From c8859e2636aefdec9890c331f8cd790193a0862e Mon Sep 17 00:00:00 2001 From: Vuong Date: Sat, 12 Oct 2024 18:22:15 +0800 Subject: [PATCH 01/91] added `databricks_app` resource --- apps/resource_app.go | 88 +++++++++ apps/resource_app_test.go | 289 ++++++++++++++++++++++++++++++ internal/providers/sdkv2/sdkv2.go | 2 + 3 files changed, 379 insertions(+) create mode 100644 apps/resource_app.go create mode 100644 apps/resource_app_test.go diff --git a/apps/resource_app.go b/apps/resource_app.go new file mode 100644 index 0000000000..d716701417 --- /dev/null +++ b/apps/resource_app.go @@ -0,0 +1,88 @@ +package apps + +import ( + "context" + "log" + "time" + + "github.com/databricks/databricks-sdk-go/service/apps" + "github.com/databricks/terraform-provider-databricks/common" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" +) + +const defaultEndpointProvisionTimeout = 75 * time.Minute +const deleteCallTimeout = 10 * time.Second + +func ResourceApp() common.Resource { + s := common.StructToSchema(apps.App{}, func(m map[string]*schema.Schema) map[string]*schema.Schema { + common.CustomizeSchemaPath(m, "name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) + for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", + "default_source_code_path", "pending_deployment", "service_principal_id", "service_principal_name", + "update_time", "updater", "url"} { + common.CustomizeSchemaPath(m, p).SetComputed() + } + return m + }) + return common.Resource{ + Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { + var create apps.CreateAppRequest + common.DataToStructPointer(d, s, &create) + w, err := c.WorkspaceClient() + if err != nil { + return err + } + wait, err := w.Apps.Create(ctx, create) + if err != nil { + return err + } + app, err := wait.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) + if err != nil { + log.Printf("[ERROR] Error waiting for app to be created: %s", err.Error()) + _, nestedErr := w.Apps.DeleteByName(ctx, create.Name) + if nestedErr != nil { + log.Printf("[ERROR] Error cleaning up app: %s", nestedErr.Error()) + } + return err + } + d.SetId(app.Name) + return nil + }, + Read: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { + w, err := c.WorkspaceClient() + if err != nil { + return err + } + app, err := w.Apps.GetByName(ctx, d.Id()) + if err != nil { + return err + } + return common.StructToData(app, s, d) + }, + Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { + var update apps.UpdateAppRequest + common.DataToStructPointer(d, s, &update) + w, err := c.WorkspaceClient() + if err != nil { + return err + } + app, err := w.Apps.Update(ctx, update) + if err != nil { + return err + } + return common.StructToData(app, s, d) + }, + Delete: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { + w, err := c.WorkspaceClient() + if err != nil { + return err + } + _, err = w.Apps.DeleteByName(ctx, d.Id()) + return err + }, + Schema: s, + Timeouts: &schema.ResourceTimeout{ + Create: schema.DefaultTimeout(defaultEndpointProvisionTimeout), + }, + } +} diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go new file mode 100644 index 0000000000..864b7c4cb2 --- /dev/null +++ b/apps/resource_app_test.go @@ -0,0 +1,289 @@ +package apps + +import ( + "testing" + + "github.com/databricks/databricks-sdk-go/experimental/mocks" + "github.com/databricks/databricks-sdk-go/qa/poll" + "github.com/databricks/databricks-sdk-go/service/apps" + "github.com/stretchr/testify/mock" + + "github.com/databricks/terraform-provider-databricks/qa" +) + +func getTestApp(warehouseName, endpointName string) *apps.App { + return &apps.App{ + Name: "my-custom-app", + Description: "My app description.", + ComputeStatus: &apps.ComputeStatus{ + State: "ERROR", + Message: "App compute is active.", + }, + AppStatus: &apps.ApplicationStatus{ + State: "DEPLOYING", + Message: "Application is running.", + }, + Url: "my-custom-app-123.cloud.databricksapps.com", + ActiveDeployment: &apps.AppDeployment{ + DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", + SourceCodePath: "/Workspace/user@test.com/my_custom_app", + Mode: "SNAPSHOT", + DeploymentArtifacts: &apps.AppDeploymentArtifacts{ + SourceCodePath: "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc", + }, + Status: &apps.AppDeploymentStatus{ + State: "SUCCEEDED", + Message: "Deployment is in progress.", + }, + CreateTime: "2019-08-24T14:15:22Z", + Creator: "user@test.com", + UpdateTime: "2019-08-24T14:15:22Z", + }, + CreateTime: "2019-08-24T14:15:22Z", + Creator: "user@test.com", + UpdateTime: "2019-08-24T14:15:22Z", + Updater: "user@test.com", + PendingDeployment: &apps.AppDeployment{ + DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", + SourceCodePath: "/Workspace/user@test.com/my_custom_app", + Mode: "SNAPSHOT", + DeploymentArtifacts: &apps.AppDeploymentArtifacts{ + SourceCodePath: "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc", + }, + Status: &apps.AppDeploymentStatus{ + State: "SUCCEEDED", + Message: "Deployment is in progress.", + }, + CreateTime: "2019-08-24T14:15:22Z", + Creator: "user@test.com", + UpdateTime: "2019-08-24T14:15:22Z", + }, + Resources: []apps.AppResource{ + { + Name: "api-key", + Description: "API key for external service.", + Secret: &apps.AppResourceSecret{ + Scope: "my-scope", + Key: "my-key", + Permission: "READ", + }, + SqlWarehouse: &apps.AppResourceSqlWarehouse{ + Id: warehouseName, + Permission: "CAN_MANAGE", + }, + ServingEndpoint: &apps.AppResourceServingEndpoint{ + Name: endpointName, + Permission: "CAN_MANAGE", + }, + Job: &apps.AppResourceJob{ + Id: "1234", + Permission: "CAN_MANAGE", + }, + }, + }, + ServicePrincipalId: 0, + ServicePrincipalName: "string", + DefaultSourceCodePath: "/Workspace/user@test.com/my_custom_app", + } +} + +func getTestAppData(warehouseName, endpointName string) map[string]interface{} { + return map[string]any{ + "name": "my-custom-app", + "description": "My app description.", + "compute_status": []any{map[string]any{"state": "ERROR", "message": "App compute is active."}}, + "app_status": []any{map[string]any{"state": "DEPLOYING", "message": "Application is running."}}, + "url": "my-custom-app-123.cloud.databricksapps.com", + "active_deployment": []any{map[string]any{ + "deployment_id": "01ef0bda89f21f08a8351f41e4a9b948", + "source_code_path": "/Workspace/user@test.com/my_custom_app", + "mode": "SNAPSHOT", + "deployment_artifacts": []any{map[string]any{"source_code_path": "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc"}}, + "status": []any{map[string]any{"state": "SUCCEEDED", "message": "Deployment is in progress."}}, + "create_time": "2019-08-24T14:15:22Z", + "creator": "user@test.com", + "update_time": "2019-08-24T14:15:22Z", + }}, + "resources": []any{map[string]any{ + "name": "api-key", + "description": "API key for external service.", + "secret": []any{map[string]any{ + "scope": "my-scope", + "key": "my-key", + "permission": "READ", + }}, + "sql_warehouse": []any{map[string]any{ + "id": warehouseName, + "permission": "CAN_MANAGE", + }}, + "serving_endpoint": []any{map[string]any{ + "name": endpointName, + "permission": "CAN_MANAGE", + }}, + "job": []any{map[string]any{ + "id": "1234", + "permission": "CAN_MANAGE", + }}, + }}, + "create_time": "2019-08-24T14:15:22Z", + "creator": "user@test.com", + } +} + +func TestResourceAppsCreate(t *testing.T) { + qa.ResourceFixture{ + MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { + api := a.GetMockAppsAPI().EXPECT() + api.Create(mock.Anything, apps.CreateAppRequest{ + Name: "my-custom-app", + Description: "My app description.", + Resources: []apps.AppResource{ + { + Name: "api-key", + Description: "API key for external service.", + Secret: &apps.AppResourceSecret{ + Scope: "my-scope", + Key: "my-key", + Permission: "READ", + }, + SqlWarehouse: &apps.AppResourceSqlWarehouse{ + Id: "e9ca293f79a74b5c", + Permission: "CAN_MANAGE", + }, + ServingEndpoint: &apps.AppResourceServingEndpoint{ + Name: "databricks-meta-llama-3-1-70b-instruct", + Permission: "CAN_MANAGE", + }, + Job: &apps.AppResourceJob{ + Id: "1234", + Permission: "CAN_MANAGE", + }, + }, + }, + }).Return(&apps.WaitGetAppActive[apps.App]{Poll: poll.Simple(*getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"))}, nil) + api.GetByName(mock.Anything, "my-custom-app").Return( + getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) + }, + Create: true, + HCL: ` + name = "my-custom-app" + description = "My app description." + resources { + name = "api-key" + description = "API key for external service." + secret { + scope = "my-scope" + key = "my-key" + permission = "READ" + } + sql_warehouse { + id = "e9ca293f79a74b5c" + permission = "CAN_MANAGE" + } + serving_endpoint { + name = "databricks-meta-llama-3-1-70b-instruct" + permission = "CAN_MANAGE" + } + job { + id = "1234" + permission = "CAN_MANAGE" + } + } + `, + Resource: ResourceApp(), + }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) +} + +func TestResourceAppsRead(t *testing.T) { + qa.ResourceFixture{ + MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { + a.GetMockAppsAPI().EXPECT(). + GetByName(mock.Anything, "my-custom-app"). + Return(getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) + }, + Resource: ResourceApp(), + Read: true, + New: true, + ID: "my-custom-app", + }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) +} + +func TestResourceAppsUpdate(t *testing.T) { + qa.ResourceFixture{ + MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { + api := a.GetMockAppsAPI().EXPECT() + api.Update(mock.Anything, apps.UpdateAppRequest{ + Name: "my-custom-app", + Description: "My app description.", + Resources: []apps.AppResource{ + { + Name: "api-key", + Description: "API key for external service.", + Secret: &apps.AppResourceSecret{ + Scope: "my-scope", + Key: "my-key", + Permission: "READ", + }, + SqlWarehouse: &apps.AppResourceSqlWarehouse{ + Id: "new_warehouse", + Permission: "CAN_MANAGE", + }, + ServingEndpoint: &apps.AppResourceServingEndpoint{ + Name: "new_endpoint", + Permission: "CAN_MANAGE", + }, + Job: &apps.AppResourceJob{ + Id: "1234", + Permission: "CAN_MANAGE", + }, + }, + }, + }).Return(getTestApp("new_warehouse", "new_endpoint"), nil) + api.GetByName(mock.Anything, "my-custom-app"). + Return(getTestApp("new_warehouse", "new_endpoint"), nil) + }, + Resource: ResourceApp(), + Update: true, + InstanceState: map[string]string{ + "name": "my-custom-app", + "description": "My app description.", + }, + HCL: ` + name = "my-custom-app" + description = "My app description." + resources { + name = "api-key" + description = "API key for external service." + secret { + scope = "my-scope" + key = "my-key" + permission = "READ" + } + sql_warehouse { + id = "new_warehouse" + permission = "CAN_MANAGE" + } + serving_endpoint { + name = "new_endpoint" + permission = "CAN_MANAGE" + } + job { + id = "1234" + permission = "CAN_MANAGE" + } + } + `, + ID: "my-custom-app", + }.ApplyAndExpectData(t, getTestAppData("new_warehouse", "new_endpoint")) +} + +func TestResourceAppsDelete(t *testing.T) { + qa.ResourceFixture{ + MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { + a.GetMockAppsAPI().EXPECT().DeleteByName(mock.Anything, "my-custom-app").Return(getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) + }, + Resource: ResourceApp(), + Delete: true, + ID: "my-custom-app", + }.ApplyAndExpectData(t, nil) +} diff --git a/internal/providers/sdkv2/sdkv2.go b/internal/providers/sdkv2/sdkv2.go index 65ab1f4973..4e32c86236 100644 --- a/internal/providers/sdkv2/sdkv2.go +++ b/internal/providers/sdkv2/sdkv2.go @@ -23,6 +23,7 @@ import ( "github.com/databricks/databricks-sdk-go/useragent" "github.com/databricks/terraform-provider-databricks/access" + "github.com/databricks/terraform-provider-databricks/apps" "github.com/databricks/terraform-provider-databricks/aws" "github.com/databricks/terraform-provider-databricks/catalog" "github.com/databricks/terraform-provider-databricks/clusters" @@ -128,6 +129,7 @@ func DatabricksProvider() *schema.Provider { }, ResourcesMap: map[string]*schema.Resource{ // must be in alphabetical order "databricks_access_control_rule_set": permissions.ResourceAccessControlRuleSet().ToResource(), + "databricks_app": apps.ResourceApp().ToResource(), "databricks_artifact_allowlist": catalog.ResourceArtifactAllowlist().ToResource(), "databricks_aws_s3_mount": storage.ResourceAWSS3Mount().ToResource(), "databricks_azure_adls_gen1_mount": storage.ResourceAzureAdlsGen1Mount().ToResource(), From 962d9f24f4f45ae3deb28302731f2210ddf7ffbc Mon Sep 17 00:00:00 2001 From: Vuong Date: Wed, 16 Oct 2024 18:08:32 +0800 Subject: [PATCH 02/91] wip --- apps/resource_app.go | 91 ++++++++++++++++++++++++++------- apps/resource_app_test.go | 80 +++++++++++++++-------------- internal/acceptance/app_test.go | 42 +++++++++++++++ 3 files changed, 158 insertions(+), 55 deletions(-) create mode 100644 internal/acceptance/app_test.go diff --git a/apps/resource_app.go b/apps/resource_app.go index d716701417..0830dc5d81 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -14,32 +14,77 @@ import ( const defaultEndpointProvisionTimeout = 75 * time.Minute const deleteCallTimeout = 10 * time.Second +type App struct { + apps.App + // The mode of which the deployment will manage the source code. + Mode string `json:"mode,omitempty"` + // The workspace file system path of the source code used to create the app + // deployment. This is different from + // `deployment_artifacts.source_code_path`, which is the path used by the + // deployed app. The former refers to the original source code location of + // the app in the workspace during deployment creation, whereas the latter + // provides a system generated stable snapshotted source code path used by + // the deployment. + SourceCodePath string `json:"source_code_path,omitempty"` +} + +func (App) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { + + // Required fields & validation + s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) + s.SchemaPath("mode").SetDefault("SNAPSHOT").SetValidateFunc(validation.StringInSlice([]string{"SNAPSHOT", "AUTO_SYNC"}, false)) + + // Computed fields + for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", + "default_source_code_path", "pending_deployment", "service_principal_id", "service_principal_name", + "update_time", "updater", "url"} { + s.SchemaPath(p).SetComputed() + } + + // SuppressDiff + s.SchemaPath("source_code_path").SetCustomSuppressDiff(common.WorkspacePathPrefixDiffSuppress) + + return s +} + +var appSchema = common.StructToSchema(App{}, nil) + func ResourceApp() common.Resource { - s := common.StructToSchema(apps.App{}, func(m map[string]*schema.Schema) map[string]*schema.Schema { - common.CustomizeSchemaPath(m, "name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) - for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", - "default_source_code_path", "pending_deployment", "service_principal_id", "service_principal_name", - "update_time", "updater", "url"} { - common.CustomizeSchemaPath(m, p).SetComputed() - } - return m - }) return common.Resource{ Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var create apps.CreateAppRequest - common.DataToStructPointer(d, s, &create) + var createApp apps.CreateAppRequest + var createAppDeployment apps.CreateAppDeploymentRequest + common.DataToStructPointer(d, appSchema, &createApp) + common.DataToStructPointer(d, appSchema, &createAppDeployment) w, err := c.WorkspaceClient() if err != nil { return err } - wait, err := w.Apps.Create(ctx, create) + + // create the app, which does not require the source code path yet + wait, err := w.Apps.Create(ctx, createApp) if err != nil { return err } app, err := wait.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) if err != nil { log.Printf("[ERROR] Error waiting for app to be created: %s", err.Error()) - _, nestedErr := w.Apps.DeleteByName(ctx, create.Name) + _, nestedErr := w.Apps.DeleteByName(ctx, createApp.Name) + if nestedErr != nil { + log.Printf("[ERROR] Error cleaning up app: %s", nestedErr.Error()) + } + return err + } + // now deploy the app, using the source code path + createAppDeployment.AppName = app.Name + waitDeploy, err := w.Apps.Deploy(ctx, createAppDeployment) + if err != nil { + return err + } + _, err = waitDeploy.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) + if err != nil { + log.Printf("[ERROR] Error waiting for app to be deployed: %s", err.Error()) + _, nestedErr := w.Apps.DeleteByName(ctx, createApp.Name) if nestedErr != nil { log.Printf("[ERROR] Error cleaning up app: %s", nestedErr.Error()) } @@ -57,20 +102,30 @@ func ResourceApp() common.Resource { if err != nil { return err } - return common.StructToData(app, s, d) + return common.StructToData(app, appSchema, d) }, Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { var update apps.UpdateAppRequest - common.DataToStructPointer(d, s, &update) + common.DataToStructPointer(d, appSchema, &update) w, err := c.WorkspaceClient() if err != nil { return err } - app, err := w.Apps.Update(ctx, update) + _, err = w.Apps.Update(ctx, update) if err != nil { return err } - return common.StructToData(app, s, d) + if d.HasChanges("source_code_path", "mode") { + _, err = w.Apps.Deploy(ctx, apps.CreateAppDeploymentRequest{ + AppName: d.Id(), + Mode: apps.AppDeploymentMode(d.Get("mode").(string)), + SourceCodePath: d.Get("source_code_path").(string), + }) + if err != nil { + return err + } + } + return nil }, Delete: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { w, err := c.WorkspaceClient() @@ -80,7 +135,7 @@ func ResourceApp() common.Resource { _, err = w.Apps.DeleteByName(ctx, d.Id()) return err }, - Schema: s, + Schema: appSchema, Timeouts: &schema.ResourceTimeout{ Create: schema.DefaultTimeout(defaultEndpointProvisionTimeout), }, diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index 864b7c4cb2..be6bb58f58 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -11,6 +11,24 @@ import ( "github.com/databricks/terraform-provider-databricks/qa" ) +func getTestAppDeployment(path string) *apps.AppDeployment { + return &apps.AppDeployment{ + DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", + SourceCodePath: path, + Mode: "SNAPSHOT", + DeploymentArtifacts: &apps.AppDeploymentArtifacts{ + SourceCodePath: "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc", + }, + Status: &apps.AppDeploymentStatus{ + State: "SUCCEEDED", + Message: "Deployment is in progress.", + }, + CreateTime: "2019-08-24T14:15:22Z", + Creator: "user@test.com", + UpdateTime: "2019-08-24T14:15:22Z", + } +} + func getTestApp(warehouseName, endpointName string) *apps.App { return &apps.App{ Name: "my-custom-app", @@ -23,41 +41,13 @@ func getTestApp(warehouseName, endpointName string) *apps.App { State: "DEPLOYING", Message: "Application is running.", }, - Url: "my-custom-app-123.cloud.databricksapps.com", - ActiveDeployment: &apps.AppDeployment{ - DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", - SourceCodePath: "/Workspace/user@test.com/my_custom_app", - Mode: "SNAPSHOT", - DeploymentArtifacts: &apps.AppDeploymentArtifacts{ - SourceCodePath: "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc", - }, - Status: &apps.AppDeploymentStatus{ - State: "SUCCEEDED", - Message: "Deployment is in progress.", - }, - CreateTime: "2019-08-24T14:15:22Z", - Creator: "user@test.com", - UpdateTime: "2019-08-24T14:15:22Z", - }, - CreateTime: "2019-08-24T14:15:22Z", - Creator: "user@test.com", - UpdateTime: "2019-08-24T14:15:22Z", - Updater: "user@test.com", - PendingDeployment: &apps.AppDeployment{ - DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", - SourceCodePath: "/Workspace/user@test.com/my_custom_app", - Mode: "SNAPSHOT", - DeploymentArtifacts: &apps.AppDeploymentArtifacts{ - SourceCodePath: "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc", - }, - Status: &apps.AppDeploymentStatus{ - State: "SUCCEEDED", - Message: "Deployment is in progress.", - }, - CreateTime: "2019-08-24T14:15:22Z", - Creator: "user@test.com", - UpdateTime: "2019-08-24T14:15:22Z", - }, + Url: "my-custom-app-123.cloud.databricksapps.com", + ActiveDeployment: getTestAppDeployment("/Workspace/user@test.com/my_custom_app"), + CreateTime: "2019-08-24T14:15:22Z", + Creator: "user@test.com", + UpdateTime: "2019-08-24T14:15:22Z", + Updater: "user@test.com", + PendingDeployment: getTestAppDeployment("/Workspace/user@test.com/my_custom_app"), Resources: []apps.AppResource{ { Name: "api-key", @@ -161,6 +151,11 @@ func TestResourceAppsCreate(t *testing.T) { }, }, }).Return(&apps.WaitGetAppActive[apps.App]{Poll: poll.Simple(*getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"))}, nil) + api.Deploy(mock.Anything, apps.CreateAppDeploymentRequest{ + AppName: "my-custom-app", + Mode: "SNAPSHOT", + SourceCodePath: "/Workspace/user@test.com/my_custom_app", + }).Return(&apps.WaitGetDeploymentAppSucceeded[apps.AppDeployment]{Poll: poll.Simple(*getTestAppDeployment("/Workspace/user@test.com/my_custom_app"))}, nil) api.GetByName(mock.Anything, "my-custom-app").Return( getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) }, @@ -168,6 +163,8 @@ func TestResourceAppsCreate(t *testing.T) { HCL: ` name = "my-custom-app" description = "My app description." + source_code_path = "/Workspace/user@test.com/my_custom_app" + mode = "SNAPSHOT" resources { name = "api-key" description = "API key for external service." @@ -239,18 +236,27 @@ func TestResourceAppsUpdate(t *testing.T) { }, }, }).Return(getTestApp("new_warehouse", "new_endpoint"), nil) + api.Deploy(mock.Anything, apps.CreateAppDeploymentRequest{ + AppName: "my-custom-app", + Mode: "SNAPSHOT", + SourceCodePath: "/Workspace/user@test.com/my_new_custom_app", + }).Return(&apps.WaitGetDeploymentAppSucceeded[apps.AppDeployment]{Poll: poll.Simple(*getTestAppDeployment("/Workspace/user@test.com/my_new_custom_app"))}, nil) api.GetByName(mock.Anything, "my-custom-app"). Return(getTestApp("new_warehouse", "new_endpoint"), nil) }, Resource: ResourceApp(), Update: true, InstanceState: map[string]string{ - "name": "my-custom-app", - "description": "My app description.", + "name": "my-custom-app", + "description": "My app description.", + "source_code_path": "/Workspace/user@test.com/my_custom_app", + "mode": "SNAPSHOT", }, HCL: ` name = "my-custom-app" description = "My app description." + source_code_path = "/Workspace/user@test.com/my_new_custom_app" + mode = "SNAPSHOT" resources { name = "api-key" description = "API key for external service." diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go new file mode 100644 index 0000000000..517e617e7d --- /dev/null +++ b/internal/acceptance/app_test.go @@ -0,0 +1,42 @@ +package acceptance + +import ( + "fmt" + "testing" +) + +var ( + appTemplate = ` + resource "databricks_workspace_file" "this" { + source = "{var.CWD}/../../storage/testdata/tf-test-python.py" + path = "/Shared/%s/xx_{var.RANDOM}" + } + resource "databricks_app" "this" { + name = "my-custom-app" + description = "%s" + source_code_path = databricks_workspace_file.this.workspace_path + mode = "SNAPSHOT" + }` +) + +func TestAccAppCreate(t *testing.T) { + loadWorkspaceEnv(t) + if isGcp(t) { + skipf(t)("not available on GCP") + } + WorkspaceLevel(t, Step{ + Template: fmt.Sprintf(appTemplate, "app", "My app"), + }) +} + +func TestAccAppUpdate(t *testing.T) { + loadWorkspaceEnv(t) + if isGcp(t) { + skipf(t)("not available on GCP") + } + WorkspaceLevel(t, Step{ + Template: fmt.Sprintf(budgetTemplate, "app", "My app"), + }, Step{ + Template: fmt.Sprintf(budgetTemplate, "app", "My new app"), + }) +} From 2e9137aa60b64da7eed8d1d783b28501cd4ed055 Mon Sep 17 00:00:00 2001 From: Vuong Date: Tue, 29 Oct 2024 17:10:14 +0800 Subject: [PATCH 03/91] add doc --- docs/resources/app.md | 80 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 docs/resources/app.md diff --git a/docs/resources/app.md b/docs/resources/app.md new file mode 100644 index 0000000000..358f96e973 --- /dev/null +++ b/docs/resources/app.md @@ -0,0 +1,80 @@ +--- +subcategory: "Apps" +--- +# databricks_app Resource + +-> This feature is in [Public Preview](https://docs.databricks.com/release-notes/release-types.html). + +Apps run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on. + +## Example Usage + +```hcl +resource "databricks_app" "this" { + name = "my-custom-app" + description = "My app" + source_code_path = "/Workspace/user@test.com/my_custom_app" + mode = "SNAPSHOT" +} +``` + +## Argument Reference + +The following arguments are required: + +* `name` - (Required) The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. It must be unique within the workspace. +* `description` - The description of the app. + +One or more `resource` block with the following arguments: + +* `name` - Name of the App Resource. +* `description` - Description of the App Resource. + +* One or more of the following resource blocks + * `secret` block + * `scope` - Scope of the secret to grant permission on. + * `key` - Key of the secret to grant permission on. + * `permission` - Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: `READ`, `WRITE`, `MANAGE`. + * `sql_warehouse` block + * `id` - Id of the SQL warehouse to grant permission on. + * `permission` - Permission to grant on the SQL warehouse. Supported permissions are: `CAN_MANAGE`, `CAN_USE`, `IS_OWNER`. + * `serving_endpoint` block + * `name` - Name of the serving endpoint to grant permission on. + * `permission` - Permission to grant on the serving endpoint. Supported permissions are: `CAN_MANAGE`, `CAN_QUERY`, `CAN_VIEW`. + * `job` block + * `id` - Id of the job to grant permission on. + * `permission` - Permissions to grant on the Job. Supported permissions are: `CAN_MANAGE`, `IS_OWNER`, `CAN_MANAGE_RUN`, `CAN_VIEW`. + +## Attribute Reference + +In addition to all arguments above, the following attributes are exported: + +* `compute_status` block + * `state` - State of the app compute. + * `message` - Compute status message +* `app_status` block + * `state` - State of the application. + * `message` - Application status message +* `url` - The URL of the app once it is deployed. +* `create_time` - The creation time of the app. +* `creator` - The email of the user that created the app. +* `update_time` - The update time of the app. +* `updater` - The email of the user that last updated the app. +* `service_principal_id` - id of the app service principal +* `service_principal_name` - name of the app service principal +* `default_source_code_path` - The default workspace file system path of the source code from which app deployment are created. This field tracks the workspace source code path of the last active deployment. + +## Import + +This resource can be imported by name: + +```bash +terraform import databricks_app.this +``` + +## Related Resources + +The following resources are used in the same context: + +* [databricks_cluster](cluster.md) to create [Databricks Clusters](https://docs.databricks.com/clusters/index.html). +* [databricks_library](library.md) to install a [library](https://docs.databricks.com/libraries/index.html) on [databricks_cluster](cluster.md). From 91b516632dec88397ccd44eeb4a164598a999d1e Mon Sep 17 00:00:00 2001 From: Vuong Date: Tue, 29 Oct 2024 17:46:35 +0800 Subject: [PATCH 04/91] alias --- apps/resource_app.go | 61 +++++++++++++++++++++++++++------ apps/resource_app_test.go | 6 ++-- internal/acceptance/app_test.go | 21 ++++++++++++ 3 files changed, 75 insertions(+), 13 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 0830dc5d81..2c6828c9bd 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -11,10 +11,14 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" ) -const defaultEndpointProvisionTimeout = 75 * time.Minute +const defaultAppProvisionTimeout = 10 * time.Minute const deleteCallTimeout = 10 * time.Second -type App struct { +var appAliasMap = map[string]string{ + "resources": "resource", +} + +type appStruct struct { apps.App // The mode of which the deployment will manage the source code. Mode string `json:"mode,omitempty"` @@ -28,12 +32,49 @@ type App struct { SourceCodePath string `json:"source_code_path,omitempty"` } -func (App) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { +type appCreateStruct struct { + apps.CreateAppRequest +} + +func (appCreateStruct) Aliases() map[string]map[string]string { + return map[string]map[string]string{ + "apps.appCreateStruct": appAliasMap, + } +} + +func (appCreateStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { + return s +} + +type appUpdateStruct struct { + apps.UpdateAppRequest +} + +func (appUpdateStruct) Aliases() map[string]map[string]string { + return map[string]map[string]string{ + "apps.appUpdateStruct": appAliasMap, + } +} + +func (appUpdateStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { + return s +} + +func (appStruct) Aliases() map[string]map[string]string { + return map[string]map[string]string{ + "apps.appStruct": appAliasMap, + } +} + +func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { // Required fields & validation s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) s.SchemaPath("mode").SetDefault("SNAPSHOT").SetValidateFunc(validation.StringInSlice([]string{"SNAPSHOT", "AUTO_SYNC"}, false)) + // Slice set + s.SchemaPath("resource").SetSliceSet() + // Computed fields for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", "default_source_code_path", "pending_deployment", "service_principal_id", "service_principal_name", @@ -47,12 +88,12 @@ func (App) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSch return s } -var appSchema = common.StructToSchema(App{}, nil) +var appSchema = common.StructToSchema(appStruct{}, nil) func ResourceApp() common.Resource { return common.Resource{ Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var createApp apps.CreateAppRequest + var createApp appCreateStruct var createAppDeployment apps.CreateAppDeploymentRequest common.DataToStructPointer(d, appSchema, &createApp) common.DataToStructPointer(d, appSchema, &createAppDeployment) @@ -62,7 +103,7 @@ func ResourceApp() common.Resource { } // create the app, which does not require the source code path yet - wait, err := w.Apps.Create(ctx, createApp) + wait, err := w.Apps.Create(ctx, createApp.CreateAppRequest) if err != nil { return err } @@ -102,16 +143,16 @@ func ResourceApp() common.Resource { if err != nil { return err } - return common.StructToData(app, appSchema, d) + return common.StructToData(appStruct{App: *app}, appSchema, d) }, Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var update apps.UpdateAppRequest + var update appUpdateStruct common.DataToStructPointer(d, appSchema, &update) w, err := c.WorkspaceClient() if err != nil { return err } - _, err = w.Apps.Update(ctx, update) + _, err = w.Apps.Update(ctx, update.UpdateAppRequest) if err != nil { return err } @@ -137,7 +178,7 @@ func ResourceApp() common.Resource { }, Schema: appSchema, Timeouts: &schema.ResourceTimeout{ - Create: schema.DefaultTimeout(defaultEndpointProvisionTimeout), + Create: schema.DefaultTimeout(defaultAppProvisionTimeout), }, } } diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index be6bb58f58..dc1290d9bd 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -94,7 +94,7 @@ func getTestAppData(warehouseName, endpointName string) map[string]interface{} { "creator": "user@test.com", "update_time": "2019-08-24T14:15:22Z", }}, - "resources": []any{map[string]any{ + "resource": []any{map[string]any{ "name": "api-key", "description": "API key for external service.", "secret": []any{map[string]any{ @@ -165,7 +165,7 @@ func TestResourceAppsCreate(t *testing.T) { description = "My app description." source_code_path = "/Workspace/user@test.com/my_custom_app" mode = "SNAPSHOT" - resources { + resource { name = "api-key" description = "API key for external service." secret { @@ -257,7 +257,7 @@ func TestResourceAppsUpdate(t *testing.T) { description = "My app description." source_code_path = "/Workspace/user@test.com/my_new_custom_app" mode = "SNAPSHOT" - resources { + resource { name = "api-key" description = "API key for external service." secret { diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go index 517e617e7d..9d9ccae361 100644 --- a/internal/acceptance/app_test.go +++ b/internal/acceptance/app_test.go @@ -7,6 +7,19 @@ import ( var ( appTemplate = ` + resource "databricks_sql_endpoint" "this" { + name = "tf-{var.RANDOM}" + cluster_size = "2X-Small" + max_num_clusters = 1 + + tags { + custom_tags { + key = "Owner" + value = "eng-dev-ecosystem-team_at_databricks.com" + } + } + } + resource "databricks_workspace_file" "this" { source = "{var.CWD}/../../storage/testdata/tf-test-python.py" path = "/Shared/%s/xx_{var.RANDOM}" @@ -16,6 +29,14 @@ var ( description = "%s" source_code_path = databricks_workspace_file.this.workspace_path mode = "SNAPSHOT" + resource { + name = "warehouse" + description = "warehouse for app" + sql_warehouse { + id = databricks_sql_endpoint.this.id + permission = "CAN_MANAGE" + } + } }` ) From 35b85eb205e4f45c6f6a5cbf631691e42f16e562 Mon Sep 17 00:00:00 2001 From: Vuong Date: Tue, 29 Oct 2024 17:58:55 +0800 Subject: [PATCH 05/91] fix --- apps/resource_app.go | 3 --- internal/providers/sdkv2/sdkv2.go | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 2c6828c9bd..c306372ac2 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -72,9 +72,6 @@ func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.Customiza s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) s.SchemaPath("mode").SetDefault("SNAPSHOT").SetValidateFunc(validation.StringInSlice([]string{"SNAPSHOT", "AUTO_SYNC"}, false)) - // Slice set - s.SchemaPath("resource").SetSliceSet() - // Computed fields for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", "default_source_code_path", "pending_deployment", "service_principal_id", "service_principal_name", diff --git a/internal/providers/sdkv2/sdkv2.go b/internal/providers/sdkv2/sdkv2.go index d34757ddb6..4d20a3e3a3 100644 --- a/internal/providers/sdkv2/sdkv2.go +++ b/internal/providers/sdkv2/sdkv2.go @@ -130,7 +130,7 @@ func DatabricksProvider() *schema.Provider { ResourcesMap: map[string]*schema.Resource{ // must be in alphabetical order "databricks_access_control_rule_set": permissions.ResourceAccessControlRuleSet().ToResource(), "databricks_alert": sql.ResourceAlert().ToResource(), - "databricks_app": apps.ResourceApp().ToResource(), + "databricks_app": apps.ResourceApp().ToResource(), "databricks_artifact_allowlist": catalog.ResourceArtifactAllowlist().ToResource(), "databricks_aws_s3_mount": storage.ResourceAWSS3Mount().ToResource(), "databricks_azure_adls_gen1_mount": storage.ResourceAzureAdlsGen1Mount().ToResource(), From 9c7ad60c0fcda71fc619fb62a6d05f277e09e84b Mon Sep 17 00:00:00 2001 From: Vuong Date: Wed, 30 Oct 2024 14:25:37 +0800 Subject: [PATCH 06/91] fix test --- internal/acceptance/app_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go index 9d9ccae361..03845d1441 100644 --- a/internal/acceptance/app_test.go +++ b/internal/acceptance/app_test.go @@ -25,7 +25,7 @@ var ( path = "/Shared/%s/xx_{var.RANDOM}" } resource "databricks_app" "this" { - name = "my-custom-app" + name = "{var.RANDOM}" description = "%s" source_code_path = databricks_workspace_file.this.workspace_path mode = "SNAPSHOT" @@ -56,8 +56,8 @@ func TestAccAppUpdate(t *testing.T) { skipf(t)("not available on GCP") } WorkspaceLevel(t, Step{ - Template: fmt.Sprintf(budgetTemplate, "app", "My app"), + Template: fmt.Sprintf(appTemplate, "app", "My app"), }, Step{ - Template: fmt.Sprintf(budgetTemplate, "app", "My new app"), + Template: fmt.Sprintf(appTemplate, "app", "My new app"), }) } From 863fa37336835f6c98af44a3134370143ac0df5d Mon Sep 17 00:00:00 2001 From: Vuong Date: Wed, 30 Oct 2024 16:41:33 +0800 Subject: [PATCH 07/91] fix test --- internal/acceptance/app_test.go | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go index 03845d1441..dfdfba26fa 100644 --- a/internal/acceptance/app_test.go +++ b/internal/acceptance/app_test.go @@ -20,14 +20,18 @@ var ( } } + resource "databricks_directory" "my_custom_directory" { + path = "/Shared/provider-test/xx_{var.RANDOM}" + } + resource "databricks_workspace_file" "this" { source = "{var.CWD}/../../storage/testdata/tf-test-python.py" - path = "/Shared/%s/xx_{var.RANDOM}" + path = databricks_directory.my_custom_directory.path + "/tf-test-python.py" } resource "databricks_app" "this" { name = "{var.RANDOM}" description = "%s" - source_code_path = databricks_workspace_file.this.workspace_path + source_code_path = databricks_directory.my_custom_directory.path mode = "SNAPSHOT" resource { name = "warehouse" @@ -46,7 +50,7 @@ func TestAccAppCreate(t *testing.T) { skipf(t)("not available on GCP") } WorkspaceLevel(t, Step{ - Template: fmt.Sprintf(appTemplate, "app", "My app"), + Template: fmt.Sprintf(appTemplate, "My app"), }) } @@ -56,8 +60,8 @@ func TestAccAppUpdate(t *testing.T) { skipf(t)("not available on GCP") } WorkspaceLevel(t, Step{ - Template: fmt.Sprintf(appTemplate, "app", "My app"), + Template: fmt.Sprintf(appTemplate, "My app"), }, Step{ - Template: fmt.Sprintf(appTemplate, "app", "My new app"), + Template: fmt.Sprintf(appTemplate, "My new app"), }) } From 2d7b38cb535fff12a61cbe809ea99bc8d8a2b521 Mon Sep 17 00:00:00 2001 From: Vuong Date: Wed, 30 Oct 2024 20:53:39 +0800 Subject: [PATCH 08/91] fix --- internal/acceptance/app_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go index dfdfba26fa..b4f75000f8 100644 --- a/internal/acceptance/app_test.go +++ b/internal/acceptance/app_test.go @@ -26,7 +26,7 @@ var ( resource "databricks_workspace_file" "this" { source = "{var.CWD}/../../storage/testdata/tf-test-python.py" - path = databricks_directory.my_custom_directory.path + "/tf-test-python.py" + path = "${databricks_directory.my_custom_directory.path}/tf-test-python.py" } resource "databricks_app" "this" { name = "{var.RANDOM}" From ff8bee8de414870603b38a9a5115b0882d9b04e5 Mon Sep 17 00:00:00 2001 From: Vuong Date: Thu, 14 Nov 2024 18:36:02 +0700 Subject: [PATCH 09/91] feedback --- apps/resource_app.go | 85 ++++------------------------ apps/resource_app_test.go | 113 +++++++++++++++++--------------------- docs/resources/app.md | 32 +++++------ 3 files changed, 74 insertions(+), 156 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index c306372ac2..3ec730ae6e 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -20,44 +20,6 @@ var appAliasMap = map[string]string{ type appStruct struct { apps.App - // The mode of which the deployment will manage the source code. - Mode string `json:"mode,omitempty"` - // The workspace file system path of the source code used to create the app - // deployment. This is different from - // `deployment_artifacts.source_code_path`, which is the path used by the - // deployed app. The former refers to the original source code location of - // the app in the workspace during deployment creation, whereas the latter - // provides a system generated stable snapshotted source code path used by - // the deployment. - SourceCodePath string `json:"source_code_path,omitempty"` -} - -type appCreateStruct struct { - apps.CreateAppRequest -} - -func (appCreateStruct) Aliases() map[string]map[string]string { - return map[string]map[string]string{ - "apps.appCreateStruct": appAliasMap, - } -} - -func (appCreateStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { - return s -} - -type appUpdateStruct struct { - apps.UpdateAppRequest -} - -func (appUpdateStruct) Aliases() map[string]map[string]string { - return map[string]map[string]string{ - "apps.appUpdateStruct": appAliasMap, - } -} - -func (appUpdateStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { - return s } func (appStruct) Aliases() map[string]map[string]string { @@ -70,7 +32,6 @@ func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.Customiza // Required fields & validation s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) - s.SchemaPath("mode").SetDefault("SNAPSHOT").SetValidateFunc(validation.StringInSlice([]string{"SNAPSHOT", "AUTO_SYNC"}, false)) // Computed fields for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", @@ -78,10 +39,6 @@ func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.Customiza "update_time", "updater", "url"} { s.SchemaPath(p).SetComputed() } - - // SuppressDiff - s.SchemaPath("source_code_path").SetCustomSuppressDiff(common.WorkspacePathPrefixDiffSuppress) - return s } @@ -90,17 +47,17 @@ var appSchema = common.StructToSchema(appStruct{}, nil) func ResourceApp() common.Resource { return common.Resource{ Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var createApp appCreateStruct - var createAppDeployment apps.CreateAppDeploymentRequest + var createApp appStruct common.DataToStructPointer(d, appSchema, &createApp) - common.DataToStructPointer(d, appSchema, &createAppDeployment) w, err := c.WorkspaceClient() if err != nil { return err } - // create the app, which does not require the source code path yet - wait, err := w.Apps.Create(ctx, createApp.CreateAppRequest) + // create the app + wait, err := w.Apps.Create(ctx, apps.CreateAppRequest{ + App: &createApp.App, + }) if err != nil { return err } @@ -113,21 +70,6 @@ func ResourceApp() common.Resource { } return err } - // now deploy the app, using the source code path - createAppDeployment.AppName = app.Name - waitDeploy, err := w.Apps.Deploy(ctx, createAppDeployment) - if err != nil { - return err - } - _, err = waitDeploy.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) - if err != nil { - log.Printf("[ERROR] Error waiting for app to be deployed: %s", err.Error()) - _, nestedErr := w.Apps.DeleteByName(ctx, createApp.Name) - if nestedErr != nil { - log.Printf("[ERROR] Error cleaning up app: %s", nestedErr.Error()) - } - return err - } d.SetId(app.Name) return nil }, @@ -143,26 +85,19 @@ func ResourceApp() common.Resource { return common.StructToData(appStruct{App: *app}, appSchema, d) }, Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var update appUpdateStruct + var update appStruct common.DataToStructPointer(d, appSchema, &update) w, err := c.WorkspaceClient() if err != nil { return err } - _, err = w.Apps.Update(ctx, update.UpdateAppRequest) + _, err = w.Apps.Update(ctx, apps.UpdateAppRequest{ + App: &update.App, + Name: d.Id(), + }) if err != nil { return err } - if d.HasChanges("source_code_path", "mode") { - _, err = w.Apps.Deploy(ctx, apps.CreateAppDeploymentRequest{ - AppName: d.Id(), - Mode: apps.AppDeploymentMode(d.Get("mode").(string)), - SourceCodePath: d.Get("source_code_path").(string), - }) - if err != nil { - return err - } - } return nil }, Delete: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index dc1290d9bd..e2a96164e7 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -125,37 +125,34 @@ func TestResourceAppsCreate(t *testing.T) { MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { api := a.GetMockAppsAPI().EXPECT() api.Create(mock.Anything, apps.CreateAppRequest{ - Name: "my-custom-app", - Description: "My app description.", - Resources: []apps.AppResource{ - { - Name: "api-key", - Description: "API key for external service.", - Secret: &apps.AppResourceSecret{ - Scope: "my-scope", - Key: "my-key", - Permission: "READ", - }, - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: "e9ca293f79a74b5c", - Permission: "CAN_MANAGE", - }, - ServingEndpoint: &apps.AppResourceServingEndpoint{ - Name: "databricks-meta-llama-3-1-70b-instruct", - Permission: "CAN_MANAGE", - }, - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE", + App: &apps.App{ + Name: "my-custom-app", + Description: "My app description.", + Resources: []apps.AppResource{ + { + Name: "api-key", + Description: "API key for external service.", + Secret: &apps.AppResourceSecret{ + Scope: "my-scope", + Key: "my-key", + Permission: "READ", + }, + SqlWarehouse: &apps.AppResourceSqlWarehouse{ + Id: "e9ca293f79a74b5c", + Permission: "CAN_MANAGE", + }, + ServingEndpoint: &apps.AppResourceServingEndpoint{ + Name: "databricks-meta-llama-3-1-70b-instruct", + Permission: "CAN_MANAGE", + }, + Job: &apps.AppResourceJob{ + Id: "1234", + Permission: "CAN_MANAGE", + }, }, }, }, }).Return(&apps.WaitGetAppActive[apps.App]{Poll: poll.Simple(*getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"))}, nil) - api.Deploy(mock.Anything, apps.CreateAppDeploymentRequest{ - AppName: "my-custom-app", - Mode: "SNAPSHOT", - SourceCodePath: "/Workspace/user@test.com/my_custom_app", - }).Return(&apps.WaitGetDeploymentAppSucceeded[apps.AppDeployment]{Poll: poll.Simple(*getTestAppDeployment("/Workspace/user@test.com/my_custom_app"))}, nil) api.GetByName(mock.Anything, "my-custom-app").Return( getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) }, @@ -163,8 +160,6 @@ func TestResourceAppsCreate(t *testing.T) { HCL: ` name = "my-custom-app" description = "My app description." - source_code_path = "/Workspace/user@test.com/my_custom_app" - mode = "SNAPSHOT" resource { name = "api-key" description = "API key for external service." @@ -210,53 +205,47 @@ func TestResourceAppsUpdate(t *testing.T) { MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { api := a.GetMockAppsAPI().EXPECT() api.Update(mock.Anything, apps.UpdateAppRequest{ - Name: "my-custom-app", - Description: "My app description.", - Resources: []apps.AppResource{ - { - Name: "api-key", - Description: "API key for external service.", - Secret: &apps.AppResourceSecret{ - Scope: "my-scope", - Key: "my-key", - Permission: "READ", - }, - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: "new_warehouse", - Permission: "CAN_MANAGE", - }, - ServingEndpoint: &apps.AppResourceServingEndpoint{ - Name: "new_endpoint", - Permission: "CAN_MANAGE", - }, - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE", + Name: "my-custom-app", + App: &apps.App{ + Name: "my-custom-app", + Description: "My app description.", + Resources: []apps.AppResource{ + { + Name: "api-key", + Description: "API key for external service.", + Secret: &apps.AppResourceSecret{ + Scope: "my-scope", + Key: "my-key", + Permission: "READ", + }, + SqlWarehouse: &apps.AppResourceSqlWarehouse{ + Id: "new_warehouse", + Permission: "CAN_MANAGE", + }, + ServingEndpoint: &apps.AppResourceServingEndpoint{ + Name: "new_endpoint", + Permission: "CAN_MANAGE", + }, + Job: &apps.AppResourceJob{ + Id: "1234", + Permission: "CAN_MANAGE", + }, }, }, }, }).Return(getTestApp("new_warehouse", "new_endpoint"), nil) - api.Deploy(mock.Anything, apps.CreateAppDeploymentRequest{ - AppName: "my-custom-app", - Mode: "SNAPSHOT", - SourceCodePath: "/Workspace/user@test.com/my_new_custom_app", - }).Return(&apps.WaitGetDeploymentAppSucceeded[apps.AppDeployment]{Poll: poll.Simple(*getTestAppDeployment("/Workspace/user@test.com/my_new_custom_app"))}, nil) api.GetByName(mock.Anything, "my-custom-app"). Return(getTestApp("new_warehouse", "new_endpoint"), nil) }, Resource: ResourceApp(), Update: true, InstanceState: map[string]string{ - "name": "my-custom-app", - "description": "My app description.", - "source_code_path": "/Workspace/user@test.com/my_custom_app", - "mode": "SNAPSHOT", + "name": "my-custom-app", + "description": "My app description.", }, HCL: ` name = "my-custom-app" description = "My app description." - source_code_path = "/Workspace/user@test.com/my_new_custom_app" - mode = "SNAPSHOT" resource { name = "api-key" description = "API key for external service." diff --git a/docs/resources/app.md b/docs/resources/app.md index 358f96e973..b3b2f90880 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -13,8 +13,6 @@ Apps run directly on a customer’s Databricks instance, integrate with their da resource "databricks_app" "this" { name = "my-custom-app" description = "My app" - source_code_path = "/Workspace/user@test.com/my_custom_app" - mode = "SNAPSHOT" } ``` @@ -27,23 +25,19 @@ The following arguments are required: One or more `resource` block with the following arguments: -* `name` - Name of the App Resource. -* `description` - Description of the App Resource. - -* One or more of the following resource blocks - * `secret` block - * `scope` - Scope of the secret to grant permission on. - * `key` - Key of the secret to grant permission on. - * `permission` - Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: `READ`, `WRITE`, `MANAGE`. - * `sql_warehouse` block - * `id` - Id of the SQL warehouse to grant permission on. - * `permission` - Permission to grant on the SQL warehouse. Supported permissions are: `CAN_MANAGE`, `CAN_USE`, `IS_OWNER`. - * `serving_endpoint` block - * `name` - Name of the serving endpoint to grant permission on. - * `permission` - Permission to grant on the serving endpoint. Supported permissions are: `CAN_MANAGE`, `CAN_QUERY`, `CAN_VIEW`. - * `job` block - * `id` - Id of the job to grant permission on. - * `permission` - Permissions to grant on the Job. Supported permissions are: `CAN_MANAGE`, `IS_OWNER`, `CAN_MANAGE_RUN`, `CAN_VIEW`. +* `secret` block + * `scope` - Scope of the secret to grant permission on. + * `key` - Key of the secret to grant permission on. + * `permission` - Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: `READ`, `WRITE`, `MANAGE`. +* `sql_warehouse` block + * `id` - Id of the SQL warehouse to grant permission on. + * `permission` - Permission to grant on the SQL warehouse. Supported permissions are: `CAN_MANAGE`, `CAN_USE`, `IS_OWNER`. +* `serving_endpoint` block + * `name` - Name of the serving endpoint to grant permission on. + * `permission` - Permission to grant on the serving endpoint. Supported permissions are: `CAN_MANAGE`, `CAN_QUERY`, `CAN_VIEW`. +* `job` block + * `id` - Id of the job to grant permission on. + * `permission` - Permissions to grant on the Job. Supported permissions are: `CAN_MANAGE`, `IS_OWNER`, `CAN_MANAGE_RUN`, `CAN_VIEW`. ## Attribute Reference From 0daeea175b1733d7789a5e60853fb0349d128118 Mon Sep 17 00:00:00 2001 From: Vuong Date: Fri, 15 Nov 2024 07:07:27 +0700 Subject: [PATCH 10/91] fix test --- internal/acceptance/app_test.go | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go index b4f75000f8..1e4be950e1 100644 --- a/internal/acceptance/app_test.go +++ b/internal/acceptance/app_test.go @@ -20,19 +20,9 @@ var ( } } - resource "databricks_directory" "my_custom_directory" { - path = "/Shared/provider-test/xx_{var.RANDOM}" - } - - resource "databricks_workspace_file" "this" { - source = "{var.CWD}/../../storage/testdata/tf-test-python.py" - path = "${databricks_directory.my_custom_directory.path}/tf-test-python.py" - } resource "databricks_app" "this" { name = "{var.RANDOM}" description = "%s" - source_code_path = databricks_directory.my_custom_directory.path - mode = "SNAPSHOT" resource { name = "warehouse" description = "warehouse for app" From eda8a916319cebe3575e114899bc49dd24e01a91 Mon Sep 17 00:00:00 2001 From: Vuong Date: Fri, 15 Nov 2024 22:33:58 +0800 Subject: [PATCH 11/91] feedback --- apps/resource_app.go | 27 +++++++++++++++++++++------ docs/resources/app.md | 14 +++++++++++++- 2 files changed, 34 insertions(+), 7 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 3ec730ae6e..fb787313ae 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -3,6 +3,7 @@ package apps import ( "context" "log" + "regexp" "time" "github.com/databricks/databricks-sdk-go/service/apps" @@ -11,8 +12,10 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" ) -const defaultAppProvisionTimeout = 10 * time.Minute -const deleteCallTimeout = 10 * time.Second +const ( + defaultAppProvisionTimeout = 10 * time.Minute + deleteCallTimeout = 10 * time.Second +) var appAliasMap = map[string]string{ "resources": "resource", @@ -31,12 +34,23 @@ func (appStruct) Aliases() map[string]map[string]string { func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { // Required fields & validation - s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringLenBetween(2, 30)) + s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringMatch(regexp.MustCompile("^[a-z-]{2,30}$"), "name must contain only lowercase alphanumeric characters and hyphens, and be between 2 and 30 characters long")) // Computed fields - for _, p := range []string{"active_deployment", "app_status", "compute_status", "create_time", "creator", - "default_source_code_path", "pending_deployment", "service_principal_id", "service_principal_name", - "update_time", "updater", "url"} { + for _, p := range []string{ + "active_deployment", + "app_status", + "compute_status", + "create_time", + "creator", + "default_source_code_path", + "pending_deployment", + "service_principal_id", + "service_principal_name", + "update_time", + "updater", + "url", + } { s.SchemaPath(p).SetComputed() } return s @@ -61,6 +75,7 @@ func ResourceApp() common.Resource { if err != nil { return err } + // wait for up to the create timeout, accounting for the deletion on failure. app, err := wait.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) if err != nil { log.Printf("[ERROR] Error waiting for app to be created: %s", err.Error()) diff --git a/docs/resources/app.md b/docs/resources/app.md index b3b2f90880..d3576714b6 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -13,6 +13,18 @@ Apps run directly on a customer’s Databricks instance, integrate with their da resource "databricks_app" "this" { name = "my-custom-app" description = "My app" + sql_warehouse { + id = "e9ca293f79a74b5c" + permission = "CAN_MANAGE" + } + serving_endpoint { + name = "databricks-meta-llama-3-1-70b-instruct" + permission = "CAN_MANAGE" + } + job { + id = "1234" + permission = "CAN_MANAGE" + } } ``` @@ -21,7 +33,7 @@ resource "databricks_app" "this" { The following arguments are required: * `name` - (Required) The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. It must be unique within the workspace. -* `description` - The description of the app. +* `description` - (Optional) The description of the app. One or more `resource` block with the following arguments: From f254176da7791c91d64d312823829529384450e7 Mon Sep 17 00:00:00 2001 From: Vuong Date: Sat, 16 Nov 2024 10:49:52 +0800 Subject: [PATCH 12/91] feedback --- apps/resource_app.go | 3 +- apps/resource_app_test.go | 177 +++++++++++++++++++++++--------------- docs/resources/app.md | 10 ++- qa/testing.go | 2 +- 4 files changed, 118 insertions(+), 74 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index fb787313ae..338471b8fd 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -35,7 +35,8 @@ func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.Customiza // Required fields & validation s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringMatch(regexp.MustCompile("^[a-z-]{2,30}$"), "name must contain only lowercase alphanumeric characters and hyphens, and be between 2 and 30 characters long")) - + // Resources should be a set + s.SchemaPath("resource").SetSliceSet() // Computed fields for _, p := range []string{ "active_deployment", diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index e2a96164e7..955a670327 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -11,6 +11,45 @@ import ( "github.com/databricks/terraform-provider-databricks/qa" ) +func getTestAppRequest(warehouseName, endpointName string) *apps.App { + return &apps.App{ + Name: "my-custom-app", + Description: "My app description.", + Resources: []apps.AppResource{ + { + Name: "sql-warehouse", + SqlWarehouse: &apps.AppResourceSqlWarehouse{ + Id: warehouseName, + Permission: "CAN_MANAGE", + }, + }, + { + Name: "job", + Job: &apps.AppResourceJob{ + Id: "1234", + Permission: "CAN_MANAGE", + }, + }, + { + Name: "serving-endpoint", + ServingEndpoint: &apps.AppResourceServingEndpoint{ + Name: endpointName, + Permission: "CAN_MANAGE", + }, + }, + { + Name: "api-key", + Description: "API key for external service.", + Secret: &apps.AppResourceSecret{ + Scope: "my-scope", + Key: "my-key", + Permission: "READ", + }, + }, + }, + } +} + func getTestAppDeployment(path string) *apps.AppDeployment { return &apps.AppDeployment{ DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", @@ -29,7 +68,7 @@ func getTestAppDeployment(path string) *apps.AppDeployment { } } -func getTestApp(warehouseName, endpointName string) *apps.App { +func getTestAppResponse(warehouseName, endpointName string) *apps.App { return &apps.App{ Name: "my-custom-app", Description: "My app description.", @@ -57,14 +96,23 @@ func getTestApp(warehouseName, endpointName string) *apps.App { Key: "my-key", Permission: "READ", }, + }, + { + Name: "sql-warehouse", SqlWarehouse: &apps.AppResourceSqlWarehouse{ Id: warehouseName, Permission: "CAN_MANAGE", }, + }, + { + Name: "serving-endpoint", ServingEndpoint: &apps.AppResourceServingEndpoint{ Name: endpointName, Permission: "CAN_MANAGE", }, + }, + { + Name: "job", Job: &apps.AppResourceJob{ Id: "1234", Permission: "CAN_MANAGE", @@ -95,21 +143,42 @@ func getTestAppData(warehouseName, endpointName string) map[string]interface{} { "update_time": "2019-08-24T14:15:22Z", }}, "resource": []any{map[string]any{ - "name": "api-key", - "description": "API key for external service.", + "name": "api-key", + "description": "API key for external service.", + "job": []any{}, + "sql_warehouse": []any{}, + "serving_endpoint": []any{}, "secret": []any{map[string]any{ "scope": "my-scope", "key": "my-key", "permission": "READ", }}, + }, map[string]any{ + "name": "sql-warehouse", + "description": "", + "job": []any{}, + "secret": []any{}, + "serving_endpoint": []any{}, "sql_warehouse": []any{map[string]any{ "id": warehouseName, "permission": "CAN_MANAGE", }}, + }, map[string]any{ + "name": "serving-endpoint", + "description": "", + "job": []any{}, + "secret": []any{}, + "sql_warehouse": []any{}, "serving_endpoint": []any{map[string]any{ "name": endpointName, "permission": "CAN_MANAGE", }}, + }, map[string]any{ + "name": "job", + "description": "", + "sql_warehouse": []any{}, + "secret": []any{}, + "serving_endpoint": []any{}, "job": []any{map[string]any{ "id": "1234", "permission": "CAN_MANAGE", @@ -125,36 +194,10 @@ func TestResourceAppsCreate(t *testing.T) { MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { api := a.GetMockAppsAPI().EXPECT() api.Create(mock.Anything, apps.CreateAppRequest{ - App: &apps.App{ - Name: "my-custom-app", - Description: "My app description.", - Resources: []apps.AppResource{ - { - Name: "api-key", - Description: "API key for external service.", - Secret: &apps.AppResourceSecret{ - Scope: "my-scope", - Key: "my-key", - Permission: "READ", - }, - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: "e9ca293f79a74b5c", - Permission: "CAN_MANAGE", - }, - ServingEndpoint: &apps.AppResourceServingEndpoint{ - Name: "databricks-meta-llama-3-1-70b-instruct", - Permission: "CAN_MANAGE", - }, - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE", - }, - }, - }, - }, - }).Return(&apps.WaitGetAppActive[apps.App]{Poll: poll.Simple(*getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"))}, nil) + App: getTestAppRequest("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), + }).Return(&apps.WaitGetAppActive[apps.App]{Poll: poll.Simple(*getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"))}, nil) api.GetByName(mock.Anything, "my-custom-app").Return( - getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) + getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) }, Create: true, HCL: ` @@ -168,19 +211,28 @@ func TestResourceAppsCreate(t *testing.T) { key = "my-key" permission = "READ" } + } + resource { + name = "sql-warehouse" sql_warehouse { id = "e9ca293f79a74b5c" permission = "CAN_MANAGE" - } + } + } + resource { + name = "serving-endpoint" serving_endpoint { name = "databricks-meta-llama-3-1-70b-instruct" permission = "CAN_MANAGE" } + } + resource { + name = "job" job { id = "1234" permission = "CAN_MANAGE" - } - } + } + } `, Resource: ResourceApp(), }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) @@ -191,7 +243,7 @@ func TestResourceAppsRead(t *testing.T) { MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { a.GetMockAppsAPI().EXPECT(). GetByName(mock.Anything, "my-custom-app"). - Return(getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) + Return(getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) }, Resource: ResourceApp(), Read: true, @@ -206,36 +258,10 @@ func TestResourceAppsUpdate(t *testing.T) { api := a.GetMockAppsAPI().EXPECT() api.Update(mock.Anything, apps.UpdateAppRequest{ Name: "my-custom-app", - App: &apps.App{ - Name: "my-custom-app", - Description: "My app description.", - Resources: []apps.AppResource{ - { - Name: "api-key", - Description: "API key for external service.", - Secret: &apps.AppResourceSecret{ - Scope: "my-scope", - Key: "my-key", - Permission: "READ", - }, - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: "new_warehouse", - Permission: "CAN_MANAGE", - }, - ServingEndpoint: &apps.AppResourceServingEndpoint{ - Name: "new_endpoint", - Permission: "CAN_MANAGE", - }, - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE", - }, - }, - }, - }, - }).Return(getTestApp("new_warehouse", "new_endpoint"), nil) + App: getTestAppRequest("e9ca293f79a74b5c", "new_endpoint"), + }).Return(getTestAppResponse("e9ca293f79a74b5c", "new_endpoint"), nil) api.GetByName(mock.Anything, "my-custom-app"). - Return(getTestApp("new_warehouse", "new_endpoint"), nil) + Return(getTestAppResponse("e9ca293f79a74b5c", "new_endpoint"), nil) }, Resource: ResourceApp(), Update: true, @@ -254,28 +280,37 @@ func TestResourceAppsUpdate(t *testing.T) { key = "my-key" permission = "READ" } + } + resource { + name = "sql-warehouse" sql_warehouse { - id = "new_warehouse" + id = "e9ca293f79a74b5c" permission = "CAN_MANAGE" - } + } + } + resource { + name = "serving-endpoint" serving_endpoint { name = "new_endpoint" permission = "CAN_MANAGE" } + } + resource { + name = "job" job { id = "1234" permission = "CAN_MANAGE" - } - } + } + } `, ID: "my-custom-app", - }.ApplyAndExpectData(t, getTestAppData("new_warehouse", "new_endpoint")) + }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "new_endpoint")) } func TestResourceAppsDelete(t *testing.T) { qa.ResourceFixture{ MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { - a.GetMockAppsAPI().EXPECT().DeleteByName(mock.Anything, "my-custom-app").Return(getTestApp("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) + a.GetMockAppsAPI().EXPECT().DeleteByName(mock.Anything, "my-custom-app").Return(getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) }, Resource: ResourceApp(), Delete: true, diff --git a/docs/resources/app.md b/docs/resources/app.md index d3576714b6..31edaaba24 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -34,8 +34,16 @@ The following arguments are required: * `name` - (Required) The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. It must be unique within the workspace. * `description` - (Optional) The description of the app. +* `resource` - (Optional) A list of resources that the app have access to. -One or more `resource` block with the following arguments: +### resource Configuration Block + +This block describes individual resource. + +* `name` - (Required) The name of the resource. +* `description` - (Optional) The description of the resource. + +Exactly one of the specific blocks described below is required: * `secret` block * `scope` - Scope of the secret to grant permission on. diff --git a/qa/testing.go b/qa/testing.go index 045c100c1f..0390ef33bc 100644 --- a/qa/testing.go +++ b/qa/testing.go @@ -390,7 +390,7 @@ func (f ResourceFixture) ApplyAndExpectData(t *testing.T, data map[string]any) { if k == "id" { assert.Equal(t, expected, d.Id()) } else if that, ok := d.Get(k).(*schema.Set); ok { - this := expected.([]string) + this := expected.([]any) assert.Equal(t, len(this), that.Len(), "set has different length") for _, item := range this { assert.True(t, that.Contains(item), "set does not contain %s", item) From be96f91621227a6d8742e1897674e5e34c4de9c6 Mon Sep 17 00:00:00 2001 From: Vuong Date: Thu, 21 Nov 2024 10:03:41 +0800 Subject: [PATCH 13/91] feedback --- apps/resource_app.go | 5 ++++- docs/resources/app.md | 35 +++++++++++++++++++++++------------ 2 files changed, 27 insertions(+), 13 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 338471b8fd..cca820b2b7 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -34,7 +34,10 @@ func (appStruct) Aliases() map[string]map[string]string { func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { // Required fields & validation - s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(validation.StringMatch(regexp.MustCompile("^[a-z-]{2,30}$"), "name must contain only lowercase alphanumeric characters and hyphens, and be between 2 and 30 characters long")) + appNameValidationFunc := validation.StringMatch( + regexp.MustCompile("^[a-z-]{2,30}$"), + "name must contain only lowercase alphanumeric characters and hyphens, and be between 2 and 30 characters long") + s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(appNameValidationFunc) // Resources should be a set s.SchemaPath("resource").SetSliceSet() // Computed fields diff --git a/docs/resources/app.md b/docs/resources/app.md index 31edaaba24..5fbd1aae97 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -13,18 +13,27 @@ Apps run directly on a customer’s Databricks instance, integrate with their da resource "databricks_app" "this" { name = "my-custom-app" description = "My app" - sql_warehouse { - id = "e9ca293f79a74b5c" - permission = "CAN_MANAGE" + resource { + name = "sql-warehouse" + sql_warehouse { + id = "e9ca293f79a74b5c" + permission = "CAN_MANAGE" + } } - serving_endpoint { - name = "databricks-meta-llama-3-1-70b-instruct" - permission = "CAN_MANAGE" + resource { + name = "serving-endpoint" + serving_endpoint { + name = "databricks-meta-llama-3-1-70b-instruct" + permission = "CAN_MANAGE" + } } - job { - id = "1234" - permission = "CAN_MANAGE" - } + resource { + name = "job" + job { + id = "1234" + permission = "CAN_MANAGE" + } + } } ``` @@ -90,5 +99,7 @@ terraform import databricks_app.this The following resources are used in the same context: -* [databricks_cluster](cluster.md) to create [Databricks Clusters](https://docs.databricks.com/clusters/index.html). -* [databricks_library](library.md) to install a [library](https://docs.databricks.com/libraries/index.html) on [databricks_cluster](cluster.md). +* [databricks_sql_endpoint](sql_endpoint.md) to manage Databricks SQL [Endpoints](https://docs.databricks.com/sql/admin/sql-endpoints.html). +* [databricks_model_serving](model_serving.md) to serve this model on a Databricks serving endpoint. +* [databricks_secret](secret.md) to manage [secrets](https://docs.databricks.com/security/secrets/index.html#secrets-user-guide) in Databricks workspace. +* [databricks_job](job.md) to manage [Databricks Jobs](https://docs.databricks.com/jobs.html) to run non-interactive code. From 8338d094ca046fce9a6a77445c22efb893872e5d Mon Sep 17 00:00:00 2001 From: Vuong Date: Fri, 22 Nov 2024 10:37:53 +0800 Subject: [PATCH 14/91] add app permission --- docs/resources/permissions.md | 2 +- internal/acceptance/permissions_test.go | 19 +++++++++++++++++++ permissions/permission_definitions.go | 11 +++++++++++ 3 files changed, 31 insertions(+), 1 deletion(-) diff --git a/docs/resources/permissions.md b/docs/resources/permissions.md index 9696df577e..ce3f30d639 100644 --- a/docs/resources/permissions.md +++ b/docs/resources/permissions.md @@ -423,7 +423,6 @@ Valid [permission levels](https://docs.databricks.com/security/access-control/wo A folder could be specified by using either `directory_path` or `directory_id` attribute. The value for the `directory_id` is the object ID of the resource in the Databricks Workspace that is exposed as `object_id` attribute of the `databricks_directory` resource as shown below. - ```hcl resource "databricks_group" "auto" { display_name = "Automation" @@ -910,6 +909,7 @@ One type argument and at least one access control block argument are required. Exactly one of the following arguments is required: +- `app_name` - [app](app.md) name - `cluster_id` - [cluster](cluster.md) id - `cluster_policy_id` - [cluster policy](cluster_policy.md) id - `instance_pool_id` - [instance pool](instance_pool.md) id diff --git a/internal/acceptance/permissions_test.go b/internal/acceptance/permissions_test.go index 20dfb564d0..66f81a8738 100644 --- a/internal/acceptance/permissions_test.go +++ b/internal/acceptance/permissions_test.go @@ -947,3 +947,22 @@ func TestAccPermissions_Query(t *testing.T) { ExpectError: regexp.MustCompile("cannot remove management permissions for the current user for query, allowed levels: CAN_MANAGE"), }) } + +func TestAccPermissions_App(t *testing.T) { + loadDebugEnvIfRunsFromIDE(t, "workspace") + queryTemplate := ` + resource "databricks_app" "this" { + name = "{var.RANDOM}" + description = "Test app" + }` + WorkspaceLevel(t, Step{ + Template: queryTemplate + makePermissionsTestStage("app_name", "databricks_app.this.name", groupPermissions("CAN_USE")), + }, Step{ + Template: queryTemplate + makePermissionsTestStage("app_name", "databricks_app.this.name", + currentPrincipalPermission(t, "CAN_MANAGE"), groupPermissions("CAN_USE", "CAN_MANAGE")), + }, Step{ + Template: queryTemplate + makePermissionsTestStage("app_name", "databricks_app.this.name", + currentPrincipalPermission(t, "CAN_USE"), groupPermissions("CAN_USE", "CAN_MANAGE")), + ExpectError: regexp.MustCompile("cannot remove management permissions for the current user for apps, allowed levels: CAN_MANAGE"), + }) +} diff --git a/permissions/permission_definitions.go b/permissions/permission_definitions.go index 398b032a64..1c6e8537cf 100644 --- a/permissions/permission_definitions.go +++ b/permissions/permission_definitions.go @@ -743,5 +743,16 @@ func allResourcePermissions() []resourcePermissions { updateAclCustomizers: []update.ACLCustomizer{update.AddCurrentUserAsManage}, deleteAclCustomizers: []update.ACLCustomizer{update.AddCurrentUserAsManage}, }, + { + field: "app_name", + objectType: "apps", + requestObjectType: "apps", + allowedPermissionLevels: map[string]permissionLevelOptions{ + "CAN_USE": {isManagementPermission: false}, + "CAN_MANAGE": {isManagementPermission: true}, + }, + updateAclCustomizers: []update.ACLCustomizer{update.AddCurrentUserAsManage}, + deleteAclCustomizers: []update.ACLCustomizer{update.AddCurrentUserAsManage}, + }, } } From 07ea8b7500dd299d347ed9f3f12d90c7c9b1ba29 Mon Sep 17 00:00:00 2001 From: Vuong Date: Fri, 22 Nov 2024 11:29:57 +0800 Subject: [PATCH 15/91] fix test --- permissions/resource_permissions_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/permissions/resource_permissions_test.go b/permissions/resource_permissions_test.go index 983b59fbc1..12b3219acf 100644 --- a/permissions/resource_permissions_test.go +++ b/permissions/resource_permissions_test.go @@ -593,7 +593,7 @@ func TestResourcePermissionsCreate_invalid(t *testing.T) { qa.ResourceFixture{ Resource: ResourcePermissions(), Create: true, - }.ExpectError(t, "at least one type of resource identifier must be set; allowed fields: authorization, cluster_id, cluster_policy_id, dashboard_id, directory_id, directory_path, experiment_id, instance_pool_id, job_id, notebook_id, notebook_path, pipeline_id, registered_model_id, repo_id, repo_path, serving_endpoint_id, sql_alert_id, sql_dashboard_id, sql_endpoint_id, sql_query_id, vector_search_endpoint_id, workspace_file_id, workspace_file_path") + }.ExpectError(t, "at least one type of resource identifier must be set; allowed fields: app_name, authorization, cluster_id, cluster_policy_id, dashboard_id, directory_id, directory_path, experiment_id, instance_pool_id, job_id, notebook_id, notebook_path, pipeline_id, registered_model_id, repo_id, repo_path, serving_endpoint_id, sql_alert_id, sql_dashboard_id, sql_endpoint_id, sql_query_id, vector_search_endpoint_id, workspace_file_id, workspace_file_path") } func TestResourcePermissionsCreate_no_access_control(t *testing.T) { From 9e41c692be0ebba3b34aa7e092b4ca9532d0d967 Mon Sep 17 00:00:00 2001 From: Vuong Date: Fri, 22 Nov 2024 16:10:58 +0800 Subject: [PATCH 16/91] more computed fields --- apps/resource_app.go | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/resource_app.go b/apps/resource_app.go index cca820b2b7..9ad8e08cc4 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -49,6 +49,7 @@ func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.Customiza "creator", "default_source_code_path", "pending_deployment", + "service_principal_client_id", "service_principal_id", "service_principal_name", "update_time", From 0ad429477a4c7427216bd3e3cc89882264e12be0 Mon Sep 17 00:00:00 2001 From: Vuong Date: Tue, 26 Nov 2024 16:54:08 +0700 Subject: [PATCH 17/91] feedback --- apps/resource_app.go | 47 ++++++++++++++++++++----- apps/resource_app_test.go | 30 +++++++++++++++- internal/acceptance/permissions_test.go | 3 ++ 3 files changed, 70 insertions(+), 10 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 9ad8e08cc4..5637fbf310 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -2,14 +2,13 @@ package apps import ( "context" + "errors" "log" - "regexp" "time" "github.com/databricks/databricks-sdk-go/service/apps" "github.com/databricks/terraform-provider-databricks/common" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" - "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" ) const ( @@ -33,11 +32,8 @@ func (appStruct) Aliases() map[string]map[string]string { func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { - // Required fields & validation - appNameValidationFunc := validation.StringMatch( - regexp.MustCompile("^[a-z-]{2,30}$"), - "name must contain only lowercase alphanumeric characters and hyphens, and be between 2 and 30 characters long") - s.SchemaPath("name").SetRequired().SetForceNew().SetValidateFunc(appNameValidationFunc) + // Name is required and cannot be updated + s.SchemaPath("name").SetRequired().SetForceNew() // Resources should be a set s.SchemaPath("resource").SetSliceSet() // Computed fields @@ -63,11 +59,41 @@ func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.Customiza var appSchema = common.StructToSchema(appStruct{}, nil) +// each resource block should have exactly one resource type +func appHasExactlyOneOfResourceType(d *schema.ResourceData) bool { + if _, ok := d.GetOk("resource"); ok { + // resources is a TF set + resources := d.Get("resource").(*schema.Set).List() + for _, resource := range resources { + resource := resource.(map[string]interface{}) + count := 0 + for _, v := range resource { + // each resource type is stored as a list of maps. check for non-empty list + if value, ok := v.([]interface{}); ok { + if len(value) == 0 { + continue + } + count++ + } + } + if count != 1 { + return false + } + } + return true + } else { + return false + } +} + func ResourceApp() common.Resource { return common.Resource{ Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { var createApp appStruct common.DataToStructPointer(d, appSchema, &createApp) + if appHasExactlyOneOfResourceType(d) == false { + return errors.New("Exactly one resource type per resource block should be provided") + } w, err := c.WorkspaceClient() if err != nil { return err @@ -80,8 +106,9 @@ func ResourceApp() common.Resource { if err != nil { return err } + d.SetId(wait.Name) // wait for up to the create timeout, accounting for the deletion on failure. - app, err := wait.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) + _, err = wait.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) if err != nil { log.Printf("[ERROR] Error waiting for app to be created: %s", err.Error()) _, nestedErr := w.Apps.DeleteByName(ctx, createApp.Name) @@ -90,7 +117,6 @@ func ResourceApp() common.Resource { } return err } - d.SetId(app.Name) return nil }, Read: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { @@ -107,6 +133,9 @@ func ResourceApp() common.Resource { Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { var update appStruct common.DataToStructPointer(d, appSchema, &update) + if appHasExactlyOneOfResourceType(d) == false { + return errors.New("Exactly one resource type per resource block should be provided") + } w, err := c.WorkspaceClient() if err != nil { return err diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index 955a670327..ebad847383 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -195,7 +195,10 @@ func TestResourceAppsCreate(t *testing.T) { api := a.GetMockAppsAPI().EXPECT() api.Create(mock.Anything, apps.CreateAppRequest{ App: getTestAppRequest("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), - }).Return(&apps.WaitGetAppActive[apps.App]{Poll: poll.Simple(*getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"))}, nil) + }).Return(&apps.WaitGetAppActive[apps.App]{ + Name: "my-custom-app", + Poll: poll.Simple(*getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")), + }, nil) api.GetByName(mock.Anything, "my-custom-app").Return( getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) }, @@ -238,6 +241,31 @@ func TestResourceAppsCreate(t *testing.T) { }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) } +func TestResourceAppsCreateExactlyOnce(t *testing.T) { + qa.ResourceFixture{ + MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) {}, + Create: true, + HCL: ` + name = "my-custom-app" + description = "My app description." + resource { + name = "api-key" + description = "API key for external service." + secret { + scope = "my-scope" + key = "my-key" + permission = "READ" + } + serving_endpoint { + name = "databricks-meta-llama-3-1-70b-instruct" + permission = "CAN_MANAGE" + } + } + `, + Resource: ResourceApp(), + }.ExpectError(t, "Exactly one resource type per resource block should be provided") +} + func TestResourceAppsRead(t *testing.T) { qa.ResourceFixture{ MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { diff --git a/internal/acceptance/permissions_test.go b/internal/acceptance/permissions_test.go index 66f81a8738..d17145e5ec 100644 --- a/internal/acceptance/permissions_test.go +++ b/internal/acceptance/permissions_test.go @@ -950,6 +950,9 @@ func TestAccPermissions_Query(t *testing.T) { func TestAccPermissions_App(t *testing.T) { loadDebugEnvIfRunsFromIDE(t, "workspace") + if isGcp(t) { + skipf(t)("not available on GCP") + } queryTemplate := ` resource "databricks_app" "this" { name = "{var.RANDOM}" From 8bdcda914bb8ba36e4bfab517211a554e58fcd82 Mon Sep 17 00:00:00 2001 From: Vuong Date: Tue, 26 Nov 2024 17:08:42 +0700 Subject: [PATCH 18/91] fix test --- apps/resource_app.go | 8 ++++---- apps/resource_app_test.go | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 5637fbf310..297255b77b 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -91,8 +91,8 @@ func ResourceApp() common.Resource { Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { var createApp appStruct common.DataToStructPointer(d, appSchema, &createApp) - if appHasExactlyOneOfResourceType(d) == false { - return errors.New("Exactly one resource type per resource block should be provided") + if !appHasExactlyOneOfResourceType(d) { + return errors.New("exactly one resource type per resource block should be provided") } w, err := c.WorkspaceClient() if err != nil { @@ -133,8 +133,8 @@ func ResourceApp() common.Resource { Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { var update appStruct common.DataToStructPointer(d, appSchema, &update) - if appHasExactlyOneOfResourceType(d) == false { - return errors.New("Exactly one resource type per resource block should be provided") + if !appHasExactlyOneOfResourceType(d) { + return errors.New("exactly one resource type per resource block should be provided") } w, err := c.WorkspaceClient() if err != nil { diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index ebad847383..229480ed8e 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -263,7 +263,7 @@ func TestResourceAppsCreateExactlyOnce(t *testing.T) { } `, Resource: ResourceApp(), - }.ExpectError(t, "Exactly one resource type per resource block should be provided") + }.ExpectError(t, "exactly one resource type per resource block should be provided") } func TestResourceAppsRead(t *testing.T) { From 2bac7aa7cc25a9ad8aebc939fe3ef965cdf6e84b Mon Sep 17 00:00:00 2001 From: Vuong Date: Wed, 27 Nov 2024 13:17:46 +0700 Subject: [PATCH 19/91] feedback --- apps/resource_app.go | 4 ++-- apps/resource_app_test.go | 29 +++++++++++++++++++++++++++++ docs/resources/app.md | 2 +- 3 files changed, 32 insertions(+), 3 deletions(-) diff --git a/apps/resource_app.go b/apps/resource_app.go index 297255b77b..6f22b1781e 100644 --- a/apps/resource_app.go +++ b/apps/resource_app.go @@ -64,6 +64,7 @@ func appHasExactlyOneOfResourceType(d *schema.ResourceData) bool { if _, ok := d.GetOk("resource"); ok { // resources is a TF set resources := d.Get("resource").(*schema.Set).List() + log.Printf("resources: %v", resources) for _, resource := range resources { resource := resource.(map[string]interface{}) count := 0 @@ -81,9 +82,8 @@ func appHasExactlyOneOfResourceType(d *schema.ResourceData) bool { } } return true - } else { - return false } + return true } func ResourceApp() common.Resource { diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go index 229480ed8e..198c590bd5 100644 --- a/apps/resource_app_test.go +++ b/apps/resource_app_test.go @@ -241,6 +241,35 @@ func TestResourceAppsCreate(t *testing.T) { }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) } +var emptyApp = &apps.App{ + Name: "my-custom-app", + Description: "My app description.", +} + +func TestResourceAppsCreateNoResource(t *testing.T) { + qa.ResourceFixture{ + MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { + api := a.GetMockAppsAPI().EXPECT() + api.Create(mock.Anything, apps.CreateAppRequest{ + App: emptyApp, + }).Return(&apps.WaitGetAppActive[apps.App]{ + Name: "my-custom-app", + Poll: poll.Simple(*emptyApp), + }, nil) + api.GetByName(mock.Anything, "my-custom-app").Return(emptyApp, nil) + }, + Create: true, + HCL: ` + name = "my-custom-app" + description = "My app description." + `, + Resource: ResourceApp(), + }.ApplyAndExpectData(t, map[string]any{ + "name": "my-custom-app", + "description": "My app description.", + }) +} + func TestResourceAppsCreateExactlyOnce(t *testing.T) { qa.ResourceFixture{ MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) {}, diff --git a/docs/resources/app.md b/docs/resources/app.md index 5fbd1aae97..f713b35181 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -5,7 +5,7 @@ subcategory: "Apps" -> This feature is in [Public Preview](https://docs.databricks.com/release-notes/release-types.html). -Apps run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on. +[Databricks Apps](https://docs.databricks.com/en/dev-tools/databricks-apps/index.html) run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on. This resource creates the application but does not handle app deployment, which should be handled separately as part of your CI/CD pipeline. ## Example Usage From 17e192354281913ad1016bdfb5b3ae501281d554 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 28 Nov 2024 15:51:15 +0100 Subject: [PATCH 20/91] work --- apps/resource_app.go | 165 -------- apps/resource_app_test.go | 376 ------------------ internal/acceptance/account_rule_set_test.go | 4 +- internal/acceptance/app_test.go | 57 --- internal/acceptance/budget_test.go | 12 +- internal/acceptance/catalog_test.go | 4 +- internal/acceptance/cluster_test.go | 4 +- .../acceptance/custom_app_integration_test.go | 4 +- .../acceptance/data_current_config_test.go | 16 +- ...ta_mws_network_connectivity_config_test.go | 10 +- ...a_mws_network_connectivity_configs_test.go | 10 +- internal/acceptance/entitlements_test.go | 4 +- internal/acceptance/init.go | 48 +-- internal/acceptance/job_test.go | 6 +- internal/acceptance/metastore_test.go | 22 +- internal/acceptance/model_serving_test.go | 18 +- .../mws_network_connectivity_config_test.go | 4 +- internal/acceptance/mws_workspaces_test.go | 4 +- internal/acceptance/permissions_test.go | 14 +- internal/acceptance/schema_test.go | 4 +- internal/acceptance/service_principal_test.go | 12 +- internal/acceptance/sql_global_config_test.go | 8 +- internal/acceptance/sql_permissions_test.go | 2 +- internal/acceptance/sql_table_test.go | 34 +- .../acceptance/storage_credential_test.go | 6 +- internal/acceptance/vector_search_test.go | 6 +- internal/acceptance/workspace_conf_test.go | 10 +- .../providers/pluginfw/converters/tf_to_go.go | 9 +- .../pluginfw/pluginfw_rollout_utils.go | 5 +- .../pluginfw/products/app/app_acc_test.go | 132 ++++++ .../pluginfw/products/app/resource_app.go | 283 +++++++++++++ .../pluginfw/tfschema/customizable_schema.go | 14 +- .../pluginfw/tfschema/list_nested_block.go | 2 +- .../pluginfw/tfschema/nested_block_object.go | 23 +- .../pluginfw/tfschema/single_nested_block.go | 2 +- .../pluginfw/tfschema/struct_to_schema.go | 4 +- internal/providers/sdkv2/sdkv2.go | 1 - 37 files changed, 591 insertions(+), 748 deletions(-) delete mode 100644 apps/resource_app.go delete mode 100644 apps/resource_app_test.go delete mode 100644 internal/acceptance/app_test.go create mode 100644 internal/providers/pluginfw/products/app/app_acc_test.go create mode 100644 internal/providers/pluginfw/products/app/resource_app.go diff --git a/apps/resource_app.go b/apps/resource_app.go deleted file mode 100644 index 6f22b1781e..0000000000 --- a/apps/resource_app.go +++ /dev/null @@ -1,165 +0,0 @@ -package apps - -import ( - "context" - "errors" - "log" - "time" - - "github.com/databricks/databricks-sdk-go/service/apps" - "github.com/databricks/terraform-provider-databricks/common" - "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" -) - -const ( - defaultAppProvisionTimeout = 10 * time.Minute - deleteCallTimeout = 10 * time.Second -) - -var appAliasMap = map[string]string{ - "resources": "resource", -} - -type appStruct struct { - apps.App -} - -func (appStruct) Aliases() map[string]map[string]string { - return map[string]map[string]string{ - "apps.appStruct": appAliasMap, - } -} - -func (appStruct) CustomizeSchema(s *common.CustomizableSchema) *common.CustomizableSchema { - - // Name is required and cannot be updated - s.SchemaPath("name").SetRequired().SetForceNew() - // Resources should be a set - s.SchemaPath("resource").SetSliceSet() - // Computed fields - for _, p := range []string{ - "active_deployment", - "app_status", - "compute_status", - "create_time", - "creator", - "default_source_code_path", - "pending_deployment", - "service_principal_client_id", - "service_principal_id", - "service_principal_name", - "update_time", - "updater", - "url", - } { - s.SchemaPath(p).SetComputed() - } - return s -} - -var appSchema = common.StructToSchema(appStruct{}, nil) - -// each resource block should have exactly one resource type -func appHasExactlyOneOfResourceType(d *schema.ResourceData) bool { - if _, ok := d.GetOk("resource"); ok { - // resources is a TF set - resources := d.Get("resource").(*schema.Set).List() - log.Printf("resources: %v", resources) - for _, resource := range resources { - resource := resource.(map[string]interface{}) - count := 0 - for _, v := range resource { - // each resource type is stored as a list of maps. check for non-empty list - if value, ok := v.([]interface{}); ok { - if len(value) == 0 { - continue - } - count++ - } - } - if count != 1 { - return false - } - } - return true - } - return true -} - -func ResourceApp() common.Resource { - return common.Resource{ - Create: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var createApp appStruct - common.DataToStructPointer(d, appSchema, &createApp) - if !appHasExactlyOneOfResourceType(d) { - return errors.New("exactly one resource type per resource block should be provided") - } - w, err := c.WorkspaceClient() - if err != nil { - return err - } - - // create the app - wait, err := w.Apps.Create(ctx, apps.CreateAppRequest{ - App: &createApp.App, - }) - if err != nil { - return err - } - d.SetId(wait.Name) - // wait for up to the create timeout, accounting for the deletion on failure. - _, err = wait.GetWithTimeout(d.Timeout(schema.TimeoutCreate) - deleteCallTimeout) - if err != nil { - log.Printf("[ERROR] Error waiting for app to be created: %s", err.Error()) - _, nestedErr := w.Apps.DeleteByName(ctx, createApp.Name) - if nestedErr != nil { - log.Printf("[ERROR] Error cleaning up app: %s", nestedErr.Error()) - } - return err - } - return nil - }, - Read: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - w, err := c.WorkspaceClient() - if err != nil { - return err - } - app, err := w.Apps.GetByName(ctx, d.Id()) - if err != nil { - return err - } - return common.StructToData(appStruct{App: *app}, appSchema, d) - }, - Update: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - var update appStruct - common.DataToStructPointer(d, appSchema, &update) - if !appHasExactlyOneOfResourceType(d) { - return errors.New("exactly one resource type per resource block should be provided") - } - w, err := c.WorkspaceClient() - if err != nil { - return err - } - _, err = w.Apps.Update(ctx, apps.UpdateAppRequest{ - App: &update.App, - Name: d.Id(), - }) - if err != nil { - return err - } - return nil - }, - Delete: func(ctx context.Context, d *schema.ResourceData, c *common.DatabricksClient) error { - w, err := c.WorkspaceClient() - if err != nil { - return err - } - _, err = w.Apps.DeleteByName(ctx, d.Id()) - return err - }, - Schema: appSchema, - Timeouts: &schema.ResourceTimeout{ - Create: schema.DefaultTimeout(defaultAppProvisionTimeout), - }, - } -} diff --git a/apps/resource_app_test.go b/apps/resource_app_test.go deleted file mode 100644 index 198c590bd5..0000000000 --- a/apps/resource_app_test.go +++ /dev/null @@ -1,376 +0,0 @@ -package apps - -import ( - "testing" - - "github.com/databricks/databricks-sdk-go/experimental/mocks" - "github.com/databricks/databricks-sdk-go/qa/poll" - "github.com/databricks/databricks-sdk-go/service/apps" - "github.com/stretchr/testify/mock" - - "github.com/databricks/terraform-provider-databricks/qa" -) - -func getTestAppRequest(warehouseName, endpointName string) *apps.App { - return &apps.App{ - Name: "my-custom-app", - Description: "My app description.", - Resources: []apps.AppResource{ - { - Name: "sql-warehouse", - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: warehouseName, - Permission: "CAN_MANAGE", - }, - }, - { - Name: "job", - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE", - }, - }, - { - Name: "serving-endpoint", - ServingEndpoint: &apps.AppResourceServingEndpoint{ - Name: endpointName, - Permission: "CAN_MANAGE", - }, - }, - { - Name: "api-key", - Description: "API key for external service.", - Secret: &apps.AppResourceSecret{ - Scope: "my-scope", - Key: "my-key", - Permission: "READ", - }, - }, - }, - } -} - -func getTestAppDeployment(path string) *apps.AppDeployment { - return &apps.AppDeployment{ - DeploymentId: "01ef0bda89f21f08a8351f41e4a9b948", - SourceCodePath: path, - Mode: "SNAPSHOT", - DeploymentArtifacts: &apps.AppDeploymentArtifacts{ - SourceCodePath: "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc", - }, - Status: &apps.AppDeploymentStatus{ - State: "SUCCEEDED", - Message: "Deployment is in progress.", - }, - CreateTime: "2019-08-24T14:15:22Z", - Creator: "user@test.com", - UpdateTime: "2019-08-24T14:15:22Z", - } -} - -func getTestAppResponse(warehouseName, endpointName string) *apps.App { - return &apps.App{ - Name: "my-custom-app", - Description: "My app description.", - ComputeStatus: &apps.ComputeStatus{ - State: "ERROR", - Message: "App compute is active.", - }, - AppStatus: &apps.ApplicationStatus{ - State: "DEPLOYING", - Message: "Application is running.", - }, - Url: "my-custom-app-123.cloud.databricksapps.com", - ActiveDeployment: getTestAppDeployment("/Workspace/user@test.com/my_custom_app"), - CreateTime: "2019-08-24T14:15:22Z", - Creator: "user@test.com", - UpdateTime: "2019-08-24T14:15:22Z", - Updater: "user@test.com", - PendingDeployment: getTestAppDeployment("/Workspace/user@test.com/my_custom_app"), - Resources: []apps.AppResource{ - { - Name: "api-key", - Description: "API key for external service.", - Secret: &apps.AppResourceSecret{ - Scope: "my-scope", - Key: "my-key", - Permission: "READ", - }, - }, - { - Name: "sql-warehouse", - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: warehouseName, - Permission: "CAN_MANAGE", - }, - }, - { - Name: "serving-endpoint", - ServingEndpoint: &apps.AppResourceServingEndpoint{ - Name: endpointName, - Permission: "CAN_MANAGE", - }, - }, - { - Name: "job", - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE", - }, - }, - }, - ServicePrincipalId: 0, - ServicePrincipalName: "string", - DefaultSourceCodePath: "/Workspace/user@test.com/my_custom_app", - } -} - -func getTestAppData(warehouseName, endpointName string) map[string]interface{} { - return map[string]any{ - "name": "my-custom-app", - "description": "My app description.", - "compute_status": []any{map[string]any{"state": "ERROR", "message": "App compute is active."}}, - "app_status": []any{map[string]any{"state": "DEPLOYING", "message": "Application is running."}}, - "url": "my-custom-app-123.cloud.databricksapps.com", - "active_deployment": []any{map[string]any{ - "deployment_id": "01ef0bda89f21f08a8351f41e4a9b948", - "source_code_path": "/Workspace/user@test.com/my_custom_app", - "mode": "SNAPSHOT", - "deployment_artifacts": []any{map[string]any{"source_code_path": "/Workspace/Users/9627a015-e892-43f7-9085-eec3892da408/src/01ef1a1ed75d1964b62234a35efa61fc"}}, - "status": []any{map[string]any{"state": "SUCCEEDED", "message": "Deployment is in progress."}}, - "create_time": "2019-08-24T14:15:22Z", - "creator": "user@test.com", - "update_time": "2019-08-24T14:15:22Z", - }}, - "resource": []any{map[string]any{ - "name": "api-key", - "description": "API key for external service.", - "job": []any{}, - "sql_warehouse": []any{}, - "serving_endpoint": []any{}, - "secret": []any{map[string]any{ - "scope": "my-scope", - "key": "my-key", - "permission": "READ", - }}, - }, map[string]any{ - "name": "sql-warehouse", - "description": "", - "job": []any{}, - "secret": []any{}, - "serving_endpoint": []any{}, - "sql_warehouse": []any{map[string]any{ - "id": warehouseName, - "permission": "CAN_MANAGE", - }}, - }, map[string]any{ - "name": "serving-endpoint", - "description": "", - "job": []any{}, - "secret": []any{}, - "sql_warehouse": []any{}, - "serving_endpoint": []any{map[string]any{ - "name": endpointName, - "permission": "CAN_MANAGE", - }}, - }, map[string]any{ - "name": "job", - "description": "", - "sql_warehouse": []any{}, - "secret": []any{}, - "serving_endpoint": []any{}, - "job": []any{map[string]any{ - "id": "1234", - "permission": "CAN_MANAGE", - }}, - }}, - "create_time": "2019-08-24T14:15:22Z", - "creator": "user@test.com", - } -} - -func TestResourceAppsCreate(t *testing.T) { - qa.ResourceFixture{ - MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { - api := a.GetMockAppsAPI().EXPECT() - api.Create(mock.Anything, apps.CreateAppRequest{ - App: getTestAppRequest("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), - }).Return(&apps.WaitGetAppActive[apps.App]{ - Name: "my-custom-app", - Poll: poll.Simple(*getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")), - }, nil) - api.GetByName(mock.Anything, "my-custom-app").Return( - getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) - }, - Create: true, - HCL: ` - name = "my-custom-app" - description = "My app description." - resource { - name = "api-key" - description = "API key for external service." - secret { - scope = "my-scope" - key = "my-key" - permission = "READ" - } - } - resource { - name = "sql-warehouse" - sql_warehouse { - id = "e9ca293f79a74b5c" - permission = "CAN_MANAGE" - } - } - resource { - name = "serving-endpoint" - serving_endpoint { - name = "databricks-meta-llama-3-1-70b-instruct" - permission = "CAN_MANAGE" - } - } - resource { - name = "job" - job { - id = "1234" - permission = "CAN_MANAGE" - } - } - `, - Resource: ResourceApp(), - }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) -} - -var emptyApp = &apps.App{ - Name: "my-custom-app", - Description: "My app description.", -} - -func TestResourceAppsCreateNoResource(t *testing.T) { - qa.ResourceFixture{ - MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { - api := a.GetMockAppsAPI().EXPECT() - api.Create(mock.Anything, apps.CreateAppRequest{ - App: emptyApp, - }).Return(&apps.WaitGetAppActive[apps.App]{ - Name: "my-custom-app", - Poll: poll.Simple(*emptyApp), - }, nil) - api.GetByName(mock.Anything, "my-custom-app").Return(emptyApp, nil) - }, - Create: true, - HCL: ` - name = "my-custom-app" - description = "My app description." - `, - Resource: ResourceApp(), - }.ApplyAndExpectData(t, map[string]any{ - "name": "my-custom-app", - "description": "My app description.", - }) -} - -func TestResourceAppsCreateExactlyOnce(t *testing.T) { - qa.ResourceFixture{ - MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) {}, - Create: true, - HCL: ` - name = "my-custom-app" - description = "My app description." - resource { - name = "api-key" - description = "API key for external service." - secret { - scope = "my-scope" - key = "my-key" - permission = "READ" - } - serving_endpoint { - name = "databricks-meta-llama-3-1-70b-instruct" - permission = "CAN_MANAGE" - } - } - `, - Resource: ResourceApp(), - }.ExpectError(t, "exactly one resource type per resource block should be provided") -} - -func TestResourceAppsRead(t *testing.T) { - qa.ResourceFixture{ - MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { - a.GetMockAppsAPI().EXPECT(). - GetByName(mock.Anything, "my-custom-app"). - Return(getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) - }, - Resource: ResourceApp(), - Read: true, - New: true, - ID: "my-custom-app", - }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct")) -} - -func TestResourceAppsUpdate(t *testing.T) { - qa.ResourceFixture{ - MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { - api := a.GetMockAppsAPI().EXPECT() - api.Update(mock.Anything, apps.UpdateAppRequest{ - Name: "my-custom-app", - App: getTestAppRequest("e9ca293f79a74b5c", "new_endpoint"), - }).Return(getTestAppResponse("e9ca293f79a74b5c", "new_endpoint"), nil) - api.GetByName(mock.Anything, "my-custom-app"). - Return(getTestAppResponse("e9ca293f79a74b5c", "new_endpoint"), nil) - }, - Resource: ResourceApp(), - Update: true, - InstanceState: map[string]string{ - "name": "my-custom-app", - "description": "My app description.", - }, - HCL: ` - name = "my-custom-app" - description = "My app description." - resource { - name = "api-key" - description = "API key for external service." - secret { - scope = "my-scope" - key = "my-key" - permission = "READ" - } - } - resource { - name = "sql-warehouse" - sql_warehouse { - id = "e9ca293f79a74b5c" - permission = "CAN_MANAGE" - } - } - resource { - name = "serving-endpoint" - serving_endpoint { - name = "new_endpoint" - permission = "CAN_MANAGE" - } - } - resource { - name = "job" - job { - id = "1234" - permission = "CAN_MANAGE" - } - } - `, - ID: "my-custom-app", - }.ApplyAndExpectData(t, getTestAppData("e9ca293f79a74b5c", "new_endpoint")) -} - -func TestResourceAppsDelete(t *testing.T) { - qa.ResourceFixture{ - MockWorkspaceClientFunc: func(a *mocks.MockWorkspaceClient) { - a.GetMockAppsAPI().EXPECT().DeleteByName(mock.Anything, "my-custom-app").Return(getTestAppResponse("e9ca293f79a74b5c", "databricks-meta-llama-3-1-70b-instruct"), nil) - }, - Resource: ResourceApp(), - Delete: true, - ID: "my-custom-app", - }.ApplyAndExpectData(t, nil) -} diff --git a/internal/acceptance/account_rule_set_test.go b/internal/acceptance/account_rule_set_test.go index a134cdf667..ae7f5e4cc9 100644 --- a/internal/acceptance/account_rule_set_test.go +++ b/internal/acceptance/account_rule_set_test.go @@ -14,7 +14,7 @@ import ( // Application ID is mandatory in Azure today. func getServicePrincipalResource(t *testing.T) string { - if isAzure(t) { + if IsAzure(t) { return ` resource "databricks_service_principal" "this" { application_id = "{var.RANDOM_UUID}" @@ -30,7 +30,7 @@ func getServicePrincipalResource(t *testing.T) string { } func TestMwsAccAccountServicePrincipalRuleSetsFullLifeCycle(t *testing.T) { - loadAccountEnv(t) + LoadAccountEnv(t) spResource := getServicePrincipalResource(t) AccountLevel(t, Step{ Template: spResource + ` diff --git a/internal/acceptance/app_test.go b/internal/acceptance/app_test.go deleted file mode 100644 index 1e4be950e1..0000000000 --- a/internal/acceptance/app_test.go +++ /dev/null @@ -1,57 +0,0 @@ -package acceptance - -import ( - "fmt" - "testing" -) - -var ( - appTemplate = ` - resource "databricks_sql_endpoint" "this" { - name = "tf-{var.RANDOM}" - cluster_size = "2X-Small" - max_num_clusters = 1 - - tags { - custom_tags { - key = "Owner" - value = "eng-dev-ecosystem-team_at_databricks.com" - } - } - } - - resource "databricks_app" "this" { - name = "{var.RANDOM}" - description = "%s" - resource { - name = "warehouse" - description = "warehouse for app" - sql_warehouse { - id = databricks_sql_endpoint.this.id - permission = "CAN_MANAGE" - } - } - }` -) - -func TestAccAppCreate(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") - } - WorkspaceLevel(t, Step{ - Template: fmt.Sprintf(appTemplate, "My app"), - }) -} - -func TestAccAppUpdate(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") - } - WorkspaceLevel(t, Step{ - Template: fmt.Sprintf(appTemplate, "My app"), - }, Step{ - Template: fmt.Sprintf(appTemplate, "My new app"), - }) -} diff --git a/internal/acceptance/budget_test.go b/internal/acceptance/budget_test.go index 44b8262de9..c139daa47f 100644 --- a/internal/acceptance/budget_test.go +++ b/internal/acceptance/budget_test.go @@ -41,9 +41,9 @@ var ( ) func TestMwsAccBudgetCreate(t *testing.T) { - loadAccountEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") + LoadAccountEnv(t) + if IsGcp(t) { + Skipf(t)("not available on GCP") } AccountLevel(t, Step{ Template: fmt.Sprintf(budgetTemplate, "840"), @@ -51,9 +51,9 @@ func TestMwsAccBudgetCreate(t *testing.T) { } func TestMwsAccBudgetUpdate(t *testing.T) { - loadAccountEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") + LoadAccountEnv(t) + if IsGcp(t) { + Skipf(t)("not available on GCP") } AccountLevel(t, Step{ Template: fmt.Sprintf(budgetTemplate, "840"), diff --git a/internal/acceptance/catalog_test.go b/internal/acceptance/catalog_test.go index 3b1278c36e..17d81d6547 100644 --- a/internal/acceptance/catalog_test.go +++ b/internal/acceptance/catalog_test.go @@ -6,7 +6,7 @@ import ( ) func TestUcAccCatalog(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) UnityWorkspaceLevel(t, Step{ Template: fmt.Sprintf(` resource "databricks_catalog" "sandbox" { @@ -54,7 +54,7 @@ func TestUcAccCatalogIsolated(t *testing.T) { } func TestUcAccCatalogUpdate(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) UnityWorkspaceLevel(t, Step{ Template: fmt.Sprintf(` resource "databricks_catalog" "sandbox" { diff --git a/internal/acceptance/cluster_test.go b/internal/acceptance/cluster_test.go index bc1c4023d9..1f3bb71608 100644 --- a/internal/acceptance/cluster_test.go +++ b/internal/acceptance/cluster_test.go @@ -102,8 +102,8 @@ func awsClusterTemplate(availability string) string { } func TestAccClusterResource_CreateAndUpdateAwsAttributes(t *testing.T) { - loadWorkspaceEnv(t) - if isAws(t) { + LoadWorkspaceEnv(t) + if IsAws(t) { WorkspaceLevel(t, Step{ Template: awsClusterTemplate("SPOT"), }, Step{ diff --git a/internal/acceptance/custom_app_integration_test.go b/internal/acceptance/custom_app_integration_test.go index 280e5c039b..c1b51da906 100644 --- a/internal/acceptance/custom_app_integration_test.go +++ b/internal/acceptance/custom_app_integration_test.go @@ -18,14 +18,14 @@ var ( ) func TestMwsAccCustomAppIntegrationCreate(t *testing.T) { - loadAccountEnv(t) + LoadAccountEnv(t) AccountLevel(t, Step{ Template: fmt.Sprintf(customAppIntegrationTemplate, "30"), }) } func TestMwsAccCustomAppIntegrationUpdate(t *testing.T) { - loadAccountEnv(t) + LoadAccountEnv(t) AccountLevel(t, Step{ Template: fmt.Sprintf(customAppIntegrationTemplate, "30"), }, Step{ diff --git a/internal/acceptance/data_current_config_test.go b/internal/acceptance/data_current_config_test.go index 25fcce48e4..505b0ad5c4 100644 --- a/internal/acceptance/data_current_config_test.go +++ b/internal/acceptance/data_current_config_test.go @@ -22,18 +22,18 @@ func checkCurrentConfig(t *testing.T, cloudType string, isAccount string) func(s } func TestAccDataCurrentConfig(t *testing.T) { - loadWorkspaceEnv(t) - if isAws(t) { + LoadWorkspaceEnv(t) + if IsAws(t) { WorkspaceLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "aws", "false"), }) - } else if isAzure(t) { + } else if IsAzure(t) { WorkspaceLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "azure", "false"), }) - } else if isGcp(t) { + } else if IsGcp(t) { WorkspaceLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "gcp", "false"), @@ -42,18 +42,18 @@ func TestAccDataCurrentConfig(t *testing.T) { } func TestMwsAccDataCurrentConfig(t *testing.T) { - loadAccountEnv(t) - if isAws(t) { + LoadAccountEnv(t) + if IsAws(t) { AccountLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "aws", "true"), }) - } else if isAzure(t) { + } else if IsAzure(t) { AccountLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "azure", "true"), }) - } else if isGcp(t) { + } else if IsGcp(t) { AccountLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "gcp", "true"), diff --git a/internal/acceptance/data_mws_network_connectivity_config_test.go b/internal/acceptance/data_mws_network_connectivity_config_test.go index 15dc457d62..b76f9bee44 100755 --- a/internal/acceptance/data_mws_network_connectivity_config_test.go +++ b/internal/acceptance/data_mws_network_connectivity_config_test.go @@ -8,14 +8,14 @@ import ( ) func TestAccDataSourceMwsNetworkConnectivityConfigTest(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("GCP not supported") + LoadWorkspaceEnv(t) + if IsGcp(t) { + Skipf(t)("GCP not supported") } var sourceRegion string - if isAzure(t) { + if IsAzure(t) { sourceRegion = "eastus2" - } else if isAws(t) { + } else if IsAws(t) { sourceRegion = "us-east-2" } AccountLevel(t, diff --git a/internal/acceptance/data_mws_network_connectivity_configs_test.go b/internal/acceptance/data_mws_network_connectivity_configs_test.go index 94647bb4ca..ecf61dd807 100755 --- a/internal/acceptance/data_mws_network_connectivity_configs_test.go +++ b/internal/acceptance/data_mws_network_connectivity_configs_test.go @@ -8,14 +8,14 @@ import ( ) func TestAccDataSourceMwsNetworkConnectivityConfigsTest(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("GCP not supported") + LoadWorkspaceEnv(t) + if IsGcp(t) { + Skipf(t)("GCP not supported") } var region string - if isAzure(t) { + if IsAzure(t) { region = "eastus2" - } else if isAws(t) { + } else if IsAws(t) { region = "us-east-2" } AccountLevel(t, diff --git a/internal/acceptance/entitlements_test.go b/internal/acceptance/entitlements_test.go index 2aeb4e2d0b..d36cf3123e 100644 --- a/internal/acceptance/entitlements_test.go +++ b/internal/acceptance/entitlements_test.go @@ -84,9 +84,9 @@ func makePreconfig(t *testing.T, r entitlementResource) func() { } func entitlementsTest(t *testing.T, f func(*testing.T, entitlementResource)) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) sp := &servicePrincipalResource{} - if isAzure(t) { + if IsAzure(t) { // A long-lived application is used in Azure. sp.applicationId = GetEnvOrSkipTest(t, "ACCOUNT_LEVEL_SERVICE_PRINCIPAL_ID") sp.cleanup = false diff --git a/internal/acceptance/init.go b/internal/acceptance/init.go index 604d7b636c..4a869919cf 100644 --- a/internal/acceptance/init.go +++ b/internal/acceptance/init.go @@ -37,22 +37,22 @@ func init() { } func WorkspaceLevel(t *testing.T, steps ...Step) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) run(t, steps) } func AccountLevel(t *testing.T, steps ...Step) { - loadAccountEnv(t) + LoadAccountEnv(t) run(t, steps) } func UnityWorkspaceLevel(t *testing.T, steps ...Step) { - loadUcwsEnv(t) + LoadUcwsEnv(t) run(t, steps) } func UnityAccountLevel(t *testing.T, steps ...Step) { - loadUcacctEnv(t) + LoadUcacctEnv(t) run(t, steps) } @@ -125,7 +125,7 @@ func environmentTemplate(t *testing.T, template string, otherVars ...map[string] "RANDOM_UUID": createUuid(), } if len(otherVars) > 1 { - skipf(t)("cannot have more than one custom variable map") + Skipf(t)("cannot have more than one custom variable map") } if len(otherVars) == 1 { for k, v := range otherVars[0] { @@ -147,14 +147,14 @@ func environmentTemplate(t *testing.T, template string, otherVars ...map[string] value = vars[varName] } if value == "" { - skipf(t)("Missing %s %s variable.", varType, varName) + Skipf(t)("Missing %s %s variable.", varType, varName) missing++ continue } template = strings.ReplaceAll(template, `{`+varType+`.`+varName+`}`, value) } if missing > 0 { - skipf(t)("please set %d variables and restart", missing) + Skipf(t)("please set %d variables and restart", missing) } return commands.TrimLeadingWhitespace(template) } @@ -291,7 +291,7 @@ const hexCharset = "0123456789abcdef" func GetEnvOrSkipTest(t *testing.T, name string) string { value := os.Getenv(name) if value == "" { - skipf(t)("Environment variable %s is missing", name) + Skipf(t)("Environment variable %s is missing", name) } return value } @@ -300,7 +300,7 @@ func GetEnvInt64OrSkipTest(t *testing.T, name string) int64 { v := GetEnvOrSkipTest(t, name) i, err := strconv.ParseInt(v, 10, 64) if err != nil { - skipf(t)("`%s` is not int64: %s", v, err) + Skipf(t)("`%s` is not int64: %s", v, err) } return i } @@ -338,7 +338,7 @@ func RandomHex(prefix string, randLen int) string { return string(b) } -func skipf(t *testing.T) func(format string, args ...any) { +func Skipf(t *testing.T) func(format string, args ...any) { if isInDebug() { // VSCode "debug test" feature doesn't show dlv logs, // so that we fail here for maintainer productivity. @@ -359,51 +359,51 @@ func setDebugLogger() { } } -func loadWorkspaceEnv(t *testing.T) { +func LoadWorkspaceEnv(t *testing.T) { initTest(t, "workspace") if os.Getenv("DATABRICKS_ACCOUNT_ID") != "" { - skipf(t)("Skipping workspace test on account level") + Skipf(t)("Skipping workspace test on account level") } } -func loadAccountEnv(t *testing.T) { +func LoadAccountEnv(t *testing.T) { initTest(t, "account") if os.Getenv("DATABRICKS_ACCOUNT_ID") == "" { - skipf(t)("Skipping account test on workspace level") + Skipf(t)("Skipping account test on workspace level") } } -func loadUcwsEnv(t *testing.T) { +func LoadUcwsEnv(t *testing.T) { initTest(t, "ucws") if os.Getenv("TEST_METASTORE_ID") == "" { - skipf(t)("Skipping non-Unity Catalog test") + Skipf(t)("Skipping non-Unity Catalog test") } if os.Getenv("DATABRICKS_ACCOUNT_ID") != "" { - skipf(t)("Skipping workspace test on account level") + Skipf(t)("Skipping workspace test on account level") } } -func loadUcacctEnv(t *testing.T) { +func LoadUcacctEnv(t *testing.T) { initTest(t, "ucacct") if os.Getenv("TEST_METASTORE_ID") == "" { - skipf(t)("Skipping non-Unity Catalog test") + Skipf(t)("Skipping non-Unity Catalog test") } if os.Getenv("DATABRICKS_ACCOUNT_ID") == "" { - skipf(t)("Skipping account test on workspace level") + Skipf(t)("Skipping account test on workspace level") } } -func isAws(t *testing.T) bool { +func IsAws(t *testing.T) bool { awsCloudEnvs := []string{"MWS", "aws", "ucws", "ucacct"} return isCloudEnvInList(t, awsCloudEnvs) } -func isAzure(t *testing.T) bool { +func IsAzure(t *testing.T) bool { azureCloudEnvs := []string{"azure", "azure-ucacct"} return isCloudEnvInList(t, azureCloudEnvs) } -func isGcp(t *testing.T) bool { +func IsGcp(t *testing.T) bool { gcpCloudEnvs := []string{"gcp-accounts", "gcp-ucacct", "gcp-ucws", "gcp"} return isCloudEnvInList(t, gcpCloudEnvs) } @@ -411,7 +411,7 @@ func isGcp(t *testing.T) bool { func isCloudEnvInList(t *testing.T, cloudEnvs []string) bool { cloudEnv := os.Getenv("CLOUD_ENV") if cloudEnv == "" { - skipf(t)("Acceptance tests skipped unless env 'CLOUD_ENV' is set") + Skipf(t)("Acceptance tests skipped unless env 'CLOUD_ENV' is set") } return slices.Contains(cloudEnvs, cloudEnv) } diff --git a/internal/acceptance/job_test.go b/internal/acceptance/job_test.go index b28b5a6bb9..61aa41a8fc 100644 --- a/internal/acceptance/job_test.go +++ b/internal/acceptance/job_test.go @@ -356,7 +356,7 @@ func TestAccJobRunAsUser(t *testing.T) { } func TestUcAccJobRunAsServicePrincipal(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) spId := GetEnvOrSkipTest(t, "ACCOUNT_LEVEL_SERVICE_PRINCIPAL_ID") UnityWorkspaceLevel(t, Step{ Template: runAsTemplate(`service_principal_name = "` + spId + `"`), @@ -373,7 +373,7 @@ func getRunAsAttribute(t *testing.T, ctx context.Context) string { } func TestUcAccJobRunAsMutations(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) spId := GetEnvOrSkipTest(t, "ACCOUNT_LEVEL_SERVICE_PRINCIPAL_ID") // Note: the attribute must match the type of principal that the test is run as. ctx := context.Background() @@ -396,7 +396,7 @@ func TestUcAccJobRunAsMutations(t *testing.T) { } func TestAccRemoveWebhooks(t *testing.T) { - skipf(t)("There is no API to create notification destinations. Once available, add here and enable this test.") + Skipf(t)("There is no API to create notification destinations. Once available, add here and enable this test.") WorkspaceLevel(t, Step{ Template: ` resource databricks_job test { diff --git a/internal/acceptance/metastore_test.go b/internal/acceptance/metastore_test.go index a430b91839..3dfb387a34 100644 --- a/internal/acceptance/metastore_test.go +++ b/internal/acceptance/metastore_test.go @@ -10,36 +10,36 @@ import ( ) func getStorageRoot(t *testing.T) string { - if isAws(t) { + if IsAws(t) { return "s3://{env.TEST_BUCKET}/test{var.RANDOM}" - } else if isAzure(t) { + } else if IsAzure(t) { return "abfss://{var.RANDOM}@{var.RANDOM}/" - } else if isGcp(t) { + } else if IsGcp(t) { return "gs://{var.RANDOM}/metastore" } return "" } func getRegion(t *testing.T) string { - if isAws(t) { + if IsAws(t) { return "us-east-1" - } else if isAzure(t) { + } else if IsAzure(t) { return "eastus" - } else if isGcp(t) { + } else if IsGcp(t) { return "us-east1" } return "" } func TestUcAccRootlessMetastore(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "region": getRegion(t), }) } func TestUcAccMetastore(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), @@ -47,7 +47,7 @@ func TestUcAccMetastore(t *testing.T) { } func TestUcAccMetastoreDeltaSharing(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), @@ -58,7 +58,7 @@ func TestUcAccMetastoreDeltaSharing(t *testing.T) { } func TestUcAccMetastoreDeltaSharingInfiniteLifetime(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), @@ -68,7 +68,7 @@ func TestUcAccMetastoreDeltaSharingInfiniteLifetime(t *testing.T) { } func TestUcAccMetastoreWithOwnerUpdates(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTestWithOwnerUpdates(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), diff --git a/internal/acceptance/model_serving_test.go b/internal/acceptance/model_serving_test.go index 808ef634ab..a7c0887df1 100644 --- a/internal/acceptance/model_serving_test.go +++ b/internal/acceptance/model_serving_test.go @@ -8,9 +8,9 @@ import ( ) func TestAccModelServing(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") + LoadWorkspaceEnv(t) + if IsGcp(t) { + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-model-serving-%s", @@ -86,9 +86,9 @@ func TestAccModelServing(t *testing.T) { } func TestUcAccModelServingProvisionedThroughput(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") + LoadWorkspaceEnv(t) + if IsGcp(t) { + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-model-serving-pt-%s", @@ -161,9 +161,9 @@ func TestUcAccModelServingProvisionedThroughput(t *testing.T) { } func TestAccModelServingExternalModel(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") + LoadWorkspaceEnv(t) + if IsGcp(t) { + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-model-serving-em-%s", diff --git a/internal/acceptance/mws_network_connectivity_config_test.go b/internal/acceptance/mws_network_connectivity_config_test.go index d7fbf5d8f8..29d6239620 100644 --- a/internal/acceptance/mws_network_connectivity_config_test.go +++ b/internal/acceptance/mws_network_connectivity_config_test.go @@ -5,7 +5,7 @@ import ( ) func TestMwsAccNetworkConnectivityConfig(t *testing.T) { - if isAzure(t) { + if IsAzure(t) { AccountLevel(t, Step{ Template: ` resource "databricks_mws_network_connectivity_config" "this" { @@ -34,7 +34,7 @@ func TestMwsAccNetworkConnectivityConfig(t *testing.T) { `, }) } - if isAws(t) { + if IsAws(t) { AccountLevel(t, Step{ Template: ` resource "databricks_mws_network_connectivity_config" "this" { diff --git a/internal/acceptance/mws_workspaces_test.go b/internal/acceptance/mws_workspaces_test.go index 07d5279874..e0ce44c72e 100644 --- a/internal/acceptance/mws_workspaces_test.go +++ b/internal/acceptance/mws_workspaces_test.go @@ -301,8 +301,8 @@ func TestMwsAccGcpPscWorkspaces(t *testing.T) { } func TestMwsAccAwsChangeToServicePrincipal(t *testing.T) { - if !isAws(t) { - skipf(t)("TestMwsAccAwsChangeToServicePrincipal should only run on AWS") + if !IsAws(t) { + Skipf(t)("TestMwsAccAwsChangeToServicePrincipal should only run on AWS") } workspaceTemplate := func(tokenBlock string) string { return ` diff --git a/internal/acceptance/permissions_test.go b/internal/acceptance/permissions_test.go index d17145e5ec..dca6a56260 100644 --- a/internal/acceptance/permissions_test.go +++ b/internal/acceptance/permissions_test.go @@ -68,7 +68,7 @@ func currentPrincipalPermission(t *testing.T, permissionLevel string) func(*make skipCreation: true, } return func(config *makePermissionsConfig) { - if isGcp(t) { + if IsGcp(t) { config.user = append(config.user, settings) } else { config.servicePrincipal = append(config.servicePrincipal, settings) @@ -77,7 +77,7 @@ func currentPrincipalPermission(t *testing.T, permissionLevel string) func(*make } func currentPrincipalType(t *testing.T) string { - if isGcp(t) { + if IsGcp(t) { return "user" } return "service_principal" @@ -583,7 +583,7 @@ func TestAccPermissions_Repo_Path(t *testing.T) { } func TestAccPermissions_Authorization_Passwords(t *testing.T) { - skipf(t)("ACLs for passwords are disabled on testing workspaces") + Skipf(t)("ACLs for passwords are disabled on testing workspaces") loadDebugEnvIfRunsFromIDE(t, "workspace") WorkspaceLevel(t, Step{ Template: makePermissionsTestStage("authorization", "\"passwords\"", groupPermissions("CAN_USE")), @@ -833,8 +833,8 @@ func TestAccPermissions_RegisteredModel_Root(t *testing.T) { func TestAccPermissions_ServingEndpoint(t *testing.T) { loadDebugEnvIfRunsFromIDE(t, "workspace") - if isGcp(t) { - skipf(t)("Serving endpoints are not supported on GCP") + if IsGcp(t) { + Skipf(t)("Serving endpoints are not supported on GCP") } endpointTemplate := ` resource "databricks_model_serving" "endpoint" { @@ -950,8 +950,8 @@ func TestAccPermissions_Query(t *testing.T) { func TestAccPermissions_App(t *testing.T) { loadDebugEnvIfRunsFromIDE(t, "workspace") - if isGcp(t) { - skipf(t)("not available on GCP") + if IsGcp(t) { + Skipf(t)("not available on GCP") } queryTemplate := ` resource "databricks_app" "this" { diff --git a/internal/acceptance/schema_test.go b/internal/acceptance/schema_test.go index e257597237..24cf5ff892 100644 --- a/internal/acceptance/schema_test.go +++ b/internal/acceptance/schema_test.go @@ -90,7 +90,7 @@ func schemaTemplateWithOwner(t *testing.T, comment string, owner string) string } func getPredictiveOptimizationSetting(t *testing.T, enabled bool) string { - if isGcp(t) { + if IsGcp(t) { return "" } value := "ENABLE" @@ -101,7 +101,7 @@ func getPredictiveOptimizationSetting(t *testing.T, enabled bool) string { } func TestUcAccSchemaUpdate(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) UnityWorkspaceLevel(t, Step{ Template: catalogTemplate + schemaTemplateWithOwner(t, "this database is managed by terraform", "account users"), }, Step{ diff --git a/internal/acceptance/service_principal_test.go b/internal/acceptance/service_principal_test.go index d1b75198e8..6bf750a838 100644 --- a/internal/acceptance/service_principal_test.go +++ b/internal/acceptance/service_principal_test.go @@ -22,9 +22,9 @@ const awsSpn = `resource "databricks_service_principal" "this" { }` func TestAccServicePrincipalHomeDeleteSuccess(t *testing.T) { - loadWorkspaceEnv(t) - if !isAzure(t) { - skipf(t)("Test only valid for Azure") + LoadWorkspaceEnv(t) + if !IsAzure(t) { + Skipf(t)("Test only valid for Azure") } uuid := createUuid() template := ` @@ -58,9 +58,9 @@ func TestAccServicePrincipalHomeDeleteSuccess(t *testing.T) { } func TestAccServicePrinicpalHomeDeleteNotDeleted(t *testing.T) { - loadWorkspaceEnv(t) - if !isAzure(t) { - skipf(t)("Test only valid for Azure") + LoadWorkspaceEnv(t) + if !IsAzure(t) { + Skipf(t)("Test only valid for Azure") } uuid := createUuid() template := ` diff --git a/internal/acceptance/sql_global_config_test.go b/internal/acceptance/sql_global_config_test.go index 03c67e356e..61d0b0b2f7 100644 --- a/internal/acceptance/sql_global_config_test.go +++ b/internal/acceptance/sql_global_config_test.go @@ -37,7 +37,7 @@ resource "databricks_sql_global_config" "this" { } func TestAccSQLGlobalConfig(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) WorkspaceLevel(t, Step{ PreConfig: func() { ctx := context.Background() @@ -49,9 +49,9 @@ func TestAccSQLGlobalConfig(t *testing.T) { } func TestAccSQLGlobalConfigServerless(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { - skipf(t)("GCP does not support serverless compute") + LoadWorkspaceEnv(t) + if IsGcp(t) { + Skipf(t)("GCP does not support serverless compute") } checkServerlessEnabled := func(enabled bool) func(state *terraform.State) error { diff --git a/internal/acceptance/sql_permissions_test.go b/internal/acceptance/sql_permissions_test.go index 23aa37a51f..3f3e924653 100644 --- a/internal/acceptance/sql_permissions_test.go +++ b/internal/acceptance/sql_permissions_test.go @@ -12,7 +12,7 @@ import ( ) func TestAccTableACL(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) tableName := qa.RandomName("table_acl_") clusterId := GetEnvOrSkipTest(t, "TEST_TABLE_ACL_CLUSTER_ID") ctx := context.Background() diff --git a/internal/acceptance/sql_table_test.go b/internal/acceptance/sql_table_test.go index 6ba5a83714..1c7412a57c 100644 --- a/internal/acceptance/sql_table_test.go +++ b/internal/acceptance/sql_table_test.go @@ -12,7 +12,7 @@ import ( func TestUcAccResourceSqlTable_Managed(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -74,7 +74,7 @@ func TestUcAccResourceSqlTable_Managed(t *testing.T) { func TestUcAccResourceSqlTableWithIdentityColumn_Managed(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -175,7 +175,7 @@ func TestUcAccResourceSqlTable_External(t *testing.T) { func TestUcAccResourceSqlTable_View(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -226,7 +226,7 @@ func TestUcAccResourceSqlTable_View(t *testing.T) { func TestUcAccResourceSqlTable_WarehousePartition(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -277,7 +277,7 @@ func TestUcAccResourceSqlTable_WarehousePartition(t *testing.T) { } func TestUcAccResourceSqlTable_Liquid(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -381,7 +381,7 @@ var inlineAndMembershipChangeErrorRegex = regexp.MustCompile(inlineAndMembership func TestUcAccResourceSqlTable_RenameColumn(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -406,7 +406,7 @@ func constructManagedSqlTableTemplateWithColumnTypeUpdates(tableName string, col func TestUcAccResourceSqlTable_ColumnTypeSuppressDiff(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() columnName := RandomName() @@ -448,7 +448,7 @@ func TestUcAccResourceSqlTable_ColumnTypeSuppressDiff(t *testing.T) { func TestUcAccResourceSqlTable_AddColumnComment(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -460,7 +460,7 @@ func TestUcAccResourceSqlTable_AddColumnComment(t *testing.T) { func TestUcAccResourceSqlTable_DropColumnNullable(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -472,7 +472,7 @@ func TestUcAccResourceSqlTable_DropColumnNullable(t *testing.T) { func TestUcAccResourceSqlTable_MultipleColumnUpdates(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -484,7 +484,7 @@ func TestUcAccResourceSqlTable_MultipleColumnUpdates(t *testing.T) { func TestUcAccResourceSqlTable_ChangeColumnTypeThrows(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() @@ -498,7 +498,7 @@ func TestUcAccResourceSqlTable_ChangeColumnTypeThrows(t *testing.T) { func TestUcAccResourceSqlTable_DropColumn(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -513,7 +513,7 @@ func TestUcAccResourceSqlTable_DropColumn(t *testing.T) { func TestUcAccResourceSqlTable_DropMultipleColumns(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -529,7 +529,7 @@ func TestUcAccResourceSqlTable_DropMultipleColumns(t *testing.T) { func TestUcAccResourceSqlTable_AddColumn(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -544,7 +544,7 @@ func TestUcAccResourceSqlTable_AddColumn(t *testing.T) { func TestUcAccResourceSqlTable_AddMultipleColumns(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -560,7 +560,7 @@ func TestUcAccResourceSqlTable_AddMultipleColumns(t *testing.T) { func TestUcAccResourceSqlTable_AddColumnAndUpdateThrows(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() @@ -577,7 +577,7 @@ func TestUcAccResourceSqlTable_AddColumnAndUpdateThrows(t *testing.T) { func TestUcAccResourceSqlTable_DropColumnAndUpdateThrows(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() diff --git a/internal/acceptance/storage_credential_test.go b/internal/acceptance/storage_credential_test.go index c78598f729..bdc10e8324 100644 --- a/internal/acceptance/storage_credential_test.go +++ b/internal/acceptance/storage_credential_test.go @@ -5,8 +5,8 @@ import ( ) func TestUcAccStorageCredential(t *testing.T) { - loadUcwsEnv(t) - if isAws(t) { + LoadUcwsEnv(t) + if IsAws(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_storage_credential" "external" { @@ -28,7 +28,7 @@ func TestUcAccStorageCredential(t *testing.T) { comment = "Managed by TF" }`, }) - } else if isGcp(t) { + } else if IsGcp(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_storage_credential" "external" { diff --git a/internal/acceptance/vector_search_test.go b/internal/acceptance/vector_search_test.go index 890f36ca34..1b09302a94 100644 --- a/internal/acceptance/vector_search_test.go +++ b/internal/acceptance/vector_search_test.go @@ -8,9 +8,9 @@ import ( ) func TestUcAccVectorSearchEndpoint(t *testing.T) { - loadUcwsEnv(t) - if isGcp(t) { - skipf(t)("not available on GCP") + LoadUcwsEnv(t) + if IsGcp(t) { + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-vector-search-%[1]s", diff --git a/internal/acceptance/workspace_conf_test.go b/internal/acceptance/workspace_conf_test.go index 80f12bfe89..2284ff5382 100644 --- a/internal/acceptance/workspace_conf_test.go +++ b/internal/acceptance/workspace_conf_test.go @@ -82,7 +82,7 @@ func TestAccWorkspaceConfFullLifecycle(t *testing.T) { } func TestAccWorkspaceConf_GetValidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) conf, err := workspace.SafeGetStatus(ctx, w, []string{"enableIpAccessLists"}) @@ -91,7 +91,7 @@ func TestAccWorkspaceConf_GetValidKey(t *testing.T) { } func TestAccWorkspaceConf_GetInvalidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) conf, err := workspace.SafeGetStatus(ctx, w, []string{"invalidKey", "enableIpAccessLists"}) @@ -100,7 +100,7 @@ func TestAccWorkspaceConf_GetInvalidKey(t *testing.T) { } func TestAccWorkspaceConf_GetOnlyInvalidKeys(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) _, err := workspace.SafeGetStatus(ctx, w, []string{"invalidKey"}) @@ -108,7 +108,7 @@ func TestAccWorkspaceConf_GetOnlyInvalidKeys(t *testing.T) { } func TestAccWorkspaceConf_SetInvalidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) err := workspace.SafeSetStatus(ctx, w, map[string]struct{}{}, map[string]string{ @@ -118,7 +118,7 @@ func TestAccWorkspaceConf_SetInvalidKey(t *testing.T) { } func TestAccWorkspaceConf_DeleteInvalidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) err := workspace.SafeSetStatus(ctx, w, map[string]struct{}{"invalidKey": {}}, map[string]string{ diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 27eb02d915..94cb3a4fcc 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -23,7 +23,6 @@ const tfSdkToGoSdkFieldConversionFailureMessage = "tfsdk to gosdk field conversi // types.Bool -> bool // types.Int64 -> int64 // types.Float64 -> float64 -// types.String -> string // // NOTE: // @@ -166,17 +165,17 @@ func tfsdkToGoSdkStructField(srcField reflect.Value, destField reflect.Value, sr switch v := srcFieldValue.(type) { case types.Bool: destField.SetBool(v.ValueBool()) - if !v.IsNull() { + if !v.IsNull() && !v.IsUnknown() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } case types.Int64: destField.SetInt(v.ValueInt64()) - if !v.IsNull() { + if !v.IsNull() && !v.IsUnknown() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } case types.Float64: destField.SetFloat(v.ValueFloat64()) - if !v.IsNull() { + if !v.IsNull() && !v.IsUnknown() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } case types.String: @@ -209,7 +208,7 @@ func tfsdkToGoSdkStructField(srcField reflect.Value, destField reflect.Value, sr destField.Set(destVal.Elem()) } else { destField.SetString(v.ValueString()) - if !v.IsNull() { + if !v.IsNull() && !v.IsUnknown() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } } diff --git a/internal/providers/pluginfw/pluginfw_rollout_utils.go b/internal/providers/pluginfw/pluginfw_rollout_utils.go index 2a83954e39..da5110a636 100644 --- a/internal/providers/pluginfw/pluginfw_rollout_utils.go +++ b/internal/providers/pluginfw/pluginfw_rollout_utils.go @@ -12,6 +12,7 @@ import ( "slices" "strings" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/products/app" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/products/catalog" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/products/cluster" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/products/library" @@ -38,8 +39,8 @@ var migratedDataSources = []func() datasource.DataSource{ // List of resources that have been onboarded to the plugin framework - not migrated from sdkv2. var pluginFwOnlyResources = []func() resource.Resource{ - // TODO Add resources here - sharing.ResourceShare, // Using the staging name (with pluginframework suffix) + sharing.ResourceShare, + app.ResourceApp, } // List of data sources that have been onboarded to the plugin framework - not migrated from sdkv2. diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go new file mode 100644 index 0000000000..96faf5a854 --- /dev/null +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -0,0 +1,132 @@ +package app_test + +import ( + "fmt" + "regexp" + "testing" + + "github.com/databricks/terraform-provider-databricks/internal/acceptance" +) + +const baseResources = ` + resource "databricks_sql_endpoint" "this" { + name = "tf-{var.STICKY_RANDOM}" + cluster_size = "2X-Small" + max_num_clusters = 1 + + tags { + custom_tags { + key = "Owner" + value = "eng-dev-ecosystem-team_at_databricks.com" + } + } + } + + resource "databricks_job" "this" { + name = "tf-{var.STICKY_RANDOM}" + } + + resource "databricks_secret_scope" "this" { + name = "tf-{var.STICKY_RANDOM}" + } + + resource "databricks_secret" "this" { + scope = databricks_secret_scope.this.name + key = "tf-{var.STICKY_RANDOM}" + string_value = "secret" + } + + resource "databricks_model_serving" "this" { + name = "tf-{var.STICKY_RANDOM}" + config { + served_models { + name = "prod_model" + model_name = "experiment-fixture-model" + model_version = "1" + workload_size = "Small" + scale_to_zero_enabled = true + } + } + } +` + +func makeTemplate(description string) string { + appTemplate := baseResources + ` + resource "databricks_app" "this" { + name = "{var.STICKY_RANDOM}" + description = "%s" + resources { + name = "warehouse" + description = "warehouse for app" + job { + id = databricks_job.this.id + permission = "CAN_MANAGE" + } + } + resources { + name = "secret" + description = "secret for app" + secret { + scope = databricks_secret_scope.this.name + key = databricks_secret.this.key + permission = "MANAGE" + } + } + resources { + name = "serving endpoint" + description = "serving endpoint for app" + serving_endpoint { + name = databricks_model_serving.this.name + permission = "CAN_MANAGE" + } + } + resources { + name = "sql warehouse" + description = "sql warehouse for app" + sql_warehouse { + id = databricks_sql_endpoint.this.id + permission = "CAN_MANAGE" + } + } + }` + return fmt.Sprintf(appTemplate, description) +} + +var templateWithInvalidResource = ` + resource "databricks_app" "this" { + name = "{var.STICKY_RANDOM}" + description = "My app" + resources { + name = "invalid resource" + description = "invalid resource for app" + job { + id = "123" + permission = "CAN_MANAGE" + } + sql_warehouse { + id = "123" + permission = "CAN_MANAGE" + } + } + }` + +func TestAccAppInvalidResource(t *testing.T) { + acceptance.WorkspaceLevel(t, acceptance.Step{ + Template: templateWithInvalidResource, + ExpectError: regexp.MustCompile(regexp.QuoteMeta(`2 attributes specified when one (and only one) of +[resources[0].secret.<.job,resources[0].secret.<.serving_endpoint,resources[0].secret.<.sql_warehouse] +is required`)), + }) +} + +func TestAccApp(t *testing.T) { + acceptance.LoadWorkspaceEnv(t) + if acceptance.IsGcp(t) { + acceptance.Skipf(t)("not available on GCP") + } + acceptance.WorkspaceLevel(t, acceptance.Step{ + Template: makeTemplate("My app"), + }, acceptance.Step{ + Template: makeTemplate("My new app"), + }) +} diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go new file mode 100644 index 0000000000..210134d773 --- /dev/null +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -0,0 +1,283 @@ +package app + +import ( + "context" + "time" + + "github.com/databricks/databricks-sdk-go/apierr" + "github.com/databricks/databricks-sdk-go/service/apps" + "github.com/databricks/terraform-provider-databricks/common" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" + pluginfwcontext "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/context" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" + "github.com/databricks/terraform-provider-databricks/internal/service/apps_tf" + "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" + "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" + "github.com/hashicorp/terraform-plugin-framework/path" + "github.com/hashicorp/terraform-plugin-framework/resource" + "github.com/hashicorp/terraform-plugin-framework/resource/schema/listplanmodifier" + "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" + "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" + "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" +) + +const ( + resourceName = "app" + defaultAppProvisionTimeout = 10 * time.Minute + deleteCallTimeout = 10 * time.Second +) + +func ResourceApp() resource.Resource { + return &resourceApp{} +} + +type resourceApp struct { + client *common.DatabricksClient +} + +func (a resourceApp) Metadata(ctx context.Context, req resource.MetadataRequest, resp *resource.MetadataResponse) { + resp.TypeName = pluginfwcommon.GetDatabricksProductionName(resourceName) +} + +type makeListBlockUnknownIfNotInState struct{} + +func (m makeListBlockUnknownIfNotInState) Description(_ context.Context) string { + return "Make the field unknown if not in state" +} + +func (m makeListBlockUnknownIfNotInState) MarkdownDescription(_ context.Context) string { + return "Make the field unknown if not in state" +} + +func (m makeListBlockUnknownIfNotInState) PlanModifyList(ctx context.Context, req planmodifier.ListRequest, resp *planmodifier.ListResponse) { + if req.StateValue.IsNull() { + elem := types.ObjectUnknown(req.PlanValue.ElementType(ctx).(basetypes.ObjectType).AttrTypes) + var d diag.Diagnostics + resp.PlanValue, d = types.ListValue(req.PlanValue.ElementType(ctx), []attr.Value{elem}) + resp.Diagnostics.Append(d...) + return + } + listplanmodifier.UseStateForUnknown().PlanModifyList(ctx, req, resp) +} + +func (a resourceApp) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { + resp.Schema = tfschema.ResourceStructToSchema(apps_tf.App{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { + cs.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") + // Computed fields + for _, p := range []string{ + "active_deployment", + "app_status", + "compute_status", + "create_time", + "creator", + "default_source_code_path", + "pending_deployment", + "service_principal_client_id", + "service_principal_id", + "service_principal_name", + "update_time", + "updater", + "url", + } { + cs.SetReadOnly(p) + } + // All pointers are treated as list blocks to be compatible with resources implemented in SDKv2. + // The plugin framework requires that the number of blocks in the config and plan match. This means that + // it isn't possible to have a computed list block that is not part of the config. To work around this, + // we need to treat these blocks as attributes in the schema, which allows us to set them as computed. + for _, p := range []string{"app_status", "compute_status"} { + cs.Transform(func(bsb tfschema.BaseSchemaBuilder) tfschema.BaseSchemaBuilder { + switch b := bsb.(type) { + case tfschema.ListNestedBlockBuilder: + return tfschema.SingleNestedBlockBuilder{ + NestedObject: b.NestedObject, + Computed: true, + } + } + return bsb + }, p) + } + exclusiveFields := []string{"job", "secret", "serving_endpoint", "sql_warehouse"} + for _, field := range exclusiveFields { + paths := path.Expressions{} + for _, f := range exclusiveFields { + if f == field { + continue + } + paths = append(paths, path.MatchRelative().AtParent().AtName(f)) + } + cs.AddValidator(listvalidator.ExactlyOneOf(paths...), "resources", field) + } + return cs + }) +} + +func (a *resourceApp) Configure(ctx context.Context, req resource.ConfigureRequest, resp *resource.ConfigureResponse) { + if a.client == nil && req.ProviderData != nil { + a.client = pluginfwcommon.ConfigureResource(req, resp) + } +} + +func (a *resourceApp) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse) { + ctx = pluginfwcontext.SetUserAgentInResourceContext(ctx, resourceName) + w, diags := a.client.GetWorkspaceClient() + resp.Diagnostics.Append(diags...) + if resp.Diagnostics.HasError() { + return + } + + var app apps_tf.App + resp.Diagnostics.Append(req.Plan.Get(ctx, &app)...) + if resp.Diagnostics.HasError() { + return + } + var appGoSdk apps.App + resp.Diagnostics.Append(converters.TfSdkToGoSdkStruct(ctx, app, &appGoSdk)...) + if resp.Diagnostics.HasError() { + return + } + + // Create the app + waiter, err := w.Apps.Create(ctx, apps.CreateAppRequest{App: &appGoSdk}) + if err != nil { + resp.Diagnostics.AddError("failed to create app", err.Error()) + return + } + + // Store the initial version of the app in state + var newApp apps_tf.App + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, waiter.Response, &newApp)...) + if resp.Diagnostics.HasError() { + return + } + appStatus := newApp.AppStatus[0] + computeStatus := newApp.ComputeStatus[0] + newApp.AppStatus = nil + newApp.ComputeStatus = nil + resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) + resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("app_status"), appStatus)...) + resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("compute_status"), computeStatus)...) + if resp.Diagnostics.HasError() { + return + } + + // Wait for the app to be created + finalApp, err := waiter.Get() + if err != nil { + resp.Diagnostics.AddError("failed to create app", err.Error()) + return + } + + // Store the final version of the app in state + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, finalApp, &newApp)...) + if resp.Diagnostics.HasError() { + return + } + resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) + if resp.Diagnostics.HasError() { + return + } +} + +func (a *resourceApp) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse) { + ctx = pluginfwcontext.SetUserAgentInResourceContext(ctx, resourceName) + w, diags := a.client.GetWorkspaceClient() + resp.Diagnostics.Append(diags...) + if resp.Diagnostics.HasError() { + return + } + + var app apps_tf.App + resp.Diagnostics.Append(req.State.Get(ctx, &app)...) + if resp.Diagnostics.HasError() { + return + } + + appGoSdk, err := w.Apps.GetByName(ctx, app.Name.ValueString()) + if err != nil { + resp.Diagnostics.AddError("failed to get app", err.Error()) + return + } + + var newApp apps_tf.App + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, appGoSdk, &newApp)...) + if resp.Diagnostics.HasError() { + return + } + + appStatus := newApp.AppStatus[0] + computeStatus := newApp.ComputeStatus[0] + newApp.AppStatus = nil + newApp.ComputeStatus = nil + resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) + resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("app_status"), appStatus)...) + resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("compute_status"), computeStatus)...) +} + +func (a *resourceApp) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse) { + ctx = pluginfwcontext.SetUserAgentInResourceContext(ctx, resourceName) + w, diags := a.client.GetWorkspaceClient() + resp.Diagnostics.Append(diags...) + if resp.Diagnostics.HasError() { + return + } + + var app apps_tf.App + resp.Diagnostics.Append(req.Plan.Get(ctx, &app)...) + if resp.Diagnostics.HasError() { + return + } + + // Update the app + var appGoSdk apps.App + resp.Diagnostics.Append(converters.TfSdkToGoSdkStruct(ctx, app, &appGoSdk)...) + if resp.Diagnostics.HasError() { + return + } + _, err := w.Apps.Update(ctx, apps.UpdateAppRequest{App: &appGoSdk, Name: app.Name.ValueString()}) + if err != nil { + resp.Diagnostics.AddError("failed to update app", err.Error()) + return + } + + // Store the updated version of the app in state + var newApp apps_tf.App + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, appGoSdk, &newApp)...) + if resp.Diagnostics.HasError() { + return + } + appStatus := newApp.AppStatus[0] + computeStatus := newApp.ComputeStatus[0] + newApp.AppStatus = nil + newApp.ComputeStatus = nil + resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) + resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("app_status"), appStatus)...) + resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("compute_status"), computeStatus)...) +} + +func (a *resourceApp) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse) { + ctx = pluginfwcontext.SetUserAgentInResourceContext(ctx, resourceName) + w, diags := a.client.GetWorkspaceClient() + resp.Diagnostics.Append(diags...) + if resp.Diagnostics.HasError() { + return + } + + var app apps_tf.App + resp.Diagnostics.Append(req.State.Get(ctx, &app)...) + if resp.Diagnostics.HasError() { + return + } + + // Delete the app + _, err := w.Apps.DeleteByName(ctx, app.Name.ValueString()) + if err != nil && !apierr.IsMissing(err) { + resp.Diagnostics.AddError("failed to delete app", err.Error()) + return + } +} + +var _ resource.ResourceWithConfigure = &resourceApp{} diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index 162e7392d5..bf90352e4d 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -16,7 +16,7 @@ type CustomizableSchema struct { // ConstructCustomizableSchema constructs a CustomizableSchema given a NestedBlockObject. func ConstructCustomizableSchema(nestedObject NestedBlockObject) *CustomizableSchema { - attr := AttributeBuilder(SingleNestedBlockBuilder{NestedObject: nestedObject}) + attr := AttributeBuilder(SingleNestedBlockBuilder{NestedObject: &nestedObject}) return &CustomizableSchema{attr: attr} } @@ -61,6 +61,8 @@ func (s *CustomizableSchema) AddValidator(v any, path ...string) *CustomizableSc return a.AddValidator(v.(validator.List)) case ListNestedAttributeBuilder: return a.AddValidator(v.(validator.List)) + case ListNestedBlockBuilder: + return a.AddValidator(v.(validator.List)) case MapAttributeBuilder: return a.AddValidator(v.(validator.Map)) case MapNestedAttributeBuilder: @@ -175,6 +177,16 @@ func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { return s } +func (s *CustomizableSchema) Transform(transformer func(BaseSchemaBuilder) BaseSchemaBuilder, path ...string) *CustomizableSchema { + cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { + return transformer(attr) + } + + navigateSchemaWithCallback(&s.attr, cb, path...) + + return s +} + // navigateSchemaWithCallback navigates through schema attributes and executes callback on the target, panics if path does not exist or invalid. func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) BaseSchemaBuilder, path ...string) (BaseSchemaBuilder, error) { currentScm := s diff --git a/internal/providers/pluginfw/tfschema/list_nested_block.go b/internal/providers/pluginfw/tfschema/list_nested_block.go index 2edb9a6a22..7e55f5d695 100644 --- a/internal/providers/pluginfw/tfschema/list_nested_block.go +++ b/internal/providers/pluginfw/tfschema/list_nested_block.go @@ -10,7 +10,7 @@ import ( // ListNestedBlockBuilder represents a list of complex (non-primitive) types. // To be compatible with our sdkv2 schema, all struct types in the gosdk are represented with this type. type ListNestedBlockBuilder struct { - NestedObject NestedBlockObject + NestedObject *NestedBlockObject Optional bool Required bool Sensitive bool diff --git a/internal/providers/pluginfw/tfschema/nested_block_object.go b/internal/providers/pluginfw/tfschema/nested_block_object.go index 2f9853eb76..83ee4f1d1f 100644 --- a/internal/providers/pluginfw/tfschema/nested_block_object.go +++ b/internal/providers/pluginfw/tfschema/nested_block_object.go @@ -3,12 +3,16 @@ package tfschema import ( dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" + "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" + "github.com/hashicorp/terraform-plugin-framework/schema/validator" ) // NestedAttributteObject is the intermediate type for nested complex (non-primitive) types. type NestedBlockObject struct { - Attributes map[string]AttributeBuilder - Blocks map[string]BlockBuilder + Attributes map[string]AttributeBuilder + Blocks map[string]BlockBuilder + Validators []validator.Object + PlanModifiers []planmodifier.Object } func (a NestedBlockObject) BuildDataSourceAttribute() dataschema.NestedBlockObject { @@ -18,6 +22,7 @@ func (a NestedBlockObject) BuildDataSourceAttribute() dataschema.NestedBlockObje return dataschema.NestedBlockObject{ Attributes: dataSourceAttributes, Blocks: dataSourceBlocks, + Validators: a.Validators, } } @@ -26,7 +31,17 @@ func (a NestedBlockObject) BuildResourceAttribute() schema.NestedBlockObject { resourceBlocks := BuildResourceBlockMap(a.Blocks) return schema.NestedBlockObject{ - Attributes: resourceAttributes, - Blocks: resourceBlocks, + Attributes: resourceAttributes, + Blocks: resourceBlocks, + Validators: a.Validators, + PlanModifiers: a.PlanModifiers, } } + +func (a *NestedBlockObject) AddValidator(v validator.Object) { + a.Validators = append(a.Validators, v) +} + +func (a *NestedBlockObject) AddPlanModifier(p planmodifier.Object) { + a.PlanModifiers = append(a.PlanModifiers, p) +} diff --git a/internal/providers/pluginfw/tfschema/single_nested_block.go b/internal/providers/pluginfw/tfschema/single_nested_block.go index aace19618b..a4d3ea88ed 100644 --- a/internal/providers/pluginfw/tfschema/single_nested_block.go +++ b/internal/providers/pluginfw/tfschema/single_nested_block.go @@ -12,7 +12,7 @@ import ( // SingleNestedBlockBuilder represents a single nested complex (non-primitive) type. type SingleNestedBlockBuilder struct { - NestedObject NestedBlockObject + NestedObject *NestedBlockObject Optional bool Required bool Sensitive bool diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 206af67fb2..45e7534d81 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -92,7 +92,7 @@ func typeToSchema(v reflect.Value) NestedBlockObject { validators = append(validators, listvalidator.SizeAtMost(1)) } scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ + NestedObject: &NestedBlockObject{ Attributes: nestedScm.Attributes, Blocks: nestedScm.Blocks, }, @@ -187,7 +187,7 @@ func typeToSchema(v reflect.Value) NestedBlockObject { sv := reflect.New(elem) nestedScm := typeToSchema(sv) scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: nestedScm, + NestedObject: &nestedScm, Optional: structTag.optional, Required: !structTag.optional, Computed: structTag.computed, diff --git a/internal/providers/sdkv2/sdkv2.go b/internal/providers/sdkv2/sdkv2.go index b91078738a..1426b411c4 100644 --- a/internal/providers/sdkv2/sdkv2.go +++ b/internal/providers/sdkv2/sdkv2.go @@ -133,7 +133,6 @@ func DatabricksProvider(sdkV2Fallbacks ...pluginfw.SdkV2FallbackOption) *schema. resourceMap := map[string]*schema.Resource{ // must be in alphabetical order "databricks_access_control_rule_set": permissions.ResourceAccessControlRuleSet().ToResource(), "databricks_alert": sql.ResourceAlert().ToResource(), - "databricks_app": apps.ResourceApp().ToResource(), "databricks_artifact_allowlist": catalog.ResourceArtifactAllowlist().ToResource(), "databricks_aws_s3_mount": storage.ResourceAWSS3Mount().ToResource(), "databricks_azure_adls_gen1_mount": storage.ResourceAzureAdlsGen1Mount().ToResource(), From 731469e0de035417a8c9fec8a9a2df0416ab23f9 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 29 Nov 2024 16:35:00 +0100 Subject: [PATCH 21/91] Remove unused configuration from blocks --- .../pluginfw/tfschema/attribute_builder.go | 19 ++++++++ .../pluginfw/tfschema/base_schema_builder.go | 5 -- .../pluginfw/tfschema/customizable_schema.go | 38 ++++++++++++--- .../pluginfw/tfschema/list_nested_block.go | 48 ------------------- .../pluginfw/tfschema/single_nested_block.go | 48 ------------------- .../pluginfw/tfschema/struct_to_schema.go | 6 --- 6 files changed, 50 insertions(+), 114 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/attribute_builder.go b/internal/providers/pluginfw/tfschema/attribute_builder.go index f467c74d0f..f2f496e460 100644 --- a/internal/providers/pluginfw/tfschema/attribute_builder.go +++ b/internal/providers/pluginfw/tfschema/attribute_builder.go @@ -10,6 +10,25 @@ import ( // This common interface prevents us from keeping two copies of StructToSchema and CustomizableSchema. type AttributeBuilder interface { BaseSchemaBuilder + + // SetOptional sets the attribute as optional in the schema. This does not affect whether the attribute is computed. + // It fails if the attribute is already optional. + SetOptional() BaseSchemaBuilder + + // SetRequired sets the attribute as required in the schema. This does not affect whether the attribute is computed. + // It fails if the attribute is already required. + SetRequired() BaseSchemaBuilder + + // SetSensitive sets the attribute as sensitive in the schema. It fails if the attribute is already sensitive. + SetSensitive() BaseSchemaBuilder + + // SetComputed sets the attribute as computed in the schema. It fails if the attribute is already computed. + SetComputed() BaseSchemaBuilder + + // Sets the attribute as read-only in the schema, i.e. computed and neither optional or required. It fails if the + // attribute is already read-only. + SetReadOnly() BaseSchemaBuilder + BuildDataSourceAttribute() dataschema.Attribute BuildResourceAttribute() schema.Attribute } diff --git a/internal/providers/pluginfw/tfschema/base_schema_builder.go b/internal/providers/pluginfw/tfschema/base_schema_builder.go index 8bdd471e63..70851d6edc 100644 --- a/internal/providers/pluginfw/tfschema/base_schema_builder.go +++ b/internal/providers/pluginfw/tfschema/base_schema_builder.go @@ -3,10 +3,5 @@ package tfschema // BaseSchemaBuilder is the common interface for all blocks and attributes, it can be used to build data source and resource. // Both AttributeBuilder and BlockBuilder extend this interface. type BaseSchemaBuilder interface { - SetOptional() BaseSchemaBuilder - SetRequired() BaseSchemaBuilder - SetSensitive() BaseSchemaBuilder - SetComputed() BaseSchemaBuilder - SetReadOnly() BaseSchemaBuilder SetDeprecated(string) BaseSchemaBuilder } diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index 162e7392d5..be297a28bb 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -16,8 +16,7 @@ type CustomizableSchema struct { // ConstructCustomizableSchema constructs a CustomizableSchema given a NestedBlockObject. func ConstructCustomizableSchema(nestedObject NestedBlockObject) *CustomizableSchema { - attr := AttributeBuilder(SingleNestedBlockBuilder{NestedObject: nestedObject}) - return &CustomizableSchema{attr: attr} + return &CustomizableSchema{attr: SingleNestedBlockBuilder{NestedObject: nestedObject}} } // ToAttributeMap converts CustomizableSchema into BaseSchemaBuilder. @@ -116,7 +115,12 @@ func (s *CustomizableSchema) AddPlanModifier(v any, path ...string) *Customizabl func (s *CustomizableSchema) SetOptional(path ...string) *CustomizableSchema { cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { - return attr.SetOptional() + switch a := attr.(type) { + case AttributeBuilder: + return a.SetOptional() + default: + panic(fmt.Errorf("SetOptional called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) + } } navigateSchemaWithCallback(&s.attr, cb, path...) @@ -126,7 +130,12 @@ func (s *CustomizableSchema) SetOptional(path ...string) *CustomizableSchema { func (s *CustomizableSchema) SetRequired(path ...string) *CustomizableSchema { cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { - return attr.SetRequired() + switch a := attr.(type) { + case AttributeBuilder: + return a.SetRequired() + default: + panic(fmt.Errorf("SetRequired called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) + } } navigateSchemaWithCallback(&s.attr, cb, path...) @@ -136,7 +145,12 @@ func (s *CustomizableSchema) SetRequired(path ...string) *CustomizableSchema { func (s *CustomizableSchema) SetSensitive(path ...string) *CustomizableSchema { cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { - return attr.SetSensitive() + switch a := attr.(type) { + case AttributeBuilder: + return a.SetSensitive() + default: + panic(fmt.Errorf("SetSensitive called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) + } } navigateSchemaWithCallback(&s.attr, cb, path...) @@ -155,7 +169,12 @@ func (s *CustomizableSchema) SetDeprecated(msg string, path ...string) *Customiz func (s *CustomizableSchema) SetComputed(path ...string) *CustomizableSchema { cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { - return attr.SetComputed() + switch a := attr.(type) { + case AttributeBuilder: + return a.SetComputed() + default: + panic(fmt.Errorf("SetComputed called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) + } } navigateSchemaWithCallback(&s.attr, cb, path...) @@ -167,7 +186,12 @@ func (s *CustomizableSchema) SetComputed(path ...string) *CustomizableSchema { // by the platform. func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { - return attr.SetReadOnly() + switch a := attr.(type) { + case AttributeBuilder: + return a.SetReadOnly() + default: + panic(fmt.Errorf("SetReadOnly called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) + } } navigateSchemaWithCallback(&s.attr, cb, path...) diff --git a/internal/providers/pluginfw/tfschema/list_nested_block.go b/internal/providers/pluginfw/tfschema/list_nested_block.go index 2edb9a6a22..7f75bdc4c8 100644 --- a/internal/providers/pluginfw/tfschema/list_nested_block.go +++ b/internal/providers/pluginfw/tfschema/list_nested_block.go @@ -11,10 +11,6 @@ import ( // To be compatible with our sdkv2 schema, all struct types in the gosdk are represented with this type. type ListNestedBlockBuilder struct { NestedObject NestedBlockObject - Optional bool - Required bool - Sensitive bool - Computed bool DeprecationMessage string Validators []validator.List PlanModifiers []planmodifier.List @@ -37,50 +33,6 @@ func (a ListNestedBlockBuilder) BuildResourceBlock() schema.Block { } } -func (a ListNestedBlockBuilder) SetOptional() BaseSchemaBuilder { - if a.Optional && !a.Required { - panic("attribute is already optional") - } - a.Optional = true - a.Required = false - return a -} - -func (a ListNestedBlockBuilder) SetRequired() BaseSchemaBuilder { - if !a.Optional && a.Required { - panic("attribute is already required") - } - a.Optional = false - a.Required = true - return a -} - -func (a ListNestedBlockBuilder) SetSensitive() BaseSchemaBuilder { - if a.Sensitive { - panic("attribute is already sensitive") - } - a.Sensitive = true - return a -} - -func (a ListNestedBlockBuilder) SetComputed() BaseSchemaBuilder { - if a.Computed { - panic("attribute is already computed") - } - a.Computed = true - return a -} - -func (a ListNestedBlockBuilder) SetReadOnly() BaseSchemaBuilder { - if a.Computed && !a.Optional && !a.Required { - panic("attribute is already read only") - } - a.Computed = true - a.Optional = false - a.Required = false - return a -} - func (a ListNestedBlockBuilder) SetDeprecated(msg string) BaseSchemaBuilder { a.DeprecationMessage = msg return a diff --git a/internal/providers/pluginfw/tfschema/single_nested_block.go b/internal/providers/pluginfw/tfschema/single_nested_block.go index aace19618b..aac8a73eb8 100644 --- a/internal/providers/pluginfw/tfschema/single_nested_block.go +++ b/internal/providers/pluginfw/tfschema/single_nested_block.go @@ -13,10 +13,6 @@ import ( // SingleNestedBlockBuilder represents a single nested complex (non-primitive) type. type SingleNestedBlockBuilder struct { NestedObject NestedBlockObject - Optional bool - Required bool - Sensitive bool - Computed bool DeprecationMessage string Validators []validator.Object PlanModifiers []planmodifier.Object @@ -49,50 +45,6 @@ func (a SingleNestedBlockBuilder) BuildResourceBlock() schema.Block { } } -func (a SingleNestedBlockBuilder) SetOptional() BaseSchemaBuilder { - if a.Optional && !a.Required { - panic("attribute is already optional") - } - a.Optional = true - a.Required = false - return a -} - -func (a SingleNestedBlockBuilder) SetRequired() BaseSchemaBuilder { - if !a.Optional && a.Required { - panic("attribute is already required") - } - a.Optional = false - a.Required = true - return a -} - -func (a SingleNestedBlockBuilder) SetSensitive() BaseSchemaBuilder { - if a.Sensitive { - panic("attribute is already sensitive") - } - a.Sensitive = true - return a -} - -func (a SingleNestedBlockBuilder) SetComputed() BaseSchemaBuilder { - if a.Computed { - panic("attribute is already computed") - } - a.Computed = true - return a -} - -func (a SingleNestedBlockBuilder) SetReadOnly() BaseSchemaBuilder { - if a.Computed && !a.Optional && !a.Required { - panic("attribute is already read only") - } - a.Computed = true - a.Optional = false - a.Required = false - return a -} - func (a SingleNestedBlockBuilder) SetDeprecated(msg string) BaseSchemaBuilder { a.DeprecationMessage = msg return a diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 206af67fb2..b5b6e35fbc 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -96,9 +96,6 @@ func typeToSchema(v reflect.Value) NestedBlockObject { Attributes: nestedScm.Attributes, Blocks: nestedScm.Blocks, }, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, Validators: validators, } } @@ -188,9 +185,6 @@ func typeToSchema(v reflect.Value) NestedBlockObject { nestedScm := typeToSchema(sv) scmBlock[fieldName] = ListNestedBlockBuilder{ NestedObject: nestedScm, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, } } } else { From 7dd91f4b83335d22d94874f01564d9368d86a7a5 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 29 Nov 2024 16:39:19 +0100 Subject: [PATCH 22/91] add test --- .../pluginfw/tfschema/customizable_schema_test.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index ff949d9daf..9763707abb 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -130,3 +130,12 @@ func TestCustomizeSchemaObjectTypeValidatorAdded(t *testing.T) { assert.True(t, len(scm.Blocks["nested_slice_object"].(schema.ListNestedBlock).Validators) == 1) } + +func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { + assert.Panics(t, func() { + _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.SetRequired("nested") + return c + }) + }) +} \ No newline at end of file From 14fea498b626defe7eb938f3420f96afb903f7c9 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 29 Nov 2024 16:40:21 +0100 Subject: [PATCH 23/91] fix --- .../tfschema/customizable_schema_test.go | 38 ++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 9763707abb..262d041fae 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -138,4 +138,40 @@ func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { return c }) }) -} \ No newline at end of file +} + +func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { + assert.Panics(t, func() { + _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.SetOptional("nested") + return c + }) + }) +} + +func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { + assert.Panics(t, func() { + _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.SetSensitive("nested") + return c + }) + }) +} + +func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { + assert.Panics(t, func() { + _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.SetReadOnly("nested") + return c + }) + }) +} + +func TestCustomizeSchema_SetComputed_PanicOnBlock(t *testing.T) { + assert.Panics(t, func() { + _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.SetComputed("nested") + return c + }) + }) +} From 6bd77aade0942ba9a2ee38da8d6cd2c4bd9f1ed9 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 2 Dec 2024 10:00:02 +0100 Subject: [PATCH 24/91] Add ConvertToAttribute() support --- .../pluginfw/tfschema/block_builder.go | 6 + .../pluginfw/tfschema/customizable_schema.go | 66 +++++- .../tfschema/customizable_schema_test.go | 217 ++++++++++++++++++ .../pluginfw/tfschema/list_nested_block.go | 9 + .../pluginfw/tfschema/nested_block_object.go | 13 ++ .../pluginfw/tfschema/single_nested_block.go | 9 + 6 files changed, 315 insertions(+), 5 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/block_builder.go b/internal/providers/pluginfw/tfschema/block_builder.go index abf3f38cb6..33f3dae67a 100644 --- a/internal/providers/pluginfw/tfschema/block_builder.go +++ b/internal/providers/pluginfw/tfschema/block_builder.go @@ -10,6 +10,12 @@ import ( // This common interface prevents us from keeping two copies of StructToSchema and CustomizableSchema. type BlockBuilder interface { BaseSchemaBuilder + + // ToAttribute converts a block to its corresponding attribute type. Currently, ResourceStructToSchema converts all + // nested struct fields and slices to blocks. This method is used to convert those blocks to their corresponding + // attribute type. The resulting attribute will not have any of the Computed/Optional/Required/Sensitive flags set. + ToAttribute() AttributeBuilder + BuildDataSourceBlock() dataschema.Block BuildResourceBlock() schema.Block } diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index be297a28bb..08a0e4e93e 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -10,6 +10,7 @@ import ( ) // CustomizableSchema is a wrapper struct on top of BaseSchemaBuilder that can be used to navigate through nested schema add customizations. +// The methods of CustomizableSchema that modify the underlying schema should return the same CustomizableSchema object to allow chaining. type CustomizableSchema struct { attr BaseSchemaBuilder } @@ -199,8 +200,63 @@ func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { return s } +// ConvertToAttribute converts the last element of the path from a block to an attribute. +// It panics if the path is empty, if the path does not exist in the schema, or if the path +// points to an attribute, not a block. +func (s *CustomizableSchema) ConvertToAttribute(path ...string) *CustomizableSchema { + if len(path) == 0 { + panic(fmt.Errorf("ToAttribute called on root schema. %s", common.TerraformBugErrorMessage)) + } + field := path[len(path)-1] + + cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { + switch a := attr.(type) { + case ListNestedBlockBuilder: + elem, ok := a.NestedObject.Blocks[field] + if !ok { + panic(fmt.Errorf("field %s does not exist in nested block", field)) + } + if a.NestedObject.Attributes == nil { + a.NestedObject.Attributes = make(map[string]AttributeBuilder) + } + a.NestedObject.Attributes[field] = elem.ToAttribute() + delete(a.NestedObject.Blocks, field) + if len(a.NestedObject.Blocks) == 0 { + a.NestedObject.Blocks = nil + } + return a + case SingleNestedBlockBuilder: + elem, ok := a.NestedObject.Blocks[field] + if !ok { + panic(fmt.Errorf("field %s does not exist in nested block", field)) + } + if a.NestedObject.Attributes == nil { + a.NestedObject.Attributes = make(map[string]AttributeBuilder) + } + a.NestedObject.Attributes[field] = elem.ToAttribute() + delete(a.NestedObject.Blocks, field) + if len(a.NestedObject.Blocks) == 0 { + a.NestedObject.Blocks = nil + } + return a + default: + panic(fmt.Errorf("ConvertToAttribute called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) + } + } + + // We have to go only as far as the second-to-last entry, since we need to change the parent schema + // by moving the last entry from a block to an attribute. + if len(path) == 1 { + s.attr = cb(s.attr) + } else { + navigateSchemaWithCallback(&s.attr, cb, path[0:len(path)-1]...) + } + + return s +} + // navigateSchemaWithCallback navigates through schema attributes and executes callback on the target, panics if path does not exist or invalid. -func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) BaseSchemaBuilder, path ...string) (BaseSchemaBuilder, error) { +func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) BaseSchemaBuilder, path ...string) { currentScm := s for i, p := range path { m := attributeToNestedBlockObject(currentScm) @@ -211,7 +267,7 @@ func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) if i == len(path)-1 { newV := cb(v).(AttributeBuilder) mAttr[p] = newV - return mAttr[p], nil + return } castedV := v.(BaseSchemaBuilder) currentScm = &castedV @@ -219,14 +275,14 @@ func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) if i == len(path)-1 { newV := cb(v).(BlockBuilder) mBlock[p] = newV - return mBlock[p], nil + return } castedV := v.(BaseSchemaBuilder) currentScm = &castedV } else { - return nil, fmt.Errorf("missing key %s", p) + panic(fmt.Errorf("missing key %s", p)) } } - return nil, fmt.Errorf("path %v is incomplete", path) + panic(fmt.Errorf("path %v is incomplete", path)) } diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 262d041fae..fbf63f8b7e 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -6,6 +6,7 @@ import ( "testing" "github.com/hashicorp/terraform-plugin-framework/resource/schema" + "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" "github.com/hashicorp/terraform-plugin-framework/schema/validator" "github.com/hashicorp/terraform-plugin-framework/types" @@ -175,3 +176,219 @@ func TestCustomizeSchema_SetComputed_PanicOnBlock(t *testing.T) { }) }) } + +type mockPlanModifier struct{} + +// Description implements planmodifier.List. +func (m mockPlanModifier) Description(context.Context) string { + panic("unimplemented") +} + +// MarkdownDescription implements planmodifier.List. +func (m mockPlanModifier) MarkdownDescription(context.Context) string { + panic("unimplemented") +} + +// PlanModifyList implements planmodifier.List. +func (m mockPlanModifier) PlanModifyList(context.Context, planmodifier.ListRequest, *planmodifier.ListResponse) { + panic("unimplemented") +} + +// PlanModifyList implements planmodifier.List. +func (m mockPlanModifier) PlanModifyObject(context.Context, planmodifier.ObjectRequest, *planmodifier.ObjectResponse) { + panic("unimplemented") +} + +var _ planmodifier.List = mockPlanModifier{} +var _ planmodifier.Object = mockPlanModifier{} + +type mockValidator struct{} + +// Description implements validator.List. +func (m mockValidator) Description(context.Context) string { + panic("unimplemented") +} + +// MarkdownDescription implements validator.List. +func (m mockValidator) MarkdownDescription(context.Context) string { + panic("unimplemented") +} + +// ValidateList implements validator.List. +func (m mockValidator) ValidateList(context.Context, validator.ListRequest, *validator.ListResponse) { + panic("unimplemented") +} + +// ValidateList implements validator.Object. +func (m mockValidator) ValidateObject(context.Context, validator.ObjectRequest, *validator.ObjectResponse) { + panic("unimplemented") +} + +var _ validator.List = mockValidator{} +var _ validator.Object = mockValidator{} + +func TestCustomizeSchema_ToAttribute(t *testing.T) { + v := mockValidator{} + pm := mockPlanModifier{} + testCases := []struct { + name string + baseSchema NestedBlockObject + path []string + want NestedBlockObject + expectPanic bool + }{ + { + name: "ListNestedBlock", + baseSchema: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "list": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + DeprecationMessage: "deprecated", + Validators: []validator.List{v}, + PlanModifiers: []planmodifier.List{pm}, + }, + }, + }, + path: []string{"list"}, + want: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "list": ListNestedAttributeBuilder{ + NestedObject: NestedAttributeObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + DeprecationMessage: "deprecated", + Validators: []validator.List{v}, + PlanModifiers: []planmodifier.List{pm}, + }, + }, + }, + }, + { + name: "ListNestedBlock/CalledOnInnerBlock", + baseSchema: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "list": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "nested_block": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + }, + }, + }, + }, + }, + }, + path: []string{"list", "nested_block"}, + want: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "list": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "nested_block": ListNestedAttributeBuilder{ + NestedObject: NestedAttributeObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "SingleNestedBlock", + baseSchema: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "single": SingleNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + DeprecationMessage: "deprecated", + Validators: []validator.Object{v}, + PlanModifiers: []planmodifier.Object{pm}, + }, + }, + }, + path: []string{"single"}, + want: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "single": SingleNestedAttributeBuilder{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + DeprecationMessage: "deprecated", + Validators: []validator.Object{v}, + PlanModifiers: []planmodifier.Object{pm}, + }, + }, + }, + }, + { + name: "SingleNestedBlock/RecursiveBlocks", + baseSchema: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "single": SingleNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "nested_block": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + }, + }, + }, + }, + }, + }, + path: []string{"single"}, + want: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "single": SingleNestedAttributeBuilder{ + Attributes: map[string]AttributeBuilder{ + "nested_block": ListNestedAttributeBuilder{ + NestedObject: NestedAttributeObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "PanicOnEmptyPath", + path: nil, + expectPanic: true, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + if c.expectPanic { + assert.Panics(t, func() { + ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) + }) + } else { + got := ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) + assert.Equal(t, c.want, got.attr.(SingleNestedBlockBuilder).NestedObject) + } + }) + } +} diff --git a/internal/providers/pluginfw/tfschema/list_nested_block.go b/internal/providers/pluginfw/tfschema/list_nested_block.go index 7f75bdc4c8..03d9a51287 100644 --- a/internal/providers/pluginfw/tfschema/list_nested_block.go +++ b/internal/providers/pluginfw/tfschema/list_nested_block.go @@ -16,6 +16,15 @@ type ListNestedBlockBuilder struct { PlanModifiers []planmodifier.List } +func (a ListNestedBlockBuilder) ToAttribute() AttributeBuilder { + return ListNestedAttributeBuilder{ + NestedObject: a.NestedObject.ToNestedAttributeObject(), + DeprecationMessage: a.DeprecationMessage, + Validators: a.Validators, + PlanModifiers: a.PlanModifiers, + } +} + func (a ListNestedBlockBuilder) BuildDataSourceBlock() dataschema.Block { return dataschema.ListNestedBlock{ NestedObject: a.NestedObject.BuildDataSourceAttribute(), diff --git a/internal/providers/pluginfw/tfschema/nested_block_object.go b/internal/providers/pluginfw/tfschema/nested_block_object.go index 2f9853eb76..2be8935d6b 100644 --- a/internal/providers/pluginfw/tfschema/nested_block_object.go +++ b/internal/providers/pluginfw/tfschema/nested_block_object.go @@ -11,6 +11,19 @@ type NestedBlockObject struct { Blocks map[string]BlockBuilder } +func (a NestedBlockObject) ToNestedAttributeObject() NestedAttributeObject { + attributes := make(map[string]AttributeBuilder) + for k, v := range a.Attributes { + attributes[k] = v + } + for k, v := range a.Blocks { + attributes[k] = v.ToAttribute() + } + return NestedAttributeObject{ + Attributes: attributes, + } +} + func (a NestedBlockObject) BuildDataSourceAttribute() dataschema.NestedBlockObject { dataSourceAttributes := BuildDataSourceAttributeMap(a.Attributes) dataSourceBlocks := BuildDataSourceBlockMap(a.Blocks) diff --git a/internal/providers/pluginfw/tfschema/single_nested_block.go b/internal/providers/pluginfw/tfschema/single_nested_block.go index aac8a73eb8..1b88c9ae01 100644 --- a/internal/providers/pluginfw/tfschema/single_nested_block.go +++ b/internal/providers/pluginfw/tfschema/single_nested_block.go @@ -18,6 +18,15 @@ type SingleNestedBlockBuilder struct { PlanModifiers []planmodifier.Object } +func (a SingleNestedBlockBuilder) ToAttribute() AttributeBuilder { + return SingleNestedAttributeBuilder{ + Attributes: a.NestedObject.ToNestedAttributeObject().Attributes, + DeprecationMessage: a.DeprecationMessage, + Validators: a.Validators, + PlanModifiers: a.PlanModifiers, + } +} + func (a SingleNestedBlockBuilder) BuildDataSourceAttribute() dataschema.Attribute { panic(fmt.Errorf("BuildDataSourceBlock should never be called for SingleNestedBlockBuilder. %s", common.TerraformBugErrorMessage)) } From 25ae4baa4288cbaa8b0b96c975c673a6b0f45ed5 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 2 Dec 2024 10:03:16 +0100 Subject: [PATCH 25/91] small typos --- internal/providers/pluginfw/tfschema/customizable_schema.go | 2 +- .../providers/pluginfw/tfschema/customizable_schema_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index 08a0e4e93e..136482673e 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -205,7 +205,7 @@ func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { // points to an attribute, not a block. func (s *CustomizableSchema) ConvertToAttribute(path ...string) *CustomizableSchema { if len(path) == 0 { - panic(fmt.Errorf("ToAttribute called on root schema. %s", common.TerraformBugErrorMessage)) + panic(fmt.Errorf("ConvertToAttribute called on root schema. %s", common.TerraformBugErrorMessage)) } field := path[len(path)-1] diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index fbf63f8b7e..512e3d93a1 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -227,7 +227,7 @@ func (m mockValidator) ValidateObject(context.Context, validator.ObjectRequest, var _ validator.List = mockValidator{} var _ validator.Object = mockValidator{} -func TestCustomizeSchema_ToAttribute(t *testing.T) { +func TestCustomizeSchema_ConvertToAttribute(t *testing.T) { v := mockValidator{} pm := mockPlanModifier{} testCases := []struct { From 1628cb8deea243fb41a1ebea3704e300697d132d Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Tue, 3 Dec 2024 14:02:26 +0100 Subject: [PATCH 26/91] work --- .../providers/pluginfw/converters/tf_to_go.go | 6 +- .../pluginfw/products/app/app_acc_test.go | 65 +++++++------ .../pluginfw/products/app/resource_app.go | 65 +++---------- .../products/sharing/resource_share.go | 4 +- .../tfschema/list_nested_attribute.go | 1 + .../tfschema/nested_attribute_object.go | 6 ++ .../validators/exactly_one_attribute.go | 97 +++++++++++++++++++ internal/service/apps_tf/model.go | 49 +++++++++- 8 files changed, 203 insertions(+), 90 deletions(-) create mode 100644 internal/providers/pluginfw/validators/exactly_one_attribute.go diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 94cb3a4fcc..0c3d3f85c6 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -165,17 +165,17 @@ func tfsdkToGoSdkStructField(srcField reflect.Value, destField reflect.Value, sr switch v := srcFieldValue.(type) { case types.Bool: destField.SetBool(v.ValueBool()) - if !v.IsNull() && !v.IsUnknown() { + if !v.IsNull() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } case types.Int64: destField.SetInt(v.ValueInt64()) - if !v.IsNull() && !v.IsUnknown() { + if !v.IsNull() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } case types.Float64: destField.SetFloat(v.ValueFloat64()) - if !v.IsNull() && !v.IsUnknown() { + if !v.IsNull() { addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) } case types.String: diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index 96faf5a854..1488f81619 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -8,7 +8,7 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/acceptance" ) -const baseResources = ` +/* resource "databricks_sql_endpoint" "this" { name = "tf-{var.STICKY_RANDOM}" cluster_size = "2X-Small" @@ -26,16 +26,6 @@ const baseResources = ` name = "tf-{var.STICKY_RANDOM}" } - resource "databricks_secret_scope" "this" { - name = "tf-{var.STICKY_RANDOM}" - } - - resource "databricks_secret" "this" { - scope = databricks_secret_scope.this.name - key = "tf-{var.STICKY_RANDOM}" - string_value = "secret" - } - resource "databricks_model_serving" "this" { name = "tf-{var.STICKY_RANDOM}" config { @@ -48,13 +38,23 @@ const baseResources = ` } } } +*/ +const baseResources = ` + + resource "databricks_secret_scope" "this" { + name = "tf-{var.STICKY_RANDOM}" + } + + resource "databricks_secret" "this" { + scope = databricks_secret_scope.this.name + key = "tf-{var.STICKY_RANDOM}" + string_value = "secret" + } + ` -func makeTemplate(description string) string { - appTemplate := baseResources + ` - resource "databricks_app" "this" { - name = "{var.STICKY_RANDOM}" - description = "%s" +/* + resources { name = "warehouse" description = "warehouse for app" @@ -63,15 +63,6 @@ func makeTemplate(description string) string { permission = "CAN_MANAGE" } } - resources { - name = "secret" - description = "secret for app" - secret { - scope = databricks_secret_scope.this.name - key = databricks_secret.this.key - permission = "MANAGE" - } - } resources { name = "serving endpoint" description = "serving endpoint for app" @@ -88,6 +79,21 @@ func makeTemplate(description string) string { permission = "CAN_MANAGE" } } +*/ +func makeTemplate(description string) string { + appTemplate := baseResources + ` + resource "databricks_app" "this" { + name = "{var.STICKY_RANDOM}" + description = "%s" + resources { + name = "secret" + description = "secret for app" + secret { + scope = databricks_secret_scope.this.name + key = databricks_secret.this.key + permission = "MANAGE" + } + } }` return fmt.Sprintf(appTemplate, description) } @@ -99,9 +105,10 @@ var templateWithInvalidResource = ` resources { name = "invalid resource" description = "invalid resource for app" - job { - id = "123" + secret { permission = "CAN_MANAGE" + key = "test" + scope = "test" } sql_warehouse { id = "123" @@ -110,11 +117,11 @@ var templateWithInvalidResource = ` } }` -func TestAccAppInvalidResource(t *testing.T) { +func TestAccApp_InvalidResource(t *testing.T) { acceptance.WorkspaceLevel(t, acceptance.Step{ Template: templateWithInvalidResource, ExpectError: regexp.MustCompile(regexp.QuoteMeta(`2 attributes specified when one (and only one) of -[resources[0].secret.<.job,resources[0].secret.<.serving_endpoint,resources[0].secret.<.sql_warehouse] +[resources[0].job.<.secret,resources[0].job.<.serving_endpoint,resources[0].job.<.sql_warehouse] is required`)), }) } diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 210134d773..267422cb82 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -12,16 +12,10 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/apps_tf" - "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" - "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" + "github.com/hashicorp/terraform-plugin-framework-validators/objectvalidator" "github.com/hashicorp/terraform-plugin-framework/path" "github.com/hashicorp/terraform-plugin-framework/resource" - "github.com/hashicorp/terraform-plugin-framework/resource/schema/listplanmodifier" - "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" - "github.com/hashicorp/terraform-plugin-framework/types" - "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) const ( @@ -42,30 +36,16 @@ func (a resourceApp) Metadata(ctx context.Context, req resource.MetadataRequest, resp.TypeName = pluginfwcommon.GetDatabricksProductionName(resourceName) } -type makeListBlockUnknownIfNotInState struct{} - -func (m makeListBlockUnknownIfNotInState) Description(_ context.Context) string { - return "Make the field unknown if not in state" -} - -func (m makeListBlockUnknownIfNotInState) MarkdownDescription(_ context.Context) string { - return "Make the field unknown if not in state" -} - -func (m makeListBlockUnknownIfNotInState) PlanModifyList(ctx context.Context, req planmodifier.ListRequest, resp *planmodifier.ListResponse) { - if req.StateValue.IsNull() { - elem := types.ObjectUnknown(req.PlanValue.ElementType(ctx).(basetypes.ObjectType).AttrTypes) - var d diag.Diagnostics - resp.PlanValue, d = types.ListValue(req.PlanValue.ElementType(ctx), []attr.Value{elem}) - resp.Diagnostics.Append(d...) - return - } - listplanmodifier.UseStateForUnknown().PlanModifyList(ctx, req, resp) -} - func (a resourceApp) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { resp.Schema = tfschema.ResourceStructToSchema(apps_tf.App{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { cs.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") + // All pointers are treated as list blocks to be compatible with resources implemented in SDKv2. + // The plugin framework requires that the number of blocks in the config and plan match. This means that + // it isn't possible to have a computed list block that is not part of the config. To work around this, + // we need to treat these blocks as attributes in the schema, which allows us to set them as computed. + for _, p := range []string{"active_deployment", "app_status", "compute_status", "pending_deployment"} { + cs.ConvertToAttribute(p) + } // Computed fields for _, p := range []string{ "active_deployment", @@ -84,33 +64,12 @@ func (a resourceApp) Schema(ctx context.Context, req resource.SchemaRequest, res } { cs.SetReadOnly(p) } - // All pointers are treated as list blocks to be compatible with resources implemented in SDKv2. - // The plugin framework requires that the number of blocks in the config and plan match. This means that - // it isn't possible to have a computed list block that is not part of the config. To work around this, - // we need to treat these blocks as attributes in the schema, which allows us to set them as computed. - for _, p := range []string{"app_status", "compute_status"} { - cs.Transform(func(bsb tfschema.BaseSchemaBuilder) tfschema.BaseSchemaBuilder { - switch b := bsb.(type) { - case tfschema.ListNestedBlockBuilder: - return tfschema.SingleNestedBlockBuilder{ - NestedObject: b.NestedObject, - Computed: true, - } - } - return bsb - }, p) - } exclusiveFields := []string{"job", "secret", "serving_endpoint", "sql_warehouse"} - for _, field := range exclusiveFields { - paths := path.Expressions{} - for _, f := range exclusiveFields { - if f == field { - continue - } - paths = append(paths, path.MatchRelative().AtParent().AtName(f)) - } - cs.AddValidator(listvalidator.ExactlyOneOf(paths...), "resources", field) + paths := path.Expressions{} + for _, field := range exclusiveFields[1:] { + paths = append(paths, path.MatchRelative().AtParent().AtName(field)) } + cs.AddValidator(objectvalidator.ExactlyOneOf(paths...), "resources", exclusiveFields[0]) return cs }) } diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index e86847e0c9..29ac9ab2e0 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -145,8 +145,8 @@ func (r *ShareResource) Schema(ctx context.Context, req resource.SchemaRequest, c.AddPlanModifier(stringplanmodifier.UseStateForUnknown(), "created_by") c.SetRequired("object", "data_object_type") - c.SetRequired("object", "partitions", "values", "op") - c.SetRequired("object", "partitions", "values", "name") + c.SetRequired("object", "partition", "value", "op") + c.SetRequired("object", "partition", "value", "name") return c }) resp.Schema = schema.Schema{ diff --git a/internal/providers/pluginfw/tfschema/list_nested_attribute.go b/internal/providers/pluginfw/tfschema/list_nested_attribute.go index 9cd882990c..adc97a7ed8 100644 --- a/internal/providers/pluginfw/tfschema/list_nested_attribute.go +++ b/internal/providers/pluginfw/tfschema/list_nested_attribute.go @@ -85,6 +85,7 @@ func (a ListNestedAttributeBuilder) SetReadOnly() AttributeBuilder { a.Computed = true a.Optional = false a.Required = false + a.NestedObject.SetReadOnly() return a } diff --git a/internal/providers/pluginfw/tfschema/nested_attribute_object.go b/internal/providers/pluginfw/tfschema/nested_attribute_object.go index bf9f639231..f12702f7b9 100644 --- a/internal/providers/pluginfw/tfschema/nested_attribute_object.go +++ b/internal/providers/pluginfw/tfschema/nested_attribute_object.go @@ -25,3 +25,9 @@ func (a NestedAttributeObject) BuildResourceAttribute() schema.NestedAttributeOb Attributes: resourceAttributes, } } + +func (a NestedAttributeObject) SetReadOnly() { + for attr, attrV := range a.Attributes { + a.Attributes[attr] = attrV.SetReadOnly() + } +} diff --git a/internal/providers/pluginfw/validators/exactly_one_attribute.go b/internal/providers/pluginfw/validators/exactly_one_attribute.go new file mode 100644 index 0000000000..138e00b7c1 --- /dev/null +++ b/internal/providers/pluginfw/validators/exactly_one_attribute.go @@ -0,0 +1,97 @@ +package validators + +import ( + "context" + "fmt" + + "github.com/hashicorp/terraform-plugin-framework-validators/helpers/validatordiag" + "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/path" + "github.com/hashicorp/terraform-plugin-framework/schema/validator" +) + +// Identical to objectvalidators.ExactlyOneOf() except that it doesn't count the current attribute. +// Great for migrating ExactlyOneOf and defining it on the containing schema. +type ExactlyOneAttributeValidator struct { + paths path.Expressions +} + +func ExactlyOneOf(expressions ...path.Expression) validator.Object { + return ExactlyOneAttributeValidator{ + paths: expressions, + } +} + +// Description implements validator.Object. +func (e ExactlyOneAttributeValidator) Description(ctx context.Context) string { + return e.MarkdownDescription(ctx) +} + +// MarkdownDescription implements validator.Object. +func (e ExactlyOneAttributeValidator) MarkdownDescription(context.Context) string { + return fmt.Sprintf("Requires exactly one of the following attributes on the specified object to be set: " + e.paths.String()) +} + +// ValidateObject implements validator.Object. +func (e ExactlyOneAttributeValidator) ValidateObject(ctx context.Context, req validator.ObjectRequest, res *validator.ObjectResponse) { + count := 0 + expressions := req.PathExpression.MergeExpressions(e.paths...) + + // If current attribute is unknown, delay validation + if req.ConfigValue.IsUnknown() { + return + } + + for _, expression := range expressions { + matchedPaths, diags := req.Config.PathMatches(ctx, expression) + + res.Diagnostics.Append(diags...) + + // Collect all errors + if diags.HasError() { + continue + } + + for _, mp := range matchedPaths { + // If the user specifies the same attribute this validator is applied to, + // also as part of the input, skip it + if mp.Equal(req.Path) { + continue + } + + var mpVal attr.Value + diags := req.Config.GetAttribute(ctx, mp, &mpVal) + res.Diagnostics.Append(diags...) + + // Collect all errors + if diags.HasError() { + continue + } + + // Delay validation until all involved attribute have a known value + if mpVal.IsUnknown() { + return + } + + if !mpVal.IsNull() { + count++ + } + } + } + + if count == 0 { + res.Diagnostics.Append(validatordiag.InvalidAttributeCombinationDiagnostic( + req.Path, + fmt.Sprintf("No attribute specified when one (and only one) of %s is required", expressions), + )) + } + + if count > 1 { + res.Diagnostics.Append(validatordiag.InvalidAttributeCombinationDiagnostic( + req.Path, + fmt.Sprintf("%d attributes specified when one (and only one) of %s is required", count, expressions), + )) + } +} + +var _ validator.Object = ExactlyOneAttributeValidator{} diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 2da3b843f9..664e9ab0cd 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -11,15 +11,16 @@ We use go-native types for lists and maps intentionally for the ease for convert package apps_tf import ( + "context" "github.com/hashicorp/terraform-plugin-framework/types" ) type App struct { // The active deployment of the app. A deployment is considered active when // it has been deployed to the app compute. - ActiveDeployment []AppDeployment `tfsdk:"active_deployment" tf:"optional,object"` + ActiveDeployment types.Object `tfsdk:"active_deployment" tf:"optional,object"` - AppStatus []ApplicationStatus `tfsdk:"app_status" tf:"optional,object"` + AppStatus types.List `tfsdk:"app_status" tf:"optional,object" tftype:"ApplicationStatus"` ComputeStatus []ComputeStatus `tfsdk:"compute_status" tf:"optional,object"` // The creation time of the app. Formatted timestamp in ISO 6801. @@ -37,7 +38,7 @@ type App struct { Name types.String `tfsdk:"name" tf:""` // The pending deployment of the app. A deployment is considered pending // when it is being prepared for deployment to the app compute. - PendingDeployment []AppDeployment `tfsdk:"pending_deployment" tf:"optional,object"` + PendingDeployment AppDeployments `tfsdk:"pending_deployment" tf:"optional,object"` // Resources for the app. Resources []AppResource `tfsdk:"resources" tf:"optional"` @@ -54,6 +55,12 @@ type App struct { Url types.String `tfsdk:"url" tf:"computed,optional"` } +func (a *App) GetNestedTypes() map[string]any { + return map[string]any{ + "active_deployment": AppDeployment{}, + } +} + func (newState *App) SyncEffectiveFieldsDuringCreateOrUpdate(plan App) { } @@ -96,6 +103,24 @@ func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AppAccessControlResponse) { } +type AppDeployments []AppDeployment + +func (a AppDeployments) SetUnknown(context.Context, bool) error { + return nil +} + +func (a AppDeployments) SetValue(context.Context, any) error { + return nil +} + +func (a AppDeployments) GetUnknown(context.Context) bool { + return false +} + +func (a AppDeployments) GetValue(context.Context) any { + return a +} + type AppDeployment struct { // The creation time of the deployment. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -283,6 +308,24 @@ func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringRead(existingState AppResourceSqlWarehouse) { } +type ApplicationStatuses []ApplicationStatus + +func (a ApplicationStatuses) SetUnknown(context.Context, bool) error { + return nil +} + +func (a ApplicationStatuses) SetValue(context.Context, any) error { + return nil +} + +func (a ApplicationStatuses) GetUnknown(context.Context) bool { + return false +} + +func (a ApplicationStatuses) GetValue(context.Context) any { + return a +} + type ApplicationStatus struct { // Application status message Message types.String `tfsdk:"message" tf:"computed,optional"` From e30e67744755a165bf25faee8e4347539da22707 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 4 Dec 2024 10:06:27 +0100 Subject: [PATCH 27/91] wip first commit --- .codegen/model.go.tmpl | 35 +- .../registered_model/data_registered_model.go | 8 +- .../products/sharing/resource_share.go | 41 +- .../pluginfw/tfschema/struct_to_schema.go | 33 +- internal/service/apps_tf/model.go | 206 ++- internal/service/billing_tf/model.go | 244 ++- internal/service/catalog_tf/model.go | 1586 +++++++++++++++-- internal/service/compute_tf/model.go | 1367 ++++++++++++-- internal/service/dashboards_tf/model.go | 263 ++- internal/service/files_tf/model.go | 153 +- internal/service/iam_tf/model.go | 432 ++++- internal/service/jobs_tf/model.go | 1368 +++++++++++--- internal/service/marketplace_tf/model.go | 748 +++++++- internal/service/ml_tf/model.go | 950 +++++++++- internal/service/oauth2_tf/model.go | 192 +- internal/service/pipelines_tf/model.go | 515 +++++- internal/service/provisioning_tf/model.go | 349 +++- internal/service/serving_tf/model.go | 610 ++++++- internal/service/settings_tf/model.go | 872 ++++++++- internal/service/sharing_tf/model.go | 314 +++- internal/service/sql_tf/model.go | 1039 +++++++++-- internal/service/vectorsearch_tf/model.go | 296 ++- internal/service/workspace_tf/model.go | 410 ++++- 23 files changed, 10558 insertions(+), 1473 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index ffdd7e1ce2..63c893af29 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -55,9 +55,35 @@ func (newState *{{.PascalName}}) SyncEffectiveFieldsDuringRead(existingState {{. {{- end}} } +func (a {{.PascalName}}) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + {{- range .Fields -}} + {{- if or .Entity.IsObject .Entity.ArrayValue .Entity.MapValue}} + "{{.PascalName}}": reflect.TypeOf({{ template "complex-field-value" .Entity }}), + {{- end}} + {{- end}} + } +} + {{end}} {{end}} +{{define "complex-field-value" -}} + {{- if .ArrayValue }}{{ template "complex-field-value" .ArrayValue }} + {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} + {{- else -}} + {{- if .IsExternal -}}{{.Package.Name}}.{{- end -}} + {{- if or .IsString .Enum -}}"" + {{- else if .IsBool -}}false + {{- else if .IsInt64 -}}0 + {{- else if .IsFloat64 -}}0.0 + {{- else if .IsInt -}}0 + {{- else if .IsAny -}}struct{}{} + {{- else if .IsObject -}}{{.PascalName}}{} + {{- end -}} + {{- end -}} +{{- end -}} + {{- define "field" -}} {{if .effective}}Effective{{end}}{{.field.PascalName}} {{template "type" .field.Entity}} `{{template "field-tag" . }}` {{- end -}} @@ -91,12 +117,9 @@ func (newState *{{.PascalName}}) SyncEffectiveFieldsDuringRead(existingState {{. {{- else if .IsFloat64}}types.Float64 {{- else if .IsInt}}types.Int64 {{- else if .IsByteStream}}io.ReadCloser - {{- else if .ArrayValue }} - {{- if .ArrayValue.IsObject }}{{template "type" .ArrayValue}} - {{- else }}[]{{template "type" .ArrayValue}} - {{- end }} - {{- else if .MapValue }}map[string]{{template "type" .MapValue}} - {{- else if .IsObject }}[]{{.PascalName}} + {{- else if .ArrayValue }}types.List + {{- else if .MapValue }}types.Map + {{- else if .IsObject }}types.Object {{- else if .Enum }}types.String {{- else}}any /* MISSING TYPE */ {{- end -}} diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index 980c46ed14..e98b69bde8 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -14,7 +14,9 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) const dataSourceName = "registered_model" @@ -86,8 +88,10 @@ func (d *RegisteredModelDataSource) Read(ctx context.Context, req datasource.Rea if resp.Diagnostics.HasError() { return } - if modelInfo.Aliases == nil { - modelInfo.Aliases = []catalog_tf.RegisteredModelAlias{} + if modelInfo.Aliases.IsNull() { + var d diag.Diagnostics + modelInfo.Aliases, d = basetypes.NewListValueFrom(ctx, modelInfo.Aliases.ElementType(ctx), []catalog_tf.RegisteredModelAlias{}) + resp.Diagnostics.Append(d...) } registeredModel.ModelInfo = append(registeredModel.ModelInfo, modelInfo) resp.Diagnostics.Append(resp.State.Set(ctx, registeredModel)...) diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index e86847e0c9..c2568d7268 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -13,11 +13,13 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/sharing_tf" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/path" "github.com/hashicorp/terraform-plugin-framework/resource" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/int64planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) const resourceName = "share" @@ -145,8 +147,8 @@ func (r *ShareResource) Schema(ctx context.Context, req resource.SchemaRequest, c.AddPlanModifier(stringplanmodifier.UseStateForUnknown(), "created_by") c.SetRequired("object", "data_object_type") - c.SetRequired("object", "partitions", "values", "op") - c.SetRequired("object", "partitions", "values", "name") + c.SetRequired("object", "partition", "value", "op") + c.SetRequired("object", "partition", "value", "name") return c }) resp.Schema = schema.Schema{ @@ -214,9 +216,16 @@ func (r *ShareResource) Create(ctx context.Context, req resource.CreateRequest, } newState.SyncEffectiveFieldsDuringCreateOrUpdate(plan.ShareInfo) - for i := range newState.Objects { - newState.Objects[i].SyncEffectiveFieldsDuringCreateOrUpdate(plan.Objects[i]) + planObjects := []sharing_tf.SharedDataObject{} + resp.Diagnostics.Append(plan.Objects.ElementsAs(ctx, &planObjects, true)...) + newStateObjects := []sharing_tf.SharedDataObject{} + resp.Diagnostics.Append(newState.Objects.ElementsAs(ctx, &newStateObjects, true)...) + for i := range newStateObjects { + newStateObjects[i].SyncEffectiveFieldsDuringCreateOrUpdate(planObjects[i]) } + var d diag.Diagnostics + newState.Objects, d = basetypes.NewListValueFrom(ctx, newState.Objects.ElementType(ctx), newStateObjects) + resp.Diagnostics.Append(d...) resp.Diagnostics.Append(resp.State.Set(ctx, newState)...) if resp.Diagnostics.HasError() { @@ -272,9 +281,16 @@ func (r *ShareResource) Read(ctx context.Context, req resource.ReadRequest, resp } newState.SyncEffectiveFieldsDuringRead(existingState.ShareInfo) - for i := range newState.Objects { - newState.Objects[i].SyncEffectiveFieldsDuringRead(existingState.Objects[i]) + var existingObjects []sharing_tf.SharedDataObject + resp.Diagnostics.Append(existingState.Objects.ElementsAs(ctx, &existingObjects, true)...) + var newStateObjects []sharing_tf.SharedDataObject + resp.Diagnostics.Append(newState.Objects.ElementsAs(ctx, &newStateObjects, true)...) + for i := range newStateObjects { + newStateObjects[i].SyncEffectiveFieldsDuringRead(existingObjects[i]) } + var d diag.Diagnostics + newState.Objects, d = basetypes.NewListValueFrom(ctx, newState.Objects.ElementType(ctx), newStateObjects) + resp.Diagnostics.Append(d...) resp.Diagnostics.Append(resp.State.Set(ctx, newState)...) } @@ -371,9 +387,16 @@ func (r *ShareResource) Update(ctx context.Context, req resource.UpdateRequest, } state.SyncEffectiveFieldsDuringCreateOrUpdate(plan.ShareInfo) - for i := range state.Objects { - state.Objects[i].SyncEffectiveFieldsDuringCreateOrUpdate(plan.Objects[i]) - } + planObjects := []sharing_tf.SharedDataObject{} + resp.Diagnostics.Append(plan.Objects.ElementsAs(ctx, &planObjects, true)...) + stateObjects := []sharing_tf.SharedDataObject{} + resp.Diagnostics.Append(state.Objects.ElementsAs(ctx, &stateObjects, true)...) + for i := range stateObjects { + stateObjects[i].SyncEffectiveFieldsDuringCreateOrUpdate(planObjects[i]) + } + var d diag.Diagnostics + state.Objects, d = basetypes.NewListValueFrom(ctx, state.Objects.ElementType(ctx), stateObjects) + resp.Diagnostics.Append(d...) resp.Diagnostics.Append(resp.State.Set(ctx, state)...) } diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index b5b6e35fbc..6b1df6ea4e 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -20,6 +20,10 @@ type structTag struct { singleObject bool } +type complexFieldTypeProvider interface { + GetComplexFieldTypes() map[string]reflect.Type +} + func typeToSchema(v reflect.Value) NestedBlockObject { scmAttr := map[string]AttributeBuilder{} scmBlock := map[string]BlockBuilder{} @@ -32,6 +36,13 @@ func typeToSchema(v reflect.Value) NestedBlockObject { panic(fmt.Errorf("schema value of Struct is expected, but got %s: %#v. %s", rk.String(), v, common.TerraformBugErrorMessage)) } fields := tfreflect.ListAllFields(v) + + // Get metadata about complex fields + var complexFieldTypes map[string]reflect.Type + if provider, ok := v.Interface().(complexFieldTypeProvider); ok { + complexFieldTypes = provider.GetComplexFieldTypes() + } + for _, field := range fields { typeField := field.StructField fieldName := typeField.Tag.Get("tfsdk") @@ -174,10 +185,24 @@ func typeToSchema(v reflect.Value) NestedBlockObject { Required: !structTag.optional, Computed: structTag.computed, } - case types.List: - panic(fmt.Errorf("types.List should never be used in tfsdk structs. %s", common.TerraformBugErrorMessage)) - case types.Map: - panic(fmt.Errorf("types.Map should never be used in tfsdk structs. %s", common.TerraformBugErrorMessage)) + case types.Object, types.List: + // Look up nested struct type + if complexFieldTypes == nil { + panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) + } + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + } + fieldValue := reflect.New(fieldType).Elem() + + // Generate the nested block schema + // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). + scmBlock[fieldName] = ListNestedBlockBuilder{ + NestedObject: typeToSchema(fieldValue), + } + case types.Set, types.Tuple, types.Map: + panic(fmt.Errorf("%T should never be used in tfsdk structs. %s", value.Interface(), common.TerraformBugErrorMessage)) default: // If it is a real stuct instead of a tfsdk type, recursively resolve it. elem := typeFieldType diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 2da3b843f9..c3862cd1c7 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -11,17 +11,19 @@ We use go-native types for lists and maps intentionally for the ease for convert package apps_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) type App struct { // The active deployment of the app. A deployment is considered active when // it has been deployed to the app compute. - ActiveDeployment []AppDeployment `tfsdk:"active_deployment" tf:"optional,object"` + ActiveDeployment types.Object `tfsdk:"active_deployment" tf:"optional,object"` - AppStatus []ApplicationStatus `tfsdk:"app_status" tf:"optional,object"` + AppStatus types.Object `tfsdk:"app_status" tf:"optional,object"` - ComputeStatus []ComputeStatus `tfsdk:"compute_status" tf:"optional,object"` + ComputeStatus types.Object `tfsdk:"compute_status" tf:"optional,object"` // The creation time of the app. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The email of the user that created the app. @@ -37,9 +39,9 @@ type App struct { Name types.String `tfsdk:"name" tf:""` // The pending deployment of the app. A deployment is considered pending // when it is being prepared for deployment to the app compute. - PendingDeployment []AppDeployment `tfsdk:"pending_deployment" tf:"optional,object"` + PendingDeployment types.Object `tfsdk:"pending_deployment" tf:"optional,object"` // Resources for the app. - Resources []AppResource `tfsdk:"resources" tf:"optional"` + Resources types.List `tfsdk:"resources" tf:"optional"` ServicePrincipalClientId types.String `tfsdk:"service_principal_client_id" tf:"computed,optional"` @@ -60,6 +62,16 @@ func (newState *App) SyncEffectiveFieldsDuringCreateOrUpdate(plan App) { func (newState *App) SyncEffectiveFieldsDuringRead(existingState App) { } +func (a App) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ActiveDeployment": reflect.TypeOf(AppDeployment{}), + "AppStatus": reflect.TypeOf(ApplicationStatus{}), + "ComputeStatus": reflect.TypeOf(ComputeStatus{}), + "PendingDeployment": reflect.TypeOf(AppDeployment{}), + "Resources": reflect.TypeOf(AppResource{}), + } +} + type AppAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -77,9 +89,13 @@ func (newState *AppAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState AppAccessControlRequest) { } +func (a AppAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppAccessControlResponse struct { // All permissions. - AllPermissions []AppPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -96,13 +112,19 @@ func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AppAccessControlResponse) { } +func (a AppAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(AppPermission{}), + } +} + type AppDeployment struct { // The creation time of the deployment. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The email of the user creates the deployment. Creator types.String `tfsdk:"creator" tf:"computed,optional"` // The deployment artifacts for an app. - DeploymentArtifacts []AppDeploymentArtifacts `tfsdk:"deployment_artifacts" tf:"optional,object"` + DeploymentArtifacts types.Object `tfsdk:"deployment_artifacts" tf:"optional,object"` // The unique id of the deployment. DeploymentId types.String `tfsdk:"deployment_id" tf:"optional"` // The mode of which the deployment will manage the source code. @@ -116,7 +138,7 @@ type AppDeployment struct { // the deployment. SourceCodePath types.String `tfsdk:"source_code_path" tf:"optional"` // Status and status message of the deployment - Status []AppDeploymentStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // The update time of the deployment. Formatted timestamp in ISO 6801. UpdateTime types.String `tfsdk:"update_time" tf:"computed,optional"` } @@ -127,6 +149,13 @@ func (newState *AppDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppD func (newState *AppDeployment) SyncEffectiveFieldsDuringRead(existingState AppDeployment) { } +func (a AppDeployment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DeploymentArtifacts": reflect.TypeOf(AppDeploymentArtifacts{}), + "Status": reflect.TypeOf(AppDeploymentStatus{}), + } +} + type AppDeploymentArtifacts struct { // The snapshotted workspace file system path of the source code loaded by // the deployed app. @@ -139,6 +168,10 @@ func (newState *AppDeploymentArtifacts) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AppDeploymentArtifacts) SyncEffectiveFieldsDuringRead(existingState AppDeploymentArtifacts) { } +func (a AppDeploymentArtifacts) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppDeploymentStatus struct { // Message corresponding with the deployment state. Message types.String `tfsdk:"message" tf:"computed,optional"` @@ -152,10 +185,14 @@ func (newState *AppDeploymentStatus) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AppDeploymentStatus) SyncEffectiveFieldsDuringRead(existingState AppDeploymentStatus) { } +func (a AppDeploymentStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -166,8 +203,14 @@ func (newState *AppPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppP func (newState *AppPermission) SyncEffectiveFieldsDuringRead(existingState AppPermission) { } +func (a AppPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type AppPermissions struct { - AccessControlList []AppAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -180,6 +223,12 @@ func (newState *AppPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan App func (newState *AppPermissions) SyncEffectiveFieldsDuringRead(existingState AppPermissions) { } +func (a AppPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AppAccessControlResponse{}), + } +} + type AppPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -192,8 +241,12 @@ func (newState *AppPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpda func (newState *AppPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState AppPermissionsDescription) { } +func (a AppPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppPermissionsRequest struct { - AccessControlList []AppAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The app for which to get or manage permissions. AppName types.String `tfsdk:"-"` } @@ -204,19 +257,25 @@ func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState AppPermissionsRequest) { } +func (a AppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AppAccessControlRequest{}), + } +} + type AppResource struct { // Description of the App Resource. Description types.String `tfsdk:"description" tf:"optional"` - Job []AppResourceJob `tfsdk:"job" tf:"optional,object"` + Job types.Object `tfsdk:"job" tf:"optional,object"` // Name of the App Resource. Name types.String `tfsdk:"name" tf:""` - Secret []AppResourceSecret `tfsdk:"secret" tf:"optional,object"` + Secret types.Object `tfsdk:"secret" tf:"optional,object"` - ServingEndpoint []AppResourceServingEndpoint `tfsdk:"serving_endpoint" tf:"optional,object"` + ServingEndpoint types.Object `tfsdk:"serving_endpoint" tf:"optional,object"` - SqlWarehouse []AppResourceSqlWarehouse `tfsdk:"sql_warehouse" tf:"optional,object"` + SqlWarehouse types.Object `tfsdk:"sql_warehouse" tf:"optional,object"` } func (newState *AppResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppResource) { @@ -225,6 +284,15 @@ func (newState *AppResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppRes func (newState *AppResource) SyncEffectiveFieldsDuringRead(existingState AppResource) { } +func (a AppResource) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Job": reflect.TypeOf(AppResourceJob{}), + "Secret": reflect.TypeOf(AppResourceSecret{}), + "ServingEndpoint": reflect.TypeOf(AppResourceServingEndpoint{}), + "SqlWarehouse": reflect.TypeOf(AppResourceSqlWarehouse{}), + } +} + type AppResourceJob struct { // Id of the job to grant permission on. Id types.String `tfsdk:"id" tf:""` @@ -239,6 +307,10 @@ func (newState *AppResourceJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan App func (newState *AppResourceJob) SyncEffectiveFieldsDuringRead(existingState AppResourceJob) { } +func (a AppResourceJob) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppResourceSecret struct { // Key of the secret to grant permission on. Key types.String `tfsdk:"key" tf:""` @@ -255,6 +327,10 @@ func (newState *AppResourceSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AppResourceSecret) SyncEffectiveFieldsDuringRead(existingState AppResourceSecret) { } +func (a AppResourceSecret) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppResourceServingEndpoint struct { // Name of the serving endpoint to grant permission on. Name types.String `tfsdk:"name" tf:""` @@ -269,6 +345,10 @@ func (newState *AppResourceServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpd func (newState *AppResourceServingEndpoint) SyncEffectiveFieldsDuringRead(existingState AppResourceServingEndpoint) { } +func (a AppResourceServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AppResourceSqlWarehouse struct { // Id of the SQL warehouse to grant permission on. Id types.String `tfsdk:"id" tf:""` @@ -283,6 +363,10 @@ func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringRead(existingState AppResourceSqlWarehouse) { } +func (a AppResourceSqlWarehouse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ApplicationStatus struct { // Application status message Message types.String `tfsdk:"message" tf:"computed,optional"` @@ -296,6 +380,10 @@ func (newState *ApplicationStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ApplicationStatus) SyncEffectiveFieldsDuringRead(existingState ApplicationStatus) { } +func (a ApplicationStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ComputeStatus struct { // Compute status message Message types.String `tfsdk:"message" tf:"computed,optional"` @@ -309,9 +397,13 @@ func (newState *ComputeStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Comp func (newState *ComputeStatus) SyncEffectiveFieldsDuringRead(existingState ComputeStatus) { } +func (a ComputeStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Create an app deployment type CreateAppDeploymentRequest struct { - AppDeployment []AppDeployment `tfsdk:"app_deployment" tf:"optional,object"` + AppDeployment types.Object `tfsdk:"app_deployment" tf:"optional,object"` // The name of the app. AppName types.String `tfsdk:"-"` } @@ -322,9 +414,15 @@ func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existingState CreateAppDeploymentRequest) { } +func (a CreateAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AppDeployment": reflect.TypeOf(AppDeployment{}), + } +} + // Create an app type CreateAppRequest struct { - App []App `tfsdk:"app" tf:"optional,object"` + App types.Object `tfsdk:"app" tf:"optional,object"` } func (newState *CreateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateAppRequest) { @@ -333,6 +431,12 @@ func (newState *CreateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateAppRequest) SyncEffectiveFieldsDuringRead(existingState CreateAppRequest) { } +func (a CreateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "App": reflect.TypeOf(App{}), + } +} + // Delete an app type DeleteAppRequest struct { // The name of the app. @@ -345,6 +449,10 @@ func (newState *DeleteAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteAppRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAppRequest) { } +func (a DeleteAppRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an app deployment type GetAppDeploymentRequest struct { // The name of the app. @@ -359,6 +467,10 @@ func (newState *GetAppDeploymentRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existingState GetAppDeploymentRequest) { } +func (a GetAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get app permission levels type GetAppPermissionLevelsRequest struct { // The app for which to get or manage permissions. @@ -371,9 +483,13 @@ func (newState *GetAppPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetAppPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionLevelsRequest) { } +func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetAppPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []AppPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetAppPermissionLevelsResponse) { @@ -382,6 +498,12 @@ func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionLevelsResponse) { } +func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(AppPermissionsDescription{}), + } +} + // Get app permissions type GetAppPermissionsRequest struct { // The app for which to get or manage permissions. @@ -394,6 +516,10 @@ func (newState *GetAppPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetAppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionsRequest) { } +func (a GetAppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an app type GetAppRequest struct { // The name of the app. @@ -406,6 +532,10 @@ func (newState *GetAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetA func (newState *GetAppRequest) SyncEffectiveFieldsDuringRead(existingState GetAppRequest) { } +func (a GetAppRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List app deployments type ListAppDeploymentsRequest struct { // The name of the app. @@ -423,9 +553,13 @@ func (newState *ListAppDeploymentsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListAppDeploymentsRequest) SyncEffectiveFieldsDuringRead(existingState ListAppDeploymentsRequest) { } +func (a ListAppDeploymentsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAppDeploymentsResponse struct { // Deployment history of the app. - AppDeployments []AppDeployment `tfsdk:"app_deployments" tf:"optional"` + AppDeployments types.List `tfsdk:"app_deployments" tf:"optional"` // Pagination token to request the next page of apps. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -436,6 +570,12 @@ func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringRead(existingState ListAppDeploymentsResponse) { } +func (a ListAppDeploymentsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AppDeployments": reflect.TypeOf(AppDeployment{}), + } +} + // List apps type ListAppsRequest struct { // Upper bound for items returned. @@ -451,8 +591,12 @@ func (newState *ListAppsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListAppsRequest) SyncEffectiveFieldsDuringRead(existingState ListAppsRequest) { } +func (a ListAppsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAppsResponse struct { - Apps []App `tfsdk:"apps" tf:"optional"` + Apps types.List `tfsdk:"apps" tf:"optional"` // Pagination token to request the next page of apps. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -463,6 +607,12 @@ func (newState *ListAppsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListAppsResponse) SyncEffectiveFieldsDuringRead(existingState ListAppsResponse) { } +func (a ListAppsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Apps": reflect.TypeOf(App{}), + } +} + type StartAppRequest struct { // The name of the app. Name types.String `tfsdk:"-"` @@ -474,6 +624,10 @@ func (newState *StartAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan St func (newState *StartAppRequest) SyncEffectiveFieldsDuringRead(existingState StartAppRequest) { } +func (a StartAppRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StopAppRequest struct { // The name of the app. Name types.String `tfsdk:"-"` @@ -485,9 +639,13 @@ func (newState *StopAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sto func (newState *StopAppRequest) SyncEffectiveFieldsDuringRead(existingState StopAppRequest) { } +func (a StopAppRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Update an app type UpdateAppRequest struct { - App []App `tfsdk:"app" tf:"optional,object"` + App types.Object `tfsdk:"app" tf:"optional,object"` // The name of the app. The name must contain only lowercase alphanumeric // characters and hyphens. It must be unique within the workspace. Name types.String `tfsdk:"-"` @@ -498,3 +656,9 @@ func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAppRequest) { } + +func (a UpdateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "App": reflect.TypeOf(App{}), + } +} diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 7c3ecc7e7a..d86f148fad 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -12,6 +12,7 @@ package billing_tf import ( "io" + "reflect" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -31,10 +32,14 @@ func (newState *ActionConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ActionConfiguration) SyncEffectiveFieldsDuringRead(existingState ActionConfiguration) { } +func (a ActionConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AlertConfiguration struct { // Configured actions for this alert. These define what happens when an // alert enters a triggered state. - ActionConfigurations []ActionConfiguration `tfsdk:"action_configurations" tf:"optional"` + ActionConfigurations types.List `tfsdk:"action_configurations" tf:"optional"` // Databricks alert configuration ID. AlertConfigurationId types.String `tfsdk:"alert_configuration_id" tf:"optional"` // The threshold for the budget alert to determine if it is in a triggered @@ -56,12 +61,18 @@ func (newState *AlertConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertConfiguration) SyncEffectiveFieldsDuringRead(existingState AlertConfiguration) { } +func (a AlertConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ActionConfigurations": reflect.TypeOf(ActionConfiguration{}), + } +} + type BudgetConfiguration struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` // Alerts to configure when this budget is in a triggered state. Budgets // must have exactly one alert configuration. - AlertConfigurations []AlertConfiguration `tfsdk:"alert_configurations" tf:"optional"` + AlertConfigurations types.List `tfsdk:"alert_configurations" tf:"optional"` // Databricks budget configuration ID. BudgetConfigurationId types.String `tfsdk:"budget_configuration_id" tf:"optional"` // Creation time of this budget configuration. @@ -72,7 +83,7 @@ type BudgetConfiguration struct { // usage to limit the scope of what is considered for this budget. Leave // empty to include all usage for this account. All provided filters must be // matched for usage to be included. - Filter []BudgetConfigurationFilter `tfsdk:"filter" tf:"optional,object"` + Filter types.Object `tfsdk:"filter" tf:"optional,object"` // Update time of this budget configuration. UpdateTime types.Int64 `tfsdk:"update_time" tf:"optional"` } @@ -83,13 +94,20 @@ func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringRead(existingState BudgetConfiguration) { } +func (a BudgetConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AlertConfigurations": reflect.TypeOf(AlertConfiguration{}), + "Filter": reflect.TypeOf(BudgetConfigurationFilter{}), + } +} + type BudgetConfigurationFilter struct { // A list of tag keys and values that will limit the budget to usage that // includes those specific custom tags. Tags are case-sensitive and should // be entered exactly as they appear in your usage data. - Tags []BudgetConfigurationFilterTagClause `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // If provided, usage must match with the provided Databricks workspace IDs. - WorkspaceId []BudgetConfigurationFilterWorkspaceIdClause `tfsdk:"workspace_id" tf:"optional,object"` + WorkspaceId types.Object `tfsdk:"workspace_id" tf:"optional,object"` } func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan BudgetConfigurationFilter) { @@ -98,10 +116,17 @@ func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringCreateOrUpda func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilter) { } +func (a BudgetConfigurationFilter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(BudgetConfigurationFilterTagClause{}), + "WorkspaceId": reflect.TypeOf(BudgetConfigurationFilterWorkspaceIdClause{}), + } +} + type BudgetConfigurationFilterClause struct { Operator types.String `tfsdk:"operator" tf:"optional"` - Values []types.String `tfsdk:"values" tf:"optional"` + Values types.List `tfsdk:"values" tf:"optional"` } func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringCreateOrUpdate(plan BudgetConfigurationFilterClause) { @@ -110,10 +135,16 @@ func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringCreate func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterClause) { } +func (a BudgetConfigurationFilterClause) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Values": reflect.TypeOf(""), + } +} + type BudgetConfigurationFilterTagClause struct { Key types.String `tfsdk:"key" tf:"optional"` - Value []BudgetConfigurationFilterClause `tfsdk:"value" tf:"optional,object"` + Value types.Object `tfsdk:"value" tf:"optional,object"` } func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringCreateOrUpdate(plan BudgetConfigurationFilterTagClause) { @@ -122,10 +153,16 @@ func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringCre func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterTagClause) { } +func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Value": reflect.TypeOf(BudgetConfigurationFilterClause{}), + } +} + type BudgetConfigurationFilterWorkspaceIdClause struct { Operator types.String `tfsdk:"operator" tf:"optional"` - Values []types.Int64 `tfsdk:"values" tf:"optional"` + Values types.List `tfsdk:"values" tf:"optional"` } func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsDuringCreateOrUpdate(plan BudgetConfigurationFilterWorkspaceIdClause) { @@ -134,6 +171,12 @@ func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsD func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterWorkspaceIdClause) { } +func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Values": reflect.TypeOf(0), + } +} + type CreateBillingUsageDashboardRequest struct { // Workspace level usage dashboard shows usage data for the specified // workspace ID. Global level usage dashboard shows usage data for all @@ -150,6 +193,10 @@ func (newState *CreateBillingUsageDashboardRequest) SyncEffectiveFieldsDuringCre func (newState *CreateBillingUsageDashboardRequest) SyncEffectiveFieldsDuringRead(existingState CreateBillingUsageDashboardRequest) { } +func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateBillingUsageDashboardResponse struct { // The unique id of the usage dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` @@ -161,19 +208,23 @@ func (newState *CreateBillingUsageDashboardResponse) SyncEffectiveFieldsDuringCr func (newState *CreateBillingUsageDashboardResponse) SyncEffectiveFieldsDuringRead(existingState CreateBillingUsageDashboardResponse) { } +func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateBudgetConfigurationBudget struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` // Alerts to configure when this budget is in a triggered state. Budgets // must have exactly one alert configuration. - AlertConfigurations []CreateBudgetConfigurationBudgetAlertConfigurations `tfsdk:"alert_configurations" tf:"optional"` + AlertConfigurations types.List `tfsdk:"alert_configurations" tf:"optional"` // Human-readable name of budget configuration. Max Length: 128 DisplayName types.String `tfsdk:"display_name" tf:"optional"` // Configured filters for this budget. These are applied to your account's // usage to limit the scope of what is considered for this budget. Leave // empty to include all usage for this account. All provided filters must be // matched for usage to be included. - Filter []BudgetConfigurationFilter `tfsdk:"filter" tf:"optional,object"` + Filter types.Object `tfsdk:"filter" tf:"optional,object"` } func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateBudgetConfigurationBudget) { @@ -182,6 +233,13 @@ func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreate func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudget) { } +func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AlertConfigurations": reflect.TypeOf(CreateBudgetConfigurationBudgetAlertConfigurations{}), + "Filter": reflect.TypeOf(BudgetConfigurationFilter{}), + } +} + type CreateBudgetConfigurationBudgetActionConfigurations struct { // The type of the action. ActionType types.String `tfsdk:"action_type" tf:"optional"` @@ -195,10 +253,14 @@ func (newState *CreateBudgetConfigurationBudgetActionConfigurations) SyncEffecti func (newState *CreateBudgetConfigurationBudgetActionConfigurations) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudgetActionConfigurations) { } +func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateBudgetConfigurationBudgetAlertConfigurations struct { // Configured actions for this alert. These define what happens when an // alert enters a triggered state. - ActionConfigurations []CreateBudgetConfigurationBudgetActionConfigurations `tfsdk:"action_configurations" tf:"optional"` + ActionConfigurations types.List `tfsdk:"action_configurations" tf:"optional"` // The threshold for the budget alert to determine if it is in a triggered // state. The number is evaluated based on `quantity_type`. QuantityThreshold types.String `tfsdk:"quantity_threshold" tf:"optional"` @@ -218,9 +280,15 @@ func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiv func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudgetAlertConfigurations) { } +func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ActionConfigurations": reflect.TypeOf(CreateBudgetConfigurationBudgetActionConfigurations{}), + } +} + type CreateBudgetConfigurationRequest struct { // Properties of the new budget configuration. - Budget []CreateBudgetConfigurationBudget `tfsdk:"budget" tf:"object"` + Budget types.Object `tfsdk:"budget" tf:"object"` } func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateBudgetConfigurationRequest) { @@ -229,9 +297,15 @@ func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationRequest) { } +func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Budget": reflect.TypeOf(CreateBudgetConfigurationBudget{}), + } +} + type CreateBudgetConfigurationResponse struct { // The created budget configuration. - Budget []BudgetConfiguration `tfsdk:"budget" tf:"optional,object"` + Budget types.Object `tfsdk:"budget" tf:"optional,object"` } func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateBudgetConfigurationResponse) { @@ -240,6 +314,12 @@ func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationResponse) { } +func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Budget": reflect.TypeOf(BudgetConfiguration{}), + } +} + type CreateLogDeliveryConfigurationParams struct { // The optional human-readable name of the log delivery configuration. // Defaults to empty. @@ -309,7 +389,7 @@ type CreateLogDeliveryConfigurationParams struct { // delivery won't include account level logs. For some types of Databricks // deployments there is only one workspace per account ID, so this field is // unnecessary. - WorkspaceIdsFilter []types.Int64 `tfsdk:"workspace_ids_filter" tf:"optional"` + WorkspaceIdsFilter types.List `tfsdk:"workspace_ids_filter" tf:"optional"` } func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateLogDeliveryConfigurationParams) { @@ -318,6 +398,12 @@ func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringC func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringRead(existingState CreateLogDeliveryConfigurationParams) { } +func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "WorkspaceIdsFilter": reflect.TypeOf(0), + } +} + // Delete budget type DeleteBudgetConfigurationRequest struct { // The Databricks budget configuration ID. @@ -330,6 +416,10 @@ func (newState *DeleteBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteBudgetConfigurationRequest) { } +func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteBudgetConfigurationResponse struct { } @@ -339,6 +429,10 @@ func (newState *DeleteBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *DeleteBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteBudgetConfigurationResponse) { } +func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Return billable usage logs type DownloadRequest struct { // Format: `YYYY-MM`. Last month to return billable usage logs for. This @@ -359,6 +453,10 @@ func (newState *DownloadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DownloadRequest) SyncEffectiveFieldsDuringRead(existingState DownloadRequest) { } +func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DownloadResponse struct { Contents io.ReadCloser `tfsdk:"-"` } @@ -369,6 +467,10 @@ func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DownloadResponse) SyncEffectiveFieldsDuringRead(existingState DownloadResponse) { } +func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get usage dashboard type GetBillingUsageDashboardRequest struct { // Workspace level usage dashboard shows usage data for the specified @@ -386,6 +488,10 @@ func (newState *GetBillingUsageDashboardRequest) SyncEffectiveFieldsDuringCreate func (newState *GetBillingUsageDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetBillingUsageDashboardRequest) { } +func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetBillingUsageDashboardResponse struct { // The unique id of the usage dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` @@ -399,6 +505,10 @@ func (newState *GetBillingUsageDashboardResponse) SyncEffectiveFieldsDuringCreat func (newState *GetBillingUsageDashboardResponse) SyncEffectiveFieldsDuringRead(existingState GetBillingUsageDashboardResponse) { } +func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get budget type GetBudgetConfigurationRequest struct { // The budget configuration ID @@ -411,8 +521,12 @@ func (newState *GetBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState GetBudgetConfigurationRequest) { } +func (a GetBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetBudgetConfigurationResponse struct { - Budget []BudgetConfiguration `tfsdk:"budget" tf:"optional,object"` + Budget types.Object `tfsdk:"budget" tf:"optional,object"` } func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetBudgetConfigurationResponse) { @@ -421,6 +535,12 @@ func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState GetBudgetConfigurationResponse) { } +func (a GetBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Budget": reflect.TypeOf(BudgetConfiguration{}), + } +} + // Get log delivery configuration type GetLogDeliveryRequest struct { // Databricks log delivery configuration ID @@ -433,6 +553,10 @@ func (newState *GetLogDeliveryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetLogDeliveryRequest) SyncEffectiveFieldsDuringRead(existingState GetLogDeliveryRequest) { } +func (a GetLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get all budgets type ListBudgetConfigurationsRequest struct { // A page token received from a previous get all budget configurations call. @@ -447,8 +571,12 @@ func (newState *ListBudgetConfigurationsRequest) SyncEffectiveFieldsDuringCreate func (newState *ListBudgetConfigurationsRequest) SyncEffectiveFieldsDuringRead(existingState ListBudgetConfigurationsRequest) { } +func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListBudgetConfigurationsResponse struct { - Budgets []BudgetConfiguration `tfsdk:"budgets" tf:"optional"` + Budgets types.List `tfsdk:"budgets" tf:"optional"` // Token which can be sent as `page_token` to retrieve the next page of // results. If this field is omitted, there are no subsequent budgets. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -460,6 +588,12 @@ func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringCreat func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringRead(existingState ListBudgetConfigurationsResponse) { } +func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Budgets": reflect.TypeOf(BudgetConfiguration{}), + } +} + // Get all log delivery configurations type ListLogDeliveryRequest struct { // Filter by credential configuration ID. @@ -476,6 +610,10 @@ func (newState *ListLogDeliveryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListLogDeliveryRequest) SyncEffectiveFieldsDuringRead(existingState ListLogDeliveryRequest) { } +func (a ListLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogDeliveryConfiguration struct { // The Databricks account ID that hosts the log delivery configuration. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -504,7 +642,7 @@ type LogDeliveryConfiguration struct { // available for usage before March 2019 (`2019-03`). DeliveryStartTime types.String `tfsdk:"delivery_start_time" tf:"optional"` // Databricks log delivery status. - LogDeliveryStatus []LogDeliveryStatus `tfsdk:"log_delivery_status" tf:"optional,object"` + LogDeliveryStatus types.Object `tfsdk:"log_delivery_status" tf:"optional,object"` // Log delivery type. Supported values are: // // * `BILLABLE_USAGE` — Configure [billable usage log delivery]. For the @@ -557,7 +695,7 @@ type LogDeliveryConfiguration struct { // delivery won't include account level logs. For some types of Databricks // deployments there is only one workspace per account ID, so this field is // unnecessary. - WorkspaceIdsFilter []types.Int64 `tfsdk:"workspace_ids_filter" tf:"optional"` + WorkspaceIdsFilter types.List `tfsdk:"workspace_ids_filter" tf:"optional"` } func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogDeliveryConfiguration) { @@ -566,6 +704,13 @@ func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState LogDeliveryConfiguration) { } +func (a LogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LogDeliveryStatus": reflect.TypeOf(LogDeliveryStatus{}), + "WorkspaceIdsFilter": reflect.TypeOf(0), + } +} + // Databricks log delivery status. type LogDeliveryStatus struct { // The UTC time for the latest log delivery attempt. @@ -595,6 +740,10 @@ func (newState *LogDeliveryStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogDeliveryStatus) SyncEffectiveFieldsDuringRead(existingState LogDeliveryStatus) { } +func (a LogDeliveryStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PatchStatusResponse struct { } @@ -604,12 +753,16 @@ func (newState *PatchStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PatchStatusResponse) SyncEffectiveFieldsDuringRead(existingState PatchStatusResponse) { } +func (a PatchStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateBudgetConfigurationBudget struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` // Alerts to configure when this budget is in a triggered state. Budgets // must have exactly one alert configuration. - AlertConfigurations []AlertConfiguration `tfsdk:"alert_configurations" tf:"optional"` + AlertConfigurations types.List `tfsdk:"alert_configurations" tf:"optional"` // Databricks budget configuration ID. BudgetConfigurationId types.String `tfsdk:"budget_configuration_id" tf:"optional"` // Human-readable name of budget configuration. Max Length: 128 @@ -618,7 +771,7 @@ type UpdateBudgetConfigurationBudget struct { // usage to limit the scope of what is considered for this budget. Leave // empty to include all usage for this account. All provided filters must be // matched for usage to be included. - Filter []BudgetConfigurationFilter `tfsdk:"filter" tf:"optional,object"` + Filter types.Object `tfsdk:"filter" tf:"optional,object"` } func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateBudgetConfigurationBudget) { @@ -627,10 +780,17 @@ func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreate func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationBudget) { } +func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AlertConfigurations": reflect.TypeOf(AlertConfiguration{}), + "Filter": reflect.TypeOf(BudgetConfigurationFilter{}), + } +} + type UpdateBudgetConfigurationRequest struct { // The updated budget. This will overwrite the budget specified by the // budget ID. - Budget []UpdateBudgetConfigurationBudget `tfsdk:"budget" tf:"object"` + Budget types.Object `tfsdk:"budget" tf:"object"` // The Databricks budget configuration ID. BudgetId types.String `tfsdk:"-"` } @@ -641,9 +801,15 @@ func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationRequest) { } +func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Budget": reflect.TypeOf(UpdateBudgetConfigurationBudget{}), + } +} + type UpdateBudgetConfigurationResponse struct { // The updated budget. - Budget []BudgetConfiguration `tfsdk:"budget" tf:"optional,object"` + Budget types.Object `tfsdk:"budget" tf:"optional,object"` } func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateBudgetConfigurationResponse) { @@ -652,6 +818,12 @@ func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationResponse) { } +func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Budget": reflect.TypeOf(BudgetConfiguration{}), + } +} + type UpdateLogDeliveryConfigurationStatusRequest struct { // Databricks log delivery configuration ID LogDeliveryConfigurationId types.String `tfsdk:"-"` @@ -669,8 +841,12 @@ func (newState *UpdateLogDeliveryConfigurationStatusRequest) SyncEffectiveFields func (newState *UpdateLogDeliveryConfigurationStatusRequest) SyncEffectiveFieldsDuringRead(existingState UpdateLogDeliveryConfigurationStatusRequest) { } +func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WrappedCreateLogDeliveryConfiguration struct { - LogDeliveryConfiguration []CreateLogDeliveryConfigurationParams `tfsdk:"log_delivery_configuration" tf:"optional,object"` + LogDeliveryConfiguration types.Object `tfsdk:"log_delivery_configuration" tf:"optional,object"` } func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan WrappedCreateLogDeliveryConfiguration) { @@ -679,8 +855,14 @@ func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuring func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState WrappedCreateLogDeliveryConfiguration) { } +func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LogDeliveryConfiguration": reflect.TypeOf(CreateLogDeliveryConfigurationParams{}), + } +} + type WrappedLogDeliveryConfiguration struct { - LogDeliveryConfiguration []LogDeliveryConfiguration `tfsdk:"log_delivery_configuration" tf:"optional,object"` + LogDeliveryConfiguration types.Object `tfsdk:"log_delivery_configuration" tf:"optional,object"` } func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan WrappedLogDeliveryConfiguration) { @@ -689,8 +871,14 @@ func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreate func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState WrappedLogDeliveryConfiguration) { } +func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LogDeliveryConfiguration": reflect.TypeOf(LogDeliveryConfiguration{}), + } +} + type WrappedLogDeliveryConfigurations struct { - LogDeliveryConfigurations []LogDeliveryConfiguration `tfsdk:"log_delivery_configurations" tf:"optional"` + LogDeliveryConfigurations types.List `tfsdk:"log_delivery_configurations" tf:"optional"` } func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringCreateOrUpdate(plan WrappedLogDeliveryConfigurations) { @@ -698,3 +886,9 @@ func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringCreat func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringRead(existingState WrappedLogDeliveryConfigurations) { } + +func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LogDeliveryConfigurations": reflect.TypeOf(LogDeliveryConfiguration{}), + } +} diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index aef640cdfa..365e84be7f 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -11,11 +11,13 @@ We use go-native types for lists and maps intentionally for the ease for convert package catalog_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) type AccountsCreateMetastore struct { - MetastoreInfo []CreateMetastore `tfsdk:"metastore_info" tf:"optional,object"` + MetastoreInfo types.Object `tfsdk:"metastore_info" tf:"optional,object"` } func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsCreateMetastore) { @@ -24,8 +26,14 @@ func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringRead(existingState AccountsCreateMetastore) { } +func (a AccountsCreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MetastoreInfo": reflect.TypeOf(CreateMetastore{}), + } +} + type AccountsCreateMetastoreAssignment struct { - MetastoreAssignment []CreateMetastoreAssignment `tfsdk:"metastore_assignment" tf:"optional,object"` + MetastoreAssignment types.Object `tfsdk:"metastore_assignment" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` // Workspace ID. @@ -38,8 +46,14 @@ func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringCrea func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsCreateMetastoreAssignment) { } +func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MetastoreAssignment": reflect.TypeOf(CreateMetastoreAssignment{}), + } +} + type AccountsCreateStorageCredential struct { - CredentialInfo []CreateStorageCredential `tfsdk:"credential_info" tf:"optional,object"` + CredentialInfo types.Object `tfsdk:"credential_info" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` } @@ -50,8 +64,14 @@ func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringCreate func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringRead(existingState AccountsCreateStorageCredential) { } +func (a AccountsCreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CredentialInfo": reflect.TypeOf(CreateStorageCredential{}), + } +} + type AccountsMetastoreAssignment struct { - MetastoreAssignment []MetastoreAssignment `tfsdk:"metastore_assignment" tf:"optional,object"` + MetastoreAssignment types.Object `tfsdk:"metastore_assignment" tf:"optional,object"` } func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsMetastoreAssignment) { @@ -60,8 +80,14 @@ func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUp func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsMetastoreAssignment) { } +func (a AccountsMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MetastoreAssignment": reflect.TypeOf(MetastoreAssignment{}), + } +} + type AccountsMetastoreInfo struct { - MetastoreInfo []MetastoreInfo `tfsdk:"metastore_info" tf:"optional,object"` + MetastoreInfo types.Object `tfsdk:"metastore_info" tf:"optional,object"` } func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsMetastoreInfo) { @@ -70,8 +96,14 @@ func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringRead(existingState AccountsMetastoreInfo) { } +func (a AccountsMetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MetastoreInfo": reflect.TypeOf(MetastoreInfo{}), + } +} + type AccountsStorageCredentialInfo struct { - CredentialInfo []StorageCredentialInfo `tfsdk:"credential_info" tf:"optional,object"` + CredentialInfo types.Object `tfsdk:"credential_info" tf:"optional,object"` } func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsStorageCredentialInfo) { @@ -80,11 +112,17 @@ func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringCreateOr func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingState AccountsStorageCredentialInfo) { } +func (a AccountsStorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CredentialInfo": reflect.TypeOf(StorageCredentialInfo{}), + } +} + type AccountsUpdateMetastore struct { // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` - MetastoreInfo []UpdateMetastore `tfsdk:"metastore_info" tf:"optional,object"` + MetastoreInfo types.Object `tfsdk:"metastore_info" tf:"optional,object"` } func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsUpdateMetastore) { @@ -93,8 +131,14 @@ func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateMetastore) { } +func (a AccountsUpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MetastoreInfo": reflect.TypeOf(UpdateMetastore{}), + } +} + type AccountsUpdateMetastoreAssignment struct { - MetastoreAssignment []UpdateMetastoreAssignment `tfsdk:"metastore_assignment" tf:"optional,object"` + MetastoreAssignment types.Object `tfsdk:"metastore_assignment" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` // Workspace ID. @@ -107,8 +151,14 @@ func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringCrea func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateMetastoreAssignment) { } +func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MetastoreAssignment": reflect.TypeOf(UpdateMetastoreAssignment{}), + } +} + type AccountsUpdateStorageCredential struct { - CredentialInfo []UpdateStorageCredential `tfsdk:"credential_info" tf:"optional,object"` + CredentialInfo types.Object `tfsdk:"credential_info" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` // Name of the storage credential. @@ -121,9 +171,15 @@ func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringCreate func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateStorageCredential) { } +func (a AccountsUpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CredentialInfo": reflect.TypeOf(UpdateStorageCredential{}), + } +} + type ArtifactAllowlistInfo struct { // A list of allowed artifact match patterns. - ArtifactMatchers []ArtifactMatcher `tfsdk:"artifact_matchers" tf:"optional"` + ArtifactMatchers types.List `tfsdk:"artifact_matchers" tf:"optional"` // Time at which this artifact allowlist was set, in epoch milliseconds. CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` // Username of the user who set the artifact allowlist. @@ -138,6 +194,12 @@ func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringRead(existingState ArtifactAllowlistInfo) { } +func (a ArtifactAllowlistInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ArtifactMatchers": reflect.TypeOf(ArtifactMatcher{}), + } +} + type ArtifactMatcher struct { // The artifact path or maven coordinate Artifact types.String `tfsdk:"artifact" tf:""` @@ -151,6 +213,10 @@ func (newState *ArtifactMatcher) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ar func (newState *ArtifactMatcher) SyncEffectiveFieldsDuringRead(existingState ArtifactMatcher) { } +func (a ArtifactMatcher) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AssignResponse struct { } @@ -160,6 +226,10 @@ func (newState *AssignResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ass func (newState *AssignResponse) SyncEffectiveFieldsDuringRead(existingState AssignResponse) { } +func (a AssignResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // AWS temporary credentials for API authentication. Read more at // https://docs.aws.amazon.com/STS/latest/APIReference/API_Credentials.html. type AwsCredentials struct { @@ -181,6 +251,10 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan Aws func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsCredentials) { } +func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The AWS IAM role configuration type AwsIamRole struct { // The external ID used in role assumption to prevent the confused deputy @@ -200,6 +274,10 @@ func (newState *AwsIamRole) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsIamR func (newState *AwsIamRole) SyncEffectiveFieldsDuringRead(existingState AwsIamRole) { } +func (a AwsIamRole) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AwsIamRoleRequest struct { // The Amazon Resource Name (ARN) of the AWS IAM role for S3 data access. RoleArn types.String `tfsdk:"role_arn" tf:""` @@ -211,6 +289,10 @@ func (newState *AwsIamRoleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AwsIamRoleRequest) SyncEffectiveFieldsDuringRead(existingState AwsIamRoleRequest) { } +func (a AwsIamRoleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AwsIamRoleResponse struct { // The external ID used in role assumption to prevent confused deputy // problem.. @@ -228,6 +310,10 @@ func (newState *AwsIamRoleResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AwsIamRoleResponse) SyncEffectiveFieldsDuringRead(existingState AwsIamRoleResponse) { } +func (a AwsIamRoleResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Azure Active Directory token, essentially the Oauth token for Azure Service // Principal or Managed Identity. Read more at // https://learn.microsoft.com/en-us/azure/databricks/dev-tools/api/latest/aad/service-prin-aad-token @@ -243,6 +329,10 @@ func (newState *AzureActiveDirectoryToken) SyncEffectiveFieldsDuringCreateOrUpda func (newState *AzureActiveDirectoryToken) SyncEffectiveFieldsDuringRead(existingState AzureActiveDirectoryToken) { } +func (a AzureActiveDirectoryToken) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The Azure managed identity configuration. type AzureManagedIdentity struct { // The Azure resource ID of the Azure Databricks Access Connector. Use the @@ -269,6 +359,10 @@ func (newState *AzureManagedIdentity) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *AzureManagedIdentity) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentity) { } +func (a AzureManagedIdentity) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AzureManagedIdentityRequest struct { // The Azure resource ID of the Azure Databricks Access Connector. Use the // format @@ -289,6 +383,10 @@ func (newState *AzureManagedIdentityRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *AzureManagedIdentityRequest) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentityRequest) { } +func (a AzureManagedIdentityRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AzureManagedIdentityResponse struct { // The Azure resource ID of the Azure Databricks Access Connector. Use the // format @@ -311,6 +409,10 @@ func (newState *AzureManagedIdentityResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *AzureManagedIdentityResponse) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentityResponse) { } +func (a AzureManagedIdentityResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The Azure service principal configuration. type AzureServicePrincipal struct { // The application ID of the application registration within the referenced @@ -329,6 +431,10 @@ func (newState *AzureServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AzureServicePrincipal) SyncEffectiveFieldsDuringRead(existingState AzureServicePrincipal) { } +func (a AzureServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Azure temporary credentials for API authentication. Read more at // https://docs.microsoft.com/en-us/rest/api/storageservices/create-user-delegation-sas type AzureUserDelegationSas struct { @@ -342,6 +448,10 @@ func (newState *AzureUserDelegationSas) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AzureUserDelegationSas) SyncEffectiveFieldsDuringRead(existingState AzureUserDelegationSas) { } +func (a AzureUserDelegationSas) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Cancel refresh type CancelRefreshRequest struct { // ID of the refresh. @@ -356,6 +466,10 @@ func (newState *CancelRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CancelRefreshRequest) SyncEffectiveFieldsDuringRead(existingState CancelRefreshRequest) { } +func (a CancelRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CancelRefreshResponse struct { } @@ -365,6 +479,10 @@ func (newState *CancelRefreshResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CancelRefreshResponse) SyncEffectiveFieldsDuringRead(existingState CancelRefreshResponse) { } +func (a CancelRefreshResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CatalogInfo struct { // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is @@ -381,7 +499,7 @@ type CatalogInfo struct { // Username of catalog creator. CreatedBy types.String `tfsdk:"created_by" tf:"optional"` - EffectivePredictiveOptimizationFlag []EffectivePredictiveOptimizationFlag `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` + EffectivePredictiveOptimizationFlag types.Object `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` // Whether predictive optimization should be enabled for this object and // objects under it. EnablePredictiveOptimization types.String `tfsdk:"enable_predictive_optimization" tf:"optional"` @@ -395,18 +513,18 @@ type CatalogInfo struct { // Name of catalog. Name types.String `tfsdk:"name" tf:"optional"` // A map of key-value properties attached to the securable. - Options map[string]types.String `tfsdk:"options" tf:"optional"` + Options types.Map `tfsdk:"options" tf:"optional"` // Username of current owner of catalog. Owner types.String `tfsdk:"owner" tf:"optional"` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` // The name of delta sharing provider. // // A Delta Sharing catalog is a catalog that is based on a Delta share on a // remote sharing server. ProviderName types.String `tfsdk:"provider_name" tf:"optional"` // Status of an asynchronously provisioned resource. - ProvisioningInfo []ProvisioningInfo `tfsdk:"provisioning_info" tf:"optional,object"` + ProvisioningInfo types.Object `tfsdk:"provisioning_info" tf:"optional,object"` // Kind of catalog securable. SecurableKind types.String `tfsdk:"securable_kind" tf:"optional"` @@ -429,6 +547,15 @@ func (newState *CatalogInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Catalo func (newState *CatalogInfo) SyncEffectiveFieldsDuringRead(existingState CatalogInfo) { } +func (a CatalogInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), + "Options": reflect.TypeOf(""), + "Properties": reflect.TypeOf(""), + "ProvisioningInfo": reflect.TypeOf(ProvisioningInfo{}), + } +} + type CloudflareApiToken struct { // The Cloudflare access key id of the token. AccessKeyId types.String `tfsdk:"access_key_id" tf:""` @@ -444,11 +571,15 @@ func (newState *CloudflareApiToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CloudflareApiToken) SyncEffectiveFieldsDuringRead(existingState CloudflareApiToken) { } +func (a CloudflareApiToken) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ColumnInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` - Mask []ColumnMask `tfsdk:"mask" tf:"optional,object"` + Mask types.Object `tfsdk:"mask" tf:"optional,object"` // Name of Column. Name types.String `tfsdk:"name" tf:"optional"` // Whether field may be Null (default: true). @@ -477,6 +608,12 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } +func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Mask": reflect.TypeOf(ColumnMask{}), + } +} + type ColumnMask struct { // The full name of the column mask SQL UDF. FunctionName types.String `tfsdk:"function_name" tf:"optional"` @@ -484,7 +621,7 @@ type ColumnMask struct { // mask function. The first arg of the mask function should be of the type // of the column being masked and the types of the rest of the args should // match the types of columns in 'using_column_names'. - UsingColumnNames []types.String `tfsdk:"using_column_names" tf:"optional"` + UsingColumnNames types.List `tfsdk:"using_column_names" tf:"optional"` } func (newState *ColumnMask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnMask) { @@ -493,6 +630,12 @@ func (newState *ColumnMask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnM func (newState *ColumnMask) SyncEffectiveFieldsDuringRead(existingState ColumnMask) { } +func (a ColumnMask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "UsingColumnNames": reflect.TypeOf(""), + } +} + type ConnectionInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -513,14 +656,14 @@ type ConnectionInfo struct { // Name of the connection. Name types.String `tfsdk:"name" tf:"optional"` // A map of key-value properties attached to the securable. - Options map[string]types.String `tfsdk:"options" tf:"optional"` + Options types.Map `tfsdk:"options" tf:"optional"` // Username of current owner of the connection. Owner types.String `tfsdk:"owner" tf:"optional"` // An object containing map of key-value properties attached to the // connection. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` // Status of an asynchronously provisioned resource. - ProvisioningInfo []ProvisioningInfo `tfsdk:"provisioning_info" tf:"optional,object"` + ProvisioningInfo types.Object `tfsdk:"provisioning_info" tf:"optional,object"` // If the connection is read only. ReadOnly types.Bool `tfsdk:"read_only" tf:"optional"` // Kind of connection securable. @@ -541,11 +684,19 @@ func (newState *ConnectionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Con func (newState *ConnectionInfo) SyncEffectiveFieldsDuringRead(existingState ConnectionInfo) { } +func (a ConnectionInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(""), + "Properties": reflect.TypeOf(""), + "ProvisioningInfo": reflect.TypeOf(ProvisioningInfo{}), + } +} + // Detailed status of an online table. Shown if the online table is in the // ONLINE_CONTINUOUS_UPDATE or the ONLINE_UPDATING_PIPELINE_RESOURCES state. type ContinuousUpdateStatus struct { // Progress of the initial data synchronization. - InitialPipelineSyncProgress []PipelineProgress `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` + InitialPipelineSyncProgress types.Object `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` // The last source table Delta version that was synced to the online table. // Note that this Delta version may not be completely synced to the online // table yet. @@ -561,6 +712,12 @@ func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringRead(existingState ContinuousUpdateStatus) { } +func (a ContinuousUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InitialPipelineSyncProgress": reflect.TypeOf(PipelineProgress{}), + } +} + type CreateCatalog struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -569,9 +726,9 @@ type CreateCatalog struct { // Name of catalog. Name types.String `tfsdk:"name" tf:""` // A map of key-value properties attached to the securable. - Options map[string]types.String `tfsdk:"options" tf:"optional"` + Options types.Map `tfsdk:"options" tf:"optional"` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` // The name of delta sharing provider. // // A Delta Sharing catalog is a catalog that is based on a Delta share on a @@ -589,6 +746,13 @@ func (newState *CreateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateCatalog) SyncEffectiveFieldsDuringRead(existingState CreateCatalog) { } +func (a CreateCatalog) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(""), + "Properties": reflect.TypeOf(""), + } +} + type CreateConnection struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -597,10 +761,10 @@ type CreateConnection struct { // Name of the connection. Name types.String `tfsdk:"name" tf:""` // A map of key-value properties attached to the securable. - Options map[string]types.String `tfsdk:"options" tf:""` + Options types.Map `tfsdk:"options" tf:""` // An object containing map of key-value properties attached to the // connection. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` // If the connection is read only. ReadOnly types.Bool `tfsdk:"read_only" tf:"optional"` } @@ -611,18 +775,25 @@ func (newState *CreateConnection) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateConnection) SyncEffectiveFieldsDuringRead(existingState CreateConnection) { } +func (a CreateConnection) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(""), + "Properties": reflect.TypeOf(""), + } +} + type CreateCredentialRequest struct { // The AWS IAM role configuration - AwsIamRole []AwsIamRole `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentity `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // TODO(UC-978): Document GCP service account key usage for service // credentials. - GcpServiceAccountKey []GcpServiceAccountKey `tfsdk:"gcp_service_account_key" tf:"optional,object"` + GcpServiceAccountKey types.Object `tfsdk:"gcp_service_account_key" tf:"optional,object"` // The credential name. The name must be unique among storage and service // credentials within the metastore. Name types.String `tfsdk:"name" tf:""` @@ -642,6 +813,15 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialRequest) { } +func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRole{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "GcpServiceAccountKey": reflect.TypeOf(GcpServiceAccountKey{}), + } +} + type CreateExternalLocation struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -650,7 +830,7 @@ type CreateExternalLocation struct { // Name of the storage credential used with this location. CredentialName types.String `tfsdk:"credential_name" tf:""` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails []EncryptionDetails `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` // Indicates whether fallback mode is enabled for this external location. // When fallback mode is enabled, the access to the location falls back to // cluster credentials if UC credentials are not sufficient. @@ -672,6 +852,12 @@ func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringRead(existingState CreateExternalLocation) { } +func (a CreateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + } +} + type CreateFunction struct { // Name of parent catalog. CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -686,7 +872,7 @@ type CreateFunction struct { // Pretty printed function data type. FullDataType types.String `tfsdk:"full_data_type" tf:""` - InputParams []FunctionParameterInfos `tfsdk:"input_params" tf:"object"` + InputParams types.Object `tfsdk:"input_params" tf:"object"` // Whether the function is deterministic. IsDeterministic types.Bool `tfsdk:"is_deterministic" tf:""` // Function null call. @@ -698,7 +884,7 @@ type CreateFunction struct { // JSON-serialized key-value pair map, encoded (escaped) as a string. Properties types.String `tfsdk:"properties" tf:"optional"` // Table function return parameters. - ReturnParams []FunctionParameterInfos `tfsdk:"return_params" tf:"optional,object"` + ReturnParams types.Object `tfsdk:"return_params" tf:"optional,object"` // Function language. When **EXTERNAL** is used, the language of the routine // function should be specified in the __external_language__ field, and the // __return_params__ of the function cannot be used (as **TABLE** return @@ -708,7 +894,7 @@ type CreateFunction struct { // Function body. RoutineDefinition types.String `tfsdk:"routine_definition" tf:""` // Function dependencies. - RoutineDependencies []DependencyList `tfsdk:"routine_dependencies" tf:"optional,object"` + RoutineDependencies types.Object `tfsdk:"routine_dependencies" tf:"optional,object"` // Name of parent schema relative to its parent catalog. SchemaName types.String `tfsdk:"schema_name" tf:""` // Function security type. @@ -727,9 +913,17 @@ func (newState *CreateFunction) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateFunction) SyncEffectiveFieldsDuringRead(existingState CreateFunction) { } +func (a CreateFunction) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InputParams": reflect.TypeOf(FunctionParameterInfos{}), + "ReturnParams": reflect.TypeOf(FunctionParameterInfos{}), + "RoutineDependencies": reflect.TypeOf(DependencyList{}), + } +} + type CreateFunctionRequest struct { // Partial __FunctionInfo__ specifying the function to be created. - FunctionInfo []CreateFunction `tfsdk:"function_info" tf:"object"` + FunctionInfo types.Object `tfsdk:"function_info" tf:"object"` } func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateFunctionRequest) { @@ -738,6 +932,12 @@ func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringRead(existingState CreateFunctionRequest) { } +func (a CreateFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FunctionInfo": reflect.TypeOf(CreateFunction{}), + } +} + type CreateMetastore struct { // The user-specified name of the metastore. Name types.String `tfsdk:"name" tf:""` @@ -756,6 +956,10 @@ func (newState *CreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cr func (newState *CreateMetastore) SyncEffectiveFieldsDuringRead(existingState CreateMetastore) { } +func (a CreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateMetastoreAssignment struct { // The name of the default catalog in the metastore. This field is // depracted. Please use "Default Namespace API" to configure the default @@ -773,6 +977,10 @@ func (newState *CreateMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState CreateMetastoreAssignment) { } +func (a CreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateMonitor struct { // The directory to store monitoring assets (e.g. dashboard, metric tables). AssetsDir types.String `tfsdk:"assets_dir" tf:""` @@ -783,17 +991,17 @@ type CreateMonitor struct { // Custom metrics to compute on the monitored table. These can be aggregate // metrics, derived metrics (from already computed aggregate metrics), or // drift metrics (comparing metrics across time windows). - CustomMetrics []MonitorMetric `tfsdk:"custom_metrics" tf:"optional"` + CustomMetrics types.List `tfsdk:"custom_metrics" tf:"optional"` // The data classification config for the monitor. - DataClassificationConfig []MonitorDataClassificationConfig `tfsdk:"data_classification_config" tf:"optional,object"` + DataClassificationConfig types.Object `tfsdk:"data_classification_config" tf:"optional,object"` // Configuration for monitoring inference logs. - InferenceLog []MonitorInferenceLog `tfsdk:"inference_log" tf:"optional,object"` + InferenceLog types.Object `tfsdk:"inference_log" tf:"optional,object"` // The notification settings for the monitor. - Notifications []MonitorNotifications `tfsdk:"notifications" tf:"optional,object"` + Notifications types.Object `tfsdk:"notifications" tf:"optional,object"` // Schema where output metric tables are created. OutputSchemaName types.String `tfsdk:"output_schema_name" tf:""` // The schedule for automatically updating and refreshing metric tables. - Schedule []MonitorCronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // Whether to skip creating a default dashboard summarizing data quality // metrics. SkipBuiltinDashboard types.Bool `tfsdk:"skip_builtin_dashboard" tf:"optional"` @@ -802,13 +1010,13 @@ type CreateMonitor struct { // slice for each predicate and its complements. For high-cardinality // columns, only the top 100 unique values by frequency will generate // slices. - SlicingExprs []types.String `tfsdk:"slicing_exprs" tf:"optional"` + SlicingExprs types.List `tfsdk:"slicing_exprs" tf:"optional"` // Configuration for monitoring snapshot tables. Snapshot []MonitorSnapshot `tfsdk:"snapshot" tf:"optional,object"` // Full name of the table. TableName types.String `tfsdk:"-"` // Configuration for monitoring time series tables. - TimeSeries []MonitorTimeSeries `tfsdk:"time_series" tf:"optional,object"` + TimeSeries types.Object `tfsdk:"time_series" tf:"optional,object"` // Optional argument to specify the warehouse for dashboard creation. If not // specified, the first running warehouse will be used. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` @@ -820,10 +1028,23 @@ func (newState *CreateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateMonitor) SyncEffectiveFieldsDuringRead(existingState CreateMonitor) { } +func (a CreateMonitor) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CustomMetrics": reflect.TypeOf(MonitorMetric{}), + "DataClassificationConfig": reflect.TypeOf(MonitorDataClassificationConfig{}), + "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), + "Notifications": reflect.TypeOf(MonitorNotifications{}), + "Schedule": reflect.TypeOf(MonitorCronSchedule{}), + "SlicingExprs": reflect.TypeOf(""), + "Snapshot": reflect.TypeOf(MonitorSnapshot{}), + "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), + } +} + // Create an Online Table type CreateOnlineTableRequest struct { // Online Table information. - Table []OnlineTable `tfsdk:"table" tf:"optional,object"` + Table types.Object `tfsdk:"table" tf:"optional,object"` } func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateOnlineTableRequest) { @@ -832,6 +1053,12 @@ func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState CreateOnlineTableRequest) { } +func (a CreateOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Table": reflect.TypeOf(OnlineTable{}), + } +} + type CreateRegisteredModelRequest struct { // The name of the catalog where the schema and the registered model reside CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -852,6 +1079,10 @@ func (newState *CreateRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *CreateRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState CreateRegisteredModelRequest) { } +func (a CreateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateResponse struct { } @@ -861,6 +1092,10 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateSchema struct { // Name of parent catalog. CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -869,7 +1104,7 @@ type CreateSchema struct { // Name of schema, relative to parent catalog. Name types.String `tfsdk:"name" tf:""` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` // Storage root URL for managed tables within schema. StorageRoot types.String `tfsdk:"storage_root" tf:"optional"` } @@ -880,15 +1115,21 @@ func (newState *CreateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreateSchema) SyncEffectiveFieldsDuringRead(existingState CreateSchema) { } +func (a CreateSchema) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Properties": reflect.TypeOf(""), + } +} + type CreateStorageCredential struct { // The AWS IAM role configuration. - AwsIamRole []AwsIamRoleRequest `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentityRequest `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken []CloudflareApiToken `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // The Databricks managed GCP service account configuration. @@ -908,11 +1149,21 @@ func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringRead(existingState CreateStorageCredential) { } +func (a CreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRoleRequest{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityRequest{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), + "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), + } +} + type CreateTableConstraint struct { // A table constraint, as defined by *one* of the following fields being // set: __primary_key_constraint__, __foreign_key_constraint__, // __named_table_constraint__. - Constraint []TableConstraint `tfsdk:"constraint" tf:"object"` + Constraint types.Object `tfsdk:"constraint" tf:"object"` // The full name of the table referenced by the constraint. FullNameArg types.String `tfsdk:"full_name_arg" tf:""` } @@ -923,6 +1174,12 @@ func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringRead(existingState CreateTableConstraint) { } +func (a CreateTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Constraint": reflect.TypeOf(TableConstraint{}), + } +} + type CreateVolumeRequestContent struct { // The name of the catalog where the schema and the volume are CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -944,13 +1201,17 @@ func (newState *CreateVolumeRequestContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateVolumeRequestContent) SyncEffectiveFieldsDuringRead(existingState CreateVolumeRequestContent) { } +func (a CreateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CredentialInfo struct { // The AWS IAM role configuration - AwsIamRole []AwsIamRole `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentity `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // Time at which this credential was created, in epoch milliseconds. @@ -991,6 +1252,14 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState CredentialInfo) { } +func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRole{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + } +} + type CredentialValidationResult struct { // Error message would exist when the result does not equal to **PASS**. Message types.String `tfsdk:"message" tf:"optional"` @@ -1004,10 +1273,14 @@ func (newState *CredentialValidationResult) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CredentialValidationResult) SyncEffectiveFieldsDuringRead(existingState CredentialValidationResult) { } +func (a CredentialValidationResult) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Currently assigned workspaces type CurrentWorkspaceBindings struct { // A list of workspace IDs. - Workspaces []types.Int64 `tfsdk:"workspaces" tf:"optional"` + Workspaces types.List `tfsdk:"workspaces" tf:"optional"` } func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdate(plan CurrentWorkspaceBindings) { @@ -1016,6 +1289,12 @@ func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingState CurrentWorkspaceBindings) { } +func (a CurrentWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Workspaces": reflect.TypeOf(0), + } +} + type DatabricksGcpServiceAccountRequest struct { } @@ -1025,6 +1304,10 @@ func (newState *DatabricksGcpServiceAccountRequest) SyncEffectiveFieldsDuringCre func (newState *DatabricksGcpServiceAccountRequest) SyncEffectiveFieldsDuringRead(existingState DatabricksGcpServiceAccountRequest) { } +func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DatabricksGcpServiceAccountResponse struct { // The Databricks internal ID that represents this service account. This is // an output-only field. @@ -1039,6 +1322,10 @@ func (newState *DatabricksGcpServiceAccountResponse) SyncEffectiveFieldsDuringCr func (newState *DatabricksGcpServiceAccountResponse) SyncEffectiveFieldsDuringRead(existingState DatabricksGcpServiceAccountResponse) { } +func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a metastore assignment type DeleteAccountMetastoreAssignmentRequest struct { // Unity Catalog metastore ID @@ -1053,6 +1340,10 @@ func (newState *DeleteAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuri func (newState *DeleteAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountMetastoreAssignmentRequest) { } +func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a metastore type DeleteAccountMetastoreRequest struct { // Force deletion even if the metastore is not empty. Default is false. @@ -1067,6 +1358,10 @@ func (newState *DeleteAccountMetastoreRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteAccountMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountMetastoreRequest) { } +func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a storage credential type DeleteAccountStorageCredentialRequest struct { // Force deletion even if the Storage Credential is not empty. Default is @@ -1084,6 +1379,10 @@ func (newState *DeleteAccountStorageCredentialRequest) SyncEffectiveFieldsDuring func (newState *DeleteAccountStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountStorageCredentialRequest) { } +func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a Registered Model Alias type DeleteAliasRequest struct { // The name of the alias @@ -1098,6 +1397,10 @@ func (newState *DeleteAliasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteAliasRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAliasRequest) { } +func (a DeleteAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteAliasResponse struct { } @@ -1107,6 +1410,10 @@ func (newState *DeleteAliasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteAliasResponse) SyncEffectiveFieldsDuringRead(existingState DeleteAliasResponse) { } +func (a DeleteAliasResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a catalog type DeleteCatalogRequest struct { // Force deletion even if the catalog is not empty. @@ -1121,6 +1428,10 @@ func (newState *DeleteCatalogRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteCatalogRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCatalogRequest) { } +func (a DeleteCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a connection type DeleteConnectionRequest struct { // The name of the connection to be deleted. @@ -1133,6 +1444,10 @@ func (newState *DeleteConnectionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteConnectionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteConnectionRequest) { } +func (a DeleteConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a credential type DeleteCredentialRequest struct { // Force an update even if there are dependent services (when purpose is @@ -1149,6 +1464,10 @@ func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialRequest) { } +func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteCredentialResponse struct { } @@ -1158,6 +1477,10 @@ func (newState *DeleteCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteCredentialResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialResponse) { } +func (a DeleteCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete an external location type DeleteExternalLocationRequest struct { // Force deletion even if there are dependent external tables or mounts. @@ -1172,6 +1495,10 @@ func (newState *DeleteExternalLocationRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteExternalLocationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExternalLocationRequest) { } +func (a DeleteExternalLocationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a function type DeleteFunctionRequest struct { // Force deletion even if the function is notempty. @@ -1187,6 +1514,10 @@ func (newState *DeleteFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteFunctionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFunctionRequest) { } +func (a DeleteFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a metastore type DeleteMetastoreRequest struct { // Force deletion even if the metastore is not empty. Default is false. @@ -1201,6 +1532,10 @@ func (newState *DeleteMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState DeleteMetastoreRequest) { } +func (a DeleteMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a Model Version type DeleteModelVersionRequest struct { // The three-level (fully qualified) name of the model version @@ -1215,6 +1550,10 @@ func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionRequest) { } +func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete an Online Table type DeleteOnlineTableRequest struct { // Full three-part (catalog, schema, table) name of the table. @@ -1227,6 +1566,10 @@ func (newState *DeleteOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteOnlineTableRequest) { } +func (a DeleteOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a table monitor type DeleteQualityMonitorRequest struct { // Full name of the table. @@ -1239,6 +1582,10 @@ func (newState *DeleteQualityMonitorRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *DeleteQualityMonitorRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQualityMonitorRequest) { } +func (a DeleteQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a Registered Model type DeleteRegisteredModelRequest struct { // The three-level (fully qualified) name of the registered model @@ -1251,6 +1598,10 @@ func (newState *DeleteRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRegisteredModelRequest) { } +func (a DeleteRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -1260,6 +1611,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a schema type DeleteSchemaRequest struct { // Force deletion even if the schema is not empty. @@ -1274,6 +1629,10 @@ func (newState *DeleteSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteSchemaRequest) SyncEffectiveFieldsDuringRead(existingState DeleteSchemaRequest) { } +func (a DeleteSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a credential type DeleteStorageCredentialRequest struct { // Force deletion even if there are dependent external locations or external @@ -1289,6 +1648,10 @@ func (newState *DeleteStorageCredentialRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteStorageCredentialRequest) { } +func (a DeleteStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a table constraint type DeleteTableConstraintRequest struct { // If true, try deleting all child constraints of the current constraint. If @@ -1307,6 +1670,10 @@ func (newState *DeleteTableConstraintRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteTableConstraintRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableConstraintRequest) { } +func (a DeleteTableConstraintRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a table type DeleteTableRequest struct { // Full name of the table. @@ -1319,6 +1686,10 @@ func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableRequest) { } +func (a DeleteTableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a Volume type DeleteVolumeRequest struct { // The three-level (fully qualified) name of the volume @@ -1331,12 +1702,16 @@ func (newState *DeleteVolumeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteVolumeRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVolumeRequest) { } +func (a DeleteVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Properties pertaining to the current state of the delta table as given by the // commit server. This does not contain **delta.*** (input) properties in // __TableInfo.properties__. type DeltaRuntimePropertiesKvPairs struct { // A map of key-value properties attached to the securable. - DeltaRuntimeProperties map[string]types.String `tfsdk:"delta_runtime_properties" tf:""` + DeltaRuntimeProperties types.Map `tfsdk:"delta_runtime_properties" tf:""` } func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeltaRuntimePropertiesKvPairs) { @@ -1345,13 +1720,19 @@ func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOr func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existingState DeltaRuntimePropertiesKvPairs) { } +func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DeltaRuntimeProperties": reflect.TypeOf(""), + } +} + // A dependency of a SQL object. Either the __table__ field or the __function__ // field must be defined. type Dependency struct { // A function that is dependent on a SQL object. - Function []FunctionDependency `tfsdk:"function" tf:"optional,object"` + Function types.Object `tfsdk:"function" tf:"optional,object"` // A table that is dependent on a SQL object. - Table []TableDependency `tfsdk:"table" tf:"optional,object"` + Table types.Object `tfsdk:"table" tf:"optional,object"` } func (newState *Dependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dependency) { @@ -1360,10 +1741,17 @@ func (newState *Dependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Depende func (newState *Dependency) SyncEffectiveFieldsDuringRead(existingState Dependency) { } +func (a Dependency) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Function": reflect.TypeOf(FunctionDependency{}), + "Table": reflect.TypeOf(TableDependency{}), + } +} + // A list of dependencies. type DependencyList struct { // Array of dependencies. - Dependencies []Dependency `tfsdk:"dependencies" tf:"optional"` + Dependencies types.List `tfsdk:"dependencies" tf:"optional"` } func (newState *DependencyList) SyncEffectiveFieldsDuringCreateOrUpdate(plan DependencyList) { @@ -1372,6 +1760,12 @@ func (newState *DependencyList) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dep func (newState *DependencyList) SyncEffectiveFieldsDuringRead(existingState DependencyList) { } +func (a DependencyList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dependencies": reflect.TypeOf(Dependency{}), + } +} + // Disable a system schema type DisableRequest struct { // The metastore ID under which the system schema lives. @@ -1386,6 +1780,10 @@ func (newState *DisableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dis func (newState *DisableRequest) SyncEffectiveFieldsDuringRead(existingState DisableRequest) { } +func (a DisableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DisableResponse struct { } @@ -1395,10 +1793,14 @@ func (newState *DisableResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Di func (newState *DisableResponse) SyncEffectiveFieldsDuringRead(existingState DisableResponse) { } +func (a DisableResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EffectivePermissionsList struct { // The privileges conveyed to each principal (either directly or via // inheritance) - PrivilegeAssignments []EffectivePrivilegeAssignment `tfsdk:"privilege_assignments" tf:"optional"` + PrivilegeAssignments types.List `tfsdk:"privilege_assignments" tf:"optional"` } func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringCreateOrUpdate(plan EffectivePermissionsList) { @@ -1407,6 +1809,12 @@ func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringRead(existingState EffectivePermissionsList) { } +func (a EffectivePermissionsList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PrivilegeAssignments": reflect.TypeOf(EffectivePrivilegeAssignment{}), + } +} + type EffectivePredictiveOptimizationFlag struct { // The name of the object from which the flag was inherited. If there was no // inheritance, this field is left blank. @@ -1425,6 +1833,10 @@ func (newState *EffectivePredictiveOptimizationFlag) SyncEffectiveFieldsDuringCr func (newState *EffectivePredictiveOptimizationFlag) SyncEffectiveFieldsDuringRead(existingState EffectivePredictiveOptimizationFlag) { } +func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EffectivePrivilege struct { // The full name of the object that conveys this privilege via inheritance. // This field is omitted when privilege is not inherited (it's assigned to @@ -1444,12 +1856,16 @@ func (newState *EffectivePrivilege) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EffectivePrivilege) SyncEffectiveFieldsDuringRead(existingState EffectivePrivilege) { } +func (a EffectivePrivilege) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EffectivePrivilegeAssignment struct { // The principal (user email address or group name). Principal types.String `tfsdk:"principal" tf:"optional"` // The privileges conveyed to the principal (either directly or via // inheritance). - Privileges []EffectivePrivilege `tfsdk:"privileges" tf:"optional"` + Privileges types.List `tfsdk:"privileges" tf:"optional"` } func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan EffectivePrivilegeAssignment) { @@ -1458,6 +1874,12 @@ func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrU func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState EffectivePrivilegeAssignment) { } +func (a EffectivePrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Privileges": reflect.TypeOf(EffectivePrivilege{}), + } +} + // Enable a system schema type EnableRequest struct { // The metastore ID under which the system schema lives. @@ -1472,6 +1894,10 @@ func (newState *EnableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Enab func (newState *EnableRequest) SyncEffectiveFieldsDuringRead(existingState EnableRequest) { } +func (a EnableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EnableResponse struct { } @@ -1481,10 +1907,14 @@ func (newState *EnableResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ena func (newState *EnableResponse) SyncEffectiveFieldsDuringRead(existingState EnableResponse) { } +func (a EnableResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Encryption options that apply to clients connecting to cloud storage. type EncryptionDetails struct { // Server-Side Encryption properties for clients communicating with AWS s3. - SseEncryptionDetails []SseEncryptionDetails `tfsdk:"sse_encryption_details" tf:"optional,object"` + SseEncryptionDetails types.Object `tfsdk:"sse_encryption_details" tf:"optional,object"` } func (newState *EncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan EncryptionDetails) { @@ -1493,6 +1923,12 @@ func (newState *EncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EncryptionDetails) SyncEffectiveFieldsDuringRead(existingState EncryptionDetails) { } +func (a EncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SseEncryptionDetails": reflect.TypeOf(SseEncryptionDetails{}), + } +} + // Get boolean reflecting if table exists type ExistsRequest struct { // Full name of the table. @@ -1505,6 +1941,10 @@ func (newState *ExistsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exis func (newState *ExistsRequest) SyncEffectiveFieldsDuringRead(existingState ExistsRequest) { } +func (a ExistsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExternalLocationInfo struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -1523,7 +1963,7 @@ type ExternalLocationInfo struct { // Name of the storage credential used with this location. CredentialName types.String `tfsdk:"credential_name" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails []EncryptionDetails `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` // Indicates whether fallback mode is enabled for this external location. // When fallback mode is enabled, the access to the location falls back to // cluster credentials if UC credentials are not sufficient. @@ -1553,6 +1993,12 @@ func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringRead(existingState ExternalLocationInfo) { } +func (a ExternalLocationInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + } +} + // Detailed status of an online table. Shown if the online table is in the // OFFLINE_FAILED or the ONLINE_PIPELINE_FAILED state. type FailedStatus struct { @@ -1573,13 +2019,17 @@ func (newState *FailedStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Faile func (newState *FailedStatus) SyncEffectiveFieldsDuringRead(existingState FailedStatus) { } +func (a FailedStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ForeignKeyConstraint struct { // Column names for this constraint. - ChildColumns []types.String `tfsdk:"child_columns" tf:""` + ChildColumns types.List `tfsdk:"child_columns" tf:""` // The name of the constraint. Name types.String `tfsdk:"name" tf:""` // Column names for this constraint. - ParentColumns []types.String `tfsdk:"parent_columns" tf:""` + ParentColumns types.List `tfsdk:"parent_columns" tf:""` // The full name of the parent constraint. ParentTable types.String `tfsdk:"parent_table" tf:""` } @@ -1590,6 +2040,13 @@ func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringRead(existingState ForeignKeyConstraint) { } +func (a ForeignKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ChildColumns": reflect.TypeOf(""), + "ParentColumns": reflect.TypeOf(""), + } +} + // A function that is dependent on a SQL object. type FunctionDependency struct { // Full name of the dependent function, in the form of @@ -1603,6 +2060,10 @@ func (newState *FunctionDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *FunctionDependency) SyncEffectiveFieldsDuringRead(existingState FunctionDependency) { } +func (a FunctionDependency) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FunctionInfo struct { // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is @@ -1630,7 +2091,7 @@ type FunctionInfo struct { // Id of Function, relative to parent schema. FunctionId types.String `tfsdk:"function_id" tf:"optional"` - InputParams []FunctionParameterInfos `tfsdk:"input_params" tf:"optional,object"` + InputParams types.Object `tfsdk:"input_params" tf:"optional,object"` // Whether the function is deterministic. IsDeterministic types.Bool `tfsdk:"is_deterministic" tf:"optional"` // Function null call. @@ -1646,7 +2107,7 @@ type FunctionInfo struct { // JSON-serialized key-value pair map, encoded (escaped) as a string. Properties types.String `tfsdk:"properties" tf:"optional"` // Table function return parameters. - ReturnParams []FunctionParameterInfos `tfsdk:"return_params" tf:"optional,object"` + ReturnParams types.Object `tfsdk:"return_params" tf:"optional,object"` // Function language. When **EXTERNAL** is used, the language of the routine // function should be specified in the __external_language__ field, and the // __return_params__ of the function cannot be used (as **TABLE** return @@ -1656,7 +2117,7 @@ type FunctionInfo struct { // Function body. RoutineDefinition types.String `tfsdk:"routine_definition" tf:"optional"` // Function dependencies. - RoutineDependencies []DependencyList `tfsdk:"routine_dependencies" tf:"optional,object"` + RoutineDependencies types.Object `tfsdk:"routine_dependencies" tf:"optional,object"` // Name of parent schema relative to its parent catalog. SchemaName types.String `tfsdk:"schema_name" tf:"optional"` // Function security type. @@ -1679,6 +2140,14 @@ func (newState *FunctionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Funct func (newState *FunctionInfo) SyncEffectiveFieldsDuringRead(existingState FunctionInfo) { } +func (a FunctionInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InputParams": reflect.TypeOf(FunctionParameterInfos{}), + "ReturnParams": reflect.TypeOf(FunctionParameterInfos{}), + "RoutineDependencies": reflect.TypeOf(DependencyList{}), + } +} + type FunctionParameterInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1712,10 +2181,14 @@ func (newState *FunctionParameterInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *FunctionParameterInfo) SyncEffectiveFieldsDuringRead(existingState FunctionParameterInfo) { } +func (a FunctionParameterInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FunctionParameterInfos struct { // The array of __FunctionParameterInfo__ definitions of the function's // parameters. - Parameters []FunctionParameterInfo `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` } func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringCreateOrUpdate(plan FunctionParameterInfos) { @@ -1724,6 +2197,12 @@ func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringRead(existingState FunctionParameterInfos) { } +func (a FunctionParameterInfos) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(FunctionParameterInfo{}), + } +} + // GCP temporary credentials for API authentication. Read more at // https://developers.google.com/identity/protocols/oauth2/service-account type GcpOauthToken struct { @@ -1736,6 +2215,10 @@ func (newState *GcpOauthToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpO func (newState *GcpOauthToken) SyncEffectiveFieldsDuringRead(existingState GcpOauthToken) { } +func (a GcpOauthToken) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // GCP long-lived credential. GCP Service Account. type GcpServiceAccountKey struct { // The email of the service account. [Create:REQ Update:OPT]. @@ -1752,12 +2235,16 @@ func (newState *GcpServiceAccountKey) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GcpServiceAccountKey) SyncEffectiveFieldsDuringRead(existingState GcpServiceAccountKey) { } +func (a GcpServiceAccountKey) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Options to customize the requested temporary credential type GenerateTemporaryServiceCredentialAzureOptions struct { // The resources to which the temporary Azure credential should apply. These // resources are the scopes that are passed to the token provider (see // https://learn.microsoft.com/python/api/azure-core/azure.core.credentials.tokencredential?view=azure-python) - Resources []types.String `tfsdk:"resources" tf:"optional"` + Resources types.List `tfsdk:"resources" tf:"optional"` } func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan GenerateTemporaryServiceCredentialAzureOptions) { @@ -1766,9 +2253,15 @@ func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFie func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryServiceCredentialAzureOptions) { } +func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Resources": reflect.TypeOf(""), + } +} + type GenerateTemporaryServiceCredentialRequest struct { // Options to customize the requested temporary credential - AzureOptions []GenerateTemporaryServiceCredentialAzureOptions `tfsdk:"azure_options" tf:"optional,object"` + AzureOptions types.Object `tfsdk:"azure_options" tf:"optional,object"` // The name of the service credential used to generate a temporary // credential CredentialName types.String `tfsdk:"credential_name" tf:""` @@ -1780,6 +2273,12 @@ func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDu func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryServiceCredentialRequest) { } +func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AzureOptions": reflect.TypeOf(GenerateTemporaryServiceCredentialAzureOptions{}), + } +} + type GenerateTemporaryTableCredentialRequest struct { // The operation performed against the table data, either READ or // READ_WRITE. If READ_WRITE is specified, the credentials returned will @@ -1795,26 +2294,30 @@ func (newState *GenerateTemporaryTableCredentialRequest) SyncEffectiveFieldsDuri func (newState *GenerateTemporaryTableCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryTableCredentialRequest) { } +func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GenerateTemporaryTableCredentialResponse struct { // AWS temporary credentials for API authentication. Read more at // https://docs.aws.amazon.com/STS/latest/APIReference/API_Credentials.html. - AwsTempCredentials []AwsCredentials `tfsdk:"aws_temp_credentials" tf:"optional,object"` + AwsTempCredentials types.Object `tfsdk:"aws_temp_credentials" tf:"optional,object"` // Azure Active Directory token, essentially the Oauth token for Azure // Service Principal or Managed Identity. Read more at // https://learn.microsoft.com/en-us/azure/databricks/dev-tools/api/latest/aad/service-prin-aad-token - AzureAad []AzureActiveDirectoryToken `tfsdk:"azure_aad" tf:"optional,object"` + AzureAad types.Object `tfsdk:"azure_aad" tf:"optional,object"` // Azure temporary credentials for API authentication. Read more at // https://docs.microsoft.com/en-us/rest/api/storageservices/create-user-delegation-sas - AzureUserDelegationSas []AzureUserDelegationSas `tfsdk:"azure_user_delegation_sas" tf:"optional,object"` + AzureUserDelegationSas types.Object `tfsdk:"azure_user_delegation_sas" tf:"optional,object"` // Server time when the credential will expire, in epoch milliseconds. The // API client is advised to cache the credential given this expiration time. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` // GCP temporary credentials for API authentication. Read more at // https://developers.google.com/identity/protocols/oauth2/service-account - GcpOauthToken []GcpOauthToken `tfsdk:"gcp_oauth_token" tf:"optional,object"` + GcpOauthToken types.Object `tfsdk:"gcp_oauth_token" tf:"optional,object"` // R2 temporary credentials for API authentication. Read more at // https://developers.cloudflare.com/r2/api/s3/tokens/. - R2TempCredentials []R2Credentials `tfsdk:"r2_temp_credentials" tf:"optional,object"` + R2TempCredentials types.Object `tfsdk:"r2_temp_credentials" tf:"optional,object"` // The URL of the storage path accessible by the temporary credential. Url types.String `tfsdk:"url" tf:"optional"` } @@ -1825,6 +2328,16 @@ func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDur func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryTableCredentialResponse) { } +func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsTempCredentials": reflect.TypeOf(AwsCredentials{}), + "AzureAad": reflect.TypeOf(AzureActiveDirectoryToken{}), + "AzureUserDelegationSas": reflect.TypeOf(AzureUserDelegationSas{}), + "GcpOauthToken": reflect.TypeOf(GcpOauthToken{}), + "R2TempCredentials": reflect.TypeOf(R2Credentials{}), + } +} + // Gets the metastore assignment for a workspace type GetAccountMetastoreAssignmentRequest struct { // Workspace ID. @@ -1837,6 +2350,10 @@ func (newState *GetAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringC func (newState *GetAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountMetastoreAssignmentRequest) { } +func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a metastore type GetAccountMetastoreRequest struct { // Unity Catalog metastore ID @@ -1849,6 +2366,10 @@ func (newState *GetAccountMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetAccountMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountMetastoreRequest) { } +func (a GetAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Gets the named storage credential type GetAccountStorageCredentialRequest struct { // Unity Catalog metastore ID @@ -1863,6 +2384,10 @@ func (newState *GetAccountStorageCredentialRequest) SyncEffectiveFieldsDuringCre func (newState *GetAccountStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountStorageCredentialRequest) { } +func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an artifact allowlist type GetArtifactAllowlistRequest struct { // The artifact type of the allowlist. @@ -1875,6 +2400,10 @@ func (newState *GetArtifactAllowlistRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetArtifactAllowlistRequest) SyncEffectiveFieldsDuringRead(existingState GetArtifactAllowlistRequest) { } +func (a GetArtifactAllowlistRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get securable workspace bindings type GetBindingsRequest struct { // Maximum number of workspace bindings to return. - When set to 0, the page @@ -1898,6 +2427,10 @@ func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringRead(existingState GetBindingsRequest) { } +func (a GetBindingsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get Model Version By Alias type GetByAliasRequest struct { // The name of the alias @@ -1915,6 +2448,10 @@ func (newState *GetByAliasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetByAliasRequest) SyncEffectiveFieldsDuringRead(existingState GetByAliasRequest) { } +func (a GetByAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a catalog type GetCatalogRequest struct { // Whether to include catalogs in the response for which the principal can @@ -1930,6 +2467,10 @@ func (newState *GetCatalogRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetCatalogRequest) SyncEffectiveFieldsDuringRead(existingState GetCatalogRequest) { } +func (a GetCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a connection type GetConnectionRequest struct { // Name of the connection. @@ -1942,6 +2483,10 @@ func (newState *GetConnectionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetConnectionRequest) SyncEffectiveFieldsDuringRead(existingState GetConnectionRequest) { } +func (a GetConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a credential type GetCredentialRequest struct { // Name of the credential. @@ -1954,6 +2499,10 @@ func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialRequest) { } +func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get effective permissions type GetEffectiveRequest struct { // Full name of securable. @@ -1971,6 +2520,10 @@ func (newState *GetEffectiveRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetEffectiveRequest) SyncEffectiveFieldsDuringRead(existingState GetEffectiveRequest) { } +func (a GetEffectiveRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an external location type GetExternalLocationRequest struct { // Whether to include external locations in the response for which the @@ -1986,6 +2539,10 @@ func (newState *GetExternalLocationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetExternalLocationRequest) SyncEffectiveFieldsDuringRead(existingState GetExternalLocationRequest) { } +func (a GetExternalLocationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a function type GetFunctionRequest struct { // Whether to include functions in the response for which the principal can @@ -2002,6 +2559,10 @@ func (newState *GetFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetFunctionRequest) SyncEffectiveFieldsDuringRead(existingState GetFunctionRequest) { } +func (a GetFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get permissions type GetGrantRequest struct { // Full name of securable. @@ -2019,6 +2580,10 @@ func (newState *GetGrantRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetGrantRequest) SyncEffectiveFieldsDuringRead(existingState GetGrantRequest) { } +func (a GetGrantRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a metastore type GetMetastoreRequest struct { // Unique ID of the metastore. @@ -2031,6 +2596,10 @@ func (newState *GetMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState GetMetastoreRequest) { } +func (a GetMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetMetastoreSummaryResponse struct { // Cloud vendor of the metastore home shard (e.g., `aws`, `azure`, `gcp`). Cloud types.String `tfsdk:"cloud" tf:"optional"` @@ -2082,6 +2651,10 @@ func (newState *GetMetastoreSummaryResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetMetastoreSummaryResponse) SyncEffectiveFieldsDuringRead(existingState GetMetastoreSummaryResponse) { } +func (a GetMetastoreSummaryResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a Model Version type GetModelVersionRequest struct { // The three-level (fully qualified) name of the model version @@ -2102,6 +2675,10 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionRequest) { } +func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an Online Table type GetOnlineTableRequest struct { // Full three-part (catalog, schema, table) name of the table. @@ -2114,6 +2691,10 @@ func (newState *GetOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState GetOnlineTableRequest) { } +func (a GetOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a table monitor type GetQualityMonitorRequest struct { // Full name of the table. @@ -2126,6 +2707,10 @@ func (newState *GetQualityMonitorRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetQualityMonitorRequest) SyncEffectiveFieldsDuringRead(existingState GetQualityMonitorRequest) { } +func (a GetQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get information for a single resource quota. type GetQuotaRequest struct { // Full name of the parent resource. Provide the metastore ID if the parent @@ -2144,9 +2729,13 @@ func (newState *GetQuotaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetQuotaRequest) SyncEffectiveFieldsDuringRead(existingState GetQuotaRequest) { } +func (a GetQuotaRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetQuotaResponse struct { // The returned QuotaInfo. - QuotaInfo []QuotaInfo `tfsdk:"quota_info" tf:"optional,object"` + QuotaInfo types.Object `tfsdk:"quota_info" tf:"optional,object"` } func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetQuotaResponse) { @@ -2155,6 +2744,12 @@ func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringRead(existingState GetQuotaResponse) { } +func (a GetQuotaResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "QuotaInfo": reflect.TypeOf(QuotaInfo{}), + } +} + // Get refresh type GetRefreshRequest struct { // ID of the refresh. @@ -2169,6 +2764,10 @@ func (newState *GetRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetRefreshRequest) SyncEffectiveFieldsDuringRead(existingState GetRefreshRequest) { } +func (a GetRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a Registered Model type GetRegisteredModelRequest struct { // The three-level (fully qualified) name of the registered model @@ -2186,6 +2785,10 @@ func (newState *GetRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelRequest) { } +func (a GetRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a schema type GetSchemaRequest struct { // Full name of the schema. @@ -2201,6 +2804,10 @@ func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringRead(existingState GetSchemaRequest) { } +func (a GetSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a credential type GetStorageCredentialRequest struct { // Name of the storage credential. @@ -2213,6 +2820,10 @@ func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetStorageCredentialRequest) { } +func (a GetStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a table type GetTableRequest struct { // Full name of the table. @@ -2232,6 +2843,10 @@ func (newState *GetTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetTableRequest) SyncEffectiveFieldsDuringRead(existingState GetTableRequest) { } +func (a GetTableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get catalog workspace bindings type GetWorkspaceBindingRequest struct { // The name of the catalog. @@ -2244,6 +2859,10 @@ func (newState *GetWorkspaceBindingRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetWorkspaceBindingRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceBindingRequest) { } +func (a GetWorkspaceBindingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get all workspaces assigned to a metastore type ListAccountMetastoreAssignmentsRequest struct { // Unity Catalog metastore ID @@ -2256,9 +2875,13 @@ func (newState *ListAccountMetastoreAssignmentsRequest) SyncEffectiveFieldsDurin func (newState *ListAccountMetastoreAssignmentsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountMetastoreAssignmentsRequest) { } +func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The list of workspaces to which the given metastore is assigned. type ListAccountMetastoreAssignmentsResponse struct { - WorkspaceIds []types.Int64 `tfsdk:"workspace_ids" tf:"optional"` + WorkspaceIds types.List `tfsdk:"workspace_ids" tf:"optional"` } func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAccountMetastoreAssignmentsResponse) { @@ -2267,6 +2890,12 @@ func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuri func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuringRead(existingState ListAccountMetastoreAssignmentsResponse) { } +func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "WorkspaceIds": reflect.TypeOf(0), + } +} + // Get all storage credentials assigned to a metastore type ListAccountStorageCredentialsRequest struct { // Unity Catalog metastore ID @@ -2279,9 +2908,13 @@ func (newState *ListAccountStorageCredentialsRequest) SyncEffectiveFieldsDuringC func (newState *ListAccountStorageCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountStorageCredentialsRequest) { } +func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAccountStorageCredentialsResponse struct { // An array of metastore storage credentials. - StorageCredentials []StorageCredentialInfo `tfsdk:"storage_credentials" tf:"optional"` + StorageCredentials types.List `tfsdk:"storage_credentials" tf:"optional"` } func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAccountStorageCredentialsResponse) { @@ -2290,6 +2923,12 @@ func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuring func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListAccountStorageCredentialsResponse) { } +func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "StorageCredentials": reflect.TypeOf(StorageCredentialInfo{}), + } +} + // List catalogs type ListCatalogsRequest struct { // Whether to include catalogs in the response for which the principal can @@ -2315,9 +2954,13 @@ func (newState *ListCatalogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListCatalogsRequest) SyncEffectiveFieldsDuringRead(existingState ListCatalogsRequest) { } +func (a ListCatalogsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListCatalogsResponse struct { // An array of catalog information objects. - Catalogs []CatalogInfo `tfsdk:"catalogs" tf:"optional"` + Catalogs types.List `tfsdk:"catalogs" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -2330,6 +2973,12 @@ func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringRead(existingState ListCatalogsResponse) { } +func (a ListCatalogsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Catalogs": reflect.TypeOf(CatalogInfo{}), + } +} + // List connections type ListConnectionsRequest struct { // Maximum number of connections to return. - If not set, all connections @@ -2349,9 +2998,13 @@ func (newState *ListConnectionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListConnectionsRequest) SyncEffectiveFieldsDuringRead(existingState ListConnectionsRequest) { } +func (a ListConnectionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListConnectionsResponse struct { // An array of connection information objects. - Connections []ConnectionInfo `tfsdk:"connections" tf:"optional"` + Connections types.List `tfsdk:"connections" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -2364,6 +3017,12 @@ func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringRead(existingState ListConnectionsResponse) { } +func (a ListConnectionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Connections": reflect.TypeOf(ConnectionInfo{}), + } +} + // List credentials type ListCredentialsRequest struct { // Maximum number of credentials to return. - If not set, the default max @@ -2384,8 +3043,12 @@ func (newState *ListCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListCredentialsRequest) { } +func (a ListCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListCredentialsResponse struct { - Credentials []CredentialInfo `tfsdk:"credentials" tf:"optional"` + Credentials types.List `tfsdk:"credentials" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -2398,6 +3061,12 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListCredentialsResponse) { } +func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Credentials": reflect.TypeOf(CredentialInfo{}), + } +} + // List external locations type ListExternalLocationsRequest struct { // Whether to include external locations in the response for which the @@ -2420,9 +3089,13 @@ func (newState *ListExternalLocationsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListExternalLocationsRequest) SyncEffectiveFieldsDuringRead(existingState ListExternalLocationsRequest) { } +func (a ListExternalLocationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListExternalLocationsResponse struct { // An array of external locations. - ExternalLocations []ExternalLocationInfo `tfsdk:"external_locations" tf:"optional"` + ExternalLocations types.List `tfsdk:"external_locations" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -2435,6 +3108,12 @@ func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringCreateOr func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringRead(existingState ListExternalLocationsResponse) { } +func (a ListExternalLocationsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExternalLocations": reflect.TypeOf(ExternalLocationInfo{}), + } +} + // List functions type ListFunctionsRequest struct { // Name of parent catalog for functions of interest. @@ -2461,9 +3140,13 @@ func (newState *ListFunctionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListFunctionsRequest) SyncEffectiveFieldsDuringRead(existingState ListFunctionsRequest) { } +func (a ListFunctionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListFunctionsResponse struct { // An array of function information objects. - Functions []FunctionInfo `tfsdk:"functions" tf:"optional"` + Functions types.List `tfsdk:"functions" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -2476,9 +3159,15 @@ func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringRead(existingState ListFunctionsResponse) { } +func (a ListFunctionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Functions": reflect.TypeOf(FunctionInfo{}), + } +} + type ListMetastoresResponse struct { // An array of metastore information objects. - Metastores []MetastoreInfo `tfsdk:"metastores" tf:"optional"` + Metastores types.List `tfsdk:"metastores" tf:"optional"` } func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListMetastoresResponse) { @@ -2487,6 +3176,12 @@ func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringRead(existingState ListMetastoresResponse) { } +func (a ListMetastoresResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Metastores": reflect.TypeOf(MetastoreInfo{}), + } +} + // List Model Versions type ListModelVersionsRequest struct { // The full three-level name of the registered model under which to list @@ -2513,8 +3208,12 @@ func (newState *ListModelVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListModelVersionsRequest) SyncEffectiveFieldsDuringRead(existingState ListModelVersionsRequest) { } +func (a ListModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListModelVersionsResponse struct { - ModelVersions []ModelVersionInfo `tfsdk:"model_versions" tf:"optional"` + ModelVersions types.List `tfsdk:"model_versions" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -2527,6 +3226,12 @@ func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringRead(existingState ListModelVersionsResponse) { } +func (a ListModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ModelVersions": reflect.TypeOf(ModelVersionInfo{}), + } +} + // List all resource quotas under a metastore. type ListQuotasRequest struct { // The number of quotas to return. @@ -2541,13 +3246,17 @@ func (newState *ListQuotasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQuotasRequest) SyncEffectiveFieldsDuringRead(existingState ListQuotasRequest) { } +func (a ListQuotasRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListQuotasResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of returned QuotaInfos. - Quotas []QuotaInfo `tfsdk:"quotas" tf:"optional"` + Quotas types.List `tfsdk:"quotas" tf:"optional"` } func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListQuotasResponse) { @@ -2556,6 +3265,12 @@ func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringRead(existingState ListQuotasResponse) { } +func (a ListQuotasResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Quotas": reflect.TypeOf(QuotaInfo{}), + } +} + // List refreshes type ListRefreshesRequest struct { // Full name of the table. @@ -2568,6 +3283,10 @@ func (newState *ListRefreshesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListRefreshesRequest) SyncEffectiveFieldsDuringRead(existingState ListRefreshesRequest) { } +func (a ListRefreshesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List Registered Models type ListRegisteredModelsRequest struct { // The identifier of the catalog under which to list registered models. If @@ -2607,12 +3326,16 @@ func (newState *ListRegisteredModelsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListRegisteredModelsRequest) SyncEffectiveFieldsDuringRead(existingState ListRegisteredModelsRequest) { } +func (a ListRegisteredModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListRegisteredModelsResponse struct { // Opaque token for pagination. Omitted if there are no more results. // page_token should be set to this value for fetching the next page. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - RegisteredModels []RegisteredModelInfo `tfsdk:"registered_models" tf:"optional"` + RegisteredModels types.List `tfsdk:"registered_models" tf:"optional"` } func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListRegisteredModelsResponse) { @@ -2621,6 +3344,12 @@ func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringRead(existingState ListRegisteredModelsResponse) { } +func (a ListRegisteredModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RegisteredModels": reflect.TypeOf(RegisteredModelInfo{}), + } +} + // List schemas type ListSchemasRequest struct { // Parent catalog for schemas of interest. @@ -2645,13 +3374,17 @@ func (newState *ListSchemasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSchemasRequest) SyncEffectiveFieldsDuringRead(existingState ListSchemasRequest) { } +func (a ListSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListSchemasResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of schema information objects. - Schemas []SchemaInfo `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` } func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListSchemasResponse) { @@ -2660,6 +3393,12 @@ func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringRead(existingState ListSchemasResponse) { } +func (a ListSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Schemas": reflect.TypeOf(SchemaInfo{}), + } +} + // List credentials type ListStorageCredentialsRequest struct { // Maximum number of storage credentials to return. If not set, all the @@ -2679,13 +3418,17 @@ func (newState *ListStorageCredentialsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListStorageCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListStorageCredentialsRequest) { } +func (a ListStorageCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListStorageCredentialsResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - StorageCredentials []StorageCredentialInfo `tfsdk:"storage_credentials" tf:"optional"` + StorageCredentials types.List `tfsdk:"storage_credentials" tf:"optional"` } func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListStorageCredentialsResponse) { @@ -2694,6 +3437,12 @@ func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListStorageCredentialsResponse) { } +func (a ListStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "StorageCredentials": reflect.TypeOf(StorageCredentialInfo{}), + } +} + // List table summaries type ListSummariesRequest struct { // Name of parent catalog for tables of interest. @@ -2724,6 +3473,10 @@ func (newState *ListSummariesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListSummariesRequest) SyncEffectiveFieldsDuringRead(existingState ListSummariesRequest) { } +func (a ListSummariesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List system schemas type ListSystemSchemasRequest struct { // Maximum number of schemas to return. - When set to 0, the page length is @@ -2745,13 +3498,17 @@ func (newState *ListSystemSchemasRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListSystemSchemasRequest) SyncEffectiveFieldsDuringRead(existingState ListSystemSchemasRequest) { } +func (a ListSystemSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListSystemSchemasResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of system schema information objects. - Schemas []SystemSchemaInfo `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` } func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListSystemSchemasResponse) { @@ -2760,13 +3517,19 @@ func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringRead(existingState ListSystemSchemasResponse) { } +func (a ListSystemSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Schemas": reflect.TypeOf(SystemSchemaInfo{}), + } +} + type ListTableSummariesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // List of table summaries. - Tables []TableSummary `tfsdk:"tables" tf:"optional"` + Tables types.List `tfsdk:"tables" tf:"optional"` } func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListTableSummariesResponse) { @@ -2775,6 +3538,12 @@ func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringRead(existingState ListTableSummariesResponse) { } +func (a ListTableSummariesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tables": reflect.TypeOf(TableSummary{}), + } +} + // List tables type ListTablesRequest struct { // Name of parent catalog for tables of interest. @@ -2812,13 +3581,17 @@ func (newState *ListTablesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTablesRequest) SyncEffectiveFieldsDuringRead(existingState ListTablesRequest) { } +func (a ListTablesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListTablesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of table information objects. - Tables []TableInfo `tfsdk:"tables" tf:"optional"` + Tables types.List `tfsdk:"tables" tf:"optional"` } func (newState *ListTablesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListTablesResponse) { @@ -2827,6 +3600,12 @@ func (newState *ListTablesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTablesResponse) SyncEffectiveFieldsDuringRead(existingState ListTablesResponse) { } +func (a ListTablesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tables": reflect.TypeOf(TableInfo{}), + } +} + // List Volumes type ListVolumesRequest struct { // The identifier of the catalog @@ -2860,13 +3639,17 @@ func (newState *ListVolumesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListVolumesRequest) SyncEffectiveFieldsDuringRead(existingState ListVolumesRequest) { } +func (a ListVolumesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListVolumesResponseContent struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request to retrieve the next page of results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Volumes []VolumeInfo `tfsdk:"volumes" tf:"optional"` + Volumes types.List `tfsdk:"volumes" tf:"optional"` } func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListVolumesResponseContent) { @@ -2875,6 +3658,12 @@ func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringRead(existingState ListVolumesResponseContent) { } +func (a ListVolumesResponseContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Volumes": reflect.TypeOf(VolumeInfo{}), + } +} + type MetastoreAssignment struct { // The name of the default catalog in the metastore. DefaultCatalogName types.String `tfsdk:"default_catalog_name" tf:"optional"` @@ -2890,6 +3679,10 @@ func (newState *MetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState MetastoreAssignment) { } +func (a MetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MetastoreInfo struct { // Cloud vendor of the metastore home shard (e.g., `aws`, `azure`, `gcp`). Cloud types.String `tfsdk:"cloud" tf:"optional"` @@ -2941,9 +3734,13 @@ func (newState *MetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Meta func (newState *MetastoreInfo) SyncEffectiveFieldsDuringRead(existingState MetastoreInfo) { } +func (a MetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ModelVersionInfo struct { // List of aliases associated with the model version - Aliases []RegisteredModelAlias `tfsdk:"aliases" tf:"optional"` + Aliases types.List `tfsdk:"aliases" tf:"optional"` // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is // enabled in the request. @@ -2964,7 +3761,7 @@ type ModelVersionInfo struct { // parent schema ModelName types.String `tfsdk:"model_name" tf:"optional"` // Model version dependencies, for feature-store packaged models - ModelVersionDependencies []DependencyList `tfsdk:"model_version_dependencies" tf:"optional,object"` + ModelVersionDependencies types.Object `tfsdk:"model_version_dependencies" tf:"optional,object"` // MLflow run ID used when creating the model version, if ``source`` was // generated by an experiment run stored in an MLflow tracking server RunId types.String `tfsdk:"run_id" tf:"optional"` @@ -3000,6 +3797,13 @@ func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan M func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringRead(existingState ModelVersionInfo) { } +func (a ModelVersionInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Aliases": reflect.TypeOf(RegisteredModelAlias{}), + "ModelVersionDependencies": reflect.TypeOf(DependencyList{}), + } +} + type MonitorCronSchedule struct { // Read only field that indicates whether a schedule is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` @@ -3018,6 +3822,10 @@ func (newState *MonitorCronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MonitorCronSchedule) SyncEffectiveFieldsDuringRead(existingState MonitorCronSchedule) { } +func (a MonitorCronSchedule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MonitorDataClassificationConfig struct { // Whether data classification is enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -3029,10 +3837,14 @@ func (newState *MonitorDataClassificationConfig) SyncEffectiveFieldsDuringCreate func (newState *MonitorDataClassificationConfig) SyncEffectiveFieldsDuringRead(existingState MonitorDataClassificationConfig) { } +func (a MonitorDataClassificationConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MonitorDestination struct { // The list of email addresses to send the notification to. A maximum of 5 // email addresses is supported. - EmailAddresses []types.String `tfsdk:"email_addresses" tf:"optional"` + EmailAddresses types.List `tfsdk:"email_addresses" tf:"optional"` } func (newState *MonitorDestination) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorDestination) { @@ -3041,12 +3853,18 @@ func (newState *MonitorDestination) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorDestination) SyncEffectiveFieldsDuringRead(existingState MonitorDestination) { } +func (a MonitorDestination) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EmailAddresses": reflect.TypeOf(""), + } +} + type MonitorInferenceLog struct { // Granularities for aggregating data into time windows based on their // timestamp. Currently the following static granularities are supported: // {``"5 minutes"``, ``"30 minutes"``, ``"1 hour"``, ``"1 day"``, ``" // week(s)"``, ``"1 month"``, ``"1 year"``}. - Granularities []types.String `tfsdk:"granularities" tf:""` + Granularities types.List `tfsdk:"granularities" tf:""` // Optional column that contains the ground truth for the prediction. LabelCol types.String `tfsdk:"label_col" tf:"optional"` // Column that contains the id of the model generating the predictions. @@ -3078,6 +3896,12 @@ func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringRead(existingState MonitorInferenceLog) { } +func (a MonitorInferenceLog) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Granularities": reflect.TypeOf(""), + } +} + type MonitorInfo struct { // The directory to store monitoring assets (e.g. dashboard, metric tables). AssetsDir types.String `tfsdk:"assets_dir" tf:"optional"` @@ -3088,37 +3912,37 @@ type MonitorInfo struct { // Custom metrics to compute on the monitored table. These can be aggregate // metrics, derived metrics (from already computed aggregate metrics), or // drift metrics (comparing metrics across time windows). - CustomMetrics []MonitorMetric `tfsdk:"custom_metrics" tf:"optional"` + CustomMetrics types.List `tfsdk:"custom_metrics" tf:"optional"` // Id of dashboard that visualizes the computed metrics. This can be empty // if the monitor is in PENDING state. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` // The data classification config for the monitor. - DataClassificationConfig []MonitorDataClassificationConfig `tfsdk:"data_classification_config" tf:"optional,object"` + DataClassificationConfig types.Object `tfsdk:"data_classification_config" tf:"optional,object"` // The full name of the drift metrics table. Format: // __catalog_name__.__schema_name__.__table_name__. DriftMetricsTableName types.String `tfsdk:"drift_metrics_table_name" tf:""` // Configuration for monitoring inference logs. - InferenceLog []MonitorInferenceLog `tfsdk:"inference_log" tf:"optional,object"` + InferenceLog types.Object `tfsdk:"inference_log" tf:"optional,object"` // The latest failure message of the monitor (if any). LatestMonitorFailureMsg types.String `tfsdk:"latest_monitor_failure_msg" tf:"optional"` // The version of the monitor config (e.g. 1,2,3). If negative, the monitor // may be corrupted. MonitorVersion types.String `tfsdk:"monitor_version" tf:""` // The notification settings for the monitor. - Notifications []MonitorNotifications `tfsdk:"notifications" tf:"optional,object"` + Notifications types.Object `tfsdk:"notifications" tf:"optional,object"` // Schema where output metric tables are created. OutputSchemaName types.String `tfsdk:"output_schema_name" tf:"optional"` // The full name of the profile metrics table. Format: // __catalog_name__.__schema_name__.__table_name__. ProfileMetricsTableName types.String `tfsdk:"profile_metrics_table_name" tf:""` // The schedule for automatically updating and refreshing metric tables. - Schedule []MonitorCronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // List of column expressions to slice data with for targeted analysis. The // data is grouped by each expression independently, resulting in a separate // slice for each predicate and its complements. For high-cardinality // columns, only the top 100 unique values by frequency will generate // slices. - SlicingExprs []types.String `tfsdk:"slicing_exprs" tf:"optional"` + SlicingExprs types.List `tfsdk:"slicing_exprs" tf:"optional"` // Configuration for monitoring snapshot tables. Snapshot []MonitorSnapshot `tfsdk:"snapshot" tf:"optional,object"` // The status of the monitor. @@ -3127,7 +3951,7 @@ type MonitorInfo struct { // __catalog_name__.__schema_name__.__table_name__. TableName types.String `tfsdk:"table_name" tf:""` // Configuration for monitoring time series tables. - TimeSeries []MonitorTimeSeries `tfsdk:"time_series" tf:"optional,object"` + TimeSeries types.Object `tfsdk:"time_series" tf:"optional,object"` } func (newState *MonitorInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorInfo) { @@ -3136,6 +3960,19 @@ func (newState *MonitorInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Monito func (newState *MonitorInfo) SyncEffectiveFieldsDuringRead(existingState MonitorInfo) { } +func (a MonitorInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CustomMetrics": reflect.TypeOf(MonitorMetric{}), + "DataClassificationConfig": reflect.TypeOf(MonitorDataClassificationConfig{}), + "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), + "Notifications": reflect.TypeOf(MonitorNotifications{}), + "Schedule": reflect.TypeOf(MonitorCronSchedule{}), + "SlicingExprs": reflect.TypeOf(""), + "Snapshot": reflect.TypeOf(MonitorSnapshot{}), + "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), + } +} + type MonitorMetric struct { // Jinja template for a SQL expression that specifies how to compute the // metric. See [create metric definition]. @@ -3145,7 +3982,7 @@ type MonitorMetric struct { // A list of column names in the input table the metric should be computed // for. Can use ``":table"`` to indicate that the metric needs information // from multiple columns. - InputColumns []types.String `tfsdk:"input_columns" tf:""` + InputColumns types.List `tfsdk:"input_columns" tf:""` // Name of the metric in the output tables. Name types.String `tfsdk:"name" tf:""` // The output type of the custom metric. @@ -3169,12 +4006,18 @@ func (newState *MonitorMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan Moni func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState MonitorMetric) { } +func (a MonitorMetric) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InputColumns": reflect.TypeOf(""), + } +} + type MonitorNotifications struct { // Who to send notifications to on monitor failure. - OnFailure []MonitorDestination `tfsdk:"on_failure" tf:"optional,object"` + OnFailure types.Object `tfsdk:"on_failure" tf:"optional,object"` // Who to send notifications to when new data classification tags are // detected. - OnNewClassificationTagDetected []MonitorDestination `tfsdk:"on_new_classification_tag_detected" tf:"optional,object"` + OnNewClassificationTagDetected types.Object `tfsdk:"on_new_classification_tag_detected" tf:"optional,object"` } func (newState *MonitorNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorNotifications) { @@ -3183,6 +4026,13 @@ func (newState *MonitorNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *MonitorNotifications) SyncEffectiveFieldsDuringRead(existingState MonitorNotifications) { } +func (a MonitorNotifications) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OnFailure": reflect.TypeOf(MonitorDestination{}), + "OnNewClassificationTagDetected": reflect.TypeOf(MonitorDestination{}), + } +} + type MonitorRefreshInfo struct { // Time at which refresh operation completed (milliseconds since 1/1/1970 // UTC). @@ -3207,9 +4057,13 @@ func (newState *MonitorRefreshInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorRefreshInfo) SyncEffectiveFieldsDuringRead(existingState MonitorRefreshInfo) { } +func (a MonitorRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MonitorRefreshListResponse struct { // List of refreshes. - Refreshes []MonitorRefreshInfo `tfsdk:"refreshes" tf:"optional"` + Refreshes types.List `tfsdk:"refreshes" tf:"optional"` } func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorRefreshListResponse) { @@ -3218,6 +4072,12 @@ func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringRead(existingState MonitorRefreshListResponse) { } +func (a MonitorRefreshListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Refreshes": reflect.TypeOf(MonitorRefreshInfo{}), + } +} + type MonitorSnapshot struct { } @@ -3227,12 +4087,16 @@ func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringRead(existingState MonitorSnapshot) { } +func (a MonitorSnapshot) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MonitorTimeSeries struct { // Granularities for aggregating data into time windows based on their // timestamp. Currently the following static granularities are supported: // {``"5 minutes"``, ``"30 minutes"``, ``"1 hour"``, ``"1 day"``, ``" // week(s)"``, ``"1 month"``, ``"1 year"``}. - Granularities []types.String `tfsdk:"granularities" tf:""` + Granularities types.List `tfsdk:"granularities" tf:""` // Column that contains the timestamps of requests. The column must be one // of the following: - A ``TimestampType`` column - A column whose values // can be converted to timestamps through the pyspark ``to_timestamp`` @@ -3248,6 +4112,12 @@ func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringRead(existingState MonitorTimeSeries) { } +func (a MonitorTimeSeries) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Granularities": reflect.TypeOf(""), + } +} + type NamedTableConstraint struct { // The name of the constraint. Name types.String `tfsdk:"name" tf:""` @@ -3259,14 +4129,18 @@ func (newState *NamedTableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *NamedTableConstraint) SyncEffectiveFieldsDuringRead(existingState NamedTableConstraint) { } +func (a NamedTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Online Table information. type OnlineTable struct { // Full three-part (catalog, schema, table) name of the table. Name types.String `tfsdk:"name" tf:"optional"` // Specification of the online table. - Spec []OnlineTableSpec `tfsdk:"spec" tf:"optional,object"` + Spec types.Object `tfsdk:"spec" tf:"optional,object"` // Online Table data synchronization status - Status []OnlineTableStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // Data serving REST API URL for this table TableServingUrl types.String `tfsdk:"table_serving_url" tf:"computed,optional"` // The provisioning state of the online table entity in Unity Catalog. This @@ -3282,6 +4156,13 @@ func (newState *OnlineTable) SyncEffectiveFieldsDuringCreateOrUpdate(plan Online func (newState *OnlineTable) SyncEffectiveFieldsDuringRead(existingState OnlineTable) { } +func (a OnlineTable) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Spec": reflect.TypeOf(OnlineTableSpec{}), + "Status": reflect.TypeOf(OnlineTableStatus{}), + } +} + // Specification of an online table. type OnlineTableSpec struct { // Whether to create a full-copy pipeline -- a pipeline that stops after @@ -3296,7 +4177,7 @@ type OnlineTableSpec struct { // the caller. PipelineId types.String `tfsdk:"pipeline_id" tf:"computed,optional"` // Primary Key columns to be used for data insert/update in the destination. - PrimaryKeyColumns []types.String `tfsdk:"primary_key_columns" tf:"optional"` + PrimaryKeyColumns types.List `tfsdk:"primary_key_columns" tf:"optional"` // Pipeline runs continuously after generating the initial data. RunContinuously []OnlineTableSpecContinuousSchedulingPolicy `tfsdk:"run_continuously" tf:"optional,object"` // Pipeline stops after generating the initial data and can be triggered @@ -3315,6 +4196,14 @@ func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan On func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpec) { } +func (a OnlineTableSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PrimaryKeyColumns": reflect.TypeOf(""), + "RunContinuously": reflect.TypeOf(OnlineTableSpecContinuousSchedulingPolicy{}), + "RunTriggered": reflect.TypeOf(OnlineTableSpecTriggeredSchedulingPolicy{}), + } +} + type OnlineTableSpecContinuousSchedulingPolicy struct { } @@ -3324,6 +4213,10 @@ func (newState *OnlineTableSpecContinuousSchedulingPolicy) SyncEffectiveFieldsDu func (newState *OnlineTableSpecContinuousSchedulingPolicy) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpecContinuousSchedulingPolicy) { } +func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type OnlineTableSpecTriggeredSchedulingPolicy struct { } @@ -3333,25 +4226,29 @@ func (newState *OnlineTableSpecTriggeredSchedulingPolicy) SyncEffectiveFieldsDur func (newState *OnlineTableSpecTriggeredSchedulingPolicy) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpecTriggeredSchedulingPolicy) { } +func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Status of an online table. type OnlineTableStatus struct { // Detailed status of an online table. Shown if the online table is in the // ONLINE_CONTINUOUS_UPDATE or the ONLINE_UPDATING_PIPELINE_RESOURCES state. - ContinuousUpdateStatus []ContinuousUpdateStatus `tfsdk:"continuous_update_status" tf:"optional,object"` + ContinuousUpdateStatus types.Object `tfsdk:"continuous_update_status" tf:"optional,object"` // The state of the online table. DetailedState types.String `tfsdk:"detailed_state" tf:"optional"` // Detailed status of an online table. Shown if the online table is in the // OFFLINE_FAILED or the ONLINE_PIPELINE_FAILED state. - FailedStatus []FailedStatus `tfsdk:"failed_status" tf:"optional,object"` + FailedStatus types.Object `tfsdk:"failed_status" tf:"optional,object"` // A text description of the current state of the online table. Message types.String `tfsdk:"message" tf:"optional"` // Detailed status of an online table. Shown if the online table is in the // PROVISIONING_PIPELINE_RESOURCES or the PROVISIONING_INITIAL_SNAPSHOT // state. - ProvisioningStatus []ProvisioningStatus `tfsdk:"provisioning_status" tf:"optional,object"` + ProvisioningStatus types.Object `tfsdk:"provisioning_status" tf:"optional,object"` // Detailed status of an online table. Shown if the online table is in the // ONLINE_TRIGGERED_UPDATE or the ONLINE_NO_PENDING_UPDATE state. - TriggeredUpdateStatus []TriggeredUpdateStatus `tfsdk:"triggered_update_status" tf:"optional,object"` + TriggeredUpdateStatus types.Object `tfsdk:"triggered_update_status" tf:"optional,object"` } func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan OnlineTableStatus) { @@ -3360,13 +4257,22 @@ func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringRead(existingState OnlineTableStatus) { } +func (a OnlineTableStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ContinuousUpdateStatus": reflect.TypeOf(ContinuousUpdateStatus{}), + "FailedStatus": reflect.TypeOf(FailedStatus{}), + "ProvisioningStatus": reflect.TypeOf(ProvisioningStatus{}), + "TriggeredUpdateStatus": reflect.TypeOf(TriggeredUpdateStatus{}), + } +} + type PermissionsChange struct { // The set of privileges to add. - Add []types.String `tfsdk:"add" tf:"optional"` + Add types.List `tfsdk:"add" tf:"optional"` // The principal whose privileges we are changing. Principal types.String `tfsdk:"principal" tf:"optional"` // The set of privileges to remove. - Remove []types.String `tfsdk:"remove" tf:"optional"` + Remove types.List `tfsdk:"remove" tf:"optional"` } func (newState *PermissionsChange) SyncEffectiveFieldsDuringCreateOrUpdate(plan PermissionsChange) { @@ -3375,9 +4281,16 @@ func (newState *PermissionsChange) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PermissionsChange) SyncEffectiveFieldsDuringRead(existingState PermissionsChange) { } +func (a PermissionsChange) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Add": reflect.TypeOf(""), + "Remove": reflect.TypeOf(""), + } +} + type PermissionsList struct { // The privileges assigned to each principal - PrivilegeAssignments []PrivilegeAssignment `tfsdk:"privilege_assignments" tf:"optional"` + PrivilegeAssignments types.List `tfsdk:"privilege_assignments" tf:"optional"` } func (newState *PermissionsList) SyncEffectiveFieldsDuringCreateOrUpdate(plan PermissionsList) { @@ -3386,6 +4299,12 @@ func (newState *PermissionsList) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pe func (newState *PermissionsList) SyncEffectiveFieldsDuringRead(existingState PermissionsList) { } +func (a PermissionsList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PrivilegeAssignments": reflect.TypeOf(PrivilegeAssignment{}), + } +} + // Progress information of the Online Table data synchronization pipeline. type PipelineProgress struct { // The estimated time remaining to complete this update in seconds. @@ -3408,9 +4327,13 @@ func (newState *PipelineProgress) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *PipelineProgress) SyncEffectiveFieldsDuringRead(existingState PipelineProgress) { } +func (a PipelineProgress) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PrimaryKeyConstraint struct { // Column names for this constraint. - ChildColumns []types.String `tfsdk:"child_columns" tf:""` + ChildColumns types.List `tfsdk:"child_columns" tf:""` // The name of the constraint. Name types.String `tfsdk:"name" tf:""` } @@ -3421,11 +4344,17 @@ func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringRead(existingState PrimaryKeyConstraint) { } +func (a PrimaryKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ChildColumns": reflect.TypeOf(""), + } +} + type PrivilegeAssignment struct { // The principal (user email address or group name). Principal types.String `tfsdk:"principal" tf:"optional"` // The privileges assigned to the principal. - Privileges []types.String `tfsdk:"privileges" tf:"optional"` + Privileges types.List `tfsdk:"privileges" tf:"optional"` } func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan PrivilegeAssignment) { @@ -3434,6 +4363,12 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState PrivilegeAssignment) { } +func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Privileges": reflect.TypeOf(""), + } +} + // Status of an asynchronously provisioned resource. type ProvisioningInfo struct { State types.String `tfsdk:"state" tf:"optional"` @@ -3445,12 +4380,16 @@ func (newState *ProvisioningInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *ProvisioningInfo) SyncEffectiveFieldsDuringRead(existingState ProvisioningInfo) { } +func (a ProvisioningInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Detailed status of an online table. Shown if the online table is in the // PROVISIONING_PIPELINE_RESOURCES or the PROVISIONING_INITIAL_SNAPSHOT state. type ProvisioningStatus struct { // Details about initial data synchronization. Only populated when in the // PROVISIONING_INITIAL_SNAPSHOT state. - InitialPipelineSyncProgress []PipelineProgress `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` + InitialPipelineSyncProgress types.Object `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` } func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan ProvisioningStatus) { @@ -3459,6 +4398,12 @@ func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringRead(existingState ProvisioningStatus) { } +func (a ProvisioningStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InitialPipelineSyncProgress": reflect.TypeOf(PipelineProgress{}), + } +} + type QuotaInfo struct { // The timestamp that indicates when the quota count was last updated. LastRefreshedAt types.Int64 `tfsdk:"last_refreshed_at" tf:"optional"` @@ -3481,6 +4426,10 @@ func (newState *QuotaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan QuotaInf func (newState *QuotaInfo) SyncEffectiveFieldsDuringRead(existingState QuotaInfo) { } +func (a QuotaInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // R2 temporary credentials for API authentication. Read more at // https://developers.cloudflare.com/r2/api/s3/tokens/. type R2Credentials struct { @@ -3498,6 +4447,10 @@ func (newState *R2Credentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan R2Cr func (newState *R2Credentials) SyncEffectiveFieldsDuringRead(existingState R2Credentials) { } +func (a R2Credentials) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a Volume type ReadVolumeRequest struct { // Whether to include volumes in the response for which the principal can @@ -3513,6 +4466,10 @@ func (newState *ReadVolumeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ReadVolumeRequest) SyncEffectiveFieldsDuringRead(existingState ReadVolumeRequest) { } +func (a ReadVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegenerateDashboardRequest struct { // Full name of the table. TableName types.String `tfsdk:"-"` @@ -3527,6 +4484,10 @@ func (newState *RegenerateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RegenerateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState RegenerateDashboardRequest) { } +func (a RegenerateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegenerateDashboardResponse struct { // Id of the regenerated monitoring dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` @@ -3540,6 +4501,10 @@ func (newState *RegenerateDashboardResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *RegenerateDashboardResponse) SyncEffectiveFieldsDuringRead(existingState RegenerateDashboardResponse) { } +func (a RegenerateDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Registered model alias. type RegisteredModelAlias struct { // Name of the alias, e.g. 'champion' or 'latest_stable' @@ -3554,9 +4519,13 @@ func (newState *RegisteredModelAlias) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RegisteredModelAlias) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAlias) { } +func (a RegisteredModelAlias) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegisteredModelInfo struct { // List of aliases associated with the registered model - Aliases []RegisteredModelAlias `tfsdk:"aliases" tf:"optional"` + Aliases types.List `tfsdk:"aliases" tf:"optional"` // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is // enabled in the request. @@ -3596,6 +4565,12 @@ func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringRead(existingState RegisteredModelInfo) { } +func (a RegisteredModelInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Aliases": reflect.TypeOf(RegisteredModelAlias{}), + } +} + // Queue a metric refresh for a monitor type RunRefreshRequest struct { // Full name of the table. @@ -3608,6 +4583,10 @@ func (newState *RunRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RunRefreshRequest) SyncEffectiveFieldsDuringRead(existingState RunRefreshRequest) { } +func (a RunRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SchemaInfo struct { // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is @@ -3624,7 +4603,7 @@ type SchemaInfo struct { // Username of schema creator. CreatedBy types.String `tfsdk:"created_by" tf:"optional"` - EffectivePredictiveOptimizationFlag []EffectivePredictiveOptimizationFlag `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` + EffectivePredictiveOptimizationFlag types.Object `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` // Whether predictive optimization should be enabled for this object and // objects under it. EnablePredictiveOptimization types.String `tfsdk:"enable_predictive_optimization" tf:"optional"` @@ -3637,7 +4616,7 @@ type SchemaInfo struct { // Username of current owner of schema. Owner types.String `tfsdk:"owner" tf:"optional"` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` // The unique identifier of the schema. SchemaId types.String `tfsdk:"schema_id" tf:"optional"` // Storage location for managed tables within schema. @@ -3656,9 +4635,16 @@ func (newState *SchemaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaI func (newState *SchemaInfo) SyncEffectiveFieldsDuringRead(existingState SchemaInfo) { } +func (a SchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), + "Properties": reflect.TypeOf(""), + } +} + type SetArtifactAllowlist struct { // A list of allowed artifact match patterns. - ArtifactMatchers []ArtifactMatcher `tfsdk:"artifact_matchers" tf:""` + ArtifactMatchers types.List `tfsdk:"artifact_matchers" tf:""` // The artifact type of the allowlist. ArtifactType types.String `tfsdk:"-"` } @@ -3669,6 +4655,12 @@ func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringRead(existingState SetArtifactAllowlist) { } +func (a SetArtifactAllowlist) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ArtifactMatchers": reflect.TypeOf(ArtifactMatcher{}), + } +} + type SetRegisteredModelAliasRequest struct { // The name of the alias Alias types.String `tfsdk:"alias" tf:""` @@ -3684,6 +4676,10 @@ func (newState *SetRegisteredModelAliasRequest) SyncEffectiveFieldsDuringCreateO func (newState *SetRegisteredModelAliasRequest) SyncEffectiveFieldsDuringRead(existingState SetRegisteredModelAliasRequest) { } +func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Server-Side Encryption properties for clients communicating with AWS s3. type SseEncryptionDetails struct { // The type of key encryption to use (affects headers from s3 client). @@ -3699,15 +4695,19 @@ func (newState *SseEncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SseEncryptionDetails) SyncEffectiveFieldsDuringRead(existingState SseEncryptionDetails) { } +func (a SseEncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StorageCredentialInfo struct { // The AWS IAM role configuration. - AwsIamRole []AwsIamRoleResponse `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentityResponse `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken []CloudflareApiToken `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // Time at which this Credential was created, in epoch milliseconds. @@ -3715,7 +4715,7 @@ type StorageCredentialInfo struct { // Username of credential creator. CreatedBy types.String `tfsdk:"created_by" tf:"optional"` // The Databricks managed GCP service account configuration. - DatabricksGcpServiceAccount []DatabricksGcpServiceAccountResponse `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` + DatabricksGcpServiceAccount types.Object `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // The full name of the credential. FullName types.String `tfsdk:"full_name" tf:"optional"` // The unique identifier of the credential. @@ -3745,6 +4745,16 @@ func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingState StorageCredentialInfo) { } +func (a StorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRoleResponse{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityResponse{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), + "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountResponse{}), + } +} + type SystemSchemaInfo struct { // Name of the system schema. Schema types.String `tfsdk:"schema" tf:"optional"` @@ -3759,15 +4769,19 @@ func (newState *SystemSchemaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SystemSchemaInfo) SyncEffectiveFieldsDuringRead(existingState SystemSchemaInfo) { } +func (a SystemSchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // A table constraint, as defined by *one* of the following fields being set: // __primary_key_constraint__, __foreign_key_constraint__, // __named_table_constraint__. type TableConstraint struct { - ForeignKeyConstraint []ForeignKeyConstraint `tfsdk:"foreign_key_constraint" tf:"optional,object"` + ForeignKeyConstraint types.Object `tfsdk:"foreign_key_constraint" tf:"optional,object"` - NamedTableConstraint []NamedTableConstraint `tfsdk:"named_table_constraint" tf:"optional,object"` + NamedTableConstraint types.Object `tfsdk:"named_table_constraint" tf:"optional,object"` - PrimaryKeyConstraint []PrimaryKeyConstraint `tfsdk:"primary_key_constraint" tf:"optional,object"` + PrimaryKeyConstraint types.Object `tfsdk:"primary_key_constraint" tf:"optional,object"` } func (newState *TableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableConstraint) { @@ -3776,6 +4790,14 @@ func (newState *TableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ta func (newState *TableConstraint) SyncEffectiveFieldsDuringRead(existingState TableConstraint) { } +func (a TableConstraint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ForeignKeyConstraint": reflect.TypeOf(ForeignKeyConstraint{}), + "NamedTableConstraint": reflect.TypeOf(NamedTableConstraint{}), + "PrimaryKeyConstraint": reflect.TypeOf(PrimaryKeyConstraint{}), + } +} + // A table that is dependent on a SQL object. type TableDependency struct { // Full name of the dependent table, in the form of @@ -3789,6 +4811,10 @@ func (newState *TableDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ta func (newState *TableDependency) SyncEffectiveFieldsDuringRead(existingState TableDependency) { } +func (a TableDependency) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TableExistsResponse struct { // Whether the table exists or not. TableExists types.Bool `tfsdk:"table_exists" tf:"optional"` @@ -3800,6 +4826,10 @@ func (newState *TableExistsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TableExistsResponse) SyncEffectiveFieldsDuringRead(existingState TableExistsResponse) { } +func (a TableExistsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TableInfo struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -3810,7 +4840,7 @@ type TableInfo struct { // Name of parent catalog. CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` // The array of __ColumnInfo__ definitions of the table's columns. - Columns []ColumnInfo `tfsdk:"columns" tf:"optional"` + Columns types.List `tfsdk:"columns" tf:"optional"` // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` // Time at which this table was created, in epoch milliseconds. @@ -3825,14 +4855,14 @@ type TableInfo struct { // omitted if table is not deleted. DeletedAt types.Int64 `tfsdk:"deleted_at" tf:"optional"` // Information pertaining to current state of the delta table. - DeltaRuntimePropertiesKvpairs []DeltaRuntimePropertiesKvPairs `tfsdk:"delta_runtime_properties_kvpairs" tf:"optional,object"` + DeltaRuntimePropertiesKvpairs types.Object `tfsdk:"delta_runtime_properties_kvpairs" tf:"optional,object"` - EffectivePredictiveOptimizationFlag []EffectivePredictiveOptimizationFlag `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` + EffectivePredictiveOptimizationFlag types.Object `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` // Whether predictive optimization should be enabled for this object and // objects under it. EnablePredictiveOptimization types.String `tfsdk:"enable_predictive_optimization" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails []EncryptionDetails `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` // Full name of table, in form of // __catalog_name__.__schema_name__.__table_name__ FullName types.String `tfsdk:"full_name" tf:"optional"` @@ -3846,9 +4876,9 @@ type TableInfo struct { // (Materialized View, Streaming Table, etc.). PipelineId types.String `tfsdk:"pipeline_id" tf:"optional"` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` - RowFilter []TableRowFilter `tfsdk:"row_filter" tf:"optional,object"` + RowFilter types.Object `tfsdk:"row_filter" tf:"optional,object"` // Name of parent schema relative to its parent catalog. SchemaName types.String `tfsdk:"schema_name" tf:"optional"` // List of schemes whose objects can be referenced without qualification. @@ -3860,7 +4890,7 @@ type TableInfo struct { StorageLocation types.String `tfsdk:"storage_location" tf:"optional"` // List of table constraints. Note: this field is not set in the output of // the __listTables__ API. - TableConstraints []TableConstraint `tfsdk:"table_constraints" tf:"optional"` + TableConstraints types.List `tfsdk:"table_constraints" tf:"optional"` // The unique identifier of the table. TableId types.String `tfsdk:"table_id" tf:"optional"` @@ -3877,7 +4907,7 @@ type TableInfo struct { // provided; - when DependencyList is an empty list, the dependency is // provided but is empty; - when DependencyList is not an empty list, // dependencies are provided and recorded. - ViewDependencies []DependencyList `tfsdk:"view_dependencies" tf:"optional,object"` + ViewDependencies types.Object `tfsdk:"view_dependencies" tf:"optional,object"` } func (newState *TableInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableInfo) { @@ -3886,13 +4916,26 @@ func (newState *TableInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableInf func (newState *TableInfo) SyncEffectiveFieldsDuringRead(existingState TableInfo) { } +func (a TableInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Columns": reflect.TypeOf(ColumnInfo{}), + "DeltaRuntimePropertiesKvpairs": reflect.TypeOf(DeltaRuntimePropertiesKvPairs{}), + "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), + "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + "Properties": reflect.TypeOf(""), + "RowFilter": reflect.TypeOf(TableRowFilter{}), + "TableConstraints": reflect.TypeOf(TableConstraint{}), + "ViewDependencies": reflect.TypeOf(DependencyList{}), + } +} + type TableRowFilter struct { // The full name of the row filter SQL UDF. FunctionName types.String `tfsdk:"function_name" tf:""` // The list of table columns to be passed as input to the row filter // function. The column types should match the types of the filter function // arguments. - InputColumnNames []types.String `tfsdk:"input_column_names" tf:""` + InputColumnNames types.List `tfsdk:"input_column_names" tf:""` } func (newState *TableRowFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableRowFilter) { @@ -3901,6 +4944,12 @@ func (newState *TableRowFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tab func (newState *TableRowFilter) SyncEffectiveFieldsDuringRead(existingState TableRowFilter) { } +func (a TableRowFilter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InputColumnNames": reflect.TypeOf(""), + } +} + type TableSummary struct { // The full name of the table. FullName types.String `tfsdk:"full_name" tf:"optional"` @@ -3914,14 +4963,18 @@ func (newState *TableSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Table func (newState *TableSummary) SyncEffectiveFieldsDuringRead(existingState TableSummary) { } +func (a TableSummary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TemporaryCredentials struct { // AWS temporary credentials for API authentication. Read more at // https://docs.aws.amazon.com/STS/latest/APIReference/API_Credentials.html. - AwsTempCredentials []AwsCredentials `tfsdk:"aws_temp_credentials" tf:"optional,object"` + AwsTempCredentials types.Object `tfsdk:"aws_temp_credentials" tf:"optional,object"` // Azure Active Directory token, essentially the Oauth token for Azure // Service Principal or Managed Identity. Read more at // https://learn.microsoft.com/en-us/azure/databricks/dev-tools/api/latest/aad/service-prin-aad-token - AzureAad []AzureActiveDirectoryToken `tfsdk:"azure_aad" tf:"optional,object"` + AzureAad types.Object `tfsdk:"azure_aad" tf:"optional,object"` // Server time when the credential will expire, in epoch milliseconds. The // API client is advised to cache the credential given this expiration time. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` @@ -3933,6 +4986,13 @@ func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringRead(existingState TemporaryCredentials) { } +func (a TemporaryCredentials) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsTempCredentials": reflect.TypeOf(AwsCredentials{}), + "AzureAad": reflect.TypeOf(AzureActiveDirectoryToken{}), + } +} + // Detailed status of an online table. Shown if the online table is in the // ONLINE_TRIGGERED_UPDATE or the ONLINE_NO_PENDING_UPDATE state. type TriggeredUpdateStatus struct { @@ -3944,7 +5004,7 @@ type TriggeredUpdateStatus struct { // table to the online table. Timestamp types.String `tfsdk:"timestamp" tf:"optional"` // Progress of the active data synchronization pipeline. - TriggeredUpdateProgress []PipelineProgress `tfsdk:"triggered_update_progress" tf:"optional,object"` + TriggeredUpdateProgress types.Object `tfsdk:"triggered_update_progress" tf:"optional,object"` } func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan TriggeredUpdateStatus) { @@ -3953,6 +5013,12 @@ func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringRead(existingState TriggeredUpdateStatus) { } +func (a TriggeredUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TriggeredUpdateProgress": reflect.TypeOf(PipelineProgress{}), + } +} + // Delete an assignment type UnassignRequest struct { // Query for the ID of the metastore to delete. @@ -3967,6 +5033,10 @@ func (newState *UnassignRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Un func (newState *UnassignRequest) SyncEffectiveFieldsDuringRead(existingState UnassignRequest) { } +func (a UnassignRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UnassignResponse struct { } @@ -3976,6 +5046,10 @@ func (newState *UnassignResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UnassignResponse) SyncEffectiveFieldsDuringRead(existingState UnassignResponse) { } +func (a UnassignResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateAssignmentResponse struct { } @@ -3985,6 +5059,10 @@ func (newState *UpdateAssignmentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateAssignmentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateAssignmentResponse) { } +func (a UpdateAssignmentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateCatalog struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -4001,7 +5079,7 @@ type UpdateCatalog struct { // Username of current owner of catalog. Owner types.String `tfsdk:"owner" tf:"optional"` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` } func (newState *UpdateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCatalog) { @@ -4010,13 +5088,19 @@ func (newState *UpdateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateCatalog) SyncEffectiveFieldsDuringRead(existingState UpdateCatalog) { } +func (a UpdateCatalog) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Properties": reflect.TypeOf(""), + } +} + type UpdateConnection struct { // Name of the connection. Name types.String `tfsdk:"-"` // New name for the connection. NewName types.String `tfsdk:"new_name" tf:"optional"` // A map of key-value properties attached to the securable. - Options map[string]types.String `tfsdk:"options" tf:""` + Options types.Map `tfsdk:"options" tf:""` // Username of current owner of the connection. Owner types.String `tfsdk:"owner" tf:"optional"` } @@ -4027,13 +5111,19 @@ func (newState *UpdateConnection) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateConnection) SyncEffectiveFieldsDuringRead(existingState UpdateConnection) { } +func (a UpdateConnection) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(""), + } +} + type UpdateCredentialRequest struct { // The AWS IAM role configuration - AwsIamRole []AwsIamRole `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentity `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // Force an update even if there are dependent services (when purpose is @@ -4063,6 +5153,14 @@ func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialRequest) { } +func (a UpdateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRole{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + } +} + type UpdateExternalLocation struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -4071,7 +5169,7 @@ type UpdateExternalLocation struct { // Name of the storage credential used with this location. CredentialName types.String `tfsdk:"credential_name" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails []EncryptionDetails `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` // Indicates whether fallback mode is enabled for this external location. // When fallback mode is enabled, the access to the location falls back to // cluster credentials if UC credentials are not sufficient. @@ -4102,6 +5200,12 @@ func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringRead(existingState UpdateExternalLocation) { } +func (a UpdateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + } +} + type UpdateFunction struct { // The fully-qualified name of the function (of the form // __catalog_name__.__schema_name__.__function__name__). @@ -4116,6 +5220,10 @@ func (newState *UpdateFunction) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateFunction) SyncEffectiveFieldsDuringRead(existingState UpdateFunction) { } +func (a UpdateFunction) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateMetastore struct { // The organization name of a Delta Sharing entity, to be used in // Databricks-to-Databricks Delta Sharing as the official name. @@ -4143,6 +5251,10 @@ func (newState *UpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateMetastore) SyncEffectiveFieldsDuringRead(existingState UpdateMetastore) { } +func (a UpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateMetastoreAssignment struct { // The name of the default catalog in the metastore. This field is // depracted. Please use "Default Namespace API" to configure the default @@ -4160,6 +5272,10 @@ func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState UpdateMetastoreAssignment) { } +func (a UpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateModelVersionRequest struct { // The comment attached to the model version Comment types.String `tfsdk:"comment" tf:"optional"` @@ -4175,6 +5291,10 @@ func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionRequest) { } +func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateMonitor struct { // Name of the baseline table from which drift metrics are computed from. // Columns in the monitored table should also be present in the baseline @@ -4183,32 +5303,32 @@ type UpdateMonitor struct { // Custom metrics to compute on the monitored table. These can be aggregate // metrics, derived metrics (from already computed aggregate metrics), or // drift metrics (comparing metrics across time windows). - CustomMetrics []MonitorMetric `tfsdk:"custom_metrics" tf:"optional"` + CustomMetrics types.List `tfsdk:"custom_metrics" tf:"optional"` // Id of dashboard that visualizes the computed metrics. This can be empty // if the monitor is in PENDING state. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` // The data classification config for the monitor. - DataClassificationConfig []MonitorDataClassificationConfig `tfsdk:"data_classification_config" tf:"optional,object"` + DataClassificationConfig types.Object `tfsdk:"data_classification_config" tf:"optional,object"` // Configuration for monitoring inference logs. - InferenceLog []MonitorInferenceLog `tfsdk:"inference_log" tf:"optional,object"` + InferenceLog types.Object `tfsdk:"inference_log" tf:"optional,object"` // The notification settings for the monitor. - Notifications []MonitorNotifications `tfsdk:"notifications" tf:"optional,object"` + Notifications types.Object `tfsdk:"notifications" tf:"optional,object"` // Schema where output metric tables are created. OutputSchemaName types.String `tfsdk:"output_schema_name" tf:""` // The schedule for automatically updating and refreshing metric tables. - Schedule []MonitorCronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // List of column expressions to slice data with for targeted analysis. The // data is grouped by each expression independently, resulting in a separate // slice for each predicate and its complements. For high-cardinality // columns, only the top 100 unique values by frequency will generate // slices. - SlicingExprs []types.String `tfsdk:"slicing_exprs" tf:"optional"` + SlicingExprs types.List `tfsdk:"slicing_exprs" tf:"optional"` // Configuration for monitoring snapshot tables. Snapshot []MonitorSnapshot `tfsdk:"snapshot" tf:"optional,object"` // Full name of the table. TableName types.String `tfsdk:"-"` // Configuration for monitoring time series tables. - TimeSeries []MonitorTimeSeries `tfsdk:"time_series" tf:"optional,object"` + TimeSeries types.Object `tfsdk:"time_series" tf:"optional,object"` } func (newState *UpdateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateMonitor) { @@ -4217,9 +5337,22 @@ func (newState *UpdateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateMonitor) SyncEffectiveFieldsDuringRead(existingState UpdateMonitor) { } +func (a UpdateMonitor) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CustomMetrics": reflect.TypeOf(MonitorMetric{}), + "DataClassificationConfig": reflect.TypeOf(MonitorDataClassificationConfig{}), + "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), + "Notifications": reflect.TypeOf(MonitorNotifications{}), + "Schedule": reflect.TypeOf(MonitorCronSchedule{}), + "SlicingExprs": reflect.TypeOf(""), + "Snapshot": reflect.TypeOf(MonitorSnapshot{}), + "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), + } +} + type UpdatePermissions struct { // Array of permissions change objects. - Changes []PermissionsChange `tfsdk:"changes" tf:"optional"` + Changes types.List `tfsdk:"changes" tf:"optional"` // Full name of securable. FullName types.String `tfsdk:"-"` // Type of securable. @@ -4232,6 +5365,12 @@ func (newState *UpdatePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdatePermissions) SyncEffectiveFieldsDuringRead(existingState UpdatePermissions) { } +func (a UpdatePermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Changes": reflect.TypeOf(PermissionsChange{}), + } +} + type UpdateRegisteredModelRequest struct { // The comment attached to the registered model Comment types.String `tfsdk:"comment" tf:"optional"` @@ -4249,6 +5388,10 @@ func (newState *UpdateRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *UpdateRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRegisteredModelRequest) { } +func (a UpdateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateResponse struct { } @@ -4258,6 +5401,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateSchema struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -4271,7 +5418,7 @@ type UpdateSchema struct { // Username of current owner of schema. Owner types.String `tfsdk:"owner" tf:"optional"` // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:"optional"` + Properties types.Map `tfsdk:"properties" tf:"optional"` } func (newState *UpdateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateSchema) { @@ -4280,15 +5427,21 @@ func (newState *UpdateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Updat func (newState *UpdateSchema) SyncEffectiveFieldsDuringRead(existingState UpdateSchema) { } +func (a UpdateSchema) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Properties": reflect.TypeOf(""), + } +} + type UpdateStorageCredential struct { // The AWS IAM role configuration. - AwsIamRole []AwsIamRoleRequest `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentityResponse `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken []CloudflareApiToken `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // The Databricks managed GCP service account configuration. @@ -4317,6 +5470,16 @@ func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingState UpdateStorageCredential) { } +func (a UpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRoleRequest{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityResponse{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), + "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), + } +} + // Update a table owner. type UpdateTableRequest struct { // Full name of the table. @@ -4331,6 +5494,10 @@ func (newState *UpdateTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateTableRequest) SyncEffectiveFieldsDuringRead(existingState UpdateTableRequest) { } +func (a UpdateTableRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateVolumeRequestContent struct { // The comment attached to the volume Comment types.String `tfsdk:"comment" tf:"optional"` @@ -4348,13 +5515,17 @@ func (newState *UpdateVolumeRequestContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateVolumeRequestContent) SyncEffectiveFieldsDuringRead(existingState UpdateVolumeRequestContent) { } +func (a UpdateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateWorkspaceBindings struct { // A list of workspace IDs. - AssignWorkspaces []types.Int64 `tfsdk:"assign_workspaces" tf:"optional"` + AssignWorkspaces types.List `tfsdk:"assign_workspaces" tf:"optional"` // The name of the catalog. Name types.String `tfsdk:"-"` // A list of workspace IDs. - UnassignWorkspaces []types.Int64 `tfsdk:"unassign_workspaces" tf:"optional"` + UnassignWorkspaces types.List `tfsdk:"unassign_workspaces" tf:"optional"` } func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateWorkspaceBindings) { @@ -4363,11 +5534,18 @@ func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceBindings) { } +func (a UpdateWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AssignWorkspaces": reflect.TypeOf(0), + "UnassignWorkspaces": reflect.TypeOf(0), + } +} + type UpdateWorkspaceBindingsParameters struct { // List of workspace bindings - Add []WorkspaceBinding `tfsdk:"add" tf:"optional"` + Add types.List `tfsdk:"add" tf:"optional"` // List of workspace bindings - Remove []WorkspaceBinding `tfsdk:"remove" tf:"optional"` + Remove types.List `tfsdk:"remove" tf:"optional"` // The name of the securable. SecurableName types.String `tfsdk:"-"` // The type of the securable to bind to a workspace. @@ -4380,11 +5558,18 @@ func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringCrea func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceBindingsParameters) { } +func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Add": reflect.TypeOf(WorkspaceBinding{}), + "Remove": reflect.TypeOf(WorkspaceBinding{}), + } +} + type ValidateCredentialRequest struct { // The AWS IAM role configuration - AwsIamRole []AwsIamRole `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentity `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // Required. The name of an existing credential or long-lived cloud // credential to validate. CredentialName types.String `tfsdk:"credential_name" tf:"optional"` @@ -4408,12 +5593,19 @@ func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState ValidateCredentialRequest) { } +func (a ValidateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRole{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), + } +} + type ValidateCredentialResponse struct { // Whether the tested location is a directory in cloud storage. Only // applicable for when purpose is **STORAGE**. IsDir types.Bool `tfsdk:"isDir" tf:"optional"` // The results of the validation check. - Results []CredentialValidationResult `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ValidateCredentialResponse) { @@ -4422,15 +5614,21 @@ func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringRead(existingState ValidateCredentialResponse) { } +func (a ValidateCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(CredentialValidationResult{}), + } +} + type ValidateStorageCredential struct { // The AWS IAM role configuration. - AwsIamRole []AwsIamRoleRequest `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity []AzureManagedIdentityRequest `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal []AzureServicePrincipal `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken []CloudflareApiToken `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` // The Databricks created GCP service account configuration. DatabricksGcpServiceAccount []DatabricksGcpServiceAccountRequest `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // The name of an existing external location to validate. @@ -4449,11 +5647,21 @@ func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringRead(existingState ValidateStorageCredential) { } +func (a ValidateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsIamRole": reflect.TypeOf(AwsIamRoleRequest{}), + "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityRequest{}), + "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), + "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), + } +} + type ValidateStorageCredentialResponse struct { // Whether the tested location is a directory in cloud storage. IsDir types.Bool `tfsdk:"isDir" tf:"optional"` // The results of the validation check. - Results []ValidationResult `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ValidateStorageCredentialResponse) { @@ -4462,6 +5670,12 @@ func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringCrea func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringRead(existingState ValidateStorageCredentialResponse) { } +func (a ValidateStorageCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(ValidationResult{}), + } +} + type ValidationResult struct { // Error message would exist when the result does not equal to **PASS**. Message types.String `tfsdk:"message" tf:"optional"` @@ -4477,6 +5691,10 @@ func (newState *ValidationResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan V func (newState *ValidationResult) SyncEffectiveFieldsDuringRead(existingState ValidationResult) { } +func (a ValidationResult) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type VolumeInfo struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -4493,7 +5711,7 @@ type VolumeInfo struct { // The identifier of the user who created the volume CreatedBy types.String `tfsdk:"created_by" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails []EncryptionDetails `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` // The three-level (fully qualified) name of the volume FullName types.String `tfsdk:"full_name" tf:"optional"` // The unique identifier of the metastore @@ -4522,6 +5740,12 @@ func (newState *VolumeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan VolumeI func (newState *VolumeInfo) SyncEffectiveFieldsDuringRead(existingState VolumeInfo) { } +func (a VolumeInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + } +} + type WorkspaceBinding struct { BindingType types.String `tfsdk:"binding_type" tf:"optional"` @@ -4534,10 +5758,14 @@ func (newState *WorkspaceBinding) SyncEffectiveFieldsDuringCreateOrUpdate(plan W func (newState *WorkspaceBinding) SyncEffectiveFieldsDuringRead(existingState WorkspaceBinding) { } +func (a WorkspaceBinding) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Currently assigned workspace bindings type WorkspaceBindingsResponse struct { // List of workspace bindings - Bindings []WorkspaceBinding `tfsdk:"bindings" tf:"optional"` + Bindings types.List `tfsdk:"bindings" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). @@ -4549,3 +5777,9 @@ func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringRead(existingState WorkspaceBindingsResponse) { } + +func (a WorkspaceBindingsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Bindings": reflect.TypeOf(WorkspaceBinding{}), + } +} diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index d1e67f00bb..47f3431f2e 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package compute_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -49,6 +51,10 @@ func (newState *AddInstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AddInstanceProfile) SyncEffectiveFieldsDuringRead(existingState AddInstanceProfile) { } +func (a AddInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AddResponse struct { } @@ -58,6 +64,10 @@ func (newState *AddResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddRes func (newState *AddResponse) SyncEffectiveFieldsDuringRead(existingState AddResponse) { } +func (a AddResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Adlsgen2Info struct { // abfss destination, e.g. // `abfss://@.dfs.core.windows.net/`. @@ -70,6 +80,10 @@ func (newState *Adlsgen2Info) SyncEffectiveFieldsDuringCreateOrUpdate(plan Adlsg func (newState *Adlsgen2Info) SyncEffectiveFieldsDuringRead(existingState Adlsgen2Info) { } +func (a Adlsgen2Info) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AutoScale struct { // The maximum number of workers to which the cluster can scale up when // overloaded. Note that `max_workers` must be strictly greater than @@ -87,6 +101,10 @@ func (newState *AutoScale) SyncEffectiveFieldsDuringCreateOrUpdate(plan AutoScal func (newState *AutoScale) SyncEffectiveFieldsDuringRead(existingState AutoScale) { } +func (a AutoScale) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AwsAttributes struct { // Availability type used for all subsequent nodes past the // `first_on_demand` ones. @@ -179,6 +197,10 @@ func (newState *AwsAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsA func (newState *AwsAttributes) SyncEffectiveFieldsDuringRead(existingState AwsAttributes) { } +func (a AwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AzureAttributes struct { // Availability type used for all subsequent nodes past the // `first_on_demand` ones. Note: If `first_on_demand` is zero (which only @@ -196,7 +218,7 @@ type AzureAttributes struct { // mutated over the lifetime of a cluster. FirstOnDemand types.Int64 `tfsdk:"first_on_demand" tf:"optional"` // Defines values necessary to configure and run Azure Log Analytics agent - LogAnalyticsInfo []LogAnalyticsInfo `tfsdk:"log_analytics_info" tf:"optional,object"` + LogAnalyticsInfo types.Object `tfsdk:"log_analytics_info" tf:"optional,object"` // The max bid price to be used for Azure spot instances. The Max price for // the bid cannot be higher than the on-demand price of the instance. If not // specified, the default value is -1, which specifies that the instance @@ -211,6 +233,12 @@ func (newState *AzureAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan Az func (newState *AzureAttributes) SyncEffectiveFieldsDuringRead(existingState AzureAttributes) { } +func (a AzureAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LogAnalyticsInfo": reflect.TypeOf(LogAnalyticsInfo{}), + } +} + type CancelCommand struct { ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -225,6 +253,10 @@ func (newState *CancelCommand) SyncEffectiveFieldsDuringCreateOrUpdate(plan Canc func (newState *CancelCommand) SyncEffectiveFieldsDuringRead(existingState CancelCommand) { } +func (a CancelCommand) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CancelResponse struct { } @@ -234,6 +266,10 @@ func (newState *CancelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Can func (newState *CancelResponse) SyncEffectiveFieldsDuringRead(existingState CancelResponse) { } +func (a CancelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ChangeClusterOwner struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -247,6 +283,10 @@ func (newState *ChangeClusterOwner) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ChangeClusterOwner) SyncEffectiveFieldsDuringRead(existingState ChangeClusterOwner) { } +func (a ChangeClusterOwner) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ChangeClusterOwnerResponse struct { } @@ -256,6 +296,10 @@ func (newState *ChangeClusterOwnerResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ChangeClusterOwnerResponse) SyncEffectiveFieldsDuringRead(existingState ChangeClusterOwnerResponse) { } +func (a ChangeClusterOwnerResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClientsTypes struct { // With jobs set, the cluster can be used for jobs Jobs types.Bool `tfsdk:"jobs" tf:"optional"` @@ -269,6 +313,10 @@ func (newState *ClientsTypes) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clien func (newState *ClientsTypes) SyncEffectiveFieldsDuringRead(existingState ClientsTypes) { } +func (a ClientsTypes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CloneCluster struct { // The cluster that is being cloned. SourceClusterId types.String `tfsdk:"source_cluster_id" tf:""` @@ -280,8 +328,12 @@ func (newState *CloneCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clone func (newState *CloneCluster) SyncEffectiveFieldsDuringRead(existingState CloneCluster) { } +func (a CloneCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CloudProviderNodeInfo struct { - Status []types.String `tfsdk:"status" tf:"optional"` + Status types.List `tfsdk:"status" tf:"optional"` } func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan CloudProviderNodeInfo) { @@ -290,6 +342,12 @@ func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringRead(existingState CloudProviderNodeInfo) { } +func (a CloudProviderNodeInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Status": reflect.TypeOf(""), + } +} + type ClusterAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -307,9 +365,13 @@ func (newState *ClusterAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ClusterAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ClusterAccessControlRequest) { } +func (a ClusterAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterAccessControlResponse struct { // All permissions. - AllPermissions []ClusterPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -326,6 +388,12 @@ func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ClusterAccessControlResponse) { } +func (a ClusterAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(ClusterPermission{}), + } +} + type ClusterAttributes struct { // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically @@ -335,17 +403,17 @@ type ClusterAttributes struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes []AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes []AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf []ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -357,7 +425,7 @@ type ClusterAttributes struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Data security mode decides what data governance model to use when // accessing data from a cluster. // @@ -382,7 +450,7 @@ type ClusterAttributes struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage []DockerImage `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -400,12 +468,12 @@ type ClusterAttributes struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes []GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts []InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // This field encodes, through a single value, the resources available to @@ -432,7 +500,7 @@ type ClusterAttributes struct { // JVM options to the driver and the executors via // `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` // respectively. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // An object containing a set of optional, user-specified environment // variable key-value pairs. Please note that key-value pair of the form // (X,Y) will be exported as is (i.e., `export X='Y'`) while launching the @@ -446,7 +514,7 @@ type ClusterAttributes struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of // available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. @@ -454,9 +522,9 @@ type ClusterAttributes struct { // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType []WorkloadType `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` } func (newState *ClusterAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterAttributes) { @@ -465,6 +533,22 @@ func (newState *ClusterAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterAttributes) SyncEffectiveFieldsDuringRead(existingState ClusterAttributes) { } +func (a ClusterAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsAttributes": reflect.TypeOf(AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(AzureAttributes{}), + "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), + "CustomTags": reflect.TypeOf(""), + "DockerImage": reflect.TypeOf(DockerImage{}), + "GcpAttributes": reflect.TypeOf(GcpAttributes{}), + "InitScripts": reflect.TypeOf(InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(""), + "WorkloadType": reflect.TypeOf(WorkloadType{}), + } +} + type ClusterCompliance struct { // Canonical unique identifier for a cluster. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -475,7 +559,7 @@ type ClusterCompliance struct { // validation errors. The keys indicate the path where the policy validation // error is occurring. The values indicate an error message describing the // policy validation error. - Violations map[string]types.String `tfsdk:"violations" tf:"optional"` + Violations types.Map `tfsdk:"violations" tf:"optional"` } func (newState *ClusterCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterCompliance) { @@ -484,11 +568,17 @@ func (newState *ClusterCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterCompliance) SyncEffectiveFieldsDuringRead(existingState ClusterCompliance) { } +func (a ClusterCompliance) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Violations": reflect.TypeOf(""), + } +} + type ClusterDetails struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -497,10 +587,10 @@ type ClusterDetails struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes []AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes []AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // Number of CPU cores available for this cluster. Note that this can be // fractional, e.g. 7.5 cores, since certain node types are configured to // share cores between Spark nodes on the same instance. @@ -514,9 +604,9 @@ type ClusterDetails struct { // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf []ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster log delivery status. - ClusterLogStatus []LogSyncStatus `tfsdk:"cluster_log_status" tf:"optional,object"` + ClusterLogStatus types.Object `tfsdk:"cluster_log_status" tf:"optional,object"` // Total amount of cluster memory, in megabytes ClusterMemoryMb types.Int64 `tfsdk:"cluster_memory_mb" tf:"optional"` // Cluster name requested by the user. This doesn't have to be unique. If @@ -537,7 +627,7 @@ type ClusterDetails struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Data security mode decides what data governance model to use when // accessing data from a cluster. // @@ -573,13 +663,13 @@ type ClusterDetails struct { // - ClusterId: // // - Name: - DefaultTags map[string]types.String `tfsdk:"default_tags" tf:"optional"` + DefaultTags types.Map `tfsdk:"default_tags" tf:"optional"` - DockerImage []DockerImage `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` // Node on which the Spark driver resides. The driver node contains the // Spark master and the Databricks application that manages the per-notebook // Spark REPLs. - Driver []SparkNode `tfsdk:"driver" tf:"optional,object"` + Driver types.Object `tfsdk:"driver" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -596,15 +686,15 @@ type ClusterDetails struct { // Whether to enable LUKS on cluster VMs' local disks EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Nodes on which the Spark executors reside. - Executors []SparkNode `tfsdk:"executors" tf:"optional"` + Executors types.List `tfsdk:"executors" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes []GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts []InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // Port on which Spark JDBC server is listening, in the driver nod. No @@ -650,7 +740,7 @@ type ClusterDetails struct { // JVM options to the driver and the executors via // `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` // respectively. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // A canonical SparkContext identifier. This value *does* change when the // Spark driver restarts. The pair `(cluster_id, spark_context_id)` is a // globally unique identifier over all Spark contexts. @@ -668,7 +758,7 @@ type ClusterDetails struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of // available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. @@ -677,11 +767,11 @@ type ClusterDetails struct { // or edit this cluster. The contents of `spec` can be used in the body of a // create cluster request. This field might not be populated for older // clusters. Note: not included in the response of the ListClusters API. - Spec []ClusterSpec `tfsdk:"spec" tf:"optional,object"` + Spec types.Object `tfsdk:"spec" tf:"optional,object"` // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` // Time (in epoch milliseconds) when the cluster creation request was // received (when the cluster entered a `PENDING` state). StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` @@ -695,9 +785,9 @@ type ClusterDetails struct { TerminatedTime types.Int64 `tfsdk:"terminated_time" tf:"optional"` // Information about why the cluster was terminated. This field only appears // when the cluster is in a `TERMINATING` or `TERMINATED` state. - TerminationReason []TerminationReason `tfsdk:"termination_reason" tf:"optional,object"` + TerminationReason types.Object `tfsdk:"termination_reason" tf:"optional,object"` - WorkloadType []WorkloadType `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` } func (newState *ClusterDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterDetails) { @@ -706,13 +796,36 @@ func (newState *ClusterDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clu func (newState *ClusterDetails) SyncEffectiveFieldsDuringRead(existingState ClusterDetails) { } +func (a ClusterDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + "AwsAttributes": reflect.TypeOf(AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(AzureAttributes{}), + "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), + "ClusterLogStatus": reflect.TypeOf(LogSyncStatus{}), + "CustomTags": reflect.TypeOf(""), + "DefaultTags": reflect.TypeOf(""), + "DockerImage": reflect.TypeOf(DockerImage{}), + "Driver": reflect.TypeOf(SparkNode{}), + "Executors": reflect.TypeOf(SparkNode{}), + "GcpAttributes": reflect.TypeOf(GcpAttributes{}), + "InitScripts": reflect.TypeOf(InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "Spec": reflect.TypeOf(ClusterSpec{}), + "SshPublicKeys": reflect.TypeOf(""), + "TerminationReason": reflect.TypeOf(TerminationReason{}), + "WorkloadType": reflect.TypeOf(WorkloadType{}), + } +} + type ClusterEvent struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` // - DataPlaneEventDetails []DataPlaneEventDetails `tfsdk:"data_plane_event_details" tf:"optional,object"` + DataPlaneEventDetails types.Object `tfsdk:"data_plane_event_details" tf:"optional,object"` // - Details []EventDetails `tfsdk:"details" tf:"optional,object"` + Details types.Object `tfsdk:"details" tf:"optional,object"` // The timestamp when the event occurred, stored as the number of // milliseconds since the Unix epoch. If not provided, this will be assigned // by the Timeline service. @@ -727,11 +840,18 @@ func (newState *ClusterEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clust func (newState *ClusterEvent) SyncEffectiveFieldsDuringRead(existingState ClusterEvent) { } +func (a ClusterEvent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataPlaneEventDetails": reflect.TypeOf(DataPlaneEventDetails{}), + "Details": reflect.TypeOf(EventDetails{}), + } +} + type ClusterLibraryStatuses struct { // Unique identifier for the cluster. ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` // Status of all libraries on the cluster. - LibraryStatuses []LibraryFullStatus `tfsdk:"library_statuses" tf:"optional"` + LibraryStatuses types.List `tfsdk:"library_statuses" tf:"optional"` } func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterLibraryStatuses) { @@ -740,16 +860,22 @@ func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringRead(existingState ClusterLibraryStatuses) { } +func (a ClusterLibraryStatuses) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LibraryStatuses": reflect.TypeOf(LibraryFullStatus{}), + } +} + type ClusterLogConf struct { // destination needs to be provided. e.g. `{ "dbfs" : { "destination" : // "dbfs:/home/cluster_log" } }` - Dbfs []DbfsStorageInfo `tfsdk:"dbfs" tf:"optional,object"` + Dbfs types.Object `tfsdk:"dbfs" tf:"optional,object"` // destination and either the region or endpoint need to be provided. e.g. // `{ "s3": { "destination" : "s3://cluster_log_bucket/prefix", "region" : // "us-west-2" } }` Cluster iam role is used to access s3, please make sure // the cluster iam role in `instance_profile_arn` has permission to write // data to the s3 destination. - S3 []S3StorageInfo `tfsdk:"s3" tf:"optional,object"` + S3 types.Object `tfsdk:"s3" tf:"optional,object"` } func (newState *ClusterLogConf) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterLogConf) { @@ -758,10 +884,17 @@ func (newState *ClusterLogConf) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clu func (newState *ClusterLogConf) SyncEffectiveFieldsDuringRead(existingState ClusterLogConf) { } +func (a ClusterLogConf) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dbfs": reflect.TypeOf(DbfsStorageInfo{}), + "S3": reflect.TypeOf(S3StorageInfo{}), + } +} + type ClusterPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -772,8 +905,14 @@ func (newState *ClusterPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterPermission) SyncEffectiveFieldsDuringRead(existingState ClusterPermission) { } +func (a ClusterPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type ClusterPermissions struct { - AccessControlList []ClusterAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -786,6 +925,12 @@ func (newState *ClusterPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterPermissions) SyncEffectiveFieldsDuringRead(existingState ClusterPermissions) { } +func (a ClusterPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ClusterAccessControlResponse{}), + } +} + type ClusterPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -798,8 +943,12 @@ func (newState *ClusterPermissionsDescription) SyncEffectiveFieldsDuringCreateOr func (newState *ClusterPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ClusterPermissionsDescription) { } +func (a ClusterPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterPermissionsRequest struct { - AccessControlList []ClusterAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The cluster for which to get or manage permissions. ClusterId types.String `tfsdk:"-"` } @@ -810,6 +959,12 @@ func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPermissionsRequest) { } +func (a ClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ClusterAccessControlRequest{}), + } +} + type ClusterPolicyAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -827,9 +982,13 @@ func (newState *ClusterPolicyAccessControlRequest) SyncEffectiveFieldsDuringCrea func (newState *ClusterPolicyAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyAccessControlRequest) { } +func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterPolicyAccessControlResponse struct { // All permissions. - AllPermissions []ClusterPolicyPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -846,10 +1005,16 @@ func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringCre func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyAccessControlResponse) { } +func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(ClusterPolicyPermission{}), + } +} + type ClusterPolicyPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -860,8 +1025,14 @@ func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermission) { } +func (a ClusterPolicyPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type ClusterPolicyPermissions struct { - AccessControlList []ClusterPolicyAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -874,6 +1045,12 @@ func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissions) { } +func (a ClusterPolicyPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ClusterPolicyAccessControlResponse{}), + } +} + type ClusterPolicyPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -886,8 +1063,12 @@ func (newState *ClusterPolicyPermissionsDescription) SyncEffectiveFieldsDuringCr func (newState *ClusterPolicyPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissionsDescription) { } +func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterPolicyPermissionsRequest struct { - AccessControlList []ClusterPolicyAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The cluster policy for which to get or manage permissions. ClusterPolicyId types.String `tfsdk:"-"` } @@ -898,6 +1079,12 @@ func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringCreate func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissionsRequest) { } +func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ClusterPolicyAccessControlRequest{}), + } +} + // Represents a change to the cluster settings required for the cluster to // become compliant with its policy. type ClusterSettingsChange struct { @@ -921,11 +1108,15 @@ func (newState *ClusterSettingsChange) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ClusterSettingsChange) SyncEffectiveFieldsDuringRead(existingState ClusterSettingsChange) { } +func (a ClusterSettingsChange) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterSize struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Number of worker nodes that this cluster should have. A cluster has one // Spark Driver and `num_workers` Executors for a total of `num_workers` + 1 // Spark nodes. @@ -945,6 +1136,12 @@ func (newState *ClusterSize) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSize) SyncEffectiveFieldsDuringRead(existingState ClusterSize) { } +func (a ClusterSize) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + } +} + type ClusterSpec struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -953,7 +1150,7 @@ type ClusterSpec struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -962,17 +1159,17 @@ type ClusterSpec struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes []AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes []AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf []ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -984,7 +1181,7 @@ type ClusterSpec struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Data security mode decides what data governance model to use when // accessing data from a cluster. // @@ -1009,7 +1206,7 @@ type ClusterSpec struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage []DockerImage `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -1027,12 +1224,12 @@ type ClusterSpec struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes []GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts []InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // This field encodes, through a single value, the resources available to @@ -1070,7 +1267,7 @@ type ClusterSpec struct { // JVM options to the driver and the executors via // `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` // respectively. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // An object containing a set of optional, user-specified environment // variable key-value pairs. Please note that key-value pair of the form // (X,Y) will be exported as is (i.e., `export X='Y'`) while launching the @@ -1084,7 +1281,7 @@ type ClusterSpec struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of // available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. @@ -1092,9 +1289,9 @@ type ClusterSpec struct { // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType []WorkloadType `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` } func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterSpec) { @@ -1103,6 +1300,23 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState ClusterSpec) { } +func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + "AwsAttributes": reflect.TypeOf(AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(AzureAttributes{}), + "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), + "CustomTags": reflect.TypeOf(""), + "DockerImage": reflect.TypeOf(DockerImage{}), + "GcpAttributes": reflect.TypeOf(GcpAttributes{}), + "InitScripts": reflect.TypeOf(InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(""), + "WorkloadType": reflect.TypeOf(WorkloadType{}), + } +} + // Get status type ClusterStatus struct { // Unique identifier of the cluster whose status should be retrieved. @@ -1115,6 +1329,10 @@ func (newState *ClusterStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clus func (newState *ClusterStatus) SyncEffectiveFieldsDuringRead(existingState ClusterStatus) { } +func (a ClusterStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Command struct { // Running cluster id ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -1132,6 +1350,10 @@ func (newState *Command) SyncEffectiveFieldsDuringCreateOrUpdate(plan Command) { func (newState *Command) SyncEffectiveFieldsDuringRead(existingState Command) { } +func (a Command) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get command info type CommandStatusRequest struct { ClusterId types.String `tfsdk:"-"` @@ -1147,10 +1369,14 @@ func (newState *CommandStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CommandStatusRequest) SyncEffectiveFieldsDuringRead(existingState CommandStatusRequest) { } +func (a CommandStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CommandStatusResponse struct { Id types.String `tfsdk:"id" tf:"optional"` - Results []Results `tfsdk:"results" tf:"optional,object"` + Results types.Object `tfsdk:"results" tf:"optional,object"` Status types.String `tfsdk:"status" tf:"optional"` } @@ -1161,6 +1387,12 @@ func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringRead(existingState CommandStatusResponse) { } +func (a CommandStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(Results{}), + } +} + // Get status type ContextStatusRequest struct { ClusterId types.String `tfsdk:"-"` @@ -1174,6 +1406,10 @@ func (newState *ContextStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ContextStatusRequest) SyncEffectiveFieldsDuringRead(existingState ContextStatusRequest) { } +func (a ContextStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ContextStatusResponse struct { Id types.String `tfsdk:"id" tf:"optional"` @@ -1186,6 +1422,10 @@ func (newState *ContextStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ContextStatusResponse) SyncEffectiveFieldsDuringRead(existingState ContextStatusResponse) { } +func (a ContextStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateCluster struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -1194,7 +1434,7 @@ type CreateCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -1203,20 +1443,20 @@ type CreateCluster struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes []AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes []AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // When specified, this clones libraries from a source cluster during the // creation of a new cluster. - CloneFrom []CloneCluster `tfsdk:"clone_from" tf:"optional,object"` + CloneFrom types.Object `tfsdk:"clone_from" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf []ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -1228,7 +1468,7 @@ type CreateCluster struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Data security mode decides what data governance model to use when // accessing data from a cluster. // @@ -1253,7 +1493,7 @@ type CreateCluster struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage []DockerImage `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -1271,12 +1511,12 @@ type CreateCluster struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes []GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts []InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // This field encodes, through a single value, the resources available to @@ -1314,7 +1554,7 @@ type CreateCluster struct { // JVM options to the driver and the executors via // `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` // respectively. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // An object containing a set of optional, user-specified environment // variable key-value pairs. Please note that key-value pair of the form // (X,Y) will be exported as is (i.e., `export X='Y'`) while launching the @@ -1328,7 +1568,7 @@ type CreateCluster struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of // available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. @@ -1336,9 +1576,9 @@ type CreateCluster struct { // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType []WorkloadType `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` } func (newState *CreateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCluster) { @@ -1347,6 +1587,24 @@ func (newState *CreateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateCluster) SyncEffectiveFieldsDuringRead(existingState CreateCluster) { } +func (a CreateCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + "AwsAttributes": reflect.TypeOf(AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(AzureAttributes{}), + "CloneFrom": reflect.TypeOf(CloneCluster{}), + "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), + "CustomTags": reflect.TypeOf(""), + "DockerImage": reflect.TypeOf(DockerImage{}), + "GcpAttributes": reflect.TypeOf(GcpAttributes{}), + "InitScripts": reflect.TypeOf(InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(""), + "WorkloadType": reflect.TypeOf(WorkloadType{}), + } +} + type CreateClusterResponse struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` } @@ -1357,6 +1615,10 @@ func (newState *CreateClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateClusterResponse) SyncEffectiveFieldsDuringRead(existingState CreateClusterResponse) { } +func (a CreateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateContext struct { // Running cluster id ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -1370,22 +1632,26 @@ func (newState *CreateContext) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateContext) SyncEffectiveFieldsDuringRead(existingState CreateContext) { } +func (a CreateContext) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateInstancePool struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. - AwsAttributes []InstancePoolAwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to instance pools running on Azure. If not specified // at pool creation, a set of default values will be used. - AzureAttributes []InstancePoolAzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: // // - Currently, Databricks allows at most 45 custom tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Defines the specification of the disks that will be attached to all spark // containers. - DiskSpec []DiskSpec `tfsdk:"disk_spec" tf:"optional,object"` + DiskSpec types.Object `tfsdk:"disk_spec" tf:"optional,object"` // Autoscaling Local Storage: when enabled, this instances in this pool will // dynamically acquire additional disk space when its Spark workers are // running low on disk space. In AWS, this feature requires specific AWS @@ -1394,7 +1660,7 @@ type CreateInstancePool struct { EnableElasticDisk types.Bool `tfsdk:"enable_elastic_disk" tf:"optional"` // Attributes related to instance pools running on Google Cloud Platform. If // not specified at pool creation, a set of default values will be used. - GcpAttributes []InstancePoolGcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -1419,12 +1685,12 @@ type CreateInstancePool struct { // :method:clusters/listNodeTypes API call. NodeTypeId types.String `tfsdk:"node_type_id" tf:""` // Custom Docker Image BYOC - PreloadedDockerImages []DockerImage `tfsdk:"preloaded_docker_images" tf:"optional"` + PreloadedDockerImages types.List `tfsdk:"preloaded_docker_images" tf:"optional"` // A list containing at most one preloaded Spark image version for the pool. // Pool-backed clusters started with the preloaded Spark version will start // faster. A list of available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. - PreloadedSparkVersions []types.String `tfsdk:"preloaded_spark_versions" tf:"optional"` + PreloadedSparkVersions types.List `tfsdk:"preloaded_spark_versions" tf:"optional"` } func (newState *CreateInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateInstancePool) { @@ -1433,6 +1699,18 @@ func (newState *CreateInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateInstancePool) SyncEffectiveFieldsDuringRead(existingState CreateInstancePool) { } +func (a CreateInstancePool) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), + "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), + "CustomTags": reflect.TypeOf(""), + "DiskSpec": reflect.TypeOf(DiskSpec{}), + "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), + "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), + "PreloadedSparkVersions": reflect.TypeOf(""), + } +} + type CreateInstancePoolResponse struct { // The ID of the created instance pool. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` @@ -1444,6 +1722,10 @@ func (newState *CreateInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState CreateInstancePoolResponse) { } +func (a CreateInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreatePolicy struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -1454,7 +1736,7 @@ type CreatePolicy struct { Description types.String `tfsdk:"description" tf:"optional"` // A list of libraries to be installed on the next cluster restart that uses // this policy. The maximum number of libraries is 500. - Libraries []Library `tfsdk:"libraries" tf:"optional"` + Libraries types.List `tfsdk:"libraries" tf:"optional"` // Max number of clusters per user that can be active using this policy. If // not present, there is no max limit. MaxClustersPerUser types.Int64 `tfsdk:"max_clusters_per_user" tf:"optional"` @@ -1486,6 +1768,12 @@ func (newState *CreatePolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreatePolicy) SyncEffectiveFieldsDuringRead(existingState CreatePolicy) { } +func (a CreatePolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Libraries": reflect.TypeOf(Library{}), + } +} + type CreatePolicyResponse struct { // Canonical unique identifier for the cluster policy. PolicyId types.String `tfsdk:"policy_id" tf:"optional"` @@ -1497,6 +1785,10 @@ func (newState *CreatePolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreatePolicyResponse) SyncEffectiveFieldsDuringRead(existingState CreatePolicyResponse) { } +func (a CreatePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateResponse struct { // The global init script ID. ScriptId types.String `tfsdk:"script_id" tf:"optional"` @@ -1508,6 +1800,10 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Created struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -1518,6 +1814,10 @@ func (newState *Created) SyncEffectiveFieldsDuringCreateOrUpdate(plan Created) { func (newState *Created) SyncEffectiveFieldsDuringRead(existingState Created) { } +func (a Created) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DataPlaneEventDetails struct { // EventType types.String `tfsdk:"event_type" tf:"optional"` @@ -1535,6 +1835,10 @@ func (newState *DataPlaneEventDetails) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DataPlaneEventDetails) SyncEffectiveFieldsDuringRead(existingState DataPlaneEventDetails) { } +func (a DataPlaneEventDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DbfsStorageInfo struct { // dbfs destination, e.g. `dbfs:/my/path` Destination types.String `tfsdk:"destination" tf:""` @@ -1546,6 +1850,10 @@ func (newState *DbfsStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Db func (newState *DbfsStorageInfo) SyncEffectiveFieldsDuringRead(existingState DbfsStorageInfo) { } +func (a DbfsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteCluster struct { // The cluster to be terminated. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -1557,6 +1865,10 @@ func (newState *DeleteCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dele func (newState *DeleteCluster) SyncEffectiveFieldsDuringRead(existingState DeleteCluster) { } +func (a DeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteClusterResponse struct { } @@ -1566,6 +1878,10 @@ func (newState *DeleteClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteClusterResponse) SyncEffectiveFieldsDuringRead(existingState DeleteClusterResponse) { } +func (a DeleteClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete init script type DeleteGlobalInitScriptRequest struct { // The ID of the global init script. @@ -1578,6 +1894,10 @@ func (newState *DeleteGlobalInitScriptRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteGlobalInitScriptRequest) SyncEffectiveFieldsDuringRead(existingState DeleteGlobalInitScriptRequest) { } +func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteInstancePool struct { // The instance pool to be terminated. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:""` @@ -1589,6 +1909,10 @@ func (newState *DeleteInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteInstancePool) SyncEffectiveFieldsDuringRead(existingState DeleteInstancePool) { } +func (a DeleteInstancePool) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteInstancePoolResponse struct { } @@ -1598,6 +1922,10 @@ func (newState *DeleteInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState DeleteInstancePoolResponse) { } +func (a DeleteInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeletePolicy struct { // The ID of the policy to delete. PolicyId types.String `tfsdk:"policy_id" tf:""` @@ -1609,6 +1937,10 @@ func (newState *DeletePolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delet func (newState *DeletePolicy) SyncEffectiveFieldsDuringRead(existingState DeletePolicy) { } +func (a DeletePolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeletePolicyResponse struct { } @@ -1618,6 +1950,10 @@ func (newState *DeletePolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeletePolicyResponse) SyncEffectiveFieldsDuringRead(existingState DeletePolicyResponse) { } +func (a DeletePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -1627,6 +1963,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DestroyContext struct { ClusterId types.String `tfsdk:"clusterId" tf:""` @@ -1639,6 +1979,10 @@ func (newState *DestroyContext) SyncEffectiveFieldsDuringCreateOrUpdate(plan Des func (newState *DestroyContext) SyncEffectiveFieldsDuringRead(existingState DestroyContext) { } +func (a DestroyContext) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DestroyResponse struct { } @@ -1648,6 +1992,10 @@ func (newState *DestroyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan De func (newState *DestroyResponse) SyncEffectiveFieldsDuringRead(existingState DestroyResponse) { } +func (a DestroyResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DiskSpec struct { // The number of disks launched for each instance: - This feature is only // enabled for supported node types. - Users can choose up to the limit of @@ -1680,7 +2028,7 @@ type DiskSpec struct { DiskThroughput types.Int64 `tfsdk:"disk_throughput" tf:"optional"` // The type of disks that will be launched with this cluster. - DiskType []DiskType `tfsdk:"disk_type" tf:"optional,object"` + DiskType types.Object `tfsdk:"disk_type" tf:"optional,object"` } func (newState *DiskSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskSpec) { @@ -1689,6 +2037,12 @@ func (newState *DiskSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskSpec) func (newState *DiskSpec) SyncEffectiveFieldsDuringRead(existingState DiskSpec) { } +func (a DiskSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DiskType": reflect.TypeOf(DiskType{}), + } +} + type DiskType struct { AzureDiskVolumeType types.String `tfsdk:"azure_disk_volume_type" tf:"optional"` @@ -1701,6 +2055,10 @@ func (newState *DiskType) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskType) func (newState *DiskType) SyncEffectiveFieldsDuringRead(existingState DiskType) { } +func (a DiskType) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DockerBasicAuth struct { // Password of the user Password types.String `tfsdk:"password" tf:"optional"` @@ -1714,8 +2072,12 @@ func (newState *DockerBasicAuth) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DockerBasicAuth) SyncEffectiveFieldsDuringRead(existingState DockerBasicAuth) { } +func (a DockerBasicAuth) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DockerImage struct { - BasicAuth []DockerBasicAuth `tfsdk:"basic_auth" tf:"optional,object"` + BasicAuth types.Object `tfsdk:"basic_auth" tf:"optional,object"` // URL of the docker image. Url types.String `tfsdk:"url" tf:"optional"` } @@ -1726,6 +2088,12 @@ func (newState *DockerImage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Docker func (newState *DockerImage) SyncEffectiveFieldsDuringRead(existingState DockerImage) { } +func (a DockerImage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "BasicAuth": reflect.TypeOf(DockerBasicAuth{}), + } +} + type EditCluster struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -1734,7 +2102,7 @@ type EditCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -1743,10 +2111,10 @@ type EditCluster struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes []AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes []AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // ID of the cluster ClusterId types.String `tfsdk:"cluster_id" tf:""` // The configuration for delivering spark logs to a long-term storage @@ -1755,7 +2123,7 @@ type EditCluster struct { // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf []ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -1767,7 +2135,7 @@ type EditCluster struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Data security mode decides what data governance model to use when // accessing data from a cluster. // @@ -1792,7 +2160,7 @@ type EditCluster struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage []DockerImage `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -1810,12 +2178,12 @@ type EditCluster struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes []GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts []InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // This field encodes, through a single value, the resources available to @@ -1853,7 +2221,7 @@ type EditCluster struct { // JVM options to the driver and the executors via // `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` // respectively. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // An object containing a set of optional, user-specified environment // variable key-value pairs. Please note that key-value pair of the form // (X,Y) will be exported as is (i.e., `export X='Y'`) while launching the @@ -1867,7 +2235,7 @@ type EditCluster struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of // available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. @@ -1875,9 +2243,9 @@ type EditCluster struct { // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType []WorkloadType `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` } func (newState *EditCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditCluster) { @@ -1886,6 +2254,23 @@ func (newState *EditCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditCl func (newState *EditCluster) SyncEffectiveFieldsDuringRead(existingState EditCluster) { } +func (a EditCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + "AwsAttributes": reflect.TypeOf(AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(AzureAttributes{}), + "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), + "CustomTags": reflect.TypeOf(""), + "DockerImage": reflect.TypeOf(DockerImage{}), + "GcpAttributes": reflect.TypeOf(GcpAttributes{}), + "InitScripts": reflect.TypeOf(InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(""), + "WorkloadType": reflect.TypeOf(WorkloadType{}), + } +} + type EditClusterResponse struct { } @@ -1895,13 +2280,17 @@ func (newState *EditClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *EditClusterResponse) SyncEffectiveFieldsDuringRead(existingState EditClusterResponse) { } +func (a EditClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EditInstancePool struct { // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: // // - Currently, Databricks allows at most 45 custom tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -1935,6 +2324,12 @@ func (newState *EditInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *EditInstancePool) SyncEffectiveFieldsDuringRead(existingState EditInstancePool) { } +func (a EditInstancePool) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CustomTags": reflect.TypeOf(""), + } +} + type EditInstancePoolResponse struct { } @@ -1944,6 +2339,10 @@ func (newState *EditInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EditInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState EditInstancePoolResponse) { } +func (a EditInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EditPolicy struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -1954,7 +2353,7 @@ type EditPolicy struct { Description types.String `tfsdk:"description" tf:"optional"` // A list of libraries to be installed on the next cluster restart that uses // this policy. The maximum number of libraries is 500. - Libraries []Library `tfsdk:"libraries" tf:"optional"` + Libraries types.List `tfsdk:"libraries" tf:"optional"` // Max number of clusters per user that can be active using this policy. If // not present, there is no max limit. MaxClustersPerUser types.Int64 `tfsdk:"max_clusters_per_user" tf:"optional"` @@ -1988,6 +2387,12 @@ func (newState *EditPolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditPol func (newState *EditPolicy) SyncEffectiveFieldsDuringRead(existingState EditPolicy) { } +func (a EditPolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Libraries": reflect.TypeOf(Library{}), + } +} + type EditPolicyResponse struct { } @@ -1997,6 +2402,10 @@ func (newState *EditPolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EditPolicyResponse) SyncEffectiveFieldsDuringRead(existingState EditPolicyResponse) { } +func (a EditPolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EditResponse struct { } @@ -2006,6 +2415,10 @@ func (newState *EditResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditR func (newState *EditResponse) SyncEffectiveFieldsDuringRead(existingState EditResponse) { } +func (a EditResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EnforceClusterComplianceRequest struct { // The ID of the cluster you want to enforce policy compliance on. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -2020,10 +2433,14 @@ func (newState *EnforceClusterComplianceRequest) SyncEffectiveFieldsDuringCreate func (newState *EnforceClusterComplianceRequest) SyncEffectiveFieldsDuringRead(existingState EnforceClusterComplianceRequest) { } +func (a EnforceClusterComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EnforceClusterComplianceResponse struct { // A list of changes that have been made to the cluster settings for the // cluster to become compliant with its policy. - Changes []ClusterSettingsChange `tfsdk:"changes" tf:"optional"` + Changes types.List `tfsdk:"changes" tf:"optional"` // Whether any changes have been made to the cluster settings for the // cluster to become compliant with its policy. HasChanges types.Bool `tfsdk:"has_changes" tf:"optional"` @@ -2035,6 +2452,12 @@ func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringCreat func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringRead(existingState EnforceClusterComplianceResponse) { } +func (a EnforceClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Changes": reflect.TypeOf(ClusterSettingsChange{}), + } +} + // The environment entity used to preserve serverless environment side panel and // jobs' environment for non-notebook task. In this minimal environment spec, // only pip dependencies are supported. @@ -2050,7 +2473,7 @@ type Environment struct { // dependency could be , , (WSFS or Volumes in Databricks), E.g. // dependencies: ["foo==0.0.1", "-r /Workspace/test/requirements.txt"] - Dependencies []types.String `tfsdk:"dependencies" tf:"optional"` + Dependencies types.List `tfsdk:"dependencies" tf:"optional"` } func (newState *Environment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Environment) { @@ -2059,14 +2482,20 @@ func (newState *Environment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Enviro func (newState *Environment) SyncEffectiveFieldsDuringRead(existingState Environment) { } +func (a Environment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dependencies": reflect.TypeOf(""), + } +} + type EventDetails struct { // * For created clusters, the attributes of the cluster. * For edited // clusters, the new attributes of the cluster. - Attributes []ClusterAttributes `tfsdk:"attributes" tf:"optional,object"` + Attributes types.Object `tfsdk:"attributes" tf:"optional,object"` // The cause of a change in target size. Cause types.String `tfsdk:"cause" tf:"optional"` // The actual cluster size that was set in the cluster creation or edit. - ClusterSize []ClusterSize `tfsdk:"cluster_size" tf:"optional,object"` + ClusterSize types.Object `tfsdk:"cluster_size" tf:"optional,object"` // The current number of vCPUs in the cluster. CurrentNumVcpus types.Int64 `tfsdk:"current_num_vcpus" tf:"optional"` // The current number of nodes in the cluster. @@ -2084,7 +2513,7 @@ type EventDetails struct { FreeSpace types.Int64 `tfsdk:"free_space" tf:"optional"` // List of global and cluster init scripts associated with this cluster // event. - InitScripts []InitScriptEventDetails `tfsdk:"init_scripts" tf:"optional,object"` + InitScripts types.Object `tfsdk:"init_scripts" tf:"optional,object"` // Instance Id where the event originated from InstanceId types.String `tfsdk:"instance_id" tf:"optional"` // Unique identifier of the specific job run associated with this cluster @@ -2092,15 +2521,15 @@ type EventDetails struct { // cluster name JobRunName types.String `tfsdk:"job_run_name" tf:"optional"` // The cluster attributes before a cluster was edited. - PreviousAttributes []ClusterAttributes `tfsdk:"previous_attributes" tf:"optional,object"` + PreviousAttributes types.Object `tfsdk:"previous_attributes" tf:"optional,object"` // The size of the cluster before an edit or resize. - PreviousClusterSize []ClusterSize `tfsdk:"previous_cluster_size" tf:"optional,object"` + PreviousClusterSize types.Object `tfsdk:"previous_cluster_size" tf:"optional,object"` // Previous disk size in bytes PreviousDiskSize types.Int64 `tfsdk:"previous_disk_size" tf:"optional"` // A termination reason: * On a TERMINATED event, this is the reason of the // termination. * On a RESIZE_COMPLETE event, this indicates the reason that // we failed to acquire some nodes. - Reason []TerminationReason `tfsdk:"reason" tf:"optional,object"` + Reason types.Object `tfsdk:"reason" tf:"optional,object"` // The targeted number of vCPUs in the cluster. TargetNumVcpus types.Int64 `tfsdk:"target_num_vcpus" tf:"optional"` // The targeted number of nodes in the cluster. @@ -2116,6 +2545,17 @@ func (newState *EventDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Event func (newState *EventDetails) SyncEffectiveFieldsDuringRead(existingState EventDetails) { } +func (a EventDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Attributes": reflect.TypeOf(ClusterAttributes{}), + "ClusterSize": reflect.TypeOf(ClusterSize{}), + "InitScripts": reflect.TypeOf(InitScriptEventDetails{}), + "PreviousAttributes": reflect.TypeOf(ClusterAttributes{}), + "PreviousClusterSize": reflect.TypeOf(ClusterSize{}), + "Reason": reflect.TypeOf(TerminationReason{}), + } +} + type GcpAttributes struct { // This field determines whether the instance pool will contain preemptible // VMs, on-demand VMs, or preemptible VMs with a fallback to on-demand VMs @@ -2156,6 +2596,10 @@ func (newState *GcpAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpA func (newState *GcpAttributes) SyncEffectiveFieldsDuringRead(existingState GcpAttributes) { } +func (a GcpAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GcsStorageInfo struct { // GCS destination/URI, e.g. `gs://my-bucket/some-prefix` Destination types.String `tfsdk:"destination" tf:""` @@ -2167,6 +2611,10 @@ func (newState *GcsStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Gcs func (newState *GcsStorageInfo) SyncEffectiveFieldsDuringRead(existingState GcsStorageInfo) { } +func (a GcsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get cluster policy compliance type GetClusterComplianceRequest struct { // The ID of the cluster to get the compliance status @@ -2179,6 +2627,10 @@ func (newState *GetClusterComplianceRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetClusterComplianceRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterComplianceRequest) { } +func (a GetClusterComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetClusterComplianceResponse struct { // Whether the cluster is compliant with its policy or not. Clusters could // be out of compliance if the policy was updated after the cluster was last @@ -2188,7 +2640,7 @@ type GetClusterComplianceResponse struct { // validation errors. The keys indicate the path where the policy validation // error is occurring. The values indicate an error message describing the // policy validation error. - Violations map[string]types.String `tfsdk:"violations" tf:"optional"` + Violations types.Map `tfsdk:"violations" tf:"optional"` } func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetClusterComplianceResponse) { @@ -2197,6 +2649,12 @@ func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterComplianceResponse) { } +func (a GetClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Violations": reflect.TypeOf(""), + } +} + // Get cluster permission levels type GetClusterPermissionLevelsRequest struct { // The cluster for which to get or manage permissions. @@ -2209,9 +2667,13 @@ func (newState *GetClusterPermissionLevelsRequest) SyncEffectiveFieldsDuringCrea func (newState *GetClusterPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionLevelsRequest) { } +func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetClusterPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []ClusterPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetClusterPermissionLevelsResponse) { @@ -2220,6 +2682,12 @@ func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringCre func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionLevelsResponse) { } +func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(ClusterPermissionsDescription{}), + } +} + // Get cluster permissions type GetClusterPermissionsRequest struct { // The cluster for which to get or manage permissions. @@ -2232,6 +2700,10 @@ func (newState *GetClusterPermissionsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *GetClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionsRequest) { } +func (a GetClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get cluster policy permission levels type GetClusterPolicyPermissionLevelsRequest struct { // The cluster policy for which to get or manage permissions. @@ -2244,9 +2716,13 @@ func (newState *GetClusterPolicyPermissionLevelsRequest) SyncEffectiveFieldsDuri func (newState *GetClusterPolicyPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionLevelsRequest) { } +func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetClusterPolicyPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []ClusterPolicyPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetClusterPolicyPermissionLevelsResponse) { @@ -2255,6 +2731,12 @@ func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDur func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionLevelsResponse) { } +func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(ClusterPolicyPermissionsDescription{}), + } +} + // Get cluster policy permissions type GetClusterPolicyPermissionsRequest struct { // The cluster policy for which to get or manage permissions. @@ -2267,6 +2749,10 @@ func (newState *GetClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringCre func (newState *GetClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionsRequest) { } +func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a cluster policy type GetClusterPolicyRequest struct { // Canonical unique identifier for the Cluster Policy. @@ -2279,6 +2765,10 @@ func (newState *GetClusterPolicyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetClusterPolicyRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyRequest) { } +func (a GetClusterPolicyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get cluster info type GetClusterRequest struct { // The cluster about which to retrieve information. @@ -2291,6 +2781,10 @@ func (newState *GetClusterRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetClusterRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterRequest) { } +func (a GetClusterRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetEvents struct { // The ID of the cluster to retrieve events about. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -2299,7 +2793,7 @@ type GetEvents struct { EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` // An optional set of event types to filter on. If empty, all event types // are returned. - EventTypes []types.String `tfsdk:"event_types" tf:"optional"` + EventTypes types.List `tfsdk:"event_types" tf:"optional"` // The maximum number of events to include in a page of events. Defaults to // 50, and maximum allowed value is 500. Limit types.Int64 `tfsdk:"limit" tf:"optional"` @@ -2320,12 +2814,18 @@ func (newState *GetEvents) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetEvent func (newState *GetEvents) SyncEffectiveFieldsDuringRead(existingState GetEvents) { } +func (a GetEvents) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EventTypes": reflect.TypeOf(""), + } +} + type GetEventsResponse struct { // - Events []ClusterEvent `tfsdk:"events" tf:"optional"` + Events types.List `tfsdk:"events" tf:"optional"` // The parameters required to retrieve the next page of events. Omitted if // there are no more events to read. - NextPage []GetEvents `tfsdk:"next_page" tf:"optional,object"` + NextPage types.Object `tfsdk:"next_page" tf:"optional,object"` // The total number of events filtered by the start_time, end_time, and // event_types. TotalCount types.Int64 `tfsdk:"total_count" tf:"optional"` @@ -2337,6 +2837,13 @@ func (newState *GetEventsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetEventsResponse) SyncEffectiveFieldsDuringRead(existingState GetEventsResponse) { } +func (a GetEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Events": reflect.TypeOf(ClusterEvent{}), + "NextPage": reflect.TypeOf(GetEvents{}), + } +} + // Get an init script type GetGlobalInitScriptRequest struct { // The ID of the global init script. @@ -2349,19 +2856,23 @@ func (newState *GetGlobalInitScriptRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetGlobalInitScriptRequest) SyncEffectiveFieldsDuringRead(existingState GetGlobalInitScriptRequest) { } +func (a GetGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetInstancePool struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. - AwsAttributes []InstancePoolAwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to instance pools running on Azure. If not specified // at pool creation, a set of default values will be used. - AzureAttributes []InstancePoolAzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: // // - Currently, Databricks allows at most 45 custom tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Tags that are added by Databricks regardless of any `custom_tags`, // including: // @@ -2372,10 +2883,10 @@ type GetInstancePool struct { // - InstancePoolName: // // - InstancePoolId: - DefaultTags map[string]types.String `tfsdk:"default_tags" tf:"optional"` + DefaultTags types.Map `tfsdk:"default_tags" tf:"optional"` // Defines the specification of the disks that will be attached to all spark // containers. - DiskSpec []DiskSpec `tfsdk:"disk_spec" tf:"optional,object"` + DiskSpec types.Object `tfsdk:"disk_spec" tf:"optional,object"` // Autoscaling Local Storage: when enabled, this instances in this pool will // dynamically acquire additional disk space when its Spark workers are // running low on disk space. In AWS, this feature requires specific AWS @@ -2384,7 +2895,7 @@ type GetInstancePool struct { EnableElasticDisk types.Bool `tfsdk:"enable_elastic_disk" tf:"optional"` // Attributes related to instance pools running on Google Cloud Platform. If // not specified at pool creation, a set of default values will be used. - GcpAttributes []InstancePoolGcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -2411,18 +2922,18 @@ type GetInstancePool struct { // :method:clusters/listNodeTypes API call. NodeTypeId types.String `tfsdk:"node_type_id" tf:"optional"` // Custom Docker Image BYOC - PreloadedDockerImages []DockerImage `tfsdk:"preloaded_docker_images" tf:"optional"` + PreloadedDockerImages types.List `tfsdk:"preloaded_docker_images" tf:"optional"` // A list containing at most one preloaded Spark image version for the pool. // Pool-backed clusters started with the preloaded Spark version will start // faster. A list of available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. - PreloadedSparkVersions []types.String `tfsdk:"preloaded_spark_versions" tf:"optional"` + PreloadedSparkVersions types.List `tfsdk:"preloaded_spark_versions" tf:"optional"` // Current state of the instance pool. State types.String `tfsdk:"state" tf:"optional"` // Usage statistics about the instance pool. - Stats []InstancePoolStats `tfsdk:"stats" tf:"optional,object"` + Stats types.Object `tfsdk:"stats" tf:"optional,object"` // Status of failed pending instances in the pool. - Status []InstancePoolStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` } func (newState *GetInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetInstancePool) { @@ -2431,6 +2942,21 @@ func (newState *GetInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetInstancePool) SyncEffectiveFieldsDuringRead(existingState GetInstancePool) { } +func (a GetInstancePool) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), + "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), + "CustomTags": reflect.TypeOf(""), + "DefaultTags": reflect.TypeOf(""), + "DiskSpec": reflect.TypeOf(DiskSpec{}), + "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), + "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), + "PreloadedSparkVersions": reflect.TypeOf(""), + "Stats": reflect.TypeOf(InstancePoolStats{}), + "Status": reflect.TypeOf(InstancePoolStatus{}), + } +} + // Get instance pool permission levels type GetInstancePoolPermissionLevelsRequest struct { // The instance pool for which to get or manage permissions. @@ -2443,9 +2969,13 @@ func (newState *GetInstancePoolPermissionLevelsRequest) SyncEffectiveFieldsDurin func (newState *GetInstancePoolPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionLevelsRequest) { } +func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetInstancePoolPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []InstancePoolPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetInstancePoolPermissionLevelsResponse) { @@ -2454,6 +2984,12 @@ func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuri func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionLevelsResponse) { } +func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(InstancePoolPermissionsDescription{}), + } +} + // Get instance pool permissions type GetInstancePoolPermissionsRequest struct { // The instance pool for which to get or manage permissions. @@ -2466,6 +3002,10 @@ func (newState *GetInstancePoolPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *GetInstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionsRequest) { } +func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get instance pool information type GetInstancePoolRequest struct { // The canonical unique identifier for the instance pool. @@ -2478,6 +3018,10 @@ func (newState *GetInstancePoolRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetInstancePoolRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolRequest) { } +func (a GetInstancePoolRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get policy family information type GetPolicyFamilyRequest struct { // The family ID about which to retrieve information. @@ -2493,9 +3037,13 @@ func (newState *GetPolicyFamilyRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPolicyFamilyRequest) SyncEffectiveFieldsDuringRead(existingState GetPolicyFamilyRequest) { } +func (a GetPolicyFamilyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetSparkVersionsResponse struct { // All the available Spark versions. - Versions []SparkVersion `tfsdk:"versions" tf:"optional"` + Versions types.List `tfsdk:"versions" tf:"optional"` } func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetSparkVersionsResponse) { @@ -2504,6 +3052,12 @@ func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringRead(existingState GetSparkVersionsResponse) { } +func (a GetSparkVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Versions": reflect.TypeOf(SparkVersion{}), + } +} + type GlobalInitScriptCreateRequest struct { // Specifies whether the script is enabled. The script runs only if enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -2531,6 +3085,10 @@ func (newState *GlobalInitScriptCreateRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GlobalInitScriptCreateRequest) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptCreateRequest) { } +func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GlobalInitScriptDetails struct { // Time when the script was created, represented as a Unix timestamp in // milliseconds. @@ -2559,6 +3117,10 @@ func (newState *GlobalInitScriptDetails) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GlobalInitScriptDetails) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptDetails) { } +func (a GlobalInitScriptDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GlobalInitScriptDetailsWithContent struct { // Time when the script was created, represented as a Unix timestamp in // milliseconds. @@ -2589,6 +3151,10 @@ func (newState *GlobalInitScriptDetailsWithContent) SyncEffectiveFieldsDuringCre func (newState *GlobalInitScriptDetailsWithContent) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptDetailsWithContent) { } +func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GlobalInitScriptUpdateRequest struct { // Specifies whether the script is enabled. The script runs only if enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -2619,11 +3185,15 @@ func (newState *GlobalInitScriptUpdateRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GlobalInitScriptUpdateRequest) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptUpdateRequest) { } +func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InitScriptEventDetails struct { // The cluster scoped init scripts associated with this cluster event - Cluster []InitScriptInfoAndExecutionDetails `tfsdk:"cluster" tf:"optional"` + Cluster types.List `tfsdk:"cluster" tf:"optional"` // The global init scripts associated with this cluster event - Global []InitScriptInfoAndExecutionDetails `tfsdk:"global" tf:"optional"` + Global types.List `tfsdk:"global" tf:"optional"` // The private ip address of the node where the init scripts were run. ReportedForNode types.String `tfsdk:"reported_for_node" tf:"optional"` } @@ -2634,6 +3204,13 @@ func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptEventDetails) { } +func (a InitScriptEventDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Cluster": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), + "Global": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), + } +} + type InitScriptExecutionDetails struct { // Addition details regarding errors. ErrorMessage types.String `tfsdk:"error_message" tf:"optional"` @@ -2649,32 +3226,36 @@ func (newState *InitScriptExecutionDetails) SyncEffectiveFieldsDuringCreateOrUpd func (newState *InitScriptExecutionDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptExecutionDetails) { } +func (a InitScriptExecutionDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InitScriptInfo struct { // destination needs to be provided. e.g. `{ "abfss" : { "destination" : // "abfss://@.dfs.core.windows.net/" // } } - Abfss []Adlsgen2Info `tfsdk:"abfss" tf:"optional,object"` + Abfss types.Object `tfsdk:"abfss" tf:"optional,object"` // destination needs to be provided. e.g. `{ "dbfs" : { "destination" : // "dbfs:/home/cluster_log" } }` - Dbfs []DbfsStorageInfo `tfsdk:"dbfs" tf:"optional,object"` + Dbfs types.Object `tfsdk:"dbfs" tf:"optional,object"` // destination needs to be provided. e.g. `{ "file" : { "destination" : // "file:/my/local/file.sh" } }` - File []LocalFileInfo `tfsdk:"file" tf:"optional,object"` + File types.Object `tfsdk:"file" tf:"optional,object"` // destination needs to be provided. e.g. `{ "gcs": { "destination": // "gs://my-bucket/file.sh" } }` - Gcs []GcsStorageInfo `tfsdk:"gcs" tf:"optional,object"` + Gcs types.Object `tfsdk:"gcs" tf:"optional,object"` // destination and either the region or endpoint need to be provided. e.g. // `{ "s3": { "destination" : "s3://cluster_log_bucket/prefix", "region" : // "us-west-2" } }` Cluster iam role is used to access s3, please make sure // the cluster iam role in `instance_profile_arn` has permission to write // data to the s3 destination. - S3 []S3StorageInfo `tfsdk:"s3" tf:"optional,object"` + S3 types.Object `tfsdk:"s3" tf:"optional,object"` // destination needs to be provided. e.g. `{ "volumes" : { "destination" : // "/Volumes/my-init.sh" } }` - Volumes []VolumesStorageInfo `tfsdk:"volumes" tf:"optional,object"` + Volumes types.Object `tfsdk:"volumes" tf:"optional,object"` // destination needs to be provided. e.g. `{ "workspace" : { "destination" : // "/Users/user1@databricks.com/my-init.sh" } }` - Workspace []WorkspaceStorageInfo `tfsdk:"workspace" tf:"optional,object"` + Workspace types.Object `tfsdk:"workspace" tf:"optional,object"` } func (newState *InitScriptInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan InitScriptInfo) { @@ -2683,11 +3264,23 @@ func (newState *InitScriptInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ini func (newState *InitScriptInfo) SyncEffectiveFieldsDuringRead(existingState InitScriptInfo) { } +func (a InitScriptInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Abfss": reflect.TypeOf(Adlsgen2Info{}), + "Dbfs": reflect.TypeOf(DbfsStorageInfo{}), + "File": reflect.TypeOf(LocalFileInfo{}), + "Gcs": reflect.TypeOf(GcsStorageInfo{}), + "S3": reflect.TypeOf(S3StorageInfo{}), + "Volumes": reflect.TypeOf(VolumesStorageInfo{}), + "Workspace": reflect.TypeOf(WorkspaceStorageInfo{}), + } +} + type InitScriptInfoAndExecutionDetails struct { // Details about the script - ExecutionDetails []InitScriptExecutionDetails `tfsdk:"execution_details" tf:"optional,object"` + ExecutionDetails types.Object `tfsdk:"execution_details" tf:"optional,object"` // The script - Script []InitScriptInfo `tfsdk:"script" tf:"optional,object"` + Script types.Object `tfsdk:"script" tf:"optional,object"` } func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan InitScriptInfoAndExecutionDetails) { @@ -2696,11 +3289,18 @@ func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringCrea func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptInfoAndExecutionDetails) { } +func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExecutionDetails": reflect.TypeOf(InitScriptExecutionDetails{}), + "Script": reflect.TypeOf(InitScriptInfo{}), + } +} + type InstallLibraries struct { // Unique identifier for the cluster on which to install these libraries. ClusterId types.String `tfsdk:"cluster_id" tf:""` // The libraries to install. - Libraries []Library `tfsdk:"libraries" tf:""` + Libraries types.List `tfsdk:"libraries" tf:""` } func (newState *InstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan InstallLibraries) { @@ -2709,6 +3309,12 @@ func (newState *InstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan I func (newState *InstallLibraries) SyncEffectiveFieldsDuringRead(existingState InstallLibraries) { } +func (a InstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Libraries": reflect.TypeOf(Library{}), + } +} + type InstallLibrariesResponse struct { } @@ -2718,6 +3324,10 @@ func (newState *InstallLibrariesResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *InstallLibrariesResponse) SyncEffectiveFieldsDuringRead(existingState InstallLibrariesResponse) { } +func (a InstallLibrariesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2735,9 +3345,13 @@ func (newState *InstancePoolAccessControlRequest) SyncEffectiveFieldsDuringCreat func (newState *InstancePoolAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState InstancePoolAccessControlRequest) { } +func (a InstancePoolAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolAccessControlResponse struct { // All permissions. - AllPermissions []InstancePoolPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -2754,19 +3368,25 @@ func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringCrea func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState InstancePoolAccessControlResponse) { } +func (a InstancePoolAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(InstancePoolPermission{}), + } +} + type InstancePoolAndStats struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. - AwsAttributes []InstancePoolAwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to instance pools running on Azure. If not specified // at pool creation, a set of default values will be used. - AzureAttributes []InstancePoolAzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: // // - Currently, Databricks allows at most 45 custom tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Tags that are added by Databricks regardless of any `custom_tags`, // including: // @@ -2777,10 +3397,10 @@ type InstancePoolAndStats struct { // - InstancePoolName: // // - InstancePoolId: - DefaultTags map[string]types.String `tfsdk:"default_tags" tf:"optional"` + DefaultTags types.Map `tfsdk:"default_tags" tf:"optional"` // Defines the specification of the disks that will be attached to all spark // containers. - DiskSpec []DiskSpec `tfsdk:"disk_spec" tf:"optional,object"` + DiskSpec types.Object `tfsdk:"disk_spec" tf:"optional,object"` // Autoscaling Local Storage: when enabled, this instances in this pool will // dynamically acquire additional disk space when its Spark workers are // running low on disk space. In AWS, this feature requires specific AWS @@ -2789,7 +3409,7 @@ type InstancePoolAndStats struct { EnableElasticDisk types.Bool `tfsdk:"enable_elastic_disk" tf:"optional"` // Attributes related to instance pools running on Google Cloud Platform. If // not specified at pool creation, a set of default values will be used. - GcpAttributes []InstancePoolGcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -2816,18 +3436,18 @@ type InstancePoolAndStats struct { // :method:clusters/listNodeTypes API call. NodeTypeId types.String `tfsdk:"node_type_id" tf:"optional"` // Custom Docker Image BYOC - PreloadedDockerImages []DockerImage `tfsdk:"preloaded_docker_images" tf:"optional"` + PreloadedDockerImages types.List `tfsdk:"preloaded_docker_images" tf:"optional"` // A list containing at most one preloaded Spark image version for the pool. // Pool-backed clusters started with the preloaded Spark version will start // faster. A list of available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. - PreloadedSparkVersions []types.String `tfsdk:"preloaded_spark_versions" tf:"optional"` + PreloadedSparkVersions types.List `tfsdk:"preloaded_spark_versions" tf:"optional"` // Current state of the instance pool. State types.String `tfsdk:"state" tf:"optional"` // Usage statistics about the instance pool. - Stats []InstancePoolStats `tfsdk:"stats" tf:"optional,object"` + Stats types.Object `tfsdk:"stats" tf:"optional,object"` // Status of failed pending instances in the pool. - Status []InstancePoolStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` } func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan InstancePoolAndStats) { @@ -2836,6 +3456,21 @@ func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringRead(existingState InstancePoolAndStats) { } +func (a InstancePoolAndStats) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), + "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), + "CustomTags": reflect.TypeOf(""), + "DefaultTags": reflect.TypeOf(""), + "DiskSpec": reflect.TypeOf(DiskSpec{}), + "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), + "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), + "PreloadedSparkVersions": reflect.TypeOf(""), + "Stats": reflect.TypeOf(InstancePoolStats{}), + "Status": reflect.TypeOf(InstancePoolStatus{}), + } +} + type InstancePoolAwsAttributes struct { // Availability type used for the spot nodes. // @@ -2874,6 +3509,10 @@ func (newState *InstancePoolAwsAttributes) SyncEffectiveFieldsDuringCreateOrUpda func (newState *InstancePoolAwsAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolAwsAttributes) { } +func (a InstancePoolAwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolAzureAttributes struct { // Shows the Availability type used for the spot nodes. // @@ -2891,6 +3530,10 @@ func (newState *InstancePoolAzureAttributes) SyncEffectiveFieldsDuringCreateOrUp func (newState *InstancePoolAzureAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolAzureAttributes) { } +func (a InstancePoolAzureAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolGcpAttributes struct { // This field determines whether the instance pool will contain preemptible // VMs, on-demand VMs, or preemptible VMs with a fallback to on-demand VMs @@ -2928,10 +3571,14 @@ func (newState *InstancePoolGcpAttributes) SyncEffectiveFieldsDuringCreateOrUpda func (newState *InstancePoolGcpAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolGcpAttributes) { } +func (a InstancePoolGcpAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -2942,8 +3589,14 @@ func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermission) { } +func (a InstancePoolPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type InstancePoolPermissions struct { - AccessControlList []InstancePoolAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -2956,6 +3609,12 @@ func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissions) { } +func (a InstancePoolPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(InstancePoolAccessControlResponse{}), + } +} + type InstancePoolPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2968,8 +3627,12 @@ func (newState *InstancePoolPermissionsDescription) SyncEffectiveFieldsDuringCre func (newState *InstancePoolPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissionsDescription) { } +func (a InstancePoolPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolPermissionsRequest struct { - AccessControlList []InstancePoolAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The instance pool for which to get or manage permissions. InstancePoolId types.String `tfsdk:"-"` } @@ -2980,6 +3643,12 @@ func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringCreateO func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissionsRequest) { } +func (a InstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(InstancePoolAccessControlRequest{}), + } +} + type InstancePoolStats struct { // Number of active instances in the pool that are NOT part of a cluster. IdleCount types.Int64 `tfsdk:"idle_count" tf:"optional"` @@ -2997,12 +3666,16 @@ func (newState *InstancePoolStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstancePoolStats) SyncEffectiveFieldsDuringRead(existingState InstancePoolStats) { } +func (a InstancePoolStats) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InstancePoolStatus struct { // List of error messages for the failed pending instances. The // pending_instance_errors follows FIFO with maximum length of the min_idle // of the pool. The pending_instance_errors is emptied once the number of // exiting available instances reaches the min_idle of the pool. - PendingInstanceErrors []PendingInstanceError `tfsdk:"pending_instance_errors" tf:"optional"` + PendingInstanceErrors types.List `tfsdk:"pending_instance_errors" tf:"optional"` } func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan InstancePoolStatus) { @@ -3011,6 +3684,12 @@ func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringRead(existingState InstancePoolStatus) { } +func (a InstancePoolStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PendingInstanceErrors": reflect.TypeOf(PendingInstanceError{}), + } +} + type InstanceProfile struct { // The AWS IAM role ARN of the role associated with the instance profile. // This field is required if your role name and instance profile name do not @@ -3038,9 +3717,13 @@ func (newState *InstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan In func (newState *InstanceProfile) SyncEffectiveFieldsDuringRead(existingState InstanceProfile) { } +func (a InstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Library struct { // Specification of a CRAN library to be installed as part of the library - Cran []RCranLibrary `tfsdk:"cran" tf:"optional,object"` + Cran types.Object `tfsdk:"cran" tf:"optional,object"` // Deprecated. URI of the egg library to install. Installing Python egg // files is deprecated and is not supported in Databricks Runtime 14.0 and // above. @@ -3055,10 +3738,10 @@ type Library struct { Jar types.String `tfsdk:"jar" tf:"optional"` // Specification of a maven library to be installed. For example: `{ // "coordinates": "org.jsoup:jsoup:1.7.2" }` - Maven []MavenLibrary `tfsdk:"maven" tf:"optional,object"` + Maven types.Object `tfsdk:"maven" tf:"optional,object"` // Specification of a PyPi library to be installed. For example: `{ // "package": "simplejson" }` - Pypi []PythonPyPiLibrary `tfsdk:"pypi" tf:"optional,object"` + Pypi types.Object `tfsdk:"pypi" tf:"optional,object"` // URI of the requirements.txt file to install. Only Workspace paths and // Unity Catalog Volumes paths are supported. For example: `{ // "requirements": "/Workspace/path/to/requirements.txt" }` or `{ @@ -3080,16 +3763,24 @@ func (newState *Library) SyncEffectiveFieldsDuringCreateOrUpdate(plan Library) { func (newState *Library) SyncEffectiveFieldsDuringRead(existingState Library) { } +func (a Library) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Cran": reflect.TypeOf(RCranLibrary{}), + "Maven": reflect.TypeOf(MavenLibrary{}), + "Pypi": reflect.TypeOf(PythonPyPiLibrary{}), + } +} + // The status of the library on a specific cluster. type LibraryFullStatus struct { // Whether the library was set to be installed on all clusters via the // libraries UI. IsLibraryForAllClusters types.Bool `tfsdk:"is_library_for_all_clusters" tf:"optional"` // Unique identifier for the library. - Library []Library `tfsdk:"library" tf:"optional,object"` + Library types.Object `tfsdk:"library" tf:"optional,object"` // All the info and warning messages that have occurred so far for this // library. - Messages []types.String `tfsdk:"messages" tf:"optional"` + Messages types.List `tfsdk:"messages" tf:"optional"` // Status of installing the library on the cluster. Status types.String `tfsdk:"status" tf:"optional"` } @@ -3100,9 +3791,16 @@ func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringRead(existingState LibraryFullStatus) { } +func (a LibraryFullStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Library": reflect.TypeOf(Library{}), + "Messages": reflect.TypeOf(""), + } +} + type ListAllClusterLibraryStatusesResponse struct { // A list of cluster statuses. - Statuses []ClusterLibraryStatuses `tfsdk:"statuses" tf:"optional"` + Statuses types.List `tfsdk:"statuses" tf:"optional"` } func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAllClusterLibraryStatusesResponse) { @@ -3111,12 +3809,18 @@ func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuring func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuringRead(existingState ListAllClusterLibraryStatusesResponse) { } +func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Statuses": reflect.TypeOf(ClusterLibraryStatuses{}), + } +} + type ListAvailableZonesResponse struct { // The availability zone if no `zone_id` is provided in the cluster creation // request. DefaultZone types.String `tfsdk:"default_zone" tf:"optional"` // The list of available zones (e.g., ['us-west-2c', 'us-east-2']). - Zones []types.String `tfsdk:"zones" tf:"optional"` + Zones types.List `tfsdk:"zones" tf:"optional"` } func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAvailableZonesResponse) { @@ -3125,6 +3829,12 @@ func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringRead(existingState ListAvailableZonesResponse) { } +func (a ListAvailableZonesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Zones": reflect.TypeOf(""), + } +} + // List cluster policy compliance type ListClusterCompliancesRequest struct { // Use this field to specify the maximum number of results to be returned by @@ -3144,9 +3854,13 @@ func (newState *ListClusterCompliancesRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListClusterCompliancesRequest) SyncEffectiveFieldsDuringRead(existingState ListClusterCompliancesRequest) { } +func (a ListClusterCompliancesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListClusterCompliancesResponse struct { // A list of clusters and their policy compliance statuses. - Clusters []ClusterCompliance `tfsdk:"clusters" tf:"optional"` + Clusters types.List `tfsdk:"clusters" tf:"optional"` // This field represents the pagination token to retrieve the next page of // results. If the value is "", it means no further results for the request. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -3162,6 +3876,12 @@ func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringRead(existingState ListClusterCompliancesResponse) { } +func (a ListClusterCompliancesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Clusters": reflect.TypeOf(ClusterCompliance{}), + } +} + // List cluster policies type ListClusterPoliciesRequest struct { // The cluster policy attribute to sort by. * `POLICY_CREATION_TIME` - Sort @@ -3179,11 +3899,15 @@ func (newState *ListClusterPoliciesRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListClusterPoliciesRequest) SyncEffectiveFieldsDuringRead(existingState ListClusterPoliciesRequest) { } +func (a ListClusterPoliciesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListClustersFilterBy struct { // The source of cluster creation. - ClusterSources []types.String `tfsdk:"cluster_sources" tf:"optional"` + ClusterSources types.List `tfsdk:"cluster_sources" tf:"optional"` // The current state of the clusters. - ClusterStates []types.String `tfsdk:"cluster_states" tf:"optional"` + ClusterStates types.List `tfsdk:"cluster_states" tf:"optional"` // Whether the clusters are pinned or not. IsPinned types.Bool `tfsdk:"is_pinned" tf:"optional"` // The ID of the cluster policy used to create the cluster if applicable. @@ -3196,10 +3920,17 @@ func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringRead(existingState ListClustersFilterBy) { } +func (a ListClustersFilterBy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ClusterSources": reflect.TypeOf(""), + "ClusterStates": reflect.TypeOf(""), + } +} + // List clusters type ListClustersRequest struct { // Filters to apply to the list of clusters. - FilterBy []ListClustersFilterBy `tfsdk:"-"` + FilterBy types.Object `tfsdk:"-"` // Use this field to specify the maximum number of results to be returned by // the server. The server may further constrain the maximum number of // results returned in a single page. @@ -3208,7 +3939,7 @@ type ListClustersRequest struct { // to list the next or previous page of clusters respectively. PageToken types.String `tfsdk:"-"` // Sort the list of clusters by a specific criteria. - SortBy []ListClustersSortBy `tfsdk:"-"` + SortBy types.Object `tfsdk:"-"` } func (newState *ListClustersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListClustersRequest) { @@ -3217,9 +3948,16 @@ func (newState *ListClustersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListClustersRequest) SyncEffectiveFieldsDuringRead(existingState ListClustersRequest) { } +func (a ListClustersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FilterBy": reflect.TypeOf(ListClustersFilterBy{}), + "SortBy": reflect.TypeOf(ListClustersSortBy{}), + } +} + type ListClustersResponse struct { // - Clusters []ClusterDetails `tfsdk:"clusters" tf:"optional"` + Clusters types.List `tfsdk:"clusters" tf:"optional"` // This field represents the pagination token to retrieve the next page of // results. If the value is "", it means no further results for the request. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -3235,6 +3973,12 @@ func (newState *ListClustersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListClustersResponse) SyncEffectiveFieldsDuringRead(existingState ListClustersResponse) { } +func (a ListClustersResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Clusters": reflect.TypeOf(ClusterDetails{}), + } +} + type ListClustersSortBy struct { // The direction to sort by. Direction types.String `tfsdk:"direction" tf:"optional"` @@ -3250,8 +3994,12 @@ func (newState *ListClustersSortBy) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListClustersSortBy) SyncEffectiveFieldsDuringRead(existingState ListClustersSortBy) { } +func (a ListClustersSortBy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListGlobalInitScriptsResponse struct { - Scripts []GlobalInitScriptDetails `tfsdk:"scripts" tf:"optional"` + Scripts types.List `tfsdk:"scripts" tf:"optional"` } func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListGlobalInitScriptsResponse) { @@ -3260,8 +4008,14 @@ func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringCreateOr func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringRead(existingState ListGlobalInitScriptsResponse) { } +func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Scripts": reflect.TypeOf(GlobalInitScriptDetails{}), + } +} + type ListInstancePools struct { - InstancePools []InstancePoolAndStats `tfsdk:"instance_pools" tf:"optional"` + InstancePools types.List `tfsdk:"instance_pools" tf:"optional"` } func (newState *ListInstancePools) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListInstancePools) { @@ -3270,9 +4024,15 @@ func (newState *ListInstancePools) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListInstancePools) SyncEffectiveFieldsDuringRead(existingState ListInstancePools) { } +func (a ListInstancePools) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InstancePools": reflect.TypeOf(InstancePoolAndStats{}), + } +} + type ListInstanceProfilesResponse struct { // A list of instance profiles that the user can access. - InstanceProfiles []InstanceProfile `tfsdk:"instance_profiles" tf:"optional"` + InstanceProfiles types.List `tfsdk:"instance_profiles" tf:"optional"` } func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListInstanceProfilesResponse) { @@ -3281,9 +4041,15 @@ func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringRead(existingState ListInstanceProfilesResponse) { } +func (a ListInstanceProfilesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InstanceProfiles": reflect.TypeOf(InstanceProfile{}), + } +} + type ListNodeTypesResponse struct { // The list of available Spark node types. - NodeTypes []NodeType `tfsdk:"node_types" tf:"optional"` + NodeTypes types.List `tfsdk:"node_types" tf:"optional"` } func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListNodeTypesResponse) { @@ -3292,9 +4058,15 @@ func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringRead(existingState ListNodeTypesResponse) { } +func (a ListNodeTypesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NodeTypes": reflect.TypeOf(NodeType{}), + } +} + type ListPoliciesResponse struct { // List of policies. - Policies []Policy `tfsdk:"policies" tf:"optional"` + Policies types.List `tfsdk:"policies" tf:"optional"` } func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListPoliciesResponse) { @@ -3303,6 +4075,12 @@ func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringRead(existingState ListPoliciesResponse) { } +func (a ListPoliciesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Policies": reflect.TypeOf(Policy{}), + } +} + // List policy families type ListPolicyFamiliesRequest struct { // Maximum number of policy families to return. @@ -3317,12 +4095,16 @@ func (newState *ListPolicyFamiliesRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListPolicyFamiliesRequest) SyncEffectiveFieldsDuringRead(existingState ListPolicyFamiliesRequest) { } +func (a ListPolicyFamiliesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListPolicyFamiliesResponse struct { // A token that can be used to get the next page of results. If not present, // there are no more results to show. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // List of policy families. - PolicyFamilies []PolicyFamily `tfsdk:"policy_families" tf:"optional"` + PolicyFamilies types.List `tfsdk:"policy_families" tf:"optional"` } func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListPolicyFamiliesResponse) { @@ -3331,6 +4113,12 @@ func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringRead(existingState ListPolicyFamiliesResponse) { } +func (a ListPolicyFamiliesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PolicyFamilies": reflect.TypeOf(PolicyFamily{}), + } +} + type LocalFileInfo struct { // local file destination, e.g. `file:/my/local/file.sh` Destination types.String `tfsdk:"destination" tf:""` @@ -3342,6 +4130,10 @@ func (newState *LocalFileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Loca func (newState *LocalFileInfo) SyncEffectiveFieldsDuringRead(existingState LocalFileInfo) { } +func (a LocalFileInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogAnalyticsInfo struct { // LogAnalyticsPrimaryKey types.String `tfsdk:"log_analytics_primary_key" tf:"optional"` @@ -3355,6 +4147,10 @@ func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringRead(existingState LogAnalyticsInfo) { } +func (a LogAnalyticsInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogSyncStatus struct { // The timestamp of last attempt. If the last attempt fails, // `last_exception` will contain the exception in the last attempt. @@ -3370,6 +4166,10 @@ func (newState *LogSyncStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogS func (newState *LogSyncStatus) SyncEffectiveFieldsDuringRead(existingState LogSyncStatus) { } +func (a LogSyncStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MavenLibrary struct { // Gradle-style maven coordinates. For example: "org.jsoup:jsoup:1.7.2". Coordinates types.String `tfsdk:"coordinates" tf:""` @@ -3378,7 +4178,7 @@ type MavenLibrary struct { // // Maven dependency exclusions: // https://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html. - Exclusions []types.String `tfsdk:"exclusions" tf:"optional"` + Exclusions types.List `tfsdk:"exclusions" tf:"optional"` // Maven repo to install the Maven package from. If omitted, both Maven // Central Repository and Spark Packages are searched. Repo types.String `tfsdk:"repo" tf:"optional"` @@ -3390,6 +4190,12 @@ func (newState *MavenLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Maven func (newState *MavenLibrary) SyncEffectiveFieldsDuringRead(existingState MavenLibrary) { } +func (a MavenLibrary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exclusions": reflect.TypeOf(""), + } +} + type NodeInstanceType struct { InstanceTypeId types.String `tfsdk:"instance_type_id" tf:"optional"` @@ -3408,6 +4214,10 @@ func (newState *NodeInstanceType) SyncEffectiveFieldsDuringCreateOrUpdate(plan N func (newState *NodeInstanceType) SyncEffectiveFieldsDuringRead(existingState NodeInstanceType) { } +func (a NodeInstanceType) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type NodeType struct { Category types.String `tfsdk:"category" tf:"optional"` // A string description associated with this node type, e.g., "r3.xlarge". @@ -3432,9 +4242,9 @@ type NodeType struct { // Memory (in MB) available for this node type. MemoryMb types.Int64 `tfsdk:"memory_mb" tf:""` - NodeInfo []CloudProviderNodeInfo `tfsdk:"node_info" tf:"optional,object"` + NodeInfo types.Object `tfsdk:"node_info" tf:"optional,object"` - NodeInstanceType []NodeInstanceType `tfsdk:"node_instance_type" tf:"optional,object"` + NodeInstanceType types.Object `tfsdk:"node_instance_type" tf:"optional,object"` // Unique identifier for this node type. NodeTypeId types.String `tfsdk:"node_type_id" tf:""` // Number of CPU cores available for this node type. Note that this can be @@ -3464,6 +4274,13 @@ func (newState *NodeType) SyncEffectiveFieldsDuringCreateOrUpdate(plan NodeType) func (newState *NodeType) SyncEffectiveFieldsDuringRead(existingState NodeType) { } +func (a NodeType) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NodeInfo": reflect.TypeOf(CloudProviderNodeInfo{}), + "NodeInstanceType": reflect.TypeOf(NodeInstanceType{}), + } +} + type PendingInstanceError struct { InstanceId types.String `tfsdk:"instance_id" tf:"optional"` @@ -3476,6 +4293,10 @@ func (newState *PendingInstanceError) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PendingInstanceError) SyncEffectiveFieldsDuringRead(existingState PendingInstanceError) { } +func (a PendingInstanceError) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PermanentDeleteCluster struct { // The cluster to be deleted. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -3487,6 +4308,10 @@ func (newState *PermanentDeleteCluster) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PermanentDeleteCluster) SyncEffectiveFieldsDuringRead(existingState PermanentDeleteCluster) { } +func (a PermanentDeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PermanentDeleteClusterResponse struct { } @@ -3496,6 +4321,10 @@ func (newState *PermanentDeleteClusterResponse) SyncEffectiveFieldsDuringCreateO func (newState *PermanentDeleteClusterResponse) SyncEffectiveFieldsDuringRead(existingState PermanentDeleteClusterResponse) { } +func (a PermanentDeleteClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PinCluster struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -3507,6 +4336,10 @@ func (newState *PinCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan PinClus func (newState *PinCluster) SyncEffectiveFieldsDuringRead(existingState PinCluster) { } +func (a PinCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PinClusterResponse struct { } @@ -3516,6 +4349,10 @@ func (newState *PinClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PinClusterResponse) SyncEffectiveFieldsDuringRead(existingState PinClusterResponse) { } +func (a PinClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Describes a Cluster Policy entity. type Policy struct { // Creation time. The timestamp (in millisecond) when this Cluster Policy @@ -3537,7 +4374,7 @@ type Policy struct { IsDefault types.Bool `tfsdk:"is_default" tf:"optional"` // A list of libraries to be installed on the next cluster restart that uses // this policy. The maximum number of libraries is 500. - Libraries []Library `tfsdk:"libraries" tf:"optional"` + Libraries types.List `tfsdk:"libraries" tf:"optional"` // Max number of clusters per user that can be active using this policy. If // not present, there is no max limit. MaxClustersPerUser types.Int64 `tfsdk:"max_clusters_per_user" tf:"optional"` @@ -3571,6 +4408,12 @@ func (newState *Policy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Policy) { func (newState *Policy) SyncEffectiveFieldsDuringRead(existingState Policy) { } +func (a Policy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Libraries": reflect.TypeOf(Library{}), + } +} + type PolicyFamily struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -3591,6 +4434,10 @@ func (newState *PolicyFamily) SyncEffectiveFieldsDuringCreateOrUpdate(plan Polic func (newState *PolicyFamily) SyncEffectiveFieldsDuringRead(existingState PolicyFamily) { } +func (a PolicyFamily) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PythonPyPiLibrary struct { // The name of the pypi package to install. An optional exact version // specification is also supported. Examples: "simplejson" and @@ -3607,6 +4454,10 @@ func (newState *PythonPyPiLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PythonPyPiLibrary) SyncEffectiveFieldsDuringRead(existingState PythonPyPiLibrary) { } +func (a PythonPyPiLibrary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RCranLibrary struct { // The name of the CRAN package to install. Package types.String `tfsdk:"package" tf:""` @@ -3621,6 +4472,10 @@ func (newState *RCranLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan RCran func (newState *RCranLibrary) SyncEffectiveFieldsDuringRead(existingState RCranLibrary) { } +func (a RCranLibrary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RemoveInstanceProfile struct { // The ARN of the instance profile to remove. This field is required. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:""` @@ -3632,6 +4487,10 @@ func (newState *RemoveInstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *RemoveInstanceProfile) SyncEffectiveFieldsDuringRead(existingState RemoveInstanceProfile) { } +func (a RemoveInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RemoveResponse struct { } @@ -3641,11 +4500,15 @@ func (newState *RemoveResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rem func (newState *RemoveResponse) SyncEffectiveFieldsDuringRead(existingState RemoveResponse) { } +func (a RemoveResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ResizeCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // The cluster to be resized. ClusterId types.String `tfsdk:"cluster_id" tf:""` // Number of worker nodes that this cluster should have. A cluster has one @@ -3667,6 +4530,12 @@ func (newState *ResizeCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resi func (newState *ResizeCluster) SyncEffectiveFieldsDuringRead(existingState ResizeCluster) { } +func (a ResizeCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + } +} + type ResizeClusterResponse struct { } @@ -3676,6 +4545,10 @@ func (newState *ResizeClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ResizeClusterResponse) SyncEffectiveFieldsDuringRead(existingState ResizeClusterResponse) { } +func (a ResizeClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestartCluster struct { // The cluster to be started. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -3689,6 +4562,10 @@ func (newState *RestartCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *RestartCluster) SyncEffectiveFieldsDuringRead(existingState RestartCluster) { } +func (a RestartCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestartClusterResponse struct { } @@ -3698,6 +4575,10 @@ func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringRead(existingState RestartClusterResponse) { } +func (a RestartClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Results struct { // The cause of the error Cause types.String `tfsdk:"cause" tf:"optional"` @@ -3706,7 +4587,7 @@ type Results struct { // The image filename FileName types.String `tfsdk:"fileName" tf:"optional"` - FileNames []types.String `tfsdk:"fileNames" tf:"optional"` + FileNames types.List `tfsdk:"fileNames" tf:"optional"` // true if a JSON schema is returned instead of a string representation of // the Hive type. IsJsonSchema types.Bool `tfsdk:"isJsonSchema" tf:"optional"` @@ -3715,7 +4596,7 @@ type Results struct { ResultType types.String `tfsdk:"resultType" tf:"optional"` // The table schema - Schema []map[string]any `tfsdk:"schema" tf:"optional"` + Schema types.List `tfsdk:"schema" tf:"optional"` // The summary of the error Summary types.String `tfsdk:"summary" tf:"optional"` // true if partial results are returned. @@ -3728,6 +4609,13 @@ func (newState *Results) SyncEffectiveFieldsDuringCreateOrUpdate(plan Results) { func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { } +func (a Results) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileNames": reflect.TypeOf(""), + "Schema": reflect.TypeOf(struct{}{}), + } +} + type S3StorageInfo struct { // (Optional) Set canned access control list for the logs, e.g. // `bucket-owner-full-control`. If `canned_cal` is set, please make sure the @@ -3767,13 +4655,17 @@ func (newState *S3StorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan S3St func (newState *S3StorageInfo) SyncEffectiveFieldsDuringRead(existingState S3StorageInfo) { } +func (a S3StorageInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SparkNode struct { // The private IP address of the host instance. HostPrivateIp types.String `tfsdk:"host_private_ip" tf:"optional"` // Globally unique identifier for the host instance from the cloud provider. InstanceId types.String `tfsdk:"instance_id" tf:"optional"` // Attributes specific to AWS for a Spark node. - NodeAwsAttributes []SparkNodeAwsAttributes `tfsdk:"node_aws_attributes" tf:"optional,object"` + NodeAwsAttributes types.Object `tfsdk:"node_aws_attributes" tf:"optional,object"` // Globally unique identifier for this node. NodeId types.String `tfsdk:"node_id" tf:"optional"` // Private IP address (typically a 10.x.x.x address) of the Spark node. Note @@ -3801,6 +4693,12 @@ func (newState *SparkNode) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparkNod func (newState *SparkNode) SyncEffectiveFieldsDuringRead(existingState SparkNode) { } +func (a SparkNode) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NodeAwsAttributes": reflect.TypeOf(SparkNodeAwsAttributes{}), + } +} + type SparkNodeAwsAttributes struct { // Whether this node is on an Amazon spot instance. IsSpot types.Bool `tfsdk:"is_spot" tf:"optional"` @@ -3812,6 +4710,10 @@ func (newState *SparkNodeAwsAttributes) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SparkNodeAwsAttributes) SyncEffectiveFieldsDuringRead(existingState SparkNodeAwsAttributes) { } +func (a SparkNodeAwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SparkVersion struct { // Spark version key, for example "2.1.x-scala2.11". This is the value which // should be provided as the "spark_version" when creating a new cluster. @@ -3829,6 +4731,10 @@ func (newState *SparkVersion) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spark func (newState *SparkVersion) SyncEffectiveFieldsDuringRead(existingState SparkVersion) { } +func (a SparkVersion) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StartCluster struct { // The cluster to be started. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -3840,6 +4746,10 @@ func (newState *StartCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Start func (newState *StartCluster) SyncEffectiveFieldsDuringRead(existingState StartCluster) { } +func (a StartCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StartClusterResponse struct { } @@ -3849,12 +4759,16 @@ func (newState *StartClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StartClusterResponse) SyncEffectiveFieldsDuringRead(existingState StartClusterResponse) { } +func (a StartClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TerminationReason struct { // status code indicating why the cluster was terminated Code types.String `tfsdk:"code" tf:"optional"` // list of parameters that provide additional information about why the // cluster was terminated - Parameters map[string]types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.Map `tfsdk:"parameters" tf:"optional"` // type of the termination Type types.String `tfsdk:"type" tf:"optional"` } @@ -3865,11 +4779,17 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState TerminationReason) { } +func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type UninstallLibraries struct { // Unique identifier for the cluster on which to uninstall these libraries. ClusterId types.String `tfsdk:"cluster_id" tf:""` // The libraries to uninstall. - Libraries []Library `tfsdk:"libraries" tf:""` + Libraries types.List `tfsdk:"libraries" tf:""` } func (newState *UninstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan UninstallLibraries) { @@ -3878,6 +4798,12 @@ func (newState *UninstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UninstallLibraries) SyncEffectiveFieldsDuringRead(existingState UninstallLibraries) { } +func (a UninstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Libraries": reflect.TypeOf(Library{}), + } +} + type UninstallLibrariesResponse struct { } @@ -3887,6 +4813,10 @@ func (newState *UninstallLibrariesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UninstallLibrariesResponse) SyncEffectiveFieldsDuringRead(existingState UninstallLibrariesResponse) { } +func (a UninstallLibrariesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UnpinCluster struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -3898,6 +4828,10 @@ func (newState *UnpinCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Unpin func (newState *UnpinCluster) SyncEffectiveFieldsDuringRead(existingState UnpinCluster) { } +func (a UnpinCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UnpinClusterResponse struct { } @@ -3907,9 +4841,13 @@ func (newState *UnpinClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UnpinClusterResponse) SyncEffectiveFieldsDuringRead(existingState UnpinClusterResponse) { } +func (a UnpinClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateCluster struct { // The cluster to be updated. - Cluster []UpdateClusterResource `tfsdk:"cluster" tf:"optional,object"` + Cluster types.Object `tfsdk:"cluster" tf:"optional,object"` // ID of the cluster. ClusterId types.String `tfsdk:"cluster_id" tf:""` // Specifies which fields of the cluster will be updated. This is required @@ -3926,11 +4864,17 @@ func (newState *UpdateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateCluster) SyncEffectiveFieldsDuringRead(existingState UpdateCluster) { } +func (a UpdateCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Cluster": reflect.TypeOf(UpdateClusterResource{}), + } +} + type UpdateClusterResource struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []AutoScale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -3939,17 +4883,17 @@ type UpdateClusterResource struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes []AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes []AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf []ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -3961,7 +4905,7 @@ type UpdateClusterResource struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Data security mode decides what data governance model to use when // accessing data from a cluster. // @@ -3986,7 +4930,7 @@ type UpdateClusterResource struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage []DockerImage `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -4004,12 +4948,12 @@ type UpdateClusterResource struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes []GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts []InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // This field encodes, through a single value, the resources available to @@ -4047,7 +4991,7 @@ type UpdateClusterResource struct { // JVM options to the driver and the executors via // `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` // respectively. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // An object containing a set of optional, user-specified environment // variable key-value pairs. Please note that key-value pair of the form // (X,Y) will be exported as is (i.e., `export X='Y'`) while launching the @@ -4061,7 +5005,7 @@ type UpdateClusterResource struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of // available Spark versions can be retrieved by using the // :method:clusters/sparkVersions API call. @@ -4069,9 +5013,9 @@ type UpdateClusterResource struct { // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType []WorkloadType `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` } func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateClusterResource) { @@ -4080,6 +5024,23 @@ func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringRead(existingState UpdateClusterResource) { } +func (a UpdateClusterResource) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(AutoScale{}), + "AwsAttributes": reflect.TypeOf(AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(AzureAttributes{}), + "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), + "CustomTags": reflect.TypeOf(""), + "DockerImage": reflect.TypeOf(DockerImage{}), + "GcpAttributes": reflect.TypeOf(GcpAttributes{}), + "InitScripts": reflect.TypeOf(InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(""), + "WorkloadType": reflect.TypeOf(WorkloadType{}), + } +} + type UpdateClusterResponse struct { } @@ -4089,6 +5050,10 @@ func (newState *UpdateClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateClusterResponse) SyncEffectiveFieldsDuringRead(existingState UpdateClusterResponse) { } +func (a UpdateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateResponse struct { } @@ -4098,6 +5063,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type VolumesStorageInfo struct { // Unity Catalog Volumes file destination, e.g. `/Volumes/my-init.sh` Destination types.String `tfsdk:"destination" tf:""` @@ -4109,9 +5078,13 @@ func (newState *VolumesStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *VolumesStorageInfo) SyncEffectiveFieldsDuringRead(existingState VolumesStorageInfo) { } +func (a VolumesStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WorkloadType struct { // defined what type of clients can use the cluster. E.g. Notebooks, Jobs - Clients []ClientsTypes `tfsdk:"clients" tf:"object"` + Clients types.Object `tfsdk:"clients" tf:"object"` } func (newState *WorkloadType) SyncEffectiveFieldsDuringCreateOrUpdate(plan WorkloadType) { @@ -4120,6 +5093,12 @@ func (newState *WorkloadType) SyncEffectiveFieldsDuringCreateOrUpdate(plan Workl func (newState *WorkloadType) SyncEffectiveFieldsDuringRead(existingState WorkloadType) { } +func (a WorkloadType) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Clients": reflect.TypeOf(ClientsTypes{}), + } +} + type WorkspaceStorageInfo struct { // workspace files destination, e.g. // `/Users/user1@databricks.com/my-init.sh` @@ -4131,3 +5110,7 @@ func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringRead(existingState WorkspaceStorageInfo) { } + +func (a WorkspaceStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 2b6ff5a197..adec574f13 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -11,13 +11,15 @@ We use go-native types for lists and maps intentionally for the ease for convert package dashboards_tf import ( + "reflect" + "github.com/databricks/databricks-sdk-go/service/sql" "github.com/hashicorp/terraform-plugin-framework/types" ) // Create dashboard type CreateDashboardRequest struct { - Dashboard []Dashboard `tfsdk:"dashboard" tf:"optional,object"` + Dashboard types.Object `tfsdk:"dashboard" tf:"optional,object"` } func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateDashboardRequest) { @@ -26,12 +28,18 @@ func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState CreateDashboardRequest) { } +func (a CreateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dashboard": reflect.TypeOf(Dashboard{}), + } +} + // Create dashboard schedule type CreateScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. DashboardId types.String `tfsdk:"-"` - Schedule []Schedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` } func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateScheduleRequest) { @@ -40,6 +48,12 @@ func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringRead(existingState CreateScheduleRequest) { } +func (a CreateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Schedule": reflect.TypeOf(Schedule{}), + } +} + // Create schedule subscription type CreateSubscriptionRequest struct { // UUID identifying the dashboard to which the subscription belongs. @@ -47,7 +61,7 @@ type CreateSubscriptionRequest struct { // UUID identifying the schedule to which the subscription belongs. ScheduleId types.String `tfsdk:"-"` - Subscription []Subscription `tfsdk:"subscription" tf:"optional,object"` + Subscription types.Object `tfsdk:"subscription" tf:"optional,object"` } func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateSubscriptionRequest) { @@ -56,6 +70,12 @@ func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState CreateSubscriptionRequest) { } +func (a CreateSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Subscription": reflect.TypeOf(Subscription{}), + } +} + type CronSchedule struct { // A cron expression using quartz syntax. EX: `0 0 8 * * ?` represents // everyday at 8am. See [Cron Trigger] for details. @@ -75,6 +95,10 @@ func (newState *CronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronS func (newState *CronSchedule) SyncEffectiveFieldsDuringRead(existingState CronSchedule) { } +func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Dashboard struct { // The timestamp of when the dashboard was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -117,6 +141,10 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboar func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard) { } +func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete dashboard schedule type DeleteScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. @@ -134,6 +162,10 @@ func (newState *DeleteScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteScheduleRequest) SyncEffectiveFieldsDuringRead(existingState DeleteScheduleRequest) { } +func (a DeleteScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteScheduleResponse struct { } @@ -143,6 +175,10 @@ func (newState *DeleteScheduleResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteScheduleResponse) SyncEffectiveFieldsDuringRead(existingState DeleteScheduleResponse) { } +func (a DeleteScheduleResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete schedule subscription type DeleteSubscriptionRequest struct { // UUID identifying the dashboard which the subscription belongs. @@ -162,6 +198,10 @@ func (newState *DeleteSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteSubscriptionRequest) { } +func (a DeleteSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteSubscriptionResponse struct { } @@ -171,11 +211,15 @@ func (newState *DeleteSubscriptionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteSubscriptionResponse) SyncEffectiveFieldsDuringRead(existingState DeleteSubscriptionResponse) { } +func (a DeleteSubscriptionResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Genie AI Response type GenieAttachment struct { - Query []QueryAttachment `tfsdk:"query" tf:"optional,object"` + Query types.Object `tfsdk:"query" tf:"optional,object"` - Text []TextAttachment `tfsdk:"text" tf:"optional,object"` + Text types.Object `tfsdk:"text" tf:"optional,object"` } func (newState *GenieAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan GenieAttachment) { @@ -184,6 +228,13 @@ func (newState *GenieAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GenieAttachment) SyncEffectiveFieldsDuringRead(existingState GenieAttachment) { } +func (a GenieAttachment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Query": reflect.TypeOf(QueryAttachment{}), + "Text": reflect.TypeOf(TextAttachment{}), + } +} + type GenieConversation struct { // Timestamp when the message was created CreatedTimestamp types.Int64 `tfsdk:"created_timestamp" tf:"optional"` @@ -205,6 +256,10 @@ func (newState *GenieConversation) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GenieConversation) SyncEffectiveFieldsDuringRead(existingState GenieConversation) { } +func (a GenieConversation) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GenieCreateConversationMessageRequest struct { // User message content. Content types.String `tfsdk:"content" tf:""` @@ -220,6 +275,10 @@ func (newState *GenieCreateConversationMessageRequest) SyncEffectiveFieldsDuring func (newState *GenieCreateConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieCreateConversationMessageRequest) { } +func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Execute SQL query in a conversation message type GenieExecuteMessageQueryRequest struct { // Conversation ID @@ -236,6 +295,10 @@ func (newState *GenieExecuteMessageQueryRequest) SyncEffectiveFieldsDuringCreate func (newState *GenieExecuteMessageQueryRequest) SyncEffectiveFieldsDuringRead(existingState GenieExecuteMessageQueryRequest) { } +func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get conversation message type GenieGetConversationMessageRequest struct { // The ID associated with the target conversation. @@ -254,6 +317,10 @@ func (newState *GenieGetConversationMessageRequest) SyncEffectiveFieldsDuringCre func (newState *GenieGetConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieGetConversationMessageRequest) { } +func (a GenieGetConversationMessageRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get conversation message SQL query result type GenieGetMessageQueryResultRequest struct { // Conversation ID @@ -270,6 +337,10 @@ func (newState *GenieGetMessageQueryResultRequest) SyncEffectiveFieldsDuringCrea func (newState *GenieGetMessageQueryResultRequest) SyncEffectiveFieldsDuringRead(existingState GenieGetMessageQueryResultRequest) { } +func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GenieGetMessageQueryResultResponse struct { // SQL Statement Execution response. See [Get status, manifest, and result // first chunk](:method:statementexecution/getstatement) for more details. @@ -282,9 +353,15 @@ func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringCre func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringRead(existingState GenieGetMessageQueryResultResponse) { } +func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "StatementResponse": reflect.TypeOf(sql.StatementResponse{}), + } +} + type GenieMessage struct { // AI produced response to the message - Attachments []GenieAttachment `tfsdk:"attachments" tf:"optional"` + Attachments types.List `tfsdk:"attachments" tf:"optional"` // User message content Content types.String `tfsdk:"content" tf:""` // Conversation ID @@ -292,13 +369,13 @@ type GenieMessage struct { // Timestamp when the message was created CreatedTimestamp types.Int64 `tfsdk:"created_timestamp" tf:"optional"` // Error message if AI failed to respond to the message - Error []MessageError `tfsdk:"error" tf:"optional,object"` + Error types.Object `tfsdk:"error" tf:"optional,object"` // Message ID Id types.String `tfsdk:"id" tf:""` // Timestamp when the message was last updated LastUpdatedTimestamp types.Int64 `tfsdk:"last_updated_timestamp" tf:"optional"` // The result of SQL query if the message has a query attachment - QueryResult []Result `tfsdk:"query_result" tf:"optional,object"` + QueryResult types.Object `tfsdk:"query_result" tf:"optional,object"` // Genie space ID SpaceId types.String `tfsdk:"space_id" tf:""` // MesssageStatus. The possible values are: * `FETCHING_METADATA`: Fetching @@ -328,6 +405,14 @@ func (newState *GenieMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Genie func (newState *GenieMessage) SyncEffectiveFieldsDuringRead(existingState GenieMessage) { } +func (a GenieMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Attachments": reflect.TypeOf(GenieAttachment{}), + "Error": reflect.TypeOf(MessageError{}), + "QueryResult": reflect.TypeOf(Result{}), + } +} + type GenieStartConversationMessageRequest struct { // The text of the message that starts the conversation. Content types.String `tfsdk:"content" tf:""` @@ -342,12 +427,16 @@ func (newState *GenieStartConversationMessageRequest) SyncEffectiveFieldsDuringC func (newState *GenieStartConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieStartConversationMessageRequest) { } +func (a GenieStartConversationMessageRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GenieStartConversationResponse struct { - Conversation []GenieConversation `tfsdk:"conversation" tf:"optional,object"` + Conversation types.Object `tfsdk:"conversation" tf:"optional,object"` // Conversation ID ConversationId types.String `tfsdk:"conversation_id" tf:""` - Message []GenieMessage `tfsdk:"message" tf:"optional,object"` + Message types.Object `tfsdk:"message" tf:"optional,object"` // Message ID MessageId types.String `tfsdk:"message_id" tf:""` } @@ -358,6 +447,13 @@ func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringCreateO func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringRead(existingState GenieStartConversationResponse) { } +func (a GenieStartConversationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Conversation": reflect.TypeOf(GenieConversation{}), + "Message": reflect.TypeOf(GenieMessage{}), + } +} + // Get dashboard type GetDashboardRequest struct { // UUID identifying the dashboard. @@ -370,6 +466,10 @@ func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetDashboardRequest) { } +func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get published dashboard type GetPublishedDashboardRequest struct { // UUID identifying the published dashboard. @@ -382,6 +482,10 @@ func (newState *GetPublishedDashboardRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *GetPublishedDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetPublishedDashboardRequest) { } +func (a GetPublishedDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get dashboard schedule type GetScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. @@ -396,6 +500,10 @@ func (newState *GetScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetScheduleRequest) SyncEffectiveFieldsDuringRead(existingState GetScheduleRequest) { } +func (a GetScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get schedule subscription type GetSubscriptionRequest struct { // UUID identifying the dashboard which the subscription belongs. @@ -412,6 +520,10 @@ func (newState *GetSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState GetSubscriptionRequest) { } +func (a GetSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List dashboards type ListDashboardsRequest struct { // The number of dashboards to return per page. @@ -432,8 +544,12 @@ func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringRead(existingState ListDashboardsRequest) { } +func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListDashboardsResponse struct { - Dashboards []Dashboard `tfsdk:"dashboards" tf:"optional"` + Dashboards types.List `tfsdk:"dashboards" tf:"optional"` // A token, which can be sent as `page_token` to retrieve the next page. If // this field is omitted, there are no subsequent dashboards. NextPageToken types.String `tfsdk:"next_page_token" tf:"computed,optional"` @@ -445,6 +561,12 @@ func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringRead(existingState ListDashboardsResponse) { } +func (a ListDashboardsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dashboards": reflect.TypeOf(Dashboard{}), + } +} + // List dashboard schedules type ListSchedulesRequest struct { // UUID identifying the dashboard to which the schedules belongs. @@ -462,13 +584,17 @@ func (newState *ListSchedulesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListSchedulesRequest) SyncEffectiveFieldsDuringRead(existingState ListSchedulesRequest) { } +func (a ListSchedulesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListSchedulesResponse struct { // A token that can be used as a `page_token` in subsequent requests to // retrieve the next page of results. If this field is omitted, there are no // subsequent schedules. NextPageToken types.String `tfsdk:"next_page_token" tf:"computed,optional"` - Schedules []Schedule `tfsdk:"schedules" tf:"optional"` + Schedules types.List `tfsdk:"schedules" tf:"optional"` } func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListSchedulesResponse) { @@ -477,6 +603,12 @@ func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringRead(existingState ListSchedulesResponse) { } +func (a ListSchedulesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Schedules": reflect.TypeOf(Schedule{}), + } +} + // List schedule subscriptions type ListSubscriptionsRequest struct { // UUID identifying the dashboard which the subscriptions belongs. @@ -496,13 +628,17 @@ func (newState *ListSubscriptionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListSubscriptionsRequest) SyncEffectiveFieldsDuringRead(existingState ListSubscriptionsRequest) { } +func (a ListSubscriptionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListSubscriptionsResponse struct { // A token that can be used as a `page_token` in subsequent requests to // retrieve the next page of results. If this field is omitted, there are no // subsequent subscriptions. NextPageToken types.String `tfsdk:"next_page_token" tf:"computed,optional"` - Subscriptions []Subscription `tfsdk:"subscriptions" tf:"optional"` + Subscriptions types.List `tfsdk:"subscriptions" tf:"optional"` } func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListSubscriptionsResponse) { @@ -511,6 +647,12 @@ func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringRead(existingState ListSubscriptionsResponse) { } +func (a ListSubscriptionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Subscriptions": reflect.TypeOf(Subscription{}), + } +} + type MessageError struct { Error types.String `tfsdk:"error" tf:"optional"` @@ -523,6 +665,10 @@ func (newState *MessageError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Messa func (newState *MessageError) SyncEffectiveFieldsDuringRead(existingState MessageError) { } +func (a MessageError) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MigrateDashboardRequest struct { // Display name for the new Lakeview dashboard. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -539,6 +685,10 @@ func (newState *MigrateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *MigrateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState MigrateDashboardRequest) { } +func (a MigrateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PublishRequest struct { // UUID identifying the dashboard to be published. DashboardId types.String `tfsdk:"-"` @@ -557,6 +707,10 @@ func (newState *PublishRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pub func (newState *PublishRequest) SyncEffectiveFieldsDuringRead(existingState PublishRequest) { } +func (a PublishRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PublishedDashboard struct { // The display name of the published dashboard. DisplayName types.String `tfsdk:"display_name" tf:"computed,optional"` @@ -574,6 +728,10 @@ func (newState *PublishedDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PublishedDashboard) SyncEffectiveFieldsDuringRead(existingState PublishedDashboard) { } +func (a PublishedDashboard) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type QueryAttachment struct { // Description of the query Description types.String `tfsdk:"description" tf:"optional"` @@ -599,6 +757,10 @@ func (newState *QueryAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Qu func (newState *QueryAttachment) SyncEffectiveFieldsDuringRead(existingState QueryAttachment) { } +func (a QueryAttachment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Result struct { // If result is truncated IsTruncated types.Bool `tfsdk:"is_truncated" tf:"optional"` @@ -616,12 +778,16 @@ func (newState *Result) SyncEffectiveFieldsDuringCreateOrUpdate(plan Result) { func (newState *Result) SyncEffectiveFieldsDuringRead(existingState Result) { } +func (a Result) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Schedule struct { // A timestamp indicating when the schedule was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The cron expression describing the frequency of the periodic refresh for // this schedule. - CronSchedule []CronSchedule `tfsdk:"cron_schedule" tf:"object"` + CronSchedule types.Object `tfsdk:"cron_schedule" tf:"object"` // UUID identifying the dashboard to which the schedule belongs. DashboardId types.String `tfsdk:"dashboard_id" tf:"computed,optional"` // The display name for schedule. @@ -646,13 +812,19 @@ func (newState *Schedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan Schedule) func (newState *Schedule) SyncEffectiveFieldsDuringRead(existingState Schedule) { } +func (a Schedule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CronSchedule": reflect.TypeOf(CronSchedule{}), + } +} + type Subscriber struct { // The destination to receive the subscription email. This parameter is // mutually exclusive with `user_subscriber`. - DestinationSubscriber []SubscriptionSubscriberDestination `tfsdk:"destination_subscriber" tf:"optional,object"` + DestinationSubscriber types.Object `tfsdk:"destination_subscriber" tf:"optional,object"` // The user to receive the subscription email. This parameter is mutually // exclusive with `destination_subscriber`. - UserSubscriber []SubscriptionSubscriberUser `tfsdk:"user_subscriber" tf:"optional,object"` + UserSubscriber types.Object `tfsdk:"user_subscriber" tf:"optional,object"` } func (newState *Subscriber) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subscriber) { @@ -661,6 +833,13 @@ func (newState *Subscriber) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subscri func (newState *Subscriber) SyncEffectiveFieldsDuringRead(existingState Subscriber) { } +func (a Subscriber) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DestinationSubscriber": reflect.TypeOf(SubscriptionSubscriberDestination{}), + "UserSubscriber": reflect.TypeOf(SubscriptionSubscriberUser{}), + } +} + type Subscription struct { // A timestamp indicating when the subscription was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -677,7 +856,7 @@ type Subscription struct { ScheduleId types.String `tfsdk:"schedule_id" tf:"computed,optional"` // Subscriber details for users and destinations to be added as subscribers // to the schedule. - Subscriber []Subscriber `tfsdk:"subscriber" tf:"object"` + Subscriber types.Object `tfsdk:"subscriber" tf:"object"` // UUID identifying the subscription. SubscriptionId types.String `tfsdk:"subscription_id" tf:"computed,optional"` // A timestamp indicating when the subscription was last updated. @@ -690,6 +869,12 @@ func (newState *Subscription) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subsc func (newState *Subscription) SyncEffectiveFieldsDuringRead(existingState Subscription) { } +func (a Subscription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Subscriber": reflect.TypeOf(Subscriber{}), + } +} + type SubscriptionSubscriberDestination struct { // The canonical identifier of the destination to receive email // notification. @@ -702,6 +887,10 @@ func (newState *SubscriptionSubscriberDestination) SyncEffectiveFieldsDuringCrea func (newState *SubscriptionSubscriberDestination) SyncEffectiveFieldsDuringRead(existingState SubscriptionSubscriberDestination) { } +func (a SubscriptionSubscriberDestination) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SubscriptionSubscriberUser struct { // UserId of the subscriber. UserId types.Int64 `tfsdk:"user_id" tf:"computed,optional"` @@ -713,6 +902,10 @@ func (newState *SubscriptionSubscriberUser) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SubscriptionSubscriberUser) SyncEffectiveFieldsDuringRead(existingState SubscriptionSubscriberUser) { } +func (a SubscriptionSubscriberUser) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TextAttachment struct { // AI generated message Content types.String `tfsdk:"content" tf:"optional"` @@ -726,6 +919,10 @@ func (newState *TextAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tex func (newState *TextAttachment) SyncEffectiveFieldsDuringRead(existingState TextAttachment) { } +func (a TextAttachment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Trash dashboard type TrashDashboardRequest struct { // UUID identifying the dashboard. @@ -738,6 +935,10 @@ func (newState *TrashDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *TrashDashboardRequest) SyncEffectiveFieldsDuringRead(existingState TrashDashboardRequest) { } +func (a TrashDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TrashDashboardResponse struct { } @@ -747,6 +948,10 @@ func (newState *TrashDashboardResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *TrashDashboardResponse) SyncEffectiveFieldsDuringRead(existingState TrashDashboardResponse) { } +func (a TrashDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Unpublish dashboard type UnpublishDashboardRequest struct { // UUID identifying the published dashboard. @@ -759,6 +964,10 @@ func (newState *UnpublishDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UnpublishDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UnpublishDashboardRequest) { } +func (a UnpublishDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UnpublishDashboardResponse struct { } @@ -768,9 +977,13 @@ func (newState *UnpublishDashboardResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UnpublishDashboardResponse) SyncEffectiveFieldsDuringRead(existingState UnpublishDashboardResponse) { } +func (a UnpublishDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Update dashboard type UpdateDashboardRequest struct { - Dashboard []Dashboard `tfsdk:"dashboard" tf:"optional,object"` + Dashboard types.Object `tfsdk:"dashboard" tf:"optional,object"` // UUID identifying the dashboard. DashboardId types.String `tfsdk:"-"` } @@ -781,12 +994,18 @@ func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDashboardRequest) { } +func (a UpdateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dashboard": reflect.TypeOf(Dashboard{}), + } +} + // Update dashboard schedule type UpdateScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. DashboardId types.String `tfsdk:"-"` - Schedule []Schedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // UUID identifying the schedule. ScheduleId types.String `tfsdk:"-"` } @@ -796,3 +1015,9 @@ func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringRead(existingState UpdateScheduleRequest) { } + +func (a UpdateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Schedule": reflect.TypeOf(Schedule{}), + } +} diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index d2296d76ee..991ed48f7d 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -12,6 +12,7 @@ package files_tf import ( "io" + "reflect" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -30,6 +31,10 @@ func (newState *AddBlock) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddBlock) func (newState *AddBlock) SyncEffectiveFieldsDuringRead(existingState AddBlock) { } +func (a AddBlock) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AddBlockResponse struct { } @@ -39,6 +44,10 @@ func (newState *AddBlockResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan A func (newState *AddBlockResponse) SyncEffectiveFieldsDuringRead(existingState AddBlockResponse) { } +func (a AddBlockResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Close struct { // The handle on an open stream. Handle types.Int64 `tfsdk:"handle" tf:""` @@ -50,6 +59,10 @@ func (newState *Close) SyncEffectiveFieldsDuringCreateOrUpdate(plan Close) { func (newState *Close) SyncEffectiveFieldsDuringRead(existingState Close) { } +func (a Close) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CloseResponse struct { } @@ -59,6 +72,10 @@ func (newState *CloseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clos func (newState *CloseResponse) SyncEffectiveFieldsDuringRead(existingState CloseResponse) { } +func (a CloseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Create struct { // The flag that specifies whether to overwrite existing file/files. Overwrite types.Bool `tfsdk:"overwrite" tf:"optional"` @@ -72,6 +89,10 @@ func (newState *Create) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create) { func (newState *Create) SyncEffectiveFieldsDuringRead(existingState Create) { } +func (a Create) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Create a directory type CreateDirectoryRequest struct { // The absolute path of a directory. @@ -84,6 +105,10 @@ func (newState *CreateDirectoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateDirectoryRequest) SyncEffectiveFieldsDuringRead(existingState CreateDirectoryRequest) { } +func (a CreateDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateDirectoryResponse struct { } @@ -93,6 +118,10 @@ func (newState *CreateDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState CreateDirectoryResponse) { } +func (a CreateDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateResponse struct { // Handle which should subsequently be passed into the AddBlock and Close // calls when writing to a file through a stream. @@ -105,6 +134,10 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Delete struct { // The path of the file or directory to delete. The path should be the // absolute DBFS path. @@ -120,6 +153,10 @@ func (newState *Delete) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete) { func (newState *Delete) SyncEffectiveFieldsDuringRead(existingState Delete) { } +func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a directory type DeleteDirectoryRequest struct { // The absolute path of a directory. @@ -132,6 +169,10 @@ func (newState *DeleteDirectoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteDirectoryRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDirectoryRequest) { } +func (a DeleteDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteDirectoryResponse struct { } @@ -141,6 +182,10 @@ func (newState *DeleteDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDirectoryResponse) { } +func (a DeleteDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a file type DeleteFileRequest struct { // The absolute path of the file. @@ -153,6 +198,10 @@ func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFileRequest) { } +func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -162,6 +211,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DirectoryEntry struct { // The length of the file in bytes. This field is omitted for directories. FileSize types.Int64 `tfsdk:"file_size" tf:"optional"` @@ -182,6 +235,10 @@ func (newState *DirectoryEntry) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dir func (newState *DirectoryEntry) SyncEffectiveFieldsDuringRead(existingState DirectoryEntry) { } +func (a DirectoryEntry) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Download a file type DownloadRequest struct { // The absolute path of the file. @@ -194,6 +251,10 @@ func (newState *DownloadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DownloadRequest) SyncEffectiveFieldsDuringRead(existingState DownloadRequest) { } +func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DownloadResponse struct { ContentLength types.Int64 `tfsdk:"-"` @@ -210,6 +271,10 @@ func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DownloadResponse) SyncEffectiveFieldsDuringRead(existingState DownloadResponse) { } +func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FileInfo struct { // The length of the file in bytes. This field is omitted for directories. FileSize types.Int64 `tfsdk:"file_size" tf:"optional"` @@ -227,6 +292,10 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } +func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get directory metadata type GetDirectoryMetadataRequest struct { // The absolute path of a directory. @@ -239,6 +308,10 @@ func (newState *GetDirectoryMetadataRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetDirectoryMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetDirectoryMetadataRequest) { } +func (a GetDirectoryMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetDirectoryMetadataResponse struct { } @@ -248,6 +321,10 @@ func (newState *GetDirectoryMetadataResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetDirectoryMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetDirectoryMetadataResponse) { } +func (a GetDirectoryMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get file metadata type GetMetadataRequest struct { // The absolute path of the file. @@ -260,6 +337,10 @@ func (newState *GetMetadataRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetMetadataRequest) { } +func (a GetMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetMetadataResponse struct { ContentLength types.Int64 `tfsdk:"-"` @@ -274,6 +355,10 @@ func (newState *GetMetadataResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetMetadataResponse) { } +func (a GetMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the information of a file or directory type GetStatusRequest struct { // The path of the file or directory. The path should be the absolute DBFS @@ -287,6 +372,10 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } +func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List directory contents or file details type ListDbfsRequest struct { // The path of the file or directory. The path should be the absolute DBFS @@ -300,6 +389,10 @@ func (newState *ListDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListDbfsRequest) SyncEffectiveFieldsDuringRead(existingState ListDbfsRequest) { } +func (a ListDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List directory contents type ListDirectoryContentsRequest struct { // The absolute path of a directory. @@ -332,9 +425,13 @@ func (newState *ListDirectoryContentsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListDirectoryContentsRequest) SyncEffectiveFieldsDuringRead(existingState ListDirectoryContentsRequest) { } +func (a ListDirectoryContentsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListDirectoryResponse struct { // Array of DirectoryEntry. - Contents []DirectoryEntry `tfsdk:"contents" tf:"optional"` + Contents types.List `tfsdk:"contents" tf:"optional"` // A token, which can be sent as `page_token` to retrieve the next page. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -345,10 +442,16 @@ func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState ListDirectoryResponse) { } +func (a ListDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Contents": reflect.TypeOf(DirectoryEntry{}), + } +} + type ListStatusResponse struct { // A list of FileInfo's that describe contents of directory or file. See // example above. - Files []FileInfo `tfsdk:"files" tf:"optional"` + Files types.List `tfsdk:"files" tf:"optional"` } func (newState *ListStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListStatusResponse) { @@ -357,6 +460,12 @@ func (newState *ListStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListStatusResponse) SyncEffectiveFieldsDuringRead(existingState ListStatusResponse) { } +func (a ListStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Files": reflect.TypeOf(FileInfo{}), + } +} + type MkDirs struct { // The path of the new directory. The path should be the absolute DBFS path. Path types.String `tfsdk:"path" tf:""` @@ -368,6 +477,10 @@ func (newState *MkDirs) SyncEffectiveFieldsDuringCreateOrUpdate(plan MkDirs) { func (newState *MkDirs) SyncEffectiveFieldsDuringRead(existingState MkDirs) { } +func (a MkDirs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MkDirsResponse struct { } @@ -377,6 +490,10 @@ func (newState *MkDirsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MkD func (newState *MkDirsResponse) SyncEffectiveFieldsDuringRead(existingState MkDirsResponse) { } +func (a MkDirsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Move struct { // The destination path of the file or directory. The path should be the // absolute DBFS path. @@ -392,6 +509,10 @@ func (newState *Move) SyncEffectiveFieldsDuringCreateOrUpdate(plan Move) { func (newState *Move) SyncEffectiveFieldsDuringRead(existingState Move) { } +func (a Move) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MoveResponse struct { } @@ -401,6 +522,10 @@ func (newState *MoveResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MoveR func (newState *MoveResponse) SyncEffectiveFieldsDuringRead(existingState MoveResponse) { } +func (a MoveResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Put struct { // This parameter might be absent, and instead a posted file will be used. Contents types.String `tfsdk:"contents" tf:"optional"` @@ -416,6 +541,10 @@ func (newState *Put) SyncEffectiveFieldsDuringCreateOrUpdate(plan Put) { func (newState *Put) SyncEffectiveFieldsDuringRead(existingState Put) { } +func (a Put) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PutResponse struct { } @@ -425,6 +554,10 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRes func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResponse) { } +func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the contents of a file type ReadDbfsRequest struct { // The number of bytes to read starting from the offset. This has a limit of @@ -442,6 +575,10 @@ func (newState *ReadDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReadDbfsRequest) SyncEffectiveFieldsDuringRead(existingState ReadDbfsRequest) { } +func (a ReadDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ReadResponse struct { // The number of bytes read (could be less than ``length`` if we hit end of // file). This refers to number of bytes read in unencoded version (response @@ -457,6 +594,10 @@ func (newState *ReadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReadR func (newState *ReadResponse) SyncEffectiveFieldsDuringRead(existingState ReadResponse) { } +func (a ReadResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Upload a file type UploadRequest struct { Contents io.ReadCloser `tfsdk:"-"` @@ -472,6 +613,10 @@ func (newState *UploadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Uplo func (newState *UploadRequest) SyncEffectiveFieldsDuringRead(existingState UploadRequest) { } +func (a UploadRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UploadResponse struct { } @@ -480,3 +625,7 @@ func (newState *UploadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upl func (newState *UploadResponse) SyncEffectiveFieldsDuringRead(existingState UploadResponse) { } + +func (a UploadResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 869726ccb7..94fade7736 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package iam_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -31,9 +33,13 @@ func (newState *AccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *AccessControlRequest) SyncEffectiveFieldsDuringRead(existingState AccessControlRequest) { } +func (a AccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AccessControlResponse struct { // All permissions. - AllPermissions []Permission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -50,6 +56,12 @@ func (newState *AccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AccessControlResponse) { } +func (a AccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(Permission{}), + } +} + type ComplexValue struct { Display types.String `tfsdk:"display" tf:"optional"` @@ -68,6 +80,10 @@ func (newState *ComplexValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Compl func (newState *ComplexValue) SyncEffectiveFieldsDuringRead(existingState ComplexValue) { } +func (a ComplexValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a group type DeleteAccountGroupRequest struct { // Unique ID for a group in the Databricks account. @@ -80,6 +96,10 @@ func (newState *DeleteAccountGroupRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteAccountGroupRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountGroupRequest) { } +func (a DeleteAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a service principal type DeleteAccountServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks account. @@ -92,6 +112,10 @@ func (newState *DeleteAccountServicePrincipalRequest) SyncEffectiveFieldsDuringC func (newState *DeleteAccountServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountServicePrincipalRequest) { } +func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a user type DeleteAccountUserRequest struct { // Unique ID for a user in the Databricks account. @@ -104,6 +128,10 @@ func (newState *DeleteAccountUserRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteAccountUserRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountUserRequest) { } +func (a DeleteAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a group type DeleteGroupRequest struct { // Unique ID for a group in the Databricks workspace. @@ -116,6 +144,10 @@ func (newState *DeleteGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteGroupRequest) SyncEffectiveFieldsDuringRead(existingState DeleteGroupRequest) { } +func (a DeleteGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -125,6 +157,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a service principal type DeleteServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks workspace. @@ -137,6 +173,10 @@ func (newState *DeleteServicePrincipalRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServicePrincipalRequest) { } +func (a DeleteServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a user type DeleteUserRequest struct { // Unique ID for a user in the Databricks workspace. @@ -149,6 +189,10 @@ func (newState *DeleteUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteUserRequest) SyncEffectiveFieldsDuringRead(existingState DeleteUserRequest) { } +func (a DeleteUserRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete permissions assignment type DeleteWorkspaceAssignmentRequest struct { // The ID of the user, service principal, or group. @@ -163,6 +207,10 @@ func (newState *DeleteWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspaceAssignmentRequest) { } +func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteWorkspacePermissionAssignmentResponse struct { } @@ -172,6 +220,10 @@ func (newState *DeleteWorkspacePermissionAssignmentResponse) SyncEffectiveFields func (newState *DeleteWorkspacePermissionAssignmentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspacePermissionAssignmentResponse) { } +func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get group details type GetAccountGroupRequest struct { // Unique ID for a group in the Databricks account. @@ -184,6 +236,10 @@ func (newState *GetAccountGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetAccountGroupRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountGroupRequest) { } +func (a GetAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get service principal details type GetAccountServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks account. @@ -196,6 +252,10 @@ func (newState *GetAccountServicePrincipalRequest) SyncEffectiveFieldsDuringCrea func (newState *GetAccountServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountServicePrincipalRequest) { } +func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get user details type GetAccountUserRequest struct { // Comma-separated list of attributes to return in response. @@ -229,6 +289,10 @@ func (newState *GetAccountUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetAccountUserRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountUserRequest) { } +func (a GetAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get assignable roles for a resource type GetAssignableRolesForResourceRequest struct { // The resource name for which assignable roles will be listed. @@ -241,8 +305,12 @@ func (newState *GetAssignableRolesForResourceRequest) SyncEffectiveFieldsDuringC func (newState *GetAssignableRolesForResourceRequest) SyncEffectiveFieldsDuringRead(existingState GetAssignableRolesForResourceRequest) { } +func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetAssignableRolesForResourceResponse struct { - Roles []Role `tfsdk:"roles" tf:"optional"` + Roles types.List `tfsdk:"roles" tf:"optional"` } func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetAssignableRolesForResourceResponse) { @@ -251,6 +319,12 @@ func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuring func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuringRead(existingState GetAssignableRolesForResourceResponse) { } +func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Roles": reflect.TypeOf(Role{}), + } +} + // Get group details type GetGroupRequest struct { // Unique ID for a group in the Databricks workspace. @@ -263,9 +337,13 @@ func (newState *GetGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetGroupRequest) SyncEffectiveFieldsDuringRead(existingState GetGroupRequest) { } +func (a GetGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPasswordPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []PasswordPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPasswordPermissionLevelsResponse) { @@ -274,6 +352,12 @@ func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringCr func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPasswordPermissionLevelsResponse) { } +func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(PasswordPermissionsDescription{}), + } +} + // Get object permission levels type GetPermissionLevelsRequest struct { // @@ -288,9 +372,13 @@ func (newState *GetPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetPermissionLevelsRequest) { } +func (a GetPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []PermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPermissionLevelsResponse) { @@ -299,6 +387,12 @@ func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPermissionLevelsResponse) { } +func (a GetPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(PermissionsDescription{}), + } +} + // Get object permissions type GetPermissionRequest struct { // The id of the request object. @@ -317,6 +411,10 @@ func (newState *GetPermissionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetPermissionRequest) SyncEffectiveFieldsDuringRead(existingState GetPermissionRequest) { } +func (a GetPermissionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a rule set type GetRuleSetRequest struct { // Etag used for versioning. The response is at least as fresh as the eTag @@ -338,6 +436,10 @@ func (newState *GetRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetRuleSetRequest) SyncEffectiveFieldsDuringRead(existingState GetRuleSetRequest) { } +func (a GetRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get service principal details type GetServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks workspace. @@ -350,6 +452,10 @@ func (newState *GetServicePrincipalRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState GetServicePrincipalRequest) { } +func (a GetServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get user details type GetUserRequest struct { // Comma-separated list of attributes to return in response. @@ -383,6 +489,10 @@ func (newState *GetUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetUserRequest) SyncEffectiveFieldsDuringRead(existingState GetUserRequest) { } +func (a GetUserRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List workspace permissions type GetWorkspaceAssignmentRequest struct { // The workspace ID. @@ -395,9 +505,13 @@ func (newState *GetWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceAssignmentRequest) { } +func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GrantRule struct { // Principals this grant rule applies to. - Principals []types.String `tfsdk:"principals" tf:"optional"` + Principals types.List `tfsdk:"principals" tf:"optional"` // Role that is assigned to the list of principals. Role types.String `tfsdk:"role" tf:""` } @@ -408,6 +522,12 @@ func (newState *GrantRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan GrantRul func (newState *GrantRule) SyncEffectiveFieldsDuringRead(existingState GrantRule) { } +func (a GrantRule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Principals": reflect.TypeOf(""), + } +} + type Group struct { // String that represents a human-readable group name DisplayName types.String `tfsdk:"displayName" tf:"optional"` @@ -415,21 +535,21 @@ type Group struct { // full list of supported values. // // [assigning entitlements]: https://docs.databricks.com/administration-guide/users-groups/index.html#assigning-entitlements - Entitlements []ComplexValue `tfsdk:"entitlements" tf:"optional"` + Entitlements types.List `tfsdk:"entitlements" tf:"optional"` ExternalId types.String `tfsdk:"externalId" tf:"optional"` - Groups []ComplexValue `tfsdk:"groups" tf:"optional"` + Groups types.List `tfsdk:"groups" tf:"optional"` // Databricks group ID Id types.String `tfsdk:"id" tf:"optional"` - Members []ComplexValue `tfsdk:"members" tf:"optional"` + Members types.List `tfsdk:"members" tf:"optional"` // Container for the group identifier. Workspace local versus account. - Meta []ResourceMeta `tfsdk:"meta" tf:"optional,object"` + Meta types.Object `tfsdk:"meta" tf:"optional,object"` // Corresponds to AWS instance profile/arn role. - Roles []ComplexValue `tfsdk:"roles" tf:"optional"` + Roles types.List `tfsdk:"roles" tf:"optional"` // The schema of the group. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` } func (newState *Group) SyncEffectiveFieldsDuringCreateOrUpdate(plan Group) { @@ -438,6 +558,17 @@ func (newState *Group) SyncEffectiveFieldsDuringCreateOrUpdate(plan Group) { func (newState *Group) SyncEffectiveFieldsDuringRead(existingState Group) { } +func (a Group) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Entitlements": reflect.TypeOf(ComplexValue{}), + "Groups": reflect.TypeOf(ComplexValue{}), + "Members": reflect.TypeOf(ComplexValue{}), + "Meta": reflect.TypeOf(ResourceMeta{}), + "Roles": reflect.TypeOf(ComplexValue{}), + "Schemas": reflect.TypeOf(""), + } +} + // List group details type ListAccountGroupsRequest struct { // Comma-separated list of attributes to return in response. @@ -468,6 +599,10 @@ func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountGroupsRequest) { } +func (a ListAccountGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List service principals type ListAccountServicePrincipalsRequest struct { // Comma-separated list of attributes to return in response. @@ -498,6 +633,10 @@ func (newState *ListAccountServicePrincipalsRequest) SyncEffectiveFieldsDuringCr func (newState *ListAccountServicePrincipalsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountServicePrincipalsRequest) { } +func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List users type ListAccountUsersRequest struct { // Comma-separated list of attributes to return in response. @@ -529,6 +668,10 @@ func (newState *ListAccountUsersRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListAccountUsersRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountUsersRequest) { } +func (a ListAccountUsersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List group details type ListGroupsRequest struct { // Comma-separated list of attributes to return in response. @@ -559,13 +702,17 @@ func (newState *ListGroupsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListGroupsRequest) SyncEffectiveFieldsDuringRead(existingState ListGroupsRequest) { } +func (a ListGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListGroupsResponse struct { // Total results returned in the response. ItemsPerPage types.Int64 `tfsdk:"itemsPerPage" tf:"optional"` // User objects returned in the response. - Resources []Group `tfsdk:"Resources" tf:"optional"` + Resources types.List `tfsdk:"Resources" tf:"optional"` // The schema of the service principal. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` // Starting index of all the results that matched the request filters. First // item is number 1. StartIndex types.Int64 `tfsdk:"startIndex" tf:"optional"` @@ -579,13 +726,20 @@ func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringRead(existingState ListGroupsResponse) { } +func (a ListGroupsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Resources": reflect.TypeOf(Group{}), + "Schemas": reflect.TypeOf(""), + } +} + type ListServicePrincipalResponse struct { // Total results returned in the response. ItemsPerPage types.Int64 `tfsdk:"itemsPerPage" tf:"optional"` // User objects returned in the response. - Resources []ServicePrincipal `tfsdk:"Resources" tf:"optional"` + Resources types.List `tfsdk:"Resources" tf:"optional"` // The schema of the List response. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` // Starting index of all the results that matched the request filters. First // item is number 1. StartIndex types.Int64 `tfsdk:"startIndex" tf:"optional"` @@ -599,6 +753,13 @@ func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalResponse) { } +func (a ListServicePrincipalResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Resources": reflect.TypeOf(ServicePrincipal{}), + "Schemas": reflect.TypeOf(""), + } +} + // List service principals type ListServicePrincipalsRequest struct { // Comma-separated list of attributes to return in response. @@ -629,6 +790,10 @@ func (newState *ListServicePrincipalsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListServicePrincipalsRequest) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalsRequest) { } +func (a ListServicePrincipalsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List users type ListUsersRequest struct { // Comma-separated list of attributes to return in response. @@ -660,13 +825,17 @@ func (newState *ListUsersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListUsersRequest) SyncEffectiveFieldsDuringRead(existingState ListUsersRequest) { } +func (a ListUsersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListUsersResponse struct { // Total results returned in the response. ItemsPerPage types.Int64 `tfsdk:"itemsPerPage" tf:"optional"` // User objects returned in the response. - Resources []User `tfsdk:"Resources" tf:"optional"` + Resources types.List `tfsdk:"Resources" tf:"optional"` // The schema of the List response. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` // Starting index of all the results that matched the request filters. First // item is number 1. StartIndex types.Int64 `tfsdk:"startIndex" tf:"optional"` @@ -680,6 +849,13 @@ func (newState *ListUsersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListUsersResponse) SyncEffectiveFieldsDuringRead(existingState ListUsersResponse) { } +func (a ListUsersResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Resources": reflect.TypeOf(User{}), + "Schemas": reflect.TypeOf(""), + } +} + // Get permission assignments type ListWorkspaceAssignmentRequest struct { // The workspace ID for the account. @@ -692,6 +868,10 @@ func (newState *ListWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState ListWorkspaceAssignmentRequest) { } +func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MigratePermissionsRequest struct { // The name of the workspace group that permissions will be migrated from. FromWorkspaceGroupName types.String `tfsdk:"from_workspace_group_name" tf:""` @@ -710,6 +890,10 @@ func (newState *MigratePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *MigratePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState MigratePermissionsRequest) { } +func (a MigratePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MigratePermissionsResponse struct { // Number of permissions migrated. PermissionsMigrated types.Int64 `tfsdk:"permissions_migrated" tf:"optional"` @@ -721,6 +905,10 @@ func (newState *MigratePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *MigratePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState MigratePermissionsResponse) { } +func (a MigratePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Name struct { // Family name of the Databricks user. FamilyName types.String `tfsdk:"familyName" tf:"optional"` @@ -734,8 +922,12 @@ func (newState *Name) SyncEffectiveFieldsDuringCreateOrUpdate(plan Name) { func (newState *Name) SyncEffectiveFieldsDuringRead(existingState Name) { } +func (a Name) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ObjectPermissions struct { - AccessControlList []AccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -748,14 +940,20 @@ func (newState *ObjectPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ObjectPermissions) SyncEffectiveFieldsDuringRead(existingState ObjectPermissions) { } +func (a ObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AccessControlResponse{}), + } +} + type PartialUpdate struct { // Unique ID for a user in the Databricks workspace. Id types.String `tfsdk:"-"` - Operations []Patch `tfsdk:"Operations" tf:"optional"` + Operations types.List `tfsdk:"Operations" tf:"optional"` // The schema of the patch request. Must be // ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` } func (newState *PartialUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan PartialUpdate) { @@ -764,6 +962,13 @@ func (newState *PartialUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan Part func (newState *PartialUpdate) SyncEffectiveFieldsDuringRead(existingState PartialUpdate) { } +func (a PartialUpdate) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Operations": reflect.TypeOf(Patch{}), + "Schemas": reflect.TypeOf(""), + } +} + type PasswordAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -781,9 +986,13 @@ func (newState *PasswordAccessControlRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *PasswordAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState PasswordAccessControlRequest) { } +func (a PasswordAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PasswordAccessControlResponse struct { // All permissions. - AllPermissions []PasswordPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -800,10 +1009,16 @@ func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringCreateOr func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState PasswordAccessControlResponse) { } +func (a PasswordAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(PasswordPermission{}), + } +} + type PasswordPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -814,8 +1029,14 @@ func (newState *PasswordPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PasswordPermission) SyncEffectiveFieldsDuringRead(existingState PasswordPermission) { } +func (a PasswordPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type PasswordPermissions struct { - AccessControlList []PasswordAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -828,6 +1049,12 @@ func (newState *PasswordPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PasswordPermissions) SyncEffectiveFieldsDuringRead(existingState PasswordPermissions) { } +func (a PasswordPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(PasswordAccessControlResponse{}), + } +} + type PasswordPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -840,8 +1067,12 @@ func (newState *PasswordPermissionsDescription) SyncEffectiveFieldsDuringCreateO func (newState *PasswordPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PasswordPermissionsDescription) { } +func (a PasswordPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PasswordPermissionsRequest struct { - AccessControlList []PasswordAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` } func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PasswordPermissionsRequest) { @@ -850,6 +1081,12 @@ func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PasswordPermissionsRequest) { } +func (a PasswordPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(PasswordAccessControlRequest{}), + } +} + type Patch struct { // Type of patch operation. Op types.String `tfsdk:"op" tf:"optional"` @@ -865,6 +1102,10 @@ func (newState *Patch) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patch) { func (newState *Patch) SyncEffectiveFieldsDuringRead(existingState Patch) { } +func (a Patch) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PatchResponse struct { } @@ -874,10 +1115,14 @@ func (newState *PatchResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patc func (newState *PatchResponse) SyncEffectiveFieldsDuringRead(existingState PatchResponse) { } +func (a PatchResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Permission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -888,15 +1133,21 @@ func (newState *Permission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Permiss func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permission) { } +func (a Permission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + // The output format for existing workspace PermissionAssignment records, which // contains some info for user consumption. type PermissionAssignment struct { // Error response associated with a workspace permission assignment, if any. Error types.String `tfsdk:"error" tf:"optional"` // The permissions level of the principal. - Permissions []types.String `tfsdk:"permissions" tf:"optional"` + Permissions types.List `tfsdk:"permissions" tf:"optional"` // Information about the principal assigned to the workspace. - Principal []PrincipalOutput `tfsdk:"principal" tf:"optional,object"` + Principal types.Object `tfsdk:"principal" tf:"optional,object"` } func (newState *PermissionAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan PermissionAssignment) { @@ -905,9 +1156,16 @@ func (newState *PermissionAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PermissionAssignment) SyncEffectiveFieldsDuringRead(existingState PermissionAssignment) { } +func (a PermissionAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Permissions": reflect.TypeOf(""), + "Principal": reflect.TypeOf(PrincipalOutput{}), + } +} + type PermissionAssignments struct { // Array of permissions assignments defined for a workspace. - PermissionAssignments []PermissionAssignment `tfsdk:"permission_assignments" tf:"optional"` + PermissionAssignments types.List `tfsdk:"permission_assignments" tf:"optional"` } func (newState *PermissionAssignments) SyncEffectiveFieldsDuringCreateOrUpdate(plan PermissionAssignments) { @@ -916,6 +1174,12 @@ func (newState *PermissionAssignments) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *PermissionAssignments) SyncEffectiveFieldsDuringRead(existingState PermissionAssignments) { } +func (a PermissionAssignments) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionAssignments": reflect.TypeOf(PermissionAssignment{}), + } +} + type PermissionOutput struct { // The results of a permissions query. Description types.String `tfsdk:"description" tf:"optional"` @@ -929,6 +1193,10 @@ func (newState *PermissionOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *PermissionOutput) SyncEffectiveFieldsDuringRead(existingState PermissionOutput) { } +func (a PermissionOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -941,8 +1209,12 @@ func (newState *PermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PermissionsDescription) { } +func (a PermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PermissionsRequest struct { - AccessControlList []AccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The id of the request object. RequestObjectId types.String `tfsdk:"-"` // The type of the request object. Can be one of the following: alerts, @@ -959,6 +1231,12 @@ func (newState *PermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PermissionsRequest) { } +func (a PermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AccessControlRequest{}), + } +} + // Information about the principal assigned to the workspace. type PrincipalOutput struct { // The display name of the principal. @@ -980,6 +1258,10 @@ func (newState *PrincipalOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pr func (newState *PrincipalOutput) SyncEffectiveFieldsDuringRead(existingState PrincipalOutput) { } +func (a PrincipalOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ResourceMeta struct { // Identifier for group type. Can be local workspace group // (`WorkspaceGroup`) or account group (`Group`). @@ -992,6 +1274,10 @@ func (newState *ResourceMeta) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resou func (newState *ResourceMeta) SyncEffectiveFieldsDuringRead(existingState ResourceMeta) { } +func (a ResourceMeta) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Role struct { // Role to assign to a principal or a list of principals on a resource. Name types.String `tfsdk:"name" tf:""` @@ -1003,11 +1289,15 @@ func (newState *Role) SyncEffectiveFieldsDuringCreateOrUpdate(plan Role) { func (newState *Role) SyncEffectiveFieldsDuringRead(existingState Role) { } +func (a Role) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RuleSetResponse struct { // Identifies the version of the rule set returned. Etag types.String `tfsdk:"etag" tf:"optional"` - GrantRules []GrantRule `tfsdk:"grant_rules" tf:"optional"` + GrantRules types.List `tfsdk:"grant_rules" tf:"optional"` // Name of the rule set. Name types.String `tfsdk:"name" tf:"optional"` } @@ -1018,13 +1308,19 @@ func (newState *RuleSetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ru func (newState *RuleSetResponse) SyncEffectiveFieldsDuringRead(existingState RuleSetResponse) { } +func (a RuleSetResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "GrantRules": reflect.TypeOf(GrantRule{}), + } +} + type RuleSetUpdateRequest struct { // The expected etag of the rule set to update. The update will fail if the // value does not match the value that is stored in account access control // service. Etag types.String `tfsdk:"etag" tf:""` - GrantRules []GrantRule `tfsdk:"grant_rules" tf:"optional"` + GrantRules types.List `tfsdk:"grant_rules" tf:"optional"` // Name of the rule set. Name types.String `tfsdk:"name" tf:""` } @@ -1035,6 +1331,12 @@ func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringRead(existingState RuleSetUpdateRequest) { } +func (a RuleSetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "GrantRules": reflect.TypeOf(GrantRule{}), + } +} + type ServicePrincipal struct { // If this user is active Active types.Bool `tfsdk:"active" tf:"optional"` @@ -1046,17 +1348,17 @@ type ServicePrincipal struct { // entitlements] for a full list of supported values. // // [assigning entitlements]: https://docs.databricks.com/administration-guide/users-groups/index.html#assigning-entitlements - Entitlements []ComplexValue `tfsdk:"entitlements" tf:"optional"` + Entitlements types.List `tfsdk:"entitlements" tf:"optional"` ExternalId types.String `tfsdk:"externalId" tf:"optional"` - Groups []ComplexValue `tfsdk:"groups" tf:"optional"` + Groups types.List `tfsdk:"groups" tf:"optional"` // Databricks service principal ID. Id types.String `tfsdk:"id" tf:"optional"` // Corresponds to AWS instance profile/arn role. - Roles []ComplexValue `tfsdk:"roles" tf:"optional"` + Roles types.List `tfsdk:"roles" tf:"optional"` // The schema of the List response. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` } func (newState *ServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(plan ServicePrincipal) { @@ -1065,6 +1367,15 @@ func (newState *ServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServicePrincipal) SyncEffectiveFieldsDuringRead(existingState ServicePrincipal) { } +func (a ServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Entitlements": reflect.TypeOf(ComplexValue{}), + "Groups": reflect.TypeOf(ComplexValue{}), + "Roles": reflect.TypeOf(ComplexValue{}), + "Schemas": reflect.TypeOf(""), + } +} + type UpdateResponse struct { } @@ -1074,11 +1385,15 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateRuleSetRequest struct { // Name of the rule set. Name types.String `tfsdk:"name" tf:""` - RuleSet []RuleSetUpdateRequest `tfsdk:"rule_set" tf:"object"` + RuleSet types.Object `tfsdk:"rule_set" tf:"object"` } func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRuleSetRequest) { @@ -1087,6 +1402,12 @@ func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRuleSetRequest) { } +func (a UpdateRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RuleSet": reflect.TypeOf(RuleSetUpdateRequest{}), + } +} + type UpdateWorkspaceAssignments struct { // Array of permissions assignments to update on the workspace. Valid values // are "USER" and "ADMIN" (case-sensitive). If both "USER" and "ADMIN" are @@ -1094,7 +1415,7 @@ type UpdateWorkspaceAssignments struct { // that excluding this field, or providing unsupported values, will have the // same effect as providing an empty list, which will result in the deletion // of all permissions for the principal. - Permissions []types.String `tfsdk:"permissions" tf:"optional"` + Permissions types.List `tfsdk:"permissions" tf:"optional"` // The ID of the user, service principal, or group. PrincipalId types.Int64 `tfsdk:"-"` // The workspace ID. @@ -1107,6 +1428,12 @@ func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceAssignments) { } +func (a UpdateWorkspaceAssignments) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Permissions": reflect.TypeOf(""), + } +} + type User struct { // If this user is active Active types.Bool `tfsdk:"active" tf:"optional"` @@ -1118,25 +1445,25 @@ type User struct { // [identity federation is enabled]: https://docs.databricks.com/administration-guide/users-groups/best-practices.html#enable-identity-federation DisplayName types.String `tfsdk:"displayName" tf:"optional"` // All the emails associated with the Databricks user. - Emails []ComplexValue `tfsdk:"emails" tf:"optional"` + Emails types.List `tfsdk:"emails" tf:"optional"` // Entitlements assigned to the user. See [assigning entitlements] for a // full list of supported values. // // [assigning entitlements]: https://docs.databricks.com/administration-guide/users-groups/index.html#assigning-entitlements - Entitlements []ComplexValue `tfsdk:"entitlements" tf:"optional"` + Entitlements types.List `tfsdk:"entitlements" tf:"optional"` // External ID is not currently supported. It is reserved for future use. ExternalId types.String `tfsdk:"externalId" tf:"optional"` - Groups []ComplexValue `tfsdk:"groups" tf:"optional"` + Groups types.List `tfsdk:"groups" tf:"optional"` // Databricks user ID. This is automatically set by Databricks. Any value // provided by the client will be ignored. Id types.String `tfsdk:"id" tf:"optional"` - Name []Name `tfsdk:"name" tf:"optional,object"` + Name types.Object `tfsdk:"name" tf:"optional,object"` // Corresponds to AWS instance profile/arn role. - Roles []ComplexValue `tfsdk:"roles" tf:"optional"` + Roles types.List `tfsdk:"roles" tf:"optional"` // The schema of the user. - Schemas []types.String `tfsdk:"schemas" tf:"optional"` + Schemas types.List `tfsdk:"schemas" tf:"optional"` // Email address of the Databricks user. UserName types.String `tfsdk:"userName" tf:"optional"` } @@ -1147,9 +1474,20 @@ func (newState *User) SyncEffectiveFieldsDuringCreateOrUpdate(plan User) { func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { } +func (a User) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Emails": reflect.TypeOf(ComplexValue{}), + "Entitlements": reflect.TypeOf(ComplexValue{}), + "Groups": reflect.TypeOf(ComplexValue{}), + "Name": reflect.TypeOf(Name{}), + "Roles": reflect.TypeOf(ComplexValue{}), + "Schemas": reflect.TypeOf(""), + } +} + type WorkspacePermissions struct { // Array of permissions defined for a workspace. - Permissions []PermissionOutput `tfsdk:"permissions" tf:"optional"` + Permissions types.List `tfsdk:"permissions" tf:"optional"` } func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan WorkspacePermissions) { @@ -1157,3 +1495,9 @@ func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringRead(existingState WorkspacePermissions) { } + +func (a WorkspacePermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Permissions": reflect.TypeOf(PermissionOutput{}), + } +} diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 51e158e64f..e185640d6a 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package jobs_tf import ( + "reflect" + "github.com/databricks/databricks-sdk-go/service/compute" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -33,7 +35,7 @@ type BaseJob struct { JobId types.Int64 `tfsdk:"job_id" tf:"optional"` // Settings for this job and all of its runs. These settings can be updated // using the `resetJob` method. - Settings []JobSettings `tfsdk:"settings" tf:"optional,object"` + Settings types.Object `tfsdk:"settings" tf:"optional,object"` } func (newState *BaseJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseJob) { @@ -42,6 +44,12 @@ func (newState *BaseJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseJob) { func (newState *BaseJob) SyncEffectiveFieldsDuringRead(existingState BaseJob) { } +func (a BaseJob) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Settings": reflect.TypeOf(JobSettings{}), + } +} + type BaseRun struct { // The sequence number of this run attempt for a triggered job run. The // initial attempt of a run has an attempt_number of 0. If the initial run @@ -60,10 +68,10 @@ type BaseRun struct { // The cluster used for this run. If the run is specified to use a new // cluster, this field is set once the Jobs service has requested a cluster // for the run. - ClusterInstance []ClusterInstance `tfsdk:"cluster_instance" tf:"optional,object"` + ClusterInstance types.Object `tfsdk:"cluster_instance" tf:"optional,object"` // A snapshot of the job’s cluster specification when this run was // created. - ClusterSpec []ClusterSpec `tfsdk:"cluster_spec" tf:"optional,object"` + ClusterSpec types.Object `tfsdk:"cluster_spec" tf:"optional,object"` // The creator user name. This field won’t be included in the response if // the user has already been deleted. CreatorUserName types.String `tfsdk:"creator_user_name" tf:"optional"` @@ -90,15 +98,15 @@ type BaseRun struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource []GitSource `tfsdk:"git_source" tf:"optional,object"` + GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. - JobClusters []JobCluster `tfsdk:"job_clusters" tf:"optional"` + JobClusters types.List `tfsdk:"job_clusters" tf:"optional"` // The canonical identifier of the job that contains this run. JobId types.Int64 `tfsdk:"job_id" tf:"optional"` // Job-level parameters used in the run - JobParameters []JobParameter `tfsdk:"job_parameters" tf:"optional"` + JobParameters types.List `tfsdk:"job_parameters" tf:"optional"` // ID of the job run that this run belongs to. For legacy and single-task // job runs the field is populated with the job run ID. For task runs, the // field is populated with the ID of the job run that the task run belongs @@ -111,11 +119,11 @@ type BaseRun struct { // run_id of the original attempt; otherwise, it is the same as the run_id. OriginalAttemptRunId types.Int64 `tfsdk:"original_attempt_run_id" tf:"optional"` // The parameters used for this run. - OverridingParameters []RunParameters `tfsdk:"overriding_parameters" tf:"optional,object"` + OverridingParameters types.Object `tfsdk:"overriding_parameters" tf:"optional,object"` // The time in milliseconds that the run has spent in the queue. QueueDuration types.Int64 `tfsdk:"queue_duration" tf:"optional"` // The repair history of the run. - RepairHistory []RepairHistoryItem `tfsdk:"repair_history" tf:"optional"` + RepairHistory types.List `tfsdk:"repair_history" tf:"optional"` // The time in milliseconds it took the job run and all of its repairs to // finish. RunDuration types.Int64 `tfsdk:"run_duration" tf:"optional"` @@ -136,7 +144,7 @@ type BaseRun struct { RunType types.String `tfsdk:"run_type" tf:"optional"` // The cron schedule that triggered this run if it was triggered by the // periodic scheduler. - Schedule []CronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // The time in milliseconds it took to set up the cluster. For runs that run // on new clusters this is the cluster creation time, for runs that run on // existing clusters this time should be very short. The duration of a task @@ -151,12 +159,12 @@ type BaseRun struct { // new cluster, this is the time the cluster creation call is issued. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State []RunState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status []RunStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // The list of tasks performed by the run. Each task has its own `run_id` // which you can use to call `JobsGetOutput` to retrieve the run resutls. - Tasks []RunTask `tfsdk:"tasks" tf:"optional"` + Tasks types.List `tfsdk:"tasks" tf:"optional"` // The type of trigger that fired this run. // // * `PERIODIC`: Schedules that periodically trigger runs, such as a cron @@ -169,7 +177,7 @@ type BaseRun struct { // arrival. * `TABLE`: Indicates a run that is triggered by a table update. Trigger types.String `tfsdk:"trigger" tf:"optional"` // Additional details about what triggered the run - TriggerInfo []TriggerInfo `tfsdk:"trigger_info" tf:"optional,object"` + TriggerInfo types.Object `tfsdk:"trigger_info" tf:"optional,object"` } func (newState *BaseRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseRun) { @@ -178,6 +186,23 @@ func (newState *BaseRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseRun) { func (newState *BaseRun) SyncEffectiveFieldsDuringRead(existingState BaseRun) { } +func (a BaseRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ClusterInstance": reflect.TypeOf(ClusterInstance{}), + "ClusterSpec": reflect.TypeOf(ClusterSpec{}), + "GitSource": reflect.TypeOf(GitSource{}), + "JobClusters": reflect.TypeOf(JobCluster{}), + "JobParameters": reflect.TypeOf(JobParameter{}), + "OverridingParameters": reflect.TypeOf(RunParameters{}), + "RepairHistory": reflect.TypeOf(RepairHistoryItem{}), + "Schedule": reflect.TypeOf(CronSchedule{}), + "State": reflect.TypeOf(RunState{}), + "Status": reflect.TypeOf(RunStatus{}), + "Tasks": reflect.TypeOf(RunTask{}), + "TriggerInfo": reflect.TypeOf(TriggerInfo{}), + } +} + type CancelAllRuns struct { // Optional boolean parameter to cancel all queued runs. If no job_id is // provided, all queued runs in the workspace are canceled. @@ -192,6 +217,10 @@ func (newState *CancelAllRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan Canc func (newState *CancelAllRuns) SyncEffectiveFieldsDuringRead(existingState CancelAllRuns) { } +func (a CancelAllRuns) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CancelAllRunsResponse struct { } @@ -201,6 +230,10 @@ func (newState *CancelAllRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CancelAllRunsResponse) SyncEffectiveFieldsDuringRead(existingState CancelAllRunsResponse) { } +func (a CancelAllRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CancelRun struct { // This field is required. RunId types.Int64 `tfsdk:"run_id" tf:""` @@ -212,6 +245,10 @@ func (newState *CancelRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan CancelRu func (newState *CancelRun) SyncEffectiveFieldsDuringRead(existingState CancelRun) { } +func (a CancelRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CancelRunResponse struct { } @@ -221,6 +258,10 @@ func (newState *CancelRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CancelRunResponse) SyncEffectiveFieldsDuringRead(existingState CancelRunResponse) { } +func (a CancelRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterInstance struct { // The canonical identifier for the cluster used by a run. This field is // always available for runs on existing clusters. For runs on new clusters, @@ -248,6 +289,10 @@ func (newState *ClusterInstance) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cl func (newState *ClusterInstance) SyncEffectiveFieldsDuringRead(existingState ClusterInstance) { } +func (a ClusterInstance) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterSpec struct { // If existing_cluster_id, the ID of an existing cluster that is used for // all runs. When running jobs or tasks on an existing cluster, you may need @@ -259,7 +304,7 @@ type ClusterSpec struct { JobClusterKey types.String `tfsdk:"job_cluster_key" tf:"optional"` // An optional list of libraries to be installed on the cluster. The default // value is an empty list. - Libraries compute.Library `tfsdk:"library" tf:"optional"` + Libraries types.List `tfsdk:"library" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` @@ -271,6 +316,13 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState ClusterSpec) { } +func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Libraries": reflect.TypeOf(compute.Library{}), + "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + } +} + type ConditionTask struct { // The left operand of the condition task. Can be either a string value or a // job state or parameter reference. @@ -297,6 +349,10 @@ func (newState *ConditionTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cond func (newState *ConditionTask) SyncEffectiveFieldsDuringRead(existingState ConditionTask) { } +func (a ConditionTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Continuous struct { // Indicate whether the continuous execution of the job is paused or not. // Defaults to UNPAUSED. @@ -309,9 +365,13 @@ func (newState *Continuous) SyncEffectiveFieldsDuringCreateOrUpdate(plan Continu func (newState *Continuous) SyncEffectiveFieldsDuringRead(existingState Continuous) { } +func (a Continuous) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateJob struct { // List of permissions to set on the job. - AccessControlList []JobAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The id of the user specified budget policy to use for this job. If not // specified, a default budget policy may be applied when creating or // modifying the job. See `effective_budget_policy_id` for the budget policy @@ -320,9 +380,9 @@ type CreateJob struct { // An optional continuous property for this job. The continuous property // will ensure that there is always one run executing. Only one of // `schedule` and `continuous` can be used. - Continuous []Continuous `tfsdk:"continuous" tf:"optional,object"` + Continuous types.Object `tfsdk:"continuous" tf:"optional,object"` // Deployment information for jobs managed by external sources. - Deployment []JobDeployment `tfsdk:"deployment" tf:"optional,object"` + Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` // An optional description for the job. The maximum length is 27700 // characters in UTF-8 encoding. Description types.String `tfsdk:"description" tf:"optional"` @@ -333,14 +393,14 @@ type CreateJob struct { EditMode types.String `tfsdk:"edit_mode" tf:"optional"` // An optional set of email addresses that is notified when runs of this job // begin or complete as well as when this job is deleted. - EmailNotifications []JobEmailNotifications `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` // A list of task execution environment specifications that can be // referenced by serverless tasks of this job. An environment is required to // be present for serverless tasks. For serverless notebook tasks, the // environment is accessible in the notebook environment panel. For other // serverless tasks, the task environment is required to be specified using // environment_key in the task settings. - Environments []JobEnvironment `tfsdk:"environment" tf:"optional"` + Environments types.List `tfsdk:"environment" tf:"optional"` // Used to tell what is the format of the job. This field is ignored in // Create/Update/Reset calls. When using the Jobs API 2.1 this value is // always set to `"MULTI_TASK"`. @@ -355,13 +415,13 @@ type CreateJob struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource []GitSource `tfsdk:"git_source" tf:"optional,object"` + GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health []JobsHealthRules `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. - JobClusters []JobCluster `tfsdk:"job_cluster" tf:"optional"` + JobClusters types.List `tfsdk:"job_cluster" tf:"optional"` // An optional maximum allowed number of concurrent runs of the job. Set // this value if you want to be able to execute multiple runs of the same // job concurrently. This is useful for example if you trigger your job on a @@ -380,39 +440,39 @@ type CreateJob struct { // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // job. - NotificationSettings []JobNotificationSettings `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` // Job-level parameter definitions - Parameters []JobParameterDefinition `tfsdk:"parameter" tf:"optional"` + Parameters types.List `tfsdk:"parameter" tf:"optional"` // The queue settings of the job. - Queue []QueueSettings `tfsdk:"queue" tf:"optional,object"` + Queue types.Object `tfsdk:"queue" tf:"optional,object"` // Write-only setting. Specifies the user, service principal or group that // the job/pipeline runs as. If not specified, the job/pipeline runs as the // user who created the job/pipeline. // // Either `user_name` or `service_principal_name` should be specified. If // not, an error is thrown. - RunAs []JobRunAs `tfsdk:"run_as" tf:"optional,object"` + RunAs types.Object `tfsdk:"run_as" tf:"optional,object"` // An optional periodic schedule for this job. The default behavior is that // the job only runs when triggered by clicking “Run Now” in the Jobs UI // or sending an API request to `runNow`. - Schedule []CronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // A map of tags associated with the job. These are forwarded to the cluster // as cluster tags for jobs clusters, and are subject to the same // limitations as cluster tags. A maximum of 25 tags can be added to the // job. - Tags map[string]types.String `tfsdk:"tags" tf:"optional"` + Tags types.Map `tfsdk:"tags" tf:"optional"` // A list of task specifications to be executed by this job. - Tasks []Task `tfsdk:"task" tf:"optional"` + Tasks types.List `tfsdk:"task" tf:"optional"` // An optional timeout applied to each run of this job. A value of `0` means // no timeout. TimeoutSeconds types.Int64 `tfsdk:"timeout_seconds" tf:"optional"` // A configuration to trigger a run when certain conditions are met. The // default behavior is that the job runs only when triggered by clicking // “Run Now” in the Jobs UI or sending an API request to `runNow`. - Trigger []TriggerSettings `tfsdk:"trigger" tf:"optional,object"` + Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` // A collection of system notification IDs to notify when runs of this job // begin or complete. - WebhookNotifications []WebhookNotifications `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *CreateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateJob) { @@ -421,6 +481,28 @@ func (newState *CreateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateJo func (newState *CreateJob) SyncEffectiveFieldsDuringRead(existingState CreateJob) { } +func (a CreateJob) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(JobAccessControlRequest{}), + "Continuous": reflect.TypeOf(Continuous{}), + "Deployment": reflect.TypeOf(JobDeployment{}), + "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), + "Environments": reflect.TypeOf(JobEnvironment{}), + "GitSource": reflect.TypeOf(GitSource{}), + "Health": reflect.TypeOf(JobsHealthRules{}), + "JobClusters": reflect.TypeOf(JobCluster{}), + "NotificationSettings": reflect.TypeOf(JobNotificationSettings{}), + "Parameters": reflect.TypeOf(JobParameterDefinition{}), + "Queue": reflect.TypeOf(QueueSettings{}), + "RunAs": reflect.TypeOf(JobRunAs{}), + "Schedule": reflect.TypeOf(CronSchedule{}), + "Tags": reflect.TypeOf(""), + "Tasks": reflect.TypeOf(Task{}), + "Trigger": reflect.TypeOf(TriggerSettings{}), + "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + } +} + // Job was created successfully type CreateResponse struct { // The canonical identifier for the newly created job. @@ -433,6 +515,10 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CronSchedule struct { // Indicate whether this schedule is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` @@ -454,10 +540,14 @@ func (newState *CronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronS func (newState *CronSchedule) SyncEffectiveFieldsDuringRead(existingState CronSchedule) { } +func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DbtOutput struct { // An optional map of headers to send when retrieving the artifact from the // `artifacts_link`. - ArtifactsHeaders map[string]types.String `tfsdk:"artifacts_headers" tf:"optional"` + ArtifactsHeaders types.Map `tfsdk:"artifacts_headers" tf:"optional"` // A pre-signed URL to download the (compressed) dbt artifacts. This link is // valid for a limited time (30 minutes). This information is only available // after the run has finished. @@ -470,6 +560,12 @@ func (newState *DbtOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan DbtOutpu func (newState *DbtOutput) SyncEffectiveFieldsDuringRead(existingState DbtOutput) { } +func (a DbtOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ArtifactsHeaders": reflect.TypeOf(""), + } +} + type DbtTask struct { // Optional name of the catalog to use. The value is the top level in the // 3-level namespace of Unity Catalog (catalog / schema / relation). The @@ -479,7 +575,7 @@ type DbtTask struct { // A list of dbt commands to execute. All commands must start with `dbt`. // This parameter must not be empty. A maximum of up to 10 commands can be // provided. - Commands []types.String `tfsdk:"commands" tf:""` + Commands types.List `tfsdk:"commands" tf:""` // Optional (relative) path to the profiles directory. Can only be specified // if no warehouse_id is specified. If no warehouse_id is specified and this // folder is unset, the root directory is used. @@ -513,6 +609,12 @@ func (newState *DbtTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan DbtTask) { func (newState *DbtTask) SyncEffectiveFieldsDuringRead(existingState DbtTask) { } +func (a DbtTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Commands": reflect.TypeOf(""), + } +} + type DeleteJob struct { // The canonical identifier of the job to delete. This field is required. JobId types.Int64 `tfsdk:"job_id" tf:""` @@ -524,6 +626,10 @@ func (newState *DeleteJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteJo func (newState *DeleteJob) SyncEffectiveFieldsDuringRead(existingState DeleteJob) { } +func (a DeleteJob) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -533,6 +639,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRun struct { // ID of the run to delete. RunId types.Int64 `tfsdk:"run_id" tf:""` @@ -544,6 +654,10 @@ func (newState *DeleteRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteRu func (newState *DeleteRun) SyncEffectiveFieldsDuringRead(existingState DeleteRun) { } +func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRunResponse struct { } @@ -553,6 +667,10 @@ func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunResponse) { } +func (a DeleteRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Represents a change to the job cluster's settings that would be required for // the job clusters to become compliant with their policies. type EnforcePolicyComplianceForJobResponseJobClusterSettingsChange struct { @@ -577,6 +695,10 @@ func (newState *EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) S func (newState *EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) { } +func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EnforcePolicyComplianceRequest struct { // The ID of the job you want to enforce policy compliance on. JobId types.Int64 `tfsdk:"job_id" tf:""` @@ -591,6 +713,10 @@ func (newState *EnforcePolicyComplianceRequest) SyncEffectiveFieldsDuringCreateO func (newState *EnforcePolicyComplianceRequest) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceRequest) { } +func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EnforcePolicyComplianceResponse struct { // Whether any changes have been made to the job cluster settings for the // job to become compliant with its policies. @@ -598,14 +724,14 @@ type EnforcePolicyComplianceResponse struct { // A list of job cluster changes that have been made to the job’s cluster // settings in order for all job clusters to become compliant with their // policies. - JobClusterChanges []EnforcePolicyComplianceForJobResponseJobClusterSettingsChange `tfsdk:"job_cluster_changes" tf:"optional"` + JobClusterChanges types.List `tfsdk:"job_cluster_changes" tf:"optional"` // Updated job settings after policy enforcement. Policy enforcement only // applies to job clusters that are created when running the job (which are // specified in new_cluster) and does not apply to existing all-purpose // clusters. Updated job settings are derived by applying policy default // values to the existing job clusters in order to satisfy policy // requirements. - Settings []JobSettings `tfsdk:"settings" tf:"optional,object"` + Settings types.Object `tfsdk:"settings" tf:"optional,object"` } func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan EnforcePolicyComplianceResponse) { @@ -614,6 +740,13 @@ func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringCreate func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceResponse) { } +func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "JobClusterChanges": reflect.TypeOf(EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}), + "Settings": reflect.TypeOf(JobSettings{}), + } +} + // Run was exported successfully. type ExportRunOutput struct { // The exported content in HTML format (one for every view item). To extract @@ -621,7 +754,7 @@ type ExportRunOutput struct { // script]. // // [Python script]: https://docs.databricks.com/en/_static/examples/extract.py - Views []ViewItem `tfsdk:"views" tf:"optional"` + Views types.List `tfsdk:"views" tf:"optional"` } func (newState *ExportRunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan ExportRunOutput) { @@ -630,6 +763,12 @@ func (newState *ExportRunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ex func (newState *ExportRunOutput) SyncEffectiveFieldsDuringRead(existingState ExportRunOutput) { } +func (a ExportRunOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Views": reflect.TypeOf(ViewItem{}), + } +} + // Export and retrieve a job run type ExportRunRequest struct { // The canonical identifier for the run. This field is required. @@ -644,6 +783,10 @@ func (newState *ExportRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *ExportRunRequest) SyncEffectiveFieldsDuringRead(existingState ExportRunRequest) { } +func (a ExportRunRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FileArrivalTriggerConfiguration struct { // If set, the trigger starts a run only after the specified amount of time // passed since the last time the trigger fired. The minimum allowed value @@ -665,11 +808,15 @@ func (newState *FileArrivalTriggerConfiguration) SyncEffectiveFieldsDuringCreate func (newState *FileArrivalTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState FileArrivalTriggerConfiguration) { } +func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ForEachStats struct { // Sample of 3 most common error messages occurred during the iteration. - ErrorMessageStats []ForEachTaskErrorMessageStats `tfsdk:"error_message_stats" tf:"optional"` + ErrorMessageStats types.List `tfsdk:"error_message_stats" tf:"optional"` // Describes stats of the iteration. Only latest retries are considered. - TaskRunStats []ForEachTaskTaskRunStats `tfsdk:"task_run_stats" tf:"optional,object"` + TaskRunStats types.Object `tfsdk:"task_run_stats" tf:"optional,object"` } func (newState *ForEachStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEachStats) { @@ -678,6 +825,13 @@ func (newState *ForEachStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEa func (newState *ForEachStats) SyncEffectiveFieldsDuringRead(existingState ForEachStats) { } +func (a ForEachStats) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ErrorMessageStats": reflect.TypeOf(ForEachTaskErrorMessageStats{}), + "TaskRunStats": reflect.TypeOf(ForEachTaskTaskRunStats{}), + } +} + type ForEachTask struct { // An optional maximum allowed number of concurrent runs of the task. Set // this value if you want to be able to execute multiple runs of the task @@ -687,7 +841,7 @@ type ForEachTask struct { // an array parameter. Inputs types.String `tfsdk:"inputs" tf:""` // Configuration for the task that will be run for each element in the array - Task []Task `tfsdk:"task" tf:"object"` + Task types.Object `tfsdk:"task" tf:"object"` } func (newState *ForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEachTask) { @@ -696,6 +850,12 @@ func (newState *ForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEac func (newState *ForEachTask) SyncEffectiveFieldsDuringRead(existingState ForEachTask) { } +func (a ForEachTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Task": reflect.TypeOf(Task{}), + } +} + type ForEachTaskErrorMessageStats struct { // Describes the count of such error message encountered during the // iterations. @@ -712,6 +872,10 @@ func (newState *ForEachTaskErrorMessageStats) SyncEffectiveFieldsDuringCreateOrU func (newState *ForEachTaskErrorMessageStats) SyncEffectiveFieldsDuringRead(existingState ForEachTaskErrorMessageStats) { } +func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ForEachTaskTaskRunStats struct { // Describes the iteration runs having an active lifecycle state or an // active run sub state. @@ -734,6 +898,10 @@ func (newState *ForEachTaskTaskRunStats) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ForEachTaskTaskRunStats) SyncEffectiveFieldsDuringRead(existingState ForEachTaskTaskRunStats) { } +func (a ForEachTaskTaskRunStats) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get job permission levels type GetJobPermissionLevelsRequest struct { // The job for which to get or manage permissions. @@ -746,9 +914,13 @@ func (newState *GetJobPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetJobPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionLevelsRequest) { } +func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetJobPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []JobPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetJobPermissionLevelsResponse) { @@ -757,6 +929,12 @@ func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionLevelsResponse) { } +func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(JobPermissionsDescription{}), + } +} + // Get job permissions type GetJobPermissionsRequest struct { // The job for which to get or manage permissions. @@ -769,6 +947,10 @@ func (newState *GetJobPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetJobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionsRequest) { } +func (a GetJobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a single job type GetJobRequest struct { // The canonical identifier of the job to retrieve information about. This @@ -782,6 +964,10 @@ func (newState *GetJobRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetJ func (newState *GetJobRequest) SyncEffectiveFieldsDuringRead(existingState GetJobRequest) { } +func (a GetJobRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get job policy compliance type GetPolicyComplianceRequest struct { // The ID of the job whose compliance status you are requesting. @@ -794,6 +980,10 @@ func (newState *GetPolicyComplianceRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetPolicyComplianceRequest) SyncEffectiveFieldsDuringRead(existingState GetPolicyComplianceRequest) { } +func (a GetPolicyComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPolicyComplianceResponse struct { // Whether the job is compliant with its policies or not. Jobs could be out // of compliance if a policy they are using was updated after the job was @@ -805,7 +995,7 @@ type GetPolicyComplianceResponse struct { // error is occurring. An identifier for the job cluster is prepended to the // path. The values indicate an error message describing the policy // validation error. - Violations map[string]types.String `tfsdk:"violations" tf:"optional"` + Violations types.Map `tfsdk:"violations" tf:"optional"` } func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPolicyComplianceResponse) { @@ -814,6 +1004,12 @@ func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringRead(existingState GetPolicyComplianceResponse) { } +func (a GetPolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Violations": reflect.TypeOf(""), + } +} + // Get the output for a single run type GetRunOutputRequest struct { // The canonical identifier for the run. @@ -826,6 +1022,10 @@ func (newState *GetRunOutputRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetRunOutputRequest) SyncEffectiveFieldsDuringRead(existingState GetRunOutputRequest) { } +func (a GetRunOutputRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a single job run type GetRunRequest struct { // Whether to include the repair history in the response. @@ -846,6 +1046,10 @@ func (newState *GetRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetR func (newState *GetRunRequest) SyncEffectiveFieldsDuringRead(existingState GetRunRequest) { } +func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Read-only state of the remote repository at the time the job was run. This // field is only included on job runs. type GitSnapshot struct { @@ -861,6 +1065,10 @@ func (newState *GitSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSna func (newState *GitSnapshot) SyncEffectiveFieldsDuringRead(existingState GitSnapshot) { } +func (a GitSnapshot) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // An optional specification for a remote Git repository containing the source // code used by tasks. Version-controlled source code is supported by notebook, // dbt, Python script, and SQL File tasks. @@ -883,7 +1091,7 @@ type GitSource struct { GitProvider types.String `tfsdk:"git_provider" tf:""` // Read-only state of the remote repository at the time the job was run. // This field is only included on job runs. - GitSnapshot []GitSnapshot `tfsdk:"git_snapshot" tf:"optional,object"` + GitSnapshot types.Object `tfsdk:"git_snapshot" tf:"optional,object"` // Name of the tag to be checked out and used by this job. This field cannot // be specified in conjunction with git_branch or git_commit. GitTag types.String `tfsdk:"tag" tf:"optional"` @@ -891,7 +1099,7 @@ type GitSource struct { GitUrl types.String `tfsdk:"url" tf:""` // The source of the job specification in the remote repository when the job // is source controlled. - JobSource []JobSource `tfsdk:"job_source" tf:"optional,object"` + JobSource types.Object `tfsdk:"job_source" tf:"optional,object"` } func (newState *GitSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSource) { @@ -900,6 +1108,13 @@ func (newState *GitSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSourc func (newState *GitSource) SyncEffectiveFieldsDuringRead(existingState GitSource) { } +func (a GitSource) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "GitSnapshot": reflect.TypeOf(GitSnapshot{}), + "JobSource": reflect.TypeOf(JobSource{}), + } +} + // Job was retrieved successfully. type Job struct { // The time at which this job was created in epoch milliseconds @@ -927,7 +1142,7 @@ type Job struct { RunAsUserName types.String `tfsdk:"run_as_user_name" tf:"optional"` // Settings for this job and all of its runs. These settings can be updated // using the `resetJob` method. - Settings []JobSettings `tfsdk:"settings" tf:"optional,object"` + Settings types.Object `tfsdk:"settings" tf:"optional,object"` } func (newState *Job) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job) { @@ -936,6 +1151,12 @@ func (newState *Job) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job) { func (newState *Job) SyncEffectiveFieldsDuringRead(existingState Job) { } +func (a Job) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Settings": reflect.TypeOf(JobSettings{}), + } +} + type JobAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -953,9 +1174,13 @@ func (newState *JobAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *JobAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState JobAccessControlRequest) { } +func (a JobAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobAccessControlResponse struct { // All permissions. - AllPermissions []JobPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -972,6 +1197,12 @@ func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState JobAccessControlResponse) { } +func (a JobAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(JobPermission{}), + } +} + type JobCluster struct { // A unique name for the job cluster. This field is required and must be // unique within the job. `JobTaskSettings` may refer to this field to @@ -987,6 +1218,12 @@ func (newState *JobCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobClus func (newState *JobCluster) SyncEffectiveFieldsDuringRead(existingState JobCluster) { } +func (a JobCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + } +} + type JobCompliance struct { // Whether this job is in compliance with the latest version of its policy. IsCompliant types.Bool `tfsdk:"is_compliant" tf:"optional"` @@ -997,7 +1234,7 @@ type JobCompliance struct { // error is occurring. An identifier for the job cluster is prepended to the // path. The values indicate an error message describing the policy // validation error. - Violations map[string]types.String `tfsdk:"violations" tf:"optional"` + Violations types.Map `tfsdk:"violations" tf:"optional"` } func (newState *JobCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobCompliance) { @@ -1006,6 +1243,12 @@ func (newState *JobCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobC func (newState *JobCompliance) SyncEffectiveFieldsDuringRead(existingState JobCompliance) { } +func (a JobCompliance) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Violations": reflect.TypeOf(""), + } +} + type JobDeployment struct { // The kind of deployment that manages the job. // @@ -1021,6 +1264,10 @@ func (newState *JobDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobD func (newState *JobDeployment) SyncEffectiveFieldsDuringRead(existingState JobDeployment) { } +func (a JobDeployment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobEmailNotifications struct { // If true, do not send email to recipients specified in `on_failure` if the // run is skipped. This field is `deprecated`. Please use the @@ -1030,17 +1277,17 @@ type JobEmailNotifications struct { // exceeds the threshold specified for the `RUN_DURATION_SECONDS` metric in // the `health` field. If no rule for the `RUN_DURATION_SECONDS` metric is // specified in the `health` field for the job, notifications are not sent. - OnDurationWarningThresholdExceeded []types.String `tfsdk:"on_duration_warning_threshold_exceeded" tf:"optional"` + OnDurationWarningThresholdExceeded types.List `tfsdk:"on_duration_warning_threshold_exceeded" tf:"optional"` // A list of email addresses to be notified when a run unsuccessfully // completes. A run is considered to have completed unsuccessfully if it // ends with an `INTERNAL_ERROR` `life_cycle_state` or a `FAILED`, or // `TIMED_OUT` result_state. If this is not specified on job creation, // reset, or update the list is empty, and notifications are not sent. - OnFailure []types.String `tfsdk:"on_failure" tf:"optional"` + OnFailure types.List `tfsdk:"on_failure" tf:"optional"` // A list of email addresses to be notified when a run begins. If not // specified on job creation, reset, or update, the list is empty, and // notifications are not sent. - OnStart []types.String `tfsdk:"on_start" tf:"optional"` + OnStart types.List `tfsdk:"on_start" tf:"optional"` // A list of email addresses to notify when any streaming backlog thresholds // are exceeded for any stream. Streaming backlog thresholds can be set in // the `health` field using the following metrics: @@ -1048,13 +1295,13 @@ type JobEmailNotifications struct { // `STREAMING_BACKLOG_SECONDS`, or `STREAMING_BACKLOG_FILES`. Alerting is // based on the 10-minute average of these metrics. If the issue persists, // notifications are resent every 30 minutes. - OnStreamingBacklogExceeded []types.String `tfsdk:"on_streaming_backlog_exceeded" tf:"optional"` + OnStreamingBacklogExceeded types.List `tfsdk:"on_streaming_backlog_exceeded" tf:"optional"` // A list of email addresses to be notified when a run successfully // completes. A run is considered to have completed successfully if it ends // with a `TERMINATED` `life_cycle_state` and a `SUCCESS` result_state. If // not specified on job creation, reset, or update, the list is empty, and // notifications are not sent. - OnSuccess []types.String `tfsdk:"on_success" tf:"optional"` + OnSuccess types.List `tfsdk:"on_success" tf:"optional"` } func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobEmailNotifications) { @@ -1063,6 +1310,16 @@ func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringRead(existingState JobEmailNotifications) { } +func (a JobEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OnDurationWarningThresholdExceeded": reflect.TypeOf(""), + "OnFailure": reflect.TypeOf(""), + "OnStart": reflect.TypeOf(""), + "OnStreamingBacklogExceeded": reflect.TypeOf(""), + "OnSuccess": reflect.TypeOf(""), + } +} + type JobEnvironment struct { // The key of an environment. It has to be unique within a job. EnvironmentKey types.String `tfsdk:"environment_key" tf:""` @@ -1078,6 +1335,12 @@ func (newState *JobEnvironment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobEnvironment) SyncEffectiveFieldsDuringRead(existingState JobEnvironment) { } +func (a JobEnvironment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Spec": reflect.TypeOf(compute.Environment{}), + } +} + type JobNotificationSettings struct { // If true, do not send notifications to recipients specified in // `on_failure` if the run is canceled. @@ -1093,6 +1356,10 @@ func (newState *JobNotificationSettings) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *JobNotificationSettings) SyncEffectiveFieldsDuringRead(existingState JobNotificationSettings) { } +func (a JobNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobParameter struct { // The optional default value of the parameter Default types.String `tfsdk:"default" tf:"optional"` @@ -1108,6 +1375,10 @@ func (newState *JobParameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobPa func (newState *JobParameter) SyncEffectiveFieldsDuringRead(existingState JobParameter) { } +func (a JobParameter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobParameterDefinition struct { // Default value of the parameter. Default types.String `tfsdk:"default" tf:""` @@ -1122,10 +1393,14 @@ func (newState *JobParameterDefinition) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *JobParameterDefinition) SyncEffectiveFieldsDuringRead(existingState JobParameterDefinition) { } +func (a JobParameterDefinition) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -1136,8 +1411,14 @@ func (newState *JobPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobP func (newState *JobPermission) SyncEffectiveFieldsDuringRead(existingState JobPermission) { } +func (a JobPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type JobPermissions struct { - AccessControlList []JobAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -1150,6 +1431,12 @@ func (newState *JobPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobPermissions) SyncEffectiveFieldsDuringRead(existingState JobPermissions) { } +func (a JobPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(JobAccessControlResponse{}), + } +} + type JobPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1162,8 +1449,12 @@ func (newState *JobPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpda func (newState *JobPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState JobPermissionsDescription) { } +func (a JobPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobPermissionsRequest struct { - AccessControlList []JobAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The job for which to get or manage permissions. JobId types.String `tfsdk:"-"` } @@ -1174,6 +1465,12 @@ func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState JobPermissionsRequest) { } +func (a JobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(JobAccessControlRequest{}), + } +} + // Write-only setting. Specifies the user, service principal or group that the // job/pipeline runs as. If not specified, the job/pipeline runs as the user who // created the job/pipeline. @@ -1195,6 +1492,10 @@ func (newState *JobRunAs) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobRunAs) func (newState *JobRunAs) SyncEffectiveFieldsDuringRead(existingState JobRunAs) { } +func (a JobRunAs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobSettings struct { // The id of the user specified budget policy to use for this job. If not // specified, a default budget policy may be applied when creating or @@ -1204,9 +1505,9 @@ type JobSettings struct { // An optional continuous property for this job. The continuous property // will ensure that there is always one run executing. Only one of // `schedule` and `continuous` can be used. - Continuous []Continuous `tfsdk:"continuous" tf:"optional,object"` + Continuous types.Object `tfsdk:"continuous" tf:"optional,object"` // Deployment information for jobs managed by external sources. - Deployment []JobDeployment `tfsdk:"deployment" tf:"optional,object"` + Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` // An optional description for the job. The maximum length is 27700 // characters in UTF-8 encoding. Description types.String `tfsdk:"description" tf:"optional"` @@ -1217,14 +1518,14 @@ type JobSettings struct { EditMode types.String `tfsdk:"edit_mode" tf:"optional"` // An optional set of email addresses that is notified when runs of this job // begin or complete as well as when this job is deleted. - EmailNotifications []JobEmailNotifications `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` // A list of task execution environment specifications that can be // referenced by serverless tasks of this job. An environment is required to // be present for serverless tasks. For serverless notebook tasks, the // environment is accessible in the notebook environment panel. For other // serverless tasks, the task environment is required to be specified using // environment_key in the task settings. - Environments []JobEnvironment `tfsdk:"environment" tf:"optional"` + Environments types.List `tfsdk:"environment" tf:"optional"` // Used to tell what is the format of the job. This field is ignored in // Create/Update/Reset calls. When using the Jobs API 2.1 this value is // always set to `"MULTI_TASK"`. @@ -1239,13 +1540,13 @@ type JobSettings struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource []GitSource `tfsdk:"git_source" tf:"optional,object"` + GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health []JobsHealthRules `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. - JobClusters []JobCluster `tfsdk:"job_cluster" tf:"optional"` + JobClusters types.List `tfsdk:"job_cluster" tf:"optional"` // An optional maximum allowed number of concurrent runs of the job. Set // this value if you want to be able to execute multiple runs of the same // job concurrently. This is useful for example if you trigger your job on a @@ -1264,39 +1565,39 @@ type JobSettings struct { // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // job. - NotificationSettings []JobNotificationSettings `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` // Job-level parameter definitions - Parameters []JobParameterDefinition `tfsdk:"parameter" tf:"optional"` + Parameters types.List `tfsdk:"parameter" tf:"optional"` // The queue settings of the job. - Queue []QueueSettings `tfsdk:"queue" tf:"optional,object"` + Queue types.Object `tfsdk:"queue" tf:"optional,object"` // Write-only setting. Specifies the user, service principal or group that // the job/pipeline runs as. If not specified, the job/pipeline runs as the // user who created the job/pipeline. // // Either `user_name` or `service_principal_name` should be specified. If // not, an error is thrown. - RunAs []JobRunAs `tfsdk:"run_as" tf:"optional,object"` + RunAs types.Object `tfsdk:"run_as" tf:"optional,object"` // An optional periodic schedule for this job. The default behavior is that // the job only runs when triggered by clicking “Run Now” in the Jobs UI // or sending an API request to `runNow`. - Schedule []CronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // A map of tags associated with the job. These are forwarded to the cluster // as cluster tags for jobs clusters, and are subject to the same // limitations as cluster tags. A maximum of 25 tags can be added to the // job. - Tags map[string]types.String `tfsdk:"tags" tf:"optional"` + Tags types.Map `tfsdk:"tags" tf:"optional"` // A list of task specifications to be executed by this job. - Tasks []Task `tfsdk:"task" tf:"optional"` + Tasks types.List `tfsdk:"task" tf:"optional"` // An optional timeout applied to each run of this job. A value of `0` means // no timeout. TimeoutSeconds types.Int64 `tfsdk:"timeout_seconds" tf:"optional"` // A configuration to trigger a run when certain conditions are met. The // default behavior is that the job runs only when triggered by clicking // “Run Now” in the Jobs UI or sending an API request to `runNow`. - Trigger []TriggerSettings `tfsdk:"trigger" tf:"optional,object"` + Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` // A collection of system notification IDs to notify when runs of this job // begin or complete. - WebhookNotifications []WebhookNotifications `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *JobSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSettings) { @@ -1305,6 +1606,27 @@ func (newState *JobSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSet func (newState *JobSettings) SyncEffectiveFieldsDuringRead(existingState JobSettings) { } +func (a JobSettings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Continuous": reflect.TypeOf(Continuous{}), + "Deployment": reflect.TypeOf(JobDeployment{}), + "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), + "Environments": reflect.TypeOf(JobEnvironment{}), + "GitSource": reflect.TypeOf(GitSource{}), + "Health": reflect.TypeOf(JobsHealthRules{}), + "JobClusters": reflect.TypeOf(JobCluster{}), + "NotificationSettings": reflect.TypeOf(JobNotificationSettings{}), + "Parameters": reflect.TypeOf(JobParameterDefinition{}), + "Queue": reflect.TypeOf(QueueSettings{}), + "RunAs": reflect.TypeOf(JobRunAs{}), + "Schedule": reflect.TypeOf(CronSchedule{}), + "Tags": reflect.TypeOf(""), + "Tasks": reflect.TypeOf(Task{}), + "Trigger": reflect.TypeOf(TriggerSettings{}), + "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + } +} + // The source of the job specification in the remote repository when the job is // source controlled. type JobSource struct { @@ -1330,6 +1652,10 @@ func (newState *JobSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSourc func (newState *JobSource) SyncEffectiveFieldsDuringRead(existingState JobSource) { } +func (a JobSource) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobsHealthRule struct { // Specifies the health metric that is being evaluated for a particular // health rule. @@ -1358,9 +1684,13 @@ func (newState *JobsHealthRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobsHealthRule) SyncEffectiveFieldsDuringRead(existingState JobsHealthRule) { } +func (a JobsHealthRule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // An optional set of health rules that can be defined for this job. type JobsHealthRules struct { - Rules []JobsHealthRule `tfsdk:"rules" tf:"optional"` + Rules types.List `tfsdk:"rules" tf:"optional"` } func (newState *JobsHealthRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobsHealthRules) { @@ -1369,9 +1699,15 @@ func (newState *JobsHealthRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan Jo func (newState *JobsHealthRules) SyncEffectiveFieldsDuringRead(existingState JobsHealthRules) { } +func (a JobsHealthRules) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Rules": reflect.TypeOf(JobsHealthRule{}), + } +} + type ListJobComplianceForPolicyResponse struct { // A list of jobs and their policy compliance statuses. - Jobs []JobCompliance `tfsdk:"jobs" tf:"optional"` + Jobs types.List `tfsdk:"jobs" tf:"optional"` // This field represents the pagination token to retrieve the next page of // results. If this field is not in the response, it means no further // results for the request. @@ -1388,6 +1724,12 @@ func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringCre func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringRead(existingState ListJobComplianceForPolicyResponse) { } +func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Jobs": reflect.TypeOf(JobCompliance{}), + } +} + // List job policy compliance type ListJobComplianceRequest struct { // Use this field to specify the maximum number of results to be returned by @@ -1407,6 +1749,10 @@ func (newState *ListJobComplianceRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListJobComplianceRequest) SyncEffectiveFieldsDuringRead(existingState ListJobComplianceRequest) { } +func (a ListJobComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List jobs type ListJobsRequest struct { // Whether to include task and cluster details in the response. @@ -1431,6 +1777,10 @@ func (newState *ListJobsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListJobsRequest) SyncEffectiveFieldsDuringRead(existingState ListJobsRequest) { } +func (a ListJobsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List of jobs was retrieved successfully. type ListJobsResponse struct { // If true, additional jobs matching the provided filter are available for @@ -1438,7 +1788,7 @@ type ListJobsResponse struct { HasMore types.Bool `tfsdk:"has_more" tf:"optional"` // The list of jobs. Only included in the response if there are jobs to // list. - Jobs []BaseJob `tfsdk:"jobs" tf:"optional"` + Jobs types.List `tfsdk:"jobs" tf:"optional"` // A token that can be used to list the next page of jobs (if applicable). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // A token that can be used to list the previous page of jobs (if @@ -1452,6 +1802,12 @@ func (newState *ListJobsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListJobsResponse) SyncEffectiveFieldsDuringRead(existingState ListJobsResponse) { } +func (a ListJobsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Jobs": reflect.TypeOf(BaseJob{}), + } +} + // List job runs type ListRunsRequest struct { // If active_only is `true`, only active runs are included in the results; @@ -1498,6 +1854,10 @@ func (newState *ListRunsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListRunsRequest) SyncEffectiveFieldsDuringRead(existingState ListRunsRequest) { } +func (a ListRunsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List of runs was retrieved successfully. type ListRunsResponse struct { // If true, additional runs matching the provided filter are available for @@ -1510,7 +1870,7 @@ type ListRunsResponse struct { PrevPageToken types.String `tfsdk:"prev_page_token" tf:"optional"` // A list of runs, from most recently started to least. Only included in the // response if there are runs to list. - Runs []BaseRun `tfsdk:"runs" tf:"optional"` + Runs types.List `tfsdk:"runs" tf:"optional"` } func (newState *ListRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListRunsResponse) { @@ -1519,6 +1879,12 @@ func (newState *ListRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListRunsResponse) SyncEffectiveFieldsDuringRead(existingState ListRunsResponse) { } +func (a ListRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Runs": reflect.TypeOf(BaseRun{}), + } +} + type NotebookOutput struct { // The value passed to // [dbutils.notebook.exit()](/notebooks/notebook-workflows.html#notebook-workflows-exit). @@ -1537,6 +1903,10 @@ func (newState *NotebookOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Not func (newState *NotebookOutput) SyncEffectiveFieldsDuringRead(existingState NotebookOutput) { } +func (a NotebookOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type NotebookTask struct { // Base parameters to be used for each run of this job. If the run is // initiated by a call to :method:jobs/run Now with parameters specified, @@ -1555,7 +1925,7 @@ type NotebookTask struct { // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html#dbutils-widgets - BaseParameters map[string]types.String `tfsdk:"base_parameters" tf:"optional"` + BaseParameters types.Map `tfsdk:"base_parameters" tf:"optional"` // The path of the notebook to be run in the Databricks workspace or remote // repository. For notebooks stored in the Databricks workspace, the path // must be absolute and begin with a slash. For notebooks stored in a remote @@ -1584,6 +1954,12 @@ func (newState *NotebookTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Noteb func (newState *NotebookTask) SyncEffectiveFieldsDuringRead(existingState NotebookTask) { } +func (a NotebookTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "BaseParameters": reflect.TypeOf(""), + } +} + type PeriodicTriggerConfiguration struct { // The interval at which the trigger should run. Interval types.Int64 `tfsdk:"interval" tf:""` @@ -1597,6 +1973,10 @@ func (newState *PeriodicTriggerConfiguration) SyncEffectiveFieldsDuringCreateOrU func (newState *PeriodicTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState PeriodicTriggerConfiguration) { } +func (a PeriodicTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelineParams struct { // If true, triggers a full refresh on the delta live table. FullRefresh types.Bool `tfsdk:"full_refresh" tf:"optional"` @@ -1608,6 +1988,10 @@ func (newState *PipelineParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pip func (newState *PipelineParams) SyncEffectiveFieldsDuringRead(existingState PipelineParams) { } +func (a PipelineParams) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelineTask struct { // If true, triggers a full refresh on the delta live table. FullRefresh types.Bool `tfsdk:"full_refresh" tf:"optional"` @@ -1621,6 +2005,10 @@ func (newState *PipelineTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipel func (newState *PipelineTask) SyncEffectiveFieldsDuringRead(existingState PipelineTask) { } +func (a PipelineTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PythonWheelTask struct { // Named entry point to use, if it does not exist in the metadata of the // package it executes the function from the package directly using @@ -1629,12 +2017,12 @@ type PythonWheelTask struct { // Command-line parameters passed to Python wheel task in the form of // `["--name=task", "--data=dbfs:/path/to/data.json"]`. Leave it empty if // `parameters` is not null. - NamedParameters map[string]types.String `tfsdk:"named_parameters" tf:"optional"` + NamedParameters types.Map `tfsdk:"named_parameters" tf:"optional"` // Name of the package to execute PackageName types.String `tfsdk:"package_name" tf:""` // Command-line parameters passed to Python wheel task. Leave it empty if // `named_parameters` is not null. - Parameters []types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` } func (newState *PythonWheelTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan PythonWheelTask) { @@ -1643,6 +2031,13 @@ func (newState *PythonWheelTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Py func (newState *PythonWheelTask) SyncEffectiveFieldsDuringRead(existingState PythonWheelTask) { } +func (a PythonWheelTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NamedParameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(""), + } +} + type QueueDetails struct { // The reason for queuing the run. * `ACTIVE_RUNS_LIMIT_REACHED`: The run // was queued due to reaching the workspace limit of active task runs. * @@ -1662,6 +2057,10 @@ func (newState *QueueDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Queue func (newState *QueueDetails) SyncEffectiveFieldsDuringRead(existingState QueueDetails) { } +func (a QueueDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type QueueSettings struct { // If true, enable queueing for the job. This is a required field. Enabled types.Bool `tfsdk:"enabled" tf:""` @@ -1673,6 +2072,10 @@ func (newState *QueueSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan Queu func (newState *QueueSettings) SyncEffectiveFieldsDuringRead(existingState QueueSettings) { } +func (a QueueSettings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RepairHistoryItem struct { // The end time of the (repaired) run. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -1682,12 +2085,12 @@ type RepairHistoryItem struct { // The start time of the (repaired) run. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State []RunState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status []RunStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // The run IDs of the task runs that ran as part of this repair history // item. - TaskRunIds []types.Int64 `tfsdk:"task_run_ids" tf:"optional"` + TaskRunIds types.List `tfsdk:"task_run_ids" tf:"optional"` // The repair history item type. Indicates whether a run is the original run // or a repair run. Type types.String `tfsdk:"type" tf:"optional"` @@ -1699,11 +2102,19 @@ func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringRead(existingState RepairHistoryItem) { } +func (a RepairHistoryItem) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "State": reflect.TypeOf(RunState{}), + "Status": reflect.TypeOf(RunStatus{}), + "TaskRunIds": reflect.TypeOf(0), + } +} + type RepairRun struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt // run"]` - DbtCommands []types.String `tfsdk:"dbt_commands" tf:"optional"` + DbtCommands types.List `tfsdk:"dbt_commands" tf:"optional"` // A list of parameters for jobs with Spark JAR tasks, for example // `"jar_params": ["john doe", "35"]`. The parameters are used to invoke the // main function of the main class specified in the Spark JAR task. If not @@ -1716,10 +2127,10 @@ type RepairRun struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - JarParams []types.String `tfsdk:"jar_params" tf:"optional"` + JarParams types.List `tfsdk:"jar_params" tf:"optional"` // Job-level parameters used in the run. for example `"param": // "overriding_val"` - JobParameters map[string]types.String `tfsdk:"job_parameters" tf:"optional"` + JobParameters types.Map `tfsdk:"job_parameters" tf:"optional"` // The ID of the latest repair. This parameter is not required when // repairing a run for the first time, but must be provided on subsequent // requests to repair the same run. @@ -1743,11 +2154,11 @@ type RepairRun struct { // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html - NotebookParams map[string]types.String `tfsdk:"notebook_params" tf:"optional"` + NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams []PipelineParams `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` - PythonNamedParams map[string]types.String `tfsdk:"python_named_params" tf:"optional"` + PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example // `"python_params": ["john doe", "35"]`. The parameters are passed to // Python file as command-line parameters. If specified upon `run-now`, it @@ -1765,7 +2176,7 @@ type RepairRun struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - PythonParams []types.String `tfsdk:"python_params" tf:"optional"` + PythonParams types.List `tfsdk:"python_params" tf:"optional"` // If true, repair all failed tasks. Only one of `rerun_tasks` or // `rerun_all_failed_tasks` can be used. RerunAllFailedTasks types.Bool `tfsdk:"rerun_all_failed_tasks" tf:"optional"` @@ -1774,7 +2185,7 @@ type RepairRun struct { // `rerun_all_failed_tasks`. RerunDependentTasks types.Bool `tfsdk:"rerun_dependent_tasks" tf:"optional"` // The task keys of the task runs to repair. - RerunTasks []types.String `tfsdk:"rerun_tasks" tf:"optional"` + RerunTasks types.List `tfsdk:"rerun_tasks" tf:"optional"` // The job run ID of the run to repair. The run must not be in progress. RunId types.Int64 `tfsdk:"run_id" tf:""` // A list of parameters for jobs with spark submit task, for example @@ -1795,11 +2206,11 @@ type RepairRun struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - SparkSubmitParams []types.String `tfsdk:"spark_submit_params" tf:"optional"` + SparkSubmitParams types.List `tfsdk:"spark_submit_params" tf:"optional"` // A map from keys to values for jobs with SQL task, for example // `"sql_params": {"name": "john doe", "age": "35"}`. The SQL alert task // does not support custom parameters. - SqlParams map[string]types.String `tfsdk:"sql_params" tf:"optional"` + SqlParams types.Map `tfsdk:"sql_params" tf:"optional"` } func (newState *RepairRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepairRun) { @@ -1808,6 +2219,21 @@ func (newState *RepairRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepairRu func (newState *RepairRun) SyncEffectiveFieldsDuringRead(existingState RepairRun) { } +func (a RepairRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DbtCommands": reflect.TypeOf(""), + "JarParams": reflect.TypeOf(""), + "JobParameters": reflect.TypeOf(""), + "NotebookParams": reflect.TypeOf(""), + "PipelineParams": reflect.TypeOf(PipelineParams{}), + "PythonNamedParams": reflect.TypeOf(""), + "PythonParams": reflect.TypeOf(""), + "RerunTasks": reflect.TypeOf(""), + "SparkSubmitParams": reflect.TypeOf(""), + "SqlParams": reflect.TypeOf(""), + } +} + // Run repair was initiated. type RepairRunResponse struct { // The ID of the repair. Must be provided in subsequent repairs using the @@ -1821,6 +2247,10 @@ func (newState *RepairRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RepairRunResponse) SyncEffectiveFieldsDuringRead(existingState RepairRunResponse) { } +func (a RepairRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ResetJob struct { // The canonical identifier of the job to reset. This field is required. JobId types.Int64 `tfsdk:"job_id" tf:""` @@ -1829,7 +2259,7 @@ type ResetJob struct { // // Changes to the field `JobBaseSettings.timeout_seconds` are applied to // active runs. Changes to other fields are applied to future runs only. - NewSettings []JobSettings `tfsdk:"new_settings" tf:"object"` + NewSettings types.Object `tfsdk:"new_settings" tf:"object"` } func (newState *ResetJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResetJob) { @@ -1838,6 +2268,12 @@ func (newState *ResetJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResetJob) func (newState *ResetJob) SyncEffectiveFieldsDuringRead(existingState ResetJob) { } +func (a ResetJob) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NewSettings": reflect.TypeOf(JobSettings{}), + } +} + type ResetResponse struct { } @@ -1847,6 +2283,10 @@ func (newState *ResetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rese func (newState *ResetResponse) SyncEffectiveFieldsDuringRead(existingState ResetResponse) { } +func (a ResetResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ResolvedConditionTaskValues struct { Left types.String `tfsdk:"left" tf:"optional"` @@ -1859,8 +2299,12 @@ func (newState *ResolvedConditionTaskValues) SyncEffectiveFieldsDuringCreateOrUp func (newState *ResolvedConditionTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedConditionTaskValues) { } +func (a ResolvedConditionTaskValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ResolvedDbtTaskValues struct { - Commands []types.String `tfsdk:"commands" tf:"optional"` + Commands types.List `tfsdk:"commands" tf:"optional"` } func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedDbtTaskValues) { @@ -1869,8 +2313,14 @@ func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedDbtTaskValues) { } +func (a ResolvedDbtTaskValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Commands": reflect.TypeOf(""), + } +} + type ResolvedNotebookTaskValues struct { - BaseParameters map[string]types.String `tfsdk:"base_parameters" tf:"optional"` + BaseParameters types.Map `tfsdk:"base_parameters" tf:"optional"` } func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedNotebookTaskValues) { @@ -1879,8 +2329,14 @@ func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedNotebookTaskValues) { } +func (a ResolvedNotebookTaskValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "BaseParameters": reflect.TypeOf(""), + } +} + type ResolvedParamPairValues struct { - Parameters map[string]types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.Map `tfsdk:"parameters" tf:"optional"` } func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedParamPairValues) { @@ -1889,10 +2345,16 @@ func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringRead(existingState ResolvedParamPairValues) { } +func (a ResolvedParamPairValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type ResolvedPythonWheelTaskValues struct { - NamedParameters map[string]types.String `tfsdk:"named_parameters" tf:"optional"` + NamedParameters types.Map `tfsdk:"named_parameters" tf:"optional"` - Parameters []types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` } func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedPythonWheelTaskValues) { @@ -1901,10 +2363,17 @@ func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringCreateOr func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedPythonWheelTaskValues) { } +func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "NamedParameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(""), + } +} + type ResolvedRunJobTaskValues struct { - JobParameters map[string]types.String `tfsdk:"job_parameters" tf:"optional"` + JobParameters types.Map `tfsdk:"job_parameters" tf:"optional"` - Parameters map[string]types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.Map `tfsdk:"parameters" tf:"optional"` } func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedRunJobTaskValues) { @@ -1913,8 +2382,15 @@ func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedRunJobTaskValues) { } +func (a ResolvedRunJobTaskValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "JobParameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(""), + } +} + type ResolvedStringParamsValues struct { - Parameters []types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` } func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedStringParamsValues) { @@ -1923,26 +2399,32 @@ func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringRead(existingState ResolvedStringParamsValues) { } +func (a ResolvedStringParamsValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type ResolvedValues struct { - ConditionTask []ResolvedConditionTaskValues `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` - DbtTask []ResolvedDbtTaskValues `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` - NotebookTask []ResolvedNotebookTaskValues `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` - PythonWheelTask []ResolvedPythonWheelTaskValues `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` - RunJobTask []ResolvedRunJobTaskValues `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` - SimulationTask []ResolvedParamPairValues `tfsdk:"simulation_task" tf:"optional,object"` + SimulationTask types.Object `tfsdk:"simulation_task" tf:"optional,object"` - SparkJarTask []ResolvedStringParamsValues `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` - SparkPythonTask []ResolvedStringParamsValues `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` - SparkSubmitTask []ResolvedStringParamsValues `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` - SqlTask []ResolvedParamPairValues `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` } func (newState *ResolvedValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedValues) { @@ -1951,6 +2433,21 @@ func (newState *ResolvedValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResolvedValues) SyncEffectiveFieldsDuringRead(existingState ResolvedValues) { } +func (a ResolvedValues) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ConditionTask": reflect.TypeOf(ResolvedConditionTaskValues{}), + "DbtTask": reflect.TypeOf(ResolvedDbtTaskValues{}), + "NotebookTask": reflect.TypeOf(ResolvedNotebookTaskValues{}), + "PythonWheelTask": reflect.TypeOf(ResolvedPythonWheelTaskValues{}), + "RunJobTask": reflect.TypeOf(ResolvedRunJobTaskValues{}), + "SimulationTask": reflect.TypeOf(ResolvedParamPairValues{}), + "SparkJarTask": reflect.TypeOf(ResolvedStringParamsValues{}), + "SparkPythonTask": reflect.TypeOf(ResolvedStringParamsValues{}), + "SparkSubmitTask": reflect.TypeOf(ResolvedStringParamsValues{}), + "SqlTask": reflect.TypeOf(ResolvedParamPairValues{}), + } +} + // Run was retrieved successfully type Run struct { // The sequence number of this run attempt for a triggered job run. The @@ -1970,10 +2467,10 @@ type Run struct { // The cluster used for this run. If the run is specified to use a new // cluster, this field is set once the Jobs service has requested a cluster // for the run. - ClusterInstance []ClusterInstance `tfsdk:"cluster_instance" tf:"optional,object"` + ClusterInstance types.Object `tfsdk:"cluster_instance" tf:"optional,object"` // A snapshot of the job’s cluster specification when this run was // created. - ClusterSpec []ClusterSpec `tfsdk:"cluster_spec" tf:"optional,object"` + ClusterSpec types.Object `tfsdk:"cluster_spec" tf:"optional,object"` // The creator user name. This field won’t be included in the response if // the user has already been deleted. CreatorUserName types.String `tfsdk:"creator_user_name" tf:"optional"` @@ -2000,18 +2497,18 @@ type Run struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource []GitSource `tfsdk:"git_source" tf:"optional,object"` + GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` // Only populated by for-each iterations. The parent for-each task is // located in tasks array. - Iterations []RunTask `tfsdk:"iterations" tf:"optional"` + Iterations types.List `tfsdk:"iterations" tf:"optional"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. - JobClusters []JobCluster `tfsdk:"job_clusters" tf:"optional"` + JobClusters types.List `tfsdk:"job_clusters" tf:"optional"` // The canonical identifier of the job that contains this run. JobId types.Int64 `tfsdk:"job_id" tf:"optional"` // Job-level parameters used in the run - JobParameters []JobParameter `tfsdk:"job_parameters" tf:"optional"` + JobParameters types.List `tfsdk:"job_parameters" tf:"optional"` // ID of the job run that this run belongs to. For legacy and single-task // job runs the field is populated with the job run ID. For task runs, the // field is populated with the ID of the job run that the task run belongs @@ -2026,11 +2523,11 @@ type Run struct { // run_id of the original attempt; otherwise, it is the same as the run_id. OriginalAttemptRunId types.Int64 `tfsdk:"original_attempt_run_id" tf:"optional"` // The parameters used for this run. - OverridingParameters []RunParameters `tfsdk:"overriding_parameters" tf:"optional,object"` + OverridingParameters types.Object `tfsdk:"overriding_parameters" tf:"optional,object"` // The time in milliseconds that the run has spent in the queue. QueueDuration types.Int64 `tfsdk:"queue_duration" tf:"optional"` // The repair history of the run. - RepairHistory []RepairHistoryItem `tfsdk:"repair_history" tf:"optional"` + RepairHistory types.List `tfsdk:"repair_history" tf:"optional"` // The time in milliseconds it took the job run and all of its repairs to // finish. RunDuration types.Int64 `tfsdk:"run_duration" tf:"optional"` @@ -2051,7 +2548,7 @@ type Run struct { RunType types.String `tfsdk:"run_type" tf:"optional"` // The cron schedule that triggered this run if it was triggered by the // periodic scheduler. - Schedule []CronSchedule `tfsdk:"schedule" tf:"optional,object"` + Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` // The time in milliseconds it took to set up the cluster. For runs that run // on new clusters this is the cluster creation time, for runs that run on // existing clusters this time should be very short. The duration of a task @@ -2066,12 +2563,12 @@ type Run struct { // new cluster, this is the time the cluster creation call is issued. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State []RunState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status []RunStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // The list of tasks performed by the run. Each task has its own `run_id` // which you can use to call `JobsGetOutput` to retrieve the run resutls. - Tasks []RunTask `tfsdk:"tasks" tf:"optional"` + Tasks types.List `tfsdk:"tasks" tf:"optional"` // The type of trigger that fired this run. // // * `PERIODIC`: Schedules that periodically trigger runs, such as a cron @@ -2084,7 +2581,7 @@ type Run struct { // arrival. * `TABLE`: Indicates a run that is triggered by a table update. Trigger types.String `tfsdk:"trigger" tf:"optional"` // Additional details about what triggered the run - TriggerInfo []TriggerInfo `tfsdk:"trigger_info" tf:"optional,object"` + TriggerInfo types.Object `tfsdk:"trigger_info" tf:"optional,object"` } func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { @@ -2093,6 +2590,24 @@ func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { } +func (a Run) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ClusterInstance": reflect.TypeOf(ClusterInstance{}), + "ClusterSpec": reflect.TypeOf(ClusterSpec{}), + "GitSource": reflect.TypeOf(GitSource{}), + "Iterations": reflect.TypeOf(RunTask{}), + "JobClusters": reflect.TypeOf(JobCluster{}), + "JobParameters": reflect.TypeOf(JobParameter{}), + "OverridingParameters": reflect.TypeOf(RunParameters{}), + "RepairHistory": reflect.TypeOf(RepairHistoryItem{}), + "Schedule": reflect.TypeOf(CronSchedule{}), + "State": reflect.TypeOf(RunState{}), + "Status": reflect.TypeOf(RunStatus{}), + "Tasks": reflect.TypeOf(RunTask{}), + "TriggerInfo": reflect.TypeOf(TriggerInfo{}), + } +} + type RunConditionTask struct { // The left operand of the condition task. Can be either a string value or a // job state or parameter reference. @@ -2122,6 +2637,10 @@ func (newState *RunConditionTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RunConditionTask) SyncEffectiveFieldsDuringRead(existingState RunConditionTask) { } +func (a RunConditionTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RunForEachTask struct { // An optional maximum allowed number of concurrent runs of the task. Set // this value if you want to be able to execute multiple runs of the task @@ -2132,9 +2651,9 @@ type RunForEachTask struct { Inputs types.String `tfsdk:"inputs" tf:""` // Read only field. Populated for GetRun and ListRuns RPC calls and stores // the execution stats of an For each task - Stats []ForEachStats `tfsdk:"stats" tf:"optional,object"` + Stats types.Object `tfsdk:"stats" tf:"optional,object"` // Configuration for the task that will be run for each element in the array - Task []Task `tfsdk:"task" tf:"object"` + Task types.Object `tfsdk:"task" tf:"object"` } func (newState *RunForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunForEachTask) { @@ -2143,6 +2662,13 @@ func (newState *RunForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run func (newState *RunForEachTask) SyncEffectiveFieldsDuringRead(existingState RunForEachTask) { } +func (a RunForEachTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Stats": reflect.TypeOf(ForEachStats{}), + "Task": reflect.TypeOf(Task{}), + } +} + type RunJobOutput struct { // The run id of the triggered job run RunId types.Int64 `tfsdk:"run_id" tf:"optional"` @@ -2154,11 +2680,15 @@ func (newState *RunJobOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJo func (newState *RunJobOutput) SyncEffectiveFieldsDuringRead(existingState RunJobOutput) { } +func (a RunJobOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RunJobTask struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt // run"]` - DbtCommands []types.String `tfsdk:"dbt_commands" tf:"optional"` + DbtCommands types.List `tfsdk:"dbt_commands" tf:"optional"` // A list of parameters for jobs with Spark JAR tasks, for example // `"jar_params": ["john doe", "35"]`. The parameters are used to invoke the // main function of the main class specified in the Spark JAR task. If not @@ -2171,11 +2701,11 @@ type RunJobTask struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - JarParams []types.String `tfsdk:"jar_params" tf:"optional"` + JarParams types.List `tfsdk:"jar_params" tf:"optional"` // ID of the job to trigger. JobId types.Int64 `tfsdk:"job_id" tf:""` // Job-level parameters used to trigger the job. - JobParameters map[string]types.String `tfsdk:"job_parameters" tf:"optional"` + JobParameters types.Map `tfsdk:"job_parameters" tf:"optional"` // A map from keys to values for jobs with notebook task, for example // `"notebook_params": {"name": "john doe", "age": "35"}`. The map is passed // to the notebook and is accessible through the [dbutils.widgets.get] @@ -2195,11 +2725,11 @@ type RunJobTask struct { // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html - NotebookParams map[string]types.String `tfsdk:"notebook_params" tf:"optional"` + NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams []PipelineParams `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` - PythonNamedParams map[string]types.String `tfsdk:"python_named_params" tf:"optional"` + PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example // `"python_params": ["john doe", "35"]`. The parameters are passed to // Python file as command-line parameters. If specified upon `run-now`, it @@ -2217,7 +2747,7 @@ type RunJobTask struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - PythonParams []types.String `tfsdk:"python_params" tf:"optional"` + PythonParams types.List `tfsdk:"python_params" tf:"optional"` // A list of parameters for jobs with spark submit task, for example // `"spark_submit_params": ["--class", // "org.apache.spark.examples.SparkPi"]`. The parameters are passed to @@ -2236,11 +2766,11 @@ type RunJobTask struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - SparkSubmitParams []types.String `tfsdk:"spark_submit_params" tf:"optional"` + SparkSubmitParams types.List `tfsdk:"spark_submit_params" tf:"optional"` // A map from keys to values for jobs with SQL task, for example // `"sql_params": {"name": "john doe", "age": "35"}`. The SQL alert task // does not support custom parameters. - SqlParams map[string]types.String `tfsdk:"sql_params" tf:"optional"` + SqlParams types.Map `tfsdk:"sql_params" tf:"optional"` } func (newState *RunJobTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJobTask) { @@ -2249,11 +2779,25 @@ func (newState *RunJobTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJobT func (newState *RunJobTask) SyncEffectiveFieldsDuringRead(existingState RunJobTask) { } +func (a RunJobTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DbtCommands": reflect.TypeOf(""), + "JarParams": reflect.TypeOf(""), + "JobParameters": reflect.TypeOf(""), + "NotebookParams": reflect.TypeOf(""), + "PipelineParams": reflect.TypeOf(PipelineParams{}), + "PythonNamedParams": reflect.TypeOf(""), + "PythonParams": reflect.TypeOf(""), + "SparkSubmitParams": reflect.TypeOf(""), + "SqlParams": reflect.TypeOf(""), + } +} + type RunNow struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt // run"]` - DbtCommands []types.String `tfsdk:"dbt_commands" tf:"optional"` + DbtCommands types.List `tfsdk:"dbt_commands" tf:"optional"` // An optional token to guarantee the idempotency of job run requests. If a // run with the provided token already exists, the request does not create a // new run but returns the ID of the existing run instead. If a run with the @@ -2281,12 +2825,12 @@ type RunNow struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - JarParams []types.String `tfsdk:"jar_params" tf:"optional"` + JarParams types.List `tfsdk:"jar_params" tf:"optional"` // The ID of the job to be executed JobId types.Int64 `tfsdk:"job_id" tf:""` // Job-level parameters used in the run. for example `"param": // "overriding_val"` - JobParameters map[string]types.String `tfsdk:"job_parameters" tf:"optional"` + JobParameters types.Map `tfsdk:"job_parameters" tf:"optional"` // A map from keys to values for jobs with notebook task, for example // `"notebook_params": {"name": "john doe", "age": "35"}`. The map is passed // to the notebook and is accessible through the [dbutils.widgets.get] @@ -2306,14 +2850,14 @@ type RunNow struct { // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html - NotebookParams map[string]types.String `tfsdk:"notebook_params" tf:"optional"` + NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // A list of task keys to run inside of the job. If this field is not // provided, all tasks in the job will be run. - Only []types.String `tfsdk:"only" tf:"optional"` + Only types.List `tfsdk:"only" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams []PipelineParams `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` - PythonNamedParams map[string]types.String `tfsdk:"python_named_params" tf:"optional"` + PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example // `"python_params": ["john doe", "35"]`. The parameters are passed to // Python file as command-line parameters. If specified upon `run-now`, it @@ -2331,9 +2875,9 @@ type RunNow struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - PythonParams []types.String `tfsdk:"python_params" tf:"optional"` + PythonParams types.List `tfsdk:"python_params" tf:"optional"` // The queue settings of the run. - Queue []QueueSettings `tfsdk:"queue" tf:"optional,object"` + Queue types.Object `tfsdk:"queue" tf:"optional,object"` // A list of parameters for jobs with spark submit task, for example // `"spark_submit_params": ["--class", // "org.apache.spark.examples.SparkPi"]`. The parameters are passed to @@ -2352,11 +2896,11 @@ type RunNow struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - SparkSubmitParams []types.String `tfsdk:"spark_submit_params" tf:"optional"` + SparkSubmitParams types.List `tfsdk:"spark_submit_params" tf:"optional"` // A map from keys to values for jobs with SQL task, for example // `"sql_params": {"name": "john doe", "age": "35"}`. The SQL alert task // does not support custom parameters. - SqlParams map[string]types.String `tfsdk:"sql_params" tf:"optional"` + SqlParams types.Map `tfsdk:"sql_params" tf:"optional"` } func (newState *RunNow) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunNow) { @@ -2365,6 +2909,22 @@ func (newState *RunNow) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunNow) { func (newState *RunNow) SyncEffectiveFieldsDuringRead(existingState RunNow) { } +func (a RunNow) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DbtCommands": reflect.TypeOf(""), + "JarParams": reflect.TypeOf(""), + "JobParameters": reflect.TypeOf(""), + "NotebookParams": reflect.TypeOf(""), + "Only": reflect.TypeOf(""), + "PipelineParams": reflect.TypeOf(PipelineParams{}), + "PythonNamedParams": reflect.TypeOf(""), + "PythonParams": reflect.TypeOf(""), + "Queue": reflect.TypeOf(QueueSettings{}), + "SparkSubmitParams": reflect.TypeOf(""), + "SqlParams": reflect.TypeOf(""), + } +} + // Run was started successfully. type RunNowResponse struct { // A unique identifier for this job run. This is set to the same value as @@ -2380,10 +2940,14 @@ func (newState *RunNowResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run func (newState *RunNowResponse) SyncEffectiveFieldsDuringRead(existingState RunNowResponse) { } +func (a RunNowResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Run output was retrieved successfully. type RunOutput struct { // The output of a dbt task, if available. - DbtOutput []DbtOutput `tfsdk:"dbt_output" tf:"optional,object"` + DbtOutput types.Object `tfsdk:"dbt_output" tf:"optional,object"` // An error message indicating why a task failed or why output is not // available. The message is unstructured, and its exact format is subject // to change. @@ -2404,7 +2968,7 @@ type RunOutput struct { // Whether the logs are truncated. LogsTruncated types.Bool `tfsdk:"logs_truncated" tf:"optional"` // All details of the run except for its output. - Metadata []Run `tfsdk:"metadata" tf:"optional,object"` + Metadata types.Object `tfsdk:"metadata" tf:"optional,object"` // The output of a notebook task, if available. A notebook task that // terminates (either successfully or with a failure) without calling // `dbutils.notebook.exit()` is considered to have an empty output. This @@ -2413,11 +2977,11 @@ type RunOutput struct { // the [ClusterLogConf] field to configure log storage for the job cluster. // // [ClusterLogConf]: https://docs.databricks.com/dev-tools/api/latest/clusters.html#clusterlogconf - NotebookOutput []NotebookOutput `tfsdk:"notebook_output" tf:"optional,object"` + NotebookOutput types.Object `tfsdk:"notebook_output" tf:"optional,object"` // The output of a run job task, if available - RunJobOutput []RunJobOutput `tfsdk:"run_job_output" tf:"optional,object"` + RunJobOutput types.Object `tfsdk:"run_job_output" tf:"optional,object"` // The output of a SQL task, if available. - SqlOutput []SqlOutput `tfsdk:"sql_output" tf:"optional,object"` + SqlOutput types.Object `tfsdk:"sql_output" tf:"optional,object"` } func (newState *RunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunOutput) { @@ -2426,11 +2990,21 @@ func (newState *RunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunOutpu func (newState *RunOutput) SyncEffectiveFieldsDuringRead(existingState RunOutput) { } +func (a RunOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DbtOutput": reflect.TypeOf(DbtOutput{}), + "Metadata": reflect.TypeOf(Run{}), + "NotebookOutput": reflect.TypeOf(NotebookOutput{}), + "RunJobOutput": reflect.TypeOf(RunJobOutput{}), + "SqlOutput": reflect.TypeOf(SqlOutput{}), + } +} + type RunParameters struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt // run"]` - DbtCommands []types.String `tfsdk:"dbt_commands" tf:"optional"` + DbtCommands types.List `tfsdk:"dbt_commands" tf:"optional"` // A list of parameters for jobs with Spark JAR tasks, for example // `"jar_params": ["john doe", "35"]`. The parameters are used to invoke the // main function of the main class specified in the Spark JAR task. If not @@ -2443,7 +3017,7 @@ type RunParameters struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - JarParams []types.String `tfsdk:"jar_params" tf:"optional"` + JarParams types.List `tfsdk:"jar_params" tf:"optional"` // A map from keys to values for jobs with notebook task, for example // `"notebook_params": {"name": "john doe", "age": "35"}`. The map is passed // to the notebook and is accessible through the [dbutils.widgets.get] @@ -2463,11 +3037,11 @@ type RunParameters struct { // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html - NotebookParams map[string]types.String `tfsdk:"notebook_params" tf:"optional"` + NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams []PipelineParams `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` - PythonNamedParams map[string]types.String `tfsdk:"python_named_params" tf:"optional"` + PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example // `"python_params": ["john doe", "35"]`. The parameters are passed to // Python file as command-line parameters. If specified upon `run-now`, it @@ -2485,7 +3059,7 @@ type RunParameters struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - PythonParams []types.String `tfsdk:"python_params" tf:"optional"` + PythonParams types.List `tfsdk:"python_params" tf:"optional"` // A list of parameters for jobs with spark submit task, for example // `"spark_submit_params": ["--class", // "org.apache.spark.examples.SparkPi"]`. The parameters are passed to @@ -2504,11 +3078,11 @@ type RunParameters struct { // non-ASCII characters are Chinese, Japanese kanjis, and emojis. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - SparkSubmitParams []types.String `tfsdk:"spark_submit_params" tf:"optional"` + SparkSubmitParams types.List `tfsdk:"spark_submit_params" tf:"optional"` // A map from keys to values for jobs with SQL task, for example // `"sql_params": {"name": "john doe", "age": "35"}`. The SQL alert task // does not support custom parameters. - SqlParams map[string]types.String `tfsdk:"sql_params" tf:"optional"` + SqlParams types.Map `tfsdk:"sql_params" tf:"optional"` } func (newState *RunParameters) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunParameters) { @@ -2517,6 +3091,19 @@ func (newState *RunParameters) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunP func (newState *RunParameters) SyncEffectiveFieldsDuringRead(existingState RunParameters) { } +func (a RunParameters) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DbtCommands": reflect.TypeOf(""), + "JarParams": reflect.TypeOf(""), + "NotebookParams": reflect.TypeOf(""), + "PipelineParams": reflect.TypeOf(PipelineParams{}), + "PythonNamedParams": reflect.TypeOf(""), + "PythonParams": reflect.TypeOf(""), + "SparkSubmitParams": reflect.TypeOf(""), + "SqlParams": reflect.TypeOf(""), + } +} + // The current state of the run. type RunState struct { // A value indicating the run's current lifecycle state. This field is @@ -2541,15 +3128,19 @@ func (newState *RunState) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunState) func (newState *RunState) SyncEffectiveFieldsDuringRead(existingState RunState) { } +func (a RunState) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The current status of the run type RunStatus struct { // If the run was queued, details about the reason for queuing the run. - QueueDetails []QueueDetails `tfsdk:"queue_details" tf:"optional,object"` + QueueDetails types.Object `tfsdk:"queue_details" tf:"optional,object"` // The current state of the run. State types.String `tfsdk:"state" tf:"optional"` // If the run is in a TERMINATING or TERMINATED state, details about the // reason for terminating the run. - TerminationDetails []TerminationDetails `tfsdk:"termination_details" tf:"optional,object"` + TerminationDetails types.Object `tfsdk:"termination_details" tf:"optional,object"` } func (newState *RunStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunStatus) { @@ -2558,6 +3149,13 @@ func (newState *RunStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunStatu func (newState *RunStatus) SyncEffectiveFieldsDuringRead(existingState RunStatus) { } +func (a RunStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "QueueDetails": reflect.TypeOf(QueueDetails{}), + "TerminationDetails": reflect.TypeOf(TerminationDetails{}), + } +} + // Used when outputting a child run, in GetRun or ListRuns. type RunTask struct { // The sequence number of this run attempt for a triggered job run. The @@ -2577,26 +3175,26 @@ type RunTask struct { // The cluster used for this run. If the run is specified to use a new // cluster, this field is set once the Jobs service has requested a cluster // for the run. - ClusterInstance []ClusterInstance `tfsdk:"cluster_instance" tf:"optional,object"` + ClusterInstance types.Object `tfsdk:"cluster_instance" tf:"optional,object"` // The task evaluates a condition that can be used to control the execution // of other tasks when the `condition_task` field is present. The condition // task does not require a cluster to execute and does not support retries // or notifications. - ConditionTask []RunConditionTask `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` // The task runs one or more dbt commands when the `dbt_task` field is // present. The dbt task requires both Databricks SQL and the ability to use // a serverless or a pro SQL warehouse. - DbtTask []DbtTask `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` // An optional array of objects specifying the dependency graph of the task. // All tasks specified in this field must complete successfully before // executing this task. The key is `task_key`, and the value is the name // assigned to the dependent task. - DependsOn []TaskDependency `tfsdk:"depends_on" tf:"optional"` + DependsOn types.List `tfsdk:"depends_on" tf:"optional"` // An optional description for this task. Description types.String `tfsdk:"description" tf:"optional"` // An optional set of email addresses notified when the task run begins or // completes. The default behavior is to not send any emails. - EmailNotifications []JobEmailNotifications `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` // The time at which this run ended in epoch milliseconds (milliseconds // since 1/1/1970 UTC). This field is set to 0 if the job is still running. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -2619,7 +3217,7 @@ type RunTask struct { ExistingClusterId types.String `tfsdk:"existing_cluster_id" tf:"optional"` // The task executes a nested task for every input provided when the // `for_each_task` field is present. - ForEachTask []RunForEachTask `tfsdk:"for_each_task" tf:"optional,object"` + ForEachTask types.Object `tfsdk:"for_each_task" tf:"optional,object"` // An optional specification for a remote Git repository containing the // source code used by tasks. Version-controlled source code is supported by // notebook, dbt, Python script, and SQL File tasks. If `git_source` is set, @@ -2628,32 +3226,32 @@ type RunTask struct { // `WORKSPACE` on the task. Note: dbt and SQL File tasks support only // version-controlled sources. If dbt or SQL File tasks are used, // `git_source` must be defined on the job. - GitSource []GitSource `tfsdk:"git_source" tf:"optional,object"` + GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` // If job_cluster_key, this task is executed reusing the cluster specified // in `job.settings.job_clusters`. JobClusterKey types.String `tfsdk:"job_cluster_key" tf:"optional"` // An optional list of libraries to be installed on the cluster. The default // value is an empty list. - Libraries compute.Library `tfsdk:"library" tf:"optional"` + Libraries types.List `tfsdk:"library" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. - NotebookTask []NotebookTask `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // task run. - NotificationSettings []TaskNotificationSettings `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` // The task triggers a pipeline update when the `pipeline_task` field is // present. Only pipelines configured to use triggered more are supported. - PipelineTask []PipelineTask `tfsdk:"pipeline_task" tf:"optional,object"` + PipelineTask types.Object `tfsdk:"pipeline_task" tf:"optional,object"` // The task runs a Python wheel when the `python_wheel_task` field is // present. - PythonWheelTask []PythonWheelTask `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` // The time in milliseconds that the run has spent in the queue. QueueDuration types.Int64 `tfsdk:"queue_duration" tf:"optional"` // Parameter values including resolved references - ResolvedValues []ResolvedValues `tfsdk:"resolved_values" tf:"optional,object"` + ResolvedValues types.Object `tfsdk:"resolved_values" tf:"optional,object"` // The time in milliseconds it took the job run and all of its repairs to // finish. RunDuration types.Int64 `tfsdk:"run_duration" tf:"optional"` @@ -2665,7 +3263,7 @@ type RunTask struct { // possible values. RunIf types.String `tfsdk:"run_if" tf:"optional"` // The task triggers another job when the `run_job_task` field is present. - RunJobTask []RunJobTask `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` RunPageUrl types.String `tfsdk:"run_page_url" tf:"optional"` // The time in milliseconds it took to set up the cluster. For runs that run @@ -2677,10 +3275,10 @@ type RunTask struct { // `run_duration` field. SetupDuration types.Int64 `tfsdk:"setup_duration" tf:"optional"` // The task runs a JAR when the `spark_jar_task` field is present. - SparkJarTask []SparkJarTask `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` // The task runs a Python file when the `spark_python_task` field is // present. - SparkPythonTask []SparkPythonTask `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` // (Legacy) The task runs the spark-submit script when the // `spark_submit_task` field is present. This task can run only on new // clusters and is not compatible with serverless compute. @@ -2699,19 +3297,19 @@ type RunTask struct { // // The `--jars`, `--py-files`, `--files` arguments support DBFS and S3 // paths. - SparkSubmitTask []SparkSubmitTask `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` // The task runs a SQL query or file, or it refreshes a SQL alert or a // legacy SQL dashboard when the `sql_task` field is present. - SqlTask []SqlTask `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` // The time at which this run was started in epoch milliseconds // (milliseconds since 1/1/1970 UTC). This may not be the time when the job // task starts executing, for example, if the job is scheduled to run on a // new cluster, this is the time the cluster creation call is issued. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State []RunState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status []RunStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // A unique name for the task. This field is used to refer to this task from // other tasks. This field is required and must be unique within its parent // job. On Update or Reset, this field is used to reference the tasks to be @@ -2723,7 +3321,7 @@ type RunTask struct { // A collection of system notification IDs to notify when the run begins or // completes. The default behavior is to not send any system notifications. // Task webhooks respect the task notification settings. - WebhookNotifications []WebhookNotifications `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *RunTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTask) { @@ -2732,6 +3330,33 @@ func (newState *RunTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTask) { func (newState *RunTask) SyncEffectiveFieldsDuringRead(existingState RunTask) { } +func (a RunTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ClusterInstance": reflect.TypeOf(ClusterInstance{}), + "ConditionTask": reflect.TypeOf(RunConditionTask{}), + "DbtTask": reflect.TypeOf(DbtTask{}), + "DependsOn": reflect.TypeOf(TaskDependency{}), + "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), + "ForEachTask": reflect.TypeOf(RunForEachTask{}), + "GitSource": reflect.TypeOf(GitSource{}), + "Libraries": reflect.TypeOf(compute.Library{}), + "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + "NotebookTask": reflect.TypeOf(NotebookTask{}), + "NotificationSettings": reflect.TypeOf(TaskNotificationSettings{}), + "PipelineTask": reflect.TypeOf(PipelineTask{}), + "PythonWheelTask": reflect.TypeOf(PythonWheelTask{}), + "ResolvedValues": reflect.TypeOf(ResolvedValues{}), + "RunJobTask": reflect.TypeOf(RunJobTask{}), + "SparkJarTask": reflect.TypeOf(SparkJarTask{}), + "SparkPythonTask": reflect.TypeOf(SparkPythonTask{}), + "SparkSubmitTask": reflect.TypeOf(SparkSubmitTask{}), + "SqlTask": reflect.TypeOf(SqlTask{}), + "State": reflect.TypeOf(RunState{}), + "Status": reflect.TypeOf(RunStatus{}), + "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + } +} + type SparkJarTask struct { // Deprecated since 04/2016. Provide a `jar` through the `libraries` field // instead. For an example, see :method:jobs/create. @@ -2748,7 +3373,7 @@ type SparkJarTask struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - Parameters []types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` } func (newState *SparkJarTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparkJarTask) { @@ -2757,6 +3382,12 @@ func (newState *SparkJarTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spark func (newState *SparkJarTask) SyncEffectiveFieldsDuringRead(existingState SparkJarTask) { } +func (a SparkJarTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type SparkPythonTask struct { // Command line parameters passed to the Python file. // @@ -2764,7 +3395,7 @@ type SparkPythonTask struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - Parameters []types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // The Python file to be executed. Cloud file URIs (such as dbfs:/, s3:/, // adls:/, gcs:/) and workspace paths are supported. For python files stored // in the Databricks workspace, the path must be absolute and begin with @@ -2789,6 +3420,12 @@ func (newState *SparkPythonTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sp func (newState *SparkPythonTask) SyncEffectiveFieldsDuringRead(existingState SparkPythonTask) { } +func (a SparkPythonTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type SparkSubmitTask struct { // Command-line parameters passed to spark submit. // @@ -2796,7 +3433,7 @@ type SparkSubmitTask struct { // about job runs. // // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - Parameters []types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` } func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparkSubmitTask) { @@ -2805,6 +3442,12 @@ func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sp func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringRead(existingState SparkSubmitTask) { } +func (a SparkSubmitTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type SqlAlertOutput struct { // The state of the SQL alert. // @@ -2818,7 +3461,7 @@ type SqlAlertOutput struct { // with the SQL alert is required to view this field. QueryText types.String `tfsdk:"query_text" tf:"optional"` // Information about SQL statements executed in the run. - SqlStatements []SqlStatementOutput `tfsdk:"sql_statements" tf:"optional"` + SqlStatements types.List `tfsdk:"sql_statements" tf:"optional"` // The canonical identifier of the SQL warehouse. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` } @@ -2829,11 +3472,17 @@ func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringRead(existingState SqlAlertOutput) { } +func (a SqlAlertOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SqlStatements": reflect.TypeOf(SqlStatementOutput{}), + } +} + type SqlDashboardOutput struct { // The canonical identifier of the SQL warehouse. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` // Widgets executed in the run. Only SQL query based widgets are listed. - Widgets []SqlDashboardWidgetOutput `tfsdk:"widgets" tf:"optional"` + Widgets types.List `tfsdk:"widgets" tf:"optional"` } func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlDashboardOutput) { @@ -2842,11 +3491,17 @@ func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringRead(existingState SqlDashboardOutput) { } +func (a SqlDashboardOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Widgets": reflect.TypeOf(SqlDashboardWidgetOutput{}), + } +} + type SqlDashboardWidgetOutput struct { // Time (in epoch milliseconds) when execution of the SQL widget ends. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` // The information about the error when execution fails. - Error []SqlOutputError `tfsdk:"error" tf:"optional,object"` + Error types.Object `tfsdk:"error" tf:"optional,object"` // The link to find the output results. OutputLink types.String `tfsdk:"output_link" tf:"optional"` // Time (in epoch milliseconds) when execution of the SQL widget starts. @@ -2865,13 +3520,19 @@ func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringRead(existingState SqlDashboardWidgetOutput) { } +func (a SqlDashboardWidgetOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Error": reflect.TypeOf(SqlOutputError{}), + } +} + type SqlOutput struct { // The output of a SQL alert task, if available. - AlertOutput []SqlAlertOutput `tfsdk:"alert_output" tf:"optional,object"` + AlertOutput types.Object `tfsdk:"alert_output" tf:"optional,object"` // The output of a SQL dashboard task, if available. - DashboardOutput []SqlDashboardOutput `tfsdk:"dashboard_output" tf:"optional,object"` + DashboardOutput types.Object `tfsdk:"dashboard_output" tf:"optional,object"` // The output of a SQL query task, if available. - QueryOutput []SqlQueryOutput `tfsdk:"query_output" tf:"optional,object"` + QueryOutput types.Object `tfsdk:"query_output" tf:"optional,object"` } func (newState *SqlOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlOutput) { @@ -2880,6 +3541,14 @@ func (newState *SqlOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlOutpu func (newState *SqlOutput) SyncEffectiveFieldsDuringRead(existingState SqlOutput) { } +func (a SqlOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AlertOutput": reflect.TypeOf(SqlAlertOutput{}), + "DashboardOutput": reflect.TypeOf(SqlDashboardOutput{}), + "QueryOutput": reflect.TypeOf(SqlQueryOutput{}), + } +} + type SqlOutputError struct { // The error message when execution fails. Message types.String `tfsdk:"message" tf:"optional"` @@ -2891,6 +3560,10 @@ func (newState *SqlOutputError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlOutputError) SyncEffectiveFieldsDuringRead(existingState SqlOutputError) { } +func (a SqlOutputError) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SqlQueryOutput struct { EndpointId types.String `tfsdk:"endpoint_id" tf:"optional"` // The link to find the output results. @@ -2899,7 +3572,7 @@ type SqlQueryOutput struct { // required to view this field. QueryText types.String `tfsdk:"query_text" tf:"optional"` // Information about SQL statements executed in the run. - SqlStatements []SqlStatementOutput `tfsdk:"sql_statements" tf:"optional"` + SqlStatements types.List `tfsdk:"sql_statements" tf:"optional"` // The canonical identifier of the SQL warehouse. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` } @@ -2910,6 +3583,12 @@ func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringRead(existingState SqlQueryOutput) { } +func (a SqlQueryOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SqlStatements": reflect.TypeOf(SqlStatementOutput{}), + } +} + type SqlStatementOutput struct { // A key that can be used to look up query details. LookupKey types.String `tfsdk:"lookup_key" tf:"optional"` @@ -2921,19 +3600,23 @@ func (newState *SqlStatementOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SqlStatementOutput) SyncEffectiveFieldsDuringRead(existingState SqlStatementOutput) { } +func (a SqlStatementOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SqlTask struct { // If alert, indicates that this job must refresh a SQL alert. - Alert []SqlTaskAlert `tfsdk:"alert" tf:"optional,object"` + Alert types.Object `tfsdk:"alert" tf:"optional,object"` // If dashboard, indicates that this job must refresh a SQL dashboard. - Dashboard []SqlTaskDashboard `tfsdk:"dashboard" tf:"optional,object"` + Dashboard types.Object `tfsdk:"dashboard" tf:"optional,object"` // If file, indicates that this job runs a SQL file in a remote Git // repository. - File []SqlTaskFile `tfsdk:"file" tf:"optional,object"` + File types.Object `tfsdk:"file" tf:"optional,object"` // Parameters to be used for each run of this job. The SQL alert task does // not support custom parameters. - Parameters map[string]types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.Map `tfsdk:"parameters" tf:"optional"` // If query, indicates that this job must execute a SQL query. - Query []SqlTaskQuery `tfsdk:"query" tf:"optional,object"` + Query types.Object `tfsdk:"query" tf:"optional,object"` // The canonical identifier of the SQL warehouse. Recommended to use with // serverless or pro SQL warehouses. Classic SQL warehouses are only // supported for SQL alert, dashboard and query tasks and are limited to @@ -2947,13 +3630,23 @@ func (newState *SqlTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTask) { func (newState *SqlTask) SyncEffectiveFieldsDuringRead(existingState SqlTask) { } +func (a SqlTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Alert": reflect.TypeOf(SqlTaskAlert{}), + "Dashboard": reflect.TypeOf(SqlTaskDashboard{}), + "File": reflect.TypeOf(SqlTaskFile{}), + "Parameters": reflect.TypeOf(""), + "Query": reflect.TypeOf(SqlTaskQuery{}), + } +} + type SqlTaskAlert struct { // The canonical identifier of the SQL alert. AlertId types.String `tfsdk:"alert_id" tf:""` // If true, the alert notifications are not sent to subscribers. PauseSubscriptions types.Bool `tfsdk:"pause_subscriptions" tf:"optional"` // If specified, alert notifications are sent to subscribers. - Subscriptions []SqlTaskSubscription `tfsdk:"subscriptions" tf:"optional"` + Subscriptions types.List `tfsdk:"subscriptions" tf:"optional"` } func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTaskAlert) { @@ -2962,6 +3655,12 @@ func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTa func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringRead(existingState SqlTaskAlert) { } +func (a SqlTaskAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Subscriptions": reflect.TypeOf(SqlTaskSubscription{}), + } +} + type SqlTaskDashboard struct { // Subject of the email sent to subscribers of this task. CustomSubject types.String `tfsdk:"custom_subject" tf:"optional"` @@ -2971,7 +3670,7 @@ type SqlTaskDashboard struct { // subscribers. PauseSubscriptions types.Bool `tfsdk:"pause_subscriptions" tf:"optional"` // If specified, dashboard snapshots are sent to subscriptions. - Subscriptions []SqlTaskSubscription `tfsdk:"subscriptions" tf:"optional"` + Subscriptions types.List `tfsdk:"subscriptions" tf:"optional"` } func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTaskDashboard) { @@ -2980,6 +3679,12 @@ func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringRead(existingState SqlTaskDashboard) { } +func (a SqlTaskDashboard) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Subscriptions": reflect.TypeOf(SqlTaskSubscription{}), + } +} + type SqlTaskFile struct { // Path of the SQL file. Must be relative if the source is a remote Git // repository and absolute for workspace paths. @@ -3001,6 +3706,10 @@ func (newState *SqlTaskFile) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTas func (newState *SqlTaskFile) SyncEffectiveFieldsDuringRead(existingState SqlTaskFile) { } +func (a SqlTaskFile) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SqlTaskQuery struct { // The canonical identifier of the SQL query. QueryId types.String `tfsdk:"query_id" tf:""` @@ -3012,6 +3721,10 @@ func (newState *SqlTaskQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTa func (newState *SqlTaskQuery) SyncEffectiveFieldsDuringRead(existingState SqlTaskQuery) { } +func (a SqlTaskQuery) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SqlTaskSubscription struct { // The canonical identifier of the destination to receive email // notification. This parameter is mutually exclusive with user_name. You @@ -3030,18 +3743,22 @@ func (newState *SqlTaskSubscription) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SqlTaskSubscription) SyncEffectiveFieldsDuringRead(existingState SqlTaskSubscription) { } +func (a SqlTaskSubscription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SubmitRun struct { // List of permissions to set on the job. - AccessControlList []JobAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The user specified id of the budget policy to use for this one-time run. // If not specified, the run will be not be attributed to any budget policy. BudgetPolicyId types.String `tfsdk:"budget_policy_id" tf:"optional"` // An optional set of email addresses notified when the run begins or // completes. - EmailNotifications []JobEmailNotifications `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` // A list of task execution environment specifications that can be // referenced by tasks of this run. - Environments []JobEnvironment `tfsdk:"environments" tf:"optional"` + Environments types.List `tfsdk:"environments" tf:"optional"` // An optional specification for a remote Git repository containing the // source code used by tasks. Version-controlled source code is supported by // notebook, dbt, Python script, and SQL File tasks. @@ -3052,9 +3769,9 @@ type SubmitRun struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource []GitSource `tfsdk:"git_source" tf:"optional,object"` + GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health []JobsHealthRules `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // An optional token that can be used to guarantee the idempotency of job // run requests. If a run with the provided token already exists, the // request does not create a new run but returns the ID of the existing run @@ -3074,22 +3791,22 @@ type SubmitRun struct { // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // run. - NotificationSettings []JobNotificationSettings `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` // The queue settings of the one-time run. - Queue []QueueSettings `tfsdk:"queue" tf:"optional,object"` + Queue types.Object `tfsdk:"queue" tf:"optional,object"` // Specifies the user or service principal that the job runs as. If not // specified, the job runs as the user who submits the request. - RunAs []JobRunAs `tfsdk:"run_as" tf:"optional,object"` + RunAs types.Object `tfsdk:"run_as" tf:"optional,object"` // An optional name for the run. The default value is `Untitled`. RunName types.String `tfsdk:"run_name" tf:"optional"` - Tasks []SubmitTask `tfsdk:"tasks" tf:"optional"` + Tasks types.List `tfsdk:"tasks" tf:"optional"` // An optional timeout applied to each run of this job. A value of `0` means // no timeout. TimeoutSeconds types.Int64 `tfsdk:"timeout_seconds" tf:"optional"` // A collection of system notification IDs to notify when the run begins or // completes. - WebhookNotifications []WebhookNotifications `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *SubmitRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitRun) { @@ -3098,6 +3815,21 @@ func (newState *SubmitRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitRu func (newState *SubmitRun) SyncEffectiveFieldsDuringRead(existingState SubmitRun) { } +func (a SubmitRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(JobAccessControlRequest{}), + "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), + "Environments": reflect.TypeOf(JobEnvironment{}), + "GitSource": reflect.TypeOf(GitSource{}), + "Health": reflect.TypeOf(JobsHealthRules{}), + "NotificationSettings": reflect.TypeOf(JobNotificationSettings{}), + "Queue": reflect.TypeOf(QueueSettings{}), + "RunAs": reflect.TypeOf(JobRunAs{}), + "Tasks": reflect.TypeOf(SubmitTask{}), + "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + } +} + // Run was created and started successfully. type SubmitRunResponse struct { // The canonical identifier for the newly submitted run. @@ -3110,26 +3842,30 @@ func (newState *SubmitRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SubmitRunResponse) SyncEffectiveFieldsDuringRead(existingState SubmitRunResponse) { } +func (a SubmitRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SubmitTask struct { // The task evaluates a condition that can be used to control the execution // of other tasks when the `condition_task` field is present. The condition // task does not require a cluster to execute and does not support retries // or notifications. - ConditionTask []ConditionTask `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` // The task runs one or more dbt commands when the `dbt_task` field is // present. The dbt task requires both Databricks SQL and the ability to use // a serverless or a pro SQL warehouse. - DbtTask []DbtTask `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` // An optional array of objects specifying the dependency graph of the task. // All tasks specified in this field must complete successfully before // executing this task. The key is `task_key`, and the value is the name // assigned to the dependent task. - DependsOn []TaskDependency `tfsdk:"depends_on" tf:"optional"` + DependsOn types.List `tfsdk:"depends_on" tf:"optional"` // An optional description for this task. Description types.String `tfsdk:"description" tf:"optional"` // An optional set of email addresses notified when the task run begins or // completes. The default behavior is to not send any emails. - EmailNotifications []JobEmailNotifications `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` // The key that references an environment spec in a job. This field is // required for Python script, Python wheel and dbt tasks when using // serverless compute. @@ -3141,39 +3877,39 @@ type SubmitTask struct { ExistingClusterId types.String `tfsdk:"existing_cluster_id" tf:"optional"` // The task executes a nested task for every input provided when the // `for_each_task` field is present. - ForEachTask []ForEachTask `tfsdk:"for_each_task" tf:"optional,object"` + ForEachTask types.Object `tfsdk:"for_each_task" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health []JobsHealthRules `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // An optional list of libraries to be installed on the cluster. The default // value is an empty list. - Libraries compute.Library `tfsdk:"library" tf:"optional"` + Libraries types.List `tfsdk:"library" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. - NotebookTask []NotebookTask `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // task run. - NotificationSettings []TaskNotificationSettings `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` // The task triggers a pipeline update when the `pipeline_task` field is // present. Only pipelines configured to use triggered more are supported. - PipelineTask []PipelineTask `tfsdk:"pipeline_task" tf:"optional,object"` + PipelineTask types.Object `tfsdk:"pipeline_task" tf:"optional,object"` // The task runs a Python wheel when the `python_wheel_task` field is // present. - PythonWheelTask []PythonWheelTask `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` // An optional value indicating the condition that determines whether the // task should be run once its dependencies have been completed. When // omitted, defaults to `ALL_SUCCESS`. See :method:jobs/create for a list of // possible values. RunIf types.String `tfsdk:"run_if" tf:"optional"` // The task triggers another job when the `run_job_task` field is present. - RunJobTask []RunJobTask `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` // The task runs a JAR when the `spark_jar_task` field is present. - SparkJarTask []SparkJarTask `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` // The task runs a Python file when the `spark_python_task` field is // present. - SparkPythonTask []SparkPythonTask `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` // (Legacy) The task runs the spark-submit script when the // `spark_submit_task` field is present. This task can run only on new // clusters and is not compatible with serverless compute. @@ -3192,10 +3928,10 @@ type SubmitTask struct { // // The `--jars`, `--py-files`, `--files` arguments support DBFS and S3 // paths. - SparkSubmitTask []SparkSubmitTask `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` // The task runs a SQL query or file, or it refreshes a SQL alert or a // legacy SQL dashboard when the `sql_task` field is present. - SqlTask []SqlTask `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` // A unique name for the task. This field is used to refer to this task from // other tasks. This field is required and must be unique within its parent // job. On Update or Reset, this field is used to reference the tasks to be @@ -3207,7 +3943,7 @@ type SubmitTask struct { // A collection of system notification IDs to notify when the run begins or // completes. The default behavior is to not send any system notifications. // Task webhooks respect the task notification settings. - WebhookNotifications []WebhookNotifications `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *SubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitTask) { @@ -3216,6 +3952,29 @@ func (newState *SubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitT func (newState *SubmitTask) SyncEffectiveFieldsDuringRead(existingState SubmitTask) { } +func (a SubmitTask) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ConditionTask": reflect.TypeOf(ConditionTask{}), + "DbtTask": reflect.TypeOf(DbtTask{}), + "DependsOn": reflect.TypeOf(TaskDependency{}), + "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), + "ForEachTask": reflect.TypeOf(ForEachTask{}), + "Health": reflect.TypeOf(JobsHealthRules{}), + "Libraries": reflect.TypeOf(compute.Library{}), + "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + "NotebookTask": reflect.TypeOf(NotebookTask{}), + "NotificationSettings": reflect.TypeOf(TaskNotificationSettings{}), + "PipelineTask": reflect.TypeOf(PipelineTask{}), + "PythonWheelTask": reflect.TypeOf(PythonWheelTask{}), + "RunJobTask": reflect.TypeOf(RunJobTask{}), + "SparkJarTask": reflect.TypeOf(SparkJarTask{}), + "SparkPythonTask": reflect.TypeOf(SparkPythonTask{}), + "SparkSubmitTask": reflect.TypeOf(SparkSubmitTask{}), + "SqlTask": reflect.TypeOf(SqlTask{}), + "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + } +} + type TableUpdateTriggerConfiguration struct { // The table(s) condition based on which to trigger a job run. Condition types.String `tfsdk:"condition" tf:"optional"` @@ -3225,7 +3984,7 @@ type TableUpdateTriggerConfiguration struct { MinTimeBetweenTriggersSeconds types.Int64 `tfsdk:"min_time_between_triggers_seconds" tf:"optional"` // A list of Delta tables to monitor for changes. The table name must be in // the format `catalog_name.schema_name.table_name`. - TableNames []types.String `tfsdk:"table_names" tf:"optional"` + TableNames types.List `tfsdk:"table_names" tf:"optional"` // If set, the trigger starts a run only after no table updates have // occurred for the specified time and can be used to wait for a series of // table updates before triggering a run. The minimum allowed value is 60 @@ -3239,21 +3998,27 @@ func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringCreate func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState TableUpdateTriggerConfiguration) { } +func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TableNames": reflect.TypeOf(""), + } +} + type Task struct { // The task evaluates a condition that can be used to control the execution // of other tasks when the `condition_task` field is present. The condition // task does not require a cluster to execute and does not support retries // or notifications. - ConditionTask []ConditionTask `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` // The task runs one or more dbt commands when the `dbt_task` field is // present. The dbt task requires both Databricks SQL and the ability to use // a serverless or a pro SQL warehouse. - DbtTask []DbtTask `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` // An optional array of objects specifying the dependency graph of the task. // All tasks specified in this field must complete before executing this // task. The task will run only if the `run_if` condition is true. The key // is `task_key`, and the value is the name assigned to the dependent task. - DependsOn []TaskDependency `tfsdk:"depends_on" tf:"optional"` + DependsOn types.List `tfsdk:"depends_on" tf:"optional"` // An optional description for this task. Description types.String `tfsdk:"description" tf:"optional"` // An option to disable auto optimization in serverless @@ -3261,7 +4026,7 @@ type Task struct { // An optional set of email addresses that is notified when runs of this // task begin or complete as well as when this task is deleted. The default // behavior is to not send any emails. - EmailNotifications []TaskEmailNotifications `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` // The key that references an environment spec in a job. This field is // required for Python script, Python wheel and dbt tasks when using // serverless compute. @@ -3273,15 +4038,15 @@ type Task struct { ExistingClusterId types.String `tfsdk:"existing_cluster_id" tf:"optional"` // The task executes a nested task for every input provided when the // `for_each_task` field is present. - ForEachTask []ForEachTask `tfsdk:"for_each_task" tf:"optional,object"` + ForEachTask types.Object `tfsdk:"for_each_task" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health []JobsHealthRules `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // If job_cluster_key, this task is executed reusing the cluster specified // in `job.settings.job_clusters`. JobClusterKey types.String `tfsdk:"job_cluster_key" tf:"optional"` // An optional list of libraries to be installed on the cluster. The default // value is an empty list. - Libraries compute.Library `tfsdk:"library" tf:"optional"` + Libraries types.List `tfsdk:"library" tf:"optional"` // An optional maximum number of times to retry an unsuccessful run. A run // is considered to be unsuccessful if it completes with the `FAILED` // result_state or `INTERNAL_ERROR` `life_cycle_state`. The value `-1` means @@ -3295,17 +4060,17 @@ type Task struct { // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. - NotebookTask []NotebookTask `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // task. - NotificationSettings []TaskNotificationSettings `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` // The task triggers a pipeline update when the `pipeline_task` field is // present. Only pipelines configured to use triggered more are supported. - PipelineTask []PipelineTask `tfsdk:"pipeline_task" tf:"optional,object"` + PipelineTask types.Object `tfsdk:"pipeline_task" tf:"optional,object"` // The task runs a Python wheel when the `python_wheel_task` field is // present. - PythonWheelTask []PythonWheelTask `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` // An optional policy to specify whether to retry a job when it times out. // The default behavior is to not retry on timeout. RetryOnTimeout types.Bool `tfsdk:"retry_on_timeout" tf:"optional"` @@ -3320,12 +4085,12 @@ type Task struct { // dependencies have failed RunIf types.String `tfsdk:"run_if" tf:"optional"` // The task triggers another job when the `run_job_task` field is present. - RunJobTask []RunJobTask `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` // The task runs a JAR when the `spark_jar_task` field is present. - SparkJarTask []SparkJarTask `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` // The task runs a Python file when the `spark_python_task` field is // present. - SparkPythonTask []SparkPythonTask `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` // (Legacy) The task runs the spark-submit script when the // `spark_submit_task` field is present. This task can run only on new // clusters and is not compatible with serverless compute. @@ -3344,10 +4109,10 @@ type Task struct { // // The `--jars`, `--py-files`, `--files` arguments support DBFS and S3 // paths. - SparkSubmitTask []SparkSubmitTask `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` // The task runs a SQL query or file, or it refreshes a SQL alert or a // legacy SQL dashboard when the `sql_task` field is present. - SqlTask []SqlTask `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` // A unique name for the task. This field is used to refer to this task from // other tasks. This field is required and must be unique within its parent // job. On Update or Reset, this field is used to reference the tasks to be @@ -3359,7 +4124,7 @@ type Task struct { // A collection of system notification IDs to notify when runs of this task // begin or complete. The default behavior is to not send any system // notifications. - WebhookNotifications []WebhookNotifications `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *Task) SyncEffectiveFieldsDuringCreateOrUpdate(plan Task) { @@ -3368,6 +4133,29 @@ func (newState *Task) SyncEffectiveFieldsDuringCreateOrUpdate(plan Task) { func (newState *Task) SyncEffectiveFieldsDuringRead(existingState Task) { } +func (a Task) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ConditionTask": reflect.TypeOf(ConditionTask{}), + "DbtTask": reflect.TypeOf(DbtTask{}), + "DependsOn": reflect.TypeOf(TaskDependency{}), + "EmailNotifications": reflect.TypeOf(TaskEmailNotifications{}), + "ForEachTask": reflect.TypeOf(ForEachTask{}), + "Health": reflect.TypeOf(JobsHealthRules{}), + "Libraries": reflect.TypeOf(compute.Library{}), + "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + "NotebookTask": reflect.TypeOf(NotebookTask{}), + "NotificationSettings": reflect.TypeOf(TaskNotificationSettings{}), + "PipelineTask": reflect.TypeOf(PipelineTask{}), + "PythonWheelTask": reflect.TypeOf(PythonWheelTask{}), + "RunJobTask": reflect.TypeOf(RunJobTask{}), + "SparkJarTask": reflect.TypeOf(SparkJarTask{}), + "SparkPythonTask": reflect.TypeOf(SparkPythonTask{}), + "SparkSubmitTask": reflect.TypeOf(SparkSubmitTask{}), + "SqlTask": reflect.TypeOf(SqlTask{}), + "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + } +} + type TaskDependency struct { // Can only be specified on condition task dependencies. The outcome of the // dependent task that must be met for this task to run. @@ -3382,6 +4170,10 @@ func (newState *TaskDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tas func (newState *TaskDependency) SyncEffectiveFieldsDuringRead(existingState TaskDependency) { } +func (a TaskDependency) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TaskEmailNotifications struct { // If true, do not send email to recipients specified in `on_failure` if the // run is skipped. This field is `deprecated`. Please use the @@ -3391,17 +4183,17 @@ type TaskEmailNotifications struct { // exceeds the threshold specified for the `RUN_DURATION_SECONDS` metric in // the `health` field. If no rule for the `RUN_DURATION_SECONDS` metric is // specified in the `health` field for the job, notifications are not sent. - OnDurationWarningThresholdExceeded []types.String `tfsdk:"on_duration_warning_threshold_exceeded" tf:"optional"` + OnDurationWarningThresholdExceeded types.List `tfsdk:"on_duration_warning_threshold_exceeded" tf:"optional"` // A list of email addresses to be notified when a run unsuccessfully // completes. A run is considered to have completed unsuccessfully if it // ends with an `INTERNAL_ERROR` `life_cycle_state` or a `FAILED`, or // `TIMED_OUT` result_state. If this is not specified on job creation, // reset, or update the list is empty, and notifications are not sent. - OnFailure []types.String `tfsdk:"on_failure" tf:"optional"` + OnFailure types.List `tfsdk:"on_failure" tf:"optional"` // A list of email addresses to be notified when a run begins. If not // specified on job creation, reset, or update, the list is empty, and // notifications are not sent. - OnStart []types.String `tfsdk:"on_start" tf:"optional"` + OnStart types.List `tfsdk:"on_start" tf:"optional"` // A list of email addresses to notify when any streaming backlog thresholds // are exceeded for any stream. Streaming backlog thresholds can be set in // the `health` field using the following metrics: @@ -3409,13 +4201,13 @@ type TaskEmailNotifications struct { // `STREAMING_BACKLOG_SECONDS`, or `STREAMING_BACKLOG_FILES`. Alerting is // based on the 10-minute average of these metrics. If the issue persists, // notifications are resent every 30 minutes. - OnStreamingBacklogExceeded []types.String `tfsdk:"on_streaming_backlog_exceeded" tf:"optional"` + OnStreamingBacklogExceeded types.List `tfsdk:"on_streaming_backlog_exceeded" tf:"optional"` // A list of email addresses to be notified when a run successfully // completes. A run is considered to have completed successfully if it ends // with a `TERMINATED` `life_cycle_state` and a `SUCCESS` result_state. If // not specified on job creation, reset, or update, the list is empty, and // notifications are not sent. - OnSuccess []types.String `tfsdk:"on_success" tf:"optional"` + OnSuccess types.List `tfsdk:"on_success" tf:"optional"` } func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan TaskEmailNotifications) { @@ -3424,6 +4216,16 @@ func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringRead(existingState TaskEmailNotifications) { } +func (a TaskEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OnDurationWarningThresholdExceeded": reflect.TypeOf(""), + "OnFailure": reflect.TypeOf(""), + "OnStart": reflect.TypeOf(""), + "OnStreamingBacklogExceeded": reflect.TypeOf(""), + "OnSuccess": reflect.TypeOf(""), + } +} + type TaskNotificationSettings struct { // If true, do not send notifications to recipients specified in `on_start` // for the retried runs and do not send notifications to recipients @@ -3443,6 +4245,10 @@ func (newState *TaskNotificationSettings) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *TaskNotificationSettings) SyncEffectiveFieldsDuringRead(existingState TaskNotificationSettings) { } +func (a TaskNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TerminationDetails struct { // The code indicates why the run was terminated. Additional codes might be // introduced in future releases. * `SUCCESS`: The run was completed @@ -3510,6 +4316,10 @@ func (newState *TerminationDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationDetails) SyncEffectiveFieldsDuringRead(existingState TerminationDetails) { } +func (a TerminationDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Additional details about what triggered the run type TriggerInfo struct { // The run id of the Run Job task run @@ -3522,17 +4332,21 @@ func (newState *TriggerInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Trigge func (newState *TriggerInfo) SyncEffectiveFieldsDuringRead(existingState TriggerInfo) { } +func (a TriggerInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TriggerSettings struct { // File arrival trigger settings. - FileArrival []FileArrivalTriggerConfiguration `tfsdk:"file_arrival" tf:"optional,object"` + FileArrival types.Object `tfsdk:"file_arrival" tf:"optional,object"` // Whether this trigger is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` // Periodic trigger settings. - Periodic []PeriodicTriggerConfiguration `tfsdk:"periodic" tf:"optional,object"` + Periodic types.Object `tfsdk:"periodic" tf:"optional,object"` // Old table trigger settings name. Deprecated in favor of `table_update`. - Table []TableUpdateTriggerConfiguration `tfsdk:"table" tf:"optional,object"` + Table types.Object `tfsdk:"table" tf:"optional,object"` - TableUpdate []TableUpdateTriggerConfiguration `tfsdk:"table_update" tf:"optional,object"` + TableUpdate types.Object `tfsdk:"table_update" tf:"optional,object"` } func (newState *TriggerSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan TriggerSettings) { @@ -3541,11 +4355,20 @@ func (newState *TriggerSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tr func (newState *TriggerSettings) SyncEffectiveFieldsDuringRead(existingState TriggerSettings) { } +func (a TriggerSettings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileArrival": reflect.TypeOf(FileArrivalTriggerConfiguration{}), + "Periodic": reflect.TypeOf(PeriodicTriggerConfiguration{}), + "Table": reflect.TypeOf(TableUpdateTriggerConfiguration{}), + "TableUpdate": reflect.TypeOf(TableUpdateTriggerConfiguration{}), + } +} + type UpdateJob struct { // Remove top-level fields in the job settings. Removing nested fields is // not supported, except for tasks and job clusters (`tasks/task_1`). This // field is optional. - FieldsToRemove []types.String `tfsdk:"fields_to_remove" tf:"optional"` + FieldsToRemove types.List `tfsdk:"fields_to_remove" tf:"optional"` // The canonical identifier of the job to update. This field is required. JobId types.Int64 `tfsdk:"job_id" tf:""` // The new settings for the job. @@ -3559,7 +4382,7 @@ type UpdateJob struct { // // Changes to the field `JobSettings.timeout_seconds` are applied to active // runs. Changes to other fields are applied to future runs only. - NewSettings []JobSettings `tfsdk:"new_settings" tf:"optional,object"` + NewSettings types.Object `tfsdk:"new_settings" tf:"optional,object"` } func (newState *UpdateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateJob) { @@ -3568,6 +4391,13 @@ func (newState *UpdateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateJo func (newState *UpdateJob) SyncEffectiveFieldsDuringRead(existingState UpdateJob) { } +func (a UpdateJob) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FieldsToRemove": reflect.TypeOf(""), + "NewSettings": reflect.TypeOf(JobSettings{}), + } +} + type UpdateResponse struct { } @@ -3577,6 +4407,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ViewItem struct { // Content of the view. Content types.String `tfsdk:"content" tf:"optional"` @@ -3594,6 +4428,10 @@ func (newState *ViewItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan ViewItem) func (newState *ViewItem) SyncEffectiveFieldsDuringRead(existingState ViewItem) { } +func (a ViewItem) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Webhook struct { Id types.String `tfsdk:"id" tf:""` } @@ -3604,18 +4442,22 @@ func (newState *Webhook) SyncEffectiveFieldsDuringCreateOrUpdate(plan Webhook) { func (newState *Webhook) SyncEffectiveFieldsDuringRead(existingState Webhook) { } +func (a Webhook) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WebhookNotifications struct { // An optional list of system notification IDs to call when the duration of // a run exceeds the threshold specified for the `RUN_DURATION_SECONDS` // metric in the `health` field. A maximum of 3 destinations can be // specified for the `on_duration_warning_threshold_exceeded` property. - OnDurationWarningThresholdExceeded []Webhook `tfsdk:"on_duration_warning_threshold_exceeded" tf:"optional"` + OnDurationWarningThresholdExceeded types.List `tfsdk:"on_duration_warning_threshold_exceeded" tf:"optional"` // An optional list of system notification IDs to call when the run fails. A // maximum of 3 destinations can be specified for the `on_failure` property. - OnFailure []Webhook `tfsdk:"on_failure" tf:"optional"` + OnFailure types.List `tfsdk:"on_failure" tf:"optional"` // An optional list of system notification IDs to call when the run starts. // A maximum of 3 destinations can be specified for the `on_start` property. - OnStart []Webhook `tfsdk:"on_start" tf:"optional"` + OnStart types.List `tfsdk:"on_start" tf:"optional"` // An optional list of system notification IDs to call when any streaming // backlog thresholds are exceeded for any stream. Streaming backlog // thresholds can be set in the `health` field using the following metrics: @@ -3624,11 +4466,11 @@ type WebhookNotifications struct { // based on the 10-minute average of these metrics. If the issue persists, // notifications are resent every 30 minutes. A maximum of 3 destinations // can be specified for the `on_streaming_backlog_exceeded` property. - OnStreamingBacklogExceeded []Webhook `tfsdk:"on_streaming_backlog_exceeded" tf:"optional"` + OnStreamingBacklogExceeded types.List `tfsdk:"on_streaming_backlog_exceeded" tf:"optional"` // An optional list of system notification IDs to call when the run // completes successfully. A maximum of 3 destinations can be specified for // the `on_success` property. - OnSuccess []Webhook `tfsdk:"on_success" tf:"optional"` + OnSuccess types.List `tfsdk:"on_success" tf:"optional"` } func (newState *WebhookNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan WebhookNotifications) { @@ -3636,3 +4478,13 @@ func (newState *WebhookNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WebhookNotifications) SyncEffectiveFieldsDuringRead(existingState WebhookNotifications) { } + +func (a WebhookNotifications) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OnDurationWarningThresholdExceeded": reflect.TypeOf(Webhook{}), + "OnFailure": reflect.TypeOf(Webhook{}), + "OnStart": reflect.TypeOf(Webhook{}), + "OnStreamingBacklogExceeded": reflect.TypeOf(Webhook{}), + "OnSuccess": reflect.TypeOf(Webhook{}), + } +} diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 125335b593..621f04aa09 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package marketplace_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -26,8 +28,12 @@ func (newState *AddExchangeForListingRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *AddExchangeForListingRequest) SyncEffectiveFieldsDuringRead(existingState AddExchangeForListingRequest) { } +func (a AddExchangeForListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AddExchangeForListingResponse struct { - ExchangeForListing []ExchangeListing `tfsdk:"exchange_for_listing" tf:"optional,object"` + ExchangeForListing types.Object `tfsdk:"exchange_for_listing" tf:"optional,object"` } func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddExchangeForListingResponse) { @@ -36,9 +42,15 @@ func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringCreateOr func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringRead(existingState AddExchangeForListingResponse) { } +func (a AddExchangeForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExchangeForListing": reflect.TypeOf(ExchangeListing{}), + } +} + // Get one batch of listings. One may specify up to 50 IDs per request. type BatchGetListingsRequest struct { - Ids []types.String `tfsdk:"-"` + Ids types.List `tfsdk:"-"` } func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan BatchGetListingsRequest) { @@ -47,8 +59,14 @@ func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringRead(existingState BatchGetListingsRequest) { } +func (a BatchGetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Ids": reflect.TypeOf(""), + } +} + type BatchGetListingsResponse struct { - Listings []Listing `tfsdk:"listings" tf:"optional"` + Listings types.List `tfsdk:"listings" tf:"optional"` } func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan BatchGetListingsResponse) { @@ -57,9 +75,15 @@ func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringRead(existingState BatchGetListingsResponse) { } +func (a BatchGetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listings": reflect.TypeOf(Listing{}), + } +} + // Get one batch of providers. One may specify up to 50 IDs per request. type BatchGetProvidersRequest struct { - Ids []types.String `tfsdk:"-"` + Ids types.List `tfsdk:"-"` } func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan BatchGetProvidersRequest) { @@ -68,8 +92,14 @@ func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringRead(existingState BatchGetProvidersRequest) { } +func (a BatchGetProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Ids": reflect.TypeOf(""), + } +} + type BatchGetProvidersResponse struct { - Providers []ProviderInfo `tfsdk:"providers" tf:"optional"` + Providers types.List `tfsdk:"providers" tf:"optional"` } func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan BatchGetProvidersResponse) { @@ -78,6 +108,12 @@ func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringRead(existingState BatchGetProvidersResponse) { } +func (a BatchGetProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Providers": reflect.TypeOf(ProviderInfo{}), + } +} + type ConsumerTerms struct { Version types.String `tfsdk:"version" tf:""` } @@ -88,6 +124,10 @@ func (newState *ConsumerTerms) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cons func (newState *ConsumerTerms) SyncEffectiveFieldsDuringRead(existingState ConsumerTerms) { } +func (a ConsumerTerms) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // contact info for the consumer requesting data or performing a listing // installation type ContactInfo struct { @@ -106,8 +146,12 @@ func (newState *ContactInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Contac func (newState *ContactInfo) SyncEffectiveFieldsDuringRead(existingState ContactInfo) { } +func (a ContactInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateExchangeFilterRequest struct { - Filter []ExchangeFilter `tfsdk:"filter" tf:"object"` + Filter types.Object `tfsdk:"filter" tf:"object"` } func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateExchangeFilterRequest) { @@ -116,6 +160,12 @@ func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState CreateExchangeFilterRequest) { } +func (a CreateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Filter": reflect.TypeOf(ExchangeFilter{}), + } +} + type CreateExchangeFilterResponse struct { FilterId types.String `tfsdk:"filter_id" tf:"optional"` } @@ -126,8 +176,12 @@ func (newState *CreateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *CreateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState CreateExchangeFilterResponse) { } +func (a CreateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateExchangeRequest struct { - Exchange []Exchange `tfsdk:"exchange" tf:"object"` + Exchange types.Object `tfsdk:"exchange" tf:"object"` } func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateExchangeRequest) { @@ -136,6 +190,12 @@ func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringRead(existingState CreateExchangeRequest) { } +func (a CreateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exchange": reflect.TypeOf(Exchange{}), + } +} + type CreateExchangeResponse struct { ExchangeId types.String `tfsdk:"exchange_id" tf:"optional"` } @@ -146,10 +206,14 @@ func (newState *CreateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateExchangeResponse) SyncEffectiveFieldsDuringRead(existingState CreateExchangeResponse) { } +func (a CreateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateFileRequest struct { DisplayName types.String `tfsdk:"display_name" tf:"optional"` - FileParent []FileParent `tfsdk:"file_parent" tf:"object"` + FileParent types.Object `tfsdk:"file_parent" tf:"object"` MarketplaceFileType types.String `tfsdk:"marketplace_file_type" tf:""` @@ -162,8 +226,14 @@ func (newState *CreateFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateFileRequest) SyncEffectiveFieldsDuringRead(existingState CreateFileRequest) { } +func (a CreateFileRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileParent": reflect.TypeOf(FileParent{}), + } +} + type CreateFileResponse struct { - FileInfo []FileInfo `tfsdk:"file_info" tf:"optional,object"` + FileInfo types.Object `tfsdk:"file_info" tf:"optional,object"` // Pre-signed POST URL to blob storage UploadUrl types.String `tfsdk:"upload_url" tf:"optional"` } @@ -174,8 +244,14 @@ func (newState *CreateFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateFileResponse) SyncEffectiveFieldsDuringRead(existingState CreateFileResponse) { } +func (a CreateFileResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileInfo": reflect.TypeOf(FileInfo{}), + } +} + type CreateInstallationRequest struct { - AcceptedConsumerTerms []ConsumerTerms `tfsdk:"accepted_consumer_terms" tf:"optional,object"` + AcceptedConsumerTerms types.Object `tfsdk:"accepted_consumer_terms" tf:"optional,object"` CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -183,7 +259,7 @@ type CreateInstallationRequest struct { RecipientType types.String `tfsdk:"recipient_type" tf:"optional"` // for git repo installations - RepoDetail []RepoInstallation `tfsdk:"repo_detail" tf:"optional,object"` + RepoDetail types.Object `tfsdk:"repo_detail" tf:"optional,object"` ShareName types.String `tfsdk:"share_name" tf:"optional"` } @@ -194,8 +270,15 @@ func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringRead(existingState CreateInstallationRequest) { } +func (a CreateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AcceptedConsumerTerms": reflect.TypeOf(ConsumerTerms{}), + "RepoDetail": reflect.TypeOf(RepoInstallation{}), + } +} + type CreateListingRequest struct { - Listing []Listing `tfsdk:"listing" tf:"object"` + Listing types.Object `tfsdk:"listing" tf:"object"` } func (newState *CreateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateListingRequest) { @@ -204,6 +287,12 @@ func (newState *CreateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreateListingRequest) SyncEffectiveFieldsDuringRead(existingState CreateListingRequest) { } +func (a CreateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listing": reflect.TypeOf(Listing{}), + } +} + type CreateListingResponse struct { ListingId types.String `tfsdk:"listing_id" tf:"optional"` } @@ -214,9 +303,13 @@ func (newState *CreateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateListingResponse) SyncEffectiveFieldsDuringRead(existingState CreateListingResponse) { } +func (a CreateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Data request messages also creates a lead (maybe) type CreatePersonalizationRequest struct { - AcceptedConsumerTerms []ConsumerTerms `tfsdk:"accepted_consumer_terms" tf:"object"` + AcceptedConsumerTerms types.Object `tfsdk:"accepted_consumer_terms" tf:"object"` Comment types.String `tfsdk:"comment" tf:"optional"` @@ -241,6 +334,12 @@ func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringRead(existingState CreatePersonalizationRequest) { } +func (a CreatePersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AcceptedConsumerTerms": reflect.TypeOf(ConsumerTerms{}), + } +} + type CreatePersonalizationRequestResponse struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -251,8 +350,12 @@ func (newState *CreatePersonalizationRequestResponse) SyncEffectiveFieldsDuringC func (newState *CreatePersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState CreatePersonalizationRequestResponse) { } +func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateProviderRequest struct { - Provider []ProviderInfo `tfsdk:"provider" tf:"object"` + Provider types.Object `tfsdk:"provider" tf:"object"` } func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateProviderRequest) { @@ -261,6 +364,12 @@ func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringRead(existingState CreateProviderRequest) { } +func (a CreateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Provider": reflect.TypeOf(ProviderInfo{}), + } +} + type CreateProviderResponse struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -271,6 +380,10 @@ func (newState *CreateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateProviderResponse) SyncEffectiveFieldsDuringRead(existingState CreateProviderResponse) { } +func (a CreateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DataRefreshInfo struct { Interval types.Int64 `tfsdk:"interval" tf:""` @@ -283,6 +396,10 @@ func (newState *DataRefreshInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Da func (newState *DataRefreshInfo) SyncEffectiveFieldsDuringRead(existingState DataRefreshInfo) { } +func (a DataRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete an exchange filter type DeleteExchangeFilterRequest struct { Id types.String `tfsdk:"-"` @@ -294,6 +411,10 @@ func (newState *DeleteExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *DeleteExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeFilterRequest) { } +func (a DeleteExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteExchangeFilterResponse struct { } @@ -303,6 +424,10 @@ func (newState *DeleteExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeFilterResponse) { } +func (a DeleteExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete an exchange type DeleteExchangeRequest struct { Id types.String `tfsdk:"-"` @@ -314,6 +439,10 @@ func (newState *DeleteExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteExchangeRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeRequest) { } +func (a DeleteExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteExchangeResponse struct { } @@ -323,6 +452,10 @@ func (newState *DeleteExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteExchangeResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeResponse) { } +func (a DeleteExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a file type DeleteFileRequest struct { FileId types.String `tfsdk:"-"` @@ -334,6 +467,10 @@ func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFileRequest) { } +func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteFileResponse struct { } @@ -343,6 +480,10 @@ func (newState *DeleteFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileResponse) SyncEffectiveFieldsDuringRead(existingState DeleteFileResponse) { } +func (a DeleteFileResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Uninstall from a listing type DeleteInstallationRequest struct { InstallationId types.String `tfsdk:"-"` @@ -356,6 +497,10 @@ func (newState *DeleteInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteInstallationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteInstallationRequest) { } +func (a DeleteInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteInstallationResponse struct { } @@ -365,6 +510,10 @@ func (newState *DeleteInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteInstallationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteInstallationResponse) { } +func (a DeleteInstallationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a listing type DeleteListingRequest struct { Id types.String `tfsdk:"-"` @@ -376,6 +525,10 @@ func (newState *DeleteListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteListingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteListingRequest) { } +func (a DeleteListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteListingResponse struct { } @@ -385,6 +538,10 @@ func (newState *DeleteListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteListingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteListingResponse) { } +func (a DeleteListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete provider type DeleteProviderRequest struct { Id types.String `tfsdk:"-"` @@ -396,6 +553,10 @@ func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringRead(existingState DeleteProviderRequest) { } +func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteProviderResponse struct { } @@ -405,6 +566,10 @@ func (newState *DeleteProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteProviderResponse) SyncEffectiveFieldsDuringRead(existingState DeleteProviderResponse) { } +func (a DeleteProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Exchange struct { Comment types.String `tfsdk:"comment" tf:"optional"` @@ -412,11 +577,11 @@ type Exchange struct { CreatedBy types.String `tfsdk:"created_by" tf:"optional"` - Filters []ExchangeFilter `tfsdk:"filters" tf:"optional"` + Filters types.List `tfsdk:"filters" tf:"optional"` Id types.String `tfsdk:"id" tf:"optional"` - LinkedListings []ExchangeListing `tfsdk:"linked_listings" tf:"optional"` + LinkedListings types.List `tfsdk:"linked_listings" tf:"optional"` Name types.String `tfsdk:"name" tf:""` @@ -431,6 +596,13 @@ func (newState *Exchange) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exchange) func (newState *Exchange) SyncEffectiveFieldsDuringRead(existingState Exchange) { } +func (a Exchange) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Filters": reflect.TypeOf(ExchangeFilter{}), + "LinkedListings": reflect.TypeOf(ExchangeListing{}), + } +} + type ExchangeFilter struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -457,6 +629,10 @@ func (newState *ExchangeFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exc func (newState *ExchangeFilter) SyncEffectiveFieldsDuringRead(existingState ExchangeFilter) { } +func (a ExchangeFilter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExchangeListing struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -479,6 +655,10 @@ func (newState *ExchangeListing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ex func (newState *ExchangeListing) SyncEffectiveFieldsDuringRead(existingState ExchangeListing) { } +func (a ExchangeListing) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FileInfo struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` // Name displayed to users for applicable files, e.g. embedded notebooks @@ -486,7 +666,7 @@ type FileInfo struct { DownloadLink types.String `tfsdk:"download_link" tf:"optional"` - FileParent []FileParent `tfsdk:"file_parent" tf:"optional,object"` + FileParent types.Object `tfsdk:"file_parent" tf:"optional,object"` Id types.String `tfsdk:"id" tf:"optional"` @@ -508,6 +688,12 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } +func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileParent": reflect.TypeOf(FileParent{}), + } +} + type FileParent struct { FileParentType types.String `tfsdk:"file_parent_type" tf:"optional"` // TODO make the following fields required @@ -520,6 +706,10 @@ func (newState *FileParent) SyncEffectiveFieldsDuringCreateOrUpdate(plan FilePar func (newState *FileParent) SyncEffectiveFieldsDuringRead(existingState FileParent) { } +func (a FileParent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an exchange type GetExchangeRequest struct { Id types.String `tfsdk:"-"` @@ -531,8 +721,12 @@ func (newState *GetExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetExchangeRequest) SyncEffectiveFieldsDuringRead(existingState GetExchangeRequest) { } +func (a GetExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetExchangeResponse struct { - Exchange []Exchange `tfsdk:"exchange" tf:"optional,object"` + Exchange types.Object `tfsdk:"exchange" tf:"optional,object"` } func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetExchangeResponse) { @@ -541,6 +735,12 @@ func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringRead(existingState GetExchangeResponse) { } +func (a GetExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exchange": reflect.TypeOf(Exchange{}), + } +} + // Get a file type GetFileRequest struct { FileId types.String `tfsdk:"-"` @@ -552,8 +752,12 @@ func (newState *GetFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetFileRequest) SyncEffectiveFieldsDuringRead(existingState GetFileRequest) { } +func (a GetFileRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetFileResponse struct { - FileInfo []FileInfo `tfsdk:"file_info" tf:"optional,object"` + FileInfo types.Object `tfsdk:"file_info" tf:"optional,object"` } func (newState *GetFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetFileResponse) { @@ -562,6 +766,12 @@ func (newState *GetFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetFileResponse) SyncEffectiveFieldsDuringRead(existingState GetFileResponse) { } +func (a GetFileResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileInfo": reflect.TypeOf(FileInfo{}), + } +} + type GetLatestVersionProviderAnalyticsDashboardResponse struct { // version here is latest logical version of the dashboard template Version types.Int64 `tfsdk:"version" tf:"optional"` @@ -573,6 +783,10 @@ func (newState *GetLatestVersionProviderAnalyticsDashboardResponse) SyncEffectiv func (newState *GetLatestVersionProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionProviderAnalyticsDashboardResponse) { } +func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get listing content metadata type GetListingContentMetadataRequest struct { ListingId types.String `tfsdk:"-"` @@ -588,10 +802,14 @@ func (newState *GetListingContentMetadataRequest) SyncEffectiveFieldsDuringCreat func (newState *GetListingContentMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetListingContentMetadataRequest) { } +func (a GetListingContentMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetListingContentMetadataResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - SharedDataObjects []SharedDataObject `tfsdk:"shared_data_objects" tf:"optional"` + SharedDataObjects types.List `tfsdk:"shared_data_objects" tf:"optional"` } func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetListingContentMetadataResponse) { @@ -600,6 +818,12 @@ func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringCrea func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetListingContentMetadataResponse) { } +func (a GetListingContentMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SharedDataObjects": reflect.TypeOf(SharedDataObject{}), + } +} + // Get listing type GetListingRequest struct { Id types.String `tfsdk:"-"` @@ -611,8 +835,12 @@ func (newState *GetListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingRequest) SyncEffectiveFieldsDuringRead(existingState GetListingRequest) { } +func (a GetListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetListingResponse struct { - Listing []Listing `tfsdk:"listing" tf:"optional,object"` + Listing types.Object `tfsdk:"listing" tf:"optional,object"` } func (newState *GetListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetListingResponse) { @@ -621,6 +849,12 @@ func (newState *GetListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingResponse) SyncEffectiveFieldsDuringRead(existingState GetListingResponse) { } +func (a GetListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listing": reflect.TypeOf(Listing{}), + } +} + // List listings type GetListingsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -634,8 +868,12 @@ func (newState *GetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingsRequest) SyncEffectiveFieldsDuringRead(existingState GetListingsRequest) { } +func (a GetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetListingsResponse struct { - Listings []Listing `tfsdk:"listings" tf:"optional"` + Listings types.List `tfsdk:"listings" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -646,6 +884,12 @@ func (newState *GetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetListingsResponse) SyncEffectiveFieldsDuringRead(existingState GetListingsResponse) { } +func (a GetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listings": reflect.TypeOf(Listing{}), + } +} + // Get the personalization request for a listing type GetPersonalizationRequestRequest struct { ListingId types.String `tfsdk:"-"` @@ -657,8 +901,12 @@ func (newState *GetPersonalizationRequestRequest) SyncEffectiveFieldsDuringCreat func (newState *GetPersonalizationRequestRequest) SyncEffectiveFieldsDuringRead(existingState GetPersonalizationRequestRequest) { } +func (a GetPersonalizationRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPersonalizationRequestResponse struct { - PersonalizationRequests []PersonalizationRequest `tfsdk:"personalization_requests" tf:"optional"` + PersonalizationRequests types.List `tfsdk:"personalization_requests" tf:"optional"` } func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPersonalizationRequestResponse) { @@ -667,6 +915,12 @@ func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringCrea func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState GetPersonalizationRequestResponse) { } +func (a GetPersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PersonalizationRequests": reflect.TypeOf(PersonalizationRequest{}), + } +} + // Get a provider type GetProviderRequest struct { Id types.String `tfsdk:"-"` @@ -678,8 +932,12 @@ func (newState *GetProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetProviderRequest) SyncEffectiveFieldsDuringRead(existingState GetProviderRequest) { } +func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetProviderResponse struct { - Provider []ProviderInfo `tfsdk:"provider" tf:"optional,object"` + Provider types.Object `tfsdk:"provider" tf:"optional,object"` } func (newState *GetProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetProviderResponse) { @@ -688,8 +946,14 @@ func (newState *GetProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetProviderResponse) SyncEffectiveFieldsDuringRead(existingState GetProviderResponse) { } +func (a GetProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Provider": reflect.TypeOf(ProviderInfo{}), + } +} + type Installation struct { - Installation []InstallationDetail `tfsdk:"installation" tf:"optional,object"` + Installation types.Object `tfsdk:"installation" tf:"optional,object"` } func (newState *Installation) SyncEffectiveFieldsDuringCreateOrUpdate(plan Installation) { @@ -698,6 +962,12 @@ func (newState *Installation) SyncEffectiveFieldsDuringCreateOrUpdate(plan Insta func (newState *Installation) SyncEffectiveFieldsDuringRead(existingState Installation) { } +func (a Installation) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Installation": reflect.TypeOf(InstallationDetail{}), + } +} + type InstallationDetail struct { CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -721,9 +991,9 @@ type InstallationDetail struct { Status types.String `tfsdk:"status" tf:"optional"` - TokenDetail []TokenDetail `tfsdk:"token_detail" tf:"optional,object"` + TokenDetail types.Object `tfsdk:"token_detail" tf:"optional,object"` - Tokens []TokenInfo `tfsdk:"tokens" tf:"optional"` + Tokens types.List `tfsdk:"tokens" tf:"optional"` } func (newState *InstallationDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan InstallationDetail) { @@ -732,6 +1002,13 @@ func (newState *InstallationDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstallationDetail) SyncEffectiveFieldsDuringRead(existingState InstallationDetail) { } +func (a InstallationDetail) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenDetail": reflect.TypeOf(TokenDetail{}), + "Tokens": reflect.TypeOf(TokenInfo{}), + } +} + // List all installations type ListAllInstallationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -745,8 +1022,12 @@ func (newState *ListAllInstallationsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListAllInstallationsRequest) SyncEffectiveFieldsDuringRead(existingState ListAllInstallationsRequest) { } +func (a ListAllInstallationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAllInstallationsResponse struct { - Installations []InstallationDetail `tfsdk:"installations" tf:"optional"` + Installations types.List `tfsdk:"installations" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -757,6 +1038,12 @@ func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringRead(existingState ListAllInstallationsResponse) { } +func (a ListAllInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Installations": reflect.TypeOf(InstallationDetail{}), + } +} + // List all personalization requests type ListAllPersonalizationRequestsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -770,10 +1057,14 @@ func (newState *ListAllPersonalizationRequestsRequest) SyncEffectiveFieldsDuring func (newState *ListAllPersonalizationRequestsRequest) SyncEffectiveFieldsDuringRead(existingState ListAllPersonalizationRequestsRequest) { } +func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAllPersonalizationRequestsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - PersonalizationRequests []PersonalizationRequest `tfsdk:"personalization_requests" tf:"optional"` + PersonalizationRequests types.List `tfsdk:"personalization_requests" tf:"optional"` } func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAllPersonalizationRequestsResponse) { @@ -782,6 +1073,12 @@ func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDurin func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDuringRead(existingState ListAllPersonalizationRequestsResponse) { } +func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PersonalizationRequests": reflect.TypeOf(PersonalizationRequest{}), + } +} + // List exchange filters type ListExchangeFiltersRequest struct { ExchangeId types.String `tfsdk:"-"` @@ -797,8 +1094,12 @@ func (newState *ListExchangeFiltersRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListExchangeFiltersRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangeFiltersRequest) { } +func (a ListExchangeFiltersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListExchangeFiltersResponse struct { - Filters []ExchangeFilter `tfsdk:"filters" tf:"optional"` + Filters types.List `tfsdk:"filters" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -809,6 +1110,12 @@ func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangeFiltersResponse) { } +func (a ListExchangeFiltersResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Filters": reflect.TypeOf(ExchangeFilter{}), + } +} + // List exchanges for listing type ListExchangesForListingRequest struct { ListingId types.String `tfsdk:"-"` @@ -824,8 +1131,12 @@ func (newState *ListExchangesForListingRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListExchangesForListingRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangesForListingRequest) { } +func (a ListExchangesForListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListExchangesForListingResponse struct { - ExchangeListing []ExchangeListing `tfsdk:"exchange_listing" tf:"optional"` + ExchangeListing types.List `tfsdk:"exchange_listing" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -836,6 +1147,12 @@ func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringCreate func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangesForListingResponse) { } +func (a ListExchangesForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExchangeListing": reflect.TypeOf(ExchangeListing{}), + } +} + // List exchanges type ListExchangesRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -849,8 +1166,12 @@ func (newState *ListExchangesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListExchangesRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangesRequest) { } +func (a ListExchangesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListExchangesResponse struct { - Exchanges []Exchange `tfsdk:"exchanges" tf:"optional"` + Exchanges types.List `tfsdk:"exchanges" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -861,9 +1182,15 @@ func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangesResponse) { } +func (a ListExchangesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exchanges": reflect.TypeOf(Exchange{}), + } +} + // List files type ListFilesRequest struct { - FileParent []FileParent `tfsdk:"-"` + FileParent types.Object `tfsdk:"-"` PageSize types.Int64 `tfsdk:"-"` @@ -876,8 +1203,14 @@ func (newState *ListFilesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListFilesRequest) SyncEffectiveFieldsDuringRead(existingState ListFilesRequest) { } +func (a ListFilesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileParent": reflect.TypeOf(FileParent{}), + } +} + type ListFilesResponse struct { - FileInfos []FileInfo `tfsdk:"file_infos" tf:"optional"` + FileInfos types.List `tfsdk:"file_infos" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -888,6 +1221,12 @@ func (newState *ListFilesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListFilesResponse) SyncEffectiveFieldsDuringRead(existingState ListFilesResponse) { } +func (a ListFilesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FileInfos": reflect.TypeOf(FileInfo{}), + } +} + // List all listing fulfillments type ListFulfillmentsRequest struct { ListingId types.String `tfsdk:"-"` @@ -903,8 +1242,12 @@ func (newState *ListFulfillmentsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListFulfillmentsRequest) SyncEffectiveFieldsDuringRead(existingState ListFulfillmentsRequest) { } +func (a ListFulfillmentsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListFulfillmentsResponse struct { - Fulfillments []ListingFulfillment `tfsdk:"fulfillments" tf:"optional"` + Fulfillments types.List `tfsdk:"fulfillments" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -915,6 +1258,12 @@ func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringRead(existingState ListFulfillmentsResponse) { } +func (a ListFulfillmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Fulfillments": reflect.TypeOf(ListingFulfillment{}), + } +} + // List installations for a listing type ListInstallationsRequest struct { ListingId types.String `tfsdk:"-"` @@ -930,8 +1279,12 @@ func (newState *ListInstallationsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListInstallationsRequest) SyncEffectiveFieldsDuringRead(existingState ListInstallationsRequest) { } +func (a ListInstallationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListInstallationsResponse struct { - Installations []InstallationDetail `tfsdk:"installations" tf:"optional"` + Installations types.List `tfsdk:"installations" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -942,6 +1295,12 @@ func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringRead(existingState ListInstallationsResponse) { } +func (a ListInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Installations": reflect.TypeOf(InstallationDetail{}), + } +} + // List listings for exchange type ListListingsForExchangeRequest struct { ExchangeId types.String `tfsdk:"-"` @@ -957,8 +1316,12 @@ func (newState *ListListingsForExchangeRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListListingsForExchangeRequest) SyncEffectiveFieldsDuringRead(existingState ListListingsForExchangeRequest) { } +func (a ListListingsForExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListListingsForExchangeResponse struct { - ExchangeListings []ExchangeListing `tfsdk:"exchange_listings" tf:"optional"` + ExchangeListings types.List `tfsdk:"exchange_listings" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -969,12 +1332,18 @@ func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringCreate func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringRead(existingState ListListingsForExchangeResponse) { } +func (a ListListingsForExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExchangeListings": reflect.TypeOf(ExchangeListing{}), + } +} + // List listings type ListListingsRequest struct { // Matches any of the following asset types - Assets []types.String `tfsdk:"-"` + Assets types.List `tfsdk:"-"` // Matches any of the following categories - Categories []types.String `tfsdk:"-"` + Categories types.List `tfsdk:"-"` // Filters each listing based on if it is free. IsFree types.Bool `tfsdk:"-"` // Filters each listing based on if it is a private exchange. @@ -986,9 +1355,9 @@ type ListListingsRequest struct { PageToken types.String `tfsdk:"-"` // Matches any of the following provider ids - ProviderIds []types.String `tfsdk:"-"` + ProviderIds types.List `tfsdk:"-"` // Matches any of the following tags - Tags []ListingTag `tfsdk:"-"` + Tags types.List `tfsdk:"-"` } func (newState *ListListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListListingsRequest) { @@ -997,8 +1366,17 @@ func (newState *ListListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListListingsRequest) SyncEffectiveFieldsDuringRead(existingState ListListingsRequest) { } +func (a ListListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Assets": reflect.TypeOf(""), + "Categories": reflect.TypeOf(""), + "ProviderIds": reflect.TypeOf(""), + "Tags": reflect.TypeOf(ListingTag{}), + } +} + type ListListingsResponse struct { - Listings []Listing `tfsdk:"listings" tf:"optional"` + Listings types.List `tfsdk:"listings" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -1009,6 +1387,12 @@ func (newState *ListListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListListingsResponse) SyncEffectiveFieldsDuringRead(existingState ListListingsResponse) { } +func (a ListListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listings": reflect.TypeOf(Listing{}), + } +} + type ListProviderAnalyticsDashboardResponse struct { // dashboard_id will be used to open Lakeview dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:""` @@ -1024,6 +1408,10 @@ func (newState *ListProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDurin func (newState *ListProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState ListProviderAnalyticsDashboardResponse) { } +func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List providers type ListProvidersRequest struct { IsFeatured types.Bool `tfsdk:"-"` @@ -1039,10 +1427,14 @@ func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringRead(existingState ListProvidersRequest) { } +func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListProvidersResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Providers []ProviderInfo `tfsdk:"providers" tf:"optional"` + Providers types.List `tfsdk:"providers" tf:"optional"` } func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListProvidersResponse) { @@ -1051,12 +1443,18 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingState ListProvidersResponse) { } +func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Providers": reflect.TypeOf(ProviderInfo{}), + } +} + type Listing struct { - Detail []ListingDetail `tfsdk:"detail" tf:"optional,object"` + Detail types.Object `tfsdk:"detail" tf:"optional,object"` Id types.String `tfsdk:"id" tf:"optional"` // Next Number: 26 - Summary []ListingSummary `tfsdk:"summary" tf:"object"` + Summary types.Object `tfsdk:"summary" tf:"object"` } func (newState *Listing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing) { @@ -1065,16 +1463,23 @@ func (newState *Listing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing) { func (newState *Listing) SyncEffectiveFieldsDuringRead(existingState Listing) { } +func (a Listing) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Detail": reflect.TypeOf(ListingDetail{}), + "Summary": reflect.TypeOf(ListingSummary{}), + } +} + type ListingDetail struct { // Type of assets included in the listing. eg. GIT_REPO, DATA_TABLE, MODEL, // NOTEBOOK - Assets []types.String `tfsdk:"assets" tf:"optional"` + Assets types.List `tfsdk:"assets" tf:"optional"` // The ending date timestamp for when the data spans CollectionDateEnd types.Int64 `tfsdk:"collection_date_end" tf:"optional"` // The starting date timestamp for when the data spans CollectionDateStart types.Int64 `tfsdk:"collection_date_start" tf:"optional"` // Smallest unit of time in the dataset - CollectionGranularity []DataRefreshInfo `tfsdk:"collection_granularity" tf:"optional,object"` + CollectionGranularity types.Object `tfsdk:"collection_granularity" tf:"optional,object"` // Whether the dataset is free or paid Cost types.String `tfsdk:"cost" tf:"optional"` // Where/how the data is sourced @@ -1084,9 +1489,9 @@ type ListingDetail struct { DocumentationLink types.String `tfsdk:"documentation_link" tf:"optional"` - EmbeddedNotebookFileInfos []FileInfo `tfsdk:"embedded_notebook_file_infos" tf:"optional"` + EmbeddedNotebookFileInfos types.List `tfsdk:"embedded_notebook_file_infos" tf:"optional"` - FileIds []types.String `tfsdk:"file_ids" tf:"optional"` + FileIds types.List `tfsdk:"file_ids" tf:"optional"` // Which geo region the listing data is collected from GeographicalCoverage types.String `tfsdk:"geographical_coverage" tf:"optional"` // ID 20, 21 removed don't use License of the data asset - Required for @@ -1109,11 +1514,11 @@ type ListingDetail struct { // the field is optional and won't need to have NOT NULL integrity check 2. // The value is fairly fixed, static and low cardinality (eg. enums). 3. The // value won't be used in filters or joins with other tables. - Tags []ListingTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` TermsOfService types.String `tfsdk:"terms_of_service" tf:"optional"` // How often data is updated - UpdateFrequency []DataRefreshInfo `tfsdk:"update_frequency" tf:"optional,object"` + UpdateFrequency types.Object `tfsdk:"update_frequency" tf:"optional,object"` } func (newState *ListingDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListingDetail) { @@ -1122,6 +1527,17 @@ func (newState *ListingDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan List func (newState *ListingDetail) SyncEffectiveFieldsDuringRead(existingState ListingDetail) { } +func (a ListingDetail) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Assets": reflect.TypeOf(""), + "CollectionGranularity": reflect.TypeOf(DataRefreshInfo{}), + "EmbeddedNotebookFileInfos": reflect.TypeOf(FileInfo{}), + "FileIds": reflect.TypeOf(""), + "Tags": reflect.TypeOf(ListingTag{}), + "UpdateFrequency": reflect.TypeOf(DataRefreshInfo{}), + } +} + type ListingFulfillment struct { FulfillmentType types.String `tfsdk:"fulfillment_type" tf:"optional"` @@ -1129,9 +1545,9 @@ type ListingFulfillment struct { RecipientType types.String `tfsdk:"recipient_type" tf:"optional"` - RepoInfo []RepoInfo `tfsdk:"repo_info" tf:"optional,object"` + RepoInfo types.Object `tfsdk:"repo_info" tf:"optional,object"` - ShareInfo []ShareInfo `tfsdk:"share_info" tf:"optional,object"` + ShareInfo types.Object `tfsdk:"share_info" tf:"optional,object"` } func (newState *ListingFulfillment) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListingFulfillment) { @@ -1140,6 +1556,13 @@ func (newState *ListingFulfillment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListingFulfillment) SyncEffectiveFieldsDuringRead(existingState ListingFulfillment) { } +func (a ListingFulfillment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RepoInfo": reflect.TypeOf(RepoInfo{}), + "ShareInfo": reflect.TypeOf(ShareInfo{}), + } +} + type ListingSetting struct { Visibility types.String `tfsdk:"visibility" tf:"optional"` } @@ -1150,9 +1573,13 @@ func (newState *ListingSetting) SyncEffectiveFieldsDuringCreateOrUpdate(plan Lis func (newState *ListingSetting) SyncEffectiveFieldsDuringRead(existingState ListingSetting) { } +func (a ListingSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Next Number: 26 type ListingSummary struct { - Categories []types.String `tfsdk:"categories" tf:"optional"` + Categories types.List `tfsdk:"categories" tf:"optional"` CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -1160,10 +1587,10 @@ type ListingSummary struct { CreatedById types.Int64 `tfsdk:"created_by_id" tf:"optional"` - ExchangeIds []types.String `tfsdk:"exchange_ids" tf:"optional"` + ExchangeIds types.List `tfsdk:"exchange_ids" tf:"optional"` // if a git repo is being created, a listing will be initialized with this // field as opposed to a share - GitRepo []RepoInfo `tfsdk:"git_repo" tf:"optional,object"` + GitRepo types.Object `tfsdk:"git_repo" tf:"optional,object"` ListingType types.String `tfsdk:"listingType" tf:""` @@ -1171,15 +1598,15 @@ type ListingSummary struct { ProviderId types.String `tfsdk:"provider_id" tf:"optional"` - ProviderRegion []RegionInfo `tfsdk:"provider_region" tf:"optional,object"` + ProviderRegion types.Object `tfsdk:"provider_region" tf:"optional,object"` PublishedAt types.Int64 `tfsdk:"published_at" tf:"optional"` PublishedBy types.String `tfsdk:"published_by" tf:"optional"` - Setting []ListingSetting `tfsdk:"setting" tf:"optional,object"` + Setting types.Object `tfsdk:"setting" tf:"optional,object"` - Share []ShareInfo `tfsdk:"share" tf:"optional,object"` + Share types.Object `tfsdk:"share" tf:"optional,object"` // Enums Status types.String `tfsdk:"status" tf:"optional"` @@ -1198,12 +1625,23 @@ func (newState *ListingSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Lis func (newState *ListingSummary) SyncEffectiveFieldsDuringRead(existingState ListingSummary) { } +func (a ListingSummary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Categories": reflect.TypeOf(""), + "ExchangeIds": reflect.TypeOf(""), + "GitRepo": reflect.TypeOf(RepoInfo{}), + "ProviderRegion": reflect.TypeOf(RegionInfo{}), + "Setting": reflect.TypeOf(ListingSetting{}), + "Share": reflect.TypeOf(ShareInfo{}), + } +} + type ListingTag struct { // Tag name (enum) TagName types.String `tfsdk:"tag_name" tf:"optional"` // String representation of the tag value. Values should be string literals // (no complex types) - TagValues []types.String `tfsdk:"tag_values" tf:"optional"` + TagValues types.List `tfsdk:"tag_values" tf:"optional"` } func (newState *ListingTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListingTag) { @@ -1212,13 +1650,19 @@ func (newState *ListingTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing func (newState *ListingTag) SyncEffectiveFieldsDuringRead(existingState ListingTag) { } +func (a ListingTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TagValues": reflect.TypeOf(""), + } +} + type PersonalizationRequest struct { Comment types.String `tfsdk:"comment" tf:"optional"` - ConsumerRegion []RegionInfo `tfsdk:"consumer_region" tf:"object"` + ConsumerRegion types.Object `tfsdk:"consumer_region" tf:"object"` // contact info for the consumer requesting data or performing a listing // installation - ContactInfo []ContactInfo `tfsdk:"contact_info" tf:"optional,object"` + ContactInfo types.Object `tfsdk:"contact_info" tf:"optional,object"` CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -1238,7 +1682,7 @@ type PersonalizationRequest struct { RecipientType types.String `tfsdk:"recipient_type" tf:"optional"` - Share []ShareInfo `tfsdk:"share" tf:"optional,object"` + Share types.Object `tfsdk:"share" tf:"optional,object"` Status types.String `tfsdk:"status" tf:"optional"` @@ -1253,6 +1697,14 @@ func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringRead(existingState PersonalizationRequest) { } +func (a PersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ConsumerRegion": reflect.TypeOf(RegionInfo{}), + "ContactInfo": reflect.TypeOf(ContactInfo{}), + "Share": reflect.TypeOf(ShareInfo{}), + } +} + type ProviderAnalyticsDashboard struct { Id types.String `tfsdk:"id" tf:""` } @@ -1263,6 +1715,10 @@ func (newState *ProviderAnalyticsDashboard) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ProviderAnalyticsDashboard) SyncEffectiveFieldsDuringRead(existingState ProviderAnalyticsDashboard) { } +func (a ProviderAnalyticsDashboard) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ProviderInfo struct { BusinessContactEmail types.String `tfsdk:"business_contact_email" tf:""` @@ -1299,6 +1755,10 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Provi func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState ProviderInfo) { } +func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegionInfo struct { Cloud types.String `tfsdk:"cloud" tf:"optional"` @@ -1311,6 +1771,10 @@ func (newState *RegionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RegionI func (newState *RegionInfo) SyncEffectiveFieldsDuringRead(existingState RegionInfo) { } +func (a RegionInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Remove an exchange for listing type RemoveExchangeForListingRequest struct { Id types.String `tfsdk:"-"` @@ -1322,6 +1786,10 @@ func (newState *RemoveExchangeForListingRequest) SyncEffectiveFieldsDuringCreate func (newState *RemoveExchangeForListingRequest) SyncEffectiveFieldsDuringRead(existingState RemoveExchangeForListingRequest) { } +func (a RemoveExchangeForListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RemoveExchangeForListingResponse struct { } @@ -1331,6 +1799,10 @@ func (newState *RemoveExchangeForListingResponse) SyncEffectiveFieldsDuringCreat func (newState *RemoveExchangeForListingResponse) SyncEffectiveFieldsDuringRead(existingState RemoveExchangeForListingResponse) { } +func (a RemoveExchangeForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RepoInfo struct { // the git repo url e.g. https://github.com/databrickslabs/dolly.git GitRepoUrl types.String `tfsdk:"git_repo_url" tf:""` @@ -1342,6 +1814,10 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoInfo) func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) { } +func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RepoInstallation struct { // the user-specified repo name for their installed git repo listing RepoName types.String `tfsdk:"repo_name" tf:""` @@ -1357,12 +1833,16 @@ func (newState *RepoInstallation) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RepoInstallation) SyncEffectiveFieldsDuringRead(existingState RepoInstallation) { } +func (a RepoInstallation) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Search listings type SearchListingsRequest struct { // Matches any of the following asset types - Assets []types.String `tfsdk:"-"` + Assets types.List `tfsdk:"-"` // Matches any of the following categories - Categories []types.String `tfsdk:"-"` + Categories types.List `tfsdk:"-"` IsFree types.Bool `tfsdk:"-"` @@ -1372,7 +1852,7 @@ type SearchListingsRequest struct { PageToken types.String `tfsdk:"-"` // Matches any of the following provider ids - ProviderIds []types.String `tfsdk:"-"` + ProviderIds types.List `tfsdk:"-"` // Fuzzy matches query Query types.String `tfsdk:"-"` } @@ -1383,8 +1863,16 @@ func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringRead(existingState SearchListingsRequest) { } +func (a SearchListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Assets": reflect.TypeOf(""), + "Categories": reflect.TypeOf(""), + "ProviderIds": reflect.TypeOf(""), + } +} + type SearchListingsResponse struct { - Listings []Listing `tfsdk:"listings" tf:"optional"` + Listings types.List `tfsdk:"listings" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -1395,6 +1883,12 @@ func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringRead(existingState SearchListingsResponse) { } +func (a SearchListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listings": reflect.TypeOf(Listing{}), + } +} + type ShareInfo struct { Name types.String `tfsdk:"name" tf:""` @@ -1407,6 +1901,10 @@ func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInf func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo) { } +func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SharedDataObject struct { // The type of the data object. Could be one of: TABLE, SCHEMA, // NOTEBOOK_FILE, MODEL, VOLUME @@ -1421,6 +1919,10 @@ func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { } +func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenDetail struct { BearerToken types.String `tfsdk:"bearerToken" tf:"optional"` @@ -1439,6 +1941,10 @@ func (newState *TokenDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenD func (newState *TokenDetail) SyncEffectiveFieldsDuringRead(existingState TokenDetail) { } +func (a TokenDetail) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenInfo struct { // Full activation url to retrieve the access token. It will be empty if the // token is already retrieved. @@ -1463,8 +1969,12 @@ func (newState *TokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenInf func (newState *TokenInfo) SyncEffectiveFieldsDuringRead(existingState TokenInfo) { } +func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateExchangeFilterRequest struct { - Filter []ExchangeFilter `tfsdk:"filter" tf:"object"` + Filter types.Object `tfsdk:"filter" tf:"object"` Id types.String `tfsdk:"-"` } @@ -1475,8 +1985,14 @@ func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeFilterRequest) { } +func (a UpdateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Filter": reflect.TypeOf(ExchangeFilter{}), + } +} + type UpdateExchangeFilterResponse struct { - Filter []ExchangeFilter `tfsdk:"filter" tf:"optional,object"` + Filter types.Object `tfsdk:"filter" tf:"optional,object"` } func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateExchangeFilterResponse) { @@ -1485,8 +2001,14 @@ func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeFilterResponse) { } +func (a UpdateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Filter": reflect.TypeOf(ExchangeFilter{}), + } +} + type UpdateExchangeRequest struct { - Exchange []Exchange `tfsdk:"exchange" tf:"object"` + Exchange types.Object `tfsdk:"exchange" tf:"object"` Id types.String `tfsdk:"-"` } @@ -1497,8 +2019,14 @@ func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeRequest) { } +func (a UpdateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exchange": reflect.TypeOf(Exchange{}), + } +} + type UpdateExchangeResponse struct { - Exchange []Exchange `tfsdk:"exchange" tf:"optional,object"` + Exchange types.Object `tfsdk:"exchange" tf:"optional,object"` } func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateExchangeResponse) { @@ -1507,8 +2035,14 @@ func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeResponse) { } +func (a UpdateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exchange": reflect.TypeOf(Exchange{}), + } +} + type UpdateInstallationRequest struct { - Installation []InstallationDetail `tfsdk:"installation" tf:"object"` + Installation types.Object `tfsdk:"installation" tf:"object"` InstallationId types.String `tfsdk:"-"` @@ -1523,8 +2057,14 @@ func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateInstallationRequest) { } +func (a UpdateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Installation": reflect.TypeOf(InstallationDetail{}), + } +} + type UpdateInstallationResponse struct { - Installation []InstallationDetail `tfsdk:"installation" tf:"optional,object"` + Installation types.Object `tfsdk:"installation" tf:"optional,object"` } func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateInstallationResponse) { @@ -1533,10 +2073,16 @@ func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringRead(existingState UpdateInstallationResponse) { } +func (a UpdateInstallationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Installation": reflect.TypeOf(InstallationDetail{}), + } +} + type UpdateListingRequest struct { Id types.String `tfsdk:"-"` - Listing []Listing `tfsdk:"listing" tf:"object"` + Listing types.Object `tfsdk:"listing" tf:"object"` } func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateListingRequest) { @@ -1545,8 +2091,14 @@ func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateListingRequest) { } +func (a UpdateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listing": reflect.TypeOf(Listing{}), + } +} + type UpdateListingResponse struct { - Listing []Listing `tfsdk:"listing" tf:"optional,object"` + Listing types.Object `tfsdk:"listing" tf:"optional,object"` } func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateListingResponse) { @@ -1555,6 +2107,12 @@ func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringRead(existingState UpdateListingResponse) { } +func (a UpdateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Listing": reflect.TypeOf(Listing{}), + } +} + type UpdatePersonalizationRequestRequest struct { ListingId types.String `tfsdk:"-"` @@ -1562,7 +2120,7 @@ type UpdatePersonalizationRequestRequest struct { RequestId types.String `tfsdk:"-"` - Share []ShareInfo `tfsdk:"share" tf:"optional,object"` + Share types.Object `tfsdk:"share" tf:"optional,object"` Status types.String `tfsdk:"status" tf:""` } @@ -1573,8 +2131,14 @@ func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringCr func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalizationRequestRequest) { } +func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Share": reflect.TypeOf(ShareInfo{}), + } +} + type UpdatePersonalizationRequestResponse struct { - Request []PersonalizationRequest `tfsdk:"request" tf:"optional,object"` + Request types.Object `tfsdk:"request" tf:"optional,object"` } func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdatePersonalizationRequestResponse) { @@ -1583,6 +2147,12 @@ func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringC func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalizationRequestResponse) { } +func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Request": reflect.TypeOf(PersonalizationRequest{}), + } +} + type UpdateProviderAnalyticsDashboardRequest struct { // id is immutable property and can't be updated. Id types.String `tfsdk:"-"` @@ -1598,6 +2168,10 @@ func (newState *UpdateProviderAnalyticsDashboardRequest) SyncEffectiveFieldsDuri func (newState *UpdateProviderAnalyticsDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UpdateProviderAnalyticsDashboardRequest) { } +func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateProviderAnalyticsDashboardResponse struct { // this is newly created Lakeview dashboard for the user DashboardId types.String `tfsdk:"dashboard_id" tf:""` @@ -1613,10 +2187,14 @@ func (newState *UpdateProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDur func (newState *UpdateProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState UpdateProviderAnalyticsDashboardResponse) { } +func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateProviderRequest struct { Id types.String `tfsdk:"-"` - Provider []ProviderInfo `tfsdk:"provider" tf:"object"` + Provider types.Object `tfsdk:"provider" tf:"object"` } func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateProviderRequest) { @@ -1625,8 +2203,14 @@ func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringRead(existingState UpdateProviderRequest) { } +func (a UpdateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Provider": reflect.TypeOf(ProviderInfo{}), + } +} + type UpdateProviderResponse struct { - Provider []ProviderInfo `tfsdk:"provider" tf:"optional,object"` + Provider types.Object `tfsdk:"provider" tf:"optional,object"` } func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateProviderResponse) { @@ -1634,3 +2218,9 @@ func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringRead(existingState UpdateProviderResponse) { } + +func (a UpdateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Provider": reflect.TypeOf(ProviderInfo{}), + } +} diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index c978e6a2c4..9e07b0dfb6 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package ml_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -76,6 +78,10 @@ func (newState *Activity) SyncEffectiveFieldsDuringCreateOrUpdate(plan Activity) func (newState *Activity) SyncEffectiveFieldsDuringRead(existingState Activity) { } +func (a Activity) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ApproveTransitionRequest struct { // Specifies whether to archive all current model versions in the target // stage. @@ -104,9 +110,13 @@ func (newState *ApproveTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ApproveTransitionRequest) SyncEffectiveFieldsDuringRead(existingState ApproveTransitionRequest) { } +func (a ApproveTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ApproveTransitionRequestResponse struct { // Activity recorded for the action. - Activity []Activity `tfsdk:"activity" tf:"optional,object"` + Activity types.Object `tfsdk:"activity" tf:"optional,object"` } func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ApproveTransitionRequestResponse) { @@ -115,10 +125,16 @@ func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringCreat func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState ApproveTransitionRequestResponse) { } +func (a ApproveTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Activity": reflect.TypeOf(Activity{}), + } +} + // Comment details. type CommentObject struct { // Array of actions on the activity allowed for the current viewer. - AvailableActions []types.String `tfsdk:"available_actions" tf:"optional"` + AvailableActions types.List `tfsdk:"available_actions" tf:"optional"` // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` // Creation time of the object, as a Unix timestamp in milliseconds. @@ -137,6 +153,12 @@ func (newState *CommentObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan Comm func (newState *CommentObject) SyncEffectiveFieldsDuringRead(existingState CommentObject) { } +func (a CommentObject) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AvailableActions": reflect.TypeOf(""), + } +} + type CreateComment struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:""` @@ -152,9 +174,13 @@ func (newState *CreateComment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateComment) SyncEffectiveFieldsDuringRead(existingState CreateComment) { } +func (a CreateComment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateCommentResponse struct { // Comment details. - Comment []CommentObject `tfsdk:"comment" tf:"optional,object"` + Comment types.Object `tfsdk:"comment" tf:"optional,object"` } func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCommentResponse) { @@ -163,6 +189,12 @@ func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringRead(existingState CreateCommentResponse) { } +func (a CreateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Comment": reflect.TypeOf(CommentObject{}), + } +} + type CreateExperiment struct { // Location where all artifacts for the experiment are stored. If not // provided, the remote server will select an appropriate default. @@ -174,7 +206,7 @@ type CreateExperiment struct { // backends are guaranteed to support tag keys up to 250 bytes in size and // tag values up to 5000 bytes in size. All storage backends are also // guaranteed to support up to 20 tags per request. - Tags []ExperimentTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *CreateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateExperiment) { @@ -183,6 +215,12 @@ func (newState *CreateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateExperiment) SyncEffectiveFieldsDuringRead(existingState CreateExperiment) { } +func (a CreateExperiment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(ExperimentTag{}), + } +} + type CreateExperimentResponse struct { // Unique identifier for the experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:"optional"` @@ -194,13 +232,17 @@ func (newState *CreateExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateExperimentResponse) SyncEffectiveFieldsDuringRead(existingState CreateExperimentResponse) { } +func (a CreateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateModelRequest struct { // Optional description for registered model. Description types.String `tfsdk:"description" tf:"optional"` // Register models under this name Name types.String `tfsdk:"name" tf:""` // Additional metadata for registered model. - Tags []ModelTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *CreateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateModelRequest) { @@ -209,8 +251,14 @@ func (newState *CreateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateModelRequest) SyncEffectiveFieldsDuringRead(existingState CreateModelRequest) { } +func (a CreateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(ModelTag{}), + } +} + type CreateModelResponse struct { - RegisteredModel []Model `tfsdk:"registered_model" tf:"optional,object"` + RegisteredModel types.Object `tfsdk:"registered_model" tf:"optional,object"` } func (newState *CreateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateModelResponse) { @@ -219,6 +267,12 @@ func (newState *CreateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateModelResponse) SyncEffectiveFieldsDuringRead(existingState CreateModelResponse) { } +func (a CreateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RegisteredModel": reflect.TypeOf(Model{}), + } +} + type CreateModelVersionRequest struct { // Optional description for model version. Description types.String `tfsdk:"description" tf:"optional"` @@ -233,7 +287,7 @@ type CreateModelVersionRequest struct { // URI indicating the location of the model artifacts. Source types.String `tfsdk:"source" tf:""` // Additional metadata for model version. - Tags []ModelVersionTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateModelVersionRequest) { @@ -242,9 +296,15 @@ func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState CreateModelVersionRequest) { } +func (a CreateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(ModelVersionTag{}), + } +} + type CreateModelVersionResponse struct { // Return new version number generated for this model in registry. - ModelVersion []ModelVersion `tfsdk:"model_version" tf:"optional,object"` + ModelVersion types.Object `tfsdk:"model_version" tf:"optional,object"` } func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateModelVersionResponse) { @@ -253,6 +313,12 @@ func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState CreateModelVersionResponse) { } +func (a CreateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ModelVersion": reflect.TypeOf(ModelVersion{}), + } +} + type CreateRegistryWebhook struct { // User-specified description for the webhook. Description types.String `tfsdk:"description" tf:"optional"` @@ -289,11 +355,11 @@ type CreateRegistryWebhook struct { // // * `TRANSITION_REQUEST_TO_ARCHIVED_CREATED`: A user requested a model // version be archived. - Events []types.String `tfsdk:"events" tf:""` + Events types.List `tfsdk:"events" tf:""` - HttpUrlSpec []HttpUrlSpec `tfsdk:"http_url_spec" tf:"optional,object"` + HttpUrlSpec types.Object `tfsdk:"http_url_spec" tf:"optional,object"` - JobSpec []JobSpec `tfsdk:"job_spec" tf:"optional,object"` + JobSpec types.Object `tfsdk:"job_spec" tf:"optional,object"` // Name of the model whose events would trigger this webhook. ModelName types.String `tfsdk:"model_name" tf:"optional"` // Enable or disable triggering the webhook, or put the webhook into test @@ -313,13 +379,21 @@ func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState CreateRegistryWebhook) { } +func (a CreateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Events": reflect.TypeOf(""), + "HttpUrlSpec": reflect.TypeOf(HttpUrlSpec{}), + "JobSpec": reflect.TypeOf(JobSpec{}), + } +} + type CreateRun struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:"optional"` // Unix timestamp in milliseconds of when the run started. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Additional metadata for run. - Tags []RunTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // ID of the user executing the run. This field is deprecated as of MLflow // 1.0, and will be removed in a future MLflow release. Use 'mlflow.user' // tag instead. @@ -332,9 +406,15 @@ func (newState *CreateRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateRu func (newState *CreateRun) SyncEffectiveFieldsDuringRead(existingState CreateRun) { } +func (a CreateRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(RunTag{}), + } +} + type CreateRunResponse struct { // The newly created run. - Run []Run `tfsdk:"run" tf:"optional,object"` + Run types.Object `tfsdk:"run" tf:"optional,object"` } func (newState *CreateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateRunResponse) { @@ -343,6 +423,12 @@ func (newState *CreateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRunResponse) SyncEffectiveFieldsDuringRead(existingState CreateRunResponse) { } +func (a CreateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Run": reflect.TypeOf(Run{}), + } +} + type CreateTransitionRequest struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -368,9 +454,13 @@ func (newState *CreateTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateTransitionRequest) SyncEffectiveFieldsDuringRead(existingState CreateTransitionRequest) { } +func (a CreateTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateTransitionRequestResponse struct { // Transition request details. - Request []TransitionRequest `tfsdk:"request" tf:"optional,object"` + Request types.Object `tfsdk:"request" tf:"optional,object"` } func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateTransitionRequestResponse) { @@ -379,8 +469,14 @@ func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState CreateTransitionRequestResponse) { } +func (a CreateTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Request": reflect.TypeOf(TransitionRequest{}), + } +} + type CreateWebhookResponse struct { - Webhook []RegistryWebhook `tfsdk:"webhook" tf:"optional,object"` + Webhook types.Object `tfsdk:"webhook" tf:"optional,object"` } func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateWebhookResponse) { @@ -389,6 +485,12 @@ func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringRead(existingState CreateWebhookResponse) { } +func (a CreateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Webhook": reflect.TypeOf(RegistryWebhook{}), + } +} + type Dataset struct { // Dataset digest, e.g. an md5 hash of the dataset that uniquely identifies // it within datasets of the same name. @@ -418,12 +520,16 @@ func (newState *Dataset) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dataset) { func (newState *Dataset) SyncEffectiveFieldsDuringRead(existingState Dataset) { } +func (a Dataset) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DatasetInput struct { // The dataset being used as a Run input. - Dataset []Dataset `tfsdk:"dataset" tf:"optional,object"` + Dataset types.Object `tfsdk:"dataset" tf:"optional,object"` // A list of tags for the dataset input, e.g. a “context” tag with value // “training” - Tags []InputTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *DatasetInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan DatasetInput) { @@ -432,6 +538,13 @@ func (newState *DatasetInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Datas func (newState *DatasetInput) SyncEffectiveFieldsDuringRead(existingState DatasetInput) { } +func (a DatasetInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Dataset": reflect.TypeOf(Dataset{}), + "Tags": reflect.TypeOf(InputTag{}), + } +} + // Delete a comment type DeleteCommentRequest struct { Id types.String `tfsdk:"-"` @@ -443,6 +556,10 @@ func (newState *DeleteCommentRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteCommentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCommentRequest) { } +func (a DeleteCommentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteCommentResponse struct { } @@ -452,6 +569,10 @@ func (newState *DeleteCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteCommentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCommentResponse) { } +func (a DeleteCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -463,6 +584,10 @@ func (newState *DeleteExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteExperiment) SyncEffectiveFieldsDuringRead(existingState DeleteExperiment) { } +func (a DeleteExperiment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteExperimentResponse struct { } @@ -472,6 +597,10 @@ func (newState *DeleteExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteExperimentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExperimentResponse) { } +func (a DeleteExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a model type DeleteModelRequest struct { // Registered model unique name identifier. @@ -484,6 +613,10 @@ func (newState *DeleteModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteModelRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelRequest) { } +func (a DeleteModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteModelResponse struct { } @@ -493,6 +626,10 @@ func (newState *DeleteModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteModelResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelResponse) { } +func (a DeleteModelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a model tag type DeleteModelTagRequest struct { // Name of the tag. The name must be an exact match; wild-card deletion is @@ -508,6 +645,10 @@ func (newState *DeleteModelTagRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteModelTagRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelTagRequest) { } +func (a DeleteModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteModelTagResponse struct { } @@ -517,6 +658,10 @@ func (newState *DeleteModelTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteModelTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelTagResponse) { } +func (a DeleteModelTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a model version. type DeleteModelVersionRequest struct { // Name of the registered model @@ -531,6 +676,10 @@ func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionRequest) { } +func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteModelVersionResponse struct { } @@ -540,6 +689,10 @@ func (newState *DeleteModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionResponse) { } +func (a DeleteModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a model version tag type DeleteModelVersionTagRequest struct { // Name of the tag. The name must be an exact match; wild-card deletion is @@ -557,6 +710,10 @@ func (newState *DeleteModelVersionTagRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteModelVersionTagRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionTagRequest) { } +func (a DeleteModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteModelVersionTagResponse struct { } @@ -566,6 +723,10 @@ func (newState *DeleteModelVersionTagResponse) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteModelVersionTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionTagResponse) { } +func (a DeleteModelVersionTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRun struct { // ID of the run to delete. RunId types.String `tfsdk:"run_id" tf:""` @@ -577,6 +738,10 @@ func (newState *DeleteRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteRu func (newState *DeleteRun) SyncEffectiveFieldsDuringRead(existingState DeleteRun) { } +func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRunResponse struct { } @@ -586,6 +751,10 @@ func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunResponse) { } +func (a DeleteRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRuns struct { // The ID of the experiment containing the runs to delete. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -604,6 +773,10 @@ func (newState *DeleteRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteR func (newState *DeleteRuns) SyncEffectiveFieldsDuringRead(existingState DeleteRuns) { } +func (a DeleteRuns) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRunsResponse struct { // The number of runs deleted. RunsDeleted types.Int64 `tfsdk:"runs_deleted" tf:"optional"` @@ -615,6 +788,10 @@ func (newState *DeleteRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunsResponse) { } +func (a DeleteRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteTag struct { // Name of the tag. Maximum size is 255 bytes. Must be provided. Key types.String `tfsdk:"key" tf:""` @@ -628,6 +805,10 @@ func (newState *DeleteTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteTa func (newState *DeleteTag) SyncEffectiveFieldsDuringRead(existingState DeleteTag) { } +func (a DeleteTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteTagResponse struct { } @@ -637,6 +818,10 @@ func (newState *DeleteTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteTagResponse) { } +func (a DeleteTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a transition request type DeleteTransitionRequestRequest struct { // User-provided comment on the action. @@ -667,6 +852,10 @@ func (newState *DeleteTransitionRequestRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteTransitionRequestRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTransitionRequestRequest) { } +func (a DeleteTransitionRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteTransitionRequestResponse struct { } @@ -676,6 +865,10 @@ func (newState *DeleteTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *DeleteTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState DeleteTransitionRequestResponse) { } +func (a DeleteTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a webhook type DeleteWebhookRequest struct { // Webhook ID required to delete a registry webhook. @@ -688,6 +881,10 @@ func (newState *DeleteWebhookRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteWebhookRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWebhookRequest) { } +func (a DeleteWebhookRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteWebhookResponse struct { } @@ -697,6 +894,10 @@ func (newState *DeleteWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteWebhookResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWebhookResponse) { } +func (a DeleteWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Experiment struct { // Location where artifacts for the experiment are stored. ArtifactLocation types.String `tfsdk:"artifact_location" tf:"optional"` @@ -712,7 +913,7 @@ type Experiment struct { // Human readable name that identifies the experiment. Name types.String `tfsdk:"name" tf:"optional"` // Tags: Additional metadata key-value pairs. - Tags []ExperimentTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *Experiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Experiment) { @@ -721,6 +922,12 @@ func (newState *Experiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Experim func (newState *Experiment) SyncEffectiveFieldsDuringRead(existingState Experiment) { } +func (a Experiment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(ExperimentTag{}), + } +} + type ExperimentAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -738,9 +945,13 @@ func (newState *ExperimentAccessControlRequest) SyncEffectiveFieldsDuringCreateO func (newState *ExperimentAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ExperimentAccessControlRequest) { } +func (a ExperimentAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExperimentAccessControlResponse struct { // All permissions. - AllPermissions []ExperimentPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -757,10 +968,16 @@ func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringCreate func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ExperimentAccessControlResponse) { } +func (a ExperimentAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(ExperimentPermission{}), + } +} + type ExperimentPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -771,8 +988,14 @@ func (newState *ExperimentPermission) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExperimentPermission) SyncEffectiveFieldsDuringRead(existingState ExperimentPermission) { } +func (a ExperimentPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type ExperimentPermissions struct { - AccessControlList []ExperimentAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -785,6 +1008,12 @@ func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissions) { } +func (a ExperimentPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ExperimentAccessControlResponse{}), + } +} + type ExperimentPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -797,8 +1026,12 @@ func (newState *ExperimentPermissionsDescription) SyncEffectiveFieldsDuringCreat func (newState *ExperimentPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissionsDescription) { } +func (a ExperimentPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExperimentPermissionsRequest struct { - AccessControlList []ExperimentAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The experiment for which to get or manage permissions. ExperimentId types.String `tfsdk:"-"` } @@ -809,6 +1042,12 @@ func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissionsRequest) { } +func (a ExperimentPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ExperimentAccessControlRequest{}), + } +} + type ExperimentTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -822,6 +1061,10 @@ func (newState *ExperimentTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Expe func (newState *ExperimentTag) SyncEffectiveFieldsDuringRead(existingState ExperimentTag) { } +func (a ExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FileInfo struct { // Size in bytes. Unset for directories. FileSize types.Int64 `tfsdk:"file_size" tf:"optional"` @@ -837,6 +1080,10 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } +func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get metadata type GetByNameRequest struct { // Name of the associated experiment. @@ -849,6 +1096,10 @@ func (newState *GetByNameRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetByNameRequest) SyncEffectiveFieldsDuringRead(existingState GetByNameRequest) { } +func (a GetByNameRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get experiment permission levels type GetExperimentPermissionLevelsRequest struct { // The experiment for which to get or manage permissions. @@ -861,9 +1112,13 @@ func (newState *GetExperimentPermissionLevelsRequest) SyncEffectiveFieldsDuringC func (newState *GetExperimentPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionLevelsRequest) { } +func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetExperimentPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []ExperimentPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetExperimentPermissionLevelsResponse) { @@ -872,6 +1127,12 @@ func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuring func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionLevelsResponse) { } +func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(ExperimentPermissionsDescription{}), + } +} + // Get experiment permissions type GetExperimentPermissionsRequest struct { // The experiment for which to get or manage permissions. @@ -884,6 +1145,10 @@ func (newState *GetExperimentPermissionsRequest) SyncEffectiveFieldsDuringCreate func (newState *GetExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionsRequest) { } +func (a GetExperimentPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an experiment type GetExperimentRequest struct { // ID of the associated experiment. @@ -896,9 +1161,13 @@ func (newState *GetExperimentRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetExperimentRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentRequest) { } +func (a GetExperimentRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetExperimentResponse struct { // Experiment details. - Experiment []Experiment `tfsdk:"experiment" tf:"optional,object"` + Experiment types.Object `tfsdk:"experiment" tf:"optional,object"` } func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetExperimentResponse) { @@ -907,6 +1176,12 @@ func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringRead(existingState GetExperimentResponse) { } +func (a GetExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Experiment": reflect.TypeOf(Experiment{}), + } +} + // Get history of a given metric within a run type GetHistoryRequest struct { // Maximum number of Metric records to return per paginated request. Default @@ -930,11 +1205,15 @@ func (newState *GetHistoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetHistoryRequest) SyncEffectiveFieldsDuringRead(existingState GetHistoryRequest) { } +func (a GetHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetLatestVersionsRequest struct { // Registered model unique name identifier. Name types.String `tfsdk:"name" tf:""` // List of stages. - Stages []types.String `tfsdk:"stages" tf:"optional"` + Stages types.List `tfsdk:"stages" tf:"optional"` } func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetLatestVersionsRequest) { @@ -943,11 +1222,17 @@ func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionsRequest) { } +func (a GetLatestVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Stages": reflect.TypeOf(""), + } +} + type GetLatestVersionsResponse struct { // Latest version models for each requests stage. Only return models with // current `READY` status. If no `stages` provided, returns the latest // version for each stage, including `"None"`. - ModelVersions []ModelVersion `tfsdk:"model_versions" tf:"optional"` + ModelVersions types.List `tfsdk:"model_versions" tf:"optional"` } func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetLatestVersionsResponse) { @@ -956,9 +1241,15 @@ func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionsResponse) { } +func (a GetLatestVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ModelVersions": reflect.TypeOf(ModelVersion{}), + } +} + type GetMetricHistoryResponse struct { // All logged values for this metric. - Metrics []Metric `tfsdk:"metrics" tf:"optional"` + Metrics types.List `tfsdk:"metrics" tf:"optional"` // Token that can be used to retrieve the next page of metric history // results NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -970,6 +1261,12 @@ func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringRead(existingState GetMetricHistoryResponse) { } +func (a GetMetricHistoryResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Metrics": reflect.TypeOf(Metric{}), + } +} + // Get model type GetModelRequest struct { // Registered model unique name identifier. @@ -982,8 +1279,12 @@ func (newState *GetModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetModelRequest) SyncEffectiveFieldsDuringRead(existingState GetModelRequest) { } +func (a GetModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetModelResponse struct { - RegisteredModelDatabricks []ModelDatabricks `tfsdk:"registered_model_databricks" tf:"optional,object"` + RegisteredModelDatabricks types.Object `tfsdk:"registered_model_databricks" tf:"optional,object"` } func (newState *GetModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetModelResponse) { @@ -992,6 +1293,12 @@ func (newState *GetModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetModelResponse) SyncEffectiveFieldsDuringRead(existingState GetModelResponse) { } +func (a GetModelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RegisteredModelDatabricks": reflect.TypeOf(ModelDatabricks{}), + } +} + // Get a model version URI type GetModelVersionDownloadUriRequest struct { // Name of the registered model @@ -1006,6 +1313,10 @@ func (newState *GetModelVersionDownloadUriRequest) SyncEffectiveFieldsDuringCrea func (newState *GetModelVersionDownloadUriRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionDownloadUriRequest) { } +func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetModelVersionDownloadUriResponse struct { // URI corresponding to where artifacts for this model version are stored. ArtifactUri types.String `tfsdk:"artifact_uri" tf:"optional"` @@ -1017,6 +1328,10 @@ func (newState *GetModelVersionDownloadUriResponse) SyncEffectiveFieldsDuringCre func (newState *GetModelVersionDownloadUriResponse) SyncEffectiveFieldsDuringRead(existingState GetModelVersionDownloadUriResponse) { } +func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a model version type GetModelVersionRequest struct { // Name of the registered model @@ -1031,8 +1346,12 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionRequest) { } +func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetModelVersionResponse struct { - ModelVersion []ModelVersion `tfsdk:"model_version" tf:"optional,object"` + ModelVersion types.Object `tfsdk:"model_version" tf:"optional,object"` } func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetModelVersionResponse) { @@ -1041,6 +1360,12 @@ func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState GetModelVersionResponse) { } +func (a GetModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ModelVersion": reflect.TypeOf(ModelVersion{}), + } +} + // Get registered model permission levels type GetRegisteredModelPermissionLevelsRequest struct { // The registered model for which to get or manage permissions. @@ -1053,9 +1378,13 @@ func (newState *GetRegisteredModelPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetRegisteredModelPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionLevelsRequest) { } +func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetRegisteredModelPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []RegisteredModelPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRegisteredModelPermissionLevelsResponse) { @@ -1064,6 +1393,12 @@ func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionLevelsResponse) { } +func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(RegisteredModelPermissionsDescription{}), + } +} + // Get registered model permissions type GetRegisteredModelPermissionsRequest struct { // The registered model for which to get or manage permissions. @@ -1076,6 +1411,10 @@ func (newState *GetRegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetRegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionsRequest) { } +func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a run type GetRunRequest struct { // ID of the run to fetch. Must be provided. @@ -1091,10 +1430,14 @@ func (newState *GetRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetR func (newState *GetRunRequest) SyncEffectiveFieldsDuringRead(existingState GetRunRequest) { } +func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetRunResponse struct { // Run metadata (name, start time, etc) and data (metrics, params, and // tags). - Run []Run `tfsdk:"run" tf:"optional,object"` + Run types.Object `tfsdk:"run" tf:"optional,object"` } func (newState *GetRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRunResponse) { @@ -1103,6 +1446,12 @@ func (newState *GetRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetRunResponse) SyncEffectiveFieldsDuringRead(existingState GetRunResponse) { } +func (a GetRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Run": reflect.TypeOf(Run{}), + } +} + type HttpUrlSpec struct { // Value of the authorization header that should be sent in the request sent // by the wehbook. It should be of the form `" "`. @@ -1131,6 +1480,10 @@ func (newState *HttpUrlSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan HttpUr func (newState *HttpUrlSpec) SyncEffectiveFieldsDuringRead(existingState HttpUrlSpec) { } +func (a HttpUrlSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type HttpUrlSpecWithoutSecret struct { // Enable/disable SSL certificate validation. Default is true. For // self-signed certificates, this field must be false AND the destination @@ -1150,6 +1503,10 @@ func (newState *HttpUrlSpecWithoutSecret) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *HttpUrlSpecWithoutSecret) SyncEffectiveFieldsDuringRead(existingState HttpUrlSpecWithoutSecret) { } +func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type InputTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -1163,6 +1520,10 @@ func (newState *InputTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan InputTag) func (newState *InputTag) SyncEffectiveFieldsDuringRead(existingState InputTag) { } +func (a InputTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobSpec struct { // The personal access token used to authorize webhook's job runs. AccessToken types.String `tfsdk:"access_token" tf:""` @@ -1180,6 +1541,10 @@ func (newState *JobSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSpec) { func (newState *JobSpec) SyncEffectiveFieldsDuringRead(existingState JobSpec) { } +func (a JobSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type JobSpecWithoutSecret struct { // ID of the job that the webhook runs. JobId types.String `tfsdk:"job_id" tf:"optional"` @@ -1195,6 +1560,10 @@ func (newState *JobSpecWithoutSecret) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *JobSpecWithoutSecret) SyncEffectiveFieldsDuringRead(existingState JobSpecWithoutSecret) { } +func (a JobSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get all artifacts type ListArtifactsRequest struct { // Token indicating the page of artifact results to fetch. `page_token` is @@ -1220,9 +1589,13 @@ func (newState *ListArtifactsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListArtifactsRequest) SyncEffectiveFieldsDuringRead(existingState ListArtifactsRequest) { } +func (a ListArtifactsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListArtifactsResponse struct { // File location and metadata for artifacts. - Files []FileInfo `tfsdk:"files" tf:"optional"` + Files types.List `tfsdk:"files" tf:"optional"` // Token that can be used to retrieve the next page of artifact results NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // Root artifact directory for the run. @@ -1235,6 +1608,12 @@ func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringRead(existingState ListArtifactsResponse) { } +func (a ListArtifactsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Files": reflect.TypeOf(FileInfo{}), + } +} + // List experiments type ListExperimentsRequest struct { // Maximum number of experiments desired. If `max_results` is unspecified, @@ -1256,10 +1635,14 @@ func (newState *ListExperimentsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListExperimentsRequest) SyncEffectiveFieldsDuringRead(existingState ListExperimentsRequest) { } +func (a ListExperimentsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListExperimentsResponse struct { // Paginated Experiments beginning with the first item on the requested // page. - Experiments []Experiment `tfsdk:"experiments" tf:"optional"` + Experiments types.List `tfsdk:"experiments" tf:"optional"` // Token that can be used to retrieve the next page of experiments. Empty // token means no more experiment is available for retrieval. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1271,6 +1654,12 @@ func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringRead(existingState ListExperimentsResponse) { } +func (a ListExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Experiments": reflect.TypeOf(Experiment{}), + } +} + // List models type ListModelsRequest struct { // Maximum number of registered models desired. Max threshold is 1000. @@ -1285,11 +1674,15 @@ func (newState *ListModelsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListModelsRequest) SyncEffectiveFieldsDuringRead(existingState ListModelsRequest) { } +func (a ListModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListModelsResponse struct { // Pagination token to request next page of models for the same query. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - RegisteredModels []Model `tfsdk:"registered_models" tf:"optional"` + RegisteredModels types.List `tfsdk:"registered_models" tf:"optional"` } func (newState *ListModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListModelsResponse) { @@ -1298,11 +1691,17 @@ func (newState *ListModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListModelsResponse) SyncEffectiveFieldsDuringRead(existingState ListModelsResponse) { } +func (a ListModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RegisteredModels": reflect.TypeOf(Model{}), + } +} + type ListRegistryWebhooks struct { // Token that can be used to retrieve the next page of artifact results NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // Array of registry webhooks. - Webhooks []RegistryWebhook `tfsdk:"webhooks" tf:"optional"` + Webhooks types.List `tfsdk:"webhooks" tf:"optional"` } func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListRegistryWebhooks) { @@ -1311,6 +1710,12 @@ func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringRead(existingState ListRegistryWebhooks) { } +func (a ListRegistryWebhooks) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Webhooks": reflect.TypeOf(RegistryWebhook{}), + } +} + // List transition requests type ListTransitionRequestsRequest struct { // Name of the model. @@ -1325,9 +1730,13 @@ func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringRead(existingState ListTransitionRequestsRequest) { } +func (a ListTransitionRequestsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListTransitionRequestsResponse struct { // Array of open transition requests. - Requests []Activity `tfsdk:"requests" tf:"optional"` + Requests types.List `tfsdk:"requests" tf:"optional"` } func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListTransitionRequestsResponse) { @@ -1336,12 +1745,18 @@ func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringRead(existingState ListTransitionRequestsResponse) { } +func (a ListTransitionRequestsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Requests": reflect.TypeOf(Activity{}), + } +} + // List registry webhooks type ListWebhooksRequest struct { // If `events` is specified, any webhook with one or more of the specified // trigger events is included in the output. If `events` is not specified, // webhooks of all event types are included in the output. - Events []types.String `tfsdk:"-"` + Events types.List `tfsdk:"-"` // If not specified, all webhooks associated with the specified events are // listed, regardless of their associated model. ModelName types.String `tfsdk:"-"` @@ -1355,18 +1770,24 @@ func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringRead(existingState ListWebhooksRequest) { } +func (a ListWebhooksRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Events": reflect.TypeOf(""), + } +} + type LogBatch struct { // Metrics to log. A single request can contain up to 1000 metrics, and up // to 1000 metrics, params, and tags in total. - Metrics []Metric `tfsdk:"metrics" tf:"optional"` + Metrics types.List `tfsdk:"metrics" tf:"optional"` // Params to log. A single request can contain up to 100 params, and up to // 1000 metrics, params, and tags in total. - Params []Param `tfsdk:"params" tf:"optional"` + Params types.List `tfsdk:"params" tf:"optional"` // ID of the run to log under RunId types.String `tfsdk:"run_id" tf:"optional"` // Tags to log. A single request can contain up to 100 tags, and up to 1000 // metrics, params, and tags in total. - Tags []RunTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *LogBatch) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogBatch) { @@ -1375,6 +1796,14 @@ func (newState *LogBatch) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogBatch) func (newState *LogBatch) SyncEffectiveFieldsDuringRead(existingState LogBatch) { } +func (a LogBatch) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Metrics": reflect.TypeOf(Metric{}), + "Params": reflect.TypeOf(Param{}), + "Tags": reflect.TypeOf(RunTag{}), + } +} + type LogBatchResponse struct { } @@ -1384,9 +1813,13 @@ func (newState *LogBatchResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogBatchResponse) SyncEffectiveFieldsDuringRead(existingState LogBatchResponse) { } +func (a LogBatchResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogInputs struct { // Dataset inputs - Datasets []DatasetInput `tfsdk:"datasets" tf:"optional"` + Datasets types.List `tfsdk:"datasets" tf:"optional"` // ID of the run to log under RunId types.String `tfsdk:"run_id" tf:"optional"` } @@ -1397,6 +1830,12 @@ func (newState *LogInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogInput func (newState *LogInputs) SyncEffectiveFieldsDuringRead(existingState LogInputs) { } +func (a LogInputs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Datasets": reflect.TypeOf(DatasetInput{}), + } +} + type LogInputsResponse struct { } @@ -1406,6 +1845,10 @@ func (newState *LogInputsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogInputsResponse) SyncEffectiveFieldsDuringRead(existingState LogInputsResponse) { } +func (a LogInputsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogMetric struct { // Name of the metric. Key types.String `tfsdk:"key" tf:""` @@ -1428,6 +1871,10 @@ func (newState *LogMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogMetri func (newState *LogMetric) SyncEffectiveFieldsDuringRead(existingState LogMetric) { } +func (a LogMetric) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogMetricResponse struct { } @@ -1437,6 +1884,10 @@ func (newState *LogMetricResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogMetricResponse) SyncEffectiveFieldsDuringRead(existingState LogMetricResponse) { } +func (a LogMetricResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogModel struct { // MLmodel file in json format. ModelJson types.String `tfsdk:"model_json" tf:"optional"` @@ -1450,6 +1901,10 @@ func (newState *LogModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogModel) func (newState *LogModel) SyncEffectiveFieldsDuringRead(existingState LogModel) { } +func (a LogModel) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogModelResponse struct { } @@ -1459,6 +1914,10 @@ func (newState *LogModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogModelResponse) SyncEffectiveFieldsDuringRead(existingState LogModelResponse) { } +func (a LogModelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogParam struct { // Name of the param. Maximum size is 255 bytes. Key types.String `tfsdk:"key" tf:""` @@ -1477,6 +1936,10 @@ func (newState *LogParam) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogParam) func (newState *LogParam) SyncEffectiveFieldsDuringRead(existingState LogParam) { } +func (a LogParam) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type LogParamResponse struct { } @@ -1486,6 +1949,10 @@ func (newState *LogParamResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogParamResponse) SyncEffectiveFieldsDuringRead(existingState LogParamResponse) { } +func (a LogParamResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Metric struct { // Key identifying this metric. Key types.String `tfsdk:"key" tf:"optional"` @@ -1503,6 +1970,10 @@ func (newState *Metric) SyncEffectiveFieldsDuringCreateOrUpdate(plan Metric) { func (newState *Metric) SyncEffectiveFieldsDuringRead(existingState Metric) { } +func (a Metric) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Model struct { // Timestamp recorded when this `registered_model` was created. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1513,11 +1984,11 @@ type Model struct { LastUpdatedTimestamp types.Int64 `tfsdk:"last_updated_timestamp" tf:"optional"` // Collection of latest model versions for each stage. Only contains models // with current `READY` status. - LatestVersions []ModelVersion `tfsdk:"latest_versions" tf:"optional"` + LatestVersions types.List `tfsdk:"latest_versions" tf:"optional"` // Unique name for the model. Name types.String `tfsdk:"name" tf:"optional"` // Tags: Additional metadata key-value pairs for this `registered_model`. - Tags []ModelTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // User that created this `registered_model` UserId types.String `tfsdk:"user_id" tf:"optional"` } @@ -1528,6 +1999,13 @@ func (newState *Model) SyncEffectiveFieldsDuringCreateOrUpdate(plan Model) { func (newState *Model) SyncEffectiveFieldsDuringRead(existingState Model) { } +func (a Model) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LatestVersions": reflect.TypeOf(ModelVersion{}), + "Tags": reflect.TypeOf(ModelTag{}), + } +} + type ModelDatabricks struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1538,14 +2016,14 @@ type ModelDatabricks struct { // Time of the object at last update, as a Unix timestamp in milliseconds. LastUpdatedTimestamp types.Int64 `tfsdk:"last_updated_timestamp" tf:"optional"` // Array of model versions, each the latest version for its stage. - LatestVersions []ModelVersion `tfsdk:"latest_versions" tf:"optional"` + LatestVersions types.List `tfsdk:"latest_versions" tf:"optional"` // Name of the model. Name types.String `tfsdk:"name" tf:"optional"` // Permission level of the requesting user on the object. For what is // allowed at each level, see [MLflow Model permissions](..). PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` // Array of tags associated with the model. - Tags []ModelTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // The username of the user that created the object. UserId types.String `tfsdk:"user_id" tf:"optional"` } @@ -1556,6 +2034,13 @@ func (newState *ModelDatabricks) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *ModelDatabricks) SyncEffectiveFieldsDuringRead(existingState ModelDatabricks) { } +func (a ModelDatabricks) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LatestVersions": reflect.TypeOf(ModelVersion{}), + "Tags": reflect.TypeOf(ModelTag{}), + } +} + type ModelTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -1569,6 +2054,10 @@ func (newState *ModelTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan ModelTag) func (newState *ModelTag) SyncEffectiveFieldsDuringRead(existingState ModelTag) { } +func (a ModelTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ModelVersion struct { // Timestamp recorded when this `model_version` was created. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1594,7 +2083,7 @@ type ModelVersion struct { // Details on current `status`, if it is pending or failed. StatusMessage types.String `tfsdk:"status_message" tf:"optional"` // Tags: Additional metadata key-value pairs for this `model_version`. - Tags []ModelVersionTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // User that created this `model_version`. UserId types.String `tfsdk:"user_id" tf:"optional"` // Model's version number. @@ -1607,6 +2096,12 @@ func (newState *ModelVersion) SyncEffectiveFieldsDuringCreateOrUpdate(plan Model func (newState *ModelVersion) SyncEffectiveFieldsDuringRead(existingState ModelVersion) { } +func (a ModelVersion) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(ModelVersionTag{}), + } +} + type ModelVersionDatabricks struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1651,7 +2146,7 @@ type ModelVersionDatabricks struct { // Details on the current status, for example why registration failed. StatusMessage types.String `tfsdk:"status_message" tf:"optional"` // Array of tags that are associated with the model version. - Tags []ModelVersionTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // The username of the user that created the object. UserId types.String `tfsdk:"user_id" tf:"optional"` // Version of the model. @@ -1664,6 +2159,12 @@ func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringRead(existingState ModelVersionDatabricks) { } +func (a ModelVersionDatabricks) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(ModelVersionTag{}), + } +} + type ModelVersionTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -1677,6 +2178,10 @@ func (newState *ModelVersionTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *ModelVersionTag) SyncEffectiveFieldsDuringRead(existingState ModelVersionTag) { } +func (a ModelVersionTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Param struct { // Key identifying this param. Key types.String `tfsdk:"key" tf:"optional"` @@ -1690,6 +2195,10 @@ func (newState *Param) SyncEffectiveFieldsDuringCreateOrUpdate(plan Param) { func (newState *Param) SyncEffectiveFieldsDuringRead(existingState Param) { } +func (a Param) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegisteredModelAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1707,9 +2216,13 @@ func (newState *RegisteredModelAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *RegisteredModelAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAccessControlRequest) { } +func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegisteredModelAccessControlResponse struct { // All permissions. - AllPermissions []RegisteredModelPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -1726,10 +2239,16 @@ func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAccessControlResponse) { } +func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(RegisteredModelPermission{}), + } +} + type RegisteredModelPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -1740,8 +2259,14 @@ func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermission) { } +func (a RegisteredModelPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type RegisteredModelPermissions struct { - AccessControlList []RegisteredModelAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -1754,6 +2279,12 @@ func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissions) { } +func (a RegisteredModelPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(RegisteredModelAccessControlResponse{}), + } +} + type RegisteredModelPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1766,8 +2297,12 @@ func (newState *RegisteredModelPermissionsDescription) SyncEffectiveFieldsDuring func (newState *RegisteredModelPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissionsDescription) { } +func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RegisteredModelPermissionsRequest struct { - AccessControlList []RegisteredModelAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The registered model for which to get or manage permissions. RegisteredModelId types.String `tfsdk:"-"` } @@ -1778,6 +2313,12 @@ func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissionsRequest) { } +func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(RegisteredModelAccessControlRequest{}), + } +} + type RegistryWebhook struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1816,13 +2357,13 @@ type RegistryWebhook struct { // // * `TRANSITION_REQUEST_TO_ARCHIVED_CREATED`: A user requested a model // version be archived. - Events []types.String `tfsdk:"events" tf:"optional"` + Events types.List `tfsdk:"events" tf:"optional"` - HttpUrlSpec []HttpUrlSpecWithoutSecret `tfsdk:"http_url_spec" tf:"optional,object"` + HttpUrlSpec types.Object `tfsdk:"http_url_spec" tf:"optional,object"` // Webhook ID Id types.String `tfsdk:"id" tf:"optional"` - JobSpec []JobSpecWithoutSecret `tfsdk:"job_spec" tf:"optional,object"` + JobSpec types.Object `tfsdk:"job_spec" tf:"optional,object"` // Time of the object at last update, as a Unix timestamp in milliseconds. LastUpdatedTimestamp types.Int64 `tfsdk:"last_updated_timestamp" tf:"optional"` // Name of the model whose events would trigger this webhook. @@ -1844,6 +2385,14 @@ func (newState *RegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RegistryWebhook) SyncEffectiveFieldsDuringRead(existingState RegistryWebhook) { } +func (a RegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Events": reflect.TypeOf(""), + "HttpUrlSpec": reflect.TypeOf(HttpUrlSpecWithoutSecret{}), + "JobSpec": reflect.TypeOf(JobSpecWithoutSecret{}), + } +} + type RejectTransitionRequest struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1869,9 +2418,13 @@ func (newState *RejectTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *RejectTransitionRequest) SyncEffectiveFieldsDuringRead(existingState RejectTransitionRequest) { } +func (a RejectTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RejectTransitionRequestResponse struct { // Activity recorded for the action. - Activity []Activity `tfsdk:"activity" tf:"optional,object"` + Activity types.Object `tfsdk:"activity" tf:"optional,object"` } func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan RejectTransitionRequestResponse) { @@ -1880,6 +2433,12 @@ func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState RejectTransitionRequestResponse) { } +func (a RejectTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Activity": reflect.TypeOf(Activity{}), + } +} + type RenameModelRequest struct { // Registered model unique name identifier. Name types.String `tfsdk:"name" tf:""` @@ -1893,8 +2452,12 @@ func (newState *RenameModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RenameModelRequest) SyncEffectiveFieldsDuringRead(existingState RenameModelRequest) { } +func (a RenameModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RenameModelResponse struct { - RegisteredModel []Model `tfsdk:"registered_model" tf:"optional,object"` + RegisteredModel types.Object `tfsdk:"registered_model" tf:"optional,object"` } func (newState *RenameModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan RenameModelResponse) { @@ -1903,6 +2466,12 @@ func (newState *RenameModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RenameModelResponse) SyncEffectiveFieldsDuringRead(existingState RenameModelResponse) { } +func (a RenameModelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RegisteredModel": reflect.TypeOf(Model{}), + } +} + type RestoreExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -1914,6 +2483,10 @@ func (newState *RestoreExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RestoreExperiment) SyncEffectiveFieldsDuringRead(existingState RestoreExperiment) { } +func (a RestoreExperiment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestoreExperimentResponse struct { } @@ -1923,6 +2496,10 @@ func (newState *RestoreExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RestoreExperimentResponse) SyncEffectiveFieldsDuringRead(existingState RestoreExperimentResponse) { } +func (a RestoreExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestoreRun struct { // ID of the run to restore. RunId types.String `tfsdk:"run_id" tf:""` @@ -1934,6 +2511,10 @@ func (newState *RestoreRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan Restore func (newState *RestoreRun) SyncEffectiveFieldsDuringRead(existingState RestoreRun) { } +func (a RestoreRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestoreRunResponse struct { } @@ -1943,6 +2524,10 @@ func (newState *RestoreRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RestoreRunResponse) SyncEffectiveFieldsDuringRead(existingState RestoreRunResponse) { } +func (a RestoreRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestoreRuns struct { // The ID of the experiment containing the runs to restore. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -1961,6 +2546,10 @@ func (newState *RestoreRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan Restor func (newState *RestoreRuns) SyncEffectiveFieldsDuringRead(existingState RestoreRuns) { } +func (a RestoreRuns) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestoreRunsResponse struct { // The number of runs restored. RunsRestored types.Int64 `tfsdk:"runs_restored" tf:"optional"` @@ -1972,13 +2561,17 @@ func (newState *RestoreRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RestoreRunsResponse) SyncEffectiveFieldsDuringRead(existingState RestoreRunsResponse) { } +func (a RestoreRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Run struct { // Run data. - Data []RunData `tfsdk:"data" tf:"optional,object"` + Data types.Object `tfsdk:"data" tf:"optional,object"` // Run metadata. - Info []RunInfo `tfsdk:"info" tf:"optional,object"` + Info types.Object `tfsdk:"info" tf:"optional,object"` // Run inputs. - Inputs []RunInputs `tfsdk:"inputs" tf:"optional,object"` + Inputs types.Object `tfsdk:"inputs" tf:"optional,object"` } func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { @@ -1987,13 +2580,21 @@ func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { } +func (a Run) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Data": reflect.TypeOf(RunData{}), + "Info": reflect.TypeOf(RunInfo{}), + "Inputs": reflect.TypeOf(RunInputs{}), + } +} + type RunData struct { // Run metrics. - Metrics []Metric `tfsdk:"metrics" tf:"optional"` + Metrics types.List `tfsdk:"metrics" tf:"optional"` // Run parameters. - Params []Param `tfsdk:"params" tf:"optional"` + Params types.List `tfsdk:"params" tf:"optional"` // Additional metadata key-value pairs. - Tags []RunTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *RunData) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunData) { @@ -2002,6 +2603,14 @@ func (newState *RunData) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunData) { func (newState *RunData) SyncEffectiveFieldsDuringRead(existingState RunData) { } +func (a RunData) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Metrics": reflect.TypeOf(Metric{}), + "Params": reflect.TypeOf(Param{}), + "Tags": reflect.TypeOf(RunTag{}), + } +} + type RunInfo struct { // URI of the directory where artifacts should be uploaded. This can be a // local path (starting with "/"), or a distributed file system (DFS) path, @@ -2035,9 +2644,13 @@ func (newState *RunInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInfo) { func (newState *RunInfo) SyncEffectiveFieldsDuringRead(existingState RunInfo) { } +func (a RunInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RunInputs struct { // Run metrics. - DatasetInputs []DatasetInput `tfsdk:"dataset_inputs" tf:"optional"` + DatasetInputs types.List `tfsdk:"dataset_inputs" tf:"optional"` } func (newState *RunInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInputs) { @@ -2046,6 +2659,12 @@ func (newState *RunInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInput func (newState *RunInputs) SyncEffectiveFieldsDuringRead(existingState RunInputs) { } +func (a RunInputs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DatasetInputs": reflect.TypeOf(DatasetInput{}), + } +} + type RunTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -2059,6 +2678,10 @@ func (newState *RunTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTag) { func (newState *RunTag) SyncEffectiveFieldsDuringRead(existingState RunTag) { } +func (a RunTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SearchExperiments struct { // String representing a SQL filter condition (e.g. "name ILIKE // 'my-experiment%'") @@ -2069,7 +2692,7 @@ type SearchExperiments struct { // name and last updated timestamp with an optional "DESC" or "ASC" // annotation, where "ASC" is the default. Tiebreaks are done by experiment // id DESC. - OrderBy []types.String `tfsdk:"order_by" tf:"optional"` + OrderBy types.List `tfsdk:"order_by" tf:"optional"` // Token indicating the page of experiments to fetch PageToken types.String `tfsdk:"page_token" tf:"optional"` // Qualifier for type of experiments to be returned. If unspecified, return @@ -2083,9 +2706,15 @@ func (newState *SearchExperiments) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SearchExperiments) SyncEffectiveFieldsDuringRead(existingState SearchExperiments) { } +func (a SearchExperiments) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OrderBy": reflect.TypeOf(""), + } +} + type SearchExperimentsResponse struct { // Experiments that match the search criteria - Experiments []Experiment `tfsdk:"experiments" tf:"optional"` + Experiments types.List `tfsdk:"experiments" tf:"optional"` // Token that can be used to retrieve the next page of experiments. An empty // token means that no more experiments are available for retrieval. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -2097,6 +2726,12 @@ func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringRead(existingState SearchExperimentsResponse) { } +func (a SearchExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Experiments": reflect.TypeOf(Experiment{}), + } +} + // Searches model versions type SearchModelVersionsRequest struct { // String filter condition, like "name='my-model-name'". Must be a single @@ -2108,7 +2743,7 @@ type SearchModelVersionsRequest struct { // with an optional "DESC" or "ASC" annotation, where "ASC" is the default. // Tiebreaks are done by latest stage transition timestamp, followed by name // ASC, followed by version DESC. - OrderBy []types.String `tfsdk:"-"` + OrderBy types.List `tfsdk:"-"` // Pagination token to go to next page based on previous search query. PageToken types.String `tfsdk:"-"` } @@ -2119,9 +2754,15 @@ func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringRead(existingState SearchModelVersionsRequest) { } +func (a SearchModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OrderBy": reflect.TypeOf(""), + } +} + type SearchModelVersionsResponse struct { // Models that match the search criteria - ModelVersions []ModelVersion `tfsdk:"model_versions" tf:"optional"` + ModelVersions types.List `tfsdk:"model_versions" tf:"optional"` // Pagination token to request next page of models for the same search // query. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -2133,6 +2774,12 @@ func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringRead(existingState SearchModelVersionsResponse) { } +func (a SearchModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ModelVersions": reflect.TypeOf(ModelVersion{}), + } +} + // Search models type SearchModelsRequest struct { // String filter condition, like "name LIKE 'my-model-name'". Interpreted in @@ -2144,7 +2791,7 @@ type SearchModelsRequest struct { // List of columns for ordering search results, which can include model name // and last updated timestamp with an optional "DESC" or "ASC" annotation, // where "ASC" is the default. Tiebreaks are done by model name ASC. - OrderBy []types.String `tfsdk:"-"` + OrderBy types.List `tfsdk:"-"` // Pagination token to go to the next page based on a previous search query. PageToken types.String `tfsdk:"-"` } @@ -2155,11 +2802,17 @@ func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringRead(existingState SearchModelsRequest) { } +func (a SearchModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OrderBy": reflect.TypeOf(""), + } +} + type SearchModelsResponse struct { // Pagination token to request the next page of models. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // Registered Models that match the search criteria. - RegisteredModels []Model `tfsdk:"registered_models" tf:"optional"` + RegisteredModels types.List `tfsdk:"registered_models" tf:"optional"` } func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan SearchModelsResponse) { @@ -2168,9 +2821,15 @@ func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringRead(existingState SearchModelsResponse) { } +func (a SearchModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RegisteredModels": reflect.TypeOf(Model{}), + } +} + type SearchRuns struct { // List of experiment IDs to search over. - ExperimentIds []types.String `tfsdk:"experiment_ids" tf:"optional"` + ExperimentIds types.List `tfsdk:"experiment_ids" tf:"optional"` // A filter expression over params, metrics, and tags, that allows returning // a subset of runs. The syntax is a subset of SQL that supports ANDing // together binary operations between a param, metric, or tag and a @@ -2192,7 +2851,7 @@ type SearchRuns struct { // "metrics.rmse"] Tiebreaks are done by start_time DESC followed by run_id // for runs with the same start time (and this is the default ordering // criterion if order_by is not provided). - OrderBy []types.String `tfsdk:"order_by" tf:"optional"` + OrderBy types.List `tfsdk:"order_by" tf:"optional"` // Token for the current page of runs. PageToken types.String `tfsdk:"page_token" tf:"optional"` // Whether to display only active, only deleted, or all runs. Defaults to @@ -2206,11 +2865,18 @@ func (newState *SearchRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan SearchR func (newState *SearchRuns) SyncEffectiveFieldsDuringRead(existingState SearchRuns) { } +func (a SearchRuns) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExperimentIds": reflect.TypeOf(""), + "OrderBy": reflect.TypeOf(""), + } +} + type SearchRunsResponse struct { // Token for the next page of runs. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // Runs that match the search criteria. - Runs []Run `tfsdk:"runs" tf:"optional"` + Runs types.List `tfsdk:"runs" tf:"optional"` } func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan SearchRunsResponse) { @@ -2219,6 +2885,12 @@ func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringRead(existingState SearchRunsResponse) { } +func (a SearchRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Runs": reflect.TypeOf(Run{}), + } +} + type SetExperimentTag struct { // ID of the experiment under which to log the tag. Must be provided. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -2237,6 +2909,10 @@ func (newState *SetExperimentTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SetExperimentTag) SyncEffectiveFieldsDuringRead(existingState SetExperimentTag) { } +func (a SetExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetExperimentTagResponse struct { } @@ -2246,6 +2922,10 @@ func (newState *SetExperimentTagResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *SetExperimentTagResponse) SyncEffectiveFieldsDuringRead(existingState SetExperimentTagResponse) { } +func (a SetExperimentTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetModelTagRequest struct { // Name of the tag. Maximum size depends on storage backend. If a tag with // this name already exists, its preexisting value will be replaced by the @@ -2266,6 +2946,10 @@ func (newState *SetModelTagRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SetModelTagRequest) SyncEffectiveFieldsDuringRead(existingState SetModelTagRequest) { } +func (a SetModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetModelTagResponse struct { } @@ -2275,6 +2959,10 @@ func (newState *SetModelTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SetModelTagResponse) SyncEffectiveFieldsDuringRead(existingState SetModelTagResponse) { } +func (a SetModelTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetModelVersionTagRequest struct { // Name of the tag. Maximum size depends on storage backend. If a tag with // this name already exists, its preexisting value will be replaced by the @@ -2297,6 +2985,10 @@ func (newState *SetModelVersionTagRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *SetModelVersionTagRequest) SyncEffectiveFieldsDuringRead(existingState SetModelVersionTagRequest) { } +func (a SetModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetModelVersionTagResponse struct { } @@ -2306,6 +2998,10 @@ func (newState *SetModelVersionTagResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SetModelVersionTagResponse) SyncEffectiveFieldsDuringRead(existingState SetModelVersionTagResponse) { } +func (a SetModelVersionTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetTag struct { // Name of the tag. Maximum size depends on storage backend. All storage // backends are guaranteed to support key values up to 250 bytes in size. @@ -2327,6 +3023,10 @@ func (newState *SetTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetTag) { func (newState *SetTag) SyncEffectiveFieldsDuringRead(existingState SetTag) { } +func (a SetTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetTagResponse struct { } @@ -2336,6 +3036,10 @@ func (newState *SetTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Set func (newState *SetTagResponse) SyncEffectiveFieldsDuringRead(existingState SetTagResponse) { } +func (a SetTagResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Test webhook response object. type TestRegistryWebhook struct { // Body of the response from the webhook URL @@ -2350,6 +3054,10 @@ func (newState *TestRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TestRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhook) { } +func (a TestRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TestRegistryWebhookRequest struct { // If `event` is specified, the test trigger uses the specified event. If // `event` is not specified, the test trigger uses a randomly chosen event @@ -2365,9 +3073,13 @@ func (newState *TestRegistryWebhookRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *TestRegistryWebhookRequest) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhookRequest) { } +func (a TestRegistryWebhookRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TestRegistryWebhookResponse struct { // Test webhook response object. - Webhook []TestRegistryWebhook `tfsdk:"webhook" tf:"optional,object"` + Webhook types.Object `tfsdk:"webhook" tf:"optional,object"` } func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan TestRegistryWebhookResponse) { @@ -2376,6 +3088,12 @@ func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhookResponse) { } +func (a TestRegistryWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Webhook": reflect.TypeOf(TestRegistryWebhook{}), + } +} + type TransitionModelVersionStageDatabricks struct { // Specifies whether to archive all current model versions in the target // stage. @@ -2404,10 +3122,14 @@ func (newState *TransitionModelVersionStageDatabricks) SyncEffectiveFieldsDuring func (newState *TransitionModelVersionStageDatabricks) SyncEffectiveFieldsDuringRead(existingState TransitionModelVersionStageDatabricks) { } +func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Transition request details. type TransitionRequest struct { // Array of actions on the activity allowed for the current viewer. - AvailableActions []types.String `tfsdk:"available_actions" tf:"optional"` + AvailableActions types.List `tfsdk:"available_actions" tf:"optional"` // User-provided comment associated with the transition request. Comment types.String `tfsdk:"comment" tf:"optional"` // Creation time of the object, as a Unix timestamp in milliseconds. @@ -2433,8 +3155,14 @@ func (newState *TransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TransitionRequest) SyncEffectiveFieldsDuringRead(existingState TransitionRequest) { } +func (a TransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AvailableActions": reflect.TypeOf(""), + } +} + type TransitionStageResponse struct { - ModelVersion []ModelVersionDatabricks `tfsdk:"model_version" tf:"optional,object"` + ModelVersion types.Object `tfsdk:"model_version" tf:"optional,object"` } func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan TransitionStageResponse) { @@ -2443,6 +3171,12 @@ func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringRead(existingState TransitionStageResponse) { } +func (a TransitionStageResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ModelVersion": reflect.TypeOf(ModelVersionDatabricks{}), + } +} + type UpdateComment struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:""` @@ -2456,9 +3190,13 @@ func (newState *UpdateComment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateComment) SyncEffectiveFieldsDuringRead(existingState UpdateComment) { } +func (a UpdateComment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateCommentResponse struct { // Comment details. - Comment []CommentObject `tfsdk:"comment" tf:"optional,object"` + Comment types.Object `tfsdk:"comment" tf:"optional,object"` } func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCommentResponse) { @@ -2467,6 +3205,12 @@ func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateCommentResponse) { } +func (a UpdateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Comment": reflect.TypeOf(CommentObject{}), + } +} + type UpdateExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -2481,6 +3225,10 @@ func (newState *UpdateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateExperiment) SyncEffectiveFieldsDuringRead(existingState UpdateExperiment) { } +func (a UpdateExperiment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateExperimentResponse struct { } @@ -2490,6 +3238,10 @@ func (newState *UpdateExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateExperimentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExperimentResponse) { } +func (a UpdateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateModelRequest struct { // If provided, updates the description for this `registered_model`. Description types.String `tfsdk:"description" tf:"optional"` @@ -2503,6 +3255,10 @@ func (newState *UpdateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateModelRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelRequest) { } +func (a UpdateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateModelResponse struct { } @@ -2512,6 +3268,10 @@ func (newState *UpdateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *UpdateModelResponse) SyncEffectiveFieldsDuringRead(existingState UpdateModelResponse) { } +func (a UpdateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateModelVersionRequest struct { // If provided, updates the description for this `registered_model`. Description types.String `tfsdk:"description" tf:"optional"` @@ -2527,6 +3287,10 @@ func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionRequest) { } +func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateModelVersionResponse struct { } @@ -2536,6 +3300,10 @@ func (newState *UpdateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionResponse) { } +func (a UpdateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateRegistryWebhook struct { // User-specified description for the webhook. Description types.String `tfsdk:"description" tf:"optional"` @@ -2572,13 +3340,13 @@ type UpdateRegistryWebhook struct { // // * `TRANSITION_REQUEST_TO_ARCHIVED_CREATED`: A user requested a model // version be archived. - Events []types.String `tfsdk:"events" tf:"optional"` + Events types.List `tfsdk:"events" tf:"optional"` - HttpUrlSpec []HttpUrlSpec `tfsdk:"http_url_spec" tf:"optional,object"` + HttpUrlSpec types.Object `tfsdk:"http_url_spec" tf:"optional,object"` // Webhook ID Id types.String `tfsdk:"id" tf:""` - JobSpec []JobSpec `tfsdk:"job_spec" tf:"optional,object"` + JobSpec types.Object `tfsdk:"job_spec" tf:"optional,object"` // Enable or disable triggering the webhook, or put the webhook into test // mode. The default is `ACTIVE`: * `ACTIVE`: Webhook is triggered when an // associated event happens. @@ -2596,6 +3364,14 @@ func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState UpdateRegistryWebhook) { } +func (a UpdateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Events": reflect.TypeOf(""), + "HttpUrlSpec": reflect.TypeOf(HttpUrlSpec{}), + "JobSpec": reflect.TypeOf(JobSpec{}), + } +} + type UpdateRun struct { // Unix timestamp in milliseconds of when the run ended. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -2614,9 +3390,13 @@ func (newState *UpdateRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRu func (newState *UpdateRun) SyncEffectiveFieldsDuringRead(existingState UpdateRun) { } +func (a UpdateRun) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateRunResponse struct { // Updated metadata of the run. - RunInfo []RunInfo `tfsdk:"run_info" tf:"optional,object"` + RunInfo types.Object `tfsdk:"run_info" tf:"optional,object"` } func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRunResponse) { @@ -2625,6 +3405,12 @@ func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringRead(existingState UpdateRunResponse) { } +func (a UpdateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RunInfo": reflect.TypeOf(RunInfo{}), + } +} + type UpdateWebhookResponse struct { } @@ -2633,3 +3419,7 @@ func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringRead(existingState UpdateWebhookResponse) { } + +func (a UpdateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 537a30b386..b201a6749b 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package oauth2_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -21,12 +23,12 @@ type CreateCustomAppIntegration struct { // Name of the custom OAuth app Name types.String `tfsdk:"name" tf:"optional"` // List of OAuth redirect urls - RedirectUrls []types.String `tfsdk:"redirect_urls" tf:"optional"` + RedirectUrls types.List `tfsdk:"redirect_urls" tf:"optional"` // OAuth scopes granted to the application. Supported scopes: all-apis, sql, // offline_access, openid, profile, email. - Scopes []types.String `tfsdk:"scopes" tf:"optional"` + Scopes types.List `tfsdk:"scopes" tf:"optional"` // Token access policy - TokenAccessPolicy []TokenAccessPolicy `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCustomAppIntegration) { @@ -35,6 +37,14 @@ func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existingState CreateCustomAppIntegration) { } +func (a CreateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RedirectUrls": reflect.TypeOf(""), + "Scopes": reflect.TypeOf(""), + "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + } +} + type CreateCustomAppIntegrationOutput struct { // OAuth client-id generated by the Databricks ClientId types.String `tfsdk:"client_id" tf:"optional"` @@ -51,12 +61,16 @@ func (newState *CreateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *CreateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState CreateCustomAppIntegrationOutput) { } +func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreatePublishedAppIntegration struct { // App id of the OAuth published app integration. For example power-bi, // tableau-deskop AppId types.String `tfsdk:"app_id" tf:"optional"` // Token access policy - TokenAccessPolicy []TokenAccessPolicy `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreatePublishedAppIntegration) { @@ -65,6 +79,12 @@ func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOr func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(existingState CreatePublishedAppIntegration) { } +func (a CreatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + } +} + type CreatePublishedAppIntegrationOutput struct { // Unique integration id for the published OAuth app IntegrationId types.String `tfsdk:"integration_id" tf:"optional"` @@ -76,6 +96,10 @@ func (newState *CreatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *CreatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState CreatePublishedAppIntegrationOutput) { } +func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Create service principal secret type CreateServicePrincipalSecretRequest struct { // The service principal ID. @@ -88,6 +112,10 @@ func (newState *CreateServicePrincipalSecretRequest) SyncEffectiveFieldsDuringCr func (newState *CreateServicePrincipalSecretRequest) SyncEffectiveFieldsDuringRead(existingState CreateServicePrincipalSecretRequest) { } +func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateServicePrincipalSecretResponse struct { // UTC time when the secret was created CreateTime types.String `tfsdk:"create_time" tf:"optional"` @@ -109,6 +137,10 @@ func (newState *CreateServicePrincipalSecretResponse) SyncEffectiveFieldsDuringC func (newState *CreateServicePrincipalSecretResponse) SyncEffectiveFieldsDuringRead(existingState CreateServicePrincipalSecretResponse) { } +func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DataPlaneInfo struct { // Authorization details as a string. AuthorizationDetails types.String `tfsdk:"authorization_details" tf:"optional"` @@ -122,6 +154,10 @@ func (newState *DataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Data func (newState *DataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState DataPlaneInfo) { } +func (a DataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteCustomAppIntegrationOutput struct { } @@ -131,6 +167,10 @@ func (newState *DeleteCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *DeleteCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState DeleteCustomAppIntegrationOutput) { } +func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete Custom OAuth App Integration type DeleteCustomAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -142,6 +182,10 @@ func (newState *DeleteCustomAppIntegrationRequest) SyncEffectiveFieldsDuringCrea func (newState *DeleteCustomAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCustomAppIntegrationRequest) { } +func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeletePublishedAppIntegrationOutput struct { } @@ -151,6 +195,10 @@ func (newState *DeletePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *DeletePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState DeletePublishedAppIntegrationOutput) { } +func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete Published OAuth App Integration type DeletePublishedAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -162,6 +210,10 @@ func (newState *DeletePublishedAppIntegrationRequest) SyncEffectiveFieldsDuringC func (newState *DeletePublishedAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState DeletePublishedAppIntegrationRequest) { } +func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -171,6 +223,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete service principal secret type DeleteServicePrincipalSecretRequest struct { // The secret ID. @@ -185,6 +241,10 @@ func (newState *DeleteServicePrincipalSecretRequest) SyncEffectiveFieldsDuringCr func (newState *DeleteServicePrincipalSecretRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServicePrincipalSecretRequest) { } +func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetCustomAppIntegrationOutput struct { // The client id of the custom OAuth app ClientId types.String `tfsdk:"client_id" tf:"optional"` @@ -202,11 +262,11 @@ type GetCustomAppIntegrationOutput struct { // The display name of the custom OAuth app Name types.String `tfsdk:"name" tf:"optional"` // List of OAuth redirect urls - RedirectUrls []types.String `tfsdk:"redirect_urls" tf:"optional"` + RedirectUrls types.List `tfsdk:"redirect_urls" tf:"optional"` - Scopes []types.String `tfsdk:"scopes" tf:"optional"` + Scopes types.List `tfsdk:"scopes" tf:"optional"` // Token access policy - TokenAccessPolicy []TokenAccessPolicy `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetCustomAppIntegrationOutput) { @@ -215,6 +275,14 @@ func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOr func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationOutput) { } +func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RedirectUrls": reflect.TypeOf(""), + "Scopes": reflect.TypeOf(""), + "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + } +} + // Get OAuth Custom App Integration type GetCustomAppIntegrationRequest struct { // The OAuth app integration ID. @@ -227,9 +295,13 @@ func (newState *GetCustomAppIntegrationRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetCustomAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationRequest) { } +func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetCustomAppIntegrationsOutput struct { // List of Custom OAuth App Integrations defined for the account. - Apps []GetCustomAppIntegrationOutput `tfsdk:"apps" tf:"optional"` + Apps types.List `tfsdk:"apps" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -240,6 +312,12 @@ func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringCreateO func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationsOutput) { } +func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Apps": reflect.TypeOf(GetCustomAppIntegrationOutput{}), + } +} + type GetPublishedAppIntegrationOutput struct { // App-id of the published app integration AppId types.String `tfsdk:"app_id" tf:"optional"` @@ -252,7 +330,7 @@ type GetPublishedAppIntegrationOutput struct { // Display name of the published OAuth app Name types.String `tfsdk:"name" tf:"optional"` // Token access policy - TokenAccessPolicy []TokenAccessPolicy `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPublishedAppIntegrationOutput) { @@ -261,6 +339,12 @@ func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationOutput) { } +func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + } +} + // Get OAuth Published App Integration type GetPublishedAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -272,9 +356,13 @@ func (newState *GetPublishedAppIntegrationRequest) SyncEffectiveFieldsDuringCrea func (newState *GetPublishedAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationRequest) { } +func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPublishedAppIntegrationsOutput struct { // List of Published OAuth App Integrations defined for the account. - Apps []GetPublishedAppIntegrationOutput `tfsdk:"apps" tf:"optional"` + Apps types.List `tfsdk:"apps" tf:"optional"` NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` } @@ -285,9 +373,15 @@ func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringCrea func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationsOutput) { } +func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Apps": reflect.TypeOf(GetPublishedAppIntegrationOutput{}), + } +} + type GetPublishedAppsOutput struct { // List of Published OAuth Apps. - Apps []PublishedAppOutput `tfsdk:"apps" tf:"optional"` + Apps types.List `tfsdk:"apps" tf:"optional"` // A token that can be used to get the next page of results. If not present, // there are no more results to show. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -299,6 +393,12 @@ func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppsOutput) { } +func (a GetPublishedAppsOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Apps": reflect.TypeOf(PublishedAppOutput{}), + } +} + // Get custom oauth app integrations type ListCustomAppIntegrationsRequest struct { IncludeCreatorUsername types.Bool `tfsdk:"-"` @@ -314,6 +414,10 @@ func (newState *ListCustomAppIntegrationsRequest) SyncEffectiveFieldsDuringCreat func (newState *ListCustomAppIntegrationsRequest) SyncEffectiveFieldsDuringRead(existingState ListCustomAppIntegrationsRequest) { } +func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get all the published OAuth apps type ListOAuthPublishedAppsRequest struct { // The max number of OAuth published apps to return in one page. @@ -328,6 +432,10 @@ func (newState *ListOAuthPublishedAppsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListOAuthPublishedAppsRequest) SyncEffectiveFieldsDuringRead(existingState ListOAuthPublishedAppsRequest) { } +func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get published oauth app integrations type ListPublishedAppIntegrationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -341,6 +449,10 @@ func (newState *ListPublishedAppIntegrationsRequest) SyncEffectiveFieldsDuringCr func (newState *ListPublishedAppIntegrationsRequest) SyncEffectiveFieldsDuringRead(existingState ListPublishedAppIntegrationsRequest) { } +func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List service principal secrets type ListServicePrincipalSecretsRequest struct { // An opaque page token which was the `next_page_token` in the response of @@ -363,11 +475,15 @@ func (newState *ListServicePrincipalSecretsRequest) SyncEffectiveFieldsDuringCre func (newState *ListServicePrincipalSecretsRequest) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalSecretsRequest) { } +func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListServicePrincipalSecretsResponse struct { // A token, which can be sent as `page_token` to retrieve the next page. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // List of the secrets - Secrets []SecretInfo `tfsdk:"secrets" tf:"optional"` + Secrets types.List `tfsdk:"secrets" tf:"optional"` } func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListServicePrincipalSecretsResponse) { @@ -376,6 +492,12 @@ func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringCr func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalSecretsResponse) { } +func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Secrets": reflect.TypeOf(SecretInfo{}), + } +} + type PublishedAppOutput struct { // Unique ID of the published OAuth app. AppId types.String `tfsdk:"app_id" tf:"optional"` @@ -390,9 +512,9 @@ type PublishedAppOutput struct { // The display name of the published OAuth app. Name types.String `tfsdk:"name" tf:"optional"` // Redirect URLs of the published OAuth app. - RedirectUrls []types.String `tfsdk:"redirect_urls" tf:"optional"` + RedirectUrls types.List `tfsdk:"redirect_urls" tf:"optional"` // Required scopes for the published OAuth app. - Scopes []types.String `tfsdk:"scopes" tf:"optional"` + Scopes types.List `tfsdk:"scopes" tf:"optional"` } func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan PublishedAppOutput) { @@ -401,6 +523,13 @@ func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringRead(existingState PublishedAppOutput) { } +func (a PublishedAppOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RedirectUrls": reflect.TypeOf(""), + "Scopes": reflect.TypeOf(""), + } +} + type SecretInfo struct { // UTC time when the secret was created CreateTime types.String `tfsdk:"create_time" tf:"optional"` @@ -420,6 +549,10 @@ func (newState *SecretInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan SecretI func (newState *SecretInfo) SyncEffectiveFieldsDuringRead(existingState SecretInfo) { } +func (a SecretInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenAccessPolicy struct { // access token time to live in minutes AccessTokenTtlInMinutes types.Int64 `tfsdk:"access_token_ttl_in_minutes" tf:"optional"` @@ -433,13 +566,17 @@ func (newState *TokenAccessPolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TokenAccessPolicy) SyncEffectiveFieldsDuringRead(existingState TokenAccessPolicy) { } +func (a TokenAccessPolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateCustomAppIntegration struct { IntegrationId types.String `tfsdk:"-"` // List of OAuth redirect urls to be updated in the custom OAuth app // integration - RedirectUrls []types.String `tfsdk:"redirect_urls" tf:"optional"` + RedirectUrls types.List `tfsdk:"redirect_urls" tf:"optional"` // Token access policy to be updated in the custom OAuth app integration - TokenAccessPolicy []TokenAccessPolicy `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCustomAppIntegration) { @@ -448,6 +585,13 @@ func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existingState UpdateCustomAppIntegration) { } +func (a UpdateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RedirectUrls": reflect.TypeOf(""), + "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + } +} + type UpdateCustomAppIntegrationOutput struct { } @@ -457,10 +601,14 @@ func (newState *UpdateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *UpdateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState UpdateCustomAppIntegrationOutput) { } +func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdatePublishedAppIntegration struct { IntegrationId types.String `tfsdk:"-"` // Token access policy to be updated in the published OAuth app integration - TokenAccessPolicy []TokenAccessPolicy `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdatePublishedAppIntegration) { @@ -469,6 +617,12 @@ func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOr func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(existingState UpdatePublishedAppIntegration) { } +func (a UpdatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + } +} + type UpdatePublishedAppIntegrationOutput struct { } @@ -477,3 +631,7 @@ func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState UpdatePublishedAppIntegrationOutput) { } + +func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 56f0b9d192..876e969be4 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package pipelines_tf import ( + "reflect" + "github.com/databricks/databricks-sdk-go/service/compute" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -30,13 +32,13 @@ type CreatePipeline struct { // DLT Release Channel that specifies which version to use. Channel types.String `tfsdk:"channel" tf:"optional"` // Cluster settings for this pipeline deployment. - Clusters []PipelineCluster `tfsdk:"clusters" tf:"optional"` + Clusters types.List `tfsdk:"clusters" tf:"optional"` // String-String configuration for this pipeline execution. - Configuration map[string]types.String `tfsdk:"configuration" tf:"optional"` + Configuration types.Map `tfsdk:"configuration" tf:"optional"` // Whether the pipeline is continuous or triggered. This replaces `trigger`. Continuous types.Bool `tfsdk:"continuous" tf:"optional"` // Deployment type of this pipeline. - Deployment []PipelineDeployment `tfsdk:"deployment" tf:"optional,object"` + Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` // Whether the pipeline is in Development mode. Defaults to false. Development types.Bool `tfsdk:"development" tf:"optional"` @@ -44,24 +46,24 @@ type CreatePipeline struct { // Pipeline product edition. Edition types.String `tfsdk:"edition" tf:"optional"` // Filters on which Pipeline packages to include in the deployed graph. - Filters []Filters `tfsdk:"filters" tf:"optional,object"` + Filters types.Object `tfsdk:"filters" tf:"optional,object"` // The definition of a gateway pipeline to support change data capture. - GatewayDefinition []IngestionGatewayPipelineDefinition `tfsdk:"gateway_definition" tf:"optional,object"` + GatewayDefinition types.Object `tfsdk:"gateway_definition" tf:"optional,object"` // Unique identifier for this pipeline. Id types.String `tfsdk:"id" tf:"optional"` // The configuration for a managed ingestion pipeline. These settings cannot // be used with the 'libraries', 'target' or 'catalog' settings. - IngestionDefinition []IngestionPipelineDefinition `tfsdk:"ingestion_definition" tf:"optional,object"` + IngestionDefinition types.Object `tfsdk:"ingestion_definition" tf:"optional,object"` // Libraries or code needed by this deployment. - Libraries []PipelineLibrary `tfsdk:"libraries" tf:"optional"` + Libraries types.List `tfsdk:"libraries" tf:"optional"` // Friendly identifier for this pipeline. Name types.String `tfsdk:"name" tf:"optional"` // List of notification settings for this pipeline. - Notifications []Notifications `tfsdk:"notifications" tf:"optional"` + Notifications types.List `tfsdk:"notifications" tf:"optional"` // Whether Photon is enabled for this pipeline. Photon types.Bool `tfsdk:"photon" tf:"optional"` // Restart window of this pipeline. - RestartWindow []RestartWindow `tfsdk:"restart_window" tf:"optional,object"` + RestartWindow types.Object `tfsdk:"restart_window" tf:"optional,object"` // The default schema (database) where tables are read from or published to. // The presence of this field implies that the pipeline is in direct // publishing mode. @@ -75,7 +77,7 @@ type CreatePipeline struct { // To publish to Unity Catalog, also specify `catalog`. Target types.String `tfsdk:"target" tf:"optional"` // Which pipeline trigger to use. Deprecated: Use `continuous` instead. - Trigger []PipelineTrigger `tfsdk:"trigger" tf:"optional,object"` + Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` } func (newState *CreatePipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreatePipeline) { @@ -84,9 +86,24 @@ func (newState *CreatePipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreatePipeline) SyncEffectiveFieldsDuringRead(existingState CreatePipeline) { } +func (a CreatePipeline) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Clusters": reflect.TypeOf(PipelineCluster{}), + "Configuration": reflect.TypeOf(""), + "Deployment": reflect.TypeOf(PipelineDeployment{}), + "Filters": reflect.TypeOf(Filters{}), + "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), + "IngestionDefinition": reflect.TypeOf(IngestionPipelineDefinition{}), + "Libraries": reflect.TypeOf(PipelineLibrary{}), + "Notifications": reflect.TypeOf(Notifications{}), + "RestartWindow": reflect.TypeOf(RestartWindow{}), + "Trigger": reflect.TypeOf(PipelineTrigger{}), + } +} + type CreatePipelineResponse struct { // Only returned when dry_run is true. - EffectiveSettings []PipelineSpec `tfsdk:"effective_settings" tf:"optional,object"` + EffectiveSettings types.Object `tfsdk:"effective_settings" tf:"optional,object"` // The unique identifier for the newly created pipeline. Only returned when // dry_run is false. PipelineId types.String `tfsdk:"pipeline_id" tf:"optional"` @@ -98,6 +115,12 @@ func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringRead(existingState CreatePipelineResponse) { } +func (a CreatePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EffectiveSettings": reflect.TypeOf(PipelineSpec{}), + } +} + type CronTrigger struct { QuartzCronSchedule types.String `tfsdk:"quartz_cron_schedule" tf:"optional"` @@ -110,6 +133,10 @@ func (newState *CronTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronTr func (newState *CronTrigger) SyncEffectiveFieldsDuringRead(existingState CronTrigger) { } +func (a CronTrigger) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DataPlaneId struct { // The instance name of the data plane emitting an event. Instance types.String `tfsdk:"instance" tf:"optional"` @@ -123,6 +150,10 @@ func (newState *DataPlaneId) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataPl func (newState *DataPlaneId) SyncEffectiveFieldsDuringRead(existingState DataPlaneId) { } +func (a DataPlaneId) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a pipeline type DeletePipelineRequest struct { PipelineId types.String `tfsdk:"-"` @@ -134,6 +165,10 @@ func (newState *DeletePipelineRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeletePipelineRequest) SyncEffectiveFieldsDuringRead(existingState DeletePipelineRequest) { } +func (a DeletePipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeletePipelineResponse struct { } @@ -143,6 +178,10 @@ func (newState *DeletePipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeletePipelineResponse) SyncEffectiveFieldsDuringRead(existingState DeletePipelineResponse) { } +func (a DeletePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EditPipeline struct { // If false, deployment will fail if name has changed and conflicts the name // of another pipeline. @@ -158,13 +197,13 @@ type EditPipeline struct { // DLT Release Channel that specifies which version to use. Channel types.String `tfsdk:"channel" tf:"optional"` // Cluster settings for this pipeline deployment. - Clusters []PipelineCluster `tfsdk:"clusters" tf:"optional"` + Clusters types.List `tfsdk:"clusters" tf:"optional"` // String-String configuration for this pipeline execution. - Configuration map[string]types.String `tfsdk:"configuration" tf:"optional"` + Configuration types.Map `tfsdk:"configuration" tf:"optional"` // Whether the pipeline is continuous or triggered. This replaces `trigger`. Continuous types.Bool `tfsdk:"continuous" tf:"optional"` // Deployment type of this pipeline. - Deployment []PipelineDeployment `tfsdk:"deployment" tf:"optional,object"` + Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` // Whether the pipeline is in Development mode. Defaults to false. Development types.Bool `tfsdk:"development" tf:"optional"` // Pipeline product edition. @@ -174,26 +213,26 @@ type EditPipeline struct { // will fail with a conflict. ExpectedLastModified types.Int64 `tfsdk:"expected_last_modified" tf:"optional"` // Filters on which Pipeline packages to include in the deployed graph. - Filters []Filters `tfsdk:"filters" tf:"optional,object"` + Filters types.Object `tfsdk:"filters" tf:"optional,object"` // The definition of a gateway pipeline to support change data capture. - GatewayDefinition []IngestionGatewayPipelineDefinition `tfsdk:"gateway_definition" tf:"optional,object"` + GatewayDefinition types.Object `tfsdk:"gateway_definition" tf:"optional,object"` // Unique identifier for this pipeline. Id types.String `tfsdk:"id" tf:"optional"` // The configuration for a managed ingestion pipeline. These settings cannot // be used with the 'libraries', 'target' or 'catalog' settings. - IngestionDefinition []IngestionPipelineDefinition `tfsdk:"ingestion_definition" tf:"optional,object"` + IngestionDefinition types.Object `tfsdk:"ingestion_definition" tf:"optional,object"` // Libraries or code needed by this deployment. - Libraries []PipelineLibrary `tfsdk:"libraries" tf:"optional"` + Libraries types.List `tfsdk:"libraries" tf:"optional"` // Friendly identifier for this pipeline. Name types.String `tfsdk:"name" tf:"optional"` // List of notification settings for this pipeline. - Notifications []Notifications `tfsdk:"notifications" tf:"optional"` + Notifications types.List `tfsdk:"notifications" tf:"optional"` // Whether Photon is enabled for this pipeline. Photon types.Bool `tfsdk:"photon" tf:"optional"` // Unique identifier for this pipeline. PipelineId types.String `tfsdk:"pipeline_id" tf:"optional"` // Restart window of this pipeline. - RestartWindow []RestartWindow `tfsdk:"restart_window" tf:"optional,object"` + RestartWindow types.Object `tfsdk:"restart_window" tf:"optional,object"` // The default schema (database) where tables are read from or published to. // The presence of this field implies that the pipeline is in direct // publishing mode. @@ -207,7 +246,7 @@ type EditPipeline struct { // To publish to Unity Catalog, also specify `catalog`. Target types.String `tfsdk:"target" tf:"optional"` // Which pipeline trigger to use. Deprecated: Use `continuous` instead. - Trigger []PipelineTrigger `tfsdk:"trigger" tf:"optional,object"` + Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` } func (newState *EditPipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditPipeline) { @@ -216,6 +255,21 @@ func (newState *EditPipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditP func (newState *EditPipeline) SyncEffectiveFieldsDuringRead(existingState EditPipeline) { } +func (a EditPipeline) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Clusters": reflect.TypeOf(PipelineCluster{}), + "Configuration": reflect.TypeOf(""), + "Deployment": reflect.TypeOf(PipelineDeployment{}), + "Filters": reflect.TypeOf(Filters{}), + "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), + "IngestionDefinition": reflect.TypeOf(IngestionPipelineDefinition{}), + "Libraries": reflect.TypeOf(PipelineLibrary{}), + "Notifications": reflect.TypeOf(Notifications{}), + "RestartWindow": reflect.TypeOf(RestartWindow{}), + "Trigger": reflect.TypeOf(PipelineTrigger{}), + } +} + type EditPipelineResponse struct { } @@ -225,9 +279,13 @@ func (newState *EditPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EditPipelineResponse) SyncEffectiveFieldsDuringRead(existingState EditPipelineResponse) { } +func (a EditPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ErrorDetail struct { // The exception thrown for this error, with its chain of cause. - Exceptions []SerializedException `tfsdk:"exceptions" tf:"optional"` + Exceptions types.List `tfsdk:"exceptions" tf:"optional"` // Whether this error is considered fatal, that is, unrecoverable. Fatal types.Bool `tfsdk:"fatal" tf:"optional"` } @@ -238,6 +296,12 @@ func (newState *ErrorDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan ErrorD func (newState *ErrorDetail) SyncEffectiveFieldsDuringRead(existingState ErrorDetail) { } +func (a ErrorDetail) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exceptions": reflect.TypeOf(SerializedException{}), + } +} + type FileLibrary struct { // The absolute path of the file. Path types.String `tfsdk:"path" tf:"optional"` @@ -249,11 +313,15 @@ func (newState *FileLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileLi func (newState *FileLibrary) SyncEffectiveFieldsDuringRead(existingState FileLibrary) { } +func (a FileLibrary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Filters struct { // Paths to exclude. - Exclude []types.String `tfsdk:"exclude" tf:"optional"` + Exclude types.List `tfsdk:"exclude" tf:"optional"` // Paths to include. - Include []types.String `tfsdk:"include" tf:"optional"` + Include types.List `tfsdk:"include" tf:"optional"` } func (newState *Filters) SyncEffectiveFieldsDuringCreateOrUpdate(plan Filters) { @@ -262,6 +330,13 @@ func (newState *Filters) SyncEffectiveFieldsDuringCreateOrUpdate(plan Filters) { func (newState *Filters) SyncEffectiveFieldsDuringRead(existingState Filters) { } +func (a Filters) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Exclude": reflect.TypeOf(""), + "Include": reflect.TypeOf(""), + } +} + // Get pipeline permission levels type GetPipelinePermissionLevelsRequest struct { // The pipeline for which to get or manage permissions. @@ -274,9 +349,13 @@ func (newState *GetPipelinePermissionLevelsRequest) SyncEffectiveFieldsDuringCre func (newState *GetPipelinePermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionLevelsRequest) { } +func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPipelinePermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []PipelinePermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPipelinePermissionLevelsResponse) { @@ -285,6 +364,12 @@ func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringCr func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionLevelsResponse) { } +func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(PipelinePermissionsDescription{}), + } +} + // Get pipeline permissions type GetPipelinePermissionsRequest struct { // The pipeline for which to get or manage permissions. @@ -297,6 +382,10 @@ func (newState *GetPipelinePermissionsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetPipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionsRequest) { } +func (a GetPipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a pipeline type GetPipelineRequest struct { PipelineId types.String `tfsdk:"-"` @@ -308,6 +397,10 @@ func (newState *GetPipelineRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetPipelineRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelineRequest) { } +func (a GetPipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetPipelineResponse struct { // An optional message detailing the cause of the pipeline state. Cause types.String `tfsdk:"cause" tf:"optional"` @@ -323,7 +416,7 @@ type GetPipelineResponse struct { LastModified types.Int64 `tfsdk:"last_modified" tf:"optional"` // Status of the latest updates for the pipeline. Ordered with the newest // update first. - LatestUpdates []UpdateStateInfo `tfsdk:"latest_updates" tf:"optional"` + LatestUpdates types.List `tfsdk:"latest_updates" tf:"optional"` // A human friendly identifier for the pipeline, taken from the `spec`. Name types.String `tfsdk:"name" tf:"optional"` // The ID of the pipeline. @@ -332,7 +425,7 @@ type GetPipelineResponse struct { RunAsUserName types.String `tfsdk:"run_as_user_name" tf:"optional"` // The pipeline specification. This field is not returned when called by // `ListPipelines`. - Spec []PipelineSpec `tfsdk:"spec" tf:"optional,object"` + Spec types.Object `tfsdk:"spec" tf:"optional,object"` // The pipeline state. State types.String `tfsdk:"state" tf:"optional"` } @@ -343,6 +436,13 @@ func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringRead(existingState GetPipelineResponse) { } +func (a GetPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LatestUpdates": reflect.TypeOf(UpdateStateInfo{}), + "Spec": reflect.TypeOf(PipelineSpec{}), + } +} + // Get a pipeline update type GetUpdateRequest struct { // The ID of the pipeline. @@ -357,9 +457,13 @@ func (newState *GetUpdateRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetUpdateRequest) SyncEffectiveFieldsDuringRead(existingState GetUpdateRequest) { } +func (a GetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetUpdateResponse struct { // The current update info. - Update []UpdateInfo `tfsdk:"update" tf:"optional,object"` + Update types.Object `tfsdk:"update" tf:"optional,object"` } func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetUpdateResponse) { @@ -368,13 +472,19 @@ func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringRead(existingState GetUpdateResponse) { } +func (a GetUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Update": reflect.TypeOf(UpdateInfo{}), + } +} + type IngestionConfig struct { // Select a specific source report. - Report []ReportSpec `tfsdk:"report" tf:"optional,object"` + Report types.Object `tfsdk:"report" tf:"optional,object"` // Select all tables from a specific source schema. - Schema []SchemaSpec `tfsdk:"schema" tf:"optional,object"` + Schema types.Object `tfsdk:"schema" tf:"optional,object"` // Select a specific source table. - Table []TableSpec `tfsdk:"table" tf:"optional,object"` + Table types.Object `tfsdk:"table" tf:"optional,object"` } func (newState *IngestionConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan IngestionConfig) { @@ -383,6 +493,14 @@ func (newState *IngestionConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan In func (newState *IngestionConfig) SyncEffectiveFieldsDuringRead(existingState IngestionConfig) { } +func (a IngestionConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Report": reflect.TypeOf(ReportSpec{}), + "Schema": reflect.TypeOf(SchemaSpec{}), + "Table": reflect.TypeOf(TableSpec{}), + } +} + type IngestionGatewayPipelineDefinition struct { // [Deprecated, use connection_name instead] Immutable. The Unity Catalog // connection that this gateway pipeline uses to communicate with the @@ -410,6 +528,10 @@ func (newState *IngestionGatewayPipelineDefinition) SyncEffectiveFieldsDuringCre func (newState *IngestionGatewayPipelineDefinition) SyncEffectiveFieldsDuringRead(existingState IngestionGatewayPipelineDefinition) { } +func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type IngestionPipelineDefinition struct { // Immutable. The Unity Catalog connection that this ingestion pipeline uses // to communicate with the source. This is used with connectors for @@ -421,10 +543,10 @@ type IngestionPipelineDefinition struct { IngestionGatewayId types.String `tfsdk:"ingestion_gateway_id" tf:"optional"` // Required. Settings specifying tables to replicate and the destination for // the replicated tables. - Objects []IngestionConfig `tfsdk:"objects" tf:"optional"` + Objects types.List `tfsdk:"objects" tf:"optional"` // Configuration settings to control the ingestion of tables. These settings // are applied to all tables in the pipeline. - TableConfiguration []TableSpecificConfig `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringCreateOrUpdate(plan IngestionPipelineDefinition) { @@ -433,6 +555,13 @@ func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringCreateOrUp func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringRead(existingState IngestionPipelineDefinition) { } +func (a IngestionPipelineDefinition) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Objects": reflect.TypeOf(IngestionConfig{}), + "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + } +} + // List pipeline events type ListPipelineEventsRequest struct { // Criteria to select a subset of results, expressed using a SQL-like @@ -451,7 +580,7 @@ type ListPipelineEventsRequest struct { // example, ["timestamp asc"]. The sort order can be ascending or // descending. By default, events are returned in descending order by // timestamp. - OrderBy []types.String `tfsdk:"-"` + OrderBy types.List `tfsdk:"-"` // Page token returned by previous call. This field is mutually exclusive // with all fields in this request except max_results. An error is returned // if any fields other than max_results are set when this field is set. @@ -466,9 +595,15 @@ func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringRead(existingState ListPipelineEventsRequest) { } +func (a ListPipelineEventsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OrderBy": reflect.TypeOf(""), + } +} + type ListPipelineEventsResponse struct { // The list of events matching the request criteria. - Events []PipelineEvent `tfsdk:"events" tf:"optional"` + Events types.List `tfsdk:"events" tf:"optional"` // If present, a token to fetch the next page of events. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // If present, a token to fetch the previous page of events. @@ -481,6 +616,12 @@ func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringRead(existingState ListPipelineEventsResponse) { } +func (a ListPipelineEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Events": reflect.TypeOf(PipelineEvent{}), + } +} + // List pipelines type ListPipelinesRequest struct { // Select a subset of results based on the specified criteria. The supported @@ -501,7 +642,7 @@ type ListPipelinesRequest struct { MaxResults types.Int64 `tfsdk:"-"` // A list of strings specifying the order of results. Supported order_by // fields are id and name. The default is id asc. This field is optional. - OrderBy []types.String `tfsdk:"-"` + OrderBy types.List `tfsdk:"-"` // Page token returned by previous call PageToken types.String `tfsdk:"-"` } @@ -512,11 +653,17 @@ func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringRead(existingState ListPipelinesRequest) { } +func (a ListPipelinesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "OrderBy": reflect.TypeOf(""), + } +} + type ListPipelinesResponse struct { // If present, a token to fetch the next page of events. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // The list of events matching the request criteria. - Statuses []PipelineStateInfo `tfsdk:"statuses" tf:"optional"` + Statuses types.List `tfsdk:"statuses" tf:"optional"` } func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListPipelinesResponse) { @@ -525,6 +672,12 @@ func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringRead(existingState ListPipelinesResponse) { } +func (a ListPipelinesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Statuses": reflect.TypeOf(PipelineStateInfo{}), + } +} + // List pipeline updates type ListUpdatesRequest struct { // Max number of entries to return in a single page. @@ -543,6 +696,10 @@ func (newState *ListUpdatesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListUpdatesRequest) SyncEffectiveFieldsDuringRead(existingState ListUpdatesRequest) { } +func (a ListUpdatesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListUpdatesResponse struct { // If present, then there are more results, and this a token to be used in a // subsequent request to fetch the next page. @@ -551,7 +708,7 @@ type ListUpdatesResponse struct { // the previous page. PrevPageToken types.String `tfsdk:"prev_page_token" tf:"optional"` - Updates []UpdateInfo `tfsdk:"updates" tf:"optional"` + Updates types.List `tfsdk:"updates" tf:"optional"` } func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListUpdatesResponse) { @@ -560,6 +717,12 @@ func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringRead(existingState ListUpdatesResponse) { } +func (a ListUpdatesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Updates": reflect.TypeOf(UpdateInfo{}), + } +} + type ManualTrigger struct { } @@ -569,6 +732,10 @@ func (newState *ManualTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan Manu func (newState *ManualTrigger) SyncEffectiveFieldsDuringRead(existingState ManualTrigger) { } +func (a ManualTrigger) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type NotebookLibrary struct { // The absolute path of the notebook. Path types.String `tfsdk:"path" tf:"optional"` @@ -580,6 +747,10 @@ func (newState *NotebookLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan No func (newState *NotebookLibrary) SyncEffectiveFieldsDuringRead(existingState NotebookLibrary) { } +func (a NotebookLibrary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Notifications struct { // A list of alerts that trigger the sending of notifications to the // configured destinations. The supported alerts are: @@ -588,9 +759,9 @@ type Notifications struct { // `on-update-failure`: Each time a pipeline update fails. * // `on-update-fatal-failure`: A pipeline update fails with a non-retryable // (fatal) error. * `on-flow-failure`: A single data flow fails. - Alerts []types.String `tfsdk:"alerts" tf:"optional"` + Alerts types.List `tfsdk:"alerts" tf:"optional"` // A list of email addresses notified when a configured alert is triggered. - EmailRecipients []types.String `tfsdk:"email_recipients" tf:"optional"` + EmailRecipients types.List `tfsdk:"email_recipients" tf:"optional"` } func (newState *Notifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan Notifications) { @@ -599,6 +770,13 @@ func (newState *Notifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan Noti func (newState *Notifications) SyncEffectiveFieldsDuringRead(existingState Notifications) { } +func (a Notifications) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Alerts": reflect.TypeOf(""), + "EmailRecipients": reflect.TypeOf(""), + } +} + type Origin struct { // The id of a batch. Unique within a flow. BatchId types.Int64 `tfsdk:"batch_id" tf:"optional"` @@ -643,6 +821,10 @@ func (newState *Origin) SyncEffectiveFieldsDuringCreateOrUpdate(plan Origin) { func (newState *Origin) SyncEffectiveFieldsDuringRead(existingState Origin) { } +func (a Origin) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelineAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -660,9 +842,13 @@ func (newState *PipelineAccessControlRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *PipelineAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState PipelineAccessControlRequest) { } +func (a PipelineAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelineAccessControlResponse struct { // All permissions. - AllPermissions []PipelinePermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -679,6 +865,12 @@ func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringCreateOr func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState PipelineAccessControlResponse) { } +func (a PipelineAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(PipelinePermission{}), + } +} + type PipelineCluster struct { // Note: This field won't be persisted. Only API users will check this // field. @@ -686,7 +878,7 @@ type PipelineCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale []PipelineClusterAutoscale `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. AwsAttributes compute.AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` @@ -708,7 +900,7 @@ type PipelineCluster struct { // // - Clusters can only reuse cloud resources if the resources' tags are a // subset of the cluster tags - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -726,7 +918,7 @@ type PipelineCluster struct { // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent // to `//init_scripts`. - InitScripts compute.InitScriptInfo `tfsdk:"init_scripts" tf:"optional"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional"` // The optional ID of the instance pool to which the cluster belongs. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` // A label for the cluster specification, either `default` to configure the @@ -755,7 +947,7 @@ type PipelineCluster struct { // An object containing a set of optional, user-specified Spark // configuration key-value pairs. See :method:clusters/create for more // details. - SparkConf map[string]types.String `tfsdk:"spark_conf" tf:"optional"` + SparkConf types.Map `tfsdk:"spark_conf" tf:"optional"` // An object containing a set of optional, user-specified environment // variable key-value pairs. Please note that key-value pair of the form // (X,Y) will be exported as is (i.e., `export X='Y'`) while launching the @@ -769,11 +961,11 @@ type PipelineCluster struct { // Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", // "SPARK_LOCAL_DIRS": "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": // "$SPARK_DAEMON_JAVA_OPTS -Dspark.shuffle.service.enabled=true"}` - SparkEnvVars map[string]types.String `tfsdk:"spark_env_vars" tf:"optional"` + SparkEnvVars types.Map `tfsdk:"spark_env_vars" tf:"optional"` // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. - SshPublicKeys []types.String `tfsdk:"ssh_public_keys" tf:"optional"` + SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` } func (newState *PipelineCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan PipelineCluster) { @@ -782,6 +974,21 @@ func (newState *PipelineCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineCluster) SyncEffectiveFieldsDuringRead(existingState PipelineCluster) { } +func (a PipelineCluster) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Autoscale": reflect.TypeOf(PipelineClusterAutoscale{}), + "AwsAttributes": reflect.TypeOf(compute.AwsAttributes{}), + "AzureAttributes": reflect.TypeOf(compute.AzureAttributes{}), + "ClusterLogConf": reflect.TypeOf(compute.ClusterLogConf{}), + "CustomTags": reflect.TypeOf(""), + "GcpAttributes": reflect.TypeOf(compute.GcpAttributes{}), + "InitScripts": reflect.TypeOf(compute.InitScriptInfo{}), + "SparkConf": reflect.TypeOf(""), + "SparkEnvVars": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(""), + } +} + type PipelineClusterAutoscale struct { // The maximum number of workers to which the cluster can scale up when // overloaded. `max_workers` must be strictly greater than `min_workers`. @@ -804,6 +1011,10 @@ func (newState *PipelineClusterAutoscale) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *PipelineClusterAutoscale) SyncEffectiveFieldsDuringRead(existingState PipelineClusterAutoscale) { } +func (a PipelineClusterAutoscale) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelineDeployment struct { // The deployment method that manages the pipeline. Kind types.String `tfsdk:"kind" tf:"optional"` @@ -817,9 +1028,13 @@ func (newState *PipelineDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelineDeployment) SyncEffectiveFieldsDuringRead(existingState PipelineDeployment) { } +func (a PipelineDeployment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelineEvent struct { // Information about an error captured by the event. - Error []ErrorDetail `tfsdk:"error" tf:"optional,object"` + Error types.Object `tfsdk:"error" tf:"optional,object"` // The event type. Should always correspond to the details EventType types.String `tfsdk:"event_type" tf:"optional"` // A time-based, globally unique id. @@ -831,9 +1046,9 @@ type PipelineEvent struct { // The display message associated with the event. Message types.String `tfsdk:"message" tf:"optional"` // Describes where the event originates from. - Origin []Origin `tfsdk:"origin" tf:"optional,object"` + Origin types.Object `tfsdk:"origin" tf:"optional,object"` // A sequencing object to identify and order events. - Sequence []Sequencing `tfsdk:"sequence" tf:"optional,object"` + Sequence types.Object `tfsdk:"sequence" tf:"optional,object"` // The time of the event. Timestamp types.String `tfsdk:"timestamp" tf:"optional"` } @@ -844,17 +1059,25 @@ func (newState *PipelineEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipe func (newState *PipelineEvent) SyncEffectiveFieldsDuringRead(existingState PipelineEvent) { } +func (a PipelineEvent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Error": reflect.TypeOf(ErrorDetail{}), + "Origin": reflect.TypeOf(Origin{}), + "Sequence": reflect.TypeOf(Sequencing{}), + } +} + type PipelineLibrary struct { // The path to a file that defines a pipeline and is stored in the // Databricks Repos. - File []FileLibrary `tfsdk:"file" tf:"optional,object"` + File types.Object `tfsdk:"file" tf:"optional,object"` // URI of the jar to be installed. Currently only DBFS is supported. Jar types.String `tfsdk:"jar" tf:"optional"` // Specification of a maven library to be installed. Maven compute.MavenLibrary `tfsdk:"maven" tf:"optional,object"` // The path to a notebook that defines a pipeline and is stored in the // Databricks workspace. - Notebook []NotebookLibrary `tfsdk:"notebook" tf:"optional,object"` + Notebook types.Object `tfsdk:"notebook" tf:"optional,object"` // URI of the whl to be installed. Whl types.String `tfsdk:"whl" tf:"optional"` } @@ -865,10 +1088,18 @@ func (newState *PipelineLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineLibrary) SyncEffectiveFieldsDuringRead(existingState PipelineLibrary) { } +func (a PipelineLibrary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "File": reflect.TypeOf(FileLibrary{}), + "Maven": reflect.TypeOf(compute.MavenLibrary{}), + "Notebook": reflect.TypeOf(NotebookLibrary{}), + } +} + type PipelinePermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -879,8 +1110,14 @@ func (newState *PipelinePermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelinePermission) SyncEffectiveFieldsDuringRead(existingState PipelinePermission) { } +func (a PipelinePermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type PipelinePermissions struct { - AccessControlList []PipelineAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -893,6 +1130,12 @@ func (newState *PipelinePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PipelinePermissions) SyncEffectiveFieldsDuringRead(existingState PipelinePermissions) { } +func (a PipelinePermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(PipelineAccessControlResponse{}), + } +} + type PipelinePermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -905,8 +1148,12 @@ func (newState *PipelinePermissionsDescription) SyncEffectiveFieldsDuringCreateO func (newState *PipelinePermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PipelinePermissionsDescription) { } +func (a PipelinePermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PipelinePermissionsRequest struct { - AccessControlList []PipelineAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The pipeline for which to get or manage permissions. PipelineId types.String `tfsdk:"-"` } @@ -917,6 +1164,12 @@ func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PipelinePermissionsRequest) { } +func (a PipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(PipelineAccessControlRequest{}), + } +} + type PipelineSpec struct { // Budget policy of this pipeline. BudgetPolicyId types.String `tfsdk:"budget_policy_id" tf:"optional"` @@ -929,36 +1182,36 @@ type PipelineSpec struct { // DLT Release Channel that specifies which version to use. Channel types.String `tfsdk:"channel" tf:"optional"` // Cluster settings for this pipeline deployment. - Clusters []PipelineCluster `tfsdk:"clusters" tf:"optional"` + Clusters types.List `tfsdk:"clusters" tf:"optional"` // String-String configuration for this pipeline execution. - Configuration map[string]types.String `tfsdk:"configuration" tf:"optional"` + Configuration types.Map `tfsdk:"configuration" tf:"optional"` // Whether the pipeline is continuous or triggered. This replaces `trigger`. Continuous types.Bool `tfsdk:"continuous" tf:"optional"` // Deployment type of this pipeline. - Deployment []PipelineDeployment `tfsdk:"deployment" tf:"optional,object"` + Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` // Whether the pipeline is in Development mode. Defaults to false. Development types.Bool `tfsdk:"development" tf:"optional"` // Pipeline product edition. Edition types.String `tfsdk:"edition" tf:"optional"` // Filters on which Pipeline packages to include in the deployed graph. - Filters []Filters `tfsdk:"filters" tf:"optional,object"` + Filters types.Object `tfsdk:"filters" tf:"optional,object"` // The definition of a gateway pipeline to support change data capture. - GatewayDefinition []IngestionGatewayPipelineDefinition `tfsdk:"gateway_definition" tf:"optional,object"` + GatewayDefinition types.Object `tfsdk:"gateway_definition" tf:"optional,object"` // Unique identifier for this pipeline. Id types.String `tfsdk:"id" tf:"optional"` // The configuration for a managed ingestion pipeline. These settings cannot // be used with the 'libraries', 'target' or 'catalog' settings. - IngestionDefinition []IngestionPipelineDefinition `tfsdk:"ingestion_definition" tf:"optional,object"` + IngestionDefinition types.Object `tfsdk:"ingestion_definition" tf:"optional,object"` // Libraries or code needed by this deployment. - Libraries []PipelineLibrary `tfsdk:"libraries" tf:"optional"` + Libraries types.List `tfsdk:"libraries" tf:"optional"` // Friendly identifier for this pipeline. Name types.String `tfsdk:"name" tf:"optional"` // List of notification settings for this pipeline. - Notifications []Notifications `tfsdk:"notifications" tf:"optional"` + Notifications types.List `tfsdk:"notifications" tf:"optional"` // Whether Photon is enabled for this pipeline. Photon types.Bool `tfsdk:"photon" tf:"optional"` // Restart window of this pipeline. - RestartWindow []RestartWindow `tfsdk:"restart_window" tf:"optional,object"` + RestartWindow types.Object `tfsdk:"restart_window" tf:"optional,object"` // The default schema (database) where tables are read from or published to. // The presence of this field implies that the pipeline is in direct // publishing mode. @@ -972,7 +1225,7 @@ type PipelineSpec struct { // To publish to Unity Catalog, also specify `catalog`. Target types.String `tfsdk:"target" tf:"optional"` // Which pipeline trigger to use. Deprecated: Use `continuous` instead. - Trigger []PipelineTrigger `tfsdk:"trigger" tf:"optional,object"` + Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` } func (newState *PipelineSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan PipelineSpec) { @@ -981,6 +1234,21 @@ func (newState *PipelineSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipel func (newState *PipelineSpec) SyncEffectiveFieldsDuringRead(existingState PipelineSpec) { } +func (a PipelineSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Clusters": reflect.TypeOf(PipelineCluster{}), + "Configuration": reflect.TypeOf(""), + "Deployment": reflect.TypeOf(PipelineDeployment{}), + "Filters": reflect.TypeOf(Filters{}), + "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), + "IngestionDefinition": reflect.TypeOf(IngestionPipelineDefinition{}), + "Libraries": reflect.TypeOf(PipelineLibrary{}), + "Notifications": reflect.TypeOf(Notifications{}), + "RestartWindow": reflect.TypeOf(RestartWindow{}), + "Trigger": reflect.TypeOf(PipelineTrigger{}), + } +} + type PipelineStateInfo struct { // The unique identifier of the cluster running the pipeline. ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` @@ -990,7 +1258,7 @@ type PipelineStateInfo struct { Health types.String `tfsdk:"health" tf:"optional"` // Status of the latest updates for the pipeline. Ordered with the newest // update first. - LatestUpdates []UpdateStateInfo `tfsdk:"latest_updates" tf:"optional"` + LatestUpdates types.List `tfsdk:"latest_updates" tf:"optional"` // The user-friendly name of the pipeline. Name types.String `tfsdk:"name" tf:"optional"` // The unique identifier of the pipeline. @@ -1008,8 +1276,14 @@ func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringRead(existingState PipelineStateInfo) { } +func (a PipelineStateInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LatestUpdates": reflect.TypeOf(UpdateStateInfo{}), + } +} + type PipelineTrigger struct { - Cron []CronTrigger `tfsdk:"cron" tf:"optional,object"` + Cron types.Object `tfsdk:"cron" tf:"optional,object"` Manual []ManualTrigger `tfsdk:"manual" tf:"optional,object"` } @@ -1020,6 +1294,13 @@ func (newState *PipelineTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineTrigger) SyncEffectiveFieldsDuringRead(existingState PipelineTrigger) { } +func (a PipelineTrigger) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Cron": reflect.TypeOf(CronTrigger{}), + "Manual": reflect.TypeOf(ManualTrigger{}), + } +} + type ReportSpec struct { // Required. Destination catalog to store table. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -1033,7 +1314,7 @@ type ReportSpec struct { // Configuration settings to control the ingestion of tables. These settings // override the table_configuration defined in the // IngestionPipelineDefinition object. - TableConfiguration []TableSpecificConfig `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *ReportSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReportSpec) { @@ -1042,6 +1323,12 @@ func (newState *ReportSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReportS func (newState *ReportSpec) SyncEffectiveFieldsDuringRead(existingState ReportSpec) { } +func (a ReportSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + } +} + type RestartWindow struct { // Days of week in which the restart is allowed to happen (within a // five-hour window starting at start_hour). If not specified all days of @@ -1063,6 +1350,10 @@ func (newState *RestartWindow) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rest func (newState *RestartWindow) SyncEffectiveFieldsDuringRead(existingState RestartWindow) { } +func (a RestartWindow) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SchemaSpec struct { // Required. Destination catalog to store tables. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -1078,7 +1369,7 @@ type SchemaSpec struct { // Configuration settings to control the ingestion of tables. These settings // are applied to all tables in this schema and override the // table_configuration defined in the IngestionPipelineDefinition object. - TableConfiguration []TableSpecificConfig `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *SchemaSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaSpec) { @@ -1087,11 +1378,17 @@ func (newState *SchemaSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaS func (newState *SchemaSpec) SyncEffectiveFieldsDuringRead(existingState SchemaSpec) { } +func (a SchemaSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + } +} + type Sequencing struct { // A sequence number, unique and increasing within the control plane. ControlPlaneSeqNo types.Int64 `tfsdk:"control_plane_seq_no" tf:"optional"` // the ID assigned by the data plane. - DataPlaneId []DataPlaneId `tfsdk:"data_plane_id" tf:"optional,object"` + DataPlaneId types.Object `tfsdk:"data_plane_id" tf:"optional,object"` } func (newState *Sequencing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sequencing) { @@ -1100,13 +1397,19 @@ func (newState *Sequencing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sequenc func (newState *Sequencing) SyncEffectiveFieldsDuringRead(existingState Sequencing) { } +func (a Sequencing) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataPlaneId": reflect.TypeOf(DataPlaneId{}), + } +} + type SerializedException struct { // Runtime class of the exception ClassName types.String `tfsdk:"class_name" tf:"optional"` // Exception message Message types.String `tfsdk:"message" tf:"optional"` // Stack trace consisting of a list of stack frames - Stack []StackFrame `tfsdk:"stack" tf:"optional"` + Stack types.List `tfsdk:"stack" tf:"optional"` } func (newState *SerializedException) SyncEffectiveFieldsDuringCreateOrUpdate(plan SerializedException) { @@ -1115,6 +1418,12 @@ func (newState *SerializedException) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SerializedException) SyncEffectiveFieldsDuringRead(existingState SerializedException) { } +func (a SerializedException) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Stack": reflect.TypeOf(StackFrame{}), + } +} + type StackFrame struct { // Class from which the method call originated DeclaringClass types.String `tfsdk:"declaring_class" tf:"optional"` @@ -1132,6 +1441,10 @@ func (newState *StackFrame) SyncEffectiveFieldsDuringCreateOrUpdate(plan StackFr func (newState *StackFrame) SyncEffectiveFieldsDuringRead(existingState StackFrame) { } +func (a StackFrame) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StartUpdate struct { Cause types.String `tfsdk:"cause" tf:"optional"` // If true, this update will reset all tables before running. @@ -1140,14 +1453,14 @@ type StartUpdate struct { // and full_refresh_selection are empty, this is a full graph update. Full // Refresh on a table means that the states of the table will be reset // before the refresh. - FullRefreshSelection []types.String `tfsdk:"full_refresh_selection" tf:"optional"` + FullRefreshSelection types.List `tfsdk:"full_refresh_selection" tf:"optional"` PipelineId types.String `tfsdk:"-"` // A list of tables to update without fullRefresh. If both refresh_selection // and full_refresh_selection are empty, this is a full graph update. Full // Refresh on a table means that the states of the table will be reset // before the refresh. - RefreshSelection []types.String `tfsdk:"refresh_selection" tf:"optional"` + RefreshSelection types.List `tfsdk:"refresh_selection" tf:"optional"` // If true, this update only validates the correctness of pipeline source // code but does not materialize or publish any datasets. ValidateOnly types.Bool `tfsdk:"validate_only" tf:"optional"` @@ -1159,6 +1472,13 @@ func (newState *StartUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan StartU func (newState *StartUpdate) SyncEffectiveFieldsDuringRead(existingState StartUpdate) { } +func (a StartUpdate) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FullRefreshSelection": reflect.TypeOf(""), + "RefreshSelection": reflect.TypeOf(""), + } +} + type StartUpdateResponse struct { UpdateId types.String `tfsdk:"update_id" tf:"optional"` } @@ -1169,6 +1489,10 @@ func (newState *StartUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *StartUpdateResponse) SyncEffectiveFieldsDuringRead(existingState StartUpdateResponse) { } +func (a StartUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StopPipelineResponse struct { } @@ -1178,6 +1502,10 @@ func (newState *StopPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StopPipelineResponse) SyncEffectiveFieldsDuringRead(existingState StopPipelineResponse) { } +func (a StopPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Stop a pipeline type StopRequest struct { PipelineId types.String `tfsdk:"-"` @@ -1189,6 +1517,10 @@ func (newState *StopRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan StopRe func (newState *StopRequest) SyncEffectiveFieldsDuringRead(existingState StopRequest) { } +func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TableSpec struct { // Required. Destination catalog to store table. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -1207,7 +1539,7 @@ type TableSpec struct { // Configuration settings to control the ingestion of tables. These settings // override the table_configuration defined in the // IngestionPipelineDefinition object and the SchemaSpec. - TableConfiguration []TableSpecificConfig `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *TableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableSpec) { @@ -1216,9 +1548,15 @@ func (newState *TableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableSpe func (newState *TableSpec) SyncEffectiveFieldsDuringRead(existingState TableSpec) { } +func (a TableSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + } +} + type TableSpecificConfig struct { // The primary key of the table used to apply changes. - PrimaryKeys []types.String `tfsdk:"primary_keys" tf:"optional"` + PrimaryKeys types.List `tfsdk:"primary_keys" tf:"optional"` // If true, formula fields defined in the table are included in the // ingestion. This setting is only valid for the Salesforce connector SalesforceIncludeFormulaFields types.Bool `tfsdk:"salesforce_include_formula_fields" tf:"optional"` @@ -1227,7 +1565,7 @@ type TableSpecificConfig struct { // The column names specifying the logical order of events in the source // data. Delta Live Tables uses this sequencing to handle change events that // arrive out of order. - SequenceBy []types.String `tfsdk:"sequence_by" tf:"optional"` + SequenceBy types.List `tfsdk:"sequence_by" tf:"optional"` } func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableSpecificConfig) { @@ -1236,6 +1574,13 @@ func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringRead(existingState TableSpecificConfig) { } +func (a TableSpecificConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PrimaryKeys": reflect.TypeOf(""), + "SequenceBy": reflect.TypeOf(""), + } +} + type UpdateInfo struct { // What triggered this update. Cause types.String `tfsdk:"cause" tf:"optional"` @@ -1243,7 +1588,7 @@ type UpdateInfo struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` // The pipeline configuration with system defaults applied where unspecified // by the user. Not returned by ListUpdates. - Config []PipelineSpec `tfsdk:"config" tf:"optional,object"` + Config types.Object `tfsdk:"config" tf:"optional,object"` // The time when this update was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"optional"` // If true, this update will reset all tables before running. @@ -1252,14 +1597,14 @@ type UpdateInfo struct { // and full_refresh_selection are empty, this is a full graph update. Full // Refresh on a table means that the states of the table will be reset // before the refresh. - FullRefreshSelection []types.String `tfsdk:"full_refresh_selection" tf:"optional"` + FullRefreshSelection types.List `tfsdk:"full_refresh_selection" tf:"optional"` // The ID of the pipeline. PipelineId types.String `tfsdk:"pipeline_id" tf:"optional"` // A list of tables to update without fullRefresh. If both refresh_selection // and full_refresh_selection are empty, this is a full graph update. Full // Refresh on a table means that the states of the table will be reset // before the refresh. - RefreshSelection []types.String `tfsdk:"refresh_selection" tf:"optional"` + RefreshSelection types.List `tfsdk:"refresh_selection" tf:"optional"` // The update state. State types.String `tfsdk:"state" tf:"optional"` // The ID of this update. @@ -1275,6 +1620,14 @@ func (newState *UpdateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateI func (newState *UpdateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateInfo) { } +func (a UpdateInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Config": reflect.TypeOf(PipelineSpec{}), + "FullRefreshSelection": reflect.TypeOf(""), + "RefreshSelection": reflect.TypeOf(""), + } +} + type UpdateStateInfo struct { CreationTime types.String `tfsdk:"creation_time" tf:"optional"` @@ -1288,3 +1641,7 @@ func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateStateInfo) { } + +func (a UpdateStateInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 5ccfa54fbb..8950936ded 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -11,11 +11,13 @@ We use go-native types for lists and maps intentionally for the ease for convert package provisioning_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) type AwsCredentials struct { - StsRole []StsRole `tfsdk:"sts_role" tf:"optional,object"` + StsRole types.Object `tfsdk:"sts_role" tf:"optional,object"` } func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsCredentials) { @@ -24,6 +26,12 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan Aws func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsCredentials) { } +func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "StsRole": reflect.TypeOf(StsRole{}), + } +} + type AwsKeyInfo struct { // The AWS KMS key alias. KeyAlias types.String `tfsdk:"key_alias" tf:"optional"` @@ -44,6 +52,10 @@ func (newState *AwsKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsKeyI func (newState *AwsKeyInfo) SyncEffectiveFieldsDuringRead(existingState AwsKeyInfo) { } +func (a AwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AzureWorkspaceInfo struct { // Azure Resource Group name ResourceGroup types.String `tfsdk:"resource_group" tf:"optional"` @@ -57,10 +69,14 @@ func (newState *AzureWorkspaceInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AzureWorkspaceInfo) SyncEffectiveFieldsDuringRead(existingState AzureWorkspaceInfo) { } +func (a AzureWorkspaceInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The general workspace configurations that are specific to cloud providers. type CloudResourceContainer struct { // The general workspace configurations that are specific to Google Cloud. - Gcp []CustomerFacingGcpCloudResourceContainer `tfsdk:"gcp" tf:"optional,object"` + Gcp types.Object `tfsdk:"gcp" tf:"optional,object"` } func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringCreateOrUpdate(plan CloudResourceContainer) { @@ -69,6 +85,12 @@ func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringRead(existingState CloudResourceContainer) { } +func (a CloudResourceContainer) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Gcp": reflect.TypeOf(CustomerFacingGcpCloudResourceContainer{}), + } +} + type CreateAwsKeyInfo struct { // The AWS KMS key alias. KeyAlias types.String `tfsdk:"key_alias" tf:"optional"` @@ -88,8 +110,12 @@ func (newState *CreateAwsKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateAwsKeyInfo) SyncEffectiveFieldsDuringRead(existingState CreateAwsKeyInfo) { } +func (a CreateAwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateCredentialAwsCredentials struct { - StsRole []CreateCredentialStsRole `tfsdk:"sts_role" tf:"optional,object"` + StsRole types.Object `tfsdk:"sts_role" tf:"optional,object"` } func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCredentialAwsCredentials) { @@ -98,8 +124,14 @@ func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringCreateO func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringRead(existingState CreateCredentialAwsCredentials) { } +func (a CreateCredentialAwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "StsRole": reflect.TypeOf(CreateCredentialStsRole{}), + } +} + type CreateCredentialRequest struct { - AwsCredentials []CreateCredentialAwsCredentials `tfsdk:"aws_credentials" tf:"object"` + AwsCredentials types.Object `tfsdk:"aws_credentials" tf:"object"` // The human-readable name of the credential configuration object. CredentialsName types.String `tfsdk:"credentials_name" tf:""` } @@ -110,6 +142,12 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialRequest) { } +func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsCredentials": reflect.TypeOf(CreateCredentialAwsCredentials{}), + } +} + type CreateCredentialStsRole struct { // The Amazon Resource Name (ARN) of the cross account role. RoleArn types.String `tfsdk:"role_arn" tf:"optional"` @@ -121,12 +159,16 @@ func (newState *CreateCredentialStsRole) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialStsRole) SyncEffectiveFieldsDuringRead(existingState CreateCredentialStsRole) { } +func (a CreateCredentialStsRole) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateCustomerManagedKeyRequest struct { - AwsKeyInfo []CreateAwsKeyInfo `tfsdk:"aws_key_info" tf:"optional,object"` + AwsKeyInfo types.Object `tfsdk:"aws_key_info" tf:"optional,object"` - GcpKeyInfo []CreateGcpKeyInfo `tfsdk:"gcp_key_info" tf:"optional,object"` + GcpKeyInfo types.Object `tfsdk:"gcp_key_info" tf:"optional,object"` // The cases that the key can be used for. - UseCases []types.String `tfsdk:"use_cases" tf:""` + UseCases types.List `tfsdk:"use_cases" tf:""` } func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCustomerManagedKeyRequest) { @@ -135,6 +177,14 @@ func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringCreate func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringRead(existingState CreateCustomerManagedKeyRequest) { } +func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsKeyInfo": reflect.TypeOf(CreateAwsKeyInfo{}), + "GcpKeyInfo": reflect.TypeOf(CreateGcpKeyInfo{}), + "UseCases": reflect.TypeOf(""), + } +} + type CreateGcpKeyInfo struct { // The GCP KMS key's resource name KmsKeyId types.String `tfsdk:"kms_key_id" tf:""` @@ -146,23 +196,27 @@ func (newState *CreateGcpKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateGcpKeyInfo) SyncEffectiveFieldsDuringRead(existingState CreateGcpKeyInfo) { } +func (a CreateGcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateNetworkRequest struct { // The Google Cloud specific information for this network (for example, the // VPC ID, subnet ID, and secondary IP ranges). - GcpNetworkInfo []GcpNetworkInfo `tfsdk:"gcp_network_info" tf:"optional,object"` + GcpNetworkInfo types.Object `tfsdk:"gcp_network_info" tf:"optional,object"` // The human-readable name of the network configuration. NetworkName types.String `tfsdk:"network_name" tf:""` // IDs of one to five security groups associated with this network. Security // group IDs **cannot** be used in multiple network configurations. - SecurityGroupIds []types.String `tfsdk:"security_group_ids" tf:"optional"` + SecurityGroupIds types.List `tfsdk:"security_group_ids" tf:"optional"` // IDs of at least two subnets associated with this network. Subnet IDs // **cannot** be used in multiple network configurations. - SubnetIds []types.String `tfsdk:"subnet_ids" tf:"optional"` + SubnetIds types.List `tfsdk:"subnet_ids" tf:"optional"` // If specified, contains the VPC endpoints used to allow cluster // communication from this VPC over [AWS PrivateLink]. // // [AWS PrivateLink]: https://aws.amazon.com/privatelink/ - VpcEndpoints []NetworkVpcEndpoints `tfsdk:"vpc_endpoints" tf:"optional,object"` + VpcEndpoints types.Object `tfsdk:"vpc_endpoints" tf:"optional,object"` // The ID of the VPC associated with this network. VPC IDs can be used in // multiple network configurations. VpcId types.String `tfsdk:"vpc_id" tf:"optional"` @@ -174,9 +228,18 @@ func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringRead(existingState CreateNetworkRequest) { } +func (a CreateNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "GcpNetworkInfo": reflect.TypeOf(GcpNetworkInfo{}), + "SecurityGroupIds": reflect.TypeOf(""), + "SubnetIds": reflect.TypeOf(""), + "VpcEndpoints": reflect.TypeOf(NetworkVpcEndpoints{}), + } +} + type CreateStorageConfigurationRequest struct { // Root S3 bucket information. - RootBucketInfo []RootBucketInfo `tfsdk:"root_bucket_info" tf:"object"` + RootBucketInfo types.Object `tfsdk:"root_bucket_info" tf:"object"` // The human-readable name of the storage configuration. StorageConfigurationName types.String `tfsdk:"storage_configuration_name" tf:""` } @@ -187,12 +250,18 @@ func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringCrea func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState CreateStorageConfigurationRequest) { } +func (a CreateStorageConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RootBucketInfo": reflect.TypeOf(RootBucketInfo{}), + } +} + type CreateVpcEndpointRequest struct { // The ID of the VPC endpoint object in AWS. AwsVpcEndpointId types.String `tfsdk:"aws_vpc_endpoint_id" tf:"optional"` // The Google Cloud specific information for this Private Service Connect // endpoint. - GcpVpcEndpointInfo []GcpVpcEndpointInfo `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` + GcpVpcEndpointInfo types.Object `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` // The AWS region in which this VPC endpoint object exists. Region types.String `tfsdk:"region" tf:"optional"` // The human-readable name of the storage configuration. @@ -205,6 +274,12 @@ func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState CreateVpcEndpointRequest) { } +func (a CreateVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "GcpVpcEndpointInfo": reflect.TypeOf(GcpVpcEndpointInfo{}), + } +} + type CreateWorkspaceRequest struct { // The AWS region of the workspace's data plane. AwsRegion types.String `tfsdk:"aws_region" tf:"optional"` @@ -213,14 +288,14 @@ type CreateWorkspaceRequest struct { Cloud types.String `tfsdk:"cloud" tf:"optional"` // The general workspace configurations that are specific to cloud // providers. - CloudResourceContainer []CloudResourceContainer `tfsdk:"cloud_resource_container" tf:"optional,object"` + CloudResourceContainer types.Object `tfsdk:"cloud_resource_container" tf:"optional,object"` // ID of the workspace's credential configuration object. CredentialsId types.String `tfsdk:"credentials_id" tf:"optional"` // The custom tags key-value pairing that is attached to this workspace. The // key-value pair is a string of utf-8 characters. The value can be an empty // string, with maximum length of 255 characters. The key can be of maximum // length of 127 characters, and cannot be empty. - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // The deployment name defines part of the subdomain for the workspace. The // workspace URL for the web application and REST APIs is // `.cloud.databricks.com`. For example, if the @@ -274,9 +349,9 @@ type CreateWorkspaceRequest struct { // for a new workspace]. // // [calculate subnet sizes for a new workspace]: https://docs.gcp.databricks.com/administration-guide/cloud-configurations/gcp/network-sizing.html - GcpManagedNetworkConfig []GcpManagedNetworkConfig `tfsdk:"gcp_managed_network_config" tf:"optional,object"` + GcpManagedNetworkConfig types.Object `tfsdk:"gcp_managed_network_config" tf:"optional,object"` // The configurations for the GKE cluster of a Databricks workspace. - GkeConfig []GkeConfig `tfsdk:"gke_config" tf:"optional,object"` + GkeConfig types.Object `tfsdk:"gke_config" tf:"optional,object"` // Whether no public IP is enabled for the workspace. IsNoPublicIpEnabled types.Bool `tfsdk:"is_no_public_ip_enabled" tf:"optional"` // The Google Cloud region of the workspace data plane in your Google @@ -324,11 +399,20 @@ func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState CreateWorkspaceRequest) { } +func (a CreateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CloudResourceContainer": reflect.TypeOf(CloudResourceContainer{}), + "CustomTags": reflect.TypeOf(""), + "GcpManagedNetworkConfig": reflect.TypeOf(GcpManagedNetworkConfig{}), + "GkeConfig": reflect.TypeOf(GkeConfig{}), + } +} + type Credential struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` - AwsCredentials []AwsCredentials `tfsdk:"aws_credentials" tf:"optional,object"` + AwsCredentials types.Object `tfsdk:"aws_credentials" tf:"optional,object"` // Time in epoch milliseconds when the credential was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // Databricks credential configuration ID. @@ -343,6 +427,12 @@ func (newState *Credential) SyncEffectiveFieldsDuringCreateOrUpdate(plan Credent func (newState *Credential) SyncEffectiveFieldsDuringRead(existingState Credential) { } +func (a Credential) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsCredentials": reflect.TypeOf(AwsCredentials{}), + } +} + // The general workspace configurations that are specific to Google Cloud. type CustomerFacingGcpCloudResourceContainer struct { // The Google Cloud project ID, which the workspace uses to instantiate @@ -356,19 +446,23 @@ func (newState *CustomerFacingGcpCloudResourceContainer) SyncEffectiveFieldsDuri func (newState *CustomerFacingGcpCloudResourceContainer) SyncEffectiveFieldsDuringRead(existingState CustomerFacingGcpCloudResourceContainer) { } +func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CustomerManagedKey struct { // The Databricks account ID that holds the customer-managed key. AccountId types.String `tfsdk:"account_id" tf:"optional"` - AwsKeyInfo []AwsKeyInfo `tfsdk:"aws_key_info" tf:"optional,object"` + AwsKeyInfo types.Object `tfsdk:"aws_key_info" tf:"optional,object"` // Time in epoch milliseconds when the customer key was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // ID of the encryption key configuration object. CustomerManagedKeyId types.String `tfsdk:"customer_managed_key_id" tf:"optional"` - GcpKeyInfo []GcpKeyInfo `tfsdk:"gcp_key_info" tf:"optional,object"` + GcpKeyInfo types.Object `tfsdk:"gcp_key_info" tf:"optional,object"` // The cases that the key can be used for. - UseCases []types.String `tfsdk:"use_cases" tf:"optional"` + UseCases types.List `tfsdk:"use_cases" tf:"optional"` } func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringCreateOrUpdate(plan CustomerManagedKey) { @@ -377,6 +471,14 @@ func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringRead(existingState CustomerManagedKey) { } +func (a CustomerManagedKey) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsKeyInfo": reflect.TypeOf(AwsKeyInfo{}), + "GcpKeyInfo": reflect.TypeOf(GcpKeyInfo{}), + "UseCases": reflect.TypeOf(""), + } +} + // Delete credential configuration type DeleteCredentialRequest struct { // Databricks Account API credential configuration ID @@ -389,6 +491,10 @@ func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialRequest) { } +func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete encryption key configuration type DeleteEncryptionKeyRequest struct { // Databricks encryption key configuration ID. @@ -401,6 +507,10 @@ func (newState *DeleteEncryptionKeyRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteEncryptionKeyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteEncryptionKeyRequest) { } +func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a network configuration type DeleteNetworkRequest struct { // Databricks Account API network configuration ID. @@ -413,6 +523,10 @@ func (newState *DeleteNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteNetworkRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkRequest) { } +func (a DeleteNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a private access settings object type DeletePrivateAccesRequest struct { // Databricks Account API private access settings ID. @@ -425,6 +539,10 @@ func (newState *DeletePrivateAccesRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeletePrivateAccesRequest) SyncEffectiveFieldsDuringRead(existingState DeletePrivateAccesRequest) { } +func (a DeletePrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -434,6 +552,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete storage configuration type DeleteStorageRequest struct { // Databricks Account API storage configuration ID. @@ -446,6 +568,10 @@ func (newState *DeleteStorageRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteStorageRequest) SyncEffectiveFieldsDuringRead(existingState DeleteStorageRequest) { } +func (a DeleteStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete VPC endpoint configuration type DeleteVpcEndpointRequest struct { // Databricks VPC endpoint ID. @@ -458,6 +584,10 @@ func (newState *DeleteVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVpcEndpointRequest) { } +func (a DeleteVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a workspace type DeleteWorkspaceRequest struct { // Workspace ID. @@ -470,6 +600,10 @@ func (newState *DeleteWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspaceRequest) { } +func (a DeleteWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExternalCustomerInfo struct { // Email of the authoritative user. AuthoritativeUserEmail types.String `tfsdk:"authoritative_user_email" tf:"optional"` @@ -485,6 +619,10 @@ func (newState *ExternalCustomerInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExternalCustomerInfo) SyncEffectiveFieldsDuringRead(existingState ExternalCustomerInfo) { } +func (a ExternalCustomerInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GcpKeyInfo struct { // The GCP KMS key's resource name KmsKeyId types.String `tfsdk:"kms_key_id" tf:""` @@ -496,6 +634,10 @@ func (newState *GcpKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpKeyI func (newState *GcpKeyInfo) SyncEffectiveFieldsDuringRead(existingState GcpKeyInfo) { } +func (a GcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The network settings for the workspace. The configurations are only for // Databricks-managed VPCs. It is ignored if you specify a customer-managed VPC // in the `network_id` field.", All the IP range configurations must be mutually @@ -537,6 +679,10 @@ func (newState *GcpManagedNetworkConfig) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GcpManagedNetworkConfig) SyncEffectiveFieldsDuringRead(existingState GcpManagedNetworkConfig) { } +func (a GcpManagedNetworkConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The Google Cloud specific information for this network (for example, the VPC // ID, subnet ID, and secondary IP ranges). type GcpNetworkInfo struct { @@ -566,6 +712,10 @@ func (newState *GcpNetworkInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Gcp func (newState *GcpNetworkInfo) SyncEffectiveFieldsDuringRead(existingState GcpNetworkInfo) { } +func (a GcpNetworkInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The Google Cloud specific information for this Private Service Connect // endpoint. type GcpVpcEndpointInfo struct { @@ -588,6 +738,10 @@ func (newState *GcpVpcEndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GcpVpcEndpointInfo) SyncEffectiveFieldsDuringRead(existingState GcpVpcEndpointInfo) { } +func (a GcpVpcEndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get credential configuration type GetCredentialRequest struct { // Databricks Account API credential configuration ID @@ -600,6 +754,10 @@ func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialRequest) { } +func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get encryption key configuration type GetEncryptionKeyRequest struct { // Databricks encryption key configuration ID. @@ -612,6 +770,10 @@ func (newState *GetEncryptionKeyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetEncryptionKeyRequest) SyncEffectiveFieldsDuringRead(existingState GetEncryptionKeyRequest) { } +func (a GetEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a network configuration type GetNetworkRequest struct { // Databricks Account API network configuration ID. @@ -624,6 +786,10 @@ func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringRead(existingState GetNetworkRequest) { } +func (a GetNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a private access settings object type GetPrivateAccesRequest struct { // Databricks Account API private access settings ID. @@ -636,6 +802,10 @@ func (newState *GetPrivateAccesRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPrivateAccesRequest) SyncEffectiveFieldsDuringRead(existingState GetPrivateAccesRequest) { } +func (a GetPrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get storage configuration type GetStorageRequest struct { // Databricks Account API storage configuration ID. @@ -648,6 +818,10 @@ func (newState *GetStorageRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetStorageRequest) SyncEffectiveFieldsDuringRead(existingState GetStorageRequest) { } +func (a GetStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a VPC endpoint configuration type GetVpcEndpointRequest struct { // Databricks VPC endpoint ID. @@ -660,6 +834,10 @@ func (newState *GetVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetVpcEndpointRequest) { } +func (a GetVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a workspace type GetWorkspaceRequest struct { // Workspace ID. @@ -672,6 +850,10 @@ func (newState *GetWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceRequest) { } +func (a GetWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The configurations for the GKE cluster of a Databricks workspace. type GkeConfig struct { // Specifies the network connectivity types for the GKE nodes and the GKE @@ -696,29 +878,33 @@ func (newState *GkeConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan GkeConfi func (newState *GkeConfig) SyncEffectiveFieldsDuringRead(existingState GkeConfig) { } +func (a GkeConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Network struct { // The Databricks account ID associated with this network configuration. AccountId types.String `tfsdk:"account_id" tf:"optional"` // Time in epoch milliseconds when the network was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // Array of error messages about the network configuration. - ErrorMessages []NetworkHealth `tfsdk:"error_messages" tf:"computed,optional"` + ErrorMessages types.List `tfsdk:"error_messages" tf:"computed,optional"` // The Google Cloud specific information for this network (for example, the // VPC ID, subnet ID, and secondary IP ranges). - GcpNetworkInfo []GcpNetworkInfo `tfsdk:"gcp_network_info" tf:"optional,object"` + GcpNetworkInfo types.Object `tfsdk:"gcp_network_info" tf:"optional,object"` // The Databricks network configuration ID. NetworkId types.String `tfsdk:"network_id" tf:"optional"` // The human-readable name of the network configuration. NetworkName types.String `tfsdk:"network_name" tf:"optional"` - SecurityGroupIds []types.String `tfsdk:"security_group_ids" tf:"optional"` + SecurityGroupIds types.List `tfsdk:"security_group_ids" tf:"optional"` - SubnetIds []types.String `tfsdk:"subnet_ids" tf:"optional"` + SubnetIds types.List `tfsdk:"subnet_ids" tf:"optional"` // If specified, contains the VPC endpoints used to allow cluster // communication from this VPC over [AWS PrivateLink]. // // [AWS PrivateLink]: https://aws.amazon.com/privatelink/ - VpcEndpoints []NetworkVpcEndpoints `tfsdk:"vpc_endpoints" tf:"optional,object"` + VpcEndpoints types.Object `tfsdk:"vpc_endpoints" tf:"optional,object"` // The ID of the VPC associated with this network configuration. VPC IDs can // be used in multiple networks. VpcId types.String `tfsdk:"vpc_id" tf:"optional"` @@ -727,7 +913,7 @@ type Network struct { // Broken. * `WARNED`: Warned. VpcStatus types.String `tfsdk:"vpc_status" tf:"computed,optional"` // Array of warning messages about the network configuration. - WarningMessages []NetworkWarning `tfsdk:"warning_messages" tf:"computed,optional"` + WarningMessages types.List `tfsdk:"warning_messages" tf:"computed,optional"` // Workspace ID associated with this network configuration. WorkspaceId types.Int64 `tfsdk:"workspace_id" tf:"optional"` } @@ -738,6 +924,17 @@ func (newState *Network) SyncEffectiveFieldsDuringCreateOrUpdate(plan Network) { func (newState *Network) SyncEffectiveFieldsDuringRead(existingState Network) { } +func (a Network) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ErrorMessages": reflect.TypeOf(NetworkHealth{}), + "GcpNetworkInfo": reflect.TypeOf(GcpNetworkInfo{}), + "SecurityGroupIds": reflect.TypeOf(""), + "SubnetIds": reflect.TypeOf(""), + "VpcEndpoints": reflect.TypeOf(NetworkVpcEndpoints{}), + "WarningMessages": reflect.TypeOf(NetworkWarning{}), + } +} + type NetworkHealth struct { // Details of the error. ErrorMessage types.String `tfsdk:"error_message" tf:"optional"` @@ -752,6 +949,10 @@ func (newState *NetworkHealth) SyncEffectiveFieldsDuringCreateOrUpdate(plan Netw func (newState *NetworkHealth) SyncEffectiveFieldsDuringRead(existingState NetworkHealth) { } +func (a NetworkHealth) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // If specified, contains the VPC endpoints used to allow cluster communication // from this VPC over [AWS PrivateLink]. // @@ -759,10 +960,10 @@ func (newState *NetworkHealth) SyncEffectiveFieldsDuringRead(existingState Netwo type NetworkVpcEndpoints struct { // The VPC endpoint ID used by this network to access the Databricks secure // cluster connectivity relay. - DataplaneRelay []types.String `tfsdk:"dataplane_relay" tf:""` + DataplaneRelay types.List `tfsdk:"dataplane_relay" tf:""` // The VPC endpoint ID used by this network to access the Databricks REST // API. - RestApi []types.String `tfsdk:"rest_api" tf:""` + RestApi types.List `tfsdk:"rest_api" tf:""` } func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringCreateOrUpdate(plan NetworkVpcEndpoints) { @@ -771,6 +972,13 @@ func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringRead(existingState NetworkVpcEndpoints) { } +func (a NetworkVpcEndpoints) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataplaneRelay": reflect.TypeOf(""), + "RestApi": reflect.TypeOf(""), + } +} + type NetworkWarning struct { // Details of the warning. WarningMessage types.String `tfsdk:"warning_message" tf:"optional"` @@ -785,11 +993,15 @@ func (newState *NetworkWarning) SyncEffectiveFieldsDuringCreateOrUpdate(plan Net func (newState *NetworkWarning) SyncEffectiveFieldsDuringRead(existingState NetworkWarning) { } +func (a NetworkWarning) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PrivateAccessSettings struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` // An array of Databricks VPC endpoint IDs. - AllowedVpcEndpointIds []types.String `tfsdk:"allowed_vpc_endpoint_ids" tf:"optional"` + AllowedVpcEndpointIds types.List `tfsdk:"allowed_vpc_endpoint_ids" tf:"optional"` // The private access level controls which VPC endpoints can connect to the // UI or API of any workspace that attaches this private access settings // object. * `ACCOUNT` level access (the default) allows only VPC endpoints @@ -818,6 +1030,12 @@ func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringRead(existingState PrivateAccessSettings) { } +func (a PrivateAccessSettings) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllowedVpcEndpointIds": reflect.TypeOf(""), + } +} + type ReplaceResponse struct { } @@ -827,6 +1045,10 @@ func (newState *ReplaceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReplaceResponse) SyncEffectiveFieldsDuringRead(existingState ReplaceResponse) { } +func (a ReplaceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Root S3 bucket information. type RootBucketInfo struct { // The name of the S3 bucket. @@ -839,13 +1061,17 @@ func (newState *RootBucketInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Roo func (newState *RootBucketInfo) SyncEffectiveFieldsDuringRead(existingState RootBucketInfo) { } +func (a RootBucketInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StorageConfiguration struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"computed,optional"` // Time in epoch milliseconds when the storage configuration was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // Root S3 bucket information. - RootBucketInfo []RootBucketInfo `tfsdk:"root_bucket_info" tf:"optional,object"` + RootBucketInfo types.Object `tfsdk:"root_bucket_info" tf:"optional,object"` // Databricks storage configuration ID. StorageConfigurationId types.String `tfsdk:"storage_configuration_id" tf:"optional"` // The human-readable name of the storage configuration. @@ -858,6 +1084,12 @@ func (newState *StorageConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StorageConfiguration) SyncEffectiveFieldsDuringRead(existingState StorageConfiguration) { } +func (a StorageConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RootBucketInfo": reflect.TypeOf(RootBucketInfo{}), + } +} + type StsRole struct { // The external ID that needs to be trusted by the cross-account role. This // is always your Databricks account ID. @@ -872,6 +1104,10 @@ func (newState *StsRole) SyncEffectiveFieldsDuringCreateOrUpdate(plan StsRole) { func (newState *StsRole) SyncEffectiveFieldsDuringRead(existingState StsRole) { } +func (a StsRole) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateResponse struct { } @@ -881,6 +1117,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateWorkspaceRequest struct { // The AWS region of the workspace's data plane (for example, `us-west-2`). // This parameter is available only for updating failed workspaces. @@ -892,7 +1132,7 @@ type UpdateWorkspaceRequest struct { // key-value pair is a string of utf-8 characters. The value can be an empty // string, with maximum length of 255 characters. The key can be of maximum // length of 127 characters, and cannot be empty. - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // The ID of the workspace's managed services encryption key configuration // object. This parameter is available only for updating failed workspaces. ManagedServicesCustomerManagedKeyId types.String `tfsdk:"managed_services_customer_managed_key_id" tf:"optional"` @@ -922,6 +1162,12 @@ func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceRequest) { } +func (a UpdateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CustomTags": reflect.TypeOf(""), + } +} + type UpsertPrivateAccessSettingsRequest struct { // An array of Databricks VPC endpoint IDs. This is the Databricks ID that // is returned when registering the VPC endpoint configuration in your @@ -937,7 +1183,7 @@ type UpsertPrivateAccessSettingsRequest struct { // public internet, see [IP access lists]. // // [IP access lists]: https://docs.databricks.com/security/network/ip-access-list.html - AllowedVpcEndpointIds []types.String `tfsdk:"allowed_vpc_endpoint_ids" tf:"optional"` + AllowedVpcEndpointIds types.List `tfsdk:"allowed_vpc_endpoint_ids" tf:"optional"` // The private access level controls which VPC endpoints can connect to the // UI or API of any workspace that attaches this private access settings // object. * `ACCOUNT` level access (the default) allows only VPC endpoints @@ -966,6 +1212,12 @@ func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringCre func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringRead(existingState UpsertPrivateAccessSettingsRequest) { } +func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllowedVpcEndpointIds": reflect.TypeOf(""), + } +} + type VpcEndpoint struct { // The Databricks account ID that hosts the VPC endpoint configuration. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -982,7 +1234,7 @@ type VpcEndpoint struct { AwsVpcEndpointId types.String `tfsdk:"aws_vpc_endpoint_id" tf:"optional"` // The Google Cloud specific information for this Private Service Connect // endpoint. - GcpVpcEndpointInfo []GcpVpcEndpointInfo `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` + GcpVpcEndpointInfo types.Object `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` // The AWS region in which this VPC endpoint object exists. Region types.String `tfsdk:"region" tf:"optional"` // The current state (such as `available` or `rejected`) of the VPC @@ -1010,18 +1262,24 @@ func (newState *VpcEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan VpcEnd func (newState *VpcEndpoint) SyncEffectiveFieldsDuringRead(existingState VpcEndpoint) { } +func (a VpcEndpoint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "GcpVpcEndpointInfo": reflect.TypeOf(GcpVpcEndpointInfo{}), + } +} + type Workspace struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` // The AWS region of the workspace data plane (for example, `us-west-2`). AwsRegion types.String `tfsdk:"aws_region" tf:"optional"` - AzureWorkspaceInfo []AzureWorkspaceInfo `tfsdk:"azure_workspace_info" tf:"optional,object"` + AzureWorkspaceInfo types.Object `tfsdk:"azure_workspace_info" tf:"optional,object"` // The cloud name. This field always has the value `gcp`. Cloud types.String `tfsdk:"cloud" tf:"optional"` // The general workspace configurations that are specific to cloud // providers. - CloudResourceContainer []CloudResourceContainer `tfsdk:"cloud_resource_container" tf:"optional,object"` + CloudResourceContainer types.Object `tfsdk:"cloud_resource_container" tf:"optional,object"` // Time in epoch milliseconds when the workspace was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // ID of the workspace's credential configuration object. @@ -1030,7 +1288,7 @@ type Workspace struct { // key-value pair is a string of utf-8 characters. The value can be an empty // string, with maximum length of 255 characters. The key can be of maximum // length of 127 characters, and cannot be empty. - CustomTags map[string]types.String `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // The deployment name defines part of the subdomain for the workspace. The // workspace URL for web application and REST APIs is // `.cloud.databricks.com`. @@ -1041,7 +1299,7 @@ type Workspace struct { // If this workspace is for a external customer, then external_customer_info // is populated. If this workspace is not for a external customer, then // external_customer_info is empty. - ExternalCustomerInfo []ExternalCustomerInfo `tfsdk:"external_customer_info" tf:"optional,object"` + ExternalCustomerInfo types.Object `tfsdk:"external_customer_info" tf:"optional,object"` // The network settings for the workspace. The configurations are only for // Databricks-managed VPCs. It is ignored if you specify a customer-managed // VPC in the `network_id` field.", All the IP range configurations must be @@ -1065,9 +1323,9 @@ type Workspace struct { // for a new workspace]. // // [calculate subnet sizes for a new workspace]: https://docs.gcp.databricks.com/administration-guide/cloud-configurations/gcp/network-sizing.html - GcpManagedNetworkConfig []GcpManagedNetworkConfig `tfsdk:"gcp_managed_network_config" tf:"optional,object"` + GcpManagedNetworkConfig types.Object `tfsdk:"gcp_managed_network_config" tf:"optional,object"` // The configurations for the GKE cluster of a Databricks workspace. - GkeConfig []GkeConfig `tfsdk:"gke_config" tf:"optional,object"` + GkeConfig types.Object `tfsdk:"gke_config" tf:"optional,object"` // Whether no public IP is enabled for the workspace. IsNoPublicIpEnabled types.Bool `tfsdk:"is_no_public_ip_enabled" tf:"optional"` // The Google Cloud region of the workspace data plane in your Google @@ -1115,3 +1373,14 @@ func (newState *Workspace) SyncEffectiveFieldsDuringCreateOrUpdate(plan Workspac func (newState *Workspace) SyncEffectiveFieldsDuringRead(existingState Workspace) { } + +func (a Workspace) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AzureWorkspaceInfo": reflect.TypeOf(AzureWorkspaceInfo{}), + "CloudResourceContainer": reflect.TypeOf(CloudResourceContainer{}), + "CustomTags": reflect.TypeOf(""), + "ExternalCustomerInfo": reflect.TypeOf(ExternalCustomerInfo{}), + "GcpManagedNetworkConfig": reflect.TypeOf(GcpManagedNetworkConfig{}), + "GkeConfig": reflect.TypeOf(GkeConfig{}), + } +} diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 940de56ad4..44138b065d 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -12,6 +12,7 @@ package serving_tf import ( "io" + "reflect" "github.com/databricks/databricks-sdk-go/service/oauth2" "github.com/hashicorp/terraform-plugin-framework/types" @@ -36,20 +37,24 @@ func (newState *Ai21LabsConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ai2 func (newState *Ai21LabsConfig) SyncEffectiveFieldsDuringRead(existingState Ai21LabsConfig) { } +func (a Ai21LabsConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AiGatewayConfig struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. - Guardrails []AiGatewayGuardrails `tfsdk:"guardrails" tf:"optional,object"` + Guardrails types.Object `tfsdk:"guardrails" tf:"optional,object"` // Configuration for payload logging using inference tables. Use these // tables to monitor and audit data being sent to and received from model // APIs and to improve model quality. - InferenceTableConfig []AiGatewayInferenceTableConfig `tfsdk:"inference_table_config" tf:"optional,object"` + InferenceTableConfig types.Object `tfsdk:"inference_table_config" tf:"optional,object"` // Configuration for rate limits which can be set to limit endpoint traffic. - RateLimits []AiGatewayRateLimit `tfsdk:"rate_limits" tf:"optional"` + RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` // Configuration to enable usage tracking using system tables. These tables // allow you to monitor operational usage on endpoints and their associated // costs. - UsageTrackingConfig []AiGatewayUsageTrackingConfig `tfsdk:"usage_tracking_config" tf:"optional,object"` + UsageTrackingConfig types.Object `tfsdk:"usage_tracking_config" tf:"optional,object"` } func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan AiGatewayConfig) { @@ -58,17 +63,26 @@ func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ai func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayConfig) { } +func (a AiGatewayConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Guardrails": reflect.TypeOf(AiGatewayGuardrails{}), + "InferenceTableConfig": reflect.TypeOf(AiGatewayInferenceTableConfig{}), + "RateLimits": reflect.TypeOf(AiGatewayRateLimit{}), + "UsageTrackingConfig": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), + } +} + type AiGatewayGuardrailParameters struct { // List of invalid keywords. AI guardrail uses keyword or string matching to // decide if the keyword exists in the request or response content. - InvalidKeywords []types.String `tfsdk:"invalid_keywords" tf:"optional"` + InvalidKeywords types.List `tfsdk:"invalid_keywords" tf:"optional"` // Configuration for guardrail PII filter. - Pii []AiGatewayGuardrailPiiBehavior `tfsdk:"pii" tf:"optional,object"` + Pii types.Object `tfsdk:"pii" tf:"optional,object"` // Indicates whether the safety filter is enabled. Safety types.Bool `tfsdk:"safety" tf:"optional"` // The list of allowed topics. Given a chat request, this guardrail flags // the request if its topic is not in the allowed topics. - ValidTopics []types.String `tfsdk:"valid_topics" tf:"optional"` + ValidTopics types.List `tfsdk:"valid_topics" tf:"optional"` } func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringCreateOrUpdate(plan AiGatewayGuardrailParameters) { @@ -77,6 +91,14 @@ func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringCreateOrU func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrailParameters) { } +func (a AiGatewayGuardrailParameters) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InvalidKeywords": reflect.TypeOf(""), + "Pii": reflect.TypeOf(AiGatewayGuardrailPiiBehavior{}), + "ValidTopics": reflect.TypeOf(""), + } +} + type AiGatewayGuardrailPiiBehavior struct { // Behavior for PII filter. Currently only 'BLOCK' is supported. If 'BLOCK' // is set for the input guardrail and the request contains PII, the request @@ -93,11 +115,15 @@ func (newState *AiGatewayGuardrailPiiBehavior) SyncEffectiveFieldsDuringCreateOr func (newState *AiGatewayGuardrailPiiBehavior) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrailPiiBehavior) { } +func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AiGatewayGuardrails struct { // Configuration for input guardrail filters. - Input []AiGatewayGuardrailParameters `tfsdk:"input" tf:"optional,object"` + Input types.Object `tfsdk:"input" tf:"optional,object"` // Configuration for output guardrail filters. - Output []AiGatewayGuardrailParameters `tfsdk:"output" tf:"optional,object"` + Output types.Object `tfsdk:"output" tf:"optional,object"` } func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringCreateOrUpdate(plan AiGatewayGuardrails) { @@ -106,6 +132,13 @@ func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrails) { } +func (a AiGatewayGuardrails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Input": reflect.TypeOf(AiGatewayGuardrailParameters{}), + "Output": reflect.TypeOf(AiGatewayGuardrailParameters{}), + } +} + type AiGatewayInferenceTableConfig struct { // The name of the catalog in Unity Catalog. Required when enabling // inference tables. NOTE: On update, you have to disable inference table @@ -128,6 +161,10 @@ func (newState *AiGatewayInferenceTableConfig) SyncEffectiveFieldsDuringCreateOr func (newState *AiGatewayInferenceTableConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayInferenceTableConfig) { } +func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AiGatewayRateLimit struct { // Used to specify how many calls are allowed for a key within the // renewal_period. @@ -146,6 +183,10 @@ func (newState *AiGatewayRateLimit) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AiGatewayRateLimit) SyncEffectiveFieldsDuringRead(existingState AiGatewayRateLimit) { } +func (a AiGatewayRateLimit) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AiGatewayUsageTrackingConfig struct { // Whether to enable usage tracking. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -157,6 +198,10 @@ func (newState *AiGatewayUsageTrackingConfig) SyncEffectiveFieldsDuringCreateOrU func (newState *AiGatewayUsageTrackingConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayUsageTrackingConfig) { } +func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AmazonBedrockConfig struct { // The Databricks secret key reference for an AWS access key ID with // permissions to interact with Bedrock services. If you prefer to paste @@ -197,6 +242,10 @@ func (newState *AmazonBedrockConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AmazonBedrockConfig) SyncEffectiveFieldsDuringRead(existingState AmazonBedrockConfig) { } +func (a AmazonBedrockConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AnthropicConfig struct { // The Databricks secret key reference for an Anthropic API key. If you // prefer to paste your API key directly, see `anthropic_api_key_plaintext`. @@ -216,6 +265,10 @@ func (newState *AnthropicConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan An func (newState *AnthropicConfig) SyncEffectiveFieldsDuringRead(existingState AnthropicConfig) { } +func (a AnthropicConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AutoCaptureConfigInput struct { // The name of the catalog in Unity Catalog. NOTE: On update, you cannot // change the catalog name if the inference table is already enabled. @@ -236,6 +289,10 @@ func (newState *AutoCaptureConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AutoCaptureConfigInput) SyncEffectiveFieldsDuringRead(existingState AutoCaptureConfigInput) { } +func (a AutoCaptureConfigInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AutoCaptureConfigOutput struct { // The name of the catalog in Unity Catalog. CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -244,7 +301,7 @@ type AutoCaptureConfigOutput struct { // The name of the schema in Unity Catalog. SchemaName types.String `tfsdk:"schema_name" tf:"optional"` - State []AutoCaptureState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The prefix of the table in Unity Catalog. TableNamePrefix types.String `tfsdk:"table_name_prefix" tf:"optional"` } @@ -255,8 +312,14 @@ func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringRead(existingState AutoCaptureConfigOutput) { } +func (a AutoCaptureConfigOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "State": reflect.TypeOf(AutoCaptureState{}), + } +} + type AutoCaptureState struct { - PayloadTable []PayloadTable `tfsdk:"payload_table" tf:"optional,object"` + PayloadTable types.Object `tfsdk:"payload_table" tf:"optional,object"` } func (newState *AutoCaptureState) SyncEffectiveFieldsDuringCreateOrUpdate(plan AutoCaptureState) { @@ -265,6 +328,12 @@ func (newState *AutoCaptureState) SyncEffectiveFieldsDuringCreateOrUpdate(plan A func (newState *AutoCaptureState) SyncEffectiveFieldsDuringRead(existingState AutoCaptureState) { } +func (a AutoCaptureState) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PayloadTable": reflect.TypeOf(PayloadTable{}), + } +} + // Get build logs for a served model type BuildLogsRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -281,6 +350,10 @@ func (newState *BuildLogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan B func (newState *BuildLogsRequest) SyncEffectiveFieldsDuringRead(existingState BuildLogsRequest) { } +func (a BuildLogsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type BuildLogsResponse struct { // The logs associated with building the served entity's environment. Logs types.String `tfsdk:"logs" tf:""` @@ -292,6 +365,10 @@ func (newState *BuildLogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *BuildLogsResponse) SyncEffectiveFieldsDuringRead(existingState BuildLogsResponse) { } +func (a BuildLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ChatMessage struct { // The content of the message. Content types.String `tfsdk:"content" tf:"optional"` @@ -305,6 +382,10 @@ func (newState *ChatMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan ChatMe func (newState *ChatMessage) SyncEffectiveFieldsDuringRead(existingState ChatMessage) { } +func (a ChatMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CohereConfig struct { // This is an optional field to provide a customized base URL for the Cohere // API. If left unspecified, the standard Cohere base URL is used. @@ -327,24 +408,28 @@ func (newState *CohereConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Coher func (newState *CohereConfig) SyncEffectiveFieldsDuringRead(existingState CohereConfig) { } +func (a CohereConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateServingEndpoint struct { // The AI Gateway configuration for the serving endpoint. NOTE: only // external model endpoints are supported as of now. - AiGateway []AiGatewayConfig `tfsdk:"ai_gateway" tf:"optional,object"` + AiGateway types.Object `tfsdk:"ai_gateway" tf:"optional,object"` // The core config of the serving endpoint. - Config []EndpointCoreConfigInput `tfsdk:"config" tf:"object"` + Config types.Object `tfsdk:"config" tf:"object"` // The name of the serving endpoint. This field is required and must be // unique across a Databricks workspace. An endpoint name can consist of // alphanumeric characters, dashes, and underscores. Name types.String `tfsdk:"name" tf:""` // Rate limits to be applied to the serving endpoint. NOTE: this field is // deprecated, please use AI Gateway to manage rate limits. - RateLimits []RateLimit `tfsdk:"rate_limits" tf:"optional"` + RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` // Enable route optimization for the serving endpoint. RouteOptimized types.Bool `tfsdk:"route_optimized" tf:"optional"` // Tags to be attached to the serving endpoint and automatically propagated // to billing logs. - Tags []EndpointTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateServingEndpoint) { @@ -353,6 +438,15 @@ func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringRead(existingState CreateServingEndpoint) { } +func (a CreateServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AiGateway": reflect.TypeOf(AiGatewayConfig{}), + "Config": reflect.TypeOf(EndpointCoreConfigInput{}), + "RateLimits": reflect.TypeOf(RateLimit{}), + "Tags": reflect.TypeOf(EndpointTag{}), + } +} + type DatabricksModelServingConfig struct { // The Databricks secret key reference for a Databricks API token that // corresponds to a user or service principal with Can Query access to the @@ -379,12 +473,16 @@ func (newState *DatabricksModelServingConfig) SyncEffectiveFieldsDuringCreateOrU func (newState *DatabricksModelServingConfig) SyncEffectiveFieldsDuringRead(existingState DatabricksModelServingConfig) { } +func (a DatabricksModelServingConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DataframeSplitInput struct { - Columns []any `tfsdk:"columns" tf:"optional"` + Columns types.List `tfsdk:"columns" tf:"optional"` - Data []any `tfsdk:"data" tf:"optional"` + Data types.List `tfsdk:"data" tf:"optional"` - Index []types.Int64 `tfsdk:"index" tf:"optional"` + Index types.List `tfsdk:"index" tf:"optional"` } func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataframeSplitInput) { @@ -393,6 +491,14 @@ func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringRead(existingState DataframeSplitInput) { } +func (a DataframeSplitInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Columns": reflect.TypeOf(struct{}{}), + "Data": reflect.TypeOf(struct{}{}), + "Index": reflect.TypeOf(0), + } +} + type DeleteResponse struct { } @@ -402,6 +508,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a serving endpoint type DeleteServingEndpointRequest struct { // The name of the serving endpoint. This field is required. @@ -414,8 +524,12 @@ func (newState *DeleteServingEndpointRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteServingEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServingEndpointRequest) { } +func (a DeleteServingEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EmbeddingsV1ResponseEmbeddingElement struct { - Embedding []types.Float64 `tfsdk:"embedding" tf:"optional"` + Embedding types.List `tfsdk:"embedding" tf:"optional"` // The index of the embedding in the response. Index types.Int64 `tfsdk:"index" tf:"optional"` // This will always be 'embedding'. @@ -428,21 +542,27 @@ func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringC func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringRead(existingState EmbeddingsV1ResponseEmbeddingElement) { } +func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Embedding": reflect.TypeOf(0.0), + } +} + type EndpointCoreConfigInput struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. - AutoCaptureConfig []AutoCaptureConfigInput `tfsdk:"auto_capture_config" tf:"optional,object"` + AutoCaptureConfig types.Object `tfsdk:"auto_capture_config" tf:"optional,object"` // The name of the serving endpoint to update. This field is required. Name types.String `tfsdk:"-"` // A list of served entities for the endpoint to serve. A serving endpoint // can have up to 15 served entities. - ServedEntities []ServedEntityInput `tfsdk:"served_entities" tf:"optional"` + ServedEntities types.List `tfsdk:"served_entities" tf:"optional"` // (Deprecated, use served_entities instead) A list of served models for the // endpoint to serve. A serving endpoint can have up to 15 served models. - ServedModels []ServedModelInput `tfsdk:"served_models" tf:"optional"` + ServedModels types.List `tfsdk:"served_models" tf:"optional"` // The traffic config defining how invocations to the serving endpoint // should be routed. - TrafficConfig []TrafficConfig `tfsdk:"traffic_config" tf:"optional,object"` + TrafficConfig types.Object `tfsdk:"traffic_config" tf:"optional,object"` } func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointCoreConfigInput) { @@ -451,19 +571,28 @@ func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigInput) { } +func (a EndpointCoreConfigInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AutoCaptureConfig": reflect.TypeOf(AutoCaptureConfigInput{}), + "ServedEntities": reflect.TypeOf(ServedEntityInput{}), + "ServedModels": reflect.TypeOf(ServedModelInput{}), + "TrafficConfig": reflect.TypeOf(TrafficConfig{}), + } +} + type EndpointCoreConfigOutput struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. - AutoCaptureConfig []AutoCaptureConfigOutput `tfsdk:"auto_capture_config" tf:"optional,object"` + AutoCaptureConfig types.Object `tfsdk:"auto_capture_config" tf:"optional,object"` // The config version that the serving endpoint is currently serving. ConfigVersion types.Int64 `tfsdk:"config_version" tf:"optional"` // The list of served entities under the serving endpoint config. - ServedEntities []ServedEntityOutput `tfsdk:"served_entities" tf:"optional"` + ServedEntities types.List `tfsdk:"served_entities" tf:"optional"` // (Deprecated, use served_entities instead) The list of served models under // the serving endpoint config. - ServedModels []ServedModelOutput `tfsdk:"served_models" tf:"optional"` + ServedModels types.List `tfsdk:"served_models" tf:"optional"` // The traffic configuration associated with the serving endpoint config. - TrafficConfig []TrafficConfig `tfsdk:"traffic_config" tf:"optional,object"` + TrafficConfig types.Object `tfsdk:"traffic_config" tf:"optional,object"` } func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointCoreConfigOutput) { @@ -472,12 +601,21 @@ func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigOutput) { } +func (a EndpointCoreConfigOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AutoCaptureConfig": reflect.TypeOf(AutoCaptureConfigOutput{}), + "ServedEntities": reflect.TypeOf(ServedEntityOutput{}), + "ServedModels": reflect.TypeOf(ServedModelOutput{}), + "TrafficConfig": reflect.TypeOf(TrafficConfig{}), + } +} + type EndpointCoreConfigSummary struct { // The list of served entities under the serving endpoint config. - ServedEntities []ServedEntitySpec `tfsdk:"served_entities" tf:"optional"` + ServedEntities types.List `tfsdk:"served_entities" tf:"optional"` // (Deprecated, use served_entities instead) The list of served models under // the serving endpoint config. - ServedModels []ServedModelSpec `tfsdk:"served_models" tf:"optional"` + ServedModels types.List `tfsdk:"served_models" tf:"optional"` } func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointCoreConfigSummary) { @@ -486,23 +624,30 @@ func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringCreateOrUpda func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigSummary) { } +func (a EndpointCoreConfigSummary) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ServedEntities": reflect.TypeOf(ServedEntitySpec{}), + "ServedModels": reflect.TypeOf(ServedModelSpec{}), + } +} + type EndpointPendingConfig struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. - AutoCaptureConfig []AutoCaptureConfigOutput `tfsdk:"auto_capture_config" tf:"optional,object"` + AutoCaptureConfig types.Object `tfsdk:"auto_capture_config" tf:"optional,object"` // The config version that the serving endpoint is currently serving. ConfigVersion types.Int64 `tfsdk:"config_version" tf:"optional"` // The list of served entities belonging to the last issued update to the // serving endpoint. - ServedEntities []ServedEntityOutput `tfsdk:"served_entities" tf:"optional"` + ServedEntities types.List `tfsdk:"served_entities" tf:"optional"` // (Deprecated, use served_entities instead) The list of served models // belonging to the last issued update to the serving endpoint. - ServedModels []ServedModelOutput `tfsdk:"served_models" tf:"optional"` + ServedModels types.List `tfsdk:"served_models" tf:"optional"` // The timestamp when the update to the pending config started. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // The traffic config defining how invocations to the serving endpoint // should be routed. - TrafficConfig []TrafficConfig `tfsdk:"traffic_config" tf:"optional,object"` + TrafficConfig types.Object `tfsdk:"traffic_config" tf:"optional,object"` } func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointPendingConfig) { @@ -511,6 +656,15 @@ func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringRead(existingState EndpointPendingConfig) { } +func (a EndpointPendingConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AutoCaptureConfig": reflect.TypeOf(AutoCaptureConfigOutput{}), + "ServedEntities": reflect.TypeOf(ServedEntityOutput{}), + "ServedModels": reflect.TypeOf(ServedModelOutput{}), + "TrafficConfig": reflect.TypeOf(TrafficConfig{}), + } +} + type EndpointState struct { // The state of an endpoint's config update. This informs the user if the // pending_config is in progress, if the update failed, or if there is no @@ -531,6 +685,10 @@ func (newState *EndpointState) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endp func (newState *EndpointState) SyncEffectiveFieldsDuringRead(existingState EndpointState) { } +func (a EndpointState) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EndpointTag struct { // Key field for a serving endpoint tag. Key types.String `tfsdk:"key" tf:""` @@ -544,6 +702,10 @@ func (newState *EndpointTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpoi func (newState *EndpointTag) SyncEffectiveFieldsDuringRead(existingState EndpointTag) { } +func (a EndpointTag) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get metrics of a serving endpoint type ExportMetricsRequest struct { // The name of the serving endpoint to retrieve metrics for. This field is @@ -557,6 +719,10 @@ func (newState *ExportMetricsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExportMetricsRequest) SyncEffectiveFieldsDuringRead(existingState ExportMetricsRequest) { } +func (a ExportMetricsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExportMetricsResponse struct { Contents io.ReadCloser `tfsdk:"-"` } @@ -567,27 +733,31 @@ func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringRead(existingState ExportMetricsResponse) { } +func (a ExportMetricsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExternalModel struct { // AI21Labs Config. Only required if the provider is 'ai21labs'. - Ai21labsConfig []Ai21LabsConfig `tfsdk:"ai21labs_config" tf:"optional,object"` + Ai21labsConfig types.Object `tfsdk:"ai21labs_config" tf:"optional,object"` // Amazon Bedrock Config. Only required if the provider is 'amazon-bedrock'. - AmazonBedrockConfig []AmazonBedrockConfig `tfsdk:"amazon_bedrock_config" tf:"optional,object"` + AmazonBedrockConfig types.Object `tfsdk:"amazon_bedrock_config" tf:"optional,object"` // Anthropic Config. Only required if the provider is 'anthropic'. - AnthropicConfig []AnthropicConfig `tfsdk:"anthropic_config" tf:"optional,object"` + AnthropicConfig types.Object `tfsdk:"anthropic_config" tf:"optional,object"` // Cohere Config. Only required if the provider is 'cohere'. - CohereConfig []CohereConfig `tfsdk:"cohere_config" tf:"optional,object"` + CohereConfig types.Object `tfsdk:"cohere_config" tf:"optional,object"` // Databricks Model Serving Config. Only required if the provider is // 'databricks-model-serving'. - DatabricksModelServingConfig []DatabricksModelServingConfig `tfsdk:"databricks_model_serving_config" tf:"optional,object"` + DatabricksModelServingConfig types.Object `tfsdk:"databricks_model_serving_config" tf:"optional,object"` // Google Cloud Vertex AI Config. Only required if the provider is // 'google-cloud-vertex-ai'. - GoogleCloudVertexAiConfig []GoogleCloudVertexAiConfig `tfsdk:"google_cloud_vertex_ai_config" tf:"optional,object"` + GoogleCloudVertexAiConfig types.Object `tfsdk:"google_cloud_vertex_ai_config" tf:"optional,object"` // The name of the external model. Name types.String `tfsdk:"name" tf:""` // OpenAI Config. Only required if the provider is 'openai'. - OpenaiConfig []OpenAiConfig `tfsdk:"openai_config" tf:"optional,object"` + OpenaiConfig types.Object `tfsdk:"openai_config" tf:"optional,object"` // PaLM Config. Only required if the provider is 'palm'. - PalmConfig []PaLmConfig `tfsdk:"palm_config" tf:"optional,object"` + PalmConfig types.Object `tfsdk:"palm_config" tf:"optional,object"` // The name of the provider for the external model. Currently, the supported // providers are 'ai21labs', 'anthropic', 'amazon-bedrock', 'cohere', // 'databricks-model-serving', 'google-cloud-vertex-ai', 'openai', and @@ -603,6 +773,19 @@ func (newState *ExternalModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exte func (newState *ExternalModel) SyncEffectiveFieldsDuringRead(existingState ExternalModel) { } +func (a ExternalModel) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Ai21labsConfig": reflect.TypeOf(Ai21LabsConfig{}), + "AmazonBedrockConfig": reflect.TypeOf(AmazonBedrockConfig{}), + "AnthropicConfig": reflect.TypeOf(AnthropicConfig{}), + "CohereConfig": reflect.TypeOf(CohereConfig{}), + "DatabricksModelServingConfig": reflect.TypeOf(DatabricksModelServingConfig{}), + "GoogleCloudVertexAiConfig": reflect.TypeOf(GoogleCloudVertexAiConfig{}), + "OpenaiConfig": reflect.TypeOf(OpenAiConfig{}), + "PalmConfig": reflect.TypeOf(PaLmConfig{}), + } +} + type ExternalModelUsageElement struct { // The number of tokens in the chat/completions response. CompletionTokens types.Int64 `tfsdk:"completion_tokens" tf:"optional"` @@ -618,6 +801,10 @@ func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringRead(existingState ExternalModelUsageElement) { } +func (a ExternalModelUsageElement) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type FoundationModel struct { // The description of the foundation model. Description types.String `tfsdk:"description" tf:"optional"` @@ -635,6 +822,10 @@ func (newState *FoundationModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Fo func (newState *FoundationModel) SyncEffectiveFieldsDuringRead(existingState FoundationModel) { } +func (a FoundationModel) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the schema for a serving endpoint type GetOpenApiRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -648,6 +839,10 @@ func (newState *GetOpenApiRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetOpenApiRequest) SyncEffectiveFieldsDuringRead(existingState GetOpenApiRequest) { } +func (a GetOpenApiRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The response is an OpenAPI spec in JSON format that typically includes fields // like openapi, info, servers and paths, etc. type GetOpenApiResponse struct { @@ -659,6 +854,10 @@ func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringRead(existingState GetOpenApiResponse) { } +func (a GetOpenApiResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get serving endpoint permission levels type GetServingEndpointPermissionLevelsRequest struct { // The serving endpoint for which to get or manage permissions. @@ -671,9 +870,13 @@ func (newState *GetServingEndpointPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetServingEndpointPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionLevelsRequest) { } +func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetServingEndpointPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []ServingEndpointPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetServingEndpointPermissionLevelsResponse) { @@ -682,6 +885,12 @@ func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionLevelsResponse) { } +func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(ServingEndpointPermissionsDescription{}), + } +} + // Get serving endpoint permissions type GetServingEndpointPermissionsRequest struct { // The serving endpoint for which to get or manage permissions. @@ -694,6 +903,10 @@ func (newState *GetServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionsRequest) { } +func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a single serving endpoint type GetServingEndpointRequest struct { // The name of the serving endpoint. This field is required. @@ -706,6 +919,10 @@ func (newState *GetServingEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetServingEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointRequest) { } +func (a GetServingEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GoogleCloudVertexAiConfig struct { // The Databricks secret key reference for a private key for the service // account which has access to the Google Cloud Vertex AI Service. See [Best @@ -742,9 +959,13 @@ func (newState *GoogleCloudVertexAiConfig) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GoogleCloudVertexAiConfig) SyncEffectiveFieldsDuringRead(existingState GoogleCloudVertexAiConfig) { } +func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListEndpointsResponse struct { // The list of endpoints. - Endpoints []ServingEndpoint `tfsdk:"endpoints" tf:"optional"` + Endpoints types.List `tfsdk:"endpoints" tf:"optional"` } func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListEndpointsResponse) { @@ -753,6 +974,12 @@ func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringRead(existingState ListEndpointsResponse) { } +func (a ListEndpointsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Endpoints": reflect.TypeOf(ServingEndpoint{}), + } +} + // Get the latest logs for a served model type LogsRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -769,6 +996,10 @@ func (newState *LogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogsRe func (newState *LogsRequest) SyncEffectiveFieldsDuringRead(existingState LogsRequest) { } +func (a LogsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ModelDataPlaneInfo struct { // Information required to query DataPlane API 'query' endpoint. QueryInfo oauth2.DataPlaneInfo `tfsdk:"query_info" tf:"optional,object"` @@ -780,6 +1011,12 @@ func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState ModelDataPlaneInfo) { } +func (a ModelDataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "QueryInfo": reflect.TypeOf(oauth2.DataPlaneInfo{}), + } +} + type OpenAiConfig struct { // This field is only required for Azure AD OpenAI and is the Microsoft // Entra Client ID. @@ -840,6 +1077,10 @@ func (newState *OpenAiConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan OpenA func (newState *OpenAiConfig) SyncEffectiveFieldsDuringRead(existingState OpenAiConfig) { } +func (a OpenAiConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PaLmConfig struct { // The Databricks secret key reference for a PaLM API key. If you prefer to // paste your API key directly, see `palm_api_key_plaintext`. You must @@ -859,11 +1100,15 @@ func (newState *PaLmConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan PaLmCon func (newState *PaLmConfig) SyncEffectiveFieldsDuringRead(existingState PaLmConfig) { } +func (a PaLmConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PatchServingEndpointTags struct { // List of endpoint tags to add - AddTags []EndpointTag `tfsdk:"add_tags" tf:"optional"` + AddTags types.List `tfsdk:"add_tags" tf:"optional"` // List of tag keys to delete - DeleteTags []types.String `tfsdk:"delete_tags" tf:"optional"` + DeleteTags types.List `tfsdk:"delete_tags" tf:"optional"` // The name of the serving endpoint who's tags to patch. This field is // required. Name types.String `tfsdk:"-"` @@ -875,6 +1120,13 @@ func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringRead(existingState PatchServingEndpointTags) { } +func (a PatchServingEndpointTags) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AddTags": reflect.TypeOf(EndpointTag{}), + "DeleteTags": reflect.TypeOf(""), + } +} + type PayloadTable struct { // The name of the payload table. Name types.String `tfsdk:"name" tf:"optional"` @@ -890,24 +1142,28 @@ func (newState *PayloadTable) SyncEffectiveFieldsDuringCreateOrUpdate(plan Paylo func (newState *PayloadTable) SyncEffectiveFieldsDuringRead(existingState PayloadTable) { } +func (a PayloadTable) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Update AI Gateway of a serving endpoint type PutAiGatewayRequest struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. - Guardrails []AiGatewayGuardrails `tfsdk:"guardrails" tf:"optional,object"` + Guardrails types.Object `tfsdk:"guardrails" tf:"optional,object"` // Configuration for payload logging using inference tables. Use these // tables to monitor and audit data being sent to and received from model // APIs and to improve model quality. - InferenceTableConfig []AiGatewayInferenceTableConfig `tfsdk:"inference_table_config" tf:"optional,object"` + InferenceTableConfig types.Object `tfsdk:"inference_table_config" tf:"optional,object"` // The name of the serving endpoint whose AI Gateway is being updated. This // field is required. Name types.String `tfsdk:"-"` // Configuration for rate limits which can be set to limit endpoint traffic. - RateLimits []AiGatewayRateLimit `tfsdk:"rate_limits" tf:"optional"` + RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` // Configuration to enable usage tracking using system tables. These tables // allow you to monitor operational usage on endpoints and their associated // costs. - UsageTrackingConfig []AiGatewayUsageTrackingConfig `tfsdk:"usage_tracking_config" tf:"optional,object"` + UsageTrackingConfig types.Object `tfsdk:"usage_tracking_config" tf:"optional,object"` } func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAiGatewayRequest) { @@ -916,20 +1172,29 @@ func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringRead(existingState PutAiGatewayRequest) { } +func (a PutAiGatewayRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Guardrails": reflect.TypeOf(AiGatewayGuardrails{}), + "InferenceTableConfig": reflect.TypeOf(AiGatewayInferenceTableConfig{}), + "RateLimits": reflect.TypeOf(AiGatewayRateLimit{}), + "UsageTrackingConfig": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), + } +} + type PutAiGatewayResponse struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. - Guardrails []AiGatewayGuardrails `tfsdk:"guardrails" tf:"optional,object"` + Guardrails types.Object `tfsdk:"guardrails" tf:"optional,object"` // Configuration for payload logging using inference tables. Use these // tables to monitor and audit data being sent to and received from model // APIs and to improve model quality . - InferenceTableConfig []AiGatewayInferenceTableConfig `tfsdk:"inference_table_config" tf:"optional,object"` + InferenceTableConfig types.Object `tfsdk:"inference_table_config" tf:"optional,object"` // Configuration for rate limits which can be set to limit endpoint traffic. - RateLimits []AiGatewayRateLimit `tfsdk:"rate_limits" tf:"optional"` + RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` // Configuration to enable usage tracking using system tables. These tables // allow you to monitor operational usage on endpoints and their associated // costs. - UsageTrackingConfig []AiGatewayUsageTrackingConfig `tfsdk:"usage_tracking_config" tf:"optional,object"` + UsageTrackingConfig types.Object `tfsdk:"usage_tracking_config" tf:"optional,object"` } func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAiGatewayResponse) { @@ -938,13 +1203,22 @@ func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringRead(existingState PutAiGatewayResponse) { } +func (a PutAiGatewayResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Guardrails": reflect.TypeOf(AiGatewayGuardrails{}), + "InferenceTableConfig": reflect.TypeOf(AiGatewayInferenceTableConfig{}), + "RateLimits": reflect.TypeOf(AiGatewayRateLimit{}), + "UsageTrackingConfig": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), + } +} + // Update rate limits of a serving endpoint type PutRequest struct { // The name of the serving endpoint whose rate limits are being updated. // This field is required. Name types.String `tfsdk:"-"` // The list of endpoint rate limits. - RateLimits []RateLimit `tfsdk:"rate_limits" tf:"optional"` + RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` } func (newState *PutRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRequest) { @@ -953,9 +1227,15 @@ func (newState *PutRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRequ func (newState *PutRequest) SyncEffectiveFieldsDuringRead(existingState PutRequest) { } +func (a PutRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RateLimits": reflect.TypeOf(RateLimit{}), + } +} + type PutResponse struct { // The list of endpoint rate limits. - RateLimits []RateLimit `tfsdk:"rate_limits" tf:"optional"` + RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` } func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutResponse) { @@ -964,16 +1244,22 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRes func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResponse) { } +func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RateLimits": reflect.TypeOf(RateLimit{}), + } +} + type QueryEndpointInput struct { // Pandas Dataframe input in the records orientation. - DataframeRecords []any `tfsdk:"dataframe_records" tf:"optional"` + DataframeRecords types.List `tfsdk:"dataframe_records" tf:"optional"` // Pandas Dataframe input in the split orientation. - DataframeSplit []DataframeSplitInput `tfsdk:"dataframe_split" tf:"optional,object"` + DataframeSplit types.Object `tfsdk:"dataframe_split" tf:"optional,object"` // The extra parameters field used ONLY for __completions, chat,__ and // __embeddings external & foundation model__ serving endpoints. This is a // map of strings and should only be used with other external/foundation // model query fields. - ExtraParams map[string]types.String `tfsdk:"extra_params" tf:"optional"` + ExtraParams types.Map `tfsdk:"extra_params" tf:"optional"` // The input string (or array of strings) field used ONLY for __embeddings // external & foundation model__ serving endpoints and is the only field // (along with extra_params if needed) used by embeddings queries. @@ -981,7 +1267,7 @@ type QueryEndpointInput struct { // Tensor-based input in columnar format. Inputs any `tfsdk:"inputs" tf:"optional"` // Tensor-based input in row format. - Instances []any `tfsdk:"instances" tf:"optional"` + Instances types.List `tfsdk:"instances" tf:"optional"` // The max tokens field used ONLY for __completions__ and __chat external & // foundation model__ serving endpoints. This is an integer and should only // be used with other chat/completions query fields. @@ -989,7 +1275,7 @@ type QueryEndpointInput struct { // The messages field used ONLY for __chat external & foundation model__ // serving endpoints. This is a map of strings and should only be used with // other chat query fields. - Messages []ChatMessage `tfsdk:"messages" tf:"optional"` + Messages types.List `tfsdk:"messages" tf:"optional"` // The n (number of candidates) field used ONLY for __completions__ and // __chat external & foundation model__ serving endpoints. This is an // integer between 1 and 5 with a default of 1 and should only be used with @@ -1004,7 +1290,7 @@ type QueryEndpointInput struct { // The stop sequences field used ONLY for __completions__ and __chat // external & foundation model__ serving endpoints. This is a list of // strings and should only be used with other chat/completions query fields. - Stop []types.String `tfsdk:"stop" tf:"optional"` + Stop types.List `tfsdk:"stop" tf:"optional"` // The stream field used ONLY for __completions__ and __chat external & // foundation model__ serving endpoints. This is a boolean defaulting to // false and should only be used with other chat/completions query fields. @@ -1022,16 +1308,27 @@ func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringRead(existingState QueryEndpointInput) { } +func (a QueryEndpointInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataframeRecords": reflect.TypeOf(struct{}{}), + "DataframeSplit": reflect.TypeOf(DataframeSplitInput{}), + "ExtraParams": reflect.TypeOf(""), + "Instances": reflect.TypeOf(struct{}{}), + "Messages": reflect.TypeOf(ChatMessage{}), + "Stop": reflect.TypeOf(""), + } +} + type QueryEndpointResponse struct { // The list of choices returned by the __chat or completions // external/foundation model__ serving endpoint. - Choices []V1ResponseChoiceElement `tfsdk:"choices" tf:"optional"` + Choices types.List `tfsdk:"choices" tf:"optional"` // The timestamp in seconds when the query was created in Unix time returned // by a __completions or chat external/foundation model__ serving endpoint. Created types.Int64 `tfsdk:"created" tf:"optional"` // The list of the embeddings returned by the __embeddings // external/foundation model__ serving endpoint. - Data []EmbeddingsV1ResponseEmbeddingElement `tfsdk:"data" tf:"optional"` + Data types.List `tfsdk:"data" tf:"optional"` // The ID of the query that may be returned by a __completions or chat // external/foundation model__ serving endpoint. Id types.String `tfsdk:"id" tf:"optional"` @@ -1043,14 +1340,14 @@ type QueryEndpointResponse struct { // embeddings)]. Object types.String `tfsdk:"object" tf:"optional"` // The predictions returned by the serving endpoint. - Predictions []any `tfsdk:"predictions" tf:"optional"` + Predictions types.List `tfsdk:"predictions" tf:"optional"` // The name of the served model that served the request. This is useful when // there are multiple models behind the same endpoint with traffic split. ServedModelName types.String `tfsdk:"-"` // The usage object that may be returned by the __external/foundation // model__ serving endpoint. This contains information about the number of // tokens used in the prompt and response. - Usage []ExternalModelUsageElement `tfsdk:"usage" tf:"optional,object"` + Usage types.Object `tfsdk:"usage" tf:"optional,object"` } func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryEndpointResponse) { @@ -1059,6 +1356,15 @@ func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringRead(existingState QueryEndpointResponse) { } +func (a QueryEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Choices": reflect.TypeOf(V1ResponseChoiceElement{}), + "Data": reflect.TypeOf(EmbeddingsV1ResponseEmbeddingElement{}), + "Predictions": reflect.TypeOf(struct{}{}), + "Usage": reflect.TypeOf(ExternalModelUsageElement{}), + } +} + type RateLimit struct { // Used to specify how many calls are allowed for a key within the // renewal_period. @@ -1078,6 +1384,10 @@ func (newState *RateLimit) SyncEffectiveFieldsDuringCreateOrUpdate(plan RateLimi func (newState *RateLimit) SyncEffectiveFieldsDuringRead(existingState RateLimit) { } +func (a RateLimit) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Route struct { // The name of the served model this route configures traffic for. ServedModelName types.String `tfsdk:"served_model_name" tf:""` @@ -1092,6 +1402,10 @@ func (newState *Route) SyncEffectiveFieldsDuringCreateOrUpdate(plan Route) { func (newState *Route) SyncEffectiveFieldsDuringRead(existingState Route) { } +func (a Route) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ServedEntityInput struct { // The name of the entity to be served. The entity may be a model in the // Databricks Model Registry, a model in the Unity Catalog (UC), or a @@ -1108,7 +1422,7 @@ type ServedEntityInput struct { // variables that refer to Databricks secrets: `{"OPENAI_API_KEY": // "{{secrets/my_scope/my_key}}", "DATABRICKS_TOKEN": // "{{secrets/my_scope2/my_key2}}"}` - EnvironmentVars map[string]types.String `tfsdk:"environment_vars" tf:"optional"` + EnvironmentVars types.Map `tfsdk:"environment_vars" tf:"optional"` // The external model to be served. NOTE: Only one of external_model and // (entity_name, entity_version, workload_size, workload_type, and // scale_to_zero_enabled) can be specified with the latter set being used @@ -1117,7 +1431,7 @@ type ServedEntityInput struct { // endpoint without external_model. If the endpoint is created without // external_model, users cannot update it to add external_model later. The // task type of all external models within an endpoint must be the same. - ExternalModel []ExternalModel `tfsdk:"external_model" tf:"optional,object"` + ExternalModel types.Object `tfsdk:"external_model" tf:"optional,object"` // ARN of the instance profile that the served entity uses to access AWS // resources. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:"optional"` @@ -1159,6 +1473,13 @@ func (newState *ServedEntityInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedEntityInput) SyncEffectiveFieldsDuringRead(existingState ServedEntityInput) { } +func (a ServedEntityInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EnvironmentVars": reflect.TypeOf(""), + "ExternalModel": reflect.TypeOf(ExternalModel{}), + } +} + type ServedEntityOutput struct { // The creation timestamp of the served entity in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1179,17 +1500,17 @@ type ServedEntityOutput struct { // variables that refer to Databricks secrets: `{"OPENAI_API_KEY": // "{{secrets/my_scope/my_key}}", "DATABRICKS_TOKEN": // "{{secrets/my_scope2/my_key2}}"}` - EnvironmentVars map[string]types.String `tfsdk:"environment_vars" tf:"optional"` + EnvironmentVars types.Map `tfsdk:"environment_vars" tf:"optional"` // The external model that is served. NOTE: Only one of external_model, // foundation_model, and (entity_name, entity_version, workload_size, // workload_type, and scale_to_zero_enabled) is returned based on the // endpoint type. - ExternalModel []ExternalModel `tfsdk:"external_model" tf:"optional,object"` + ExternalModel types.Object `tfsdk:"external_model" tf:"optional,object"` // The foundation model that is served. NOTE: Only one of foundation_model, // external_model, and (entity_name, entity_version, workload_size, // workload_type, and scale_to_zero_enabled) is returned based on the // endpoint type. - FoundationModel []FoundationModel `tfsdk:"foundation_model" tf:"optional,object"` + FoundationModel types.Object `tfsdk:"foundation_model" tf:"optional,object"` // ARN of the instance profile that the served entity uses to access AWS // resources. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:"optional"` @@ -1203,7 +1524,7 @@ type ServedEntityOutput struct { // zero. ScaleToZeroEnabled types.Bool `tfsdk:"scale_to_zero_enabled" tf:"optional"` // Information corresponding to the state of the served entity. - State []ServedModelState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The workload size of the served entity. The workload size corresponds to // a range of provisioned concurrency that the compute autoscales between. A // single unit of provisioned concurrency can process one request at a time. @@ -1228,6 +1549,15 @@ func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringRead(existingState ServedEntityOutput) { } +func (a ServedEntityOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EnvironmentVars": reflect.TypeOf(""), + "ExternalModel": reflect.TypeOf(ExternalModel{}), + "FoundationModel": reflect.TypeOf(FoundationModel{}), + "State": reflect.TypeOf(ServedModelState{}), + } +} + type ServedEntitySpec struct { // The name of the entity served. The entity may be a model in the // Databricks Model Registry, a model in the Unity Catalog (UC), or a @@ -1241,11 +1571,11 @@ type ServedEntitySpec struct { // The external model that is served. NOTE: Only one of external_model, // foundation_model, and (entity_name, entity_version) is returned based on // the endpoint type. - ExternalModel []ExternalModel `tfsdk:"external_model" tf:"optional,object"` + ExternalModel types.Object `tfsdk:"external_model" tf:"optional,object"` // The foundation model that is served. NOTE: Only one of foundation_model, // external_model, and (entity_name, entity_version) is returned based on // the endpoint type. - FoundationModel []FoundationModel `tfsdk:"foundation_model" tf:"optional,object"` + FoundationModel types.Object `tfsdk:"foundation_model" tf:"optional,object"` // The name of the served entity. Name types.String `tfsdk:"name" tf:"optional"` } @@ -1256,6 +1586,13 @@ func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringRead(existingState ServedEntitySpec) { } +func (a ServedEntitySpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ExternalModel": reflect.TypeOf(ExternalModel{}), + "FoundationModel": reflect.TypeOf(FoundationModel{}), + } +} + type ServedModelInput struct { // An object containing a set of optional, user-specified environment // variable key-value pairs used for serving this model. Note: this is an @@ -1263,7 +1600,7 @@ type ServedModelInput struct { // variables that refer to Databricks secrets: `{"OPENAI_API_KEY": // "{{secrets/my_scope/my_key}}", "DATABRICKS_TOKEN": // "{{secrets/my_scope2/my_key2}}"}` - EnvironmentVars map[string]types.String `tfsdk:"environment_vars" tf:"optional"` + EnvironmentVars types.Map `tfsdk:"environment_vars" tf:"optional"` // ARN of the instance profile that the served model will use to access AWS // resources. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:"optional"` @@ -1310,6 +1647,12 @@ func (newState *ServedModelInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedModelInput) SyncEffectiveFieldsDuringRead(existingState ServedModelInput) { } +func (a ServedModelInput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EnvironmentVars": reflect.TypeOf(""), + } +} + type ServedModelOutput struct { // The creation timestamp of the served model in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1321,7 +1664,7 @@ type ServedModelOutput struct { // variables that refer to Databricks secrets: `{"OPENAI_API_KEY": // "{{secrets/my_scope/my_key}}", "DATABRICKS_TOKEN": // "{{secrets/my_scope2/my_key2}}"}` - EnvironmentVars map[string]types.String `tfsdk:"environment_vars" tf:"optional"` + EnvironmentVars types.Map `tfsdk:"environment_vars" tf:"optional"` // ARN of the instance profile that the served model will use to access AWS // resources. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:"optional"` @@ -1337,7 +1680,7 @@ type ServedModelOutput struct { // zero. ScaleToZeroEnabled types.Bool `tfsdk:"scale_to_zero_enabled" tf:"optional"` // Information corresponding to the state of the Served Model. - State []ServedModelState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // The workload size of the served model. The workload size corresponds to a // range of provisioned concurrency that the compute will autoscale between. // A single unit of provisioned concurrency can process one request at a @@ -1362,6 +1705,13 @@ func (newState *ServedModelOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedModelOutput) SyncEffectiveFieldsDuringRead(existingState ServedModelOutput) { } +func (a ServedModelOutput) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EnvironmentVars": reflect.TypeOf(""), + "State": reflect.TypeOf(ServedModelState{}), + } +} + type ServedModelSpec struct { // The name of the model in Databricks Model Registry or the full name of // the model in Unity Catalog. @@ -1379,6 +1729,10 @@ func (newState *ServedModelSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Se func (newState *ServedModelSpec) SyncEffectiveFieldsDuringRead(existingState ServedModelSpec) { } +func (a ServedModelSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ServedModelState struct { // The state of the served entity deployment. DEPLOYMENT_CREATING indicates // that the served entity is not ready yet because the deployment is still @@ -1403,6 +1757,10 @@ func (newState *ServedModelState) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedModelState) SyncEffectiveFieldsDuringRead(existingState ServedModelState) { } +func (a ServedModelState) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ServerLogsResponse struct { // The most recent log lines of the model server processing invocation // requests. @@ -1415,12 +1773,16 @@ func (newState *ServerLogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServerLogsResponse) SyncEffectiveFieldsDuringRead(existingState ServerLogsResponse) { } +func (a ServerLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ServingEndpoint struct { // The AI Gateway configuration for the serving endpoint. NOTE: Only // external model endpoints are currently supported. - AiGateway []AiGatewayConfig `tfsdk:"ai_gateway" tf:"optional,object"` + AiGateway types.Object `tfsdk:"ai_gateway" tf:"optional,object"` // The config that is currently being served by the endpoint. - Config []EndpointCoreConfigSummary `tfsdk:"config" tf:"optional,object"` + Config types.Object `tfsdk:"config" tf:"optional,object"` // The timestamp when the endpoint was created in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` // The email of the user who created the serving endpoint. @@ -1433,9 +1795,9 @@ type ServingEndpoint struct { // The name of the serving endpoint. Name types.String `tfsdk:"name" tf:"optional"` // Information corresponding to the state of the serving endpoint. - State []EndpointState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // Tags attached to the serving endpoint. - Tags []EndpointTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // The task type of the serving endpoint. Task types.String `tfsdk:"task" tf:"optional"` } @@ -1446,6 +1808,15 @@ func (newState *ServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Se func (newState *ServingEndpoint) SyncEffectiveFieldsDuringRead(existingState ServingEndpoint) { } +func (a ServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AiGateway": reflect.TypeOf(AiGatewayConfig{}), + "Config": reflect.TypeOf(EndpointCoreConfigSummary{}), + "State": reflect.TypeOf(EndpointState{}), + "Tags": reflect.TypeOf(EndpointTag{}), + } +} + type ServingEndpointAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1463,9 +1834,13 @@ func (newState *ServingEndpointAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *ServingEndpointAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ServingEndpointAccessControlRequest) { } +func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ServingEndpointAccessControlResponse struct { // All permissions. - AllPermissions []ServingEndpointPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -1482,18 +1857,24 @@ func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ServingEndpointAccessControlResponse) { } +func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(ServingEndpointPermission{}), + } +} + type ServingEndpointDetailed struct { // The AI Gateway configuration for the serving endpoint. NOTE: Only // external model endpoints are currently supported. - AiGateway []AiGatewayConfig `tfsdk:"ai_gateway" tf:"optional,object"` + AiGateway types.Object `tfsdk:"ai_gateway" tf:"optional,object"` // The config that is currently being served by the endpoint. - Config []EndpointCoreConfigOutput `tfsdk:"config" tf:"optional,object"` + Config types.Object `tfsdk:"config" tf:"optional,object"` // The timestamp when the endpoint was created in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` // The email of the user who created the serving endpoint. Creator types.String `tfsdk:"creator" tf:"optional"` // Information required to query DataPlane APIs. - DataPlaneInfo []ModelDataPlaneInfo `tfsdk:"data_plane_info" tf:"optional,object"` + DataPlaneInfo types.Object `tfsdk:"data_plane_info" tf:"optional,object"` // Endpoint invocation url if route optimization is enabled for endpoint EndpointUrl types.String `tfsdk:"endpoint_url" tf:"optional"` // System-generated ID of the endpoint. This is used to refer to the @@ -1504,16 +1885,16 @@ type ServingEndpointDetailed struct { // The name of the serving endpoint. Name types.String `tfsdk:"name" tf:"optional"` // The config that the endpoint is attempting to update to. - PendingConfig []EndpointPendingConfig `tfsdk:"pending_config" tf:"optional,object"` + PendingConfig types.Object `tfsdk:"pending_config" tf:"optional,object"` // The permission level of the principal making the request. PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` // Boolean representing if route optimization has been enabled for the // endpoint RouteOptimized types.Bool `tfsdk:"route_optimized" tf:"optional"` // Information corresponding to the state of the serving endpoint. - State []EndpointState `tfsdk:"state" tf:"optional,object"` + State types.Object `tfsdk:"state" tf:"optional,object"` // Tags attached to the serving endpoint. - Tags []EndpointTag `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // The task type of the serving endpoint. Task types.String `tfsdk:"task" tf:"optional"` } @@ -1524,10 +1905,21 @@ func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringRead(existingState ServingEndpointDetailed) { } +func (a ServingEndpointDetailed) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AiGateway": reflect.TypeOf(AiGatewayConfig{}), + "Config": reflect.TypeOf(EndpointCoreConfigOutput{}), + "DataPlaneInfo": reflect.TypeOf(ModelDataPlaneInfo{}), + "PendingConfig": reflect.TypeOf(EndpointPendingConfig{}), + "State": reflect.TypeOf(EndpointState{}), + "Tags": reflect.TypeOf(EndpointTag{}), + } +} + type ServingEndpointPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -1538,8 +1930,14 @@ func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermission) { } +func (a ServingEndpointPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type ServingEndpointPermissions struct { - AccessControlList []ServingEndpointAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -1552,6 +1950,12 @@ func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissions) { } +func (a ServingEndpointPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ServingEndpointAccessControlResponse{}), + } +} + type ServingEndpointPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1564,8 +1968,12 @@ func (newState *ServingEndpointPermissionsDescription) SyncEffectiveFieldsDuring func (newState *ServingEndpointPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissionsDescription) { } +func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ServingEndpointPermissionsRequest struct { - AccessControlList []ServingEndpointAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The serving endpoint for which to get or manage permissions. ServingEndpointId types.String `tfsdk:"-"` } @@ -1576,9 +1984,15 @@ func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissionsRequest) { } +func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(ServingEndpointAccessControlRequest{}), + } +} + type TrafficConfig struct { // The list of routes that define traffic to each served entity. - Routes []Route `tfsdk:"routes" tf:"optional"` + Routes types.List `tfsdk:"routes" tf:"optional"` } func (newState *TrafficConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan TrafficConfig) { @@ -1587,6 +2001,12 @@ func (newState *TrafficConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Traf func (newState *TrafficConfig) SyncEffectiveFieldsDuringRead(existingState TrafficConfig) { } +func (a TrafficConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Routes": reflect.TypeOf(Route{}), + } +} + type V1ResponseChoiceElement struct { // The finish reason returned by the endpoint. FinishReason types.String `tfsdk:"finishReason" tf:"optional"` @@ -1595,7 +2015,7 @@ type V1ResponseChoiceElement struct { // The logprobs returned only by the __completions__ endpoint. Logprobs types.Int64 `tfsdk:"logprobs" tf:"optional"` // The message response from the __chat__ endpoint. - Message []ChatMessage `tfsdk:"message" tf:"optional,object"` + Message types.Object `tfsdk:"message" tf:"optional,object"` // The text response from the __completions__ endpoint. Text types.String `tfsdk:"text" tf:"optional"` } @@ -1605,3 +2025,9 @@ func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringRead(existingState V1ResponseChoiceElement) { } + +func (a V1ResponseChoiceElement) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Message": reflect.TypeOf(ChatMessage{}), + } +} diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index e34e7c4d5f..23417eda2e 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package settings_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -24,8 +26,12 @@ func (newState *AibiDashboardEmbeddingAccessPolicy) SyncEffectiveFieldsDuringCre func (newState *AibiDashboardEmbeddingAccessPolicy) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingAccessPolicy) { } +func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AibiDashboardEmbeddingAccessPolicySetting struct { - AibiDashboardEmbeddingAccessPolicy []AibiDashboardEmbeddingAccessPolicy `tfsdk:"aibi_dashboard_embedding_access_policy" tf:"object"` + AibiDashboardEmbeddingAccessPolicy types.Object `tfsdk:"aibi_dashboard_embedding_access_policy" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -48,8 +54,14 @@ func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDu func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingAccessPolicySetting) { } +func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AibiDashboardEmbeddingAccessPolicy": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicy{}), + } +} + type AibiDashboardEmbeddingApprovedDomains struct { - ApprovedDomains []types.String `tfsdk:"approved_domains" tf:"optional"` + ApprovedDomains types.List `tfsdk:"approved_domains" tf:"optional"` } func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuringCreateOrUpdate(plan AibiDashboardEmbeddingApprovedDomains) { @@ -58,8 +70,14 @@ func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuring func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingApprovedDomains) { } +func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ApprovedDomains": reflect.TypeOf(""), + } +} + type AibiDashboardEmbeddingApprovedDomainsSetting struct { - AibiDashboardEmbeddingApprovedDomains []AibiDashboardEmbeddingApprovedDomains `tfsdk:"aibi_dashboard_embedding_approved_domains" tf:"object"` + AibiDashboardEmbeddingApprovedDomains types.Object `tfsdk:"aibi_dashboard_embedding_approved_domains" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -82,8 +100,14 @@ func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveField func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingApprovedDomainsSetting) { } +func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AibiDashboardEmbeddingApprovedDomains": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomains{}), + } +} + type AutomaticClusterUpdateSetting struct { - AutomaticClusterUpdateWorkspace []ClusterAutoRestartMessage `tfsdk:"automatic_cluster_update_workspace" tf:"object"` + AutomaticClusterUpdateWorkspace types.Object `tfsdk:"automatic_cluster_update_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -106,6 +130,12 @@ func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringCreateOr func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringRead(existingState AutomaticClusterUpdateSetting) { } +func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AutomaticClusterUpdateWorkspace": reflect.TypeOf(ClusterAutoRestartMessage{}), + } +} + type BooleanMessage struct { Value types.Bool `tfsdk:"value" tf:"optional"` } @@ -116,6 +146,10 @@ func (newState *BooleanMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Boo func (newState *BooleanMessage) SyncEffectiveFieldsDuringRead(existingState BooleanMessage) { } +func (a BooleanMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterAutoRestartMessage struct { CanToggle types.Bool `tfsdk:"can_toggle" tf:"optional"` @@ -126,9 +160,9 @@ type ClusterAutoRestartMessage struct { // intended to use only for purposes like showing an error message to the // customer with the additional details. For example, using these details we // can check why exactly the feature is disabled for this customer. - EnablementDetails []ClusterAutoRestartMessageEnablementDetails `tfsdk:"enablement_details" tf:"optional,object"` + EnablementDetails types.Object `tfsdk:"enablement_details" tf:"optional,object"` - MaintenanceWindow []ClusterAutoRestartMessageMaintenanceWindow `tfsdk:"maintenance_window" tf:"optional,object"` + MaintenanceWindow types.Object `tfsdk:"maintenance_window" tf:"optional,object"` RestartEvenIfNoUpdatesAvailable types.Bool `tfsdk:"restart_even_if_no_updates_available" tf:"optional"` } @@ -139,6 +173,13 @@ func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessage) { } +func (a ClusterAutoRestartMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EnablementDetails": reflect.TypeOf(ClusterAutoRestartMessageEnablementDetails{}), + "MaintenanceWindow": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindow{}), + } +} + // Contains an information about the enablement status judging (e.g. whether the // enterprise tier is enabled) This is only additional information that MUST NOT // be used to decide whether the setting is enabled or not. This is intended to @@ -161,8 +202,12 @@ func (newState *ClusterAutoRestartMessageEnablementDetails) SyncEffectiveFieldsD func (newState *ClusterAutoRestartMessageEnablementDetails) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageEnablementDetails) { } +func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ClusterAutoRestartMessageMaintenanceWindow struct { - WeekDayBasedSchedule []ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule `tfsdk:"week_day_based_schedule" tf:"optional,object"` + WeekDayBasedSchedule types.Object `tfsdk:"week_day_based_schedule" tf:"optional,object"` } func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterAutoRestartMessageMaintenanceWindow) { @@ -171,12 +216,18 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsD func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindow) { } +func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "WeekDayBasedSchedule": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}), + } +} + type ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule struct { DayOfWeek types.String `tfsdk:"day_of_week" tf:"optional"` Frequency types.String `tfsdk:"frequency" tf:"optional"` - WindowStartTime []ClusterAutoRestartMessageMaintenanceWindowWindowStartTime `tfsdk:"window_start_time" tf:"optional,object"` + WindowStartTime types.Object `tfsdk:"window_start_time" tf:"optional,object"` } func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) { @@ -185,6 +236,12 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) { } +func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "WindowStartTime": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}), + } +} + type ClusterAutoRestartMessageMaintenanceWindowWindowStartTime struct { Hours types.Int64 `tfsdk:"hours" tf:"optional"` @@ -197,10 +254,14 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) SyncE func (newState *ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) { } +func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // SHIELD feature: CSP type ComplianceSecurityProfile struct { // Set by customers when they request Compliance Security Profile (CSP) - ComplianceStandards []types.String `tfsdk:"compliance_standards" tf:"optional"` + ComplianceStandards types.List `tfsdk:"compliance_standards" tf:"optional"` IsEnabled types.Bool `tfsdk:"is_enabled" tf:"optional"` } @@ -211,9 +272,15 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existingState ComplianceSecurityProfile) { } +func (a ComplianceSecurityProfile) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ComplianceStandards": reflect.TypeOf(""), + } +} + type ComplianceSecurityProfileSetting struct { // SHIELD feature: CSP - ComplianceSecurityProfileWorkspace []ComplianceSecurityProfile `tfsdk:"compliance_security_profile_workspace" tf:"object"` + ComplianceSecurityProfileWorkspace types.Object `tfsdk:"compliance_security_profile_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -236,16 +303,22 @@ func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringCreat func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringRead(existingState ComplianceSecurityProfileSetting) { } +func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ComplianceSecurityProfileWorkspace": reflect.TypeOf(ComplianceSecurityProfile{}), + } +} + type Config struct { - Email []EmailConfig `tfsdk:"email" tf:"optional,object"` + Email types.Object `tfsdk:"email" tf:"optional,object"` - GenericWebhook []GenericWebhookConfig `tfsdk:"generic_webhook" tf:"optional,object"` + GenericWebhook types.Object `tfsdk:"generic_webhook" tf:"optional,object"` - MicrosoftTeams []MicrosoftTeamsConfig `tfsdk:"microsoft_teams" tf:"optional,object"` + MicrosoftTeams types.Object `tfsdk:"microsoft_teams" tf:"optional,object"` - Pagerduty []PagerdutyConfig `tfsdk:"pagerduty" tf:"optional,object"` + Pagerduty types.Object `tfsdk:"pagerduty" tf:"optional,object"` - Slack []SlackConfig `tfsdk:"slack" tf:"optional,object"` + Slack types.Object `tfsdk:"slack" tf:"optional,object"` } func (newState *Config) SyncEffectiveFieldsDuringCreateOrUpdate(plan Config) { @@ -254,9 +327,19 @@ func (newState *Config) SyncEffectiveFieldsDuringCreateOrUpdate(plan Config) { func (newState *Config) SyncEffectiveFieldsDuringRead(existingState Config) { } +func (a Config) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Email": reflect.TypeOf(EmailConfig{}), + "GenericWebhook": reflect.TypeOf(GenericWebhookConfig{}), + "MicrosoftTeams": reflect.TypeOf(MicrosoftTeamsConfig{}), + "Pagerduty": reflect.TypeOf(PagerdutyConfig{}), + "Slack": reflect.TypeOf(SlackConfig{}), + } +} + // Details required to configure a block list or allow list. type CreateIpAccessList struct { - IpAddresses []types.String `tfsdk:"ip_addresses" tf:"optional"` + IpAddresses types.List `tfsdk:"ip_addresses" tf:"optional"` // Label for the IP access list. This **cannot** be empty. Label types.String `tfsdk:"label" tf:""` // Type of IP access list. Valid values are as follows and are @@ -274,10 +357,16 @@ func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringRead(existingState CreateIpAccessList) { } +func (a CreateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAddresses": reflect.TypeOf(""), + } +} + // An IP access list was successfully created. type CreateIpAccessListResponse struct { // Definition of an IP Access list - IpAccessList []IpAccessListInfo `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` } func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateIpAccessListResponse) { @@ -286,6 +375,12 @@ func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState CreateIpAccessListResponse) { } +func (a CreateIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessList": reflect.TypeOf(IpAccessListInfo{}), + } +} + type CreateNetworkConnectivityConfigRequest struct { // The name of the network connectivity configuration. The name can contain // alphanumeric characters, hyphens, and underscores. The length must be @@ -304,10 +399,14 @@ func (newState *CreateNetworkConnectivityConfigRequest) SyncEffectiveFieldsDurin func (newState *CreateNetworkConnectivityConfigRequest) SyncEffectiveFieldsDuringRead(existingState CreateNetworkConnectivityConfigRequest) { } +func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateNotificationDestinationRequest struct { // The configuration for the notification destination. Must wrap EXACTLY one // of the nested configs. - Config []Config `tfsdk:"config" tf:"optional,object"` + Config types.Object `tfsdk:"config" tf:"optional,object"` // The display name for the notification destination. DisplayName types.String `tfsdk:"display_name" tf:"optional"` } @@ -318,6 +417,12 @@ func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState CreateNotificationDestinationRequest) { } +func (a CreateNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Config": reflect.TypeOf(Config{}), + } +} + // Configuration details for creating on-behalf tokens. type CreateOboTokenRequest struct { // Application ID of the service principal. @@ -334,9 +439,13 @@ func (newState *CreateOboTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateOboTokenRequest) SyncEffectiveFieldsDuringRead(existingState CreateOboTokenRequest) { } +func (a CreateOboTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // An on-behalf token was successfully created for the service principal. type CreateOboTokenResponse struct { - TokenInfo []TokenInfo `tfsdk:"token_info" tf:"optional,object"` + TokenInfo types.Object `tfsdk:"token_info" tf:"optional,object"` // Value of the token. TokenValue types.String `tfsdk:"token_value" tf:"optional"` } @@ -347,6 +456,12 @@ func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringRead(existingState CreateOboTokenResponse) { } +func (a CreateOboTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenInfo": reflect.TypeOf(TokenInfo{}), + } +} + type CreatePrivateEndpointRuleRequest struct { // The sub-resource type (group ID) of the target resource. Note that to // connect to workspace root storage (root DBFS), you need two endpoints, @@ -364,6 +479,10 @@ func (newState *CreatePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreat func (newState *CreatePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState CreatePrivateEndpointRuleRequest) { } +func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateTokenRequest struct { // Optional description to attach to the token. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -379,9 +498,13 @@ func (newState *CreateTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateTokenRequest) SyncEffectiveFieldsDuringRead(existingState CreateTokenRequest) { } +func (a CreateTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateTokenResponse struct { // The information for the new token. - TokenInfo []PublicTokenInfo `tfsdk:"token_info" tf:"optional,object"` + TokenInfo types.Object `tfsdk:"token_info" tf:"optional,object"` // The value of the new token. TokenValue types.String `tfsdk:"token_value" tf:"optional"` } @@ -392,11 +515,17 @@ func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringRead(existingState CreateTokenResponse) { } +func (a CreateTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenInfo": reflect.TypeOf(PublicTokenInfo{}), + } +} + // Account level policy for CSP type CspEnablementAccount struct { // Set by customers when they request Compliance Security Profile (CSP) // Invariants are enforced in Settings policy. - ComplianceStandards []types.String `tfsdk:"compliance_standards" tf:"optional"` + ComplianceStandards types.List `tfsdk:"compliance_standards" tf:"optional"` // Enforced = it cannot be overriden at workspace level. IsEnforced types.Bool `tfsdk:"is_enforced" tf:"optional"` } @@ -407,9 +536,15 @@ func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringRead(existingState CspEnablementAccount) { } +func (a CspEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ComplianceStandards": reflect.TypeOf(""), + } +} + type CspEnablementAccountSetting struct { // Account level policy for CSP - CspEnablementAccount []CspEnablementAccount `tfsdk:"csp_enablement_account" tf:"object"` + CspEnablementAccount types.Object `tfsdk:"csp_enablement_account" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -432,6 +567,12 @@ func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringCreateOrUp func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringRead(existingState CspEnablementAccountSetting) { } +func (a CspEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CspEnablementAccount": reflect.TypeOf(CspEnablementAccount{}), + } +} + // This represents the setting configuration for the default namespace in the // Databricks workspace. Setting the default catalog for the workspace // determines the catalog that is used when queries do not reference a fully @@ -451,7 +592,7 @@ type DefaultNamespaceSetting struct { // PATCH request to identify the setting version you are updating. Etag types.String `tfsdk:"etag" tf:"optional"` - Namespace []StringMessage `tfsdk:"namespace" tf:"object"` + Namespace types.Object `tfsdk:"namespace" tf:"object"` // Name of the corresponding setting. This field is populated in the // response, but it will not be respected even if it's set in the request // body. The setting name in the path parameter will be respected instead. @@ -466,6 +607,12 @@ func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringRead(existingState DefaultNamespaceSetting) { } +func (a DefaultNamespaceSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Namespace": reflect.TypeOf(StringMessage{}), + } +} + // Delete access list type DeleteAccountIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -478,6 +625,10 @@ func (newState *DeleteAccountIpAccessListRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteAccountIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountIpAccessListRequest) { } +func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete the default namespace setting type DeleteDefaultNamespaceSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -496,6 +647,10 @@ func (newState *DeleteDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringC func (newState *DeleteDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDefaultNamespaceSettingRequest) { } +func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The etag is returned. type DeleteDefaultNamespaceSettingResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -514,6 +669,10 @@ func (newState *DeleteDefaultNamespaceSettingResponse) SyncEffectiveFieldsDuring func (newState *DeleteDefaultNamespaceSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDefaultNamespaceSettingResponse) { } +func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete Legacy Access Disablement Status type DeleteDisableLegacyAccessRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -532,6 +691,10 @@ func (newState *DeleteDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyAccessRequest) { } +func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The etag is returned. type DeleteDisableLegacyAccessResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -550,6 +713,10 @@ func (newState *DeleteDisableLegacyAccessResponse) SyncEffectiveFieldsDuringCrea func (newState *DeleteDisableLegacyAccessResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyAccessResponse) { } +func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete the disable legacy DBFS setting type DeleteDisableLegacyDbfsRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -568,6 +735,10 @@ func (newState *DeleteDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyDbfsRequest) { } +func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The etag is returned. type DeleteDisableLegacyDbfsResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -586,6 +757,10 @@ func (newState *DeleteDisableLegacyDbfsResponse) SyncEffectiveFieldsDuringCreate func (newState *DeleteDisableLegacyDbfsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyDbfsResponse) { } +func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete the disable legacy features setting type DeleteDisableLegacyFeaturesRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -604,6 +779,10 @@ func (newState *DeleteDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCre func (newState *DeleteDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyFeaturesRequest) { } +func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The etag is returned. type DeleteDisableLegacyFeaturesResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -622,6 +801,10 @@ func (newState *DeleteDisableLegacyFeaturesResponse) SyncEffectiveFieldsDuringCr func (newState *DeleteDisableLegacyFeaturesResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyFeaturesResponse) { } +func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete access list type DeleteIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -634,6 +817,10 @@ func (newState *DeleteIpAccessListRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState DeleteIpAccessListRequest) { } +func (a DeleteIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a network connectivity configuration type DeleteNetworkConnectivityConfigurationRequest struct { // Your Network Connectvity Configuration ID. @@ -646,6 +833,10 @@ func (newState *DeleteNetworkConnectivityConfigurationRequest) SyncEffectiveFiel func (newState *DeleteNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkConnectivityConfigurationRequest) { } +func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteNetworkConnectivityConfigurationResponse struct { } @@ -655,6 +846,10 @@ func (newState *DeleteNetworkConnectivityConfigurationResponse) SyncEffectiveFie func (newState *DeleteNetworkConnectivityConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkConnectivityConfigurationResponse) { } +func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a notification destination type DeleteNotificationDestinationRequest struct { Id types.String `tfsdk:"-"` @@ -666,6 +861,10 @@ func (newState *DeleteNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *DeleteNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNotificationDestinationRequest) { } +func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete Personal Compute setting type DeletePersonalComputeSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -684,6 +883,10 @@ func (newState *DeletePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCr func (newState *DeletePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeletePersonalComputeSettingRequest) { } +func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The etag is returned. type DeletePersonalComputeSettingResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -702,6 +905,10 @@ func (newState *DeletePersonalComputeSettingResponse) SyncEffectiveFieldsDuringC func (newState *DeletePersonalComputeSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeletePersonalComputeSettingResponse) { } +func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a private endpoint rule type DeletePrivateEndpointRuleRequest struct { // Your Network Connectvity Configuration ID. @@ -716,6 +923,10 @@ func (newState *DeletePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreat func (newState *DeletePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState DeletePrivateEndpointRuleRequest) { } +func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -725,6 +936,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete the restrict workspace admins setting type DeleteRestrictWorkspaceAdminsSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -743,6 +958,10 @@ func (newState *DeleteRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (newState *DeleteRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRestrictWorkspaceAdminsSettingRequest) { } +func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The etag is returned. type DeleteRestrictWorkspaceAdminsSettingResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -761,6 +980,10 @@ func (newState *DeleteRestrictWorkspaceAdminsSettingResponse) SyncEffectiveField func (newState *DeleteRestrictWorkspaceAdminsSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRestrictWorkspaceAdminsSettingResponse) { } +func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a token type DeleteTokenManagementRequest struct { // The ID of the token to revoke. @@ -773,8 +996,12 @@ func (newState *DeleteTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTokenManagementRequest) { } +func (a DeleteTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DisableLegacyAccess struct { - DisableLegacyAccess []BooleanMessage `tfsdk:"disable_legacy_access" tf:"object"` + DisableLegacyAccess types.Object `tfsdk:"disable_legacy_access" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -797,8 +1024,14 @@ func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringRead(existingState DisableLegacyAccess) { } +func (a DisableLegacyAccess) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DisableLegacyAccess": reflect.TypeOf(BooleanMessage{}), + } +} + type DisableLegacyDbfs struct { - DisableLegacyDbfs []BooleanMessage `tfsdk:"disable_legacy_dbfs" tf:"object"` + DisableLegacyDbfs types.Object `tfsdk:"disable_legacy_dbfs" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -821,8 +1054,14 @@ func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringRead(existingState DisableLegacyDbfs) { } +func (a DisableLegacyDbfs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DisableLegacyDbfs": reflect.TypeOf(BooleanMessage{}), + } +} + type DisableLegacyFeatures struct { - DisableLegacyFeatures []BooleanMessage `tfsdk:"disable_legacy_features" tf:"object"` + DisableLegacyFeatures types.Object `tfsdk:"disable_legacy_features" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -845,9 +1084,15 @@ func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringRead(existingState DisableLegacyFeatures) { } +func (a DisableLegacyFeatures) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DisableLegacyFeatures": reflect.TypeOf(BooleanMessage{}), + } +} + type EmailConfig struct { // Email addresses to notify. - Addresses []types.String `tfsdk:"addresses" tf:"optional"` + Addresses types.List `tfsdk:"addresses" tf:"optional"` } func (newState *EmailConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan EmailConfig) { @@ -856,6 +1101,12 @@ func (newState *EmailConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan EmailC func (newState *EmailConfig) SyncEffectiveFieldsDuringRead(existingState EmailConfig) { } +func (a EmailConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Addresses": reflect.TypeOf(""), + } +} + type Empty struct { } @@ -865,6 +1116,10 @@ func (newState *Empty) SyncEffectiveFieldsDuringCreateOrUpdate(plan Empty) { func (newState *Empty) SyncEffectiveFieldsDuringRead(existingState Empty) { } +func (a Empty) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // SHIELD feature: ESM type EnhancedSecurityMonitoring struct { IsEnabled types.Bool `tfsdk:"is_enabled" tf:"optional"` @@ -876,9 +1131,13 @@ func (newState *EnhancedSecurityMonitoring) SyncEffectiveFieldsDuringCreateOrUpd func (newState *EnhancedSecurityMonitoring) SyncEffectiveFieldsDuringRead(existingState EnhancedSecurityMonitoring) { } +func (a EnhancedSecurityMonitoring) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EnhancedSecurityMonitoringSetting struct { // SHIELD feature: ESM - EnhancedSecurityMonitoringWorkspace []EnhancedSecurityMonitoring `tfsdk:"enhanced_security_monitoring_workspace" tf:"object"` + EnhancedSecurityMonitoringWorkspace types.Object `tfsdk:"enhanced_security_monitoring_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -901,6 +1160,12 @@ func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringCrea func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringRead(existingState EnhancedSecurityMonitoringSetting) { } +func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EnhancedSecurityMonitoringWorkspace": reflect.TypeOf(EnhancedSecurityMonitoring{}), + } +} + // Account level policy for ESM type EsmEnablementAccount struct { IsEnforced types.Bool `tfsdk:"is_enforced" tf:"optional"` @@ -912,9 +1177,13 @@ func (newState *EsmEnablementAccount) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EsmEnablementAccount) SyncEffectiveFieldsDuringRead(existingState EsmEnablementAccount) { } +func (a EsmEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EsmEnablementAccountSetting struct { // Account level policy for ESM - EsmEnablementAccount []EsmEnablementAccount `tfsdk:"esm_enablement_account" tf:"object"` + EsmEnablementAccount types.Object `tfsdk:"esm_enablement_account" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -937,6 +1206,12 @@ func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringCreateOrUp func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringRead(existingState EsmEnablementAccountSetting) { } +func (a EsmEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EsmEnablementAccount": reflect.TypeOf(EsmEnablementAccount{}), + } +} + // The exchange token is the result of the token exchange with the IdP type ExchangeToken struct { // The requested token. @@ -947,7 +1222,7 @@ type ExchangeToken struct { // User ID of the user that owns this token. OwnerId types.Int64 `tfsdk:"ownerId" tf:"optional"` // The scopes of access granted in the token. - Scopes []types.String `tfsdk:"scopes" tf:"optional"` + Scopes types.List `tfsdk:"scopes" tf:"optional"` // The type of this exchange token TokenType types.String `tfsdk:"tokenType" tf:"optional"` } @@ -958,14 +1233,20 @@ func (newState *ExchangeToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exch func (newState *ExchangeToken) SyncEffectiveFieldsDuringRead(existingState ExchangeToken) { } +func (a ExchangeToken) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Scopes": reflect.TypeOf(""), + } +} + // Exchange a token with the IdP type ExchangeTokenRequest struct { // The partition of Credentials store - PartitionId []PartitionId `tfsdk:"partitionId" tf:"object"` + PartitionId types.Object `tfsdk:"partitionId" tf:"object"` // Array of scopes for the token request. - Scopes []types.String `tfsdk:"scopes" tf:""` + Scopes types.List `tfsdk:"scopes" tf:""` // A list of token types being requested - TokenType []types.String `tfsdk:"tokenType" tf:""` + TokenType types.List `tfsdk:"tokenType" tf:""` } func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan ExchangeTokenRequest) { @@ -974,9 +1255,17 @@ func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringRead(existingState ExchangeTokenRequest) { } +func (a ExchangeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PartitionId": reflect.TypeOf(PartitionId{}), + "Scopes": reflect.TypeOf(""), + "TokenType": reflect.TypeOf(""), + } +} + // Exhanged tokens were successfully returned. type ExchangeTokenResponse struct { - Values []ExchangeToken `tfsdk:"values" tf:"optional"` + Values types.List `tfsdk:"values" tf:"optional"` } func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ExchangeTokenResponse) { @@ -985,10 +1274,16 @@ func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringRead(existingState ExchangeTokenResponse) { } +func (a ExchangeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Values": reflect.TypeOf(ExchangeToken{}), + } +} + // An IP access list was successfully returned. type FetchIpAccessListResponse struct { // Definition of an IP Access list - IpAccessList []IpAccessListInfo `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` } func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan FetchIpAccessListResponse) { @@ -997,6 +1292,12 @@ func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState FetchIpAccessListResponse) { } +func (a FetchIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessList": reflect.TypeOf(IpAccessListInfo{}), + } +} + type GenericWebhookConfig struct { // [Input-Only][Optional] Password for webhook. Password types.String `tfsdk:"password" tf:"optional"` @@ -1018,6 +1319,10 @@ func (newState *GenericWebhookConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GenericWebhookConfig) SyncEffectiveFieldsDuringRead(existingState GenericWebhookConfig) { } +func (a GenericWebhookConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get IP access list type GetAccountIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -1030,6 +1335,10 @@ func (newState *GetAccountIpAccessListRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetAccountIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountIpAccessListRequest) { } +func (a GetAccountIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Retrieve the AI/BI dashboard embedding access policy type GetAibiDashboardEmbeddingAccessPolicySettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1048,6 +1357,10 @@ func (newState *GetAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffecti func (newState *GetAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAibiDashboardEmbeddingAccessPolicySettingRequest) { } +func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Retrieve the list of domains approved to host embedded AI/BI dashboards type GetAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1066,6 +1379,10 @@ func (newState *GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffe func (newState *GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) { } +func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the automatic cluster update setting type GetAutomaticClusterUpdateSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1084,6 +1401,10 @@ func (newState *GetAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuri func (newState *GetAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAutomaticClusterUpdateSettingRequest) { } +func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the compliance security profile setting type GetComplianceSecurityProfileSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1102,6 +1423,10 @@ func (newState *GetComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsD func (newState *GetComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetComplianceSecurityProfileSettingRequest) { } +func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the compliance security profile setting for new workspaces type GetCspEnablementAccountSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1120,6 +1445,10 @@ func (newState *GetCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuring func (newState *GetCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetCspEnablementAccountSettingRequest) { } +func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the default namespace setting type GetDefaultNamespaceSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1138,6 +1467,10 @@ func (newState *GetDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringCrea func (newState *GetDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetDefaultNamespaceSettingRequest) { } +func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Retrieve Legacy Access Disablement Status type GetDisableLegacyAccessRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1156,6 +1489,10 @@ func (newState *GetDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyAccessRequest) { } +func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the disable legacy DBFS setting type GetDisableLegacyDbfsRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1174,6 +1511,10 @@ func (newState *GetDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyDbfsRequest) { } +func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the disable legacy features setting type GetDisableLegacyFeaturesRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1192,6 +1533,10 @@ func (newState *GetDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCreate func (newState *GetDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyFeaturesRequest) { } +func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the enhanced security monitoring setting type GetEnhancedSecurityMonitoringSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1210,6 +1555,10 @@ func (newState *GetEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFields func (newState *GetEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetEnhancedSecurityMonitoringSettingRequest) { } +func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the enhanced security monitoring setting for new workspaces type GetEsmEnablementAccountSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1228,6 +1577,10 @@ func (newState *GetEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuring func (newState *GetEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetEsmEnablementAccountSettingRequest) { } +func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get access list type GetIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -1240,9 +1593,13 @@ func (newState *GetIpAccessListRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListRequest) { } +func (a GetIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetIpAccessListResponse struct { // Definition of an IP Access list - IpAccessList []IpAccessListInfo `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` } func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetIpAccessListResponse) { @@ -1251,9 +1608,15 @@ func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListResponse) { } +func (a GetIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessList": reflect.TypeOf(IpAccessListInfo{}), + } +} + // IP access lists were successfully returned. type GetIpAccessListsResponse struct { - IpAccessLists []IpAccessListInfo `tfsdk:"ip_access_lists" tf:"optional"` + IpAccessLists types.List `tfsdk:"ip_access_lists" tf:"optional"` } func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetIpAccessListsResponse) { @@ -1262,6 +1625,12 @@ func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListsResponse) { } +func (a GetIpAccessListsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessLists": reflect.TypeOf(IpAccessListInfo{}), + } +} + // Get a network connectivity configuration type GetNetworkConnectivityConfigurationRequest struct { // Your Network Connectvity Configuration ID. @@ -1274,6 +1643,10 @@ func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsD func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState GetNetworkConnectivityConfigurationRequest) { } +func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a notification destination type GetNotificationDestinationRequest struct { Id types.String `tfsdk:"-"` @@ -1285,6 +1658,10 @@ func (newState *GetNotificationDestinationRequest) SyncEffectiveFieldsDuringCrea func (newState *GetNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState GetNotificationDestinationRequest) { } +func (a GetNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get Personal Compute setting type GetPersonalComputeSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1303,6 +1680,10 @@ func (newState *GetPersonalComputeSettingRequest) SyncEffectiveFieldsDuringCreat func (newState *GetPersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetPersonalComputeSettingRequest) { } +func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a private endpoint rule type GetPrivateEndpointRuleRequest struct { // Your Network Connectvity Configuration ID. @@ -1317,6 +1698,10 @@ func (newState *GetPrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetPrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState GetPrivateEndpointRuleRequest) { } +func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get the restrict workspace admins setting type GetRestrictWorkspaceAdminsSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1335,6 +1720,10 @@ func (newState *GetRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDur func (newState *GetRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetRestrictWorkspaceAdminsSettingRequest) { } +func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Check configuration status type GetStatusRequest struct { Keys types.String `tfsdk:"-"` @@ -1346,6 +1735,10 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } +func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get token info type GetTokenManagementRequest struct { // The ID of the token to get. @@ -1358,9 +1751,13 @@ func (newState *GetTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState GetTokenManagementRequest) { } +func (a GetTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetTokenPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []TokenPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetTokenPermissionLevelsResponse) { @@ -1369,9 +1766,15 @@ func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringCreat func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetTokenPermissionLevelsResponse) { } +func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(TokenPermissionsDescription{}), + } +} + // Token with specified Token ID was successfully returned. type GetTokenResponse struct { - TokenInfo []TokenInfo `tfsdk:"token_info" tf:"optional,object"` + TokenInfo types.Object `tfsdk:"token_info" tf:"optional,object"` } func (newState *GetTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetTokenResponse) { @@ -1380,6 +1783,12 @@ func (newState *GetTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetTokenResponse) SyncEffectiveFieldsDuringRead(existingState GetTokenResponse) { } +func (a GetTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenInfo": reflect.TypeOf(TokenInfo{}), + } +} + // Definition of an IP Access list type IpAccessListInfo struct { // Total number of IP or CIDR values. @@ -1391,7 +1800,7 @@ type IpAccessListInfo struct { // Specifies whether this IP access list is enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` - IpAddresses []types.String `tfsdk:"ip_addresses" tf:"optional"` + IpAddresses types.List `tfsdk:"ip_addresses" tf:"optional"` // Label for the IP access list. This **cannot** be empty. Label types.String `tfsdk:"label" tf:"optional"` // Universally unique identifier (UUID) of the IP access list. @@ -1415,9 +1824,15 @@ func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan I func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringRead(existingState IpAccessListInfo) { } +func (a IpAccessListInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAddresses": reflect.TypeOf(""), + } +} + // IP access lists were successfully returned. type ListIpAccessListResponse struct { - IpAccessLists []IpAccessListInfo `tfsdk:"ip_access_lists" tf:"optional"` + IpAccessLists types.List `tfsdk:"ip_access_lists" tf:"optional"` } func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListIpAccessListResponse) { @@ -1426,8 +1841,14 @@ func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState ListIpAccessListResponse) { } +func (a ListIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessLists": reflect.TypeOf(IpAccessListInfo{}), + } +} + type ListNccAzurePrivateEndpointRulesResponse struct { - Items []NccAzurePrivateEndpointRule `tfsdk:"items" tf:"optional"` + Items types.List `tfsdk:"items" tf:"optional"` // A token that can be used to get the next page of results. If null, there // are no more results to show. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1439,6 +1860,12 @@ func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDur func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDuringRead(existingState ListNccAzurePrivateEndpointRulesResponse) { } +func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Items": reflect.TypeOf(NccAzurePrivateEndpointRule{}), + } +} + // List network connectivity configurations type ListNetworkConnectivityConfigurationsRequest struct { // Pagination token to go to next page based on previous query. @@ -1451,8 +1878,12 @@ func (newState *ListNetworkConnectivityConfigurationsRequest) SyncEffectiveField func (newState *ListNetworkConnectivityConfigurationsRequest) SyncEffectiveFieldsDuringRead(existingState ListNetworkConnectivityConfigurationsRequest) { } +func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListNetworkConnectivityConfigurationsResponse struct { - Items []NetworkConnectivityConfiguration `tfsdk:"items" tf:"optional"` + Items types.List `tfsdk:"items" tf:"optional"` // A token that can be used to get the next page of results. If null, there // are no more results to show. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1464,6 +1895,12 @@ func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFiel func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFieldsDuringRead(existingState ListNetworkConnectivityConfigurationsResponse) { } +func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Items": reflect.TypeOf(NetworkConnectivityConfiguration{}), + } +} + // List notification destinations type ListNotificationDestinationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1477,11 +1914,15 @@ func (newState *ListNotificationDestinationsRequest) SyncEffectiveFieldsDuringCr func (newState *ListNotificationDestinationsRequest) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsRequest) { } +func (a ListNotificationDestinationsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListNotificationDestinationsResponse struct { // Page token for next of results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Results []ListNotificationDestinationsResult `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListNotificationDestinationsResponse) { @@ -1490,6 +1931,12 @@ func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringC func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResponse) { } +func (a ListNotificationDestinationsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(ListNotificationDestinationsResult{}), + } +} + type ListNotificationDestinationsResult struct { // [Output-only] The type of the notification destination. The type can not // be changed once set. @@ -1506,6 +1953,10 @@ func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringCre func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResult) { } +func (a ListNotificationDestinationsResult) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List private endpoint rules type ListPrivateEndpointRulesRequest struct { // Your Network Connectvity Configuration ID. @@ -1520,9 +1971,13 @@ func (newState *ListPrivateEndpointRulesRequest) SyncEffectiveFieldsDuringCreate func (newState *ListPrivateEndpointRulesRequest) SyncEffectiveFieldsDuringRead(existingState ListPrivateEndpointRulesRequest) { } +func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListPublicTokensResponse struct { // The information for each token. - TokenInfos []PublicTokenInfo `tfsdk:"token_infos" tf:"optional"` + TokenInfos types.List `tfsdk:"token_infos" tf:"optional"` } func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListPublicTokensResponse) { @@ -1531,6 +1986,12 @@ func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringRead(existingState ListPublicTokensResponse) { } +func (a ListPublicTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenInfos": reflect.TypeOf(PublicTokenInfo{}), + } +} + // List all tokens type ListTokenManagementRequest struct { // User ID of the user that created the token. @@ -1545,10 +2006,14 @@ func (newState *ListTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState ListTokenManagementRequest) { } +func (a ListTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Tokens were successfully returned. type ListTokensResponse struct { // Token metadata of each user-created token in the workspace - TokenInfos []TokenInfo `tfsdk:"token_infos" tf:"optional"` + TokenInfos types.List `tfsdk:"token_infos" tf:"optional"` } func (newState *ListTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListTokensResponse) { @@ -1557,6 +2022,12 @@ func (newState *ListTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTokensResponse) SyncEffectiveFieldsDuringRead(existingState ListTokensResponse) { } +func (a ListTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "TokenInfos": reflect.TypeOf(TokenInfo{}), + } +} + type MicrosoftTeamsConfig struct { // [Input-Only] URL for Microsoft Teams. Url types.String `tfsdk:"url" tf:"optional"` @@ -1570,12 +2041,16 @@ func (newState *MicrosoftTeamsConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *MicrosoftTeamsConfig) SyncEffectiveFieldsDuringRead(existingState MicrosoftTeamsConfig) { } +func (a MicrosoftTeamsConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The stable AWS IP CIDR blocks. You can use these to configure the firewall of // your resources to allow traffic from your Databricks workspace. type NccAwsStableIpRule struct { // The list of stable IP CIDR blocks from which Databricks network traffic // originates when accessing your resources. - CidrBlocks []types.String `tfsdk:"cidr_blocks" tf:"optional"` + CidrBlocks types.List `tfsdk:"cidr_blocks" tf:"optional"` } func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccAwsStableIpRule) { @@ -1584,6 +2059,12 @@ func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringRead(existingState NccAwsStableIpRule) { } +func (a NccAwsStableIpRule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CidrBlocks": reflect.TypeOf(""), + } +} + type NccAzurePrivateEndpointRule struct { // The current status of this private endpoint. The private endpoint rules // are effective only if the connection state is `ESTABLISHED`. Remember @@ -1628,17 +2109,21 @@ func (newState *NccAzurePrivateEndpointRule) SyncEffectiveFieldsDuringCreateOrUp func (newState *NccAzurePrivateEndpointRule) SyncEffectiveFieldsDuringRead(existingState NccAzurePrivateEndpointRule) { } +func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // The stable Azure service endpoints. You can configure the firewall of your // Azure resources to allow traffic from your Databricks serverless compute // resources. type NccAzureServiceEndpointRule struct { // The list of subnets from which Databricks network traffic originates when // accessing your Azure resources. - Subnets []types.String `tfsdk:"subnets" tf:"optional"` + Subnets types.List `tfsdk:"subnets" tf:"optional"` // The Azure region in which this service endpoint rule applies. TargetRegion types.String `tfsdk:"target_region" tf:"optional"` // The Azure services to which this service endpoint rule applies to. - TargetServices []types.String `tfsdk:"target_services" tf:"optional"` + TargetServices types.List `tfsdk:"target_services" tf:"optional"` } func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccAzureServiceEndpointRule) { @@ -1647,16 +2132,23 @@ func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringCreateOrUp func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringRead(existingState NccAzureServiceEndpointRule) { } +func (a NccAzureServiceEndpointRule) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Subnets": reflect.TypeOf(""), + "TargetServices": reflect.TypeOf(""), + } +} + // The network connectivity rules that apply to network traffic from your // serverless compute resources. type NccEgressConfig struct { // The network connectivity rules that are applied by default without // resource specific configurations. You can find the stable network // information of your serverless compute resources here. - DefaultRules []NccEgressDefaultRules `tfsdk:"default_rules" tf:"computed,optional"` + DefaultRules types.Object `tfsdk:"default_rules" tf:"computed,optional"` // The network connectivity rules that configured for each destinations. // These rules override default rules. - TargetRules []NccEgressTargetRules `tfsdk:"target_rules" tf:"optional,object"` + TargetRules types.Object `tfsdk:"target_rules" tf:"optional,object"` } func (newState *NccEgressConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccEgressConfig) { @@ -1665,6 +2157,13 @@ func (newState *NccEgressConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Nc func (newState *NccEgressConfig) SyncEffectiveFieldsDuringRead(existingState NccEgressConfig) { } +func (a NccEgressConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DefaultRules": reflect.TypeOf(NccEgressDefaultRules{}), + "TargetRules": reflect.TypeOf(NccEgressTargetRules{}), + } +} + // The network connectivity rules that are applied by default without resource // specific configurations. You can find the stable network information of your // serverless compute resources here. @@ -1672,11 +2171,11 @@ type NccEgressDefaultRules struct { // The stable AWS IP CIDR blocks. You can use these to configure the // firewall of your resources to allow traffic from your Databricks // workspace. - AwsStableIpRule []NccAwsStableIpRule `tfsdk:"aws_stable_ip_rule" tf:"optional,object"` + AwsStableIpRule types.Object `tfsdk:"aws_stable_ip_rule" tf:"optional,object"` // The stable Azure service endpoints. You can configure the firewall of // your Azure resources to allow traffic from your Databricks serverless // compute resources. - AzureServiceEndpointRule []NccAzureServiceEndpointRule `tfsdk:"azure_service_endpoint_rule" tf:"optional,object"` + AzureServiceEndpointRule types.Object `tfsdk:"azure_service_endpoint_rule" tf:"optional,object"` } func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccEgressDefaultRules) { @@ -1685,10 +2184,17 @@ func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringRead(existingState NccEgressDefaultRules) { } +func (a NccEgressDefaultRules) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AwsStableIpRule": reflect.TypeOf(NccAwsStableIpRule{}), + "AzureServiceEndpointRule": reflect.TypeOf(NccAzureServiceEndpointRule{}), + } +} + // The network connectivity rules that configured for each destinations. These // rules override default rules. type NccEgressTargetRules struct { - AzurePrivateEndpointRules []NccAzurePrivateEndpointRule `tfsdk:"azure_private_endpoint_rules" tf:"optional"` + AzurePrivateEndpointRules types.List `tfsdk:"azure_private_endpoint_rules" tf:"optional"` } func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccEgressTargetRules) { @@ -1697,6 +2203,12 @@ func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringRead(existingState NccEgressTargetRules) { } +func (a NccEgressTargetRules) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AzurePrivateEndpointRules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), + } +} + type NetworkConnectivityConfiguration struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -1704,7 +2216,7 @@ type NetworkConnectivityConfiguration struct { CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // The network connectivity rules that apply to network traffic from your // serverless compute resources. - EgressConfig []NccEgressConfig `tfsdk:"egress_config" tf:"optional,object"` + EgressConfig types.Object `tfsdk:"egress_config" tf:"optional,object"` // The name of the network connectivity configuration. The name can contain // alphanumeric characters, hyphens, and underscores. The length must be // between 3 and 30 characters. The name must match the regular expression @@ -1726,11 +2238,17 @@ func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringCreat func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringRead(existingState NetworkConnectivityConfiguration) { } +func (a NetworkConnectivityConfiguration) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EgressConfig": reflect.TypeOf(NccEgressConfig{}), + } +} + type NotificationDestination struct { // The configuration for the notification destination. Will be exactly one // of the nested configs. Only returns for users with workspace admin // permissions. - Config []Config `tfsdk:"config" tf:"optional,object"` + Config types.Object `tfsdk:"config" tf:"optional,object"` // [Output-only] The type of the notification destination. The type can not // be changed once set. DestinationType types.String `tfsdk:"destination_type" tf:"optional"` @@ -1746,6 +2264,12 @@ func (newState *NotificationDestination) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *NotificationDestination) SyncEffectiveFieldsDuringRead(existingState NotificationDestination) { } +func (a NotificationDestination) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Config": reflect.TypeOf(Config{}), + } +} + type PagerdutyConfig struct { // [Input-Only] Integration key for PagerDuty. IntegrationKey types.String `tfsdk:"integration_key" tf:"optional"` @@ -1759,6 +2283,10 @@ func (newState *PagerdutyConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pa func (newState *PagerdutyConfig) SyncEffectiveFieldsDuringRead(existingState PagerdutyConfig) { } +func (a PagerdutyConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Partition by workspace or account type PartitionId struct { // The ID of the workspace. @@ -1771,6 +2299,10 @@ func (newState *PartitionId) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partit func (newState *PartitionId) SyncEffectiveFieldsDuringRead(existingState PartitionId) { } +func (a PartitionId) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PersonalComputeMessage struct { // ON: Grants all users in all workspaces access to the Personal Compute // default policy, allowing all users to create single-machine compute @@ -1788,6 +2320,10 @@ func (newState *PersonalComputeMessage) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalComputeMessage) SyncEffectiveFieldsDuringRead(existingState PersonalComputeMessage) { } +func (a PersonalComputeMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PersonalComputeSetting struct { // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to @@ -1798,7 +2334,7 @@ type PersonalComputeSetting struct { // PATCH request to identify the setting version you are updating. Etag types.String `tfsdk:"etag" tf:"optional"` - PersonalCompute []PersonalComputeMessage `tfsdk:"personal_compute" tf:"object"` + PersonalCompute types.Object `tfsdk:"personal_compute" tf:"object"` // Name of the corresponding setting. This field is populated in the // response, but it will not be respected even if it's set in the request // body. The setting name in the path parameter will be respected instead. @@ -1813,6 +2349,12 @@ func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringRead(existingState PersonalComputeSetting) { } +func (a PersonalComputeSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PersonalCompute": reflect.TypeOf(PersonalComputeMessage{}), + } +} + type PublicTokenInfo struct { // Comment the token was created with, if applicable. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1831,6 +2373,10 @@ func (newState *PublicTokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pu func (newState *PublicTokenInfo) SyncEffectiveFieldsDuringRead(existingState PublicTokenInfo) { } +func (a PublicTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Details required to replace an IP access list. type ReplaceIpAccessList struct { // Specifies whether this IP access list is enabled. @@ -1838,7 +2384,7 @@ type ReplaceIpAccessList struct { // The ID for the corresponding IP access list IpAccessListId types.String `tfsdk:"-"` - IpAddresses []types.String `tfsdk:"ip_addresses" tf:"optional"` + IpAddresses types.List `tfsdk:"ip_addresses" tf:"optional"` // Label for the IP access list. This **cannot** be empty. Label types.String `tfsdk:"label" tf:""` // Type of IP access list. Valid values are as follows and are @@ -1856,6 +2402,12 @@ func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringRead(existingState ReplaceIpAccessList) { } +func (a ReplaceIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAddresses": reflect.TypeOf(""), + } +} + type ReplaceResponse struct { } @@ -1865,6 +2417,10 @@ func (newState *ReplaceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReplaceResponse) SyncEffectiveFieldsDuringRead(existingState ReplaceResponse) { } +func (a ReplaceResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestrictWorkspaceAdminsMessage struct { Status types.String `tfsdk:"status" tf:""` } @@ -1875,6 +2431,10 @@ func (newState *RestrictWorkspaceAdminsMessage) SyncEffectiveFieldsDuringCreateO func (newState *RestrictWorkspaceAdminsMessage) SyncEffectiveFieldsDuringRead(existingState RestrictWorkspaceAdminsMessage) { } +func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestrictWorkspaceAdminsSetting struct { // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to @@ -1885,7 +2445,7 @@ type RestrictWorkspaceAdminsSetting struct { // PATCH request to identify the setting version you are updating. Etag types.String `tfsdk:"etag" tf:"optional"` - RestrictWorkspaceAdmins []RestrictWorkspaceAdminsMessage `tfsdk:"restrict_workspace_admins" tf:"object"` + RestrictWorkspaceAdmins types.Object `tfsdk:"restrict_workspace_admins" tf:"object"` // Name of the corresponding setting. This field is populated in the // response, but it will not be respected even if it's set in the request // body. The setting name in the path parameter will be respected instead. @@ -1900,6 +2460,12 @@ func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringCreateO func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringRead(existingState RestrictWorkspaceAdminsSetting) { } +func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RestrictWorkspaceAdmins": reflect.TypeOf(RestrictWorkspaceAdminsMessage{}), + } +} + type RevokeTokenRequest struct { // The ID of the token to be revoked. TokenId types.String `tfsdk:"token_id" tf:""` @@ -1911,6 +2477,10 @@ func (newState *RevokeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RevokeTokenRequest) SyncEffectiveFieldsDuringRead(existingState RevokeTokenRequest) { } +func (a RevokeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RevokeTokenResponse struct { } @@ -1920,6 +2490,10 @@ func (newState *RevokeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RevokeTokenResponse) SyncEffectiveFieldsDuringRead(existingState RevokeTokenResponse) { } +func (a RevokeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SetStatusResponse struct { } @@ -1929,6 +2503,10 @@ func (newState *SetStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SetStatusResponse) SyncEffectiveFieldsDuringRead(existingState SetStatusResponse) { } +func (a SetStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SlackConfig struct { // [Input-Only] URL for Slack destination. Url types.String `tfsdk:"url" tf:"optional"` @@ -1942,6 +2520,10 @@ func (newState *SlackConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan SlackC func (newState *SlackConfig) SyncEffectiveFieldsDuringRead(existingState SlackConfig) { } +func (a SlackConfig) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StringMessage struct { // Represents a generic string value. Value types.String `tfsdk:"value" tf:"optional"` @@ -1953,6 +2535,10 @@ func (newState *StringMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Stri func (newState *StringMessage) SyncEffectiveFieldsDuringRead(existingState StringMessage) { } +func (a StringMessage) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1970,9 +2556,13 @@ func (newState *TokenAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *TokenAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState TokenAccessControlRequest) { } +func (a TokenAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenAccessControlResponse struct { // All permissions. - AllPermissions []TokenPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -1989,6 +2579,12 @@ func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState TokenAccessControlResponse) { } +func (a TokenAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(TokenPermission{}), + } +} + type TokenInfo struct { // Comment that describes the purpose of the token, specified by the token // creator. @@ -2018,10 +2614,14 @@ func (newState *TokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenInf func (newState *TokenInfo) SyncEffectiveFieldsDuringRead(existingState TokenInfo) { } +func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -2032,8 +2632,14 @@ func (newState *TokenPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan To func (newState *TokenPermission) SyncEffectiveFieldsDuringRead(existingState TokenPermission) { } +func (a TokenPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type TokenPermissions struct { - AccessControlList []TokenAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -2046,6 +2652,12 @@ func (newState *TokenPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan T func (newState *TokenPermissions) SyncEffectiveFieldsDuringRead(existingState TokenPermissions) { } +func (a TokenPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(TokenAccessControlResponse{}), + } +} + type TokenPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2058,8 +2670,12 @@ func (newState *TokenPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUp func (newState *TokenPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState TokenPermissionsDescription) { } +func (a TokenPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TokenPermissionsRequest struct { - AccessControlList []TokenAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` } func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenPermissionsRequest) { @@ -2068,6 +2684,12 @@ func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState TokenPermissionsRequest) { } +func (a TokenPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(TokenAccessControlRequest{}), + } +} + // Details required to update a setting. type UpdateAibiDashboardEmbeddingAccessPolicySettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2079,7 +2701,7 @@ type UpdateAibiDashboardEmbeddingAccessPolicySettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []AibiDashboardEmbeddingAccessPolicySetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) { @@ -2088,6 +2710,12 @@ func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffe func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) { } +func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicySetting{}), + } +} + // Details required to update a setting. type UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2099,7 +2727,7 @@ type UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []AibiDashboardEmbeddingApprovedDomainsSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) { @@ -2108,6 +2736,12 @@ func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncE func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) { } +func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomainsSetting{}), + } +} + // Details required to update a setting. type UpdateAutomaticClusterUpdateSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2119,7 +2753,7 @@ type UpdateAutomaticClusterUpdateSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []AutomaticClusterUpdateSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateAutomaticClusterUpdateSettingRequest) { @@ -2128,6 +2762,12 @@ func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsD func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAutomaticClusterUpdateSettingRequest) { } +func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(AutomaticClusterUpdateSetting{}), + } +} + // Details required to update a setting. type UpdateComplianceSecurityProfileSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2139,7 +2779,7 @@ type UpdateComplianceSecurityProfileSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []ComplianceSecurityProfileSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateComplianceSecurityProfileSettingRequest) { @@ -2148,6 +2788,12 @@ func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFiel func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateComplianceSecurityProfileSettingRequest) { } +func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(ComplianceSecurityProfileSetting{}), + } +} + // Details required to update a setting. type UpdateCspEnablementAccountSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2159,7 +2805,7 @@ type UpdateCspEnablementAccountSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []CspEnablementAccountSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCspEnablementAccountSettingRequest) { @@ -2168,6 +2814,12 @@ func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCspEnablementAccountSettingRequest) { } +func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(CspEnablementAccountSetting{}), + } +} + // Details required to update a setting. type UpdateDefaultNamespaceSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2187,7 +2839,7 @@ type UpdateDefaultNamespaceSettingRequest struct { // assumed). This setting requires a restart of clusters and SQL warehouses // to take effect. Additionally, the default namespace only applies when // using Unity Catalog-enabled compute. - Setting []DefaultNamespaceSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDefaultNamespaceSettingRequest) { @@ -2196,6 +2848,12 @@ func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringC func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDefaultNamespaceSettingRequest) { } +func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(DefaultNamespaceSetting{}), + } +} + // Details required to update a setting. type UpdateDisableLegacyAccessRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2207,7 +2865,7 @@ type UpdateDisableLegacyAccessRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []DisableLegacyAccess `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDisableLegacyAccessRequest) { @@ -2216,6 +2874,12 @@ func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreat func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyAccessRequest) { } +func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(DisableLegacyAccess{}), + } +} + // Details required to update a setting. type UpdateDisableLegacyDbfsRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2227,7 +2891,7 @@ type UpdateDisableLegacyDbfsRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []DisableLegacyDbfs `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDisableLegacyDbfsRequest) { @@ -2236,6 +2900,12 @@ func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateO func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyDbfsRequest) { } +func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(DisableLegacyDbfs{}), + } +} + // Details required to update a setting. type UpdateDisableLegacyFeaturesRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2247,7 +2917,7 @@ type UpdateDisableLegacyFeaturesRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []DisableLegacyFeatures `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDisableLegacyFeaturesRequest) { @@ -2256,6 +2926,12 @@ func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCre func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyFeaturesRequest) { } +func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(DisableLegacyFeatures{}), + } +} + // Details required to update a setting. type UpdateEnhancedSecurityMonitoringSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2267,7 +2943,7 @@ type UpdateEnhancedSecurityMonitoringSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []EnhancedSecurityMonitoringSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateEnhancedSecurityMonitoringSettingRequest) { @@ -2276,6 +2952,12 @@ func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFie func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateEnhancedSecurityMonitoringSettingRequest) { } +func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(EnhancedSecurityMonitoringSetting{}), + } +} + // Details required to update a setting. type UpdateEsmEnablementAccountSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2287,7 +2969,7 @@ type UpdateEsmEnablementAccountSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []EsmEnablementAccountSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateEsmEnablementAccountSettingRequest) { @@ -2296,6 +2978,12 @@ func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateEsmEnablementAccountSettingRequest) { } +func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(EsmEnablementAccountSetting{}), + } +} + // Details required to update an IP access list. type UpdateIpAccessList struct { // Specifies whether this IP access list is enabled. @@ -2303,7 +2991,7 @@ type UpdateIpAccessList struct { // The ID for the corresponding IP access list IpAccessListId types.String `tfsdk:"-"` - IpAddresses []types.String `tfsdk:"ip_addresses" tf:"optional"` + IpAddresses types.List `tfsdk:"ip_addresses" tf:"optional"` // Label for the IP access list. This **cannot** be empty. Label types.String `tfsdk:"label" tf:"optional"` // Type of IP access list. Valid values are as follows and are @@ -2321,10 +3009,16 @@ func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringRead(existingState UpdateIpAccessList) { } +func (a UpdateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAddresses": reflect.TypeOf(""), + } +} + type UpdateNotificationDestinationRequest struct { // The configuration for the notification destination. Must wrap EXACTLY one // of the nested configs. - Config []Config `tfsdk:"config" tf:"optional,object"` + Config types.Object `tfsdk:"config" tf:"optional,object"` // The display name for the notification destination. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // UUID identifying notification destination. @@ -2337,6 +3031,12 @@ func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateNotificationDestinationRequest) { } +func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Config": reflect.TypeOf(Config{}), + } +} + // Details required to update a setting. type UpdatePersonalComputeSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2348,7 +3048,7 @@ type UpdatePersonalComputeSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []PersonalComputeSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdatePersonalComputeSettingRequest) { @@ -2357,6 +3057,12 @@ func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCr func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalComputeSettingRequest) { } +func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(PersonalComputeSetting{}), + } +} + type UpdateResponse struct { } @@ -2366,6 +3072,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Details required to update a setting. type UpdateRestrictWorkspaceAdminsSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2377,7 +3087,7 @@ type UpdateRestrictWorkspaceAdminsSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting []RestrictWorkspaceAdminsSetting `tfsdk:"setting" tf:"object"` + Setting types.Object `tfsdk:"setting" tf:"object"` } func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRestrictWorkspaceAdminsSettingRequest) { @@ -2385,3 +3095,9 @@ func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRestrictWorkspaceAdminsSettingRequest) { } + +func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Setting": reflect.TypeOf(RestrictWorkspaceAdminsSetting{}), + } +} diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 6bde086372..603440115c 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package sharing_tf import ( + "reflect" + "github.com/databricks/databricks-sdk-go/service/catalog" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -33,6 +35,10 @@ func (newState *CreateProvider) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateProvider) SyncEffectiveFieldsDuringRead(existingState CreateProvider) { } +func (a CreateProvider) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateRecipient struct { // The delta sharing authentication type. AuthenticationType types.String `tfsdk:"authentication_type" tf:""` @@ -46,13 +52,13 @@ type CreateRecipient struct { // Expiration timestamp of the token, in epoch milliseconds. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` // IP Access List - IpAccessList []IpAccessList `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` // Name of Recipient. Name types.String `tfsdk:"name" tf:""` // Username of the recipient owner. Owner types.String `tfsdk:"owner" tf:"optional"` // Recipient properties as map of string key-value pairs. - PropertiesKvpairs []SecurablePropertiesKvPairs `tfsdk:"properties_kvpairs" tf:"optional,object"` + PropertiesKvpairs types.Object `tfsdk:"properties_kvpairs" tf:"optional,object"` // The one-time sharing code provided by the data recipient. This field is // required when the __authentication_type__ is **DATABRICKS**. SharingCode types.String `tfsdk:"sharing_code" tf:"optional"` @@ -64,6 +70,13 @@ func (newState *CreateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cr func (newState *CreateRecipient) SyncEffectiveFieldsDuringRead(existingState CreateRecipient) { } +func (a CreateRecipient) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessList": reflect.TypeOf(IpAccessList{}), + "PropertiesKvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), + } +} + type CreateShare struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -79,6 +92,10 @@ func (newState *CreateShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateShare) SyncEffectiveFieldsDuringRead(existingState CreateShare) { } +func (a CreateShare) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a provider type DeleteProviderRequest struct { // Name of the provider. @@ -91,6 +108,10 @@ func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringRead(existingState DeleteProviderRequest) { } +func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a share recipient type DeleteRecipientRequest struct { // Name of the recipient. @@ -103,6 +124,10 @@ func (newState *DeleteRecipientRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteRecipientRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRecipientRequest) { } +func (a DeleteRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -112,6 +137,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a share type DeleteShareRequest struct { // The name of the share. @@ -124,6 +153,10 @@ func (newState *DeleteShareRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteShareRequest) SyncEffectiveFieldsDuringRead(existingState DeleteShareRequest) { } +func (a DeleteShareRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a share activation URL type GetActivationUrlInfoRequest struct { // The one time activation url. It also accepts activation token. @@ -136,6 +169,10 @@ func (newState *GetActivationUrlInfoRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetActivationUrlInfoRequest) SyncEffectiveFieldsDuringRead(existingState GetActivationUrlInfoRequest) { } +func (a GetActivationUrlInfoRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetActivationUrlInfoResponse struct { } @@ -145,6 +182,10 @@ func (newState *GetActivationUrlInfoResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetActivationUrlInfoResponse) SyncEffectiveFieldsDuringRead(existingState GetActivationUrlInfoResponse) { } +func (a GetActivationUrlInfoResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a provider type GetProviderRequest struct { // Name of the provider. @@ -157,6 +198,10 @@ func (newState *GetProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetProviderRequest) SyncEffectiveFieldsDuringRead(existingState GetProviderRequest) { } +func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a share recipient type GetRecipientRequest struct { // Name of the recipient. @@ -169,13 +214,17 @@ func (newState *GetRecipientRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetRecipientRequest) SyncEffectiveFieldsDuringRead(existingState GetRecipientRequest) { } +func (a GetRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetRecipientSharePermissionsResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of data share permissions for a recipient. - PermissionsOut []ShareToPrivilegeAssignment `tfsdk:"permissions_out" tf:"optional"` + PermissionsOut types.List `tfsdk:"permissions_out" tf:"optional"` } func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRecipientSharePermissionsResponse) { @@ -184,6 +233,12 @@ func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringC func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState GetRecipientSharePermissionsResponse) { } +func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionsOut": reflect.TypeOf(ShareToPrivilegeAssignment{}), + } +} + // Get a share type GetShareRequest struct { // Query for data to include in the share. @@ -198,9 +253,13 @@ func (newState *GetShareRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetShareRequest) SyncEffectiveFieldsDuringRead(existingState GetShareRequest) { } +func (a GetShareRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type IpAccessList struct { // Allowed IP Addresses in CIDR notation. Limit of 100. - AllowedIpAddresses []types.String `tfsdk:"allowed_ip_addresses" tf:"optional"` + AllowedIpAddresses types.List `tfsdk:"allowed_ip_addresses" tf:"optional"` } func (newState *IpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan IpAccessList) { @@ -209,13 +268,19 @@ func (newState *IpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan IpAcc func (newState *IpAccessList) SyncEffectiveFieldsDuringRead(existingState IpAccessList) { } +func (a IpAccessList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllowedIpAddresses": reflect.TypeOf(""), + } +} + type ListProviderSharesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of provider shares. - Shares []ProviderShare `tfsdk:"shares" tf:"optional"` + Shares types.List `tfsdk:"shares" tf:"optional"` } func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListProviderSharesResponse) { @@ -224,6 +289,12 @@ func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringRead(existingState ListProviderSharesResponse) { } +func (a ListProviderSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Shares": reflect.TypeOf(ProviderShare{}), + } +} + // List providers type ListProvidersRequest struct { // If not provided, all providers will be returned. If no providers exist @@ -249,13 +320,17 @@ func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringRead(existingState ListProvidersRequest) { } +func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListProvidersResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of provider information objects. - Providers []ProviderInfo `tfsdk:"providers" tf:"optional"` + Providers types.List `tfsdk:"providers" tf:"optional"` } func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListProvidersResponse) { @@ -264,6 +339,12 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingState ListProvidersResponse) { } +func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Providers": reflect.TypeOf(ProviderInfo{}), + } +} + // List share recipients type ListRecipientsRequest struct { // If not provided, all recipients will be returned. If no recipients exist @@ -289,13 +370,17 @@ func (newState *ListRecipientsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListRecipientsRequest) SyncEffectiveFieldsDuringRead(existingState ListRecipientsRequest) { } +func (a ListRecipientsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListRecipientsResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of recipient information objects. - Recipients []RecipientInfo `tfsdk:"recipients" tf:"optional"` + Recipients types.List `tfsdk:"recipients" tf:"optional"` } func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListRecipientsResponse) { @@ -304,6 +389,12 @@ func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringRead(existingState ListRecipientsResponse) { } +func (a ListRecipientsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Recipients": reflect.TypeOf(RecipientInfo{}), + } +} + // List shares by Provider type ListSharesRequest struct { // Maximum number of shares to return. - when set to 0, the page length is @@ -328,13 +419,17 @@ func (newState *ListSharesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSharesRequest) SyncEffectiveFieldsDuringRead(existingState ListSharesRequest) { } +func (a ListSharesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListSharesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next // request (for the next page of results). NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // An array of data share information objects. - Shares []ShareInfo `tfsdk:"shares" tf:"optional"` + Shares types.List `tfsdk:"shares" tf:"optional"` } func (newState *ListSharesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListSharesResponse) { @@ -343,9 +438,15 @@ func (newState *ListSharesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSharesResponse) SyncEffectiveFieldsDuringRead(existingState ListSharesResponse) { } +func (a ListSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Shares": reflect.TypeOf(ShareInfo{}), + } +} + type Partition struct { // An array of partition values. - Values []PartitionValue `tfsdk:"value" tf:"optional"` + Values types.List `tfsdk:"value" tf:"optional"` } func (newState *Partition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partition) { @@ -354,6 +455,12 @@ func (newState *Partition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partitio func (newState *Partition) SyncEffectiveFieldsDuringRead(existingState Partition) { } +func (a Partition) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Values": reflect.TypeOf(PartitionValue{}), + } +} + type PartitionValue struct { // The name of the partition column. Name types.String `tfsdk:"name" tf:"optional"` @@ -375,11 +482,15 @@ func (newState *PartitionValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Par func (newState *PartitionValue) SyncEffectiveFieldsDuringRead(existingState PartitionValue) { } +func (a PartitionValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PrivilegeAssignment struct { // The principal (user email address or group name). Principal types.String `tfsdk:"principal" tf:"optional"` // The privileges assigned to the principal. - Privileges []types.String `tfsdk:"privileges" tf:"optional"` + Privileges types.List `tfsdk:"privileges" tf:"optional"` } func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan PrivilegeAssignment) { @@ -388,6 +499,12 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState PrivilegeAssignment) { } +func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Privileges": reflect.TypeOf(""), + } +} + type ProviderInfo struct { // The delta sharing authentication type. AuthenticationType types.String `tfsdk:"authentication_type" tf:"optional"` @@ -413,7 +530,7 @@ type ProviderInfo struct { Owner types.String `tfsdk:"owner" tf:"optional"` // The recipient profile. This field is only present when the // authentication_type is `TOKEN`. - RecipientProfile []RecipientProfile `tfsdk:"recipient_profile" tf:"optional,object"` + RecipientProfile types.Object `tfsdk:"recipient_profile" tf:"optional,object"` // This field is only present when the authentication_type is `TOKEN` or not // provided. RecipientProfileStr types.String `tfsdk:"recipient_profile_str" tf:"optional"` @@ -432,6 +549,12 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Provi func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState ProviderInfo) { } +func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "RecipientProfile": reflect.TypeOf(RecipientProfile{}), + } +} + type ProviderShare struct { // The name of the Provider Share. Name types.String `tfsdk:"name" tf:"optional"` @@ -443,6 +566,10 @@ func (newState *ProviderShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Prov func (newState *ProviderShare) SyncEffectiveFieldsDuringRead(existingState ProviderShare) { } +func (a ProviderShare) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RecipientInfo struct { // A boolean status field showing whether the Recipient's activation URL has // been exercised or not. @@ -467,7 +594,7 @@ type RecipientInfo struct { // __cloud__:__region__:__metastore-uuid__. DataRecipientGlobalMetastoreId types.String `tfsdk:"data_recipient_global_metastore_id" tf:"optional"` // IP Access List - IpAccessList []IpAccessList `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` // Unique identifier of recipient's Unity Catalog metastore. This field is // only present when the __authentication_type__ is **DATABRICKS** MetastoreId types.String `tfsdk:"metastore_id" tf:"optional"` @@ -476,7 +603,7 @@ type RecipientInfo struct { // Username of the recipient owner. Owner types.String `tfsdk:"owner" tf:"optional"` // Recipient properties as map of string key-value pairs. - PropertiesKvpairs []SecurablePropertiesKvPairs `tfsdk:"properties_kvpairs" tf:"optional,object"` + PropertiesKvpairs types.Object `tfsdk:"properties_kvpairs" tf:"optional,object"` // Cloud region of the recipient's Unity Catalog Metstore. This field is // only present when the __authentication_type__ is **DATABRICKS**. Region types.String `tfsdk:"region" tf:"optional"` @@ -484,7 +611,7 @@ type RecipientInfo struct { // only present when the __authentication_type__ is **DATABRICKS**. SharingCode types.String `tfsdk:"sharing_code" tf:"optional"` // This field is only present when the __authentication_type__ is **TOKEN**. - Tokens []RecipientTokenInfo `tfsdk:"tokens" tf:"optional"` + Tokens types.List `tfsdk:"tokens" tf:"optional"` // Time at which the recipient was updated, in epoch milliseconds. UpdatedAt types.Int64 `tfsdk:"updated_at" tf:"optional"` // Username of recipient updater. @@ -497,6 +624,14 @@ func (newState *RecipientInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Reci func (newState *RecipientInfo) SyncEffectiveFieldsDuringRead(existingState RecipientInfo) { } +func (a RecipientInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessList": reflect.TypeOf(IpAccessList{}), + "PropertiesKvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), + "Tokens": reflect.TypeOf(RecipientTokenInfo{}), + } +} + type RecipientProfile struct { // The token used to authorize the recipient. BearerToken types.String `tfsdk:"bearer_token" tf:"optional"` @@ -512,6 +647,10 @@ func (newState *RecipientProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RecipientProfile) SyncEffectiveFieldsDuringRead(existingState RecipientProfile) { } +func (a RecipientProfile) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RecipientTokenInfo struct { // Full activation URL to retrieve the access token. It will be empty if the // token is already retrieved. @@ -536,6 +675,10 @@ func (newState *RecipientTokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RecipientTokenInfo) SyncEffectiveFieldsDuringRead(existingState RecipientTokenInfo) { } +func (a RecipientTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an access token type RetrieveTokenRequest struct { // The one time activation url. It also accepts activation token. @@ -548,6 +691,10 @@ func (newState *RetrieveTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RetrieveTokenRequest) SyncEffectiveFieldsDuringRead(existingState RetrieveTokenRequest) { } +func (a RetrieveTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RetrieveTokenResponse struct { // The token used to authorize the recipient. BearerToken types.String `tfsdk:"bearerToken" tf:"optional"` @@ -565,6 +712,10 @@ func (newState *RetrieveTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *RetrieveTokenResponse) SyncEffectiveFieldsDuringRead(existingState RetrieveTokenResponse) { } +func (a RetrieveTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RotateRecipientToken struct { // The expiration time of the bearer token in ISO 8601 format. This will set // the expiration_time of existing token only to a smaller timestamp, it @@ -581,11 +732,15 @@ func (newState *RotateRecipientToken) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RotateRecipientToken) SyncEffectiveFieldsDuringRead(existingState RotateRecipientToken) { } +func (a RotateRecipientToken) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // An object with __properties__ containing map of key-value properties attached // to the securable. type SecurablePropertiesKvPairs struct { // A map of key-value properties attached to the securable. - Properties map[string]types.String `tfsdk:"properties" tf:""` + Properties types.Map `tfsdk:"properties" tf:""` } func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOrUpdate(plan SecurablePropertiesKvPairs) { @@ -594,6 +749,12 @@ func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existingState SecurablePropertiesKvPairs) { } +func (a SecurablePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Properties": reflect.TypeOf(""), + } +} + type ShareInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -604,10 +765,9 @@ type ShareInfo struct { // Name of the share. Name types.String `tfsdk:"name" tf:"optional"` // A list of shared data objects within the share. - Objects []SharedDataObject `tfsdk:"object" tf:"optional"` + Objects types.List `tfsdk:"object" tf:"optional"` // Username of current owner of share. - Owner types.String `tfsdk:"owner" tf:"optional"` - EffectiveOwner types.String `tfsdk:"effective_owner" tf:"computed,optional"` + Owner types.String `tfsdk:"owner" tf:"computed,optional"` // Storage Location URL (full path) for the share. StorageLocation types.String `tfsdk:"storage_location" tf:"optional"` // Storage root URL for the share. @@ -619,14 +779,14 @@ type ShareInfo struct { } func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInfo) { - newState.EffectiveOwner = newState.Owner - newState.Owner = plan.Owner } func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo) { - newState.EffectiveOwner = existingState.EffectiveOwner - if existingState.EffectiveOwner.ValueString() == newState.Owner.ValueString() { - newState.Owner = existingState.Owner +} + +func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Objects": reflect.TypeOf(SharedDataObject{}), } } @@ -654,9 +814,13 @@ func (newState *SharePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *SharePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState SharePermissionsRequest) { } +func (a SharePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ShareToPrivilegeAssignment struct { // The privileges assigned to the principal. - PrivilegeAssignments []PrivilegeAssignment `tfsdk:"privilege_assignments" tf:"optional"` + PrivilegeAssignments types.List `tfsdk:"privilege_assignments" tf:"optional"` // The share name. ShareName types.String `tfsdk:"share_name" tf:"optional"` } @@ -667,6 +831,12 @@ func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState ShareToPrivilegeAssignment) { } +func (a ShareToPrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PrivilegeAssignments": reflect.TypeOf(PrivilegeAssignment{}), + } +} + type SharedDataObject struct { // The time when this data object is added to the share, in epoch // milliseconds. @@ -674,8 +844,7 @@ type SharedDataObject struct { // Username of the sharer. AddedBy types.String `tfsdk:"added_by" tf:"computed,optional"` // Whether to enable cdf or indicate if cdf is enabled on the shared object. - CdfEnabled types.Bool `tfsdk:"cdf_enabled" tf:"optional"` - EffectiveCdfEnabled types.Bool `tfsdk:"effective_cdf_enabled" tf:"computed,optional"` + CdfEnabled types.Bool `tfsdk:"cdf_enabled" tf:"computed,optional"` // A user-provided comment when adding the data object to the share. // [Update:OPT] Comment types.String `tfsdk:"comment" tf:"optional"` @@ -687,21 +856,19 @@ type SharedDataObject struct { DataObjectType types.String `tfsdk:"data_object_type" tf:"optional"` // Whether to enable or disable sharing of data history. If not specified, // the default is **DISABLED**. - HistoryDataSharingStatus types.String `tfsdk:"history_data_sharing_status" tf:"optional"` - EffectiveHistoryDataSharingStatus types.String `tfsdk:"effective_history_data_sharing_status" tf:"computed,optional"` + HistoryDataSharingStatus types.String `tfsdk:"history_data_sharing_status" tf:"computed,optional"` // A fully qualified name that uniquely identifies a data object. // // For example, a table's fully qualified name is in the format of // `..`. Name types.String `tfsdk:"name" tf:""` // Array of partitions for the shared data. - Partitions []Partition `tfsdk:"partition" tf:"optional"` + Partitions types.List `tfsdk:"partition" tf:"optional"` // A user-provided new name for the data object within the share. If this // new name is not provided, the object's original name will be used as the // `shared_as` name. The `shared_as` name must be unique within a share. For // tables, the new name must follow the format of `.
`. - SharedAs types.String `tfsdk:"shared_as" tf:"optional"` - EffectiveSharedAs types.String `tfsdk:"effective_shared_as" tf:"computed,optional"` + SharedAs types.String `tfsdk:"shared_as" tf:"computed,optional"` // The start version associated with the object. This allows data providers // to control the lowest object version that is accessible by clients. If // specified, clients can query snapshots or changes for versions >= @@ -709,8 +876,7 @@ type SharedDataObject struct { // version of the object at the time it was added to the share. // // NOTE: The start_version should be <= the `current` version of the object. - StartVersion types.Int64 `tfsdk:"start_version" tf:"optional"` - EffectiveStartVersion types.Int64 `tfsdk:"effective_start_version" tf:"computed,optional"` + StartVersion types.Int64 `tfsdk:"start_version" tf:"computed,optional"` // One of: **ACTIVE**, **PERMISSION_DENIED**. Status types.String `tfsdk:"status" tf:"computed,optional"` // A user-provided new name for the data object within the share. If this @@ -722,32 +888,14 @@ type SharedDataObject struct { } func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan SharedDataObject) { - newState.EffectiveCdfEnabled = newState.CdfEnabled - newState.CdfEnabled = plan.CdfEnabled - newState.EffectiveHistoryDataSharingStatus = newState.HistoryDataSharingStatus - newState.HistoryDataSharingStatus = plan.HistoryDataSharingStatus - newState.EffectiveSharedAs = newState.SharedAs - newState.SharedAs = plan.SharedAs - newState.EffectiveStartVersion = newState.StartVersion - newState.StartVersion = plan.StartVersion } func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { - newState.EffectiveCdfEnabled = existingState.EffectiveCdfEnabled - if existingState.EffectiveCdfEnabled.ValueBool() == newState.CdfEnabled.ValueBool() { - newState.CdfEnabled = existingState.CdfEnabled - } - newState.EffectiveHistoryDataSharingStatus = existingState.EffectiveHistoryDataSharingStatus - if existingState.EffectiveHistoryDataSharingStatus.ValueString() == newState.HistoryDataSharingStatus.ValueString() { - newState.HistoryDataSharingStatus = existingState.HistoryDataSharingStatus - } - newState.EffectiveSharedAs = existingState.EffectiveSharedAs - if existingState.EffectiveSharedAs.ValueString() == newState.SharedAs.ValueString() { - newState.SharedAs = existingState.SharedAs - } - newState.EffectiveStartVersion = existingState.EffectiveStartVersion - if existingState.EffectiveStartVersion.ValueInt64() == newState.StartVersion.ValueInt64() { - newState.StartVersion = existingState.StartVersion +} + +func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Partitions": reflect.TypeOf(Partition{}), } } @@ -755,7 +903,7 @@ type SharedDataObjectUpdate struct { // One of: **ADD**, **REMOVE**, **UPDATE**. Action types.String `tfsdk:"action" tf:"optional"` // The data object that is being added, removed, or updated. - DataObject []SharedDataObject `tfsdk:"data_object" tf:"optional,object"` + DataObject types.Object `tfsdk:"data_object" tf:"optional,object"` } func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan SharedDataObjectUpdate) { @@ -764,6 +912,12 @@ func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringRead(existingState SharedDataObjectUpdate) { } +func (a SharedDataObjectUpdate) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataObject": reflect.TypeOf(SharedDataObject{}), + } +} + type UpdatePermissionsResponse struct { } @@ -773,6 +927,10 @@ func (newState *UpdatePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdatePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState UpdatePermissionsResponse) { } +func (a UpdatePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateProvider struct { // Description about the provider. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -793,13 +951,17 @@ func (newState *UpdateProvider) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateProvider) SyncEffectiveFieldsDuringRead(existingState UpdateProvider) { } +func (a UpdateProvider) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateRecipient struct { // Description about the recipient. Comment types.String `tfsdk:"comment" tf:"optional"` // Expiration timestamp of the token, in epoch milliseconds. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` // IP Access List - IpAccessList []IpAccessList `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` // Name of the recipient. Name types.String `tfsdk:"-"` // New name for the recipient. @@ -810,7 +972,7 @@ type UpdateRecipient struct { // update request, the specified properties will override the existing // properties. To add and remove properties, one would need to perform a // read-modify-write. - PropertiesKvpairs []SecurablePropertiesKvPairs `tfsdk:"properties_kvpairs" tf:"optional,object"` + PropertiesKvpairs types.Object `tfsdk:"properties_kvpairs" tf:"optional,object"` } func (newState *UpdateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRecipient) { @@ -819,6 +981,13 @@ func (newState *UpdateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateRecipient) SyncEffectiveFieldsDuringRead(existingState UpdateRecipient) { } +func (a UpdateRecipient) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "IpAccessList": reflect.TypeOf(IpAccessList{}), + "PropertiesKvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), + } +} + type UpdateResponse struct { } @@ -828,6 +997,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateShare struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -836,29 +1009,28 @@ type UpdateShare struct { // New name for the share. NewName types.String `tfsdk:"new_name" tf:"optional"` // Username of current owner of share. - Owner types.String `tfsdk:"owner" tf:"optional"` - EffectiveOwner types.String `tfsdk:"effective_owner" tf:"computed,optional"` + Owner types.String `tfsdk:"owner" tf:"computed,optional"` // Storage root URL for the share. StorageRoot types.String `tfsdk:"storage_root" tf:"optional"` // Array of shared data object updates. - Updates []SharedDataObjectUpdate `tfsdk:"updates" tf:"optional"` + Updates types.List `tfsdk:"updates" tf:"optional"` } func (newState *UpdateShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateShare) { - newState.EffectiveOwner = newState.Owner - newState.Owner = plan.Owner } func (newState *UpdateShare) SyncEffectiveFieldsDuringRead(existingState UpdateShare) { - newState.EffectiveOwner = existingState.EffectiveOwner - if existingState.EffectiveOwner.ValueString() == newState.Owner.ValueString() { - newState.Owner = existingState.Owner +} + +func (a UpdateShare) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Updates": reflect.TypeOf(SharedDataObjectUpdate{}), } } type UpdateSharePermissions struct { // Array of permission changes. - Changes catalog.PermissionsChange `tfsdk:"changes" tf:"optional"` + Changes types.List `tfsdk:"changes" tf:"optional"` // Maximum number of permissions to return. - when set to 0, the page length // is set to a server configured value (recommended); - when set to a value // greater than 0, the page length is the minimum of this value and a server @@ -880,3 +1052,9 @@ func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringRead(existingState UpdateSharePermissions) { } + +func (a UpdateSharePermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Changes": reflect.TypeOf(catalog.PermissionsChange{}), + } +} diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index b961f17901..c5660ef6a6 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package sql_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -29,9 +31,13 @@ func (newState *AccessControl) SyncEffectiveFieldsDuringCreateOrUpdate(plan Acce func (newState *AccessControl) SyncEffectiveFieldsDuringRead(existingState AccessControl) { } +func (a AccessControl) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Alert struct { // Trigger conditions of the alert. - Condition []AlertCondition `tfsdk:"condition" tf:"optional,object"` + Condition types.Object `tfsdk:"condition" tf:"optional,object"` // The timestamp indicating when the alert was created. CreateTime types.String `tfsdk:"create_time" tf:"optional"` // Custom body of alert notification, if it exists. See [here] for custom @@ -81,6 +87,12 @@ func (newState *Alert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Alert) { func (newState *Alert) SyncEffectiveFieldsDuringRead(existingState Alert) { } +func (a Alert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Condition": reflect.TypeOf(AlertCondition{}), + } +} + type AlertCondition struct { // Alert state if result is empty. EmptyResultState types.String `tfsdk:"empty_result_state" tf:"optional"` @@ -88,9 +100,9 @@ type AlertCondition struct { Op types.String `tfsdk:"op" tf:"optional"` // Name of the column from the query result to use for comparison in alert // evaluation. - Operand []AlertConditionOperand `tfsdk:"operand" tf:"optional,object"` + Operand types.Object `tfsdk:"operand" tf:"optional,object"` // Threshold value used for comparison in alert evaluation. - Threshold []AlertConditionThreshold `tfsdk:"threshold" tf:"optional,object"` + Threshold types.Object `tfsdk:"threshold" tf:"optional,object"` } func (newState *AlertCondition) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertCondition) { @@ -99,8 +111,15 @@ func (newState *AlertCondition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ale func (newState *AlertCondition) SyncEffectiveFieldsDuringRead(existingState AlertCondition) { } +func (a AlertCondition) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Operand": reflect.TypeOf(AlertConditionOperand{}), + "Threshold": reflect.TypeOf(AlertConditionThreshold{}), + } +} + type AlertConditionOperand struct { - Column []AlertOperandColumn `tfsdk:"column" tf:"optional,object"` + Column types.Object `tfsdk:"column" tf:"optional,object"` } func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertConditionOperand) { @@ -109,8 +128,14 @@ func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringRead(existingState AlertConditionOperand) { } +func (a AlertConditionOperand) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Column": reflect.TypeOf(AlertOperandColumn{}), + } +} + type AlertConditionThreshold struct { - Value []AlertOperandValue `tfsdk:"value" tf:"optional,object"` + Value types.Object `tfsdk:"value" tf:"optional,object"` } func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertConditionThreshold) { @@ -119,6 +144,12 @@ func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringRead(existingState AlertConditionThreshold) { } +func (a AlertConditionThreshold) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Value": reflect.TypeOf(AlertOperandValue{}), + } +} + type AlertOperandColumn struct { Name types.String `tfsdk:"name" tf:"optional"` } @@ -129,6 +160,10 @@ func (newState *AlertOperandColumn) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertOperandColumn) SyncEffectiveFieldsDuringRead(existingState AlertOperandColumn) { } +func (a AlertOperandColumn) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AlertOperandValue struct { BoolValue types.Bool `tfsdk:"bool_value" tf:"optional"` @@ -143,6 +178,10 @@ func (newState *AlertOperandValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertOperandValue) SyncEffectiveFieldsDuringRead(existingState AlertOperandValue) { } +func (a AlertOperandValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Alert configuration options. type AlertOptions struct { // Name of column in the query result to compare in alert evaluation. @@ -177,6 +216,10 @@ func (newState *AlertOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Alert func (newState *AlertOptions) SyncEffectiveFieldsDuringRead(existingState AlertOptions) { } +func (a AlertOptions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AlertQuery struct { // The timestamp when this query was created. CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -208,11 +251,11 @@ type AlertQuery struct { // on the query page. Name types.String `tfsdk:"name" tf:"optional"` - Options []QueryOptions `tfsdk:"options" tf:"optional,object"` + Options types.Object `tfsdk:"options" tf:"optional,object"` // The text of the query to be run. Query types.String `tfsdk:"query" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // The timestamp at which this query was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` // The ID of the user who owns the query. @@ -225,6 +268,13 @@ func (newState *AlertQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertQu func (newState *AlertQuery) SyncEffectiveFieldsDuringRead(existingState AlertQuery) { } +func (a AlertQuery) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(QueryOptions{}), + "Tags": reflect.TypeOf(""), + } +} + // Describes metadata for a particular chunk, within a result set; this // structure is used both within a manifest, and when fetching individual chunk // data or links. @@ -246,6 +296,10 @@ func (newState *BaseChunkInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Base func (newState *BaseChunkInfo) SyncEffectiveFieldsDuringRead(existingState BaseChunkInfo) { } +func (a BaseChunkInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Cancel statement execution type CancelExecutionRequest struct { // The statement ID is returned upon successfully submitting a SQL @@ -259,6 +313,10 @@ func (newState *CancelExecutionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CancelExecutionRequest) SyncEffectiveFieldsDuringRead(existingState CancelExecutionRequest) { } +func (a CancelExecutionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CancelExecutionResponse struct { } @@ -268,6 +326,10 @@ func (newState *CancelExecutionResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CancelExecutionResponse) SyncEffectiveFieldsDuringRead(existingState CancelExecutionResponse) { } +func (a CancelExecutionResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Configures the channel name and DBSQL version of the warehouse. // CHANNEL_NAME_CUSTOM should be chosen only when `dbsql_version` is specified. type Channel struct { @@ -282,6 +344,10 @@ func (newState *Channel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Channel) { func (newState *Channel) SyncEffectiveFieldsDuringRead(existingState Channel) { } +func (a Channel) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Details about a Channel. type ChannelInfo struct { // DB SQL Version the Channel is mapped to. @@ -296,6 +362,10 @@ func (newState *ChannelInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Channe func (newState *ChannelInfo) SyncEffectiveFieldsDuringRead(existingState ChannelInfo) { } +func (a ChannelInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ColumnInfo struct { // The name of the column. Name types.String `tfsdk:"name" tf:"optional"` @@ -322,11 +392,15 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } +func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateAlert struct { // Name of the alert. Name types.String `tfsdk:"name" tf:""` // Alert configuration options. - Options []AlertOptions `tfsdk:"options" tf:"object"` + Options types.Object `tfsdk:"options" tf:"object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // Query ID. @@ -343,8 +417,14 @@ func (newState *CreateAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateAlert) SyncEffectiveFieldsDuringRead(existingState CreateAlert) { } +func (a CreateAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(AlertOptions{}), + } +} + type CreateAlertRequest struct { - Alert []CreateAlertRequestAlert `tfsdk:"alert" tf:"optional,object"` + Alert types.Object `tfsdk:"alert" tf:"optional,object"` } func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateAlertRequest) { @@ -353,9 +433,15 @@ func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringRead(existingState CreateAlertRequest) { } +func (a CreateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Alert": reflect.TypeOf(CreateAlertRequestAlert{}), + } +} + type CreateAlertRequestAlert struct { // Trigger conditions of the alert. - Condition []AlertCondition `tfsdk:"condition" tf:"optional,object"` + Condition types.Object `tfsdk:"condition" tf:"optional,object"` // Custom body of alert notification, if it exists. See [here] for custom // templating instructions. // @@ -387,8 +473,14 @@ func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingState CreateAlertRequestAlert) { } +func (a CreateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Condition": reflect.TypeOf(AlertCondition{}), + } +} + type CreateQueryRequest struct { - Query []CreateQueryRequestQuery `tfsdk:"query" tf:"optional,object"` + Query types.Object `tfsdk:"query" tf:"optional,object"` } func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateQueryRequest) { @@ -397,6 +489,12 @@ func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringRead(existingState CreateQueryRequest) { } +func (a CreateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Query": reflect.TypeOf(CreateQueryRequestQuery{}), + } +} + type CreateQueryRequestQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -409,7 +507,7 @@ type CreateQueryRequestQuery struct { // and on the query page. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // List of query parameter definitions. - Parameters []QueryParameter `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // Workspace path of the workspace folder containing the object. ParentPath types.String `tfsdk:"parent_path" tf:"optional"` // Text of the query to be run. @@ -419,7 +517,7 @@ type CreateQueryRequestQuery struct { // Name of the schema where this query will be executed. Schema types.String `tfsdk:"schema" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // ID of the SQL warehouse attached to the query. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` } @@ -430,6 +528,13 @@ func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingState CreateQueryRequestQuery) { } +func (a CreateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(QueryParameter{}), + "Tags": reflect.TypeOf(""), + } +} + // Add visualization to a query type CreateQueryVisualizationsLegacyRequest struct { // A short description of this visualization. This is not displayed in the @@ -454,8 +559,12 @@ func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDurin func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState CreateQueryVisualizationsLegacyRequest) { } +func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateVisualizationRequest struct { - Visualization []CreateVisualizationRequestVisualization `tfsdk:"visualization" tf:"optional,object"` + Visualization types.Object `tfsdk:"visualization" tf:"optional,object"` } func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateVisualizationRequest) { @@ -464,6 +573,12 @@ func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState CreateVisualizationRequest) { } +func (a CreateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Visualization": reflect.TypeOf(CreateVisualizationRequestVisualization{}), + } +} + type CreateVisualizationRequestVisualization struct { // The display name of the visualization. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -487,6 +602,10 @@ func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuri func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuringRead(existingState CreateVisualizationRequestVisualization) { } +func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateWarehouseRequest struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -498,7 +617,7 @@ type CreateWarehouseRequest struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel []Channel `tfsdk:"channel" tf:"optional,object"` + Channel types.Object `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -544,7 +663,7 @@ type CreateWarehouseRequest struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags []EndpointTags `tfsdk:"tags" tf:"optional,object"` + Tags types.Object `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -557,6 +676,13 @@ func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState CreateWarehouseRequest) { } +func (a CreateWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Channel": reflect.TypeOf(Channel{}), + "Tags": reflect.TypeOf(EndpointTags{}), + } +} + type CreateWarehouseResponse struct { // Id for the SQL warehouse. This value is unique across all SQL warehouses. Id types.String `tfsdk:"id" tf:"optional"` @@ -568,13 +694,17 @@ func (newState *CreateWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState CreateWarehouseResponse) { } +func (a CreateWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateWidget struct { // Dashboard ID returned by :method:dashboards/create. DashboardId types.String `tfsdk:"dashboard_id" tf:""` // Widget ID returned by :method:dashboardwidgets/create Id types.String `tfsdk:"-"` - Options []WidgetOptions `tfsdk:"options" tf:"object"` + Options types.Object `tfsdk:"options" tf:"object"` // If this is a textbox widget, the application displays this text. This // field is ignored if the widget contains a visualization in the // `visualization` field. @@ -591,6 +721,12 @@ func (newState *CreateWidget) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreateWidget) SyncEffectiveFieldsDuringRead(existingState CreateWidget) { } +func (a CreateWidget) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(WidgetOptions{}), + } +} + // A JSON representing a dashboard containing widgets of visualizations and text // boxes. type Dashboard struct { @@ -619,7 +755,7 @@ type Dashboard struct { // the dashboard page. Name types.String `tfsdk:"name" tf:"optional"` - Options []DashboardOptions `tfsdk:"options" tf:"optional,object"` + Options types.Object `tfsdk:"options" tf:"optional,object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // * `CAN_VIEW`: Can view the query * `CAN_RUN`: Can run the query * @@ -629,15 +765,15 @@ type Dashboard struct { // spaces. Appears in the URL for this query. Slug types.String `tfsdk:"slug" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // Timestamp when this dashboard was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` - User []User `tfsdk:"user" tf:"optional,object"` + User types.Object `tfsdk:"user" tf:"optional,object"` // The ID of the user who owns the dashboard. UserId types.Int64 `tfsdk:"user_id" tf:"optional"` - Widgets []Widget `tfsdk:"widgets" tf:"optional"` + Widgets types.List `tfsdk:"widgets" tf:"optional"` } func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboard) { @@ -646,6 +782,15 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboar func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard) { } +func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(DashboardOptions{}), + "Tags": reflect.TypeOf(""), + "User": reflect.TypeOf(User{}), + "Widgets": reflect.TypeOf(Widget{}), + } +} + type DashboardEditContent struct { DashboardId types.String `tfsdk:"-"` // The title of this dashboard that appears in list views and at the top of @@ -656,7 +801,7 @@ type DashboardEditContent struct { // owner" behavior) RunAsRole types.String `tfsdk:"run_as_role" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *DashboardEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan DashboardEditContent) { @@ -665,6 +810,12 @@ func (newState *DashboardEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DashboardEditContent) SyncEffectiveFieldsDuringRead(existingState DashboardEditContent) { } +func (a DashboardEditContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(""), + } +} + type DashboardOptions struct { // The timestamp when this dashboard was moved to trash. Only present when // the `is_archived` property is `true`. Trashed items are deleted after @@ -678,6 +829,10 @@ func (newState *DashboardOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DashboardOptions) SyncEffectiveFieldsDuringRead(existingState DashboardOptions) { } +func (a DashboardOptions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DashboardPostContent struct { // Indicates whether the dashboard filters are enabled DashboardFiltersEnabled types.Bool `tfsdk:"dashboard_filters_enabled" tf:"optional"` @@ -694,7 +849,7 @@ type DashboardPostContent struct { // owner" behavior) RunAsRole types.String `tfsdk:"run_as_role" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *DashboardPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan DashboardPostContent) { @@ -703,6 +858,12 @@ func (newState *DashboardPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DashboardPostContent) SyncEffectiveFieldsDuringRead(existingState DashboardPostContent) { } +func (a DashboardPostContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(""), + } +} + // A JSON object representing a DBSQL data source / SQL warehouse. type DataSource struct { // Data source ID maps to the ID of the data source used by the resource and @@ -737,6 +898,10 @@ func (newState *DataSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataSou func (newState *DataSource) SyncEffectiveFieldsDuringRead(existingState DataSource) { } +func (a DataSource) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DateRange struct { End types.String `tfsdk:"end" tf:""` @@ -749,9 +914,13 @@ func (newState *DateRange) SyncEffectiveFieldsDuringCreateOrUpdate(plan DateRang func (newState *DateRange) SyncEffectiveFieldsDuringRead(existingState DateRange) { } +func (a DateRange) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DateRangeValue struct { // Manually specified date-time range value. - DateRangeValue []DateRange `tfsdk:"date_range_value" tf:"optional,object"` + DateRangeValue types.Object `tfsdk:"date_range_value" tf:"optional,object"` // Dynamic date-time range value based on current date-time. DynamicDateRangeValue types.String `tfsdk:"dynamic_date_range_value" tf:"optional"` // Date-time precision to format the value into when the query is run. @@ -767,6 +936,12 @@ func (newState *DateRangeValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dat func (newState *DateRangeValue) SyncEffectiveFieldsDuringRead(existingState DateRangeValue) { } +func (a DateRangeValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DateRangeValue": reflect.TypeOf(DateRange{}), + } +} + type DateValue struct { // Manually specified date-time value. DateValue types.String `tfsdk:"date_value" tf:"optional"` @@ -783,6 +958,10 @@ func (newState *DateValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan DateValu func (newState *DateValue) SyncEffectiveFieldsDuringRead(existingState DateValue) { } +func (a DateValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete an alert type DeleteAlertsLegacyRequest struct { AlertId types.String `tfsdk:"-"` @@ -794,6 +973,10 @@ func (newState *DeleteAlertsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteAlertsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAlertsLegacyRequest) { } +func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Remove a dashboard type DeleteDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -805,6 +988,10 @@ func (newState *DeleteDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteDashboardRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDashboardRequest) { } +func (a DeleteDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Remove widget type DeleteDashboardWidgetRequest struct { // Widget ID returned by :method:dashboardwidgets/create @@ -817,6 +1004,10 @@ func (newState *DeleteDashboardWidgetRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteDashboardWidgetRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDashboardWidgetRequest) { } +func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a query type DeleteQueriesLegacyRequest struct { QueryId types.String `tfsdk:"-"` @@ -828,6 +1019,10 @@ func (newState *DeleteQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQueriesLegacyRequest) { } +func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Remove visualization type DeleteQueryVisualizationsLegacyRequest struct { // Widget ID returned by :method:queryvizualisations/create @@ -840,6 +1035,10 @@ func (newState *DeleteQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDurin func (newState *DeleteQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQueryVisualizationsLegacyRequest) { } +func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -849,6 +1048,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Remove a visualization type DeleteVisualizationRequest struct { Id types.String `tfsdk:"-"` @@ -860,6 +1063,10 @@ func (newState *DeleteVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVisualizationRequest) { } +func (a DeleteVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a warehouse type DeleteWarehouseRequest struct { // Required. Id of the SQL warehouse. @@ -872,6 +1079,10 @@ func (newState *DeleteWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWarehouseRequest) { } +func (a DeleteWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteWarehouseResponse struct { } @@ -881,12 +1092,16 @@ func (newState *DeleteWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWarehouseResponse) { } +func (a DeleteWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EditAlert struct { AlertId types.String `tfsdk:"-"` // Name of the alert. Name types.String `tfsdk:"name" tf:""` // Alert configuration options. - Options []AlertOptions `tfsdk:"options" tf:"object"` + Options types.Object `tfsdk:"options" tf:"object"` // Query ID. QueryId types.String `tfsdk:"query_id" tf:""` // Number of seconds after being triggered before the alert rearms itself @@ -901,6 +1116,12 @@ func (newState *EditAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditAler func (newState *EditAlert) SyncEffectiveFieldsDuringRead(existingState EditAlert) { } +func (a EditAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(AlertOptions{}), + } +} + type EditWarehouseRequest struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -910,7 +1131,7 @@ type EditWarehouseRequest struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel []Channel `tfsdk:"channel" tf:"optional,object"` + Channel types.Object `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -958,7 +1179,7 @@ type EditWarehouseRequest struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags []EndpointTags `tfsdk:"tags" tf:"optional,object"` + Tags types.Object `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -971,6 +1192,13 @@ func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState EditWarehouseRequest) { } +func (a EditWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Channel": reflect.TypeOf(Channel{}), + "Tags": reflect.TypeOf(EndpointTags{}), + } +} + type EditWarehouseResponse struct { } @@ -980,6 +1208,10 @@ func (newState *EditWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EditWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState EditWarehouseResponse) { } +func (a EditWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Represents an empty message, similar to google.protobuf.Empty, which is not // available in the firm right now. type Empty struct { @@ -991,6 +1223,10 @@ func (newState *Empty) SyncEffectiveFieldsDuringCreateOrUpdate(plan Empty) { func (newState *Empty) SyncEffectiveFieldsDuringRead(existingState Empty) { } +func (a Empty) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EndpointConfPair struct { Key types.String `tfsdk:"key" tf:"optional"` @@ -1003,12 +1239,16 @@ func (newState *EndpointConfPair) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *EndpointConfPair) SyncEffectiveFieldsDuringRead(existingState EndpointConfPair) { } +func (a EndpointConfPair) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EndpointHealth struct { // Details about errors that are causing current degraded/failed status. Details types.String `tfsdk:"details" tf:"optional"` // The reason for failure to bring up clusters for this warehouse. This is // available when status is 'FAILED' and sometimes when it is DEGRADED. - FailureReason []TerminationReason `tfsdk:"failure_reason" tf:"optional,object"` + FailureReason types.Object `tfsdk:"failure_reason" tf:"optional,object"` // Deprecated. split into summary and details for security Message types.String `tfsdk:"message" tf:"optional"` // Health status of the warehouse. @@ -1024,6 +1264,12 @@ func (newState *EndpointHealth) SyncEffectiveFieldsDuringCreateOrUpdate(plan End func (newState *EndpointHealth) SyncEffectiveFieldsDuringRead(existingState EndpointHealth) { } +func (a EndpointHealth) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FailureReason": reflect.TypeOf(TerminationReason{}), + } +} + type EndpointInfo struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -1033,7 +1279,7 @@ type EndpointInfo struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel []Channel `tfsdk:"channel" tf:"optional,object"` + Channel types.Object `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -1051,7 +1297,7 @@ type EndpointInfo struct { EnableServerlessCompute types.Bool `tfsdk:"enable_serverless_compute" tf:"optional"` // Optional health status. Assume the warehouse is healthy if this field is // not set. - Health []EndpointHealth `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // unique identifier for warehouse Id types.String `tfsdk:"id" tf:"optional"` // Deprecated. Instance profile used to pass IAM role to the cluster @@ -1085,7 +1331,7 @@ type EndpointInfo struct { // current number of clusters running for the service NumClusters types.Int64 `tfsdk:"num_clusters" tf:"optional"` // ODBC parameters for the SQL warehouse - OdbcParams []OdbcParams `tfsdk:"odbc_params" tf:"optional,object"` + OdbcParams types.Object `tfsdk:"odbc_params" tf:"optional,object"` // Configurations whether the warehouse should use spot instances. SpotInstancePolicy types.String `tfsdk:"spot_instance_policy" tf:"optional"` // State of the warehouse @@ -1094,7 +1340,7 @@ type EndpointInfo struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags []EndpointTags `tfsdk:"tags" tf:"optional,object"` + Tags types.Object `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -1107,6 +1353,15 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState EndpointInfo) { } +func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Channel": reflect.TypeOf(Channel{}), + "Health": reflect.TypeOf(EndpointHealth{}), + "OdbcParams": reflect.TypeOf(OdbcParams{}), + "Tags": reflect.TypeOf(EndpointTags{}), + } +} + type EndpointTagPair struct { Key types.String `tfsdk:"key" tf:"optional"` @@ -1119,8 +1374,12 @@ func (newState *EndpointTagPair) SyncEffectiveFieldsDuringCreateOrUpdate(plan En func (newState *EndpointTagPair) SyncEffectiveFieldsDuringRead(existingState EndpointTagPair) { } +func (a EndpointTagPair) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EndpointTags struct { - CustomTags []EndpointTagPair `tfsdk:"custom_tags" tf:"optional"` + CustomTags types.List `tfsdk:"custom_tags" tf:"optional"` } func (newState *EndpointTags) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointTags) { @@ -1129,13 +1388,19 @@ func (newState *EndpointTags) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointTags) SyncEffectiveFieldsDuringRead(existingState EndpointTags) { } +func (a EndpointTags) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "CustomTags": reflect.TypeOf(EndpointTagPair{}), + } +} + type EnumValue struct { // List of valid query parameter values, newline delimited. EnumOptions types.String `tfsdk:"enum_options" tf:"optional"` // If specified, allows multiple values to be selected for this parameter. - MultiValuesOptions []MultiValuesOptions `tfsdk:"multi_values_options" tf:"optional,object"` + MultiValuesOptions types.Object `tfsdk:"multi_values_options" tf:"optional,object"` // List of selected query parameter values. - Values []types.String `tfsdk:"values" tf:"optional"` + Values types.List `tfsdk:"values" tf:"optional"` } func (newState *EnumValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan EnumValue) { @@ -1144,6 +1409,13 @@ func (newState *EnumValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan EnumValu func (newState *EnumValue) SyncEffectiveFieldsDuringRead(existingState EnumValue) { } +func (a EnumValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), + "Values": reflect.TypeOf(""), + } +} + type ExecuteStatementRequest struct { // Applies the given byte limit to the statement's result size. Byte counts // are based on internal data representations and might not match the final @@ -1235,7 +1507,7 @@ type ExecuteStatementRequest struct { // // [Parameter markers]: https://docs.databricks.com/sql/language-manual/sql-ref-parameter-marker.html // [`cast` function]: https://docs.databricks.com/sql/language-manual/functions/cast.html - Parameters []StatementParameterListItem `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // Applies the given row limit to the statement's result set, but unlike the // `LIMIT` clause in SQL, it also sets the `truncated` field in the response // to indicate whether the result was trimmed due to the limit or not. @@ -1276,6 +1548,12 @@ func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringRead(existingState ExecuteStatementRequest) { } +func (a ExecuteStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(StatementParameterListItem{}), + } +} + type ExternalLink struct { // The number of bytes in the result chunk. This field is not available when // using `INLINE` disposition. @@ -1293,7 +1571,7 @@ type ExternalLink struct { // typically used to pass a decryption key to the external service. The // values of these headers should be considered sensitive and the client // should not expose these values in a log. - HttpHeaders map[string]types.String `tfsdk:"http_headers" tf:"optional"` + HttpHeaders types.Map `tfsdk:"http_headers" tf:"optional"` // When fetching, provides the `chunk_index` for the _next_ chunk. If // absent, indicates there are no more chunks. The next chunk can be fetched // with a :method:statementexecution/getStatementResultChunkN request. @@ -1315,6 +1593,12 @@ func (newState *ExternalLink) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exter func (newState *ExternalLink) SyncEffectiveFieldsDuringRead(existingState ExternalLink) { } +func (a ExternalLink) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "HttpHeaders": reflect.TypeOf(""), + } +} + // Get an alert type GetAlertRequest struct { Id types.String `tfsdk:"-"` @@ -1326,6 +1610,10 @@ func (newState *GetAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetAlertRequest) SyncEffectiveFieldsDuringRead(existingState GetAlertRequest) { } +func (a GetAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an alert type GetAlertsLegacyRequest struct { AlertId types.String `tfsdk:"-"` @@ -1337,6 +1625,10 @@ func (newState *GetAlertsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetAlertsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState GetAlertsLegacyRequest) { } +func (a GetAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Retrieve a definition type GetDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -1348,6 +1640,10 @@ func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetDashboardRequest) { } +func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get object ACL type GetDbsqlPermissionRequest struct { // Object ID. An ACL is returned for the object with this UUID. @@ -1362,6 +1658,10 @@ func (newState *GetDbsqlPermissionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetDbsqlPermissionRequest) SyncEffectiveFieldsDuringRead(existingState GetDbsqlPermissionRequest) { } +func (a GetDbsqlPermissionRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a query definition. type GetQueriesLegacyRequest struct { QueryId types.String `tfsdk:"-"` @@ -1373,6 +1673,10 @@ func (newState *GetQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState GetQueriesLegacyRequest) { } +func (a GetQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a query type GetQueryRequest struct { Id types.String `tfsdk:"-"` @@ -1384,8 +1688,12 @@ func (newState *GetQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetQueryRequest) SyncEffectiveFieldsDuringRead(existingState GetQueryRequest) { } +func (a GetQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetResponse struct { - AccessControlList []AccessControl `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // An object's type and UUID, separated by a forward slash (/) character. ObjectId types.String `tfsdk:"object_id" tf:"optional"` // A singular noun object type. @@ -1398,6 +1706,12 @@ func (newState *GetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRes func (newState *GetResponse) SyncEffectiveFieldsDuringRead(existingState GetResponse) { } +func (a GetResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AccessControl{}), + } +} + // Get status, manifest, and result first chunk type GetStatementRequest struct { // The statement ID is returned upon successfully submitting a SQL @@ -1411,6 +1725,10 @@ func (newState *GetStatementRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetStatementRequest) SyncEffectiveFieldsDuringRead(existingState GetStatementRequest) { } +func (a GetStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get result chunk by index type GetStatementResultChunkNRequest struct { ChunkIndex types.Int64 `tfsdk:"-"` @@ -1425,6 +1743,10 @@ func (newState *GetStatementResultChunkNRequest) SyncEffectiveFieldsDuringCreate func (newState *GetStatementResultChunkNRequest) SyncEffectiveFieldsDuringRead(existingState GetStatementResultChunkNRequest) { } +func (a GetStatementResultChunkNRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get SQL warehouse permission levels type GetWarehousePermissionLevelsRequest struct { // The SQL warehouse for which to get or manage permissions. @@ -1437,9 +1759,13 @@ func (newState *GetWarehousePermissionLevelsRequest) SyncEffectiveFieldsDuringCr func (newState *GetWarehousePermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionLevelsRequest) { } +func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetWarehousePermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []WarehousePermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetWarehousePermissionLevelsResponse) { @@ -1448,6 +1774,12 @@ func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringC func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionLevelsResponse) { } +func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(WarehousePermissionsDescription{}), + } +} + // Get SQL warehouse permissions type GetWarehousePermissionsRequest struct { // The SQL warehouse for which to get or manage permissions. @@ -1460,6 +1792,10 @@ func (newState *GetWarehousePermissionsRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetWarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionsRequest) { } +func (a GetWarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get warehouse info type GetWarehouseRequest struct { // Required. Id of the SQL warehouse. @@ -1472,6 +1808,10 @@ func (newState *GetWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehouseRequest) { } +func (a GetWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetWarehouseResponse struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -1481,7 +1821,7 @@ type GetWarehouseResponse struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel []Channel `tfsdk:"channel" tf:"optional,object"` + Channel types.Object `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -1499,7 +1839,7 @@ type GetWarehouseResponse struct { EnableServerlessCompute types.Bool `tfsdk:"enable_serverless_compute" tf:"optional"` // Optional health status. Assume the warehouse is healthy if this field is // not set. - Health []EndpointHealth `tfsdk:"health" tf:"optional,object"` + Health types.Object `tfsdk:"health" tf:"optional,object"` // unique identifier for warehouse Id types.String `tfsdk:"id" tf:"optional"` // Deprecated. Instance profile used to pass IAM role to the cluster @@ -1533,7 +1873,7 @@ type GetWarehouseResponse struct { // current number of clusters running for the service NumClusters types.Int64 `tfsdk:"num_clusters" tf:"optional"` // ODBC parameters for the SQL warehouse - OdbcParams []OdbcParams `tfsdk:"odbc_params" tf:"optional,object"` + OdbcParams types.Object `tfsdk:"odbc_params" tf:"optional,object"` // Configurations whether the warehouse should use spot instances. SpotInstancePolicy types.String `tfsdk:"spot_instance_policy" tf:"optional"` // State of the warehouse @@ -1542,7 +1882,7 @@ type GetWarehouseResponse struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags []EndpointTags `tfsdk:"tags" tf:"optional,object"` + Tags types.Object `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -1555,23 +1895,32 @@ func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState GetWarehouseResponse) { } +func (a GetWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Channel": reflect.TypeOf(Channel{}), + "Health": reflect.TypeOf(EndpointHealth{}), + "OdbcParams": reflect.TypeOf(OdbcParams{}), + "Tags": reflect.TypeOf(EndpointTags{}), + } +} + type GetWorkspaceWarehouseConfigResponse struct { // Optional: Channel selection details - Channel []Channel `tfsdk:"channel" tf:"optional,object"` + Channel types.Object `tfsdk:"channel" tf:"optional,object"` // Deprecated: Use sql_configuration_parameters - ConfigParam []RepeatedEndpointConfPairs `tfsdk:"config_param" tf:"optional,object"` + ConfigParam types.Object `tfsdk:"config_param" tf:"optional,object"` // Spark confs for external hive metastore configuration JSON serialized // size must be less than <= 512K - DataAccessConfig []EndpointConfPair `tfsdk:"data_access_config" tf:"optional"` + DataAccessConfig types.List `tfsdk:"data_access_config" tf:"optional"` // List of Warehouse Types allowed in this workspace (limits allowed value // of the type field in CreateWarehouse and EditWarehouse). Note: Some types // cannot be disabled, they don't need to be specified in // SetWorkspaceWarehouseConfig. Note: Disabling a type may cause existing // warehouses to be converted to another type. Used by frontend to save // specific type availability in the warehouse create and edit form UI. - EnabledWarehouseTypes []WarehouseTypePair `tfsdk:"enabled_warehouse_types" tf:"optional"` + EnabledWarehouseTypes types.List `tfsdk:"enabled_warehouse_types" tf:"optional"` // Deprecated: Use sql_configuration_parameters - GlobalParam []RepeatedEndpointConfPairs `tfsdk:"global_param" tf:"optional,object"` + GlobalParam types.Object `tfsdk:"global_param" tf:"optional,object"` // GCP only: Google Service Account used to pass to cluster to access Google // Cloud Storage GoogleServiceAccount types.String `tfsdk:"google_service_account" tf:"optional"` @@ -1580,7 +1929,7 @@ type GetWorkspaceWarehouseConfigResponse struct { // Security policy for warehouses SecurityPolicy types.String `tfsdk:"security_policy" tf:"optional"` // SQL configuration parameters - SqlConfigurationParameters []RepeatedEndpointConfPairs `tfsdk:"sql_configuration_parameters" tf:"optional,object"` + SqlConfigurationParameters types.Object `tfsdk:"sql_configuration_parameters" tf:"optional,object"` } func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetWorkspaceWarehouseConfigResponse) { @@ -1589,6 +1938,17 @@ func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCr func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceWarehouseConfigResponse) { } +func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Channel": reflect.TypeOf(Channel{}), + "ConfigParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "DataAccessConfig": reflect.TypeOf(EndpointConfPair{}), + "EnabledWarehouseTypes": reflect.TypeOf(WarehouseTypePair{}), + "GlobalParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "SqlConfigurationParameters": reflect.TypeOf(RepeatedEndpointConfPairs{}), + } +} + type LegacyAlert struct { // Timestamp when the alert was created. CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -1599,11 +1959,11 @@ type LegacyAlert struct { // Name of the alert. Name types.String `tfsdk:"name" tf:"optional"` // Alert configuration options. - Options []AlertOptions `tfsdk:"options" tf:"optional,object"` + Options types.Object `tfsdk:"options" tf:"optional,object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` - Query []AlertQuery `tfsdk:"query" tf:"optional,object"` + Query types.Object `tfsdk:"query" tf:"optional,object"` // Number of seconds after being triggered before the alert rearms itself // and can be triggered again. If `null`, alert will never be triggered // again. @@ -1615,7 +1975,7 @@ type LegacyAlert struct { // Timestamp when the alert was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` - User []User `tfsdk:"user" tf:"optional,object"` + User types.Object `tfsdk:"user" tf:"optional,object"` } func (newState *LegacyAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan LegacyAlert) { @@ -1624,6 +1984,14 @@ func (newState *LegacyAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Legacy func (newState *LegacyAlert) SyncEffectiveFieldsDuringRead(existingState LegacyAlert) { } +func (a LegacyAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(AlertOptions{}), + "Query": reflect.TypeOf(AlertQuery{}), + "User": reflect.TypeOf(User{}), + } +} + type LegacyQuery struct { // Describes whether the authenticated user is allowed to edit the // definition of this query. @@ -1658,7 +2026,7 @@ type LegacyQuery struct { // type parameters are handled safely. IsSafe types.Bool `tfsdk:"is_safe" tf:"optional"` - LastModifiedBy []User `tfsdk:"last_modified_by" tf:"optional,object"` + LastModifiedBy types.Object `tfsdk:"last_modified_by" tf:"optional,object"` // The ID of the user who last saved changes to this query. LastModifiedById types.Int64 `tfsdk:"last_modified_by_id" tf:"optional"` // If there is a cached result for this query and user, this field includes @@ -1669,7 +2037,7 @@ type LegacyQuery struct { // on the query page. Name types.String `tfsdk:"name" tf:"optional"` - Options []QueryOptions `tfsdk:"options" tf:"optional,object"` + Options types.Object `tfsdk:"options" tf:"optional,object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // * `CAN_VIEW`: Can view the query * `CAN_RUN`: Can run the query * @@ -1684,15 +2052,15 @@ type LegacyQuery struct { // owner" behavior) RunAsRole types.String `tfsdk:"run_as_role" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // The timestamp at which this query was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` - User []User `tfsdk:"user" tf:"optional,object"` + User types.Object `tfsdk:"user" tf:"optional,object"` // The ID of the user who owns the query. UserId types.Int64 `tfsdk:"user_id" tf:"optional"` - Visualizations []LegacyVisualization `tfsdk:"visualizations" tf:"optional"` + Visualizations types.List `tfsdk:"visualizations" tf:"optional"` } func (newState *LegacyQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan LegacyQuery) { @@ -1701,6 +2069,16 @@ func (newState *LegacyQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan Legacy func (newState *LegacyQuery) SyncEffectiveFieldsDuringRead(existingState LegacyQuery) { } +func (a LegacyQuery) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "LastModifiedBy": reflect.TypeOf(User{}), + "Options": reflect.TypeOf(QueryOptions{}), + "Tags": reflect.TypeOf(""), + "User": reflect.TypeOf(User{}), + "Visualizations": reflect.TypeOf(LegacyVisualization{}), + } +} + // The visualization description API changes frequently and is unsupported. You // can duplicate a visualization by copying description objects received _from // the API_ and then using them to create a new one with a POST request to the @@ -1721,7 +2099,7 @@ type LegacyVisualization struct { // settings in JSON. Options any `tfsdk:"options" tf:"optional"` - Query []LegacyQuery `tfsdk:"query" tf:"optional,object"` + Query types.Object `tfsdk:"query" tf:"optional,object"` // The type of visualization: chart, table, pivot table, and so on. Type types.String `tfsdk:"type" tf:"optional"` @@ -1734,6 +2112,12 @@ func (newState *LegacyVisualization) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *LegacyVisualization) SyncEffectiveFieldsDuringRead(existingState LegacyVisualization) { } +func (a LegacyVisualization) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Query": reflect.TypeOf(LegacyQuery{}), + } +} + // List alerts type ListAlertsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1747,10 +2131,14 @@ func (newState *ListAlertsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListAlertsRequest) SyncEffectiveFieldsDuringRead(existingState ListAlertsRequest) { } +func (a ListAlertsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAlertsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Results []ListAlertsResponseAlert `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAlertsResponse) { @@ -1759,9 +2147,15 @@ func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringRead(existingState ListAlertsResponse) { } +func (a ListAlertsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(ListAlertsResponseAlert{}), + } +} + type ListAlertsResponseAlert struct { // Trigger conditions of the alert. - Condition []AlertCondition `tfsdk:"condition" tf:"optional,object"` + Condition types.Object `tfsdk:"condition" tf:"optional,object"` // The timestamp indicating when the alert was created. CreateTime types.String `tfsdk:"create_time" tf:"optional"` // Custom body of alert notification, if it exists. See [here] for custom @@ -1809,6 +2203,12 @@ func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringRead(existingState ListAlertsResponseAlert) { } +func (a ListAlertsResponseAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Condition": reflect.TypeOf(AlertCondition{}), + } +} + // Get dashboard objects type ListDashboardsRequest struct { // Name of dashboard attribute to order by. @@ -1827,6 +2227,10 @@ func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringRead(existingState ListDashboardsRequest) { } +func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a list of queries type ListQueriesLegacyRequest struct { // Name of query attribute to order by. Default sort order is ascending. @@ -1858,6 +2262,10 @@ func (newState *ListQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState ListQueriesLegacyRequest) { } +func (a ListQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List queries type ListQueriesRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1871,13 +2279,17 @@ func (newState *ListQueriesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQueriesRequest) SyncEffectiveFieldsDuringRead(existingState ListQueriesRequest) { } +func (a ListQueriesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListQueriesResponse struct { // Whether there is another page of results. HasNextPage types.Bool `tfsdk:"has_next_page" tf:"optional"` // A token that can be used to get the next page of results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Res []QueryInfo `tfsdk:"res" tf:"optional"` + Res types.List `tfsdk:"res" tf:"optional"` } func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListQueriesResponse) { @@ -1886,10 +2298,16 @@ func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringRead(existingState ListQueriesResponse) { } +func (a ListQueriesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Res": reflect.TypeOf(QueryInfo{}), + } +} + // List Queries type ListQueryHistoryRequest struct { // A filter to limit query history results. This field is optional. - FilterBy []QueryFilter `tfsdk:"-"` + FilterBy types.Object `tfsdk:"-"` // Whether to include the query metrics with each query. Only use this for a // small subset of queries (max_results). Defaults to false. IncludeMetrics types.Bool `tfsdk:"-"` @@ -1909,10 +2327,16 @@ func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringRead(existingState ListQueryHistoryRequest) { } +func (a ListQueryHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FilterBy": reflect.TypeOf(QueryFilter{}), + } +} + type ListQueryObjectsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Results []ListQueryObjectsResponseQuery `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListQueryObjectsResponse) { @@ -1921,6 +2345,12 @@ func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringRead(existingState ListQueryObjectsResponse) { } +func (a ListQueryObjectsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(ListQueryObjectsResponseQuery{}), + } +} + type ListQueryObjectsResponseQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -1943,7 +2373,7 @@ type ListQueryObjectsResponseQuery struct { // Username of the user that owns the query. OwnerUserName types.String `tfsdk:"owner_user_name" tf:"optional"` // List of query parameter definitions. - Parameters []QueryParameter `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // Text of the query to be run. QueryText types.String `tfsdk:"query_text" tf:"optional"` // Sets the "Run as" role for the object. @@ -1951,7 +2381,7 @@ type ListQueryObjectsResponseQuery struct { // Name of the schema where this query will be executed. Schema types.String `tfsdk:"schema" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // Timestamp when this query was last updated. UpdateTime types.String `tfsdk:"update_time" tf:"optional"` // ID of the SQL warehouse attached to the query. @@ -1964,6 +2394,13 @@ func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringCreateOr func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringRead(existingState ListQueryObjectsResponseQuery) { } +func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(QueryParameter{}), + "Tags": reflect.TypeOf(""), + } +} + type ListResponse struct { // The total number of dashboards. Count types.Int64 `tfsdk:"count" tf:"optional"` @@ -1972,7 +2409,7 @@ type ListResponse struct { // The number of dashboards per page. PageSize types.Int64 `tfsdk:"page_size" tf:"optional"` // List of dashboards returned. - Results []Dashboard `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListResponse) { @@ -1981,6 +2418,12 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListR func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListResponse) { } +func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(Dashboard{}), + } +} + // List visualizations on a query type ListVisualizationsForQueryRequest struct { Id types.String `tfsdk:"-"` @@ -1996,10 +2439,14 @@ func (newState *ListVisualizationsForQueryRequest) SyncEffectiveFieldsDuringCrea func (newState *ListVisualizationsForQueryRequest) SyncEffectiveFieldsDuringRead(existingState ListVisualizationsForQueryRequest) { } +func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListVisualizationsForQueryResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - Results []Visualization `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListVisualizationsForQueryResponse) { @@ -2008,6 +2455,12 @@ func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringCre func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringRead(existingState ListVisualizationsForQueryResponse) { } +func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(Visualization{}), + } +} + // List warehouses type ListWarehousesRequest struct { // Service Principal which will be used to fetch the list of warehouses. If @@ -2021,9 +2474,13 @@ func (newState *ListWarehousesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListWarehousesRequest) SyncEffectiveFieldsDuringRead(existingState ListWarehousesRequest) { } +func (a ListWarehousesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListWarehousesResponse struct { // A list of warehouses and their configurations. - Warehouses []EndpointInfo `tfsdk:"warehouses" tf:"optional"` + Warehouses types.List `tfsdk:"warehouses" tf:"optional"` } func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListWarehousesResponse) { @@ -2032,6 +2489,12 @@ func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringRead(existingState ListWarehousesResponse) { } +func (a ListWarehousesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Warehouses": reflect.TypeOf(EndpointInfo{}), + } +} + type MultiValuesOptions struct { // Character that prefixes each selected parameter value. Prefix types.String `tfsdk:"prefix" tf:"optional"` @@ -2048,6 +2511,10 @@ func (newState *MultiValuesOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MultiValuesOptions) SyncEffectiveFieldsDuringRead(existingState MultiValuesOptions) { } +func (a MultiValuesOptions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type NumericValue struct { Value types.Float64 `tfsdk:"value" tf:"optional"` } @@ -2058,6 +2525,10 @@ func (newState *NumericValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Numer func (newState *NumericValue) SyncEffectiveFieldsDuringRead(existingState NumericValue) { } +func (a NumericValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type OdbcParams struct { Hostname types.String `tfsdk:"hostname" tf:"optional"` @@ -2074,13 +2545,17 @@ func (newState *OdbcParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan OdbcPar func (newState *OdbcParams) SyncEffectiveFieldsDuringRead(existingState OdbcParams) { } +func (a OdbcParams) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Parameter struct { // List of valid parameter values, newline delimited. Only applies for // dropdown list parameters. EnumOptions types.String `tfsdk:"enumOptions" tf:"optional"` // If specified, allows multiple values to be selected for this parameter. // Only applies to dropdown list and query-based dropdown list parameters. - MultiValuesOptions []MultiValuesOptions `tfsdk:"multiValuesOptions" tf:"optional,object"` + MultiValuesOptions types.Object `tfsdk:"multiValuesOptions" tf:"optional,object"` // The literal parameter marker that appears between double curly braces in // the query text. Name types.String `tfsdk:"name" tf:"optional"` @@ -2101,6 +2576,12 @@ func (newState *Parameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Paramete func (newState *Parameter) SyncEffectiveFieldsDuringRead(existingState Parameter) { } +func (a Parameter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), + } +} + type Query struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -2123,7 +2604,7 @@ type Query struct { // Username of the user that owns the query. OwnerUserName types.String `tfsdk:"owner_user_name" tf:"optional"` // List of query parameter definitions. - Parameters []QueryParameter `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // Workspace path of the workspace folder containing the object. ParentPath types.String `tfsdk:"parent_path" tf:"optional"` // Text of the query to be run. @@ -2133,7 +2614,7 @@ type Query struct { // Name of the schema where this query will be executed. Schema types.String `tfsdk:"schema" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // Timestamp when this query was last updated. UpdateTime types.String `tfsdk:"update_time" tf:"optional"` // ID of the SQL warehouse attached to the query. @@ -2146,13 +2627,20 @@ func (newState *Query) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query) { func (newState *Query) SyncEffectiveFieldsDuringRead(existingState Query) { } +func (a Query) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(QueryParameter{}), + "Tags": reflect.TypeOf(""), + } +} + type QueryBackedValue struct { // If specified, allows multiple values to be selected for this parameter. - MultiValuesOptions []MultiValuesOptions `tfsdk:"multi_values_options" tf:"optional,object"` + MultiValuesOptions types.Object `tfsdk:"multi_values_options" tf:"optional,object"` // UUID of the query that provides the parameter values. QueryId types.String `tfsdk:"query_id" tf:"optional"` // List of selected query parameter values. - Values []types.String `tfsdk:"values" tf:"optional"` + Values types.List `tfsdk:"values" tf:"optional"` } func (newState *QueryBackedValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryBackedValue) { @@ -2161,6 +2649,13 @@ func (newState *QueryBackedValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryBackedValue) SyncEffectiveFieldsDuringRead(existingState QueryBackedValue) { } +func (a QueryBackedValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), + "Values": reflect.TypeOf(""), + } +} + type QueryEditContent struct { // Data source ID maps to the ID of the data source used by the resource and // is distinct from the warehouse ID. [Learn more] @@ -2186,7 +2681,7 @@ type QueryEditContent struct { // owner" behavior) RunAsRole types.String `tfsdk:"run_as_role" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *QueryEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryEditContent) { @@ -2195,18 +2690,24 @@ func (newState *QueryEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryEditContent) SyncEffectiveFieldsDuringRead(existingState QueryEditContent) { } +func (a QueryEditContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(""), + } +} + type QueryFilter struct { // A range filter for query submitted time. The time range must be <= 30 // days. - QueryStartTimeRange []TimeRange `tfsdk:"query_start_time_range" tf:"optional,object"` + QueryStartTimeRange types.Object `tfsdk:"query_start_time_range" tf:"optional,object"` // A list of statement IDs. - StatementIds []types.String `tfsdk:"statement_ids" tf:"optional"` + StatementIds types.List `tfsdk:"statement_ids" tf:"optional"` - Statuses []types.String `tfsdk:"statuses" tf:"optional"` + Statuses types.List `tfsdk:"statuses" tf:"optional"` // A list of user IDs who ran the queries. - UserIds []types.Int64 `tfsdk:"user_ids" tf:"optional"` + UserIds types.List `tfsdk:"user_ids" tf:"optional"` // A list of warehouse IDs. - WarehouseIds []types.String `tfsdk:"warehouse_ids" tf:"optional"` + WarehouseIds types.List `tfsdk:"warehouse_ids" tf:"optional"` } func (newState *QueryFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryFilter) { @@ -2215,9 +2716,19 @@ func (newState *QueryFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryF func (newState *QueryFilter) SyncEffectiveFieldsDuringRead(existingState QueryFilter) { } +func (a QueryFilter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "QueryStartTimeRange": reflect.TypeOf(TimeRange{}), + "StatementIds": reflect.TypeOf(""), + "Statuses": reflect.TypeOf(""), + "UserIds": reflect.TypeOf(0), + "WarehouseIds": reflect.TypeOf(""), + } +} + type QueryInfo struct { // SQL Warehouse channel information at the time of query execution - ChannelUsed []ChannelInfo `tfsdk:"channel_used" tf:"optional,object"` + ChannelUsed types.Object `tfsdk:"channel_used" tf:"optional,object"` // Total execution time of the statement ( excluding result fetch time ). Duration types.Int64 `tfsdk:"duration" tf:"optional"` // Alias for `warehouse_id`. @@ -2236,7 +2747,7 @@ type QueryInfo struct { // A key that can be used to look up query details. LookupKey types.String `tfsdk:"lookup_key" tf:"optional"` // Metrics about query execution. - Metrics []QueryMetrics `tfsdk:"metrics" tf:"optional,object"` + Metrics types.Object `tfsdk:"metrics" tf:"optional,object"` // Whether plans exist for the execution, or the reason why they are missing PlansState types.String `tfsdk:"plans_state" tf:"optional"` // The time the query ended. @@ -2273,6 +2784,13 @@ func (newState *QueryInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryInf func (newState *QueryInfo) SyncEffectiveFieldsDuringRead(existingState QueryInfo) { } +func (a QueryInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ChannelUsed": reflect.TypeOf(ChannelInfo{}), + "Metrics": reflect.TypeOf(QueryMetrics{}), + } +} + type QueryList struct { // The total number of queries. Count types.Int64 `tfsdk:"count" tf:"optional"` @@ -2281,7 +2799,7 @@ type QueryList struct { // The number of queries per page. PageSize types.Int64 `tfsdk:"page_size" tf:"optional"` // List of queries returned. - Results []LegacyQuery `tfsdk:"results" tf:"optional"` + Results types.List `tfsdk:"results" tf:"optional"` } func (newState *QueryList) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryList) { @@ -2290,6 +2808,12 @@ func (newState *QueryList) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryLis func (newState *QueryList) SyncEffectiveFieldsDuringRead(existingState QueryList) { } +func (a QueryList) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Results": reflect.TypeOf(LegacyQuery{}), + } +} + // A query metric that encapsulates a set of measurements for a single query. // Metrics come from the driver and are stored in the history service database. type QueryMetrics struct { @@ -2357,6 +2881,10 @@ func (newState *QueryMetrics) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query func (newState *QueryMetrics) SyncEffectiveFieldsDuringRead(existingState QueryMetrics) { } +func (a QueryMetrics) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type QueryOptions struct { // The name of the catalog to execute this query in. Catalog types.String `tfsdk:"catalog" tf:"optional"` @@ -2365,7 +2893,7 @@ type QueryOptions struct { // days. MovedToTrashAt types.String `tfsdk:"moved_to_trash_at" tf:"optional"` - Parameters []Parameter `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // The name of the schema to execute this query in. Schema types.String `tfsdk:"schema" tf:"optional"` } @@ -2376,24 +2904,30 @@ func (newState *QueryOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query func (newState *QueryOptions) SyncEffectiveFieldsDuringRead(existingState QueryOptions) { } +func (a QueryOptions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(Parameter{}), + } +} + type QueryParameter struct { // Date-range query parameter value. Can only specify one of // `dynamic_date_range_value` or `date_range_value`. - DateRangeValue []DateRangeValue `tfsdk:"date_range_value" tf:"optional,object"` + DateRangeValue types.Object `tfsdk:"date_range_value" tf:"optional,object"` // Date query parameter value. Can only specify one of `dynamic_date_value` // or `date_value`. - DateValue []DateValue `tfsdk:"date_value" tf:"optional,object"` + DateValue types.Object `tfsdk:"date_value" tf:"optional,object"` // Dropdown query parameter value. - EnumValue []EnumValue `tfsdk:"enum_value" tf:"optional,object"` + EnumValue types.Object `tfsdk:"enum_value" tf:"optional,object"` // Literal parameter marker that appears between double curly braces in the // query text. Name types.String `tfsdk:"name" tf:"optional"` // Numeric query parameter value. - NumericValue []NumericValue `tfsdk:"numeric_value" tf:"optional,object"` + NumericValue types.Object `tfsdk:"numeric_value" tf:"optional,object"` // Query-based dropdown query parameter value. - QueryBackedValue []QueryBackedValue `tfsdk:"query_backed_value" tf:"optional,object"` + QueryBackedValue types.Object `tfsdk:"query_backed_value" tf:"optional,object"` // Text query parameter value. - TextValue []TextValue `tfsdk:"text_value" tf:"optional,object"` + TextValue types.Object `tfsdk:"text_value" tf:"optional,object"` // Text displayed in the user-facing parameter widget in the UI. Title types.String `tfsdk:"title" tf:"optional"` } @@ -2404,6 +2938,17 @@ func (newState *QueryParameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Que func (newState *QueryParameter) SyncEffectiveFieldsDuringRead(existingState QueryParameter) { } +func (a QueryParameter) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DateRangeValue": reflect.TypeOf(DateRangeValue{}), + "DateValue": reflect.TypeOf(DateValue{}), + "EnumValue": reflect.TypeOf(EnumValue{}), + "NumericValue": reflect.TypeOf(NumericValue{}), + "QueryBackedValue": reflect.TypeOf(QueryBackedValue{}), + "TextValue": reflect.TypeOf(TextValue{}), + } +} + type QueryPostContent struct { // Data source ID maps to the ID of the data source used by the resource and // is distinct from the warehouse ID. [Learn more] @@ -2429,7 +2974,7 @@ type QueryPostContent struct { // owner" behavior) RunAsRole types.String `tfsdk:"run_as_role" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` } func (newState *QueryPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryPostContent) { @@ -2438,11 +2983,17 @@ func (newState *QueryPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryPostContent) SyncEffectiveFieldsDuringRead(existingState QueryPostContent) { } +func (a QueryPostContent) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Tags": reflect.TypeOf(""), + } +} + type RepeatedEndpointConfPairs struct { // Deprecated: Use configuration_pairs - ConfigPair []EndpointConfPair `tfsdk:"config_pair" tf:"optional"` + ConfigPair types.List `tfsdk:"config_pair" tf:"optional"` - ConfigurationPairs []EndpointConfPair `tfsdk:"configuration_pairs" tf:"optional"` + ConfigurationPairs types.List `tfsdk:"configuration_pairs" tf:"optional"` } func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepeatedEndpointConfPairs) { @@ -2451,6 +3002,13 @@ func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringRead(existingState RepeatedEndpointConfPairs) { } +func (a RepeatedEndpointConfPairs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ConfigPair": reflect.TypeOf(EndpointConfPair{}), + "ConfigurationPairs": reflect.TypeOf(EndpointConfPair{}), + } +} + // Restore a dashboard type RestoreDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -2462,6 +3020,10 @@ func (newState *RestoreDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *RestoreDashboardRequest) SyncEffectiveFieldsDuringRead(existingState RestoreDashboardRequest) { } +func (a RestoreDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Restore a query type RestoreQueriesLegacyRequest struct { QueryId types.String `tfsdk:"-"` @@ -2473,6 +3035,10 @@ func (newState *RestoreQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *RestoreQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState RestoreQueriesLegacyRequest) { } +func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RestoreResponse struct { } @@ -2482,6 +3048,10 @@ func (newState *RestoreResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RestoreResponse) SyncEffectiveFieldsDuringRead(existingState RestoreResponse) { } +func (a RestoreResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ResultData struct { // The number of bytes in the result chunk. This field is not available when // using `INLINE` disposition. @@ -2491,9 +3061,9 @@ type ResultData struct { // The `JSON_ARRAY` format is an array of arrays of values, where each // non-null value is formatted as a string. Null values are encoded as JSON // `null`. - DataArray [][]types.String `tfsdk:"data_array" tf:"optional"` + DataArray types.List `tfsdk:"data_array" tf:"optional"` - ExternalLinks []ExternalLink `tfsdk:"external_links" tf:"optional"` + ExternalLinks types.List `tfsdk:"external_links" tf:"optional"` // When fetching, provides the `chunk_index` for the _next_ chunk. If // absent, indicates there are no more chunks. The next chunk can be fetched // with a :method:statementexecution/getStatementResultChunkN request. @@ -2515,14 +3085,21 @@ func (newState *ResultData) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultD func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultData) { } +func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataArray": reflect.TypeOf(""), + "ExternalLinks": reflect.TypeOf(ExternalLink{}), + } +} + // The result manifest provides schema and metadata for the result set. type ResultManifest struct { // Array of result set chunk metadata. - Chunks []BaseChunkInfo `tfsdk:"chunks" tf:"optional"` + Chunks types.List `tfsdk:"chunks" tf:"optional"` Format types.String `tfsdk:"format" tf:"optional"` // The schema is an ordered list of column descriptions. - Schema []ResultSchema `tfsdk:"schema" tf:"optional,object"` + Schema types.Object `tfsdk:"schema" tf:"optional,object"` // The total number of bytes in the result set. This field is not available // when using `INLINE` disposition. TotalByteCount types.Int64 `tfsdk:"total_byte_count" tf:"optional"` @@ -2541,11 +3118,18 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState ResultManifest) { } +func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Chunks": reflect.TypeOf(BaseChunkInfo{}), + "Schema": reflect.TypeOf(ResultSchema{}), + } +} + // The schema is an ordered list of column descriptions. type ResultSchema struct { ColumnCount types.Int64 `tfsdk:"column_count" tf:"optional"` - Columns []ColumnInfo `tfsdk:"columns" tf:"optional"` + Columns types.List `tfsdk:"columns" tf:"optional"` } func (newState *ResultSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultSchema) { @@ -2554,6 +3138,12 @@ func (newState *ResultSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resul func (newState *ResultSchema) SyncEffectiveFieldsDuringRead(existingState ResultSchema) { } +func (a ResultSchema) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Columns": reflect.TypeOf(ColumnInfo{}), + } +} + type ServiceError struct { ErrorCode types.String `tfsdk:"error_code" tf:"optional"` // A brief summary of the error condition. @@ -2566,9 +3156,13 @@ func (newState *ServiceError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Servi func (newState *ServiceError) SyncEffectiveFieldsDuringRead(existingState ServiceError) { } +func (a ServiceError) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Set object ACL type SetRequest struct { - AccessControlList []AccessControl `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // Object ID. The ACL for the object with this UUID is overwritten by this // request's POST content. ObjectId types.String `tfsdk:"-"` @@ -2582,8 +3176,14 @@ func (newState *SetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetRequ func (newState *SetRequest) SyncEffectiveFieldsDuringRead(existingState SetRequest) { } +func (a SetRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AccessControl{}), + } +} + type SetResponse struct { - AccessControlList []AccessControl `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // An object's type and UUID, separated by a forward slash (/) character. ObjectId types.String `tfsdk:"object_id" tf:"optional"` // A singular noun object type. @@ -2596,23 +3196,29 @@ func (newState *SetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetRes func (newState *SetResponse) SyncEffectiveFieldsDuringRead(existingState SetResponse) { } +func (a SetResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(AccessControl{}), + } +} + type SetWorkspaceWarehouseConfigRequest struct { // Optional: Channel selection details - Channel []Channel `tfsdk:"channel" tf:"optional,object"` + Channel types.Object `tfsdk:"channel" tf:"optional,object"` // Deprecated: Use sql_configuration_parameters - ConfigParam []RepeatedEndpointConfPairs `tfsdk:"config_param" tf:"optional,object"` + ConfigParam types.Object `tfsdk:"config_param" tf:"optional,object"` // Spark confs for external hive metastore configuration JSON serialized // size must be less than <= 512K - DataAccessConfig []EndpointConfPair `tfsdk:"data_access_config" tf:"optional"` + DataAccessConfig types.List `tfsdk:"data_access_config" tf:"optional"` // List of Warehouse Types allowed in this workspace (limits allowed value // of the type field in CreateWarehouse and EditWarehouse). Note: Some types // cannot be disabled, they don't need to be specified in // SetWorkspaceWarehouseConfig. Note: Disabling a type may cause existing // warehouses to be converted to another type. Used by frontend to save // specific type availability in the warehouse create and edit form UI. - EnabledWarehouseTypes []WarehouseTypePair `tfsdk:"enabled_warehouse_types" tf:"optional"` + EnabledWarehouseTypes types.List `tfsdk:"enabled_warehouse_types" tf:"optional"` // Deprecated: Use sql_configuration_parameters - GlobalParam []RepeatedEndpointConfPairs `tfsdk:"global_param" tf:"optional,object"` + GlobalParam types.Object `tfsdk:"global_param" tf:"optional,object"` // GCP only: Google Service Account used to pass to cluster to access Google // Cloud Storage GoogleServiceAccount types.String `tfsdk:"google_service_account" tf:"optional"` @@ -2621,7 +3227,7 @@ type SetWorkspaceWarehouseConfigRequest struct { // Security policy for warehouses SecurityPolicy types.String `tfsdk:"security_policy" tf:"optional"` // SQL configuration parameters - SqlConfigurationParameters []RepeatedEndpointConfPairs `tfsdk:"sql_configuration_parameters" tf:"optional,object"` + SqlConfigurationParameters types.Object `tfsdk:"sql_configuration_parameters" tf:"optional,object"` } func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetWorkspaceWarehouseConfigRequest) { @@ -2630,6 +3236,17 @@ func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringCre func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringRead(existingState SetWorkspaceWarehouseConfigRequest) { } +func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Channel": reflect.TypeOf(Channel{}), + "ConfigParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "DataAccessConfig": reflect.TypeOf(EndpointConfPair{}), + "EnabledWarehouseTypes": reflect.TypeOf(WarehouseTypePair{}), + "GlobalParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "SqlConfigurationParameters": reflect.TypeOf(RepeatedEndpointConfPairs{}), + } +} + type SetWorkspaceWarehouseConfigResponse struct { } @@ -2639,6 +3256,10 @@ func (newState *SetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCr func (newState *SetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRead(existingState SetWorkspaceWarehouseConfigResponse) { } +func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Start a warehouse type StartRequest struct { // Required. Id of the SQL warehouse. @@ -2651,6 +3272,10 @@ func (newState *StartRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Start func (newState *StartRequest) SyncEffectiveFieldsDuringRead(existingState StartRequest) { } +func (a StartRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StartWarehouseResponse struct { } @@ -2660,6 +3285,10 @@ func (newState *StartWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *StartWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState StartWarehouseResponse) { } +func (a StartWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StatementParameterListItem struct { // The name of a parameter marker to be substituted in the statement. Name types.String `tfsdk:"name" tf:""` @@ -2682,17 +3311,21 @@ func (newState *StatementParameterListItem) SyncEffectiveFieldsDuringCreateOrUpd func (newState *StatementParameterListItem) SyncEffectiveFieldsDuringRead(existingState StatementParameterListItem) { } +func (a StatementParameterListItem) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StatementResponse struct { // The result manifest provides schema and metadata for the result set. - Manifest []ResultManifest `tfsdk:"manifest" tf:"optional,object"` + Manifest types.Object `tfsdk:"manifest" tf:"optional,object"` - Result []ResultData `tfsdk:"result" tf:"optional,object"` + Result types.Object `tfsdk:"result" tf:"optional,object"` // The statement ID is returned upon successfully submitting a SQL // statement, and is a required reference for all subsequent calls. StatementId types.String `tfsdk:"statement_id" tf:"optional"` // The status response includes execution state and if relevant, error // information. - Status []StatementStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` } func (newState *StatementResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan StatementResponse) { @@ -2701,10 +3334,18 @@ func (newState *StatementResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *StatementResponse) SyncEffectiveFieldsDuringRead(existingState StatementResponse) { } +func (a StatementResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Manifest": reflect.TypeOf(ResultManifest{}), + "Result": reflect.TypeOf(ResultData{}), + "Status": reflect.TypeOf(StatementStatus{}), + } +} + // The status response includes execution state and if relevant, error // information. type StatementStatus struct { - Error []ServiceError `tfsdk:"error" tf:"optional,object"` + Error types.Object `tfsdk:"error" tf:"optional,object"` // Statement execution state: - `PENDING`: waiting for warehouse - // `RUNNING`: running - `SUCCEEDED`: execution was successful, result data // available for fetch - `FAILED`: execution failed; reason for failure @@ -2721,6 +3362,12 @@ func (newState *StatementStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan St func (newState *StatementStatus) SyncEffectiveFieldsDuringRead(existingState StatementStatus) { } +func (a StatementStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Error": reflect.TypeOf(ServiceError{}), + } +} + // Stop a warehouse type StopRequest struct { // Required. Id of the SQL warehouse. @@ -2733,6 +3380,10 @@ func (newState *StopRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan StopRe func (newState *StopRequest) SyncEffectiveFieldsDuringRead(existingState StopRequest) { } +func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type StopWarehouseResponse struct { } @@ -2742,6 +3393,10 @@ func (newState *StopWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *StopWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState StopWarehouseResponse) { } +func (a StopWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Success struct { Message types.String `tfsdk:"message" tf:"optional"` } @@ -2752,12 +3407,16 @@ func (newState *Success) SyncEffectiveFieldsDuringCreateOrUpdate(plan Success) { func (newState *Success) SyncEffectiveFieldsDuringRead(existingState Success) { } +func (a Success) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TerminationReason struct { // status code indicating why the cluster was terminated Code types.String `tfsdk:"code" tf:"optional"` // list of parameters that provide additional information about why the // cluster was terminated - Parameters map[string]types.String `tfsdk:"parameters" tf:"optional"` + Parameters types.Map `tfsdk:"parameters" tf:"optional"` // type of the termination Type types.String `tfsdk:"type" tf:"optional"` } @@ -2768,6 +3427,12 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState TerminationReason) { } +func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(""), + } +} + type TextValue struct { Value types.String `tfsdk:"value" tf:"optional"` } @@ -2778,6 +3443,10 @@ func (newState *TextValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan TextValu func (newState *TextValue) SyncEffectiveFieldsDuringRead(existingState TextValue) { } +func (a TextValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TimeRange struct { // The end time in milliseconds. EndTimeMs types.Int64 `tfsdk:"end_time_ms" tf:"optional"` @@ -2791,6 +3460,10 @@ func (newState *TimeRange) SyncEffectiveFieldsDuringCreateOrUpdate(plan TimeRang func (newState *TimeRange) SyncEffectiveFieldsDuringRead(existingState TimeRange) { } +func (a TimeRange) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type TransferOwnershipObjectId struct { // Email address for the new owner, who must exist in the workspace. NewOwner types.String `tfsdk:"new_owner" tf:"optional"` @@ -2802,12 +3475,16 @@ func (newState *TransferOwnershipObjectId) SyncEffectiveFieldsDuringCreateOrUpda func (newState *TransferOwnershipObjectId) SyncEffectiveFieldsDuringRead(existingState TransferOwnershipObjectId) { } +func (a TransferOwnershipObjectId) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Transfer object ownership type TransferOwnershipRequest struct { // Email address for the new owner, who must exist in the workspace. NewOwner types.String `tfsdk:"new_owner" tf:"optional"` // The ID of the object on which to change ownership. - ObjectId []TransferOwnershipObjectId `tfsdk:"-"` + ObjectId types.Object `tfsdk:"-"` // The type of object on which to change ownership. ObjectType types.String `tfsdk:"-"` } @@ -2818,6 +3495,12 @@ func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringRead(existingState TransferOwnershipRequest) { } +func (a TransferOwnershipRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ObjectId": reflect.TypeOf(TransferOwnershipObjectId{}), + } +} + // Delete an alert type TrashAlertRequest struct { Id types.String `tfsdk:"-"` @@ -2829,6 +3512,10 @@ func (newState *TrashAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TrashAlertRequest) SyncEffectiveFieldsDuringRead(existingState TrashAlertRequest) { } +func (a TrashAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a query type TrashQueryRequest struct { Id types.String `tfsdk:"-"` @@ -2840,8 +3527,12 @@ func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringRead(existingState TrashQueryRequest) { } +func (a TrashQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateAlertRequest struct { - Alert []UpdateAlertRequestAlert `tfsdk:"alert" tf:"optional,object"` + Alert types.Object `tfsdk:"alert" tf:"optional,object"` Id types.String `tfsdk:"-"` // Field mask is required to be passed into the PATCH request. Field mask @@ -2857,9 +3548,15 @@ func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAlertRequest) { } +func (a UpdateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Alert": reflect.TypeOf(UpdateAlertRequestAlert{}), + } +} + type UpdateAlertRequestAlert struct { // Trigger conditions of the alert. - Condition []AlertCondition `tfsdk:"condition" tf:"optional,object"` + Condition types.Object `tfsdk:"condition" tf:"optional,object"` // Custom body of alert notification, if it exists. See [here] for custom // templating instructions. // @@ -2892,10 +3589,16 @@ func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingState UpdateAlertRequestAlert) { } +func (a UpdateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Condition": reflect.TypeOf(AlertCondition{}), + } +} + type UpdateQueryRequest struct { Id types.String `tfsdk:"-"` - Query []UpdateQueryRequestQuery `tfsdk:"query" tf:"optional,object"` + Query types.Object `tfsdk:"query" tf:"optional,object"` // Field mask is required to be passed into the PATCH request. Field mask // specifies which fields of the setting payload will be updated. The field // mask needs to be supplied as single string. To specify multiple fields in @@ -2909,6 +3612,12 @@ func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringRead(existingState UpdateQueryRequest) { } +func (a UpdateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Query": reflect.TypeOf(UpdateQueryRequestQuery{}), + } +} + type UpdateQueryRequestQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -2923,7 +3632,7 @@ type UpdateQueryRequestQuery struct { // Username of the user that owns the query. OwnerUserName types.String `tfsdk:"owner_user_name" tf:"optional"` // List of query parameter definitions. - Parameters []QueryParameter `tfsdk:"parameters" tf:"optional"` + Parameters types.List `tfsdk:"parameters" tf:"optional"` // Text of the query to be run. QueryText types.String `tfsdk:"query_text" tf:"optional"` // Sets the "Run as" role for the object. @@ -2931,7 +3640,7 @@ type UpdateQueryRequestQuery struct { // Name of the schema where this query will be executed. Schema types.String `tfsdk:"schema" tf:"optional"` - Tags []types.String `tfsdk:"tags" tf:"optional"` + Tags types.List `tfsdk:"tags" tf:"optional"` // ID of the SQL warehouse attached to the query. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` } @@ -2942,6 +3651,13 @@ func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingState UpdateQueryRequestQuery) { } +func (a UpdateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Parameters": reflect.TypeOf(QueryParameter{}), + "Tags": reflect.TypeOf(""), + } +} + type UpdateResponse struct { } @@ -2951,6 +3667,10 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateVisualizationRequest struct { Id types.String `tfsdk:"-"` // Field mask is required to be passed into the PATCH request. Field mask @@ -2959,7 +3679,7 @@ type UpdateVisualizationRequest struct { // the field mask, use comma as the separator (no space). UpdateMask types.String `tfsdk:"update_mask" tf:""` - Visualization []UpdateVisualizationRequestVisualization `tfsdk:"visualization" tf:"optional,object"` + Visualization types.Object `tfsdk:"visualization" tf:"optional,object"` } func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateVisualizationRequest) { @@ -2968,6 +3688,12 @@ func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateVisualizationRequest) { } +func (a UpdateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Visualization": reflect.TypeOf(UpdateVisualizationRequestVisualization{}), + } +} + type UpdateVisualizationRequestVisualization struct { // The display name of the visualization. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -2989,6 +3715,10 @@ func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuri func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuringRead(existingState UpdateVisualizationRequestVisualization) { } +func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type User struct { Email types.String `tfsdk:"email" tf:"optional"` @@ -3003,6 +3733,10 @@ func (newState *User) SyncEffectiveFieldsDuringCreateOrUpdate(plan User) { func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { } +func (a User) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Visualization struct { // The timestamp indicating when the visualization was created. CreateTime types.String `tfsdk:"create_time" tf:"optional"` @@ -3032,6 +3766,10 @@ func (newState *Visualization) SyncEffectiveFieldsDuringCreateOrUpdate(plan Visu func (newState *Visualization) SyncEffectiveFieldsDuringRead(existingState Visualization) { } +func (a Visualization) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WarehouseAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -3049,9 +3787,13 @@ func (newState *WarehouseAccessControlRequest) SyncEffectiveFieldsDuringCreateOr func (newState *WarehouseAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState WarehouseAccessControlRequest) { } +func (a WarehouseAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WarehouseAccessControlResponse struct { // All permissions. - AllPermissions []WarehousePermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -3068,10 +3810,16 @@ func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringCreateO func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState WarehouseAccessControlResponse) { } +func (a WarehouseAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(WarehousePermission{}), + } +} + type WarehousePermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -3082,8 +3830,14 @@ func (newState *WarehousePermission) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *WarehousePermission) SyncEffectiveFieldsDuringRead(existingState WarehousePermission) { } +func (a WarehousePermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type WarehousePermissions struct { - AccessControlList []WarehouseAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -3096,6 +3850,12 @@ func (newState *WarehousePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WarehousePermissions) SyncEffectiveFieldsDuringRead(existingState WarehousePermissions) { } +func (a WarehousePermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(WarehouseAccessControlResponse{}), + } +} + type WarehousePermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -3108,8 +3868,12 @@ func (newState *WarehousePermissionsDescription) SyncEffectiveFieldsDuringCreate func (newState *WarehousePermissionsDescription) SyncEffectiveFieldsDuringRead(existingState WarehousePermissionsDescription) { } +func (a WarehousePermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WarehousePermissionsRequest struct { - AccessControlList []WarehouseAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The SQL warehouse for which to get or manage permissions. WarehouseId types.String `tfsdk:"-"` } @@ -3120,6 +3884,12 @@ func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState WarehousePermissionsRequest) { } +func (a WarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(WarehouseAccessControlRequest{}), + } +} + type WarehouseTypePair struct { // If set to false the specific warehouse type will not be be allowed as a // value for warehouse_type in CreateWarehouse and EditWarehouse @@ -3134,17 +3904,21 @@ func (newState *WarehouseTypePair) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *WarehouseTypePair) SyncEffectiveFieldsDuringRead(existingState WarehouseTypePair) { } +func (a WarehouseTypePair) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Widget struct { // The unique ID for this widget. Id types.String `tfsdk:"id" tf:"optional"` - Options []WidgetOptions `tfsdk:"options" tf:"optional,object"` + Options types.Object `tfsdk:"options" tf:"optional,object"` // The visualization description API changes frequently and is unsupported. // You can duplicate a visualization by copying description objects received // _from the API_ and then using them to create a new one with a POST // request to the same endpoint. Databricks does not recommend constructing // ad-hoc visualizations entirely in JSON. - Visualization []LegacyVisualization `tfsdk:"visualization" tf:"optional,object"` + Visualization types.Object `tfsdk:"visualization" tf:"optional,object"` // Unused field. Width types.Int64 `tfsdk:"width" tf:"optional"` } @@ -3155,6 +3929,13 @@ func (newState *Widget) SyncEffectiveFieldsDuringCreateOrUpdate(plan Widget) { func (newState *Widget) SyncEffectiveFieldsDuringRead(existingState Widget) { } +func (a Widget) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Options": reflect.TypeOf(WidgetOptions{}), + "Visualization": reflect.TypeOf(LegacyVisualization{}), + } +} + type WidgetOptions struct { // Timestamp when this object was created CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -3168,7 +3949,7 @@ type WidgetOptions struct { ParameterMappings any `tfsdk:"parameterMappings" tf:"optional"` // Coordinates of this widget on a dashboard. This portion of the API // changes frequently and is unsupported. - Position []WidgetPosition `tfsdk:"position" tf:"optional,object"` + Position types.Object `tfsdk:"position" tf:"optional,object"` // Custom title of the widget Title types.String `tfsdk:"title" tf:"optional"` // Timestamp of the last time this object was updated. @@ -3181,6 +3962,12 @@ func (newState *WidgetOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Widg func (newState *WidgetOptions) SyncEffectiveFieldsDuringRead(existingState WidgetOptions) { } +func (a WidgetOptions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Position": reflect.TypeOf(WidgetPosition{}), + } +} + // Coordinates of this widget on a dashboard. This portion of the API changes // frequently and is unsupported. type WidgetPosition struct { @@ -3201,3 +3988,7 @@ func (newState *WidgetPosition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Wid func (newState *WidgetPosition) SyncEffectiveFieldsDuringRead(existingState WidgetPosition) { } + +func (a WidgetPosition) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 4c35584942..0366fb3743 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package vectorsearch_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -25,6 +27,10 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } +func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateEndpoint struct { // Type of endpoint. EndpointType types.String `tfsdk:"endpoint_type" tf:""` @@ -38,13 +44,17 @@ func (newState *CreateEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateEndpoint) SyncEffectiveFieldsDuringRead(existingState CreateEndpoint) { } +func (a CreateEndpoint) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateVectorIndexRequest struct { // Specification for Delta Sync Index. Required if `index_type` is // `DELTA_SYNC`. - DeltaSyncIndexSpec []DeltaSyncVectorIndexSpecRequest `tfsdk:"delta_sync_index_spec" tf:"optional,object"` + DeltaSyncIndexSpec types.Object `tfsdk:"delta_sync_index_spec" tf:"optional,object"` // Specification for Direct Vector Access Index. Required if `index_type` is // `DIRECT_ACCESS`. - DirectAccessIndexSpec []DirectAccessVectorIndexSpec `tfsdk:"direct_access_index_spec" tf:"optional,object"` + DirectAccessIndexSpec types.Object `tfsdk:"direct_access_index_spec" tf:"optional,object"` // Name of the endpoint to be used for serving the index EndpointName types.String `tfsdk:"endpoint_name" tf:""` // There are 2 types of Vector Search indexes: @@ -67,8 +77,15 @@ func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState CreateVectorIndexRequest) { } +func (a CreateVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DeltaSyncIndexSpec": reflect.TypeOf(DeltaSyncVectorIndexSpecRequest{}), + "DirectAccessIndexSpec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), + } +} + type CreateVectorIndexResponse struct { - VectorIndex []VectorIndex `tfsdk:"vector_index" tf:"optional,object"` + VectorIndex types.Object `tfsdk:"vector_index" tf:"optional,object"` } func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateVectorIndexResponse) { @@ -77,10 +94,16 @@ func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState CreateVectorIndexResponse) { } +func (a CreateVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "VectorIndex": reflect.TypeOf(VectorIndex{}), + } +} + // Result of the upsert or delete operation. type DeleteDataResult struct { // List of primary keys for rows that failed to process. - FailedPrimaryKeys []types.String `tfsdk:"failed_primary_keys" tf:"optional"` + FailedPrimaryKeys types.List `tfsdk:"failed_primary_keys" tf:"optional"` // Count of successfully processed rows. SuccessRowCount types.Int64 `tfsdk:"success_row_count" tf:"optional"` } @@ -91,13 +114,19 @@ func (newState *DeleteDataResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteDataResult) SyncEffectiveFieldsDuringRead(existingState DeleteDataResult) { } +func (a DeleteDataResult) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FailedPrimaryKeys": reflect.TypeOf(""), + } +} + // Request payload for deleting data from a vector index. type DeleteDataVectorIndexRequest struct { // Name of the vector index where data is to be deleted. Must be a Direct // Vector Access Index. IndexName types.String `tfsdk:"-"` // List of primary keys for the data to be deleted. - PrimaryKeys []types.String `tfsdk:"primary_keys" tf:""` + PrimaryKeys types.List `tfsdk:"primary_keys" tf:""` } func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteDataVectorIndexRequest) { @@ -106,10 +135,16 @@ func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDataVectorIndexRequest) { } +func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PrimaryKeys": reflect.TypeOf(""), + } +} + // Response to a delete data vector index request. type DeleteDataVectorIndexResponse struct { // Result of the upsert or delete operation. - Result []DeleteDataResult `tfsdk:"result" tf:"optional,object"` + Result types.Object `tfsdk:"result" tf:"optional,object"` // Status of the delete operation. Status types.String `tfsdk:"status" tf:"optional"` } @@ -120,6 +155,12 @@ func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDataVectorIndexResponse) { } +func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Result": reflect.TypeOf(DeleteDataResult{}), + } +} + // Delete an endpoint type DeleteEndpointRequest struct { // Name of the endpoint @@ -132,6 +173,10 @@ func (newState *DeleteEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteEndpointRequest) { } +func (a DeleteEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteEndpointResponse struct { } @@ -141,6 +186,10 @@ func (newState *DeleteEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteEndpointResponse) SyncEffectiveFieldsDuringRead(existingState DeleteEndpointResponse) { } +func (a DeleteEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete an index type DeleteIndexRequest struct { // Name of the index @@ -153,6 +202,10 @@ func (newState *DeleteIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteIndexRequest) SyncEffectiveFieldsDuringRead(existingState DeleteIndexRequest) { } +func (a DeleteIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteIndexResponse struct { } @@ -162,17 +215,21 @@ func (newState *DeleteIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteIndexResponse) SyncEffectiveFieldsDuringRead(existingState DeleteIndexResponse) { } +func (a DeleteIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeltaSyncVectorIndexSpecRequest struct { // [Optional] Select the columns to sync with the vector index. If you leave // this field blank, all columns from the source table are synced with the // index. The primary key column and embedding source column or embedding // vector column are always synced. - ColumnsToSync []types.String `tfsdk:"columns_to_sync" tf:"optional"` + ColumnsToSync types.List `tfsdk:"columns_to_sync" tf:"optional"` // The columns that contain the embedding source. - EmbeddingSourceColumns []EmbeddingSourceColumn `tfsdk:"embedding_source_columns" tf:"optional"` + EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` // The columns that contain the embedding vectors. The format should be // array[double]. - EmbeddingVectorColumns []EmbeddingVectorColumn `tfsdk:"embedding_vector_columns" tf:"optional"` + EmbeddingVectorColumns types.List `tfsdk:"embedding_vector_columns" tf:"optional"` // [Optional] Automatically sync the vector index contents and computed // embeddings to the specified Delta table. The only supported table name is // the index name with the suffix `_writeback_table`. @@ -196,11 +253,19 @@ func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringCreate func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringRead(existingState DeltaSyncVectorIndexSpecRequest) { } +func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ColumnsToSync": reflect.TypeOf(""), + "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), + "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), + } +} + type DeltaSyncVectorIndexSpecResponse struct { // The columns that contain the embedding source. - EmbeddingSourceColumns []EmbeddingSourceColumn `tfsdk:"embedding_source_columns" tf:"optional"` + EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` // The columns that contain the embedding vectors. - EmbeddingVectorColumns []EmbeddingVectorColumn `tfsdk:"embedding_vector_columns" tf:"optional"` + EmbeddingVectorColumns types.List `tfsdk:"embedding_vector_columns" tf:"optional"` // [Optional] Name of the Delta table to sync the vector index contents and // computed embeddings to. EmbeddingWritebackTable types.String `tfsdk:"embedding_writeback_table" tf:"optional"` @@ -225,11 +290,18 @@ func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringCreat func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringRead(existingState DeltaSyncVectorIndexSpecResponse) { } +func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), + "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), + } +} + type DirectAccessVectorIndexSpec struct { // Contains the optional model endpoint to use during query time. - EmbeddingSourceColumns []EmbeddingSourceColumn `tfsdk:"embedding_source_columns" tf:"optional"` + EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` - EmbeddingVectorColumns []EmbeddingVectorColumn `tfsdk:"embedding_vector_columns" tf:"optional"` + EmbeddingVectorColumns types.List `tfsdk:"embedding_vector_columns" tf:"optional"` // The schema of the index in JSON format. // // Supported types are `integer`, `long`, `float`, `double`, `boolean`, @@ -245,6 +317,13 @@ func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringCreateOrUp func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringRead(existingState DirectAccessVectorIndexSpec) { } +func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), + "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), + } +} + type EmbeddingSourceColumn struct { // Name of the embedding model endpoint EmbeddingModelEndpointName types.String `tfsdk:"embedding_model_endpoint_name" tf:"optional"` @@ -258,6 +337,10 @@ func (newState *EmbeddingSourceColumn) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EmbeddingSourceColumn) SyncEffectiveFieldsDuringRead(existingState EmbeddingSourceColumn) { } +func (a EmbeddingSourceColumn) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EmbeddingVectorColumn struct { // Dimension of the embedding vector EmbeddingDimension types.Int64 `tfsdk:"embedding_dimension" tf:"optional"` @@ -271,13 +354,17 @@ func (newState *EmbeddingVectorColumn) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EmbeddingVectorColumn) SyncEffectiveFieldsDuringRead(existingState EmbeddingVectorColumn) { } +func (a EmbeddingVectorColumn) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type EndpointInfo struct { // Timestamp of endpoint creation CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` // Creator of the endpoint Creator types.String `tfsdk:"creator" tf:"optional"` // Current status of the endpoint - EndpointStatus []EndpointStatus `tfsdk:"endpoint_status" tf:"optional,object"` + EndpointStatus types.Object `tfsdk:"endpoint_status" tf:"optional,object"` // Type of endpoint. EndpointType types.String `tfsdk:"endpoint_type" tf:"optional"` // Unique identifier of the endpoint @@ -298,6 +385,12 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState EndpointInfo) { } +func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "EndpointStatus": reflect.TypeOf(EndpointStatus{}), + } +} + // Status information of an endpoint type EndpointStatus struct { // Additional status message @@ -312,6 +405,10 @@ func (newState *EndpointStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan End func (newState *EndpointStatus) SyncEffectiveFieldsDuringRead(existingState EndpointStatus) { } +func (a EndpointStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an endpoint type GetEndpointRequest struct { // Name of the endpoint @@ -324,6 +421,10 @@ func (newState *GetEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetEndpointRequest) { } +func (a GetEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get an index type GetIndexRequest struct { // Name of the index @@ -336,9 +437,13 @@ func (newState *GetIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetIndexRequest) SyncEffectiveFieldsDuringRead(existingState GetIndexRequest) { } +func (a GetIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListEndpointResponse struct { // An array of Endpoint objects - Endpoints []EndpointInfo `tfsdk:"endpoints" tf:"optional"` + Endpoints types.List `tfsdk:"endpoints" tf:"optional"` // A token that can be used to get the next page of results. If not present, // there are no more results to show. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -350,6 +455,12 @@ func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringRead(existingState ListEndpointResponse) { } +func (a ListEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Endpoints": reflect.TypeOf(EndpointInfo{}), + } +} + // List all endpoints type ListEndpointsRequest struct { // Token for pagination @@ -362,6 +473,10 @@ func (newState *ListEndpointsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListEndpointsRequest) SyncEffectiveFieldsDuringRead(existingState ListEndpointsRequest) { } +func (a ListEndpointsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // List indexes type ListIndexesRequest struct { // Name of the endpoint @@ -376,8 +491,12 @@ func (newState *ListIndexesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListIndexesRequest) SyncEffectiveFieldsDuringRead(existingState ListIndexesRequest) { } +func (a ListIndexesRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListValue struct { - Values []Value `tfsdk:"values" tf:"optional"` + Values types.List `tfsdk:"values" tf:"optional"` } func (newState *ListValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListValue) { @@ -386,12 +505,18 @@ func (newState *ListValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListValu func (newState *ListValue) SyncEffectiveFieldsDuringRead(existingState ListValue) { } +func (a ListValue) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Values": reflect.TypeOf(Value{}), + } +} + type ListVectorIndexesResponse struct { // A token that can be used to get the next page of results. If not present, // there are no more results to show. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` - VectorIndexes []MiniVectorIndex `tfsdk:"vector_indexes" tf:"optional"` + VectorIndexes types.List `tfsdk:"vector_indexes" tf:"optional"` } func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListVectorIndexesResponse) { @@ -400,12 +525,18 @@ func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringRead(existingState ListVectorIndexesResponse) { } +func (a ListVectorIndexesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "VectorIndexes": reflect.TypeOf(MiniVectorIndex{}), + } +} + // Key-value pair. type MapStringValueEntry struct { // Column name. Key types.String `tfsdk:"key" tf:"optional"` // Column value, nullable. - Value []Value `tfsdk:"value" tf:"optional,object"` + Value types.Object `tfsdk:"value" tf:"optional,object"` } func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringCreateOrUpdate(plan MapStringValueEntry) { @@ -414,6 +545,12 @@ func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringRead(existingState MapStringValueEntry) { } +func (a MapStringValueEntry) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Value": reflect.TypeOf(Value{}), + } +} + type MiniVectorIndex struct { // The user who created the index. Creator types.String `tfsdk:"creator" tf:"optional"` @@ -439,6 +576,10 @@ func (newState *MiniVectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mi func (newState *MiniVectorIndex) SyncEffectiveFieldsDuringRead(existingState MiniVectorIndex) { } +func (a MiniVectorIndex) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Request payload for getting next page of results. type QueryVectorIndexNextPageRequest struct { // Name of the endpoint. @@ -456,9 +597,13 @@ func (newState *QueryVectorIndexNextPageRequest) SyncEffectiveFieldsDuringCreate func (newState *QueryVectorIndexNextPageRequest) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexNextPageRequest) { } +func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type QueryVectorIndexRequest struct { // List of column names to include in the response. - Columns []types.String `tfsdk:"columns" tf:""` + Columns types.List `tfsdk:"columns" tf:""` // JSON string representing query filters. // // Example filters: - `{"id <": 5}`: Filter for id less than 5. - `{"id >": @@ -476,7 +621,7 @@ type QueryVectorIndexRequest struct { QueryType types.String `tfsdk:"query_type" tf:"optional"` // Query vector. Required for Direct Vector Access Index and Delta Sync // Index using self-managed vectors. - QueryVector []types.Float64 `tfsdk:"query_vector" tf:"optional"` + QueryVector types.List `tfsdk:"query_vector" tf:"optional"` // Threshold for the approximate nearest neighbor search. Defaults to 0.0. ScoreThreshold types.Float64 `tfsdk:"score_threshold" tf:"optional"` } @@ -487,15 +632,22 @@ func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexRequest) { } +func (a QueryVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Columns": reflect.TypeOf(""), + "QueryVector": reflect.TypeOf(0.0), + } +} + type QueryVectorIndexResponse struct { // Metadata about the result set. - Manifest []ResultManifest `tfsdk:"manifest" tf:"optional,object"` + Manifest types.Object `tfsdk:"manifest" tf:"optional,object"` // [Optional] Token that can be used in `QueryVectorIndexNextPage` API to // get next page of results. If more than 1000 results satisfy the query, // they are returned in groups of 1000. Empty value means no more results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // Data returned in the query result. - Result []ResultData `tfsdk:"result" tf:"optional,object"` + Result types.Object `tfsdk:"result" tf:"optional,object"` } func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryVectorIndexResponse) { @@ -504,10 +656,17 @@ func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexResponse) { } +func (a QueryVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Manifest": reflect.TypeOf(ResultManifest{}), + "Result": reflect.TypeOf(ResultData{}), + } +} + // Data returned in the query result. type ResultData struct { // Data rows returned in the query. - DataArray [][]types.String `tfsdk:"data_array" tf:"optional"` + DataArray types.List `tfsdk:"data_array" tf:"optional"` // Number of rows in the result set. RowCount types.Int64 `tfsdk:"row_count" tf:"optional"` } @@ -518,12 +677,18 @@ func (newState *ResultData) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultD func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultData) { } +func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DataArray": reflect.TypeOf(""), + } +} + // Metadata about the result set. type ResultManifest struct { // Number of columns in the result set. ColumnCount types.Int64 `tfsdk:"column_count" tf:"optional"` // Information about each column in the result set. - Columns []ColumnInfo `tfsdk:"columns" tf:"optional"` + Columns types.List `tfsdk:"columns" tf:"optional"` } func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultManifest) { @@ -532,6 +697,12 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState ResultManifest) { } +func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Columns": reflect.TypeOf(ColumnInfo{}), + } +} + // Request payload for scanning data from a vector index. type ScanVectorIndexRequest struct { // Name of the vector index to scan. @@ -548,10 +719,14 @@ func (newState *ScanVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ScanVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState ScanVectorIndexRequest) { } +func (a ScanVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Response to a scan vector index request. type ScanVectorIndexResponse struct { // List of data entries - Data []Struct `tfsdk:"data" tf:"optional"` + Data types.List `tfsdk:"data" tf:"optional"` // Primary key of the last entry. LastPrimaryKey types.String `tfsdk:"last_primary_key" tf:"optional"` } @@ -562,9 +737,15 @@ func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState ScanVectorIndexResponse) { } +func (a ScanVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Data": reflect.TypeOf(Struct{}), + } +} + type Struct struct { // Data entry, corresponding to a row in a vector index. - Fields []MapStringValueEntry `tfsdk:"fields" tf:"optional"` + Fields types.List `tfsdk:"fields" tf:"optional"` } func (newState *Struct) SyncEffectiveFieldsDuringCreateOrUpdate(plan Struct) { @@ -573,6 +754,12 @@ func (newState *Struct) SyncEffectiveFieldsDuringCreateOrUpdate(plan Struct) { func (newState *Struct) SyncEffectiveFieldsDuringRead(existingState Struct) { } +func (a Struct) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Fields": reflect.TypeOf(MapStringValueEntry{}), + } +} + // Synchronize an index type SyncIndexRequest struct { // Name of the vector index to synchronize. Must be a Delta Sync Index. @@ -585,6 +772,10 @@ func (newState *SyncIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SyncIndexRequest) SyncEffectiveFieldsDuringRead(existingState SyncIndexRequest) { } +func (a SyncIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SyncIndexResponse struct { } @@ -594,10 +785,14 @@ func (newState *SyncIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SyncIndexResponse) SyncEffectiveFieldsDuringRead(existingState SyncIndexResponse) { } +func (a SyncIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Result of the upsert or delete operation. type UpsertDataResult struct { // List of primary keys for rows that failed to process. - FailedPrimaryKeys []types.String `tfsdk:"failed_primary_keys" tf:"optional"` + FailedPrimaryKeys types.List `tfsdk:"failed_primary_keys" tf:"optional"` // Count of successfully processed rows. SuccessRowCount types.Int64 `tfsdk:"success_row_count" tf:"optional"` } @@ -608,6 +803,12 @@ func (newState *UpsertDataResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpsertDataResult) SyncEffectiveFieldsDuringRead(existingState UpsertDataResult) { } +func (a UpsertDataResult) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "FailedPrimaryKeys": reflect.TypeOf(""), + } +} + // Request payload for upserting data into a vector index. type UpsertDataVectorIndexRequest struct { // Name of the vector index where data is to be upserted. Must be a Direct @@ -623,10 +824,14 @@ func (newState *UpsertDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *UpsertDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState UpsertDataVectorIndexRequest) { } +func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Response to an upsert data vector index request. type UpsertDataVectorIndexResponse struct { // Result of the upsert or delete operation. - Result []UpsertDataResult `tfsdk:"result" tf:"optional,object"` + Result types.Object `tfsdk:"result" tf:"optional,object"` // Status of the upsert operation. Status types.String `tfsdk:"status" tf:"optional"` } @@ -637,10 +842,16 @@ func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringCreateOr func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState UpsertDataVectorIndexResponse) { } +func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Result": reflect.TypeOf(UpsertDataResult{}), + } +} + type Value struct { BoolValue types.Bool `tfsdk:"bool_value" tf:"optional"` - ListValue []ListValue `tfsdk:"list_value" tf:"optional,object"` + ListValue types.Object `tfsdk:"list_value" tf:"optional,object"` NullValue types.String `tfsdk:"null_value" tf:"optional"` @@ -648,7 +859,7 @@ type Value struct { StringValue types.String `tfsdk:"string_value" tf:"optional"` - StructValue []Struct `tfsdk:"struct_value" tf:"optional,object"` + StructValue types.Object `tfsdk:"struct_value" tf:"optional,object"` } func (newState *Value) SyncEffectiveFieldsDuringCreateOrUpdate(plan Value) { @@ -657,13 +868,20 @@ func (newState *Value) SyncEffectiveFieldsDuringCreateOrUpdate(plan Value) { func (newState *Value) SyncEffectiveFieldsDuringRead(existingState Value) { } +func (a Value) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "ListValue": reflect.TypeOf(ListValue{}), + "StructValue": reflect.TypeOf(Struct{}), + } +} + type VectorIndex struct { // The user who created the index. Creator types.String `tfsdk:"creator" tf:"optional"` - DeltaSyncIndexSpec []DeltaSyncVectorIndexSpecResponse `tfsdk:"delta_sync_index_spec" tf:"optional,object"` + DeltaSyncIndexSpec types.Object `tfsdk:"delta_sync_index_spec" tf:"optional,object"` - DirectAccessIndexSpec []DirectAccessVectorIndexSpec `tfsdk:"direct_access_index_spec" tf:"optional,object"` + DirectAccessIndexSpec types.Object `tfsdk:"direct_access_index_spec" tf:"optional,object"` // Name of the endpoint associated with the index EndpointName types.String `tfsdk:"endpoint_name" tf:"optional"` // There are 2 types of Vector Search indexes: @@ -679,7 +897,7 @@ type VectorIndex struct { // Primary key of the index PrimaryKey types.String `tfsdk:"primary_key" tf:"optional"` - Status []VectorIndexStatus `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` } func (newState *VectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan VectorIndex) { @@ -688,6 +906,14 @@ func (newState *VectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan Vector func (newState *VectorIndex) SyncEffectiveFieldsDuringRead(existingState VectorIndex) { } +func (a VectorIndex) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "DeltaSyncIndexSpec": reflect.TypeOf(DeltaSyncVectorIndexSpecResponse{}), + "DirectAccessIndexSpec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), + "Status": reflect.TypeOf(VectorIndexStatus{}), + } +} + type VectorIndexStatus struct { // Index API Url to be used to perform operations on the index IndexUrl types.String `tfsdk:"index_url" tf:"optional"` @@ -704,3 +930,7 @@ func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringRead(existingState VectorIndexStatus) { } + +func (a VectorIndexStatus) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 508e90337d..9ec8a281ac 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -11,6 +11,8 @@ We use go-native types for lists and maps intentionally for the ease for convert package workspace_tf import ( + "reflect" + "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -27,6 +29,10 @@ func (newState *AclItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan AclItem) { func (newState *AclItem) SyncEffectiveFieldsDuringRead(existingState AclItem) { } +func (a AclItem) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type AzureKeyVaultSecretScopeMetadata struct { // The DNS of the KeyVault DnsName types.String `tfsdk:"dns_name" tf:""` @@ -41,6 +47,10 @@ func (newState *AzureKeyVaultSecretScopeMetadata) SyncEffectiveFieldsDuringCreat func (newState *AzureKeyVaultSecretScopeMetadata) SyncEffectiveFieldsDuringRead(existingState AzureKeyVaultSecretScopeMetadata) { } +func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateCredentialsRequest struct { // Git provider. This field is case-insensitive. The available Git providers // are `gitHub`, `bitbucketCloud`, `gitLab`, `azureDevOpsServices`, @@ -69,6 +79,10 @@ func (newState *CreateCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialsRequest) { } +func (a CreateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateCredentialsResponse struct { // ID of the credential object in the workspace. CredentialId types.Int64 `tfsdk:"credential_id" tf:""` @@ -85,6 +99,10 @@ func (newState *CreateCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState CreateCredentialsResponse) { } +func (a CreateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CreateRepoRequest struct { // Desired path for the repo in the workspace. Almost any path in the // workspace can be chosen. If repo is created in `/Repos`, path must be in @@ -97,7 +115,7 @@ type CreateRepoRequest struct { Provider types.String `tfsdk:"provider" tf:""` // If specified, the repo will be created with sparse checkout enabled. You // cannot enable/disable sparse checkout after the repo is created. - SparseCheckout []SparseCheckout `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the Git repository to be linked. Url types.String `tfsdk:"url" tf:""` } @@ -108,6 +126,12 @@ func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringRead(existingState CreateRepoRequest) { } +func (a CreateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + } +} + type CreateRepoResponse struct { // Branch that the Git folder (repo) is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -121,7 +145,7 @@ type CreateRepoResponse struct { // Git provider of the linked Git repository. Provider types.String `tfsdk:"provider" tf:"optional"` // Sparse checkout settings for the Git folder (repo). - SparseCheckout []SparseCheckout `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the linked Git repository. Url types.String `tfsdk:"url" tf:"optional"` } @@ -132,9 +156,15 @@ func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringRead(existingState CreateRepoResponse) { } +func (a CreateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + } +} + type CreateScope struct { // The metadata for the secret scope if the type is `AZURE_KEYVAULT` - BackendAzureKeyvault []AzureKeyVaultSecretScopeMetadata `tfsdk:"backend_azure_keyvault" tf:"optional,object"` + BackendAzureKeyvault types.Object `tfsdk:"backend_azure_keyvault" tf:"optional,object"` // The principal that is initially granted `MANAGE` permission to the // created scope. InitialManagePrincipal types.String `tfsdk:"initial_manage_principal" tf:"optional"` @@ -151,6 +181,12 @@ func (newState *CreateScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateScope) SyncEffectiveFieldsDuringRead(existingState CreateScope) { } +func (a CreateScope) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "BackendAzureKeyvault": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), + } +} + type CreateScopeResponse struct { } @@ -160,6 +196,10 @@ func (newState *CreateScopeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateScopeResponse) SyncEffectiveFieldsDuringRead(existingState CreateScopeResponse) { } +func (a CreateScopeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type CredentialInfo struct { // ID of the credential object in the workspace. CredentialId types.Int64 `tfsdk:"credential_id" tf:""` @@ -176,6 +216,10 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState CredentialInfo) { } +func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Delete struct { // The absolute path of the notebook or directory. Path types.String `tfsdk:"path" tf:""` @@ -192,6 +236,10 @@ func (newState *Delete) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete) { func (newState *Delete) SyncEffectiveFieldsDuringRead(existingState Delete) { } +func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteAcl struct { // The principal to remove an existing ACL from. Principal types.String `tfsdk:"principal" tf:""` @@ -205,6 +253,10 @@ func (newState *DeleteAcl) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteAc func (newState *DeleteAcl) SyncEffectiveFieldsDuringRead(existingState DeleteAcl) { } +func (a DeleteAcl) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteAclResponse struct { } @@ -214,6 +266,10 @@ func (newState *DeleteAclResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteAclResponse) SyncEffectiveFieldsDuringRead(existingState DeleteAclResponse) { } +func (a DeleteAclResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a credential type DeleteCredentialsRequest struct { // The ID for the corresponding credential to access. @@ -226,6 +282,10 @@ func (newState *DeleteCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialsRequest) { } +func (a DeleteCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteCredentialsResponse struct { } @@ -235,6 +295,10 @@ func (newState *DeleteCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialsResponse) { } +func (a DeleteCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Delete a repo type DeleteRepoRequest struct { // The ID for the corresponding repo to delete. @@ -247,6 +311,10 @@ func (newState *DeleteRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRepoRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRepoRequest) { } +func (a DeleteRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteRepoResponse struct { } @@ -256,6 +324,10 @@ func (newState *DeleteRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRepoResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRepoResponse) { } +func (a DeleteRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteResponse struct { } @@ -265,6 +337,10 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteScope struct { // Name of the scope to delete. Scope types.String `tfsdk:"scope" tf:""` @@ -276,6 +352,10 @@ func (newState *DeleteScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete func (newState *DeleteScope) SyncEffectiveFieldsDuringRead(existingState DeleteScope) { } +func (a DeleteScope) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteScopeResponse struct { } @@ -285,6 +365,10 @@ func (newState *DeleteScopeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteScopeResponse) SyncEffectiveFieldsDuringRead(existingState DeleteScopeResponse) { } +func (a DeleteScopeResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteSecret struct { // Name of the secret to delete. Key types.String `tfsdk:"key" tf:""` @@ -298,6 +382,10 @@ func (newState *DeleteSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delet func (newState *DeleteSecret) SyncEffectiveFieldsDuringRead(existingState DeleteSecret) { } +func (a DeleteSecret) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type DeleteSecretResponse struct { } @@ -307,6 +395,10 @@ func (newState *DeleteSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteSecretResponse) SyncEffectiveFieldsDuringRead(existingState DeleteSecretResponse) { } +func (a DeleteSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Export a workspace object type ExportRequest struct { // This specifies the format of the exported file. By default, this is @@ -335,6 +427,10 @@ func (newState *ExportRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Expo func (newState *ExportRequest) SyncEffectiveFieldsDuringRead(existingState ExportRequest) { } +func (a ExportRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ExportResponse struct { // The base64-encoded content. If the limit (10MB) is exceeded, exception // with error code **MAX_NOTEBOOK_SIZE_EXCEEDED** is thrown. @@ -349,6 +445,10 @@ func (newState *ExportResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exp func (newState *ExportResponse) SyncEffectiveFieldsDuringRead(existingState ExportResponse) { } +func (a ExportResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get secret ACL details type GetAclRequest struct { // The principal to fetch ACL information for. @@ -363,6 +463,10 @@ func (newState *GetAclRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetA func (newState *GetAclRequest) SyncEffectiveFieldsDuringRead(existingState GetAclRequest) { } +func (a GetAclRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a credential entry type GetCredentialsRequest struct { // The ID for the corresponding credential to access. @@ -375,6 +479,10 @@ func (newState *GetCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialsRequest) { } +func (a GetCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetCredentialsResponse struct { // ID of the credential object in the workspace. CredentialId types.Int64 `tfsdk:"credential_id" tf:""` @@ -391,6 +499,10 @@ func (newState *GetCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState GetCredentialsResponse) { } +func (a GetCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get repo permission levels type GetRepoPermissionLevelsRequest struct { // The repo for which to get or manage permissions. @@ -403,9 +515,13 @@ func (newState *GetRepoPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetRepoPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionLevelsRequest) { } +func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetRepoPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []RepoPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRepoPermissionLevelsResponse) { @@ -414,6 +530,12 @@ func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringCreate func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionLevelsResponse) { } +func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(RepoPermissionsDescription{}), + } +} + // Get repo permissions type GetRepoPermissionsRequest struct { // The repo for which to get or manage permissions. @@ -426,6 +548,10 @@ func (newState *GetRepoPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetRepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionsRequest) { } +func (a GetRepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get a repo type GetRepoRequest struct { // ID of the Git folder (repo) object in the workspace. @@ -438,6 +564,10 @@ func (newState *GetRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetRepoRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoRequest) { } +func (a GetRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetRepoResponse struct { // Branch that the local version of the repo is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -450,7 +580,7 @@ type GetRepoResponse struct { // Git provider of the linked Git repository. Provider types.String `tfsdk:"provider" tf:"optional"` // Sparse checkout settings for the Git folder (repo). - SparseCheckout []SparseCheckout `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the linked Git repository. Url types.String `tfsdk:"url" tf:"optional"` } @@ -461,6 +591,12 @@ func (newState *GetRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetRepoResponse) SyncEffectiveFieldsDuringRead(existingState GetRepoResponse) { } +func (a GetRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + } +} + // Get a secret type GetSecretRequest struct { // The key to fetch secret for. @@ -475,6 +611,10 @@ func (newState *GetSecretRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSecretRequest) SyncEffectiveFieldsDuringRead(existingState GetSecretRequest) { } +func (a GetSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetSecretResponse struct { // A unique name to identify the secret. Key types.String `tfsdk:"key" tf:"optional"` @@ -488,6 +628,10 @@ func (newState *GetSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetSecretResponse) SyncEffectiveFieldsDuringRead(existingState GetSecretResponse) { } +func (a GetSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get status type GetStatusRequest struct { // The absolute path of the notebook or directory. @@ -500,6 +644,10 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } +func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Get workspace object permission levels type GetWorkspaceObjectPermissionLevelsRequest struct { // The workspace object for which to get or manage permissions. @@ -514,9 +662,13 @@ func (newState *GetWorkspaceObjectPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetWorkspaceObjectPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionLevelsRequest) { } +func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type GetWorkspaceObjectPermissionLevelsResponse struct { // Specific permission levels - PermissionLevels []WorkspaceObjectPermissionsDescription `tfsdk:"permission_levels" tf:"optional"` + PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` } func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetWorkspaceObjectPermissionLevelsResponse) { @@ -525,6 +677,12 @@ func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionLevelsResponse) { } +func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "PermissionLevels": reflect.TypeOf(WorkspaceObjectPermissionsDescription{}), + } +} + // Get workspace object permissions type GetWorkspaceObjectPermissionsRequest struct { // The workspace object for which to get or manage permissions. @@ -539,6 +697,10 @@ func (newState *GetWorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetWorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionsRequest) { } +func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Import struct { // The base64-encoded content. This has a limit of 10 MB. // @@ -578,6 +740,10 @@ func (newState *Import) SyncEffectiveFieldsDuringCreateOrUpdate(plan Import) { func (newState *Import) SyncEffectiveFieldsDuringRead(existingState Import) { } +func (a Import) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ImportResponse struct { } @@ -587,6 +753,10 @@ func (newState *ImportResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Imp func (newState *ImportResponse) SyncEffectiveFieldsDuringRead(existingState ImportResponse) { } +func (a ImportResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + // Lists ACLs type ListAclsRequest struct { // The name of the scope to fetch ACL information from. @@ -599,9 +769,13 @@ func (newState *ListAclsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListAclsRequest) SyncEffectiveFieldsDuringRead(existingState ListAclsRequest) { } +func (a ListAclsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListAclsResponse struct { // The associated ACLs rule applied to principals in the given scope. - Items []AclItem `tfsdk:"items" tf:"optional"` + Items types.List `tfsdk:"items" tf:"optional"` } func (newState *ListAclsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListAclsResponse) { @@ -610,9 +784,15 @@ func (newState *ListAclsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListAclsResponse) SyncEffectiveFieldsDuringRead(existingState ListAclsResponse) { } +func (a ListAclsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Items": reflect.TypeOf(AclItem{}), + } +} + type ListCredentialsResponse struct { // List of credentials. - Credentials []CredentialInfo `tfsdk:"credentials" tf:"optional"` + Credentials types.List `tfsdk:"credentials" tf:"optional"` } func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListCredentialsResponse) { @@ -621,6 +801,12 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListCredentialsResponse) { } +func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Credentials": reflect.TypeOf(CredentialInfo{}), + } +} + // Get repos type ListReposRequest struct { // Token used to get the next page of results. If not specified, returns the @@ -639,12 +825,16 @@ func (newState *ListReposRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListReposRequest) SyncEffectiveFieldsDuringRead(existingState ListReposRequest) { } +func (a ListReposRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListReposResponse struct { // Token that can be specified as a query parameter to the `GET /repos` // endpoint to retrieve the next page of results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // List of Git folders (repos). - Repos []RepoInfo `tfsdk:"repos" tf:"optional"` + Repos types.List `tfsdk:"repos" tf:"optional"` } func (newState *ListReposResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListReposResponse) { @@ -653,9 +843,15 @@ func (newState *ListReposResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListReposResponse) SyncEffectiveFieldsDuringRead(existingState ListReposResponse) { } +func (a ListReposResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Repos": reflect.TypeOf(RepoInfo{}), + } +} + type ListResponse struct { // List of objects. - Objects []ObjectInfo `tfsdk:"objects" tf:"optional"` + Objects types.List `tfsdk:"objects" tf:"optional"` } func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListResponse) { @@ -664,9 +860,15 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListR func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListResponse) { } +func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Objects": reflect.TypeOf(ObjectInfo{}), + } +} + type ListScopesResponse struct { // The available secret scopes. - Scopes []SecretScope `tfsdk:"scopes" tf:"optional"` + Scopes types.List `tfsdk:"scopes" tf:"optional"` } func (newState *ListScopesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListScopesResponse) { @@ -675,6 +877,12 @@ func (newState *ListScopesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListScopesResponse) SyncEffectiveFieldsDuringRead(existingState ListScopesResponse) { } +func (a ListScopesResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Scopes": reflect.TypeOf(SecretScope{}), + } +} + // List secret keys type ListSecretsRequest struct { // The name of the scope to list secrets within. @@ -687,9 +895,13 @@ func (newState *ListSecretsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSecretsRequest) SyncEffectiveFieldsDuringRead(existingState ListSecretsRequest) { } +func (a ListSecretsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ListSecretsResponse struct { // Metadata information of all secrets contained within the given scope. - Secrets []SecretMetadata `tfsdk:"secrets" tf:"optional"` + Secrets types.List `tfsdk:"secrets" tf:"optional"` } func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListSecretsResponse) { @@ -698,6 +910,12 @@ func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringRead(existingState ListSecretsResponse) { } +func (a ListSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Secrets": reflect.TypeOf(SecretMetadata{}), + } +} + // List contents type ListWorkspaceRequest struct { // UTC timestamp in milliseconds @@ -712,6 +930,10 @@ func (newState *ListWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState ListWorkspaceRequest) { } +func (a ListWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type Mkdirs struct { // The absolute path of the directory. If the parent directories do not // exist, it will also create them. If the directory already exists, this @@ -725,6 +947,10 @@ func (newState *Mkdirs) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mkdirs) { func (newState *Mkdirs) SyncEffectiveFieldsDuringRead(existingState Mkdirs) { } +func (a Mkdirs) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type MkdirsResponse struct { } @@ -734,6 +960,10 @@ func (newState *MkdirsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mkd func (newState *MkdirsResponse) SyncEffectiveFieldsDuringRead(existingState MkdirsResponse) { } +func (a MkdirsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type ObjectInfo struct { // Only applicable to files. The creation UTC timestamp. CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -765,6 +995,10 @@ func (newState *ObjectInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ObjectI func (newState *ObjectInfo) SyncEffectiveFieldsDuringRead(existingState ObjectInfo) { } +func (a ObjectInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PutAcl struct { // The permission level applied to the principal. Permission types.String `tfsdk:"permission" tf:""` @@ -780,6 +1014,10 @@ func (newState *PutAcl) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAcl) { func (newState *PutAcl) SyncEffectiveFieldsDuringRead(existingState PutAcl) { } +func (a PutAcl) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PutAclResponse struct { } @@ -789,6 +1027,10 @@ func (newState *PutAclResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Put func (newState *PutAclResponse) SyncEffectiveFieldsDuringRead(existingState PutAclResponse) { } +func (a PutAclResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PutSecret struct { // If specified, value will be stored as bytes. BytesValue types.String `tfsdk:"bytes_value" tf:"optional"` @@ -806,6 +1048,10 @@ func (newState *PutSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutSecre func (newState *PutSecret) SyncEffectiveFieldsDuringRead(existingState PutSecret) { } +func (a PutSecret) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type PutSecretResponse struct { } @@ -815,6 +1061,10 @@ func (newState *PutSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PutSecretResponse) SyncEffectiveFieldsDuringRead(existingState PutSecretResponse) { } +func (a PutSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RepoAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -832,9 +1082,13 @@ func (newState *RepoAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *RepoAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState RepoAccessControlRequest) { } +func (a RepoAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RepoAccessControlResponse struct { // All permissions. - AllPermissions []RepoPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -851,6 +1105,12 @@ func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState RepoAccessControlResponse) { } +func (a RepoAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(RepoPermission{}), + } +} + // Git folder (repo) information. type RepoInfo struct { // Name of the current git branch of the git folder (repo). @@ -864,7 +1124,7 @@ type RepoInfo struct { // Git provider of the remote git repository, e.g. `gitHub`. Provider types.String `tfsdk:"provider" tf:"optional"` // Sparse checkout config for the git folder (repo). - SparseCheckout []SparseCheckout `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the remote git repository. Url types.String `tfsdk:"url" tf:"optional"` } @@ -875,10 +1135,16 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoInfo) func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) { } +func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + } +} + type RepoPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -889,8 +1155,14 @@ func (newState *RepoPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rep func (newState *RepoPermission) SyncEffectiveFieldsDuringRead(existingState RepoPermission) { } +func (a RepoPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type RepoPermissions struct { - AccessControlList []RepoAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -903,6 +1175,12 @@ func (newState *RepoPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RepoPermissions) SyncEffectiveFieldsDuringRead(existingState RepoPermissions) { } +func (a RepoPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(RepoAccessControlResponse{}), + } +} + type RepoPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -915,8 +1193,12 @@ func (newState *RepoPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RepoPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState RepoPermissionsDescription) { } +func (a RepoPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type RepoPermissionsRequest struct { - AccessControlList []RepoAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The repo for which to get or manage permissions. RepoId types.String `tfsdk:"-"` } @@ -927,6 +1209,12 @@ func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState RepoPermissionsRequest) { } +func (a RepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(RepoAccessControlRequest{}), + } +} + type SecretMetadata struct { // A unique name to identify the secret. Key types.String `tfsdk:"key" tf:"optional"` @@ -940,11 +1228,15 @@ func (newState *SecretMetadata) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sec func (newState *SecretMetadata) SyncEffectiveFieldsDuringRead(existingState SecretMetadata) { } +func (a SecretMetadata) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type SecretScope struct { // The type of secret scope backend. BackendType types.String `tfsdk:"backend_type" tf:"optional"` // The metadata for the secret scope if the type is `AZURE_KEYVAULT` - KeyvaultMetadata []AzureKeyVaultSecretScopeMetadata `tfsdk:"keyvault_metadata" tf:"optional,object"` + KeyvaultMetadata types.Object `tfsdk:"keyvault_metadata" tf:"optional,object"` // A unique name to identify the secret scope. Name types.String `tfsdk:"name" tf:"optional"` } @@ -955,13 +1247,19 @@ func (newState *SecretScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Secret func (newState *SecretScope) SyncEffectiveFieldsDuringRead(existingState SecretScope) { } +func (a SecretScope) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "KeyvaultMetadata": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), + } +} + // Sparse checkout configuration, it contains options like cone patterns. type SparseCheckout struct { // List of sparse checkout cone patterns, see [cone mode handling] for // details. // // [cone mode handling]: https://git-scm.com/docs/git-sparse-checkout#_internalscone_mode_handling - Patterns []types.String `tfsdk:"patterns" tf:"optional"` + Patterns types.List `tfsdk:"patterns" tf:"optional"` } func (newState *SparseCheckout) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparseCheckout) { @@ -970,13 +1268,19 @@ func (newState *SparseCheckout) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spa func (newState *SparseCheckout) SyncEffectiveFieldsDuringRead(existingState SparseCheckout) { } +func (a SparseCheckout) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Patterns": reflect.TypeOf(""), + } +} + // Sparse checkout configuration, it contains options like cone patterns. type SparseCheckoutUpdate struct { // List of sparse checkout cone patterns, see [cone mode handling] for // details. // // [cone mode handling]: https://git-scm.com/docs/git-sparse-checkout#_internalscone_mode_handling - Patterns []types.String `tfsdk:"patterns" tf:"optional"` + Patterns types.List `tfsdk:"patterns" tf:"optional"` } func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparseCheckoutUpdate) { @@ -985,6 +1289,12 @@ func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringRead(existingState SparseCheckoutUpdate) { } +func (a SparseCheckoutUpdate) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "Patterns": reflect.TypeOf(""), + } +} + type UpdateCredentialsRequest struct { // The ID for the corresponding credential to access. CredentialId types.Int64 `tfsdk:"-"` @@ -1015,6 +1325,10 @@ func (newState *UpdateCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialsRequest) { } +func (a UpdateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateCredentialsResponse struct { } @@ -1024,6 +1338,10 @@ func (newState *UpdateCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialsResponse) { } +func (a UpdateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type UpdateRepoRequest struct { // Branch that the local version of the repo is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -1031,7 +1349,7 @@ type UpdateRepoRequest struct { RepoId types.Int64 `tfsdk:"-"` // If specified, update the sparse checkout settings. The update will fail // if sparse checkout is not enabled for the repo. - SparseCheckout []SparseCheckoutUpdate `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` // Tag that the local version of the repo is checked out to. Updating the // repo to a tag puts the repo in a detached HEAD state. Before committing // new changes, you must update the repo to a branch instead of the detached @@ -1045,6 +1363,12 @@ func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRepoRequest) { } +func (a UpdateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "SparseCheckout": reflect.TypeOf(SparseCheckoutUpdate{}), + } +} + type UpdateRepoResponse struct { } @@ -1054,6 +1378,10 @@ func (newState *UpdateRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRepoResponse) SyncEffectiveFieldsDuringRead(existingState UpdateRepoResponse) { } +func (a UpdateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WorkspaceObjectAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1071,9 +1399,13 @@ func (newState *WorkspaceObjectAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *WorkspaceObjectAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectAccessControlRequest) { } +func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WorkspaceObjectAccessControlResponse struct { // All permissions. - AllPermissions []WorkspaceObjectPermission `tfsdk:"all_permissions" tf:"optional"` + AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` // Display name of the user or service principal. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // name of the group @@ -1090,10 +1422,16 @@ func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectAccessControlResponse) { } +func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AllPermissions": reflect.TypeOf(WorkspaceObjectPermission{}), + } +} + type WorkspaceObjectPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` - InheritedFromObject []types.String `tfsdk:"inherited_from_object" tf:"optional"` + InheritedFromObject types.List `tfsdk:"inherited_from_object" tf:"optional"` // Permission level PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } @@ -1104,8 +1442,14 @@ func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermission) { } +func (a WorkspaceObjectPermission) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "InheritedFromObject": reflect.TypeOf(""), + } +} + type WorkspaceObjectPermissions struct { - AccessControlList []WorkspaceObjectAccessControlResponse `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` ObjectId types.String `tfsdk:"object_id" tf:"optional"` @@ -1118,6 +1462,12 @@ func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissions) { } +func (a WorkspaceObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(WorkspaceObjectAccessControlResponse{}), + } +} + type WorkspaceObjectPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1130,8 +1480,12 @@ func (newState *WorkspaceObjectPermissionsDescription) SyncEffectiveFieldsDuring func (newState *WorkspaceObjectPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissionsDescription) { } +func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + type WorkspaceObjectPermissionsRequest struct { - AccessControlList []WorkspaceObjectAccessControlRequest `tfsdk:"access_control_list" tf:"optional"` + AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The workspace object for which to get or manage permissions. WorkspaceObjectId types.String `tfsdk:"-"` // The workspace object type for which to get or manage permissions. @@ -1143,3 +1497,9 @@ func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissionsRequest) { } + +func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "AccessControlList": reflect.TypeOf(WorkspaceObjectAccessControlRequest{}), + } +} From 6e44632ea2730cd7619ee0bd34981359136c1464 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 4 Dec 2024 13:45:53 +0100 Subject: [PATCH 28/91] maybe --- .codegen/model.go.tmpl | 47 +- .../common/complex_field_type_provider.go | 12 + .../providers/pluginfw/converters/go_to_tf.go | 94 +- .../providers/pluginfw/converters/tf_to_go.go | 119 +- .../pluginfw/tfschema/struct_to_schema.go | 41 +- internal/service/apps_tf/model.go | 359 +- internal/service/billing_tf/model.go | 416 ++- internal/service/catalog_tf/model.go | 2996 ++++++++++++++++- internal/service/compute_tf/model.go | 2384 ++++++++++++- internal/service/dashboards_tf/model.go | 506 ++- internal/service/files_tf/model.go | 301 ++ internal/service/iam_tf/model.go | 796 ++++- internal/service/jobs_tf/model.go | 2151 ++++++++++-- internal/service/marketplace_tf/model.go | 1293 ++++++- internal/service/ml_tf/model.go | 1688 +++++++++- internal/service/oauth2_tf/model.go | 348 +- internal/service/pipelines_tf/model.go | 891 ++++- internal/service/provisioning_tf/model.go | 648 +++- internal/service/serving_tf/model.go | 1013 +++++- internal/service/settings_tf/model.go | 1477 +++++++- internal/service/sharing_tf/model.go | 514 ++- internal/service/sql_tf/model.go | 1978 ++++++++++- internal/service/vectorsearch_tf/model.go | 497 ++- internal/service/workspace_tf/model.go | 750 ++++- 24 files changed, 20221 insertions(+), 1098 deletions(-) create mode 100644 internal/providers/pluginfw/common/complex_field_type_provider.go diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index 63c893af29..3344d1f8f5 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -65,19 +65,50 @@ func (a {{.PascalName}}) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + {{ range .Fields -}} + "{{.PascalName}}": {{ template "attr-type" .Entity }}, + {{ end}} + }, + } +} + {{end}} {{end}} +{{/* TODO: Handle recursive Jobs structure */}} +{{- define "attr-type" -}} + {{- if .ArrayValue }}basetypes.ListType{ + ElemType: {{ template "attr-type" .ArrayValue }}, + } + {{- else if .MapValue }}basetypes.MapType{ + ElemType: {{ template "attr-type" .MapValue }}, + } + {{- else -}} + {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}} + {{- if or .IsString .Enum -}}types.StringType + {{- else if .IsBool -}}types.BoolType + {{- else if .IsInt64 -}}types.Int64Type + {{- else if .IsFloat64 -}}types.Float64Type + {{- else if .IsInt -}}types.Int64Type + {{- else if .IsAny -}}types.ObjectType{} + {{- else if .IsByteStream}}types.ObjectType{} + {{- else if .IsObject -}}{{.PascalName}}{}.ToAttrType(ctx) + {{- end -}} + {{- end -}} +{{- end -}} -{{define "complex-field-value" -}} +{{- define "complex-field-value" -}} {{- if .ArrayValue }}{{ template "complex-field-value" .ArrayValue }} {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} {{- else -}} {{- if .IsExternal -}}{{.Package.Name}}.{{- end -}} - {{- if or .IsString .Enum -}}"" - {{- else if .IsBool -}}false - {{- else if .IsInt64 -}}0 - {{- else if .IsFloat64 -}}0.0 - {{- else if .IsInt -}}0 + {{- if or .IsString .Enum -}}types.StringType + {{- else if .IsBool -}}types.BoolType + {{- else if .IsInt64 -}}types.Int64Type + {{- else if .IsFloat64 -}}types.Float64Type + {{- else if .IsInt -}}types.Int64Type {{- else if .IsAny -}}struct{}{} {{- else if .IsObject -}}{{.PascalName}}{} {{- end -}} @@ -118,8 +149,8 @@ func (a {{.PascalName}}) GetComplexFieldTypes() map[string]reflect.Type { {{- else if .IsInt}}types.Int64 {{- else if .IsByteStream}}io.ReadCloser {{- else if .ArrayValue }}types.List - {{- else if .MapValue }}types.Map - {{- else if .IsObject }}types.Object + {{- else if .MapValue }}types.Map{{/* Note: we use types.List for objects for now. TODO: change this to types.Object. */}} + {{- else if .IsObject }}types.List {{- else if .Enum }}types.String {{- else}}any /* MISSING TYPE */ {{- end -}} diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go new file mode 100644 index 0000000000..59c0d0186b --- /dev/null +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -0,0 +1,12 @@ +package common + +import ( + "reflect" + + "github.com/hashicorp/terraform-plugin-framework/types" +) + +type ComplexFieldTypeProvider interface { + GetComplexFieldTypes() map[string]reflect.Type + ToAttrType() types.ObjectType +} diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index 9fed34b494..d1d80255b1 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -6,10 +6,13 @@ import ( "reflect" "github.com/databricks/databricks-sdk-go/logger" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-log/tflog" "github.com/databricks/terraform-provider-databricks/common" + tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" ) @@ -51,8 +54,14 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ return diag.Diagnostics{diag.NewErrorDiagnostic(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("input should be structs %s, %s", srcVal.Type().Name(), destVal.Type().Name()))} } - var forceSendFieldVal []string + var complexFieldTypes map[string]reflect.Type + var objectType types.ObjectType + if cftp, ok := destVal.Interface().(tfcommon.ComplexFieldTypeProvider); ok { + complexFieldTypes = cftp.GetComplexFieldTypes() + objectType = cftp.ToAttrType() + } + var forceSendFieldVal []string forceSendField := srcVal.FieldByName("ForceSendFields") if !forceSendField.IsValid() { // If no forceSendField, just use an empty list. @@ -75,8 +84,10 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ logger.Tracef(ctx, fmt.Sprintf("field skipped in gosdk to tfsdk conversion: destination struct does not have field %s", srcFieldName)) continue } + innerType, _ := objectType.AttrTypes[srcFieldName] + complexFieldType, _ := complexFieldTypes[srcFieldName] - err := goSdkToTfSdkSingleField(ctx, srcField, destField, fieldInForceSendFields(srcFieldName, forceSendFieldVal)) + err := goSdkToTfSdkSingleField(ctx, srcField, destField, fieldInForceSendFields(srcFieldName, forceSendFieldVal), innerType, complexFieldType) if err != nil { return diag.Diagnostics{diag.NewErrorDiagnostic(goSdkToTfSdkFieldConversionFailureMessage, err.Error())} } @@ -84,7 +95,13 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ return nil } -func goSdkToTfSdkSingleField(ctx context.Context, srcField reflect.Value, destField reflect.Value, forceSendField bool) error { +func goSdkToTfSdkSingleField( + ctx context.Context, + srcField reflect.Value, + destField reflect.Value, + forceSendField bool, + innerType attr.Type, + complexFieldType reflect.Type) error { if !destField.CanSet() { panic(fmt.Errorf("destination field can not be set: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) @@ -96,31 +113,17 @@ func goSdkToTfSdkSingleField(ctx context.Context, srcField reflect.Value, destFi return nil } - switch srcField.Kind() { - case reflect.Ptr: + if srcField.Kind() == reflect.Ptr { if srcField.IsNil() { // Skip nils return nil } + srcField = srcField.Elem() + } - var fieldToSetInterface any - - if destField.Kind() == reflect.Slice { - sliceType := destField.Type() - newSlice := reflect.MakeSlice(sliceType, 1, 1) - newSlice.Index(0).Set(reflect.New(sliceType.Elem()).Elem()) - - destField.Set(newSlice) - fieldToSetInterface = newSlice.Index(0).Addr().Interface() - } else { - destField.Set(reflect.New(destField.Type().Elem())) - fieldToSetInterface = destField.Interface() - } - - // Recursively populate the nested struct. - if GoSdkToTfSdkStruct(ctx, srcFieldValue, fieldToSetInterface).HasError() { - panic(fmt.Sprintf("%s. %s", goSdkToTfSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) - } + switch srcField.Kind() { + case reflect.Ptr: + panic(fmt.Errorf("pointer to pointer is not supported: %s. %s", srcField.Type().Name(), common.TerraformBugErrorMessage)) case reflect.Bool: boolVal := srcFieldValue.(bool) // check if the value is non-zero or if the field is in the forceSendFields list @@ -166,6 +169,14 @@ func goSdkToTfSdkSingleField(ctx context.Context, srcField reflect.Value, destFi // Skip zeros return nil } + // If the destination field is a types.List, treat the source field as a slice with length 1 + // containing only this struct. + if destField.Type() == reflect.TypeOf(types.List{}) { + listSrc := reflect.MakeSlice(reflect.SliceOf(srcField.Type()), 1, 1) + listSrc.Index(0).Set(srcField) + return goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, innerType, complexFieldType) + } + var dest any if destField.Kind() == reflect.Slice { // allocate a slice first @@ -184,17 +195,38 @@ func goSdkToTfSdkSingleField(ctx context.Context, srcField reflect.Value, destFi // Skip nils return nil } - destSlice := reflect.MakeSlice(destField.Type(), srcField.Len(), srcField.Cap()) - for j := 0; j < srcField.Len(); j++ { + // If the target is a types.List, we first convert each element of the slice to the corresponding inner type + // and then set the list. + if destField.Type() == reflect.TypeOf(types.List{}) { + elements := make([]any, 0, srcField.Len()) + for i := 0; i < srcField.Len(); i++ { + element := reflect.New(complexFieldType).Elem() + if err := goSdkToTfSdkSingleField(ctx, srcField.Index(i), element, true, innerType, complexFieldType); err != nil { + return err + } + elements = append(elements, element.Interface()) + } + destVal, d := types.ListValueFrom(ctx, innerType, elements) + if d.HasError() { + for _, diag := range d { + tflog.Error(ctx, diag.Detail()) + } + panic(fmt.Sprintf("%s. %s", goSdkToTfSdkFieldConversionFailureMessage, common.TerraformBugErrorMessage)) + } + destField.Set(reflect.ValueOf(destVal)) + } else { + destSlice := reflect.MakeSlice(destField.Type(), srcField.Len(), srcField.Cap()) + for j := 0; j < srcField.Len(); j++ { - srcElem := srcField.Index(j) + srcElem := srcField.Index(j) - destElem := destSlice.Index(j) - if err := goSdkToTfSdkSingleField(ctx, srcElem, destElem, true); err != nil { - return err + destElem := destSlice.Index(j) + if err := goSdkToTfSdkSingleField(ctx, srcElem, destElem, true, innerType, complexFieldType); err != nil { + return err + } } + destField.Set(destSlice) } - destField.Set(destSlice) case reflect.Map: if srcField.IsNil() { // Skip nils @@ -205,7 +237,7 @@ func goSdkToTfSdkSingleField(ctx context.Context, srcField reflect.Value, destFi srcMapValue := srcField.MapIndex(key) destMapValue := reflect.New(destField.Type().Elem()).Elem() destMapKey := reflect.ValueOf(key.Interface()) - if err := goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue, true); err != nil { + if err := goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue, true, innerType, complexFieldType); err != nil { return err } destMap.SetMapIndex(destMapKey, destMapValue) diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 27eb02d915..ae47ed6f83 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -6,6 +6,7 @@ import ( "reflect" "github.com/databricks/databricks-sdk-go/logger" + tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-log/tflog" @@ -52,6 +53,11 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ forceSendFieldsField := destVal.FieldByName("ForceSendFields") + var innerTypes map[string]reflect.Type + if cftp, ok := tfsdk.(tfcommon.ComplexFieldTypeProvider); ok { + innerTypes = cftp.GetComplexFieldTypes() + } + allFields := tfreflect.ListAllFields(srcVal) for _, field := range allFields { srcField := field.Value @@ -63,8 +69,9 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ } destField := destVal.FieldByName(srcFieldName) + innerType, _ := innerTypes[srcFieldName] - err := tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField) + err := tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField, innerType) if err != nil { return diag.Diagnostics{diag.NewErrorDiagnostic(tfSdkToGoSdkFieldConversionFailureMessage, err.Error())} } @@ -73,7 +80,13 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ return nil } -func tfSdkToGoSdkSingleField(ctx context.Context, srcField reflect.Value, destField reflect.Value, srcFieldName string, forceSendFieldsField *reflect.Value) error { +func tfSdkToGoSdkSingleField( + ctx context.Context, + srcField reflect.Value, + destField reflect.Value, + srcFieldName string, + forceSendFieldsField *reflect.Value, + innerType reflect.Type) error { if !destField.IsValid() { // Skip field that destination struct does not have. @@ -106,7 +119,7 @@ func tfSdkToGoSdkSingleField(ctx context.Context, srcField reflect.Value, destFi return nil } assertStructSliceLengthIsOne(srcField) - tfsdkToGoSdkStructField(srcField.Index(0), destField, srcFieldName, forceSendFieldsField, ctx) + tfsdkToGoSdkStructField(srcField.Index(0), destField, srcFieldName, forceSendFieldsField, ctx, innerType) } else if srcField.Kind() == reflect.Slice && destField.Kind() == reflect.Ptr { if srcField.IsNil() { // Skip nils @@ -121,7 +134,7 @@ func tfSdkToGoSdkSingleField(ctx context.Context, srcField reflect.Value, destFi panic(fmt.Sprintf("%s. %s", tfSdkToGoSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) } } else if srcField.Kind() == reflect.Struct { - tfsdkToGoSdkStructField(srcField, destField, srcFieldName, forceSendFieldsField, ctx) + tfsdkToGoSdkStructField(srcField, destField, srcFieldName, forceSendFieldsField, ctx, innerType) } else if srcField.Kind() == reflect.Slice { if srcField.IsNil() { // Skip nils @@ -133,7 +146,7 @@ func tfSdkToGoSdkSingleField(ctx context.Context, srcField reflect.Value, destFi srcElem := srcField.Index(j) destElem := destSlice.Index(j) - if err := tfSdkToGoSdkSingleField(ctx, srcElem, destElem, "", nil); err != nil { + if err := tfSdkToGoSdkSingleField(ctx, srcElem, destElem, "", nil, innerType); err != nil { return err } } @@ -148,7 +161,7 @@ func tfSdkToGoSdkSingleField(ctx context.Context, srcField reflect.Value, destFi srcMapValue := srcField.MapIndex(key) destMapValue := reflect.New(destField.Type().Elem()).Elem() destMapKey := reflect.ValueOf(key.Interface()) - if err := tfSdkToGoSdkSingleField(ctx, srcMapValue, destMapValue, "", nil); err != nil { + if err := tfSdkToGoSdkSingleField(ctx, srcMapValue, destMapValue, "", nil, innerType); err != nil { return err } destMap.SetMapIndex(destMapKey, destMapValue) @@ -161,7 +174,35 @@ func tfSdkToGoSdkSingleField(ctx context.Context, srcField reflect.Value, destFi } -func tfsdkToGoSdkStructField(srcField reflect.Value, destField reflect.Value, srcFieldName string, forceSendFieldsField *reflect.Value, ctx context.Context) { +// Returns a reflect.Value of the enum type with the value set to the given string. +func convertToEnumValue(v types.String, destType reflect.Type) reflect.Value { + // Find the Set method + destVal := reflect.New(destType) + setMethod := destVal.MethodByName("Set") + if !setMethod.IsValid() { + panic(fmt.Sprintf("set method not found on enum type: %s. %s", destType.Name(), common.TerraformBugErrorMessage)) + } + + // Prepare the argument for the Set method + arg := reflect.ValueOf(v.ValueString()) + + // Call the Set method + result := setMethod.Call([]reflect.Value{arg}) + if len(result) != 0 { + if err, ok := result[0].Interface().(error); ok && err != nil { + panic(fmt.Sprintf("%s. %s", err, common.TerraformBugErrorMessage)) + } + } + return destVal.Elem() +} + +func tfsdkToGoSdkStructField( + srcField reflect.Value, + destField reflect.Value, + srcFieldName string, + forceSendFieldsField *reflect.Value, + ctx context.Context, + innerType reflect.Type) { srcFieldValue := srcField.Interface() switch v := srcFieldValue.(type) { case types.Bool: @@ -188,23 +229,7 @@ func tfsdkToGoSdkStructField(srcField reflect.Value, destField reflect.Value, sr return } - // Find the Set method - destVal := reflect.New(destField.Type()) - setMethod := destVal.MethodByName("Set") - if !setMethod.IsValid() { - panic(fmt.Sprintf("set method not found on enum type: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) - } - - // Prepare the argument for the Set method - arg := reflect.ValueOf(v.ValueString()) - - // Call the Set method - result := setMethod.Call([]reflect.Value{arg}) - if len(result) != 0 { - if err, ok := result[0].Interface().(error); ok && err != nil { - panic(fmt.Sprintf("%s. %s", err, common.TerraformBugErrorMessage)) - } - } + destVal := convertToEnumValue(v, destField.Type()) // We don't need to set ForceSendFields for enums because the value is never going to be a zero value (empty string). destField.Set(destVal.Elem()) } else { @@ -214,9 +239,49 @@ func tfsdkToGoSdkStructField(srcField reflect.Value, destField reflect.Value, sr } } case types.List: - panic(fmt.Sprintf("types.List should never be used, use go native slices instead. %s", common.TerraformBugErrorMessage)) - case types.Map: - panic(fmt.Sprintf("types.Map should never be used, use go native maps instead. %s", common.TerraformBugErrorMessage)) + if v.IsNull() || v.IsUnknown() { + return + } + + var d diag.Diagnostics + innerValue := reflect.New(reflect.SliceOf(innerType)) + + // Read the nested elements into the TFSDK struct slice + d = v.ElementsAs(ctx, innerValue.Interface(), true) + if d.HasError() { + for _, diag := range d { + tflog.Error(ctx, fmt.Sprintf("[ERROR] %s: %s", diag.Summary(), diag.Detail())) + } + panic("failed to convert list") + } + + // Recursively call TFSDK to GOSDK conversion for each element in the list + var destInnerType reflect.Type + if destField.Type().Kind() == reflect.Slice { + destInnerType = destField.Type().Elem() + } else { + assertStructSliceLengthIsOne(innerValue) + // Case of types.List <-> struct + destInnerType = destField.Type() + } + + converted := make([]any, 0, innerValue.Elem().Len()) + for i := 0; i < innerValue.Elem().Len(); i++ { + next := reflect.New(destInnerType) + err := tfSdkToGoSdkSingleField(ctx, innerValue.Elem().Index(i), next, "", forceSendFieldsField, innerType) + if err != nil { + panic(err) + } + converted = append(converted, next.Elem().Interface()) + } + + if destField.Type().Kind() == reflect.Slice { + destField.Set(reflect.ValueOf(converted)) + } else { + destField.Set(reflect.ValueOf(converted[0])) + } + case types.Object, types.Map, types.Set, types.Tuple: + panic(fmt.Sprintf("%T should never be used, use go native maps instead. %s", v, common.TerraformBugErrorMessage)) default: if srcField.IsZero() { // Skip zeros diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 6b1df6ea4e..01b229b043 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -6,8 +6,10 @@ import ( "strings" "github.com/databricks/terraform-provider-databricks/common" + tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" + "github.com/hashicorp/terraform-plugin-framework/attr" dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/schema/validator" @@ -20,10 +22,6 @@ type structTag struct { singleObject bool } -type complexFieldTypeProvider interface { - GetComplexFieldTypes() map[string]reflect.Type -} - func typeToSchema(v reflect.Value) NestedBlockObject { scmAttr := map[string]AttributeBuilder{} scmBlock := map[string]BlockBuilder{} @@ -39,7 +37,7 @@ func typeToSchema(v reflect.Value) NestedBlockObject { // Get metadata about complex fields var complexFieldTypes map[string]reflect.Type - if provider, ok := v.Interface().(complexFieldTypeProvider); ok { + if provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider); ok { complexFieldTypes = provider.GetComplexFieldTypes() } @@ -185,7 +183,35 @@ func typeToSchema(v reflect.Value) NestedBlockObject { Required: !structTag.optional, Computed: structTag.computed, } - case types.Object, types.List: + case types.List: + // Look up nested struct type + if complexFieldTypes == nil { + panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) + } + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + } + // If the field type is a "primitive", use ListAttributeBuilder + // otherwise use ListNestedBlockBuilder + switch fieldType { + case reflect.TypeOf(types.BoolType), reflect.TypeOf(types.Int64Type), reflect.TypeOf(types.Float64Type), reflect.TypeOf(types.StringType): + scmAttr[fieldName] = ListAttributeBuilder{ + ElementType: reflect.New(fieldType).Elem().Interface().(attr.Type), + Optional: structTag.optional, + Required: !structTag.optional, + Computed: structTag.computed, + } + default: + fieldValue := reflect.New(fieldType).Elem() + + // Generate the nested block schema + // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). + scmBlock[fieldName] = ListNestedBlockBuilder{ + NestedObject: typeToSchema(fieldValue), + } + } + case types.Object: // Look up nested struct type if complexFieldTypes == nil { panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) @@ -197,8 +223,7 @@ func typeToSchema(v reflect.Value) NestedBlockObject { fieldValue := reflect.New(fieldType).Elem() // Generate the nested block schema - // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). - scmBlock[fieldName] = ListNestedBlockBuilder{ + scmBlock[fieldName] = SingleNestedBlockBuilder{ NestedObject: typeToSchema(fieldValue), } case types.Set, types.Tuple, types.Map: diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index c3862cd1c7..abba0ddbaa 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -11,19 +11,22 @@ We use go-native types for lists and maps intentionally for the ease for convert package apps_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type App struct { // The active deployment of the app. A deployment is considered active when // it has been deployed to the app compute. - ActiveDeployment types.Object `tfsdk:"active_deployment" tf:"optional,object"` + ActiveDeployment types.List `tfsdk:"active_deployment" tf:"optional,object"` - AppStatus types.Object `tfsdk:"app_status" tf:"optional,object"` + AppStatus types.List `tfsdk:"app_status" tf:"optional,object"` - ComputeStatus types.Object `tfsdk:"compute_status" tf:"optional,object"` + ComputeStatus types.List `tfsdk:"compute_status" tf:"optional,object"` // The creation time of the app. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The email of the user that created the app. @@ -39,7 +42,7 @@ type App struct { Name types.String `tfsdk:"name" tf:""` // The pending deployment of the app. A deployment is considered pending // when it is being prepared for deployment to the app compute. - PendingDeployment types.Object `tfsdk:"pending_deployment" tf:"optional,object"` + PendingDeployment types.List `tfsdk:"pending_deployment" tf:"optional,object"` // Resources for the app. Resources types.List `tfsdk:"resources" tf:"optional"` @@ -72,6 +75,31 @@ func (a App) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a App) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActiveDeployment": AppDeployment{}.ToAttrType(ctx), + "AppStatus": ApplicationStatus{}.ToAttrType(ctx), + "ComputeStatus": ComputeStatus{}.ToAttrType(ctx), + "CreateTime": types.StringType, + "Creator": types.StringType, + "DefaultSourceCodePath": types.StringType, + "Description": types.StringType, + "Name": types.StringType, + "PendingDeployment": AppDeployment{}.ToAttrType(ctx), + "Resources": basetypes.ListType{ + ElemType: AppResource{}.ToAttrType(ctx), + }, + "ServicePrincipalClientId": types.StringType, + "ServicePrincipalId": types.Int64Type, + "ServicePrincipalName": types.StringType, + "UpdateTime": types.StringType, + "Updater": types.StringType, + "Url": types.StringType, + }, + } +} + type AppAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -93,6 +121,17 @@ func (a AppAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a AppAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type AppAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -118,13 +157,27 @@ func (a AppAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a AppAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: AppPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type AppDeployment struct { // The creation time of the deployment. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The email of the user creates the deployment. Creator types.String `tfsdk:"creator" tf:"computed,optional"` // The deployment artifacts for an app. - DeploymentArtifacts types.Object `tfsdk:"deployment_artifacts" tf:"optional,object"` + DeploymentArtifacts types.List `tfsdk:"deployment_artifacts" tf:"optional,object"` // The unique id of the deployment. DeploymentId types.String `tfsdk:"deployment_id" tf:"optional"` // The mode of which the deployment will manage the source code. @@ -138,7 +191,7 @@ type AppDeployment struct { // the deployment. SourceCodePath types.String `tfsdk:"source_code_path" tf:"optional"` // Status and status message of the deployment - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` // The update time of the deployment. Formatted timestamp in ISO 6801. UpdateTime types.String `tfsdk:"update_time" tf:"computed,optional"` } @@ -156,6 +209,21 @@ func (a AppDeployment) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AppDeployment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "Creator": types.StringType, + "DeploymentArtifacts": AppDeploymentArtifacts{}.ToAttrType(ctx), + "DeploymentId": types.StringType, + "Mode": types.StringType, + "SourceCodePath": types.StringType, + "Status": AppDeploymentStatus{}.ToAttrType(ctx), + "UpdateTime": types.StringType, + }, + } +} + type AppDeploymentArtifacts struct { // The snapshotted workspace file system path of the source code loaded by // the deployed app. @@ -172,6 +240,14 @@ func (a AppDeploymentArtifacts) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AppDeploymentArtifacts) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "SourceCodePath": types.StringType, + }, + } +} + type AppDeploymentStatus struct { // Message corresponding with the deployment state. Message types.String `tfsdk:"message" tf:"computed,optional"` @@ -189,6 +265,15 @@ func (a AppDeploymentStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AppDeploymentStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + "State": types.StringType, + }, + } +} + type AppPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -205,7 +290,19 @@ func (newState *AppPermission) SyncEffectiveFieldsDuringRead(existingState AppPe func (a AppPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a AppPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -229,6 +326,18 @@ func (a AppPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AppPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AppAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type AppPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -245,6 +354,15 @@ func (a AppPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a AppPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type AppPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The app for which to get or manage permissions. @@ -263,19 +381,30 @@ func (a AppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AppAccessControlRequest{}.ToAttrType(ctx), + }, + "AppName": types.StringType, + }, + } +} + type AppResource struct { // Description of the App Resource. Description types.String `tfsdk:"description" tf:"optional"` - Job types.Object `tfsdk:"job" tf:"optional,object"` + Job types.List `tfsdk:"job" tf:"optional,object"` // Name of the App Resource. Name types.String `tfsdk:"name" tf:""` - Secret types.Object `tfsdk:"secret" tf:"optional,object"` + Secret types.List `tfsdk:"secret" tf:"optional,object"` - ServingEndpoint types.Object `tfsdk:"serving_endpoint" tf:"optional,object"` + ServingEndpoint types.List `tfsdk:"serving_endpoint" tf:"optional,object"` - SqlWarehouse types.Object `tfsdk:"sql_warehouse" tf:"optional,object"` + SqlWarehouse types.List `tfsdk:"sql_warehouse" tf:"optional,object"` } func (newState *AppResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppResource) { @@ -293,6 +422,19 @@ func (a AppResource) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AppResource) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Job": AppResourceJob{}.ToAttrType(ctx), + "Name": types.StringType, + "Secret": AppResourceSecret{}.ToAttrType(ctx), + "ServingEndpoint": AppResourceServingEndpoint{}.ToAttrType(ctx), + "SqlWarehouse": AppResourceSqlWarehouse{}.ToAttrType(ctx), + }, + } +} + type AppResourceJob struct { // Id of the job to grant permission on. Id types.String `tfsdk:"id" tf:""` @@ -311,6 +453,15 @@ func (a AppResourceJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AppResourceJob) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Permission": types.StringType, + }, + } +} + type AppResourceSecret struct { // Key of the secret to grant permission on. Key types.String `tfsdk:"key" tf:""` @@ -331,6 +482,16 @@ func (a AppResourceSecret) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AppResourceSecret) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Permission": types.StringType, + "Scope": types.StringType, + }, + } +} + type AppResourceServingEndpoint struct { // Name of the serving endpoint to grant permission on. Name types.String `tfsdk:"name" tf:""` @@ -349,6 +510,15 @@ func (a AppResourceServingEndpoint) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a AppResourceServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Permission": types.StringType, + }, + } +} + type AppResourceSqlWarehouse struct { // Id of the SQL warehouse to grant permission on. Id types.String `tfsdk:"id" tf:""` @@ -367,6 +537,15 @@ func (a AppResourceSqlWarehouse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a AppResourceSqlWarehouse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Permission": types.StringType, + }, + } +} + type ApplicationStatus struct { // Application status message Message types.String `tfsdk:"message" tf:"computed,optional"` @@ -384,6 +563,15 @@ func (a ApplicationStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ApplicationStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + "State": types.StringType, + }, + } +} + type ComputeStatus struct { // Compute status message Message types.String `tfsdk:"message" tf:"computed,optional"` @@ -401,9 +589,18 @@ func (a ComputeStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ComputeStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + "State": types.StringType, + }, + } +} + // Create an app deployment type CreateAppDeploymentRequest struct { - AppDeployment types.Object `tfsdk:"app_deployment" tf:"optional,object"` + AppDeployment types.List `tfsdk:"app_deployment" tf:"optional,object"` // The name of the app. AppName types.String `tfsdk:"-"` } @@ -420,9 +617,18 @@ func (a CreateAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a CreateAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppDeployment": AppDeployment{}.ToAttrType(ctx), + "AppName": types.StringType, + }, + } +} + // Create an app type CreateAppRequest struct { - App types.Object `tfsdk:"app" tf:"optional,object"` + App types.List `tfsdk:"app" tf:"optional,object"` } func (newState *CreateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateAppRequest) { @@ -437,6 +643,14 @@ func (a CreateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "App": App{}.ToAttrType(ctx), + }, + } +} + // Delete an app type DeleteAppRequest struct { // The name of the app. @@ -453,6 +667,14 @@ func (a DeleteAppRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteAppRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get an app deployment type GetAppDeploymentRequest struct { // The name of the app. @@ -471,6 +693,15 @@ func (a GetAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppName": types.StringType, + "DeploymentId": types.StringType, + }, + } +} + // Get app permission levels type GetAppPermissionLevelsRequest struct { // The app for which to get or manage permissions. @@ -487,6 +718,14 @@ func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetAppPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppName": types.StringType, + }, + } +} + type GetAppPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -504,6 +743,16 @@ func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflec } } +func (a GetAppPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: AppPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get app permissions type GetAppPermissionsRequest struct { // The app for which to get or manage permissions. @@ -520,6 +769,14 @@ func (a GetAppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetAppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppName": types.StringType, + }, + } +} + // Get an app type GetAppRequest struct { // The name of the app. @@ -536,6 +793,14 @@ func (a GetAppRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetAppRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // List app deployments type ListAppDeploymentsRequest struct { // The name of the app. @@ -557,6 +822,16 @@ func (a ListAppDeploymentsRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a ListAppDeploymentsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppName": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListAppDeploymentsResponse struct { // Deployment history of the app. AppDeployments types.List `tfsdk:"app_deployments" tf:"optional"` @@ -576,6 +851,17 @@ func (a ListAppDeploymentsResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ListAppDeploymentsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppDeployments": basetypes.ListType{ + ElemType: AppDeployment{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List apps type ListAppsRequest struct { // Upper bound for items returned. @@ -595,6 +881,15 @@ func (a ListAppsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListAppsResponse struct { Apps types.List `tfsdk:"apps" tf:"optional"` // Pagination token to request the next page of apps. @@ -613,6 +908,17 @@ func (a ListAppsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListAppsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Apps": basetypes.ListType{ + ElemType: App{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type StartAppRequest struct { // The name of the app. Name types.String `tfsdk:"-"` @@ -628,6 +934,14 @@ func (a StartAppRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StartAppRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type StopAppRequest struct { // The name of the app. Name types.String `tfsdk:"-"` @@ -643,9 +957,17 @@ func (a StopAppRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StopAppRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Update an app type UpdateAppRequest struct { - App types.Object `tfsdk:"app" tf:"optional,object"` + App types.List `tfsdk:"app" tf:"optional,object"` // The name of the app. The name must contain only lowercase alphanumeric // characters and hyphens. It must be unique within the workspace. Name types.String `tfsdk:"-"` @@ -662,3 +984,12 @@ func (a UpdateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { "App": reflect.TypeOf(App{}), } } + +func (a UpdateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "App": App{}.ToAttrType(ctx), + "Name": types.StringType, + }, + } +} diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index d86f148fad..198f7ed81f 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -11,10 +11,13 @@ We use go-native types for lists and maps intentionally for the ease for convert package billing_tf import ( + "context" "io" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type ActionConfiguration struct { @@ -36,6 +39,16 @@ func (a ActionConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ActionConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActionConfigurationId": types.StringType, + "ActionType": types.StringType, + "Target": types.StringType, + }, + } +} + type AlertConfiguration struct { // Configured actions for this alert. These define what happens when an // alert enters a triggered state. @@ -67,6 +80,21 @@ func (a AlertConfiguration) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AlertConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActionConfigurations": basetypes.ListType{ + ElemType: ActionConfiguration{}.ToAttrType(ctx), + }, + "AlertConfigurationId": types.StringType, + "QuantityThreshold": types.StringType, + "QuantityType": types.StringType, + "TimePeriod": types.StringType, + "TriggerType": types.StringType, + }, + } +} + type BudgetConfiguration struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -83,7 +111,7 @@ type BudgetConfiguration struct { // usage to limit the scope of what is considered for this budget. Leave // empty to include all usage for this account. All provided filters must be // matched for usage to be included. - Filter types.Object `tfsdk:"filter" tf:"optional,object"` + Filter types.List `tfsdk:"filter" tf:"optional,object"` // Update time of this budget configuration. UpdateTime types.Int64 `tfsdk:"update_time" tf:"optional"` } @@ -101,13 +129,29 @@ func (a BudgetConfiguration) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a BudgetConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AlertConfigurations": basetypes.ListType{ + ElemType: AlertConfiguration{}.ToAttrType(ctx), + }, + "BudgetConfigurationId": types.StringType, + "CreateTime": types.Int64Type, + "DisplayName": types.StringType, + "Filter": BudgetConfigurationFilter{}.ToAttrType(ctx), + "UpdateTime": types.Int64Type, + }, + } +} + type BudgetConfigurationFilter struct { // A list of tag keys and values that will limit the budget to usage that // includes those specific custom tags. Tags are case-sensitive and should // be entered exactly as they appear in your usage data. Tags types.List `tfsdk:"tags" tf:"optional"` // If provided, usage must match with the provided Databricks workspace IDs. - WorkspaceId types.Object `tfsdk:"workspace_id" tf:"optional,object"` + WorkspaceId types.List `tfsdk:"workspace_id" tf:"optional,object"` } func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan BudgetConfigurationFilter) { @@ -123,6 +167,17 @@ func (a BudgetConfigurationFilter) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a BudgetConfigurationFilter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Tags": basetypes.ListType{ + ElemType: BudgetConfigurationFilterTagClause{}.ToAttrType(ctx), + }, + "WorkspaceId": BudgetConfigurationFilterWorkspaceIdClause{}.ToAttrType(ctx), + }, + } +} + type BudgetConfigurationFilterClause struct { Operator types.String `tfsdk:"operator" tf:"optional"` @@ -137,14 +192,25 @@ func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringRead(e func (a BudgetConfigurationFilterClause) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(""), + "Values": reflect.TypeOf(types.StringType), + } +} + +func (a BudgetConfigurationFilterClause) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Operator": types.StringType, + "Values": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type BudgetConfigurationFilterTagClause struct { Key types.String `tfsdk:"key" tf:"optional"` - Value types.Object `tfsdk:"value" tf:"optional,object"` + Value types.List `tfsdk:"value" tf:"optional,object"` } func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringCreateOrUpdate(plan BudgetConfigurationFilterTagClause) { @@ -159,6 +225,15 @@ func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes() map[string]re } } +func (a BudgetConfigurationFilterTagClause) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": BudgetConfigurationFilterClause{}.ToAttrType(ctx), + }, + } +} + type BudgetConfigurationFilterWorkspaceIdClause struct { Operator types.String `tfsdk:"operator" tf:"optional"` @@ -173,7 +248,18 @@ func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsD func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(0), + "Values": reflect.TypeOf(types.Int64Type), + } +} + +func (a BudgetConfigurationFilterWorkspaceIdClause) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Operator": types.StringType, + "Values": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -197,6 +283,15 @@ func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a CreateBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardType": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type CreateBillingUsageDashboardResponse struct { // The unique id of the usage dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` @@ -212,6 +307,14 @@ func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a CreateBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + type CreateBudgetConfigurationBudget struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -224,7 +327,7 @@ type CreateBudgetConfigurationBudget struct { // usage to limit the scope of what is considered for this budget. Leave // empty to include all usage for this account. All provided filters must be // matched for usage to be included. - Filter types.Object `tfsdk:"filter" tf:"optional,object"` + Filter types.List `tfsdk:"filter" tf:"optional,object"` } func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateBudgetConfigurationBudget) { @@ -240,6 +343,19 @@ func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]refle } } +func (a CreateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AlertConfigurations": basetypes.ListType{ + ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "Filter": BudgetConfigurationFilter{}.ToAttrType(ctx), + }, + } +} + type CreateBudgetConfigurationBudgetActionConfigurations struct { // The type of the action. ActionType types.String `tfsdk:"action_type" tf:"optional"` @@ -257,6 +373,15 @@ func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldType return map[string]reflect.Type{} } +func (a CreateBudgetConfigurationBudgetActionConfigurations) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActionType": types.StringType, + "Target": types.StringType, + }, + } +} + type CreateBudgetConfigurationBudgetAlertConfigurations struct { // Configured actions for this alert. These define what happens when an // alert enters a triggered state. @@ -286,9 +411,23 @@ func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes } } +func (a CreateBudgetConfigurationBudgetAlertConfigurations) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActionConfigurations": basetypes.ListType{ + ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.ToAttrType(ctx), + }, + "QuantityThreshold": types.StringType, + "QuantityType": types.StringType, + "TimePeriod": types.StringType, + "TriggerType": types.StringType, + }, + } +} + type CreateBudgetConfigurationRequest struct { // Properties of the new budget configuration. - Budget types.Object `tfsdk:"budget" tf:"object"` + Budget types.List `tfsdk:"budget" tf:"object"` } func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateBudgetConfigurationRequest) { @@ -303,9 +442,17 @@ func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]refl } } +func (a CreateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Budget": CreateBudgetConfigurationBudget{}.ToAttrType(ctx), + }, + } +} + type CreateBudgetConfigurationResponse struct { // The created budget configuration. - Budget types.Object `tfsdk:"budget" tf:"optional,object"` + Budget types.List `tfsdk:"budget" tf:"optional,object"` } func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateBudgetConfigurationResponse) { @@ -320,6 +467,14 @@ func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]ref } } +func (a CreateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Budget": BudgetConfiguration{}.ToAttrType(ctx), + }, + } +} + type CreateLogDeliveryConfigurationParams struct { // The optional human-readable name of the log delivery configuration. // Defaults to empty. @@ -400,7 +555,25 @@ func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringR func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "WorkspaceIdsFilter": reflect.TypeOf(0), + "WorkspaceIdsFilter": reflect.TypeOf(types.Int64Type), + } +} + +func (a CreateLogDeliveryConfigurationParams) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConfigName": types.StringType, + "CredentialsId": types.StringType, + "DeliveryPathPrefix": types.StringType, + "DeliveryStartTime": types.StringType, + "LogType": types.StringType, + "OutputFormat": types.StringType, + "Status": types.StringType, + "StorageConfigurationId": types.StringType, + "WorkspaceIdsFilter": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -420,6 +593,14 @@ func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a DeleteBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BudgetId": types.StringType, + }, + } +} + type DeleteBudgetConfigurationResponse struct { } @@ -433,6 +614,12 @@ func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a DeleteBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Return billable usage logs type DownloadRequest struct { // Format: `YYYY-MM`. Last month to return billable usage logs for. This @@ -457,6 +644,16 @@ func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndMonth": types.StringType, + "PersonalData": types.BoolType, + "StartMonth": types.StringType, + }, + } +} + type DownloadResponse struct { Contents io.ReadCloser `tfsdk:"-"` } @@ -471,6 +668,14 @@ func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Contents": types.ObjectType{}, + }, + } +} + // Get usage dashboard type GetBillingUsageDashboardRequest struct { // Workspace level usage dashboard shows usage data for the specified @@ -492,6 +697,15 @@ func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a GetBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardType": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type GetBillingUsageDashboardResponse struct { // The unique id of the usage dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` @@ -509,6 +723,15 @@ func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a GetBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "DashboardUrl": types.StringType, + }, + } +} + // Get budget type GetBudgetConfigurationRequest struct { // The budget configuration ID @@ -525,8 +748,16 @@ func (a GetBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BudgetId": types.StringType, + }, + } +} + type GetBudgetConfigurationResponse struct { - Budget types.Object `tfsdk:"budget" tf:"optional,object"` + Budget types.List `tfsdk:"budget" tf:"optional,object"` } func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetBudgetConfigurationResponse) { @@ -541,6 +772,14 @@ func (a GetBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflec } } +func (a GetBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Budget": BudgetConfiguration{}.ToAttrType(ctx), + }, + } +} + // Get log delivery configuration type GetLogDeliveryRequest struct { // Databricks log delivery configuration ID @@ -557,6 +796,14 @@ func (a GetLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LogDeliveryConfigurationId": types.StringType, + }, + } +} + // Get all budgets type ListBudgetConfigurationsRequest struct { // A page token received from a previous get all budget configurations call. @@ -575,6 +822,14 @@ func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a ListBudgetConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageToken": types.StringType, + }, + } +} + type ListBudgetConfigurationsResponse struct { Budgets types.List `tfsdk:"budgets" tf:"optional"` // Token which can be sent as `page_token` to retrieve the next page of @@ -594,6 +849,17 @@ func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes() map[string]refl } } +func (a ListBudgetConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Budgets": basetypes.ListType{ + ElemType: BudgetConfiguration{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // Get all log delivery configurations type ListLogDeliveryRequest struct { // Filter by credential configuration ID. @@ -614,6 +880,16 @@ func (a ListLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialsId": types.StringType, + "Status": types.StringType, + "StorageConfigurationId": types.StringType, + }, + } +} + type LogDeliveryConfiguration struct { // The Databricks account ID that hosts the log delivery configuration. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -642,7 +918,7 @@ type LogDeliveryConfiguration struct { // available for usage before March 2019 (`2019-03`). DeliveryStartTime types.String `tfsdk:"delivery_start_time" tf:"optional"` // Databricks log delivery status. - LogDeliveryStatus types.Object `tfsdk:"log_delivery_status" tf:"optional,object"` + LogDeliveryStatus types.List `tfsdk:"log_delivery_status" tf:"optional,object"` // Log delivery type. Supported values are: // // * `BILLABLE_USAGE` — Configure [billable usage log delivery]. For the @@ -707,7 +983,30 @@ func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existing func (a LogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "LogDeliveryStatus": reflect.TypeOf(LogDeliveryStatus{}), - "WorkspaceIdsFilter": reflect.TypeOf(0), + "WorkspaceIdsFilter": reflect.TypeOf(types.Int64Type), + } +} + +func (a LogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "ConfigId": types.StringType, + "ConfigName": types.StringType, + "CreationTime": types.Int64Type, + "CredentialsId": types.StringType, + "DeliveryPathPrefix": types.StringType, + "DeliveryStartTime": types.StringType, + "LogDeliveryStatus": LogDeliveryStatus{}.ToAttrType(ctx), + "LogType": types.StringType, + "OutputFormat": types.StringType, + "Status": types.StringType, + "StorageConfigurationId": types.StringType, + "UpdateTime": types.Int64Type, + "WorkspaceIdsFilter": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -744,6 +1043,17 @@ func (a LogDeliveryStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogDeliveryStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LastAttemptTime": types.StringType, + "LastSuccessfulAttemptTime": types.StringType, + "Message": types.StringType, + "Status": types.StringType, + }, + } +} + type PatchStatusResponse struct { } @@ -757,6 +1067,12 @@ func (a PatchStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PatchStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateBudgetConfigurationBudget struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -771,7 +1087,7 @@ type UpdateBudgetConfigurationBudget struct { // usage to limit the scope of what is considered for this budget. Leave // empty to include all usage for this account. All provided filters must be // matched for usage to be included. - Filter types.Object `tfsdk:"filter" tf:"optional,object"` + Filter types.List `tfsdk:"filter" tf:"optional,object"` } func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateBudgetConfigurationBudget) { @@ -787,10 +1103,24 @@ func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]refle } } +func (a UpdateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AlertConfigurations": basetypes.ListType{ + ElemType: AlertConfiguration{}.ToAttrType(ctx), + }, + "BudgetConfigurationId": types.StringType, + "DisplayName": types.StringType, + "Filter": BudgetConfigurationFilter{}.ToAttrType(ctx), + }, + } +} + type UpdateBudgetConfigurationRequest struct { // The updated budget. This will overwrite the budget specified by the // budget ID. - Budget types.Object `tfsdk:"budget" tf:"object"` + Budget types.List `tfsdk:"budget" tf:"object"` // The Databricks budget configuration ID. BudgetId types.String `tfsdk:"-"` } @@ -807,9 +1137,18 @@ func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]refl } } +func (a UpdateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Budget": UpdateBudgetConfigurationBudget{}.ToAttrType(ctx), + "BudgetId": types.StringType, + }, + } +} + type UpdateBudgetConfigurationResponse struct { // The updated budget. - Budget types.Object `tfsdk:"budget" tf:"optional,object"` + Budget types.List `tfsdk:"budget" tf:"optional,object"` } func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateBudgetConfigurationResponse) { @@ -824,6 +1163,14 @@ func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]ref } } +func (a UpdateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Budget": BudgetConfiguration{}.ToAttrType(ctx), + }, + } +} + type UpdateLogDeliveryConfigurationStatusRequest struct { // Databricks log delivery configuration ID LogDeliveryConfigurationId types.String `tfsdk:"-"` @@ -845,8 +1192,17 @@ func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes() map[ return map[string]reflect.Type{} } +func (a UpdateLogDeliveryConfigurationStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LogDeliveryConfigurationId": types.StringType, + "Status": types.StringType, + }, + } +} + type WrappedCreateLogDeliveryConfiguration struct { - LogDeliveryConfiguration types.Object `tfsdk:"log_delivery_configuration" tf:"optional,object"` + LogDeliveryConfiguration types.List `tfsdk:"log_delivery_configuration" tf:"optional,object"` } func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan WrappedCreateLogDeliveryConfiguration) { @@ -861,8 +1217,16 @@ func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes() map[string } } +func (a WrappedCreateLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LogDeliveryConfiguration": CreateLogDeliveryConfigurationParams{}.ToAttrType(ctx), + }, + } +} + type WrappedLogDeliveryConfiguration struct { - LogDeliveryConfiguration types.Object `tfsdk:"log_delivery_configuration" tf:"optional,object"` + LogDeliveryConfiguration types.List `tfsdk:"log_delivery_configuration" tf:"optional,object"` } func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan WrappedLogDeliveryConfiguration) { @@ -877,6 +1241,14 @@ func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes() map[string]refle } } +func (a WrappedLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LogDeliveryConfiguration": LogDeliveryConfiguration{}.ToAttrType(ctx), + }, + } +} + type WrappedLogDeliveryConfigurations struct { LogDeliveryConfigurations types.List `tfsdk:"log_delivery_configurations" tf:"optional"` } @@ -892,3 +1264,13 @@ func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes() map[string]refl "LogDeliveryConfigurations": reflect.TypeOf(LogDeliveryConfiguration{}), } } + +func (a WrappedLogDeliveryConfigurations) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LogDeliveryConfigurations": basetypes.ListType{ + ElemType: LogDeliveryConfiguration{}.ToAttrType(ctx), + }, + }, + } +} diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 365e84be7f..bab8cdbd86 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -11,13 +11,16 @@ We use go-native types for lists and maps intentionally for the ease for convert package catalog_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AccountsCreateMetastore struct { - MetastoreInfo types.Object `tfsdk:"metastore_info" tf:"optional,object"` + MetastoreInfo types.List `tfsdk:"metastore_info" tf:"optional,object"` } func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsCreateMetastore) { @@ -32,8 +35,16 @@ func (a AccountsCreateMetastore) GetComplexFieldTypes() map[string]reflect.Type } } +func (a AccountsCreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreInfo": CreateMetastore{}.ToAttrType(ctx), + }, + } +} + type AccountsCreateMetastoreAssignment struct { - MetastoreAssignment types.Object `tfsdk:"metastore_assignment" tf:"optional,object"` + MetastoreAssignment types.List `tfsdk:"metastore_assignment" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` // Workspace ID. @@ -52,8 +63,18 @@ func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes() map[string]ref } } +func (a AccountsCreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreAssignment": CreateMetastoreAssignment{}.ToAttrType(ctx), + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type AccountsCreateStorageCredential struct { - CredentialInfo types.Object `tfsdk:"credential_info" tf:"optional,object"` + CredentialInfo types.List `tfsdk:"credential_info" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` } @@ -70,8 +91,17 @@ func (a AccountsCreateStorageCredential) GetComplexFieldTypes() map[string]refle } } +func (a AccountsCreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialInfo": CreateStorageCredential{}.ToAttrType(ctx), + "MetastoreId": types.StringType, + }, + } +} + type AccountsMetastoreAssignment struct { - MetastoreAssignment types.Object `tfsdk:"metastore_assignment" tf:"optional,object"` + MetastoreAssignment types.List `tfsdk:"metastore_assignment" tf:"optional,object"` } func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsMetastoreAssignment) { @@ -86,8 +116,16 @@ func (a AccountsMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.T } } +func (a AccountsMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreAssignment": MetastoreAssignment{}.ToAttrType(ctx), + }, + } +} + type AccountsMetastoreInfo struct { - MetastoreInfo types.Object `tfsdk:"metastore_info" tf:"optional,object"` + MetastoreInfo types.List `tfsdk:"metastore_info" tf:"optional,object"` } func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsMetastoreInfo) { @@ -102,8 +140,16 @@ func (a AccountsMetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AccountsMetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreInfo": MetastoreInfo{}.ToAttrType(ctx), + }, + } +} + type AccountsStorageCredentialInfo struct { - CredentialInfo types.Object `tfsdk:"credential_info" tf:"optional,object"` + CredentialInfo types.List `tfsdk:"credential_info" tf:"optional,object"` } func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsStorageCredentialInfo) { @@ -118,11 +164,19 @@ func (a AccountsStorageCredentialInfo) GetComplexFieldTypes() map[string]reflect } } +func (a AccountsStorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialInfo": StorageCredentialInfo{}.ToAttrType(ctx), + }, + } +} + type AccountsUpdateMetastore struct { // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` - MetastoreInfo types.Object `tfsdk:"metastore_info" tf:"optional,object"` + MetastoreInfo types.List `tfsdk:"metastore_info" tf:"optional,object"` } func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan AccountsUpdateMetastore) { @@ -137,8 +191,17 @@ func (a AccountsUpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type } } +func (a AccountsUpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + "MetastoreInfo": UpdateMetastore{}.ToAttrType(ctx), + }, + } +} + type AccountsUpdateMetastoreAssignment struct { - MetastoreAssignment types.Object `tfsdk:"metastore_assignment" tf:"optional,object"` + MetastoreAssignment types.List `tfsdk:"metastore_assignment" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` // Workspace ID. @@ -157,8 +220,18 @@ func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes() map[string]ref } } +func (a AccountsUpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreAssignment": UpdateMetastoreAssignment{}.ToAttrType(ctx), + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type AccountsUpdateStorageCredential struct { - CredentialInfo types.Object `tfsdk:"credential_info" tf:"optional,object"` + CredentialInfo types.List `tfsdk:"credential_info" tf:"optional,object"` // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` // Name of the storage credential. @@ -177,6 +250,16 @@ func (a AccountsUpdateStorageCredential) GetComplexFieldTypes() map[string]refle } } +func (a AccountsUpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialInfo": UpdateStorageCredential{}.ToAttrType(ctx), + "MetastoreId": types.StringType, + "StorageCredentialName": types.StringType, + }, + } +} + type ArtifactAllowlistInfo struct { // A list of allowed artifact match patterns. ArtifactMatchers types.List `tfsdk:"artifact_matchers" tf:"optional"` @@ -200,6 +283,19 @@ func (a ArtifactAllowlistInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ArtifactAllowlistInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactMatchers": basetypes.ListType{ + ElemType: ArtifactMatcher{}.ToAttrType(ctx), + }, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "MetastoreId": types.StringType, + }, + } +} + type ArtifactMatcher struct { // The artifact path or maven coordinate Artifact types.String `tfsdk:"artifact" tf:""` @@ -217,6 +313,15 @@ func (a ArtifactMatcher) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ArtifactMatcher) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Artifact": types.StringType, + "MatchType": types.StringType, + }, + } +} + type AssignResponse struct { } @@ -230,6 +335,12 @@ func (a AssignResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AssignResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // AWS temporary credentials for API authentication. Read more at // https://docs.aws.amazon.com/STS/latest/APIReference/API_Credentials.html. type AwsCredentials struct { @@ -255,6 +366,17 @@ func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessKeyId": types.StringType, + "AccessPoint": types.StringType, + "SecretAccessKey": types.StringType, + "SessionToken": types.StringType, + }, + } +} + // The AWS IAM role configuration type AwsIamRole struct { // The external ID used in role assumption to prevent the confused deputy @@ -278,6 +400,16 @@ func (a AwsIamRole) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AwsIamRole) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExternalId": types.StringType, + "RoleArn": types.StringType, + "UnityCatalogIamArn": types.StringType, + }, + } +} + type AwsIamRoleRequest struct { // The Amazon Resource Name (ARN) of the AWS IAM role for S3 data access. RoleArn types.String `tfsdk:"role_arn" tf:""` @@ -293,6 +425,14 @@ func (a AwsIamRoleRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AwsIamRoleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RoleArn": types.StringType, + }, + } +} + type AwsIamRoleResponse struct { // The external ID used in role assumption to prevent confused deputy // problem.. @@ -314,6 +454,16 @@ func (a AwsIamRoleResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AwsIamRoleResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExternalId": types.StringType, + "RoleArn": types.StringType, + "UnityCatalogIamArn": types.StringType, + }, + } +} + // Azure Active Directory token, essentially the Oauth token for Azure Service // Principal or Managed Identity. Read more at // https://learn.microsoft.com/en-us/azure/databricks/dev-tools/api/latest/aad/service-prin-aad-token @@ -333,6 +483,14 @@ func (a AzureActiveDirectoryToken) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a AzureActiveDirectoryToken) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AadToken": types.StringType, + }, + } +} + // The Azure managed identity configuration. type AzureManagedIdentity struct { // The Azure resource ID of the Azure Databricks Access Connector. Use the @@ -363,6 +521,16 @@ func (a AzureManagedIdentity) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AzureManagedIdentity) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessConnectorId": types.StringType, + "CredentialId": types.StringType, + "ManagedIdentityId": types.StringType, + }, + } +} + type AzureManagedIdentityRequest struct { // The Azure resource ID of the Azure Databricks Access Connector. Use the // format @@ -387,6 +555,15 @@ func (a AzureManagedIdentityRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a AzureManagedIdentityRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessConnectorId": types.StringType, + "ManagedIdentityId": types.StringType, + }, + } +} + type AzureManagedIdentityResponse struct { // The Azure resource ID of the Azure Databricks Access Connector. Use the // format @@ -413,6 +590,16 @@ func (a AzureManagedIdentityResponse) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a AzureManagedIdentityResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessConnectorId": types.StringType, + "CredentialId": types.StringType, + "ManagedIdentityId": types.StringType, + }, + } +} + // The Azure service principal configuration. type AzureServicePrincipal struct { // The application ID of the application registration within the referenced @@ -435,6 +622,16 @@ func (a AzureServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AzureServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplicationId": types.StringType, + "ClientSecret": types.StringType, + "DirectoryId": types.StringType, + }, + } +} + // Azure temporary credentials for API authentication. Read more at // https://docs.microsoft.com/en-us/rest/api/storageservices/create-user-delegation-sas type AzureUserDelegationSas struct { @@ -452,6 +649,14 @@ func (a AzureUserDelegationSas) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AzureUserDelegationSas) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "SasToken": types.StringType, + }, + } +} + // Cancel refresh type CancelRefreshRequest struct { // ID of the refresh. @@ -470,6 +675,15 @@ func (a CancelRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RefreshId": types.StringType, + "TableName": types.StringType, + }, + } +} + type CancelRefreshResponse struct { } @@ -483,6 +697,12 @@ func (a CancelRefreshResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelRefreshResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type CatalogInfo struct { // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is @@ -499,7 +719,7 @@ type CatalogInfo struct { // Username of catalog creator. CreatedBy types.String `tfsdk:"created_by" tf:"optional"` - EffectivePredictiveOptimizationFlag types.Object `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` + EffectivePredictiveOptimizationFlag types.List `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` // Whether predictive optimization should be enabled for this object and // objects under it. EnablePredictiveOptimization types.String `tfsdk:"enable_predictive_optimization" tf:"optional"` @@ -524,7 +744,7 @@ type CatalogInfo struct { // remote sharing server. ProviderName types.String `tfsdk:"provider_name" tf:"optional"` // Status of an asynchronously provisioned resource. - ProvisioningInfo types.Object `tfsdk:"provisioning_info" tf:"optional,object"` + ProvisioningInfo types.List `tfsdk:"provisioning_info" tf:"optional,object"` // Kind of catalog securable. SecurableKind types.String `tfsdk:"securable_kind" tf:"optional"` @@ -550,12 +770,47 @@ func (newState *CatalogInfo) SyncEffectiveFieldsDuringRead(existingState Catalog func (a CatalogInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "Options": reflect.TypeOf(""), - "Properties": reflect.TypeOf(""), + "Options": reflect.TypeOf(types.StringType), + "Properties": reflect.TypeOf(types.StringType), "ProvisioningInfo": reflect.TypeOf(ProvisioningInfo{}), } } +func (a CatalogInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BrowseOnly": types.BoolType, + "CatalogType": types.StringType, + "Comment": types.StringType, + "ConnectionName": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "EffectivePredictiveOptimizationFlag": EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + "EnablePredictiveOptimization": types.StringType, + "FullName": types.StringType, + "IsolationMode": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Options": basetypes.MapType{ + ElemType: types.StringType, + }, + "Owner": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "ProviderName": types.StringType, + "ProvisioningInfo": ProvisioningInfo{}.ToAttrType(ctx), + "SecurableKind": types.StringType, + "SecurableType": types.StringType, + "ShareName": types.StringType, + "StorageLocation": types.StringType, + "StorageRoot": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type CloudflareApiToken struct { // The Cloudflare access key id of the token. AccessKeyId types.String `tfsdk:"access_key_id" tf:""` @@ -575,11 +830,21 @@ func (a CloudflareApiToken) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CloudflareApiToken) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessKeyId": types.StringType, + "AccountId": types.StringType, + "SecretAccessKey": types.StringType, + }, + } +} + type ColumnInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` - Mask types.Object `tfsdk:"mask" tf:"optional,object"` + Mask types.List `tfsdk:"mask" tf:"optional,object"` // Name of Column. Name types.String `tfsdk:"name" tf:"optional"` // Whether field may be Null (default: true). @@ -614,6 +879,25 @@ func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Mask": ColumnMask{}.ToAttrType(ctx), + "Name": types.StringType, + "Nullable": types.BoolType, + "PartitionIndex": types.Int64Type, + "Position": types.Int64Type, + "TypeIntervalType": types.StringType, + "TypeJson": types.StringType, + "TypeName": types.StringType, + "TypePrecision": types.Int64Type, + "TypeScale": types.Int64Type, + "TypeText": types.StringType, + }, + } +} + type ColumnMask struct { // The full name of the column mask SQL UDF. FunctionName types.String `tfsdk:"function_name" tf:"optional"` @@ -632,7 +916,18 @@ func (newState *ColumnMask) SyncEffectiveFieldsDuringRead(existingState ColumnMa func (a ColumnMask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "UsingColumnNames": reflect.TypeOf(""), + "UsingColumnNames": reflect.TypeOf(types.StringType), + } +} + +func (a ColumnMask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FunctionName": types.StringType, + "UsingColumnNames": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -663,7 +958,7 @@ type ConnectionInfo struct { // connection. Properties types.Map `tfsdk:"properties" tf:"optional"` // Status of an asynchronously provisioned resource. - ProvisioningInfo types.Object `tfsdk:"provisioning_info" tf:"optional,object"` + ProvisioningInfo types.List `tfsdk:"provisioning_info" tf:"optional,object"` // If the connection is read only. ReadOnly types.Bool `tfsdk:"read_only" tf:"optional"` // Kind of connection securable. @@ -686,17 +981,47 @@ func (newState *ConnectionInfo) SyncEffectiveFieldsDuringRead(existingState Conn func (a ConnectionInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(""), - "Properties": reflect.TypeOf(""), + "Options": reflect.TypeOf(types.StringType), + "Properties": reflect.TypeOf(types.StringType), "ProvisioningInfo": reflect.TypeOf(ProvisioningInfo{}), } } +func (a ConnectionInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "ConnectionId": types.StringType, + "ConnectionType": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "CredentialType": types.StringType, + "FullName": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Options": basetypes.MapType{ + ElemType: types.StringType, + }, + "Owner": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "ProvisioningInfo": ProvisioningInfo{}.ToAttrType(ctx), + "ReadOnly": types.BoolType, + "SecurableKind": types.StringType, + "SecurableType": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "Url": types.StringType, + }, + } +} + // Detailed status of an online table. Shown if the online table is in the // ONLINE_CONTINUOUS_UPDATE or the ONLINE_UPDATING_PIPELINE_RESOURCES state. type ContinuousUpdateStatus struct { // Progress of the initial data synchronization. - InitialPipelineSyncProgress types.Object `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` + InitialPipelineSyncProgress types.List `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` // The last source table Delta version that was synced to the online table. // Note that this Delta version may not be completely synced to the online // table yet. @@ -718,6 +1043,16 @@ func (a ContinuousUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ContinuousUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InitialPipelineSyncProgress": PipelineProgress{}.ToAttrType(ctx), + "LastProcessedCommitVersion": types.Int64Type, + "Timestamp": types.StringType, + }, + } +} + type CreateCatalog struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -748,8 +1083,27 @@ func (newState *CreateCatalog) SyncEffectiveFieldsDuringRead(existingState Creat func (a CreateCatalog) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(""), - "Properties": reflect.TypeOf(""), + "Options": reflect.TypeOf(types.StringType), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a CreateCatalog) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "ConnectionName": types.StringType, + "Name": types.StringType, + "Options": basetypes.MapType{ + ElemType: types.StringType, + }, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "ProviderName": types.StringType, + "ShareName": types.StringType, + "StorageRoot": types.StringType, + }, } } @@ -777,23 +1131,40 @@ func (newState *CreateConnection) SyncEffectiveFieldsDuringRead(existingState Cr func (a CreateConnection) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(""), - "Properties": reflect.TypeOf(""), + "Options": reflect.TypeOf(types.StringType), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a CreateConnection) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "ConnectionType": types.StringType, + "Name": types.StringType, + "Options": basetypes.MapType{ + ElemType: types.StringType, + }, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "ReadOnly": types.BoolType, + }, } } type CreateCredentialRequest struct { // The AWS IAM role configuration - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // TODO(UC-978): Document GCP service account key usage for service // credentials. - GcpServiceAccountKey types.Object `tfsdk:"gcp_service_account_key" tf:"optional,object"` + GcpServiceAccountKey types.List `tfsdk:"gcp_service_account_key" tf:"optional,object"` // The credential name. The name must be unique among storage and service // credentials within the metastore. Name types.String `tfsdk:"name" tf:""` @@ -822,6 +1193,22 @@ func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "Comment": types.StringType, + "GcpServiceAccountKey": GcpServiceAccountKey{}.ToAttrType(ctx), + "Name": types.StringType, + "Purpose": types.StringType, + "ReadOnly": types.BoolType, + "SkipValidation": types.BoolType, + }, + } +} + type CreateExternalLocation struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -830,7 +1217,7 @@ type CreateExternalLocation struct { // Name of the storage credential used with this location. CredentialName types.String `tfsdk:"credential_name" tf:""` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.List `tfsdk:"encryption_details" tf:"optional,object"` // Indicates whether fallback mode is enabled for this external location. // When fallback mode is enabled, the access to the location falls back to // cluster credentials if UC credentials are not sufficient. @@ -858,6 +1245,22 @@ func (a CreateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessPoint": types.StringType, + "Comment": types.StringType, + "CredentialName": types.StringType, + "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), + "Fallback": types.BoolType, + "Name": types.StringType, + "ReadOnly": types.BoolType, + "SkipValidation": types.BoolType, + "Url": types.StringType, + }, + } +} + type CreateFunction struct { // Name of parent catalog. CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -872,7 +1275,7 @@ type CreateFunction struct { // Pretty printed function data type. FullDataType types.String `tfsdk:"full_data_type" tf:""` - InputParams types.Object `tfsdk:"input_params" tf:"object"` + InputParams types.List `tfsdk:"input_params" tf:"object"` // Whether the function is deterministic. IsDeterministic types.Bool `tfsdk:"is_deterministic" tf:""` // Function null call. @@ -884,7 +1287,7 @@ type CreateFunction struct { // JSON-serialized key-value pair map, encoded (escaped) as a string. Properties types.String `tfsdk:"properties" tf:"optional"` // Table function return parameters. - ReturnParams types.Object `tfsdk:"return_params" tf:"optional,object"` + ReturnParams types.List `tfsdk:"return_params" tf:"optional,object"` // Function language. When **EXTERNAL** is used, the language of the routine // function should be specified in the __external_language__ field, and the // __return_params__ of the function cannot be used (as **TABLE** return @@ -894,7 +1297,7 @@ type CreateFunction struct { // Function body. RoutineDefinition types.String `tfsdk:"routine_definition" tf:""` // Function dependencies. - RoutineDependencies types.Object `tfsdk:"routine_dependencies" tf:"optional,object"` + RoutineDependencies types.List `tfsdk:"routine_dependencies" tf:"optional,object"` // Name of parent schema relative to its parent catalog. SchemaName types.String `tfsdk:"schema_name" tf:""` // Function security type. @@ -921,9 +1324,37 @@ func (a CreateFunction) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateFunction) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Comment": types.StringType, + "DataType": types.StringType, + "ExternalLanguage": types.StringType, + "ExternalName": types.StringType, + "FullDataType": types.StringType, + "InputParams": FunctionParameterInfos{}.ToAttrType(ctx), + "IsDeterministic": types.BoolType, + "IsNullCall": types.BoolType, + "Name": types.StringType, + "ParameterStyle": types.StringType, + "Properties": types.StringType, + "ReturnParams": FunctionParameterInfos{}.ToAttrType(ctx), + "RoutineBody": types.StringType, + "RoutineDefinition": types.StringType, + "RoutineDependencies": DependencyList{}.ToAttrType(ctx), + "SchemaName": types.StringType, + "SecurityType": types.StringType, + "SpecificName": types.StringType, + "SqlDataAccess": types.StringType, + "SqlPath": types.StringType, + }, + } +} + type CreateFunctionRequest struct { // Partial __FunctionInfo__ specifying the function to be created. - FunctionInfo types.Object `tfsdk:"function_info" tf:"object"` + FunctionInfo types.List `tfsdk:"function_info" tf:"object"` } func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateFunctionRequest) { @@ -938,6 +1369,14 @@ func (a CreateFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FunctionInfo": CreateFunction{}.ToAttrType(ctx), + }, + } +} + type CreateMetastore struct { // The user-specified name of the metastore. Name types.String `tfsdk:"name" tf:""` @@ -960,6 +1399,16 @@ func (a CreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Region": types.StringType, + "StorageRoot": types.StringType, + }, + } +} + type CreateMetastoreAssignment struct { // The name of the default catalog in the metastore. This field is // depracted. Please use "Default Namespace API" to configure the default @@ -981,6 +1430,16 @@ func (a CreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a CreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DefaultCatalogName": types.StringType, + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type CreateMonitor struct { // The directory to store monitoring assets (e.g. dashboard, metric tables). AssetsDir types.String `tfsdk:"assets_dir" tf:""` @@ -993,15 +1452,15 @@ type CreateMonitor struct { // drift metrics (comparing metrics across time windows). CustomMetrics types.List `tfsdk:"custom_metrics" tf:"optional"` // The data classification config for the monitor. - DataClassificationConfig types.Object `tfsdk:"data_classification_config" tf:"optional,object"` + DataClassificationConfig types.List `tfsdk:"data_classification_config" tf:"optional,object"` // Configuration for monitoring inference logs. - InferenceLog types.Object `tfsdk:"inference_log" tf:"optional,object"` + InferenceLog types.List `tfsdk:"inference_log" tf:"optional,object"` // The notification settings for the monitor. - Notifications types.Object `tfsdk:"notifications" tf:"optional,object"` + Notifications types.List `tfsdk:"notifications" tf:"optional,object"` // Schema where output metric tables are created. OutputSchemaName types.String `tfsdk:"output_schema_name" tf:""` // The schedule for automatically updating and refreshing metric tables. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // Whether to skip creating a default dashboard summarizing data quality // metrics. SkipBuiltinDashboard types.Bool `tfsdk:"skip_builtin_dashboard" tf:"optional"` @@ -1016,7 +1475,7 @@ type CreateMonitor struct { // Full name of the table. TableName types.String `tfsdk:"-"` // Configuration for monitoring time series tables. - TimeSeries types.Object `tfsdk:"time_series" tf:"optional,object"` + TimeSeries types.List `tfsdk:"time_series" tf:"optional,object"` // Optional argument to specify the warehouse for dashboard creation. If not // specified, the first running warehouse will be used. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` @@ -1035,16 +1494,41 @@ func (a CreateMonitor) GetComplexFieldTypes() map[string]reflect.Type { "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), "Notifications": reflect.TypeOf(MonitorNotifications{}), "Schedule": reflect.TypeOf(MonitorCronSchedule{}), - "SlicingExprs": reflect.TypeOf(""), + "SlicingExprs": reflect.TypeOf(types.StringType), "Snapshot": reflect.TypeOf(MonitorSnapshot{}), "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), } } +func (a CreateMonitor) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AssetsDir": types.StringType, + "BaselineTableName": types.StringType, + "CustomMetrics": basetypes.ListType{ + ElemType: MonitorMetric{}.ToAttrType(ctx), + }, + "DataClassificationConfig": MonitorDataClassificationConfig{}.ToAttrType(ctx), + "InferenceLog": MonitorInferenceLog{}.ToAttrType(ctx), + "Notifications": MonitorNotifications{}.ToAttrType(ctx), + "OutputSchemaName": types.StringType, + "Schedule": MonitorCronSchedule{}.ToAttrType(ctx), + "SkipBuiltinDashboard": types.BoolType, + "SlicingExprs": basetypes.ListType{ + ElemType: types.StringType, + }, + "Snapshot": MonitorSnapshot{}.ToAttrType(ctx), + "TableName": types.StringType, + "TimeSeries": MonitorTimeSeries{}.ToAttrType(ctx), + "WarehouseId": types.StringType, + }, + } +} + // Create an Online Table type CreateOnlineTableRequest struct { // Online Table information. - Table types.Object `tfsdk:"table" tf:"optional,object"` + Table types.List `tfsdk:"table" tf:"optional,object"` } func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateOnlineTableRequest) { @@ -1059,6 +1543,14 @@ func (a CreateOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Table": OnlineTable{}.ToAttrType(ctx), + }, + } +} + type CreateRegisteredModelRequest struct { // The name of the catalog where the schema and the registered model reside CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -1083,6 +1575,18 @@ func (a CreateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a CreateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Comment": types.StringType, + "Name": types.StringType, + "SchemaName": types.StringType, + "StorageLocation": types.StringType, + }, + } +} + type CreateResponse struct { } @@ -1096,6 +1600,12 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type CreateSchema struct { // Name of parent catalog. CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -1117,19 +1627,33 @@ func (newState *CreateSchema) SyncEffectiveFieldsDuringRead(existingState Create func (a CreateSchema) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(""), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a CreateSchema) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Comment": types.StringType, + "Name": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "StorageRoot": types.StringType, + }, } } type CreateStorageCredential struct { // The AWS IAM role configuration. - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.List `tfsdk:"cloudflare_api_token" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // The Databricks managed GCP service account configuration. @@ -1159,11 +1683,27 @@ func (a CreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRoleRequest{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentityRequest{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), + "Comment": types.StringType, + "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + "Name": types.StringType, + "ReadOnly": types.BoolType, + "SkipValidation": types.BoolType, + }, + } +} + type CreateTableConstraint struct { // A table constraint, as defined by *one* of the following fields being // set: __primary_key_constraint__, __foreign_key_constraint__, // __named_table_constraint__. - Constraint types.Object `tfsdk:"constraint" tf:"object"` + Constraint types.List `tfsdk:"constraint" tf:"object"` // The full name of the table referenced by the constraint. FullNameArg types.String `tfsdk:"full_name_arg" tf:""` } @@ -1180,6 +1720,15 @@ func (a CreateTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Constraint": TableConstraint{}.ToAttrType(ctx), + "FullNameArg": types.StringType, + }, + } +} + type CreateVolumeRequestContent struct { // The name of the catalog where the schema and the volume are CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -1205,13 +1754,26 @@ func (a CreateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a CreateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Comment": types.StringType, + "Name": types.StringType, + "SchemaName": types.StringType, + "StorageLocation": types.StringType, + "VolumeType": types.StringType, + }, + } +} + type CredentialInfo struct { // The AWS IAM role configuration - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // Time at which this credential was created, in epoch milliseconds. @@ -1260,6 +1822,30 @@ func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "FullName": types.StringType, + "Id": types.StringType, + "IsolationMode": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "Purpose": types.StringType, + "ReadOnly": types.BoolType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "UsedForManagedStorage": types.BoolType, + }, + } +} + type CredentialValidationResult struct { // Error message would exist when the result does not equal to **PASS**. Message types.String `tfsdk:"message" tf:"optional"` @@ -1277,6 +1863,15 @@ func (a CredentialValidationResult) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a CredentialValidationResult) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + "Result": types.StringType, + }, + } +} + // Currently assigned workspaces type CurrentWorkspaceBindings struct { // A list of workspace IDs. @@ -1291,7 +1886,17 @@ func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringRead(existing func (a CurrentWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Workspaces": reflect.TypeOf(0), + "Workspaces": reflect.TypeOf(types.Int64Type), + } +} + +func (a CurrentWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Workspaces": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -1308,6 +1913,12 @@ func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a DatabricksGcpServiceAccountRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DatabricksGcpServiceAccountResponse struct { // The Databricks internal ID that represents this service account. This is // an output-only field. @@ -1326,6 +1937,15 @@ func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a DatabricksGcpServiceAccountResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.StringType, + "Email": types.StringType, + }, + } +} + // Delete a metastore assignment type DeleteAccountMetastoreAssignmentRequest struct { // Unity Catalog metastore ID @@ -1344,6 +1964,15 @@ func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a DeleteAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + // Delete a metastore type DeleteAccountMetastoreRequest struct { // Force deletion even if the metastore is not empty. Default is false. @@ -1362,6 +1991,15 @@ func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a DeleteAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "MetastoreId": types.StringType, + }, + } +} + // Delete a storage credential type DeleteAccountStorageCredentialRequest struct { // Force deletion even if the Storage Credential is not empty. Default is @@ -1383,6 +2021,16 @@ func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a DeleteAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "MetastoreId": types.StringType, + "StorageCredentialName": types.StringType, + }, + } +} + // Delete a Registered Model Alias type DeleteAliasRequest struct { // The name of the alias @@ -1401,6 +2049,15 @@ func (a DeleteAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alias": types.StringType, + "FullName": types.StringType, + }, + } +} + type DeleteAliasResponse struct { } @@ -1414,6 +2071,12 @@ func (a DeleteAliasResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteAliasResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a catalog type DeleteCatalogRequest struct { // Force deletion even if the catalog is not empty. @@ -1432,6 +2095,15 @@ func (a DeleteCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "Name": types.StringType, + }, + } +} + // Delete a connection type DeleteConnectionRequest struct { // The name of the connection to be deleted. @@ -1448,6 +2120,14 @@ func (a DeleteConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Delete a credential type DeleteCredentialRequest struct { // Force an update even if there are dependent services (when purpose is @@ -1468,6 +2148,15 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "NameArg": types.StringType, + }, + } +} + type DeleteCredentialResponse struct { } @@ -1481,6 +2170,12 @@ func (a DeleteCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete an external location type DeleteExternalLocationRequest struct { // Force deletion even if there are dependent external tables or mounts. @@ -1499,6 +2194,15 @@ func (a DeleteExternalLocationRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a DeleteExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "Name": types.StringType, + }, + } +} + // Delete a function type DeleteFunctionRequest struct { // Force deletion even if the function is notempty. @@ -1518,6 +2222,15 @@ func (a DeleteFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "Name": types.StringType, + }, + } +} + // Delete a metastore type DeleteMetastoreRequest struct { // Force deletion even if the metastore is not empty. Default is false. @@ -1536,6 +2249,15 @@ func (a DeleteMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "Id": types.StringType, + }, + } +} + // Delete a Model Version type DeleteModelVersionRequest struct { // The three-level (fully qualified) name of the model version @@ -1554,6 +2276,15 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "Version": types.Int64Type, + }, + } +} + // Delete an Online Table type DeleteOnlineTableRequest struct { // Full three-part (catalog, schema, table) name of the table. @@ -1570,6 +2301,14 @@ func (a DeleteOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Delete a table monitor type DeleteQualityMonitorRequest struct { // Full name of the table. @@ -1586,6 +2325,14 @@ func (a DeleteQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a DeleteQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableName": types.StringType, + }, + } +} + // Delete a Registered Model type DeleteRegisteredModelRequest struct { // The three-level (fully qualified) name of the registered model @@ -1602,6 +2349,14 @@ func (a DeleteRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -1615,6 +2370,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a schema type DeleteSchemaRequest struct { // Force deletion even if the schema is not empty. @@ -1633,6 +2394,15 @@ func (a DeleteSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "FullName": types.StringType, + }, + } +} + // Delete a credential type DeleteStorageCredentialRequest struct { // Force deletion even if there are dependent external locations or external @@ -1652,6 +2422,15 @@ func (a DeleteStorageCredentialRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a DeleteStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Force": types.BoolType, + "Name": types.StringType, + }, + } +} + // Delete a table constraint type DeleteTableConstraintRequest struct { // If true, try deleting all child constraints of the current constraint. If @@ -1674,6 +2453,16 @@ func (a DeleteTableConstraintRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteTableConstraintRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cascade": types.BoolType, + "ConstraintName": types.StringType, + "FullName": types.StringType, + }, + } +} + // Delete a table type DeleteTableRequest struct { // Full name of the table. @@ -1690,6 +2479,14 @@ func (a DeleteTableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteTableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + }, + } +} + // Delete a Volume type DeleteVolumeRequest struct { // The three-level (fully qualified) name of the volume @@ -1706,6 +2503,14 @@ func (a DeleteVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Properties pertaining to the current state of the delta table as given by the // commit server. This does not contain **delta.*** (input) properties in // __TableInfo.properties__. @@ -1722,7 +2527,17 @@ func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringRead(exi func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DeltaRuntimeProperties": reflect.TypeOf(""), + "DeltaRuntimeProperties": reflect.TypeOf(types.StringType), + } +} + +func (a DeltaRuntimePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DeltaRuntimeProperties": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -1730,9 +2545,9 @@ func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect // field must be defined. type Dependency struct { // A function that is dependent on a SQL object. - Function types.Object `tfsdk:"function" tf:"optional,object"` + Function types.List `tfsdk:"function" tf:"optional,object"` // A table that is dependent on a SQL object. - Table types.Object `tfsdk:"table" tf:"optional,object"` + Table types.List `tfsdk:"table" tf:"optional,object"` } func (newState *Dependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dependency) { @@ -1748,6 +2563,15 @@ func (a Dependency) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Dependency) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Function": FunctionDependency{}.ToAttrType(ctx), + "Table": TableDependency{}.ToAttrType(ctx), + }, + } +} + // A list of dependencies. type DependencyList struct { // Array of dependencies. @@ -1766,6 +2590,16 @@ func (a DependencyList) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DependencyList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Dependencies": basetypes.ListType{ + ElemType: Dependency{}.ToAttrType(ctx), + }, + }, + } +} + // Disable a system schema type DisableRequest struct { // The metastore ID under which the system schema lives. @@ -1784,6 +2618,15 @@ func (a DisableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DisableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + "SchemaName": types.StringType, + }, + } +} + type DisableResponse struct { } @@ -1797,6 +2640,12 @@ func (a DisableResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DisableResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EffectivePermissionsList struct { // The privileges conveyed to each principal (either directly or via // inheritance) @@ -1815,6 +2664,16 @@ func (a EffectivePermissionsList) GetComplexFieldTypes() map[string]reflect.Type } } +func (a EffectivePermissionsList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrivilegeAssignments": basetypes.ListType{ + ElemType: EffectivePrivilegeAssignment{}.ToAttrType(ctx), + }, + }, + } +} + type EffectivePredictiveOptimizationFlag struct { // The name of the object from which the flag was inherited. If there was no // inheritance, this field is left blank. @@ -1837,6 +2696,16 @@ func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a EffectivePredictiveOptimizationFlag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InheritedFromName": types.StringType, + "InheritedFromType": types.StringType, + "Value": types.StringType, + }, + } +} + type EffectivePrivilege struct { // The full name of the object that conveys this privilege via inheritance. // This field is omitted when privilege is not inherited (it's assigned to @@ -1860,6 +2729,16 @@ func (a EffectivePrivilege) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EffectivePrivilege) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InheritedFromName": types.StringType, + "InheritedFromType": types.StringType, + "Privilege": types.StringType, + }, + } +} + type EffectivePrivilegeAssignment struct { // The principal (user email address or group name). Principal types.String `tfsdk:"principal" tf:"optional"` @@ -1880,6 +2759,17 @@ func (a EffectivePrivilegeAssignment) GetComplexFieldTypes() map[string]reflect. } } +func (a EffectivePrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Principal": types.StringType, + "Privileges": basetypes.ListType{ + ElemType: EffectivePrivilege{}.ToAttrType(ctx), + }, + }, + } +} + // Enable a system schema type EnableRequest struct { // The metastore ID under which the system schema lives. @@ -1898,6 +2788,15 @@ func (a EnableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EnableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + "SchemaName": types.StringType, + }, + } +} + type EnableResponse struct { } @@ -1911,10 +2810,16 @@ func (a EnableResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EnableResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Encryption options that apply to clients connecting to cloud storage. type EncryptionDetails struct { // Server-Side Encryption properties for clients communicating with AWS s3. - SseEncryptionDetails types.Object `tfsdk:"sse_encryption_details" tf:"optional,object"` + SseEncryptionDetails types.List `tfsdk:"sse_encryption_details" tf:"optional,object"` } func (newState *EncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan EncryptionDetails) { @@ -1929,6 +2834,14 @@ func (a EncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "SseEncryptionDetails": SseEncryptionDetails{}.ToAttrType(ctx), + }, + } +} + // Get boolean reflecting if table exists type ExistsRequest struct { // Full name of the table. @@ -1945,6 +2858,14 @@ func (a ExistsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExistsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + }, + } +} + type ExternalLocationInfo struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -1963,7 +2884,7 @@ type ExternalLocationInfo struct { // Name of the storage credential used with this location. CredentialName types.String `tfsdk:"credential_name" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.List `tfsdk:"encryption_details" tf:"optional,object"` // Indicates whether fallback mode is enabled for this external location. // When fallback mode is enabled, the access to the location falls back to // cluster credentials if UC credentials are not sufficient. @@ -1999,6 +2920,30 @@ func (a ExternalLocationInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ExternalLocationInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessPoint": types.StringType, + "BrowseOnly": types.BoolType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "CredentialId": types.StringType, + "CredentialName": types.StringType, + "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), + "Fallback": types.BoolType, + "IsolationMode": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "ReadOnly": types.BoolType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "Url": types.StringType, + }, + } +} + // Detailed status of an online table. Shown if the online table is in the // OFFLINE_FAILED or the ONLINE_PIPELINE_FAILED state. type FailedStatus struct { @@ -2023,6 +2968,15 @@ func (a FailedStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FailedStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LastProcessedCommitVersion": types.Int64Type, + "Timestamp": types.StringType, + }, + } +} + type ForeignKeyConstraint struct { // Column names for this constraint. ChildColumns types.List `tfsdk:"child_columns" tf:""` @@ -2042,8 +2996,23 @@ func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringRead(existingStat func (a ForeignKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ChildColumns": reflect.TypeOf(""), - "ParentColumns": reflect.TypeOf(""), + "ChildColumns": reflect.TypeOf(types.StringType), + "ParentColumns": reflect.TypeOf(types.StringType), + } +} + +func (a ForeignKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ChildColumns": basetypes.ListType{ + ElemType: types.StringType, + }, + "Name": types.StringType, + "ParentColumns": basetypes.ListType{ + ElemType: types.StringType, + }, + "ParentTable": types.StringType, + }, } } @@ -2064,6 +3033,14 @@ func (a FunctionDependency) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FunctionDependency) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FunctionFullName": types.StringType, + }, + } +} + type FunctionInfo struct { // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is @@ -2091,7 +3068,7 @@ type FunctionInfo struct { // Id of Function, relative to parent schema. FunctionId types.String `tfsdk:"function_id" tf:"optional"` - InputParams types.Object `tfsdk:"input_params" tf:"optional,object"` + InputParams types.List `tfsdk:"input_params" tf:"optional,object"` // Whether the function is deterministic. IsDeterministic types.Bool `tfsdk:"is_deterministic" tf:"optional"` // Function null call. @@ -2107,7 +3084,7 @@ type FunctionInfo struct { // JSON-serialized key-value pair map, encoded (escaped) as a string. Properties types.String `tfsdk:"properties" tf:"optional"` // Table function return parameters. - ReturnParams types.Object `tfsdk:"return_params" tf:"optional,object"` + ReturnParams types.List `tfsdk:"return_params" tf:"optional,object"` // Function language. When **EXTERNAL** is used, the language of the routine // function should be specified in the __external_language__ field, and the // __return_params__ of the function cannot be used (as **TABLE** return @@ -2117,7 +3094,7 @@ type FunctionInfo struct { // Function body. RoutineDefinition types.String `tfsdk:"routine_definition" tf:"optional"` // Function dependencies. - RoutineDependencies types.Object `tfsdk:"routine_dependencies" tf:"optional,object"` + RoutineDependencies types.List `tfsdk:"routine_dependencies" tf:"optional,object"` // Name of parent schema relative to its parent catalog. SchemaName types.String `tfsdk:"schema_name" tf:"optional"` // Function security type. @@ -2148,6 +3125,43 @@ func (a FunctionInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a FunctionInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BrowseOnly": types.BoolType, + "CatalogName": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DataType": types.StringType, + "ExternalLanguage": types.StringType, + "ExternalName": types.StringType, + "FullDataType": types.StringType, + "FullName": types.StringType, + "FunctionId": types.StringType, + "InputParams": FunctionParameterInfos{}.ToAttrType(ctx), + "IsDeterministic": types.BoolType, + "IsNullCall": types.BoolType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "ParameterStyle": types.StringType, + "Properties": types.StringType, + "ReturnParams": FunctionParameterInfos{}.ToAttrType(ctx), + "RoutineBody": types.StringType, + "RoutineDefinition": types.StringType, + "RoutineDependencies": DependencyList{}.ToAttrType(ctx), + "SchemaName": types.StringType, + "SecurityType": types.StringType, + "SpecificName": types.StringType, + "SqlDataAccess": types.StringType, + "SqlPath": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type FunctionParameterInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -2185,6 +3199,25 @@ func (a FunctionParameterInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FunctionParameterInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "ParameterDefault": types.StringType, + "ParameterMode": types.StringType, + "ParameterType": types.StringType, + "Position": types.Int64Type, + "TypeIntervalType": types.StringType, + "TypeJson": types.StringType, + "TypeName": types.StringType, + "TypePrecision": types.Int64Type, + "TypeScale": types.Int64Type, + "TypeText": types.StringType, + }, + } +} + type FunctionParameterInfos struct { // The array of __FunctionParameterInfo__ definitions of the function's // parameters. @@ -2203,6 +3236,16 @@ func (a FunctionParameterInfos) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a FunctionParameterInfos) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Parameters": basetypes.ListType{ + ElemType: FunctionParameterInfo{}.ToAttrType(ctx), + }, + }, + } +} + // GCP temporary credentials for API authentication. Read more at // https://developers.google.com/identity/protocols/oauth2/service-account type GcpOauthToken struct { @@ -2219,6 +3262,14 @@ func (a GcpOauthToken) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcpOauthToken) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "OauthToken": types.StringType, + }, + } +} + // GCP long-lived credential. GCP Service Account. type GcpServiceAccountKey struct { // The email of the service account. [Create:REQ Update:OPT]. @@ -2239,6 +3290,16 @@ func (a GcpServiceAccountKey) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcpServiceAccountKey) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Email": types.StringType, + "PrivateKey": types.StringType, + "PrivateKeyId": types.StringType, + }, + } +} + // Options to customize the requested temporary credential type GenerateTemporaryServiceCredentialAzureOptions struct { // The resources to which the temporary Azure credential should apply. These @@ -2255,13 +3316,23 @@ func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFie func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Resources": reflect.TypeOf(""), + "Resources": reflect.TypeOf(types.StringType), + } +} + +func (a GenerateTemporaryServiceCredentialAzureOptions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Resources": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type GenerateTemporaryServiceCredentialRequest struct { // Options to customize the requested temporary credential - AzureOptions types.Object `tfsdk:"azure_options" tf:"optional,object"` + AzureOptions types.List `tfsdk:"azure_options" tf:"optional,object"` // The name of the service credential used to generate a temporary // credential CredentialName types.String `tfsdk:"credential_name" tf:""` @@ -2279,6 +3350,15 @@ func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes() map[st } } +func (a GenerateTemporaryServiceCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AzureOptions": GenerateTemporaryServiceCredentialAzureOptions{}.ToAttrType(ctx), + "CredentialName": types.StringType, + }, + } +} + type GenerateTemporaryTableCredentialRequest struct { // The operation performed against the table data, either READ or // READ_WRITE. If READ_WRITE is specified, the credentials returned will @@ -2298,26 +3378,35 @@ func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a GenerateTemporaryTableCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Operation": types.StringType, + "TableId": types.StringType, + }, + } +} + type GenerateTemporaryTableCredentialResponse struct { // AWS temporary credentials for API authentication. Read more at // https://docs.aws.amazon.com/STS/latest/APIReference/API_Credentials.html. - AwsTempCredentials types.Object `tfsdk:"aws_temp_credentials" tf:"optional,object"` + AwsTempCredentials types.List `tfsdk:"aws_temp_credentials" tf:"optional,object"` // Azure Active Directory token, essentially the Oauth token for Azure // Service Principal or Managed Identity. Read more at // https://learn.microsoft.com/en-us/azure/databricks/dev-tools/api/latest/aad/service-prin-aad-token - AzureAad types.Object `tfsdk:"azure_aad" tf:"optional,object"` + AzureAad types.List `tfsdk:"azure_aad" tf:"optional,object"` // Azure temporary credentials for API authentication. Read more at // https://docs.microsoft.com/en-us/rest/api/storageservices/create-user-delegation-sas - AzureUserDelegationSas types.Object `tfsdk:"azure_user_delegation_sas" tf:"optional,object"` + AzureUserDelegationSas types.List `tfsdk:"azure_user_delegation_sas" tf:"optional,object"` // Server time when the credential will expire, in epoch milliseconds. The // API client is advised to cache the credential given this expiration time. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` // GCP temporary credentials for API authentication. Read more at // https://developers.google.com/identity/protocols/oauth2/service-account - GcpOauthToken types.Object `tfsdk:"gcp_oauth_token" tf:"optional,object"` + GcpOauthToken types.List `tfsdk:"gcp_oauth_token" tf:"optional,object"` // R2 temporary credentials for API authentication. Read more at // https://developers.cloudflare.com/r2/api/s3/tokens/. - R2TempCredentials types.Object `tfsdk:"r2_temp_credentials" tf:"optional,object"` + R2TempCredentials types.List `tfsdk:"r2_temp_credentials" tf:"optional,object"` // The URL of the storage path accessible by the temporary credential. Url types.String `tfsdk:"url" tf:"optional"` } @@ -2338,6 +3427,20 @@ func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes() map[str } } +func (a GenerateTemporaryTableCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsTempCredentials": AwsCredentials{}.ToAttrType(ctx), + "AzureAad": AzureActiveDirectoryToken{}.ToAttrType(ctx), + "AzureUserDelegationSas": AzureUserDelegationSas{}.ToAttrType(ctx), + "ExpirationTime": types.Int64Type, + "GcpOauthToken": GcpOauthToken{}.ToAttrType(ctx), + "R2TempCredentials": R2Credentials{}.ToAttrType(ctx), + "Url": types.StringType, + }, + } +} + // Gets the metastore assignment for a workspace type GetAccountMetastoreAssignmentRequest struct { // Workspace ID. @@ -2354,6 +3457,14 @@ func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GetAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceId": types.Int64Type, + }, + } +} + // Get a metastore type GetAccountMetastoreRequest struct { // Unity Catalog metastore ID @@ -2370,6 +3481,14 @@ func (a GetAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + }, + } +} + // Gets the named storage credential type GetAccountStorageCredentialRequest struct { // Unity Catalog metastore ID @@ -2388,6 +3507,15 @@ func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a GetAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + "StorageCredentialName": types.StringType, + }, + } +} + // Get an artifact allowlist type GetArtifactAllowlistRequest struct { // The artifact type of the allowlist. @@ -2404,6 +3532,14 @@ func (a GetArtifactAllowlistRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetArtifactAllowlistRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactType": types.StringType, + }, + } +} + // Get securable workspace bindings type GetBindingsRequest struct { // Maximum number of workspace bindings to return. - When set to 0, the page @@ -2431,6 +3567,17 @@ func (a GetBindingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetBindingsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "SecurableName": types.StringType, + "SecurableType": types.StringType, + }, + } +} + // Get Model Version By Alias type GetByAliasRequest struct { // The name of the alias @@ -2452,6 +3599,16 @@ func (a GetByAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetByAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alias": types.StringType, + "FullName": types.StringType, + "IncludeAliases": types.BoolType, + }, + } +} + // Get a catalog type GetCatalogRequest struct { // Whether to include catalogs in the response for which the principal can @@ -2471,6 +3628,15 @@ func (a GetCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeBrowse": types.BoolType, + "Name": types.StringType, + }, + } +} + // Get a connection type GetConnectionRequest struct { // Name of the connection. @@ -2487,6 +3653,14 @@ func (a GetConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get a credential type GetCredentialRequest struct { // Name of the credential. @@ -2503,6 +3677,14 @@ func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NameArg": types.StringType, + }, + } +} + // Get effective permissions type GetEffectiveRequest struct { // Full name of securable. @@ -2524,6 +3706,16 @@ func (a GetEffectiveRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetEffectiveRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "Principal": types.StringType, + "SecurableType": types.StringType, + }, + } +} + // Get an external location type GetExternalLocationRequest struct { // Whether to include external locations in the response for which the @@ -2543,6 +3735,15 @@ func (a GetExternalLocationRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeBrowse": types.BoolType, + "Name": types.StringType, + }, + } +} + // Get a function type GetFunctionRequest struct { // Whether to include functions in the response for which the principal can @@ -2563,6 +3764,15 @@ func (a GetFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeBrowse": types.BoolType, + "Name": types.StringType, + }, + } +} + // Get permissions type GetGrantRequest struct { // Full name of securable. @@ -2584,6 +3794,16 @@ func (a GetGrantRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetGrantRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "Principal": types.StringType, + "SecurableType": types.StringType, + }, + } +} + // Get a metastore type GetMetastoreRequest struct { // Unique ID of the metastore. @@ -2600,6 +3820,14 @@ func (a GetMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetMetastoreSummaryResponse struct { // Cloud vendor of the metastore home shard (e.g., `aws`, `azure`, `gcp`). Cloud types.String `tfsdk:"cloud" tf:"optional"` @@ -2655,6 +3883,32 @@ func (a GetMetastoreSummaryResponse) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetMetastoreSummaryResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cloud": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DefaultDataAccessConfigId": types.StringType, + "DeltaSharingOrganizationName": types.StringType, + "DeltaSharingRecipientTokenLifetimeInSeconds": types.Int64Type, + "DeltaSharingScope": types.StringType, + "ExternalAccessEnabled": types.BoolType, + "GlobalMetastoreId": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "PrivilegeModelVersion": types.StringType, + "Region": types.StringType, + "StorageRoot": types.StringType, + "StorageRootCredentialId": types.StringType, + "StorageRootCredentialName": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + // Get a Model Version type GetModelVersionRequest struct { // The three-level (fully qualified) name of the model version @@ -2679,6 +3933,17 @@ func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "IncludeAliases": types.BoolType, + "IncludeBrowse": types.BoolType, + "Version": types.Int64Type, + }, + } +} + // Get an Online Table type GetOnlineTableRequest struct { // Full three-part (catalog, schema, table) name of the table. @@ -2695,6 +3960,14 @@ func (a GetOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get a table monitor type GetQualityMonitorRequest struct { // Full name of the table. @@ -2711,6 +3984,14 @@ func (a GetQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableName": types.StringType, + }, + } +} + // Get information for a single resource quota. type GetQuotaRequest struct { // Full name of the parent resource. Provide the metastore ID if the parent @@ -2733,9 +4014,19 @@ func (a GetQuotaRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetQuotaRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ParentFullName": types.StringType, + "ParentSecurableType": types.StringType, + "QuotaName": types.StringType, + }, + } +} + type GetQuotaResponse struct { // The returned QuotaInfo. - QuotaInfo types.Object `tfsdk:"quota_info" tf:"optional,object"` + QuotaInfo types.List `tfsdk:"quota_info" tf:"optional,object"` } func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetQuotaResponse) { @@ -2750,6 +4041,14 @@ func (a GetQuotaResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetQuotaResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QuotaInfo": QuotaInfo{}.ToAttrType(ctx), + }, + } +} + // Get refresh type GetRefreshRequest struct { // ID of the refresh. @@ -2768,6 +4067,15 @@ func (a GetRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RefreshId": types.StringType, + "TableName": types.StringType, + }, + } +} + // Get a Registered Model type GetRegisteredModelRequest struct { // The three-level (fully qualified) name of the registered model @@ -2789,6 +4097,16 @@ func (a GetRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a GetRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "IncludeAliases": types.BoolType, + "IncludeBrowse": types.BoolType, + }, + } +} + // Get a schema type GetSchemaRequest struct { // Full name of the schema. @@ -2808,6 +4126,15 @@ func (a GetSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "IncludeBrowse": types.BoolType, + }, + } +} + // Get a credential type GetStorageCredentialRequest struct { // Name of the storage credential. @@ -2824,6 +4151,14 @@ func (a GetStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get a table type GetTableRequest struct { // Full name of the table. @@ -2847,6 +4182,17 @@ func (a GetTableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetTableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "IncludeBrowse": types.BoolType, + "IncludeDeltaMetadata": types.BoolType, + "IncludeManifestCapabilities": types.BoolType, + }, + } +} + // Get catalog workspace bindings type GetWorkspaceBindingRequest struct { // The name of the catalog. @@ -2863,6 +4209,14 @@ func (a GetWorkspaceBindingRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetWorkspaceBindingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get all workspaces assigned to a metastore type ListAccountMetastoreAssignmentsRequest struct { // Unity Catalog metastore ID @@ -2879,6 +4233,14 @@ func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes() map[strin return map[string]reflect.Type{} } +func (a ListAccountMetastoreAssignmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + }, + } +} + // The list of workspaces to which the given metastore is assigned. type ListAccountMetastoreAssignmentsResponse struct { WorkspaceIds types.List `tfsdk:"workspace_ids" tf:"optional"` @@ -2892,7 +4254,17 @@ func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuri func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "WorkspaceIds": reflect.TypeOf(0), + "WorkspaceIds": reflect.TypeOf(types.Int64Type), + } +} + +func (a ListAccountMetastoreAssignmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceIds": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -2912,6 +4284,14 @@ func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a ListAccountStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + }, + } +} + type ListAccountStorageCredentialsResponse struct { // An array of metastore storage credentials. StorageCredentials types.List `tfsdk:"storage_credentials" tf:"optional"` @@ -2929,6 +4309,16 @@ func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes() map[string } } +func (a ListAccountStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StorageCredentials": basetypes.ListType{ + ElemType: StorageCredentialInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List catalogs type ListCatalogsRequest struct { // Whether to include catalogs in the response for which the principal can @@ -2958,6 +4348,16 @@ func (a ListCatalogsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListCatalogsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListCatalogsResponse struct { // An array of catalog information objects. Catalogs types.List `tfsdk:"catalogs" tf:"optional"` @@ -2979,6 +4379,17 @@ func (a ListCatalogsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListCatalogsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Catalogs": basetypes.ListType{ + ElemType: CatalogInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List connections type ListConnectionsRequest struct { // Maximum number of connections to return. - If not set, all connections @@ -3002,6 +4413,15 @@ func (a ListConnectionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListConnectionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListConnectionsResponse struct { // An array of connection information objects. Connections types.List `tfsdk:"connections" tf:"optional"` @@ -3023,6 +4443,17 @@ func (a ListConnectionsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListConnectionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Connections": basetypes.ListType{ + ElemType: ConnectionInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List credentials type ListCredentialsRequest struct { // Maximum number of credentials to return. - If not set, the default max @@ -3047,6 +4478,16 @@ func (a ListCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "Purpose": types.StringType, + }, + } +} + type ListCredentialsResponse struct { Credentials types.List `tfsdk:"credentials" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no @@ -3067,6 +4508,17 @@ func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Credentials": basetypes.ListType{ + ElemType: CredentialInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List external locations type ListExternalLocationsRequest struct { // Whether to include external locations in the response for which the @@ -3093,6 +4545,16 @@ func (a ListExternalLocationsRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a ListExternalLocationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListExternalLocationsResponse struct { // An array of external locations. ExternalLocations types.List `tfsdk:"external_locations" tf:"optional"` @@ -3114,6 +4576,17 @@ func (a ListExternalLocationsResponse) GetComplexFieldTypes() map[string]reflect } } +func (a ListExternalLocationsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExternalLocations": basetypes.ListType{ + ElemType: ExternalLocationInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List functions type ListFunctionsRequest struct { // Name of parent catalog for functions of interest. @@ -3144,6 +4617,18 @@ func (a ListFunctionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListFunctionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "SchemaName": types.StringType, + }, + } +} + type ListFunctionsResponse struct { // An array of function information objects. Functions types.List `tfsdk:"functions" tf:"optional"` @@ -3165,6 +4650,17 @@ func (a ListFunctionsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListFunctionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Functions": basetypes.ListType{ + ElemType: FunctionInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type ListMetastoresResponse struct { // An array of metastore information objects. Metastores types.List `tfsdk:"metastores" tf:"optional"` @@ -3182,6 +4678,16 @@ func (a ListMetastoresResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListMetastoresResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Metastores": basetypes.ListType{ + ElemType: MetastoreInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List Model Versions type ListModelVersionsRequest struct { // The full three-level name of the registered model under which to list @@ -3212,6 +4718,17 @@ func (a ListModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListModelVersionsResponse struct { ModelVersions types.List `tfsdk:"model_versions" tf:"optional"` // Opaque token to retrieve the next page of results. Absent if there are no @@ -3232,6 +4749,17 @@ func (a ListModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ListModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelVersions": basetypes.ListType{ + ElemType: ModelVersionInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List all resource quotas under a metastore. type ListQuotasRequest struct { // The number of quotas to return. @@ -3250,6 +4778,15 @@ func (a ListQuotasRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListQuotasRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListQuotasResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3271,6 +4808,17 @@ func (a ListQuotasResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListQuotasResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Quotas": basetypes.ListType{ + ElemType: QuotaInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List refreshes type ListRefreshesRequest struct { // Full name of the table. @@ -3287,6 +4835,14 @@ func (a ListRefreshesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListRefreshesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableName": types.StringType, + }, + } +} + // List Registered Models type ListRegisteredModelsRequest struct { // The identifier of the catalog under which to list registered models. If @@ -3330,6 +4886,18 @@ func (a ListRegisteredModelsRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a ListRegisteredModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "SchemaName": types.StringType, + }, + } +} + type ListRegisteredModelsResponse struct { // Opaque token for pagination. Omitted if there are no more results. // page_token should be set to this value for fetching the next page. @@ -3350,6 +4918,17 @@ func (a ListRegisteredModelsResponse) GetComplexFieldTypes() map[string]reflect. } } +func (a ListRegisteredModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "RegisteredModels": basetypes.ListType{ + ElemType: RegisteredModelInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List schemas type ListSchemasRequest struct { // Parent catalog for schemas of interest. @@ -3378,6 +4957,17 @@ func (a ListSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListSchemasResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3399,6 +4989,17 @@ func (a ListSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Schemas": basetypes.ListType{ + ElemType: SchemaInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List credentials type ListStorageCredentialsRequest struct { // Maximum number of storage credentials to return. If not set, all the @@ -3422,6 +5023,15 @@ func (a ListStorageCredentialsRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a ListStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListStorageCredentialsResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3443,6 +5053,17 @@ func (a ListStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflec } } +func (a ListStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "StorageCredentials": basetypes.ListType{ + ElemType: StorageCredentialInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List table summaries type ListSummariesRequest struct { // Name of parent catalog for tables of interest. @@ -3477,6 +5098,19 @@ func (a ListSummariesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListSummariesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "IncludeManifestCapabilities": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "SchemaNamePattern": types.StringType, + "TableNamePattern": types.StringType, + }, + } +} + // List system schemas type ListSystemSchemasRequest struct { // Maximum number of schemas to return. - When set to 0, the page length is @@ -3502,6 +5136,16 @@ func (a ListSystemSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListSystemSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "MetastoreId": types.StringType, + "PageToken": types.StringType, + }, + } +} + type ListSystemSchemasResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3523,6 +5167,17 @@ func (a ListSystemSchemasResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ListSystemSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Schemas": basetypes.ListType{ + ElemType: SystemSchemaInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ListTableSummariesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3544,6 +5199,17 @@ func (a ListTableSummariesResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ListTableSummariesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Tables": basetypes.ListType{ + ElemType: TableSummary{}.ToAttrType(ctx), + }, + }, + } +} + // List tables type ListTablesRequest struct { // Name of parent catalog for tables of interest. @@ -3585,6 +5251,23 @@ func (a ListTablesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListTablesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "IncludeBrowse": types.BoolType, + "IncludeDeltaMetadata": types.BoolType, + "IncludeManifestCapabilities": types.BoolType, + "MaxResults": types.Int64Type, + "OmitColumns": types.BoolType, + "OmitProperties": types.BoolType, + "OmitUsername": types.BoolType, + "PageToken": types.StringType, + "SchemaName": types.StringType, + }, + } +} + type ListTablesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3606,6 +5289,17 @@ func (a ListTablesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListTablesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Tables": basetypes.ListType{ + ElemType: TableInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List Volumes type ListVolumesRequest struct { // The identifier of the catalog @@ -3643,6 +5337,18 @@ func (a ListVolumesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListVolumesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "IncludeBrowse": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "SchemaName": types.StringType, + }, + } +} + type ListVolumesResponseContent struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -3664,6 +5370,17 @@ func (a ListVolumesResponseContent) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ListVolumesResponseContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Volumes": basetypes.ListType{ + ElemType: VolumeInfo{}.ToAttrType(ctx), + }, + }, + } +} + type MetastoreAssignment struct { // The name of the default catalog in the metastore. DefaultCatalogName types.String `tfsdk:"default_catalog_name" tf:"optional"` @@ -3683,6 +5400,16 @@ func (a MetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DefaultCatalogName": types.StringType, + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type MetastoreInfo struct { // Cloud vendor of the metastore home shard (e.g., `aws`, `azure`, `gcp`). Cloud types.String `tfsdk:"cloud" tf:"optional"` @@ -3738,6 +5465,32 @@ func (a MetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cloud": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DefaultDataAccessConfigId": types.StringType, + "DeltaSharingOrganizationName": types.StringType, + "DeltaSharingRecipientTokenLifetimeInSeconds": types.Int64Type, + "DeltaSharingScope": types.StringType, + "ExternalAccessEnabled": types.BoolType, + "GlobalMetastoreId": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "PrivilegeModelVersion": types.StringType, + "Region": types.StringType, + "StorageRoot": types.StringType, + "StorageRootCredentialId": types.StringType, + "StorageRootCredentialName": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type ModelVersionInfo struct { // List of aliases associated with the model version Aliases types.List `tfsdk:"aliases" tf:"optional"` @@ -3761,7 +5514,7 @@ type ModelVersionInfo struct { // parent schema ModelName types.String `tfsdk:"model_name" tf:"optional"` // Model version dependencies, for feature-store packaged models - ModelVersionDependencies types.Object `tfsdk:"model_version_dependencies" tf:"optional,object"` + ModelVersionDependencies types.List `tfsdk:"model_version_dependencies" tf:"optional,object"` // MLflow run ID used when creating the model version, if ``source`` was // generated by an experiment run stored in an MLflow tracking server RunId types.String `tfsdk:"run_id" tf:"optional"` @@ -3804,6 +5557,34 @@ func (a ModelVersionInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ModelVersionInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Aliases": basetypes.ListType{ + ElemType: RegisteredModelAlias{}.ToAttrType(ctx), + }, + "BrowseOnly": types.BoolType, + "CatalogName": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "Id": types.StringType, + "MetastoreId": types.StringType, + "ModelName": types.StringType, + "ModelVersionDependencies": DependencyList{}.ToAttrType(ctx), + "RunId": types.StringType, + "RunWorkspaceId": types.Int64Type, + "SchemaName": types.StringType, + "Source": types.StringType, + "Status": types.StringType, + "StorageLocation": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "Version": types.Int64Type, + }, + } +} + type MonitorCronSchedule struct { // Read only field that indicates whether a schedule is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` @@ -3826,6 +5607,16 @@ func (a MonitorCronSchedule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MonitorCronSchedule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PauseStatus": types.StringType, + "QuartzCronExpression": types.StringType, + "TimezoneId": types.StringType, + }, + } +} + type MonitorDataClassificationConfig struct { // Whether data classification is enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -3841,6 +5632,14 @@ func (a MonitorDataClassificationConfig) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a MonitorDataClassificationConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + }, + } +} + type MonitorDestination struct { // The list of email addresses to send the notification to. A maximum of 5 // email addresses is supported. @@ -3855,7 +5654,17 @@ func (newState *MonitorDestination) SyncEffectiveFieldsDuringRead(existingState func (a MonitorDestination) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EmailAddresses": reflect.TypeOf(""), + "EmailAddresses": reflect.TypeOf(types.StringType), + } +} + +func (a MonitorDestination) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EmailAddresses": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -3898,7 +5707,23 @@ func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringRead(existingState func (a MonitorInferenceLog) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Granularities": reflect.TypeOf(""), + "Granularities": reflect.TypeOf(types.StringType), + } +} + +func (a MonitorInferenceLog) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Granularities": basetypes.ListType{ + ElemType: types.StringType, + }, + "LabelCol": types.StringType, + "ModelIdCol": types.StringType, + "PredictionCol": types.StringType, + "PredictionProbaCol": types.StringType, + "ProblemType": types.StringType, + "TimestampCol": types.StringType, + }, } } @@ -3917,26 +5742,26 @@ type MonitorInfo struct { // if the monitor is in PENDING state. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` // The data classification config for the monitor. - DataClassificationConfig types.Object `tfsdk:"data_classification_config" tf:"optional,object"` + DataClassificationConfig types.List `tfsdk:"data_classification_config" tf:"optional,object"` // The full name of the drift metrics table. Format: // __catalog_name__.__schema_name__.__table_name__. DriftMetricsTableName types.String `tfsdk:"drift_metrics_table_name" tf:""` // Configuration for monitoring inference logs. - InferenceLog types.Object `tfsdk:"inference_log" tf:"optional,object"` + InferenceLog types.List `tfsdk:"inference_log" tf:"optional,object"` // The latest failure message of the monitor (if any). LatestMonitorFailureMsg types.String `tfsdk:"latest_monitor_failure_msg" tf:"optional"` // The version of the monitor config (e.g. 1,2,3). If negative, the monitor // may be corrupted. MonitorVersion types.String `tfsdk:"monitor_version" tf:""` // The notification settings for the monitor. - Notifications types.Object `tfsdk:"notifications" tf:"optional,object"` + Notifications types.List `tfsdk:"notifications" tf:"optional,object"` // Schema where output metric tables are created. OutputSchemaName types.String `tfsdk:"output_schema_name" tf:"optional"` // The full name of the profile metrics table. Format: // __catalog_name__.__schema_name__.__table_name__. ProfileMetricsTableName types.String `tfsdk:"profile_metrics_table_name" tf:""` // The schedule for automatically updating and refreshing metric tables. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // List of column expressions to slice data with for targeted analysis. The // data is grouped by each expression independently, resulting in a separate // slice for each predicate and its complements. For high-cardinality @@ -3951,7 +5776,7 @@ type MonitorInfo struct { // __catalog_name__.__schema_name__.__table_name__. TableName types.String `tfsdk:"table_name" tf:""` // Configuration for monitoring time series tables. - TimeSeries types.Object `tfsdk:"time_series" tf:"optional,object"` + TimeSeries types.List `tfsdk:"time_series" tf:"optional,object"` } func (newState *MonitorInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorInfo) { @@ -3967,12 +5792,41 @@ func (a MonitorInfo) GetComplexFieldTypes() map[string]reflect.Type { "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), "Notifications": reflect.TypeOf(MonitorNotifications{}), "Schedule": reflect.TypeOf(MonitorCronSchedule{}), - "SlicingExprs": reflect.TypeOf(""), + "SlicingExprs": reflect.TypeOf(types.StringType), "Snapshot": reflect.TypeOf(MonitorSnapshot{}), "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), } } +func (a MonitorInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AssetsDir": types.StringType, + "BaselineTableName": types.StringType, + "CustomMetrics": basetypes.ListType{ + ElemType: MonitorMetric{}.ToAttrType(ctx), + }, + "DashboardId": types.StringType, + "DataClassificationConfig": MonitorDataClassificationConfig{}.ToAttrType(ctx), + "DriftMetricsTableName": types.StringType, + "InferenceLog": MonitorInferenceLog{}.ToAttrType(ctx), + "LatestMonitorFailureMsg": types.StringType, + "MonitorVersion": types.StringType, + "Notifications": MonitorNotifications{}.ToAttrType(ctx), + "OutputSchemaName": types.StringType, + "ProfileMetricsTableName": types.StringType, + "Schedule": MonitorCronSchedule{}.ToAttrType(ctx), + "SlicingExprs": basetypes.ListType{ + ElemType: types.StringType, + }, + "Snapshot": MonitorSnapshot{}.ToAttrType(ctx), + "Status": types.StringType, + "TableName": types.StringType, + "TimeSeries": MonitorTimeSeries{}.ToAttrType(ctx), + }, + } +} + type MonitorMetric struct { // Jinja template for a SQL expression that specifies how to compute the // metric. See [create metric definition]. @@ -4008,16 +5862,30 @@ func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState Monit func (a MonitorMetric) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InputColumns": reflect.TypeOf(""), + "InputColumns": reflect.TypeOf(types.StringType), + } +} + +func (a MonitorMetric) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Definition": types.StringType, + "InputColumns": basetypes.ListType{ + ElemType: types.StringType, + }, + "Name": types.StringType, + "OutputDataType": types.StringType, + "Type": types.StringType, + }, } } type MonitorNotifications struct { // Who to send notifications to on monitor failure. - OnFailure types.Object `tfsdk:"on_failure" tf:"optional,object"` + OnFailure types.List `tfsdk:"on_failure" tf:"optional,object"` // Who to send notifications to when new data classification tags are // detected. - OnNewClassificationTagDetected types.Object `tfsdk:"on_new_classification_tag_detected" tf:"optional,object"` + OnNewClassificationTagDetected types.List `tfsdk:"on_new_classification_tag_detected" tf:"optional,object"` } func (newState *MonitorNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorNotifications) { @@ -4033,6 +5901,15 @@ func (a MonitorNotifications) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a MonitorNotifications) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "OnFailure": MonitorDestination{}.ToAttrType(ctx), + "OnNewClassificationTagDetected": MonitorDestination{}.ToAttrType(ctx), + }, + } +} + type MonitorRefreshInfo struct { // Time at which refresh operation completed (milliseconds since 1/1/1970 // UTC). @@ -4061,6 +5938,19 @@ func (a MonitorRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MonitorRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndTimeMs": types.Int64Type, + "Message": types.StringType, + "RefreshId": types.Int64Type, + "StartTimeMs": types.Int64Type, + "State": types.StringType, + "Trigger": types.StringType, + }, + } +} + type MonitorRefreshListResponse struct { // List of refreshes. Refreshes types.List `tfsdk:"refreshes" tf:"optional"` @@ -4078,6 +5968,16 @@ func (a MonitorRefreshListResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a MonitorRefreshListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Refreshes": basetypes.ListType{ + ElemType: MonitorRefreshInfo{}.ToAttrType(ctx), + }, + }, + } +} + type MonitorSnapshot struct { } @@ -4091,6 +5991,12 @@ func (a MonitorSnapshot) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MonitorSnapshot) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type MonitorTimeSeries struct { // Granularities for aggregating data into time windows based on their // timestamp. Currently the following static granularities are supported: @@ -4114,7 +6020,18 @@ func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringRead(existingState M func (a MonitorTimeSeries) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Granularities": reflect.TypeOf(""), + "Granularities": reflect.TypeOf(types.StringType), + } +} + +func (a MonitorTimeSeries) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Granularities": basetypes.ListType{ + ElemType: types.StringType, + }, + "TimestampCol": types.StringType, + }, } } @@ -4133,14 +6050,22 @@ func (a NamedTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NamedTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Online Table information. type OnlineTable struct { // Full three-part (catalog, schema, table) name of the table. Name types.String `tfsdk:"name" tf:"optional"` // Specification of the online table. - Spec types.Object `tfsdk:"spec" tf:"optional,object"` + Spec types.List `tfsdk:"spec" tf:"optional,object"` // Online Table data synchronization status - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` // Data serving REST API URL for this table TableServingUrl types.String `tfsdk:"table_serving_url" tf:"computed,optional"` // The provisioning state of the online table entity in Unity Catalog. This @@ -4163,6 +6088,18 @@ func (a OnlineTable) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a OnlineTable) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Spec": OnlineTableSpec{}.ToAttrType(ctx), + "Status": OnlineTableStatus{}.ToAttrType(ctx), + "TableServingUrl": types.StringType, + "UnityCatalogProvisioningState": types.StringType, + }, + } +} + // Specification of an online table. type OnlineTableSpec struct { // Whether to create a full-copy pipeline -- a pipeline that stops after @@ -4198,12 +6135,28 @@ func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringRead(existingState Onl func (a OnlineTableSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrimaryKeyColumns": reflect.TypeOf(""), + "PrimaryKeyColumns": reflect.TypeOf(types.StringType), "RunContinuously": reflect.TypeOf(OnlineTableSpecContinuousSchedulingPolicy{}), "RunTriggered": reflect.TypeOf(OnlineTableSpecTriggeredSchedulingPolicy{}), } } +func (a OnlineTableSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PerformFullCopy": types.BoolType, + "PipelineId": types.StringType, + "PrimaryKeyColumns": basetypes.ListType{ + ElemType: types.StringType, + }, + "RunContinuously": OnlineTableSpecContinuousSchedulingPolicy{}.ToAttrType(ctx), + "RunTriggered": OnlineTableSpecTriggeredSchedulingPolicy{}.ToAttrType(ctx), + "SourceTableFullName": types.StringType, + "TimeseriesKey": types.StringType, + }, + } +} + type OnlineTableSpecContinuousSchedulingPolicy struct { } @@ -4217,6 +6170,12 @@ func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes() map[st return map[string]reflect.Type{} } +func (a OnlineTableSpecContinuousSchedulingPolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type OnlineTableSpecTriggeredSchedulingPolicy struct { } @@ -4230,25 +6189,31 @@ func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes() map[str return map[string]reflect.Type{} } +func (a OnlineTableSpecTriggeredSchedulingPolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Status of an online table. type OnlineTableStatus struct { // Detailed status of an online table. Shown if the online table is in the // ONLINE_CONTINUOUS_UPDATE or the ONLINE_UPDATING_PIPELINE_RESOURCES state. - ContinuousUpdateStatus types.Object `tfsdk:"continuous_update_status" tf:"optional,object"` + ContinuousUpdateStatus types.List `tfsdk:"continuous_update_status" tf:"optional,object"` // The state of the online table. DetailedState types.String `tfsdk:"detailed_state" tf:"optional"` // Detailed status of an online table. Shown if the online table is in the // OFFLINE_FAILED or the ONLINE_PIPELINE_FAILED state. - FailedStatus types.Object `tfsdk:"failed_status" tf:"optional,object"` + FailedStatus types.List `tfsdk:"failed_status" tf:"optional,object"` // A text description of the current state of the online table. Message types.String `tfsdk:"message" tf:"optional"` // Detailed status of an online table. Shown if the online table is in the // PROVISIONING_PIPELINE_RESOURCES or the PROVISIONING_INITIAL_SNAPSHOT // state. - ProvisioningStatus types.Object `tfsdk:"provisioning_status" tf:"optional,object"` + ProvisioningStatus types.List `tfsdk:"provisioning_status" tf:"optional,object"` // Detailed status of an online table. Shown if the online table is in the // ONLINE_TRIGGERED_UPDATE or the ONLINE_NO_PENDING_UPDATE state. - TriggeredUpdateStatus types.Object `tfsdk:"triggered_update_status" tf:"optional,object"` + TriggeredUpdateStatus types.List `tfsdk:"triggered_update_status" tf:"optional,object"` } func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan OnlineTableStatus) { @@ -4266,6 +6231,19 @@ func (a OnlineTableStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a OnlineTableStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ContinuousUpdateStatus": ContinuousUpdateStatus{}.ToAttrType(ctx), + "DetailedState": types.StringType, + "FailedStatus": FailedStatus{}.ToAttrType(ctx), + "Message": types.StringType, + "ProvisioningStatus": ProvisioningStatus{}.ToAttrType(ctx), + "TriggeredUpdateStatus": TriggeredUpdateStatus{}.ToAttrType(ctx), + }, + } +} + type PermissionsChange struct { // The set of privileges to add. Add types.List `tfsdk:"add" tf:"optional"` @@ -4283,8 +6261,22 @@ func (newState *PermissionsChange) SyncEffectiveFieldsDuringRead(existingState P func (a PermissionsChange) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Add": reflect.TypeOf(""), - "Remove": reflect.TypeOf(""), + "Add": reflect.TypeOf(types.StringType), + "Remove": reflect.TypeOf(types.StringType), + } +} + +func (a PermissionsChange) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Add": basetypes.ListType{ + ElemType: types.StringType, + }, + "Principal": types.StringType, + "Remove": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -4305,6 +6297,16 @@ func (a PermissionsList) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PermissionsList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrivilegeAssignments": basetypes.ListType{ + ElemType: PrivilegeAssignment{}.ToAttrType(ctx), + }, + }, + } +} + // Progress information of the Online Table data synchronization pipeline. type PipelineProgress struct { // The estimated time remaining to complete this update in seconds. @@ -4331,6 +6333,18 @@ func (a PipelineProgress) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PipelineProgress) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EstimatedCompletionTimeSeconds": types.Float64Type, + "LatestVersionCurrentlyProcessing": types.Int64Type, + "SyncProgressCompletion": types.Float64Type, + "SyncedRowCount": types.Int64Type, + "TotalRowCount": types.Int64Type, + }, + } +} + type PrimaryKeyConstraint struct { // Column names for this constraint. ChildColumns types.List `tfsdk:"child_columns" tf:""` @@ -4346,7 +6360,18 @@ func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringRead(existingStat func (a PrimaryKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ChildColumns": reflect.TypeOf(""), + "ChildColumns": reflect.TypeOf(types.StringType), + } +} + +func (a PrimaryKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ChildColumns": basetypes.ListType{ + ElemType: types.StringType, + }, + "Name": types.StringType, + }, } } @@ -4365,7 +6390,18 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Privileges": reflect.TypeOf(""), + "Privileges": reflect.TypeOf(types.StringType), + } +} + +func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Principal": types.StringType, + "Privileges": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -4384,12 +6420,20 @@ func (a ProvisioningInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ProvisioningInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "State": types.StringType, + }, + } +} + // Detailed status of an online table. Shown if the online table is in the // PROVISIONING_PIPELINE_RESOURCES or the PROVISIONING_INITIAL_SNAPSHOT state. type ProvisioningStatus struct { // Details about initial data synchronization. Only populated when in the // PROVISIONING_INITIAL_SNAPSHOT state. - InitialPipelineSyncProgress types.Object `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` + InitialPipelineSyncProgress types.List `tfsdk:"initial_pipeline_sync_progress" tf:"optional,object"` } func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan ProvisioningStatus) { @@ -4404,6 +6448,14 @@ func (a ProvisioningStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ProvisioningStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InitialPipelineSyncProgress": PipelineProgress{}.ToAttrType(ctx), + }, + } +} + type QuotaInfo struct { // The timestamp that indicates when the quota count was last updated. LastRefreshedAt types.Int64 `tfsdk:"last_refreshed_at" tf:"optional"` @@ -4430,6 +6482,19 @@ func (a QuotaInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a QuotaInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LastRefreshedAt": types.Int64Type, + "ParentFullName": types.StringType, + "ParentSecurableType": types.StringType, + "QuotaCount": types.Int64Type, + "QuotaLimit": types.Int64Type, + "QuotaName": types.StringType, + }, + } +} + // R2 temporary credentials for API authentication. Read more at // https://developers.cloudflare.com/r2/api/s3/tokens/. type R2Credentials struct { @@ -4451,6 +6516,16 @@ func (a R2Credentials) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a R2Credentials) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessKeyId": types.StringType, + "SecretAccessKey": types.StringType, + "SessionToken": types.StringType, + }, + } +} + // Get a Volume type ReadVolumeRequest struct { // Whether to include volumes in the response for which the principal can @@ -4470,6 +6545,15 @@ func (a ReadVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ReadVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeBrowse": types.BoolType, + "Name": types.StringType, + }, + } +} + type RegenerateDashboardRequest struct { // Full name of the table. TableName types.String `tfsdk:"-"` @@ -4488,6 +6572,15 @@ func (a RegenerateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a RegenerateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableName": types.StringType, + "WarehouseId": types.StringType, + }, + } +} + type RegenerateDashboardResponse struct { // Id of the regenerated monitoring dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` @@ -4505,6 +6598,15 @@ func (a RegenerateDashboardResponse) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a RegenerateDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "ParentFolder": types.StringType, + }, + } +} + // Registered model alias. type RegisteredModelAlias struct { // Name of the alias, e.g. 'champion' or 'latest_stable' @@ -4523,6 +6625,15 @@ func (a RegisteredModelAlias) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RegisteredModelAlias) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AliasName": types.StringType, + "VersionNum": types.Int64Type, + }, + } +} + type RegisteredModelInfo struct { // List of aliases associated with the registered model Aliases types.List `tfsdk:"aliases" tf:"optional"` @@ -4571,6 +6682,29 @@ func (a RegisteredModelInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RegisteredModelInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Aliases": basetypes.ListType{ + ElemType: RegisteredModelAlias{}.ToAttrType(ctx), + }, + "BrowseOnly": types.BoolType, + "CatalogName": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "FullName": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "SchemaName": types.StringType, + "StorageLocation": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + // Queue a metric refresh for a monitor type RunRefreshRequest struct { // Full name of the table. @@ -4587,6 +6721,14 @@ func (a RunRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableName": types.StringType, + }, + } +} + type SchemaInfo struct { // Indicates whether the principal is limited to retrieving metadata for the // associated object through the BROWSE privilege when include_browse is @@ -4603,7 +6745,7 @@ type SchemaInfo struct { // Username of schema creator. CreatedBy types.String `tfsdk:"created_by" tf:"optional"` - EffectivePredictiveOptimizationFlag types.Object `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` + EffectivePredictiveOptimizationFlag types.List `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` // Whether predictive optimization should be enabled for this object and // objects under it. EnablePredictiveOptimization types.String `tfsdk:"enable_predictive_optimization" tf:"optional"` @@ -4638,7 +6780,34 @@ func (newState *SchemaInfo) SyncEffectiveFieldsDuringRead(existingState SchemaIn func (a SchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "Properties": reflect.TypeOf(""), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a SchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BrowseOnly": types.BoolType, + "CatalogName": types.StringType, + "CatalogType": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "EffectivePredictiveOptimizationFlag": EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + "EnablePredictiveOptimization": types.StringType, + "FullName": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "SchemaId": types.StringType, + "StorageLocation": types.StringType, + "StorageRoot": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, } } @@ -4661,6 +6830,17 @@ func (a SetArtifactAllowlist) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SetArtifactAllowlist) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactMatchers": basetypes.ListType{ + ElemType: ArtifactMatcher{}.ToAttrType(ctx), + }, + "ArtifactType": types.StringType, + }, + } +} + type SetRegisteredModelAliasRequest struct { // The name of the alias Alias types.String `tfsdk:"alias" tf:""` @@ -4680,6 +6860,16 @@ func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a SetRegisteredModelAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alias": types.StringType, + "FullName": types.StringType, + "VersionNum": types.Int64Type, + }, + } +} + // Server-Side Encryption properties for clients communicating with AWS s3. type SseEncryptionDetails struct { // The type of key encryption to use (affects headers from s3 client). @@ -4699,15 +6889,24 @@ func (a SseEncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SseEncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Algorithm": types.StringType, + "AwsKmsKeyArn": types.StringType, + }, + } +} + type StorageCredentialInfo struct { // The AWS IAM role configuration. - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.List `tfsdk:"cloudflare_api_token" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // Time at which this Credential was created, in epoch milliseconds. @@ -4715,7 +6914,7 @@ type StorageCredentialInfo struct { // Username of credential creator. CreatedBy types.String `tfsdk:"created_by" tf:"optional"` // The Databricks managed GCP service account configuration. - DatabricksGcpServiceAccount types.Object `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` + DatabricksGcpServiceAccount types.List `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // The full name of the credential. FullName types.String `tfsdk:"full_name" tf:"optional"` // The unique identifier of the credential. @@ -4755,6 +6954,31 @@ func (a StorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a StorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRoleResponse{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentityResponse{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountResponse{}.ToAttrType(ctx), + "FullName": types.StringType, + "Id": types.StringType, + "IsolationMode": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "ReadOnly": types.BoolType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "UsedForManagedStorage": types.BoolType, + }, + } +} + type SystemSchemaInfo struct { // Name of the system schema. Schema types.String `tfsdk:"schema" tf:"optional"` @@ -4773,15 +6997,24 @@ func (a SystemSchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SystemSchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Schema": types.StringType, + "State": types.StringType, + }, + } +} + // A table constraint, as defined by *one* of the following fields being set: // __primary_key_constraint__, __foreign_key_constraint__, // __named_table_constraint__. type TableConstraint struct { - ForeignKeyConstraint types.Object `tfsdk:"foreign_key_constraint" tf:"optional,object"` + ForeignKeyConstraint types.List `tfsdk:"foreign_key_constraint" tf:"optional,object"` - NamedTableConstraint types.Object `tfsdk:"named_table_constraint" tf:"optional,object"` + NamedTableConstraint types.List `tfsdk:"named_table_constraint" tf:"optional,object"` - PrimaryKeyConstraint types.Object `tfsdk:"primary_key_constraint" tf:"optional,object"` + PrimaryKeyConstraint types.List `tfsdk:"primary_key_constraint" tf:"optional,object"` } func (newState *TableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableConstraint) { @@ -4798,6 +7031,16 @@ func (a TableConstraint) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TableConstraint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ForeignKeyConstraint": ForeignKeyConstraint{}.ToAttrType(ctx), + "NamedTableConstraint": NamedTableConstraint{}.ToAttrType(ctx), + "PrimaryKeyConstraint": PrimaryKeyConstraint{}.ToAttrType(ctx), + }, + } +} + // A table that is dependent on a SQL object. type TableDependency struct { // Full name of the dependent table, in the form of @@ -4815,6 +7058,14 @@ func (a TableDependency) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TableDependency) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableFullName": types.StringType, + }, + } +} + type TableExistsResponse struct { // Whether the table exists or not. TableExists types.Bool `tfsdk:"table_exists" tf:"optional"` @@ -4830,6 +7081,14 @@ func (a TableExistsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TableExistsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TableExists": types.BoolType, + }, + } +} + type TableInfo struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -4855,14 +7114,14 @@ type TableInfo struct { // omitted if table is not deleted. DeletedAt types.Int64 `tfsdk:"deleted_at" tf:"optional"` // Information pertaining to current state of the delta table. - DeltaRuntimePropertiesKvpairs types.Object `tfsdk:"delta_runtime_properties_kvpairs" tf:"optional,object"` + DeltaRuntimePropertiesKvpairs types.List `tfsdk:"delta_runtime_properties_kvpairs" tf:"optional,object"` - EffectivePredictiveOptimizationFlag types.Object `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` + EffectivePredictiveOptimizationFlag types.List `tfsdk:"effective_predictive_optimization_flag" tf:"optional,object"` // Whether predictive optimization should be enabled for this object and // objects under it. EnablePredictiveOptimization types.String `tfsdk:"enable_predictive_optimization" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.List `tfsdk:"encryption_details" tf:"optional,object"` // Full name of table, in form of // __catalog_name__.__schema_name__.__table_name__ FullName types.String `tfsdk:"full_name" tf:"optional"` @@ -4878,7 +7137,7 @@ type TableInfo struct { // A map of key-value properties attached to the securable. Properties types.Map `tfsdk:"properties" tf:"optional"` - RowFilter types.Object `tfsdk:"row_filter" tf:"optional,object"` + RowFilter types.List `tfsdk:"row_filter" tf:"optional,object"` // Name of parent schema relative to its parent catalog. SchemaName types.String `tfsdk:"schema_name" tf:"optional"` // List of schemes whose objects can be referenced without qualification. @@ -4907,7 +7166,7 @@ type TableInfo struct { // provided; - when DependencyList is an empty list, the dependency is // provided but is empty; - when DependencyList is not an empty list, // dependencies are provided and recorded. - ViewDependencies types.Object `tfsdk:"view_dependencies" tf:"optional,object"` + ViewDependencies types.List `tfsdk:"view_dependencies" tf:"optional,object"` } func (newState *TableInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableInfo) { @@ -4922,13 +7181,58 @@ func (a TableInfo) GetComplexFieldTypes() map[string]reflect.Type { "DeltaRuntimePropertiesKvpairs": reflect.TypeOf(DeltaRuntimePropertiesKvPairs{}), "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), - "Properties": reflect.TypeOf(""), + "Properties": reflect.TypeOf(types.StringType), "RowFilter": reflect.TypeOf(TableRowFilter{}), "TableConstraints": reflect.TypeOf(TableConstraint{}), "ViewDependencies": reflect.TypeOf(DependencyList{}), } } +func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessPoint": types.StringType, + "BrowseOnly": types.BoolType, + "CatalogName": types.StringType, + "Columns": basetypes.ListType{ + ElemType: ColumnInfo{}.ToAttrType(ctx), + }, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DataAccessConfigurationId": types.StringType, + "DataSourceFormat": types.StringType, + "DeletedAt": types.Int64Type, + "DeltaRuntimePropertiesKvpairs": DeltaRuntimePropertiesKvPairs{}.ToAttrType(ctx), + "EffectivePredictiveOptimizationFlag": EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + "EnablePredictiveOptimization": types.StringType, + "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), + "FullName": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "PipelineId": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "RowFilter": TableRowFilter{}.ToAttrType(ctx), + "SchemaName": types.StringType, + "SqlPath": types.StringType, + "StorageCredentialName": types.StringType, + "StorageLocation": types.StringType, + "TableConstraints": basetypes.ListType{ + ElemType: TableConstraint{}.ToAttrType(ctx), + }, + "TableId": types.StringType, + "TableType": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "ViewDefinition": types.StringType, + "ViewDependencies": DependencyList{}.ToAttrType(ctx), + }, + } +} + type TableRowFilter struct { // The full name of the row filter SQL UDF. FunctionName types.String `tfsdk:"function_name" tf:""` @@ -4946,7 +7250,18 @@ func (newState *TableRowFilter) SyncEffectiveFieldsDuringRead(existingState Tabl func (a TableRowFilter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InputColumnNames": reflect.TypeOf(""), + "InputColumnNames": reflect.TypeOf(types.StringType), + } +} + +func (a TableRowFilter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FunctionName": types.StringType, + "InputColumnNames": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -4967,14 +7282,23 @@ func (a TableSummary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TableSummary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "TableType": types.StringType, + }, + } +} + type TemporaryCredentials struct { // AWS temporary credentials for API authentication. Read more at // https://docs.aws.amazon.com/STS/latest/APIReference/API_Credentials.html. - AwsTempCredentials types.Object `tfsdk:"aws_temp_credentials" tf:"optional,object"` + AwsTempCredentials types.List `tfsdk:"aws_temp_credentials" tf:"optional,object"` // Azure Active Directory token, essentially the Oauth token for Azure // Service Principal or Managed Identity. Read more at // https://learn.microsoft.com/en-us/azure/databricks/dev-tools/api/latest/aad/service-prin-aad-token - AzureAad types.Object `tfsdk:"azure_aad" tf:"optional,object"` + AzureAad types.List `tfsdk:"azure_aad" tf:"optional,object"` // Server time when the credential will expire, in epoch milliseconds. The // API client is advised to cache the credential given this expiration time. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` @@ -4993,6 +7317,16 @@ func (a TemporaryCredentials) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TemporaryCredentials) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsTempCredentials": AwsCredentials{}.ToAttrType(ctx), + "AzureAad": AzureActiveDirectoryToken{}.ToAttrType(ctx), + "ExpirationTime": types.Int64Type, + }, + } +} + // Detailed status of an online table. Shown if the online table is in the // ONLINE_TRIGGERED_UPDATE or the ONLINE_NO_PENDING_UPDATE state. type TriggeredUpdateStatus struct { @@ -5004,7 +7338,7 @@ type TriggeredUpdateStatus struct { // table to the online table. Timestamp types.String `tfsdk:"timestamp" tf:"optional"` // Progress of the active data synchronization pipeline. - TriggeredUpdateProgress types.Object `tfsdk:"triggered_update_progress" tf:"optional,object"` + TriggeredUpdateProgress types.List `tfsdk:"triggered_update_progress" tf:"optional,object"` } func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan TriggeredUpdateStatus) { @@ -5019,6 +7353,16 @@ func (a TriggeredUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TriggeredUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LastProcessedCommitVersion": types.Int64Type, + "Timestamp": types.StringType, + "TriggeredUpdateProgress": PipelineProgress{}.ToAttrType(ctx), + }, + } +} + // Delete an assignment type UnassignRequest struct { // Query for the ID of the metastore to delete. @@ -5037,6 +7381,15 @@ func (a UnassignRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UnassignRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type UnassignResponse struct { } @@ -5050,6 +7403,12 @@ func (a UnassignResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UnassignResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateAssignmentResponse struct { } @@ -5063,6 +7422,12 @@ func (a UpdateAssignmentResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a UpdateAssignmentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateCatalog struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5090,7 +7455,23 @@ func (newState *UpdateCatalog) SyncEffectiveFieldsDuringRead(existingState Updat func (a UpdateCatalog) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(""), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateCatalog) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "EnablePredictiveOptimization": types.StringType, + "IsolationMode": types.StringType, + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -5113,17 +7494,30 @@ func (newState *UpdateConnection) SyncEffectiveFieldsDuringRead(existingState Up func (a UpdateConnection) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(""), + "Options": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateConnection) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "NewName": types.StringType, + "Options": basetypes.MapType{ + ElemType: types.StringType, + }, + "Owner": types.StringType, + }, } } type UpdateCredentialRequest struct { // The AWS IAM role configuration - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // Force an update even if there are dependent services (when purpose is @@ -5161,6 +7555,24 @@ func (a UpdateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a UpdateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "Comment": types.StringType, + "Force": types.BoolType, + "IsolationMode": types.StringType, + "NameArg": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "ReadOnly": types.BoolType, + "SkipValidation": types.BoolType, + }, + } +} + type UpdateExternalLocation struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -5169,7 +7581,7 @@ type UpdateExternalLocation struct { // Name of the storage credential used with this location. CredentialName types.String `tfsdk:"credential_name" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.List `tfsdk:"encryption_details" tf:"optional,object"` // Indicates whether fallback mode is enabled for this external location. // When fallback mode is enabled, the access to the location falls back to // cluster credentials if UC credentials are not sufficient. @@ -5206,6 +7618,26 @@ func (a UpdateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessPoint": types.StringType, + "Comment": types.StringType, + "CredentialName": types.StringType, + "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), + "Fallback": types.BoolType, + "Force": types.BoolType, + "IsolationMode": types.StringType, + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "ReadOnly": types.BoolType, + "SkipValidation": types.BoolType, + "Url": types.StringType, + }, + } +} + type UpdateFunction struct { // The fully-qualified name of the function (of the form // __catalog_name__.__schema_name__.__function__name__). @@ -5224,6 +7656,15 @@ func (a UpdateFunction) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateFunction) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Owner": types.StringType, + }, + } +} + type UpdateMetastore struct { // The organization name of a Delta Sharing entity, to be used in // Databricks-to-Databricks Delta Sharing as the official name. @@ -5255,6 +7696,21 @@ func (a UpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DeltaSharingOrganizationName": types.StringType, + "DeltaSharingRecipientTokenLifetimeInSeconds": types.Int64Type, + "DeltaSharingScope": types.StringType, + "Id": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "PrivilegeModelVersion": types.StringType, + "StorageRootCredentialId": types.StringType, + }, + } +} + type UpdateMetastoreAssignment struct { // The name of the default catalog in the metastore. This field is // depracted. Please use "Default Namespace API" to configure the default @@ -5276,6 +7732,16 @@ func (a UpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a UpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DefaultCatalogName": types.StringType, + "MetastoreId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type UpdateModelVersionRequest struct { // The comment attached to the model version Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5295,6 +7761,16 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "FullName": types.StringType, + "Version": types.Int64Type, + }, + } +} + type UpdateMonitor struct { // Name of the baseline table from which drift metrics are computed from. // Columns in the monitored table should also be present in the baseline @@ -5308,15 +7784,15 @@ type UpdateMonitor struct { // if the monitor is in PENDING state. DashboardId types.String `tfsdk:"dashboard_id" tf:"optional"` // The data classification config for the monitor. - DataClassificationConfig types.Object `tfsdk:"data_classification_config" tf:"optional,object"` + DataClassificationConfig types.List `tfsdk:"data_classification_config" tf:"optional,object"` // Configuration for monitoring inference logs. - InferenceLog types.Object `tfsdk:"inference_log" tf:"optional,object"` + InferenceLog types.List `tfsdk:"inference_log" tf:"optional,object"` // The notification settings for the monitor. - Notifications types.Object `tfsdk:"notifications" tf:"optional,object"` + Notifications types.List `tfsdk:"notifications" tf:"optional,object"` // Schema where output metric tables are created. OutputSchemaName types.String `tfsdk:"output_schema_name" tf:""` // The schedule for automatically updating and refreshing metric tables. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // List of column expressions to slice data with for targeted analysis. The // data is grouped by each expression independently, resulting in a separate // slice for each predicate and its complements. For high-cardinality @@ -5328,7 +7804,7 @@ type UpdateMonitor struct { // Full name of the table. TableName types.String `tfsdk:"-"` // Configuration for monitoring time series tables. - TimeSeries types.Object `tfsdk:"time_series" tf:"optional,object"` + TimeSeries types.List `tfsdk:"time_series" tf:"optional,object"` } func (newState *UpdateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateMonitor) { @@ -5344,12 +7820,35 @@ func (a UpdateMonitor) GetComplexFieldTypes() map[string]reflect.Type { "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), "Notifications": reflect.TypeOf(MonitorNotifications{}), "Schedule": reflect.TypeOf(MonitorCronSchedule{}), - "SlicingExprs": reflect.TypeOf(""), + "SlicingExprs": reflect.TypeOf(types.StringType), "Snapshot": reflect.TypeOf(MonitorSnapshot{}), "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), } } +func (a UpdateMonitor) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BaselineTableName": types.StringType, + "CustomMetrics": basetypes.ListType{ + ElemType: MonitorMetric{}.ToAttrType(ctx), + }, + "DashboardId": types.StringType, + "DataClassificationConfig": MonitorDataClassificationConfig{}.ToAttrType(ctx), + "InferenceLog": MonitorInferenceLog{}.ToAttrType(ctx), + "Notifications": MonitorNotifications{}.ToAttrType(ctx), + "OutputSchemaName": types.StringType, + "Schedule": MonitorCronSchedule{}.ToAttrType(ctx), + "SlicingExprs": basetypes.ListType{ + ElemType: types.StringType, + }, + "Snapshot": MonitorSnapshot{}.ToAttrType(ctx), + "TableName": types.StringType, + "TimeSeries": MonitorTimeSeries{}.ToAttrType(ctx), + }, + } +} + type UpdatePermissions struct { // Array of permissions change objects. Changes types.List `tfsdk:"changes" tf:"optional"` @@ -5371,6 +7870,18 @@ func (a UpdatePermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdatePermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Changes": basetypes.ListType{ + ElemType: PermissionsChange{}.ToAttrType(ctx), + }, + "FullName": types.StringType, + "SecurableType": types.StringType, + }, + } +} + type UpdateRegisteredModelRequest struct { // The comment attached to the registered model Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5392,6 +7903,17 @@ func (a UpdateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a UpdateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "FullName": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + }, + } +} + type UpdateResponse struct { } @@ -5405,6 +7927,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateSchema struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5429,19 +7957,34 @@ func (newState *UpdateSchema) SyncEffectiveFieldsDuringRead(existingState Update func (a UpdateSchema) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(""), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateSchema) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "EnablePredictiveOptimization": types.StringType, + "FullName": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } type UpdateStorageCredential struct { // The AWS IAM role configuration. - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.List `tfsdk:"cloudflare_api_token" tf:"optional,object"` // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // The Databricks managed GCP service account configuration. @@ -5480,6 +8023,26 @@ func (a UpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type } } +func (a UpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRoleRequest{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentityResponse{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), + "Comment": types.StringType, + "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + "Force": types.BoolType, + "IsolationMode": types.StringType, + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "ReadOnly": types.BoolType, + "SkipValidation": types.BoolType, + }, + } +} + // Update a table owner. type UpdateTableRequest struct { // Full name of the table. @@ -5498,6 +8061,15 @@ func (a UpdateTableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateTableRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullName": types.StringType, + "Owner": types.StringType, + }, + } +} + type UpdateVolumeRequestContent struct { // The comment attached to the volume Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5519,6 +8091,17 @@ func (a UpdateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a UpdateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + }, + } +} + type UpdateWorkspaceBindings struct { // A list of workspace IDs. AssignWorkspaces types.List `tfsdk:"assign_workspaces" tf:"optional"` @@ -5536,8 +8119,22 @@ func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingS func (a UpdateWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AssignWorkspaces": reflect.TypeOf(0), - "UnassignWorkspaces": reflect.TypeOf(0), + "AssignWorkspaces": reflect.TypeOf(types.Int64Type), + "UnassignWorkspaces": reflect.TypeOf(types.Int64Type), + } +} + +func (a UpdateWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AssignWorkspaces": basetypes.ListType{ + ElemType: types.Int64Type, + }, + "Name": types.StringType, + "UnassignWorkspaces": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -5565,11 +8162,26 @@ func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes() map[string]ref } } +func (a UpdateWorkspaceBindingsParameters) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Add": basetypes.ListType{ + ElemType: WorkspaceBinding{}.ToAttrType(ctx), + }, + "Remove": basetypes.ListType{ + ElemType: WorkspaceBinding{}.ToAttrType(ctx), + }, + "SecurableName": types.StringType, + "SecurableType": types.StringType, + }, + } +} + type ValidateCredentialRequest struct { // The AWS IAM role configuration - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // Required. The name of an existing credential or long-lived cloud // credential to validate. CredentialName types.String `tfsdk:"credential_name" tf:"optional"` @@ -5600,6 +8212,20 @@ func (a ValidateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ValidateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), + "CredentialName": types.StringType, + "ExternalLocationName": types.StringType, + "Purpose": types.StringType, + "ReadOnly": types.BoolType, + "Url": types.StringType, + }, + } +} + type ValidateCredentialResponse struct { // Whether the tested location is a directory in cloud storage. Only // applicable for when purpose is **STORAGE**. @@ -5620,15 +8246,26 @@ func (a ValidateCredentialResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ValidateCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsDir": types.BoolType, + "Results": basetypes.ListType{ + ElemType: CredentialValidationResult{}.ToAttrType(ctx), + }, + }, + } +} + type ValidateStorageCredential struct { // The AWS IAM role configuration. - AwsIamRole types.Object `tfsdk:"aws_iam_role" tf:"optional,object"` + AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` // The Azure managed identity configuration. - AzureManagedIdentity types.Object `tfsdk:"azure_managed_identity" tf:"optional,object"` + AzureManagedIdentity types.List `tfsdk:"azure_managed_identity" tf:"optional,object"` // The Azure service principal configuration. - AzureServicePrincipal types.Object `tfsdk:"azure_service_principal" tf:"optional,object"` + AzureServicePrincipal types.List `tfsdk:"azure_service_principal" tf:"optional,object"` // The Cloudflare API token configuration. - CloudflareApiToken types.Object `tfsdk:"cloudflare_api_token" tf:"optional,object"` + CloudflareApiToken types.List `tfsdk:"cloudflare_api_token" tf:"optional,object"` // The Databricks created GCP service account configuration. DatabricksGcpServiceAccount []DatabricksGcpServiceAccountRequest `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // The name of an existing external location to validate. @@ -5657,6 +8294,22 @@ func (a ValidateStorageCredential) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ValidateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsIamRole": AwsIamRoleRequest{}.ToAttrType(ctx), + "AzureManagedIdentity": AzureManagedIdentityRequest{}.ToAttrType(ctx), + "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), + "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), + "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + "ExternalLocationName": types.StringType, + "ReadOnly": types.BoolType, + "StorageCredentialName": types.StringType, + "Url": types.StringType, + }, + } +} + type ValidateStorageCredentialResponse struct { // Whether the tested location is a directory in cloud storage. IsDir types.Bool `tfsdk:"isDir" tf:"optional"` @@ -5676,6 +8329,17 @@ func (a ValidateStorageCredentialResponse) GetComplexFieldTypes() map[string]ref } } +func (a ValidateStorageCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsDir": types.BoolType, + "Results": basetypes.ListType{ + ElemType: ValidationResult{}.ToAttrType(ctx), + }, + }, + } +} + type ValidationResult struct { // Error message would exist when the result does not equal to **PASS**. Message types.String `tfsdk:"message" tf:"optional"` @@ -5695,6 +8359,16 @@ func (a ValidationResult) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ValidationResult) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + "Operation": types.StringType, + "Result": types.StringType, + }, + } +} + type VolumeInfo struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -5711,7 +8385,7 @@ type VolumeInfo struct { // The identifier of the user who created the volume CreatedBy types.String `tfsdk:"created_by" tf:"optional"` // Encryption options that apply to clients connecting to cloud storage. - EncryptionDetails types.Object `tfsdk:"encryption_details" tf:"optional,object"` + EncryptionDetails types.List `tfsdk:"encryption_details" tf:"optional,object"` // The three-level (fully qualified) name of the volume FullName types.String `tfsdk:"full_name" tf:"optional"` // The unique identifier of the metastore @@ -5746,6 +8420,30 @@ func (a VolumeInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a VolumeInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessPoint": types.StringType, + "BrowseOnly": types.BoolType, + "CatalogName": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), + "FullName": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "SchemaName": types.StringType, + "StorageLocation": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "VolumeId": types.StringType, + "VolumeType": types.StringType, + }, + } +} + type WorkspaceBinding struct { BindingType types.String `tfsdk:"binding_type" tf:"optional"` @@ -5762,6 +8460,15 @@ func (a WorkspaceBinding) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a WorkspaceBinding) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BindingType": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + // Currently assigned workspace bindings type WorkspaceBindingsResponse struct { // List of workspace bindings @@ -5783,3 +8490,14 @@ func (a WorkspaceBindingsResponse) GetComplexFieldTypes() map[string]reflect.Typ "Bindings": reflect.TypeOf(WorkspaceBinding{}), } } + +func (a WorkspaceBindingsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Bindings": basetypes.ListType{ + ElemType: WorkspaceBinding{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 47f3431f2e..7742acceb3 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package compute_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AddInstanceProfile struct { @@ -55,6 +58,17 @@ func (a AddInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AddInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IamRoleArn": types.StringType, + "InstanceProfileArn": types.StringType, + "IsMetaInstanceProfile": types.BoolType, + "SkipValidation": types.BoolType, + }, + } +} + type AddResponse struct { } @@ -68,6 +82,12 @@ func (a AddResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AddResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Adlsgen2Info struct { // abfss destination, e.g. // `abfss://@.dfs.core.windows.net/`. @@ -84,6 +104,14 @@ func (a Adlsgen2Info) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Adlsgen2Info) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Destination": types.StringType, + }, + } +} + type AutoScale struct { // The maximum number of workers to which the cluster can scale up when // overloaded. Note that `max_workers` must be strictly greater than @@ -105,6 +133,15 @@ func (a AutoScale) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AutoScale) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxWorkers": types.Int64Type, + "MinWorkers": types.Int64Type, + }, + } +} + type AwsAttributes struct { // Availability type used for all subsequent nodes past the // `first_on_demand` ones. @@ -201,6 +238,23 @@ func (a AwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Availability": types.StringType, + "EbsVolumeCount": types.Int64Type, + "EbsVolumeIops": types.Int64Type, + "EbsVolumeSize": types.Int64Type, + "EbsVolumeThroughput": types.Int64Type, + "EbsVolumeType": types.StringType, + "FirstOnDemand": types.Int64Type, + "InstanceProfileArn": types.StringType, + "SpotBidPricePercent": types.Int64Type, + "ZoneId": types.StringType, + }, + } +} + type AzureAttributes struct { // Availability type used for all subsequent nodes past the // `first_on_demand` ones. Note: If `first_on_demand` is zero (which only @@ -218,7 +272,7 @@ type AzureAttributes struct { // mutated over the lifetime of a cluster. FirstOnDemand types.Int64 `tfsdk:"first_on_demand" tf:"optional"` // Defines values necessary to configure and run Azure Log Analytics agent - LogAnalyticsInfo types.Object `tfsdk:"log_analytics_info" tf:"optional,object"` + LogAnalyticsInfo types.List `tfsdk:"log_analytics_info" tf:"optional,object"` // The max bid price to be used for Azure spot instances. The Max price for // the bid cannot be higher than the on-demand price of the instance. If not // specified, the default value is -1, which specifies that the instance @@ -239,6 +293,17 @@ func (a AzureAttributes) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Availability": types.StringType, + "FirstOnDemand": types.Int64Type, + "LogAnalyticsInfo": LogAnalyticsInfo{}.ToAttrType(ctx), + "SpotBidMaxPrice": types.Float64Type, + }, + } +} + type CancelCommand struct { ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -257,6 +322,16 @@ func (a CancelCommand) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelCommand) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "CommandId": types.StringType, + "ContextId": types.StringType, + }, + } +} + type CancelResponse struct { } @@ -270,6 +345,12 @@ func (a CancelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ChangeClusterOwner struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -287,6 +368,15 @@ func (a ChangeClusterOwner) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ChangeClusterOwner) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "OwnerUsername": types.StringType, + }, + } +} + type ChangeClusterOwnerResponse struct { } @@ -300,6 +390,12 @@ func (a ChangeClusterOwnerResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a ChangeClusterOwnerResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ClientsTypes struct { // With jobs set, the cluster can be used for jobs Jobs types.Bool `tfsdk:"jobs" tf:"optional"` @@ -317,6 +413,15 @@ func (a ClientsTypes) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ClientsTypes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Jobs": types.BoolType, + "Notebooks": types.BoolType, + }, + } +} + type CloneCluster struct { // The cluster that is being cloned. SourceClusterId types.String `tfsdk:"source_cluster_id" tf:""` @@ -332,6 +437,14 @@ func (a CloneCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CloneCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "SourceClusterId": types.StringType, + }, + } +} + type CloudProviderNodeInfo struct { Status types.List `tfsdk:"status" tf:"optional"` } @@ -344,7 +457,17 @@ func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringRead(existingSta func (a CloudProviderNodeInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Status": reflect.TypeOf(""), + "Status": reflect.TypeOf(types.StringType), + } +} + +func (a CloudProviderNodeInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Status": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -369,6 +492,17 @@ func (a ClusterAccessControlRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a ClusterAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ClusterAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -394,6 +528,20 @@ func (a ClusterAccessControlResponse) GetComplexFieldTypes() map[string]reflect. } } +func (a ClusterAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: ClusterPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ClusterAttributes struct { // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically @@ -403,17 +551,17 @@ type ClusterAttributes struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -450,7 +598,7 @@ type ClusterAttributes struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.List `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -468,7 +616,7 @@ type ClusterAttributes struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -524,7 +672,7 @@ type ClusterAttributes struct { // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.List `tfsdk:"workload_type" tf:"optional,object"` } func (newState *ClusterAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterAttributes) { @@ -538,17 +686,58 @@ func (a ClusterAttributes) GetComplexFieldTypes() map[string]reflect.Type { "AwsAttributes": reflect.TypeOf(AwsAttributes{}), "AzureAttributes": reflect.TypeOf(AzureAttributes{}), "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "DockerImage": reflect.TypeOf(DockerImage{}), "GcpAttributes": reflect.TypeOf(GcpAttributes{}), "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), - "SshPublicKeys": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), + "SshPublicKeys": reflect.TypeOf(types.StringType), "WorkloadType": reflect.TypeOf(WorkloadType{}), } } +func (a ClusterAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoterminationMinutes": types.Int64Type, + "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), + "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), + "ClusterName": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DataSecurityMode": types.StringType, + "DockerImage": DockerImage{}.ToAttrType(ctx), + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableElasticDisk": types.BoolType, + "EnableLocalDiskEncryption": types.BoolType, + "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "NodeTypeId": types.StringType, + "PolicyId": types.StringType, + "RuntimeEngine": types.StringType, + "SingleUserName": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkVersion": types.StringType, + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "WorkloadType": WorkloadType{}.ToAttrType(ctx), + }, + } +} + type ClusterCompliance struct { // Canonical unique identifier for a cluster. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -570,7 +759,19 @@ func (newState *ClusterCompliance) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterCompliance) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(""), + "Violations": reflect.TypeOf(types.StringType), + } +} + +func (a ClusterCompliance) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "IsCompliant": types.BoolType, + "Violations": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -578,7 +779,7 @@ type ClusterDetails struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -587,10 +788,10 @@ type ClusterDetails struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // Number of CPU cores available for this cluster. Note that this can be // fractional, e.g. 7.5 cores, since certain node types are configured to // share cores between Spark nodes on the same instance. @@ -604,9 +805,9 @@ type ClusterDetails struct { // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster log delivery status. - ClusterLogStatus types.Object `tfsdk:"cluster_log_status" tf:"optional,object"` + ClusterLogStatus types.List `tfsdk:"cluster_log_status" tf:"optional,object"` // Total amount of cluster memory, in megabytes ClusterMemoryMb types.Int64 `tfsdk:"cluster_memory_mb" tf:"optional"` // Cluster name requested by the user. This doesn't have to be unique. If @@ -665,11 +866,11 @@ type ClusterDetails struct { // - Name: DefaultTags types.Map `tfsdk:"default_tags" tf:"optional"` - DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.List `tfsdk:"docker_image" tf:"optional,object"` // Node on which the Spark driver resides. The driver node contains the // Spark master and the Databricks application that manages the per-notebook // Spark REPLs. - Driver types.Object `tfsdk:"driver" tf:"optional,object"` + Driver types.List `tfsdk:"driver" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -689,7 +890,7 @@ type ClusterDetails struct { Executors types.List `tfsdk:"executors" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -767,7 +968,7 @@ type ClusterDetails struct { // or edit this cluster. The contents of `spec` can be used in the body of a // create cluster request. This field might not be populated for older // clusters. Note: not included in the response of the ListClusters API. - Spec types.Object `tfsdk:"spec" tf:"optional,object"` + Spec types.List `tfsdk:"spec" tf:"optional,object"` // SSH public key contents that will be added to each Spark node in this // cluster. The corresponding private keys can be used to login with the // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. @@ -785,9 +986,9 @@ type ClusterDetails struct { TerminatedTime types.Int64 `tfsdk:"terminated_time" tf:"optional"` // Information about why the cluster was terminated. This field only appears // when the cluster is in a `TERMINATING` or `TERMINATED` state. - TerminationReason types.Object `tfsdk:"termination_reason" tf:"optional,object"` + TerminationReason types.List `tfsdk:"termination_reason" tf:"optional,object"` - WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.List `tfsdk:"workload_type" tf:"optional,object"` } func (newState *ClusterDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterDetails) { @@ -803,29 +1004,95 @@ func (a ClusterDetails) GetComplexFieldTypes() map[string]reflect.Type { "AzureAttributes": reflect.TypeOf(AzureAttributes{}), "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), "ClusterLogStatus": reflect.TypeOf(LogSyncStatus{}), - "CustomTags": reflect.TypeOf(""), - "DefaultTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), + "DefaultTags": reflect.TypeOf(types.StringType), "DockerImage": reflect.TypeOf(DockerImage{}), "Driver": reflect.TypeOf(SparkNode{}), "Executors": reflect.TypeOf(SparkNode{}), "GcpAttributes": reflect.TypeOf(GcpAttributes{}), "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), "Spec": reflect.TypeOf(ClusterSpec{}), - "SshPublicKeys": reflect.TypeOf(""), + "SshPublicKeys": reflect.TypeOf(types.StringType), "TerminationReason": reflect.TypeOf(TerminationReason{}), "WorkloadType": reflect.TypeOf(WorkloadType{}), } } +func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Autoscale": AutoScale{}.ToAttrType(ctx), + "AutoterminationMinutes": types.Int64Type, + "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), + "ClusterCores": types.Float64Type, + "ClusterId": types.StringType, + "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), + "ClusterLogStatus": LogSyncStatus{}.ToAttrType(ctx), + "ClusterMemoryMb": types.Int64Type, + "ClusterName": types.StringType, + "ClusterSource": types.StringType, + "CreatorUserName": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DataSecurityMode": types.StringType, + "DefaultTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DockerImage": DockerImage{}.ToAttrType(ctx), + "Driver": SparkNode{}.ToAttrType(ctx), + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableElasticDisk": types.BoolType, + "EnableLocalDiskEncryption": types.BoolType, + "Executors": basetypes.ListType{ + ElemType: SparkNode{}.ToAttrType(ctx), + }, + "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "JdbcPort": types.Int64Type, + "LastRestartedTime": types.Int64Type, + "LastStateLossTime": types.Int64Type, + "NodeTypeId": types.StringType, + "NumWorkers": types.Int64Type, + "PolicyId": types.StringType, + "RuntimeEngine": types.StringType, + "SingleUserName": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkContextId": types.Int64Type, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkVersion": types.StringType, + "Spec": ClusterSpec{}.ToAttrType(ctx), + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "StartTime": types.Int64Type, + "State": types.StringType, + "StateMessage": types.StringType, + "TerminatedTime": types.Int64Type, + "TerminationReason": TerminationReason{}.ToAttrType(ctx), + "WorkloadType": WorkloadType{}.ToAttrType(ctx), + }, + } +} + type ClusterEvent struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` // - DataPlaneEventDetails types.Object `tfsdk:"data_plane_event_details" tf:"optional,object"` + DataPlaneEventDetails types.List `tfsdk:"data_plane_event_details" tf:"optional,object"` // - Details types.Object `tfsdk:"details" tf:"optional,object"` + Details types.List `tfsdk:"details" tf:"optional,object"` // The timestamp when the event occurred, stored as the number of // milliseconds since the Unix epoch. If not provided, this will be assigned // by the Timeline service. @@ -847,6 +1114,18 @@ func (a ClusterEvent) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ClusterEvent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "DataPlaneEventDetails": DataPlaneEventDetails{}.ToAttrType(ctx), + "Details": EventDetails{}.ToAttrType(ctx), + "Timestamp": types.Int64Type, + "Type": types.StringType, + }, + } +} + type ClusterLibraryStatuses struct { // Unique identifier for the cluster. ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` @@ -866,16 +1145,27 @@ func (a ClusterLibraryStatuses) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ClusterLibraryStatuses) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "LibraryStatuses": basetypes.ListType{ + ElemType: LibraryFullStatus{}.ToAttrType(ctx), + }, + }, + } +} + type ClusterLogConf struct { // destination needs to be provided. e.g. `{ "dbfs" : { "destination" : // "dbfs:/home/cluster_log" } }` - Dbfs types.Object `tfsdk:"dbfs" tf:"optional,object"` + Dbfs types.List `tfsdk:"dbfs" tf:"optional,object"` // destination and either the region or endpoint need to be provided. e.g. // `{ "s3": { "destination" : "s3://cluster_log_bucket/prefix", "region" : // "us-west-2" } }` Cluster iam role is used to access s3, please make sure // the cluster iam role in `instance_profile_arn` has permission to write // data to the s3 destination. - S3 types.Object `tfsdk:"s3" tf:"optional,object"` + S3 types.List `tfsdk:"s3" tf:"optional,object"` } func (newState *ClusterLogConf) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterLogConf) { @@ -891,6 +1181,15 @@ func (a ClusterLogConf) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ClusterLogConf) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Dbfs": DbfsStorageInfo{}.ToAttrType(ctx), + "S3": S3StorageInfo{}.ToAttrType(ctx), + }, + } +} + type ClusterPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -907,7 +1206,19 @@ func (newState *ClusterPermission) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a ClusterPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -931,6 +1242,18 @@ func (a ClusterPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ClusterPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ClusterAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type ClusterPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -947,6 +1270,15 @@ func (a ClusterPermissionsDescription) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a ClusterPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type ClusterPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The cluster for which to get or manage permissions. @@ -965,6 +1297,17 @@ func (a ClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ClusterAccessControlRequest{}.ToAttrType(ctx), + }, + "ClusterId": types.StringType, + }, + } +} + type ClusterPolicyAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -986,6 +1329,17 @@ func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a ClusterPolicyAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ClusterPolicyAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -1011,6 +1365,20 @@ func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes() map[string]re } } +func (a ClusterPolicyAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: ClusterPolicyPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ClusterPolicyPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1027,7 +1395,19 @@ func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringRead(existingS func (a ClusterPolicyPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a ClusterPolicyPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1051,6 +1431,18 @@ func (a ClusterPolicyPermissions) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ClusterPolicyPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ClusterPolicyAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type ClusterPolicyPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1067,6 +1459,15 @@ func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a ClusterPolicyPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type ClusterPolicyPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The cluster policy for which to get or manage permissions. @@ -1085,6 +1486,17 @@ func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]refle } } +func (a ClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ClusterPolicyAccessControlRequest{}.ToAttrType(ctx), + }, + "ClusterPolicyId": types.StringType, + }, + } +} + // Represents a change to the cluster settings required for the cluster to // become compliant with its policy. type ClusterSettingsChange struct { @@ -1112,11 +1524,21 @@ func (a ClusterSettingsChange) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Field": types.StringType, + "NewValue": types.StringType, + "PreviousValue": types.StringType, + }, + } +} + type ClusterSize struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Number of worker nodes that this cluster should have. A cluster has one // Spark Driver and `num_workers` Executors for a total of `num_workers` + 1 // Spark nodes. @@ -1142,6 +1564,15 @@ func (a ClusterSize) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ClusterSize) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Autoscale": AutoScale{}.ToAttrType(ctx), + "NumWorkers": types.Int64Type, + }, + } +} + type ClusterSpec struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -1150,7 +1581,7 @@ type ClusterSpec struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -1159,17 +1590,17 @@ type ClusterSpec struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -1206,7 +1637,7 @@ type ClusterSpec struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.List `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -1224,7 +1655,7 @@ type ClusterSpec struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -1291,7 +1722,7 @@ type ClusterSpec struct { // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.List `tfsdk:"workload_type" tf:"optional,object"` } func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterSpec) { @@ -1306,17 +1737,61 @@ func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { "AwsAttributes": reflect.TypeOf(AwsAttributes{}), "AzureAttributes": reflect.TypeOf(AzureAttributes{}), "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "DockerImage": reflect.TypeOf(DockerImage{}), "GcpAttributes": reflect.TypeOf(GcpAttributes{}), "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), - "SshPublicKeys": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), + "SshPublicKeys": reflect.TypeOf(types.StringType), "WorkloadType": reflect.TypeOf(WorkloadType{}), } } +func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyPolicyDefaultValues": types.BoolType, + "Autoscale": AutoScale{}.ToAttrType(ctx), + "AutoterminationMinutes": types.Int64Type, + "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), + "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), + "ClusterName": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DataSecurityMode": types.StringType, + "DockerImage": DockerImage{}.ToAttrType(ctx), + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableElasticDisk": types.BoolType, + "EnableLocalDiskEncryption": types.BoolType, + "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "NodeTypeId": types.StringType, + "NumWorkers": types.Int64Type, + "PolicyId": types.StringType, + "RuntimeEngine": types.StringType, + "SingleUserName": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkVersion": types.StringType, + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "WorkloadType": WorkloadType{}.ToAttrType(ctx), + }, + } +} + // Get status type ClusterStatus struct { // Unique identifier of the cluster whose status should be retrieved. @@ -1333,6 +1808,14 @@ func (a ClusterStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ClusterStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type Command struct { // Running cluster id ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -1354,6 +1837,17 @@ func (a Command) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Command) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "Command": types.StringType, + "ContextId": types.StringType, + "Language": types.StringType, + }, + } +} + // Get command info type CommandStatusRequest struct { ClusterId types.String `tfsdk:"-"` @@ -1373,10 +1867,20 @@ func (a CommandStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CommandStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "CommandId": types.StringType, + "ContextId": types.StringType, + }, + } +} + type CommandStatusResponse struct { Id types.String `tfsdk:"id" tf:"optional"` - Results types.Object `tfsdk:"results" tf:"optional,object"` + Results types.List `tfsdk:"results" tf:"optional,object"` Status types.String `tfsdk:"status" tf:"optional"` } @@ -1393,6 +1897,16 @@ func (a CommandStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CommandStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Results": Results{}.ToAttrType(ctx), + "Status": types.StringType, + }, + } +} + // Get status type ContextStatusRequest struct { ClusterId types.String `tfsdk:"-"` @@ -1410,6 +1924,15 @@ func (a ContextStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ContextStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "ContextId": types.StringType, + }, + } +} + type ContextStatusResponse struct { Id types.String `tfsdk:"id" tf:"optional"` @@ -1426,6 +1949,15 @@ func (a ContextStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ContextStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Status": types.StringType, + }, + } +} + type CreateCluster struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -1434,7 +1966,7 @@ type CreateCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -1443,20 +1975,20 @@ type CreateCluster struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // When specified, this clones libraries from a source cluster during the // creation of a new cluster. - CloneFrom types.Object `tfsdk:"clone_from" tf:"optional,object"` + CloneFrom types.List `tfsdk:"clone_from" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -1493,7 +2025,7 @@ type CreateCluster struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.List `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -1511,7 +2043,7 @@ type CreateCluster struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -1578,7 +2110,7 @@ type CreateCluster struct { // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.List `tfsdk:"workload_type" tf:"optional,object"` } func (newState *CreateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCluster) { @@ -1594,17 +2126,62 @@ func (a CreateCluster) GetComplexFieldTypes() map[string]reflect.Type { "AzureAttributes": reflect.TypeOf(AzureAttributes{}), "CloneFrom": reflect.TypeOf(CloneCluster{}), "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "DockerImage": reflect.TypeOf(DockerImage{}), "GcpAttributes": reflect.TypeOf(GcpAttributes{}), "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), - "SshPublicKeys": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), + "SshPublicKeys": reflect.TypeOf(types.StringType), "WorkloadType": reflect.TypeOf(WorkloadType{}), } } +func (a CreateCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyPolicyDefaultValues": types.BoolType, + "Autoscale": AutoScale{}.ToAttrType(ctx), + "AutoterminationMinutes": types.Int64Type, + "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), + "CloneFrom": CloneCluster{}.ToAttrType(ctx), + "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), + "ClusterName": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DataSecurityMode": types.StringType, + "DockerImage": DockerImage{}.ToAttrType(ctx), + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableElasticDisk": types.BoolType, + "EnableLocalDiskEncryption": types.BoolType, + "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "NodeTypeId": types.StringType, + "NumWorkers": types.Int64Type, + "PolicyId": types.StringType, + "RuntimeEngine": types.StringType, + "SingleUserName": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkVersion": types.StringType, + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "WorkloadType": WorkloadType{}.ToAttrType(ctx), + }, + } +} + type CreateClusterResponse struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` } @@ -1619,6 +2196,14 @@ func (a CreateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type CreateContext struct { // Running cluster id ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -1636,13 +2221,22 @@ func (a CreateContext) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateContext) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "Language": types.StringType, + }, + } +} + type CreateInstancePool struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to instance pools running on Azure. If not specified // at pool creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: @@ -1651,7 +2245,7 @@ type CreateInstancePool struct { CustomTags types.Map `tfsdk:"custom_tags" tf:"optional"` // Defines the specification of the disks that will be attached to all spark // containers. - DiskSpec types.Object `tfsdk:"disk_spec" tf:"optional,object"` + DiskSpec types.List `tfsdk:"disk_spec" tf:"optional,object"` // Autoscaling Local Storage: when enabled, this instances in this pool will // dynamically acquire additional disk space when its Spark workers are // running low on disk space. In AWS, this feature requires specific AWS @@ -1660,7 +2254,7 @@ type CreateInstancePool struct { EnableElasticDisk types.Bool `tfsdk:"enable_elastic_disk" tf:"optional"` // Attributes related to instance pools running on Google Cloud Platform. If // not specified at pool creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -1703,11 +2297,37 @@ func (a CreateInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "DiskSpec": reflect.TypeOf(DiskSpec{}), "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), - "PreloadedSparkVersions": reflect.TypeOf(""), + "PreloadedSparkVersions": reflect.TypeOf(types.StringType), + } +} + +func (a CreateInstancePool) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsAttributes": InstancePoolAwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": InstancePoolAzureAttributes{}.ToAttrType(ctx), + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DiskSpec": DiskSpec{}.ToAttrType(ctx), + "EnableElasticDisk": types.BoolType, + "GcpAttributes": InstancePoolGcpAttributes{}.ToAttrType(ctx), + "IdleInstanceAutoterminationMinutes": types.Int64Type, + "InstancePoolName": types.StringType, + "MaxCapacity": types.Int64Type, + "MinIdleInstances": types.Int64Type, + "NodeTypeId": types.StringType, + "PreloadedDockerImages": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "PreloadedSparkVersions": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1726,6 +2346,14 @@ func (a CreateInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a CreateInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstancePoolId": types.StringType, + }, + } +} + type CreatePolicy struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -1774,6 +2402,22 @@ func (a CreatePolicy) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreatePolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Definition": types.StringType, + "Description": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: Library{}.ToAttrType(ctx), + }, + "MaxClustersPerUser": types.Int64Type, + "Name": types.StringType, + "PolicyFamilyDefinitionOverrides": types.StringType, + "PolicyFamilyId": types.StringType, + }, + } +} + type CreatePolicyResponse struct { // Canonical unique identifier for the cluster policy. PolicyId types.String `tfsdk:"policy_id" tf:"optional"` @@ -1789,6 +2433,14 @@ func (a CreatePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreatePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PolicyId": types.StringType, + }, + } +} + type CreateResponse struct { // The global init script ID. ScriptId types.String `tfsdk:"script_id" tf:"optional"` @@ -1804,6 +2456,14 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ScriptId": types.StringType, + }, + } +} + type Created struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -1818,6 +2478,14 @@ func (a Created) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Created) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DataPlaneEventDetails struct { // EventType types.String `tfsdk:"event_type" tf:"optional"` @@ -1839,6 +2507,17 @@ func (a DataPlaneEventDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DataPlaneEventDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EventType": types.StringType, + "ExecutorFailures": types.Int64Type, + "HostId": types.StringType, + "Timestamp": types.Int64Type, + }, + } +} + type DbfsStorageInfo struct { // dbfs destination, e.g. `dbfs:/my/path` Destination types.String `tfsdk:"destination" tf:""` @@ -1854,6 +2533,14 @@ func (a DbfsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DbfsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Destination": types.StringType, + }, + } +} + type DeleteCluster struct { // The cluster to be terminated. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -1869,6 +2556,14 @@ func (a DeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type DeleteClusterResponse struct { } @@ -1882,6 +2577,12 @@ func (a DeleteClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete init script type DeleteGlobalInitScriptRequest struct { // The ID of the global init script. @@ -1898,6 +2599,14 @@ func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a DeleteGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ScriptId": types.StringType, + }, + } +} + type DeleteInstancePool struct { // The instance pool to be terminated. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:""` @@ -1913,6 +2622,14 @@ func (a DeleteInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteInstancePool) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstancePoolId": types.StringType, + }, + } +} + type DeleteInstancePoolResponse struct { } @@ -1926,6 +2643,12 @@ func (a DeleteInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeletePolicy struct { // The ID of the policy to delete. PolicyId types.String `tfsdk:"policy_id" tf:""` @@ -1941,6 +2664,14 @@ func (a DeletePolicy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeletePolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PolicyId": types.StringType, + }, + } +} + type DeletePolicyResponse struct { } @@ -1954,6 +2685,12 @@ func (a DeletePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeletePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteResponse struct { } @@ -1967,6 +2704,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DestroyContext struct { ClusterId types.String `tfsdk:"clusterId" tf:""` @@ -1983,6 +2726,15 @@ func (a DestroyContext) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DestroyContext) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "ContextId": types.StringType, + }, + } +} + type DestroyResponse struct { } @@ -1996,6 +2748,12 @@ func (a DestroyResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DestroyResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DiskSpec struct { // The number of disks launched for each instance: - This feature is only // enabled for supported node types. - Users can choose up to the limit of @@ -2028,7 +2786,7 @@ type DiskSpec struct { DiskThroughput types.Int64 `tfsdk:"disk_throughput" tf:"optional"` // The type of disks that will be launched with this cluster. - DiskType types.Object `tfsdk:"disk_type" tf:"optional,object"` + DiskType types.List `tfsdk:"disk_type" tf:"optional,object"` } func (newState *DiskSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskSpec) { @@ -2043,6 +2801,18 @@ func (a DiskSpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DiskSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DiskCount": types.Int64Type, + "DiskIops": types.Int64Type, + "DiskSize": types.Int64Type, + "DiskThroughput": types.Int64Type, + "DiskType": DiskType{}.ToAttrType(ctx), + }, + } +} + type DiskType struct { AzureDiskVolumeType types.String `tfsdk:"azure_disk_volume_type" tf:"optional"` @@ -2059,6 +2829,15 @@ func (a DiskType) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DiskType) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AzureDiskVolumeType": types.StringType, + "EbsVolumeType": types.StringType, + }, + } +} + type DockerBasicAuth struct { // Password of the user Password types.String `tfsdk:"password" tf:"optional"` @@ -2076,8 +2855,17 @@ func (a DockerBasicAuth) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DockerBasicAuth) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Password": types.StringType, + "Username": types.StringType, + }, + } +} + type DockerImage struct { - BasicAuth types.Object `tfsdk:"basic_auth" tf:"optional,object"` + BasicAuth types.List `tfsdk:"basic_auth" tf:"optional,object"` // URL of the docker image. Url types.String `tfsdk:"url" tf:"optional"` } @@ -2094,6 +2882,15 @@ func (a DockerImage) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DockerImage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BasicAuth": DockerBasicAuth{}.ToAttrType(ctx), + "Url": types.StringType, + }, + } +} + type EditCluster struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -2102,7 +2899,7 @@ type EditCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -2111,10 +2908,10 @@ type EditCluster struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // ID of the cluster ClusterId types.String `tfsdk:"cluster_id" tf:""` // The configuration for delivering spark logs to a long-term storage @@ -2123,7 +2920,7 @@ type EditCluster struct { // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -2160,7 +2957,7 @@ type EditCluster struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.List `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -2178,7 +2975,7 @@ type EditCluster struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -2245,7 +3042,7 @@ type EditCluster struct { // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.List `tfsdk:"workload_type" tf:"optional,object"` } func (newState *EditCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditCluster) { @@ -2260,17 +3057,62 @@ func (a EditCluster) GetComplexFieldTypes() map[string]reflect.Type { "AwsAttributes": reflect.TypeOf(AwsAttributes{}), "AzureAttributes": reflect.TypeOf(AzureAttributes{}), "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "DockerImage": reflect.TypeOf(DockerImage{}), "GcpAttributes": reflect.TypeOf(GcpAttributes{}), "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), - "SshPublicKeys": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), + "SshPublicKeys": reflect.TypeOf(types.StringType), "WorkloadType": reflect.TypeOf(WorkloadType{}), } } +func (a EditCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyPolicyDefaultValues": types.BoolType, + "Autoscale": AutoScale{}.ToAttrType(ctx), + "AutoterminationMinutes": types.Int64Type, + "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), + "ClusterId": types.StringType, + "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), + "ClusterName": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DataSecurityMode": types.StringType, + "DockerImage": DockerImage{}.ToAttrType(ctx), + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableElasticDisk": types.BoolType, + "EnableLocalDiskEncryption": types.BoolType, + "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "NodeTypeId": types.StringType, + "NumWorkers": types.Int64Type, + "PolicyId": types.StringType, + "RuntimeEngine": types.StringType, + "SingleUserName": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkVersion": types.StringType, + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "WorkloadType": WorkloadType{}.ToAttrType(ctx), + }, + } +} + type EditClusterResponse struct { } @@ -2284,6 +3126,12 @@ func (a EditClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EditClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EditInstancePool struct { // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in @@ -2326,7 +3174,23 @@ func (newState *EditInstancePool) SyncEffectiveFieldsDuringRead(existingState Ed func (a EditInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), + } +} + +func (a EditInstancePool) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "IdleInstanceAutoterminationMinutes": types.Int64Type, + "InstancePoolId": types.StringType, + "InstancePoolName": types.StringType, + "MaxCapacity": types.Int64Type, + "MinIdleInstances": types.Int64Type, + "NodeTypeId": types.StringType, + }, } } @@ -2343,6 +3207,12 @@ func (a EditInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a EditInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EditPolicy struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -2393,6 +3263,23 @@ func (a EditPolicy) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EditPolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Definition": types.StringType, + "Description": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: Library{}.ToAttrType(ctx), + }, + "MaxClustersPerUser": types.Int64Type, + "Name": types.StringType, + "PolicyFamilyDefinitionOverrides": types.StringType, + "PolicyFamilyId": types.StringType, + "PolicyId": types.StringType, + }, + } +} + type EditPolicyResponse struct { } @@ -2406,6 +3293,12 @@ func (a EditPolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EditPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EditResponse struct { } @@ -2419,6 +3312,12 @@ func (a EditResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EditResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EnforceClusterComplianceRequest struct { // The ID of the cluster you want to enforce policy compliance on. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -2437,6 +3336,15 @@ func (a EnforceClusterComplianceRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a EnforceClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "ValidateOnly": types.BoolType, + }, + } +} + type EnforceClusterComplianceResponse struct { // A list of changes that have been made to the cluster settings for the // cluster to become compliant with its policy. @@ -2458,6 +3366,17 @@ func (a EnforceClusterComplianceResponse) GetComplexFieldTypes() map[string]refl } } +func (a EnforceClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Changes": basetypes.ListType{ + ElemType: ClusterSettingsChange{}.ToAttrType(ctx), + }, + "HasChanges": types.BoolType, + }, + } +} + // The environment entity used to preserve serverless environment side panel and // jobs' environment for non-notebook task. In this minimal environment spec, // only pip dependencies are supported. @@ -2484,18 +3403,29 @@ func (newState *Environment) SyncEffectiveFieldsDuringRead(existingState Environ func (a Environment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dependencies": reflect.TypeOf(""), + "Dependencies": reflect.TypeOf(types.StringType), + } +} + +func (a Environment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Client": types.StringType, + "Dependencies": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type EventDetails struct { // * For created clusters, the attributes of the cluster. * For edited // clusters, the new attributes of the cluster. - Attributes types.Object `tfsdk:"attributes" tf:"optional,object"` + Attributes types.List `tfsdk:"attributes" tf:"optional,object"` // The cause of a change in target size. Cause types.String `tfsdk:"cause" tf:"optional"` // The actual cluster size that was set in the cluster creation or edit. - ClusterSize types.Object `tfsdk:"cluster_size" tf:"optional,object"` + ClusterSize types.List `tfsdk:"cluster_size" tf:"optional,object"` // The current number of vCPUs in the cluster. CurrentNumVcpus types.Int64 `tfsdk:"current_num_vcpus" tf:"optional"` // The current number of nodes in the cluster. @@ -2513,7 +3443,7 @@ type EventDetails struct { FreeSpace types.Int64 `tfsdk:"free_space" tf:"optional"` // List of global and cluster init scripts associated with this cluster // event. - InitScripts types.Object `tfsdk:"init_scripts" tf:"optional,object"` + InitScripts types.List `tfsdk:"init_scripts" tf:"optional,object"` // Instance Id where the event originated from InstanceId types.String `tfsdk:"instance_id" tf:"optional"` // Unique identifier of the specific job run associated with this cluster @@ -2521,15 +3451,15 @@ type EventDetails struct { // cluster name JobRunName types.String `tfsdk:"job_run_name" tf:"optional"` // The cluster attributes before a cluster was edited. - PreviousAttributes types.Object `tfsdk:"previous_attributes" tf:"optional,object"` + PreviousAttributes types.List `tfsdk:"previous_attributes" tf:"optional,object"` // The size of the cluster before an edit or resize. - PreviousClusterSize types.Object `tfsdk:"previous_cluster_size" tf:"optional,object"` + PreviousClusterSize types.List `tfsdk:"previous_cluster_size" tf:"optional,object"` // Previous disk size in bytes PreviousDiskSize types.Int64 `tfsdk:"previous_disk_size" tf:"optional"` // A termination reason: * On a TERMINATED event, this is the reason of the // termination. * On a RESIZE_COMPLETE event, this indicates the reason that // we failed to acquire some nodes. - Reason types.Object `tfsdk:"reason" tf:"optional,object"` + Reason types.List `tfsdk:"reason" tf:"optional,object"` // The targeted number of vCPUs in the cluster. TargetNumVcpus types.Int64 `tfsdk:"target_num_vcpus" tf:"optional"` // The targeted number of nodes in the cluster. @@ -2556,6 +3486,33 @@ func (a EventDetails) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EventDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": ClusterAttributes{}.ToAttrType(ctx), + "Cause": types.StringType, + "ClusterSize": ClusterSize{}.ToAttrType(ctx), + "CurrentNumVcpus": types.Int64Type, + "CurrentNumWorkers": types.Int64Type, + "DidNotExpandReason": types.StringType, + "DiskSize": types.Int64Type, + "DriverStateMessage": types.StringType, + "EnableTerminationForNodeBlocklisted": types.BoolType, + "FreeSpace": types.Int64Type, + "InitScripts": InitScriptEventDetails{}.ToAttrType(ctx), + "InstanceId": types.StringType, + "JobRunName": types.StringType, + "PreviousAttributes": ClusterAttributes{}.ToAttrType(ctx), + "PreviousClusterSize": ClusterSize{}.ToAttrType(ctx), + "PreviousDiskSize": types.Int64Type, + "Reason": TerminationReason{}.ToAttrType(ctx), + "TargetNumVcpus": types.Int64Type, + "TargetNumWorkers": types.Int64Type, + "User": types.StringType, + }, + } +} + type GcpAttributes struct { // This field determines whether the instance pool will contain preemptible // VMs, on-demand VMs, or preemptible VMs with a fallback to on-demand VMs @@ -2600,6 +3557,19 @@ func (a GcpAttributes) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Availability": types.StringType, + "BootDiskSize": types.Int64Type, + "GoogleServiceAccount": types.StringType, + "LocalSsdCount": types.Int64Type, + "UsePreemptibleExecutors": types.BoolType, + "ZoneId": types.StringType, + }, + } +} + type GcsStorageInfo struct { // GCS destination/URI, e.g. `gs://my-bucket/some-prefix` Destination types.String `tfsdk:"destination" tf:""` @@ -2615,6 +3585,14 @@ func (a GcsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Destination": types.StringType, + }, + } +} + // Get cluster policy compliance type GetClusterComplianceRequest struct { // The ID of the cluster to get the compliance status @@ -2631,6 +3609,14 @@ func (a GetClusterComplianceRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type GetClusterComplianceResponse struct { // Whether the cluster is compliant with its policy or not. Clusters could // be out of compliance if the policy was updated after the cluster was last @@ -2651,7 +3637,18 @@ func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringRead(exis func (a GetClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(""), + "Violations": reflect.TypeOf(types.StringType), + } +} + +func (a GetClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsCompliant": types.BoolType, + "Violations": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2671,6 +3668,14 @@ func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetClusterPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type GetClusterPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -2688,6 +3693,16 @@ func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes() map[string]re } } +func (a GetClusterPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: ClusterPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get cluster permissions type GetClusterPermissionsRequest struct { // The cluster for which to get or manage permissions. @@ -2704,6 +3719,14 @@ func (a GetClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a GetClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + // Get cluster policy permission levels type GetClusterPolicyPermissionLevelsRequest struct { // The cluster policy for which to get or manage permissions. @@ -2720,6 +3743,14 @@ func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a GetClusterPolicyPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterPolicyId": types.StringType, + }, + } +} + type GetClusterPolicyPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -2737,6 +3768,16 @@ func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes() map[str } } +func (a GetClusterPolicyPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: ClusterPolicyPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get cluster policy permissions type GetClusterPolicyPermissionsRequest struct { // The cluster policy for which to get or manage permissions. @@ -2753,7 +3794,15 @@ func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } -// Get a cluster policy +func (a GetClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterPolicyId": types.StringType, + }, + } +} + +// Get a cluster policy type GetClusterPolicyRequest struct { // Canonical unique identifier for the Cluster Policy. PolicyId types.String `tfsdk:"-"` @@ -2769,6 +3818,14 @@ func (a GetClusterPolicyRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetClusterPolicyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PolicyId": types.StringType, + }, + } +} + // Get cluster info type GetClusterRequest struct { // The cluster about which to retrieve information. @@ -2785,6 +3842,14 @@ func (a GetClusterRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetClusterRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type GetEvents struct { // The ID of the cluster to retrieve events about. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -2816,7 +3881,23 @@ func (newState *GetEvents) SyncEffectiveFieldsDuringRead(existingState GetEvents func (a GetEvents) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EventTypes": reflect.TypeOf(""), + "EventTypes": reflect.TypeOf(types.StringType), + } +} + +func (a GetEvents) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "EndTime": types.Int64Type, + "EventTypes": basetypes.ListType{ + ElemType: types.StringType, + }, + "Limit": types.Int64Type, + "Offset": types.Int64Type, + "Order": types.StringType, + "StartTime": types.Int64Type, + }, } } @@ -2825,7 +3906,7 @@ type GetEventsResponse struct { Events types.List `tfsdk:"events" tf:"optional"` // The parameters required to retrieve the next page of events. Omitted if // there are no more events to read. - NextPage types.Object `tfsdk:"next_page" tf:"optional,object"` + NextPage types.List `tfsdk:"next_page" tf:"optional,object"` // The total number of events filtered by the start_time, end_time, and // event_types. TotalCount types.Int64 `tfsdk:"total_count" tf:"optional"` @@ -2844,6 +3925,18 @@ func (a GetEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Events": basetypes.ListType{ + ElemType: ClusterEvent{}.ToAttrType(ctx), + }, + "NextPage": GetEvents{}.ToAttrType(ctx), + "TotalCount": types.Int64Type, + }, + } +} + // Get an init script type GetGlobalInitScriptRequest struct { // The ID of the global init script. @@ -2860,13 +3953,21 @@ func (a GetGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ScriptId": types.StringType, + }, + } +} + type GetInstancePool struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to instance pools running on Azure. If not specified // at pool creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: @@ -2886,7 +3987,7 @@ type GetInstancePool struct { DefaultTags types.Map `tfsdk:"default_tags" tf:"optional"` // Defines the specification of the disks that will be attached to all spark // containers. - DiskSpec types.Object `tfsdk:"disk_spec" tf:"optional,object"` + DiskSpec types.List `tfsdk:"disk_spec" tf:"optional,object"` // Autoscaling Local Storage: when enabled, this instances in this pool will // dynamically acquire additional disk space when its Spark workers are // running low on disk space. In AWS, this feature requires specific AWS @@ -2895,7 +3996,7 @@ type GetInstancePool struct { EnableElasticDisk types.Bool `tfsdk:"enable_elastic_disk" tf:"optional"` // Attributes related to instance pools running on Google Cloud Platform. If // not specified at pool creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -2931,9 +4032,9 @@ type GetInstancePool struct { // Current state of the instance pool. State types.String `tfsdk:"state" tf:"optional"` // Usage statistics about the instance pool. - Stats types.Object `tfsdk:"stats" tf:"optional,object"` + Stats types.List `tfsdk:"stats" tf:"optional,object"` // Status of failed pending instances in the pool. - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` } func (newState *GetInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetInstancePool) { @@ -2946,17 +4047,50 @@ func (a GetInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "CustomTags": reflect.TypeOf(""), - "DefaultTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), + "DefaultTags": reflect.TypeOf(types.StringType), "DiskSpec": reflect.TypeOf(DiskSpec{}), "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), - "PreloadedSparkVersions": reflect.TypeOf(""), + "PreloadedSparkVersions": reflect.TypeOf(types.StringType), "Stats": reflect.TypeOf(InstancePoolStats{}), "Status": reflect.TypeOf(InstancePoolStatus{}), } } +func (a GetInstancePool) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsAttributes": InstancePoolAwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": InstancePoolAzureAttributes{}.ToAttrType(ctx), + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DefaultTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DiskSpec": DiskSpec{}.ToAttrType(ctx), + "EnableElasticDisk": types.BoolType, + "GcpAttributes": InstancePoolGcpAttributes{}.ToAttrType(ctx), + "IdleInstanceAutoterminationMinutes": types.Int64Type, + "InstancePoolId": types.StringType, + "InstancePoolName": types.StringType, + "MaxCapacity": types.Int64Type, + "MinIdleInstances": types.Int64Type, + "NodeTypeId": types.StringType, + "PreloadedDockerImages": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "PreloadedSparkVersions": basetypes.ListType{ + ElemType: types.StringType, + }, + "State": types.StringType, + "Stats": InstancePoolStats{}.ToAttrType(ctx), + "Status": InstancePoolStatus{}.ToAttrType(ctx), + }, + } +} + // Get instance pool permission levels type GetInstancePoolPermissionLevelsRequest struct { // The instance pool for which to get or manage permissions. @@ -2973,6 +4107,14 @@ func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes() map[strin return map[string]reflect.Type{} } +func (a GetInstancePoolPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstancePoolId": types.StringType, + }, + } +} + type GetInstancePoolPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -2990,6 +4132,16 @@ func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes() map[stri } } +func (a GetInstancePoolPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: InstancePoolPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get instance pool permissions type GetInstancePoolPermissionsRequest struct { // The instance pool for which to get or manage permissions. @@ -3006,6 +4158,14 @@ func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetInstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstancePoolId": types.StringType, + }, + } +} + // Get instance pool information type GetInstancePoolRequest struct { // The canonical unique identifier for the instance pool. @@ -3022,6 +4182,14 @@ func (a GetInstancePoolRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetInstancePoolRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstancePoolId": types.StringType, + }, + } +} + // Get policy family information type GetPolicyFamilyRequest struct { // The family ID about which to retrieve information. @@ -3041,6 +4209,15 @@ func (a GetPolicyFamilyRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetPolicyFamilyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PolicyFamilyId": types.StringType, + "Version": types.Int64Type, + }, + } +} + type GetSparkVersionsResponse struct { // All the available Spark versions. Versions types.List `tfsdk:"versions" tf:"optional"` @@ -3058,6 +4235,16 @@ func (a GetSparkVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a GetSparkVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Versions": basetypes.ListType{ + ElemType: SparkVersion{}.ToAttrType(ctx), + }, + }, + } +} + type GlobalInitScriptCreateRequest struct { // Specifies whether the script is enabled. The script runs only if enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -3089,6 +4276,17 @@ func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GlobalInitScriptCreateRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + "Name": types.StringType, + "Position": types.Int64Type, + "Script": types.StringType, + }, + } +} + type GlobalInitScriptDetails struct { // Time when the script was created, represented as a Unix timestamp in // milliseconds. @@ -3121,6 +4319,21 @@ func (a GlobalInitScriptDetails) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GlobalInitScriptDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "Enabled": types.BoolType, + "Name": types.StringType, + "Position": types.Int64Type, + "ScriptId": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type GlobalInitScriptDetailsWithContent struct { // Time when the script was created, represented as a Unix timestamp in // milliseconds. @@ -3155,6 +4368,22 @@ func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a GlobalInitScriptDetailsWithContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "Enabled": types.BoolType, + "Name": types.StringType, + "Position": types.Int64Type, + "Script": types.StringType, + "ScriptId": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type GlobalInitScriptUpdateRequest struct { // Specifies whether the script is enabled. The script runs only if enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -3189,6 +4418,18 @@ func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GlobalInitScriptUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + "Name": types.StringType, + "Position": types.Int64Type, + "Script": types.StringType, + "ScriptId": types.StringType, + }, + } +} + type InitScriptEventDetails struct { // The cluster scoped init scripts associated with this cluster event Cluster types.List `tfsdk:"cluster" tf:"optional"` @@ -3211,6 +4452,20 @@ func (a InitScriptEventDetails) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a InitScriptEventDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cluster": basetypes.ListType{ + ElemType: InitScriptInfoAndExecutionDetails{}.ToAttrType(ctx), + }, + "Global": basetypes.ListType{ + ElemType: InitScriptInfoAndExecutionDetails{}.ToAttrType(ctx), + }, + "ReportedForNode": types.StringType, + }, + } +} + type InitScriptExecutionDetails struct { // Addition details regarding errors. ErrorMessage types.String `tfsdk:"error_message" tf:"optional"` @@ -3230,32 +4485,42 @@ func (a InitScriptExecutionDetails) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a InitScriptExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ErrorMessage": types.StringType, + "ExecutionDurationSeconds": types.Int64Type, + "Status": types.StringType, + }, + } +} + type InitScriptInfo struct { // destination needs to be provided. e.g. `{ "abfss" : { "destination" : // "abfss://@.dfs.core.windows.net/" // } } - Abfss types.Object `tfsdk:"abfss" tf:"optional,object"` + Abfss types.List `tfsdk:"abfss" tf:"optional,object"` // destination needs to be provided. e.g. `{ "dbfs" : { "destination" : // "dbfs:/home/cluster_log" } }` - Dbfs types.Object `tfsdk:"dbfs" tf:"optional,object"` + Dbfs types.List `tfsdk:"dbfs" tf:"optional,object"` // destination needs to be provided. e.g. `{ "file" : { "destination" : // "file:/my/local/file.sh" } }` - File types.Object `tfsdk:"file" tf:"optional,object"` + File types.List `tfsdk:"file" tf:"optional,object"` // destination needs to be provided. e.g. `{ "gcs": { "destination": // "gs://my-bucket/file.sh" } }` - Gcs types.Object `tfsdk:"gcs" tf:"optional,object"` + Gcs types.List `tfsdk:"gcs" tf:"optional,object"` // destination and either the region or endpoint need to be provided. e.g. // `{ "s3": { "destination" : "s3://cluster_log_bucket/prefix", "region" : // "us-west-2" } }` Cluster iam role is used to access s3, please make sure // the cluster iam role in `instance_profile_arn` has permission to write // data to the s3 destination. - S3 types.Object `tfsdk:"s3" tf:"optional,object"` + S3 types.List `tfsdk:"s3" tf:"optional,object"` // destination needs to be provided. e.g. `{ "volumes" : { "destination" : // "/Volumes/my-init.sh" } }` - Volumes types.Object `tfsdk:"volumes" tf:"optional,object"` + Volumes types.List `tfsdk:"volumes" tf:"optional,object"` // destination needs to be provided. e.g. `{ "workspace" : { "destination" : // "/Users/user1@databricks.com/my-init.sh" } }` - Workspace types.Object `tfsdk:"workspace" tf:"optional,object"` + Workspace types.List `tfsdk:"workspace" tf:"optional,object"` } func (newState *InitScriptInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan InitScriptInfo) { @@ -3276,11 +4541,25 @@ func (a InitScriptInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a InitScriptInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Abfss": Adlsgen2Info{}.ToAttrType(ctx), + "Dbfs": DbfsStorageInfo{}.ToAttrType(ctx), + "File": LocalFileInfo{}.ToAttrType(ctx), + "Gcs": GcsStorageInfo{}.ToAttrType(ctx), + "S3": S3StorageInfo{}.ToAttrType(ctx), + "Volumes": VolumesStorageInfo{}.ToAttrType(ctx), + "Workspace": WorkspaceStorageInfo{}.ToAttrType(ctx), + }, + } +} + type InitScriptInfoAndExecutionDetails struct { // Details about the script - ExecutionDetails types.Object `tfsdk:"execution_details" tf:"optional,object"` + ExecutionDetails types.List `tfsdk:"execution_details" tf:"optional,object"` // The script - Script types.Object `tfsdk:"script" tf:"optional,object"` + Script types.List `tfsdk:"script" tf:"optional,object"` } func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan InitScriptInfoAndExecutionDetails) { @@ -3296,6 +4575,15 @@ func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes() map[string]ref } } +func (a InitScriptInfoAndExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExecutionDetails": InitScriptExecutionDetails{}.ToAttrType(ctx), + "Script": InitScriptInfo{}.ToAttrType(ctx), + }, + } +} + type InstallLibraries struct { // Unique identifier for the cluster on which to install these libraries. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -3315,6 +4603,17 @@ func (a InstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a InstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: Library{}.ToAttrType(ctx), + }, + }, + } +} + type InstallLibrariesResponse struct { } @@ -3328,6 +4627,12 @@ func (a InstallLibrariesResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a InstallLibrariesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type InstancePoolAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -3349,6 +4654,17 @@ func (a InstancePoolAccessControlRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a InstancePoolAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type InstancePoolAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -3374,13 +4690,27 @@ func (a InstancePoolAccessControlResponse) GetComplexFieldTypes() map[string]ref } } +func (a InstancePoolAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: InstancePoolPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type InstancePoolAndStats struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to instance pools running on Azure. If not specified // at pool creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // Additional tags for pool resources. Databricks will tag all pool // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: @@ -3400,7 +4730,7 @@ type InstancePoolAndStats struct { DefaultTags types.Map `tfsdk:"default_tags" tf:"optional"` // Defines the specification of the disks that will be attached to all spark // containers. - DiskSpec types.Object `tfsdk:"disk_spec" tf:"optional,object"` + DiskSpec types.List `tfsdk:"disk_spec" tf:"optional,object"` // Autoscaling Local Storage: when enabled, this instances in this pool will // dynamically acquire additional disk space when its Spark workers are // running low on disk space. In AWS, this feature requires specific AWS @@ -3409,7 +4739,7 @@ type InstancePoolAndStats struct { EnableElasticDisk types.Bool `tfsdk:"enable_elastic_disk" tf:"optional"` // Attributes related to instance pools running on Google Cloud Platform. If // not specified at pool creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // Automatically terminates the extra instances in the pool cache after they // are inactive for this time in minutes if min_idle_instances requirement // is already met. If not set, the extra pool instances will be @@ -3445,9 +4775,9 @@ type InstancePoolAndStats struct { // Current state of the instance pool. State types.String `tfsdk:"state" tf:"optional"` // Usage statistics about the instance pool. - Stats types.Object `tfsdk:"stats" tf:"optional,object"` + Stats types.List `tfsdk:"stats" tf:"optional,object"` // Status of failed pending instances in the pool. - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` } func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan InstancePoolAndStats) { @@ -3460,17 +4790,50 @@ func (a InstancePoolAndStats) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "CustomTags": reflect.TypeOf(""), - "DefaultTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), + "DefaultTags": reflect.TypeOf(types.StringType), "DiskSpec": reflect.TypeOf(DiskSpec{}), "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), - "PreloadedSparkVersions": reflect.TypeOf(""), + "PreloadedSparkVersions": reflect.TypeOf(types.StringType), "Stats": reflect.TypeOf(InstancePoolStats{}), "Status": reflect.TypeOf(InstancePoolStatus{}), } } +func (a InstancePoolAndStats) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsAttributes": InstancePoolAwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": InstancePoolAzureAttributes{}.ToAttrType(ctx), + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DefaultTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DiskSpec": DiskSpec{}.ToAttrType(ctx), + "EnableElasticDisk": types.BoolType, + "GcpAttributes": InstancePoolGcpAttributes{}.ToAttrType(ctx), + "IdleInstanceAutoterminationMinutes": types.Int64Type, + "InstancePoolId": types.StringType, + "InstancePoolName": types.StringType, + "MaxCapacity": types.Int64Type, + "MinIdleInstances": types.Int64Type, + "NodeTypeId": types.StringType, + "PreloadedDockerImages": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "PreloadedSparkVersions": basetypes.ListType{ + ElemType: types.StringType, + }, + "State": types.StringType, + "Stats": InstancePoolStats{}.ToAttrType(ctx), + "Status": InstancePoolStatus{}.ToAttrType(ctx), + }, + } +} + type InstancePoolAwsAttributes struct { // Availability type used for the spot nodes. // @@ -3513,6 +4876,16 @@ func (a InstancePoolAwsAttributes) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a InstancePoolAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Availability": types.StringType, + "SpotBidPricePercent": types.Int64Type, + "ZoneId": types.StringType, + }, + } +} + type InstancePoolAzureAttributes struct { // Shows the Availability type used for the spot nodes. // @@ -3534,6 +4907,15 @@ func (a InstancePoolAzureAttributes) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a InstancePoolAzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Availability": types.StringType, + "SpotBidMaxPrice": types.Float64Type, + }, + } +} + type InstancePoolGcpAttributes struct { // This field determines whether the instance pool will contain preemptible // VMs, on-demand VMs, or preemptible VMs with a fallback to on-demand VMs @@ -3575,6 +4957,16 @@ func (a InstancePoolGcpAttributes) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a InstancePoolGcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GcpAvailability": types.StringType, + "LocalSsdCount": types.Int64Type, + "ZoneId": types.StringType, + }, + } +} + type InstancePoolPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -3591,7 +4983,19 @@ func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringRead(existingSt func (a InstancePoolPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a InstancePoolPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -3615,6 +5019,18 @@ func (a InstancePoolPermissions) GetComplexFieldTypes() map[string]reflect.Type } } +func (a InstancePoolPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: InstancePoolAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type InstancePoolPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -3631,6 +5047,15 @@ func (a InstancePoolPermissionsDescription) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a InstancePoolPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type InstancePoolPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The instance pool for which to get or manage permissions. @@ -3649,6 +5074,17 @@ func (a InstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]reflec } } +func (a InstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: InstancePoolAccessControlRequest{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + }, + } +} + type InstancePoolStats struct { // Number of active instances in the pool that are NOT part of a cluster. IdleCount types.Int64 `tfsdk:"idle_count" tf:"optional"` @@ -3670,6 +5106,17 @@ func (a InstancePoolStats) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a InstancePoolStats) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IdleCount": types.Int64Type, + "PendingIdleCount": types.Int64Type, + "PendingUsedCount": types.Int64Type, + "UsedCount": types.Int64Type, + }, + } +} + type InstancePoolStatus struct { // List of error messages for the failed pending instances. The // pending_instance_errors follows FIFO with maximum length of the min_idle @@ -3690,6 +5137,16 @@ func (a InstancePoolStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a InstancePoolStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PendingInstanceErrors": basetypes.ListType{ + ElemType: PendingInstanceError{}.ToAttrType(ctx), + }, + }, + } +} + type InstanceProfile struct { // The AWS IAM role ARN of the role associated with the instance profile. // This field is required if your role name and instance profile name do not @@ -3721,9 +5178,19 @@ func (a InstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a InstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IamRoleArn": types.StringType, + "InstanceProfileArn": types.StringType, + "IsMetaInstanceProfile": types.BoolType, + }, + } +} + type Library struct { // Specification of a CRAN library to be installed as part of the library - Cran types.Object `tfsdk:"cran" tf:"optional,object"` + Cran types.List `tfsdk:"cran" tf:"optional,object"` // Deprecated. URI of the egg library to install. Installing Python egg // files is deprecated and is not supported in Databricks Runtime 14.0 and // above. @@ -3738,10 +5205,10 @@ type Library struct { Jar types.String `tfsdk:"jar" tf:"optional"` // Specification of a maven library to be installed. For example: `{ // "coordinates": "org.jsoup:jsoup:1.7.2" }` - Maven types.Object `tfsdk:"maven" tf:"optional,object"` + Maven types.List `tfsdk:"maven" tf:"optional,object"` // Specification of a PyPi library to be installed. For example: `{ // "package": "simplejson" }` - Pypi types.Object `tfsdk:"pypi" tf:"optional,object"` + Pypi types.List `tfsdk:"pypi" tf:"optional,object"` // URI of the requirements.txt file to install. Only Workspace paths and // Unity Catalog Volumes paths are supported. For example: `{ // "requirements": "/Workspace/path/to/requirements.txt" }` or `{ @@ -3771,13 +5238,27 @@ func (a Library) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Library) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cran": RCranLibrary{}.ToAttrType(ctx), + "Egg": types.StringType, + "Jar": types.StringType, + "Maven": MavenLibrary{}.ToAttrType(ctx), + "Pypi": PythonPyPiLibrary{}.ToAttrType(ctx), + "Requirements": types.StringType, + "Whl": types.StringType, + }, + } +} + // The status of the library on a specific cluster. type LibraryFullStatus struct { // Whether the library was set to be installed on all clusters via the // libraries UI. IsLibraryForAllClusters types.Bool `tfsdk:"is_library_for_all_clusters" tf:"optional"` // Unique identifier for the library. - Library types.Object `tfsdk:"library" tf:"optional,object"` + Library types.List `tfsdk:"library" tf:"optional,object"` // All the info and warning messages that have occurred so far for this // library. Messages types.List `tfsdk:"messages" tf:"optional"` @@ -3794,7 +5275,20 @@ func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringRead(existingState L func (a LibraryFullStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Library": reflect.TypeOf(Library{}), - "Messages": reflect.TypeOf(""), + "Messages": reflect.TypeOf(types.StringType), + } +} + +func (a LibraryFullStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsLibraryForAllClusters": types.BoolType, + "Library": Library{}.ToAttrType(ctx), + "Messages": basetypes.ListType{ + ElemType: types.StringType, + }, + "Status": types.StringType, + }, } } @@ -3815,6 +5309,16 @@ func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes() map[string } } +func (a ListAllClusterLibraryStatusesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Statuses": basetypes.ListType{ + ElemType: ClusterLibraryStatuses{}.ToAttrType(ctx), + }, + }, + } +} + type ListAvailableZonesResponse struct { // The availability zone if no `zone_id` is provided in the cluster creation // request. @@ -3831,7 +5335,18 @@ func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringRead(existi func (a ListAvailableZonesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Zones": reflect.TypeOf(""), + "Zones": reflect.TypeOf(types.StringType), + } +} + +func (a ListAvailableZonesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DefaultZone": types.StringType, + "Zones": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -3858,6 +5373,16 @@ func (a ListClusterCompliancesRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a ListClusterCompliancesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "PolicyId": types.StringType, + }, + } +} + type ListClusterCompliancesResponse struct { // A list of clusters and their policy compliance statuses. Clusters types.List `tfsdk:"clusters" tf:"optional"` @@ -3882,6 +5407,18 @@ func (a ListClusterCompliancesResponse) GetComplexFieldTypes() map[string]reflec } } +func (a ListClusterCompliancesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Clusters": basetypes.ListType{ + ElemType: ClusterCompliance{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + }, + } +} + // List cluster policies type ListClusterPoliciesRequest struct { // The cluster policy attribute to sort by. * `POLICY_CREATION_TIME` - Sort @@ -3903,6 +5440,15 @@ func (a ListClusterPoliciesRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a ListClusterPoliciesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "SortColumn": types.StringType, + "SortOrder": types.StringType, + }, + } +} + type ListClustersFilterBy struct { // The source of cluster creation. ClusterSources types.List `tfsdk:"cluster_sources" tf:"optional"` @@ -3922,15 +5468,30 @@ func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringRead(existingStat func (a ListClustersFilterBy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ClusterSources": reflect.TypeOf(""), - "ClusterStates": reflect.TypeOf(""), + "ClusterSources": reflect.TypeOf(types.StringType), + "ClusterStates": reflect.TypeOf(types.StringType), + } +} + +func (a ListClustersFilterBy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterSources": basetypes.ListType{ + ElemType: types.StringType, + }, + "ClusterStates": basetypes.ListType{ + ElemType: types.StringType, + }, + "IsPinned": types.BoolType, + "PolicyId": types.StringType, + }, } } // List clusters type ListClustersRequest struct { // Filters to apply to the list of clusters. - FilterBy types.Object `tfsdk:"-"` + FilterBy types.List `tfsdk:"-"` // Use this field to specify the maximum number of results to be returned by // the server. The server may further constrain the maximum number of // results returned in a single page. @@ -3939,7 +5500,7 @@ type ListClustersRequest struct { // to list the next or previous page of clusters respectively. PageToken types.String `tfsdk:"-"` // Sort the list of clusters by a specific criteria. - SortBy types.Object `tfsdk:"-"` + SortBy types.List `tfsdk:"-"` } func (newState *ListClustersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListClustersRequest) { @@ -3955,6 +5516,17 @@ func (a ListClustersRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListClustersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FilterBy": ListClustersFilterBy{}.ToAttrType(ctx), + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "SortBy": ListClustersSortBy{}.ToAttrType(ctx), + }, + } +} + type ListClustersResponse struct { // Clusters types.List `tfsdk:"clusters" tf:"optional"` @@ -3979,6 +5551,18 @@ func (a ListClustersResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListClustersResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Clusters": basetypes.ListType{ + ElemType: ClusterDetails{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + }, + } +} + type ListClustersSortBy struct { // The direction to sort by. Direction types.String `tfsdk:"direction" tf:"optional"` @@ -3998,6 +5582,15 @@ func (a ListClustersSortBy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListClustersSortBy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Direction": types.StringType, + "Field": types.StringType, + }, + } +} + type ListGlobalInitScriptsResponse struct { Scripts types.List `tfsdk:"scripts" tf:"optional"` } @@ -4014,6 +5607,16 @@ func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes() map[string]reflect } } +func (a ListGlobalInitScriptsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Scripts": basetypes.ListType{ + ElemType: GlobalInitScriptDetails{}.ToAttrType(ctx), + }, + }, + } +} + type ListInstancePools struct { InstancePools types.List `tfsdk:"instance_pools" tf:"optional"` } @@ -4030,6 +5633,16 @@ func (a ListInstancePools) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListInstancePools) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstancePools": basetypes.ListType{ + ElemType: InstancePoolAndStats{}.ToAttrType(ctx), + }, + }, + } +} + type ListInstanceProfilesResponse struct { // A list of instance profiles that the user can access. InstanceProfiles types.List `tfsdk:"instance_profiles" tf:"optional"` @@ -4047,6 +5660,16 @@ func (a ListInstanceProfilesResponse) GetComplexFieldTypes() map[string]reflect. } } +func (a ListInstanceProfilesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstanceProfiles": basetypes.ListType{ + ElemType: InstanceProfile{}.ToAttrType(ctx), + }, + }, + } +} + type ListNodeTypesResponse struct { // The list of available Spark node types. NodeTypes types.List `tfsdk:"node_types" tf:"optional"` @@ -4064,6 +5687,16 @@ func (a ListNodeTypesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListNodeTypesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NodeTypes": basetypes.ListType{ + ElemType: NodeType{}.ToAttrType(ctx), + }, + }, + } +} + type ListPoliciesResponse struct { // List of policies. Policies types.List `tfsdk:"policies" tf:"optional"` @@ -4081,6 +5714,16 @@ func (a ListPoliciesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListPoliciesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Policies": basetypes.ListType{ + ElemType: Policy{}.ToAttrType(ctx), + }, + }, + } +} + // List policy families type ListPolicyFamiliesRequest struct { // Maximum number of policy families to return. @@ -4099,6 +5742,15 @@ func (a ListPolicyFamiliesRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a ListPolicyFamiliesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListPolicyFamiliesResponse struct { // A token that can be used to get the next page of results. If not present, // there are no more results to show. @@ -4119,6 +5771,17 @@ func (a ListPolicyFamiliesResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ListPolicyFamiliesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "PolicyFamilies": basetypes.ListType{ + ElemType: PolicyFamily{}.ToAttrType(ctx), + }, + }, + } +} + type LocalFileInfo struct { // local file destination, e.g. `file:/my/local/file.sh` Destination types.String `tfsdk:"destination" tf:""` @@ -4134,6 +5797,14 @@ func (a LocalFileInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LocalFileInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Destination": types.StringType, + }, + } +} + type LogAnalyticsInfo struct { // LogAnalyticsPrimaryKey types.String `tfsdk:"log_analytics_primary_key" tf:"optional"` @@ -4151,6 +5822,15 @@ func (a LogAnalyticsInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogAnalyticsInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LogAnalyticsPrimaryKey": types.StringType, + "LogAnalyticsWorkspaceId": types.StringType, + }, + } +} + type LogSyncStatus struct { // The timestamp of last attempt. If the last attempt fails, // `last_exception` will contain the exception in the last attempt. @@ -4170,6 +5850,15 @@ func (a LogSyncStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogSyncStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LastAttempted": types.Int64Type, + "LastException": types.StringType, + }, + } +} + type MavenLibrary struct { // Gradle-style maven coordinates. For example: "org.jsoup:jsoup:1.7.2". Coordinates types.String `tfsdk:"coordinates" tf:""` @@ -4192,7 +5881,19 @@ func (newState *MavenLibrary) SyncEffectiveFieldsDuringRead(existingState MavenL func (a MavenLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exclusions": reflect.TypeOf(""), + "Exclusions": reflect.TypeOf(types.StringType), + } +} + +func (a MavenLibrary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Coordinates": types.StringType, + "Exclusions": basetypes.ListType{ + ElemType: types.StringType, + }, + "Repo": types.StringType, + }, } } @@ -4218,6 +5919,18 @@ func (a NodeInstanceType) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NodeInstanceType) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstanceTypeId": types.StringType, + "LocalDiskSizeGb": types.Int64Type, + "LocalDisks": types.Int64Type, + "LocalNvmeDiskSizeGb": types.Int64Type, + "LocalNvmeDisks": types.Int64Type, + }, + } +} + type NodeType struct { Category types.String `tfsdk:"category" tf:"optional"` // A string description associated with this node type, e.g., "r3.xlarge". @@ -4242,9 +5955,9 @@ type NodeType struct { // Memory (in MB) available for this node type. MemoryMb types.Int64 `tfsdk:"memory_mb" tf:""` - NodeInfo types.Object `tfsdk:"node_info" tf:"optional,object"` + NodeInfo types.List `tfsdk:"node_info" tf:"optional,object"` - NodeInstanceType types.Object `tfsdk:"node_instance_type" tf:"optional,object"` + NodeInstanceType types.List `tfsdk:"node_instance_type" tf:"optional,object"` // Unique identifier for this node type. NodeTypeId types.String `tfsdk:"node_type_id" tf:""` // Number of CPU cores available for this node type. Note that this can be @@ -4281,6 +5994,34 @@ func (a NodeType) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a NodeType) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Category": types.StringType, + "Description": types.StringType, + "DisplayOrder": types.Int64Type, + "InstanceTypeId": types.StringType, + "IsDeprecated": types.BoolType, + "IsEncryptedInTransit": types.BoolType, + "IsGraviton": types.BoolType, + "IsHidden": types.BoolType, + "IsIoCacheEnabled": types.BoolType, + "MemoryMb": types.Int64Type, + "NodeInfo": CloudProviderNodeInfo{}.ToAttrType(ctx), + "NodeInstanceType": NodeInstanceType{}.ToAttrType(ctx), + "NodeTypeId": types.StringType, + "NumCores": types.Float64Type, + "NumGpus": types.Int64Type, + "PhotonDriverCapable": types.BoolType, + "PhotonWorkerCapable": types.BoolType, + "SupportClusterTags": types.BoolType, + "SupportEbsVolumes": types.BoolType, + "SupportPortForwarding": types.BoolType, + "SupportsElasticDisk": types.BoolType, + }, + } +} + type PendingInstanceError struct { InstanceId types.String `tfsdk:"instance_id" tf:"optional"` @@ -4297,6 +6038,15 @@ func (a PendingInstanceError) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PendingInstanceError) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstanceId": types.StringType, + "Message": types.StringType, + }, + } +} + type PermanentDeleteCluster struct { // The cluster to be deleted. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -4312,6 +6062,14 @@ func (a PermanentDeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PermanentDeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type PermanentDeleteClusterResponse struct { } @@ -4325,6 +6083,12 @@ func (a PermanentDeleteClusterResponse) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a PermanentDeleteClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type PinCluster struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -4340,6 +6104,14 @@ func (a PinCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PinCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type PinClusterResponse struct { } @@ -4353,6 +6125,12 @@ func (a PinClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PinClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Describes a Cluster Policy entity. type Policy struct { // Creation time. The timestamp (in millisecond) when this Cluster Policy @@ -4414,6 +6192,26 @@ func (a Policy) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Policy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAtTimestamp": types.Int64Type, + "CreatorUserName": types.StringType, + "Definition": types.StringType, + "Description": types.StringType, + "IsDefault": types.BoolType, + "Libraries": basetypes.ListType{ + ElemType: Library{}.ToAttrType(ctx), + }, + "MaxClustersPerUser": types.Int64Type, + "Name": types.StringType, + "PolicyFamilyDefinitionOverrides": types.StringType, + "PolicyFamilyId": types.StringType, + "PolicyId": types.StringType, + }, + } +} + type PolicyFamily struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -4438,6 +6236,17 @@ func (a PolicyFamily) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PolicyFamily) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Definition": types.StringType, + "Description": types.StringType, + "Name": types.StringType, + "PolicyFamilyId": types.StringType, + }, + } +} + type PythonPyPiLibrary struct { // The name of the pypi package to install. An optional exact version // specification is also supported. Examples: "simplejson" and @@ -4458,6 +6267,15 @@ func (a PythonPyPiLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PythonPyPiLibrary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Package": types.StringType, + "Repo": types.StringType, + }, + } +} + type RCranLibrary struct { // The name of the CRAN package to install. Package types.String `tfsdk:"package" tf:""` @@ -4476,6 +6294,15 @@ func (a RCranLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RCranLibrary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Package": types.StringType, + "Repo": types.StringType, + }, + } +} + type RemoveInstanceProfile struct { // The ARN of the instance profile to remove. This field is required. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:""` @@ -4491,6 +6318,14 @@ func (a RemoveInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RemoveInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstanceProfileArn": types.StringType, + }, + } +} + type RemoveResponse struct { } @@ -4504,11 +6339,17 @@ func (a RemoveResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RemoveResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ResizeCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // The cluster to be resized. ClusterId types.String `tfsdk:"cluster_id" tf:""` // Number of worker nodes that this cluster should have. A cluster has one @@ -4536,6 +6377,16 @@ func (a ResizeCluster) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ResizeCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Autoscale": AutoScale{}.ToAttrType(ctx), + "ClusterId": types.StringType, + "NumWorkers": types.Int64Type, + }, + } +} + type ResizeClusterResponse struct { } @@ -4549,6 +6400,12 @@ func (a ResizeClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ResizeClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type RestartCluster struct { // The cluster to be started. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -4566,6 +6423,15 @@ func (a RestartCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestartCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "RestartUser": types.StringType, + }, + } +} + type RestartClusterResponse struct { } @@ -4579,6 +6445,12 @@ func (a RestartClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestartClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Results struct { // The cause of the error Cause types.String `tfsdk:"cause" tf:"optional"` @@ -4611,11 +6483,34 @@ func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { func (a Results) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileNames": reflect.TypeOf(""), + "FileNames": reflect.TypeOf(types.StringType), "Schema": reflect.TypeOf(struct{}{}), } } +func (a Results) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cause": types.StringType, + "Data": types.ObjectType{}, + "FileName": types.StringType, + "FileNames": basetypes.ListType{ + ElemType: types.StringType, + }, + "IsJsonSchema": types.BoolType, + "Pos": types.Int64Type, + "ResultType": types.StringType, + "Schema": basetypes.ListType{ + ElemType: basetypes.MapType{ + ElemType: types.ObjectType{}, + }, + }, + "Summary": types.StringType, + "Truncated": types.BoolType, + }, + } +} + type S3StorageInfo struct { // (Optional) Set canned access control list for the logs, e.g. // `bucket-owner-full-control`. If `canned_cal` is set, please make sure the @@ -4659,13 +6554,27 @@ func (a S3StorageInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a S3StorageInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CannedAcl": types.StringType, + "Destination": types.StringType, + "EnableEncryption": types.BoolType, + "EncryptionType": types.StringType, + "Endpoint": types.StringType, + "KmsKey": types.StringType, + "Region": types.StringType, + }, + } +} + type SparkNode struct { // The private IP address of the host instance. HostPrivateIp types.String `tfsdk:"host_private_ip" tf:"optional"` // Globally unique identifier for the host instance from the cloud provider. InstanceId types.String `tfsdk:"instance_id" tf:"optional"` // Attributes specific to AWS for a Spark node. - NodeAwsAttributes types.Object `tfsdk:"node_aws_attributes" tf:"optional,object"` + NodeAwsAttributes types.List `tfsdk:"node_aws_attributes" tf:"optional,object"` // Globally unique identifier for this node. NodeId types.String `tfsdk:"node_id" tf:"optional"` // Private IP address (typically a 10.x.x.x address) of the Spark node. Note @@ -4699,6 +6608,20 @@ func (a SparkNode) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SparkNode) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "HostPrivateIp": types.StringType, + "InstanceId": types.StringType, + "NodeAwsAttributes": SparkNodeAwsAttributes{}.ToAttrType(ctx), + "NodeId": types.StringType, + "PrivateIp": types.StringType, + "PublicDns": types.StringType, + "StartTimestamp": types.Int64Type, + }, + } +} + type SparkNodeAwsAttributes struct { // Whether this node is on an Amazon spot instance. IsSpot types.Bool `tfsdk:"is_spot" tf:"optional"` @@ -4714,6 +6637,14 @@ func (a SparkNodeAwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SparkNodeAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsSpot": types.BoolType, + }, + } +} + type SparkVersion struct { // Spark version key, for example "2.1.x-scala2.11". This is the value which // should be provided as the "spark_version" when creating a new cluster. @@ -4735,6 +6666,15 @@ func (a SparkVersion) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SparkVersion) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Name": types.StringType, + }, + } +} + type StartCluster struct { // The cluster to be started. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -4750,6 +6690,14 @@ func (a StartCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StartCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type StartClusterResponse struct { } @@ -4763,6 +6711,12 @@ func (a StartClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StartClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type TerminationReason struct { // status code indicating why the cluster was terminated Code types.String `tfsdk:"code" tf:"optional"` @@ -4781,7 +6735,19 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState T func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Code": types.StringType, + "Parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "Type": types.StringType, + }, } } @@ -4804,6 +6770,17 @@ func (a UninstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UninstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: Library{}.ToAttrType(ctx), + }, + }, + } +} + type UninstallLibrariesResponse struct { } @@ -4817,6 +6794,12 @@ func (a UninstallLibrariesResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a UninstallLibrariesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UnpinCluster struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -4832,6 +6815,14 @@ func (a UnpinCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UnpinCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + }, + } +} + type UnpinClusterResponse struct { } @@ -4845,9 +6836,15 @@ func (a UnpinClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UnpinClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateCluster struct { // The cluster to be updated. - Cluster types.Object `tfsdk:"cluster" tf:"optional,object"` + Cluster types.List `tfsdk:"cluster" tf:"optional,object"` // ID of the cluster. ClusterId types.String `tfsdk:"cluster_id" tf:""` // Specifies which fields of the cluster will be updated. This is required @@ -4870,11 +6867,21 @@ func (a UpdateCluster) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cluster": UpdateClusterResource{}.ToAttrType(ctx), + "ClusterId": types.StringType, + "UpdateMask": types.StringType, + }, + } +} + type UpdateClusterResource struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically // terminated. If specified, the threshold must be between 10 and 10000 @@ -4883,17 +6890,17 @@ type UpdateClusterResource struct { AutoterminationMinutes types.Int64 `tfsdk:"autotermination_minutes" tf:"optional"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes types.Object `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes types.Object `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Two kinds of destinations (dbfs and s3) are supported. Only // one destination can be specified for one cluster. If the conf is given, // the logs will be delivered to the destination every `5 mins`. The // destination of driver logs is `$destination/$clusterId/driver`, while the // destination of executor logs is `$destination/$clusterId/executor`. - ClusterLogConf types.Object `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Cluster name requested by the user. This doesn't have to be unique. If // not specified at creation, the cluster name will be an empty string. ClusterName types.String `tfsdk:"cluster_name" tf:"optional"` @@ -4930,7 +6937,7 @@ type UpdateClusterResource struct { // mode provides a way that doesn’t have UC nor passthrough enabled. DataSecurityMode types.String `tfsdk:"data_security_mode" tf:"optional"` - DockerImage types.Object `tfsdk:"docker_image" tf:"optional,object"` + DockerImage types.List `tfsdk:"docker_image" tf:"optional,object"` // The optional ID of the instance pool for the driver of the cluster // belongs. The pool cluster uses the instance pool with id // (instance_pool_id) if the driver pool is not assigned. @@ -4948,7 +6955,7 @@ type UpdateClusterResource struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes types.Object `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -5015,7 +7022,7 @@ type UpdateClusterResource struct { // user name `ubuntu` on port `2200`. Up to 10 keys can be specified. SshPublicKeys types.List `tfsdk:"ssh_public_keys" tf:"optional"` - WorkloadType types.Object `tfsdk:"workload_type" tf:"optional,object"` + WorkloadType types.List `tfsdk:"workload_type" tf:"optional,object"` } func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateClusterResource) { @@ -5030,17 +7037,60 @@ func (a UpdateClusterResource) GetComplexFieldTypes() map[string]reflect.Type { "AwsAttributes": reflect.TypeOf(AwsAttributes{}), "AzureAttributes": reflect.TypeOf(AzureAttributes{}), "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "DockerImage": reflect.TypeOf(DockerImage{}), "GcpAttributes": reflect.TypeOf(GcpAttributes{}), "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), - "SshPublicKeys": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), + "SshPublicKeys": reflect.TypeOf(types.StringType), "WorkloadType": reflect.TypeOf(WorkloadType{}), } } +func (a UpdateClusterResource) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Autoscale": AutoScale{}.ToAttrType(ctx), + "AutoterminationMinutes": types.Int64Type, + "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), + "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), + "ClusterName": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DataSecurityMode": types.StringType, + "DockerImage": DockerImage{}.ToAttrType(ctx), + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableElasticDisk": types.BoolType, + "EnableLocalDiskEncryption": types.BoolType, + "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "NodeTypeId": types.StringType, + "NumWorkers": types.Int64Type, + "PolicyId": types.StringType, + "RuntimeEngine": types.StringType, + "SingleUserName": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkVersion": types.StringType, + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "WorkloadType": WorkloadType{}.ToAttrType(ctx), + }, + } +} + type UpdateClusterResponse struct { } @@ -5054,6 +7104,12 @@ func (a UpdateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateResponse struct { } @@ -5067,6 +7123,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type VolumesStorageInfo struct { // Unity Catalog Volumes file destination, e.g. `/Volumes/my-init.sh` Destination types.String `tfsdk:"destination" tf:""` @@ -5082,9 +7144,17 @@ func (a VolumesStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a VolumesStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Destination": types.StringType, + }, + } +} + type WorkloadType struct { // defined what type of clients can use the cluster. E.g. Notebooks, Jobs - Clients types.Object `tfsdk:"clients" tf:"object"` + Clients types.List `tfsdk:"clients" tf:"object"` } func (newState *WorkloadType) SyncEffectiveFieldsDuringCreateOrUpdate(plan WorkloadType) { @@ -5099,6 +7169,14 @@ func (a WorkloadType) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a WorkloadType) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Clients": ClientsTypes{}.ToAttrType(ctx), + }, + } +} + type WorkspaceStorageInfo struct { // workspace files destination, e.g. // `/Users/user1@databricks.com/my-init.sh` @@ -5114,3 +7192,11 @@ func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringRead(existingStat func (a WorkspaceStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a WorkspaceStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Destination": types.StringType, + }, + } +} diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index adec574f13..ecf1da7ce6 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -11,15 +11,19 @@ We use go-native types for lists and maps intentionally for the ease for convert package dashboards_tf import ( + "context" "reflect" "github.com/databricks/databricks-sdk-go/service/sql" + "github.com/databricks/terraform-provider-databricks/internal/service/sql_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) // Create dashboard type CreateDashboardRequest struct { - Dashboard types.Object `tfsdk:"dashboard" tf:"optional,object"` + Dashboard types.List `tfsdk:"dashboard" tf:"optional,object"` } func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateDashboardRequest) { @@ -34,12 +38,20 @@ func (a CreateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Dashboard": Dashboard{}.ToAttrType(ctx), + }, + } +} + // Create dashboard schedule type CreateScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. DashboardId types.String `tfsdk:"-"` - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` } func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateScheduleRequest) { @@ -54,6 +66,15 @@ func (a CreateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Schedule": Schedule{}.ToAttrType(ctx), + }, + } +} + // Create schedule subscription type CreateSubscriptionRequest struct { // UUID identifying the dashboard to which the subscription belongs. @@ -61,7 +82,7 @@ type CreateSubscriptionRequest struct { // UUID identifying the schedule to which the subscription belongs. ScheduleId types.String `tfsdk:"-"` - Subscription types.Object `tfsdk:"subscription" tf:"optional,object"` + Subscription types.List `tfsdk:"subscription" tf:"optional,object"` } func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateSubscriptionRequest) { @@ -76,6 +97,16 @@ func (a CreateSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a CreateSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "ScheduleId": types.StringType, + "Subscription": Subscription{}.ToAttrType(ctx), + }, + } +} + type CronSchedule struct { // A cron expression using quartz syntax. EX: `0 0 8 * * ?` represents // everyday at 8am. See [Cron Trigger] for details. @@ -99,6 +130,15 @@ func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QuartzCronExpression": types.StringType, + "TimezoneId": types.StringType, + }, + } +} + type Dashboard struct { // The timestamp of when the dashboard was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -145,6 +185,23 @@ func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "DashboardId": types.StringType, + "DisplayName": types.StringType, + "Etag": types.StringType, + "LifecycleState": types.StringType, + "ParentPath": types.StringType, + "Path": types.StringType, + "SerializedDashboard": types.StringType, + "UpdateTime": types.StringType, + "WarehouseId": types.StringType, + }, + } +} + // Delete dashboard schedule type DeleteScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. @@ -166,6 +223,16 @@ func (a DeleteScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Etag": types.StringType, + "ScheduleId": types.StringType, + }, + } +} + type DeleteScheduleResponse struct { } @@ -179,6 +246,12 @@ func (a DeleteScheduleResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteScheduleResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete schedule subscription type DeleteSubscriptionRequest struct { // UUID identifying the dashboard which the subscription belongs. @@ -202,6 +275,17 @@ func (a DeleteSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Etag": types.StringType, + "ScheduleId": types.StringType, + "SubscriptionId": types.StringType, + }, + } +} + type DeleteSubscriptionResponse struct { } @@ -215,11 +299,17 @@ func (a DeleteSubscriptionResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteSubscriptionResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Genie AI Response type GenieAttachment struct { - Query types.Object `tfsdk:"query" tf:"optional,object"` + Query types.List `tfsdk:"query" tf:"optional,object"` - Text types.Object `tfsdk:"text" tf:"optional,object"` + Text types.List `tfsdk:"text" tf:"optional,object"` } func (newState *GenieAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan GenieAttachment) { @@ -235,6 +325,15 @@ func (a GenieAttachment) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GenieAttachment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Query": QueryAttachment{}.ToAttrType(ctx), + "Text": TextAttachment{}.ToAttrType(ctx), + }, + } +} + type GenieConversation struct { // Timestamp when the message was created CreatedTimestamp types.Int64 `tfsdk:"created_timestamp" tf:"optional"` @@ -260,6 +359,19 @@ func (a GenieConversation) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GenieConversation) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedTimestamp": types.Int64Type, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "SpaceId": types.StringType, + "Title": types.StringType, + "UserId": types.Int64Type, + }, + } +} + type GenieCreateConversationMessageRequest struct { // User message content. Content types.String `tfsdk:"content" tf:""` @@ -279,6 +391,16 @@ func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a GenieCreateConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "ConversationId": types.StringType, + "SpaceId": types.StringType, + }, + } +} + // Execute SQL query in a conversation message type GenieExecuteMessageQueryRequest struct { // Conversation ID @@ -299,6 +421,16 @@ func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a GenieExecuteMessageQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConversationId": types.StringType, + "MessageId": types.StringType, + "SpaceId": types.StringType, + }, + } +} + // Get conversation message type GenieGetConversationMessageRequest struct { // The ID associated with the target conversation. @@ -321,6 +453,16 @@ func (a GenieGetConversationMessageRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a GenieGetConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConversationId": types.StringType, + "MessageId": types.StringType, + "SpaceId": types.StringType, + }, + } +} + // Get conversation message SQL query result type GenieGetMessageQueryResultRequest struct { // Conversation ID @@ -341,6 +483,16 @@ func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GenieGetMessageQueryResultRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConversationId": types.StringType, + "MessageId": types.StringType, + "SpaceId": types.StringType, + }, + } +} + type GenieGetMessageQueryResultResponse struct { // SQL Statement Execution response. See [Get status, manifest, and result // first chunk](:method:statementexecution/getstatement) for more details. @@ -359,6 +511,14 @@ func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes() map[string]re } } +func (a GenieGetMessageQueryResultResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StatementResponse": sql_tf.StatementResponse{}.ToAttrType(ctx), + }, + } +} + type GenieMessage struct { // AI produced response to the message Attachments types.List `tfsdk:"attachments" tf:"optional"` @@ -369,13 +529,13 @@ type GenieMessage struct { // Timestamp when the message was created CreatedTimestamp types.Int64 `tfsdk:"created_timestamp" tf:"optional"` // Error message if AI failed to respond to the message - Error types.Object `tfsdk:"error" tf:"optional,object"` + Error types.List `tfsdk:"error" tf:"optional,object"` // Message ID Id types.String `tfsdk:"id" tf:""` // Timestamp when the message was last updated LastUpdatedTimestamp types.Int64 `tfsdk:"last_updated_timestamp" tf:"optional"` // The result of SQL query if the message has a query attachment - QueryResult types.Object `tfsdk:"query_result" tf:"optional,object"` + QueryResult types.List `tfsdk:"query_result" tf:"optional,object"` // Genie space ID SpaceId types.String `tfsdk:"space_id" tf:""` // MesssageStatus. The possible values are: * `FETCHING_METADATA`: Fetching @@ -413,6 +573,26 @@ func (a GenieMessage) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GenieMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attachments": basetypes.ListType{ + ElemType: GenieAttachment{}.ToAttrType(ctx), + }, + "Content": types.StringType, + "ConversationId": types.StringType, + "CreatedTimestamp": types.Int64Type, + "Error": MessageError{}.ToAttrType(ctx), + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "QueryResult": Result{}.ToAttrType(ctx), + "SpaceId": types.StringType, + "Status": types.StringType, + "UserId": types.Int64Type, + }, + } +} + type GenieStartConversationMessageRequest struct { // The text of the message that starts the conversation. Content types.String `tfsdk:"content" tf:""` @@ -431,12 +611,21 @@ func (a GenieStartConversationMessageRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GenieStartConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "SpaceId": types.StringType, + }, + } +} + type GenieStartConversationResponse struct { - Conversation types.Object `tfsdk:"conversation" tf:"optional,object"` + Conversation types.List `tfsdk:"conversation" tf:"optional,object"` // Conversation ID ConversationId types.String `tfsdk:"conversation_id" tf:""` - Message types.Object `tfsdk:"message" tf:"optional,object"` + Message types.List `tfsdk:"message" tf:"optional,object"` // Message ID MessageId types.String `tfsdk:"message_id" tf:""` } @@ -454,6 +643,17 @@ func (a GenieStartConversationResponse) GetComplexFieldTypes() map[string]reflec } } +func (a GenieStartConversationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Conversation": GenieConversation{}.ToAttrType(ctx), + "ConversationId": types.StringType, + "Message": GenieMessage{}.ToAttrType(ctx), + "MessageId": types.StringType, + }, + } +} + // Get dashboard type GetDashboardRequest struct { // UUID identifying the dashboard. @@ -470,6 +670,14 @@ func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + // Get published dashboard type GetPublishedDashboardRequest struct { // UUID identifying the published dashboard. @@ -486,6 +694,14 @@ func (a GetPublishedDashboardRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a GetPublishedDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + // Get dashboard schedule type GetScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. @@ -504,6 +720,15 @@ func (a GetScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "ScheduleId": types.StringType, + }, + } +} + // Get schedule subscription type GetSubscriptionRequest struct { // UUID identifying the dashboard which the subscription belongs. @@ -524,6 +749,16 @@ func (a GetSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "ScheduleId": types.StringType, + "SubscriptionId": types.StringType, + }, + } +} + // List dashboards type ListDashboardsRequest struct { // The number of dashboards to return per page. @@ -548,6 +783,17 @@ func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "ShowTrashed": types.BoolType, + "View": types.StringType, + }, + } +} + type ListDashboardsResponse struct { Dashboards types.List `tfsdk:"dashboards" tf:"optional"` // A token, which can be sent as `page_token` to retrieve the next page. If @@ -567,6 +813,17 @@ func (a ListDashboardsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListDashboardsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Dashboards": basetypes.ListType{ + ElemType: Dashboard{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List dashboard schedules type ListSchedulesRequest struct { // UUID identifying the dashboard to which the schedules belongs. @@ -588,6 +845,16 @@ func (a ListSchedulesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListSchedulesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListSchedulesResponse struct { // A token that can be used as a `page_token` in subsequent requests to // retrieve the next page of results. If this field is omitted, there are no @@ -609,6 +876,17 @@ func (a ListSchedulesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListSchedulesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Schedules": basetypes.ListType{ + ElemType: Schedule{}.ToAttrType(ctx), + }, + }, + } +} + // List schedule subscriptions type ListSubscriptionsRequest struct { // UUID identifying the dashboard which the subscriptions belongs. @@ -632,6 +910,17 @@ func (a ListSubscriptionsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListSubscriptionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "ScheduleId": types.StringType, + }, + } +} + type ListSubscriptionsResponse struct { // A token that can be used as a `page_token` in subsequent requests to // retrieve the next page of results. If this field is omitted, there are no @@ -653,6 +942,17 @@ func (a ListSubscriptionsResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ListSubscriptionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Subscriptions": basetypes.ListType{ + ElemType: Subscription{}.ToAttrType(ctx), + }, + }, + } +} + type MessageError struct { Error types.String `tfsdk:"error" tf:"optional"` @@ -669,6 +969,15 @@ func (a MessageError) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MessageError) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Error": types.StringType, + "Type": types.StringType, + }, + } +} + type MigrateDashboardRequest struct { // Display name for the new Lakeview dashboard. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -689,6 +998,16 @@ func (a MigrateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a MigrateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "ParentPath": types.StringType, + "SourceDashboardId": types.StringType, + }, + } +} + type PublishRequest struct { // UUID identifying the dashboard to be published. DashboardId types.String `tfsdk:"-"` @@ -711,6 +1030,16 @@ func (a PublishRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PublishRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "EmbedCredentials": types.BoolType, + "WarehouseId": types.StringType, + }, + } +} + type PublishedDashboard struct { // The display name of the published dashboard. DisplayName types.String `tfsdk:"display_name" tf:"computed,optional"` @@ -732,6 +1061,17 @@ func (a PublishedDashboard) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PublishedDashboard) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "EmbedCredentials": types.BoolType, + "RevisionCreateTime": types.StringType, + "WarehouseId": types.StringType, + }, + } +} + type QueryAttachment struct { // Description of the query Description types.String `tfsdk:"description" tf:"optional"` @@ -761,6 +1101,20 @@ func (a QueryAttachment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a QueryAttachment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Id": types.StringType, + "InstructionId": types.StringType, + "InstructionTitle": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "Query": types.StringType, + "Title": types.StringType, + }, + } +} + type Result struct { // If result is truncated IsTruncated types.Bool `tfsdk:"is_truncated" tf:"optional"` @@ -782,12 +1136,22 @@ func (a Result) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Result) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsTruncated": types.BoolType, + "RowCount": types.Int64Type, + "StatementId": types.StringType, + }, + } +} + type Schedule struct { // A timestamp indicating when the schedule was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The cron expression describing the frequency of the periodic refresh for // this schedule. - CronSchedule types.Object `tfsdk:"cron_schedule" tf:"object"` + CronSchedule types.List `tfsdk:"cron_schedule" tf:"object"` // UUID identifying the dashboard to which the schedule belongs. DashboardId types.String `tfsdk:"dashboard_id" tf:"computed,optional"` // The display name for schedule. @@ -818,13 +1182,29 @@ func (a Schedule) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Schedule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "CronSchedule": CronSchedule{}.ToAttrType(ctx), + "DashboardId": types.StringType, + "DisplayName": types.StringType, + "Etag": types.StringType, + "PauseStatus": types.StringType, + "ScheduleId": types.StringType, + "UpdateTime": types.StringType, + "WarehouseId": types.StringType, + }, + } +} + type Subscriber struct { // The destination to receive the subscription email. This parameter is // mutually exclusive with `user_subscriber`. - DestinationSubscriber types.Object `tfsdk:"destination_subscriber" tf:"optional,object"` + DestinationSubscriber types.List `tfsdk:"destination_subscriber" tf:"optional,object"` // The user to receive the subscription email. This parameter is mutually // exclusive with `destination_subscriber`. - UserSubscriber types.Object `tfsdk:"user_subscriber" tf:"optional,object"` + UserSubscriber types.List `tfsdk:"user_subscriber" tf:"optional,object"` } func (newState *Subscriber) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subscriber) { @@ -840,6 +1220,15 @@ func (a Subscriber) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Subscriber) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationSubscriber": SubscriptionSubscriberDestination{}.ToAttrType(ctx), + "UserSubscriber": SubscriptionSubscriberUser{}.ToAttrType(ctx), + }, + } +} + type Subscription struct { // A timestamp indicating when the subscription was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -856,7 +1245,7 @@ type Subscription struct { ScheduleId types.String `tfsdk:"schedule_id" tf:"computed,optional"` // Subscriber details for users and destinations to be added as subscribers // to the schedule. - Subscriber types.Object `tfsdk:"subscriber" tf:"object"` + Subscriber types.List `tfsdk:"subscriber" tf:"object"` // UUID identifying the subscription. SubscriptionId types.String `tfsdk:"subscription_id" tf:"computed,optional"` // A timestamp indicating when the subscription was last updated. @@ -875,6 +1264,21 @@ func (a Subscription) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Subscription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "CreatedByUserId": types.Int64Type, + "DashboardId": types.StringType, + "Etag": types.StringType, + "ScheduleId": types.StringType, + "Subscriber": Subscriber{}.ToAttrType(ctx), + "SubscriptionId": types.StringType, + "UpdateTime": types.StringType, + }, + } +} + type SubscriptionSubscriberDestination struct { // The canonical identifier of the destination to receive email // notification. @@ -891,6 +1295,14 @@ func (a SubscriptionSubscriberDestination) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a SubscriptionSubscriberDestination) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationId": types.StringType, + }, + } +} + type SubscriptionSubscriberUser struct { // UserId of the subscriber. UserId types.Int64 `tfsdk:"user_id" tf:"computed,optional"` @@ -906,6 +1318,14 @@ func (a SubscriptionSubscriberUser) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a SubscriptionSubscriberUser) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "UserId": types.Int64Type, + }, + } +} + type TextAttachment struct { // AI generated message Content types.String `tfsdk:"content" tf:"optional"` @@ -923,6 +1343,15 @@ func (a TextAttachment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TextAttachment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "Id": types.StringType, + }, + } +} + // Trash dashboard type TrashDashboardRequest struct { // UUID identifying the dashboard. @@ -939,6 +1368,14 @@ func (a TrashDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TrashDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + type TrashDashboardResponse struct { } @@ -952,6 +1389,12 @@ func (a TrashDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TrashDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Unpublish dashboard type UnpublishDashboardRequest struct { // UUID identifying the published dashboard. @@ -968,6 +1411,14 @@ func (a UnpublishDashboardRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a UnpublishDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + type UnpublishDashboardResponse struct { } @@ -981,9 +1432,15 @@ func (a UnpublishDashboardResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a UnpublishDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Update dashboard type UpdateDashboardRequest struct { - Dashboard types.Object `tfsdk:"dashboard" tf:"optional,object"` + Dashboard types.List `tfsdk:"dashboard" tf:"optional,object"` // UUID identifying the dashboard. DashboardId types.String `tfsdk:"-"` } @@ -1000,12 +1457,21 @@ func (a UpdateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Dashboard": Dashboard{}.ToAttrType(ctx), + "DashboardId": types.StringType, + }, + } +} + // Update dashboard schedule type UpdateScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. DashboardId types.String `tfsdk:"-"` - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // UUID identifying the schedule. ScheduleId types.String `tfsdk:"-"` } @@ -1021,3 +1487,13 @@ func (a UpdateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { "Schedule": reflect.TypeOf(Schedule{}), } } + +func (a UpdateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Schedule": Schedule{}.ToAttrType(ctx), + "ScheduleId": types.StringType, + }, + } +} diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 991ed48f7d..299b0bce93 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -11,10 +11,13 @@ We use go-native types for lists and maps intentionally for the ease for convert package files_tf import ( + "context" "io" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AddBlock struct { @@ -35,6 +38,15 @@ func (a AddBlock) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AddBlock) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Data": types.StringType, + "Handle": types.Int64Type, + }, + } +} + type AddBlockResponse struct { } @@ -48,6 +60,12 @@ func (a AddBlockResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AddBlockResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Close struct { // The handle on an open stream. Handle types.Int64 `tfsdk:"handle" tf:""` @@ -63,6 +81,14 @@ func (a Close) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Close) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Handle": types.Int64Type, + }, + } +} + type CloseResponse struct { } @@ -76,6 +102,12 @@ func (a CloseResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CloseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Create struct { // The flag that specifies whether to overwrite existing file/files. Overwrite types.Bool `tfsdk:"overwrite" tf:"optional"` @@ -93,6 +125,15 @@ func (a Create) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Create) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Overwrite": types.BoolType, + "Path": types.StringType, + }, + } +} + // Create a directory type CreateDirectoryRequest struct { // The absolute path of a directory. @@ -109,6 +150,14 @@ func (a CreateDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DirectoryPath": types.StringType, + }, + } +} + type CreateDirectoryResponse struct { } @@ -122,6 +171,12 @@ func (a CreateDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CreateDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type CreateResponse struct { // Handle which should subsequently be passed into the AddBlock and Close // calls when writing to a file through a stream. @@ -138,6 +193,14 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Handle": types.Int64Type, + }, + } +} + type Delete struct { // The path of the file or directory to delete. The path should be the // absolute DBFS path. @@ -157,6 +220,15 @@ func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + "Recursive": types.BoolType, + }, + } +} + // Delete a directory type DeleteDirectoryRequest struct { // The absolute path of a directory. @@ -173,6 +245,14 @@ func (a DeleteDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DirectoryPath": types.StringType, + }, + } +} + type DeleteDirectoryResponse struct { } @@ -186,6 +266,12 @@ func (a DeleteDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a file type DeleteFileRequest struct { // The absolute path of the file. @@ -202,6 +288,14 @@ func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FilePath": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -215,6 +309,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DirectoryEntry struct { // The length of the file in bytes. This field is omitted for directories. FileSize types.Int64 `tfsdk:"file_size" tf:"optional"` @@ -239,6 +339,18 @@ func (a DirectoryEntry) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DirectoryEntry) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileSize": types.Int64Type, + "IsDirectory": types.BoolType, + "LastModified": types.Int64Type, + "Name": types.StringType, + "Path": types.StringType, + }, + } +} + // Download a file type DownloadRequest struct { // The absolute path of the file. @@ -255,6 +367,14 @@ func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FilePath": types.StringType, + }, + } +} + type DownloadResponse struct { ContentLength types.Int64 `tfsdk:"-"` @@ -275,6 +395,17 @@ func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ContentLength": types.Int64Type, + "ContentType": types.StringType, + "Contents": types.ObjectType{}, + "LastModified": types.StringType, + }, + } +} + type FileInfo struct { // The length of the file in bytes. This field is omitted for directories. FileSize types.Int64 `tfsdk:"file_size" tf:"optional"` @@ -296,6 +427,17 @@ func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileSize": types.Int64Type, + "IsDir": types.BoolType, + "ModificationTime": types.Int64Type, + "Path": types.StringType, + }, + } +} + // Get directory metadata type GetDirectoryMetadataRequest struct { // The absolute path of a directory. @@ -312,6 +454,14 @@ func (a GetDirectoryMetadataRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetDirectoryMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DirectoryPath": types.StringType, + }, + } +} + type GetDirectoryMetadataResponse struct { } @@ -325,6 +475,12 @@ func (a GetDirectoryMetadataResponse) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a GetDirectoryMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Get file metadata type GetMetadataRequest struct { // The absolute path of the file. @@ -341,6 +497,14 @@ func (a GetMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FilePath": types.StringType, + }, + } +} + type GetMetadataResponse struct { ContentLength types.Int64 `tfsdk:"-"` @@ -359,6 +523,16 @@ func (a GetMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ContentLength": types.Int64Type, + "ContentType": types.StringType, + "LastModified": types.StringType, + }, + } +} + // Get the information of a file or directory type GetStatusRequest struct { // The path of the file or directory. The path should be the absolute DBFS @@ -376,6 +550,14 @@ func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + // List directory contents or file details type ListDbfsRequest struct { // The path of the file or directory. The path should be the absolute DBFS @@ -393,6 +575,14 @@ func (a ListDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + // List directory contents type ListDirectoryContentsRequest struct { // The absolute path of a directory. @@ -429,6 +619,16 @@ func (a ListDirectoryContentsRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a ListDirectoryContentsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DirectoryPath": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListDirectoryResponse struct { // Array of DirectoryEntry. Contents types.List `tfsdk:"contents" tf:"optional"` @@ -448,6 +648,17 @@ func (a ListDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Contents": basetypes.ListType{ + ElemType: DirectoryEntry{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type ListStatusResponse struct { // A list of FileInfo's that describe contents of directory or file. See // example above. @@ -466,6 +677,16 @@ func (a ListStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Files": basetypes.ListType{ + ElemType: FileInfo{}.ToAttrType(ctx), + }, + }, + } +} + type MkDirs struct { // The path of the new directory. The path should be the absolute DBFS path. Path types.String `tfsdk:"path" tf:""` @@ -481,6 +702,14 @@ func (a MkDirs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MkDirs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + type MkDirsResponse struct { } @@ -494,6 +723,12 @@ func (a MkDirsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MkDirsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Move struct { // The destination path of the file or directory. The path should be the // absolute DBFS path. @@ -513,6 +748,15 @@ func (a Move) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Move) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationPath": types.StringType, + "SourcePath": types.StringType, + }, + } +} + type MoveResponse struct { } @@ -526,6 +770,12 @@ func (a MoveResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MoveResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Put struct { // This parameter might be absent, and instead a posted file will be used. Contents types.String `tfsdk:"contents" tf:"optional"` @@ -545,6 +795,16 @@ func (a Put) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Put) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Contents": types.StringType, + "Overwrite": types.BoolType, + "Path": types.StringType, + }, + } +} + type PutResponse struct { } @@ -558,6 +818,12 @@ func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Get the contents of a file type ReadDbfsRequest struct { // The number of bytes to read starting from the offset. This has a limit of @@ -579,6 +845,16 @@ func (a ReadDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ReadDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Length": types.Int64Type, + "Offset": types.Int64Type, + "Path": types.StringType, + }, + } +} + type ReadResponse struct { // The number of bytes read (could be less than ``length`` if we hit end of // file). This refers to number of bytes read in unencoded version (response @@ -598,6 +874,15 @@ func (a ReadResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ReadResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BytesRead": types.Int64Type, + "Data": types.StringType, + }, + } +} + // Upload a file type UploadRequest struct { Contents io.ReadCloser `tfsdk:"-"` @@ -617,6 +902,16 @@ func (a UploadRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UploadRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Contents": types.ObjectType{}, + "FilePath": types.StringType, + "Overwrite": types.BoolType, + }, + } +} + type UploadResponse struct { } @@ -629,3 +924,9 @@ func (newState *UploadResponse) SyncEffectiveFieldsDuringRead(existingState Uplo func (a UploadResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a UploadResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 94fade7736..07e13095b4 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package iam_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AccessControlRequest struct { @@ -37,6 +40,17 @@ func (a AccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type AccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -62,6 +76,20 @@ func (a AccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: Permission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ComplexValue struct { Display types.String `tfsdk:"display" tf:"optional"` @@ -84,6 +112,18 @@ func (a ComplexValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ComplexValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Display": types.StringType, + "Primary": types.BoolType, + "Ref": types.StringType, + "Type": types.StringType, + "Value": types.StringType, + }, + } +} + // Delete a group type DeleteAccountGroupRequest struct { // Unique ID for a group in the Databricks account. @@ -100,6 +140,14 @@ func (a DeleteAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a service principal type DeleteAccountServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks account. @@ -116,6 +164,14 @@ func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a DeleteAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a user type DeleteAccountUserRequest struct { // Unique ID for a user in the Databricks account. @@ -132,6 +188,14 @@ func (a DeleteAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a group type DeleteGroupRequest struct { // Unique ID for a group in the Databricks workspace. @@ -148,6 +212,14 @@ func (a DeleteGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -161,6 +233,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a service principal type DeleteServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks workspace. @@ -177,6 +255,14 @@ func (a DeleteServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a DeleteServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a user type DeleteUserRequest struct { // Unique ID for a user in the Databricks workspace. @@ -193,6 +279,14 @@ func (a DeleteUserRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteUserRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete permissions assignment type DeleteWorkspaceAssignmentRequest struct { // The ID of the user, service principal, or group. @@ -211,6 +305,15 @@ func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a DeleteWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrincipalId": types.Int64Type, + "WorkspaceId": types.Int64Type, + }, + } +} + type DeleteWorkspacePermissionAssignmentResponse struct { } @@ -224,6 +327,12 @@ func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes() map[ return map[string]reflect.Type{} } +func (a DeleteWorkspacePermissionAssignmentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Get group details type GetAccountGroupRequest struct { // Unique ID for a group in the Databricks account. @@ -240,6 +349,14 @@ func (a GetAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Get service principal details type GetAccountServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks account. @@ -256,6 +373,14 @@ func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Get user details type GetAccountUserRequest struct { // Comma-separated list of attributes to return in response. @@ -293,6 +418,21 @@ func (a GetAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "Id": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + // Get assignable roles for a resource type GetAssignableRolesForResourceRequest struct { // The resource name for which assignable roles will be listed. @@ -309,6 +449,14 @@ func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GetAssignableRolesForResourceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Resource": types.StringType, + }, + } +} + type GetAssignableRolesForResourceResponse struct { Roles types.List `tfsdk:"roles" tf:"optional"` } @@ -325,6 +473,16 @@ func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes() map[string } } +func (a GetAssignableRolesForResourceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Roles": basetypes.ListType{ + ElemType: Role{}.ToAttrType(ctx), + }, + }, + } +} + // Get group details type GetGroupRequest struct { // Unique ID for a group in the Databricks workspace. @@ -341,6 +499,14 @@ func (a GetGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetPasswordPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -358,6 +524,16 @@ func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes() map[string]r } } +func (a GetPasswordPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: PasswordPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get object permission levels type GetPermissionLevelsRequest struct { // @@ -376,6 +552,15 @@ func (a GetPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RequestObjectId": types.StringType, + "RequestObjectType": types.StringType, + }, + } +} + type GetPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -393,6 +578,16 @@ func (a GetPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.T } } +func (a GetPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: PermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get object permissions type GetPermissionRequest struct { // The id of the request object. @@ -415,6 +610,15 @@ func (a GetPermissionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RequestObjectId": types.StringType, + "RequestObjectType": types.StringType, + }, + } +} + // Get a rule set type GetRuleSetRequest struct { // Etag used for versioning. The response is at least as fresh as the eTag @@ -440,6 +644,15 @@ func (a GetRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + "Name": types.StringType, + }, + } +} + // Get service principal details type GetServicePrincipalRequest struct { // Unique ID for a service principal in the Databricks workspace. @@ -456,6 +669,14 @@ func (a GetServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Get user details type GetUserRequest struct { // Comma-separated list of attributes to return in response. @@ -493,6 +714,21 @@ func (a GetUserRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetUserRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "Id": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + // List workspace permissions type GetWorkspaceAssignmentRequest struct { // The workspace ID. @@ -509,6 +745,14 @@ func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceId": types.Int64Type, + }, + } +} + type GrantRule struct { // Principals this grant rule applies to. Principals types.List `tfsdk:"principals" tf:"optional"` @@ -524,7 +768,18 @@ func (newState *GrantRule) SyncEffectiveFieldsDuringRead(existingState GrantRule func (a GrantRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Principals": reflect.TypeOf(""), + "Principals": reflect.TypeOf(types.StringType), + } +} + +func (a GrantRule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Principals": basetypes.ListType{ + ElemType: types.StringType, + }, + "Role": types.StringType, + }, } } @@ -545,7 +800,7 @@ type Group struct { Members types.List `tfsdk:"members" tf:"optional"` // Container for the group identifier. Workspace local versus account. - Meta types.Object `tfsdk:"meta" tf:"optional,object"` + Meta types.List `tfsdk:"meta" tf:"optional,object"` // Corresponds to AWS instance profile/arn role. Roles types.List `tfsdk:"roles" tf:"optional"` // The schema of the group. @@ -565,7 +820,33 @@ func (a Group) GetComplexFieldTypes() map[string]reflect.Type { "Members": reflect.TypeOf(ComplexValue{}), "Meta": reflect.TypeOf(ResourceMeta{}), "Roles": reflect.TypeOf(ComplexValue{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a Group) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "Entitlements": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "ExternalId": types.StringType, + "Groups": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Id": types.StringType, + "Members": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Meta": ResourceMeta{}.ToAttrType(ctx), + "Roles": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -603,6 +884,20 @@ func (a ListAccountGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListAccountGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + // List service principals type ListAccountServicePrincipalsRequest struct { // Comma-separated list of attributes to return in response. @@ -637,6 +932,20 @@ func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a ListAccountServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + // List users type ListAccountUsersRequest struct { // Comma-separated list of attributes to return in response. @@ -672,6 +981,20 @@ func (a ListAccountUsersRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListAccountUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + // List group details type ListGroupsRequest struct { // Comma-separated list of attributes to return in response. @@ -706,6 +1029,20 @@ func (a ListGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + type ListGroupsResponse struct { // Total results returned in the response. ItemsPerPage types.Int64 `tfsdk:"itemsPerPage" tf:"optional"` @@ -729,7 +1066,23 @@ func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListGroupsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(Group{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a ListGroupsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ItemsPerPage": types.Int64Type, + "Resources": basetypes.ListType{ + ElemType: Group{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + "StartIndex": types.Int64Type, + "TotalResults": types.Int64Type, + }, } } @@ -756,7 +1109,23 @@ func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringRead(exis func (a ListServicePrincipalResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(ServicePrincipal{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a ListServicePrincipalResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ItemsPerPage": types.Int64Type, + "Resources": basetypes.ListType{ + ElemType: ServicePrincipal{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + "StartIndex": types.Int64Type, + "TotalResults": types.Int64Type, + }, } } @@ -794,6 +1163,20 @@ func (a ListServicePrincipalsRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a ListServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + // List users type ListUsersRequest struct { // Comma-separated list of attributes to return in response. @@ -829,6 +1212,20 @@ func (a ListUsersRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Attributes": types.StringType, + "Count": types.Int64Type, + "ExcludedAttributes": types.StringType, + "Filter": types.StringType, + "SortBy": types.StringType, + "SortOrder": types.StringType, + "StartIndex": types.Int64Type, + }, + } +} + type ListUsersResponse struct { // Total results returned in the response. ItemsPerPage types.Int64 `tfsdk:"itemsPerPage" tf:"optional"` @@ -852,7 +1249,23 @@ func (newState *ListUsersResponse) SyncEffectiveFieldsDuringRead(existingState L func (a ListUsersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(User{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a ListUsersResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ItemsPerPage": types.Int64Type, + "Resources": basetypes.ListType{ + ElemType: User{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + "StartIndex": types.Int64Type, + "TotalResults": types.Int64Type, + }, } } @@ -872,6 +1285,14 @@ func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a ListWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceId": types.Int64Type, + }, + } +} + type MigratePermissionsRequest struct { // The name of the workspace group that permissions will be migrated from. FromWorkspaceGroupName types.String `tfsdk:"from_workspace_group_name" tf:""` @@ -894,6 +1315,17 @@ func (a MigratePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a MigratePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FromWorkspaceGroupName": types.StringType, + "Size": types.Int64Type, + "ToAccountGroupName": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type MigratePermissionsResponse struct { // Number of permissions migrated. PermissionsMigrated types.Int64 `tfsdk:"permissions_migrated" tf:"optional"` @@ -909,6 +1341,14 @@ func (a MigratePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a MigratePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionsMigrated": types.Int64Type, + }, + } +} + type Name struct { // Family name of the Databricks user. FamilyName types.String `tfsdk:"familyName" tf:"optional"` @@ -926,6 +1366,15 @@ func (a Name) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Name) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FamilyName": types.StringType, + "GivenName": types.StringType, + }, + } +} + type ObjectPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -946,6 +1395,18 @@ func (a ObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type PartialUpdate struct { // Unique ID for a user in the Databricks workspace. Id types.String `tfsdk:"-"` @@ -965,7 +1426,21 @@ func (newState *PartialUpdate) SyncEffectiveFieldsDuringRead(existingState Parti func (a PartialUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Operations": reflect.TypeOf(Patch{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a PartialUpdate) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Operations": basetypes.ListType{ + ElemType: Patch{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -990,6 +1465,17 @@ func (a PasswordAccessControlRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a PasswordAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type PasswordAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -1015,6 +1501,20 @@ func (a PasswordAccessControlResponse) GetComplexFieldTypes() map[string]reflect } } +func (a PasswordAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: PasswordPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type PasswordPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1031,7 +1531,19 @@ func (newState *PasswordPermission) SyncEffectiveFieldsDuringRead(existingState func (a PasswordPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a PasswordPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1055,6 +1567,18 @@ func (a PasswordPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PasswordPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: PasswordAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type PasswordPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1071,6 +1595,15 @@ func (a PasswordPermissionsDescription) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a PasswordPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type PasswordPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` } @@ -1087,6 +1620,16 @@ func (a PasswordPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a PasswordPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: PasswordAccessControlRequest{}.ToAttrType(ctx), + }, + }, + } +} + type Patch struct { // Type of patch operation. Op types.String `tfsdk:"op" tf:"optional"` @@ -1106,6 +1649,16 @@ func (a Patch) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Patch) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Op": types.StringType, + "Path": types.StringType, + "Value": types.ObjectType{}, + }, + } +} + type PatchResponse struct { } @@ -1119,6 +1672,12 @@ func (a PatchResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PatchResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Permission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1135,7 +1694,19 @@ func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permissi func (a Permission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a Permission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1147,7 +1718,7 @@ type PermissionAssignment struct { // The permissions level of the principal. Permissions types.List `tfsdk:"permissions" tf:"optional"` // Information about the principal assigned to the workspace. - Principal types.Object `tfsdk:"principal" tf:"optional,object"` + Principal types.List `tfsdk:"principal" tf:"optional,object"` } func (newState *PermissionAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(plan PermissionAssignment) { @@ -1158,11 +1729,23 @@ func (newState *PermissionAssignment) SyncEffectiveFieldsDuringRead(existingStat func (a PermissionAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Permissions": reflect.TypeOf(""), + "Permissions": reflect.TypeOf(types.StringType), "Principal": reflect.TypeOf(PrincipalOutput{}), } } +func (a PermissionAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Error": types.StringType, + "Permissions": basetypes.ListType{ + ElemType: types.StringType, + }, + "Principal": PrincipalOutput{}.ToAttrType(ctx), + }, + } +} + type PermissionAssignments struct { // Array of permissions assignments defined for a workspace. PermissionAssignments types.List `tfsdk:"permission_assignments" tf:"optional"` @@ -1180,6 +1763,16 @@ func (a PermissionAssignments) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PermissionAssignments) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionAssignments": basetypes.ListType{ + ElemType: PermissionAssignment{}.ToAttrType(ctx), + }, + }, + } +} + type PermissionOutput struct { // The results of a permissions query. Description types.String `tfsdk:"description" tf:"optional"` @@ -1197,6 +1790,15 @@ func (a PermissionOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PermissionOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type PermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1213,6 +1815,15 @@ func (a PermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type PermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The id of the request object. @@ -1237,6 +1848,18 @@ func (a PermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AccessControlRequest{}.ToAttrType(ctx), + }, + "RequestObjectId": types.StringType, + "RequestObjectType": types.StringType, + }, + } +} + // Information about the principal assigned to the workspace. type PrincipalOutput struct { // The display name of the principal. @@ -1262,6 +1885,18 @@ func (a PrincipalOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PrincipalOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "GroupName": types.StringType, + "PrincipalId": types.Int64Type, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ResourceMeta struct { // Identifier for group type. Can be local workspace group // (`WorkspaceGroup`) or account group (`Group`). @@ -1278,6 +1913,14 @@ func (a ResourceMeta) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ResourceMeta) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ResourceType": types.StringType, + }, + } +} + type Role struct { // Role to assign to a principal or a list of principals on a resource. Name types.String `tfsdk:"name" tf:""` @@ -1293,6 +1936,14 @@ func (a Role) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Role) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type RuleSetResponse struct { // Identifies the version of the rule set returned. Etag types.String `tfsdk:"etag" tf:"optional"` @@ -1314,6 +1965,18 @@ func (a RuleSetResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RuleSetResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + "GrantRules": basetypes.ListType{ + ElemType: GrantRule{}.ToAttrType(ctx), + }, + "Name": types.StringType, + }, + } +} + type RuleSetUpdateRequest struct { // The expected etag of the rule set to update. The update will fail if the // value does not match the value that is stored in account access control @@ -1337,6 +2000,18 @@ func (a RuleSetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RuleSetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + "GrantRules": basetypes.ListType{ + ElemType: GrantRule{}.ToAttrType(ctx), + }, + "Name": types.StringType, + }, + } +} + type ServicePrincipal struct { // If this user is active Active types.Bool `tfsdk:"active" tf:"optional"` @@ -1372,7 +2047,31 @@ func (a ServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { "Entitlements": reflect.TypeOf(ComplexValue{}), "Groups": reflect.TypeOf(ComplexValue{}), "Roles": reflect.TypeOf(ComplexValue{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a ServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Active": types.BoolType, + "ApplicationId": types.StringType, + "DisplayName": types.StringType, + "Entitlements": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "ExternalId": types.StringType, + "Groups": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Id": types.StringType, + "Roles": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1389,11 +2088,17 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateRuleSetRequest struct { // Name of the rule set. Name types.String `tfsdk:"name" tf:""` - RuleSet types.Object `tfsdk:"rule_set" tf:"object"` + RuleSet types.List `tfsdk:"rule_set" tf:"object"` } func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRuleSetRequest) { @@ -1408,6 +2113,15 @@ func (a UpdateRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "RuleSet": RuleSetUpdateRequest{}.ToAttrType(ctx), + }, + } +} + type UpdateWorkspaceAssignments struct { // Array of permissions assignments to update on the workspace. Valid values // are "USER" and "ADMIN" (case-sensitive). If both "USER" and "ADMIN" are @@ -1430,7 +2144,19 @@ func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringRead(existi func (a UpdateWorkspaceAssignments) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Permissions": reflect.TypeOf(""), + "Permissions": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateWorkspaceAssignments) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Permissions": basetypes.ListType{ + ElemType: types.StringType, + }, + "PrincipalId": types.Int64Type, + "WorkspaceId": types.Int64Type, + }, } } @@ -1459,7 +2185,7 @@ type User struct { // provided by the client will be ignored. Id types.String `tfsdk:"id" tf:"optional"` - Name types.Object `tfsdk:"name" tf:"optional,object"` + Name types.List `tfsdk:"name" tf:"optional,object"` // Corresponds to AWS instance profile/arn role. Roles types.List `tfsdk:"roles" tf:"optional"` // The schema of the user. @@ -1481,7 +2207,35 @@ func (a User) GetComplexFieldTypes() map[string]reflect.Type { "Groups": reflect.TypeOf(ComplexValue{}), "Name": reflect.TypeOf(Name{}), "Roles": reflect.TypeOf(ComplexValue{}), - "Schemas": reflect.TypeOf(""), + "Schemas": reflect.TypeOf(types.StringType), + } +} + +func (a User) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Active": types.BoolType, + "DisplayName": types.StringType, + "Emails": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Entitlements": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "ExternalId": types.StringType, + "Groups": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Id": types.StringType, + "Name": Name{}.ToAttrType(ctx), + "Roles": basetypes.ListType{ + ElemType: ComplexValue{}.ToAttrType(ctx), + }, + "Schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + "UserName": types.StringType, + }, } } @@ -1501,3 +2255,13 @@ func (a WorkspacePermissions) GetComplexFieldTypes() map[string]reflect.Type { "Permissions": reflect.TypeOf(PermissionOutput{}), } } + +func (a WorkspacePermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Permissions": basetypes.ListType{ + ElemType: PermissionOutput{}.ToAttrType(ctx), + }, + }, + } +} diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index e185640d6a..80fb341808 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -11,10 +11,14 @@ We use go-native types for lists and maps intentionally for the ease for convert package jobs_tf import ( + "context" "reflect" "github.com/databricks/databricks-sdk-go/service/compute" + "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type BaseJob struct { @@ -35,7 +39,7 @@ type BaseJob struct { JobId types.Int64 `tfsdk:"job_id" tf:"optional"` // Settings for this job and all of its runs. These settings can be updated // using the `resetJob` method. - Settings types.Object `tfsdk:"settings" tf:"optional,object"` + Settings types.List `tfsdk:"settings" tf:"optional,object"` } func (newState *BaseJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseJob) { @@ -50,6 +54,18 @@ func (a BaseJob) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a BaseJob) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedTime": types.Int64Type, + "CreatorUserName": types.StringType, + "EffectiveBudgetPolicyId": types.StringType, + "JobId": types.Int64Type, + "Settings": JobSettings{}.ToAttrType(ctx), + }, + } +} + type BaseRun struct { // The sequence number of this run attempt for a triggered job run. The // initial attempt of a run has an attempt_number of 0. If the initial run @@ -68,10 +84,10 @@ type BaseRun struct { // The cluster used for this run. If the run is specified to use a new // cluster, this field is set once the Jobs service has requested a cluster // for the run. - ClusterInstance types.Object `tfsdk:"cluster_instance" tf:"optional,object"` + ClusterInstance types.List `tfsdk:"cluster_instance" tf:"optional,object"` // A snapshot of the job’s cluster specification when this run was // created. - ClusterSpec types.Object `tfsdk:"cluster_spec" tf:"optional,object"` + ClusterSpec types.List `tfsdk:"cluster_spec" tf:"optional,object"` // The creator user name. This field won’t be included in the response if // the user has already been deleted. CreatorUserName types.String `tfsdk:"creator_user_name" tf:"optional"` @@ -98,7 +114,7 @@ type BaseRun struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` + GitSource types.List `tfsdk:"git_source" tf:"optional,object"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. @@ -119,7 +135,7 @@ type BaseRun struct { // run_id of the original attempt; otherwise, it is the same as the run_id. OriginalAttemptRunId types.Int64 `tfsdk:"original_attempt_run_id" tf:"optional"` // The parameters used for this run. - OverridingParameters types.Object `tfsdk:"overriding_parameters" tf:"optional,object"` + OverridingParameters types.List `tfsdk:"overriding_parameters" tf:"optional,object"` // The time in milliseconds that the run has spent in the queue. QueueDuration types.Int64 `tfsdk:"queue_duration" tf:"optional"` // The repair history of the run. @@ -144,7 +160,7 @@ type BaseRun struct { RunType types.String `tfsdk:"run_type" tf:"optional"` // The cron schedule that triggered this run if it was triggered by the // periodic scheduler. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // The time in milliseconds it took to set up the cluster. For runs that run // on new clusters this is the cluster creation time, for runs that run on // existing clusters this time should be very short. The duration of a task @@ -159,9 +175,9 @@ type BaseRun struct { // new cluster, this is the time the cluster creation call is issued. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` // The list of tasks performed by the run. Each task has its own `run_id` // which you can use to call `JobsGetOutput` to retrieve the run resutls. Tasks types.List `tfsdk:"tasks" tf:"optional"` @@ -177,7 +193,7 @@ type BaseRun struct { // arrival. * `TABLE`: Indicates a run that is triggered by a table update. Trigger types.String `tfsdk:"trigger" tf:"optional"` // Additional details about what triggered the run - TriggerInfo types.Object `tfsdk:"trigger_info" tf:"optional,object"` + TriggerInfo types.List `tfsdk:"trigger_info" tf:"optional,object"` } func (newState *BaseRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseRun) { @@ -203,6 +219,52 @@ func (a BaseRun) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a BaseRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AttemptNumber": types.Int64Type, + "CleanupDuration": types.Int64Type, + "ClusterInstance": ClusterInstance{}.ToAttrType(ctx), + "ClusterSpec": ClusterSpec{}.ToAttrType(ctx), + "CreatorUserName": types.StringType, + "Description": types.StringType, + "EndTime": types.Int64Type, + "ExecutionDuration": types.Int64Type, + "GitSource": GitSource{}.ToAttrType(ctx), + "JobClusters": basetypes.ListType{ + ElemType: JobCluster{}.ToAttrType(ctx), + }, + "JobId": types.Int64Type, + "JobParameters": basetypes.ListType{ + ElemType: JobParameter{}.ToAttrType(ctx), + }, + "JobRunId": types.Int64Type, + "NumberInJob": types.Int64Type, + "OriginalAttemptRunId": types.Int64Type, + "OverridingParameters": RunParameters{}.ToAttrType(ctx), + "QueueDuration": types.Int64Type, + "RepairHistory": basetypes.ListType{ + ElemType: RepairHistoryItem{}.ToAttrType(ctx), + }, + "RunDuration": types.Int64Type, + "RunId": types.Int64Type, + "RunName": types.StringType, + "RunPageUrl": types.StringType, + "RunType": types.StringType, + "Schedule": CronSchedule{}.ToAttrType(ctx), + "SetupDuration": types.Int64Type, + "StartTime": types.Int64Type, + "State": RunState{}.ToAttrType(ctx), + "Status": RunStatus{}.ToAttrType(ctx), + "Tasks": basetypes.ListType{ + ElemType: RunTask{}.ToAttrType(ctx), + }, + "Trigger": types.StringType, + "TriggerInfo": TriggerInfo{}.ToAttrType(ctx), + }, + } +} + type CancelAllRuns struct { // Optional boolean parameter to cancel all queued runs. If no job_id is // provided, all queued runs in the workspace are canceled. @@ -221,6 +283,15 @@ func (a CancelAllRuns) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelAllRuns) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllQueuedRuns": types.BoolType, + "JobId": types.Int64Type, + }, + } +} + type CancelAllRunsResponse struct { } @@ -234,6 +305,12 @@ func (a CancelAllRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelAllRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type CancelRun struct { // This field is required. RunId types.Int64 `tfsdk:"run_id" tf:""` @@ -249,6 +326,14 @@ func (a CancelRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + }, + } +} + type CancelRunResponse struct { } @@ -262,6 +347,12 @@ func (a CancelRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ClusterInstance struct { // The canonical identifier for the cluster used by a run. This field is // always available for runs on existing clusters. For runs on new clusters, @@ -293,6 +384,15 @@ func (a ClusterInstance) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ClusterInstance) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "SparkContextId": types.StringType, + }, + } +} + type ClusterSpec struct { // If existing_cluster_id, the ID of an existing cluster that is used for // all runs. When running jobs or tasks on an existing cluster, you may need @@ -323,6 +423,19 @@ func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExistingClusterId": types.StringType, + "JobClusterKey": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: compute_tf.Library{}.ToAttrType(ctx), + }, + "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, + } +} + type ConditionTask struct { // The left operand of the condition task. Can be either a string value or a // job state or parameter reference. @@ -353,6 +466,16 @@ func (a ConditionTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ConditionTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Left": types.StringType, + "Op": types.StringType, + "Right": types.StringType, + }, + } +} + type Continuous struct { // Indicate whether the continuous execution of the job is paused or not. // Defaults to UNPAUSED. @@ -369,6 +492,14 @@ func (a Continuous) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Continuous) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PauseStatus": types.StringType, + }, + } +} + type CreateJob struct { // List of permissions to set on the job. AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -380,9 +511,9 @@ type CreateJob struct { // An optional continuous property for this job. The continuous property // will ensure that there is always one run executing. Only one of // `schedule` and `continuous` can be used. - Continuous types.Object `tfsdk:"continuous" tf:"optional,object"` + Continuous types.List `tfsdk:"continuous" tf:"optional,object"` // Deployment information for jobs managed by external sources. - Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` + Deployment types.List `tfsdk:"deployment" tf:"optional,object"` // An optional description for the job. The maximum length is 27700 // characters in UTF-8 encoding. Description types.String `tfsdk:"description" tf:"optional"` @@ -393,7 +524,7 @@ type CreateJob struct { EditMode types.String `tfsdk:"edit_mode" tf:"optional"` // An optional set of email addresses that is notified when runs of this job // begin or complete as well as when this job is deleted. - EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.List `tfsdk:"email_notifications" tf:"optional,object"` // A list of task execution environment specifications that can be // referenced by serverless tasks of this job. An environment is required to // be present for serverless tasks. For serverless notebook tasks, the @@ -415,9 +546,9 @@ type CreateJob struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` + GitSource types.List `tfsdk:"git_source" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. @@ -440,22 +571,22 @@ type CreateJob struct { // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // job. - NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.List `tfsdk:"notification_settings" tf:"optional,object"` // Job-level parameter definitions Parameters types.List `tfsdk:"parameter" tf:"optional"` // The queue settings of the job. - Queue types.Object `tfsdk:"queue" tf:"optional,object"` + Queue types.List `tfsdk:"queue" tf:"optional,object"` // Write-only setting. Specifies the user, service principal or group that // the job/pipeline runs as. If not specified, the job/pipeline runs as the // user who created the job/pipeline. // // Either `user_name` or `service_principal_name` should be specified. If // not, an error is thrown. - RunAs types.Object `tfsdk:"run_as" tf:"optional,object"` + RunAs types.List `tfsdk:"run_as" tf:"optional,object"` // An optional periodic schedule for this job. The default behavior is that // the job only runs when triggered by clicking “Run Now” in the Jobs UI // or sending an API request to `runNow`. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // A map of tags associated with the job. These are forwarded to the cluster // as cluster tags for jobs clusters, and are subject to the same // limitations as cluster tags. A maximum of 25 tags can be added to the @@ -469,10 +600,10 @@ type CreateJob struct { // A configuration to trigger a run when certain conditions are met. The // default behavior is that the job runs only when triggered by clicking // “Run Now” in the Jobs UI or sending an API request to `runNow`. - Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` + Trigger types.List `tfsdk:"trigger" tf:"optional,object"` // A collection of system notification IDs to notify when runs of this job // begin or complete. - WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.List `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *CreateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateJob) { @@ -496,13 +627,56 @@ func (a CreateJob) GetComplexFieldTypes() map[string]reflect.Type { "Queue": reflect.TypeOf(QueueSettings{}), "RunAs": reflect.TypeOf(JobRunAs{}), "Schedule": reflect.TypeOf(CronSchedule{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), "Tasks": reflect.TypeOf(Task{}), "Trigger": reflect.TypeOf(TriggerSettings{}), "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), } } +func (a CreateJob) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: JobAccessControlRequest{}.ToAttrType(ctx), + }, + "BudgetPolicyId": types.StringType, + "Continuous": Continuous{}.ToAttrType(ctx), + "Deployment": JobDeployment{}.ToAttrType(ctx), + "Description": types.StringType, + "EditMode": types.StringType, + "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), + "Environments": basetypes.ListType{ + ElemType: JobEnvironment{}.ToAttrType(ctx), + }, + "Format": types.StringType, + "GitSource": GitSource{}.ToAttrType(ctx), + "Health": JobsHealthRules{}.ToAttrType(ctx), + "JobClusters": basetypes.ListType{ + ElemType: JobCluster{}.ToAttrType(ctx), + }, + "MaxConcurrentRuns": types.Int64Type, + "Name": types.StringType, + "NotificationSettings": JobNotificationSettings{}.ToAttrType(ctx), + "Parameters": basetypes.ListType{ + ElemType: JobParameterDefinition{}.ToAttrType(ctx), + }, + "Queue": QueueSettings{}.ToAttrType(ctx), + "RunAs": JobRunAs{}.ToAttrType(ctx), + "Schedule": CronSchedule{}.ToAttrType(ctx), + "Tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "Tasks": basetypes.ListType{ + ElemType: Task{}.ToAttrType(ctx), + }, + "TimeoutSeconds": types.Int64Type, + "Trigger": TriggerSettings{}.ToAttrType(ctx), + "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + }, + } +} + // Job was created successfully type CreateResponse struct { // The canonical identifier for the newly created job. @@ -519,6 +693,14 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.Int64Type, + }, + } +} + type CronSchedule struct { // Indicate whether this schedule is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` @@ -544,6 +726,16 @@ func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PauseStatus": types.StringType, + "QuartzCronExpression": types.StringType, + "TimezoneId": types.StringType, + }, + } +} + type DbtOutput struct { // An optional map of headers to send when retrieving the artifact from the // `artifacts_link`. @@ -562,7 +754,18 @@ func (newState *DbtOutput) SyncEffectiveFieldsDuringRead(existingState DbtOutput func (a DbtOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ArtifactsHeaders": reflect.TypeOf(""), + "ArtifactsHeaders": reflect.TypeOf(types.StringType), + } +} + +func (a DbtOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactsHeaders": basetypes.MapType{ + ElemType: types.StringType, + }, + "ArtifactsLink": types.StringType, + }, } } @@ -611,7 +814,23 @@ func (newState *DbtTask) SyncEffectiveFieldsDuringRead(existingState DbtTask) { func (a DbtTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Commands": reflect.TypeOf(""), + "Commands": reflect.TypeOf(types.StringType), + } +} + +func (a DbtTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Catalog": types.StringType, + "Commands": basetypes.ListType{ + ElemType: types.StringType, + }, + "ProfilesDirectory": types.StringType, + "ProjectDirectory": types.StringType, + "Schema": types.StringType, + "Source": types.StringType, + "WarehouseId": types.StringType, + }, } } @@ -630,6 +849,14 @@ func (a DeleteJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteJob) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.Int64Type, + }, + } +} + type DeleteResponse struct { } @@ -643,6 +870,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteRun struct { // ID of the run to delete. RunId types.Int64 `tfsdk:"run_id" tf:""` @@ -658,6 +891,14 @@ func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + }, + } +} + type DeleteRunResponse struct { } @@ -671,6 +912,12 @@ func (a DeleteRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Represents a change to the job cluster's settings that would be required for // the job clusters to become compliant with their policies. type EnforcePolicyComplianceForJobResponseJobClusterSettingsChange struct { @@ -699,6 +946,16 @@ func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComple return map[string]reflect.Type{} } +func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Field": types.StringType, + "NewValue": types.StringType, + "PreviousValue": types.StringType, + }, + } +} + type EnforcePolicyComplianceRequest struct { // The ID of the job you want to enforce policy compliance on. JobId types.Int64 `tfsdk:"job_id" tf:""` @@ -717,6 +974,15 @@ func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a EnforcePolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.Int64Type, + "ValidateOnly": types.BoolType, + }, + } +} + type EnforcePolicyComplianceResponse struct { // Whether any changes have been made to the job cluster settings for the // job to become compliant with its policies. @@ -731,7 +997,7 @@ type EnforcePolicyComplianceResponse struct { // clusters. Updated job settings are derived by applying policy default // values to the existing job clusters in order to satisfy policy // requirements. - Settings types.Object `tfsdk:"settings" tf:"optional,object"` + Settings types.List `tfsdk:"settings" tf:"optional,object"` } func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan EnforcePolicyComplianceResponse) { @@ -747,6 +1013,18 @@ func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes() map[string]refle } } +func (a EnforcePolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "HasChanges": types.BoolType, + "JobClusterChanges": basetypes.ListType{ + ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.ToAttrType(ctx), + }, + "Settings": JobSettings{}.ToAttrType(ctx), + }, + } +} + // Run was exported successfully. type ExportRunOutput struct { // The exported content in HTML format (one for every view item). To extract @@ -769,6 +1047,16 @@ func (a ExportRunOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ExportRunOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Views": basetypes.ListType{ + ElemType: ViewItem{}.ToAttrType(ctx), + }, + }, + } +} + // Export and retrieve a job run type ExportRunRequest struct { // The canonical identifier for the run. This field is required. @@ -787,6 +1075,15 @@ func (a ExportRunRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExportRunRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + "ViewsToExport": types.StringType, + }, + } +} + type FileArrivalTriggerConfiguration struct { // If set, the trigger starts a run only after the specified amount of time // passed since the last time the trigger fired. The minimum allowed value @@ -812,11 +1109,21 @@ func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a FileArrivalTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MinTimeBetweenTriggersSeconds": types.Int64Type, + "Url": types.StringType, + "WaitAfterLastChangeSeconds": types.Int64Type, + }, + } +} + type ForEachStats struct { // Sample of 3 most common error messages occurred during the iteration. ErrorMessageStats types.List `tfsdk:"error_message_stats" tf:"optional"` // Describes stats of the iteration. Only latest retries are considered. - TaskRunStats types.Object `tfsdk:"task_run_stats" tf:"optional,object"` + TaskRunStats types.List `tfsdk:"task_run_stats" tf:"optional,object"` } func (newState *ForEachStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEachStats) { @@ -832,6 +1139,17 @@ func (a ForEachStats) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ForEachStats) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ErrorMessageStats": basetypes.ListType{ + ElemType: ForEachTaskErrorMessageStats{}.ToAttrType(ctx), + }, + "TaskRunStats": ForEachTaskTaskRunStats{}.ToAttrType(ctx), + }, + } +} + type ForEachTask struct { // An optional maximum allowed number of concurrent runs of the task. Set // this value if you want to be able to execute multiple runs of the task @@ -841,7 +1159,7 @@ type ForEachTask struct { // an array parameter. Inputs types.String `tfsdk:"inputs" tf:""` // Configuration for the task that will be run for each element in the array - Task types.Object `tfsdk:"task" tf:"object"` + Task types.List `tfsdk:"task" tf:"object"` } func (newState *ForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEachTask) { @@ -856,6 +1174,16 @@ func (a ForEachTask) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ForEachTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Concurrency": types.Int64Type, + "Inputs": types.StringType, + "Task": Task{}.ToAttrType(ctx), + }, + } +} + type ForEachTaskErrorMessageStats struct { // Describes the count of such error message encountered during the // iterations. @@ -876,6 +1204,16 @@ func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a ForEachTaskErrorMessageStats) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Count": types.Int64Type, + "ErrorMessage": types.StringType, + "TerminationCategory": types.StringType, + }, + } +} + type ForEachTaskTaskRunStats struct { // Describes the iteration runs having an active lifecycle state or an // active run sub state. @@ -902,6 +1240,19 @@ func (a ForEachTaskTaskRunStats) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ForEachTaskTaskRunStats) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActiveIterations": types.Int64Type, + "CompletedIterations": types.Int64Type, + "FailedIterations": types.Int64Type, + "ScheduledIterations": types.Int64Type, + "SucceededIterations": types.Int64Type, + "TotalIterations": types.Int64Type, + }, + } +} + // Get job permission levels type GetJobPermissionLevelsRequest struct { // The job for which to get or manage permissions. @@ -918,6 +1269,14 @@ func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetJobPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.StringType, + }, + } +} + type GetJobPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -935,6 +1294,16 @@ func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflec } } +func (a GetJobPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: JobPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get job permissions type GetJobPermissionsRequest struct { // The job for which to get or manage permissions. @@ -951,6 +1320,14 @@ func (a GetJobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetJobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.StringType, + }, + } +} + // Get a single job type GetJobRequest struct { // The canonical identifier of the job to retrieve information about. This @@ -968,6 +1345,14 @@ func (a GetJobRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetJobRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.Int64Type, + }, + } +} + // Get job policy compliance type GetPolicyComplianceRequest struct { // The ID of the job whose compliance status you are requesting. @@ -984,6 +1369,14 @@ func (a GetPolicyComplianceRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a GetPolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.Int64Type, + }, + } +} + type GetPolicyComplianceResponse struct { // Whether the job is compliant with its policies or not. Jobs could be out // of compliance if a policy they are using was updated after the job was @@ -1006,7 +1399,18 @@ func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringRead(exist func (a GetPolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(""), + "Violations": reflect.TypeOf(types.StringType), + } +} + +func (a GetPolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsCompliant": types.BoolType, + "Violations": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -1026,6 +1430,14 @@ func (a GetRunOutputRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRunOutputRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + }, + } +} + // Get a single job run type GetRunRequest struct { // Whether to include the repair history in the response. @@ -1050,6 +1462,17 @@ func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeHistory": types.BoolType, + "IncludeResolvedValues": types.BoolType, + "PageToken": types.StringType, + "RunId": types.Int64Type, + }, + } +} + // Read-only state of the remote repository at the time the job was run. This // field is only included on job runs. type GitSnapshot struct { @@ -1069,6 +1492,14 @@ func (a GitSnapshot) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GitSnapshot) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "UsedCommit": types.StringType, + }, + } +} + // An optional specification for a remote Git repository containing the source // code used by tasks. Version-controlled source code is supported by notebook, // dbt, Python script, and SQL File tasks. @@ -1091,7 +1522,7 @@ type GitSource struct { GitProvider types.String `tfsdk:"git_provider" tf:""` // Read-only state of the remote repository at the time the job was run. // This field is only included on job runs. - GitSnapshot types.Object `tfsdk:"git_snapshot" tf:"optional,object"` + GitSnapshot types.List `tfsdk:"git_snapshot" tf:"optional,object"` // Name of the tag to be checked out and used by this job. This field cannot // be specified in conjunction with git_branch or git_commit. GitTag types.String `tfsdk:"tag" tf:"optional"` @@ -1099,7 +1530,7 @@ type GitSource struct { GitUrl types.String `tfsdk:"url" tf:""` // The source of the job specification in the remote repository when the job // is source controlled. - JobSource types.Object `tfsdk:"job_source" tf:"optional,object"` + JobSource types.List `tfsdk:"job_source" tf:"optional,object"` } func (newState *GitSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSource) { @@ -1115,6 +1546,20 @@ func (a GitSource) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GitSource) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GitBranch": types.StringType, + "GitCommit": types.StringType, + "GitProvider": types.StringType, + "GitSnapshot": GitSnapshot{}.ToAttrType(ctx), + "GitTag": types.StringType, + "GitUrl": types.StringType, + "JobSource": JobSource{}.ToAttrType(ctx), + }, + } +} + // Job was retrieved successfully. type Job struct { // The time at which this job was created in epoch milliseconds @@ -1142,7 +1587,7 @@ type Job struct { RunAsUserName types.String `tfsdk:"run_as_user_name" tf:"optional"` // Settings for this job and all of its runs. These settings can be updated // using the `resetJob` method. - Settings types.Object `tfsdk:"settings" tf:"optional,object"` + Settings types.List `tfsdk:"settings" tf:"optional,object"` } func (newState *Job) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job) { @@ -1157,6 +1602,19 @@ func (a Job) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Job) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedTime": types.Int64Type, + "CreatorUserName": types.StringType, + "EffectiveBudgetPolicyId": types.StringType, + "JobId": types.Int64Type, + "RunAsUserName": types.StringType, + "Settings": JobSettings{}.ToAttrType(ctx), + }, + } +} + type JobAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1178,6 +1636,17 @@ func (a JobAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a JobAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type JobAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -1203,6 +1672,20 @@ func (a JobAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a JobAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: JobPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type JobCluster struct { // A unique name for the job cluster. This field is required and must be // unique within the job. `JobTaskSettings` may refer to this field to @@ -1224,6 +1707,15 @@ func (a JobCluster) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a JobCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobClusterKey": types.StringType, + "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, + } +} + type JobCompliance struct { // Whether this job is in compliance with the latest version of its policy. IsCompliant types.Bool `tfsdk:"is_compliant" tf:"optional"` @@ -1245,7 +1737,19 @@ func (newState *JobCompliance) SyncEffectiveFieldsDuringRead(existingState JobCo func (a JobCompliance) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(""), + "Violations": reflect.TypeOf(types.StringType), + } +} + +func (a JobCompliance) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsCompliant": types.BoolType, + "JobId": types.Int64Type, + "Violations": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -1268,6 +1772,15 @@ func (a JobDeployment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobDeployment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Kind": types.StringType, + "MetadataFilePath": types.StringType, + }, + } +} + type JobEmailNotifications struct { // If true, do not send email to recipients specified in `on_failure` if the // run is skipped. This field is `deprecated`. Please use the @@ -1312,11 +1825,34 @@ func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringRead(existingSta func (a JobEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OnDurationWarningThresholdExceeded": reflect.TypeOf(""), - "OnFailure": reflect.TypeOf(""), - "OnStart": reflect.TypeOf(""), - "OnStreamingBacklogExceeded": reflect.TypeOf(""), - "OnSuccess": reflect.TypeOf(""), + "OnDurationWarningThresholdExceeded": reflect.TypeOf(types.StringType), + "OnFailure": reflect.TypeOf(types.StringType), + "OnStart": reflect.TypeOf(types.StringType), + "OnStreamingBacklogExceeded": reflect.TypeOf(types.StringType), + "OnSuccess": reflect.TypeOf(types.StringType), + } +} + +func (a JobEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NoAlertForSkippedRuns": types.BoolType, + "OnDurationWarningThresholdExceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnFailure": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnStart": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnStreamingBacklogExceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnSuccess": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1341,6 +1877,15 @@ func (a JobEnvironment) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a JobEnvironment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EnvironmentKey": types.StringType, + "Spec": compute_tf.Environment{}.ToAttrType(ctx), + }, + } +} + type JobNotificationSettings struct { // If true, do not send notifications to recipients specified in // `on_failure` if the run is canceled. @@ -1360,6 +1905,15 @@ func (a JobNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a JobNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NoAlertForCanceledRuns": types.BoolType, + "NoAlertForSkippedRuns": types.BoolType, + }, + } +} + type JobParameter struct { // The optional default value of the parameter Default types.String `tfsdk:"default" tf:"optional"` @@ -1379,6 +1933,16 @@ func (a JobParameter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobParameter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Default": types.StringType, + "Name": types.StringType, + "Value": types.StringType, + }, + } +} + type JobParameterDefinition struct { // Default value of the parameter. Default types.String `tfsdk:"default" tf:""` @@ -1397,6 +1961,15 @@ func (a JobParameterDefinition) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobParameterDefinition) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Default": types.StringType, + "Name": types.StringType, + }, + } +} + type JobPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1413,7 +1986,19 @@ func (newState *JobPermission) SyncEffectiveFieldsDuringRead(existingState JobPe func (a JobPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a JobPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1437,6 +2022,18 @@ func (a JobPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a JobPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: JobAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type JobPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1453,6 +2050,15 @@ func (a JobPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a JobPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type JobPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The job for which to get or manage permissions. @@ -1471,6 +2077,17 @@ func (a JobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a JobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: JobAccessControlRequest{}.ToAttrType(ctx), + }, + "JobId": types.StringType, + }, + } +} + // Write-only setting. Specifies the user, service principal or group that the // job/pipeline runs as. If not specified, the job/pipeline runs as the user who // created the job/pipeline. @@ -1496,6 +2113,15 @@ func (a JobRunAs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobRunAs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type JobSettings struct { // The id of the user specified budget policy to use for this job. If not // specified, a default budget policy may be applied when creating or @@ -1505,9 +2131,9 @@ type JobSettings struct { // An optional continuous property for this job. The continuous property // will ensure that there is always one run executing. Only one of // `schedule` and `continuous` can be used. - Continuous types.Object `tfsdk:"continuous" tf:"optional,object"` + Continuous types.List `tfsdk:"continuous" tf:"optional,object"` // Deployment information for jobs managed by external sources. - Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` + Deployment types.List `tfsdk:"deployment" tf:"optional,object"` // An optional description for the job. The maximum length is 27700 // characters in UTF-8 encoding. Description types.String `tfsdk:"description" tf:"optional"` @@ -1518,7 +2144,7 @@ type JobSettings struct { EditMode types.String `tfsdk:"edit_mode" tf:"optional"` // An optional set of email addresses that is notified when runs of this job // begin or complete as well as when this job is deleted. - EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.List `tfsdk:"email_notifications" tf:"optional,object"` // A list of task execution environment specifications that can be // referenced by serverless tasks of this job. An environment is required to // be present for serverless tasks. For serverless notebook tasks, the @@ -1540,9 +2166,9 @@ type JobSettings struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` + GitSource types.List `tfsdk:"git_source" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // A list of job cluster specifications that can be shared and reused by // tasks of this job. Libraries cannot be declared in a shared job cluster. // You must declare dependent libraries in task settings. @@ -1565,22 +2191,22 @@ type JobSettings struct { // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // job. - NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.List `tfsdk:"notification_settings" tf:"optional,object"` // Job-level parameter definitions Parameters types.List `tfsdk:"parameter" tf:"optional"` // The queue settings of the job. - Queue types.Object `tfsdk:"queue" tf:"optional,object"` + Queue types.List `tfsdk:"queue" tf:"optional,object"` // Write-only setting. Specifies the user, service principal or group that // the job/pipeline runs as. If not specified, the job/pipeline runs as the // user who created the job/pipeline. // // Either `user_name` or `service_principal_name` should be specified. If // not, an error is thrown. - RunAs types.Object `tfsdk:"run_as" tf:"optional,object"` + RunAs types.List `tfsdk:"run_as" tf:"optional,object"` // An optional periodic schedule for this job. The default behavior is that // the job only runs when triggered by clicking “Run Now” in the Jobs UI // or sending an API request to `runNow`. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // A map of tags associated with the job. These are forwarded to the cluster // as cluster tags for jobs clusters, and are subject to the same // limitations as cluster tags. A maximum of 25 tags can be added to the @@ -1594,10 +2220,10 @@ type JobSettings struct { // A configuration to trigger a run when certain conditions are met. The // default behavior is that the job runs only when triggered by clicking // “Run Now” in the Jobs UI or sending an API request to `runNow`. - Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` + Trigger types.List `tfsdk:"trigger" tf:"optional,object"` // A collection of system notification IDs to notify when runs of this job // begin or complete. - WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.List `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *JobSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSettings) { @@ -1620,13 +2246,53 @@ func (a JobSettings) GetComplexFieldTypes() map[string]reflect.Type { "Queue": reflect.TypeOf(QueueSettings{}), "RunAs": reflect.TypeOf(JobRunAs{}), "Schedule": reflect.TypeOf(CronSchedule{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), "Tasks": reflect.TypeOf(Task{}), "Trigger": reflect.TypeOf(TriggerSettings{}), "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), } } +func (a JobSettings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BudgetPolicyId": types.StringType, + "Continuous": Continuous{}.ToAttrType(ctx), + "Deployment": JobDeployment{}.ToAttrType(ctx), + "Description": types.StringType, + "EditMode": types.StringType, + "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), + "Environments": basetypes.ListType{ + ElemType: JobEnvironment{}.ToAttrType(ctx), + }, + "Format": types.StringType, + "GitSource": GitSource{}.ToAttrType(ctx), + "Health": JobsHealthRules{}.ToAttrType(ctx), + "JobClusters": basetypes.ListType{ + ElemType: JobCluster{}.ToAttrType(ctx), + }, + "MaxConcurrentRuns": types.Int64Type, + "Name": types.StringType, + "NotificationSettings": JobNotificationSettings{}.ToAttrType(ctx), + "Parameters": basetypes.ListType{ + ElemType: JobParameterDefinition{}.ToAttrType(ctx), + }, + "Queue": QueueSettings{}.ToAttrType(ctx), + "RunAs": JobRunAs{}.ToAttrType(ctx), + "Schedule": CronSchedule{}.ToAttrType(ctx), + "Tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "Tasks": basetypes.ListType{ + ElemType: Task{}.ToAttrType(ctx), + }, + "TimeoutSeconds": types.Int64Type, + "Trigger": TriggerSettings{}.ToAttrType(ctx), + "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + }, + } +} + // The source of the job specification in the remote repository when the job is // source controlled. type JobSource struct { @@ -1656,6 +2322,16 @@ func (a JobSource) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobSource) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DirtyState": types.StringType, + "ImportFromGitBranch": types.StringType, + "JobConfigPath": types.StringType, + }, + } +} + type JobsHealthRule struct { // Specifies the health metric that is being evaluated for a particular // health rule. @@ -1688,6 +2364,16 @@ func (a JobsHealthRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobsHealthRule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Metric": types.StringType, + "Op": types.StringType, + "Value": types.Int64Type, + }, + } +} + // An optional set of health rules that can be defined for this job. type JobsHealthRules struct { Rules types.List `tfsdk:"rules" tf:"optional"` @@ -1705,6 +2391,16 @@ func (a JobsHealthRules) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a JobsHealthRules) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Rules": basetypes.ListType{ + ElemType: JobsHealthRule{}.ToAttrType(ctx), + }, + }, + } +} + type ListJobComplianceForPolicyResponse struct { // A list of jobs and their policy compliance statuses. Jobs types.List `tfsdk:"jobs" tf:"optional"` @@ -1730,6 +2426,18 @@ func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes() map[string]re } } +func (a ListJobComplianceForPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Jobs": basetypes.ListType{ + ElemType: JobCompliance{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + }, + } +} + // List job policy compliance type ListJobComplianceRequest struct { // Use this field to specify the maximum number of results to be returned by @@ -1753,6 +2461,16 @@ func (a ListJobComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListJobComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "PolicyId": types.StringType, + }, + } +} + // List jobs type ListJobsRequest struct { // Whether to include task and cluster details in the response. @@ -1781,6 +2499,18 @@ func (a ListJobsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListJobsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExpandTasks": types.BoolType, + "Limit": types.Int64Type, + "Name": types.StringType, + "Offset": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + // List of jobs was retrieved successfully. type ListJobsResponse struct { // If true, additional jobs matching the provided filter are available for @@ -1808,6 +2538,19 @@ func (a ListJobsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListJobsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "HasMore": types.BoolType, + "Jobs": basetypes.ListType{ + ElemType: BaseJob{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + }, + } +} + // List job runs type ListRunsRequest struct { // If active_only is `true`, only active runs are included in the results; @@ -1858,6 +2601,23 @@ func (a ListRunsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListRunsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActiveOnly": types.BoolType, + "CompletedOnly": types.BoolType, + "ExpandTasks": types.BoolType, + "JobId": types.Int64Type, + "Limit": types.Int64Type, + "Offset": types.Int64Type, + "PageToken": types.StringType, + "RunType": types.StringType, + "StartTimeFrom": types.Int64Type, + "StartTimeTo": types.Int64Type, + }, + } +} + // List of runs was retrieved successfully. type ListRunsResponse struct { // If true, additional runs matching the provided filter are available for @@ -1885,6 +2645,19 @@ func (a ListRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "HasMore": types.BoolType, + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + "Runs": basetypes.ListType{ + ElemType: BaseRun{}.ToAttrType(ctx), + }, + }, + } +} + type NotebookOutput struct { // The value passed to // [dbutils.notebook.exit()](/notebooks/notebook-workflows.html#notebook-workflows-exit). @@ -1907,6 +2680,15 @@ func (a NotebookOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NotebookOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Result": types.StringType, + "Truncated": types.BoolType, + }, + } +} + type NotebookTask struct { // Base parameters to be used for each run of this job. If the run is // initiated by a call to :method:jobs/run Now with parameters specified, @@ -1956,7 +2738,20 @@ func (newState *NotebookTask) SyncEffectiveFieldsDuringRead(existingState Notebo func (a NotebookTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "BaseParameters": reflect.TypeOf(""), + "BaseParameters": reflect.TypeOf(types.StringType), + } +} + +func (a NotebookTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BaseParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "NotebookPath": types.StringType, + "Source": types.StringType, + "WarehouseId": types.StringType, + }, } } @@ -1977,6 +2772,15 @@ func (a PeriodicTriggerConfiguration) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a PeriodicTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Interval": types.Int64Type, + "Unit": types.StringType, + }, + } +} + type PipelineParams struct { // If true, triggers a full refresh on the delta live table. FullRefresh types.Bool `tfsdk:"full_refresh" tf:"optional"` @@ -1992,6 +2796,14 @@ func (a PipelineParams) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PipelineParams) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullRefresh": types.BoolType, + }, + } +} + type PipelineTask struct { // If true, triggers a full refresh on the delta live table. FullRefresh types.Bool `tfsdk:"full_refresh" tf:"optional"` @@ -2009,6 +2821,15 @@ func (a PipelineTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PipelineTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FullRefresh": types.BoolType, + "PipelineId": types.StringType, + }, + } +} + type PythonWheelTask struct { // Named entry point to use, if it does not exist in the metadata of the // package it executes the function from the package directly using @@ -2033,8 +2854,23 @@ func (newState *PythonWheelTask) SyncEffectiveFieldsDuringRead(existingState Pyt func (a PythonWheelTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NamedParameters": reflect.TypeOf(""), - "Parameters": reflect.TypeOf(""), + "NamedParameters": reflect.TypeOf(types.StringType), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a PythonWheelTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EntryPoint": types.StringType, + "NamedParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "PackageName": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -2061,6 +2897,15 @@ func (a QueueDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a QueueDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Code": types.StringType, + "Message": types.StringType, + }, + } +} + type QueueSettings struct { // If true, enable queueing for the job. This is a required field. Enabled types.Bool `tfsdk:"enabled" tf:""` @@ -2076,6 +2921,14 @@ func (a QueueSettings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a QueueSettings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + }, + } +} + type RepairHistoryItem struct { // The end time of the (repaired) run. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -2085,9 +2938,9 @@ type RepairHistoryItem struct { // The start time of the (repaired) run. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` // The run IDs of the task runs that ran as part of this repair history // item. TaskRunIds types.List `tfsdk:"task_run_ids" tf:"optional"` @@ -2106,7 +2959,23 @@ func (a RepairHistoryItem) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "State": reflect.TypeOf(RunState{}), "Status": reflect.TypeOf(RunStatus{}), - "TaskRunIds": reflect.TypeOf(0), + "TaskRunIds": reflect.TypeOf(types.Int64Type), + } +} + +func (a RepairHistoryItem) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndTime": types.Int64Type, + "Id": types.Int64Type, + "StartTime": types.Int64Type, + "State": RunState{}.ToAttrType(ctx), + "Status": RunStatus{}.ToAttrType(ctx), + "TaskRunIds": basetypes.ListType{ + ElemType: types.Int64Type, + }, + "Type": types.StringType, + }, } } @@ -2156,7 +3025,7 @@ type RepairRun struct { // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.List `tfsdk:"pipeline_params" tf:"optional,object"` PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example @@ -2221,16 +3090,55 @@ func (newState *RepairRun) SyncEffectiveFieldsDuringRead(existingState RepairRun func (a RepairRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(""), - "JarParams": reflect.TypeOf(""), - "JobParameters": reflect.TypeOf(""), - "NotebookParams": reflect.TypeOf(""), + "DbtCommands": reflect.TypeOf(types.StringType), + "JarParams": reflect.TypeOf(types.StringType), + "JobParameters": reflect.TypeOf(types.StringType), + "NotebookParams": reflect.TypeOf(types.StringType), "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(""), - "PythonParams": reflect.TypeOf(""), - "RerunTasks": reflect.TypeOf(""), - "SparkSubmitParams": reflect.TypeOf(""), - "SqlParams": reflect.TypeOf(""), + "PythonNamedParams": reflect.TypeOf(types.StringType), + "PythonParams": reflect.TypeOf(types.StringType), + "RerunTasks": reflect.TypeOf(types.StringType), + "SparkSubmitParams": reflect.TypeOf(types.StringType), + "SqlParams": reflect.TypeOf(types.StringType), + } +} + +func (a RepairRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbtCommands": basetypes.ListType{ + ElemType: types.StringType, + }, + "JarParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "JobParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "LatestRepairId": types.Int64Type, + "NotebookParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PipelineParams": PipelineParams{}.ToAttrType(ctx), + "PythonNamedParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PythonParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "RerunAllFailedTasks": types.BoolType, + "RerunDependentTasks": types.BoolType, + "RerunTasks": basetypes.ListType{ + ElemType: types.StringType, + }, + "RunId": types.Int64Type, + "SparkSubmitParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "SqlParams": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2251,6 +3159,14 @@ func (a RepairRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RepairRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RepairId": types.Int64Type, + }, + } +} + type ResetJob struct { // The canonical identifier of the job to reset. This field is required. JobId types.Int64 `tfsdk:"job_id" tf:""` @@ -2259,7 +3175,7 @@ type ResetJob struct { // // Changes to the field `JobBaseSettings.timeout_seconds` are applied to // active runs. Changes to other fields are applied to future runs only. - NewSettings types.Object `tfsdk:"new_settings" tf:"object"` + NewSettings types.List `tfsdk:"new_settings" tf:"object"` } func (newState *ResetJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResetJob) { @@ -2274,6 +3190,15 @@ func (a ResetJob) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ResetJob) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.Int64Type, + "NewSettings": JobSettings{}.ToAttrType(ctx), + }, + } +} + type ResetResponse struct { } @@ -2287,6 +3212,12 @@ func (a ResetResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ResetResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ResolvedConditionTaskValues struct { Left types.String `tfsdk:"left" tf:"optional"` @@ -2303,6 +3234,15 @@ func (a ResolvedConditionTaskValues) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a ResolvedConditionTaskValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Left": types.StringType, + "Right": types.StringType, + }, + } +} + type ResolvedDbtTaskValues struct { Commands types.List `tfsdk:"commands" tf:"optional"` } @@ -2315,7 +3255,17 @@ func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringRead(existingSta func (a ResolvedDbtTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Commands": reflect.TypeOf(""), + "Commands": reflect.TypeOf(types.StringType), + } +} + +func (a ResolvedDbtTaskValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Commands": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -2331,7 +3281,17 @@ func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existi func (a ResolvedNotebookTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "BaseParameters": reflect.TypeOf(""), + "BaseParameters": reflect.TypeOf(types.StringType), + } +} + +func (a ResolvedNotebookTaskValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BaseParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2347,7 +3307,17 @@ func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringRead(existingS func (a ResolvedParamPairValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a ResolvedParamPairValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2365,8 +3335,21 @@ func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringRead(exi func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NamedParameters": reflect.TypeOf(""), - "Parameters": reflect.TypeOf(""), + "NamedParameters": reflect.TypeOf(types.StringType), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a ResolvedPythonWheelTaskValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NamedParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "Parameters": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -2384,8 +3367,21 @@ func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringRead(existing func (a ResolvedRunJobTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "JobParameters": reflect.TypeOf(""), - "Parameters": reflect.TypeOf(""), + "JobParameters": reflect.TypeOf(types.StringType), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a ResolvedRunJobTaskValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "Parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2401,30 +3397,40 @@ func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringRead(existi func (a ResolvedStringParamsValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a ResolvedStringParamsValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Parameters": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type ResolvedValues struct { - ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.List `tfsdk:"condition_task" tf:"optional,object"` - DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.List `tfsdk:"dbt_task" tf:"optional,object"` - NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` - PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.List `tfsdk:"python_wheel_task" tf:"optional,object"` - RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.List `tfsdk:"run_job_task" tf:"optional,object"` - SimulationTask types.Object `tfsdk:"simulation_task" tf:"optional,object"` + SimulationTask types.List `tfsdk:"simulation_task" tf:"optional,object"` - SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.List `tfsdk:"spark_jar_task" tf:"optional,object"` - SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.List `tfsdk:"spark_python_task" tf:"optional,object"` - SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.List `tfsdk:"spark_submit_task" tf:"optional,object"` - SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.List `tfsdk:"sql_task" tf:"optional,object"` } func (newState *ResolvedValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedValues) { @@ -2448,6 +3454,23 @@ func (a ResolvedValues) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ResolvedValues) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConditionTask": ResolvedConditionTaskValues{}.ToAttrType(ctx), + "DbtTask": ResolvedDbtTaskValues{}.ToAttrType(ctx), + "NotebookTask": ResolvedNotebookTaskValues{}.ToAttrType(ctx), + "PythonWheelTask": ResolvedPythonWheelTaskValues{}.ToAttrType(ctx), + "RunJobTask": ResolvedRunJobTaskValues{}.ToAttrType(ctx), + "SimulationTask": ResolvedParamPairValues{}.ToAttrType(ctx), + "SparkJarTask": ResolvedStringParamsValues{}.ToAttrType(ctx), + "SparkPythonTask": ResolvedStringParamsValues{}.ToAttrType(ctx), + "SparkSubmitTask": ResolvedStringParamsValues{}.ToAttrType(ctx), + "SqlTask": ResolvedParamPairValues{}.ToAttrType(ctx), + }, + } +} + // Run was retrieved successfully type Run struct { // The sequence number of this run attempt for a triggered job run. The @@ -2467,10 +3490,10 @@ type Run struct { // The cluster used for this run. If the run is specified to use a new // cluster, this field is set once the Jobs service has requested a cluster // for the run. - ClusterInstance types.Object `tfsdk:"cluster_instance" tf:"optional,object"` + ClusterInstance types.List `tfsdk:"cluster_instance" tf:"optional,object"` // A snapshot of the job’s cluster specification when this run was // created. - ClusterSpec types.Object `tfsdk:"cluster_spec" tf:"optional,object"` + ClusterSpec types.List `tfsdk:"cluster_spec" tf:"optional,object"` // The creator user name. This field won’t be included in the response if // the user has already been deleted. CreatorUserName types.String `tfsdk:"creator_user_name" tf:"optional"` @@ -2497,7 +3520,7 @@ type Run struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` + GitSource types.List `tfsdk:"git_source" tf:"optional,object"` // Only populated by for-each iterations. The parent for-each task is // located in tasks array. Iterations types.List `tfsdk:"iterations" tf:"optional"` @@ -2523,7 +3546,7 @@ type Run struct { // run_id of the original attempt; otherwise, it is the same as the run_id. OriginalAttemptRunId types.Int64 `tfsdk:"original_attempt_run_id" tf:"optional"` // The parameters used for this run. - OverridingParameters types.Object `tfsdk:"overriding_parameters" tf:"optional,object"` + OverridingParameters types.List `tfsdk:"overriding_parameters" tf:"optional,object"` // The time in milliseconds that the run has spent in the queue. QueueDuration types.Int64 `tfsdk:"queue_duration" tf:"optional"` // The repair history of the run. @@ -2548,7 +3571,7 @@ type Run struct { RunType types.String `tfsdk:"run_type" tf:"optional"` // The cron schedule that triggered this run if it was triggered by the // periodic scheduler. - Schedule types.Object `tfsdk:"schedule" tf:"optional,object"` + Schedule types.List `tfsdk:"schedule" tf:"optional,object"` // The time in milliseconds it took to set up the cluster. For runs that run // on new clusters this is the cluster creation time, for runs that run on // existing clusters this time should be very short. The duration of a task @@ -2563,9 +3586,9 @@ type Run struct { // new cluster, this is the time the cluster creation call is issued. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` // The list of tasks performed by the run. Each task has its own `run_id` // which you can use to call `JobsGetOutput` to retrieve the run resutls. Tasks types.List `tfsdk:"tasks" tf:"optional"` @@ -2581,7 +3604,7 @@ type Run struct { // arrival. * `TABLE`: Indicates a run that is triggered by a table update. Trigger types.String `tfsdk:"trigger" tf:"optional"` // Additional details about what triggered the run - TriggerInfo types.Object `tfsdk:"trigger_info" tf:"optional,object"` + TriggerInfo types.List `tfsdk:"trigger_info" tf:"optional,object"` } func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { @@ -2608,6 +3631,56 @@ func (a Run) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Run) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AttemptNumber": types.Int64Type, + "CleanupDuration": types.Int64Type, + "ClusterInstance": ClusterInstance{}.ToAttrType(ctx), + "ClusterSpec": ClusterSpec{}.ToAttrType(ctx), + "CreatorUserName": types.StringType, + "Description": types.StringType, + "EndTime": types.Int64Type, + "ExecutionDuration": types.Int64Type, + "GitSource": GitSource{}.ToAttrType(ctx), + "Iterations": basetypes.ListType{ + ElemType: RunTask{}.ToAttrType(ctx), + }, + "JobClusters": basetypes.ListType{ + ElemType: JobCluster{}.ToAttrType(ctx), + }, + "JobId": types.Int64Type, + "JobParameters": basetypes.ListType{ + ElemType: JobParameter{}.ToAttrType(ctx), + }, + "JobRunId": types.Int64Type, + "NextPageToken": types.StringType, + "NumberInJob": types.Int64Type, + "OriginalAttemptRunId": types.Int64Type, + "OverridingParameters": RunParameters{}.ToAttrType(ctx), + "QueueDuration": types.Int64Type, + "RepairHistory": basetypes.ListType{ + ElemType: RepairHistoryItem{}.ToAttrType(ctx), + }, + "RunDuration": types.Int64Type, + "RunId": types.Int64Type, + "RunName": types.StringType, + "RunPageUrl": types.StringType, + "RunType": types.StringType, + "Schedule": CronSchedule{}.ToAttrType(ctx), + "SetupDuration": types.Int64Type, + "StartTime": types.Int64Type, + "State": RunState{}.ToAttrType(ctx), + "Status": RunStatus{}.ToAttrType(ctx), + "Tasks": basetypes.ListType{ + ElemType: RunTask{}.ToAttrType(ctx), + }, + "Trigger": types.StringType, + "TriggerInfo": TriggerInfo{}.ToAttrType(ctx), + }, + } +} + type RunConditionTask struct { // The left operand of the condition task. Can be either a string value or a // job state or parameter reference. @@ -2641,6 +3714,17 @@ func (a RunConditionTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunConditionTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Left": types.StringType, + "Op": types.StringType, + "Outcome": types.StringType, + "Right": types.StringType, + }, + } +} + type RunForEachTask struct { // An optional maximum allowed number of concurrent runs of the task. Set // this value if you want to be able to execute multiple runs of the task @@ -2651,9 +3735,9 @@ type RunForEachTask struct { Inputs types.String `tfsdk:"inputs" tf:""` // Read only field. Populated for GetRun and ListRuns RPC calls and stores // the execution stats of an For each task - Stats types.Object `tfsdk:"stats" tf:"optional,object"` + Stats types.List `tfsdk:"stats" tf:"optional,object"` // Configuration for the task that will be run for each element in the array - Task types.Object `tfsdk:"task" tf:"object"` + Task types.List `tfsdk:"task" tf:"object"` } func (newState *RunForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunForEachTask) { @@ -2669,6 +3753,17 @@ func (a RunForEachTask) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RunForEachTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Concurrency": types.Int64Type, + "Inputs": types.StringType, + "Stats": ForEachStats{}.ToAttrType(ctx), + "Task": Task{}.ToAttrType(ctx), + }, + } +} + type RunJobOutput struct { // The run id of the triggered job run RunId types.Int64 `tfsdk:"run_id" tf:"optional"` @@ -2684,6 +3779,14 @@ func (a RunJobOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunJobOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + }, + } +} + type RunJobTask struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt @@ -2727,7 +3830,7 @@ type RunJobTask struct { // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.List `tfsdk:"pipeline_params" tf:"optional,object"` PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example @@ -2781,15 +3884,48 @@ func (newState *RunJobTask) SyncEffectiveFieldsDuringRead(existingState RunJobTa func (a RunJobTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(""), - "JarParams": reflect.TypeOf(""), - "JobParameters": reflect.TypeOf(""), - "NotebookParams": reflect.TypeOf(""), + "DbtCommands": reflect.TypeOf(types.StringType), + "JarParams": reflect.TypeOf(types.StringType), + "JobParameters": reflect.TypeOf(types.StringType), + "NotebookParams": reflect.TypeOf(types.StringType), "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(""), - "PythonParams": reflect.TypeOf(""), - "SparkSubmitParams": reflect.TypeOf(""), - "SqlParams": reflect.TypeOf(""), + "PythonNamedParams": reflect.TypeOf(types.StringType), + "PythonParams": reflect.TypeOf(types.StringType), + "SparkSubmitParams": reflect.TypeOf(types.StringType), + "SqlParams": reflect.TypeOf(types.StringType), + } +} + +func (a RunJobTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbtCommands": basetypes.ListType{ + ElemType: types.StringType, + }, + "JarParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "JobId": types.Int64Type, + "JobParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "NotebookParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PipelineParams": PipelineParams{}.ToAttrType(ctx), + "PythonNamedParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PythonParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "SparkSubmitParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "SqlParams": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2855,7 +3991,7 @@ type RunNow struct { // provided, all tasks in the job will be run. Only types.List `tfsdk:"only" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.List `tfsdk:"pipeline_params" tf:"optional,object"` PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example @@ -2877,7 +4013,7 @@ type RunNow struct { // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables PythonParams types.List `tfsdk:"python_params" tf:"optional"` // The queue settings of the run. - Queue types.Object `tfsdk:"queue" tf:"optional,object"` + Queue types.List `tfsdk:"queue" tf:"optional,object"` // A list of parameters for jobs with spark submit task, for example // `"spark_submit_params": ["--class", // "org.apache.spark.examples.SparkPi"]`. The parameters are passed to @@ -2911,17 +4047,55 @@ func (newState *RunNow) SyncEffectiveFieldsDuringRead(existingState RunNow) { func (a RunNow) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(""), - "JarParams": reflect.TypeOf(""), - "JobParameters": reflect.TypeOf(""), - "NotebookParams": reflect.TypeOf(""), - "Only": reflect.TypeOf(""), + "DbtCommands": reflect.TypeOf(types.StringType), + "JarParams": reflect.TypeOf(types.StringType), + "JobParameters": reflect.TypeOf(types.StringType), + "NotebookParams": reflect.TypeOf(types.StringType), + "Only": reflect.TypeOf(types.StringType), "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(""), - "PythonParams": reflect.TypeOf(""), + "PythonNamedParams": reflect.TypeOf(types.StringType), + "PythonParams": reflect.TypeOf(types.StringType), "Queue": reflect.TypeOf(QueueSettings{}), - "SparkSubmitParams": reflect.TypeOf(""), - "SqlParams": reflect.TypeOf(""), + "SparkSubmitParams": reflect.TypeOf(types.StringType), + "SqlParams": reflect.TypeOf(types.StringType), + } +} + +func (a RunNow) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbtCommands": basetypes.ListType{ + ElemType: types.StringType, + }, + "IdempotencyToken": types.StringType, + "JarParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "JobId": types.Int64Type, + "JobParameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "NotebookParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "Only": basetypes.ListType{ + ElemType: types.StringType, + }, + "PipelineParams": PipelineParams{}.ToAttrType(ctx), + "PythonNamedParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PythonParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "Queue": QueueSettings{}.ToAttrType(ctx), + "SparkSubmitParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "SqlParams": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -2944,10 +4118,19 @@ func (a RunNowResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunNowResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NumberInJob": types.Int64Type, + "RunId": types.Int64Type, + }, + } +} + // Run output was retrieved successfully. type RunOutput struct { // The output of a dbt task, if available. - DbtOutput types.Object `tfsdk:"dbt_output" tf:"optional,object"` + DbtOutput types.List `tfsdk:"dbt_output" tf:"optional,object"` // An error message indicating why a task failed or why output is not // available. The message is unstructured, and its exact format is subject // to change. @@ -2968,7 +4151,7 @@ type RunOutput struct { // Whether the logs are truncated. LogsTruncated types.Bool `tfsdk:"logs_truncated" tf:"optional"` // All details of the run except for its output. - Metadata types.Object `tfsdk:"metadata" tf:"optional,object"` + Metadata types.List `tfsdk:"metadata" tf:"optional,object"` // The output of a notebook task, if available. A notebook task that // terminates (either successfully or with a failure) without calling // `dbutils.notebook.exit()` is considered to have an empty output. This @@ -2977,11 +4160,11 @@ type RunOutput struct { // the [ClusterLogConf] field to configure log storage for the job cluster. // // [ClusterLogConf]: https://docs.databricks.com/dev-tools/api/latest/clusters.html#clusterlogconf - NotebookOutput types.Object `tfsdk:"notebook_output" tf:"optional,object"` + NotebookOutput types.List `tfsdk:"notebook_output" tf:"optional,object"` // The output of a run job task, if available - RunJobOutput types.Object `tfsdk:"run_job_output" tf:"optional,object"` + RunJobOutput types.List `tfsdk:"run_job_output" tf:"optional,object"` // The output of a SQL task, if available. - SqlOutput types.Object `tfsdk:"sql_output" tf:"optional,object"` + SqlOutput types.List `tfsdk:"sql_output" tf:"optional,object"` } func (newState *RunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunOutput) { @@ -3000,6 +4183,23 @@ func (a RunOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RunOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbtOutput": DbtOutput{}.ToAttrType(ctx), + "Error": types.StringType, + "ErrorTrace": types.StringType, + "Info": types.StringType, + "Logs": types.StringType, + "LogsTruncated": types.BoolType, + "Metadata": Run{}.ToAttrType(ctx), + "NotebookOutput": NotebookOutput{}.ToAttrType(ctx), + "RunJobOutput": RunJobOutput{}.ToAttrType(ctx), + "SqlOutput": SqlOutput{}.ToAttrType(ctx), + }, + } +} + type RunParameters struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt @@ -3039,7 +4239,7 @@ type RunParameters struct { // [dbutils.widgets.get]: https://docs.databricks.com/dev-tools/databricks-utils.html NotebookParams types.Map `tfsdk:"notebook_params" tf:"optional"` // Controls whether the pipeline should perform a full refresh - PipelineParams types.Object `tfsdk:"pipeline_params" tf:"optional,object"` + PipelineParams types.List `tfsdk:"pipeline_params" tf:"optional,object"` PythonNamedParams types.Map `tfsdk:"python_named_params" tf:"optional"` // A list of parameters for jobs with Python tasks, for example @@ -3093,14 +4293,43 @@ func (newState *RunParameters) SyncEffectiveFieldsDuringRead(existingState RunPa func (a RunParameters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(""), - "JarParams": reflect.TypeOf(""), - "NotebookParams": reflect.TypeOf(""), + "DbtCommands": reflect.TypeOf(types.StringType), + "JarParams": reflect.TypeOf(types.StringType), + "NotebookParams": reflect.TypeOf(types.StringType), "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(""), - "PythonParams": reflect.TypeOf(""), - "SparkSubmitParams": reflect.TypeOf(""), - "SqlParams": reflect.TypeOf(""), + "PythonNamedParams": reflect.TypeOf(types.StringType), + "PythonParams": reflect.TypeOf(types.StringType), + "SparkSubmitParams": reflect.TypeOf(types.StringType), + "SqlParams": reflect.TypeOf(types.StringType), + } +} + +func (a RunParameters) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbtCommands": basetypes.ListType{ + ElemType: types.StringType, + }, + "JarParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "NotebookParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PipelineParams": PipelineParams{}.ToAttrType(ctx), + "PythonNamedParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "PythonParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "SparkSubmitParams": basetypes.ListType{ + ElemType: types.StringType, + }, + "SqlParams": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -3132,15 +4361,27 @@ func (a RunState) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunState) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LifeCycleState": types.StringType, + "QueueReason": types.StringType, + "ResultState": types.StringType, + "StateMessage": types.StringType, + "UserCancelledOrTimedout": types.BoolType, + }, + } +} + // The current status of the run type RunStatus struct { // If the run was queued, details about the reason for queuing the run. - QueueDetails types.Object `tfsdk:"queue_details" tf:"optional,object"` + QueueDetails types.List `tfsdk:"queue_details" tf:"optional,object"` // The current state of the run. State types.String `tfsdk:"state" tf:"optional"` // If the run is in a TERMINATING or TERMINATED state, details about the // reason for terminating the run. - TerminationDetails types.Object `tfsdk:"termination_details" tf:"optional,object"` + TerminationDetails types.List `tfsdk:"termination_details" tf:"optional,object"` } func (newState *RunStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunStatus) { @@ -3156,6 +4397,16 @@ func (a RunStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RunStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueueDetails": QueueDetails{}.ToAttrType(ctx), + "State": types.StringType, + "TerminationDetails": TerminationDetails{}.ToAttrType(ctx), + }, + } +} + // Used when outputting a child run, in GetRun or ListRuns. type RunTask struct { // The sequence number of this run attempt for a triggered job run. The @@ -3175,16 +4426,16 @@ type RunTask struct { // The cluster used for this run. If the run is specified to use a new // cluster, this field is set once the Jobs service has requested a cluster // for the run. - ClusterInstance types.Object `tfsdk:"cluster_instance" tf:"optional,object"` + ClusterInstance types.List `tfsdk:"cluster_instance" tf:"optional,object"` // The task evaluates a condition that can be used to control the execution // of other tasks when the `condition_task` field is present. The condition // task does not require a cluster to execute and does not support retries // or notifications. - ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.List `tfsdk:"condition_task" tf:"optional,object"` // The task runs one or more dbt commands when the `dbt_task` field is // present. The dbt task requires both Databricks SQL and the ability to use // a serverless or a pro SQL warehouse. - DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.List `tfsdk:"dbt_task" tf:"optional,object"` // An optional array of objects specifying the dependency graph of the task. // All tasks specified in this field must complete successfully before // executing this task. The key is `task_key`, and the value is the name @@ -3194,7 +4445,7 @@ type RunTask struct { Description types.String `tfsdk:"description" tf:"optional"` // An optional set of email addresses notified when the task run begins or // completes. The default behavior is to not send any emails. - EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.List `tfsdk:"email_notifications" tf:"optional,object"` // The time at which this run ended in epoch milliseconds (milliseconds // since 1/1/1970 UTC). This field is set to 0 if the job is still running. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -3217,7 +4468,7 @@ type RunTask struct { ExistingClusterId types.String `tfsdk:"existing_cluster_id" tf:"optional"` // The task executes a nested task for every input provided when the // `for_each_task` field is present. - ForEachTask types.Object `tfsdk:"for_each_task" tf:"optional,object"` + ForEachTask types.List `tfsdk:"for_each_task" tf:"optional,object"` // An optional specification for a remote Git repository containing the // source code used by tasks. Version-controlled source code is supported by // notebook, dbt, Python script, and SQL File tasks. If `git_source` is set, @@ -3226,7 +4477,7 @@ type RunTask struct { // `WORKSPACE` on the task. Note: dbt and SQL File tasks support only // version-controlled sources. If dbt or SQL File tasks are used, // `git_source` must be defined on the job. - GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` + GitSource types.List `tfsdk:"git_source" tf:"optional,object"` // If job_cluster_key, this task is executed reusing the cluster specified // in `job.settings.job_clusters`. JobClusterKey types.String `tfsdk:"job_cluster_key" tf:"optional"` @@ -3237,21 +4488,21 @@ type RunTask struct { // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. - NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // task run. - NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.List `tfsdk:"notification_settings" tf:"optional,object"` // The task triggers a pipeline update when the `pipeline_task` field is // present. Only pipelines configured to use triggered more are supported. - PipelineTask types.Object `tfsdk:"pipeline_task" tf:"optional,object"` + PipelineTask types.List `tfsdk:"pipeline_task" tf:"optional,object"` // The task runs a Python wheel when the `python_wheel_task` field is // present. - PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.List `tfsdk:"python_wheel_task" tf:"optional,object"` // The time in milliseconds that the run has spent in the queue. QueueDuration types.Int64 `tfsdk:"queue_duration" tf:"optional"` // Parameter values including resolved references - ResolvedValues types.Object `tfsdk:"resolved_values" tf:"optional,object"` + ResolvedValues types.List `tfsdk:"resolved_values" tf:"optional,object"` // The time in milliseconds it took the job run and all of its repairs to // finish. RunDuration types.Int64 `tfsdk:"run_duration" tf:"optional"` @@ -3263,7 +4514,7 @@ type RunTask struct { // possible values. RunIf types.String `tfsdk:"run_if" tf:"optional"` // The task triggers another job when the `run_job_task` field is present. - RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.List `tfsdk:"run_job_task" tf:"optional,object"` RunPageUrl types.String `tfsdk:"run_page_url" tf:"optional"` // The time in milliseconds it took to set up the cluster. For runs that run @@ -3275,10 +4526,10 @@ type RunTask struct { // `run_duration` field. SetupDuration types.Int64 `tfsdk:"setup_duration" tf:"optional"` // The task runs a JAR when the `spark_jar_task` field is present. - SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.List `tfsdk:"spark_jar_task" tf:"optional,object"` // The task runs a Python file when the `spark_python_task` field is // present. - SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.List `tfsdk:"spark_python_task" tf:"optional,object"` // (Legacy) The task runs the spark-submit script when the // `spark_submit_task` field is present. This task can run only on new // clusters and is not compatible with serverless compute. @@ -3297,19 +4548,19 @@ type RunTask struct { // // The `--jars`, `--py-files`, `--files` arguments support DBFS and S3 // paths. - SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.List `tfsdk:"spark_submit_task" tf:"optional,object"` // The task runs a SQL query or file, or it refreshes a SQL alert or a // legacy SQL dashboard when the `sql_task` field is present. - SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.List `tfsdk:"sql_task" tf:"optional,object"` // The time at which this run was started in epoch milliseconds // (milliseconds since 1/1/1970 UTC). This may not be the time when the job // task starts executing, for example, if the job is scheduled to run on a // new cluster, this is the time the cluster creation call is issued. StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // Deprecated. Please use the `status` field instead. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The current status of the run - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` // A unique name for the task. This field is used to refer to this task from // other tasks. This field is required and must be unique within its parent // job. On Update or Reset, this field is used to reference the tasks to be @@ -3321,7 +4572,7 @@ type RunTask struct { // A collection of system notification IDs to notify when the run begins or // completes. The default behavior is to not send any system notifications. // Task webhooks respect the task notification settings. - WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.List `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *RunTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTask) { @@ -3357,6 +4608,56 @@ func (a RunTask) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RunTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AttemptNumber": types.Int64Type, + "CleanupDuration": types.Int64Type, + "ClusterInstance": ClusterInstance{}.ToAttrType(ctx), + "ConditionTask": RunConditionTask{}.ToAttrType(ctx), + "DbtTask": DbtTask{}.ToAttrType(ctx), + "DependsOn": basetypes.ListType{ + ElemType: TaskDependency{}.ToAttrType(ctx), + }, + "Description": types.StringType, + "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), + "EndTime": types.Int64Type, + "EnvironmentKey": types.StringType, + "ExecutionDuration": types.Int64Type, + "ExistingClusterId": types.StringType, + "ForEachTask": RunForEachTask{}.ToAttrType(ctx), + "GitSource": GitSource{}.ToAttrType(ctx), + "JobClusterKey": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: compute_tf.Library{}.ToAttrType(ctx), + }, + "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + "NotebookTask": NotebookTask{}.ToAttrType(ctx), + "NotificationSettings": TaskNotificationSettings{}.ToAttrType(ctx), + "PipelineTask": PipelineTask{}.ToAttrType(ctx), + "PythonWheelTask": PythonWheelTask{}.ToAttrType(ctx), + "QueueDuration": types.Int64Type, + "ResolvedValues": ResolvedValues{}.ToAttrType(ctx), + "RunDuration": types.Int64Type, + "RunId": types.Int64Type, + "RunIf": types.StringType, + "RunJobTask": RunJobTask{}.ToAttrType(ctx), + "RunPageUrl": types.StringType, + "SetupDuration": types.Int64Type, + "SparkJarTask": SparkJarTask{}.ToAttrType(ctx), + "SparkPythonTask": SparkPythonTask{}.ToAttrType(ctx), + "SparkSubmitTask": SparkSubmitTask{}.ToAttrType(ctx), + "SqlTask": SqlTask{}.ToAttrType(ctx), + "StartTime": types.Int64Type, + "State": RunState{}.ToAttrType(ctx), + "Status": RunStatus{}.ToAttrType(ctx), + "TaskKey": types.StringType, + "TimeoutSeconds": types.Int64Type, + "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + }, + } +} + type SparkJarTask struct { // Deprecated since 04/2016. Provide a `jar` through the `libraries` field // instead. For an example, see :method:jobs/create. @@ -3384,7 +4685,19 @@ func (newState *SparkJarTask) SyncEffectiveFieldsDuringRead(existingState SparkJ func (a SparkJarTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a SparkJarTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JarUri": types.StringType, + "MainClassName": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -3422,7 +4735,19 @@ func (newState *SparkPythonTask) SyncEffectiveFieldsDuringRead(existingState Spa func (a SparkPythonTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a SparkPythonTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Parameters": basetypes.ListType{ + ElemType: types.StringType, + }, + "PythonFile": types.StringType, + "Source": types.StringType, + }, } } @@ -3444,7 +4769,17 @@ func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringRead(existingState Spa func (a SparkSubmitTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a SparkSubmitTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Parameters": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -3478,6 +4813,20 @@ func (a SqlAlertOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SqlAlertOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertState": types.StringType, + "OutputLink": types.StringType, + "QueryText": types.StringType, + "SqlStatements": basetypes.ListType{ + ElemType: SqlStatementOutput{}.ToAttrType(ctx), + }, + "WarehouseId": types.StringType, + }, + } +} + type SqlDashboardOutput struct { // The canonical identifier of the SQL warehouse. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` @@ -3497,11 +4846,22 @@ func (a SqlDashboardOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SqlDashboardOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WarehouseId": types.StringType, + "Widgets": basetypes.ListType{ + ElemType: SqlDashboardWidgetOutput{}.ToAttrType(ctx), + }, + }, + } +} + type SqlDashboardWidgetOutput struct { // Time (in epoch milliseconds) when execution of the SQL widget ends. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` // The information about the error when execution fails. - Error types.Object `tfsdk:"error" tf:"optional,object"` + Error types.List `tfsdk:"error" tf:"optional,object"` // The link to find the output results. OutputLink types.String `tfsdk:"output_link" tf:"optional"` // Time (in epoch milliseconds) when execution of the SQL widget starts. @@ -3526,13 +4886,27 @@ func (a SqlDashboardWidgetOutput) GetComplexFieldTypes() map[string]reflect.Type } } +func (a SqlDashboardWidgetOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndTime": types.Int64Type, + "Error": SqlOutputError{}.ToAttrType(ctx), + "OutputLink": types.StringType, + "StartTime": types.Int64Type, + "Status": types.StringType, + "WidgetId": types.StringType, + "WidgetTitle": types.StringType, + }, + } +} + type SqlOutput struct { // The output of a SQL alert task, if available. - AlertOutput types.Object `tfsdk:"alert_output" tf:"optional,object"` + AlertOutput types.List `tfsdk:"alert_output" tf:"optional,object"` // The output of a SQL dashboard task, if available. - DashboardOutput types.Object `tfsdk:"dashboard_output" tf:"optional,object"` + DashboardOutput types.List `tfsdk:"dashboard_output" tf:"optional,object"` // The output of a SQL query task, if available. - QueryOutput types.Object `tfsdk:"query_output" tf:"optional,object"` + QueryOutput types.List `tfsdk:"query_output" tf:"optional,object"` } func (newState *SqlOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlOutput) { @@ -3549,6 +4923,16 @@ func (a SqlOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SqlOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertOutput": SqlAlertOutput{}.ToAttrType(ctx), + "DashboardOutput": SqlDashboardOutput{}.ToAttrType(ctx), + "QueryOutput": SqlQueryOutput{}.ToAttrType(ctx), + }, + } +} + type SqlOutputError struct { // The error message when execution fails. Message types.String `tfsdk:"message" tf:"optional"` @@ -3564,6 +4948,14 @@ func (a SqlOutputError) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SqlOutputError) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + }, + } +} + type SqlQueryOutput struct { EndpointId types.String `tfsdk:"endpoint_id" tf:"optional"` // The link to find the output results. @@ -3589,6 +4981,20 @@ func (a SqlQueryOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SqlQueryOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointId": types.StringType, + "OutputLink": types.StringType, + "QueryText": types.StringType, + "SqlStatements": basetypes.ListType{ + ElemType: SqlStatementOutput{}.ToAttrType(ctx), + }, + "WarehouseId": types.StringType, + }, + } +} + type SqlStatementOutput struct { // A key that can be used to look up query details. LookupKey types.String `tfsdk:"lookup_key" tf:"optional"` @@ -3604,19 +5010,27 @@ func (a SqlStatementOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SqlStatementOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "LookupKey": types.StringType, + }, + } +} + type SqlTask struct { // If alert, indicates that this job must refresh a SQL alert. - Alert types.Object `tfsdk:"alert" tf:"optional,object"` + Alert types.List `tfsdk:"alert" tf:"optional,object"` // If dashboard, indicates that this job must refresh a SQL dashboard. - Dashboard types.Object `tfsdk:"dashboard" tf:"optional,object"` + Dashboard types.List `tfsdk:"dashboard" tf:"optional,object"` // If file, indicates that this job runs a SQL file in a remote Git // repository. - File types.Object `tfsdk:"file" tf:"optional,object"` + File types.List `tfsdk:"file" tf:"optional,object"` // Parameters to be used for each run of this job. The SQL alert task does // not support custom parameters. Parameters types.Map `tfsdk:"parameters" tf:"optional"` // If query, indicates that this job must execute a SQL query. - Query types.Object `tfsdk:"query" tf:"optional,object"` + Query types.List `tfsdk:"query" tf:"optional,object"` // The canonical identifier of the SQL warehouse. Recommended to use with // serverless or pro SQL warehouses. Classic SQL warehouses are only // supported for SQL alert, dashboard and query tasks and are limited to @@ -3635,11 +5049,26 @@ func (a SqlTask) GetComplexFieldTypes() map[string]reflect.Type { "Alert": reflect.TypeOf(SqlTaskAlert{}), "Dashboard": reflect.TypeOf(SqlTaskDashboard{}), "File": reflect.TypeOf(SqlTaskFile{}), - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), "Query": reflect.TypeOf(SqlTaskQuery{}), } } +func (a SqlTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alert": SqlTaskAlert{}.ToAttrType(ctx), + "Dashboard": SqlTaskDashboard{}.ToAttrType(ctx), + "File": SqlTaskFile{}.ToAttrType(ctx), + "Parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "Query": SqlTaskQuery{}.ToAttrType(ctx), + "WarehouseId": types.StringType, + }, + } +} + type SqlTaskAlert struct { // The canonical identifier of the SQL alert. AlertId types.String `tfsdk:"alert_id" tf:""` @@ -3661,6 +5090,18 @@ func (a SqlTaskAlert) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SqlTaskAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertId": types.StringType, + "PauseSubscriptions": types.BoolType, + "Subscriptions": basetypes.ListType{ + ElemType: SqlTaskSubscription{}.ToAttrType(ctx), + }, + }, + } +} + type SqlTaskDashboard struct { // Subject of the email sent to subscribers of this task. CustomSubject types.String `tfsdk:"custom_subject" tf:"optional"` @@ -3685,6 +5126,19 @@ func (a SqlTaskDashboard) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SqlTaskDashboard) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CustomSubject": types.StringType, + "DashboardId": types.StringType, + "PauseSubscriptions": types.BoolType, + "Subscriptions": basetypes.ListType{ + ElemType: SqlTaskSubscription{}.ToAttrType(ctx), + }, + }, + } +} + type SqlTaskFile struct { // Path of the SQL file. Must be relative if the source is a remote Git // repository and absolute for workspace paths. @@ -3710,6 +5164,15 @@ func (a SqlTaskFile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SqlTaskFile) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + "Source": types.StringType, + }, + } +} + type SqlTaskQuery struct { // The canonical identifier of the SQL query. QueryId types.String `tfsdk:"query_id" tf:""` @@ -3725,6 +5188,14 @@ func (a SqlTaskQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SqlTaskQuery) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueryId": types.StringType, + }, + } +} + type SqlTaskSubscription struct { // The canonical identifier of the destination to receive email // notification. This parameter is mutually exclusive with user_name. You @@ -3747,6 +5218,15 @@ func (a SqlTaskSubscription) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SqlTaskSubscription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationId": types.StringType, + "UserName": types.StringType, + }, + } +} + type SubmitRun struct { // List of permissions to set on the job. AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -3755,7 +5235,7 @@ type SubmitRun struct { BudgetPolicyId types.String `tfsdk:"budget_policy_id" tf:"optional"` // An optional set of email addresses notified when the run begins or // completes. - EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.List `tfsdk:"email_notifications" tf:"optional,object"` // A list of task execution environment specifications that can be // referenced by tasks of this run. Environments types.List `tfsdk:"environments" tf:"optional"` @@ -3769,9 +5249,9 @@ type SubmitRun struct { // // Note: dbt and SQL File tasks support only version-controlled sources. If // dbt or SQL File tasks are used, `git_source` must be defined on the job. - GitSource types.Object `tfsdk:"git_source" tf:"optional,object"` + GitSource types.List `tfsdk:"git_source" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // An optional token that can be used to guarantee the idempotency of job // run requests. If a run with the provided token already exists, the // request does not create a new run but returns the ID of the existing run @@ -3791,12 +5271,12 @@ type SubmitRun struct { // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // run. - NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.List `tfsdk:"notification_settings" tf:"optional,object"` // The queue settings of the one-time run. - Queue types.Object `tfsdk:"queue" tf:"optional,object"` + Queue types.List `tfsdk:"queue" tf:"optional,object"` // Specifies the user or service principal that the job runs as. If not // specified, the job runs as the user who submits the request. - RunAs types.Object `tfsdk:"run_as" tf:"optional,object"` + RunAs types.List `tfsdk:"run_as" tf:"optional,object"` // An optional name for the run. The default value is `Untitled`. RunName types.String `tfsdk:"run_name" tf:"optional"` @@ -3806,7 +5286,7 @@ type SubmitRun struct { TimeoutSeconds types.Int64 `tfsdk:"timeout_seconds" tf:"optional"` // A collection of system notification IDs to notify when the run begins or // completes. - WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.List `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *SubmitRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitRun) { @@ -3830,6 +5310,33 @@ func (a SubmitRun) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SubmitRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: JobAccessControlRequest{}.ToAttrType(ctx), + }, + "BudgetPolicyId": types.StringType, + "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), + "Environments": basetypes.ListType{ + ElemType: JobEnvironment{}.ToAttrType(ctx), + }, + "GitSource": GitSource{}.ToAttrType(ctx), + "Health": JobsHealthRules{}.ToAttrType(ctx), + "IdempotencyToken": types.StringType, + "NotificationSettings": JobNotificationSettings{}.ToAttrType(ctx), + "Queue": QueueSettings{}.ToAttrType(ctx), + "RunAs": JobRunAs{}.ToAttrType(ctx), + "RunName": types.StringType, + "Tasks": basetypes.ListType{ + ElemType: SubmitTask{}.ToAttrType(ctx), + }, + "TimeoutSeconds": types.Int64Type, + "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + }, + } +} + // Run was created and started successfully. type SubmitRunResponse struct { // The canonical identifier for the newly submitted run. @@ -3846,16 +5353,24 @@ func (a SubmitRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SubmitRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + }, + } +} + type SubmitTask struct { // The task evaluates a condition that can be used to control the execution // of other tasks when the `condition_task` field is present. The condition // task does not require a cluster to execute and does not support retries // or notifications. - ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.List `tfsdk:"condition_task" tf:"optional,object"` // The task runs one or more dbt commands when the `dbt_task` field is // present. The dbt task requires both Databricks SQL and the ability to use // a serverless or a pro SQL warehouse. - DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.List `tfsdk:"dbt_task" tf:"optional,object"` // An optional array of objects specifying the dependency graph of the task. // All tasks specified in this field must complete successfully before // executing this task. The key is `task_key`, and the value is the name @@ -3865,7 +5380,7 @@ type SubmitTask struct { Description types.String `tfsdk:"description" tf:"optional"` // An optional set of email addresses notified when the task run begins or // completes. The default behavior is to not send any emails. - EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.List `tfsdk:"email_notifications" tf:"optional,object"` // The key that references an environment spec in a job. This field is // required for Python script, Python wheel and dbt tasks when using // serverless compute. @@ -3877,9 +5392,9 @@ type SubmitTask struct { ExistingClusterId types.String `tfsdk:"existing_cluster_id" tf:"optional"` // The task executes a nested task for every input provided when the // `for_each_task` field is present. - ForEachTask types.Object `tfsdk:"for_each_task" tf:"optional,object"` + ForEachTask types.List `tfsdk:"for_each_task" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // An optional list of libraries to be installed on the cluster. The default // value is an empty list. Libraries types.List `tfsdk:"library" tf:"optional"` @@ -3887,29 +5402,29 @@ type SubmitTask struct { // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. - NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // task run. - NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.List `tfsdk:"notification_settings" tf:"optional,object"` // The task triggers a pipeline update when the `pipeline_task` field is // present. Only pipelines configured to use triggered more are supported. - PipelineTask types.Object `tfsdk:"pipeline_task" tf:"optional,object"` + PipelineTask types.List `tfsdk:"pipeline_task" tf:"optional,object"` // The task runs a Python wheel when the `python_wheel_task` field is // present. - PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.List `tfsdk:"python_wheel_task" tf:"optional,object"` // An optional value indicating the condition that determines whether the // task should be run once its dependencies have been completed. When // omitted, defaults to `ALL_SUCCESS`. See :method:jobs/create for a list of // possible values. RunIf types.String `tfsdk:"run_if" tf:"optional"` // The task triggers another job when the `run_job_task` field is present. - RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.List `tfsdk:"run_job_task" tf:"optional,object"` // The task runs a JAR when the `spark_jar_task` field is present. - SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.List `tfsdk:"spark_jar_task" tf:"optional,object"` // The task runs a Python file when the `spark_python_task` field is // present. - SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.List `tfsdk:"spark_python_task" tf:"optional,object"` // (Legacy) The task runs the spark-submit script when the // `spark_submit_task` field is present. This task can run only on new // clusters and is not compatible with serverless compute. @@ -3928,10 +5443,10 @@ type SubmitTask struct { // // The `--jars`, `--py-files`, `--files` arguments support DBFS and S3 // paths. - SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.List `tfsdk:"spark_submit_task" tf:"optional,object"` // The task runs a SQL query or file, or it refreshes a SQL alert or a // legacy SQL dashboard when the `sql_task` field is present. - SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.List `tfsdk:"sql_task" tf:"optional,object"` // A unique name for the task. This field is used to refer to this task from // other tasks. This field is required and must be unique within its parent // job. On Update or Reset, this field is used to reference the tasks to be @@ -3943,7 +5458,7 @@ type SubmitTask struct { // A collection of system notification IDs to notify when the run begins or // completes. The default behavior is to not send any system notifications. // Task webhooks respect the task notification settings. - WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.List `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *SubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitTask) { @@ -3975,6 +5490,41 @@ func (a SubmitTask) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SubmitTask) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConditionTask": ConditionTask{}.ToAttrType(ctx), + "DbtTask": DbtTask{}.ToAttrType(ctx), + "DependsOn": basetypes.ListType{ + ElemType: TaskDependency{}.ToAttrType(ctx), + }, + "Description": types.StringType, + "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), + "EnvironmentKey": types.StringType, + "ExistingClusterId": types.StringType, + "ForEachTask": ForEachTask{}.ToAttrType(ctx), + "Health": JobsHealthRules{}.ToAttrType(ctx), + "Libraries": basetypes.ListType{ + ElemType: compute_tf.Library{}.ToAttrType(ctx), + }, + "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + "NotebookTask": NotebookTask{}.ToAttrType(ctx), + "NotificationSettings": TaskNotificationSettings{}.ToAttrType(ctx), + "PipelineTask": PipelineTask{}.ToAttrType(ctx), + "PythonWheelTask": PythonWheelTask{}.ToAttrType(ctx), + "RunIf": types.StringType, + "RunJobTask": RunJobTask{}.ToAttrType(ctx), + "SparkJarTask": SparkJarTask{}.ToAttrType(ctx), + "SparkPythonTask": SparkPythonTask{}.ToAttrType(ctx), + "SparkSubmitTask": SparkSubmitTask{}.ToAttrType(ctx), + "SqlTask": SqlTask{}.ToAttrType(ctx), + "TaskKey": types.StringType, + "TimeoutSeconds": types.Int64Type, + "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + }, + } +} + type TableUpdateTriggerConfiguration struct { // The table(s) condition based on which to trigger a job run. Condition types.String `tfsdk:"condition" tf:"optional"` @@ -4000,7 +5550,20 @@ func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringRead(e func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TableNames": reflect.TypeOf(""), + "TableNames": reflect.TypeOf(types.StringType), + } +} + +func (a TableUpdateTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Condition": types.StringType, + "MinTimeBetweenTriggersSeconds": types.Int64Type, + "TableNames": basetypes.ListType{ + ElemType: types.StringType, + }, + "WaitAfterLastChangeSeconds": types.Int64Type, + }, } } @@ -4009,11 +5572,11 @@ type Task struct { // of other tasks when the `condition_task` field is present. The condition // task does not require a cluster to execute and does not support retries // or notifications. - ConditionTask types.Object `tfsdk:"condition_task" tf:"optional,object"` + ConditionTask types.List `tfsdk:"condition_task" tf:"optional,object"` // The task runs one or more dbt commands when the `dbt_task` field is // present. The dbt task requires both Databricks SQL and the ability to use // a serverless or a pro SQL warehouse. - DbtTask types.Object `tfsdk:"dbt_task" tf:"optional,object"` + DbtTask types.List `tfsdk:"dbt_task" tf:"optional,object"` // An optional array of objects specifying the dependency graph of the task. // All tasks specified in this field must complete before executing this // task. The task will run only if the `run_if` condition is true. The key @@ -4026,7 +5589,7 @@ type Task struct { // An optional set of email addresses that is notified when runs of this // task begin or complete as well as when this task is deleted. The default // behavior is to not send any emails. - EmailNotifications types.Object `tfsdk:"email_notifications" tf:"optional,object"` + EmailNotifications types.List `tfsdk:"email_notifications" tf:"optional,object"` // The key that references an environment spec in a job. This field is // required for Python script, Python wheel and dbt tasks when using // serverless compute. @@ -4038,9 +5601,9 @@ type Task struct { ExistingClusterId types.String `tfsdk:"existing_cluster_id" tf:"optional"` // The task executes a nested task for every input provided when the // `for_each_task` field is present. - ForEachTask types.Object `tfsdk:"for_each_task" tf:"optional,object"` + ForEachTask types.List `tfsdk:"for_each_task" tf:"optional,object"` // An optional set of health rules that can be defined for this job. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // If job_cluster_key, this task is executed reusing the cluster specified // in `job.settings.job_clusters`. JobClusterKey types.String `tfsdk:"job_cluster_key" tf:"optional"` @@ -4060,17 +5623,17 @@ type Task struct { // run. NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. - NotebookTask types.Object `tfsdk:"notebook_task" tf:"optional,object"` + NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications // to each of the `email_notifications` and `webhook_notifications` for this // task. - NotificationSettings types.Object `tfsdk:"notification_settings" tf:"optional,object"` + NotificationSettings types.List `tfsdk:"notification_settings" tf:"optional,object"` // The task triggers a pipeline update when the `pipeline_task` field is // present. Only pipelines configured to use triggered more are supported. - PipelineTask types.Object `tfsdk:"pipeline_task" tf:"optional,object"` + PipelineTask types.List `tfsdk:"pipeline_task" tf:"optional,object"` // The task runs a Python wheel when the `python_wheel_task` field is // present. - PythonWheelTask types.Object `tfsdk:"python_wheel_task" tf:"optional,object"` + PythonWheelTask types.List `tfsdk:"python_wheel_task" tf:"optional,object"` // An optional policy to specify whether to retry a job when it times out. // The default behavior is to not retry on timeout. RetryOnTimeout types.Bool `tfsdk:"retry_on_timeout" tf:"optional"` @@ -4085,12 +5648,12 @@ type Task struct { // dependencies have failed RunIf types.String `tfsdk:"run_if" tf:"optional"` // The task triggers another job when the `run_job_task` field is present. - RunJobTask types.Object `tfsdk:"run_job_task" tf:"optional,object"` + RunJobTask types.List `tfsdk:"run_job_task" tf:"optional,object"` // The task runs a JAR when the `spark_jar_task` field is present. - SparkJarTask types.Object `tfsdk:"spark_jar_task" tf:"optional,object"` + SparkJarTask types.List `tfsdk:"spark_jar_task" tf:"optional,object"` // The task runs a Python file when the `spark_python_task` field is // present. - SparkPythonTask types.Object `tfsdk:"spark_python_task" tf:"optional,object"` + SparkPythonTask types.List `tfsdk:"spark_python_task" tf:"optional,object"` // (Legacy) The task runs the spark-submit script when the // `spark_submit_task` field is present. This task can run only on new // clusters and is not compatible with serverless compute. @@ -4109,10 +5672,10 @@ type Task struct { // // The `--jars`, `--py-files`, `--files` arguments support DBFS and S3 // paths. - SparkSubmitTask types.Object `tfsdk:"spark_submit_task" tf:"optional,object"` + SparkSubmitTask types.List `tfsdk:"spark_submit_task" tf:"optional,object"` // The task runs a SQL query or file, or it refreshes a SQL alert or a // legacy SQL dashboard when the `sql_task` field is present. - SqlTask types.Object `tfsdk:"sql_task" tf:"optional,object"` + SqlTask types.List `tfsdk:"sql_task" tf:"optional,object"` // A unique name for the task. This field is used to refer to this task from // other tasks. This field is required and must be unique within its parent // job. On Update or Reset, this field is used to reference the tasks to be @@ -4124,7 +5687,7 @@ type Task struct { // A collection of system notification IDs to notify when runs of this task // begin or complete. The default behavior is to not send any system // notifications. - WebhookNotifications types.Object `tfsdk:"webhook_notifications" tf:"optional,object"` + WebhookNotifications types.List `tfsdk:"webhook_notifications" tf:"optional,object"` } func (newState *Task) SyncEffectiveFieldsDuringCreateOrUpdate(plan Task) { @@ -4156,6 +5719,46 @@ func (a Task) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Task) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConditionTask": ConditionTask{}.ToAttrType(ctx), + "DbtTask": DbtTask{}.ToAttrType(ctx), + "DependsOn": basetypes.ListType{ + ElemType: TaskDependency{}.ToAttrType(ctx), + }, + "Description": types.StringType, + "DisableAutoOptimization": types.BoolType, + "EmailNotifications": TaskEmailNotifications{}.ToAttrType(ctx), + "EnvironmentKey": types.StringType, + "ExistingClusterId": types.StringType, + "ForEachTask": ForEachTask{}.ToAttrType(ctx), + "Health": JobsHealthRules{}.ToAttrType(ctx), + "JobClusterKey": types.StringType, + "Libraries": basetypes.ListType{ + ElemType: compute_tf.Library{}.ToAttrType(ctx), + }, + "MaxRetries": types.Int64Type, + "MinRetryIntervalMillis": types.Int64Type, + "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + "NotebookTask": NotebookTask{}.ToAttrType(ctx), + "NotificationSettings": TaskNotificationSettings{}.ToAttrType(ctx), + "PipelineTask": PipelineTask{}.ToAttrType(ctx), + "PythonWheelTask": PythonWheelTask{}.ToAttrType(ctx), + "RetryOnTimeout": types.BoolType, + "RunIf": types.StringType, + "RunJobTask": RunJobTask{}.ToAttrType(ctx), + "SparkJarTask": SparkJarTask{}.ToAttrType(ctx), + "SparkPythonTask": SparkPythonTask{}.ToAttrType(ctx), + "SparkSubmitTask": SparkSubmitTask{}.ToAttrType(ctx), + "SqlTask": SqlTask{}.ToAttrType(ctx), + "TaskKey": types.StringType, + "TimeoutSeconds": types.Int64Type, + "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + }, + } +} + type TaskDependency struct { // Can only be specified on condition task dependencies. The outcome of the // dependent task that must be met for this task to run. @@ -4174,6 +5777,15 @@ func (a TaskDependency) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TaskDependency) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Outcome": types.StringType, + "TaskKey": types.StringType, + }, + } +} + type TaskEmailNotifications struct { // If true, do not send email to recipients specified in `on_failure` if the // run is skipped. This field is `deprecated`. Please use the @@ -4218,11 +5830,34 @@ func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringRead(existingSt func (a TaskEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OnDurationWarningThresholdExceeded": reflect.TypeOf(""), - "OnFailure": reflect.TypeOf(""), - "OnStart": reflect.TypeOf(""), - "OnStreamingBacklogExceeded": reflect.TypeOf(""), - "OnSuccess": reflect.TypeOf(""), + "OnDurationWarningThresholdExceeded": reflect.TypeOf(types.StringType), + "OnFailure": reflect.TypeOf(types.StringType), + "OnStart": reflect.TypeOf(types.StringType), + "OnStreamingBacklogExceeded": reflect.TypeOf(types.StringType), + "OnSuccess": reflect.TypeOf(types.StringType), + } +} + +func (a TaskEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NoAlertForSkippedRuns": types.BoolType, + "OnDurationWarningThresholdExceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnFailure": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnStart": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnStreamingBacklogExceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "OnSuccess": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -4249,6 +5884,16 @@ func (a TaskNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a TaskNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertOnLastAttempt": types.BoolType, + "NoAlertForCanceledRuns": types.BoolType, + "NoAlertForSkippedRuns": types.BoolType, + }, + } +} + type TerminationDetails struct { // The code indicates why the run was terminated. Additional codes might be // introduced in future releases. * `SUCCESS`: The run was completed @@ -4320,6 +5965,16 @@ func (a TerminationDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TerminationDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Code": types.StringType, + "Message": types.StringType, + "Type": types.StringType, + }, + } +} + // Additional details about what triggered the run type TriggerInfo struct { // The run id of the Run Job task run @@ -4336,17 +5991,25 @@ func (a TriggerInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TriggerInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.Int64Type, + }, + } +} + type TriggerSettings struct { // File arrival trigger settings. - FileArrival types.Object `tfsdk:"file_arrival" tf:"optional,object"` + FileArrival types.List `tfsdk:"file_arrival" tf:"optional,object"` // Whether this trigger is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` // Periodic trigger settings. - Periodic types.Object `tfsdk:"periodic" tf:"optional,object"` + Periodic types.List `tfsdk:"periodic" tf:"optional,object"` // Old table trigger settings name. Deprecated in favor of `table_update`. - Table types.Object `tfsdk:"table" tf:"optional,object"` + Table types.List `tfsdk:"table" tf:"optional,object"` - TableUpdate types.Object `tfsdk:"table_update" tf:"optional,object"` + TableUpdate types.List `tfsdk:"table_update" tf:"optional,object"` } func (newState *TriggerSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan TriggerSettings) { @@ -4364,6 +6027,18 @@ func (a TriggerSettings) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TriggerSettings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileArrival": FileArrivalTriggerConfiguration{}.ToAttrType(ctx), + "PauseStatus": types.StringType, + "Periodic": PeriodicTriggerConfiguration{}.ToAttrType(ctx), + "Table": TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + "TableUpdate": TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + }, + } +} + type UpdateJob struct { // Remove top-level fields in the job settings. Removing nested fields is // not supported, except for tasks and job clusters (`tasks/task_1`). This @@ -4382,7 +6057,7 @@ type UpdateJob struct { // // Changes to the field `JobSettings.timeout_seconds` are applied to active // runs. Changes to other fields are applied to future runs only. - NewSettings types.Object `tfsdk:"new_settings" tf:"optional,object"` + NewSettings types.List `tfsdk:"new_settings" tf:"optional,object"` } func (newState *UpdateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateJob) { @@ -4393,11 +6068,23 @@ func (newState *UpdateJob) SyncEffectiveFieldsDuringRead(existingState UpdateJob func (a UpdateJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FieldsToRemove": reflect.TypeOf(""), + "FieldsToRemove": reflect.TypeOf(types.StringType), "NewSettings": reflect.TypeOf(JobSettings{}), } } +func (a UpdateJob) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FieldsToRemove": basetypes.ListType{ + ElemType: types.StringType, + }, + "JobId": types.Int64Type, + "NewSettings": JobSettings{}.ToAttrType(ctx), + }, + } +} + type UpdateResponse struct { } @@ -4411,6 +6098,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ViewItem struct { // Content of the view. Content types.String `tfsdk:"content" tf:"optional"` @@ -4432,6 +6125,16 @@ func (a ViewItem) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ViewItem) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "Name": types.StringType, + "Type": types.StringType, + }, + } +} + type Webhook struct { Id types.String `tfsdk:"id" tf:""` } @@ -4446,6 +6149,14 @@ func (a Webhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Webhook) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type WebhookNotifications struct { // An optional list of system notification IDs to call when the duration of // a run exceeds the threshold specified for the `RUN_DURATION_SECONDS` @@ -4488,3 +6199,25 @@ func (a WebhookNotifications) GetComplexFieldTypes() map[string]reflect.Type { "OnSuccess": reflect.TypeOf(Webhook{}), } } + +func (a WebhookNotifications) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "OnDurationWarningThresholdExceeded": basetypes.ListType{ + ElemType: Webhook{}.ToAttrType(ctx), + }, + "OnFailure": basetypes.ListType{ + ElemType: Webhook{}.ToAttrType(ctx), + }, + "OnStart": basetypes.ListType{ + ElemType: Webhook{}.ToAttrType(ctx), + }, + "OnStreamingBacklogExceeded": basetypes.ListType{ + ElemType: Webhook{}.ToAttrType(ctx), + }, + "OnSuccess": basetypes.ListType{ + ElemType: Webhook{}.ToAttrType(ctx), + }, + }, + } +} diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 621f04aa09..67577e4a9e 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package marketplace_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AddExchangeForListingRequest struct { @@ -32,8 +35,17 @@ func (a AddExchangeForListingRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a AddExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeId": types.StringType, + "ListingId": types.StringType, + }, + } +} + type AddExchangeForListingResponse struct { - ExchangeForListing types.Object `tfsdk:"exchange_for_listing" tf:"optional,object"` + ExchangeForListing types.List `tfsdk:"exchange_for_listing" tf:"optional,object"` } func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddExchangeForListingResponse) { @@ -48,6 +60,14 @@ func (a AddExchangeForListingResponse) GetComplexFieldTypes() map[string]reflect } } +func (a AddExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeForListing": ExchangeListing{}.ToAttrType(ctx), + }, + } +} + // Get one batch of listings. One may specify up to 50 IDs per request. type BatchGetListingsRequest struct { Ids types.List `tfsdk:"-"` @@ -61,7 +81,17 @@ func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringRead(existingS func (a BatchGetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Ids": reflect.TypeOf(""), + "Ids": reflect.TypeOf(types.StringType), + } +} + +func (a BatchGetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Ids": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -81,6 +111,16 @@ func (a BatchGetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a BatchGetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listings": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, + }, + } +} + // Get one batch of providers. One may specify up to 50 IDs per request. type BatchGetProvidersRequest struct { Ids types.List `tfsdk:"-"` @@ -94,7 +134,17 @@ func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringRead(existing func (a BatchGetProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Ids": reflect.TypeOf(""), + "Ids": reflect.TypeOf(types.StringType), + } +} + +func (a BatchGetProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Ids": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -114,6 +164,16 @@ func (a BatchGetProvidersResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a BatchGetProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Providers": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ConsumerTerms struct { Version types.String `tfsdk:"version" tf:""` } @@ -128,6 +188,14 @@ func (a ConsumerTerms) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ConsumerTerms) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Version": types.StringType, + }, + } +} + // contact info for the consumer requesting data or performing a listing // installation type ContactInfo struct { @@ -150,8 +218,19 @@ func (a ContactInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ContactInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Company": types.StringType, + "Email": types.StringType, + "FirstName": types.StringType, + "LastName": types.StringType, + }, + } +} + type CreateExchangeFilterRequest struct { - Filter types.Object `tfsdk:"filter" tf:"object"` + Filter types.List `tfsdk:"filter" tf:"object"` } func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateExchangeFilterRequest) { @@ -166,6 +245,14 @@ func (a CreateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.T } } +func (a CreateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": ExchangeFilter{}.ToAttrType(ctx), + }, + } +} + type CreateExchangeFilterResponse struct { FilterId types.String `tfsdk:"filter_id" tf:"optional"` } @@ -180,8 +267,16 @@ func (a CreateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a CreateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FilterId": types.StringType, + }, + } +} + type CreateExchangeRequest struct { - Exchange types.Object `tfsdk:"exchange" tf:"object"` + Exchange types.List `tfsdk:"exchange" tf:"object"` } func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateExchangeRequest) { @@ -196,6 +291,14 @@ func (a CreateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exchange": Exchange{}.ToAttrType(ctx), + }, + } +} + type CreateExchangeResponse struct { ExchangeId types.String `tfsdk:"exchange_id" tf:"optional"` } @@ -210,10 +313,18 @@ func (a CreateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeId": types.StringType, + }, + } +} + type CreateFileRequest struct { DisplayName types.String `tfsdk:"display_name" tf:"optional"` - FileParent types.Object `tfsdk:"file_parent" tf:"object"` + FileParent types.List `tfsdk:"file_parent" tf:"object"` MarketplaceFileType types.String `tfsdk:"marketplace_file_type" tf:""` @@ -232,8 +343,19 @@ func (a CreateFileRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateFileRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "FileParent": FileParent{}.ToAttrType(ctx), + "MarketplaceFileType": types.StringType, + "MimeType": types.StringType, + }, + } +} + type CreateFileResponse struct { - FileInfo types.Object `tfsdk:"file_info" tf:"optional,object"` + FileInfo types.List `tfsdk:"file_info" tf:"optional,object"` // Pre-signed POST URL to blob storage UploadUrl types.String `tfsdk:"upload_url" tf:"optional"` } @@ -250,8 +372,17 @@ func (a CreateFileResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateFileResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileInfo": FileInfo{}.ToAttrType(ctx), + "UploadUrl": types.StringType, + }, + } +} + type CreateInstallationRequest struct { - AcceptedConsumerTerms types.Object `tfsdk:"accepted_consumer_terms" tf:"optional,object"` + AcceptedConsumerTerms types.List `tfsdk:"accepted_consumer_terms" tf:"optional,object"` CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -259,7 +390,7 @@ type CreateInstallationRequest struct { RecipientType types.String `tfsdk:"recipient_type" tf:"optional"` // for git repo installations - RepoDetail types.Object `tfsdk:"repo_detail" tf:"optional,object"` + RepoDetail types.List `tfsdk:"repo_detail" tf:"optional,object"` ShareName types.String `tfsdk:"share_name" tf:"optional"` } @@ -277,8 +408,21 @@ func (a CreateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a CreateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AcceptedConsumerTerms": ConsumerTerms{}.ToAttrType(ctx), + "CatalogName": types.StringType, + "ListingId": types.StringType, + "RecipientType": types.StringType, + "RepoDetail": RepoInstallation{}.ToAttrType(ctx), + "ShareName": types.StringType, + }, + } +} + type CreateListingRequest struct { - Listing types.Object `tfsdk:"listing" tf:"object"` + Listing types.List `tfsdk:"listing" tf:"object"` } func (newState *CreateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateListingRequest) { @@ -293,6 +437,14 @@ func (a CreateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listing": Listing{}.ToAttrType(ctx), + }, + } +} + type CreateListingResponse struct { ListingId types.String `tfsdk:"listing_id" tf:"optional"` } @@ -307,9 +459,17 @@ func (a CreateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + }, + } +} + // Data request messages also creates a lead (maybe) type CreatePersonalizationRequest struct { - AcceptedConsumerTerms types.Object `tfsdk:"accepted_consumer_terms" tf:"object"` + AcceptedConsumerTerms types.List `tfsdk:"accepted_consumer_terms" tf:"object"` Comment types.String `tfsdk:"comment" tf:"optional"` @@ -340,6 +500,22 @@ func (a CreatePersonalizationRequest) GetComplexFieldTypes() map[string]reflect. } } +func (a CreatePersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AcceptedConsumerTerms": ConsumerTerms{}.ToAttrType(ctx), + "Comment": types.StringType, + "Company": types.StringType, + "FirstName": types.StringType, + "IntendedUse": types.StringType, + "IsFromLighthouse": types.BoolType, + "LastName": types.StringType, + "ListingId": types.StringType, + "RecipientType": types.StringType, + }, + } +} + type CreatePersonalizationRequestResponse struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -354,8 +530,16 @@ func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a CreatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type CreateProviderRequest struct { - Provider types.Object `tfsdk:"provider" tf:"object"` + Provider types.List `tfsdk:"provider" tf:"object"` } func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateProviderRequest) { @@ -370,6 +554,14 @@ func (a CreateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Provider": ProviderInfo{}.ToAttrType(ctx), + }, + } +} + type CreateProviderResponse struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -384,6 +576,14 @@ func (a CreateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DataRefreshInfo struct { Interval types.Int64 `tfsdk:"interval" tf:""` @@ -400,6 +600,15 @@ func (a DataRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DataRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Interval": types.Int64Type, + "Unit": types.StringType, + }, + } +} + // Delete an exchange filter type DeleteExchangeFilterRequest struct { Id types.String `tfsdk:"-"` @@ -415,6 +624,14 @@ func (a DeleteExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a DeleteExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteExchangeFilterResponse struct { } @@ -428,6 +645,12 @@ func (a DeleteExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete an exchange type DeleteExchangeRequest struct { Id types.String `tfsdk:"-"` @@ -443,6 +666,14 @@ func (a DeleteExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteExchangeResponse struct { } @@ -456,6 +687,12 @@ func (a DeleteExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a file type DeleteFileRequest struct { FileId types.String `tfsdk:"-"` @@ -471,6 +708,14 @@ func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileId": types.StringType, + }, + } +} + type DeleteFileResponse struct { } @@ -484,6 +729,12 @@ func (a DeleteFileResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteFileResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Uninstall from a listing type DeleteInstallationRequest struct { InstallationId types.String `tfsdk:"-"` @@ -501,6 +752,15 @@ func (a DeleteInstallationRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InstallationId": types.StringType, + "ListingId": types.StringType, + }, + } +} + type DeleteInstallationResponse struct { } @@ -514,6 +774,12 @@ func (a DeleteInstallationResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a listing type DeleteListingRequest struct { Id types.String `tfsdk:"-"` @@ -529,6 +795,14 @@ func (a DeleteListingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteListingResponse struct { } @@ -542,6 +816,12 @@ func (a DeleteListingResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete provider type DeleteProviderRequest struct { Id types.String `tfsdk:"-"` @@ -557,6 +837,14 @@ func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteProviderResponse struct { } @@ -570,6 +858,12 @@ func (a DeleteProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Exchange struct { Comment types.String `tfsdk:"comment" tf:"optional"` @@ -603,6 +897,26 @@ func (a Exchange) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Exchange) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "Filters": basetypes.ListType{ + ElemType: ExchangeFilter{}.ToAttrType(ctx), + }, + "Id": types.StringType, + "LinkedListings": basetypes.ListType{ + ElemType: ExchangeListing{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type ExchangeFilter struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -633,6 +947,22 @@ func (a ExchangeFilter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExchangeFilter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "ExchangeId": types.StringType, + "FilterType": types.StringType, + "FilterValue": types.StringType, + "Id": types.StringType, + "Name": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type ExchangeListing struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -659,6 +989,20 @@ func (a ExchangeListing) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExchangeListing) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "ExchangeId": types.StringType, + "ExchangeName": types.StringType, + "Id": types.StringType, + "ListingId": types.StringType, + "ListingName": types.StringType, + }, + } +} + type FileInfo struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` // Name displayed to users for applicable files, e.g. embedded notebooks @@ -666,7 +1010,7 @@ type FileInfo struct { DownloadLink types.String `tfsdk:"download_link" tf:"optional"` - FileParent types.Object `tfsdk:"file_parent" tf:"optional,object"` + FileParent types.List `tfsdk:"file_parent" tf:"optional,object"` Id types.String `tfsdk:"id" tf:"optional"` @@ -694,6 +1038,23 @@ func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.Int64Type, + "DisplayName": types.StringType, + "DownloadLink": types.StringType, + "FileParent": FileParent{}.ToAttrType(ctx), + "Id": types.StringType, + "MarketplaceFileType": types.StringType, + "MimeType": types.StringType, + "Status": types.StringType, + "StatusMessage": types.StringType, + "UpdatedAt": types.Int64Type, + }, + } +} + type FileParent struct { FileParentType types.String `tfsdk:"file_parent_type" tf:"optional"` // TODO make the following fields required @@ -710,6 +1071,15 @@ func (a FileParent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FileParent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileParentType": types.StringType, + "ParentId": types.StringType, + }, + } +} + // Get an exchange type GetExchangeRequest struct { Id types.String `tfsdk:"-"` @@ -725,8 +1095,16 @@ func (a GetExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetExchangeResponse struct { - Exchange types.Object `tfsdk:"exchange" tf:"optional,object"` + Exchange types.List `tfsdk:"exchange" tf:"optional,object"` } func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetExchangeResponse) { @@ -741,6 +1119,14 @@ func (a GetExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exchange": Exchange{}.ToAttrType(ctx), + }, + } +} + // Get a file type GetFileRequest struct { FileId types.String `tfsdk:"-"` @@ -756,8 +1142,16 @@ func (a GetFileRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetFileRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileId": types.StringType, + }, + } +} + type GetFileResponse struct { - FileInfo types.Object `tfsdk:"file_info" tf:"optional,object"` + FileInfo types.List `tfsdk:"file_info" tf:"optional,object"` } func (newState *GetFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetFileResponse) { @@ -772,6 +1166,14 @@ func (a GetFileResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetFileResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileInfo": FileInfo{}.ToAttrType(ctx), + }, + } +} + type GetLatestVersionProviderAnalyticsDashboardResponse struct { // version here is latest logical version of the dashboard template Version types.Int64 `tfsdk:"version" tf:"optional"` @@ -787,6 +1189,14 @@ func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes return map[string]reflect.Type{} } +func (a GetLatestVersionProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Version": types.Int64Type, + }, + } +} + // Get listing content metadata type GetListingContentMetadataRequest struct { ListingId types.String `tfsdk:"-"` @@ -806,6 +1216,16 @@ func (a GetListingContentMetadataRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a GetListingContentMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type GetListingContentMetadataResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -824,6 +1244,17 @@ func (a GetListingContentMetadataResponse) GetComplexFieldTypes() map[string]ref } } +func (a GetListingContentMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "SharedDataObjects": basetypes.ListType{ + ElemType: SharedDataObject{}.ToAttrType(ctx), + }, + }, + } +} + // Get listing type GetListingRequest struct { Id types.String `tfsdk:"-"` @@ -839,8 +1270,16 @@ func (a GetListingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetListingResponse struct { - Listing types.Object `tfsdk:"listing" tf:"optional,object"` + Listing types.List `tfsdk:"listing" tf:"optional,object"` } func (newState *GetListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetListingResponse) { @@ -855,6 +1294,14 @@ func (a GetListingResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listing": Listing{}.ToAttrType(ctx), + }, + } +} + // List listings type GetListingsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -872,6 +1319,15 @@ func (a GetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type GetListingsResponse struct { Listings types.List `tfsdk:"listings" tf:"optional"` @@ -890,6 +1346,17 @@ func (a GetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listings": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // Get the personalization request for a listing type GetPersonalizationRequestRequest struct { ListingId types.String `tfsdk:"-"` @@ -905,6 +1372,14 @@ func (a GetPersonalizationRequestRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a GetPersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + }, + } +} + type GetPersonalizationRequestResponse struct { PersonalizationRequests types.List `tfsdk:"personalization_requests" tf:"optional"` } @@ -921,6 +1396,16 @@ func (a GetPersonalizationRequestResponse) GetComplexFieldTypes() map[string]ref } } +func (a GetPersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PersonalizationRequests": basetypes.ListType{ + ElemType: PersonalizationRequest{}.ToAttrType(ctx), + }, + }, + } +} + // Get a provider type GetProviderRequest struct { Id types.String `tfsdk:"-"` @@ -936,8 +1421,16 @@ func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetProviderResponse struct { - Provider types.Object `tfsdk:"provider" tf:"optional,object"` + Provider types.List `tfsdk:"provider" tf:"optional,object"` } func (newState *GetProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetProviderResponse) { @@ -952,8 +1445,16 @@ func (a GetProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Provider": ProviderInfo{}.ToAttrType(ctx), + }, + } +} + type Installation struct { - Installation types.Object `tfsdk:"installation" tf:"optional,object"` + Installation types.List `tfsdk:"installation" tf:"optional,object"` } func (newState *Installation) SyncEffectiveFieldsDuringCreateOrUpdate(plan Installation) { @@ -968,6 +1469,14 @@ func (a Installation) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Installation) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Installation": InstallationDetail{}.ToAttrType(ctx), + }, + } +} + type InstallationDetail struct { CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -991,7 +1500,7 @@ type InstallationDetail struct { Status types.String `tfsdk:"status" tf:"optional"` - TokenDetail types.Object `tfsdk:"token_detail" tf:"optional,object"` + TokenDetail types.List `tfsdk:"token_detail" tf:"optional,object"` Tokens types.List `tfsdk:"tokens" tf:"optional"` } @@ -1009,6 +1518,28 @@ func (a InstallationDetail) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a InstallationDetail) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "ErrorMessage": types.StringType, + "Id": types.StringType, + "InstalledOn": types.Int64Type, + "ListingId": types.StringType, + "ListingName": types.StringType, + "RecipientType": types.StringType, + "RepoName": types.StringType, + "RepoPath": types.StringType, + "ShareName": types.StringType, + "Status": types.StringType, + "TokenDetail": TokenDetail{}.ToAttrType(ctx), + "Tokens": basetypes.ListType{ + ElemType: TokenInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List all installations type ListAllInstallationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1026,6 +1557,15 @@ func (a ListAllInstallationsRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a ListAllInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListAllInstallationsResponse struct { Installations types.List `tfsdk:"installations" tf:"optional"` @@ -1044,6 +1584,17 @@ func (a ListAllInstallationsResponse) GetComplexFieldTypes() map[string]reflect. } } +func (a ListAllInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Installations": basetypes.ListType{ + ElemType: InstallationDetail{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List all personalization requests type ListAllPersonalizationRequestsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1061,6 +1612,15 @@ func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a ListAllPersonalizationRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListAllPersonalizationRequestsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1079,6 +1639,17 @@ func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes() map[strin } } +func (a ListAllPersonalizationRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "PersonalizationRequests": basetypes.ListType{ + ElemType: PersonalizationRequest{}.ToAttrType(ctx), + }, + }, + } +} + // List exchange filters type ListExchangeFiltersRequest struct { ExchangeId types.String `tfsdk:"-"` @@ -1098,6 +1669,16 @@ func (a ListExchangeFiltersRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a ListExchangeFiltersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListExchangeFiltersResponse struct { Filters types.List `tfsdk:"filters" tf:"optional"` @@ -1116,6 +1697,17 @@ func (a ListExchangeFiltersResponse) GetComplexFieldTypes() map[string]reflect.T } } +func (a ListExchangeFiltersResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filters": basetypes.ListType{ + ElemType: ExchangeFilter{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List exchanges for listing type ListExchangesForListingRequest struct { ListingId types.String `tfsdk:"-"` @@ -1135,6 +1727,16 @@ func (a ListExchangesForListingRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a ListExchangesForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListExchangesForListingResponse struct { ExchangeListing types.List `tfsdk:"exchange_listing" tf:"optional"` @@ -1153,6 +1755,17 @@ func (a ListExchangesForListingResponse) GetComplexFieldTypes() map[string]refle } } +func (a ListExchangesForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeListing": basetypes.ListType{ + ElemType: ExchangeListing{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List exchanges type ListExchangesRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1170,6 +1783,15 @@ func (a ListExchangesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListExchangesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListExchangesResponse struct { Exchanges types.List `tfsdk:"exchanges" tf:"optional"` @@ -1188,9 +1810,20 @@ func (a ListExchangesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListExchangesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exchanges": basetypes.ListType{ + ElemType: Exchange{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List files type ListFilesRequest struct { - FileParent types.Object `tfsdk:"-"` + FileParent types.List `tfsdk:"-"` PageSize types.Int64 `tfsdk:"-"` @@ -1209,6 +1842,16 @@ func (a ListFilesRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListFilesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileParent": FileParent{}.ToAttrType(ctx), + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListFilesResponse struct { FileInfos types.List `tfsdk:"file_infos" tf:"optional"` @@ -1227,6 +1870,17 @@ func (a ListFilesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListFilesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileInfos": basetypes.ListType{ + ElemType: FileInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List all listing fulfillments type ListFulfillmentsRequest struct { ListingId types.String `tfsdk:"-"` @@ -1246,6 +1900,16 @@ func (a ListFulfillmentsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListFulfillmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListFulfillmentsResponse struct { Fulfillments types.List `tfsdk:"fulfillments" tf:"optional"` @@ -1264,6 +1928,17 @@ func (a ListFulfillmentsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListFulfillmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Fulfillments": basetypes.ListType{ + ElemType: ListingFulfillment{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List installations for a listing type ListInstallationsRequest struct { ListingId types.String `tfsdk:"-"` @@ -1283,6 +1958,16 @@ func (a ListInstallationsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListInstallationsResponse struct { Installations types.List `tfsdk:"installations" tf:"optional"` @@ -1301,6 +1986,17 @@ func (a ListInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ListInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Installations": basetypes.ListType{ + ElemType: InstallationDetail{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List listings for exchange type ListListingsForExchangeRequest struct { ExchangeId types.String `tfsdk:"-"` @@ -1320,6 +2016,16 @@ func (a ListListingsForExchangeRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a ListListingsForExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeId": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListListingsForExchangeResponse struct { ExchangeListings types.List `tfsdk:"exchange_listings" tf:"optional"` @@ -1338,6 +2044,17 @@ func (a ListListingsForExchangeResponse) GetComplexFieldTypes() map[string]refle } } +func (a ListListingsForExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExchangeListings": basetypes.ListType{ + ElemType: ExchangeListing{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List listings type ListListingsRequest struct { // Matches any of the following asset types @@ -1368,13 +2085,37 @@ func (newState *ListListingsRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Assets": reflect.TypeOf(""), - "Categories": reflect.TypeOf(""), - "ProviderIds": reflect.TypeOf(""), + "Assets": reflect.TypeOf(types.StringType), + "Categories": reflect.TypeOf(types.StringType), + "ProviderIds": reflect.TypeOf(types.StringType), "Tags": reflect.TypeOf(ListingTag{}), } } +func (a ListListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Assets": basetypes.ListType{ + ElemType: types.StringType, + }, + "Categories": basetypes.ListType{ + ElemType: types.StringType, + }, + "IsFree": types.BoolType, + "IsPrivateExchange": types.BoolType, + "IsStaffPick": types.BoolType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "ProviderIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "Tags": basetypes.ListType{ + ElemType: ListingTag{}.ToAttrType(ctx), + }, + }, + } +} + type ListListingsResponse struct { Listings types.List `tfsdk:"listings" tf:"optional"` @@ -1393,6 +2134,17 @@ func (a ListListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listings": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type ListProviderAnalyticsDashboardResponse struct { // dashboard_id will be used to open Lakeview dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:""` @@ -1412,6 +2164,16 @@ func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[strin return map[string]reflect.Type{} } +func (a ListProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Id": types.StringType, + "Version": types.Int64Type, + }, + } +} + // List providers type ListProvidersRequest struct { IsFeatured types.Bool `tfsdk:"-"` @@ -1431,6 +2193,16 @@ func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsFeatured": types.BoolType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListProvidersResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1449,12 +2221,23 @@ func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Providers": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, + }, + } +} + type Listing struct { - Detail types.Object `tfsdk:"detail" tf:"optional,object"` + Detail types.List `tfsdk:"detail" tf:"optional,object"` Id types.String `tfsdk:"id" tf:"optional"` // Next Number: 26 - Summary types.Object `tfsdk:"summary" tf:"object"` + Summary types.List `tfsdk:"summary" tf:"object"` } func (newState *Listing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing) { @@ -1470,6 +2253,16 @@ func (a Listing) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Listing) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Detail": ListingDetail{}.ToAttrType(ctx), + "Id": types.StringType, + "Summary": ListingSummary{}.ToAttrType(ctx), + }, + } +} + type ListingDetail struct { // Type of assets included in the listing. eg. GIT_REPO, DATA_TABLE, MODEL, // NOTEBOOK @@ -1479,7 +2272,7 @@ type ListingDetail struct { // The starting date timestamp for when the data spans CollectionDateStart types.Int64 `tfsdk:"collection_date_start" tf:"optional"` // Smallest unit of time in the dataset - CollectionGranularity types.Object `tfsdk:"collection_granularity" tf:"optional,object"` + CollectionGranularity types.List `tfsdk:"collection_granularity" tf:"optional,object"` // Whether the dataset is free or paid Cost types.String `tfsdk:"cost" tf:"optional"` // Where/how the data is sourced @@ -1518,7 +2311,7 @@ type ListingDetail struct { TermsOfService types.String `tfsdk:"terms_of_service" tf:"optional"` // How often data is updated - UpdateFrequency types.Object `tfsdk:"update_frequency" tf:"optional,object"` + UpdateFrequency types.List `tfsdk:"update_frequency" tf:"optional,object"` } func (newState *ListingDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListingDetail) { @@ -1529,15 +2322,49 @@ func (newState *ListingDetail) SyncEffectiveFieldsDuringRead(existingState Listi func (a ListingDetail) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Assets": reflect.TypeOf(""), + "Assets": reflect.TypeOf(types.StringType), "CollectionGranularity": reflect.TypeOf(DataRefreshInfo{}), "EmbeddedNotebookFileInfos": reflect.TypeOf(FileInfo{}), - "FileIds": reflect.TypeOf(""), + "FileIds": reflect.TypeOf(types.StringType), "Tags": reflect.TypeOf(ListingTag{}), "UpdateFrequency": reflect.TypeOf(DataRefreshInfo{}), } } +func (a ListingDetail) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Assets": basetypes.ListType{ + ElemType: types.StringType, + }, + "CollectionDateEnd": types.Int64Type, + "CollectionDateStart": types.Int64Type, + "CollectionGranularity": DataRefreshInfo{}.ToAttrType(ctx), + "Cost": types.StringType, + "DataSource": types.StringType, + "Description": types.StringType, + "DocumentationLink": types.StringType, + "EmbeddedNotebookFileInfos": basetypes.ListType{ + ElemType: FileInfo{}.ToAttrType(ctx), + }, + "FileIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "GeographicalCoverage": types.StringType, + "License": types.StringType, + "PricingModel": types.StringType, + "PrivacyPolicyLink": types.StringType, + "Size": types.Float64Type, + "SupportLink": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ListingTag{}.ToAttrType(ctx), + }, + "TermsOfService": types.StringType, + "UpdateFrequency": DataRefreshInfo{}.ToAttrType(ctx), + }, + } +} + type ListingFulfillment struct { FulfillmentType types.String `tfsdk:"fulfillment_type" tf:"optional"` @@ -1545,9 +2372,9 @@ type ListingFulfillment struct { RecipientType types.String `tfsdk:"recipient_type" tf:"optional"` - RepoInfo types.Object `tfsdk:"repo_info" tf:"optional,object"` + RepoInfo types.List `tfsdk:"repo_info" tf:"optional,object"` - ShareInfo types.Object `tfsdk:"share_info" tf:"optional,object"` + ShareInfo types.List `tfsdk:"share_info" tf:"optional,object"` } func (newState *ListingFulfillment) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListingFulfillment) { @@ -1563,6 +2390,18 @@ func (a ListingFulfillment) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListingFulfillment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FulfillmentType": types.StringType, + "ListingId": types.StringType, + "RecipientType": types.StringType, + "RepoInfo": RepoInfo{}.ToAttrType(ctx), + "ShareInfo": ShareInfo{}.ToAttrType(ctx), + }, + } +} + type ListingSetting struct { Visibility types.String `tfsdk:"visibility" tf:"optional"` } @@ -1577,6 +2416,14 @@ func (a ListingSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListingSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Visibility": types.StringType, + }, + } +} + // Next Number: 26 type ListingSummary struct { Categories types.List `tfsdk:"categories" tf:"optional"` @@ -1590,7 +2437,7 @@ type ListingSummary struct { ExchangeIds types.List `tfsdk:"exchange_ids" tf:"optional"` // if a git repo is being created, a listing will be initialized with this // field as opposed to a share - GitRepo types.Object `tfsdk:"git_repo" tf:"optional,object"` + GitRepo types.List `tfsdk:"git_repo" tf:"optional,object"` ListingType types.String `tfsdk:"listingType" tf:""` @@ -1598,15 +2445,15 @@ type ListingSummary struct { ProviderId types.String `tfsdk:"provider_id" tf:"optional"` - ProviderRegion types.Object `tfsdk:"provider_region" tf:"optional,object"` + ProviderRegion types.List `tfsdk:"provider_region" tf:"optional,object"` PublishedAt types.Int64 `tfsdk:"published_at" tf:"optional"` PublishedBy types.String `tfsdk:"published_by" tf:"optional"` - Setting types.Object `tfsdk:"setting" tf:"optional,object"` + Setting types.List `tfsdk:"setting" tf:"optional,object"` - Share types.Object `tfsdk:"share" tf:"optional,object"` + Share types.List `tfsdk:"share" tf:"optional,object"` // Enums Status types.String `tfsdk:"status" tf:"optional"` @@ -1627,8 +2474,8 @@ func (newState *ListingSummary) SyncEffectiveFieldsDuringRead(existingState List func (a ListingSummary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Categories": reflect.TypeOf(""), - "ExchangeIds": reflect.TypeOf(""), + "Categories": reflect.TypeOf(types.StringType), + "ExchangeIds": reflect.TypeOf(types.StringType), "GitRepo": reflect.TypeOf(RepoInfo{}), "ProviderRegion": reflect.TypeOf(RegionInfo{}), "Setting": reflect.TypeOf(ListingSetting{}), @@ -1636,6 +2483,36 @@ func (a ListingSummary) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListingSummary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Categories": basetypes.ListType{ + ElemType: types.StringType, + }, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "CreatedById": types.Int64Type, + "ExchangeIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "GitRepo": RepoInfo{}.ToAttrType(ctx), + "ListingType": types.StringType, + "Name": types.StringType, + "ProviderId": types.StringType, + "ProviderRegion": RegionInfo{}.ToAttrType(ctx), + "PublishedAt": types.Int64Type, + "PublishedBy": types.StringType, + "Setting": ListingSetting{}.ToAttrType(ctx), + "Share": ShareInfo{}.ToAttrType(ctx), + "Status": types.StringType, + "Subtitle": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + "UpdatedById": types.Int64Type, + }, + } +} + type ListingTag struct { // Tag name (enum) TagName types.String `tfsdk:"tag_name" tf:"optional"` @@ -1652,17 +2529,28 @@ func (newState *ListingTag) SyncEffectiveFieldsDuringRead(existingState ListingT func (a ListingTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TagValues": reflect.TypeOf(""), + "TagValues": reflect.TypeOf(types.StringType), + } +} + +func (a ListingTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TagName": types.StringType, + "TagValues": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type PersonalizationRequest struct { Comment types.String `tfsdk:"comment" tf:"optional"` - ConsumerRegion types.Object `tfsdk:"consumer_region" tf:"object"` + ConsumerRegion types.List `tfsdk:"consumer_region" tf:"object"` // contact info for the consumer requesting data or performing a listing // installation - ContactInfo types.Object `tfsdk:"contact_info" tf:"optional,object"` + ContactInfo types.List `tfsdk:"contact_info" tf:"optional,object"` CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -1682,7 +2570,7 @@ type PersonalizationRequest struct { RecipientType types.String `tfsdk:"recipient_type" tf:"optional"` - Share types.Object `tfsdk:"share" tf:"optional,object"` + Share types.List `tfsdk:"share" tf:"optional,object"` Status types.String `tfsdk:"status" tf:"optional"` @@ -1705,6 +2593,29 @@ func (a PersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "ConsumerRegion": RegionInfo{}.ToAttrType(ctx), + "ContactInfo": ContactInfo{}.ToAttrType(ctx), + "CreatedAt": types.Int64Type, + "Id": types.StringType, + "IntendedUse": types.StringType, + "IsFromLighthouse": types.BoolType, + "ListingId": types.StringType, + "ListingName": types.StringType, + "MetastoreId": types.StringType, + "ProviderId": types.StringType, + "RecipientType": types.StringType, + "Share": ShareInfo{}.ToAttrType(ctx), + "Status": types.StringType, + "StatusMessage": types.StringType, + "UpdatedAt": types.Int64Type, + }, + } +} + type ProviderAnalyticsDashboard struct { Id types.String `tfsdk:"id" tf:""` } @@ -1719,6 +2630,14 @@ func (a ProviderAnalyticsDashboard) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a ProviderAnalyticsDashboard) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type ProviderInfo struct { BusinessContactEmail types.String `tfsdk:"business_contact_email" tf:""` @@ -1759,6 +2678,27 @@ func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BusinessContactEmail": types.StringType, + "CompanyWebsiteLink": types.StringType, + "DarkModeIconFileId": types.StringType, + "DarkModeIconFilePath": types.StringType, + "Description": types.StringType, + "IconFileId": types.StringType, + "IconFilePath": types.StringType, + "Id": types.StringType, + "IsFeatured": types.BoolType, + "Name": types.StringType, + "PrivacyPolicyLink": types.StringType, + "PublishedBy": types.StringType, + "SupportContactEmail": types.StringType, + "TermOfServiceLink": types.StringType, + }, + } +} + type RegionInfo struct { Cloud types.String `tfsdk:"cloud" tf:"optional"` @@ -1775,6 +2715,15 @@ func (a RegionInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RegionInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cloud": types.StringType, + "Region": types.StringType, + }, + } +} + // Remove an exchange for listing type RemoveExchangeForListingRequest struct { Id types.String `tfsdk:"-"` @@ -1790,6 +2739,14 @@ func (a RemoveExchangeForListingRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a RemoveExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type RemoveExchangeForListingResponse struct { } @@ -1803,6 +2760,12 @@ func (a RemoveExchangeForListingResponse) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a RemoveExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type RepoInfo struct { // the git repo url e.g. https://github.com/databrickslabs/dolly.git GitRepoUrl types.String `tfsdk:"git_repo_url" tf:""` @@ -1818,6 +2781,14 @@ func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GitRepoUrl": types.StringType, + }, + } +} + type RepoInstallation struct { // the user-specified repo name for their installed git repo listing RepoName types.String `tfsdk:"repo_name" tf:""` @@ -1837,6 +2808,15 @@ func (a RepoInstallation) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RepoInstallation) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RepoName": types.StringType, + "RepoPath": types.StringType, + }, + } +} + // Search listings type SearchListingsRequest struct { // Matches any of the following asset types @@ -1865,9 +2845,30 @@ func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringRead(existingSta func (a SearchListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Assets": reflect.TypeOf(""), - "Categories": reflect.TypeOf(""), - "ProviderIds": reflect.TypeOf(""), + "Assets": reflect.TypeOf(types.StringType), + "Categories": reflect.TypeOf(types.StringType), + "ProviderIds": reflect.TypeOf(types.StringType), + } +} + +func (a SearchListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Assets": basetypes.ListType{ + ElemType: types.StringType, + }, + "Categories": basetypes.ListType{ + ElemType: types.StringType, + }, + "IsFree": types.BoolType, + "IsPrivateExchange": types.BoolType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + "ProviderIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "Query": types.StringType, + }, } } @@ -1889,6 +2890,17 @@ func (a SearchListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SearchListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listings": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type ShareInfo struct { Name types.String `tfsdk:"name" tf:""` @@ -1905,6 +2917,15 @@ func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Type": types.StringType, + }, + } +} + type SharedDataObject struct { // The type of the data object. Could be one of: TABLE, SCHEMA, // NOTEBOOK_FILE, MODEL, VOLUME @@ -1923,6 +2944,15 @@ func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataObjectType": types.StringType, + "Name": types.StringType, + }, + } +} + type TokenDetail struct { BearerToken types.String `tfsdk:"bearerToken" tf:"optional"` @@ -1945,6 +2975,17 @@ func (a TokenDetail) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TokenDetail) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BearerToken": types.StringType, + "Endpoint": types.StringType, + "ExpirationTime": types.StringType, + "ShareCredentialsVersion": types.Int64Type, + }, + } +} + type TokenInfo struct { // Full activation url to retrieve the access token. It will be empty if the // token is already retrieved. @@ -1973,8 +3014,22 @@ func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActivationUrl": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "ExpirationTime": types.Int64Type, + "Id": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type UpdateExchangeFilterRequest struct { - Filter types.Object `tfsdk:"filter" tf:"object"` + Filter types.List `tfsdk:"filter" tf:"object"` Id types.String `tfsdk:"-"` } @@ -1991,8 +3046,17 @@ func (a UpdateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.T } } +func (a UpdateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": ExchangeFilter{}.ToAttrType(ctx), + "Id": types.StringType, + }, + } +} + type UpdateExchangeFilterResponse struct { - Filter types.Object `tfsdk:"filter" tf:"optional,object"` + Filter types.List `tfsdk:"filter" tf:"optional,object"` } func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateExchangeFilterResponse) { @@ -2007,8 +3071,16 @@ func (a UpdateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect. } } +func (a UpdateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": ExchangeFilter{}.ToAttrType(ctx), + }, + } +} + type UpdateExchangeRequest struct { - Exchange types.Object `tfsdk:"exchange" tf:"object"` + Exchange types.List `tfsdk:"exchange" tf:"object"` Id types.String `tfsdk:"-"` } @@ -2025,8 +3097,17 @@ func (a UpdateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exchange": Exchange{}.ToAttrType(ctx), + "Id": types.StringType, + }, + } +} + type UpdateExchangeResponse struct { - Exchange types.Object `tfsdk:"exchange" tf:"optional,object"` + Exchange types.List `tfsdk:"exchange" tf:"optional,object"` } func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateExchangeResponse) { @@ -2041,8 +3122,16 @@ func (a UpdateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exchange": Exchange{}.ToAttrType(ctx), + }, + } +} + type UpdateInstallationRequest struct { - Installation types.Object `tfsdk:"installation" tf:"object"` + Installation types.List `tfsdk:"installation" tf:"object"` InstallationId types.String `tfsdk:"-"` @@ -2063,8 +3152,19 @@ func (a UpdateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a UpdateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Installation": InstallationDetail{}.ToAttrType(ctx), + "InstallationId": types.StringType, + "ListingId": types.StringType, + "RotateToken": types.BoolType, + }, + } +} + type UpdateInstallationResponse struct { - Installation types.Object `tfsdk:"installation" tf:"optional,object"` + Installation types.List `tfsdk:"installation" tf:"optional,object"` } func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateInstallationResponse) { @@ -2079,10 +3179,18 @@ func (a UpdateInstallationResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a UpdateInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Installation": InstallationDetail{}.ToAttrType(ctx), + }, + } +} + type UpdateListingRequest struct { Id types.String `tfsdk:"-"` - Listing types.Object `tfsdk:"listing" tf:"object"` + Listing types.List `tfsdk:"listing" tf:"object"` } func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateListingRequest) { @@ -2097,8 +3205,17 @@ func (a UpdateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Listing": Listing{}.ToAttrType(ctx), + }, + } +} + type UpdateListingResponse struct { - Listing types.Object `tfsdk:"listing" tf:"optional,object"` + Listing types.List `tfsdk:"listing" tf:"optional,object"` } func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateListingResponse) { @@ -2113,6 +3230,14 @@ func (a UpdateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Listing": Listing{}.ToAttrType(ctx), + }, + } +} + type UpdatePersonalizationRequestRequest struct { ListingId types.String `tfsdk:"-"` @@ -2120,7 +3245,7 @@ type UpdatePersonalizationRequestRequest struct { RequestId types.String `tfsdk:"-"` - Share types.Object `tfsdk:"share" tf:"optional,object"` + Share types.List `tfsdk:"share" tf:"optional,object"` Status types.String `tfsdk:"status" tf:""` } @@ -2137,8 +3262,20 @@ func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes() map[string]r } } +func (a UpdatePersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ListingId": types.StringType, + "Reason": types.StringType, + "RequestId": types.StringType, + "Share": ShareInfo{}.ToAttrType(ctx), + "Status": types.StringType, + }, + } +} + type UpdatePersonalizationRequestResponse struct { - Request types.Object `tfsdk:"request" tf:"optional,object"` + Request types.List `tfsdk:"request" tf:"optional,object"` } func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdatePersonalizationRequestResponse) { @@ -2153,6 +3290,14 @@ func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes() map[string] } } +func (a UpdatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Request": PersonalizationRequest{}.ToAttrType(ctx), + }, + } +} + type UpdateProviderAnalyticsDashboardRequest struct { // id is immutable property and can't be updated. Id types.String `tfsdk:"-"` @@ -2172,6 +3317,15 @@ func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a UpdateProviderAnalyticsDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Version": types.Int64Type, + }, + } +} + type UpdateProviderAnalyticsDashboardResponse struct { // this is newly created Lakeview dashboard for the user DashboardId types.String `tfsdk:"dashboard_id" tf:""` @@ -2191,10 +3345,20 @@ func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[str return map[string]reflect.Type{} } +func (a UpdateProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Id": types.StringType, + "Version": types.Int64Type, + }, + } +} + type UpdateProviderRequest struct { Id types.String `tfsdk:"-"` - Provider types.Object `tfsdk:"provider" tf:"object"` + Provider types.List `tfsdk:"provider" tf:"object"` } func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateProviderRequest) { @@ -2209,8 +3373,17 @@ func (a UpdateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Provider": ProviderInfo{}.ToAttrType(ctx), + }, + } +} + type UpdateProviderResponse struct { - Provider types.Object `tfsdk:"provider" tf:"optional,object"` + Provider types.List `tfsdk:"provider" tf:"optional,object"` } func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateProviderResponse) { @@ -2224,3 +3397,11 @@ func (a UpdateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { "Provider": reflect.TypeOf(ProviderInfo{}), } } + +func (a UpdateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Provider": ProviderInfo{}.ToAttrType(ctx), + }, + } +} diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 9e07b0dfb6..c8621dbedd 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package ml_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) // Activity recorded for the action. @@ -82,6 +85,22 @@ func (a Activity) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Activity) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActivityType": types.StringType, + "Comment": types.StringType, + "CreationTimestamp": types.Int64Type, + "FromStage": types.StringType, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "SystemComment": types.StringType, + "ToStage": types.StringType, + "UserId": types.StringType, + }, + } +} + type ApproveTransitionRequest struct { // Specifies whether to archive all current model versions in the target // stage. @@ -114,9 +133,21 @@ func (a ApproveTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ApproveTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArchiveExistingVersions": types.BoolType, + "Comment": types.StringType, + "Name": types.StringType, + "Stage": types.StringType, + "Version": types.StringType, + }, + } +} + type ApproveTransitionRequestResponse struct { // Activity recorded for the action. - Activity types.Object `tfsdk:"activity" tf:"optional,object"` + Activity types.List `tfsdk:"activity" tf:"optional,object"` } func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ApproveTransitionRequestResponse) { @@ -131,6 +162,14 @@ func (a ApproveTransitionRequestResponse) GetComplexFieldTypes() map[string]refl } } +func (a ApproveTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Activity": Activity{}.ToAttrType(ctx), + }, + } +} + // Comment details. type CommentObject struct { // Array of actions on the activity allowed for the current viewer. @@ -155,7 +194,22 @@ func (newState *CommentObject) SyncEffectiveFieldsDuringRead(existingState Comme func (a CommentObject) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AvailableActions": reflect.TypeOf(""), + "AvailableActions": reflect.TypeOf(types.StringType), + } +} + +func (a CommentObject) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AvailableActions": basetypes.ListType{ + ElemType: types.StringType, + }, + "Comment": types.StringType, + "CreationTimestamp": types.Int64Type, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "UserId": types.StringType, + }, } } @@ -178,9 +232,19 @@ func (a CreateComment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateComment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type CreateCommentResponse struct { // Comment details. - Comment types.Object `tfsdk:"comment" tf:"optional,object"` + Comment types.List `tfsdk:"comment" tf:"optional,object"` } func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCommentResponse) { @@ -195,6 +259,14 @@ func (a CreateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": CommentObject{}.ToAttrType(ctx), + }, + } +} + type CreateExperiment struct { // Location where all artifacts for the experiment are stored. If not // provided, the remote server will select an appropriate default. @@ -221,6 +293,18 @@ func (a CreateExperiment) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateExperiment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactLocation": types.StringType, + "Name": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ExperimentTag{}.ToAttrType(ctx), + }, + }, + } +} + type CreateExperimentResponse struct { // Unique identifier for the experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:"optional"` @@ -236,6 +320,14 @@ func (a CreateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CreateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + }, + } +} + type CreateModelRequest struct { // Optional description for registered model. Description types.String `tfsdk:"description" tf:"optional"` @@ -257,8 +349,20 @@ func (a CreateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Name": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ModelTag{}.ToAttrType(ctx), + }, + }, + } +} + type CreateModelResponse struct { - RegisteredModel types.Object `tfsdk:"registered_model" tf:"optional,object"` + RegisteredModel types.List `tfsdk:"registered_model" tf:"optional,object"` } func (newState *CreateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateModelResponse) { @@ -273,6 +377,14 @@ func (a CreateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RegisteredModel": Model{}.ToAttrType(ctx), + }, + } +} + type CreateModelVersionRequest struct { // Optional description for model version. Description types.String `tfsdk:"description" tf:"optional"` @@ -302,9 +414,24 @@ func (a CreateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a CreateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Name": types.StringType, + "RunId": types.StringType, + "RunLink": types.StringType, + "Source": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ModelVersionTag{}.ToAttrType(ctx), + }, + }, + } +} + type CreateModelVersionResponse struct { // Return new version number generated for this model in registry. - ModelVersion types.Object `tfsdk:"model_version" tf:"optional,object"` + ModelVersion types.List `tfsdk:"model_version" tf:"optional,object"` } func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateModelVersionResponse) { @@ -319,6 +446,14 @@ func (a CreateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a CreateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelVersion": ModelVersion{}.ToAttrType(ctx), + }, + } +} + type CreateRegistryWebhook struct { // User-specified description for the webhook. Description types.String `tfsdk:"description" tf:"optional"` @@ -357,9 +492,9 @@ type CreateRegistryWebhook struct { // version be archived. Events types.List `tfsdk:"events" tf:""` - HttpUrlSpec types.Object `tfsdk:"http_url_spec" tf:"optional,object"` + HttpUrlSpec types.List `tfsdk:"http_url_spec" tf:"optional,object"` - JobSpec types.Object `tfsdk:"job_spec" tf:"optional,object"` + JobSpec types.List `tfsdk:"job_spec" tf:"optional,object"` // Name of the model whose events would trigger this webhook. ModelName types.String `tfsdk:"model_name" tf:"optional"` // Enable or disable triggering the webhook, or put the webhook into test @@ -381,12 +516,27 @@ func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingSta func (a CreateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(""), + "Events": reflect.TypeOf(types.StringType), "HttpUrlSpec": reflect.TypeOf(HttpUrlSpec{}), "JobSpec": reflect.TypeOf(JobSpec{}), } } +func (a CreateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Events": basetypes.ListType{ + ElemType: types.StringType, + }, + "HttpUrlSpec": HttpUrlSpec{}.ToAttrType(ctx), + "JobSpec": JobSpec{}.ToAttrType(ctx), + "ModelName": types.StringType, + "Status": types.StringType, + }, + } +} + type CreateRun struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:"optional"` @@ -412,9 +562,22 @@ func (a CreateRun) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + "StartTime": types.Int64Type, + "Tags": basetypes.ListType{ + ElemType: RunTag{}.ToAttrType(ctx), + }, + "UserId": types.StringType, + }, + } +} + type CreateRunResponse struct { // The newly created run. - Run types.Object `tfsdk:"run" tf:"optional,object"` + Run types.List `tfsdk:"run" tf:"optional,object"` } func (newState *CreateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateRunResponse) { @@ -429,6 +592,14 @@ func (a CreateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Run": Run{}.ToAttrType(ctx), + }, + } +} + type CreateTransitionRequest struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -458,9 +629,20 @@ func (a CreateTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CreateTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "Stage": types.StringType, + "Version": types.StringType, + }, + } +} + type CreateTransitionRequestResponse struct { // Transition request details. - Request types.Object `tfsdk:"request" tf:"optional,object"` + Request types.List `tfsdk:"request" tf:"optional,object"` } func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateTransitionRequestResponse) { @@ -475,8 +657,16 @@ func (a CreateTransitionRequestResponse) GetComplexFieldTypes() map[string]refle } } +func (a CreateTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Request": TransitionRequest{}.ToAttrType(ctx), + }, + } +} + type CreateWebhookResponse struct { - Webhook types.Object `tfsdk:"webhook" tf:"optional,object"` + Webhook types.List `tfsdk:"webhook" tf:"optional,object"` } func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateWebhookResponse) { @@ -491,6 +681,14 @@ func (a CreateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Webhook": RegistryWebhook{}.ToAttrType(ctx), + }, + } +} + type Dataset struct { // Dataset digest, e.g. an md5 hash of the dataset that uniquely identifies // it within datasets of the same name. @@ -524,9 +722,22 @@ func (a Dataset) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Dataset) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Digest": types.StringType, + "Name": types.StringType, + "Profile": types.StringType, + "Schema": types.StringType, + "Source": types.StringType, + "SourceType": types.StringType, + }, + } +} + type DatasetInput struct { // The dataset being used as a Run input. - Dataset types.Object `tfsdk:"dataset" tf:"optional,object"` + Dataset types.List `tfsdk:"dataset" tf:"optional,object"` // A list of tags for the dataset input, e.g. a “context” tag with value // “training” Tags types.List `tfsdk:"tags" tf:"optional"` @@ -545,6 +756,17 @@ func (a DatasetInput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DatasetInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Dataset": Dataset{}.ToAttrType(ctx), + "Tags": basetypes.ListType{ + ElemType: InputTag{}.ToAttrType(ctx), + }, + }, + } +} + // Delete a comment type DeleteCommentRequest struct { Id types.String `tfsdk:"-"` @@ -560,6 +782,14 @@ func (a DeleteCommentRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteCommentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteCommentResponse struct { } @@ -573,6 +803,12 @@ func (a DeleteCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -588,6 +824,14 @@ func (a DeleteExperiment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteExperiment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + }, + } +} + type DeleteExperimentResponse struct { } @@ -601,6 +845,12 @@ func (a DeleteExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a model type DeleteModelRequest struct { // Registered model unique name identifier. @@ -617,6 +867,14 @@ func (a DeleteModelRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type DeleteModelResponse struct { } @@ -630,6 +888,12 @@ func (a DeleteModelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteModelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a model tag type DeleteModelTagRequest struct { // Name of the tag. The name must be an exact match; wild-card deletion is @@ -649,6 +913,15 @@ func (a DeleteModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Name": types.StringType, + }, + } +} + type DeleteModelTagResponse struct { } @@ -662,6 +935,12 @@ func (a DeleteModelTagResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteModelTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a model version. type DeleteModelVersionRequest struct { // Name of the registered model @@ -680,6 +959,15 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type DeleteModelVersionResponse struct { } @@ -693,6 +981,12 @@ func (a DeleteModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a model version tag type DeleteModelVersionTagRequest struct { // Name of the tag. The name must be an exact match; wild-card deletion is @@ -714,6 +1008,16 @@ func (a DeleteModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type DeleteModelVersionTagResponse struct { } @@ -727,6 +1031,12 @@ func (a DeleteModelVersionTagResponse) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a DeleteModelVersionTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteRun struct { // ID of the run to delete. RunId types.String `tfsdk:"run_id" tf:""` @@ -742,6 +1052,14 @@ func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.StringType, + }, + } +} + type DeleteRunResponse struct { } @@ -755,6 +1073,12 @@ func (a DeleteRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteRuns struct { // The ID of the experiment containing the runs to delete. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -777,6 +1101,16 @@ func (a DeleteRuns) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRuns) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + "MaxRuns": types.Int64Type, + "MaxTimestampMillis": types.Int64Type, + }, + } +} + type DeleteRunsResponse struct { // The number of runs deleted. RunsDeleted types.Int64 `tfsdk:"runs_deleted" tf:"optional"` @@ -792,6 +1126,14 @@ func (a DeleteRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunsDeleted": types.Int64Type, + }, + } +} + type DeleteTag struct { // Name of the tag. Maximum size is 255 bytes. Must be provided. Key types.String `tfsdk:"key" tf:""` @@ -809,6 +1151,15 @@ func (a DeleteTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "RunId": types.StringType, + }, + } +} + type DeleteTagResponse struct { } @@ -822,6 +1173,12 @@ func (a DeleteTagResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a transition request type DeleteTransitionRequestRequest struct { // User-provided comment on the action. @@ -856,6 +1213,18 @@ func (a DeleteTransitionRequestRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a DeleteTransitionRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Creator": types.StringType, + "Name": types.StringType, + "Stage": types.StringType, + "Version": types.StringType, + }, + } +} + type DeleteTransitionRequestResponse struct { } @@ -869,6 +1238,12 @@ func (a DeleteTransitionRequestResponse) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a DeleteTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a webhook type DeleteWebhookRequest struct { // Webhook ID required to delete a registry webhook. @@ -885,6 +1260,14 @@ func (a DeleteWebhookRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteWebhookResponse struct { } @@ -898,6 +1281,12 @@ func (a DeleteWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Experiment struct { // Location where artifacts for the experiment are stored. ArtifactLocation types.String `tfsdk:"artifact_location" tf:"optional"` @@ -928,6 +1317,22 @@ func (a Experiment) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Experiment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactLocation": types.StringType, + "CreationTime": types.Int64Type, + "ExperimentId": types.StringType, + "LastUpdateTime": types.Int64Type, + "LifecycleStage": types.StringType, + "Name": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ExperimentTag{}.ToAttrType(ctx), + }, + }, + } +} + type ExperimentAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -949,6 +1354,17 @@ func (a ExperimentAccessControlRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a ExperimentAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ExperimentAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -974,6 +1390,20 @@ func (a ExperimentAccessControlResponse) GetComplexFieldTypes() map[string]refle } } +func (a ExperimentAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: ExperimentPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ExperimentPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -990,7 +1420,19 @@ func (newState *ExperimentPermission) SyncEffectiveFieldsDuringRead(existingStat func (a ExperimentPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a ExperimentPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1014,6 +1456,18 @@ func (a ExperimentPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ExperimentPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ExperimentAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type ExperimentPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1030,6 +1484,15 @@ func (a ExperimentPermissionsDescription) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a ExperimentPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type ExperimentPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The experiment for which to get or manage permissions. @@ -1048,6 +1511,17 @@ func (a ExperimentPermissionsRequest) GetComplexFieldTypes() map[string]reflect. } } +func (a ExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ExperimentAccessControlRequest{}.ToAttrType(ctx), + }, + "ExperimentId": types.StringType, + }, + } +} + type ExperimentTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -1065,6 +1539,15 @@ func (a ExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type FileInfo struct { // Size in bytes. Unset for directories. FileSize types.Int64 `tfsdk:"file_size" tf:"optional"` @@ -1084,6 +1567,16 @@ func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FileSize": types.Int64Type, + "IsDir": types.BoolType, + "Path": types.StringType, + }, + } +} + // Get metadata type GetByNameRequest struct { // Name of the associated experiment. @@ -1100,6 +1593,14 @@ func (a GetByNameRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetByNameRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentName": types.StringType, + }, + } +} + // Get experiment permission levels type GetExperimentPermissionLevelsRequest struct { // The experiment for which to get or manage permissions. @@ -1116,6 +1617,14 @@ func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GetExperimentPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + }, + } +} + type GetExperimentPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -1133,6 +1642,16 @@ func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes() map[string } } +func (a GetExperimentPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: ExperimentPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get experiment permissions type GetExperimentPermissionsRequest struct { // The experiment for which to get or manage permissions. @@ -1149,6 +1668,14 @@ func (a GetExperimentPermissionsRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a GetExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + }, + } +} + // Get an experiment type GetExperimentRequest struct { // ID of the associated experiment. @@ -1165,9 +1692,17 @@ func (a GetExperimentRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetExperimentRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + }, + } +} + type GetExperimentResponse struct { // Experiment details. - Experiment types.Object `tfsdk:"experiment" tf:"optional,object"` + Experiment types.List `tfsdk:"experiment" tf:"optional,object"` } func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetExperimentResponse) { @@ -1182,6 +1717,14 @@ func (a GetExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Experiment": Experiment{}.ToAttrType(ctx), + }, + } +} + // Get history of a given metric within a run type GetHistoryRequest struct { // Maximum number of Metric records to return per paginated request. Default @@ -1209,6 +1752,18 @@ func (a GetHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "MetricKey": types.StringType, + "PageToken": types.StringType, + "RunId": types.StringType, + "RunUuid": types.StringType, + }, + } +} + type GetLatestVersionsRequest struct { // Registered model unique name identifier. Name types.String `tfsdk:"name" tf:""` @@ -1224,7 +1779,18 @@ func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringRead(existing func (a GetLatestVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Stages": reflect.TypeOf(""), + "Stages": reflect.TypeOf(types.StringType), + } +} + +func (a GetLatestVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Stages": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1247,6 +1813,16 @@ func (a GetLatestVersionsResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a GetLatestVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelVersions": basetypes.ListType{ + ElemType: ModelVersion{}.ToAttrType(ctx), + }, + }, + } +} + type GetMetricHistoryResponse struct { // All logged values for this metric. Metrics types.List `tfsdk:"metrics" tf:"optional"` @@ -1267,6 +1843,17 @@ func (a GetMetricHistoryResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a GetMetricHistoryResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Metrics": basetypes.ListType{ + ElemType: Metric{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // Get model type GetModelRequest struct { // Registered model unique name identifier. @@ -1283,8 +1870,16 @@ func (a GetModelRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type GetModelResponse struct { - RegisteredModelDatabricks types.Object `tfsdk:"registered_model_databricks" tf:"optional,object"` + RegisteredModelDatabricks types.List `tfsdk:"registered_model_databricks" tf:"optional,object"` } func (newState *GetModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetModelResponse) { @@ -1299,6 +1894,14 @@ func (a GetModelResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetModelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RegisteredModelDatabricks": ModelDatabricks{}.ToAttrType(ctx), + }, + } +} + // Get a model version URI type GetModelVersionDownloadUriRequest struct { // Name of the registered model @@ -1317,6 +1920,15 @@ func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetModelVersionDownloadUriRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type GetModelVersionDownloadUriResponse struct { // URI corresponding to where artifacts for this model version are stored. ArtifactUri types.String `tfsdk:"artifact_uri" tf:"optional"` @@ -1332,6 +1944,14 @@ func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a GetModelVersionDownloadUriResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactUri": types.StringType, + }, + } +} + // Get a model version type GetModelVersionRequest struct { // Name of the registered model @@ -1350,8 +1970,17 @@ func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type GetModelVersionResponse struct { - ModelVersion types.Object `tfsdk:"model_version" tf:"optional,object"` + ModelVersion types.List `tfsdk:"model_version" tf:"optional,object"` } func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetModelVersionResponse) { @@ -1366,6 +1995,14 @@ func (a GetModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a GetModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelVersion": ModelVersion{}.ToAttrType(ctx), + }, + } +} + // Get registered model permission levels type GetRegisteredModelPermissionLevelsRequest struct { // The registered model for which to get or manage permissions. @@ -1382,6 +2019,14 @@ func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes() map[st return map[string]reflect.Type{} } +func (a GetRegisteredModelPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RegisteredModelId": types.StringType, + }, + } +} + type GetRegisteredModelPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -1399,6 +2044,16 @@ func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes() map[s } } +func (a GetRegisteredModelPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: RegisteredModelPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get registered model permissions type GetRegisteredModelPermissionsRequest struct { // The registered model for which to get or manage permissions. @@ -1415,6 +2070,14 @@ func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GetRegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RegisteredModelId": types.StringType, + }, + } +} + // Get a run type GetRunRequest struct { // ID of the run to fetch. Must be provided. @@ -1434,10 +2097,19 @@ func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.StringType, + "RunUuid": types.StringType, + }, + } +} + type GetRunResponse struct { // Run metadata (name, start time, etc) and data (metrics, params, and // tags). - Run types.Object `tfsdk:"run" tf:"optional,object"` + Run types.List `tfsdk:"run" tf:"optional,object"` } func (newState *GetRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRunResponse) { @@ -1452,6 +2124,14 @@ func (a GetRunResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Run": Run{}.ToAttrType(ctx), + }, + } +} + type HttpUrlSpec struct { // Value of the authorization header that should be sent in the request sent // by the wehbook. It should be of the form `" "`. @@ -1484,6 +2164,17 @@ func (a HttpUrlSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a HttpUrlSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Authorization": types.StringType, + "EnableSslVerification": types.BoolType, + "Secret": types.StringType, + "Url": types.StringType, + }, + } +} + type HttpUrlSpecWithoutSecret struct { // Enable/disable SSL certificate validation. Default is true. For // self-signed certificates, this field must be false AND the destination @@ -1507,6 +2198,15 @@ func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a HttpUrlSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EnableSslVerification": types.BoolType, + "Url": types.StringType, + }, + } +} + type InputTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -1524,6 +2224,15 @@ func (a InputTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a InputTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type JobSpec struct { // The personal access token used to authorize webhook's job runs. AccessToken types.String `tfsdk:"access_token" tf:""` @@ -1545,6 +2254,16 @@ func (a JobSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessToken": types.StringType, + "JobId": types.StringType, + "WorkspaceUrl": types.StringType, + }, + } +} + type JobSpecWithoutSecret struct { // ID of the job that the webhook runs. JobId types.String `tfsdk:"job_id" tf:"optional"` @@ -1564,6 +2283,15 @@ func (a JobSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a JobSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "JobId": types.StringType, + "WorkspaceUrl": types.StringType, + }, + } +} + // Get all artifacts type ListArtifactsRequest struct { // Token indicating the page of artifact results to fetch. `page_token` is @@ -1593,6 +2321,17 @@ func (a ListArtifactsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListArtifactsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageToken": types.StringType, + "Path": types.StringType, + "RunId": types.StringType, + "RunUuid": types.StringType, + }, + } +} + type ListArtifactsResponse struct { // File location and metadata for artifacts. Files types.List `tfsdk:"files" tf:"optional"` @@ -1614,6 +2353,18 @@ func (a ListArtifactsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListArtifactsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Files": basetypes.ListType{ + ElemType: FileInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + "RootUri": types.StringType, + }, + } +} + // List experiments type ListExperimentsRequest struct { // Maximum number of experiments desired. If `max_results` is unspecified, @@ -1639,6 +2390,16 @@ func (a ListExperimentsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListExperimentsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "ViewType": types.StringType, + }, + } +} + type ListExperimentsResponse struct { // Paginated Experiments beginning with the first item on the requested // page. @@ -1660,6 +2421,17 @@ func (a ListExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Experiments": basetypes.ListType{ + ElemType: Experiment{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List models type ListModelsRequest struct { // Maximum number of registered models desired. Max threshold is 1000. @@ -1678,6 +2450,15 @@ func (a ListModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListModelsResponse struct { // Pagination token to request next page of models for the same query. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1697,6 +2478,17 @@ func (a ListModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "RegisteredModels": basetypes.ListType{ + ElemType: Model{}.ToAttrType(ctx), + }, + }, + } +} + type ListRegistryWebhooks struct { // Token that can be used to retrieve the next page of artifact results NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1716,6 +2508,17 @@ func (a ListRegistryWebhooks) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListRegistryWebhooks) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Webhooks": basetypes.ListType{ + ElemType: RegistryWebhook{}.ToAttrType(ctx), + }, + }, + } +} + // List transition requests type ListTransitionRequestsRequest struct { // Name of the model. @@ -1734,6 +2537,15 @@ func (a ListTransitionRequestsRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a ListTransitionRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type ListTransitionRequestsResponse struct { // Array of open transition requests. Requests types.List `tfsdk:"requests" tf:"optional"` @@ -1751,6 +2563,16 @@ func (a ListTransitionRequestsResponse) GetComplexFieldTypes() map[string]reflec } } +func (a ListTransitionRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Requests": basetypes.ListType{ + ElemType: Activity{}.ToAttrType(ctx), + }, + }, + } +} + // List registry webhooks type ListWebhooksRequest struct { // If `events` is specified, any webhook with one or more of the specified @@ -1772,7 +2594,19 @@ func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListWebhooksRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(""), + "Events": reflect.TypeOf(types.StringType), + } +} + +func (a ListWebhooksRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Events": basetypes.ListType{ + ElemType: types.StringType, + }, + "ModelName": types.StringType, + "PageToken": types.StringType, + }, } } @@ -1804,6 +2638,23 @@ func (a LogBatch) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a LogBatch) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Metrics": basetypes.ListType{ + ElemType: Metric{}.ToAttrType(ctx), + }, + "Params": basetypes.ListType{ + ElemType: Param{}.ToAttrType(ctx), + }, + "RunId": types.StringType, + "Tags": basetypes.ListType{ + ElemType: RunTag{}.ToAttrType(ctx), + }, + }, + } +} + type LogBatchResponse struct { } @@ -1817,6 +2668,12 @@ func (a LogBatchResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogBatchResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type LogInputs struct { // Dataset inputs Datasets types.List `tfsdk:"datasets" tf:"optional"` @@ -1836,6 +2693,17 @@ func (a LogInputs) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a LogInputs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Datasets": basetypes.ListType{ + ElemType: DatasetInput{}.ToAttrType(ctx), + }, + "RunId": types.StringType, + }, + } +} + type LogInputsResponse struct { } @@ -1849,6 +2717,12 @@ func (a LogInputsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogInputsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type LogMetric struct { // Name of the metric. Key types.String `tfsdk:"key" tf:""` @@ -1875,6 +2749,19 @@ func (a LogMetric) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogMetric) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "RunId": types.StringType, + "RunUuid": types.StringType, + "Step": types.Int64Type, + "Timestamp": types.Int64Type, + "Value": types.Float64Type, + }, + } +} + type LogMetricResponse struct { } @@ -1888,6 +2775,12 @@ func (a LogMetricResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogMetricResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type LogModel struct { // MLmodel file in json format. ModelJson types.String `tfsdk:"model_json" tf:"optional"` @@ -1905,6 +2798,15 @@ func (a LogModel) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogModel) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelJson": types.StringType, + "RunId": types.StringType, + }, + } +} + type LogModelResponse struct { } @@ -1918,6 +2820,12 @@ func (a LogModelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogModelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type LogParam struct { // Name of the param. Maximum size is 255 bytes. Key types.String `tfsdk:"key" tf:""` @@ -1940,6 +2848,17 @@ func (a LogParam) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogParam) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "RunId": types.StringType, + "RunUuid": types.StringType, + "Value": types.StringType, + }, + } +} + type LogParamResponse struct { } @@ -1953,6 +2872,12 @@ func (a LogParamResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogParamResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Metric struct { // Key identifying this metric. Key types.String `tfsdk:"key" tf:"optional"` @@ -1974,6 +2899,17 @@ func (a Metric) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Metric) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Step": types.Int64Type, + "Timestamp": types.Int64Type, + "Value": types.Float64Type, + }, + } +} + type Model struct { // Timestamp recorded when this `registered_model` was created. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -2006,6 +2942,24 @@ func (a Model) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Model) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "Description": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "LatestVersions": basetypes.ListType{ + ElemType: ModelVersion{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ModelTag{}.ToAttrType(ctx), + }, + "UserId": types.StringType, + }, + } +} + type ModelDatabricks struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -2041,6 +2995,26 @@ func (a ModelDatabricks) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ModelDatabricks) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "Description": types.StringType, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "LatestVersions": basetypes.ListType{ + ElemType: ModelVersion{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "PermissionLevel": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ModelTag{}.ToAttrType(ctx), + }, + "UserId": types.StringType, + }, + } +} + type ModelTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -2058,6 +3032,15 @@ func (a ModelTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ModelTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type ModelVersion struct { // Timestamp recorded when this `model_version` was created. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -2102,6 +3085,28 @@ func (a ModelVersion) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ModelVersion) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "CurrentStage": types.StringType, + "Description": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "Name": types.StringType, + "RunId": types.StringType, + "RunLink": types.StringType, + "Source": types.StringType, + "Status": types.StringType, + "StatusMessage": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ModelVersionTag{}.ToAttrType(ctx), + }, + "UserId": types.StringType, + "Version": types.StringType, + }, + } +} + type ModelVersionDatabricks struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -2165,6 +3170,29 @@ func (a ModelVersionDatabricks) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ModelVersionDatabricks) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "CurrentStage": types.StringType, + "Description": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "Name": types.StringType, + "PermissionLevel": types.StringType, + "RunId": types.StringType, + "RunLink": types.StringType, + "Source": types.StringType, + "Status": types.StringType, + "StatusMessage": types.StringType, + "Tags": basetypes.ListType{ + ElemType: ModelVersionTag{}.ToAttrType(ctx), + }, + "UserId": types.StringType, + "Version": types.StringType, + }, + } +} + type ModelVersionTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -2182,6 +3210,15 @@ func (a ModelVersionTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ModelVersionTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type Param struct { // Key identifying this param. Key types.String `tfsdk:"key" tf:"optional"` @@ -2199,6 +3236,15 @@ func (a Param) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Param) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type RegisteredModelAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2220,6 +3266,17 @@ func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a RegisteredModelAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type RegisteredModelAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -2245,6 +3302,20 @@ func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes() map[string] } } +func (a RegisteredModelAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: RegisteredModelPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type RegisteredModelPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2261,7 +3332,19 @@ func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringRead(existin func (a RegisteredModelPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a RegisteredModelPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -2285,6 +3368,18 @@ func (a RegisteredModelPermissions) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a RegisteredModelPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: RegisteredModelAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type RegisteredModelPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2301,6 +3396,15 @@ func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a RegisteredModelPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type RegisteredModelPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The registered model for which to get or manage permissions. @@ -2319,6 +3423,17 @@ func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string]ref } } +func (a RegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: RegisteredModelAccessControlRequest{}.ToAttrType(ctx), + }, + "RegisteredModelId": types.StringType, + }, + } +} + type RegistryWebhook struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -2359,11 +3474,11 @@ type RegistryWebhook struct { // version be archived. Events types.List `tfsdk:"events" tf:"optional"` - HttpUrlSpec types.Object `tfsdk:"http_url_spec" tf:"optional,object"` + HttpUrlSpec types.List `tfsdk:"http_url_spec" tf:"optional,object"` // Webhook ID Id types.String `tfsdk:"id" tf:"optional"` - JobSpec types.Object `tfsdk:"job_spec" tf:"optional,object"` + JobSpec types.List `tfsdk:"job_spec" tf:"optional,object"` // Time of the object at last update, as a Unix timestamp in milliseconds. LastUpdatedTimestamp types.Int64 `tfsdk:"last_updated_timestamp" tf:"optional"` // Name of the model whose events would trigger this webhook. @@ -2387,12 +3502,30 @@ func (newState *RegistryWebhook) SyncEffectiveFieldsDuringRead(existingState Reg func (a RegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(""), + "Events": reflect.TypeOf(types.StringType), "HttpUrlSpec": reflect.TypeOf(HttpUrlSpecWithoutSecret{}), "JobSpec": reflect.TypeOf(JobSpecWithoutSecret{}), } } +func (a RegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "Description": types.StringType, + "Events": basetypes.ListType{ + ElemType: types.StringType, + }, + "HttpUrlSpec": HttpUrlSpecWithoutSecret{}.ToAttrType(ctx), + "Id": types.StringType, + "JobSpec": JobSpecWithoutSecret{}.ToAttrType(ctx), + "LastUpdatedTimestamp": types.Int64Type, + "ModelName": types.StringType, + "Status": types.StringType, + }, + } +} + type RejectTransitionRequest struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -2422,9 +3555,20 @@ func (a RejectTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a RejectTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "Stage": types.StringType, + "Version": types.StringType, + }, + } +} + type RejectTransitionRequestResponse struct { // Activity recorded for the action. - Activity types.Object `tfsdk:"activity" tf:"optional,object"` + Activity types.List `tfsdk:"activity" tf:"optional,object"` } func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan RejectTransitionRequestResponse) { @@ -2439,6 +3583,14 @@ func (a RejectTransitionRequestResponse) GetComplexFieldTypes() map[string]refle } } +func (a RejectTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Activity": Activity{}.ToAttrType(ctx), + }, + } +} + type RenameModelRequest struct { // Registered model unique name identifier. Name types.String `tfsdk:"name" tf:""` @@ -2456,8 +3608,17 @@ func (a RenameModelRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RenameModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "NewName": types.StringType, + }, + } +} + type RenameModelResponse struct { - RegisteredModel types.Object `tfsdk:"registered_model" tf:"optional,object"` + RegisteredModel types.List `tfsdk:"registered_model" tf:"optional,object"` } func (newState *RenameModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan RenameModelResponse) { @@ -2472,6 +3633,14 @@ func (a RenameModelResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RenameModelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RegisteredModel": Model{}.ToAttrType(ctx), + }, + } +} + type RestoreExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -2487,6 +3656,14 @@ func (a RestoreExperiment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestoreExperiment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + }, + } +} + type RestoreExperimentResponse struct { } @@ -2500,6 +3677,12 @@ func (a RestoreExperimentResponse) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a RestoreExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type RestoreRun struct { // ID of the run to restore. RunId types.String `tfsdk:"run_id" tf:""` @@ -2515,6 +3698,14 @@ func (a RestoreRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestoreRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunId": types.StringType, + }, + } +} + type RestoreRunResponse struct { } @@ -2528,6 +3719,12 @@ func (a RestoreRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestoreRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type RestoreRuns struct { // The ID of the experiment containing the runs to restore. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -2550,6 +3747,16 @@ func (a RestoreRuns) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestoreRuns) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + "MaxRuns": types.Int64Type, + "MinTimestampMillis": types.Int64Type, + }, + } +} + type RestoreRunsResponse struct { // The number of runs restored. RunsRestored types.Int64 `tfsdk:"runs_restored" tf:"optional"` @@ -2565,13 +3772,21 @@ func (a RestoreRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestoreRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunsRestored": types.Int64Type, + }, + } +} + type Run struct { // Run data. - Data types.Object `tfsdk:"data" tf:"optional,object"` + Data types.List `tfsdk:"data" tf:"optional,object"` // Run metadata. - Info types.Object `tfsdk:"info" tf:"optional,object"` + Info types.List `tfsdk:"info" tf:"optional,object"` // Run inputs. - Inputs types.Object `tfsdk:"inputs" tf:"optional,object"` + Inputs types.List `tfsdk:"inputs" tf:"optional,object"` } func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { @@ -2588,6 +3803,16 @@ func (a Run) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Run) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Data": RunData{}.ToAttrType(ctx), + "Info": RunInfo{}.ToAttrType(ctx), + "Inputs": RunInputs{}.ToAttrType(ctx), + }, + } +} + type RunData struct { // Run metrics. Metrics types.List `tfsdk:"metrics" tf:"optional"` @@ -2611,6 +3836,22 @@ func (a RunData) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RunData) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Metrics": basetypes.ListType{ + ElemType: Metric{}.ToAttrType(ctx), + }, + "Params": basetypes.ListType{ + ElemType: Param{}.ToAttrType(ctx), + }, + "Tags": basetypes.ListType{ + ElemType: RunTag{}.ToAttrType(ctx), + }, + }, + } +} + type RunInfo struct { // URI of the directory where artifacts should be uploaded. This can be a // local path (starting with "/"), or a distributed file system (DFS) path, @@ -2648,6 +3889,22 @@ func (a RunInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArtifactUri": types.StringType, + "EndTime": types.Int64Type, + "ExperimentId": types.StringType, + "LifecycleStage": types.StringType, + "RunId": types.StringType, + "RunUuid": types.StringType, + "StartTime": types.Int64Type, + "Status": types.StringType, + "UserId": types.StringType, + }, + } +} + type RunInputs struct { // Run metrics. DatasetInputs types.List `tfsdk:"dataset_inputs" tf:"optional"` @@ -2665,6 +3922,16 @@ func (a RunInputs) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RunInputs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DatasetInputs": basetypes.ListType{ + ElemType: DatasetInput{}.ToAttrType(ctx), + }, + }, + } +} + type RunTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -2682,6 +3949,15 @@ func (a RunTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RunTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type SearchExperiments struct { // String representing a SQL filter condition (e.g. "name ILIKE // 'my-experiment%'") @@ -2708,7 +3984,21 @@ func (newState *SearchExperiments) SyncEffectiveFieldsDuringRead(existingState S func (a SearchExperiments) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(""), + "OrderBy": reflect.TypeOf(types.StringType), + } +} + +func (a SearchExperiments) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": types.StringType, + "MaxResults": types.Int64Type, + "OrderBy": basetypes.ListType{ + ElemType: types.StringType, + }, + "PageToken": types.StringType, + "ViewType": types.StringType, + }, } } @@ -2732,6 +4022,17 @@ func (a SearchExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a SearchExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Experiments": basetypes.ListType{ + ElemType: Experiment{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // Searches model versions type SearchModelVersionsRequest struct { // String filter condition, like "name='my-model-name'". Must be a single @@ -2756,7 +4057,20 @@ func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringRead(existi func (a SearchModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(""), + "OrderBy": reflect.TypeOf(types.StringType), + } +} + +func (a SearchModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": types.StringType, + "MaxResults": types.Int64Type, + "OrderBy": basetypes.ListType{ + ElemType: types.StringType, + }, + "PageToken": types.StringType, + }, } } @@ -2780,6 +4094,17 @@ func (a SearchModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.T } } +func (a SearchModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelVersions": basetypes.ListType{ + ElemType: ModelVersion{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // Search models type SearchModelsRequest struct { // String filter condition, like "name LIKE 'my-model-name'". Interpreted in @@ -2804,7 +4129,20 @@ func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringRead(existingState func (a SearchModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(""), + "OrderBy": reflect.TypeOf(types.StringType), + } +} + +func (a SearchModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": types.StringType, + "MaxResults": types.Int64Type, + "OrderBy": basetypes.ListType{ + ElemType: types.StringType, + }, + "PageToken": types.StringType, + }, } } @@ -2827,6 +4165,17 @@ func (a SearchModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SearchModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "RegisteredModels": basetypes.ListType{ + ElemType: Model{}.ToAttrType(ctx), + }, + }, + } +} + type SearchRuns struct { // List of experiment IDs to search over. ExperimentIds types.List `tfsdk:"experiment_ids" tf:"optional"` @@ -2867,8 +4216,25 @@ func (newState *SearchRuns) SyncEffectiveFieldsDuringRead(existingState SearchRu func (a SearchRuns) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExperimentIds": reflect.TypeOf(""), - "OrderBy": reflect.TypeOf(""), + "ExperimentIds": reflect.TypeOf(types.StringType), + "OrderBy": reflect.TypeOf(types.StringType), + } +} + +func (a SearchRuns) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "Filter": types.StringType, + "MaxResults": types.Int64Type, + "OrderBy": basetypes.ListType{ + ElemType: types.StringType, + }, + "PageToken": types.StringType, + "RunViewType": types.StringType, + }, } } @@ -2891,6 +4257,17 @@ func (a SearchRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SearchRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Runs": basetypes.ListType{ + ElemType: Run{}.ToAttrType(ctx), + }, + }, + } +} + type SetExperimentTag struct { // ID of the experiment under which to log the tag. Must be provided. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -2913,6 +4290,16 @@ func (a SetExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SetExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type SetExperimentTagResponse struct { } @@ -2926,6 +4313,12 @@ func (a SetExperimentTagResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a SetExperimentTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type SetModelTagRequest struct { // Name of the tag. Maximum size depends on storage backend. If a tag with // this name already exists, its preexisting value will be replaced by the @@ -2950,6 +4343,16 @@ func (a SetModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SetModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Name": types.StringType, + "Value": types.StringType, + }, + } +} + type SetModelTagResponse struct { } @@ -2963,6 +4366,12 @@ func (a SetModelTagResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SetModelTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type SetModelVersionTagRequest struct { // Name of the tag. Maximum size depends on storage backend. If a tag with // this name already exists, its preexisting value will be replaced by the @@ -2989,6 +4398,17 @@ func (a SetModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a SetModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Name": types.StringType, + "Value": types.StringType, + "Version": types.StringType, + }, + } +} + type SetModelVersionTagResponse struct { } @@ -3002,6 +4422,12 @@ func (a SetModelVersionTagResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a SetModelVersionTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type SetTag struct { // Name of the tag. Maximum size depends on storage backend. All storage // backends are guaranteed to support key values up to 250 bytes in size. @@ -3027,6 +4453,17 @@ func (a SetTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SetTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "RunId": types.StringType, + "RunUuid": types.StringType, + "Value": types.StringType, + }, + } +} + type SetTagResponse struct { } @@ -3040,6 +4477,12 @@ func (a SetTagResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SetTagResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Test webhook response object. type TestRegistryWebhook struct { // Body of the response from the webhook URL @@ -3058,6 +4501,15 @@ func (a TestRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TestRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Body": types.StringType, + "StatusCode": types.Int64Type, + }, + } +} + type TestRegistryWebhookRequest struct { // If `event` is specified, the test trigger uses the specified event. If // `event` is not specified, the test trigger uses a randomly chosen event @@ -3077,9 +4529,18 @@ func (a TestRegistryWebhookRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a TestRegistryWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Event": types.StringType, + "Id": types.StringType, + }, + } +} + type TestRegistryWebhookResponse struct { // Test webhook response object. - Webhook types.Object `tfsdk:"webhook" tf:"optional,object"` + Webhook types.List `tfsdk:"webhook" tf:"optional,object"` } func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan TestRegistryWebhookResponse) { @@ -3094,6 +4555,14 @@ func (a TestRegistryWebhookResponse) GetComplexFieldTypes() map[string]reflect.T } } +func (a TestRegistryWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Webhook": TestRegistryWebhook{}.ToAttrType(ctx), + }, + } +} + type TransitionModelVersionStageDatabricks struct { // Specifies whether to archive all current model versions in the target // stage. @@ -3126,6 +4595,18 @@ func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a TransitionModelVersionStageDatabricks) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ArchiveExistingVersions": types.BoolType, + "Comment": types.StringType, + "Name": types.StringType, + "Stage": types.StringType, + "Version": types.StringType, + }, + } +} + // Transition request details. type TransitionRequest struct { // Array of actions on the activity allowed for the current viewer. @@ -3157,12 +4638,26 @@ func (newState *TransitionRequest) SyncEffectiveFieldsDuringRead(existingState T func (a TransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AvailableActions": reflect.TypeOf(""), + "AvailableActions": reflect.TypeOf(types.StringType), + } +} + +func (a TransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AvailableActions": basetypes.ListType{ + ElemType: types.StringType, + }, + "Comment": types.StringType, + "CreationTimestamp": types.Int64Type, + "ToStage": types.StringType, + "UserId": types.StringType, + }, } } type TransitionStageResponse struct { - ModelVersion types.Object `tfsdk:"model_version" tf:"optional,object"` + ModelVersion types.List `tfsdk:"model_version" tf:"optional,object"` } func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan TransitionStageResponse) { @@ -3177,6 +4672,14 @@ func (a TransitionStageResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a TransitionStageResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelVersion": ModelVersionDatabricks{}.ToAttrType(ctx), + }, + } +} + type UpdateComment struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:""` @@ -3194,9 +4697,18 @@ func (a UpdateComment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateComment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Id": types.StringType, + }, + } +} + type UpdateCommentResponse struct { // Comment details. - Comment types.Object `tfsdk:"comment" tf:"optional,object"` + Comment types.List `tfsdk:"comment" tf:"optional,object"` } func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCommentResponse) { @@ -3211,6 +4723,14 @@ func (a UpdateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": CommentObject{}.ToAttrType(ctx), + }, + } +} + type UpdateExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -3229,6 +4749,15 @@ func (a UpdateExperiment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateExperiment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExperimentId": types.StringType, + "NewName": types.StringType, + }, + } +} + type UpdateExperimentResponse struct { } @@ -3242,6 +4771,12 @@ func (a UpdateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a UpdateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateModelRequest struct { // If provided, updates the description for this `registered_model`. Description types.String `tfsdk:"description" tf:"optional"` @@ -3259,6 +4794,15 @@ func (a UpdateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Name": types.StringType, + }, + } +} + type UpdateModelResponse struct { } @@ -3272,6 +4816,12 @@ func (a UpdateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateModelVersionRequest struct { // If provided, updates the description for this `registered_model`. Description types.String `tfsdk:"description" tf:"optional"` @@ -3291,6 +4841,16 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Name": types.StringType, + "Version": types.StringType, + }, + } +} + type UpdateModelVersionResponse struct { } @@ -3304,6 +4864,12 @@ func (a UpdateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a UpdateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateRegistryWebhook struct { // User-specified description for the webhook. Description types.String `tfsdk:"description" tf:"optional"` @@ -3342,11 +4908,11 @@ type UpdateRegistryWebhook struct { // version be archived. Events types.List `tfsdk:"events" tf:"optional"` - HttpUrlSpec types.Object `tfsdk:"http_url_spec" tf:"optional,object"` + HttpUrlSpec types.List `tfsdk:"http_url_spec" tf:"optional,object"` // Webhook ID Id types.String `tfsdk:"id" tf:""` - JobSpec types.Object `tfsdk:"job_spec" tf:"optional,object"` + JobSpec types.List `tfsdk:"job_spec" tf:"optional,object"` // Enable or disable triggering the webhook, or put the webhook into test // mode. The default is `ACTIVE`: * `ACTIVE`: Webhook is triggered when an // associated event happens. @@ -3366,12 +4932,27 @@ func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(""), + "Events": reflect.TypeOf(types.StringType), "HttpUrlSpec": reflect.TypeOf(HttpUrlSpec{}), "JobSpec": reflect.TypeOf(JobSpec{}), } } +func (a UpdateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Events": basetypes.ListType{ + ElemType: types.StringType, + }, + "HttpUrlSpec": HttpUrlSpec{}.ToAttrType(ctx), + "Id": types.StringType, + "JobSpec": JobSpec{}.ToAttrType(ctx), + "Status": types.StringType, + }, + } +} + type UpdateRun struct { // Unix timestamp in milliseconds of when the run ended. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -3394,9 +4975,20 @@ func (a UpdateRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateRun) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndTime": types.Int64Type, + "RunId": types.StringType, + "RunUuid": types.StringType, + "Status": types.StringType, + }, + } +} + type UpdateRunResponse struct { // Updated metadata of the run. - RunInfo types.Object `tfsdk:"run_info" tf:"optional,object"` + RunInfo types.List `tfsdk:"run_info" tf:"optional,object"` } func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRunResponse) { @@ -3411,6 +5003,14 @@ func (a UpdateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunInfo": RunInfo{}.ToAttrType(ctx), + }, + } +} + type UpdateWebhookResponse struct { } @@ -3423,3 +5023,9 @@ func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a UpdateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index b201a6749b..7c8ea0076c 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package oauth2_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type CreateCustomAppIntegration struct { @@ -28,7 +31,7 @@ type CreateCustomAppIntegration struct { // offline_access, openid, profile, email. Scopes types.List `tfsdk:"scopes" tf:"optional"` // Token access policy - TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.List `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCustomAppIntegration) { @@ -39,12 +42,28 @@ func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existi func (a CreateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(""), - "Scopes": reflect.TypeOf(""), + "RedirectUrls": reflect.TypeOf(types.StringType), + "Scopes": reflect.TypeOf(types.StringType), "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), } } +func (a CreateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Confidential": types.BoolType, + "Name": types.StringType, + "RedirectUrls": basetypes.ListType{ + ElemType: types.StringType, + }, + "Scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + }, + } +} + type CreateCustomAppIntegrationOutput struct { // OAuth client-id generated by the Databricks ClientId types.String `tfsdk:"client_id" tf:"optional"` @@ -65,12 +84,22 @@ func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a CreateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClientId": types.StringType, + "ClientSecret": types.StringType, + "IntegrationId": types.StringType, + }, + } +} + type CreatePublishedAppIntegration struct { // App id of the OAuth published app integration. For example power-bi, // tableau-deskop AppId types.String `tfsdk:"app_id" tf:"optional"` // Token access policy - TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.List `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreatePublishedAppIntegration) { @@ -85,6 +114,15 @@ func (a CreatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect } } +func (a CreatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppId": types.StringType, + "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + }, + } +} + type CreatePublishedAppIntegrationOutput struct { // Unique integration id for the published OAuth app IntegrationId types.String `tfsdk:"integration_id" tf:"optional"` @@ -100,6 +138,14 @@ func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a CreatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + }, + } +} + // Create service principal secret type CreateServicePrincipalSecretRequest struct { // The service principal ID. @@ -116,6 +162,14 @@ func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a CreateServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ServicePrincipalId": types.Int64Type, + }, + } +} + type CreateServicePrincipalSecretResponse struct { // UTC time when the secret was created CreateTime types.String `tfsdk:"create_time" tf:"optional"` @@ -141,6 +195,19 @@ func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a CreateServicePrincipalSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "Id": types.StringType, + "Secret": types.StringType, + "SecretHash": types.StringType, + "Status": types.StringType, + "UpdateTime": types.StringType, + }, + } +} + type DataPlaneInfo struct { // Authorization details as a string. AuthorizationDetails types.String `tfsdk:"authorization_details" tf:"optional"` @@ -158,6 +225,15 @@ func (a DataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AuthorizationDetails": types.StringType, + "EndpointUrl": types.StringType, + }, + } +} + type DeleteCustomAppIntegrationOutput struct { } @@ -171,6 +247,12 @@ func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a DeleteCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete Custom OAuth App Integration type DeleteCustomAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -186,6 +268,14 @@ func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a DeleteCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + }, + } +} + type DeletePublishedAppIntegrationOutput struct { } @@ -199,6 +289,12 @@ func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a DeletePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete Published OAuth App Integration type DeletePublishedAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -214,6 +310,14 @@ func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a DeletePublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -227,6 +331,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete service principal secret type DeleteServicePrincipalSecretRequest struct { // The secret ID. @@ -245,6 +355,15 @@ func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a DeleteServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "SecretId": types.StringType, + "ServicePrincipalId": types.Int64Type, + }, + } +} + type GetCustomAppIntegrationOutput struct { // The client id of the custom OAuth app ClientId types.String `tfsdk:"client_id" tf:"optional"` @@ -266,7 +385,7 @@ type GetCustomAppIntegrationOutput struct { Scopes types.List `tfsdk:"scopes" tf:"optional"` // Token access policy - TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.List `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetCustomAppIntegrationOutput) { @@ -277,12 +396,33 @@ func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(exi func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(""), - "Scopes": reflect.TypeOf(""), + "RedirectUrls": reflect.TypeOf(types.StringType), + "Scopes": reflect.TypeOf(types.StringType), "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), } } +func (a GetCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClientId": types.StringType, + "Confidential": types.BoolType, + "CreateTime": types.StringType, + "CreatedBy": types.Int64Type, + "CreatorUsername": types.StringType, + "IntegrationId": types.StringType, + "Name": types.StringType, + "RedirectUrls": basetypes.ListType{ + ElemType: types.StringType, + }, + "Scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + }, + } +} + // Get OAuth Custom App Integration type GetCustomAppIntegrationRequest struct { // The OAuth app integration ID. @@ -299,6 +439,14 @@ func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a GetCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + }, + } +} + type GetCustomAppIntegrationsOutput struct { // List of Custom OAuth App Integrations defined for the account. Apps types.List `tfsdk:"apps" tf:"optional"` @@ -318,6 +466,17 @@ func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflec } } +func (a GetCustomAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Apps": basetypes.ListType{ + ElemType: GetCustomAppIntegrationOutput{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type GetPublishedAppIntegrationOutput struct { // App-id of the published app integration AppId types.String `tfsdk:"app_id" tf:"optional"` @@ -330,7 +489,7 @@ type GetPublishedAppIntegrationOutput struct { // Display name of the published OAuth app Name types.String `tfsdk:"name" tf:"optional"` // Token access policy - TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.List `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetPublishedAppIntegrationOutput) { @@ -345,6 +504,19 @@ func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]refl } } +func (a GetPublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppId": types.StringType, + "CreateTime": types.StringType, + "CreatedBy": types.Int64Type, + "IntegrationId": types.StringType, + "Name": types.StringType, + "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + }, + } +} + // Get OAuth Published App Integration type GetPublishedAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -360,6 +532,14 @@ func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetPublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + }, + } +} + type GetPublishedAppIntegrationsOutput struct { // List of Published OAuth App Integrations defined for the account. Apps types.List `tfsdk:"apps" tf:"optional"` @@ -379,6 +559,17 @@ func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes() map[string]ref } } +func (a GetPublishedAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Apps": basetypes.ListType{ + ElemType: GetPublishedAppIntegrationOutput{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + type GetPublishedAppsOutput struct { // List of Published OAuth Apps. Apps types.List `tfsdk:"apps" tf:"optional"` @@ -399,6 +590,17 @@ func (a GetPublishedAppsOutput) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetPublishedAppsOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Apps": basetypes.ListType{ + ElemType: PublishedAppOutput{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // Get custom oauth app integrations type ListCustomAppIntegrationsRequest struct { IncludeCreatorUsername types.Bool `tfsdk:"-"` @@ -418,6 +620,16 @@ func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a ListCustomAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeCreatorUsername": types.BoolType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + // Get all the published OAuth apps type ListOAuthPublishedAppsRequest struct { // The max number of OAuth published apps to return in one page. @@ -436,6 +648,15 @@ func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a ListOAuthPublishedAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + // Get published oauth app integrations type ListPublishedAppIntegrationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -453,6 +674,15 @@ func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a ListPublishedAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + // List service principal secrets type ListServicePrincipalSecretsRequest struct { // An opaque page token which was the `next_page_token` in the response of @@ -479,6 +709,15 @@ func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a ListServicePrincipalSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageToken": types.StringType, + "ServicePrincipalId": types.Int64Type, + }, + } +} + type ListServicePrincipalSecretsResponse struct { // A token, which can be sent as `page_token` to retrieve the next page. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -498,6 +737,17 @@ func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes() map[string]r } } +func (a ListServicePrincipalSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Secrets": basetypes.ListType{ + ElemType: SecretInfo{}.ToAttrType(ctx), + }, + }, + } +} + type PublishedAppOutput struct { // Unique ID of the published OAuth app. AppId types.String `tfsdk:"app_id" tf:"optional"` @@ -525,8 +775,26 @@ func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringRead(existingState func (a PublishedAppOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(""), - "Scopes": reflect.TypeOf(""), + "RedirectUrls": reflect.TypeOf(types.StringType), + "Scopes": reflect.TypeOf(types.StringType), + } +} + +func (a PublishedAppOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AppId": types.StringType, + "ClientId": types.StringType, + "Description": types.StringType, + "IsConfidentialClient": types.BoolType, + "Name": types.StringType, + "RedirectUrls": basetypes.ListType{ + ElemType: types.StringType, + }, + "Scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -553,6 +821,18 @@ func (a SecretInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SecretInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "Id": types.StringType, + "SecretHash": types.StringType, + "Status": types.StringType, + "UpdateTime": types.StringType, + }, + } +} + type TokenAccessPolicy struct { // access token time to live in minutes AccessTokenTtlInMinutes types.Int64 `tfsdk:"access_token_ttl_in_minutes" tf:"optional"` @@ -570,13 +850,22 @@ func (a TokenAccessPolicy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TokenAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessTokenTtlInMinutes": types.Int64Type, + "RefreshTokenTtlInMinutes": types.Int64Type, + }, + } +} + type UpdateCustomAppIntegration struct { IntegrationId types.String `tfsdk:"-"` // List of OAuth redirect urls to be updated in the custom OAuth app // integration RedirectUrls types.List `tfsdk:"redirect_urls" tf:"optional"` // Token access policy to be updated in the custom OAuth app integration - TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.List `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCustomAppIntegration) { @@ -587,11 +876,23 @@ func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existi func (a UpdateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(""), + "RedirectUrls": reflect.TypeOf(types.StringType), "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), } } +func (a UpdateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + "RedirectUrls": basetypes.ListType{ + ElemType: types.StringType, + }, + "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + }, + } +} + type UpdateCustomAppIntegrationOutput struct { } @@ -605,10 +906,16 @@ func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a UpdateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdatePublishedAppIntegration struct { IntegrationId types.String `tfsdk:"-"` // Token access policy to be updated in the published OAuth app integration - TokenAccessPolicy types.Object `tfsdk:"token_access_policy" tf:"optional,object"` + TokenAccessPolicy types.List `tfsdk:"token_access_policy" tf:"optional,object"` } func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdatePublishedAppIntegration) { @@ -623,6 +930,15 @@ func (a UpdatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect } } +func (a UpdatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationId": types.StringType, + "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + }, + } +} + type UpdatePublishedAppIntegrationOutput struct { } @@ -635,3 +951,9 @@ func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRe func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a UpdatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 876e969be4..64a62752b8 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -11,10 +11,14 @@ We use go-native types for lists and maps intentionally for the ease for convert package pipelines_tf import ( + "context" "reflect" "github.com/databricks/databricks-sdk-go/service/compute" + "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type CreatePipeline struct { @@ -38,7 +42,7 @@ type CreatePipeline struct { // Whether the pipeline is continuous or triggered. This replaces `trigger`. Continuous types.Bool `tfsdk:"continuous" tf:"optional"` // Deployment type of this pipeline. - Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` + Deployment types.List `tfsdk:"deployment" tf:"optional,object"` // Whether the pipeline is in Development mode. Defaults to false. Development types.Bool `tfsdk:"development" tf:"optional"` @@ -46,14 +50,14 @@ type CreatePipeline struct { // Pipeline product edition. Edition types.String `tfsdk:"edition" tf:"optional"` // Filters on which Pipeline packages to include in the deployed graph. - Filters types.Object `tfsdk:"filters" tf:"optional,object"` + Filters types.List `tfsdk:"filters" tf:"optional,object"` // The definition of a gateway pipeline to support change data capture. - GatewayDefinition types.Object `tfsdk:"gateway_definition" tf:"optional,object"` + GatewayDefinition types.List `tfsdk:"gateway_definition" tf:"optional,object"` // Unique identifier for this pipeline. Id types.String `tfsdk:"id" tf:"optional"` // The configuration for a managed ingestion pipeline. These settings cannot // be used with the 'libraries', 'target' or 'catalog' settings. - IngestionDefinition types.Object `tfsdk:"ingestion_definition" tf:"optional,object"` + IngestionDefinition types.List `tfsdk:"ingestion_definition" tf:"optional,object"` // Libraries or code needed by this deployment. Libraries types.List `tfsdk:"libraries" tf:"optional"` // Friendly identifier for this pipeline. @@ -63,7 +67,7 @@ type CreatePipeline struct { // Whether Photon is enabled for this pipeline. Photon types.Bool `tfsdk:"photon" tf:"optional"` // Restart window of this pipeline. - RestartWindow types.Object `tfsdk:"restart_window" tf:"optional,object"` + RestartWindow types.List `tfsdk:"restart_window" tf:"optional,object"` // The default schema (database) where tables are read from or published to. // The presence of this field implies that the pipeline is in direct // publishing mode. @@ -77,7 +81,7 @@ type CreatePipeline struct { // To publish to Unity Catalog, also specify `catalog`. Target types.String `tfsdk:"target" tf:"optional"` // Which pipeline trigger to use. Deprecated: Use `continuous` instead. - Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` + Trigger types.List `tfsdk:"trigger" tf:"optional,object"` } func (newState *CreatePipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreatePipeline) { @@ -89,7 +93,7 @@ func (newState *CreatePipeline) SyncEffectiveFieldsDuringRead(existingState Crea func (a CreatePipeline) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Clusters": reflect.TypeOf(PipelineCluster{}), - "Configuration": reflect.TypeOf(""), + "Configuration": reflect.TypeOf(types.StringType), "Deployment": reflect.TypeOf(PipelineDeployment{}), "Filters": reflect.TypeOf(Filters{}), "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), @@ -101,9 +105,49 @@ func (a CreatePipeline) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreatePipeline) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowDuplicateNames": types.BoolType, + "BudgetPolicyId": types.StringType, + "Catalog": types.StringType, + "Channel": types.StringType, + "Clusters": basetypes.ListType{ + ElemType: PipelineCluster{}.ToAttrType(ctx), + }, + "Configuration": basetypes.MapType{ + ElemType: types.StringType, + }, + "Continuous": types.BoolType, + "Deployment": PipelineDeployment{}.ToAttrType(ctx), + "Development": types.BoolType, + "DryRun": types.BoolType, + "Edition": types.StringType, + "Filters": Filters{}.ToAttrType(ctx), + "GatewayDefinition": IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + "Id": types.StringType, + "IngestionDefinition": IngestionPipelineDefinition{}.ToAttrType(ctx), + "Libraries": basetypes.ListType{ + ElemType: PipelineLibrary{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "Notifications": basetypes.ListType{ + ElemType: Notifications{}.ToAttrType(ctx), + }, + "Photon": types.BoolType, + "RestartWindow": RestartWindow{}.ToAttrType(ctx), + "Schema": types.StringType, + "Serverless": types.BoolType, + "Storage": types.StringType, + "Target": types.StringType, + "Trigger": PipelineTrigger{}.ToAttrType(ctx), + }, + } +} + type CreatePipelineResponse struct { // Only returned when dry_run is true. - EffectiveSettings types.Object `tfsdk:"effective_settings" tf:"optional,object"` + EffectiveSettings types.List `tfsdk:"effective_settings" tf:"optional,object"` // The unique identifier for the newly created pipeline. Only returned when // dry_run is false. PipelineId types.String `tfsdk:"pipeline_id" tf:"optional"` @@ -121,6 +165,15 @@ func (a CreatePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreatePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EffectiveSettings": PipelineSpec{}.ToAttrType(ctx), + "PipelineId": types.StringType, + }, + } +} + type CronTrigger struct { QuartzCronSchedule types.String `tfsdk:"quartz_cron_schedule" tf:"optional"` @@ -137,6 +190,15 @@ func (a CronTrigger) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CronTrigger) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QuartzCronSchedule": types.StringType, + "TimezoneId": types.StringType, + }, + } +} + type DataPlaneId struct { // The instance name of the data plane emitting an event. Instance types.String `tfsdk:"instance" tf:"optional"` @@ -154,6 +216,15 @@ func (a DataPlaneId) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DataPlaneId) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Instance": types.StringType, + "SeqNo": types.Int64Type, + }, + } +} + // Delete a pipeline type DeletePipelineRequest struct { PipelineId types.String `tfsdk:"-"` @@ -169,6 +240,14 @@ func (a DeletePipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeletePipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PipelineId": types.StringType, + }, + } +} + type DeletePipelineResponse struct { } @@ -182,6 +261,12 @@ func (a DeletePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeletePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EditPipeline struct { // If false, deployment will fail if name has changed and conflicts the name // of another pipeline. @@ -203,7 +288,7 @@ type EditPipeline struct { // Whether the pipeline is continuous or triggered. This replaces `trigger`. Continuous types.Bool `tfsdk:"continuous" tf:"optional"` // Deployment type of this pipeline. - Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` + Deployment types.List `tfsdk:"deployment" tf:"optional,object"` // Whether the pipeline is in Development mode. Defaults to false. Development types.Bool `tfsdk:"development" tf:"optional"` // Pipeline product edition. @@ -213,14 +298,14 @@ type EditPipeline struct { // will fail with a conflict. ExpectedLastModified types.Int64 `tfsdk:"expected_last_modified" tf:"optional"` // Filters on which Pipeline packages to include in the deployed graph. - Filters types.Object `tfsdk:"filters" tf:"optional,object"` + Filters types.List `tfsdk:"filters" tf:"optional,object"` // The definition of a gateway pipeline to support change data capture. - GatewayDefinition types.Object `tfsdk:"gateway_definition" tf:"optional,object"` + GatewayDefinition types.List `tfsdk:"gateway_definition" tf:"optional,object"` // Unique identifier for this pipeline. Id types.String `tfsdk:"id" tf:"optional"` // The configuration for a managed ingestion pipeline. These settings cannot // be used with the 'libraries', 'target' or 'catalog' settings. - IngestionDefinition types.Object `tfsdk:"ingestion_definition" tf:"optional,object"` + IngestionDefinition types.List `tfsdk:"ingestion_definition" tf:"optional,object"` // Libraries or code needed by this deployment. Libraries types.List `tfsdk:"libraries" tf:"optional"` // Friendly identifier for this pipeline. @@ -232,7 +317,7 @@ type EditPipeline struct { // Unique identifier for this pipeline. PipelineId types.String `tfsdk:"pipeline_id" tf:"optional"` // Restart window of this pipeline. - RestartWindow types.Object `tfsdk:"restart_window" tf:"optional,object"` + RestartWindow types.List `tfsdk:"restart_window" tf:"optional,object"` // The default schema (database) where tables are read from or published to. // The presence of this field implies that the pipeline is in direct // publishing mode. @@ -246,7 +331,7 @@ type EditPipeline struct { // To publish to Unity Catalog, also specify `catalog`. Target types.String `tfsdk:"target" tf:"optional"` // Which pipeline trigger to use. Deprecated: Use `continuous` instead. - Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` + Trigger types.List `tfsdk:"trigger" tf:"optional,object"` } func (newState *EditPipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditPipeline) { @@ -258,7 +343,7 @@ func (newState *EditPipeline) SyncEffectiveFieldsDuringRead(existingState EditPi func (a EditPipeline) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Clusters": reflect.TypeOf(PipelineCluster{}), - "Configuration": reflect.TypeOf(""), + "Configuration": reflect.TypeOf(types.StringType), "Deployment": reflect.TypeOf(PipelineDeployment{}), "Filters": reflect.TypeOf(Filters{}), "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), @@ -270,6 +355,47 @@ func (a EditPipeline) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EditPipeline) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowDuplicateNames": types.BoolType, + "BudgetPolicyId": types.StringType, + "Catalog": types.StringType, + "Channel": types.StringType, + "Clusters": basetypes.ListType{ + ElemType: PipelineCluster{}.ToAttrType(ctx), + }, + "Configuration": basetypes.MapType{ + ElemType: types.StringType, + }, + "Continuous": types.BoolType, + "Deployment": PipelineDeployment{}.ToAttrType(ctx), + "Development": types.BoolType, + "Edition": types.StringType, + "ExpectedLastModified": types.Int64Type, + "Filters": Filters{}.ToAttrType(ctx), + "GatewayDefinition": IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + "Id": types.StringType, + "IngestionDefinition": IngestionPipelineDefinition{}.ToAttrType(ctx), + "Libraries": basetypes.ListType{ + ElemType: PipelineLibrary{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "Notifications": basetypes.ListType{ + ElemType: Notifications{}.ToAttrType(ctx), + }, + "Photon": types.BoolType, + "PipelineId": types.StringType, + "RestartWindow": RestartWindow{}.ToAttrType(ctx), + "Schema": types.StringType, + "Serverless": types.BoolType, + "Storage": types.StringType, + "Target": types.StringType, + "Trigger": PipelineTrigger{}.ToAttrType(ctx), + }, + } +} + type EditPipelineResponse struct { } @@ -283,6 +409,12 @@ func (a EditPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EditPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ErrorDetail struct { // The exception thrown for this error, with its chain of cause. Exceptions types.List `tfsdk:"exceptions" tf:"optional"` @@ -302,6 +434,17 @@ func (a ErrorDetail) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ErrorDetail) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exceptions": basetypes.ListType{ + ElemType: SerializedException{}.ToAttrType(ctx), + }, + "Fatal": types.BoolType, + }, + } +} + type FileLibrary struct { // The absolute path of the file. Path types.String `tfsdk:"path" tf:"optional"` @@ -317,6 +460,14 @@ func (a FileLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FileLibrary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + type Filters struct { // Paths to exclude. Exclude types.List `tfsdk:"exclude" tf:"optional"` @@ -332,8 +483,21 @@ func (newState *Filters) SyncEffectiveFieldsDuringRead(existingState Filters) { func (a Filters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exclude": reflect.TypeOf(""), - "Include": reflect.TypeOf(""), + "Exclude": reflect.TypeOf(types.StringType), + "Include": reflect.TypeOf(types.StringType), + } +} + +func (a Filters) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Exclude": basetypes.ListType{ + ElemType: types.StringType, + }, + "Include": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -353,6 +517,14 @@ func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a GetPipelinePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PipelineId": types.StringType, + }, + } +} + type GetPipelinePermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -370,6 +542,16 @@ func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes() map[string]r } } +func (a GetPipelinePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: PipelinePermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get pipeline permissions type GetPipelinePermissionsRequest struct { // The pipeline for which to get or manage permissions. @@ -386,6 +568,14 @@ func (a GetPipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetPipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PipelineId": types.StringType, + }, + } +} + // Get a pipeline type GetPipelineRequest struct { PipelineId types.String `tfsdk:"-"` @@ -401,6 +591,14 @@ func (a GetPipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetPipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PipelineId": types.StringType, + }, + } +} + type GetPipelineResponse struct { // An optional message detailing the cause of the pipeline state. Cause types.String `tfsdk:"cause" tf:"optional"` @@ -425,7 +623,7 @@ type GetPipelineResponse struct { RunAsUserName types.String `tfsdk:"run_as_user_name" tf:"optional"` // The pipeline specification. This field is not returned when called by // `ListPipelines`. - Spec types.Object `tfsdk:"spec" tf:"optional,object"` + Spec types.List `tfsdk:"spec" tf:"optional,object"` // The pipeline state. State types.String `tfsdk:"state" tf:"optional"` } @@ -443,6 +641,27 @@ func (a GetPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cause": types.StringType, + "ClusterId": types.StringType, + "CreatorUserName": types.StringType, + "EffectiveBudgetPolicyId": types.StringType, + "Health": types.StringType, + "LastModified": types.Int64Type, + "LatestUpdates": basetypes.ListType{ + ElemType: UpdateStateInfo{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "PipelineId": types.StringType, + "RunAsUserName": types.StringType, + "Spec": PipelineSpec{}.ToAttrType(ctx), + "State": types.StringType, + }, + } +} + // Get a pipeline update type GetUpdateRequest struct { // The ID of the pipeline. @@ -461,9 +680,18 @@ func (a GetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PipelineId": types.StringType, + "UpdateId": types.StringType, + }, + } +} + type GetUpdateResponse struct { // The current update info. - Update types.Object `tfsdk:"update" tf:"optional,object"` + Update types.List `tfsdk:"update" tf:"optional,object"` } func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetUpdateResponse) { @@ -478,13 +706,21 @@ func (a GetUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Update": UpdateInfo{}.ToAttrType(ctx), + }, + } +} + type IngestionConfig struct { // Select a specific source report. - Report types.Object `tfsdk:"report" tf:"optional,object"` + Report types.List `tfsdk:"report" tf:"optional,object"` // Select all tables from a specific source schema. - Schema types.Object `tfsdk:"schema" tf:"optional,object"` + Schema types.List `tfsdk:"schema" tf:"optional,object"` // Select a specific source table. - Table types.Object `tfsdk:"table" tf:"optional,object"` + Table types.List `tfsdk:"table" tf:"optional,object"` } func (newState *IngestionConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan IngestionConfig) { @@ -501,6 +737,16 @@ func (a IngestionConfig) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a IngestionConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Report": ReportSpec{}.ToAttrType(ctx), + "Schema": SchemaSpec{}.ToAttrType(ctx), + "Table": TableSpec{}.ToAttrType(ctx), + }, + } +} + type IngestionGatewayPipelineDefinition struct { // [Deprecated, use connection_name instead] Immutable. The Unity Catalog // connection that this gateway pipeline uses to communicate with the @@ -532,6 +778,18 @@ func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a IngestionGatewayPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConnectionId": types.StringType, + "ConnectionName": types.StringType, + "GatewayStorageCatalog": types.StringType, + "GatewayStorageName": types.StringType, + "GatewayStorageSchema": types.StringType, + }, + } +} + type IngestionPipelineDefinition struct { // Immutable. The Unity Catalog connection that this ingestion pipeline uses // to communicate with the source. This is used with connectors for @@ -546,7 +804,7 @@ type IngestionPipelineDefinition struct { Objects types.List `tfsdk:"objects" tf:"optional"` // Configuration settings to control the ingestion of tables. These settings // are applied to all tables in the pipeline. - TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.List `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringCreateOrUpdate(plan IngestionPipelineDefinition) { @@ -562,6 +820,19 @@ func (a IngestionPipelineDefinition) GetComplexFieldTypes() map[string]reflect.T } } +func (a IngestionPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConnectionName": types.StringType, + "IngestionGatewayId": types.StringType, + "Objects": basetypes.ListType{ + ElemType: IngestionConfig{}.ToAttrType(ctx), + }, + "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + }, + } +} + // List pipeline events type ListPipelineEventsRequest struct { // Criteria to select a subset of results, expressed using a SQL-like @@ -597,7 +868,21 @@ func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringRead(existin func (a ListPipelineEventsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(""), + "OrderBy": reflect.TypeOf(types.StringType), + } +} + +func (a ListPipelineEventsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": types.StringType, + "MaxResults": types.Int64Type, + "OrderBy": basetypes.ListType{ + ElemType: types.StringType, + }, + "PageToken": types.StringType, + "PipelineId": types.StringType, + }, } } @@ -622,6 +907,18 @@ func (a ListPipelineEventsResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ListPipelineEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Events": basetypes.ListType{ + ElemType: PipelineEvent{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + }, + } +} + // List pipelines type ListPipelinesRequest struct { // Select a subset of results based on the specified criteria. The supported @@ -655,7 +952,20 @@ func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringRead(existingStat func (a ListPipelinesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(""), + "OrderBy": reflect.TypeOf(types.StringType), + } +} + +func (a ListPipelinesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Filter": types.StringType, + "MaxResults": types.Int64Type, + "OrderBy": basetypes.ListType{ + ElemType: types.StringType, + }, + "PageToken": types.StringType, + }, } } @@ -678,6 +988,17 @@ func (a ListPipelinesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListPipelinesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Statuses": basetypes.ListType{ + ElemType: PipelineStateInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List pipeline updates type ListUpdatesRequest struct { // Max number of entries to return in a single page. @@ -700,6 +1021,17 @@ func (a ListUpdatesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListUpdatesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + "PipelineId": types.StringType, + "UntilUpdateId": types.StringType, + }, + } +} + type ListUpdatesResponse struct { // If present, then there are more results, and this a token to be used in a // subsequent request to fetch the next page. @@ -723,6 +1055,18 @@ func (a ListUpdatesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListUpdatesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "PrevPageToken": types.StringType, + "Updates": basetypes.ListType{ + ElemType: UpdateInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ManualTrigger struct { } @@ -736,6 +1080,12 @@ func (a ManualTrigger) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ManualTrigger) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type NotebookLibrary struct { // The absolute path of the notebook. Path types.String `tfsdk:"path" tf:"optional"` @@ -751,6 +1101,14 @@ func (a NotebookLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NotebookLibrary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + type Notifications struct { // A list of alerts that trigger the sending of notifications to the // configured destinations. The supported alerts are: @@ -772,8 +1130,21 @@ func (newState *Notifications) SyncEffectiveFieldsDuringRead(existingState Notif func (a Notifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Alerts": reflect.TypeOf(""), - "EmailRecipients": reflect.TypeOf(""), + "Alerts": reflect.TypeOf(types.StringType), + "EmailRecipients": reflect.TypeOf(types.StringType), + } +} + +func (a Notifications) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alerts": basetypes.ListType{ + ElemType: types.StringType, + }, + "EmailRecipients": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -825,6 +1196,30 @@ func (a Origin) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Origin) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BatchId": types.Int64Type, + "Cloud": types.StringType, + "ClusterId": types.StringType, + "DatasetName": types.StringType, + "FlowId": types.StringType, + "FlowName": types.StringType, + "Host": types.StringType, + "MaintenanceId": types.StringType, + "MaterializationName": types.StringType, + "OrgId": types.Int64Type, + "PipelineId": types.StringType, + "PipelineName": types.StringType, + "Region": types.StringType, + "RequestId": types.StringType, + "TableId": types.StringType, + "UcResourceId": types.StringType, + "UpdateId": types.StringType, + }, + } +} + type PipelineAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -846,6 +1241,17 @@ func (a PipelineAccessControlRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a PipelineAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type PipelineAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -871,6 +1277,20 @@ func (a PipelineAccessControlResponse) GetComplexFieldTypes() map[string]reflect } } +func (a PipelineAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: PipelinePermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type PipelineCluster struct { // Note: This field won't be persisted. Only API users will check this // field. @@ -878,7 +1298,7 @@ type PipelineCluster struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 // or later. - Autoscale types.Object `tfsdk:"autoscale" tf:"optional,object"` + Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. AwsAttributes compute.AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` @@ -980,12 +1400,48 @@ func (a PipelineCluster) GetComplexFieldTypes() map[string]reflect.Type { "AwsAttributes": reflect.TypeOf(compute.AwsAttributes{}), "AzureAttributes": reflect.TypeOf(compute.AzureAttributes{}), "ClusterLogConf": reflect.TypeOf(compute.ClusterLogConf{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "GcpAttributes": reflect.TypeOf(compute.GcpAttributes{}), "InitScripts": reflect.TypeOf(compute.InitScriptInfo{}), - "SparkConf": reflect.TypeOf(""), - "SparkEnvVars": reflect.TypeOf(""), - "SshPublicKeys": reflect.TypeOf(""), + "SparkConf": reflect.TypeOf(types.StringType), + "SparkEnvVars": reflect.TypeOf(types.StringType), + "SshPublicKeys": reflect.TypeOf(types.StringType), + } +} + +func (a PipelineCluster) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyPolicyDefaultValues": types.BoolType, + "Autoscale": PipelineClusterAutoscale{}.ToAttrType(ctx), + "AwsAttributes": compute_tf.AwsAttributes{}.ToAttrType(ctx), + "AzureAttributes": compute_tf.AzureAttributes{}.ToAttrType(ctx), + "ClusterLogConf": compute_tf.ClusterLogConf{}.ToAttrType(ctx), + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DriverInstancePoolId": types.StringType, + "DriverNodeTypeId": types.StringType, + "EnableLocalDiskEncryption": types.BoolType, + "GcpAttributes": compute_tf.GcpAttributes{}.ToAttrType(ctx), + "InitScripts": basetypes.ListType{ + ElemType: compute_tf.InitScriptInfo{}.ToAttrType(ctx), + }, + "InstancePoolId": types.StringType, + "Label": types.StringType, + "NodeTypeId": types.StringType, + "NumWorkers": types.Int64Type, + "PolicyId": types.StringType, + "SparkConf": basetypes.MapType{ + ElemType: types.StringType, + }, + "SparkEnvVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "SshPublicKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1015,6 +1471,16 @@ func (a PipelineClusterAutoscale) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a PipelineClusterAutoscale) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxWorkers": types.Int64Type, + "MinWorkers": types.Int64Type, + "Mode": types.StringType, + }, + } +} + type PipelineDeployment struct { // The deployment method that manages the pipeline. Kind types.String `tfsdk:"kind" tf:"optional"` @@ -1032,9 +1498,18 @@ func (a PipelineDeployment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PipelineDeployment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Kind": types.StringType, + "MetadataFilePath": types.StringType, + }, + } +} + type PipelineEvent struct { // Information about an error captured by the event. - Error types.Object `tfsdk:"error" tf:"optional,object"` + Error types.List `tfsdk:"error" tf:"optional,object"` // The event type. Should always correspond to the details EventType types.String `tfsdk:"event_type" tf:"optional"` // A time-based, globally unique id. @@ -1046,9 +1521,9 @@ type PipelineEvent struct { // The display message associated with the event. Message types.String `tfsdk:"message" tf:"optional"` // Describes where the event originates from. - Origin types.Object `tfsdk:"origin" tf:"optional,object"` + Origin types.List `tfsdk:"origin" tf:"optional,object"` // A sequencing object to identify and order events. - Sequence types.Object `tfsdk:"sequence" tf:"optional,object"` + Sequence types.List `tfsdk:"sequence" tf:"optional,object"` // The time of the event. Timestamp types.String `tfsdk:"timestamp" tf:"optional"` } @@ -1067,17 +1542,33 @@ func (a PipelineEvent) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PipelineEvent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Error": ErrorDetail{}.ToAttrType(ctx), + "EventType": types.StringType, + "Id": types.StringType, + "Level": types.StringType, + "MaturityLevel": types.StringType, + "Message": types.StringType, + "Origin": Origin{}.ToAttrType(ctx), + "Sequence": Sequencing{}.ToAttrType(ctx), + "Timestamp": types.StringType, + }, + } +} + type PipelineLibrary struct { // The path to a file that defines a pipeline and is stored in the // Databricks Repos. - File types.Object `tfsdk:"file" tf:"optional,object"` + File types.List `tfsdk:"file" tf:"optional,object"` // URI of the jar to be installed. Currently only DBFS is supported. Jar types.String `tfsdk:"jar" tf:"optional"` // Specification of a maven library to be installed. Maven compute.MavenLibrary `tfsdk:"maven" tf:"optional,object"` // The path to a notebook that defines a pipeline and is stored in the // Databricks workspace. - Notebook types.Object `tfsdk:"notebook" tf:"optional,object"` + Notebook types.List `tfsdk:"notebook" tf:"optional,object"` // URI of the whl to be installed. Whl types.String `tfsdk:"whl" tf:"optional"` } @@ -1096,6 +1587,18 @@ func (a PipelineLibrary) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PipelineLibrary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "File": FileLibrary{}.ToAttrType(ctx), + "Jar": types.StringType, + "Maven": compute_tf.MavenLibrary{}.ToAttrType(ctx), + "Notebook": NotebookLibrary{}.ToAttrType(ctx), + "Whl": types.StringType, + }, + } +} + type PipelinePermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1112,7 +1615,19 @@ func (newState *PipelinePermission) SyncEffectiveFieldsDuringRead(existingState func (a PipelinePermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a PipelinePermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1136,6 +1651,18 @@ func (a PipelinePermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PipelinePermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: PipelineAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type PipelinePermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1152,6 +1679,15 @@ func (a PipelinePermissionsDescription) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a PipelinePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type PipelinePermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The pipeline for which to get or manage permissions. @@ -1170,6 +1706,17 @@ func (a PipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a PipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: PipelineAccessControlRequest{}.ToAttrType(ctx), + }, + "PipelineId": types.StringType, + }, + } +} + type PipelineSpec struct { // Budget policy of this pipeline. BudgetPolicyId types.String `tfsdk:"budget_policy_id" tf:"optional"` @@ -1188,20 +1735,20 @@ type PipelineSpec struct { // Whether the pipeline is continuous or triggered. This replaces `trigger`. Continuous types.Bool `tfsdk:"continuous" tf:"optional"` // Deployment type of this pipeline. - Deployment types.Object `tfsdk:"deployment" tf:"optional,object"` + Deployment types.List `tfsdk:"deployment" tf:"optional,object"` // Whether the pipeline is in Development mode. Defaults to false. Development types.Bool `tfsdk:"development" tf:"optional"` // Pipeline product edition. Edition types.String `tfsdk:"edition" tf:"optional"` // Filters on which Pipeline packages to include in the deployed graph. - Filters types.Object `tfsdk:"filters" tf:"optional,object"` + Filters types.List `tfsdk:"filters" tf:"optional,object"` // The definition of a gateway pipeline to support change data capture. - GatewayDefinition types.Object `tfsdk:"gateway_definition" tf:"optional,object"` + GatewayDefinition types.List `tfsdk:"gateway_definition" tf:"optional,object"` // Unique identifier for this pipeline. Id types.String `tfsdk:"id" tf:"optional"` // The configuration for a managed ingestion pipeline. These settings cannot // be used with the 'libraries', 'target' or 'catalog' settings. - IngestionDefinition types.Object `tfsdk:"ingestion_definition" tf:"optional,object"` + IngestionDefinition types.List `tfsdk:"ingestion_definition" tf:"optional,object"` // Libraries or code needed by this deployment. Libraries types.List `tfsdk:"libraries" tf:"optional"` // Friendly identifier for this pipeline. @@ -1211,7 +1758,7 @@ type PipelineSpec struct { // Whether Photon is enabled for this pipeline. Photon types.Bool `tfsdk:"photon" tf:"optional"` // Restart window of this pipeline. - RestartWindow types.Object `tfsdk:"restart_window" tf:"optional,object"` + RestartWindow types.List `tfsdk:"restart_window" tf:"optional,object"` // The default schema (database) where tables are read from or published to. // The presence of this field implies that the pipeline is in direct // publishing mode. @@ -1225,7 +1772,7 @@ type PipelineSpec struct { // To publish to Unity Catalog, also specify `catalog`. Target types.String `tfsdk:"target" tf:"optional"` // Which pipeline trigger to use. Deprecated: Use `continuous` instead. - Trigger types.Object `tfsdk:"trigger" tf:"optional,object"` + Trigger types.List `tfsdk:"trigger" tf:"optional,object"` } func (newState *PipelineSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan PipelineSpec) { @@ -1237,7 +1784,7 @@ func (newState *PipelineSpec) SyncEffectiveFieldsDuringRead(existingState Pipeli func (a PipelineSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Clusters": reflect.TypeOf(PipelineCluster{}), - "Configuration": reflect.TypeOf(""), + "Configuration": reflect.TypeOf(types.StringType), "Deployment": reflect.TypeOf(PipelineDeployment{}), "Filters": reflect.TypeOf(Filters{}), "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), @@ -1249,6 +1796,44 @@ func (a PipelineSpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PipelineSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BudgetPolicyId": types.StringType, + "Catalog": types.StringType, + "Channel": types.StringType, + "Clusters": basetypes.ListType{ + ElemType: PipelineCluster{}.ToAttrType(ctx), + }, + "Configuration": basetypes.MapType{ + ElemType: types.StringType, + }, + "Continuous": types.BoolType, + "Deployment": PipelineDeployment{}.ToAttrType(ctx), + "Development": types.BoolType, + "Edition": types.StringType, + "Filters": Filters{}.ToAttrType(ctx), + "GatewayDefinition": IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + "Id": types.StringType, + "IngestionDefinition": IngestionPipelineDefinition{}.ToAttrType(ctx), + "Libraries": basetypes.ListType{ + ElemType: PipelineLibrary{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "Notifications": basetypes.ListType{ + ElemType: Notifications{}.ToAttrType(ctx), + }, + "Photon": types.BoolType, + "RestartWindow": RestartWindow{}.ToAttrType(ctx), + "Schema": types.StringType, + "Serverless": types.BoolType, + "Storage": types.StringType, + "Target": types.StringType, + "Trigger": PipelineTrigger{}.ToAttrType(ctx), + }, + } +} + type PipelineStateInfo struct { // The unique identifier of the cluster running the pipeline. ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` @@ -1282,8 +1867,25 @@ func (a PipelineStateInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PipelineStateInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClusterId": types.StringType, + "CreatorUserName": types.StringType, + "Health": types.StringType, + "LatestUpdates": basetypes.ListType{ + ElemType: UpdateStateInfo{}.ToAttrType(ctx), + }, + "Name": types.StringType, + "PipelineId": types.StringType, + "RunAsUserName": types.StringType, + "State": types.StringType, + }, + } +} + type PipelineTrigger struct { - Cron types.Object `tfsdk:"cron" tf:"optional,object"` + Cron types.List `tfsdk:"cron" tf:"optional,object"` Manual []ManualTrigger `tfsdk:"manual" tf:"optional,object"` } @@ -1301,6 +1903,15 @@ func (a PipelineTrigger) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PipelineTrigger) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cron": CronTrigger{}.ToAttrType(ctx), + "Manual": ManualTrigger{}.ToAttrType(ctx), + }, + } +} + type ReportSpec struct { // Required. Destination catalog to store table. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -1314,7 +1925,7 @@ type ReportSpec struct { // Configuration settings to control the ingestion of tables. These settings // override the table_configuration defined in the // IngestionPipelineDefinition object. - TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.List `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *ReportSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReportSpec) { @@ -1329,6 +1940,18 @@ func (a ReportSpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ReportSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationCatalog": types.StringType, + "DestinationSchema": types.StringType, + "DestinationTable": types.StringType, + "SourceUrl": types.StringType, + "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + }, + } +} + type RestartWindow struct { // Days of week in which the restart is allowed to happen (within a // five-hour window starting at start_hour). If not specified all days of @@ -1354,6 +1977,16 @@ func (a RestartWindow) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestartWindow) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DaysOfWeek": types.StringType, + "StartHour": types.Int64Type, + "TimeZoneId": types.StringType, + }, + } +} + type SchemaSpec struct { // Required. Destination catalog to store tables. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -1369,7 +2002,7 @@ type SchemaSpec struct { // Configuration settings to control the ingestion of tables. These settings // are applied to all tables in this schema and override the // table_configuration defined in the IngestionPipelineDefinition object. - TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.List `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *SchemaSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaSpec) { @@ -1384,11 +2017,23 @@ func (a SchemaSpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SchemaSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationCatalog": types.StringType, + "DestinationSchema": types.StringType, + "SourceCatalog": types.StringType, + "SourceSchema": types.StringType, + "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + }, + } +} + type Sequencing struct { // A sequence number, unique and increasing within the control plane. ControlPlaneSeqNo types.Int64 `tfsdk:"control_plane_seq_no" tf:"optional"` // the ID assigned by the data plane. - DataPlaneId types.Object `tfsdk:"data_plane_id" tf:"optional,object"` + DataPlaneId types.List `tfsdk:"data_plane_id" tf:"optional,object"` } func (newState *Sequencing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sequencing) { @@ -1403,6 +2048,15 @@ func (a Sequencing) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Sequencing) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ControlPlaneSeqNo": types.Int64Type, + "DataPlaneId": DataPlaneId{}.ToAttrType(ctx), + }, + } +} + type SerializedException struct { // Runtime class of the exception ClassName types.String `tfsdk:"class_name" tf:"optional"` @@ -1424,6 +2078,18 @@ func (a SerializedException) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SerializedException) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ClassName": types.StringType, + "Message": types.StringType, + "Stack": basetypes.ListType{ + ElemType: StackFrame{}.ToAttrType(ctx), + }, + }, + } +} + type StackFrame struct { // Class from which the method call originated DeclaringClass types.String `tfsdk:"declaring_class" tf:"optional"` @@ -1445,6 +2111,17 @@ func (a StackFrame) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StackFrame) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DeclaringClass": types.StringType, + "FileName": types.StringType, + "LineNumber": types.Int64Type, + "MethodName": types.StringType, + }, + } +} + type StartUpdate struct { Cause types.String `tfsdk:"cause" tf:"optional"` // If true, this update will reset all tables before running. @@ -1474,8 +2151,25 @@ func (newState *StartUpdate) SyncEffectiveFieldsDuringRead(existingState StartUp func (a StartUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FullRefreshSelection": reflect.TypeOf(""), - "RefreshSelection": reflect.TypeOf(""), + "FullRefreshSelection": reflect.TypeOf(types.StringType), + "RefreshSelection": reflect.TypeOf(types.StringType), + } +} + +func (a StartUpdate) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cause": types.StringType, + "FullRefresh": types.BoolType, + "FullRefreshSelection": basetypes.ListType{ + ElemType: types.StringType, + }, + "PipelineId": types.StringType, + "RefreshSelection": basetypes.ListType{ + ElemType: types.StringType, + }, + "ValidateOnly": types.BoolType, + }, } } @@ -1493,6 +2187,14 @@ func (a StartUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StartUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "UpdateId": types.StringType, + }, + } +} + type StopPipelineResponse struct { } @@ -1506,6 +2208,12 @@ func (a StopPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StopPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Stop a pipeline type StopRequest struct { PipelineId types.String `tfsdk:"-"` @@ -1521,6 +2229,14 @@ func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PipelineId": types.StringType, + }, + } +} + type TableSpec struct { // Required. Destination catalog to store table. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -1539,7 +2255,7 @@ type TableSpec struct { // Configuration settings to control the ingestion of tables. These settings // override the table_configuration defined in the // IngestionPipelineDefinition object and the SchemaSpec. - TableConfiguration types.Object `tfsdk:"table_configuration" tf:"optional,object"` + TableConfiguration types.List `tfsdk:"table_configuration" tf:"optional,object"` } func (newState *TableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableSpec) { @@ -1554,6 +2270,20 @@ func (a TableSpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TableSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationCatalog": types.StringType, + "DestinationSchema": types.StringType, + "DestinationTable": types.StringType, + "SourceCatalog": types.StringType, + "SourceSchema": types.StringType, + "SourceTable": types.StringType, + "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + }, + } +} + type TableSpecificConfig struct { // The primary key of the table used to apply changes. PrimaryKeys types.List `tfsdk:"primary_keys" tf:"optional"` @@ -1576,8 +2306,23 @@ func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringRead(existingState func (a TableSpecificConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrimaryKeys": reflect.TypeOf(""), - "SequenceBy": reflect.TypeOf(""), + "PrimaryKeys": reflect.TypeOf(types.StringType), + "SequenceBy": reflect.TypeOf(types.StringType), + } +} + +func (a TableSpecificConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrimaryKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "SalesforceIncludeFormulaFields": types.BoolType, + "ScdType": types.StringType, + "SequenceBy": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1588,7 +2333,7 @@ type UpdateInfo struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` // The pipeline configuration with system defaults applied where unspecified // by the user. Not returned by ListUpdates. - Config types.Object `tfsdk:"config" tf:"optional,object"` + Config types.List `tfsdk:"config" tf:"optional,object"` // The time when this update was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"optional"` // If true, this update will reset all tables before running. @@ -1623,8 +2368,30 @@ func (newState *UpdateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateIn func (a UpdateInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Config": reflect.TypeOf(PipelineSpec{}), - "FullRefreshSelection": reflect.TypeOf(""), - "RefreshSelection": reflect.TypeOf(""), + "FullRefreshSelection": reflect.TypeOf(types.StringType), + "RefreshSelection": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Cause": types.StringType, + "ClusterId": types.StringType, + "Config": PipelineSpec{}.ToAttrType(ctx), + "CreationTime": types.Int64Type, + "FullRefresh": types.BoolType, + "FullRefreshSelection": basetypes.ListType{ + ElemType: types.StringType, + }, + "PipelineId": types.StringType, + "RefreshSelection": basetypes.ListType{ + ElemType: types.StringType, + }, + "State": types.StringType, + "UpdateId": types.StringType, + "ValidateOnly": types.BoolType, + }, } } @@ -1645,3 +2412,13 @@ func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringRead(existingState Upd func (a UpdateStateInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a UpdateStateInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTime": types.StringType, + "State": types.StringType, + "UpdateId": types.StringType, + }, + } +} diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 8950936ded..dbb72277f9 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -11,13 +11,16 @@ We use go-native types for lists and maps intentionally for the ease for convert package provisioning_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AwsCredentials struct { - StsRole types.Object `tfsdk:"sts_role" tf:"optional,object"` + StsRole types.List `tfsdk:"sts_role" tf:"optional,object"` } func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsCredentials) { @@ -32,6 +35,14 @@ func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StsRole": StsRole{}.ToAttrType(ctx), + }, + } +} + type AwsKeyInfo struct { // The AWS KMS key alias. KeyAlias types.String `tfsdk:"key_alias" tf:"optional"` @@ -56,6 +67,17 @@ func (a AwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "KeyAlias": types.StringType, + "KeyArn": types.StringType, + "KeyRegion": types.StringType, + "ReuseKeyForClusterVolumes": types.BoolType, + }, + } +} + type AzureWorkspaceInfo struct { // Azure Resource Group name ResourceGroup types.String `tfsdk:"resource_group" tf:"optional"` @@ -73,10 +95,19 @@ func (a AzureWorkspaceInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AzureWorkspaceInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ResourceGroup": types.StringType, + "SubscriptionId": types.StringType, + }, + } +} + // The general workspace configurations that are specific to cloud providers. type CloudResourceContainer struct { // The general workspace configurations that are specific to Google Cloud. - Gcp types.Object `tfsdk:"gcp" tf:"optional,object"` + Gcp types.List `tfsdk:"gcp" tf:"optional,object"` } func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringCreateOrUpdate(plan CloudResourceContainer) { @@ -91,6 +122,14 @@ func (a CloudResourceContainer) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Gcp": CustomerFacingGcpCloudResourceContainer{}.ToAttrType(ctx), + }, + } +} + type CreateAwsKeyInfo struct { // The AWS KMS key alias. KeyAlias types.String `tfsdk:"key_alias" tf:"optional"` @@ -114,8 +153,18 @@ func (a CreateAwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateAwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "KeyAlias": types.StringType, + "KeyArn": types.StringType, + "ReuseKeyForClusterVolumes": types.BoolType, + }, + } +} + type CreateCredentialAwsCredentials struct { - StsRole types.Object `tfsdk:"sts_role" tf:"optional,object"` + StsRole types.List `tfsdk:"sts_role" tf:"optional,object"` } func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateCredentialAwsCredentials) { @@ -130,8 +179,16 @@ func (a CreateCredentialAwsCredentials) GetComplexFieldTypes() map[string]reflec } } +func (a CreateCredentialAwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StsRole": CreateCredentialStsRole{}.ToAttrType(ctx), + }, + } +} + type CreateCredentialRequest struct { - AwsCredentials types.Object `tfsdk:"aws_credentials" tf:"object"` + AwsCredentials types.List `tfsdk:"aws_credentials" tf:"object"` // The human-readable name of the credential configuration object. CredentialsName types.String `tfsdk:"credentials_name" tf:""` } @@ -148,6 +205,15 @@ func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsCredentials": CreateCredentialAwsCredentials{}.ToAttrType(ctx), + "CredentialsName": types.StringType, + }, + } +} + type CreateCredentialStsRole struct { // The Amazon Resource Name (ARN) of the cross account role. RoleArn types.String `tfsdk:"role_arn" tf:"optional"` @@ -163,10 +229,18 @@ func (a CreateCredentialStsRole) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CreateCredentialStsRole) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RoleArn": types.StringType, + }, + } +} + type CreateCustomerManagedKeyRequest struct { - AwsKeyInfo types.Object `tfsdk:"aws_key_info" tf:"optional,object"` + AwsKeyInfo types.List `tfsdk:"aws_key_info" tf:"optional,object"` - GcpKeyInfo types.Object `tfsdk:"gcp_key_info" tf:"optional,object"` + GcpKeyInfo types.List `tfsdk:"gcp_key_info" tf:"optional,object"` // The cases that the key can be used for. UseCases types.List `tfsdk:"use_cases" tf:""` } @@ -181,7 +255,19 @@ func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{ "AwsKeyInfo": reflect.TypeOf(CreateAwsKeyInfo{}), "GcpKeyInfo": reflect.TypeOf(CreateGcpKeyInfo{}), - "UseCases": reflect.TypeOf(""), + "UseCases": reflect.TypeOf(types.StringType), + } +} + +func (a CreateCustomerManagedKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsKeyInfo": CreateAwsKeyInfo{}.ToAttrType(ctx), + "GcpKeyInfo": CreateGcpKeyInfo{}.ToAttrType(ctx), + "UseCases": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -200,10 +286,18 @@ func (a CreateGcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateGcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "KmsKeyId": types.StringType, + }, + } +} + type CreateNetworkRequest struct { // The Google Cloud specific information for this network (for example, the // VPC ID, subnet ID, and secondary IP ranges). - GcpNetworkInfo types.Object `tfsdk:"gcp_network_info" tf:"optional,object"` + GcpNetworkInfo types.List `tfsdk:"gcp_network_info" tf:"optional,object"` // The human-readable name of the network configuration. NetworkName types.String `tfsdk:"network_name" tf:""` // IDs of one to five security groups associated with this network. Security @@ -216,7 +310,7 @@ type CreateNetworkRequest struct { // communication from this VPC over [AWS PrivateLink]. // // [AWS PrivateLink]: https://aws.amazon.com/privatelink/ - VpcEndpoints types.Object `tfsdk:"vpc_endpoints" tf:"optional,object"` + VpcEndpoints types.List `tfsdk:"vpc_endpoints" tf:"optional,object"` // The ID of the VPC associated with this network. VPC IDs can be used in // multiple network configurations. VpcId types.String `tfsdk:"vpc_id" tf:"optional"` @@ -231,15 +325,32 @@ func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringRead(existingStat func (a CreateNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "GcpNetworkInfo": reflect.TypeOf(GcpNetworkInfo{}), - "SecurityGroupIds": reflect.TypeOf(""), - "SubnetIds": reflect.TypeOf(""), + "SecurityGroupIds": reflect.TypeOf(types.StringType), + "SubnetIds": reflect.TypeOf(types.StringType), "VpcEndpoints": reflect.TypeOf(NetworkVpcEndpoints{}), } } +func (a CreateNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GcpNetworkInfo": GcpNetworkInfo{}.ToAttrType(ctx), + "NetworkName": types.StringType, + "SecurityGroupIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "SubnetIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "VpcEndpoints": NetworkVpcEndpoints{}.ToAttrType(ctx), + "VpcId": types.StringType, + }, + } +} + type CreateStorageConfigurationRequest struct { // Root S3 bucket information. - RootBucketInfo types.Object `tfsdk:"root_bucket_info" tf:"object"` + RootBucketInfo types.List `tfsdk:"root_bucket_info" tf:"object"` // The human-readable name of the storage configuration. StorageConfigurationName types.String `tfsdk:"storage_configuration_name" tf:""` } @@ -256,12 +367,21 @@ func (a CreateStorageConfigurationRequest) GetComplexFieldTypes() map[string]ref } } +func (a CreateStorageConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RootBucketInfo": RootBucketInfo{}.ToAttrType(ctx), + "StorageConfigurationName": types.StringType, + }, + } +} + type CreateVpcEndpointRequest struct { // The ID of the VPC endpoint object in AWS. AwsVpcEndpointId types.String `tfsdk:"aws_vpc_endpoint_id" tf:"optional"` // The Google Cloud specific information for this Private Service Connect // endpoint. - GcpVpcEndpointInfo types.Object `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` + GcpVpcEndpointInfo types.List `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` // The AWS region in which this VPC endpoint object exists. Region types.String `tfsdk:"region" tf:"optional"` // The human-readable name of the storage configuration. @@ -280,6 +400,17 @@ func (a CreateVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsVpcEndpointId": types.StringType, + "GcpVpcEndpointInfo": GcpVpcEndpointInfo{}.ToAttrType(ctx), + "Region": types.StringType, + "VpcEndpointName": types.StringType, + }, + } +} + type CreateWorkspaceRequest struct { // The AWS region of the workspace's data plane. AwsRegion types.String `tfsdk:"aws_region" tf:"optional"` @@ -288,7 +419,7 @@ type CreateWorkspaceRequest struct { Cloud types.String `tfsdk:"cloud" tf:"optional"` // The general workspace configurations that are specific to cloud // providers. - CloudResourceContainer types.Object `tfsdk:"cloud_resource_container" tf:"optional,object"` + CloudResourceContainer types.List `tfsdk:"cloud_resource_container" tf:"optional,object"` // ID of the workspace's credential configuration object. CredentialsId types.String `tfsdk:"credentials_id" tf:"optional"` // The custom tags key-value pairing that is attached to this workspace. The @@ -349,9 +480,9 @@ type CreateWorkspaceRequest struct { // for a new workspace]. // // [calculate subnet sizes for a new workspace]: https://docs.gcp.databricks.com/administration-guide/cloud-configurations/gcp/network-sizing.html - GcpManagedNetworkConfig types.Object `tfsdk:"gcp_managed_network_config" tf:"optional,object"` + GcpManagedNetworkConfig types.List `tfsdk:"gcp_managed_network_config" tf:"optional,object"` // The configurations for the GKE cluster of a Databricks workspace. - GkeConfig types.Object `tfsdk:"gke_config" tf:"optional,object"` + GkeConfig types.List `tfsdk:"gke_config" tf:"optional,object"` // Whether no public IP is enabled for the workspace. IsNoPublicIpEnabled types.Bool `tfsdk:"is_no_public_ip_enabled" tf:"optional"` // The Google Cloud region of the workspace data plane in your Google @@ -402,17 +533,43 @@ func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingSt func (a CreateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "CloudResourceContainer": reflect.TypeOf(CloudResourceContainer{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "GcpManagedNetworkConfig": reflect.TypeOf(GcpManagedNetworkConfig{}), "GkeConfig": reflect.TypeOf(GkeConfig{}), } } +func (a CreateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsRegion": types.StringType, + "Cloud": types.StringType, + "CloudResourceContainer": CloudResourceContainer{}.ToAttrType(ctx), + "CredentialsId": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DeploymentName": types.StringType, + "GcpManagedNetworkConfig": GcpManagedNetworkConfig{}.ToAttrType(ctx), + "GkeConfig": GkeConfig{}.ToAttrType(ctx), + "IsNoPublicIpEnabled": types.BoolType, + "Location": types.StringType, + "ManagedServicesCustomerManagedKeyId": types.StringType, + "NetworkId": types.StringType, + "PricingTier": types.StringType, + "PrivateAccessSettingsId": types.StringType, + "StorageConfigurationId": types.StringType, + "StorageCustomerManagedKeyId": types.StringType, + "WorkspaceName": types.StringType, + }, + } +} + type Credential struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` - AwsCredentials types.Object `tfsdk:"aws_credentials" tf:"optional,object"` + AwsCredentials types.List `tfsdk:"aws_credentials" tf:"optional,object"` // Time in epoch milliseconds when the credential was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // Databricks credential configuration ID. @@ -433,6 +590,18 @@ func (a Credential) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Credential) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AwsCredentials": AwsCredentials{}.ToAttrType(ctx), + "CreationTime": types.Int64Type, + "CredentialsId": types.StringType, + "CredentialsName": types.StringType, + }, + } +} + // The general workspace configurations that are specific to Google Cloud. type CustomerFacingGcpCloudResourceContainer struct { // The Google Cloud project ID, which the workspace uses to instantiate @@ -450,17 +619,25 @@ func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a CustomerFacingGcpCloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ProjectId": types.StringType, + }, + } +} + type CustomerManagedKey struct { // The Databricks account ID that holds the customer-managed key. AccountId types.String `tfsdk:"account_id" tf:"optional"` - AwsKeyInfo types.Object `tfsdk:"aws_key_info" tf:"optional,object"` + AwsKeyInfo types.List `tfsdk:"aws_key_info" tf:"optional,object"` // Time in epoch milliseconds when the customer key was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // ID of the encryption key configuration object. CustomerManagedKeyId types.String `tfsdk:"customer_managed_key_id" tf:"optional"` - GcpKeyInfo types.Object `tfsdk:"gcp_key_info" tf:"optional,object"` + GcpKeyInfo types.List `tfsdk:"gcp_key_info" tf:"optional,object"` // The cases that the key can be used for. UseCases types.List `tfsdk:"use_cases" tf:"optional"` } @@ -475,7 +652,22 @@ func (a CustomerManagedKey) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "AwsKeyInfo": reflect.TypeOf(AwsKeyInfo{}), "GcpKeyInfo": reflect.TypeOf(GcpKeyInfo{}), - "UseCases": reflect.TypeOf(""), + "UseCases": reflect.TypeOf(types.StringType), + } +} + +func (a CustomerManagedKey) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AwsKeyInfo": AwsKeyInfo{}.ToAttrType(ctx), + "CreationTime": types.Int64Type, + "CustomerManagedKeyId": types.StringType, + "GcpKeyInfo": GcpKeyInfo{}.ToAttrType(ctx), + "UseCases": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -495,6 +687,14 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialsId": types.StringType, + }, + } +} + // Delete encryption key configuration type DeleteEncryptionKeyRequest struct { // Databricks encryption key configuration ID. @@ -511,6 +711,14 @@ func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CustomerManagedKeyId": types.StringType, + }, + } +} + // Delete a network configuration type DeleteNetworkRequest struct { // Databricks Account API network configuration ID. @@ -527,6 +735,14 @@ func (a DeleteNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkId": types.StringType, + }, + } +} + // Delete a private access settings object type DeletePrivateAccesRequest struct { // Databricks Account API private access settings ID. @@ -543,6 +759,14 @@ func (a DeletePrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeletePrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrivateAccessSettingsId": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -556,6 +780,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete storage configuration type DeleteStorageRequest struct { // Databricks Account API storage configuration ID. @@ -572,6 +802,14 @@ func (a DeleteStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StorageConfigurationId": types.StringType, + }, + } +} + // Delete VPC endpoint configuration type DeleteVpcEndpointRequest struct { // Databricks VPC endpoint ID. @@ -588,6 +826,14 @@ func (a DeleteVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "VpcEndpointId": types.StringType, + }, + } +} + // Delete a workspace type DeleteWorkspaceRequest struct { // Workspace ID. @@ -604,6 +850,14 @@ func (a DeleteWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceId": types.Int64Type, + }, + } +} + type ExternalCustomerInfo struct { // Email of the authoritative user. AuthoritativeUserEmail types.String `tfsdk:"authoritative_user_email" tf:"optional"` @@ -623,6 +877,16 @@ func (a ExternalCustomerInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExternalCustomerInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AuthoritativeUserEmail": types.StringType, + "AuthoritativeUserFullName": types.StringType, + "CustomerName": types.StringType, + }, + } +} + type GcpKeyInfo struct { // The GCP KMS key's resource name KmsKeyId types.String `tfsdk:"kms_key_id" tf:""` @@ -638,6 +902,14 @@ func (a GcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "KmsKeyId": types.StringType, + }, + } +} + // The network settings for the workspace. The configurations are only for // Databricks-managed VPCs. It is ignored if you specify a customer-managed VPC // in the `network_id` field.", All the IP range configurations must be mutually @@ -683,6 +955,16 @@ func (a GcpManagedNetworkConfig) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GcpManagedNetworkConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GkeClusterPodIpRange": types.StringType, + "GkeClusterServiceIpRange": types.StringType, + "SubnetCidr": types.StringType, + }, + } +} + // The Google Cloud specific information for this network (for example, the VPC // ID, subnet ID, and secondary IP ranges). type GcpNetworkInfo struct { @@ -716,6 +998,19 @@ func (a GcpNetworkInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcpNetworkInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkProjectId": types.StringType, + "PodIpRangeName": types.StringType, + "ServiceIpRangeName": types.StringType, + "SubnetId": types.StringType, + "SubnetRegion": types.StringType, + "VpcId": types.StringType, + }, + } +} + // The Google Cloud specific information for this Private Service Connect // endpoint. type GcpVpcEndpointInfo struct { @@ -742,6 +1037,18 @@ func (a GcpVpcEndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GcpVpcEndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointRegion": types.StringType, + "ProjectId": types.StringType, + "PscConnectionId": types.StringType, + "PscEndpointName": types.StringType, + "ServiceAttachmentId": types.StringType, + }, + } +} + // Get credential configuration type GetCredentialRequest struct { // Databricks Account API credential configuration ID @@ -758,6 +1065,14 @@ func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialsId": types.StringType, + }, + } +} + // Get encryption key configuration type GetEncryptionKeyRequest struct { // Databricks encryption key configuration ID. @@ -774,6 +1089,14 @@ func (a GetEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CustomerManagedKeyId": types.StringType, + }, + } +} + // Get a network configuration type GetNetworkRequest struct { // Databricks Account API network configuration ID. @@ -790,6 +1113,14 @@ func (a GetNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkId": types.StringType, + }, + } +} + // Get a private access settings object type GetPrivateAccesRequest struct { // Databricks Account API private access settings ID. @@ -806,6 +1137,14 @@ func (a GetPrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetPrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrivateAccessSettingsId": types.StringType, + }, + } +} + // Get storage configuration type GetStorageRequest struct { // Databricks Account API storage configuration ID. @@ -822,6 +1161,14 @@ func (a GetStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StorageConfigurationId": types.StringType, + }, + } +} + // Get a VPC endpoint configuration type GetVpcEndpointRequest struct { // Databricks VPC endpoint ID. @@ -838,6 +1185,14 @@ func (a GetVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "VpcEndpointId": types.StringType, + }, + } +} + // Get a workspace type GetWorkspaceRequest struct { // Workspace ID. @@ -854,6 +1209,14 @@ func (a GetWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceId": types.Int64Type, + }, + } +} + // The configurations for the GKE cluster of a Databricks workspace. type GkeConfig struct { // Specifies the network connectivity types for the GKE nodes and the GKE @@ -882,6 +1245,15 @@ func (a GkeConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GkeConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConnectivityType": types.StringType, + "MasterIpRange": types.StringType, + }, + } +} + type Network struct { // The Databricks account ID associated with this network configuration. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -891,7 +1263,7 @@ type Network struct { ErrorMessages types.List `tfsdk:"error_messages" tf:"computed,optional"` // The Google Cloud specific information for this network (for example, the // VPC ID, subnet ID, and secondary IP ranges). - GcpNetworkInfo types.Object `tfsdk:"gcp_network_info" tf:"optional,object"` + GcpNetworkInfo types.List `tfsdk:"gcp_network_info" tf:"optional,object"` // The Databricks network configuration ID. NetworkId types.String `tfsdk:"network_id" tf:"optional"` // The human-readable name of the network configuration. @@ -904,7 +1276,7 @@ type Network struct { // communication from this VPC over [AWS PrivateLink]. // // [AWS PrivateLink]: https://aws.amazon.com/privatelink/ - VpcEndpoints types.Object `tfsdk:"vpc_endpoints" tf:"optional,object"` + VpcEndpoints types.List `tfsdk:"vpc_endpoints" tf:"optional,object"` // The ID of the VPC associated with this network configuration. VPC IDs can // be used in multiple networks. VpcId types.String `tfsdk:"vpc_id" tf:"optional"` @@ -928,13 +1300,41 @@ func (a Network) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "ErrorMessages": reflect.TypeOf(NetworkHealth{}), "GcpNetworkInfo": reflect.TypeOf(GcpNetworkInfo{}), - "SecurityGroupIds": reflect.TypeOf(""), - "SubnetIds": reflect.TypeOf(""), + "SecurityGroupIds": reflect.TypeOf(types.StringType), + "SubnetIds": reflect.TypeOf(types.StringType), "VpcEndpoints": reflect.TypeOf(NetworkVpcEndpoints{}), "WarningMessages": reflect.TypeOf(NetworkWarning{}), } } +func (a Network) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "CreationTime": types.Int64Type, + "ErrorMessages": basetypes.ListType{ + ElemType: NetworkHealth{}.ToAttrType(ctx), + }, + "GcpNetworkInfo": GcpNetworkInfo{}.ToAttrType(ctx), + "NetworkId": types.StringType, + "NetworkName": types.StringType, + "SecurityGroupIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "SubnetIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "VpcEndpoints": NetworkVpcEndpoints{}.ToAttrType(ctx), + "VpcId": types.StringType, + "VpcStatus": types.StringType, + "WarningMessages": basetypes.ListType{ + ElemType: NetworkWarning{}.ToAttrType(ctx), + }, + "WorkspaceId": types.Int64Type, + }, + } +} + type NetworkHealth struct { // Details of the error. ErrorMessage types.String `tfsdk:"error_message" tf:"optional"` @@ -953,6 +1353,15 @@ func (a NetworkHealth) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NetworkHealth) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ErrorMessage": types.StringType, + "ErrorType": types.StringType, + }, + } +} + // If specified, contains the VPC endpoints used to allow cluster communication // from this VPC over [AWS PrivateLink]. // @@ -974,8 +1383,21 @@ func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringRead(existingState func (a NetworkVpcEndpoints) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataplaneRelay": reflect.TypeOf(""), - "RestApi": reflect.TypeOf(""), + "DataplaneRelay": reflect.TypeOf(types.StringType), + "RestApi": reflect.TypeOf(types.StringType), + } +} + +func (a NetworkVpcEndpoints) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataplaneRelay": basetypes.ListType{ + ElemType: types.StringType, + }, + "RestApi": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -997,6 +1419,15 @@ func (a NetworkWarning) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NetworkWarning) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WarningMessage": types.StringType, + "WarningType": types.StringType, + }, + } +} + type PrivateAccessSettings struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -1032,7 +1463,23 @@ func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringRead(existingSta func (a PrivateAccessSettings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllowedVpcEndpointIds": reflect.TypeOf(""), + "AllowedVpcEndpointIds": reflect.TypeOf(types.StringType), + } +} + +func (a PrivateAccessSettings) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AllowedVpcEndpointIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "PrivateAccessLevel": types.StringType, + "PrivateAccessSettingsId": types.StringType, + "PrivateAccessSettingsName": types.StringType, + "PublicAccessEnabled": types.BoolType, + "Region": types.StringType, + }, } } @@ -1049,6 +1496,12 @@ func (a ReplaceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ReplaceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Root S3 bucket information. type RootBucketInfo struct { // The name of the S3 bucket. @@ -1065,13 +1518,21 @@ func (a RootBucketInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RootBucketInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BucketName": types.StringType, + }, + } +} + type StorageConfiguration struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"computed,optional"` // Time in epoch milliseconds when the storage configuration was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // Root S3 bucket information. - RootBucketInfo types.Object `tfsdk:"root_bucket_info" tf:"optional,object"` + RootBucketInfo types.List `tfsdk:"root_bucket_info" tf:"optional,object"` // Databricks storage configuration ID. StorageConfigurationId types.String `tfsdk:"storage_configuration_id" tf:"optional"` // The human-readable name of the storage configuration. @@ -1090,6 +1551,18 @@ func (a StorageConfiguration) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a StorageConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "CreationTime": types.Int64Type, + "RootBucketInfo": RootBucketInfo{}.ToAttrType(ctx), + "StorageConfigurationId": types.StringType, + "StorageConfigurationName": types.StringType, + }, + } +} + type StsRole struct { // The external ID that needs to be trusted by the cross-account role. This // is always your Databricks account ID. @@ -1108,6 +1581,15 @@ func (a StsRole) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StsRole) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExternalId": types.StringType, + "RoleArn": types.StringType, + }, + } +} + type UpdateResponse struct { } @@ -1121,6 +1603,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateWorkspaceRequest struct { // The AWS region of the workspace's data plane (for example, `us-west-2`). // This parameter is available only for updating failed workspaces. @@ -1164,7 +1652,26 @@ func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsRegion": types.StringType, + "CredentialsId": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "ManagedServicesCustomerManagedKeyId": types.StringType, + "NetworkConnectivityConfigId": types.StringType, + "NetworkId": types.StringType, + "PrivateAccessSettingsId": types.StringType, + "StorageConfigurationId": types.StringType, + "StorageCustomerManagedKeyId": types.StringType, + "WorkspaceId": types.Int64Type, + }, } } @@ -1214,7 +1721,22 @@ func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringRea func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllowedVpcEndpointIds": reflect.TypeOf(""), + "AllowedVpcEndpointIds": reflect.TypeOf(types.StringType), + } +} + +func (a UpsertPrivateAccessSettingsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowedVpcEndpointIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "PrivateAccessLevel": types.StringType, + "PrivateAccessSettingsId": types.StringType, + "PrivateAccessSettingsName": types.StringType, + "PublicAccessEnabled": types.BoolType, + "Region": types.StringType, + }, } } @@ -1234,7 +1756,7 @@ type VpcEndpoint struct { AwsVpcEndpointId types.String `tfsdk:"aws_vpc_endpoint_id" tf:"optional"` // The Google Cloud specific information for this Private Service Connect // endpoint. - GcpVpcEndpointInfo types.Object `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` + GcpVpcEndpointInfo types.List `tfsdk:"gcp_vpc_endpoint_info" tf:"optional,object"` // The AWS region in which this VPC endpoint object exists. Region types.String `tfsdk:"region" tf:"optional"` // The current state (such as `available` or `rejected`) of the VPC @@ -1268,18 +1790,35 @@ func (a VpcEndpoint) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a VpcEndpoint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AwsAccountId": types.StringType, + "AwsEndpointServiceId": types.StringType, + "AwsVpcEndpointId": types.StringType, + "GcpVpcEndpointInfo": GcpVpcEndpointInfo{}.ToAttrType(ctx), + "Region": types.StringType, + "State": types.StringType, + "UseCase": types.StringType, + "VpcEndpointId": types.StringType, + "VpcEndpointName": types.StringType, + }, + } +} + type Workspace struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` // The AWS region of the workspace data plane (for example, `us-west-2`). AwsRegion types.String `tfsdk:"aws_region" tf:"optional"` - AzureWorkspaceInfo types.Object `tfsdk:"azure_workspace_info" tf:"optional,object"` + AzureWorkspaceInfo types.List `tfsdk:"azure_workspace_info" tf:"optional,object"` // The cloud name. This field always has the value `gcp`. Cloud types.String `tfsdk:"cloud" tf:"optional"` // The general workspace configurations that are specific to cloud // providers. - CloudResourceContainer types.Object `tfsdk:"cloud_resource_container" tf:"optional,object"` + CloudResourceContainer types.List `tfsdk:"cloud_resource_container" tf:"optional,object"` // Time in epoch milliseconds when the workspace was created. CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // ID of the workspace's credential configuration object. @@ -1299,7 +1838,7 @@ type Workspace struct { // If this workspace is for a external customer, then external_customer_info // is populated. If this workspace is not for a external customer, then // external_customer_info is empty. - ExternalCustomerInfo types.Object `tfsdk:"external_customer_info" tf:"optional,object"` + ExternalCustomerInfo types.List `tfsdk:"external_customer_info" tf:"optional,object"` // The network settings for the workspace. The configurations are only for // Databricks-managed VPCs. It is ignored if you specify a customer-managed // VPC in the `network_id` field.", All the IP range configurations must be @@ -1323,9 +1862,9 @@ type Workspace struct { // for a new workspace]. // // [calculate subnet sizes for a new workspace]: https://docs.gcp.databricks.com/administration-guide/cloud-configurations/gcp/network-sizing.html - GcpManagedNetworkConfig types.Object `tfsdk:"gcp_managed_network_config" tf:"optional,object"` + GcpManagedNetworkConfig types.List `tfsdk:"gcp_managed_network_config" tf:"optional,object"` // The configurations for the GKE cluster of a Databricks workspace. - GkeConfig types.Object `tfsdk:"gke_config" tf:"optional,object"` + GkeConfig types.List `tfsdk:"gke_config" tf:"optional,object"` // Whether no public IP is enabled for the workspace. IsNoPublicIpEnabled types.Bool `tfsdk:"is_no_public_ip_enabled" tf:"optional"` // The Google Cloud region of the workspace data plane in your Google @@ -1378,9 +1917,42 @@ func (a Workspace) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "AzureWorkspaceInfo": reflect.TypeOf(AzureWorkspaceInfo{}), "CloudResourceContainer": reflect.TypeOf(CloudResourceContainer{}), - "CustomTags": reflect.TypeOf(""), + "CustomTags": reflect.TypeOf(types.StringType), "ExternalCustomerInfo": reflect.TypeOf(ExternalCustomerInfo{}), "GcpManagedNetworkConfig": reflect.TypeOf(GcpManagedNetworkConfig{}), "GkeConfig": reflect.TypeOf(GkeConfig{}), } } + +func (a Workspace) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "AwsRegion": types.StringType, + "AzureWorkspaceInfo": AzureWorkspaceInfo{}.ToAttrType(ctx), + "Cloud": types.StringType, + "CloudResourceContainer": CloudResourceContainer{}.ToAttrType(ctx), + "CreationTime": types.Int64Type, + "CredentialsId": types.StringType, + "CustomTags": basetypes.MapType{ + ElemType: types.StringType, + }, + "DeploymentName": types.StringType, + "ExternalCustomerInfo": ExternalCustomerInfo{}.ToAttrType(ctx), + "GcpManagedNetworkConfig": GcpManagedNetworkConfig{}.ToAttrType(ctx), + "GkeConfig": GkeConfig{}.ToAttrType(ctx), + "IsNoPublicIpEnabled": types.BoolType, + "Location": types.StringType, + "ManagedServicesCustomerManagedKeyId": types.StringType, + "NetworkId": types.StringType, + "PricingTier": types.StringType, + "PrivateAccessSettingsId": types.StringType, + "StorageConfigurationId": types.StringType, + "StorageCustomerManagedKeyId": types.StringType, + "WorkspaceId": types.Int64Type, + "WorkspaceName": types.StringType, + "WorkspaceStatus": types.StringType, + "WorkspaceStatusMessage": types.StringType, + }, + } +} diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 44138b065d..53997e207c 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -11,11 +11,15 @@ We use go-native types for lists and maps intentionally for the ease for convert package serving_tf import ( + "context" "io" "reflect" "github.com/databricks/databricks-sdk-go/service/oauth2" + "github.com/databricks/terraform-provider-databricks/internal/service/oauth2_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type Ai21LabsConfig struct { @@ -41,20 +45,29 @@ func (a Ai21LabsConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Ai21LabsConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Ai21labsApiKey": types.StringType, + "Ai21labsApiKeyPlaintext": types.StringType, + }, + } +} + type AiGatewayConfig struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. - Guardrails types.Object `tfsdk:"guardrails" tf:"optional,object"` + Guardrails types.List `tfsdk:"guardrails" tf:"optional,object"` // Configuration for payload logging using inference tables. Use these // tables to monitor and audit data being sent to and received from model // APIs and to improve model quality. - InferenceTableConfig types.Object `tfsdk:"inference_table_config" tf:"optional,object"` + InferenceTableConfig types.List `tfsdk:"inference_table_config" tf:"optional,object"` // Configuration for rate limits which can be set to limit endpoint traffic. RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` // Configuration to enable usage tracking using system tables. These tables // allow you to monitor operational usage on endpoints and their associated // costs. - UsageTrackingConfig types.Object `tfsdk:"usage_tracking_config" tf:"optional,object"` + UsageTrackingConfig types.List `tfsdk:"usage_tracking_config" tf:"optional,object"` } func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan AiGatewayConfig) { @@ -72,12 +85,25 @@ func (a AiGatewayConfig) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AiGatewayConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Guardrails": AiGatewayGuardrails{}.ToAttrType(ctx), + "InferenceTableConfig": AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + "RateLimits": basetypes.ListType{ + ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), + }, + "UsageTrackingConfig": AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + }, + } +} + type AiGatewayGuardrailParameters struct { // List of invalid keywords. AI guardrail uses keyword or string matching to // decide if the keyword exists in the request or response content. InvalidKeywords types.List `tfsdk:"invalid_keywords" tf:"optional"` // Configuration for guardrail PII filter. - Pii types.Object `tfsdk:"pii" tf:"optional,object"` + Pii types.List `tfsdk:"pii" tf:"optional,object"` // Indicates whether the safety filter is enabled. Safety types.Bool `tfsdk:"safety" tf:"optional"` // The list of allowed topics. Given a chat request, this guardrail flags @@ -93,9 +119,24 @@ func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringRead(exis func (a AiGatewayGuardrailParameters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InvalidKeywords": reflect.TypeOf(""), + "InvalidKeywords": reflect.TypeOf(types.StringType), "Pii": reflect.TypeOf(AiGatewayGuardrailPiiBehavior{}), - "ValidTopics": reflect.TypeOf(""), + "ValidTopics": reflect.TypeOf(types.StringType), + } +} + +func (a AiGatewayGuardrailParameters) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "InvalidKeywords": basetypes.ListType{ + ElemType: types.StringType, + }, + "Pii": AiGatewayGuardrailPiiBehavior{}.ToAttrType(ctx), + "Safety": types.BoolType, + "ValidTopics": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -119,11 +160,19 @@ func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a AiGatewayGuardrailPiiBehavior) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Behavior": types.StringType, + }, + } +} + type AiGatewayGuardrails struct { // Configuration for input guardrail filters. - Input types.Object `tfsdk:"input" tf:"optional,object"` + Input types.List `tfsdk:"input" tf:"optional,object"` // Configuration for output guardrail filters. - Output types.Object `tfsdk:"output" tf:"optional,object"` + Output types.List `tfsdk:"output" tf:"optional,object"` } func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringCreateOrUpdate(plan AiGatewayGuardrails) { @@ -139,6 +188,15 @@ func (a AiGatewayGuardrails) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AiGatewayGuardrails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Input": AiGatewayGuardrailParameters{}.ToAttrType(ctx), + "Output": AiGatewayGuardrailParameters{}.ToAttrType(ctx), + }, + } +} + type AiGatewayInferenceTableConfig struct { // The name of the catalog in Unity Catalog. Required when enabling // inference tables. NOTE: On update, you have to disable inference table @@ -165,6 +223,17 @@ func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a AiGatewayInferenceTableConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Enabled": types.BoolType, + "SchemaName": types.StringType, + "TableNamePrefix": types.StringType, + }, + } +} + type AiGatewayRateLimit struct { // Used to specify how many calls are allowed for a key within the // renewal_period. @@ -187,6 +256,16 @@ func (a AiGatewayRateLimit) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AiGatewayRateLimit) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Calls": types.Int64Type, + "Key": types.StringType, + "RenewalPeriod": types.StringType, + }, + } +} + type AiGatewayUsageTrackingConfig struct { // Whether to enable usage tracking. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -202,6 +281,14 @@ func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a AiGatewayUsageTrackingConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + }, + } +} + type AmazonBedrockConfig struct { // The Databricks secret key reference for an AWS access key ID with // permissions to interact with Bedrock services. If you prefer to paste @@ -246,6 +333,19 @@ func (a AmazonBedrockConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AmazonBedrockConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsAccessKeyId": types.StringType, + "AwsAccessKeyIdPlaintext": types.StringType, + "AwsRegion": types.StringType, + "AwsSecretAccessKey": types.StringType, + "AwsSecretAccessKeyPlaintext": types.StringType, + "BedrockProvider": types.StringType, + }, + } +} + type AnthropicConfig struct { // The Databricks secret key reference for an Anthropic API key. If you // prefer to paste your API key directly, see `anthropic_api_key_plaintext`. @@ -269,6 +369,15 @@ func (a AnthropicConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AnthropicConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AnthropicApiKey": types.StringType, + "AnthropicApiKeyPlaintext": types.StringType, + }, + } +} + type AutoCaptureConfigInput struct { // The name of the catalog in Unity Catalog. NOTE: On update, you cannot // change the catalog name if the inference table is already enabled. @@ -293,6 +402,17 @@ func (a AutoCaptureConfigInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AutoCaptureConfigInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Enabled": types.BoolType, + "SchemaName": types.StringType, + "TableNamePrefix": types.StringType, + }, + } +} + type AutoCaptureConfigOutput struct { // The name of the catalog in Unity Catalog. CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -301,7 +421,7 @@ type AutoCaptureConfigOutput struct { // The name of the schema in Unity Catalog. SchemaName types.String `tfsdk:"schema_name" tf:"optional"` - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The prefix of the table in Unity Catalog. TableNamePrefix types.String `tfsdk:"table_name_prefix" tf:"optional"` } @@ -318,8 +438,20 @@ func (a AutoCaptureConfigOutput) GetComplexFieldTypes() map[string]reflect.Type } } +func (a AutoCaptureConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CatalogName": types.StringType, + "Enabled": types.BoolType, + "SchemaName": types.StringType, + "State": AutoCaptureState{}.ToAttrType(ctx), + "TableNamePrefix": types.StringType, + }, + } +} + type AutoCaptureState struct { - PayloadTable types.Object `tfsdk:"payload_table" tf:"optional,object"` + PayloadTable types.List `tfsdk:"payload_table" tf:"optional,object"` } func (newState *AutoCaptureState) SyncEffectiveFieldsDuringCreateOrUpdate(plan AutoCaptureState) { @@ -334,6 +466,14 @@ func (a AutoCaptureState) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AutoCaptureState) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PayloadTable": PayloadTable{}.ToAttrType(ctx), + }, + } +} + // Get build logs for a served model type BuildLogsRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -354,6 +494,15 @@ func (a BuildLogsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a BuildLogsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "ServedModelName": types.StringType, + }, + } +} + type BuildLogsResponse struct { // The logs associated with building the served entity's environment. Logs types.String `tfsdk:"logs" tf:""` @@ -369,6 +518,14 @@ func (a BuildLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a BuildLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Logs": types.StringType, + }, + } +} + type ChatMessage struct { // The content of the message. Content types.String `tfsdk:"content" tf:"optional"` @@ -386,6 +543,15 @@ func (a ChatMessage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ChatMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "Role": types.StringType, + }, + } +} + type CohereConfig struct { // This is an optional field to provide a customized base URL for the Cohere // API. If left unspecified, the standard Cohere base URL is used. @@ -412,12 +578,22 @@ func (a CohereConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CohereConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CohereApiBase": types.StringType, + "CohereApiKey": types.StringType, + "CohereApiKeyPlaintext": types.StringType, + }, + } +} + type CreateServingEndpoint struct { // The AI Gateway configuration for the serving endpoint. NOTE: only // external model endpoints are supported as of now. - AiGateway types.Object `tfsdk:"ai_gateway" tf:"optional,object"` + AiGateway types.List `tfsdk:"ai_gateway" tf:"optional,object"` // The core config of the serving endpoint. - Config types.Object `tfsdk:"config" tf:"object"` + Config types.List `tfsdk:"config" tf:"object"` // The name of the serving endpoint. This field is required and must be // unique across a Databricks workspace. An endpoint name can consist of // alphanumeric characters, dashes, and underscores. @@ -447,6 +623,23 @@ func (a CreateServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AiGateway": AiGatewayConfig{}.ToAttrType(ctx), + "Config": EndpointCoreConfigInput{}.ToAttrType(ctx), + "Name": types.StringType, + "RateLimits": basetypes.ListType{ + ElemType: RateLimit{}.ToAttrType(ctx), + }, + "RouteOptimized": types.BoolType, + "Tags": basetypes.ListType{ + ElemType: EndpointTag{}.ToAttrType(ctx), + }, + }, + } +} + type DatabricksModelServingConfig struct { // The Databricks secret key reference for a Databricks API token that // corresponds to a user or service principal with Can Query access to the @@ -477,6 +670,16 @@ func (a DatabricksModelServingConfig) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DatabricksModelServingConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DatabricksApiToken": types.StringType, + "DatabricksApiTokenPlaintext": types.StringType, + "DatabricksWorkspaceUrl": types.StringType, + }, + } +} + type DataframeSplitInput struct { Columns types.List `tfsdk:"columns" tf:"optional"` @@ -495,7 +698,23 @@ func (a DataframeSplitInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Columns": reflect.TypeOf(struct{}{}), "Data": reflect.TypeOf(struct{}{}), - "Index": reflect.TypeOf(0), + "Index": reflect.TypeOf(types.Int64Type), + } +} + +func (a DataframeSplitInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Columns": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "Data": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "Index": basetypes.ListType{ + ElemType: types.Int64Type, + }, + }, } } @@ -512,6 +731,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a serving endpoint type DeleteServingEndpointRequest struct { // The name of the serving endpoint. This field is required. @@ -528,6 +753,14 @@ func (a DeleteServingEndpointRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type EmbeddingsV1ResponseEmbeddingElement struct { Embedding types.List `tfsdk:"embedding" tf:"optional"` // The index of the embedding in the response. @@ -544,14 +777,26 @@ func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringR func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Embedding": reflect.TypeOf(0.0), + "Embedding": reflect.TypeOf(types.Float64Type), + } +} + +func (a EmbeddingsV1ResponseEmbeddingElement) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Embedding": basetypes.ListType{ + ElemType: types.Float64Type, + }, + "Index": types.Int64Type, + "Object": types.StringType, + }, } } type EndpointCoreConfigInput struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. - AutoCaptureConfig types.Object `tfsdk:"auto_capture_config" tf:"optional,object"` + AutoCaptureConfig types.List `tfsdk:"auto_capture_config" tf:"optional,object"` // The name of the serving endpoint to update. This field is required. Name types.String `tfsdk:"-"` // A list of served entities for the endpoint to serve. A serving endpoint @@ -562,7 +807,7 @@ type EndpointCoreConfigInput struct { ServedModels types.List `tfsdk:"served_models" tf:"optional"` // The traffic config defining how invocations to the serving endpoint // should be routed. - TrafficConfig types.Object `tfsdk:"traffic_config" tf:"optional,object"` + TrafficConfig types.List `tfsdk:"traffic_config" tf:"optional,object"` } func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointCoreConfigInput) { @@ -580,10 +825,26 @@ func (a EndpointCoreConfigInput) GetComplexFieldTypes() map[string]reflect.Type } } +func (a EndpointCoreConfigInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoCaptureConfig": AutoCaptureConfigInput{}.ToAttrType(ctx), + "Name": types.StringType, + "ServedEntities": basetypes.ListType{ + ElemType: ServedEntityInput{}.ToAttrType(ctx), + }, + "ServedModels": basetypes.ListType{ + ElemType: ServedModelInput{}.ToAttrType(ctx), + }, + "TrafficConfig": TrafficConfig{}.ToAttrType(ctx), + }, + } +} + type EndpointCoreConfigOutput struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. - AutoCaptureConfig types.Object `tfsdk:"auto_capture_config" tf:"optional,object"` + AutoCaptureConfig types.List `tfsdk:"auto_capture_config" tf:"optional,object"` // The config version that the serving endpoint is currently serving. ConfigVersion types.Int64 `tfsdk:"config_version" tf:"optional"` // The list of served entities under the serving endpoint config. @@ -592,7 +853,7 @@ type EndpointCoreConfigOutput struct { // the serving endpoint config. ServedModels types.List `tfsdk:"served_models" tf:"optional"` // The traffic configuration associated with the serving endpoint config. - TrafficConfig types.Object `tfsdk:"traffic_config" tf:"optional,object"` + TrafficConfig types.List `tfsdk:"traffic_config" tf:"optional,object"` } func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointCoreConfigOutput) { @@ -610,6 +871,22 @@ func (a EndpointCoreConfigOutput) GetComplexFieldTypes() map[string]reflect.Type } } +func (a EndpointCoreConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoCaptureConfig": AutoCaptureConfigOutput{}.ToAttrType(ctx), + "ConfigVersion": types.Int64Type, + "ServedEntities": basetypes.ListType{ + ElemType: ServedEntityOutput{}.ToAttrType(ctx), + }, + "ServedModels": basetypes.ListType{ + ElemType: ServedModelOutput{}.ToAttrType(ctx), + }, + "TrafficConfig": TrafficConfig{}.ToAttrType(ctx), + }, + } +} + type EndpointCoreConfigSummary struct { // The list of served entities under the serving endpoint config. ServedEntities types.List `tfsdk:"served_entities" tf:"optional"` @@ -631,10 +908,23 @@ func (a EndpointCoreConfigSummary) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a EndpointCoreConfigSummary) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ServedEntities": basetypes.ListType{ + ElemType: ServedEntitySpec{}.ToAttrType(ctx), + }, + "ServedModels": basetypes.ListType{ + ElemType: ServedModelSpec{}.ToAttrType(ctx), + }, + }, + } +} + type EndpointPendingConfig struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. - AutoCaptureConfig types.Object `tfsdk:"auto_capture_config" tf:"optional,object"` + AutoCaptureConfig types.List `tfsdk:"auto_capture_config" tf:"optional,object"` // The config version that the serving endpoint is currently serving. ConfigVersion types.Int64 `tfsdk:"config_version" tf:"optional"` // The list of served entities belonging to the last issued update to the @@ -647,7 +937,7 @@ type EndpointPendingConfig struct { StartTime types.Int64 `tfsdk:"start_time" tf:"optional"` // The traffic config defining how invocations to the serving endpoint // should be routed. - TrafficConfig types.Object `tfsdk:"traffic_config" tf:"optional,object"` + TrafficConfig types.List `tfsdk:"traffic_config" tf:"optional,object"` } func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan EndpointPendingConfig) { @@ -665,6 +955,23 @@ func (a EndpointPendingConfig) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EndpointPendingConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoCaptureConfig": AutoCaptureConfigOutput{}.ToAttrType(ctx), + "ConfigVersion": types.Int64Type, + "ServedEntities": basetypes.ListType{ + ElemType: ServedEntityOutput{}.ToAttrType(ctx), + }, + "ServedModels": basetypes.ListType{ + ElemType: ServedModelOutput{}.ToAttrType(ctx), + }, + "StartTime": types.Int64Type, + "TrafficConfig": TrafficConfig{}.ToAttrType(ctx), + }, + } +} + type EndpointState struct { // The state of an endpoint's config update. This informs the user if the // pending_config is in progress, if the update failed, or if there is no @@ -689,6 +996,15 @@ func (a EndpointState) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EndpointState) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConfigUpdate": types.StringType, + "Ready": types.StringType, + }, + } +} + type EndpointTag struct { // Key field for a serving endpoint tag. Key types.String `tfsdk:"key" tf:""` @@ -706,6 +1022,15 @@ func (a EndpointTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EndpointTag) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + // Get metrics of a serving endpoint type ExportMetricsRequest struct { // The name of the serving endpoint to retrieve metrics for. This field is @@ -723,6 +1048,14 @@ func (a ExportMetricsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExportMetricsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type ExportMetricsResponse struct { Contents io.ReadCloser `tfsdk:"-"` } @@ -737,27 +1070,35 @@ func (a ExportMetricsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExportMetricsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Contents": types.ObjectType{}, + }, + } +} + type ExternalModel struct { // AI21Labs Config. Only required if the provider is 'ai21labs'. - Ai21labsConfig types.Object `tfsdk:"ai21labs_config" tf:"optional,object"` + Ai21labsConfig types.List `tfsdk:"ai21labs_config" tf:"optional,object"` // Amazon Bedrock Config. Only required if the provider is 'amazon-bedrock'. - AmazonBedrockConfig types.Object `tfsdk:"amazon_bedrock_config" tf:"optional,object"` + AmazonBedrockConfig types.List `tfsdk:"amazon_bedrock_config" tf:"optional,object"` // Anthropic Config. Only required if the provider is 'anthropic'. - AnthropicConfig types.Object `tfsdk:"anthropic_config" tf:"optional,object"` + AnthropicConfig types.List `tfsdk:"anthropic_config" tf:"optional,object"` // Cohere Config. Only required if the provider is 'cohere'. - CohereConfig types.Object `tfsdk:"cohere_config" tf:"optional,object"` + CohereConfig types.List `tfsdk:"cohere_config" tf:"optional,object"` // Databricks Model Serving Config. Only required if the provider is // 'databricks-model-serving'. - DatabricksModelServingConfig types.Object `tfsdk:"databricks_model_serving_config" tf:"optional,object"` + DatabricksModelServingConfig types.List `tfsdk:"databricks_model_serving_config" tf:"optional,object"` // Google Cloud Vertex AI Config. Only required if the provider is // 'google-cloud-vertex-ai'. - GoogleCloudVertexAiConfig types.Object `tfsdk:"google_cloud_vertex_ai_config" tf:"optional,object"` + GoogleCloudVertexAiConfig types.List `tfsdk:"google_cloud_vertex_ai_config" tf:"optional,object"` // The name of the external model. Name types.String `tfsdk:"name" tf:""` // OpenAI Config. Only required if the provider is 'openai'. - OpenaiConfig types.Object `tfsdk:"openai_config" tf:"optional,object"` + OpenaiConfig types.List `tfsdk:"openai_config" tf:"optional,object"` // PaLM Config. Only required if the provider is 'palm'. - PalmConfig types.Object `tfsdk:"palm_config" tf:"optional,object"` + PalmConfig types.List `tfsdk:"palm_config" tf:"optional,object"` // The name of the provider for the external model. Currently, the supported // providers are 'ai21labs', 'anthropic', 'amazon-bedrock', 'cohere', // 'databricks-model-serving', 'google-cloud-vertex-ai', 'openai', and @@ -786,6 +1127,24 @@ func (a ExternalModel) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ExternalModel) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Ai21labsConfig": Ai21LabsConfig{}.ToAttrType(ctx), + "AmazonBedrockConfig": AmazonBedrockConfig{}.ToAttrType(ctx), + "AnthropicConfig": AnthropicConfig{}.ToAttrType(ctx), + "CohereConfig": CohereConfig{}.ToAttrType(ctx), + "DatabricksModelServingConfig": DatabricksModelServingConfig{}.ToAttrType(ctx), + "GoogleCloudVertexAiConfig": GoogleCloudVertexAiConfig{}.ToAttrType(ctx), + "Name": types.StringType, + "OpenaiConfig": OpenAiConfig{}.ToAttrType(ctx), + "PalmConfig": PaLmConfig{}.ToAttrType(ctx), + "Provider": types.StringType, + "Task": types.StringType, + }, + } +} + type ExternalModelUsageElement struct { // The number of tokens in the chat/completions response. CompletionTokens types.Int64 `tfsdk:"completion_tokens" tf:"optional"` @@ -805,6 +1164,16 @@ func (a ExternalModelUsageElement) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a ExternalModelUsageElement) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CompletionTokens": types.Int64Type, + "PromptTokens": types.Int64Type, + "TotalTokens": types.Int64Type, + }, + } +} + type FoundationModel struct { // The description of the foundation model. Description types.String `tfsdk:"description" tf:"optional"` @@ -826,6 +1195,17 @@ func (a FoundationModel) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a FoundationModel) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "DisplayName": types.StringType, + "Docs": types.StringType, + "Name": types.StringType, + }, + } +} + // Get the schema for a serving endpoint type GetOpenApiRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -843,6 +1223,14 @@ func (a GetOpenApiRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetOpenApiRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // The response is an OpenAPI spec in JSON format that typically includes fields // like openapi, info, servers and paths, etc. type GetOpenApiResponse struct { @@ -858,6 +1246,12 @@ func (a GetOpenApiResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetOpenApiResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Get serving endpoint permission levels type GetServingEndpointPermissionLevelsRequest struct { // The serving endpoint for which to get or manage permissions. @@ -874,6 +1268,14 @@ func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes() map[st return map[string]reflect.Type{} } +func (a GetServingEndpointPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ServingEndpointId": types.StringType, + }, + } +} + type GetServingEndpointPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -891,6 +1293,16 @@ func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes() map[s } } +func (a GetServingEndpointPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: ServingEndpointPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get serving endpoint permissions type GetServingEndpointPermissionsRequest struct { // The serving endpoint for which to get or manage permissions. @@ -907,6 +1319,14 @@ func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GetServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ServingEndpointId": types.StringType, + }, + } +} + // Get a single serving endpoint type GetServingEndpointRequest struct { // The name of the serving endpoint. This field is required. @@ -923,6 +1343,14 @@ func (a GetServingEndpointRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a GetServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type GoogleCloudVertexAiConfig struct { // The Databricks secret key reference for a private key for the service // account which has access to the Google Cloud Vertex AI Service. See [Best @@ -963,6 +1391,17 @@ func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a GoogleCloudVertexAiConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrivateKey": types.StringType, + "PrivateKeyPlaintext": types.StringType, + "ProjectId": types.StringType, + "Region": types.StringType, + }, + } +} + type ListEndpointsResponse struct { // The list of endpoints. Endpoints types.List `tfsdk:"endpoints" tf:"optional"` @@ -980,6 +1419,16 @@ func (a ListEndpointsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListEndpointsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Endpoints": basetypes.ListType{ + ElemType: ServingEndpoint{}.ToAttrType(ctx), + }, + }, + } +} + // Get the latest logs for a served model type LogsRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -1000,6 +1449,15 @@ func (a LogsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a LogsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "ServedModelName": types.StringType, + }, + } +} + type ModelDataPlaneInfo struct { // Information required to query DataPlane API 'query' endpoint. QueryInfo oauth2.DataPlaneInfo `tfsdk:"query_info" tf:"optional,object"` @@ -1017,6 +1475,14 @@ func (a ModelDataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ModelDataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueryInfo": oauth2_tf.DataPlaneInfo{}.ToAttrType(ctx), + }, + } +} + type OpenAiConfig struct { // This field is only required for Azure AD OpenAI and is the Microsoft // Entra Client ID. @@ -1081,6 +1547,24 @@ func (a OpenAiConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a OpenAiConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MicrosoftEntraClientId": types.StringType, + "MicrosoftEntraClientSecret": types.StringType, + "MicrosoftEntraClientSecretPlaintext": types.StringType, + "MicrosoftEntraTenantId": types.StringType, + "OpenaiApiBase": types.StringType, + "OpenaiApiKey": types.StringType, + "OpenaiApiKeyPlaintext": types.StringType, + "OpenaiApiType": types.StringType, + "OpenaiApiVersion": types.StringType, + "OpenaiDeploymentName": types.StringType, + "OpenaiOrganization": types.StringType, + }, + } +} + type PaLmConfig struct { // The Databricks secret key reference for a PaLM API key. If you prefer to // paste your API key directly, see `palm_api_key_plaintext`. You must @@ -1104,6 +1588,15 @@ func (a PaLmConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PaLmConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PalmApiKey": types.StringType, + "PalmApiKeyPlaintext": types.StringType, + }, + } +} + type PatchServingEndpointTags struct { // List of endpoint tags to add AddTags types.List `tfsdk:"add_tags" tf:"optional"` @@ -1123,7 +1616,21 @@ func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringRead(existing func (a PatchServingEndpointTags) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "AddTags": reflect.TypeOf(EndpointTag{}), - "DeleteTags": reflect.TypeOf(""), + "DeleteTags": reflect.TypeOf(types.StringType), + } +} + +func (a PatchServingEndpointTags) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AddTags": basetypes.ListType{ + ElemType: EndpointTag{}.ToAttrType(ctx), + }, + "DeleteTags": basetypes.ListType{ + ElemType: types.StringType, + }, + "Name": types.StringType, + }, } } @@ -1146,15 +1653,25 @@ func (a PayloadTable) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PayloadTable) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Status": types.StringType, + "StatusMessage": types.StringType, + }, + } +} + // Update AI Gateway of a serving endpoint type PutAiGatewayRequest struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. - Guardrails types.Object `tfsdk:"guardrails" tf:"optional,object"` + Guardrails types.List `tfsdk:"guardrails" tf:"optional,object"` // Configuration for payload logging using inference tables. Use these // tables to monitor and audit data being sent to and received from model // APIs and to improve model quality. - InferenceTableConfig types.Object `tfsdk:"inference_table_config" tf:"optional,object"` + InferenceTableConfig types.List `tfsdk:"inference_table_config" tf:"optional,object"` // The name of the serving endpoint whose AI Gateway is being updated. This // field is required. Name types.String `tfsdk:"-"` @@ -1163,7 +1680,7 @@ type PutAiGatewayRequest struct { // Configuration to enable usage tracking using system tables. These tables // allow you to monitor operational usage on endpoints and their associated // costs. - UsageTrackingConfig types.Object `tfsdk:"usage_tracking_config" tf:"optional,object"` + UsageTrackingConfig types.List `tfsdk:"usage_tracking_config" tf:"optional,object"` } func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAiGatewayRequest) { @@ -1181,20 +1698,34 @@ func (a PutAiGatewayRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PutAiGatewayRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Guardrails": AiGatewayGuardrails{}.ToAttrType(ctx), + "InferenceTableConfig": AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + "Name": types.StringType, + "RateLimits": basetypes.ListType{ + ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), + }, + "UsageTrackingConfig": AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + }, + } +} + type PutAiGatewayResponse struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. - Guardrails types.Object `tfsdk:"guardrails" tf:"optional,object"` + Guardrails types.List `tfsdk:"guardrails" tf:"optional,object"` // Configuration for payload logging using inference tables. Use these // tables to monitor and audit data being sent to and received from model // APIs and to improve model quality . - InferenceTableConfig types.Object `tfsdk:"inference_table_config" tf:"optional,object"` + InferenceTableConfig types.List `tfsdk:"inference_table_config" tf:"optional,object"` // Configuration for rate limits which can be set to limit endpoint traffic. RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` // Configuration to enable usage tracking using system tables. These tables // allow you to monitor operational usage on endpoints and their associated // costs. - UsageTrackingConfig types.Object `tfsdk:"usage_tracking_config" tf:"optional,object"` + UsageTrackingConfig types.List `tfsdk:"usage_tracking_config" tf:"optional,object"` } func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAiGatewayResponse) { @@ -1212,6 +1743,19 @@ func (a PutAiGatewayResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PutAiGatewayResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Guardrails": AiGatewayGuardrails{}.ToAttrType(ctx), + "InferenceTableConfig": AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + "RateLimits": basetypes.ListType{ + ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), + }, + "UsageTrackingConfig": AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + }, + } +} + // Update rate limits of a serving endpoint type PutRequest struct { // The name of the serving endpoint whose rate limits are being updated. @@ -1233,6 +1777,17 @@ func (a PutRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PutRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "RateLimits": basetypes.ListType{ + ElemType: RateLimit{}.ToAttrType(ctx), + }, + }, + } +} + type PutResponse struct { // The list of endpoint rate limits. RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` @@ -1250,11 +1805,21 @@ func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RateLimits": basetypes.ListType{ + ElemType: RateLimit{}.ToAttrType(ctx), + }, + }, + } +} + type QueryEndpointInput struct { // Pandas Dataframe input in the records orientation. DataframeRecords types.List `tfsdk:"dataframe_records" tf:"optional"` // Pandas Dataframe input in the split orientation. - DataframeSplit types.Object `tfsdk:"dataframe_split" tf:"optional,object"` + DataframeSplit types.List `tfsdk:"dataframe_split" tf:"optional,object"` // The extra parameters field used ONLY for __completions, chat,__ and // __embeddings external & foundation model__ serving endpoints. This is a // map of strings and should only be used with other external/foundation @@ -1312,10 +1877,41 @@ func (a QueryEndpointInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "DataframeRecords": reflect.TypeOf(struct{}{}), "DataframeSplit": reflect.TypeOf(DataframeSplitInput{}), - "ExtraParams": reflect.TypeOf(""), + "ExtraParams": reflect.TypeOf(types.StringType), "Instances": reflect.TypeOf(struct{}{}), "Messages": reflect.TypeOf(ChatMessage{}), - "Stop": reflect.TypeOf(""), + "Stop": reflect.TypeOf(types.StringType), + } +} + +func (a QueryEndpointInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataframeRecords": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "DataframeSplit": DataframeSplitInput{}.ToAttrType(ctx), + "ExtraParams": basetypes.MapType{ + ElemType: types.StringType, + }, + "Input": types.ObjectType{}, + "Inputs": types.ObjectType{}, + "Instances": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "MaxTokens": types.Int64Type, + "Messages": basetypes.ListType{ + ElemType: ChatMessage{}.ToAttrType(ctx), + }, + "N": types.Int64Type, + "Name": types.StringType, + "Prompt": types.ObjectType{}, + "Stop": basetypes.ListType{ + ElemType: types.StringType, + }, + "Stream": types.BoolType, + "Temperature": types.Float64Type, + }, } } @@ -1347,7 +1943,7 @@ type QueryEndpointResponse struct { // The usage object that may be returned by the __external/foundation // model__ serving endpoint. This contains information about the number of // tokens used in the prompt and response. - Usage types.Object `tfsdk:"usage" tf:"optional,object"` + Usage types.List `tfsdk:"usage" tf:"optional,object"` } func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryEndpointResponse) { @@ -1365,6 +1961,28 @@ func (a QueryEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a QueryEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Choices": basetypes.ListType{ + ElemType: V1ResponseChoiceElement{}.ToAttrType(ctx), + }, + "Created": types.Int64Type, + "Data": basetypes.ListType{ + ElemType: EmbeddingsV1ResponseEmbeddingElement{}.ToAttrType(ctx), + }, + "Id": types.StringType, + "Model": types.StringType, + "Object": types.StringType, + "Predictions": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "ServedModelName": types.StringType, + "Usage": ExternalModelUsageElement{}.ToAttrType(ctx), + }, + } +} + type RateLimit struct { // Used to specify how many calls are allowed for a key within the // renewal_period. @@ -1388,6 +2006,16 @@ func (a RateLimit) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RateLimit) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Calls": types.Int64Type, + "Key": types.StringType, + "RenewalPeriod": types.StringType, + }, + } +} + type Route struct { // The name of the served model this route configures traffic for. ServedModelName types.String `tfsdk:"served_model_name" tf:""` @@ -1406,6 +2034,15 @@ func (a Route) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Route) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ServedModelName": types.StringType, + "TrafficPercentage": types.Int64Type, + }, + } +} + type ServedEntityInput struct { // The name of the entity to be served. The entity may be a model in the // Databricks Model Registry, a model in the Unity Catalog (UC), or a @@ -1431,7 +2068,7 @@ type ServedEntityInput struct { // endpoint without external_model. If the endpoint is created without // external_model, users cannot update it to add external_model later. The // task type of all external models within an endpoint must be the same. - ExternalModel types.Object `tfsdk:"external_model" tf:"optional,object"` + ExternalModel types.List `tfsdk:"external_model" tf:"optional,object"` // ARN of the instance profile that the served entity uses to access AWS // resources. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:"optional"` @@ -1475,11 +2112,31 @@ func (newState *ServedEntityInput) SyncEffectiveFieldsDuringRead(existingState S func (a ServedEntityInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(""), + "EnvironmentVars": reflect.TypeOf(types.StringType), "ExternalModel": reflect.TypeOf(ExternalModel{}), } } +func (a ServedEntityInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EntityName": types.StringType, + "EntityVersion": types.StringType, + "EnvironmentVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "ExternalModel": ExternalModel{}.ToAttrType(ctx), + "InstanceProfileArn": types.StringType, + "MaxProvisionedThroughput": types.Int64Type, + "MinProvisionedThroughput": types.Int64Type, + "Name": types.StringType, + "ScaleToZeroEnabled": types.BoolType, + "WorkloadSize": types.StringType, + "WorkloadType": types.StringType, + }, + } +} + type ServedEntityOutput struct { // The creation timestamp of the served entity in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -1505,12 +2162,12 @@ type ServedEntityOutput struct { // foundation_model, and (entity_name, entity_version, workload_size, // workload_type, and scale_to_zero_enabled) is returned based on the // endpoint type. - ExternalModel types.Object `tfsdk:"external_model" tf:"optional,object"` + ExternalModel types.List `tfsdk:"external_model" tf:"optional,object"` // The foundation model that is served. NOTE: Only one of foundation_model, // external_model, and (entity_name, entity_version, workload_size, // workload_type, and scale_to_zero_enabled) is returned based on the // endpoint type. - FoundationModel types.Object `tfsdk:"foundation_model" tf:"optional,object"` + FoundationModel types.List `tfsdk:"foundation_model" tf:"optional,object"` // ARN of the instance profile that the served entity uses to access AWS // resources. InstanceProfileArn types.String `tfsdk:"instance_profile_arn" tf:"optional"` @@ -1524,7 +2181,7 @@ type ServedEntityOutput struct { // zero. ScaleToZeroEnabled types.Bool `tfsdk:"scale_to_zero_enabled" tf:"optional"` // Information corresponding to the state of the served entity. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The workload size of the served entity. The workload size corresponds to // a range of provisioned concurrency that the compute autoscales between. A // single unit of provisioned concurrency can process one request at a time. @@ -1551,13 +2208,37 @@ func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringRead(existingState func (a ServedEntityOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(""), + "EnvironmentVars": reflect.TypeOf(types.StringType), "ExternalModel": reflect.TypeOf(ExternalModel{}), "FoundationModel": reflect.TypeOf(FoundationModel{}), "State": reflect.TypeOf(ServedModelState{}), } } +func (a ServedEntityOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "Creator": types.StringType, + "EntityName": types.StringType, + "EntityVersion": types.StringType, + "EnvironmentVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "ExternalModel": ExternalModel{}.ToAttrType(ctx), + "FoundationModel": FoundationModel{}.ToAttrType(ctx), + "InstanceProfileArn": types.StringType, + "MaxProvisionedThroughput": types.Int64Type, + "MinProvisionedThroughput": types.Int64Type, + "Name": types.StringType, + "ScaleToZeroEnabled": types.BoolType, + "State": ServedModelState{}.ToAttrType(ctx), + "WorkloadSize": types.StringType, + "WorkloadType": types.StringType, + }, + } +} + type ServedEntitySpec struct { // The name of the entity served. The entity may be a model in the // Databricks Model Registry, a model in the Unity Catalog (UC), or a @@ -1571,11 +2252,11 @@ type ServedEntitySpec struct { // The external model that is served. NOTE: Only one of external_model, // foundation_model, and (entity_name, entity_version) is returned based on // the endpoint type. - ExternalModel types.Object `tfsdk:"external_model" tf:"optional,object"` + ExternalModel types.List `tfsdk:"external_model" tf:"optional,object"` // The foundation model that is served. NOTE: Only one of foundation_model, // external_model, and (entity_name, entity_version) is returned based on // the endpoint type. - FoundationModel types.Object `tfsdk:"foundation_model" tf:"optional,object"` + FoundationModel types.List `tfsdk:"foundation_model" tf:"optional,object"` // The name of the served entity. Name types.String `tfsdk:"name" tf:"optional"` } @@ -1593,6 +2274,18 @@ func (a ServedEntitySpec) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ServedEntitySpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EntityName": types.StringType, + "EntityVersion": types.StringType, + "ExternalModel": ExternalModel{}.ToAttrType(ctx), + "FoundationModel": FoundationModel{}.ToAttrType(ctx), + "Name": types.StringType, + }, + } +} + type ServedModelInput struct { // An object containing a set of optional, user-specified environment // variable key-value pairs used for serving this model. Note: this is an @@ -1649,7 +2342,26 @@ func (newState *ServedModelInput) SyncEffectiveFieldsDuringRead(existingState Se func (a ServedModelInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(""), + "EnvironmentVars": reflect.TypeOf(types.StringType), + } +} + +func (a ServedModelInput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EnvironmentVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "InstanceProfileArn": types.StringType, + "MaxProvisionedThroughput": types.Int64Type, + "MinProvisionedThroughput": types.Int64Type, + "ModelName": types.StringType, + "ModelVersion": types.StringType, + "Name": types.StringType, + "ScaleToZeroEnabled": types.BoolType, + "WorkloadSize": types.StringType, + "WorkloadType": types.StringType, + }, } } @@ -1680,7 +2392,7 @@ type ServedModelOutput struct { // zero. ScaleToZeroEnabled types.Bool `tfsdk:"scale_to_zero_enabled" tf:"optional"` // Information corresponding to the state of the Served Model. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // The workload size of the served model. The workload size corresponds to a // range of provisioned concurrency that the compute will autoscale between. // A single unit of provisioned concurrency can process one request at a @@ -1707,11 +2419,31 @@ func (newState *ServedModelOutput) SyncEffectiveFieldsDuringRead(existingState S func (a ServedModelOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(""), + "EnvironmentVars": reflect.TypeOf(types.StringType), "State": reflect.TypeOf(ServedModelState{}), } } +func (a ServedModelOutput) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "Creator": types.StringType, + "EnvironmentVars": basetypes.MapType{ + ElemType: types.StringType, + }, + "InstanceProfileArn": types.StringType, + "ModelName": types.StringType, + "ModelVersion": types.StringType, + "Name": types.StringType, + "ScaleToZeroEnabled": types.BoolType, + "State": ServedModelState{}.ToAttrType(ctx), + "WorkloadSize": types.StringType, + "WorkloadType": types.StringType, + }, + } +} + type ServedModelSpec struct { // The name of the model in Databricks Model Registry or the full name of // the model in Unity Catalog. @@ -1733,6 +2465,16 @@ func (a ServedModelSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ServedModelSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ModelName": types.StringType, + "ModelVersion": types.StringType, + "Name": types.StringType, + }, + } +} + type ServedModelState struct { // The state of the served entity deployment. DEPLOYMENT_CREATING indicates // that the served entity is not ready yet because the deployment is still @@ -1761,6 +2503,15 @@ func (a ServedModelState) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ServedModelState) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Deployment": types.StringType, + "DeploymentStateMessage": types.StringType, + }, + } +} + type ServerLogsResponse struct { // The most recent log lines of the model server processing invocation // requests. @@ -1777,12 +2528,20 @@ func (a ServerLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ServerLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Logs": types.StringType, + }, + } +} + type ServingEndpoint struct { // The AI Gateway configuration for the serving endpoint. NOTE: Only // external model endpoints are currently supported. - AiGateway types.Object `tfsdk:"ai_gateway" tf:"optional,object"` + AiGateway types.List `tfsdk:"ai_gateway" tf:"optional,object"` // The config that is currently being served by the endpoint. - Config types.Object `tfsdk:"config" tf:"optional,object"` + Config types.List `tfsdk:"config" tf:"optional,object"` // The timestamp when the endpoint was created in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` // The email of the user who created the serving endpoint. @@ -1795,7 +2554,7 @@ type ServingEndpoint struct { // The name of the serving endpoint. Name types.String `tfsdk:"name" tf:"optional"` // Information corresponding to the state of the serving endpoint. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // Tags attached to the serving endpoint. Tags types.List `tfsdk:"tags" tf:"optional"` // The task type of the serving endpoint. @@ -1817,6 +2576,25 @@ func (a ServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AiGateway": AiGatewayConfig{}.ToAttrType(ctx), + "Config": EndpointCoreConfigSummary{}.ToAttrType(ctx), + "CreationTimestamp": types.Int64Type, + "Creator": types.StringType, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "Name": types.StringType, + "State": EndpointState{}.ToAttrType(ctx), + "Tags": basetypes.ListType{ + ElemType: EndpointTag{}.ToAttrType(ctx), + }, + "Task": types.StringType, + }, + } +} + type ServingEndpointAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1838,6 +2616,17 @@ func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a ServingEndpointAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ServingEndpointAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -1863,18 +2652,32 @@ func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes() map[string] } } +func (a ServingEndpointAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: ServingEndpointPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type ServingEndpointDetailed struct { // The AI Gateway configuration for the serving endpoint. NOTE: Only // external model endpoints are currently supported. - AiGateway types.Object `tfsdk:"ai_gateway" tf:"optional,object"` + AiGateway types.List `tfsdk:"ai_gateway" tf:"optional,object"` // The config that is currently being served by the endpoint. - Config types.Object `tfsdk:"config" tf:"optional,object"` + Config types.List `tfsdk:"config" tf:"optional,object"` // The timestamp when the endpoint was created in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` // The email of the user who created the serving endpoint. Creator types.String `tfsdk:"creator" tf:"optional"` // Information required to query DataPlane APIs. - DataPlaneInfo types.Object `tfsdk:"data_plane_info" tf:"optional,object"` + DataPlaneInfo types.List `tfsdk:"data_plane_info" tf:"optional,object"` // Endpoint invocation url if route optimization is enabled for endpoint EndpointUrl types.String `tfsdk:"endpoint_url" tf:"optional"` // System-generated ID of the endpoint. This is used to refer to the @@ -1885,14 +2688,14 @@ type ServingEndpointDetailed struct { // The name of the serving endpoint. Name types.String `tfsdk:"name" tf:"optional"` // The config that the endpoint is attempting to update to. - PendingConfig types.Object `tfsdk:"pending_config" tf:"optional,object"` + PendingConfig types.List `tfsdk:"pending_config" tf:"optional,object"` // The permission level of the principal making the request. PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` // Boolean representing if route optimization has been enabled for the // endpoint RouteOptimized types.Bool `tfsdk:"route_optimized" tf:"optional"` // Information corresponding to the state of the serving endpoint. - State types.Object `tfsdk:"state" tf:"optional,object"` + State types.List `tfsdk:"state" tf:"optional,object"` // Tags attached to the serving endpoint. Tags types.List `tfsdk:"tags" tf:"optional"` // The task type of the serving endpoint. @@ -1916,6 +2719,30 @@ func (a ServingEndpointDetailed) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ServingEndpointDetailed) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AiGateway": AiGatewayConfig{}.ToAttrType(ctx), + "Config": EndpointCoreConfigOutput{}.ToAttrType(ctx), + "CreationTimestamp": types.Int64Type, + "Creator": types.StringType, + "DataPlaneInfo": ModelDataPlaneInfo{}.ToAttrType(ctx), + "EndpointUrl": types.StringType, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "Name": types.StringType, + "PendingConfig": EndpointPendingConfig{}.ToAttrType(ctx), + "PermissionLevel": types.StringType, + "RouteOptimized": types.BoolType, + "State": EndpointState{}.ToAttrType(ctx), + "Tags": basetypes.ListType{ + ElemType: EndpointTag{}.ToAttrType(ctx), + }, + "Task": types.StringType, + }, + } +} + type ServingEndpointPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1932,7 +2759,19 @@ func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringRead(existin func (a ServingEndpointPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a ServingEndpointPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1956,6 +2795,18 @@ func (a ServingEndpointPermissions) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ServingEndpointPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ServingEndpointAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type ServingEndpointPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1972,6 +2823,15 @@ func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a ServingEndpointPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type ServingEndpointPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The serving endpoint for which to get or manage permissions. @@ -1990,6 +2850,17 @@ func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string]ref } } +func (a ServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: ServingEndpointAccessControlRequest{}.ToAttrType(ctx), + }, + "ServingEndpointId": types.StringType, + }, + } +} + type TrafficConfig struct { // The list of routes that define traffic to each served entity. Routes types.List `tfsdk:"routes" tf:"optional"` @@ -2007,6 +2878,16 @@ func (a TrafficConfig) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TrafficConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Routes": basetypes.ListType{ + ElemType: Route{}.ToAttrType(ctx), + }, + }, + } +} + type V1ResponseChoiceElement struct { // The finish reason returned by the endpoint. FinishReason types.String `tfsdk:"finishReason" tf:"optional"` @@ -2015,7 +2896,7 @@ type V1ResponseChoiceElement struct { // The logprobs returned only by the __completions__ endpoint. Logprobs types.Int64 `tfsdk:"logprobs" tf:"optional"` // The message response from the __chat__ endpoint. - Message types.Object `tfsdk:"message" tf:"optional,object"` + Message types.List `tfsdk:"message" tf:"optional,object"` // The text response from the __completions__ endpoint. Text types.String `tfsdk:"text" tf:"optional"` } @@ -2031,3 +2912,15 @@ func (a V1ResponseChoiceElement) GetComplexFieldTypes() map[string]reflect.Type "Message": reflect.TypeOf(ChatMessage{}), } } + +func (a V1ResponseChoiceElement) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FinishReason": types.StringType, + "Index": types.Int64Type, + "Logprobs": types.Int64Type, + "Message": ChatMessage{}.ToAttrType(ctx), + "Text": types.StringType, + }, + } +} diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 23417eda2e..7ddd947a05 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package settings_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AibiDashboardEmbeddingAccessPolicy struct { @@ -30,8 +33,16 @@ func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a AibiDashboardEmbeddingAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessPolicyType": types.StringType, + }, + } +} + type AibiDashboardEmbeddingAccessPolicySetting struct { - AibiDashboardEmbeddingAccessPolicy types.Object `tfsdk:"aibi_dashboard_embedding_access_policy" tf:"object"` + AibiDashboardEmbeddingAccessPolicy types.List `tfsdk:"aibi_dashboard_embedding_access_policy" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -60,6 +71,16 @@ func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes() map[st } } +func (a AibiDashboardEmbeddingAccessPolicySetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AibiDashboardEmbeddingAccessPolicy": AibiDashboardEmbeddingAccessPolicy{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type AibiDashboardEmbeddingApprovedDomains struct { ApprovedDomains types.List `tfsdk:"approved_domains" tf:"optional"` } @@ -72,12 +93,22 @@ func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuring func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ApprovedDomains": reflect.TypeOf(""), + "ApprovedDomains": reflect.TypeOf(types.StringType), + } +} + +func (a AibiDashboardEmbeddingApprovedDomains) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApprovedDomains": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type AibiDashboardEmbeddingApprovedDomainsSetting struct { - AibiDashboardEmbeddingApprovedDomains types.Object `tfsdk:"aibi_dashboard_embedding_approved_domains" tf:"object"` + AibiDashboardEmbeddingApprovedDomains types.List `tfsdk:"aibi_dashboard_embedding_approved_domains" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -106,8 +137,18 @@ func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes() map } } +func (a AibiDashboardEmbeddingApprovedDomainsSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AibiDashboardEmbeddingApprovedDomains": AibiDashboardEmbeddingApprovedDomains{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type AutomaticClusterUpdateSetting struct { - AutomaticClusterUpdateWorkspace types.Object `tfsdk:"automatic_cluster_update_workspace" tf:"object"` + AutomaticClusterUpdateWorkspace types.List `tfsdk:"automatic_cluster_update_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -136,6 +177,16 @@ func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes() map[string]reflect } } +func (a AutomaticClusterUpdateSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutomaticClusterUpdateWorkspace": ClusterAutoRestartMessage{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type BooleanMessage struct { Value types.Bool `tfsdk:"value" tf:"optional"` } @@ -150,6 +201,14 @@ func (a BooleanMessage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a BooleanMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Value": types.BoolType, + }, + } +} + type ClusterAutoRestartMessage struct { CanToggle types.Bool `tfsdk:"can_toggle" tf:"optional"` @@ -160,9 +219,9 @@ type ClusterAutoRestartMessage struct { // intended to use only for purposes like showing an error message to the // customer with the additional details. For example, using these details we // can check why exactly the feature is disabled for this customer. - EnablementDetails types.Object `tfsdk:"enablement_details" tf:"optional,object"` + EnablementDetails types.List `tfsdk:"enablement_details" tf:"optional,object"` - MaintenanceWindow types.Object `tfsdk:"maintenance_window" tf:"optional,object"` + MaintenanceWindow types.List `tfsdk:"maintenance_window" tf:"optional,object"` RestartEvenIfNoUpdatesAvailable types.Bool `tfsdk:"restart_even_if_no_updates_available" tf:"optional"` } @@ -180,6 +239,18 @@ func (a ClusterAutoRestartMessage) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ClusterAutoRestartMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CanToggle": types.BoolType, + "Enabled": types.BoolType, + "EnablementDetails": ClusterAutoRestartMessageEnablementDetails{}.ToAttrType(ctx), + "MaintenanceWindow": ClusterAutoRestartMessageMaintenanceWindow{}.ToAttrType(ctx), + "RestartEvenIfNoUpdatesAvailable": types.BoolType, + }, + } +} + // Contains an information about the enablement status judging (e.g. whether the // enterprise tier is enabled) This is only additional information that MUST NOT // be used to decide whether the setting is enabled or not. This is intended to @@ -206,8 +277,18 @@ func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes() map[s return map[string]reflect.Type{} } +func (a ClusterAutoRestartMessageEnablementDetails) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ForcedForComplianceMode": types.BoolType, + "UnavailableForDisabledEntitlement": types.BoolType, + "UnavailableForNonEnterpriseTier": types.BoolType, + }, + } +} + type ClusterAutoRestartMessageMaintenanceWindow struct { - WeekDayBasedSchedule types.Object `tfsdk:"week_day_based_schedule" tf:"optional,object"` + WeekDayBasedSchedule types.List `tfsdk:"week_day_based_schedule" tf:"optional,object"` } func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterAutoRestartMessageMaintenanceWindow) { @@ -222,12 +303,20 @@ func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes() map[s } } +func (a ClusterAutoRestartMessageMaintenanceWindow) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WeekDayBasedSchedule": ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.ToAttrType(ctx), + }, + } +} + type ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule struct { DayOfWeek types.String `tfsdk:"day_of_week" tf:"optional"` Frequency types.String `tfsdk:"frequency" tf:"optional"` - WindowStartTime types.Object `tfsdk:"window_start_time" tf:"optional,object"` + WindowStartTime types.List `tfsdk:"window_start_time" tf:"optional,object"` } func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) { @@ -242,6 +331,16 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetCompl } } +func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DayOfWeek": types.StringType, + "Frequency": types.StringType, + "WindowStartTime": ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.ToAttrType(ctx), + }, + } +} + type ClusterAutoRestartMessageMaintenanceWindowWindowStartTime struct { Hours types.Int64 `tfsdk:"hours" tf:"optional"` @@ -258,6 +357,15 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFie return map[string]reflect.Type{} } +func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Hours": types.Int64Type, + "Minutes": types.Int64Type, + }, + } +} + // SHIELD feature: CSP type ComplianceSecurityProfile struct { // Set by customers when they request Compliance Security Profile (CSP) @@ -274,13 +382,24 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existin func (a ComplianceSecurityProfile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ComplianceStandards": reflect.TypeOf(""), + "ComplianceStandards": reflect.TypeOf(types.StringType), + } +} + +func (a ComplianceSecurityProfile) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ComplianceStandards": basetypes.ListType{ + ElemType: types.StringType, + }, + "IsEnabled": types.BoolType, + }, } } type ComplianceSecurityProfileSetting struct { // SHIELD feature: CSP - ComplianceSecurityProfileWorkspace types.Object `tfsdk:"compliance_security_profile_workspace" tf:"object"` + ComplianceSecurityProfileWorkspace types.List `tfsdk:"compliance_security_profile_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -309,16 +428,26 @@ func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes() map[string]refl } } +func (a ComplianceSecurityProfileSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ComplianceSecurityProfileWorkspace": ComplianceSecurityProfile{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type Config struct { - Email types.Object `tfsdk:"email" tf:"optional,object"` + Email types.List `tfsdk:"email" tf:"optional,object"` - GenericWebhook types.Object `tfsdk:"generic_webhook" tf:"optional,object"` + GenericWebhook types.List `tfsdk:"generic_webhook" tf:"optional,object"` - MicrosoftTeams types.Object `tfsdk:"microsoft_teams" tf:"optional,object"` + MicrosoftTeams types.List `tfsdk:"microsoft_teams" tf:"optional,object"` - Pagerduty types.Object `tfsdk:"pagerduty" tf:"optional,object"` + Pagerduty types.List `tfsdk:"pagerduty" tf:"optional,object"` - Slack types.Object `tfsdk:"slack" tf:"optional,object"` + Slack types.List `tfsdk:"slack" tf:"optional,object"` } func (newState *Config) SyncEffectiveFieldsDuringCreateOrUpdate(plan Config) { @@ -337,6 +466,18 @@ func (a Config) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Config) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Email": EmailConfig{}.ToAttrType(ctx), + "GenericWebhook": GenericWebhookConfig{}.ToAttrType(ctx), + "MicrosoftTeams": MicrosoftTeamsConfig{}.ToAttrType(ctx), + "Pagerduty": PagerdutyConfig{}.ToAttrType(ctx), + "Slack": SlackConfig{}.ToAttrType(ctx), + }, + } +} + // Details required to configure a block list or allow list. type CreateIpAccessList struct { IpAddresses types.List `tfsdk:"ip_addresses" tf:"optional"` @@ -359,14 +500,26 @@ func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a CreateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(""), + "IpAddresses": reflect.TypeOf(types.StringType), + } +} + +func (a CreateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAddresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "Label": types.StringType, + "ListType": types.StringType, + }, } } // An IP access list was successfully created. type CreateIpAccessListResponse struct { // Definition of an IP Access list - IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.List `tfsdk:"ip_access_list" tf:"optional,object"` } func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateIpAccessListResponse) { @@ -381,6 +534,14 @@ func (a CreateIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a CreateIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessList": IpAccessListInfo{}.ToAttrType(ctx), + }, + } +} + type CreateNetworkConnectivityConfigRequest struct { // The name of the network connectivity configuration. The name can contain // alphanumeric characters, hyphens, and underscores. The length must be @@ -403,10 +564,19 @@ func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes() map[strin return map[string]reflect.Type{} } +func (a CreateNetworkConnectivityConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Region": types.StringType, + }, + } +} + type CreateNotificationDestinationRequest struct { // The configuration for the notification destination. Must wrap EXACTLY one // of the nested configs. - Config types.Object `tfsdk:"config" tf:"optional,object"` + Config types.List `tfsdk:"config" tf:"optional,object"` // The display name for the notification destination. DisplayName types.String `tfsdk:"display_name" tf:"optional"` } @@ -423,6 +593,15 @@ func (a CreateNotificationDestinationRequest) GetComplexFieldTypes() map[string] } } +func (a CreateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Config": Config{}.ToAttrType(ctx), + "DisplayName": types.StringType, + }, + } +} + // Configuration details for creating on-behalf tokens. type CreateOboTokenRequest struct { // Application ID of the service principal. @@ -443,9 +622,19 @@ func (a CreateOboTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateOboTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplicationId": types.StringType, + "Comment": types.StringType, + "LifetimeSeconds": types.Int64Type, + }, + } +} + // An on-behalf token was successfully created for the service principal. type CreateOboTokenResponse struct { - TokenInfo types.Object `tfsdk:"token_info" tf:"optional,object"` + TokenInfo types.List `tfsdk:"token_info" tf:"optional,object"` // Value of the token. TokenValue types.String `tfsdk:"token_value" tf:"optional"` } @@ -462,6 +651,15 @@ func (a CreateOboTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateOboTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenInfo": TokenInfo{}.ToAttrType(ctx), + "TokenValue": types.StringType, + }, + } +} + type CreatePrivateEndpointRuleRequest struct { // The sub-resource type (group ID) of the target resource. Note that to // connect to workspace root storage (root DBFS), you need two endpoints, @@ -483,6 +681,16 @@ func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a CreatePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupId": types.StringType, + "NetworkConnectivityConfigId": types.StringType, + "ResourceId": types.StringType, + }, + } +} + type CreateTokenRequest struct { // Optional description to attach to the token. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -502,9 +710,18 @@ func (a CreateTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "LifetimeSeconds": types.Int64Type, + }, + } +} + type CreateTokenResponse struct { // The information for the new token. - TokenInfo types.Object `tfsdk:"token_info" tf:"optional,object"` + TokenInfo types.List `tfsdk:"token_info" tf:"optional,object"` // The value of the new token. TokenValue types.String `tfsdk:"token_value" tf:"optional"` } @@ -521,6 +738,15 @@ func (a CreateTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenInfo": PublicTokenInfo{}.ToAttrType(ctx), + "TokenValue": types.StringType, + }, + } +} + // Account level policy for CSP type CspEnablementAccount struct { // Set by customers when they request Compliance Security Profile (CSP) @@ -538,13 +764,24 @@ func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringRead(existingStat func (a CspEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ComplianceStandards": reflect.TypeOf(""), + "ComplianceStandards": reflect.TypeOf(types.StringType), + } +} + +func (a CspEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ComplianceStandards": basetypes.ListType{ + ElemType: types.StringType, + }, + "IsEnforced": types.BoolType, + }, } } type CspEnablementAccountSetting struct { // Account level policy for CSP - CspEnablementAccount types.Object `tfsdk:"csp_enablement_account" tf:"object"` + CspEnablementAccount types.List `tfsdk:"csp_enablement_account" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -573,6 +810,16 @@ func (a CspEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.T } } +func (a CspEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CspEnablementAccount": CspEnablementAccount{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + // This represents the setting configuration for the default namespace in the // Databricks workspace. Setting the default catalog for the workspace // determines the catalog that is used when queries do not reference a fully @@ -592,7 +839,7 @@ type DefaultNamespaceSetting struct { // PATCH request to identify the setting version you are updating. Etag types.String `tfsdk:"etag" tf:"optional"` - Namespace types.Object `tfsdk:"namespace" tf:"object"` + Namespace types.List `tfsdk:"namespace" tf:"object"` // Name of the corresponding setting. This field is populated in the // response, but it will not be respected even if it's set in the request // body. The setting name in the path parameter will be respected instead. @@ -613,6 +860,16 @@ func (a DefaultNamespaceSetting) GetComplexFieldTypes() map[string]reflect.Type } } +func (a DefaultNamespaceSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + "Namespace": StringMessage{}.ToAttrType(ctx), + "SettingName": types.StringType, + }, + } +} + // Delete access list type DeleteAccountIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -629,6 +886,14 @@ func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a DeleteAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessListId": types.StringType, + }, + } +} + // Delete the default namespace setting type DeleteDefaultNamespaceSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -651,6 +916,14 @@ func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a DeleteDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // The etag is returned. type DeleteDefaultNamespaceSettingResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -673,6 +946,14 @@ func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a DeleteDefaultNamespaceSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Delete Legacy Access Disablement Status type DeleteDisableLegacyAccessRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -695,6 +976,14 @@ func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a DeleteDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // The etag is returned. type DeleteDisableLegacyAccessResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -717,6 +1006,14 @@ func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a DeleteDisableLegacyAccessResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Delete the disable legacy DBFS setting type DeleteDisableLegacyDbfsRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -739,6 +1036,14 @@ func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a DeleteDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // The etag is returned. type DeleteDisableLegacyDbfsResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -761,6 +1066,14 @@ func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a DeleteDisableLegacyDbfsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Delete the disable legacy features setting type DeleteDisableLegacyFeaturesRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -783,6 +1096,14 @@ func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a DeleteDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // The etag is returned. type DeleteDisableLegacyFeaturesResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -805,6 +1126,14 @@ func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a DeleteDisableLegacyFeaturesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Delete access list type DeleteIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -821,6 +1150,14 @@ func (a DeleteIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessListId": types.StringType, + }, + } +} + // Delete a network connectivity configuration type DeleteNetworkConnectivityConfigurationRequest struct { // Your Network Connectvity Configuration ID. @@ -837,6 +1174,14 @@ func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() ma return map[string]reflect.Type{} } +func (a DeleteNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkConnectivityConfigId": types.StringType, + }, + } +} + type DeleteNetworkConnectivityConfigurationResponse struct { } @@ -850,6 +1195,12 @@ func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes() m return map[string]reflect.Type{} } +func (a DeleteNetworkConnectivityConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a notification destination type DeleteNotificationDestinationRequest struct { Id types.String `tfsdk:"-"` @@ -865,6 +1216,14 @@ func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a DeleteNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete Personal Compute setting type DeletePersonalComputeSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -887,6 +1246,14 @@ func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a DeletePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // The etag is returned. type DeletePersonalComputeSettingResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -909,6 +1276,14 @@ func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a DeletePersonalComputeSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Delete a private endpoint rule type DeletePrivateEndpointRuleRequest struct { // Your Network Connectvity Configuration ID. @@ -927,6 +1302,15 @@ func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a DeletePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkConnectivityConfigId": types.StringType, + "PrivateEndpointRuleId": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -940,6 +1324,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete the restrict workspace admins setting type DeleteRestrictWorkspaceAdminsSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -962,6 +1352,14 @@ func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[ return map[string]reflect.Type{} } +func (a DeleteRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // The etag is returned. type DeleteRestrictWorkspaceAdminsSettingResponse struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -984,6 +1382,14 @@ func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes() map return map[string]reflect.Type{} } +func (a DeleteRestrictWorkspaceAdminsSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Delete a token type DeleteTokenManagementRequest struct { // The ID of the token to revoke. @@ -1000,8 +1406,16 @@ func (a DeleteTokenManagementRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenId": types.StringType, + }, + } +} + type DisableLegacyAccess struct { - DisableLegacyAccess types.Object `tfsdk:"disable_legacy_access" tf:"object"` + DisableLegacyAccess types.List `tfsdk:"disable_legacy_access" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -1030,8 +1444,18 @@ func (a DisableLegacyAccess) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DisableLegacyAccess) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisableLegacyAccess": BooleanMessage{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type DisableLegacyDbfs struct { - DisableLegacyDbfs types.Object `tfsdk:"disable_legacy_dbfs" tf:"object"` + DisableLegacyDbfs types.List `tfsdk:"disable_legacy_dbfs" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -1060,8 +1484,18 @@ func (a DisableLegacyDbfs) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DisableLegacyDbfs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisableLegacyDbfs": BooleanMessage{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type DisableLegacyFeatures struct { - DisableLegacyFeatures types.Object `tfsdk:"disable_legacy_features" tf:"object"` + DisableLegacyFeatures types.List `tfsdk:"disable_legacy_features" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -1090,6 +1524,16 @@ func (a DisableLegacyFeatures) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DisableLegacyFeatures) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisableLegacyFeatures": BooleanMessage{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + type EmailConfig struct { // Email addresses to notify. Addresses types.List `tfsdk:"addresses" tf:"optional"` @@ -1103,7 +1547,17 @@ func (newState *EmailConfig) SyncEffectiveFieldsDuringRead(existingState EmailCo func (a EmailConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Addresses": reflect.TypeOf(""), + "Addresses": reflect.TypeOf(types.StringType), + } +} + +func (a EmailConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Addresses": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1120,6 +1574,12 @@ func (a Empty) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Empty) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // SHIELD feature: ESM type EnhancedSecurityMonitoring struct { IsEnabled types.Bool `tfsdk:"is_enabled" tf:"optional"` @@ -1135,9 +1595,17 @@ func (a EnhancedSecurityMonitoring) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a EnhancedSecurityMonitoring) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsEnabled": types.BoolType, + }, + } +} + type EnhancedSecurityMonitoringSetting struct { // SHIELD feature: ESM - EnhancedSecurityMonitoringWorkspace types.Object `tfsdk:"enhanced_security_monitoring_workspace" tf:"object"` + EnhancedSecurityMonitoringWorkspace types.List `tfsdk:"enhanced_security_monitoring_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -1166,6 +1634,16 @@ func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes() map[string]ref } } +func (a EnhancedSecurityMonitoringSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EnhancedSecurityMonitoringWorkspace": EnhancedSecurityMonitoring{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + // Account level policy for ESM type EsmEnablementAccount struct { IsEnforced types.Bool `tfsdk:"is_enforced" tf:"optional"` @@ -1181,9 +1659,17 @@ func (a EsmEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EsmEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IsEnforced": types.BoolType, + }, + } +} + type EsmEnablementAccountSetting struct { // Account level policy for ESM - EsmEnablementAccount types.Object `tfsdk:"esm_enablement_account" tf:"object"` + EsmEnablementAccount types.List `tfsdk:"esm_enablement_account" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to // help prevent simultaneous writes of a setting overwriting each other. It @@ -1212,6 +1698,16 @@ func (a EsmEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.T } } +func (a EsmEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EsmEnablementAccount": EsmEnablementAccount{}.ToAttrType(ctx), + "Etag": types.StringType, + "SettingName": types.StringType, + }, + } +} + // The exchange token is the result of the token exchange with the IdP type ExchangeToken struct { // The requested token. @@ -1235,14 +1731,28 @@ func (newState *ExchangeToken) SyncEffectiveFieldsDuringRead(existingState Excha func (a ExchangeToken) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Scopes": reflect.TypeOf(""), + "Scopes": reflect.TypeOf(types.StringType), + } +} + +func (a ExchangeToken) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Credential": types.StringType, + "CredentialEolTime": types.Int64Type, + "OwnerId": types.Int64Type, + "Scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + "TokenType": types.StringType, + }, } } // Exchange a token with the IdP type ExchangeTokenRequest struct { // The partition of Credentials store - PartitionId types.Object `tfsdk:"partitionId" tf:"object"` + PartitionId types.List `tfsdk:"partitionId" tf:"object"` // Array of scopes for the token request. Scopes types.List `tfsdk:"scopes" tf:""` // A list of token types being requested @@ -1258,8 +1768,22 @@ func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringRead(existingStat func (a ExchangeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "PartitionId": reflect.TypeOf(PartitionId{}), - "Scopes": reflect.TypeOf(""), - "TokenType": reflect.TypeOf(""), + "Scopes": reflect.TypeOf(types.StringType), + "TokenType": reflect.TypeOf(types.StringType), + } +} + +func (a ExchangeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PartitionId": PartitionId{}.ToAttrType(ctx), + "Scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + "TokenType": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1280,10 +1804,20 @@ func (a ExchangeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ExchangeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Values": basetypes.ListType{ + ElemType: ExchangeToken{}.ToAttrType(ctx), + }, + }, + } +} + // An IP access list was successfully returned. type FetchIpAccessListResponse struct { // Definition of an IP Access list - IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.List `tfsdk:"ip_access_list" tf:"optional,object"` } func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan FetchIpAccessListResponse) { @@ -1298,6 +1832,14 @@ func (a FetchIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a FetchIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessList": IpAccessListInfo{}.ToAttrType(ctx), + }, + } +} + type GenericWebhookConfig struct { // [Input-Only][Optional] Password for webhook. Password types.String `tfsdk:"password" tf:"optional"` @@ -1323,6 +1865,19 @@ func (a GenericWebhookConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GenericWebhookConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Password": types.StringType, + "PasswordSet": types.BoolType, + "Url": types.StringType, + "UrlSet": types.BoolType, + "Username": types.StringType, + "UsernameSet": types.BoolType, + }, + } +} + // Get IP access list type GetAccountIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -1339,6 +1894,14 @@ func (a GetAccountIpAccessListRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessListId": types.StringType, + }, + } +} + // Retrieve the AI/BI dashboard embedding access policy type GetAibiDashboardEmbeddingAccessPolicySettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1361,6 +1924,14 @@ func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldType return map[string]reflect.Type{} } +func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Retrieve the list of domains approved to host embedded AI/BI dashboards type GetAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1383,6 +1954,14 @@ func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldT return map[string]reflect.Type{} } +func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the automatic cluster update setting type GetAutomaticClusterUpdateSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1405,6 +1984,14 @@ func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a GetAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the compliance security profile setting type GetComplianceSecurityProfileSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1427,6 +2014,14 @@ func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[s return map[string]reflect.Type{} } +func (a GetComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the compliance security profile setting for new workspaces type GetCspEnablementAccountSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1449,6 +2044,14 @@ func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a GetCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the default namespace setting type GetDefaultNamespaceSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1471,6 +2074,14 @@ func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Retrieve Legacy Access Disablement Status type GetDisableLegacyAccessRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1493,6 +2104,14 @@ func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the disable legacy DBFS setting type GetDisableLegacyDbfsRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1515,6 +2134,14 @@ func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the disable legacy features setting type GetDisableLegacyFeaturesRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1537,6 +2164,14 @@ func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a GetDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the enhanced security monitoring setting type GetEnhancedSecurityMonitoringSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1559,6 +2194,14 @@ func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[ return map[string]reflect.Type{} } +func (a GetEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get the enhanced security monitoring setting for new workspaces type GetEsmEnablementAccountSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1581,6 +2224,14 @@ func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a GetEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get access list type GetIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -1597,9 +2248,17 @@ func (a GetIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessListId": types.StringType, + }, + } +} + type GetIpAccessListResponse struct { // Definition of an IP Access list - IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.List `tfsdk:"ip_access_list" tf:"optional,object"` } func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetIpAccessListResponse) { @@ -1614,6 +2273,14 @@ func (a GetIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a GetIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessList": IpAccessListInfo{}.ToAttrType(ctx), + }, + } +} + // IP access lists were successfully returned. type GetIpAccessListsResponse struct { IpAccessLists types.List `tfsdk:"ip_access_lists" tf:"optional"` @@ -1631,6 +2298,16 @@ func (a GetIpAccessListsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a GetIpAccessListsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessLists": basetypes.ListType{ + ElemType: IpAccessListInfo{}.ToAttrType(ctx), + }, + }, + } +} + // Get a network connectivity configuration type GetNetworkConnectivityConfigurationRequest struct { // Your Network Connectvity Configuration ID. @@ -1647,6 +2324,14 @@ func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() map[s return map[string]reflect.Type{} } +func (a GetNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkConnectivityConfigId": types.StringType, + }, + } +} + // Get a notification destination type GetNotificationDestinationRequest struct { Id types.String `tfsdk:"-"` @@ -1662,6 +2347,14 @@ func (a GetNotificationDestinationRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a GetNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Get Personal Compute setting type GetPersonalComputeSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1684,6 +2377,14 @@ func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a GetPersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Get a private endpoint rule type GetPrivateEndpointRuleRequest struct { // Your Network Connectvity Configuration ID. @@ -1702,6 +2403,15 @@ func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a GetPrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkConnectivityConfigId": types.StringType, + "PrivateEndpointRuleId": types.StringType, + }, + } +} + // Get the restrict workspace admins setting type GetRestrictWorkspaceAdminsSettingRequest struct { // etag used for versioning. The response is at least as fresh as the eTag @@ -1724,6 +2434,14 @@ func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[str return map[string]reflect.Type{} } +func (a GetRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + }, + } +} + // Check configuration status type GetStatusRequest struct { Keys types.String `tfsdk:"-"` @@ -1739,6 +2457,14 @@ func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Keys": types.StringType, + }, + } +} + // Get token info type GetTokenManagementRequest struct { // The ID of the token to get. @@ -1755,6 +2481,14 @@ func (a GetTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a GetTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenId": types.StringType, + }, + } +} + type GetTokenPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -1772,9 +2506,19 @@ func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes() map[string]refl } } +func (a GetTokenPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: TokenPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Token with specified Token ID was successfully returned. type GetTokenResponse struct { - TokenInfo types.Object `tfsdk:"token_info" tf:"optional,object"` + TokenInfo types.List `tfsdk:"token_info" tf:"optional,object"` } func (newState *GetTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetTokenResponse) { @@ -1789,6 +2533,14 @@ func (a GetTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenInfo": TokenInfo{}.ToAttrType(ctx), + }, + } +} + // Definition of an IP Access list type IpAccessListInfo struct { // Total number of IP or CIDR values. @@ -1826,7 +2578,26 @@ func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringRead(existingState Ip func (a IpAccessListInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(""), + "IpAddresses": reflect.TypeOf(types.StringType), + } +} + +func (a IpAccessListInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AddressCount": types.Int64Type, + "CreatedAt": types.Int64Type, + "CreatedBy": types.Int64Type, + "Enabled": types.BoolType, + "IpAddresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "Label": types.StringType, + "ListId": types.StringType, + "ListType": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.Int64Type, + }, } } @@ -1847,6 +2618,16 @@ func (a ListIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IpAccessLists": basetypes.ListType{ + ElemType: IpAccessListInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ListNccAzurePrivateEndpointRulesResponse struct { Items types.List `tfsdk:"items" tf:"optional"` // A token that can be used to get the next page of results. If null, there @@ -1866,6 +2647,17 @@ func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes() map[str } } +func (a ListNccAzurePrivateEndpointRulesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Items": basetypes.ListType{ + ElemType: NccAzurePrivateEndpointRule{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List network connectivity configurations type ListNetworkConnectivityConfigurationsRequest struct { // Pagination token to go to next page based on previous query. @@ -1882,6 +2674,14 @@ func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes() map return map[string]reflect.Type{} } +func (a ListNetworkConnectivityConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageToken": types.StringType, + }, + } +} + type ListNetworkConnectivityConfigurationsResponse struct { Items types.List `tfsdk:"items" tf:"optional"` // A token that can be used to get the next page of results. If null, there @@ -1901,6 +2701,17 @@ func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes() ma } } +func (a ListNetworkConnectivityConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Items": basetypes.ListType{ + ElemType: NetworkConnectivityConfiguration{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List notification destinations type ListNotificationDestinationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -1918,6 +2729,15 @@ func (a ListNotificationDestinationsRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a ListNotificationDestinationsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListNotificationDestinationsResponse struct { // Page token for next of results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1937,6 +2757,17 @@ func (a ListNotificationDestinationsResponse) GetComplexFieldTypes() map[string] } } +func (a ListNotificationDestinationsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Results": basetypes.ListType{ + ElemType: ListNotificationDestinationsResult{}.ToAttrType(ctx), + }, + }, + } +} + type ListNotificationDestinationsResult struct { // [Output-only] The type of the notification destination. The type can not // be changed once set. @@ -1957,6 +2788,16 @@ func (a ListNotificationDestinationsResult) GetComplexFieldTypes() map[string]re return map[string]reflect.Type{} } +func (a ListNotificationDestinationsResult) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DestinationType": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + }, + } +} + // List private endpoint rules type ListPrivateEndpointRulesRequest struct { // Your Network Connectvity Configuration ID. @@ -1975,6 +2816,15 @@ func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a ListPrivateEndpointRulesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NetworkConnectivityConfigId": types.StringType, + "PageToken": types.StringType, + }, + } +} + type ListPublicTokensResponse struct { // The information for each token. TokenInfos types.List `tfsdk:"token_infos" tf:"optional"` @@ -1992,6 +2842,16 @@ func (a ListPublicTokensResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListPublicTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenInfos": basetypes.ListType{ + ElemType: PublicTokenInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List all tokens type ListTokenManagementRequest struct { // User ID of the user that created the token. @@ -2010,6 +2870,15 @@ func (a ListTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a ListTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedById": types.Int64Type, + "CreatedByUsername": types.StringType, + }, + } +} + // Tokens were successfully returned. type ListTokensResponse struct { // Token metadata of each user-created token in the workspace @@ -2028,6 +2897,16 @@ func (a ListTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenInfos": basetypes.ListType{ + ElemType: TokenInfo{}.ToAttrType(ctx), + }, + }, + } +} + type MicrosoftTeamsConfig struct { // [Input-Only] URL for Microsoft Teams. Url types.String `tfsdk:"url" tf:"optional"` @@ -2045,6 +2924,15 @@ func (a MicrosoftTeamsConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MicrosoftTeamsConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Url": types.StringType, + "UrlSet": types.BoolType, + }, + } +} + // The stable AWS IP CIDR blocks. You can use these to configure the firewall of // your resources to allow traffic from your Databricks workspace. type NccAwsStableIpRule struct { @@ -2061,7 +2949,17 @@ func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringRead(existingState func (a NccAwsStableIpRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CidrBlocks": reflect.TypeOf(""), + "CidrBlocks": reflect.TypeOf(types.StringType), + } +} + +func (a NccAwsStableIpRule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CidrBlocks": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -2113,6 +3011,23 @@ func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a NccAzurePrivateEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConnectionState": types.StringType, + "CreationTime": types.Int64Type, + "Deactivated": types.BoolType, + "DeactivatedAt": types.Int64Type, + "EndpointName": types.StringType, + "GroupId": types.StringType, + "NetworkConnectivityConfigId": types.StringType, + "ResourceId": types.StringType, + "RuleId": types.StringType, + "UpdatedTime": types.Int64Type, + }, + } +} + // The stable Azure service endpoints. You can configure the firewall of your // Azure resources to allow traffic from your Databricks serverless compute // resources. @@ -2134,8 +3049,22 @@ func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringRead(exist func (a NccAzureServiceEndpointRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subnets": reflect.TypeOf(""), - "TargetServices": reflect.TypeOf(""), + "Subnets": reflect.TypeOf(types.StringType), + "TargetServices": reflect.TypeOf(types.StringType), + } +} + +func (a NccAzureServiceEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Subnets": basetypes.ListType{ + ElemType: types.StringType, + }, + "TargetRegion": types.StringType, + "TargetServices": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -2145,10 +3074,10 @@ type NccEgressConfig struct { // The network connectivity rules that are applied by default without // resource specific configurations. You can find the stable network // information of your serverless compute resources here. - DefaultRules types.Object `tfsdk:"default_rules" tf:"computed,optional"` + DefaultRules types.List `tfsdk:"default_rules" tf:"computed,optional"` // The network connectivity rules that configured for each destinations. // These rules override default rules. - TargetRules types.Object `tfsdk:"target_rules" tf:"optional,object"` + TargetRules types.List `tfsdk:"target_rules" tf:"optional,object"` } func (newState *NccEgressConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccEgressConfig) { @@ -2164,6 +3093,15 @@ func (a NccEgressConfig) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a NccEgressConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DefaultRules": NccEgressDefaultRules{}.ToAttrType(ctx), + "TargetRules": NccEgressTargetRules{}.ToAttrType(ctx), + }, + } +} + // The network connectivity rules that are applied by default without resource // specific configurations. You can find the stable network information of your // serverless compute resources here. @@ -2171,11 +3109,11 @@ type NccEgressDefaultRules struct { // The stable AWS IP CIDR blocks. You can use these to configure the // firewall of your resources to allow traffic from your Databricks // workspace. - AwsStableIpRule types.Object `tfsdk:"aws_stable_ip_rule" tf:"optional,object"` + AwsStableIpRule types.List `tfsdk:"aws_stable_ip_rule" tf:"optional,object"` // The stable Azure service endpoints. You can configure the firewall of // your Azure resources to allow traffic from your Databricks serverless // compute resources. - AzureServiceEndpointRule types.Object `tfsdk:"azure_service_endpoint_rule" tf:"optional,object"` + AzureServiceEndpointRule types.List `tfsdk:"azure_service_endpoint_rule" tf:"optional,object"` } func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan NccEgressDefaultRules) { @@ -2191,6 +3129,15 @@ func (a NccEgressDefaultRules) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a NccEgressDefaultRules) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AwsStableIpRule": NccAwsStableIpRule{}.ToAttrType(ctx), + "AzureServiceEndpointRule": NccAzureServiceEndpointRule{}.ToAttrType(ctx), + }, + } +} + // The network connectivity rules that configured for each destinations. These // rules override default rules. type NccEgressTargetRules struct { @@ -2209,6 +3156,16 @@ func (a NccEgressTargetRules) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a NccEgressTargetRules) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AzurePrivateEndpointRules": basetypes.ListType{ + ElemType: NccAzurePrivateEndpointRule{}.ToAttrType(ctx), + }, + }, + } +} + type NetworkConnectivityConfiguration struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -2216,7 +3173,7 @@ type NetworkConnectivityConfiguration struct { CreationTime types.Int64 `tfsdk:"creation_time" tf:"computed,optional"` // The network connectivity rules that apply to network traffic from your // serverless compute resources. - EgressConfig types.Object `tfsdk:"egress_config" tf:"optional,object"` + EgressConfig types.List `tfsdk:"egress_config" tf:"optional,object"` // The name of the network connectivity configuration. The name can contain // alphanumeric characters, hyphens, and underscores. The length must be // between 3 and 30 characters. The name must match the regular expression @@ -2244,11 +3201,25 @@ func (a NetworkConnectivityConfiguration) GetComplexFieldTypes() map[string]refl } } +func (a NetworkConnectivityConfiguration) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccountId": types.StringType, + "CreationTime": types.Int64Type, + "EgressConfig": NccEgressConfig{}.ToAttrType(ctx), + "Name": types.StringType, + "NetworkConnectivityConfigId": types.StringType, + "Region": types.StringType, + "UpdatedTime": types.Int64Type, + }, + } +} + type NotificationDestination struct { // The configuration for the notification destination. Will be exactly one // of the nested configs. Only returns for users with workspace admin // permissions. - Config types.Object `tfsdk:"config" tf:"optional,object"` + Config types.List `tfsdk:"config" tf:"optional,object"` // [Output-only] The type of the notification destination. The type can not // be changed once set. DestinationType types.String `tfsdk:"destination_type" tf:"optional"` @@ -2270,6 +3241,17 @@ func (a NotificationDestination) GetComplexFieldTypes() map[string]reflect.Type } } +func (a NotificationDestination) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Config": Config{}.ToAttrType(ctx), + "DestinationType": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + }, + } +} + type PagerdutyConfig struct { // [Input-Only] Integration key for PagerDuty. IntegrationKey types.String `tfsdk:"integration_key" tf:"optional"` @@ -2287,6 +3269,15 @@ func (a PagerdutyConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PagerdutyConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IntegrationKey": types.StringType, + "IntegrationKeySet": types.BoolType, + }, + } +} + // Partition by workspace or account type PartitionId struct { // The ID of the workspace. @@ -2303,6 +3294,14 @@ func (a PartitionId) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PartitionId) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceId": types.Int64Type, + }, + } +} + type PersonalComputeMessage struct { // ON: Grants all users in all workspaces access to the Personal Compute // default policy, allowing all users to create single-machine compute @@ -2324,6 +3323,14 @@ func (a PersonalComputeMessage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PersonalComputeMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Value": types.StringType, + }, + } +} + type PersonalComputeSetting struct { // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to @@ -2334,7 +3341,7 @@ type PersonalComputeSetting struct { // PATCH request to identify the setting version you are updating. Etag types.String `tfsdk:"etag" tf:"optional"` - PersonalCompute types.Object `tfsdk:"personal_compute" tf:"object"` + PersonalCompute types.List `tfsdk:"personal_compute" tf:"object"` // Name of the corresponding setting. This field is populated in the // response, but it will not be respected even if it's set in the request // body. The setting name in the path parameter will be respected instead. @@ -2355,6 +3362,16 @@ func (a PersonalComputeSetting) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a PersonalComputeSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + "PersonalCompute": PersonalComputeMessage{}.ToAttrType(ctx), + "SettingName": types.StringType, + }, + } +} + type PublicTokenInfo struct { // Comment the token was created with, if applicable. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -2377,6 +3394,17 @@ func (a PublicTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PublicTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "CreationTime": types.Int64Type, + "ExpiryTime": types.Int64Type, + "TokenId": types.StringType, + }, + } +} + // Details required to replace an IP access list. type ReplaceIpAccessList struct { // Specifies whether this IP access list is enabled. @@ -2404,7 +3432,21 @@ func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a ReplaceIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(""), + "IpAddresses": reflect.TypeOf(types.StringType), + } +} + +func (a ReplaceIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + "IpAccessListId": types.StringType, + "IpAddresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "Label": types.StringType, + "ListType": types.StringType, + }, } } @@ -2421,6 +3463,12 @@ func (a ReplaceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ReplaceResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type RestrictWorkspaceAdminsMessage struct { Status types.String `tfsdk:"status" tf:""` } @@ -2435,6 +3483,14 @@ func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a RestrictWorkspaceAdminsMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Status": types.StringType, + }, + } +} + type RestrictWorkspaceAdminsSetting struct { // etag used for versioning. The response is at least as fresh as the eTag // provided. This is used for optimistic concurrency control as a way to @@ -2445,7 +3501,7 @@ type RestrictWorkspaceAdminsSetting struct { // PATCH request to identify the setting version you are updating. Etag types.String `tfsdk:"etag" tf:"optional"` - RestrictWorkspaceAdmins types.Object `tfsdk:"restrict_workspace_admins" tf:"object"` + RestrictWorkspaceAdmins types.List `tfsdk:"restrict_workspace_admins" tf:"object"` // Name of the corresponding setting. This field is populated in the // response, but it will not be respected even if it's set in the request // body. The setting name in the path parameter will be respected instead. @@ -2466,6 +3522,16 @@ func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes() map[string]reflec } } +func (a RestrictWorkspaceAdminsSetting) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Etag": types.StringType, + "RestrictWorkspaceAdmins": RestrictWorkspaceAdminsMessage{}.ToAttrType(ctx), + "SettingName": types.StringType, + }, + } +} + type RevokeTokenRequest struct { // The ID of the token to be revoked. TokenId types.String `tfsdk:"token_id" tf:""` @@ -2481,6 +3547,14 @@ func (a RevokeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RevokeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "TokenId": types.StringType, + }, + } +} + type RevokeTokenResponse struct { } @@ -2494,6 +3568,12 @@ func (a RevokeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RevokeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type SetStatusResponse struct { } @@ -2507,6 +3587,12 @@ func (a SetStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SetStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type SlackConfig struct { // [Input-Only] URL for Slack destination. Url types.String `tfsdk:"url" tf:"optional"` @@ -2524,6 +3610,15 @@ func (a SlackConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SlackConfig) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Url": types.StringType, + "UrlSet": types.BoolType, + }, + } +} + type StringMessage struct { // Represents a generic string value. Value types.String `tfsdk:"value" tf:"optional"` @@ -2539,6 +3634,14 @@ func (a StringMessage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StringMessage) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Value": types.StringType, + }, + } +} + type TokenAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2560,6 +3663,17 @@ func (a TokenAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a TokenAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type TokenAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -2585,6 +3699,20 @@ func (a TokenAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a TokenAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: TokenPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type TokenInfo struct { // Comment that describes the purpose of the token, specified by the token // creator. @@ -2618,6 +3746,22 @@ func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "CreatedById": types.Int64Type, + "CreatedByUsername": types.StringType, + "CreationTime": types.Int64Type, + "ExpiryTime": types.Int64Type, + "LastUsedDay": types.Int64Type, + "OwnerId": types.Int64Type, + "TokenId": types.StringType, + "WorkspaceId": types.Int64Type, + }, + } +} + type TokenPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2634,7 +3778,19 @@ func (newState *TokenPermission) SyncEffectiveFieldsDuringRead(existingState Tok func (a TokenPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a TokenPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -2658,6 +3814,18 @@ func (a TokenPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a TokenPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: TokenAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type TokenPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2674,6 +3842,15 @@ func (a TokenPermissionsDescription) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a TokenPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type TokenPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` } @@ -2690,6 +3867,16 @@ func (a TokenPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a TokenPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: TokenAccessControlRequest{}.ToAttrType(ctx), + }, + }, + } +} + // Details required to update a setting. type UpdateAibiDashboardEmbeddingAccessPolicySettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2701,7 +3888,7 @@ type UpdateAibiDashboardEmbeddingAccessPolicySettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) { @@ -2716,6 +3903,16 @@ func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldT } } +func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": AibiDashboardEmbeddingAccessPolicySetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2727,7 +3924,7 @@ type UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) { @@ -2742,6 +3939,16 @@ func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFie } } +func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": AibiDashboardEmbeddingApprovedDomainsSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateAutomaticClusterUpdateSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2753,7 +3960,7 @@ type UpdateAutomaticClusterUpdateSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateAutomaticClusterUpdateSettingRequest) { @@ -2768,6 +3975,16 @@ func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[s } } +func (a UpdateAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": AutomaticClusterUpdateSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateComplianceSecurityProfileSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2779,7 +3996,7 @@ type UpdateComplianceSecurityProfileSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateComplianceSecurityProfileSettingRequest) { @@ -2794,6 +4011,16 @@ func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() ma } } +func (a UpdateComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": ComplianceSecurityProfileSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateCspEnablementAccountSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2805,7 +4032,7 @@ type UpdateCspEnablementAccountSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateCspEnablementAccountSettingRequest) { @@ -2820,6 +4047,16 @@ func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[str } } +func (a UpdateCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": CspEnablementAccountSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateDefaultNamespaceSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2839,7 +4076,7 @@ type UpdateDefaultNamespaceSettingRequest struct { // assumed). This setting requires a restart of clusters and SQL warehouses // to take effect. Additionally, the default namespace only applies when // using Unity Catalog-enabled compute. - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDefaultNamespaceSettingRequest) { @@ -2854,6 +4091,16 @@ func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string] } } +func (a UpdateDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": DefaultNamespaceSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateDisableLegacyAccessRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2865,7 +4112,7 @@ type UpdateDisableLegacyAccessRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDisableLegacyAccessRequest) { @@ -2880,6 +4127,16 @@ func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]refl } } +func (a UpdateDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": DisableLegacyAccess{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateDisableLegacyDbfsRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2891,7 +4148,7 @@ type UpdateDisableLegacyDbfsRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDisableLegacyDbfsRequest) { @@ -2906,6 +4163,16 @@ func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflec } } +func (a UpdateDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": DisableLegacyDbfs{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateDisableLegacyFeaturesRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2917,7 +4184,7 @@ type UpdateDisableLegacyFeaturesRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateDisableLegacyFeaturesRequest) { @@ -2932,6 +4199,16 @@ func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]re } } +func (a UpdateDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": DisableLegacyFeatures{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateEnhancedSecurityMonitoringSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2943,7 +4220,7 @@ type UpdateEnhancedSecurityMonitoringSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateEnhancedSecurityMonitoringSettingRequest) { @@ -2958,6 +4235,16 @@ func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() m } } +func (a UpdateEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": EnhancedSecurityMonitoringSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update a setting. type UpdateEsmEnablementAccountSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -2969,7 +4256,7 @@ type UpdateEsmEnablementAccountSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateEsmEnablementAccountSettingRequest) { @@ -2984,6 +4271,16 @@ func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[str } } +func (a UpdateEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": EsmEnablementAccountSetting{}.ToAttrType(ctx), + }, + } +} + // Details required to update an IP access list. type UpdateIpAccessList struct { // Specifies whether this IP access list is enabled. @@ -3011,14 +4308,28 @@ func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a UpdateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(""), + "IpAddresses": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + "IpAccessListId": types.StringType, + "IpAddresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "Label": types.StringType, + "ListType": types.StringType, + }, } } type UpdateNotificationDestinationRequest struct { // The configuration for the notification destination. Must wrap EXACTLY one // of the nested configs. - Config types.Object `tfsdk:"config" tf:"optional,object"` + Config types.List `tfsdk:"config" tf:"optional,object"` // The display name for the notification destination. DisplayName types.String `tfsdk:"display_name" tf:"optional"` // UUID identifying notification destination. @@ -3037,6 +4348,16 @@ func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes() map[string] } } +func (a UpdateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Config": Config{}.ToAttrType(ctx), + "DisplayName": types.StringType, + "Id": types.StringType, + }, + } +} + // Details required to update a setting. type UpdatePersonalComputeSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -3048,7 +4369,7 @@ type UpdatePersonalComputeSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdatePersonalComputeSettingRequest) { @@ -3063,6 +4384,16 @@ func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]r } } +func (a UpdatePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": PersonalComputeSetting{}.ToAttrType(ctx), + }, + } +} + type UpdateResponse struct { } @@ -3076,6 +4407,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Details required to update a setting. type UpdateRestrictWorkspaceAdminsSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -3087,7 +4424,7 @@ type UpdateRestrictWorkspaceAdminsSettingRequest struct { // the field mask, use comma as the separator (no space). FieldMask types.String `tfsdk:"field_mask" tf:""` - Setting types.Object `tfsdk:"setting" tf:"object"` + Setting types.List `tfsdk:"setting" tf:"object"` } func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRestrictWorkspaceAdminsSettingRequest) { @@ -3101,3 +4438,13 @@ func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[ "Setting": reflect.TypeOf(RestrictWorkspaceAdminsSetting{}), } } + +func (a UpdateRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowMissing": types.BoolType, + "FieldMask": types.StringType, + "Setting": RestrictWorkspaceAdminsSetting{}.ToAttrType(ctx), + }, + } +} diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 603440115c..a0dd929e05 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -11,10 +11,14 @@ We use go-native types for lists and maps intentionally for the ease for convert package sharing_tf import ( + "context" "reflect" "github.com/databricks/databricks-sdk-go/service/catalog" + "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type CreateProvider struct { @@ -39,6 +43,17 @@ func (a CreateProvider) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateProvider) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AuthenticationType": types.StringType, + "Comment": types.StringType, + "Name": types.StringType, + "RecipientProfileStr": types.StringType, + }, + } +} + type CreateRecipient struct { // The delta sharing authentication type. AuthenticationType types.String `tfsdk:"authentication_type" tf:""` @@ -52,13 +67,13 @@ type CreateRecipient struct { // Expiration timestamp of the token, in epoch milliseconds. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` // IP Access List - IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.List `tfsdk:"ip_access_list" tf:"optional,object"` // Name of Recipient. Name types.String `tfsdk:"name" tf:""` // Username of the recipient owner. Owner types.String `tfsdk:"owner" tf:"optional"` // Recipient properties as map of string key-value pairs. - PropertiesKvpairs types.Object `tfsdk:"properties_kvpairs" tf:"optional,object"` + PropertiesKvpairs types.List `tfsdk:"properties_kvpairs" tf:"optional,object"` // The one-time sharing code provided by the data recipient. This field is // required when the __authentication_type__ is **DATABRICKS**. SharingCode types.String `tfsdk:"sharing_code" tf:"optional"` @@ -77,6 +92,22 @@ func (a CreateRecipient) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateRecipient) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AuthenticationType": types.StringType, + "Comment": types.StringType, + "DataRecipientGlobalMetastoreId": types.StringType, + "ExpirationTime": types.Int64Type, + "IpAccessList": IpAccessList{}.ToAttrType(ctx), + "Name": types.StringType, + "Owner": types.StringType, + "PropertiesKvpairs": SecurablePropertiesKvPairs{}.ToAttrType(ctx), + "SharingCode": types.StringType, + }, + } +} + type CreateShare struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -96,6 +127,16 @@ func (a CreateShare) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateShare) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "StorageRoot": types.StringType, + }, + } +} + // Delete a provider type DeleteProviderRequest struct { // Name of the provider. @@ -112,6 +153,14 @@ func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Delete a share recipient type DeleteRecipientRequest struct { // Name of the recipient. @@ -128,6 +177,14 @@ func (a DeleteRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -141,6 +198,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a share type DeleteShareRequest struct { // The name of the share. @@ -157,6 +220,14 @@ func (a DeleteShareRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteShareRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get a share activation URL type GetActivationUrlInfoRequest struct { // The one time activation url. It also accepts activation token. @@ -173,6 +244,14 @@ func (a GetActivationUrlInfoRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a GetActivationUrlInfoRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActivationUrl": types.StringType, + }, + } +} + type GetActivationUrlInfoResponse struct { } @@ -186,6 +265,12 @@ func (a GetActivationUrlInfoResponse) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a GetActivationUrlInfoResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Get a provider type GetProviderRequest struct { // Name of the provider. @@ -202,6 +287,14 @@ func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + // Get a share recipient type GetRecipientRequest struct { // Name of the recipient. @@ -218,6 +311,14 @@ func (a GetRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type GetRecipientSharePermissionsResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -239,6 +340,17 @@ func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes() map[string] } } +func (a GetRecipientSharePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "PermissionsOut": basetypes.ListType{ + ElemType: ShareToPrivilegeAssignment{}.ToAttrType(ctx), + }, + }, + } +} + // Get a share type GetShareRequest struct { // Query for data to include in the share. @@ -257,6 +369,15 @@ func (a GetShareRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetShareRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IncludeSharedData": types.BoolType, + "Name": types.StringType, + }, + } +} + type IpAccessList struct { // Allowed IP Addresses in CIDR notation. Limit of 100. AllowedIpAddresses types.List `tfsdk:"allowed_ip_addresses" tf:"optional"` @@ -270,7 +391,17 @@ func (newState *IpAccessList) SyncEffectiveFieldsDuringRead(existingState IpAcce func (a IpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllowedIpAddresses": reflect.TypeOf(""), + "AllowedIpAddresses": reflect.TypeOf(types.StringType), + } +} + +func (a IpAccessList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllowedIpAddresses": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -295,6 +426,17 @@ func (a ListProviderSharesResponse) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ListProviderSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Shares": basetypes.ListType{ + ElemType: ProviderShare{}.ToAttrType(ctx), + }, + }, + } +} + // List providers type ListProvidersRequest struct { // If not provided, all providers will be returned. If no providers exist @@ -324,6 +466,16 @@ func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataProviderGlobalMetastoreId": types.StringType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListProvidersResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -345,6 +497,17 @@ func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Providers": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List share recipients type ListRecipientsRequest struct { // If not provided, all recipients will be returned. If no recipients exist @@ -374,6 +537,16 @@ func (a ListRecipientsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListRecipientsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataRecipientGlobalMetastoreId": types.StringType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListRecipientsResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -395,6 +568,17 @@ func (a ListRecipientsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListRecipientsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Recipients": basetypes.ListType{ + ElemType: RecipientInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List shares by Provider type ListSharesRequest struct { // Maximum number of shares to return. - when set to 0, the page length is @@ -423,6 +607,16 @@ func (a ListSharesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListSharesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "Name": types.StringType, + "PageToken": types.StringType, + }, + } +} + type ListSharesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -444,6 +638,17 @@ func (a ListSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Shares": basetypes.ListType{ + ElemType: ShareInfo{}.ToAttrType(ctx), + }, + }, + } +} + type Partition struct { // An array of partition values. Values types.List `tfsdk:"value" tf:"optional"` @@ -461,6 +666,16 @@ func (a Partition) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Partition) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Values": basetypes.ListType{ + ElemType: PartitionValue{}.ToAttrType(ctx), + }, + }, + } +} + type PartitionValue struct { // The name of the partition column. Name types.String `tfsdk:"name" tf:"optional"` @@ -486,6 +701,17 @@ func (a PartitionValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PartitionValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Op": types.StringType, + "RecipientPropertyKey": types.StringType, + "Value": types.StringType, + }, + } +} + type PrivilegeAssignment struct { // The principal (user email address or group name). Principal types.String `tfsdk:"principal" tf:"optional"` @@ -501,7 +727,18 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Privileges": reflect.TypeOf(""), + "Privileges": reflect.TypeOf(types.StringType), + } +} + +func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Principal": types.StringType, + "Privileges": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -530,7 +767,7 @@ type ProviderInfo struct { Owner types.String `tfsdk:"owner" tf:"optional"` // The recipient profile. This field is only present when the // authentication_type is `TOKEN`. - RecipientProfile types.Object `tfsdk:"recipient_profile" tf:"optional,object"` + RecipientProfile types.List `tfsdk:"recipient_profile" tf:"optional,object"` // This field is only present when the authentication_type is `TOKEN` or not // provided. RecipientProfileStr types.String `tfsdk:"recipient_profile_str" tf:"optional"` @@ -555,6 +792,27 @@ func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AuthenticationType": types.StringType, + "Cloud": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DataProviderGlobalMetastoreId": types.StringType, + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "RecipientProfile": RecipientProfile{}.ToAttrType(ctx), + "RecipientProfileStr": types.StringType, + "Region": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type ProviderShare struct { // The name of the Provider Share. Name types.String `tfsdk:"name" tf:"optional"` @@ -570,6 +828,14 @@ func (a ProviderShare) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ProviderShare) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type RecipientInfo struct { // A boolean status field showing whether the Recipient's activation URL has // been exercised or not. @@ -594,7 +860,7 @@ type RecipientInfo struct { // __cloud__:__region__:__metastore-uuid__. DataRecipientGlobalMetastoreId types.String `tfsdk:"data_recipient_global_metastore_id" tf:"optional"` // IP Access List - IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.List `tfsdk:"ip_access_list" tf:"optional,object"` // Unique identifier of recipient's Unity Catalog metastore. This field is // only present when the __authentication_type__ is **DATABRICKS** MetastoreId types.String `tfsdk:"metastore_id" tf:"optional"` @@ -603,7 +869,7 @@ type RecipientInfo struct { // Username of the recipient owner. Owner types.String `tfsdk:"owner" tf:"optional"` // Recipient properties as map of string key-value pairs. - PropertiesKvpairs types.Object `tfsdk:"properties_kvpairs" tf:"optional,object"` + PropertiesKvpairs types.List `tfsdk:"properties_kvpairs" tf:"optional,object"` // Cloud region of the recipient's Unity Catalog Metstore. This field is // only present when the __authentication_type__ is **DATABRICKS**. Region types.String `tfsdk:"region" tf:"optional"` @@ -632,6 +898,33 @@ func (a RecipientInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RecipientInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Activated": types.BoolType, + "ActivationUrl": types.StringType, + "AuthenticationType": types.StringType, + "Cloud": types.StringType, + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "DataRecipientGlobalMetastoreId": types.StringType, + "IpAccessList": IpAccessList{}.ToAttrType(ctx), + "MetastoreId": types.StringType, + "Name": types.StringType, + "Owner": types.StringType, + "PropertiesKvpairs": SecurablePropertiesKvPairs{}.ToAttrType(ctx), + "Region": types.StringType, + "SharingCode": types.StringType, + "Tokens": basetypes.ListType{ + ElemType: RecipientTokenInfo{}.ToAttrType(ctx), + }, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + type RecipientProfile struct { // The token used to authorize the recipient. BearerToken types.String `tfsdk:"bearer_token" tf:"optional"` @@ -651,6 +944,16 @@ func (a RecipientProfile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RecipientProfile) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BearerToken": types.StringType, + "Endpoint": types.StringType, + "ShareCredentialsVersion": types.Int64Type, + }, + } +} + type RecipientTokenInfo struct { // Full activation URL to retrieve the access token. It will be empty if the // token is already retrieved. @@ -679,6 +982,20 @@ func (a RecipientTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RecipientTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActivationUrl": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "ExpirationTime": types.Int64Type, + "Id": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + // Get an access token type RetrieveTokenRequest struct { // The one time activation url. It also accepts activation token. @@ -695,6 +1012,14 @@ func (a RetrieveTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RetrieveTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ActivationUrl": types.StringType, + }, + } +} + type RetrieveTokenResponse struct { // The token used to authorize the recipient. BearerToken types.String `tfsdk:"bearerToken" tf:"optional"` @@ -716,6 +1041,17 @@ func (a RetrieveTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RetrieveTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BearerToken": types.StringType, + "Endpoint": types.StringType, + "ExpirationTime": types.StringType, + "ShareCredentialsVersion": types.Int64Type, + }, + } +} + type RotateRecipientToken struct { // The expiration time of the bearer token in ISO 8601 format. This will set // the expiration_time of existing token only to a smaller timestamp, it @@ -736,6 +1072,15 @@ func (a RotateRecipientToken) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RotateRecipientToken) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ExistingTokenExpireInSeconds": types.Int64Type, + "Name": types.StringType, + }, + } +} + // An object with __properties__ containing map of key-value properties attached // to the securable. type SecurablePropertiesKvPairs struct { @@ -751,7 +1096,17 @@ func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existi func (a SecurablePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(""), + "Properties": reflect.TypeOf(types.StringType), + } +} + +func (a SecurablePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Properties": basetypes.MapType{ + ElemType: types.StringType, + }, + }, } } @@ -790,6 +1145,25 @@ func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "CreatedAt": types.Int64Type, + "CreatedBy": types.StringType, + "Name": types.StringType, + "Objects": basetypes.ListType{ + ElemType: SharedDataObject{}.ToAttrType(ctx), + }, + "Owner": types.StringType, + "StorageLocation": types.StringType, + "StorageRoot": types.StringType, + "UpdatedAt": types.Int64Type, + "UpdatedBy": types.StringType, + }, + } +} + // Get recipient share permissions type SharePermissionsRequest struct { // Maximum number of permissions to return. - when set to 0, the page length @@ -818,6 +1192,16 @@ func (a SharePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a SharePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MaxResults": types.Int64Type, + "Name": types.StringType, + "PageToken": types.StringType, + }, + } +} + type ShareToPrivilegeAssignment struct { // The privileges assigned to the principal. PrivilegeAssignments types.List `tfsdk:"privilege_assignments" tf:"optional"` @@ -837,6 +1221,17 @@ func (a ShareToPrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a ShareToPrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PrivilegeAssignments": basetypes.ListType{ + ElemType: PrivilegeAssignment{}.ToAttrType(ctx), + }, + "ShareName": types.StringType, + }, + } +} + type SharedDataObject struct { // The time when this data object is added to the share, in epoch // milliseconds. @@ -899,11 +1294,33 @@ func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AddedAt": types.Int64Type, + "AddedBy": types.StringType, + "CdfEnabled": types.BoolType, + "Comment": types.StringType, + "Content": types.StringType, + "DataObjectType": types.StringType, + "HistoryDataSharingStatus": types.StringType, + "Name": types.StringType, + "Partitions": basetypes.ListType{ + ElemType: Partition{}.ToAttrType(ctx), + }, + "SharedAs": types.StringType, + "StartVersion": types.Int64Type, + "Status": types.StringType, + "StringSharedAs": types.StringType, + }, + } +} + type SharedDataObjectUpdate struct { // One of: **ADD**, **REMOVE**, **UPDATE**. Action types.String `tfsdk:"action" tf:"optional"` // The data object that is being added, removed, or updated. - DataObject types.Object `tfsdk:"data_object" tf:"optional,object"` + DataObject types.List `tfsdk:"data_object" tf:"optional,object"` } func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan SharedDataObjectUpdate) { @@ -918,6 +1335,15 @@ func (a SharedDataObjectUpdate) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SharedDataObjectUpdate) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Action": types.StringType, + "DataObject": SharedDataObject{}.ToAttrType(ctx), + }, + } +} + type UpdatePermissionsResponse struct { } @@ -931,6 +1357,12 @@ func (a UpdatePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a UpdatePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateProvider struct { // Description about the provider. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -955,13 +1387,25 @@ func (a UpdateProvider) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateProvider) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "RecipientProfileStr": types.StringType, + }, + } +} + type UpdateRecipient struct { // Description about the recipient. Comment types.String `tfsdk:"comment" tf:"optional"` // Expiration timestamp of the token, in epoch milliseconds. ExpirationTime types.Int64 `tfsdk:"expiration_time" tf:"optional"` // IP Access List - IpAccessList types.Object `tfsdk:"ip_access_list" tf:"optional,object"` + IpAccessList types.List `tfsdk:"ip_access_list" tf:"optional,object"` // Name of the recipient. Name types.String `tfsdk:"-"` // New name for the recipient. @@ -972,7 +1416,7 @@ type UpdateRecipient struct { // update request, the specified properties will override the existing // properties. To add and remove properties, one would need to perform a // read-modify-write. - PropertiesKvpairs types.Object `tfsdk:"properties_kvpairs" tf:"optional,object"` + PropertiesKvpairs types.List `tfsdk:"properties_kvpairs" tf:"optional,object"` } func (newState *UpdateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRecipient) { @@ -988,6 +1432,20 @@ func (a UpdateRecipient) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateRecipient) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "ExpirationTime": types.Int64Type, + "IpAccessList": IpAccessList{}.ToAttrType(ctx), + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "PropertiesKvpairs": SecurablePropertiesKvPairs{}.ToAttrType(ctx), + }, + } +} + type UpdateResponse struct { } @@ -1001,6 +1459,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateShare struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1028,6 +1492,21 @@ func (a UpdateShare) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateShare) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Comment": types.StringType, + "Name": types.StringType, + "NewName": types.StringType, + "Owner": types.StringType, + "StorageRoot": types.StringType, + "Updates": basetypes.ListType{ + ElemType: SharedDataObjectUpdate{}.ToAttrType(ctx), + }, + }, + } +} + type UpdateSharePermissions struct { // Array of permission changes. Changes types.List `tfsdk:"changes" tf:"optional"` @@ -1058,3 +1537,16 @@ func (a UpdateSharePermissions) GetComplexFieldTypes() map[string]reflect.Type { "Changes": reflect.TypeOf(catalog.PermissionsChange{}), } } + +func (a UpdateSharePermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Changes": basetypes.ListType{ + ElemType: catalog_tf.PermissionsChange{}.ToAttrType(ctx), + }, + "MaxResults": types.Int64Type, + "Name": types.StringType, + "PageToken": types.StringType, + }, + } +} diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index c5660ef6a6..6f3895f377 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package sql_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AccessControl struct { @@ -35,9 +38,19 @@ func (a AccessControl) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AccessControl) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "UserName": types.StringType, + }, + } +} + type Alert struct { // Trigger conditions of the alert. - Condition types.Object `tfsdk:"condition" tf:"optional,object"` + Condition types.List `tfsdk:"condition" tf:"optional,object"` // The timestamp indicating when the alert was created. CreateTime types.String `tfsdk:"create_time" tf:"optional"` // Custom body of alert notification, if it exists. See [here] for custom @@ -93,6 +106,28 @@ func (a Alert) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Alert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Condition": AlertCondition{}.ToAttrType(ctx), + "CreateTime": types.StringType, + "CustomBody": types.StringType, + "CustomSubject": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + "LifecycleState": types.StringType, + "NotifyOnOk": types.BoolType, + "OwnerUserName": types.StringType, + "ParentPath": types.StringType, + "QueryId": types.StringType, + "SecondsToRetrigger": types.Int64Type, + "State": types.StringType, + "TriggerTime": types.StringType, + "UpdateTime": types.StringType, + }, + } +} + type AlertCondition struct { // Alert state if result is empty. EmptyResultState types.String `tfsdk:"empty_result_state" tf:"optional"` @@ -100,9 +135,9 @@ type AlertCondition struct { Op types.String `tfsdk:"op" tf:"optional"` // Name of the column from the query result to use for comparison in alert // evaluation. - Operand types.Object `tfsdk:"operand" tf:"optional,object"` + Operand types.List `tfsdk:"operand" tf:"optional,object"` // Threshold value used for comparison in alert evaluation. - Threshold types.Object `tfsdk:"threshold" tf:"optional,object"` + Threshold types.List `tfsdk:"threshold" tf:"optional,object"` } func (newState *AlertCondition) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertCondition) { @@ -118,8 +153,19 @@ func (a AlertCondition) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AlertCondition) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EmptyResultState": types.StringType, + "Op": types.StringType, + "Operand": AlertConditionOperand{}.ToAttrType(ctx), + "Threshold": AlertConditionThreshold{}.ToAttrType(ctx), + }, + } +} + type AlertConditionOperand struct { - Column types.Object `tfsdk:"column" tf:"optional,object"` + Column types.List `tfsdk:"column" tf:"optional,object"` } func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertConditionOperand) { @@ -134,8 +180,16 @@ func (a AlertConditionOperand) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a AlertConditionOperand) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Column": AlertOperandColumn{}.ToAttrType(ctx), + }, + } +} + type AlertConditionThreshold struct { - Value types.Object `tfsdk:"value" tf:"optional,object"` + Value types.List `tfsdk:"value" tf:"optional,object"` } func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertConditionThreshold) { @@ -150,6 +204,14 @@ func (a AlertConditionThreshold) GetComplexFieldTypes() map[string]reflect.Type } } +func (a AlertConditionThreshold) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Value": AlertOperandValue{}.ToAttrType(ctx), + }, + } +} + type AlertOperandColumn struct { Name types.String `tfsdk:"name" tf:"optional"` } @@ -164,6 +226,14 @@ func (a AlertOperandColumn) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AlertOperandColumn) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type AlertOperandValue struct { BoolValue types.Bool `tfsdk:"bool_value" tf:"optional"` @@ -182,6 +252,16 @@ func (a AlertOperandValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AlertOperandValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BoolValue": types.BoolType, + "DoubleValue": types.Float64Type, + "StringValue": types.StringType, + }, + } +} + // Alert configuration options. type AlertOptions struct { // Name of column in the query result to compare in alert evaluation. @@ -220,6 +300,20 @@ func (a AlertOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AlertOptions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Column": types.StringType, + "CustomBody": types.StringType, + "CustomSubject": types.StringType, + "EmptyResultState": types.StringType, + "Muted": types.BoolType, + "Op": types.StringType, + "Value": types.ObjectType{}, + }, + } +} + type AlertQuery struct { // The timestamp when this query was created. CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -251,7 +345,7 @@ type AlertQuery struct { // on the query page. Name types.String `tfsdk:"name" tf:"optional"` - Options types.Object `tfsdk:"options" tf:"optional,object"` + Options types.List `tfsdk:"options" tf:"optional,object"` // The text of the query to be run. Query types.String `tfsdk:"query" tf:"optional"` @@ -271,7 +365,29 @@ func (newState *AlertQuery) SyncEffectiveFieldsDuringRead(existingState AlertQue func (a AlertQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Options": reflect.TypeOf(QueryOptions{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a AlertQuery) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.StringType, + "DataSourceId": types.StringType, + "Description": types.StringType, + "Id": types.StringType, + "IsArchived": types.BoolType, + "IsDraft": types.BoolType, + "IsSafe": types.BoolType, + "Name": types.StringType, + "Options": QueryOptions{}.ToAttrType(ctx), + "Query": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "UpdatedAt": types.StringType, + "UserId": types.Int64Type, + }, } } @@ -300,6 +416,17 @@ func (a BaseChunkInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a BaseChunkInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ByteCount": types.Int64Type, + "ChunkIndex": types.Int64Type, + "RowCount": types.Int64Type, + "RowOffset": types.Int64Type, + }, + } +} + // Cancel statement execution type CancelExecutionRequest struct { // The statement ID is returned upon successfully submitting a SQL @@ -317,6 +444,14 @@ func (a CancelExecutionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CancelExecutionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StatementId": types.StringType, + }, + } +} + type CancelExecutionResponse struct { } @@ -330,6 +465,12 @@ func (a CancelExecutionResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CancelExecutionResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Configures the channel name and DBSQL version of the warehouse. // CHANNEL_NAME_CUSTOM should be chosen only when `dbsql_version` is specified. type Channel struct { @@ -348,6 +489,15 @@ func (a Channel) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Channel) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbsqlVersion": types.StringType, + "Name": types.StringType, + }, + } +} + // Details about a Channel. type ChannelInfo struct { // DB SQL Version the Channel is mapped to. @@ -366,6 +516,15 @@ func (a ChannelInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ChannelInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DbsqlVersion": types.StringType, + "Name": types.StringType, + }, + } +} + type ColumnInfo struct { // The name of the column. Name types.String `tfsdk:"name" tf:"optional"` @@ -396,11 +555,25 @@ func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Position": types.Int64Type, + "TypeIntervalType": types.StringType, + "TypeName": types.StringType, + "TypePrecision": types.Int64Type, + "TypeScale": types.Int64Type, + "TypeText": types.StringType, + }, + } +} + type CreateAlert struct { // Name of the alert. Name types.String `tfsdk:"name" tf:""` // Alert configuration options. - Options types.Object `tfsdk:"options" tf:"object"` + Options types.List `tfsdk:"options" tf:"object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // Query ID. @@ -423,8 +596,20 @@ func (a CreateAlert) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Options": AlertOptions{}.ToAttrType(ctx), + "Parent": types.StringType, + "QueryId": types.StringType, + "Rearm": types.Int64Type, + }, + } +} + type CreateAlertRequest struct { - Alert types.Object `tfsdk:"alert" tf:"optional,object"` + Alert types.List `tfsdk:"alert" tf:"optional,object"` } func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateAlertRequest) { @@ -439,9 +624,17 @@ func (a CreateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alert": CreateAlertRequestAlert{}.ToAttrType(ctx), + }, + } +} + type CreateAlertRequestAlert struct { // Trigger conditions of the alert. - Condition types.Object `tfsdk:"condition" tf:"optional,object"` + Condition types.List `tfsdk:"condition" tf:"optional,object"` // Custom body of alert notification, if it exists. See [here] for custom // templating instructions. // @@ -479,8 +672,23 @@ func (a CreateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Condition": AlertCondition{}.ToAttrType(ctx), + "CustomBody": types.StringType, + "CustomSubject": types.StringType, + "DisplayName": types.StringType, + "NotifyOnOk": types.BoolType, + "ParentPath": types.StringType, + "QueryId": types.StringType, + "SecondsToRetrigger": types.Int64Type, + }, + } +} + type CreateQueryRequest struct { - Query types.Object `tfsdk:"query" tf:"optional,object"` + Query types.List `tfsdk:"query" tf:"optional,object"` } func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateQueryRequest) { @@ -495,6 +703,14 @@ func (a CreateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Query": CreateQueryRequestQuery{}.ToAttrType(ctx), + }, + } +} + type CreateQueryRequestQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -531,7 +747,29 @@ func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingS func (a CreateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a CreateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyAutoLimit": types.BoolType, + "Catalog": types.StringType, + "Description": types.StringType, + "DisplayName": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: QueryParameter{}.ToAttrType(ctx), + }, + "ParentPath": types.StringType, + "QueryText": types.StringType, + "RunAsMode": types.StringType, + "Schema": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "WarehouseId": types.StringType, + }, } } @@ -563,8 +801,20 @@ func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[strin return map[string]reflect.Type{} } +func (a CreateQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "Name": types.StringType, + "Options": types.ObjectType{}, + "QueryId": types.StringType, + "Type": types.StringType, + }, + } +} + type CreateVisualizationRequest struct { - Visualization types.Object `tfsdk:"visualization" tf:"optional,object"` + Visualization types.List `tfsdk:"visualization" tf:"optional,object"` } func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateVisualizationRequest) { @@ -579,6 +829,14 @@ func (a CreateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a CreateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Visualization": CreateVisualizationRequestVisualization{}.ToAttrType(ctx), + }, + } +} + type CreateVisualizationRequestVisualization struct { // The display name of the visualization. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -606,6 +864,18 @@ func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a CreateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "QueryId": types.StringType, + "SerializedOptions": types.StringType, + "SerializedQueryPlan": types.StringType, + "Type": types.StringType, + }, + } +} + type CreateWarehouseRequest struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -617,7 +887,7 @@ type CreateWarehouseRequest struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel types.Object `tfsdk:"channel" tf:"optional,object"` + Channel types.List `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -663,7 +933,7 @@ type CreateWarehouseRequest struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags types.Object `tfsdk:"tags" tf:"optional,object"` + Tags types.List `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -683,6 +953,26 @@ func (a CreateWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoStopMins": types.Int64Type, + "Channel": Channel{}.ToAttrType(ctx), + "ClusterSize": types.StringType, + "CreatorName": types.StringType, + "EnablePhoton": types.BoolType, + "EnableServerlessCompute": types.BoolType, + "InstanceProfileArn": types.StringType, + "MaxNumClusters": types.Int64Type, + "MinNumClusters": types.Int64Type, + "Name": types.StringType, + "SpotInstancePolicy": types.StringType, + "Tags": EndpointTags{}.ToAttrType(ctx), + "WarehouseType": types.StringType, + }, + } +} + type CreateWarehouseResponse struct { // Id for the SQL warehouse. This value is unique across all SQL warehouses. Id types.String `tfsdk:"id" tf:"optional"` @@ -698,13 +988,21 @@ func (a CreateWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CreateWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type CreateWidget struct { // Dashboard ID returned by :method:dashboards/create. DashboardId types.String `tfsdk:"dashboard_id" tf:""` // Widget ID returned by :method:dashboardwidgets/create Id types.String `tfsdk:"-"` - Options types.Object `tfsdk:"options" tf:"object"` + Options types.List `tfsdk:"options" tf:"object"` // If this is a textbox widget, the application displays this text. This // field is ignored if the widget contains a visualization in the // `visualization` field. @@ -727,6 +1025,19 @@ func (a CreateWidget) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateWidget) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Id": types.StringType, + "Options": WidgetOptions{}.ToAttrType(ctx), + "Text": types.StringType, + "VisualizationId": types.StringType, + "Width": types.Int64Type, + }, + } +} + // A JSON representing a dashboard containing widgets of visualizations and text // boxes. type Dashboard struct { @@ -755,7 +1066,7 @@ type Dashboard struct { // the dashboard page. Name types.String `tfsdk:"name" tf:"optional"` - Options types.Object `tfsdk:"options" tf:"optional,object"` + Options types.List `tfsdk:"options" tf:"optional,object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // * `CAN_VIEW`: Can view the query * `CAN_RUN`: Can run the query * @@ -769,7 +1080,7 @@ type Dashboard struct { // Timestamp when this dashboard was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` - User types.Object `tfsdk:"user" tf:"optional,object"` + User types.List `tfsdk:"user" tf:"optional,object"` // The ID of the user who owns the dashboard. UserId types.Int64 `tfsdk:"user_id" tf:"optional"` @@ -785,12 +1096,40 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Options": reflect.TypeOf(DashboardOptions{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), "User": reflect.TypeOf(User{}), "Widgets": reflect.TypeOf(Widget{}), } } +func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CanEdit": types.BoolType, + "CreatedAt": types.StringType, + "DashboardFiltersEnabled": types.BoolType, + "Id": types.StringType, + "IsArchived": types.BoolType, + "IsDraft": types.BoolType, + "IsFavorite": types.BoolType, + "Name": types.StringType, + "Options": DashboardOptions{}.ToAttrType(ctx), + "Parent": types.StringType, + "PermissionTier": types.StringType, + "Slug": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "UpdatedAt": types.StringType, + "User": User{}.ToAttrType(ctx), + "UserId": types.Int64Type, + "Widgets": basetypes.ListType{ + ElemType: Widget{}.ToAttrType(ctx), + }, + }, + } +} + type DashboardEditContent struct { DashboardId types.String `tfsdk:"-"` // The title of this dashboard that appears in list views and at the top of @@ -812,7 +1151,20 @@ func (newState *DashboardEditContent) SyncEffectiveFieldsDuringRead(existingStat func (a DashboardEditContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a DashboardEditContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + "Name": types.StringType, + "RunAsRole": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -833,6 +1185,14 @@ func (a DashboardOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DashboardOptions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MovedToTrashAt": types.StringType, + }, + } +} + type DashboardPostContent struct { // Indicates whether the dashboard filters are enabled DashboardFiltersEnabled types.Bool `tfsdk:"dashboard_filters_enabled" tf:"optional"` @@ -860,7 +1220,22 @@ func (newState *DashboardPostContent) SyncEffectiveFieldsDuringRead(existingStat func (a DashboardPostContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a DashboardPostContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardFiltersEnabled": types.BoolType, + "IsFavorite": types.BoolType, + "Name": types.StringType, + "Parent": types.StringType, + "RunAsRole": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -902,6 +1277,22 @@ func (a DataSource) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DataSource) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Name": types.StringType, + "PauseReason": types.StringType, + "Paused": types.Int64Type, + "SupportsAutoLimit": types.BoolType, + "Syntax": types.StringType, + "Type": types.StringType, + "ViewOnly": types.BoolType, + "WarehouseId": types.StringType, + }, + } +} + type DateRange struct { End types.String `tfsdk:"end" tf:""` @@ -918,9 +1309,18 @@ func (a DateRange) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DateRange) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "End": types.StringType, + "Start": types.StringType, + }, + } +} + type DateRangeValue struct { // Manually specified date-time range value. - DateRangeValue types.Object `tfsdk:"date_range_value" tf:"optional,object"` + DateRangeValue types.List `tfsdk:"date_range_value" tf:"optional,object"` // Dynamic date-time range value based on current date-time. DynamicDateRangeValue types.String `tfsdk:"dynamic_date_range_value" tf:"optional"` // Date-time precision to format the value into when the query is run. @@ -942,6 +1342,17 @@ func (a DateRangeValue) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a DateRangeValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DateRangeValue": DateRange{}.ToAttrType(ctx), + "DynamicDateRangeValue": types.StringType, + "Precision": types.StringType, + "StartDayOfWeek": types.Int64Type, + }, + } +} + type DateValue struct { // Manually specified date-time value. DateValue types.String `tfsdk:"date_value" tf:"optional"` @@ -962,6 +1373,16 @@ func (a DateValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DateValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DateValue": types.StringType, + "DynamicDateValue": types.StringType, + "Precision": types.StringType, + }, + } +} + // Delete an alert type DeleteAlertsLegacyRequest struct { AlertId types.String `tfsdk:"-"` @@ -977,6 +1398,14 @@ func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertId": types.StringType, + }, + } +} + // Remove a dashboard type DeleteDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -992,6 +1421,14 @@ func (a DeleteDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + // Remove widget type DeleteDashboardWidgetRequest struct { // Widget ID returned by :method:dashboardwidgets/create @@ -1008,6 +1445,14 @@ func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a DeleteDashboardWidgetRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a query type DeleteQueriesLegacyRequest struct { QueryId types.String `tfsdk:"-"` @@ -1023,6 +1468,14 @@ func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueryId": types.StringType, + }, + } +} + // Remove visualization type DeleteQueryVisualizationsLegacyRequest struct { // Widget ID returned by :method:queryvizualisations/create @@ -1039,6 +1492,14 @@ func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[strin return map[string]reflect.Type{} } +func (a DeleteQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteResponse struct { } @@ -1052,6 +1513,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Remove a visualization type DeleteVisualizationRequest struct { Id types.String `tfsdk:"-"` @@ -1067,6 +1534,14 @@ func (a DeleteVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a DeleteVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a warehouse type DeleteWarehouseRequest struct { // Required. Id of the SQL warehouse. @@ -1083,6 +1558,14 @@ func (a DeleteWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type DeleteWarehouseResponse struct { } @@ -1096,12 +1579,18 @@ func (a DeleteWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EditAlert struct { AlertId types.String `tfsdk:"-"` // Name of the alert. Name types.String `tfsdk:"name" tf:""` // Alert configuration options. - Options types.Object `tfsdk:"options" tf:"object"` + Options types.List `tfsdk:"options" tf:"object"` // Query ID. QueryId types.String `tfsdk:"query_id" tf:""` // Number of seconds after being triggered before the alert rearms itself @@ -1122,6 +1611,18 @@ func (a EditAlert) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EditAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertId": types.StringType, + "Name": types.StringType, + "Options": AlertOptions{}.ToAttrType(ctx), + "QueryId": types.StringType, + "Rearm": types.Int64Type, + }, + } +} + type EditWarehouseRequest struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -1131,7 +1632,7 @@ type EditWarehouseRequest struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel types.Object `tfsdk:"channel" tf:"optional,object"` + Channel types.List `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -1179,7 +1680,7 @@ type EditWarehouseRequest struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags types.Object `tfsdk:"tags" tf:"optional,object"` + Tags types.List `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -1199,6 +1700,27 @@ func (a EditWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EditWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoStopMins": types.Int64Type, + "Channel": Channel{}.ToAttrType(ctx), + "ClusterSize": types.StringType, + "CreatorName": types.StringType, + "EnablePhoton": types.BoolType, + "EnableServerlessCompute": types.BoolType, + "Id": types.StringType, + "InstanceProfileArn": types.StringType, + "MaxNumClusters": types.Int64Type, + "MinNumClusters": types.Int64Type, + "Name": types.StringType, + "SpotInstancePolicy": types.StringType, + "Tags": EndpointTags{}.ToAttrType(ctx), + "WarehouseType": types.StringType, + }, + } +} + type EditWarehouseResponse struct { } @@ -1212,6 +1734,12 @@ func (a EditWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EditWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Represents an empty message, similar to google.protobuf.Empty, which is not // available in the firm right now. type Empty struct { @@ -1227,6 +1755,12 @@ func (a Empty) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Empty) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type EndpointConfPair struct { Key types.String `tfsdk:"key" tf:"optional"` @@ -1243,12 +1777,21 @@ func (a EndpointConfPair) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EndpointConfPair) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type EndpointHealth struct { // Details about errors that are causing current degraded/failed status. Details types.String `tfsdk:"details" tf:"optional"` // The reason for failure to bring up clusters for this warehouse. This is // available when status is 'FAILED' and sometimes when it is DEGRADED. - FailureReason types.Object `tfsdk:"failure_reason" tf:"optional,object"` + FailureReason types.List `tfsdk:"failure_reason" tf:"optional,object"` // Deprecated. split into summary and details for security Message types.String `tfsdk:"message" tf:"optional"` // Health status of the warehouse. @@ -1270,6 +1813,18 @@ func (a EndpointHealth) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EndpointHealth) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Details": types.StringType, + "FailureReason": TerminationReason{}.ToAttrType(ctx), + "Message": types.StringType, + "Status": types.StringType, + "Summary": types.StringType, + }, + } +} + type EndpointInfo struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -1279,7 +1834,7 @@ type EndpointInfo struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel types.Object `tfsdk:"channel" tf:"optional,object"` + Channel types.List `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -1297,7 +1852,7 @@ type EndpointInfo struct { EnableServerlessCompute types.Bool `tfsdk:"enable_serverless_compute" tf:"optional"` // Optional health status. Assume the warehouse is healthy if this field is // not set. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // unique identifier for warehouse Id types.String `tfsdk:"id" tf:"optional"` // Deprecated. Instance profile used to pass IAM role to the cluster @@ -1331,7 +1886,7 @@ type EndpointInfo struct { // current number of clusters running for the service NumClusters types.Int64 `tfsdk:"num_clusters" tf:"optional"` // ODBC parameters for the SQL warehouse - OdbcParams types.Object `tfsdk:"odbc_params" tf:"optional,object"` + OdbcParams types.List `tfsdk:"odbc_params" tf:"optional,object"` // Configurations whether the warehouse should use spot instances. SpotInstancePolicy types.String `tfsdk:"spot_instance_policy" tf:"optional"` // State of the warehouse @@ -1340,7 +1895,7 @@ type EndpointInfo struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags types.Object `tfsdk:"tags" tf:"optional,object"` + Tags types.List `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -1362,6 +1917,33 @@ func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoStopMins": types.Int64Type, + "Channel": Channel{}.ToAttrType(ctx), + "ClusterSize": types.StringType, + "CreatorName": types.StringType, + "EnablePhoton": types.BoolType, + "EnableServerlessCompute": types.BoolType, + "Health": EndpointHealth{}.ToAttrType(ctx), + "Id": types.StringType, + "InstanceProfileArn": types.StringType, + "JdbcUrl": types.StringType, + "MaxNumClusters": types.Int64Type, + "MinNumClusters": types.Int64Type, + "Name": types.StringType, + "NumActiveSessions": types.Int64Type, + "NumClusters": types.Int64Type, + "OdbcParams": OdbcParams{}.ToAttrType(ctx), + "SpotInstancePolicy": types.StringType, + "State": types.StringType, + "Tags": EndpointTags{}.ToAttrType(ctx), + "WarehouseType": types.StringType, + }, + } +} + type EndpointTagPair struct { Key types.String `tfsdk:"key" tf:"optional"` @@ -1378,6 +1960,15 @@ func (a EndpointTagPair) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EndpointTagPair) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + type EndpointTags struct { CustomTags types.List `tfsdk:"custom_tags" tf:"optional"` } @@ -1394,11 +1985,21 @@ func (a EndpointTags) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EndpointTags) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CustomTags": basetypes.ListType{ + ElemType: EndpointTagPair{}.ToAttrType(ctx), + }, + }, + } +} + type EnumValue struct { // List of valid query parameter values, newline delimited. EnumOptions types.String `tfsdk:"enum_options" tf:"optional"` // If specified, allows multiple values to be selected for this parameter. - MultiValuesOptions types.Object `tfsdk:"multi_values_options" tf:"optional,object"` + MultiValuesOptions types.List `tfsdk:"multi_values_options" tf:"optional,object"` // List of selected query parameter values. Values types.List `tfsdk:"values" tf:"optional"` } @@ -1412,7 +2013,19 @@ func (newState *EnumValue) SyncEffectiveFieldsDuringRead(existingState EnumValue func (a EnumValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), - "Values": reflect.TypeOf(""), + "Values": reflect.TypeOf(types.StringType), + } +} + +func (a EnumValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EnumOptions": types.StringType, + "MultiValuesOptions": MultiValuesOptions{}.ToAttrType(ctx), + "Values": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1554,6 +2167,26 @@ func (a ExecuteStatementRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ExecuteStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ByteLimit": types.Int64Type, + "Catalog": types.StringType, + "Disposition": types.StringType, + "Format": types.StringType, + "OnWaitTimeout": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: StatementParameterListItem{}.ToAttrType(ctx), + }, + "RowLimit": types.Int64Type, + "Schema": types.StringType, + "Statement": types.StringType, + "WaitTimeout": types.StringType, + "WarehouseId": types.StringType, + }, + } +} + type ExternalLink struct { // The number of bytes in the result chunk. This field is not available when // using `INLINE` disposition. @@ -1595,7 +2228,25 @@ func (newState *ExternalLink) SyncEffectiveFieldsDuringRead(existingState Extern func (a ExternalLink) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "HttpHeaders": reflect.TypeOf(""), + "HttpHeaders": reflect.TypeOf(types.StringType), + } +} + +func (a ExternalLink) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ByteCount": types.Int64Type, + "ChunkIndex": types.Int64Type, + "Expiration": types.StringType, + "ExternalLink": types.StringType, + "HttpHeaders": basetypes.MapType{ + ElemType: types.StringType, + }, + "NextChunkIndex": types.Int64Type, + "NextChunkInternalLink": types.StringType, + "RowCount": types.Int64Type, + "RowOffset": types.Int64Type, + }, } } @@ -1614,6 +2265,14 @@ func (a GetAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Get an alert type GetAlertsLegacyRequest struct { AlertId types.String `tfsdk:"-"` @@ -1629,6 +2288,14 @@ func (a GetAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AlertId": types.StringType, + }, + } +} + // Retrieve a definition type GetDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -1644,6 +2311,14 @@ func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + // Get object ACL type GetDbsqlPermissionRequest struct { // Object ID. An ACL is returned for the object with this UUID. @@ -1662,6 +2337,15 @@ func (a GetDbsqlPermissionRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a GetDbsqlPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + // Get a query definition. type GetQueriesLegacyRequest struct { QueryId types.String `tfsdk:"-"` @@ -1677,6 +2361,14 @@ func (a GetQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a GetQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueryId": types.StringType, + }, + } +} + // Get a query type GetQueryRequest struct { Id types.String `tfsdk:"-"` @@ -1692,6 +2384,14 @@ func (a GetQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetResponse struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // An object's type and UUID, separated by a forward slash (/) character. @@ -1712,6 +2412,18 @@ func (a GetResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AccessControl{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + // Get status, manifest, and result first chunk type GetStatementRequest struct { // The statement ID is returned upon successfully submitting a SQL @@ -1729,6 +2441,14 @@ func (a GetStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "StatementId": types.StringType, + }, + } +} + // Get result chunk by index type GetStatementResultChunkNRequest struct { ChunkIndex types.Int64 `tfsdk:"-"` @@ -1747,6 +2467,15 @@ func (a GetStatementResultChunkNRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a GetStatementResultChunkNRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ChunkIndex": types.Int64Type, + "StatementId": types.StringType, + }, + } +} + // Get SQL warehouse permission levels type GetWarehousePermissionLevelsRequest struct { // The SQL warehouse for which to get or manage permissions. @@ -1763,6 +2492,14 @@ func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a GetWarehousePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WarehouseId": types.StringType, + }, + } +} + type GetWarehousePermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -1780,6 +2517,16 @@ func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes() map[string] } } +func (a GetWarehousePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: WarehousePermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get SQL warehouse permissions type GetWarehousePermissionsRequest struct { // The SQL warehouse for which to get or manage permissions. @@ -1796,6 +2543,14 @@ func (a GetWarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a GetWarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WarehouseId": types.StringType, + }, + } +} + // Get warehouse info type GetWarehouseRequest struct { // Required. Id of the SQL warehouse. @@ -1812,6 +2567,14 @@ func (a GetWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type GetWarehouseResponse struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -1821,7 +2584,7 @@ type GetWarehouseResponse struct { // Defaults to 120 mins AutoStopMins types.Int64 `tfsdk:"auto_stop_mins" tf:"optional"` // Channel Details - Channel types.Object `tfsdk:"channel" tf:"optional,object"` + Channel types.List `tfsdk:"channel" tf:"optional,object"` // Size of the clusters allocated for this warehouse. Increasing the size of // a spark cluster allows you to run larger queries on it. If you want to // increase the number of concurrent queries, please tune max_num_clusters. @@ -1839,7 +2602,7 @@ type GetWarehouseResponse struct { EnableServerlessCompute types.Bool `tfsdk:"enable_serverless_compute" tf:"optional"` // Optional health status. Assume the warehouse is healthy if this field is // not set. - Health types.Object `tfsdk:"health" tf:"optional,object"` + Health types.List `tfsdk:"health" tf:"optional,object"` // unique identifier for warehouse Id types.String `tfsdk:"id" tf:"optional"` // Deprecated. Instance profile used to pass IAM role to the cluster @@ -1873,7 +2636,7 @@ type GetWarehouseResponse struct { // current number of clusters running for the service NumClusters types.Int64 `tfsdk:"num_clusters" tf:"optional"` // ODBC parameters for the SQL warehouse - OdbcParams types.Object `tfsdk:"odbc_params" tf:"optional,object"` + OdbcParams types.List `tfsdk:"odbc_params" tf:"optional,object"` // Configurations whether the warehouse should use spot instances. SpotInstancePolicy types.String `tfsdk:"spot_instance_policy" tf:"optional"` // State of the warehouse @@ -1882,7 +2645,7 @@ type GetWarehouseResponse struct { // instances and EBS volumes) associated with this SQL warehouse. // // Supported values: - Number of tags < 45. - Tags types.Object `tfsdk:"tags" tf:"optional,object"` + Tags types.List `tfsdk:"tags" tf:"optional,object"` // Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless // compute, you must set to `PRO` and also set the field // `enable_serverless_compute` to `true`. @@ -1904,11 +2667,38 @@ func (a GetWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoStopMins": types.Int64Type, + "Channel": Channel{}.ToAttrType(ctx), + "ClusterSize": types.StringType, + "CreatorName": types.StringType, + "EnablePhoton": types.BoolType, + "EnableServerlessCompute": types.BoolType, + "Health": EndpointHealth{}.ToAttrType(ctx), + "Id": types.StringType, + "InstanceProfileArn": types.StringType, + "JdbcUrl": types.StringType, + "MaxNumClusters": types.Int64Type, + "MinNumClusters": types.Int64Type, + "Name": types.StringType, + "NumActiveSessions": types.Int64Type, + "NumClusters": types.Int64Type, + "OdbcParams": OdbcParams{}.ToAttrType(ctx), + "SpotInstancePolicy": types.StringType, + "State": types.StringType, + "Tags": EndpointTags{}.ToAttrType(ctx), + "WarehouseType": types.StringType, + }, + } +} + type GetWorkspaceWarehouseConfigResponse struct { // Optional: Channel selection details - Channel types.Object `tfsdk:"channel" tf:"optional,object"` + Channel types.List `tfsdk:"channel" tf:"optional,object"` // Deprecated: Use sql_configuration_parameters - ConfigParam types.Object `tfsdk:"config_param" tf:"optional,object"` + ConfigParam types.List `tfsdk:"config_param" tf:"optional,object"` // Spark confs for external hive metastore configuration JSON serialized // size must be less than <= 512K DataAccessConfig types.List `tfsdk:"data_access_config" tf:"optional"` @@ -1920,7 +2710,7 @@ type GetWorkspaceWarehouseConfigResponse struct { // specific type availability in the warehouse create and edit form UI. EnabledWarehouseTypes types.List `tfsdk:"enabled_warehouse_types" tf:"optional"` // Deprecated: Use sql_configuration_parameters - GlobalParam types.Object `tfsdk:"global_param" tf:"optional,object"` + GlobalParam types.List `tfsdk:"global_param" tf:"optional,object"` // GCP only: Google Service Account used to pass to cluster to access Google // Cloud Storage GoogleServiceAccount types.String `tfsdk:"google_service_account" tf:"optional"` @@ -1929,7 +2719,7 @@ type GetWorkspaceWarehouseConfigResponse struct { // Security policy for warehouses SecurityPolicy types.String `tfsdk:"security_policy" tf:"optional"` // SQL configuration parameters - SqlConfigurationParameters types.Object `tfsdk:"sql_configuration_parameters" tf:"optional,object"` + SqlConfigurationParameters types.List `tfsdk:"sql_configuration_parameters" tf:"optional,object"` } func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetWorkspaceWarehouseConfigResponse) { @@ -1949,6 +2739,26 @@ func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]r } } +func (a GetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Channel": Channel{}.ToAttrType(ctx), + "ConfigParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + "DataAccessConfig": basetypes.ListType{ + ElemType: EndpointConfPair{}.ToAttrType(ctx), + }, + "EnabledWarehouseTypes": basetypes.ListType{ + ElemType: WarehouseTypePair{}.ToAttrType(ctx), + }, + "GlobalParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + "GoogleServiceAccount": types.StringType, + "InstanceProfileArn": types.StringType, + "SecurityPolicy": types.StringType, + "SqlConfigurationParameters": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, + } +} + type LegacyAlert struct { // Timestamp when the alert was created. CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -1959,11 +2769,11 @@ type LegacyAlert struct { // Name of the alert. Name types.String `tfsdk:"name" tf:"optional"` // Alert configuration options. - Options types.Object `tfsdk:"options" tf:"optional,object"` + Options types.List `tfsdk:"options" tf:"optional,object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` - Query types.Object `tfsdk:"query" tf:"optional,object"` + Query types.List `tfsdk:"query" tf:"optional,object"` // Number of seconds after being triggered before the alert rearms itself // and can be triggered again. If `null`, alert will never be triggered // again. @@ -1975,7 +2785,7 @@ type LegacyAlert struct { // Timestamp when the alert was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` - User types.Object `tfsdk:"user" tf:"optional,object"` + User types.List `tfsdk:"user" tf:"optional,object"` } func (newState *LegacyAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan LegacyAlert) { @@ -1992,6 +2802,24 @@ func (a LegacyAlert) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a LegacyAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.StringType, + "Id": types.StringType, + "LastTriggeredAt": types.StringType, + "Name": types.StringType, + "Options": AlertOptions{}.ToAttrType(ctx), + "Parent": types.StringType, + "Query": AlertQuery{}.ToAttrType(ctx), + "Rearm": types.Int64Type, + "State": types.StringType, + "UpdatedAt": types.StringType, + "User": User{}.ToAttrType(ctx), + }, + } +} + type LegacyQuery struct { // Describes whether the authenticated user is allowed to edit the // definition of this query. @@ -2026,7 +2854,7 @@ type LegacyQuery struct { // type parameters are handled safely. IsSafe types.Bool `tfsdk:"is_safe" tf:"optional"` - LastModifiedBy types.Object `tfsdk:"last_modified_by" tf:"optional,object"` + LastModifiedBy types.List `tfsdk:"last_modified_by" tf:"optional,object"` // The ID of the user who last saved changes to this query. LastModifiedById types.Int64 `tfsdk:"last_modified_by_id" tf:"optional"` // If there is a cached result for this query and user, this field includes @@ -2037,7 +2865,7 @@ type LegacyQuery struct { // on the query page. Name types.String `tfsdk:"name" tf:"optional"` - Options types.Object `tfsdk:"options" tf:"optional,object"` + Options types.List `tfsdk:"options" tf:"optional,object"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // * `CAN_VIEW`: Can view the query * `CAN_RUN`: Can run the query * @@ -2056,7 +2884,7 @@ type LegacyQuery struct { // The timestamp at which this query was last updated. UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` - User types.Object `tfsdk:"user" tf:"optional,object"` + User types.List `tfsdk:"user" tf:"optional,object"` // The ID of the user who owns the query. UserId types.Int64 `tfsdk:"user_id" tf:"optional"` @@ -2073,12 +2901,47 @@ func (a LegacyQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "LastModifiedBy": reflect.TypeOf(User{}), "Options": reflect.TypeOf(QueryOptions{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), "User": reflect.TypeOf(User{}), "Visualizations": reflect.TypeOf(LegacyVisualization{}), } } +func (a LegacyQuery) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CanEdit": types.BoolType, + "CreatedAt": types.StringType, + "DataSourceId": types.StringType, + "Description": types.StringType, + "Id": types.StringType, + "IsArchived": types.BoolType, + "IsDraft": types.BoolType, + "IsFavorite": types.BoolType, + "IsSafe": types.BoolType, + "LastModifiedBy": User{}.ToAttrType(ctx), + "LastModifiedById": types.Int64Type, + "LatestQueryDataId": types.StringType, + "Name": types.StringType, + "Options": QueryOptions{}.ToAttrType(ctx), + "Parent": types.StringType, + "PermissionTier": types.StringType, + "Query": types.StringType, + "QueryHash": types.StringType, + "RunAsRole": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "UpdatedAt": types.StringType, + "User": User{}.ToAttrType(ctx), + "UserId": types.Int64Type, + "Visualizations": basetypes.ListType{ + ElemType: LegacyVisualization{}.ToAttrType(ctx), + }, + }, + } +} + // The visualization description API changes frequently and is unsupported. You // can duplicate a visualization by copying description objects received _from // the API_ and then using them to create a new one with a POST request to the @@ -2099,7 +2962,7 @@ type LegacyVisualization struct { // settings in JSON. Options any `tfsdk:"options" tf:"optional"` - Query types.Object `tfsdk:"query" tf:"optional,object"` + Query types.List `tfsdk:"query" tf:"optional,object"` // The type of visualization: chart, table, pivot table, and so on. Type types.String `tfsdk:"type" tf:"optional"` @@ -2118,6 +2981,21 @@ func (a LegacyVisualization) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a LegacyVisualization) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.StringType, + "Description": types.StringType, + "Id": types.StringType, + "Name": types.StringType, + "Options": types.ObjectType{}, + "Query": LegacyQuery{}.ToAttrType(ctx), + "Type": types.StringType, + "UpdatedAt": types.StringType, + }, + } +} + // List alerts type ListAlertsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -2135,6 +3013,15 @@ func (a ListAlertsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListAlertsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListAlertsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -2153,9 +3040,20 @@ func (a ListAlertsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListAlertsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Results": basetypes.ListType{ + ElemType: ListAlertsResponseAlert{}.ToAttrType(ctx), + }, + }, + } +} + type ListAlertsResponseAlert struct { // Trigger conditions of the alert. - Condition types.Object `tfsdk:"condition" tf:"optional,object"` + Condition types.List `tfsdk:"condition" tf:"optional,object"` // The timestamp indicating when the alert was created. CreateTime types.String `tfsdk:"create_time" tf:"optional"` // Custom body of alert notification, if it exists. See [here] for custom @@ -2209,6 +3107,27 @@ func (a ListAlertsResponseAlert) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListAlertsResponseAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Condition": AlertCondition{}.ToAttrType(ctx), + "CreateTime": types.StringType, + "CustomBody": types.StringType, + "CustomSubject": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + "LifecycleState": types.StringType, + "NotifyOnOk": types.BoolType, + "OwnerUserName": types.StringType, + "QueryId": types.StringType, + "SecondsToRetrigger": types.Int64Type, + "State": types.StringType, + "TriggerTime": types.StringType, + "UpdateTime": types.StringType, + }, + } +} + // Get dashboard objects type ListDashboardsRequest struct { // Name of dashboard attribute to order by. @@ -2231,6 +3150,17 @@ func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Order": types.StringType, + "Page": types.Int64Type, + "PageSize": types.Int64Type, + "Q": types.StringType, + }, + } +} + // Get a list of queries type ListQueriesLegacyRequest struct { // Name of query attribute to order by. Default sort order is ascending. @@ -2266,6 +3196,17 @@ func (a ListQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a ListQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Order": types.StringType, + "Page": types.Int64Type, + "PageSize": types.Int64Type, + "Q": types.StringType, + }, + } +} + // List queries type ListQueriesRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -2283,6 +3224,15 @@ func (a ListQueriesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListQueriesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListQueriesResponse struct { // Whether there is another page of results. HasNextPage types.Bool `tfsdk:"has_next_page" tf:"optional"` @@ -2304,10 +3254,22 @@ func (a ListQueriesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListQueriesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "HasNextPage": types.BoolType, + "NextPageToken": types.StringType, + "Res": basetypes.ListType{ + ElemType: QueryInfo{}.ToAttrType(ctx), + }, + }, + } +} + // List Queries type ListQueryHistoryRequest struct { // A filter to limit query history results. This field is optional. - FilterBy types.Object `tfsdk:"-"` + FilterBy types.List `tfsdk:"-"` // Whether to include the query metrics with each query. Only use this for a // small subset of queries (max_results). Defaults to false. IncludeMetrics types.Bool `tfsdk:"-"` @@ -2333,6 +3295,17 @@ func (a ListQueryHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListQueryHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FilterBy": QueryFilter{}.ToAttrType(ctx), + "IncludeMetrics": types.BoolType, + "MaxResults": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListQueryObjectsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -2351,6 +3324,17 @@ func (a ListQueryObjectsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListQueryObjectsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Results": basetypes.ListType{ + ElemType: ListQueryObjectsResponseQuery{}.ToAttrType(ctx), + }, + }, + } +} + type ListQueryObjectsResponseQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -2397,7 +3381,34 @@ func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringRead(exi func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a ListQueryObjectsResponseQuery) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyAutoLimit": types.BoolType, + "Catalog": types.StringType, + "CreateTime": types.StringType, + "Description": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + "LastModifierUserName": types.StringType, + "LifecycleState": types.StringType, + "OwnerUserName": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: QueryParameter{}.ToAttrType(ctx), + }, + "QueryText": types.StringType, + "RunAsMode": types.StringType, + "Schema": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "UpdateTime": types.StringType, + "WarehouseId": types.StringType, + }, } } @@ -2424,6 +3435,19 @@ func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Count": types.Int64Type, + "Page": types.Int64Type, + "PageSize": types.Int64Type, + "Results": basetypes.ListType{ + ElemType: Dashboard{}.ToAttrType(ctx), + }, + }, + } +} + // List visualizations on a query type ListVisualizationsForQueryRequest struct { Id types.String `tfsdk:"-"` @@ -2443,6 +3467,16 @@ func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes() map[string]ref return map[string]reflect.Type{} } +func (a ListVisualizationsForQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "PageSize": types.Int64Type, + "PageToken": types.StringType, + }, + } +} + type ListVisualizationsForQueryResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -2461,6 +3495,17 @@ func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes() map[string]re } } +func (a ListVisualizationsForQueryResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Results": basetypes.ListType{ + ElemType: Visualization{}.ToAttrType(ctx), + }, + }, + } +} + // List warehouses type ListWarehousesRequest struct { // Service Principal which will be used to fetch the list of warehouses. If @@ -2478,6 +3523,14 @@ func (a ListWarehousesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListWarehousesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RunAsUserId": types.Int64Type, + }, + } +} + type ListWarehousesResponse struct { // A list of warehouses and their configurations. Warehouses types.List `tfsdk:"warehouses" tf:"optional"` @@ -2495,6 +3548,16 @@ func (a ListWarehousesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListWarehousesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Warehouses": basetypes.ListType{ + ElemType: EndpointInfo{}.ToAttrType(ctx), + }, + }, + } +} + type MultiValuesOptions struct { // Character that prefixes each selected parameter value. Prefix types.String `tfsdk:"prefix" tf:"optional"` @@ -2515,6 +3578,16 @@ func (a MultiValuesOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MultiValuesOptions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Prefix": types.StringType, + "Separator": types.StringType, + "Suffix": types.StringType, + }, + } +} + type NumericValue struct { Value types.Float64 `tfsdk:"value" tf:"optional"` } @@ -2529,6 +3602,14 @@ func (a NumericValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a NumericValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Value": types.Float64Type, + }, + } +} + type OdbcParams struct { Hostname types.String `tfsdk:"hostname" tf:"optional"` @@ -2549,13 +3630,24 @@ func (a OdbcParams) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a OdbcParams) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Hostname": types.StringType, + "Path": types.StringType, + "Port": types.Int64Type, + "Protocol": types.StringType, + }, + } +} + type Parameter struct { // List of valid parameter values, newline delimited. Only applies for // dropdown list parameters. EnumOptions types.String `tfsdk:"enumOptions" tf:"optional"` // If specified, allows multiple values to be selected for this parameter. // Only applies to dropdown list and query-based dropdown list parameters. - MultiValuesOptions types.Object `tfsdk:"multiValuesOptions" tf:"optional,object"` + MultiValuesOptions types.List `tfsdk:"multiValuesOptions" tf:"optional,object"` // The literal parameter marker that appears between double curly braces in // the query text. Name types.String `tfsdk:"name" tf:"optional"` @@ -2582,6 +3674,20 @@ func (a Parameter) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Parameter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EnumOptions": types.StringType, + "MultiValuesOptions": MultiValuesOptions{}.ToAttrType(ctx), + "Name": types.StringType, + "QueryId": types.StringType, + "Title": types.StringType, + "Type": types.StringType, + "Value": types.ObjectType{}, + }, + } +} + type Query struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -2630,13 +3736,41 @@ func (newState *Query) SyncEffectiveFieldsDuringRead(existingState Query) { func (a Query) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a Query) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyAutoLimit": types.BoolType, + "Catalog": types.StringType, + "CreateTime": types.StringType, + "Description": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + "LastModifierUserName": types.StringType, + "LifecycleState": types.StringType, + "OwnerUserName": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: QueryParameter{}.ToAttrType(ctx), + }, + "ParentPath": types.StringType, + "QueryText": types.StringType, + "RunAsMode": types.StringType, + "Schema": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "UpdateTime": types.StringType, + "WarehouseId": types.StringType, + }, } } type QueryBackedValue struct { // If specified, allows multiple values to be selected for this parameter. - MultiValuesOptions types.Object `tfsdk:"multi_values_options" tf:"optional,object"` + MultiValuesOptions types.List `tfsdk:"multi_values_options" tf:"optional,object"` // UUID of the query that provides the parameter values. QueryId types.String `tfsdk:"query_id" tf:"optional"` // List of selected query parameter values. @@ -2652,7 +3786,19 @@ func (newState *QueryBackedValue) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryBackedValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), - "Values": reflect.TypeOf(""), + "Values": reflect.TypeOf(types.StringType), + } +} + +func (a QueryBackedValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "MultiValuesOptions": MultiValuesOptions{}.ToAttrType(ctx), + "QueryId": types.StringType, + "Values": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -2692,14 +3838,31 @@ func (newState *QueryEditContent) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryEditContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a QueryEditContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataSourceId": types.StringType, + "Description": types.StringType, + "Name": types.StringType, + "Options": types.ObjectType{}, + "Query": types.StringType, + "QueryId": types.StringType, + "RunAsRole": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type QueryFilter struct { // A range filter for query submitted time. The time range must be <= 30 // days. - QueryStartTimeRange types.Object `tfsdk:"query_start_time_range" tf:"optional,object"` + QueryStartTimeRange types.List `tfsdk:"query_start_time_range" tf:"optional,object"` // A list of statement IDs. StatementIds types.List `tfsdk:"statement_ids" tf:"optional"` @@ -2719,16 +3882,36 @@ func (newState *QueryFilter) SyncEffectiveFieldsDuringRead(existingState QueryFi func (a QueryFilter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "QueryStartTimeRange": reflect.TypeOf(TimeRange{}), - "StatementIds": reflect.TypeOf(""), - "Statuses": reflect.TypeOf(""), - "UserIds": reflect.TypeOf(0), - "WarehouseIds": reflect.TypeOf(""), + "StatementIds": reflect.TypeOf(types.StringType), + "Statuses": reflect.TypeOf(types.StringType), + "UserIds": reflect.TypeOf(types.Int64Type), + "WarehouseIds": reflect.TypeOf(types.StringType), + } +} + +func (a QueryFilter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueryStartTimeRange": TimeRange{}.ToAttrType(ctx), + "StatementIds": basetypes.ListType{ + ElemType: types.StringType, + }, + "Statuses": basetypes.ListType{ + ElemType: types.StringType, + }, + "UserIds": basetypes.ListType{ + ElemType: types.Int64Type, + }, + "WarehouseIds": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } type QueryInfo struct { // SQL Warehouse channel information at the time of query execution - ChannelUsed types.Object `tfsdk:"channel_used" tf:"optional,object"` + ChannelUsed types.List `tfsdk:"channel_used" tf:"optional,object"` // Total execution time of the statement ( excluding result fetch time ). Duration types.Int64 `tfsdk:"duration" tf:"optional"` // Alias for `warehouse_id`. @@ -2747,7 +3930,7 @@ type QueryInfo struct { // A key that can be used to look up query details. LookupKey types.String `tfsdk:"lookup_key" tf:"optional"` // Metrics about query execution. - Metrics types.Object `tfsdk:"metrics" tf:"optional,object"` + Metrics types.List `tfsdk:"metrics" tf:"optional,object"` // Whether plans exist for the execution, or the reason why they are missing PlansState types.String `tfsdk:"plans_state" tf:"optional"` // The time the query ended. @@ -2791,6 +3974,35 @@ func (a QueryInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a QueryInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ChannelUsed": ChannelInfo{}.ToAttrType(ctx), + "Duration": types.Int64Type, + "EndpointId": types.StringType, + "ErrorMessage": types.StringType, + "ExecutedAsUserId": types.Int64Type, + "ExecutedAsUserName": types.StringType, + "ExecutionEndTimeMs": types.Int64Type, + "IsFinal": types.BoolType, + "LookupKey": types.StringType, + "Metrics": QueryMetrics{}.ToAttrType(ctx), + "PlansState": types.StringType, + "QueryEndTimeMs": types.Int64Type, + "QueryId": types.StringType, + "QueryStartTimeMs": types.Int64Type, + "QueryText": types.StringType, + "RowsProduced": types.Int64Type, + "SparkUiUrl": types.StringType, + "StatementType": types.StringType, + "Status": types.StringType, + "UserId": types.Int64Type, + "UserName": types.StringType, + "WarehouseId": types.StringType, + }, + } +} + type QueryList struct { // The total number of queries. Count types.Int64 `tfsdk:"count" tf:"optional"` @@ -2814,6 +4026,19 @@ func (a QueryList) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a QueryList) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Count": types.Int64Type, + "Page": types.Int64Type, + "PageSize": types.Int64Type, + "Results": basetypes.ListType{ + ElemType: LegacyQuery{}.ToAttrType(ctx), + }, + }, + } +} + // A query metric that encapsulates a set of measurements for a single query. // Metrics come from the driver and are stored in the history service database. type QueryMetrics struct { @@ -2885,6 +4110,35 @@ func (a QueryMetrics) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a QueryMetrics) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CompilationTimeMs": types.Int64Type, + "ExecutionTimeMs": types.Int64Type, + "NetworkSentBytes": types.Int64Type, + "OverloadingQueueStartTimestamp": types.Int64Type, + "PhotonTotalTimeMs": types.Int64Type, + "ProvisioningQueueStartTimestamp": types.Int64Type, + "PrunedBytes": types.Int64Type, + "PrunedFilesCount": types.Int64Type, + "QueryCompilationStartTimestamp": types.Int64Type, + "ReadBytes": types.Int64Type, + "ReadCacheBytes": types.Int64Type, + "ReadFilesCount": types.Int64Type, + "ReadPartitionsCount": types.Int64Type, + "ReadRemoteBytes": types.Int64Type, + "ResultFetchTimeMs": types.Int64Type, + "ResultFromCache": types.BoolType, + "RowsProducedCount": types.Int64Type, + "RowsReadCount": types.Int64Type, + "SpillToDiskBytes": types.Int64Type, + "TaskTotalTimeMs": types.Int64Type, + "TotalTimeMs": types.Int64Type, + "WriteRemoteBytes": types.Int64Type, + }, + } +} + type QueryOptions struct { // The name of the catalog to execute this query in. Catalog types.String `tfsdk:"catalog" tf:"optional"` @@ -2910,24 +4164,37 @@ func (a QueryOptions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a QueryOptions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Catalog": types.StringType, + "MovedToTrashAt": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: Parameter{}.ToAttrType(ctx), + }, + "Schema": types.StringType, + }, + } +} + type QueryParameter struct { // Date-range query parameter value. Can only specify one of // `dynamic_date_range_value` or `date_range_value`. - DateRangeValue types.Object `tfsdk:"date_range_value" tf:"optional,object"` + DateRangeValue types.List `tfsdk:"date_range_value" tf:"optional,object"` // Date query parameter value. Can only specify one of `dynamic_date_value` // or `date_value`. - DateValue types.Object `tfsdk:"date_value" tf:"optional,object"` + DateValue types.List `tfsdk:"date_value" tf:"optional,object"` // Dropdown query parameter value. - EnumValue types.Object `tfsdk:"enum_value" tf:"optional,object"` + EnumValue types.List `tfsdk:"enum_value" tf:"optional,object"` // Literal parameter marker that appears between double curly braces in the // query text. Name types.String `tfsdk:"name" tf:"optional"` // Numeric query parameter value. - NumericValue types.Object `tfsdk:"numeric_value" tf:"optional,object"` + NumericValue types.List `tfsdk:"numeric_value" tf:"optional,object"` // Query-based dropdown query parameter value. - QueryBackedValue types.Object `tfsdk:"query_backed_value" tf:"optional,object"` + QueryBackedValue types.List `tfsdk:"query_backed_value" tf:"optional,object"` // Text query parameter value. - TextValue types.Object `tfsdk:"text_value" tf:"optional,object"` + TextValue types.List `tfsdk:"text_value" tf:"optional,object"` // Text displayed in the user-facing parameter widget in the UI. Title types.String `tfsdk:"title" tf:"optional"` } @@ -2949,6 +4216,21 @@ func (a QueryParameter) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a QueryParameter) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DateRangeValue": DateRangeValue{}.ToAttrType(ctx), + "DateValue": DateValue{}.ToAttrType(ctx), + "EnumValue": EnumValue{}.ToAttrType(ctx), + "Name": types.StringType, + "NumericValue": NumericValue{}.ToAttrType(ctx), + "QueryBackedValue": QueryBackedValue{}.ToAttrType(ctx), + "TextValue": TextValue{}.ToAttrType(ctx), + "Title": types.StringType, + }, + } +} + type QueryPostContent struct { // Data source ID maps to the ID of the data source used by the resource and // is distinct from the warehouse ID. [Learn more] @@ -2985,7 +4267,24 @@ func (newState *QueryPostContent) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryPostContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a QueryPostContent) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataSourceId": types.StringType, + "Description": types.StringType, + "Name": types.StringType, + "Options": types.ObjectType{}, + "Parent": types.StringType, + "Query": types.StringType, + "RunAsRole": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -3009,6 +4308,19 @@ func (a RepeatedEndpointConfPairs) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a RepeatedEndpointConfPairs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ConfigPair": basetypes.ListType{ + ElemType: EndpointConfPair{}.ToAttrType(ctx), + }, + "ConfigurationPairs": basetypes.ListType{ + ElemType: EndpointConfPair{}.ToAttrType(ctx), + }, + }, + } +} + // Restore a dashboard type RestoreDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -3024,6 +4336,14 @@ func (a RestoreDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a RestoreDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DashboardId": types.StringType, + }, + } +} + // Restore a query type RestoreQueriesLegacyRequest struct { QueryId types.String `tfsdk:"-"` @@ -3039,6 +4359,14 @@ func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.T return map[string]reflect.Type{} } +func (a RestoreQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "QueryId": types.StringType, + }, + } +} + type RestoreResponse struct { } @@ -3052,6 +4380,12 @@ func (a RestoreResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a RestoreResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ResultData struct { // The number of bytes in the result chunk. This field is not available when // using `INLINE` disposition. @@ -3087,11 +4421,32 @@ func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultDa func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataArray": reflect.TypeOf(""), + "DataArray": reflect.TypeOf(types.StringType), "ExternalLinks": reflect.TypeOf(ExternalLink{}), } } +func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ByteCount": types.Int64Type, + "ChunkIndex": types.Int64Type, + "DataArray": basetypes.ListType{ + ElemType: basetypes.ListType{ + ElemType: types.StringType, + }, + }, + "ExternalLinks": basetypes.ListType{ + ElemType: ExternalLink{}.ToAttrType(ctx), + }, + "NextChunkIndex": types.Int64Type, + "NextChunkInternalLink": types.StringType, + "RowCount": types.Int64Type, + "RowOffset": types.Int64Type, + }, + } +} + // The result manifest provides schema and metadata for the result set. type ResultManifest struct { // Array of result set chunk metadata. @@ -3099,7 +4454,7 @@ type ResultManifest struct { Format types.String `tfsdk:"format" tf:"optional"` // The schema is an ordered list of column descriptions. - Schema types.Object `tfsdk:"schema" tf:"optional,object"` + Schema types.List `tfsdk:"schema" tf:"optional,object"` // The total number of bytes in the result set. This field is not available // when using `INLINE` disposition. TotalByteCount types.Int64 `tfsdk:"total_byte_count" tf:"optional"` @@ -3125,6 +4480,22 @@ func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Chunks": basetypes.ListType{ + ElemType: BaseChunkInfo{}.ToAttrType(ctx), + }, + "Format": types.StringType, + "Schema": ResultSchema{}.ToAttrType(ctx), + "TotalByteCount": types.Int64Type, + "TotalChunkCount": types.Int64Type, + "TotalRowCount": types.Int64Type, + "Truncated": types.BoolType, + }, + } +} + // The schema is an ordered list of column descriptions. type ResultSchema struct { ColumnCount types.Int64 `tfsdk:"column_count" tf:"optional"` @@ -3144,6 +4515,17 @@ func (a ResultSchema) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ResultSchema) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ColumnCount": types.Int64Type, + "Columns": basetypes.ListType{ + ElemType: ColumnInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ServiceError struct { ErrorCode types.String `tfsdk:"error_code" tf:"optional"` // A brief summary of the error condition. @@ -3160,6 +4542,15 @@ func (a ServiceError) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ServiceError) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ErrorCode": types.StringType, + "Message": types.StringType, + }, + } +} + // Set object ACL type SetRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -3182,6 +4573,18 @@ func (a SetRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SetRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AccessControl{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type SetResponse struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // An object's type and UUID, separated by a forward slash (/) character. @@ -3202,11 +4605,23 @@ func (a SetResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SetResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: AccessControl{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type SetWorkspaceWarehouseConfigRequest struct { // Optional: Channel selection details - Channel types.Object `tfsdk:"channel" tf:"optional,object"` + Channel types.List `tfsdk:"channel" tf:"optional,object"` // Deprecated: Use sql_configuration_parameters - ConfigParam types.Object `tfsdk:"config_param" tf:"optional,object"` + ConfigParam types.List `tfsdk:"config_param" tf:"optional,object"` // Spark confs for external hive metastore configuration JSON serialized // size must be less than <= 512K DataAccessConfig types.List `tfsdk:"data_access_config" tf:"optional"` @@ -3218,7 +4633,7 @@ type SetWorkspaceWarehouseConfigRequest struct { // specific type availability in the warehouse create and edit form UI. EnabledWarehouseTypes types.List `tfsdk:"enabled_warehouse_types" tf:"optional"` // Deprecated: Use sql_configuration_parameters - GlobalParam types.Object `tfsdk:"global_param" tf:"optional,object"` + GlobalParam types.List `tfsdk:"global_param" tf:"optional,object"` // GCP only: Google Service Account used to pass to cluster to access Google // Cloud Storage GoogleServiceAccount types.String `tfsdk:"google_service_account" tf:"optional"` @@ -3227,7 +4642,7 @@ type SetWorkspaceWarehouseConfigRequest struct { // Security policy for warehouses SecurityPolicy types.String `tfsdk:"security_policy" tf:"optional"` // SQL configuration parameters - SqlConfigurationParameters types.Object `tfsdk:"sql_configuration_parameters" tf:"optional,object"` + SqlConfigurationParameters types.List `tfsdk:"sql_configuration_parameters" tf:"optional,object"` } func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetWorkspaceWarehouseConfigRequest) { @@ -3247,6 +4662,26 @@ func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes() map[string]re } } +func (a SetWorkspaceWarehouseConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Channel": Channel{}.ToAttrType(ctx), + "ConfigParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + "DataAccessConfig": basetypes.ListType{ + ElemType: EndpointConfPair{}.ToAttrType(ctx), + }, + "EnabledWarehouseTypes": basetypes.ListType{ + ElemType: WarehouseTypePair{}.ToAttrType(ctx), + }, + "GlobalParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + "GoogleServiceAccount": types.StringType, + "InstanceProfileArn": types.StringType, + "SecurityPolicy": types.StringType, + "SqlConfigurationParameters": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, + } +} + type SetWorkspaceWarehouseConfigResponse struct { } @@ -3260,6 +4695,12 @@ func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a SetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Start a warehouse type StartRequest struct { // Required. Id of the SQL warehouse. @@ -3276,6 +4717,14 @@ func (a StartRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StartRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type StartWarehouseResponse struct { } @@ -3289,6 +4738,12 @@ func (a StartWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StartWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type StatementParameterListItem struct { // The name of a parameter marker to be substituted in the statement. Name types.String `tfsdk:"name" tf:""` @@ -3315,17 +4770,27 @@ func (a StatementParameterListItem) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a StatementParameterListItem) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + "Type": types.StringType, + "Value": types.StringType, + }, + } +} + type StatementResponse struct { // The result manifest provides schema and metadata for the result set. - Manifest types.Object `tfsdk:"manifest" tf:"optional,object"` + Manifest types.List `tfsdk:"manifest" tf:"optional,object"` - Result types.Object `tfsdk:"result" tf:"optional,object"` + Result types.List `tfsdk:"result" tf:"optional,object"` // The statement ID is returned upon successfully submitting a SQL // statement, and is a required reference for all subsequent calls. StatementId types.String `tfsdk:"statement_id" tf:"optional"` // The status response includes execution state and if relevant, error // information. - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` } func (newState *StatementResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan StatementResponse) { @@ -3342,10 +4807,21 @@ func (a StatementResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a StatementResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Manifest": ResultManifest{}.ToAttrType(ctx), + "Result": ResultData{}.ToAttrType(ctx), + "StatementId": types.StringType, + "Status": StatementStatus{}.ToAttrType(ctx), + }, + } +} + // The status response includes execution state and if relevant, error // information. type StatementStatus struct { - Error types.Object `tfsdk:"error" tf:"optional,object"` + Error types.List `tfsdk:"error" tf:"optional,object"` // Statement execution state: - `PENDING`: waiting for warehouse - // `RUNNING`: running - `SUCCEEDED`: execution was successful, result data // available for fetch - `FAILED`: execution failed; reason for failure @@ -3368,6 +4844,15 @@ func (a StatementStatus) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a StatementStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Error": ServiceError{}.ToAttrType(ctx), + "State": types.StringType, + }, + } +} + // Stop a warehouse type StopRequest struct { // Required. Id of the SQL warehouse. @@ -3384,6 +4869,14 @@ func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type StopWarehouseResponse struct { } @@ -3397,6 +4890,12 @@ func (a StopWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a StopWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type Success struct { Message types.String `tfsdk:"message" tf:"optional"` } @@ -3411,6 +4910,14 @@ func (a Success) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Success) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + }, + } +} + type TerminationReason struct { // status code indicating why the cluster was terminated Code types.String `tfsdk:"code" tf:"optional"` @@ -3429,7 +4936,19 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState T func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(""), + "Parameters": reflect.TypeOf(types.StringType), + } +} + +func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Code": types.StringType, + "Parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "Type": types.StringType, + }, } } @@ -3447,6 +4966,14 @@ func (a TextValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TextValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Value": types.StringType, + }, + } +} + type TimeRange struct { // The end time in milliseconds. EndTimeMs types.Int64 `tfsdk:"end_time_ms" tf:"optional"` @@ -3464,6 +4991,15 @@ func (a TimeRange) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TimeRange) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndTimeMs": types.Int64Type, + "StartTimeMs": types.Int64Type, + }, + } +} + type TransferOwnershipObjectId struct { // Email address for the new owner, who must exist in the workspace. NewOwner types.String `tfsdk:"new_owner" tf:"optional"` @@ -3479,12 +5015,20 @@ func (a TransferOwnershipObjectId) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a TransferOwnershipObjectId) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NewOwner": types.StringType, + }, + } +} + // Transfer object ownership type TransferOwnershipRequest struct { // Email address for the new owner, who must exist in the workspace. NewOwner types.String `tfsdk:"new_owner" tf:"optional"` // The ID of the object on which to change ownership. - ObjectId types.Object `tfsdk:"-"` + ObjectId types.List `tfsdk:"-"` // The type of object on which to change ownership. ObjectType types.String `tfsdk:"-"` } @@ -3501,6 +5045,16 @@ func (a TransferOwnershipRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a TransferOwnershipRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NewOwner": types.StringType, + "ObjectId": TransferOwnershipObjectId{}.ToAttrType(ctx), + "ObjectType": types.StringType, + }, + } +} + // Delete an alert type TrashAlertRequest struct { Id types.String `tfsdk:"-"` @@ -3516,6 +5070,14 @@ func (a TrashAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TrashAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + // Delete a query type TrashQueryRequest struct { Id types.String `tfsdk:"-"` @@ -3531,8 +5093,16 @@ func (a TrashQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a TrashQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + }, + } +} + type UpdateAlertRequest struct { - Alert types.Object `tfsdk:"alert" tf:"optional,object"` + Alert types.List `tfsdk:"alert" tf:"optional,object"` Id types.String `tfsdk:"-"` // Field mask is required to be passed into the PATCH request. Field mask @@ -3554,9 +5124,19 @@ func (a UpdateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Alert": UpdateAlertRequestAlert{}.ToAttrType(ctx), + "Id": types.StringType, + "UpdateMask": types.StringType, + }, + } +} + type UpdateAlertRequestAlert struct { // Trigger conditions of the alert. - Condition types.Object `tfsdk:"condition" tf:"optional,object"` + Condition types.List `tfsdk:"condition" tf:"optional,object"` // Custom body of alert notification, if it exists. See [here] for custom // templating instructions. // @@ -3595,10 +5175,25 @@ func (a UpdateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type } } +func (a UpdateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Condition": AlertCondition{}.ToAttrType(ctx), + "CustomBody": types.StringType, + "CustomSubject": types.StringType, + "DisplayName": types.StringType, + "NotifyOnOk": types.BoolType, + "OwnerUserName": types.StringType, + "QueryId": types.StringType, + "SecondsToRetrigger": types.Int64Type, + }, + } +} + type UpdateQueryRequest struct { Id types.String `tfsdk:"-"` - Query types.Object `tfsdk:"query" tf:"optional,object"` + Query types.List `tfsdk:"query" tf:"optional,object"` // Field mask is required to be passed into the PATCH request. Field mask // specifies which fields of the setting payload will be updated. The field // mask needs to be supplied as single string. To specify multiple fields in @@ -3618,6 +5213,16 @@ func (a UpdateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Query": UpdateQueryRequestQuery{}.ToAttrType(ctx), + "UpdateMask": types.StringType, + }, + } +} + type UpdateQueryRequestQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -3654,7 +5259,29 @@ func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingS func (a UpdateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(""), + "Tags": reflect.TypeOf(types.StringType), + } +} + +func (a UpdateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ApplyAutoLimit": types.BoolType, + "Catalog": types.StringType, + "Description": types.StringType, + "DisplayName": types.StringType, + "OwnerUserName": types.StringType, + "Parameters": basetypes.ListType{ + ElemType: QueryParameter{}.ToAttrType(ctx), + }, + "QueryText": types.StringType, + "RunAsMode": types.StringType, + "Schema": types.StringType, + "Tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "WarehouseId": types.StringType, + }, } } @@ -3671,6 +5298,12 @@ func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateVisualizationRequest struct { Id types.String `tfsdk:"-"` // Field mask is required to be passed into the PATCH request. Field mask @@ -3679,7 +5312,7 @@ type UpdateVisualizationRequest struct { // the field mask, use comma as the separator (no space). UpdateMask types.String `tfsdk:"update_mask" tf:""` - Visualization types.Object `tfsdk:"visualization" tf:"optional,object"` + Visualization types.List `tfsdk:"visualization" tf:"optional,object"` } func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateVisualizationRequest) { @@ -3694,6 +5327,16 @@ func (a UpdateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a UpdateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "UpdateMask": types.StringType, + "Visualization": UpdateVisualizationRequestVisualization{}.ToAttrType(ctx), + }, + } +} + type UpdateVisualizationRequestVisualization struct { // The display name of the visualization. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -3719,6 +5362,17 @@ func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes() map[stri return map[string]reflect.Type{} } +func (a UpdateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DisplayName": types.StringType, + "SerializedOptions": types.StringType, + "SerializedQueryPlan": types.StringType, + "Type": types.StringType, + }, + } +} + type User struct { Email types.String `tfsdk:"email" tf:"optional"` @@ -3737,6 +5391,16 @@ func (a User) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a User) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Email": types.StringType, + "Id": types.Int64Type, + "Name": types.StringType, + }, + } +} + type Visualization struct { // The timestamp indicating when the visualization was created. CreateTime types.String `tfsdk:"create_time" tf:"optional"` @@ -3770,6 +5434,21 @@ func (a Visualization) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Visualization) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreateTime": types.StringType, + "DisplayName": types.StringType, + "Id": types.StringType, + "QueryId": types.StringType, + "SerializedOptions": types.StringType, + "SerializedQueryPlan": types.StringType, + "Type": types.StringType, + "UpdateTime": types.StringType, + }, + } +} + type WarehouseAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -3791,6 +5470,17 @@ func (a WarehouseAccessControlRequest) GetComplexFieldTypes() map[string]reflect return map[string]reflect.Type{} } +func (a WarehouseAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type WarehouseAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -3816,6 +5506,20 @@ func (a WarehouseAccessControlResponse) GetComplexFieldTypes() map[string]reflec } } +func (a WarehouseAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: WarehousePermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type WarehousePermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -3832,7 +5536,19 @@ func (newState *WarehousePermission) SyncEffectiveFieldsDuringRead(existingState func (a WarehousePermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a WarehousePermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -3856,6 +5572,18 @@ func (a WarehousePermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a WarehousePermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: WarehouseAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type WarehousePermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -3872,6 +5600,15 @@ func (a WarehousePermissionsDescription) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a WarehousePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type WarehousePermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The SQL warehouse for which to get or manage permissions. @@ -3890,6 +5627,17 @@ func (a WarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflect.T } } +func (a WarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: WarehouseAccessControlRequest{}.ToAttrType(ctx), + }, + "WarehouseId": types.StringType, + }, + } +} + type WarehouseTypePair struct { // If set to false the specific warehouse type will not be be allowed as a // value for warehouse_type in CreateWarehouse and EditWarehouse @@ -3908,17 +5656,26 @@ func (a WarehouseTypePair) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a WarehouseTypePair) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Enabled": types.BoolType, + "WarehouseType": types.StringType, + }, + } +} + type Widget struct { // The unique ID for this widget. Id types.String `tfsdk:"id" tf:"optional"` - Options types.Object `tfsdk:"options" tf:"optional,object"` + Options types.List `tfsdk:"options" tf:"optional,object"` // The visualization description API changes frequently and is unsupported. // You can duplicate a visualization by copying description objects received // _from the API_ and then using them to create a new one with a POST // request to the same endpoint. Databricks does not recommend constructing // ad-hoc visualizations entirely in JSON. - Visualization types.Object `tfsdk:"visualization" tf:"optional,object"` + Visualization types.List `tfsdk:"visualization" tf:"optional,object"` // Unused field. Width types.Int64 `tfsdk:"width" tf:"optional"` } @@ -3936,6 +5693,17 @@ func (a Widget) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Widget) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Id": types.StringType, + "Options": WidgetOptions{}.ToAttrType(ctx), + "Visualization": LegacyVisualization{}.ToAttrType(ctx), + "Width": types.Int64Type, + }, + } +} + type WidgetOptions struct { // Timestamp when this object was created CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -3949,7 +5717,7 @@ type WidgetOptions struct { ParameterMappings any `tfsdk:"parameterMappings" tf:"optional"` // Coordinates of this widget on a dashboard. This portion of the API // changes frequently and is unsupported. - Position types.Object `tfsdk:"position" tf:"optional,object"` + Position types.List `tfsdk:"position" tf:"optional,object"` // Custom title of the widget Title types.String `tfsdk:"title" tf:"optional"` // Timestamp of the last time this object was updated. @@ -3968,6 +5736,20 @@ func (a WidgetOptions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a WidgetOptions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.StringType, + "Description": types.StringType, + "IsHidden": types.BoolType, + "ParameterMappings": types.ObjectType{}, + "Position": WidgetPosition{}.ToAttrType(ctx), + "Title": types.StringType, + "UpdatedAt": types.StringType, + }, + } +} + // Coordinates of this widget on a dashboard. This portion of the API changes // frequently and is unsupported. type WidgetPosition struct { @@ -3992,3 +5774,15 @@ func (newState *WidgetPosition) SyncEffectiveFieldsDuringRead(existingState Widg func (a WidgetPosition) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a WidgetPosition) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AutoHeight": types.BoolType, + "Col": types.Int64Type, + "Row": types.Int64Type, + "SizeX": types.Int64Type, + "SizeY": types.Int64Type, + }, + } +} diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 0366fb3743..5fd9a28086 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package vectorsearch_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type ColumnInfo struct { @@ -31,6 +34,14 @@ func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Name": types.StringType, + }, + } +} + type CreateEndpoint struct { // Type of endpoint. EndpointType types.String `tfsdk:"endpoint_type" tf:""` @@ -48,13 +59,22 @@ func (a CreateEndpoint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateEndpoint) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointType": types.StringType, + "Name": types.StringType, + }, + } +} + type CreateVectorIndexRequest struct { // Specification for Delta Sync Index. Required if `index_type` is // `DELTA_SYNC`. - DeltaSyncIndexSpec types.Object `tfsdk:"delta_sync_index_spec" tf:"optional,object"` + DeltaSyncIndexSpec types.List `tfsdk:"delta_sync_index_spec" tf:"optional,object"` // Specification for Direct Vector Access Index. Required if `index_type` is // `DIRECT_ACCESS`. - DirectAccessIndexSpec types.Object `tfsdk:"direct_access_index_spec" tf:"optional,object"` + DirectAccessIndexSpec types.List `tfsdk:"direct_access_index_spec" tf:"optional,object"` // Name of the endpoint to be used for serving the index EndpointName types.String `tfsdk:"endpoint_name" tf:""` // There are 2 types of Vector Search indexes: @@ -84,8 +104,21 @@ func (a CreateVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type } } +func (a CreateVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DeltaSyncIndexSpec": DeltaSyncVectorIndexSpecRequest{}.ToAttrType(ctx), + "DirectAccessIndexSpec": DirectAccessVectorIndexSpec{}.ToAttrType(ctx), + "EndpointName": types.StringType, + "IndexType": types.StringType, + "Name": types.StringType, + "PrimaryKey": types.StringType, + }, + } +} + type CreateVectorIndexResponse struct { - VectorIndex types.Object `tfsdk:"vector_index" tf:"optional,object"` + VectorIndex types.List `tfsdk:"vector_index" tf:"optional,object"` } func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateVectorIndexResponse) { @@ -100,6 +133,14 @@ func (a CreateVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a CreateVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "VectorIndex": VectorIndex{}.ToAttrType(ctx), + }, + } +} + // Result of the upsert or delete operation. type DeleteDataResult struct { // List of primary keys for rows that failed to process. @@ -116,7 +157,18 @@ func (newState *DeleteDataResult) SyncEffectiveFieldsDuringRead(existingState De func (a DeleteDataResult) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FailedPrimaryKeys": reflect.TypeOf(""), + "FailedPrimaryKeys": reflect.TypeOf(types.StringType), + } +} + +func (a DeleteDataResult) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FailedPrimaryKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "SuccessRowCount": types.Int64Type, + }, } } @@ -137,14 +189,25 @@ func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(exis func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrimaryKeys": reflect.TypeOf(""), + "PrimaryKeys": reflect.TypeOf(types.StringType), + } +} + +func (a DeleteDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexName": types.StringType, + "PrimaryKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } // Response to a delete data vector index request. type DeleteDataVectorIndexResponse struct { // Result of the upsert or delete operation. - Result types.Object `tfsdk:"result" tf:"optional,object"` + Result types.List `tfsdk:"result" tf:"optional,object"` // Status of the delete operation. Status types.String `tfsdk:"status" tf:"optional"` } @@ -161,6 +224,15 @@ func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect } } +func (a DeleteDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Result": DeleteDataResult{}.ToAttrType(ctx), + "Status": types.StringType, + }, + } +} + // Delete an endpoint type DeleteEndpointRequest struct { // Name of the endpoint @@ -177,6 +249,14 @@ func (a DeleteEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointName": types.StringType, + }, + } +} + type DeleteEndpointResponse struct { } @@ -190,6 +270,12 @@ func (a DeleteEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete an index type DeleteIndexRequest struct { // Name of the index @@ -206,6 +292,14 @@ func (a DeleteIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexName": types.StringType, + }, + } +} + type DeleteIndexResponse struct { } @@ -219,6 +313,12 @@ func (a DeleteIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeltaSyncVectorIndexSpecRequest struct { // [Optional] Select the columns to sync with the vector index. If you leave // this field blank, all columns from the source table are synced with the @@ -255,12 +355,31 @@ func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringRead(e func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ColumnsToSync": reflect.TypeOf(""), + "ColumnsToSync": reflect.TypeOf(types.StringType), "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), } } +func (a DeltaSyncVectorIndexSpecRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ColumnsToSync": basetypes.ListType{ + ElemType: types.StringType, + }, + "EmbeddingSourceColumns": basetypes.ListType{ + ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), + }, + "EmbeddingVectorColumns": basetypes.ListType{ + ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), + }, + "EmbeddingWritebackTable": types.StringType, + "PipelineType": types.StringType, + "SourceTable": types.StringType, + }, + } +} + type DeltaSyncVectorIndexSpecResponse struct { // The columns that contain the embedding source. EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` @@ -297,6 +416,23 @@ func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes() map[string]refl } } +func (a DeltaSyncVectorIndexSpecResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EmbeddingSourceColumns": basetypes.ListType{ + ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), + }, + "EmbeddingVectorColumns": basetypes.ListType{ + ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), + }, + "EmbeddingWritebackTable": types.StringType, + "PipelineId": types.StringType, + "PipelineType": types.StringType, + "SourceTable": types.StringType, + }, + } +} + type DirectAccessVectorIndexSpec struct { // Contains the optional model endpoint to use during query time. EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` @@ -324,6 +460,20 @@ func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes() map[string]reflect.T } } +func (a DirectAccessVectorIndexSpec) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EmbeddingSourceColumns": basetypes.ListType{ + ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), + }, + "EmbeddingVectorColumns": basetypes.ListType{ + ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), + }, + "SchemaJson": types.StringType, + }, + } +} + type EmbeddingSourceColumn struct { // Name of the embedding model endpoint EmbeddingModelEndpointName types.String `tfsdk:"embedding_model_endpoint_name" tf:"optional"` @@ -341,6 +491,15 @@ func (a EmbeddingSourceColumn) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EmbeddingSourceColumn) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EmbeddingModelEndpointName": types.StringType, + "Name": types.StringType, + }, + } +} + type EmbeddingVectorColumn struct { // Dimension of the embedding vector EmbeddingDimension types.Int64 `tfsdk:"embedding_dimension" tf:"optional"` @@ -358,13 +517,22 @@ func (a EmbeddingVectorColumn) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EmbeddingVectorColumn) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EmbeddingDimension": types.Int64Type, + "Name": types.StringType, + }, + } +} + type EndpointInfo struct { // Timestamp of endpoint creation CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` // Creator of the endpoint Creator types.String `tfsdk:"creator" tf:"optional"` // Current status of the endpoint - EndpointStatus types.Object `tfsdk:"endpoint_status" tf:"optional,object"` + EndpointStatus types.List `tfsdk:"endpoint_status" tf:"optional,object"` // Type of endpoint. EndpointType types.String `tfsdk:"endpoint_type" tf:"optional"` // Unique identifier of the endpoint @@ -391,6 +559,22 @@ func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreationTimestamp": types.Int64Type, + "Creator": types.StringType, + "EndpointStatus": EndpointStatus{}.ToAttrType(ctx), + "EndpointType": types.StringType, + "Id": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + "LastUpdatedUser": types.StringType, + "Name": types.StringType, + "NumIndexes": types.Int64Type, + }, + } +} + // Status information of an endpoint type EndpointStatus struct { // Additional status message @@ -409,6 +593,15 @@ func (a EndpointStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a EndpointStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Message": types.StringType, + "State": types.StringType, + }, + } +} + // Get an endpoint type GetEndpointRequest struct { // Name of the endpoint @@ -425,6 +618,14 @@ func (a GetEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointName": types.StringType, + }, + } +} + // Get an index type GetIndexRequest struct { // Name of the index @@ -441,6 +642,14 @@ func (a GetIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexName": types.StringType, + }, + } +} + type ListEndpointResponse struct { // An array of Endpoint objects Endpoints types.List `tfsdk:"endpoints" tf:"optional"` @@ -461,6 +670,17 @@ func (a ListEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Endpoints": basetypes.ListType{ + ElemType: EndpointInfo{}.ToAttrType(ctx), + }, + "NextPageToken": types.StringType, + }, + } +} + // List all endpoints type ListEndpointsRequest struct { // Token for pagination @@ -477,6 +697,14 @@ func (a ListEndpointsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListEndpointsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PageToken": types.StringType, + }, + } +} + // List indexes type ListIndexesRequest struct { // Name of the endpoint @@ -495,6 +723,15 @@ func (a ListIndexesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListIndexesRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointName": types.StringType, + "PageToken": types.StringType, + }, + } +} + type ListValue struct { Values types.List `tfsdk:"values" tf:"optional"` } @@ -511,6 +748,16 @@ func (a ListValue) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListValue) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Values": basetypes.ListType{ + ElemType: Value{}.ToAttrType(ctx), + }, + }, + } +} + type ListVectorIndexesResponse struct { // A token that can be used to get the next page of results. If not present, // there are no more results to show. @@ -531,12 +778,23 @@ func (a ListVectorIndexesResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a ListVectorIndexesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "VectorIndexes": basetypes.ListType{ + ElemType: MiniVectorIndex{}.ToAttrType(ctx), + }, + }, + } +} + // Key-value pair. type MapStringValueEntry struct { // Column name. Key types.String `tfsdk:"key" tf:"optional"` // Column value, nullable. - Value types.Object `tfsdk:"value" tf:"optional,object"` + Value types.List `tfsdk:"value" tf:"optional,object"` } func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringCreateOrUpdate(plan MapStringValueEntry) { @@ -551,6 +809,15 @@ func (a MapStringValueEntry) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a MapStringValueEntry) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": Value{}.ToAttrType(ctx), + }, + } +} + type MiniVectorIndex struct { // The user who created the index. Creator types.String `tfsdk:"creator" tf:"optional"` @@ -580,6 +847,18 @@ func (a MiniVectorIndex) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MiniVectorIndex) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Creator": types.StringType, + "EndpointName": types.StringType, + "IndexType": types.StringType, + "Name": types.StringType, + "PrimaryKey": types.StringType, + }, + } +} + // Request payload for getting next page of results. type QueryVectorIndexNextPageRequest struct { // Name of the endpoint. @@ -601,6 +880,16 @@ func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes() map[string]refle return map[string]reflect.Type{} } +func (a QueryVectorIndexNextPageRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "EndpointName": types.StringType, + "IndexName": types.StringType, + "PageToken": types.StringType, + }, + } +} + type QueryVectorIndexRequest struct { // List of column names to include in the response. Columns types.List `tfsdk:"columns" tf:""` @@ -634,20 +923,39 @@ func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingS func (a QueryVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Columns": reflect.TypeOf(""), - "QueryVector": reflect.TypeOf(0.0), + "Columns": reflect.TypeOf(types.StringType), + "QueryVector": reflect.TypeOf(types.Float64Type), + } +} + +func (a QueryVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Columns": basetypes.ListType{ + ElemType: types.StringType, + }, + "FiltersJson": types.StringType, + "IndexName": types.StringType, + "NumResults": types.Int64Type, + "QueryText": types.StringType, + "QueryType": types.StringType, + "QueryVector": basetypes.ListType{ + ElemType: types.Float64Type, + }, + "ScoreThreshold": types.Float64Type, + }, } } type QueryVectorIndexResponse struct { // Metadata about the result set. - Manifest types.Object `tfsdk:"manifest" tf:"optional,object"` + Manifest types.List `tfsdk:"manifest" tf:"optional,object"` // [Optional] Token that can be used in `QueryVectorIndexNextPage` API to // get next page of results. If more than 1000 results satisfy the query, // they are returned in groups of 1000. Empty value means no more results. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` // Data returned in the query result. - Result types.Object `tfsdk:"result" tf:"optional,object"` + Result types.List `tfsdk:"result" tf:"optional,object"` } func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryVectorIndexResponse) { @@ -663,6 +971,16 @@ func (a QueryVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a QueryVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Manifest": ResultManifest{}.ToAttrType(ctx), + "NextPageToken": types.StringType, + "Result": ResultData{}.ToAttrType(ctx), + }, + } +} + // Data returned in the query result. type ResultData struct { // Data rows returned in the query. @@ -679,7 +997,20 @@ func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultDa func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataArray": reflect.TypeOf(""), + "DataArray": reflect.TypeOf(types.StringType), + } +} + +func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DataArray": basetypes.ListType{ + ElemType: basetypes.ListType{ + ElemType: types.StringType, + }, + }, + "RowCount": types.Int64Type, + }, } } @@ -703,6 +1034,17 @@ func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ColumnCount": types.Int64Type, + "Columns": basetypes.ListType{ + ElemType: ColumnInfo{}.ToAttrType(ctx), + }, + }, + } +} + // Request payload for scanning data from a vector index. type ScanVectorIndexRequest struct { // Name of the vector index to scan. @@ -723,6 +1065,16 @@ func (a ScanVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ScanVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexName": types.StringType, + "LastPrimaryKey": types.StringType, + "NumResults": types.Int64Type, + }, + } +} + // Response to a scan vector index request. type ScanVectorIndexResponse struct { // List of data entries @@ -743,6 +1095,17 @@ func (a ScanVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ScanVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Data": basetypes.ListType{ + ElemType: Struct{}.ToAttrType(ctx), + }, + "LastPrimaryKey": types.StringType, + }, + } +} + type Struct struct { // Data entry, corresponding to a row in a vector index. Fields types.List `tfsdk:"fields" tf:"optional"` @@ -760,6 +1123,16 @@ func (a Struct) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Struct) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Fields": basetypes.ListType{ + ElemType: MapStringValueEntry{}.ToAttrType(ctx), + }, + }, + } +} + // Synchronize an index type SyncIndexRequest struct { // Name of the vector index to synchronize. Must be a Delta Sync Index. @@ -776,6 +1149,14 @@ func (a SyncIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SyncIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexName": types.StringType, + }, + } +} + type SyncIndexResponse struct { } @@ -789,6 +1170,12 @@ func (a SyncIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SyncIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Result of the upsert or delete operation. type UpsertDataResult struct { // List of primary keys for rows that failed to process. @@ -805,7 +1192,18 @@ func (newState *UpsertDataResult) SyncEffectiveFieldsDuringRead(existingState Up func (a UpsertDataResult) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FailedPrimaryKeys": reflect.TypeOf(""), + "FailedPrimaryKeys": reflect.TypeOf(types.StringType), + } +} + +func (a UpsertDataResult) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "FailedPrimaryKeys": basetypes.ListType{ + ElemType: types.StringType, + }, + "SuccessRowCount": types.Int64Type, + }, } } @@ -828,10 +1226,19 @@ func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect. return map[string]reflect.Type{} } +func (a UpsertDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexName": types.StringType, + "InputsJson": types.StringType, + }, + } +} + // Response to an upsert data vector index request. type UpsertDataVectorIndexResponse struct { // Result of the upsert or delete operation. - Result types.Object `tfsdk:"result" tf:"optional,object"` + Result types.List `tfsdk:"result" tf:"optional,object"` // Status of the upsert operation. Status types.String `tfsdk:"status" tf:"optional"` } @@ -848,10 +1255,19 @@ func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect } } +func (a UpsertDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Result": UpsertDataResult{}.ToAttrType(ctx), + "Status": types.StringType, + }, + } +} + type Value struct { BoolValue types.Bool `tfsdk:"bool_value" tf:"optional"` - ListValue types.Object `tfsdk:"list_value" tf:"optional,object"` + ListValue types.List `tfsdk:"list_value" tf:"optional,object"` NullValue types.String `tfsdk:"null_value" tf:"optional"` @@ -859,7 +1275,7 @@ type Value struct { StringValue types.String `tfsdk:"string_value" tf:"optional"` - StructValue types.Object `tfsdk:"struct_value" tf:"optional,object"` + StructValue types.List `tfsdk:"struct_value" tf:"optional,object"` } func (newState *Value) SyncEffectiveFieldsDuringCreateOrUpdate(plan Value) { @@ -875,13 +1291,26 @@ func (a Value) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a Value) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BoolValue": types.BoolType, + "ListValue": ListValue{}.ToAttrType(ctx), + "NullValue": types.StringType, + "NumberValue": types.Float64Type, + "StringValue": types.StringType, + "StructValue": Struct{}.ToAttrType(ctx), + }, + } +} + type VectorIndex struct { // The user who created the index. Creator types.String `tfsdk:"creator" tf:"optional"` - DeltaSyncIndexSpec types.Object `tfsdk:"delta_sync_index_spec" tf:"optional,object"` + DeltaSyncIndexSpec types.List `tfsdk:"delta_sync_index_spec" tf:"optional,object"` - DirectAccessIndexSpec types.Object `tfsdk:"direct_access_index_spec" tf:"optional,object"` + DirectAccessIndexSpec types.List `tfsdk:"direct_access_index_spec" tf:"optional,object"` // Name of the endpoint associated with the index EndpointName types.String `tfsdk:"endpoint_name" tf:"optional"` // There are 2 types of Vector Search indexes: @@ -897,7 +1326,7 @@ type VectorIndex struct { // Primary key of the index PrimaryKey types.String `tfsdk:"primary_key" tf:"optional"` - Status types.Object `tfsdk:"status" tf:"optional,object"` + Status types.List `tfsdk:"status" tf:"optional,object"` } func (newState *VectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan VectorIndex) { @@ -914,6 +1343,21 @@ func (a VectorIndex) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a VectorIndex) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Creator": types.StringType, + "DeltaSyncIndexSpec": DeltaSyncVectorIndexSpecResponse{}.ToAttrType(ctx), + "DirectAccessIndexSpec": DirectAccessVectorIndexSpec{}.ToAttrType(ctx), + "EndpointName": types.StringType, + "IndexType": types.StringType, + "Name": types.StringType, + "PrimaryKey": types.StringType, + "Status": VectorIndexStatus{}.ToAttrType(ctx), + }, + } +} + type VectorIndexStatus struct { // Index API Url to be used to perform operations on the index IndexUrl types.String `tfsdk:"index_url" tf:"optional"` @@ -934,3 +1378,14 @@ func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringRead(existingState V func (a VectorIndexStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } + +func (a VectorIndexStatus) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "IndexUrl": types.StringType, + "IndexedRowCount": types.Int64Type, + "Message": types.StringType, + "Ready": types.BoolType, + }, + } +} diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 9ec8a281ac..737e3941b0 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -11,9 +11,12 @@ We use go-native types for lists and maps intentionally for the ease for convert package workspace_tf import ( + "context" "reflect" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) type AclItem struct { @@ -33,6 +36,15 @@ func (a AclItem) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a AclItem) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Permission": types.StringType, + "Principal": types.StringType, + }, + } +} + type AzureKeyVaultSecretScopeMetadata struct { // The DNS of the KeyVault DnsName types.String `tfsdk:"dns_name" tf:""` @@ -51,6 +63,15 @@ func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes() map[string]refl return map[string]reflect.Type{} } +func (a AzureKeyVaultSecretScopeMetadata) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "DnsName": types.StringType, + "ResourceId": types.StringType, + }, + } +} + type CreateCredentialsRequest struct { // Git provider. This field is case-insensitive. The available Git providers // are `gitHub`, `bitbucketCloud`, `gitLab`, `azureDevOpsServices`, @@ -83,6 +104,16 @@ func (a CreateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a CreateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GitProvider": types.StringType, + "GitUsername": types.StringType, + "PersonalAccessToken": types.StringType, + }, + } +} + type CreateCredentialsResponse struct { // ID of the credential object in the workspace. CredentialId types.Int64 `tfsdk:"credential_id" tf:""` @@ -103,6 +134,16 @@ func (a CreateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a CreateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.Int64Type, + "GitProvider": types.StringType, + "GitUsername": types.StringType, + }, + } +} + type CreateRepoRequest struct { // Desired path for the repo in the workspace. Almost any path in the // workspace can be chosen. If repo is created in `/Repos`, path must be in @@ -115,7 +156,7 @@ type CreateRepoRequest struct { Provider types.String `tfsdk:"provider" tf:""` // If specified, the repo will be created with sparse checkout enabled. You // cannot enable/disable sparse checkout after the repo is created. - SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.List `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the Git repository to be linked. Url types.String `tfsdk:"url" tf:""` } @@ -132,6 +173,17 @@ func (a CreateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + "Provider": types.StringType, + "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), + "Url": types.StringType, + }, + } +} + type CreateRepoResponse struct { // Branch that the Git folder (repo) is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -145,7 +197,7 @@ type CreateRepoResponse struct { // Git provider of the linked Git repository. Provider types.String `tfsdk:"provider" tf:"optional"` // Sparse checkout settings for the Git folder (repo). - SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.List `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the linked Git repository. Url types.String `tfsdk:"url" tf:"optional"` } @@ -162,9 +214,23 @@ func (a CreateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Branch": types.StringType, + "HeadCommitId": types.StringType, + "Id": types.Int64Type, + "Path": types.StringType, + "Provider": types.StringType, + "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), + "Url": types.StringType, + }, + } +} + type CreateScope struct { // The metadata for the secret scope if the type is `AZURE_KEYVAULT` - BackendAzureKeyvault types.Object `tfsdk:"backend_azure_keyvault" tf:"optional,object"` + BackendAzureKeyvault types.List `tfsdk:"backend_azure_keyvault" tf:"optional,object"` // The principal that is initially granted `MANAGE` permission to the // created scope. InitialManagePrincipal types.String `tfsdk:"initial_manage_principal" tf:"optional"` @@ -187,6 +253,17 @@ func (a CreateScope) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a CreateScope) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BackendAzureKeyvault": AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), + "InitialManagePrincipal": types.StringType, + "Scope": types.StringType, + "ScopeBackendType": types.StringType, + }, + } +} + type CreateScopeResponse struct { } @@ -200,6 +277,12 @@ func (a CreateScopeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CreateScopeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type CredentialInfo struct { // ID of the credential object in the workspace. CredentialId types.Int64 `tfsdk:"credential_id" tf:""` @@ -220,6 +303,16 @@ func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.Int64Type, + "GitProvider": types.StringType, + "GitUsername": types.StringType, + }, + } +} + type Delete struct { // The absolute path of the notebook or directory. Path types.String `tfsdk:"path" tf:""` @@ -240,6 +333,15 @@ func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + "Recursive": types.BoolType, + }, + } +} + type DeleteAcl struct { // The principal to remove an existing ACL from. Principal types.String `tfsdk:"principal" tf:""` @@ -257,6 +359,15 @@ func (a DeleteAcl) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteAcl) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Principal": types.StringType, + "Scope": types.StringType, + }, + } +} + type DeleteAclResponse struct { } @@ -270,6 +381,12 @@ func (a DeleteAclResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteAclResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a credential type DeleteCredentialsRequest struct { // The ID for the corresponding credential to access. @@ -286,6 +403,14 @@ func (a DeleteCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a DeleteCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.Int64Type, + }, + } +} + type DeleteCredentialsResponse struct { } @@ -299,6 +424,12 @@ func (a DeleteCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a DeleteCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Delete a repo type DeleteRepoRequest struct { // The ID for the corresponding repo to delete. @@ -315,6 +446,14 @@ func (a DeleteRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RepoId": types.Int64Type, + }, + } +} + type DeleteRepoResponse struct { } @@ -328,6 +467,12 @@ func (a DeleteRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteResponse struct { } @@ -341,6 +486,12 @@ func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteScope struct { // Name of the scope to delete. Scope types.String `tfsdk:"scope" tf:""` @@ -356,6 +507,14 @@ func (a DeleteScope) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteScope) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Scope": types.StringType, + }, + } +} + type DeleteScopeResponse struct { } @@ -369,6 +528,12 @@ func (a DeleteScopeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteScopeResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type DeleteSecret struct { // Name of the secret to delete. Key types.String `tfsdk:"key" tf:""` @@ -386,6 +551,15 @@ func (a DeleteSecret) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteSecret) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Scope": types.StringType, + }, + } +} + type DeleteSecretResponse struct { } @@ -399,6 +573,12 @@ func (a DeleteSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a DeleteSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Export a workspace object type ExportRequest struct { // This specifies the format of the exported file. By default, this is @@ -431,6 +611,15 @@ func (a ExportRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExportRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Format": types.StringType, + "Path": types.StringType, + }, + } +} + type ExportResponse struct { // The base64-encoded content. If the limit (10MB) is exceeded, exception // with error code **MAX_NOTEBOOK_SIZE_EXCEEDED** is thrown. @@ -449,6 +638,15 @@ func (a ExportResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ExportResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "FileType": types.StringType, + }, + } +} + // Get secret ACL details type GetAclRequest struct { // The principal to fetch ACL information for. @@ -467,6 +665,15 @@ func (a GetAclRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetAclRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Principal": types.StringType, + "Scope": types.StringType, + }, + } +} + // Get a credential entry type GetCredentialsRequest struct { // The ID for the corresponding credential to access. @@ -483,6 +690,14 @@ func (a GetCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.Int64Type, + }, + } +} + type GetCredentialsResponse struct { // ID of the credential object in the workspace. CredentialId types.Int64 `tfsdk:"credential_id" tf:""` @@ -503,6 +718,16 @@ func (a GetCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.Int64Type, + "GitProvider": types.StringType, + "GitUsername": types.StringType, + }, + } +} + // Get repo permission levels type GetRepoPermissionLevelsRequest struct { // The repo for which to get or manage permissions. @@ -519,6 +744,14 @@ func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflec return map[string]reflect.Type{} } +func (a GetRepoPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RepoId": types.StringType, + }, + } +} + type GetRepoPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -536,6 +769,16 @@ func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes() map[string]refle } } +func (a GetRepoPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: RepoPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get repo permissions type GetRepoPermissionsRequest struct { // The repo for which to get or manage permissions. @@ -552,6 +795,14 @@ func (a GetRepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a GetRepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RepoId": types.StringType, + }, + } +} + // Get a repo type GetRepoRequest struct { // ID of the Git folder (repo) object in the workspace. @@ -568,6 +819,14 @@ func (a GetRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "RepoId": types.Int64Type, + }, + } +} + type GetRepoResponse struct { // Branch that the local version of the repo is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -580,7 +839,7 @@ type GetRepoResponse struct { // Git provider of the linked Git repository. Provider types.String `tfsdk:"provider" tf:"optional"` // Sparse checkout settings for the Git folder (repo). - SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.List `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the linked Git repository. Url types.String `tfsdk:"url" tf:"optional"` } @@ -597,6 +856,20 @@ func (a GetRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a GetRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Branch": types.StringType, + "HeadCommitId": types.StringType, + "Id": types.Int64Type, + "Path": types.StringType, + "Provider": types.StringType, + "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), + "Url": types.StringType, + }, + } +} + // Get a secret type GetSecretRequest struct { // The key to fetch secret for. @@ -615,6 +888,15 @@ func (a GetSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Scope": types.StringType, + }, + } +} + type GetSecretResponse struct { // A unique name to identify the secret. Key types.String `tfsdk:"key" tf:"optional"` @@ -632,6 +914,15 @@ func (a GetSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "Value": types.StringType, + }, + } +} + // Get status type GetStatusRequest struct { // The absolute path of the notebook or directory. @@ -648,6 +939,14 @@ func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + // Get workspace object permission levels type GetWorkspaceObjectPermissionLevelsRequest struct { // The workspace object for which to get or manage permissions. @@ -666,6 +965,15 @@ func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes() map[st return map[string]reflect.Type{} } +func (a GetWorkspaceObjectPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceObjectId": types.StringType, + "WorkspaceObjectType": types.StringType, + }, + } +} + type GetWorkspaceObjectPermissionLevelsResponse struct { // Specific permission levels PermissionLevels types.List `tfsdk:"permission_levels" tf:"optional"` @@ -683,6 +991,16 @@ func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes() map[s } } +func (a GetWorkspaceObjectPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "PermissionLevels": basetypes.ListType{ + ElemType: WorkspaceObjectPermissionsDescription{}.ToAttrType(ctx), + }, + }, + } +} + // Get workspace object permissions type GetWorkspaceObjectPermissionsRequest struct { // The workspace object for which to get or manage permissions. @@ -701,6 +1019,15 @@ func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string] return map[string]reflect.Type{} } +func (a GetWorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "WorkspaceObjectId": types.StringType, + "WorkspaceObjectType": types.StringType, + }, + } +} + type Import struct { // The base64-encoded content. This has a limit of 10 MB. // @@ -744,6 +1071,18 @@ func (a Import) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Import) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Content": types.StringType, + "Format": types.StringType, + "Language": types.StringType, + "Overwrite": types.BoolType, + "Path": types.StringType, + }, + } +} + type ImportResponse struct { } @@ -757,6 +1096,12 @@ func (a ImportResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ImportResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + // Lists ACLs type ListAclsRequest struct { // The name of the scope to fetch ACL information from. @@ -773,6 +1118,14 @@ func (a ListAclsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListAclsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Scope": types.StringType, + }, + } +} + type ListAclsResponse struct { // The associated ACLs rule applied to principals in the given scope. Items types.List `tfsdk:"items" tf:"optional"` @@ -790,6 +1143,16 @@ func (a ListAclsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListAclsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Items": basetypes.ListType{ + ElemType: AclItem{}.ToAttrType(ctx), + }, + }, + } +} + type ListCredentialsResponse struct { // List of credentials. Credentials types.List `tfsdk:"credentials" tf:"optional"` @@ -807,6 +1170,16 @@ func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type } } +func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Credentials": basetypes.ListType{ + ElemType: CredentialInfo{}.ToAttrType(ctx), + }, + }, + } +} + // Get repos type ListReposRequest struct { // Token used to get the next page of results. If not specified, returns the @@ -829,6 +1202,15 @@ func (a ListReposRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListReposRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "PathPrefix": types.StringType, + }, + } +} + type ListReposResponse struct { // Token that can be specified as a query parameter to the `GET /repos` // endpoint to retrieve the next page of results. @@ -849,6 +1231,17 @@ func (a ListReposResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListReposResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NextPageToken": types.StringType, + "Repos": basetypes.ListType{ + ElemType: RepoInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ListResponse struct { // List of objects. Objects types.List `tfsdk:"objects" tf:"optional"` @@ -866,6 +1259,16 @@ func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Objects": basetypes.ListType{ + ElemType: ObjectInfo{}.ToAttrType(ctx), + }, + }, + } +} + type ListScopesResponse struct { // The available secret scopes. Scopes types.List `tfsdk:"scopes" tf:"optional"` @@ -883,6 +1286,16 @@ func (a ListScopesResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListScopesResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Scopes": basetypes.ListType{ + ElemType: SecretScope{}.ToAttrType(ctx), + }, + }, + } +} + // List secret keys type ListSecretsRequest struct { // The name of the scope to list secrets within. @@ -899,6 +1312,14 @@ func (a ListSecretsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Scope": types.StringType, + }, + } +} + type ListSecretsResponse struct { // Metadata information of all secrets contained within the given scope. Secrets types.List `tfsdk:"secrets" tf:"optional"` @@ -916,6 +1337,16 @@ func (a ListSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a ListSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Secrets": basetypes.ListType{ + ElemType: SecretMetadata{}.ToAttrType(ctx), + }, + }, + } +} + // List contents type ListWorkspaceRequest struct { // UTC timestamp in milliseconds @@ -934,6 +1365,15 @@ func (a ListWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ListWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "NotebooksModifiedAfter": types.Int64Type, + "Path": types.StringType, + }, + } +} + type Mkdirs struct { // The absolute path of the directory. If the parent directories do not // exist, it will also create them. If the directory already exists, this @@ -951,6 +1391,14 @@ func (a Mkdirs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a Mkdirs) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Path": types.StringType, + }, + } +} + type MkdirsResponse struct { } @@ -964,6 +1412,12 @@ func (a MkdirsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a MkdirsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type ObjectInfo struct { // Only applicable to files. The creation UTC timestamp. CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -999,6 +1453,21 @@ func (a ObjectInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a ObjectInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CreatedAt": types.Int64Type, + "Language": types.StringType, + "ModifiedAt": types.Int64Type, + "ObjectId": types.Int64Type, + "ObjectType": types.StringType, + "Path": types.StringType, + "ResourceId": types.StringType, + "Size": types.Int64Type, + }, + } +} + type PutAcl struct { // The permission level applied to the principal. Permission types.String `tfsdk:"permission" tf:""` @@ -1018,6 +1487,16 @@ func (a PutAcl) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PutAcl) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Permission": types.StringType, + "Principal": types.StringType, + "Scope": types.StringType, + }, + } +} + type PutAclResponse struct { } @@ -1031,6 +1510,12 @@ func (a PutAclResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PutAclResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type PutSecret struct { // If specified, value will be stored as bytes. BytesValue types.String `tfsdk:"bytes_value" tf:"optional"` @@ -1052,6 +1537,17 @@ func (a PutSecret) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PutSecret) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BytesValue": types.StringType, + "Key": types.StringType, + "Scope": types.StringType, + "StringValue": types.StringType, + }, + } +} + type PutSecretResponse struct { } @@ -1065,6 +1561,12 @@ func (a PutSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a PutSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type RepoAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1086,6 +1588,17 @@ func (a RepoAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a RepoAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type RepoAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -1111,6 +1624,20 @@ func (a RepoAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Typ } } +func (a RepoAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: RepoPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + // Git folder (repo) information. type RepoInfo struct { // Name of the current git branch of the git folder (repo). @@ -1124,7 +1651,7 @@ type RepoInfo struct { // Git provider of the remote git repository, e.g. `gitHub`. Provider types.String `tfsdk:"provider" tf:"optional"` // Sparse checkout config for the git folder (repo). - SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.List `tfsdk:"sparse_checkout" tf:"optional,object"` // URL of the remote git repository. Url types.String `tfsdk:"url" tf:"optional"` } @@ -1141,6 +1668,20 @@ func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Branch": types.StringType, + "HeadCommitId": types.StringType, + "Id": types.Int64Type, + "Path": types.StringType, + "Provider": types.StringType, + "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), + "Url": types.StringType, + }, + } +} + type RepoPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1157,7 +1698,19 @@ func (newState *RepoPermission) SyncEffectiveFieldsDuringRead(existingState Repo func (a RepoPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a RepoPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1181,6 +1734,18 @@ func (a RepoPermissions) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RepoPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: RepoAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type RepoPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1197,6 +1762,15 @@ func (a RepoPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Ty return map[string]reflect.Type{} } +func (a RepoPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type RepoPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The repo for which to get or manage permissions. @@ -1215,6 +1789,17 @@ func (a RepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a RepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: RepoAccessControlRequest{}.ToAttrType(ctx), + }, + "RepoId": types.StringType, + }, + } +} + type SecretMetadata struct { // A unique name to identify the secret. Key types.String `tfsdk:"key" tf:"optional"` @@ -1232,11 +1817,20 @@ func (a SecretMetadata) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a SecretMetadata) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Key": types.StringType, + "LastUpdatedTimestamp": types.Int64Type, + }, + } +} + type SecretScope struct { // The type of secret scope backend. BackendType types.String `tfsdk:"backend_type" tf:"optional"` // The metadata for the secret scope if the type is `AZURE_KEYVAULT` - KeyvaultMetadata types.Object `tfsdk:"keyvault_metadata" tf:"optional,object"` + KeyvaultMetadata types.List `tfsdk:"keyvault_metadata" tf:"optional,object"` // A unique name to identify the secret scope. Name types.String `tfsdk:"name" tf:"optional"` } @@ -1253,6 +1847,16 @@ func (a SecretScope) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a SecretScope) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "BackendType": types.StringType, + "KeyvaultMetadata": AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), + "Name": types.StringType, + }, + } +} + // Sparse checkout configuration, it contains options like cone patterns. type SparseCheckout struct { // List of sparse checkout cone patterns, see [cone mode handling] for @@ -1270,7 +1874,17 @@ func (newState *SparseCheckout) SyncEffectiveFieldsDuringRead(existingState Spar func (a SparseCheckout) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Patterns": reflect.TypeOf(""), + "Patterns": reflect.TypeOf(types.StringType), + } +} + +func (a SparseCheckout) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Patterns": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1291,7 +1905,17 @@ func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringRead(existingStat func (a SparseCheckoutUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Patterns": reflect.TypeOf(""), + "Patterns": reflect.TypeOf(types.StringType), + } +} + +func (a SparseCheckoutUpdate) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Patterns": basetypes.ListType{ + ElemType: types.StringType, + }, + }, } } @@ -1329,6 +1953,17 @@ func (a UpdateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type return map[string]reflect.Type{} } +func (a UpdateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "CredentialId": types.Int64Type, + "GitProvider": types.StringType, + "GitUsername": types.StringType, + "PersonalAccessToken": types.StringType, + }, + } +} + type UpdateCredentialsResponse struct { } @@ -1342,6 +1977,12 @@ func (a UpdateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Typ return map[string]reflect.Type{} } +func (a UpdateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type UpdateRepoRequest struct { // Branch that the local version of the repo is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -1349,7 +1990,7 @@ type UpdateRepoRequest struct { RepoId types.Int64 `tfsdk:"-"` // If specified, update the sparse checkout settings. The update will fail // if sparse checkout is not enabled for the repo. - SparseCheckout types.Object `tfsdk:"sparse_checkout" tf:"optional,object"` + SparseCheckout types.List `tfsdk:"sparse_checkout" tf:"optional,object"` // Tag that the local version of the repo is checked out to. Updating the // repo to a tag puts the repo in a detached HEAD state. Before committing // new changes, you must update the repo to a branch instead of the detached @@ -1369,6 +2010,17 @@ func (a UpdateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { } } +func (a UpdateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Branch": types.StringType, + "RepoId": types.Int64Type, + "SparseCheckout": SparseCheckoutUpdate{}.ToAttrType(ctx), + "Tag": types.StringType, + }, + } +} + type UpdateRepoResponse struct { } @@ -1382,6 +2034,12 @@ func (a UpdateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{} } +func (a UpdateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } +} + type WorkspaceObjectAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -1403,6 +2061,17 @@ func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes() map[string]r return map[string]reflect.Type{} } +func (a WorkspaceObjectAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "GroupName": types.StringType, + "PermissionLevel": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type WorkspaceObjectAccessControlResponse struct { // All permissions. AllPermissions types.List `tfsdk:"all_permissions" tf:"optional"` @@ -1428,6 +2097,20 @@ func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes() map[string] } } +func (a WorkspaceObjectAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AllPermissions": basetypes.ListType{ + ElemType: WorkspaceObjectPermission{}.ToAttrType(ctx), + }, + "DisplayName": types.StringType, + "GroupName": types.StringType, + "ServicePrincipalName": types.StringType, + "UserName": types.StringType, + }, + } +} + type WorkspaceObjectPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1444,7 +2127,19 @@ func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringRead(existin func (a WorkspaceObjectPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(""), + "InheritedFromObject": reflect.TypeOf(types.StringType), + } +} + +func (a WorkspaceObjectPermission) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Inherited": types.BoolType, + "InheritedFromObject": basetypes.ListType{ + ElemType: types.StringType, + }, + "PermissionLevel": types.StringType, + }, } } @@ -1468,6 +2163,18 @@ func (a WorkspaceObjectPermissions) GetComplexFieldTypes() map[string]reflect.Ty } } +func (a WorkspaceObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: WorkspaceObjectAccessControlResponse{}.ToAttrType(ctx), + }, + "ObjectId": types.StringType, + "ObjectType": types.StringType, + }, + } +} + type WorkspaceObjectPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1484,6 +2191,15 @@ func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes() map[string return map[string]reflect.Type{} } +func (a WorkspaceObjectPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "Description": types.StringType, + "PermissionLevel": types.StringType, + }, + } +} + type WorkspaceObjectPermissionsRequest struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // The workspace object for which to get or manage permissions. @@ -1503,3 +2219,15 @@ func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string]ref "AccessControlList": reflect.TypeOf(WorkspaceObjectAccessControlRequest{}), } } + +func (a WorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "AccessControlList": basetypes.ListType{ + ElemType: WorkspaceObjectAccessControlRequest{}.ToAttrType(ctx), + }, + "WorkspaceObjectId": types.StringType, + "WorkspaceObjectType": types.StringType, + }, + } +} From ff111822782db444d250ac5c0cce8906ec2106f2 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 09:15:12 +0100 Subject: [PATCH 29/91] fixes --- .../pluginfw/products/app/app_acc_test.go | 45 ++++++++++--------- .../pluginfw/products/app/resource_app.go | 18 -------- 2 files changed, 23 insertions(+), 40 deletions(-) diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index 1488f81619..8fc8c5950d 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -54,31 +54,32 @@ const baseResources = ` ` /* + resources { + name = "warehouse" + description = "warehouse for app" + job { + id = databricks_job.this.id + permission = "CAN_MANAGE" + } + } - resources { - name = "warehouse" - description = "warehouse for app" - job { - id = databricks_job.this.id - permission = "CAN_MANAGE" - } + resources { + name = "serving endpoint" + description = "serving endpoint for app" + serving_endpoint { + name = databricks_model_serving.this.name + permission = "CAN_MANAGE" } - resources { - name = "serving endpoint" - description = "serving endpoint for app" - serving_endpoint { - name = databricks_model_serving.this.name - permission = "CAN_MANAGE" - } - } - resources { - name = "sql warehouse" - description = "sql warehouse for app" - sql_warehouse { - id = databricks_sql_endpoint.this.id - permission = "CAN_MANAGE" - } + } + + resources { + name = "sql warehouse" + description = "sql warehouse for app" + sql_warehouse { + id = databricks_sql_endpoint.this.id + permission = "CAN_MANAGE" } + } */ func makeTemplate(description string) string { appTemplate := baseResources + ` diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 267422cb82..4fcf9f6a35 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -112,13 +112,7 @@ func (a *resourceApp) Create(ctx context.Context, req resource.CreateRequest, re if resp.Diagnostics.HasError() { return } - appStatus := newApp.AppStatus[0] - computeStatus := newApp.ComputeStatus[0] - newApp.AppStatus = nil - newApp.ComputeStatus = nil resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) - resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("app_status"), appStatus)...) - resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("compute_status"), computeStatus)...) if resp.Diagnostics.HasError() { return } @@ -167,13 +161,7 @@ func (a *resourceApp) Read(ctx context.Context, req resource.ReadRequest, resp * return } - appStatus := newApp.AppStatus[0] - computeStatus := newApp.ComputeStatus[0] - newApp.AppStatus = nil - newApp.ComputeStatus = nil resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) - resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("app_status"), appStatus)...) - resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("compute_status"), computeStatus)...) } func (a *resourceApp) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse) { @@ -208,13 +196,7 @@ func (a *resourceApp) Update(ctx context.Context, req resource.UpdateRequest, re if resp.Diagnostics.HasError() { return } - appStatus := newApp.AppStatus[0] - computeStatus := newApp.ComputeStatus[0] - newApp.AppStatus = nil - newApp.ComputeStatus = nil resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) - resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("app_status"), appStatus)...) - resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Empty().AtName("compute_status"), computeStatus)...) } func (a *resourceApp) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse) { From 8af1c311c11b933d96e80c5e4f982f0fae6f46af Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 09:15:51 +0100 Subject: [PATCH 30/91] works --- internal/acceptance/credential_test.go | 4 +- .../common/complex_field_type_provider.go | 3 +- .../providers/pluginfw/converters/go_to_tf.go | 42 +- .../providers/pluginfw/converters/tf_to_go.go | 30 +- .../resource_quality_monitor.go | 15 + .../products/sharing/resource_share.go | 11 + .../pluginfw/tfschema/struct_to_schema.go | 30 +- internal/service/apps_tf/model.go | 244 +- internal/service/billing_tf/model.go | 272 +- internal/service/catalog_tf/model.go | 2440 +++++++++-------- internal/service/compute_tf/model.go | 1912 +++++++------ internal/service/dashboards_tf/model.go | 350 +-- internal/service/files_tf/model.go | 108 +- internal/service/iam_tf/model.go | 498 ++-- internal/service/jobs_tf/model.go | 2004 ++++++++------ internal/service/marketplace_tf/model.go | 888 +++--- internal/service/ml_tf/model.go | 1004 +++---- internal/service/oauth2_tf/model.go | 202 +- internal/service/pipelines_tf/model.go | 816 +++--- internal/service/provisioning_tf/model.go | 486 ++-- internal/service/serving_tf/model.go | 854 +++--- internal/service/settings_tf/model.go | 858 +++--- internal/service/sharing_tf/model.go | 370 +-- internal/service/sql_tf/model.go | 1704 ++++++------ internal/service/vectorsearch_tf/model.go | 322 ++- internal/service/workspace_tf/model.go | 390 +-- 26 files changed, 8717 insertions(+), 7140 deletions(-) diff --git a/internal/acceptance/credential_test.go b/internal/acceptance/credential_test.go index 73a2b15b31..efbd492318 100644 --- a/internal/acceptance/credential_test.go +++ b/internal/acceptance/credential_test.go @@ -5,8 +5,8 @@ import ( ) func TestUcAccCredential(t *testing.T) { - loadUcwsEnv(t) - if isAws(t) { + LoadUcwsEnv(t) + if IsAws(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_credential" "external" { diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go index 59c0d0186b..d5538c73b1 100644 --- a/internal/providers/pluginfw/common/complex_field_type_provider.go +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -1,6 +1,7 @@ package common import ( + "context" "reflect" "github.com/hashicorp/terraform-plugin-framework/types" @@ -8,5 +9,5 @@ import ( type ComplexFieldTypeProvider interface { GetComplexFieldTypes() map[string]reflect.Type - ToAttrType() types.ObjectType + ToAttrType(context.Context) types.ObjectType } diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index d1d80255b1..d04e16ca58 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -58,7 +58,7 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ var objectType types.ObjectType if cftp, ok := destVal.Interface().(tfcommon.ComplexFieldTypeProvider); ok { complexFieldTypes = cftp.GetComplexFieldTypes() - objectType = cftp.ToAttrType() + objectType = cftp.ToAttrType(ctx) } var forceSendFieldVal []string @@ -79,13 +79,21 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ continue } destField := destVal.FieldByName(srcFieldName) + destFieldType, ok := destVal.Type().FieldByName(field.StructField.Name) + if !ok { + panic(fmt.Errorf("destination struct does not have field %s. %s", srcFieldName, common.TerraformBugErrorMessage)) + } + destFieldName := destFieldType.Tag.Get("tfsdk") + if destFieldName == "-" { + continue + } if !destField.IsValid() { logger.Tracef(ctx, fmt.Sprintf("field skipped in gosdk to tfsdk conversion: destination struct does not have field %s", srcFieldName)) continue } - innerType, _ := objectType.AttrTypes[srcFieldName] - complexFieldType, _ := complexFieldTypes[srcFieldName] + innerType := objectType.AttrTypes[destFieldName] + complexFieldType := complexFieldTypes[destFieldName] err := goSdkToTfSdkSingleField(ctx, srcField, destField, fieldInForceSendFields(srcFieldName, forceSendFieldVal), innerType, complexFieldType) if err != nil { @@ -115,6 +123,12 @@ func goSdkToTfSdkSingleField( if srcField.Kind() == reflect.Ptr { if srcField.IsNil() { + // If the destination field is a types.List, treat the source field as an empty slice. + if destField.Type() == reflect.TypeOf(types.List{}) { + listType := innerType.(types.ListType) + emptyList := types.ListNull(listType.ElemType) + destField.Set(reflect.ValueOf(emptyList)) + } // Skip nils return nil } @@ -166,6 +180,12 @@ func goSdkToTfSdkSingleField( } case reflect.Struct: if srcField.IsZero() { + // If the destination field is a types.List, treat the source field as an empty slice. + if destField.Type() == reflect.TypeOf(types.List{}) { + emptyList := types.ListNull(innerType) + destField.Set(reflect.ValueOf(emptyList)) + return nil + } // Skip zeros return nil } @@ -191,22 +211,22 @@ func goSdkToTfSdkSingleField( panic(fmt.Sprintf("%s. %s", goSdkToTfSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) } case reflect.Slice: - if srcField.IsNil() { - // Skip nils - return nil - } // If the target is a types.List, we first convert each element of the slice to the corresponding inner type // and then set the list. if destField.Type() == reflect.TypeOf(types.List{}) { + listType, ok := innerType.(types.ListType) + if !ok { + panic(fmt.Errorf("inner type is not a list type: %s. %s", innerType, common.TerraformBugErrorMessage)) + } elements := make([]any, 0, srcField.Len()) for i := 0; i < srcField.Len(); i++ { element := reflect.New(complexFieldType).Elem() - if err := goSdkToTfSdkSingleField(ctx, srcField.Index(i), element, true, innerType, complexFieldType); err != nil { + if err := goSdkToTfSdkSingleField(ctx, srcField.Index(i), element, true, listType.ElemType, complexFieldType); err != nil { return err } elements = append(elements, element.Interface()) } - destVal, d := types.ListValueFrom(ctx, innerType, elements) + destVal, d := types.ListValueFrom(ctx, listType.ElemType, elements) if d.HasError() { for _, diag := range d { tflog.Error(ctx, diag.Detail()) @@ -215,6 +235,10 @@ func goSdkToTfSdkSingleField( } destField.Set(reflect.ValueOf(destVal)) } else { + if srcField.IsNil() { + // Skip nils + return nil + } destSlice := reflect.MakeSlice(destField.Type(), srcField.Len(), srcField.Cap()) for j := 0; j < srcField.Len(); j++ { diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index ae47ed6f83..78da633214 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -69,7 +69,7 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ } destField := destVal.FieldByName(srcFieldName) - innerType, _ := innerTypes[srcFieldName] + innerType := innerTypes[srcFieldTag] err := tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField, innerType) if err != nil { @@ -95,7 +95,7 @@ func tfSdkToGoSdkSingleField( } if !destField.CanSet() { - panic(fmt.Errorf("destination field can not be set: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) + panic(fmt.Errorf("destination field can not be set: %T. %s", destField.Type(), common.TerraformBugErrorMessage)) } srcFieldValue := srcField.Interface() @@ -231,7 +231,7 @@ func tfsdkToGoSdkStructField( destVal := convertToEnumValue(v, destField.Type()) // We don't need to set ForceSendFields for enums because the value is never going to be a zero value (empty string). - destField.Set(destVal.Elem()) + destField.Set(destVal) } else { destField.SetString(v.ValueString()) if !v.IsNull() { @@ -260,25 +260,31 @@ func tfsdkToGoSdkStructField( if destField.Type().Kind() == reflect.Slice { destInnerType = destField.Type().Elem() } else { - assertStructSliceLengthIsOne(innerValue) - // Case of types.List <-> struct - destInnerType = destField.Type() + assertStructSliceLengthIsOne(innerValue.Elem()) + // Case of types.List <-> struct or ptr + if destField.Type().Kind() == reflect.Ptr { + destInnerType = destField.Type().Elem() + } else { + destInnerType = destField.Type() + } } - converted := make([]any, 0, innerValue.Elem().Len()) + converted := reflect.MakeSlice(reflect.SliceOf(destInnerType), 0, innerValue.Elem().Len()) for i := 0; i < innerValue.Elem().Len(); i++ { - next := reflect.New(destInnerType) - err := tfSdkToGoSdkSingleField(ctx, innerValue.Elem().Index(i), next, "", forceSendFieldsField, innerType) + next := reflect.New(destInnerType).Elem() + err := tfSdkToGoSdkSingleField(ctx, innerValue.Elem().Index(i), next, srcFieldName, forceSendFieldsField, innerType) if err != nil { panic(err) } - converted = append(converted, next.Elem().Interface()) + converted = reflect.Append(converted, next) } if destField.Type().Kind() == reflect.Slice { - destField.Set(reflect.ValueOf(converted)) + destField.Set(converted) + } else if destField.Type().Kind() == reflect.Ptr { + destField.Set(converted.Index(0).Addr()) } else { - destField.Set(reflect.ValueOf(converted[0])) + destField.Set(converted.Index(0)) } case types.Object, types.Map, types.Set, types.Tuple: panic(fmt.Sprintf("%T should never be used, use go native maps instead. %s", v, common.TerraformBugErrorMessage)) diff --git a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go index 8f6551922c..d7939241a6 100644 --- a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go +++ b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go @@ -3,6 +3,7 @@ package qualitymonitor import ( "context" "fmt" + "reflect" "time" "github.com/databricks/databricks-sdk-go" @@ -61,6 +62,20 @@ type MonitorInfoExtended struct { ID types.String `tfsdk:"id" tf:"optional,computed"` // Adding ID field to stay compatible with SDKv2 } +var _ pluginfwcommon.ComplexFieldTypeProvider = MonitorInfoExtended{} + +func (m MonitorInfoExtended) GetComplexFieldTypes() map[string]reflect.Type { + return m.MonitorInfo.GetComplexFieldTypes() +} + +func (m MonitorInfoExtended) ToAttrType(ctx context.Context) types.ObjectType { + tpe := m.MonitorInfo.ToAttrType(ctx) + tpe.AttrTypes["warehouse_id"] = types.StringType + tpe.AttrTypes["skip_builtin_dashboard"] = types.BoolType + tpe.AttrTypes["id"] = types.StringType + return tpe +} + type QualityMonitorResource struct { Client *common.DatabricksClient } diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index c2568d7268..d6f099bbc5 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -19,6 +19,7 @@ import ( "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/int64planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" + "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) @@ -34,6 +35,16 @@ type ShareInfoExtended struct { sharing_tf.ShareInfo } +var _ pluginfwcommon.ComplexFieldTypeProvider = ShareInfoExtended{} + +func (s ShareInfoExtended) GetComplexFieldTypes() map[string]reflect.Type { + return s.ShareInfo.GetComplexFieldTypes() +} + +func (s ShareInfoExtended) ToAttrType(ctx context.Context) types.ObjectType { + return s.ShareInfo.ToAttrType(ctx) +} + func matchOrder[T any, K comparable](target, reference []T, keyFunc func(T) K) { // Create a map to store the index positions of each key in the reference slice. orderMap := make(map[K]int) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 01b229b043..80f7f4d445 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -226,7 +226,35 @@ func typeToSchema(v reflect.Value) NestedBlockObject { scmBlock[fieldName] = SingleNestedBlockBuilder{ NestedObject: typeToSchema(fieldValue), } - case types.Set, types.Tuple, types.Map: + case types.Map: + // Look up nested struct type + if complexFieldTypes == nil { + panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) + } + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + } + // If the field type is a "primitive", use MapAttributeBuilder + // otherwise use MapNestedAttributeBuilder + switch fieldType { + case reflect.TypeOf(types.BoolType), reflect.TypeOf(types.Int64Type), reflect.TypeOf(types.Float64Type), reflect.TypeOf(types.StringType): + scmAttr[fieldName] = MapAttributeBuilder{ + ElementType: reflect.New(fieldType).Elem().Interface().(attr.Type), + Optional: structTag.optional, + Required: !structTag.optional, + Computed: structTag.computed, + } + default: + fieldValue := reflect.New(fieldType).Elem() + + // Generate the nested block schema + // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). + scmAttr[fieldName] = MapNestedAttributeBuilder{ + NestedObject: typeToSchema(fieldValue).ToNestedAttributeObject(), + } + } + case types.Set, types.Tuple: panic(fmt.Errorf("%T should never be used in tfsdk structs. %s", value.Interface(), common.TerraformBugErrorMessage)) default: // If it is a real stuct instead of a tfsdk type, recursively resolve it. diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index abba0ddbaa..743548e169 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -67,35 +67,43 @@ func (newState *App) SyncEffectiveFieldsDuringRead(existingState App) { func (a App) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ActiveDeployment": reflect.TypeOf(AppDeployment{}), - "AppStatus": reflect.TypeOf(ApplicationStatus{}), - "ComputeStatus": reflect.TypeOf(ComputeStatus{}), - "PendingDeployment": reflect.TypeOf(AppDeployment{}), - "Resources": reflect.TypeOf(AppResource{}), + "active_deployment": reflect.TypeOf(AppDeployment{}), + "app_status": reflect.TypeOf(ApplicationStatus{}), + "compute_status": reflect.TypeOf(ComputeStatus{}), + "pending_deployment": reflect.TypeOf(AppDeployment{}), + "resources": reflect.TypeOf(AppResource{}), } } func (a App) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActiveDeployment": AppDeployment{}.ToAttrType(ctx), - "AppStatus": ApplicationStatus{}.ToAttrType(ctx), - "ComputeStatus": ComputeStatus{}.ToAttrType(ctx), - "CreateTime": types.StringType, - "Creator": types.StringType, - "DefaultSourceCodePath": types.StringType, - "Description": types.StringType, - "Name": types.StringType, - "PendingDeployment": AppDeployment{}.ToAttrType(ctx), - "Resources": basetypes.ListType{ + "active_deployment": basetypes.ListType{ + ElemType: AppDeployment{}.ToAttrType(ctx), + }, + "app_status": basetypes.ListType{ + ElemType: ApplicationStatus{}.ToAttrType(ctx), + }, + "compute_status": basetypes.ListType{ + ElemType: ComputeStatus{}.ToAttrType(ctx), + }, + "create_time": types.StringType, + "creator": types.StringType, + "default_source_code_path": types.StringType, + "description": types.StringType, + "name": types.StringType, + "pending_deployment": basetypes.ListType{ + ElemType: AppDeployment{}.ToAttrType(ctx), + }, + "resources": basetypes.ListType{ ElemType: AppResource{}.ToAttrType(ctx), }, - "ServicePrincipalClientId": types.StringType, - "ServicePrincipalId": types.Int64Type, - "ServicePrincipalName": types.StringType, - "UpdateTime": types.StringType, - "Updater": types.StringType, - "Url": types.StringType, + "service_principal_client_id": types.StringType, + "service_principal_id": types.Int64Type, + "service_principal_name": types.StringType, + "update_time": types.StringType, + "updater": types.StringType, + "url": types.StringType, }, } } @@ -124,10 +132,10 @@ func (a AppAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type func (a AppAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -153,20 +161,20 @@ func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringRead(existing func (a AppAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(AppPermission{}), + "all_permissions": reflect.TypeOf(AppPermission{}), } } func (a AppAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: AppPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -204,22 +212,26 @@ func (newState *AppDeployment) SyncEffectiveFieldsDuringRead(existingState AppDe func (a AppDeployment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DeploymentArtifacts": reflect.TypeOf(AppDeploymentArtifacts{}), - "Status": reflect.TypeOf(AppDeploymentStatus{}), + "deployment_artifacts": reflect.TypeOf(AppDeploymentArtifacts{}), + "status": reflect.TypeOf(AppDeploymentStatus{}), } } func (a AppDeployment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "Creator": types.StringType, - "DeploymentArtifacts": AppDeploymentArtifacts{}.ToAttrType(ctx), - "DeploymentId": types.StringType, - "Mode": types.StringType, - "SourceCodePath": types.StringType, - "Status": AppDeploymentStatus{}.ToAttrType(ctx), - "UpdateTime": types.StringType, + "create_time": types.StringType, + "creator": types.StringType, + "deployment_artifacts": basetypes.ListType{ + ElemType: AppDeploymentArtifacts{}.ToAttrType(ctx), + }, + "deployment_id": types.StringType, + "mode": types.StringType, + "source_code_path": types.StringType, + "status": basetypes.ListType{ + ElemType: AppDeploymentStatus{}.ToAttrType(ctx), + }, + "update_time": types.StringType, }, } } @@ -243,7 +255,7 @@ func (a AppDeploymentArtifacts) GetComplexFieldTypes() map[string]reflect.Type { func (a AppDeploymentArtifacts) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "SourceCodePath": types.StringType, + "source_code_path": types.StringType, }, } } @@ -268,8 +280,8 @@ func (a AppDeploymentStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a AppDeploymentStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, - "State": types.StringType, + "message": types.StringType, + "state": types.StringType, }, } } @@ -290,18 +302,18 @@ func (newState *AppPermission) SyncEffectiveFieldsDuringRead(existingState AppPe func (a AppPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a AppPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -322,18 +334,18 @@ func (newState *AppPermissions) SyncEffectiveFieldsDuringRead(existingState AppP func (a AppPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AppAccessControlResponse{}), + "access_control_list": reflect.TypeOf(AppAccessControlResponse{}), } } func (a AppPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AppAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -357,8 +369,8 @@ func (a AppPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Typ func (a AppPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -377,17 +389,17 @@ func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingSta func (a AppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AppAccessControlRequest{}), + "access_control_list": reflect.TypeOf(AppAccessControlRequest{}), } } func (a AppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AppAccessControlRequest{}.ToAttrType(ctx), }, - "AppName": types.StringType, + "app_name": types.StringType, }, } } @@ -415,22 +427,30 @@ func (newState *AppResource) SyncEffectiveFieldsDuringRead(existingState AppReso func (a AppResource) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Job": reflect.TypeOf(AppResourceJob{}), - "Secret": reflect.TypeOf(AppResourceSecret{}), - "ServingEndpoint": reflect.TypeOf(AppResourceServingEndpoint{}), - "SqlWarehouse": reflect.TypeOf(AppResourceSqlWarehouse{}), + "job": reflect.TypeOf(AppResourceJob{}), + "secret": reflect.TypeOf(AppResourceSecret{}), + "serving_endpoint": reflect.TypeOf(AppResourceServingEndpoint{}), + "sql_warehouse": reflect.TypeOf(AppResourceSqlWarehouse{}), } } func (a AppResource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Job": AppResourceJob{}.ToAttrType(ctx), - "Name": types.StringType, - "Secret": AppResourceSecret{}.ToAttrType(ctx), - "ServingEndpoint": AppResourceServingEndpoint{}.ToAttrType(ctx), - "SqlWarehouse": AppResourceSqlWarehouse{}.ToAttrType(ctx), + "description": types.StringType, + "job": basetypes.ListType{ + ElemType: AppResourceJob{}.ToAttrType(ctx), + }, + "name": types.StringType, + "secret": basetypes.ListType{ + ElemType: AppResourceSecret{}.ToAttrType(ctx), + }, + "serving_endpoint": basetypes.ListType{ + ElemType: AppResourceServingEndpoint{}.ToAttrType(ctx), + }, + "sql_warehouse": basetypes.ListType{ + ElemType: AppResourceSqlWarehouse{}.ToAttrType(ctx), + }, }, } } @@ -456,8 +476,8 @@ func (a AppResourceJob) GetComplexFieldTypes() map[string]reflect.Type { func (a AppResourceJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Permission": types.StringType, + "id": types.StringType, + "permission": types.StringType, }, } } @@ -485,9 +505,9 @@ func (a AppResourceSecret) GetComplexFieldTypes() map[string]reflect.Type { func (a AppResourceSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Permission": types.StringType, - "Scope": types.StringType, + "key": types.StringType, + "permission": types.StringType, + "scope": types.StringType, }, } } @@ -513,8 +533,8 @@ func (a AppResourceServingEndpoint) GetComplexFieldTypes() map[string]reflect.Ty func (a AppResourceServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Permission": types.StringType, + "name": types.StringType, + "permission": types.StringType, }, } } @@ -540,8 +560,8 @@ func (a AppResourceSqlWarehouse) GetComplexFieldTypes() map[string]reflect.Type func (a AppResourceSqlWarehouse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Permission": types.StringType, + "id": types.StringType, + "permission": types.StringType, }, } } @@ -566,8 +586,8 @@ func (a ApplicationStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a ApplicationStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, - "State": types.StringType, + "message": types.StringType, + "state": types.StringType, }, } } @@ -592,8 +612,8 @@ func (a ComputeStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a ComputeStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, - "State": types.StringType, + "message": types.StringType, + "state": types.StringType, }, } } @@ -613,15 +633,17 @@ func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existi func (a CreateAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AppDeployment": reflect.TypeOf(AppDeployment{}), + "app_deployment": reflect.TypeOf(AppDeployment{}), } } func (a CreateAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppDeployment": AppDeployment{}.ToAttrType(ctx), - "AppName": types.StringType, + "app_deployment": basetypes.ListType{ + ElemType: AppDeployment{}.ToAttrType(ctx), + }, + "app_name": types.StringType, }, } } @@ -639,14 +661,16 @@ func (newState *CreateAppRequest) SyncEffectiveFieldsDuringRead(existingState Cr func (a CreateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "App": reflect.TypeOf(App{}), + "app": reflect.TypeOf(App{}), } } func (a CreateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "App": App{}.ToAttrType(ctx), + "app": basetypes.ListType{ + ElemType: App{}.ToAttrType(ctx), + }, }, } } @@ -670,7 +694,7 @@ func (a DeleteAppRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -696,8 +720,8 @@ func (a GetAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppName": types.StringType, - "DeploymentId": types.StringType, + "app_name": types.StringType, + "deployment_id": types.StringType, }, } } @@ -721,7 +745,7 @@ func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect func (a GetAppPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppName": types.StringType, + "app_name": types.StringType, }, } } @@ -739,14 +763,14 @@ func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(ex func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(AppPermissionsDescription{}), + "permission_levels": reflect.TypeOf(AppPermissionsDescription{}), } } func (a GetAppPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: AppPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -772,7 +796,7 @@ func (a GetAppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetAppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppName": types.StringType, + "app_name": types.StringType, }, } } @@ -796,7 +820,7 @@ func (a GetAppRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -825,9 +849,9 @@ func (a ListAppDeploymentsRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a ListAppDeploymentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppName": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "app_name": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -847,17 +871,17 @@ func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringRead(existi func (a ListAppDeploymentsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AppDeployments": reflect.TypeOf(AppDeployment{}), + "app_deployments": reflect.TypeOf(AppDeployment{}), } } func (a ListAppDeploymentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppDeployments": basetypes.ListType{ + "app_deployments": basetypes.ListType{ ElemType: AppDeployment{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -884,8 +908,8 @@ func (a ListAppsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -904,17 +928,17 @@ func (newState *ListAppsResponse) SyncEffectiveFieldsDuringRead(existingState Li func (a ListAppsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Apps": reflect.TypeOf(App{}), + "apps": reflect.TypeOf(App{}), } } func (a ListAppsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Apps": basetypes.ListType{ + "apps": basetypes.ListType{ ElemType: App{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -937,7 +961,7 @@ func (a StartAppRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a StartAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -960,7 +984,7 @@ func (a StopAppRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a StopAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -981,15 +1005,17 @@ func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringRead(existingState Up func (a UpdateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "App": reflect.TypeOf(App{}), + "app": reflect.TypeOf(App{}), } } func (a UpdateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "App": App{}.ToAttrType(ctx), - "Name": types.StringType, + "app": basetypes.ListType{ + ElemType: App{}.ToAttrType(ctx), + }, + "name": types.StringType, }, } } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 198f7ed81f..65186eff44 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -42,9 +42,9 @@ func (a ActionConfiguration) GetComplexFieldTypes() map[string]reflect.Type { func (a ActionConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActionConfigurationId": types.StringType, - "ActionType": types.StringType, - "Target": types.StringType, + "action_configuration_id": types.StringType, + "action_type": types.StringType, + "target": types.StringType, }, } } @@ -76,21 +76,21 @@ func (newState *AlertConfiguration) SyncEffectiveFieldsDuringRead(existingState func (a AlertConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ActionConfigurations": reflect.TypeOf(ActionConfiguration{}), + "action_configurations": reflect.TypeOf(ActionConfiguration{}), } } func (a AlertConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActionConfigurations": basetypes.ListType{ + "action_configurations": basetypes.ListType{ ElemType: ActionConfiguration{}.ToAttrType(ctx), }, - "AlertConfigurationId": types.StringType, - "QuantityThreshold": types.StringType, - "QuantityType": types.StringType, - "TimePeriod": types.StringType, - "TriggerType": types.StringType, + "alert_configuration_id": types.StringType, + "quantity_threshold": types.StringType, + "quantity_type": types.StringType, + "time_period": types.StringType, + "trigger_type": types.StringType, }, } } @@ -124,23 +124,25 @@ func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringRead(existingState func (a BudgetConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AlertConfigurations": reflect.TypeOf(AlertConfiguration{}), - "Filter": reflect.TypeOf(BudgetConfigurationFilter{}), + "alert_configurations": reflect.TypeOf(AlertConfiguration{}), + "filter": reflect.TypeOf(BudgetConfigurationFilter{}), } } func (a BudgetConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AlertConfigurations": basetypes.ListType{ + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ ElemType: AlertConfiguration{}.ToAttrType(ctx), }, - "BudgetConfigurationId": types.StringType, - "CreateTime": types.Int64Type, - "DisplayName": types.StringType, - "Filter": BudgetConfigurationFilter{}.ToAttrType(ctx), - "UpdateTime": types.Int64Type, + "budget_configuration_id": types.StringType, + "create_time": types.Int64Type, + "display_name": types.StringType, + "filter": basetypes.ListType{ + ElemType: BudgetConfigurationFilter{}.ToAttrType(ctx), + }, + "update_time": types.Int64Type, }, } } @@ -162,18 +164,20 @@ func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringRead(existin func (a BudgetConfigurationFilter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(BudgetConfigurationFilterTagClause{}), - "WorkspaceId": reflect.TypeOf(BudgetConfigurationFilterWorkspaceIdClause{}), + "tags": reflect.TypeOf(BudgetConfigurationFilterTagClause{}), + "workspace_id": reflect.TypeOf(BudgetConfigurationFilterWorkspaceIdClause{}), } } func (a BudgetConfigurationFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Tags": basetypes.ListType{ + "tags": basetypes.ListType{ ElemType: BudgetConfigurationFilterTagClause{}.ToAttrType(ctx), }, - "WorkspaceId": BudgetConfigurationFilterWorkspaceIdClause{}.ToAttrType(ctx), + "workspace_id": basetypes.ListType{ + ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.ToAttrType(ctx), + }, }, } } @@ -192,15 +196,15 @@ func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringRead(e func (a BudgetConfigurationFilterClause) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(types.StringType), + "values": reflect.TypeOf(types.StringType), } } func (a BudgetConfigurationFilterClause) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Operator": types.StringType, - "Values": basetypes.ListType{ + "operator": types.StringType, + "values": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -221,15 +225,17 @@ func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringRea func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Value": reflect.TypeOf(BudgetConfigurationFilterClause{}), + "value": reflect.TypeOf(BudgetConfigurationFilterClause{}), } } func (a BudgetConfigurationFilterTagClause) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": BudgetConfigurationFilterClause{}.ToAttrType(ctx), + "key": types.StringType, + "value": basetypes.ListType{ + ElemType: BudgetConfigurationFilterClause{}.ToAttrType(ctx), + }, }, } } @@ -248,15 +254,15 @@ func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsD func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(types.Int64Type), + "values": reflect.TypeOf(types.Int64Type), } } func (a BudgetConfigurationFilterWorkspaceIdClause) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Operator": types.StringType, - "Values": basetypes.ListType{ + "operator": types.StringType, + "values": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -286,8 +292,8 @@ func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]re func (a CreateBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardType": types.StringType, - "WorkspaceId": types.Int64Type, + "dashboard_type": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -310,7 +316,7 @@ func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]r func (a CreateBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -338,20 +344,22 @@ func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(e func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AlertConfigurations": reflect.TypeOf(CreateBudgetConfigurationBudgetAlertConfigurations{}), - "Filter": reflect.TypeOf(BudgetConfigurationFilter{}), + "alert_configurations": reflect.TypeOf(CreateBudgetConfigurationBudgetAlertConfigurations{}), + "filter": reflect.TypeOf(BudgetConfigurationFilter{}), } } func (a CreateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AlertConfigurations": basetypes.ListType{ + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "Filter": BudgetConfigurationFilter{}.ToAttrType(ctx), + "display_name": types.StringType, + "filter": basetypes.ListType{ + ElemType: BudgetConfigurationFilter{}.ToAttrType(ctx), + }, }, } } @@ -376,8 +384,8 @@ func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldType func (a CreateBudgetConfigurationBudgetActionConfigurations) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActionType": types.StringType, - "Target": types.StringType, + "action_type": types.StringType, + "target": types.StringType, }, } } @@ -407,20 +415,20 @@ func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiv func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ActionConfigurations": reflect.TypeOf(CreateBudgetConfigurationBudgetActionConfigurations{}), + "action_configurations": reflect.TypeOf(CreateBudgetConfigurationBudgetActionConfigurations{}), } } func (a CreateBudgetConfigurationBudgetAlertConfigurations) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActionConfigurations": basetypes.ListType{ + "action_configurations": basetypes.ListType{ ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.ToAttrType(ctx), }, - "QuantityThreshold": types.StringType, - "QuantityType": types.StringType, - "TimePeriod": types.StringType, - "TriggerType": types.StringType, + "quantity_threshold": types.StringType, + "quantity_type": types.StringType, + "time_period": types.StringType, + "trigger_type": types.StringType, }, } } @@ -438,14 +446,16 @@ func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead( func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Budget": reflect.TypeOf(CreateBudgetConfigurationBudget{}), + "budget": reflect.TypeOf(CreateBudgetConfigurationBudget{}), } } func (a CreateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Budget": CreateBudgetConfigurationBudget{}.ToAttrType(ctx), + "budget": basetypes.ListType{ + ElemType: CreateBudgetConfigurationBudget{}.ToAttrType(ctx), + }, }, } } @@ -463,14 +473,16 @@ func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Budget": reflect.TypeOf(BudgetConfiguration{}), + "budget": reflect.TypeOf(BudgetConfiguration{}), } } func (a CreateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Budget": BudgetConfiguration{}.ToAttrType(ctx), + "budget": basetypes.ListType{ + ElemType: BudgetConfiguration{}.ToAttrType(ctx), + }, }, } } @@ -555,22 +567,22 @@ func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringR func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "WorkspaceIdsFilter": reflect.TypeOf(types.Int64Type), + "workspace_ids_filter": reflect.TypeOf(types.Int64Type), } } func (a CreateLogDeliveryConfigurationParams) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConfigName": types.StringType, - "CredentialsId": types.StringType, - "DeliveryPathPrefix": types.StringType, - "DeliveryStartTime": types.StringType, - "LogType": types.StringType, - "OutputFormat": types.StringType, - "Status": types.StringType, - "StorageConfigurationId": types.StringType, - "WorkspaceIdsFilter": basetypes.ListType{ + "config_name": types.StringType, + "credentials_id": types.StringType, + "delivery_path_prefix": types.StringType, + "delivery_start_time": types.StringType, + "log_type": types.StringType, + "output_format": types.StringType, + "status": types.StringType, + "storage_configuration_id": types.StringType, + "workspace_ids_filter": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -596,7 +608,7 @@ func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes() map[string]refl func (a DeleteBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BudgetId": types.StringType, + "budget_id": types.StringType, }, } } @@ -647,9 +659,9 @@ func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndMonth": types.StringType, - "PersonalData": types.BoolType, - "StartMonth": types.StringType, + "end_month": types.StringType, + "personal_data": types.BoolType, + "start_month": types.StringType, }, } } @@ -671,7 +683,7 @@ func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Contents": types.ObjectType{}, + "contents": types.ObjectType{}, }, } } @@ -700,8 +712,8 @@ func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]refle func (a GetBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardType": types.StringType, - "WorkspaceId": types.Int64Type, + "dashboard_type": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -726,8 +738,8 @@ func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]refl func (a GetBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "DashboardUrl": types.StringType, + "dashboard_id": types.StringType, + "dashboard_url": types.StringType, }, } } @@ -751,7 +763,7 @@ func (a GetBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect func (a GetBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BudgetId": types.StringType, + "budget_id": types.StringType, }, } } @@ -768,14 +780,16 @@ func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(ex func (a GetBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Budget": reflect.TypeOf(BudgetConfiguration{}), + "budget": reflect.TypeOf(BudgetConfiguration{}), } } func (a GetBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Budget": BudgetConfiguration{}.ToAttrType(ctx), + "budget": basetypes.ListType{ + ElemType: BudgetConfiguration{}.ToAttrType(ctx), + }, }, } } @@ -799,7 +813,7 @@ func (a GetLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LogDeliveryConfigurationId": types.StringType, + "log_delivery_configuration_id": types.StringType, }, } } @@ -825,7 +839,7 @@ func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes() map[string]refle func (a ListBudgetConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageToken": types.StringType, + "page_token": types.StringType, }, } } @@ -845,17 +859,17 @@ func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringRead( func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Budgets": reflect.TypeOf(BudgetConfiguration{}), + "budgets": reflect.TypeOf(BudgetConfiguration{}), } } func (a ListBudgetConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Budgets": basetypes.ListType{ + "budgets": basetypes.ListType{ ElemType: BudgetConfiguration{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -883,9 +897,9 @@ func (a ListLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialsId": types.StringType, - "Status": types.StringType, - "StorageConfigurationId": types.StringType, + "credentials_id": types.StringType, + "status": types.StringType, + "storage_configuration_id": types.StringType, }, } } @@ -982,28 +996,30 @@ func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existing func (a LogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LogDeliveryStatus": reflect.TypeOf(LogDeliveryStatus{}), - "WorkspaceIdsFilter": reflect.TypeOf(types.Int64Type), + "log_delivery_status": reflect.TypeOf(LogDeliveryStatus{}), + "workspace_ids_filter": reflect.TypeOf(types.Int64Type), } } func (a LogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "ConfigId": types.StringType, - "ConfigName": types.StringType, - "CreationTime": types.Int64Type, - "CredentialsId": types.StringType, - "DeliveryPathPrefix": types.StringType, - "DeliveryStartTime": types.StringType, - "LogDeliveryStatus": LogDeliveryStatus{}.ToAttrType(ctx), - "LogType": types.StringType, - "OutputFormat": types.StringType, - "Status": types.StringType, - "StorageConfigurationId": types.StringType, - "UpdateTime": types.Int64Type, - "WorkspaceIdsFilter": basetypes.ListType{ + "account_id": types.StringType, + "config_id": types.StringType, + "config_name": types.StringType, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "delivery_path_prefix": types.StringType, + "delivery_start_time": types.StringType, + "log_delivery_status": basetypes.ListType{ + ElemType: LogDeliveryStatus{}.ToAttrType(ctx), + }, + "log_type": types.StringType, + "output_format": types.StringType, + "status": types.StringType, + "storage_configuration_id": types.StringType, + "update_time": types.Int64Type, + "workspace_ids_filter": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -1046,10 +1062,10 @@ func (a LogDeliveryStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a LogDeliveryStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LastAttemptTime": types.StringType, - "LastSuccessfulAttemptTime": types.StringType, - "Message": types.StringType, - "Status": types.StringType, + "last_attempt_time": types.StringType, + "last_successful_attempt_time": types.StringType, + "message": types.StringType, + "status": types.StringType, }, } } @@ -1098,21 +1114,23 @@ func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(e func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AlertConfigurations": reflect.TypeOf(AlertConfiguration{}), - "Filter": reflect.TypeOf(BudgetConfigurationFilter{}), + "alert_configurations": reflect.TypeOf(AlertConfiguration{}), + "filter": reflect.TypeOf(BudgetConfigurationFilter{}), } } func (a UpdateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AlertConfigurations": basetypes.ListType{ + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ ElemType: AlertConfiguration{}.ToAttrType(ctx), }, - "BudgetConfigurationId": types.StringType, - "DisplayName": types.StringType, - "Filter": BudgetConfigurationFilter{}.ToAttrType(ctx), + "budget_configuration_id": types.StringType, + "display_name": types.StringType, + "filter": basetypes.ListType{ + ElemType: BudgetConfigurationFilter{}.ToAttrType(ctx), + }, }, } } @@ -1133,15 +1151,17 @@ func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead( func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Budget": reflect.TypeOf(UpdateBudgetConfigurationBudget{}), + "budget": reflect.TypeOf(UpdateBudgetConfigurationBudget{}), } } func (a UpdateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Budget": UpdateBudgetConfigurationBudget{}.ToAttrType(ctx), - "BudgetId": types.StringType, + "budget": basetypes.ListType{ + ElemType: UpdateBudgetConfigurationBudget{}.ToAttrType(ctx), + }, + "budget_id": types.StringType, }, } } @@ -1159,14 +1179,16 @@ func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Budget": reflect.TypeOf(BudgetConfiguration{}), + "budget": reflect.TypeOf(BudgetConfiguration{}), } } func (a UpdateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Budget": BudgetConfiguration{}.ToAttrType(ctx), + "budget": basetypes.ListType{ + ElemType: BudgetConfiguration{}.ToAttrType(ctx), + }, }, } } @@ -1195,8 +1217,8 @@ func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes() map[ func (a UpdateLogDeliveryConfigurationStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LogDeliveryConfigurationId": types.StringType, - "Status": types.StringType, + "log_delivery_configuration_id": types.StringType, + "status": types.StringType, }, } } @@ -1213,14 +1235,16 @@ func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuring func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LogDeliveryConfiguration": reflect.TypeOf(CreateLogDeliveryConfigurationParams{}), + "log_delivery_configuration": reflect.TypeOf(CreateLogDeliveryConfigurationParams{}), } } func (a WrappedCreateLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LogDeliveryConfiguration": CreateLogDeliveryConfigurationParams{}.ToAttrType(ctx), + "log_delivery_configuration": basetypes.ListType{ + ElemType: CreateLogDeliveryConfigurationParams{}.ToAttrType(ctx), + }, }, } } @@ -1237,14 +1261,16 @@ func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(e func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LogDeliveryConfiguration": reflect.TypeOf(LogDeliveryConfiguration{}), + "log_delivery_configuration": reflect.TypeOf(LogDeliveryConfiguration{}), } } func (a WrappedLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LogDeliveryConfiguration": LogDeliveryConfiguration{}.ToAttrType(ctx), + "log_delivery_configuration": basetypes.ListType{ + ElemType: LogDeliveryConfiguration{}.ToAttrType(ctx), + }, }, } } @@ -1261,14 +1287,14 @@ func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringRead( func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LogDeliveryConfigurations": reflect.TypeOf(LogDeliveryConfiguration{}), + "log_delivery_configurations": reflect.TypeOf(LogDeliveryConfiguration{}), } } func (a WrappedLogDeliveryConfigurations) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LogDeliveryConfigurations": basetypes.ListType{ + "log_delivery_configurations": basetypes.ListType{ ElemType: LogDeliveryConfiguration{}.ToAttrType(ctx), }, }, diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index bab8cdbd86..c83e678656 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -31,14 +31,16 @@ func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringRead(existingS func (a AccountsCreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MetastoreInfo": reflect.TypeOf(CreateMetastore{}), + "metastore_info": reflect.TypeOf(CreateMetastore{}), } } func (a AccountsCreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreInfo": CreateMetastore{}.ToAttrType(ctx), + "metastore_info": basetypes.ListType{ + ElemType: CreateMetastore{}.ToAttrType(ctx), + }, }, } } @@ -59,16 +61,18 @@ func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringRead func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MetastoreAssignment": reflect.TypeOf(CreateMetastoreAssignment{}), + "metastore_assignment": reflect.TypeOf(CreateMetastoreAssignment{}), } } func (a AccountsCreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreAssignment": CreateMetastoreAssignment{}.ToAttrType(ctx), - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "metastore_assignment": basetypes.ListType{ + ElemType: CreateMetastoreAssignment{}.ToAttrType(ctx), + }, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -87,15 +91,17 @@ func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringRead(e func (a AccountsCreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CredentialInfo": reflect.TypeOf(CreateStorageCredential{}), + "credential_info": reflect.TypeOf(CreateStorageCredential{}), } } func (a AccountsCreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialInfo": CreateStorageCredential{}.ToAttrType(ctx), - "MetastoreId": types.StringType, + "credential_info": basetypes.ListType{ + ElemType: CreateStorageCredential{}.ToAttrType(ctx), + }, + "metastore_id": types.StringType, }, } } @@ -112,14 +118,16 @@ func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringRead(exist func (a AccountsMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MetastoreAssignment": reflect.TypeOf(MetastoreAssignment{}), + "metastore_assignment": reflect.TypeOf(MetastoreAssignment{}), } } func (a AccountsMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreAssignment": MetastoreAssignment{}.ToAttrType(ctx), + "metastore_assignment": basetypes.ListType{ + ElemType: MetastoreAssignment{}.ToAttrType(ctx), + }, }, } } @@ -136,14 +144,16 @@ func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringRead(existingSta func (a AccountsMetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MetastoreInfo": reflect.TypeOf(MetastoreInfo{}), + "metastore_info": reflect.TypeOf(MetastoreInfo{}), } } func (a AccountsMetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreInfo": MetastoreInfo{}.ToAttrType(ctx), + "metastore_info": basetypes.ListType{ + ElemType: MetastoreInfo{}.ToAttrType(ctx), + }, }, } } @@ -160,14 +170,16 @@ func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringRead(exi func (a AccountsStorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CredentialInfo": reflect.TypeOf(StorageCredentialInfo{}), + "credential_info": reflect.TypeOf(StorageCredentialInfo{}), } } func (a AccountsStorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialInfo": StorageCredentialInfo{}.ToAttrType(ctx), + "credential_info": basetypes.ListType{ + ElemType: StorageCredentialInfo{}.ToAttrType(ctx), + }, }, } } @@ -187,15 +199,17 @@ func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringRead(existingS func (a AccountsUpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MetastoreInfo": reflect.TypeOf(UpdateMetastore{}), + "metastore_info": reflect.TypeOf(UpdateMetastore{}), } } func (a AccountsUpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, - "MetastoreInfo": UpdateMetastore{}.ToAttrType(ctx), + "metastore_id": types.StringType, + "metastore_info": basetypes.ListType{ + ElemType: UpdateMetastore{}.ToAttrType(ctx), + }, }, } } @@ -216,16 +230,18 @@ func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MetastoreAssignment": reflect.TypeOf(UpdateMetastoreAssignment{}), + "metastore_assignment": reflect.TypeOf(UpdateMetastoreAssignment{}), } } func (a AccountsUpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreAssignment": UpdateMetastoreAssignment{}.ToAttrType(ctx), - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "metastore_assignment": basetypes.ListType{ + ElemType: UpdateMetastoreAssignment{}.ToAttrType(ctx), + }, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -246,16 +262,18 @@ func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringRead(e func (a AccountsUpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CredentialInfo": reflect.TypeOf(UpdateStorageCredential{}), + "credential_info": reflect.TypeOf(UpdateStorageCredential{}), } } func (a AccountsUpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialInfo": UpdateStorageCredential{}.ToAttrType(ctx), - "MetastoreId": types.StringType, - "StorageCredentialName": types.StringType, + "credential_info": basetypes.ListType{ + ElemType: UpdateStorageCredential{}.ToAttrType(ctx), + }, + "metastore_id": types.StringType, + "storage_credential_name": types.StringType, }, } } @@ -279,19 +297,19 @@ func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringRead(existingSta func (a ArtifactAllowlistInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ArtifactMatchers": reflect.TypeOf(ArtifactMatcher{}), + "artifact_matchers": reflect.TypeOf(ArtifactMatcher{}), } } func (a ArtifactAllowlistInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactMatchers": basetypes.ListType{ + "artifact_matchers": basetypes.ListType{ ElemType: ArtifactMatcher{}.ToAttrType(ctx), }, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "MetastoreId": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "metastore_id": types.StringType, }, } } @@ -316,8 +334,8 @@ func (a ArtifactMatcher) GetComplexFieldTypes() map[string]reflect.Type { func (a ArtifactMatcher) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Artifact": types.StringType, - "MatchType": types.StringType, + "artifact": types.StringType, + "match_type": types.StringType, }, } } @@ -369,10 +387,10 @@ func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessKeyId": types.StringType, - "AccessPoint": types.StringType, - "SecretAccessKey": types.StringType, - "SessionToken": types.StringType, + "access_key_id": types.StringType, + "access_point": types.StringType, + "secret_access_key": types.StringType, + "session_token": types.StringType, }, } } @@ -403,9 +421,9 @@ func (a AwsIamRole) GetComplexFieldTypes() map[string]reflect.Type { func (a AwsIamRole) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExternalId": types.StringType, - "RoleArn": types.StringType, - "UnityCatalogIamArn": types.StringType, + "external_id": types.StringType, + "role_arn": types.StringType, + "unity_catalog_iam_arn": types.StringType, }, } } @@ -428,7 +446,7 @@ func (a AwsIamRoleRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a AwsIamRoleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RoleArn": types.StringType, + "role_arn": types.StringType, }, } } @@ -457,9 +475,9 @@ func (a AwsIamRoleResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a AwsIamRoleResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExternalId": types.StringType, - "RoleArn": types.StringType, - "UnityCatalogIamArn": types.StringType, + "external_id": types.StringType, + "role_arn": types.StringType, + "unity_catalog_iam_arn": types.StringType, }, } } @@ -486,7 +504,7 @@ func (a AzureActiveDirectoryToken) GetComplexFieldTypes() map[string]reflect.Typ func (a AzureActiveDirectoryToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AadToken": types.StringType, + "aad_token": types.StringType, }, } } @@ -524,9 +542,9 @@ func (a AzureManagedIdentity) GetComplexFieldTypes() map[string]reflect.Type { func (a AzureManagedIdentity) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessConnectorId": types.StringType, - "CredentialId": types.StringType, - "ManagedIdentityId": types.StringType, + "access_connector_id": types.StringType, + "credential_id": types.StringType, + "managed_identity_id": types.StringType, }, } } @@ -558,8 +576,8 @@ func (a AzureManagedIdentityRequest) GetComplexFieldTypes() map[string]reflect.T func (a AzureManagedIdentityRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessConnectorId": types.StringType, - "ManagedIdentityId": types.StringType, + "access_connector_id": types.StringType, + "managed_identity_id": types.StringType, }, } } @@ -593,9 +611,9 @@ func (a AzureManagedIdentityResponse) GetComplexFieldTypes() map[string]reflect. func (a AzureManagedIdentityResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessConnectorId": types.StringType, - "CredentialId": types.StringType, - "ManagedIdentityId": types.StringType, + "access_connector_id": types.StringType, + "credential_id": types.StringType, + "managed_identity_id": types.StringType, }, } } @@ -625,9 +643,9 @@ func (a AzureServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { func (a AzureServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplicationId": types.StringType, - "ClientSecret": types.StringType, - "DirectoryId": types.StringType, + "application_id": types.StringType, + "client_secret": types.StringType, + "directory_id": types.StringType, }, } } @@ -652,7 +670,7 @@ func (a AzureUserDelegationSas) GetComplexFieldTypes() map[string]reflect.Type { func (a AzureUserDelegationSas) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "SasToken": types.StringType, + "sas_token": types.StringType, }, } } @@ -678,8 +696,8 @@ func (a CancelRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a CancelRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RefreshId": types.StringType, - "TableName": types.StringType, + "refresh_id": types.StringType, + "table_name": types.StringType, }, } } @@ -769,44 +787,48 @@ func (newState *CatalogInfo) SyncEffectiveFieldsDuringRead(existingState Catalog func (a CatalogInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "Options": reflect.TypeOf(types.StringType), - "Properties": reflect.TypeOf(types.StringType), - "ProvisioningInfo": reflect.TypeOf(ProvisioningInfo{}), + "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), + "options": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), + "provisioning_info": reflect.TypeOf(ProvisioningInfo{}), } } func (a CatalogInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BrowseOnly": types.BoolType, - "CatalogType": types.StringType, - "Comment": types.StringType, - "ConnectionName": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "EffectivePredictiveOptimizationFlag": EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), - "EnablePredictiveOptimization": types.StringType, - "FullName": types.StringType, - "IsolationMode": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Options": basetypes.MapType{ + "browse_only": types.BoolType, + "catalog_type": types.StringType, + "comment": types.StringType, + "connection_name": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "effective_predictive_optimization_flag": basetypes.ListType{ + ElemType: EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + }, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ ElemType: types.StringType, }, - "Owner": types.StringType, - "Properties": basetypes.MapType{ + "owner": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "ProviderName": types.StringType, - "ProvisioningInfo": ProvisioningInfo{}.ToAttrType(ctx), - "SecurableKind": types.StringType, - "SecurableType": types.StringType, - "ShareName": types.StringType, - "StorageLocation": types.StringType, - "StorageRoot": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "provider_name": types.StringType, + "provisioning_info": basetypes.ListType{ + ElemType: ProvisioningInfo{}.ToAttrType(ctx), + }, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "share_name": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -833,9 +855,9 @@ func (a CloudflareApiToken) GetComplexFieldTypes() map[string]reflect.Type { func (a CloudflareApiToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessKeyId": types.StringType, - "AccountId": types.StringType, - "SecretAccessKey": types.StringType, + "access_key_id": types.StringType, + "account_id": types.StringType, + "secret_access_key": types.StringType, }, } } @@ -875,25 +897,27 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnIn func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Mask": reflect.TypeOf(ColumnMask{}), + "mask": reflect.TypeOf(ColumnMask{}), } } func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Mask": ColumnMask{}.ToAttrType(ctx), - "Name": types.StringType, - "Nullable": types.BoolType, - "PartitionIndex": types.Int64Type, - "Position": types.Int64Type, - "TypeIntervalType": types.StringType, - "TypeJson": types.StringType, - "TypeName": types.StringType, - "TypePrecision": types.Int64Type, - "TypeScale": types.Int64Type, - "TypeText": types.StringType, + "comment": types.StringType, + "mask": basetypes.ListType{ + ElemType: ColumnMask{}.ToAttrType(ctx), + }, + "name": types.StringType, + "nullable": types.BoolType, + "partition_index": types.Int64Type, + "position": types.Int64Type, + "type_interval_type": types.StringType, + "type_json": types.StringType, + "type_name": types.StringType, + "type_precision": types.Int64Type, + "type_scale": types.Int64Type, + "type_text": types.StringType, }, } } @@ -916,15 +940,15 @@ func (newState *ColumnMask) SyncEffectiveFieldsDuringRead(existingState ColumnMa func (a ColumnMask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "UsingColumnNames": reflect.TypeOf(types.StringType), + "using_column_names": reflect.TypeOf(types.StringType), } } func (a ColumnMask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FunctionName": types.StringType, - "UsingColumnNames": basetypes.ListType{ + "function_name": types.StringType, + "using_column_names": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -981,38 +1005,40 @@ func (newState *ConnectionInfo) SyncEffectiveFieldsDuringRead(existingState Conn func (a ConnectionInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(types.StringType), - "Properties": reflect.TypeOf(types.StringType), - "ProvisioningInfo": reflect.TypeOf(ProvisioningInfo{}), + "options": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), + "provisioning_info": reflect.TypeOf(ProvisioningInfo{}), } } func (a ConnectionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "ConnectionId": types.StringType, - "ConnectionType": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "CredentialType": types.StringType, - "FullName": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Options": basetypes.MapType{ + "comment": types.StringType, + "connection_id": types.StringType, + "connection_type": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "credential_type": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ ElemType: types.StringType, }, - "Owner": types.StringType, - "Properties": basetypes.MapType{ + "owner": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "ProvisioningInfo": ProvisioningInfo{}.ToAttrType(ctx), - "ReadOnly": types.BoolType, - "SecurableKind": types.StringType, - "SecurableType": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "Url": types.StringType, + "provisioning_info": basetypes.ListType{ + ElemType: ProvisioningInfo{}.ToAttrType(ctx), + }, + "read_only": types.BoolType, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "url": types.StringType, }, } } @@ -1039,16 +1065,18 @@ func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringRead(existingSt func (a ContinuousUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InitialPipelineSyncProgress": reflect.TypeOf(PipelineProgress{}), + "initial_pipeline_sync_progress": reflect.TypeOf(PipelineProgress{}), } } func (a ContinuousUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InitialPipelineSyncProgress": PipelineProgress{}.ToAttrType(ctx), - "LastProcessedCommitVersion": types.Int64Type, - "Timestamp": types.StringType, + "initial_pipeline_sync_progress": basetypes.ListType{ + ElemType: PipelineProgress{}.ToAttrType(ctx), + }, + "last_processed_commit_version": types.Int64Type, + "timestamp": types.StringType, }, } } @@ -1083,26 +1111,26 @@ func (newState *CreateCatalog) SyncEffectiveFieldsDuringRead(existingState Creat func (a CreateCatalog) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(types.StringType), - "Properties": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), } } func (a CreateCatalog) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "ConnectionName": types.StringType, - "Name": types.StringType, - "Options": basetypes.MapType{ + "comment": types.StringType, + "connection_name": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ ElemType: types.StringType, }, - "Properties": basetypes.MapType{ + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "ProviderName": types.StringType, - "ShareName": types.StringType, - "StorageRoot": types.StringType, + "provider_name": types.StringType, + "share_name": types.StringType, + "storage_root": types.StringType, }, } } @@ -1131,24 +1159,24 @@ func (newState *CreateConnection) SyncEffectiveFieldsDuringRead(existingState Cr func (a CreateConnection) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(types.StringType), - "Properties": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), } } func (a CreateConnection) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "ConnectionType": types.StringType, - "Name": types.StringType, - "Options": basetypes.MapType{ + "comment": types.StringType, + "connection_type": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ ElemType: types.StringType, }, - "Properties": basetypes.MapType{ + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "ReadOnly": types.BoolType, + "read_only": types.BoolType, }, } } @@ -1186,25 +1214,33 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingS func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRole{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), - "GcpServiceAccountKey": reflect.TypeOf(GcpServiceAccountKey{}), + "aws_iam_role": reflect.TypeOf(AwsIamRole{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), + "gcp_service_account_key": reflect.TypeOf(GcpServiceAccountKey{}), } } func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "Comment": types.StringType, - "GcpServiceAccountKey": GcpServiceAccountKey{}.ToAttrType(ctx), - "Name": types.StringType, - "Purpose": types.StringType, - "ReadOnly": types.BoolType, - "SkipValidation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "gcp_service_account_key": basetypes.ListType{ + ElemType: GcpServiceAccountKey{}.ToAttrType(ctx), + }, + "name": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -1241,22 +1277,24 @@ func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringRead(existingSt func (a CreateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } func (a CreateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessPoint": types.StringType, - "Comment": types.StringType, - "CredentialName": types.StringType, - "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), - "Fallback": types.BoolType, - "Name": types.StringType, - "ReadOnly": types.BoolType, - "SkipValidation": types.BoolType, - "Url": types.StringType, + "access_point": types.StringType, + "comment": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.ToAttrType(ctx), + }, + "fallback": types.BoolType, + "name": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, + "url": types.StringType, }, } } @@ -1318,36 +1356,42 @@ func (newState *CreateFunction) SyncEffectiveFieldsDuringRead(existingState Crea func (a CreateFunction) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InputParams": reflect.TypeOf(FunctionParameterInfos{}), - "ReturnParams": reflect.TypeOf(FunctionParameterInfos{}), - "RoutineDependencies": reflect.TypeOf(DependencyList{}), + "input_params": reflect.TypeOf(FunctionParameterInfos{}), + "return_params": reflect.TypeOf(FunctionParameterInfos{}), + "routine_dependencies": reflect.TypeOf(DependencyList{}), } } func (a CreateFunction) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Comment": types.StringType, - "DataType": types.StringType, - "ExternalLanguage": types.StringType, - "ExternalName": types.StringType, - "FullDataType": types.StringType, - "InputParams": FunctionParameterInfos{}.ToAttrType(ctx), - "IsDeterministic": types.BoolType, - "IsNullCall": types.BoolType, - "Name": types.StringType, - "ParameterStyle": types.StringType, - "Properties": types.StringType, - "ReturnParams": FunctionParameterInfos{}.ToAttrType(ctx), - "RoutineBody": types.StringType, - "RoutineDefinition": types.StringType, - "RoutineDependencies": DependencyList{}.ToAttrType(ctx), - "SchemaName": types.StringType, - "SecurityType": types.StringType, - "SpecificName": types.StringType, - "SqlDataAccess": types.StringType, - "SqlPath": types.StringType, + "catalog_name": types.StringType, + "comment": types.StringType, + "data_type": types.StringType, + "external_language": types.StringType, + "external_name": types.StringType, + "full_data_type": types.StringType, + "input_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + }, + "is_deterministic": types.BoolType, + "is_null_call": types.BoolType, + "name": types.StringType, + "parameter_style": types.StringType, + "properties": types.StringType, + "return_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + }, + "routine_body": types.StringType, + "routine_definition": types.StringType, + "routine_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.ToAttrType(ctx), + }, + "schema_name": types.StringType, + "security_type": types.StringType, + "specific_name": types.StringType, + "sql_data_access": types.StringType, + "sql_path": types.StringType, }, } } @@ -1365,14 +1409,16 @@ func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringRead(existingSta func (a CreateFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FunctionInfo": reflect.TypeOf(CreateFunction{}), + "function_info": reflect.TypeOf(CreateFunction{}), } } func (a CreateFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FunctionInfo": CreateFunction{}.ToAttrType(ctx), + "function_info": basetypes.ListType{ + ElemType: CreateFunction{}.ToAttrType(ctx), + }, }, } } @@ -1402,9 +1448,9 @@ func (a CreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Region": types.StringType, - "StorageRoot": types.StringType, + "name": types.StringType, + "region": types.StringType, + "storage_root": types.StringType, }, } } @@ -1433,9 +1479,9 @@ func (a CreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Typ func (a CreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DefaultCatalogName": types.StringType, - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "default_catalog_name": types.StringType, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -1489,38 +1535,50 @@ func (newState *CreateMonitor) SyncEffectiveFieldsDuringRead(existingState Creat func (a CreateMonitor) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomMetrics": reflect.TypeOf(MonitorMetric{}), - "DataClassificationConfig": reflect.TypeOf(MonitorDataClassificationConfig{}), - "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), - "Notifications": reflect.TypeOf(MonitorNotifications{}), - "Schedule": reflect.TypeOf(MonitorCronSchedule{}), - "SlicingExprs": reflect.TypeOf(types.StringType), - "Snapshot": reflect.TypeOf(MonitorSnapshot{}), - "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), + "custom_metrics": reflect.TypeOf(MonitorMetric{}), + "data_classification_config": reflect.TypeOf(MonitorDataClassificationConfig{}), + "inference_log": reflect.TypeOf(MonitorInferenceLog{}), + "notifications": reflect.TypeOf(MonitorNotifications{}), + "schedule": reflect.TypeOf(MonitorCronSchedule{}), + "slicing_exprs": reflect.TypeOf(types.StringType), + "snapshot": reflect.TypeOf(MonitorSnapshot{}), + "time_series": reflect.TypeOf(MonitorTimeSeries{}), } } func (a CreateMonitor) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AssetsDir": types.StringType, - "BaselineTableName": types.StringType, - "CustomMetrics": basetypes.ListType{ + "assets_dir": types.StringType, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ ElemType: MonitorMetric{}.ToAttrType(ctx), }, - "DataClassificationConfig": MonitorDataClassificationConfig{}.ToAttrType(ctx), - "InferenceLog": MonitorInferenceLog{}.ToAttrType(ctx), - "Notifications": MonitorNotifications{}.ToAttrType(ctx), - "OutputSchemaName": types.StringType, - "Schedule": MonitorCronSchedule{}.ToAttrType(ctx), - "SkipBuiltinDashboard": types.BoolType, - "SlicingExprs": basetypes.ListType{ + "data_classification_config": basetypes.ListType{ + ElemType: MonitorDataClassificationConfig{}.ToAttrType(ctx), + }, + "inference_log": basetypes.ListType{ + ElemType: MonitorInferenceLog{}.ToAttrType(ctx), + }, + "notifications": basetypes.ListType{ + ElemType: MonitorNotifications{}.ToAttrType(ctx), + }, + "output_schema_name": types.StringType, + "schedule": basetypes.ListType{ + ElemType: MonitorCronSchedule{}.ToAttrType(ctx), + }, + "skip_builtin_dashboard": types.BoolType, + "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, - "Snapshot": MonitorSnapshot{}.ToAttrType(ctx), - "TableName": types.StringType, - "TimeSeries": MonitorTimeSeries{}.ToAttrType(ctx), - "WarehouseId": types.StringType, + "snapshot": basetypes.ListType{ + ElemType: MonitorSnapshot{}.ToAttrType(ctx), + }, + "table_name": types.StringType, + "time_series": basetypes.ListType{ + ElemType: MonitorTimeSeries{}.ToAttrType(ctx), + }, + "warehouse_id": types.StringType, }, } } @@ -1539,14 +1597,16 @@ func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringRead(existing func (a CreateOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Table": reflect.TypeOf(OnlineTable{}), + "table": reflect.TypeOf(OnlineTable{}), } } func (a CreateOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Table": OnlineTable{}.ToAttrType(ctx), + "table": basetypes.ListType{ + ElemType: OnlineTable{}.ToAttrType(ctx), + }, }, } } @@ -1578,11 +1638,11 @@ func (a CreateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect. func (a CreateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Comment": types.StringType, - "Name": types.StringType, - "SchemaName": types.StringType, - "StorageLocation": types.StringType, + "catalog_name": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "schema_name": types.StringType, + "storage_location": types.StringType, }, } } @@ -1627,20 +1687,20 @@ func (newState *CreateSchema) SyncEffectiveFieldsDuringRead(existingState Create func (a CreateSchema) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), } } func (a CreateSchema) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Comment": types.StringType, - "Name": types.StringType, - "Properties": basetypes.MapType{ + "catalog_name": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "StorageRoot": types.StringType, + "storage_root": types.StringType, }, } } @@ -1675,26 +1735,36 @@ func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringRead(existingS func (a CreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRoleRequest{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityRequest{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), - "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), - "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), + "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityRequest{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), + "cloudflare_api_token": reflect.TypeOf(CloudflareApiToken{}), + "databricks_gcp_service_account": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), } } func (a CreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRoleRequest{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentityRequest{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), - "Comment": types.StringType, - "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), - "Name": types.StringType, - "ReadOnly": types.BoolType, - "SkipValidation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleRequest{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityRequest{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + }, + "name": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -1716,15 +1786,17 @@ func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringRead(existingSta func (a CreateTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Constraint": reflect.TypeOf(TableConstraint{}), + "constraint": reflect.TypeOf(TableConstraint{}), } } func (a CreateTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Constraint": TableConstraint{}.ToAttrType(ctx), - "FullNameArg": types.StringType, + "constraint": basetypes.ListType{ + ElemType: TableConstraint{}.ToAttrType(ctx), + }, + "full_name_arg": types.StringType, }, } } @@ -1757,12 +1829,12 @@ func (a CreateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Ty func (a CreateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Comment": types.StringType, - "Name": types.StringType, - "SchemaName": types.StringType, - "StorageLocation": types.StringType, - "VolumeType": types.StringType, + "catalog_name": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "schema_name": types.StringType, + "storage_location": types.StringType, + "volume_type": types.StringType, }, } } @@ -1816,32 +1888,38 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState Cred func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRole{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "aws_iam_role": reflect.TypeOf(AwsIamRole{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), } } func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "FullName": types.StringType, - "Id": types.StringType, - "IsolationMode": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "Purpose": types.StringType, - "ReadOnly": types.BoolType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "UsedForManagedStorage": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "full_name": types.StringType, + "id": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "used_for_managed_storage": types.BoolType, }, } } @@ -1866,8 +1944,8 @@ func (a CredentialValidationResult) GetComplexFieldTypes() map[string]reflect.Ty func (a CredentialValidationResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, - "Result": types.StringType, + "message": types.StringType, + "result": types.StringType, }, } } @@ -1886,14 +1964,14 @@ func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringRead(existing func (a CurrentWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Workspaces": reflect.TypeOf(types.Int64Type), + "workspaces": reflect.TypeOf(types.Int64Type), } } func (a CurrentWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Workspaces": basetypes.ListType{ + "workspaces": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -1940,8 +2018,8 @@ func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes() map[string]r func (a DatabricksGcpServiceAccountResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.StringType, - "Email": types.StringType, + "credential_id": types.StringType, + "email": types.StringType, }, } } @@ -1967,8 +2045,8 @@ func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[stri func (a DeleteAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -1994,8 +2072,8 @@ func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect func (a DeleteAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "MetastoreId": types.StringType, + "force": types.BoolType, + "metastore_id": types.StringType, }, } } @@ -2024,9 +2102,9 @@ func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes() map[string func (a DeleteAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "MetastoreId": types.StringType, - "StorageCredentialName": types.StringType, + "force": types.BoolType, + "metastore_id": types.StringType, + "storage_credential_name": types.StringType, }, } } @@ -2052,8 +2130,8 @@ func (a DeleteAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alias": types.StringType, - "FullName": types.StringType, + "alias": types.StringType, + "full_name": types.StringType, }, } } @@ -2098,8 +2176,8 @@ func (a DeleteCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "Name": types.StringType, + "force": types.BoolType, + "name": types.StringType, }, } } @@ -2123,7 +2201,7 @@ func (a DeleteConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -2151,8 +2229,8 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "NameArg": types.StringType, + "force": types.BoolType, + "name_arg": types.StringType, }, } } @@ -2197,8 +2275,8 @@ func (a DeleteExternalLocationRequest) GetComplexFieldTypes() map[string]reflect func (a DeleteExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "Name": types.StringType, + "force": types.BoolType, + "name": types.StringType, }, } } @@ -2225,8 +2303,8 @@ func (a DeleteFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "Name": types.StringType, + "force": types.BoolType, + "name": types.StringType, }, } } @@ -2252,8 +2330,8 @@ func (a DeleteMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "Id": types.StringType, + "force": types.BoolType, + "id": types.StringType, }, } } @@ -2279,8 +2357,8 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "Version": types.Int64Type, + "full_name": types.StringType, + "version": types.Int64Type, }, } } @@ -2304,7 +2382,7 @@ func (a DeleteOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -2328,7 +2406,7 @@ func (a DeleteQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.T func (a DeleteQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableName": types.StringType, + "table_name": types.StringType, }, } } @@ -2352,7 +2430,7 @@ func (a DeleteRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect. func (a DeleteRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, + "full_name": types.StringType, }, } } @@ -2397,8 +2475,8 @@ func (a DeleteSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "FullName": types.StringType, + "force": types.BoolType, + "full_name": types.StringType, }, } } @@ -2425,8 +2503,8 @@ func (a DeleteStorageCredentialRequest) GetComplexFieldTypes() map[string]reflec func (a DeleteStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Force": types.BoolType, - "Name": types.StringType, + "force": types.BoolType, + "name": types.StringType, }, } } @@ -2456,9 +2534,9 @@ func (a DeleteTableConstraintRequest) GetComplexFieldTypes() map[string]reflect. func (a DeleteTableConstraintRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cascade": types.BoolType, - "ConstraintName": types.StringType, - "FullName": types.StringType, + "cascade": types.BoolType, + "constraint_name": types.StringType, + "full_name": types.StringType, }, } } @@ -2482,7 +2560,7 @@ func (a DeleteTableRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, + "full_name": types.StringType, }, } } @@ -2506,7 +2584,7 @@ func (a DeleteVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -2527,14 +2605,14 @@ func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringRead(exi func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DeltaRuntimeProperties": reflect.TypeOf(types.StringType), + "delta_runtime_properties": reflect.TypeOf(types.StringType), } } func (a DeltaRuntimePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DeltaRuntimeProperties": basetypes.MapType{ + "delta_runtime_properties": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -2558,16 +2636,20 @@ func (newState *Dependency) SyncEffectiveFieldsDuringRead(existingState Dependen func (a Dependency) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Function": reflect.TypeOf(FunctionDependency{}), - "Table": reflect.TypeOf(TableDependency{}), + "function": reflect.TypeOf(FunctionDependency{}), + "table": reflect.TypeOf(TableDependency{}), } } func (a Dependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Function": FunctionDependency{}.ToAttrType(ctx), - "Table": TableDependency{}.ToAttrType(ctx), + "function": basetypes.ListType{ + ElemType: FunctionDependency{}.ToAttrType(ctx), + }, + "table": basetypes.ListType{ + ElemType: TableDependency{}.ToAttrType(ctx), + }, }, } } @@ -2586,14 +2668,14 @@ func (newState *DependencyList) SyncEffectiveFieldsDuringRead(existingState Depe func (a DependencyList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dependencies": reflect.TypeOf(Dependency{}), + "dependencies": reflect.TypeOf(Dependency{}), } } func (a DependencyList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Dependencies": basetypes.ListType{ + "dependencies": basetypes.ListType{ ElemType: Dependency{}.ToAttrType(ctx), }, }, @@ -2621,8 +2703,8 @@ func (a DisableRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DisableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, - "SchemaName": types.StringType, + "metastore_id": types.StringType, + "schema_name": types.StringType, }, } } @@ -2660,14 +2742,14 @@ func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringRead(existing func (a EffectivePermissionsList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrivilegeAssignments": reflect.TypeOf(EffectivePrivilegeAssignment{}), + "privilege_assignments": reflect.TypeOf(EffectivePrivilegeAssignment{}), } } func (a EffectivePermissionsList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrivilegeAssignments": basetypes.ListType{ + "privilege_assignments": basetypes.ListType{ ElemType: EffectivePrivilegeAssignment{}.ToAttrType(ctx), }, }, @@ -2699,9 +2781,9 @@ func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes() map[string]r func (a EffectivePredictiveOptimizationFlag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InheritedFromName": types.StringType, - "InheritedFromType": types.StringType, - "Value": types.StringType, + "inherited_from_name": types.StringType, + "inherited_from_type": types.StringType, + "value": types.StringType, }, } } @@ -2732,9 +2814,9 @@ func (a EffectivePrivilege) GetComplexFieldTypes() map[string]reflect.Type { func (a EffectivePrivilege) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InheritedFromName": types.StringType, - "InheritedFromType": types.StringType, - "Privilege": types.StringType, + "inherited_from_name": types.StringType, + "inherited_from_type": types.StringType, + "privilege": types.StringType, }, } } @@ -2755,15 +2837,15 @@ func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringRead(exis func (a EffectivePrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Privileges": reflect.TypeOf(EffectivePrivilege{}), + "privileges": reflect.TypeOf(EffectivePrivilege{}), } } func (a EffectivePrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Principal": types.StringType, - "Privileges": basetypes.ListType{ + "principal": types.StringType, + "privileges": basetypes.ListType{ ElemType: EffectivePrivilege{}.ToAttrType(ctx), }, }, @@ -2791,8 +2873,8 @@ func (a EnableRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a EnableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, - "SchemaName": types.StringType, + "metastore_id": types.StringType, + "schema_name": types.StringType, }, } } @@ -2830,14 +2912,16 @@ func (newState *EncryptionDetails) SyncEffectiveFieldsDuringRead(existingState E func (a EncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SseEncryptionDetails": reflect.TypeOf(SseEncryptionDetails{}), + "sse_encryption_details": reflect.TypeOf(SseEncryptionDetails{}), } } func (a EncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "SseEncryptionDetails": SseEncryptionDetails{}.ToAttrType(ctx), + "sse_encryption_details": basetypes.ListType{ + ElemType: SseEncryptionDetails{}.ToAttrType(ctx), + }, }, } } @@ -2861,7 +2945,7 @@ func (a ExistsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ExistsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, + "full_name": types.StringType, }, } } @@ -2916,30 +3000,32 @@ func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringRead(existingStat func (a ExternalLocationInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } func (a ExternalLocationInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessPoint": types.StringType, - "BrowseOnly": types.BoolType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "CredentialId": types.StringType, - "CredentialName": types.StringType, - "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), - "Fallback": types.BoolType, - "IsolationMode": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "ReadOnly": types.BoolType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "Url": types.StringType, + "access_point": types.StringType, + "browse_only": types.BoolType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "credential_id": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.ToAttrType(ctx), + }, + "fallback": types.BoolType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "url": types.StringType, }, } } @@ -2971,8 +3057,8 @@ func (a FailedStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a FailedStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LastProcessedCommitVersion": types.Int64Type, - "Timestamp": types.StringType, + "last_processed_commit_version": types.Int64Type, + "timestamp": types.StringType, }, } } @@ -2996,22 +3082,22 @@ func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringRead(existingStat func (a ForeignKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ChildColumns": reflect.TypeOf(types.StringType), - "ParentColumns": reflect.TypeOf(types.StringType), + "child_columns": reflect.TypeOf(types.StringType), + "parent_columns": reflect.TypeOf(types.StringType), } } func (a ForeignKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ChildColumns": basetypes.ListType{ + "child_columns": basetypes.ListType{ ElemType: types.StringType, }, - "Name": types.StringType, - "ParentColumns": basetypes.ListType{ + "name": types.StringType, + "parent_columns": basetypes.ListType{ ElemType: types.StringType, }, - "ParentTable": types.StringType, + "parent_table": types.StringType, }, } } @@ -3036,7 +3122,7 @@ func (a FunctionDependency) GetComplexFieldTypes() map[string]reflect.Type { func (a FunctionDependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FunctionFullName": types.StringType, + "function_full_name": types.StringType, }, } } @@ -3119,45 +3205,51 @@ func (newState *FunctionInfo) SyncEffectiveFieldsDuringRead(existingState Functi func (a FunctionInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InputParams": reflect.TypeOf(FunctionParameterInfos{}), - "ReturnParams": reflect.TypeOf(FunctionParameterInfos{}), - "RoutineDependencies": reflect.TypeOf(DependencyList{}), + "input_params": reflect.TypeOf(FunctionParameterInfos{}), + "return_params": reflect.TypeOf(FunctionParameterInfos{}), + "routine_dependencies": reflect.TypeOf(DependencyList{}), } } func (a FunctionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BrowseOnly": types.BoolType, - "CatalogName": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DataType": types.StringType, - "ExternalLanguage": types.StringType, - "ExternalName": types.StringType, - "FullDataType": types.StringType, - "FullName": types.StringType, - "FunctionId": types.StringType, - "InputParams": FunctionParameterInfos{}.ToAttrType(ctx), - "IsDeterministic": types.BoolType, - "IsNullCall": types.BoolType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "ParameterStyle": types.StringType, - "Properties": types.StringType, - "ReturnParams": FunctionParameterInfos{}.ToAttrType(ctx), - "RoutineBody": types.StringType, - "RoutineDefinition": types.StringType, - "RoutineDependencies": DependencyList{}.ToAttrType(ctx), - "SchemaName": types.StringType, - "SecurityType": types.StringType, - "SpecificName": types.StringType, - "SqlDataAccess": types.StringType, - "SqlPath": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_type": types.StringType, + "external_language": types.StringType, + "external_name": types.StringType, + "full_data_type": types.StringType, + "full_name": types.StringType, + "function_id": types.StringType, + "input_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + }, + "is_deterministic": types.BoolType, + "is_null_call": types.BoolType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "parameter_style": types.StringType, + "properties": types.StringType, + "return_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + }, + "routine_body": types.StringType, + "routine_definition": types.StringType, + "routine_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.ToAttrType(ctx), + }, + "schema_name": types.StringType, + "security_type": types.StringType, + "specific_name": types.StringType, + "sql_data_access": types.StringType, + "sql_path": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -3202,18 +3294,18 @@ func (a FunctionParameterInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a FunctionParameterInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "ParameterDefault": types.StringType, - "ParameterMode": types.StringType, - "ParameterType": types.StringType, - "Position": types.Int64Type, - "TypeIntervalType": types.StringType, - "TypeJson": types.StringType, - "TypeName": types.StringType, - "TypePrecision": types.Int64Type, - "TypeScale": types.Int64Type, - "TypeText": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "parameter_default": types.StringType, + "parameter_mode": types.StringType, + "parameter_type": types.StringType, + "position": types.Int64Type, + "type_interval_type": types.StringType, + "type_json": types.StringType, + "type_name": types.StringType, + "type_precision": types.Int64Type, + "type_scale": types.Int64Type, + "type_text": types.StringType, }, } } @@ -3232,14 +3324,14 @@ func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringRead(existingSt func (a FunctionParameterInfos) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(FunctionParameterInfo{}), + "parameters": reflect.TypeOf(FunctionParameterInfo{}), } } func (a FunctionParameterInfos) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Parameters": basetypes.ListType{ + "parameters": basetypes.ListType{ ElemType: FunctionParameterInfo{}.ToAttrType(ctx), }, }, @@ -3265,7 +3357,7 @@ func (a GcpOauthToken) GetComplexFieldTypes() map[string]reflect.Type { func (a GcpOauthToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "OauthToken": types.StringType, + "oauth_token": types.StringType, }, } } @@ -3293,9 +3385,9 @@ func (a GcpServiceAccountKey) GetComplexFieldTypes() map[string]reflect.Type { func (a GcpServiceAccountKey) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Email": types.StringType, - "PrivateKey": types.StringType, - "PrivateKeyId": types.StringType, + "email": types.StringType, + "private_key": types.StringType, + "private_key_id": types.StringType, }, } } @@ -3316,14 +3408,14 @@ func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFie func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Resources": reflect.TypeOf(types.StringType), + "resources": reflect.TypeOf(types.StringType), } } func (a GenerateTemporaryServiceCredentialAzureOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Resources": basetypes.ListType{ + "resources": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3346,15 +3438,17 @@ func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDu func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AzureOptions": reflect.TypeOf(GenerateTemporaryServiceCredentialAzureOptions{}), + "azure_options": reflect.TypeOf(GenerateTemporaryServiceCredentialAzureOptions{}), } } func (a GenerateTemporaryServiceCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AzureOptions": GenerateTemporaryServiceCredentialAzureOptions{}.ToAttrType(ctx), - "CredentialName": types.StringType, + "azure_options": basetypes.ListType{ + ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.ToAttrType(ctx), + }, + "credential_name": types.StringType, }, } } @@ -3381,8 +3475,8 @@ func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes() map[stri func (a GenerateTemporaryTableCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Operation": types.StringType, - "TableId": types.StringType, + "operation": types.StringType, + "table_id": types.StringType, }, } } @@ -3419,24 +3513,34 @@ func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDur func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsTempCredentials": reflect.TypeOf(AwsCredentials{}), - "AzureAad": reflect.TypeOf(AzureActiveDirectoryToken{}), - "AzureUserDelegationSas": reflect.TypeOf(AzureUserDelegationSas{}), - "GcpOauthToken": reflect.TypeOf(GcpOauthToken{}), - "R2TempCredentials": reflect.TypeOf(R2Credentials{}), + "aws_temp_credentials": reflect.TypeOf(AwsCredentials{}), + "azure_aad": reflect.TypeOf(AzureActiveDirectoryToken{}), + "azure_user_delegation_sas": reflect.TypeOf(AzureUserDelegationSas{}), + "gcp_oauth_token": reflect.TypeOf(GcpOauthToken{}), + "r2_temp_credentials": reflect.TypeOf(R2Credentials{}), } } func (a GenerateTemporaryTableCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsTempCredentials": AwsCredentials{}.ToAttrType(ctx), - "AzureAad": AzureActiveDirectoryToken{}.ToAttrType(ctx), - "AzureUserDelegationSas": AzureUserDelegationSas{}.ToAttrType(ctx), - "ExpirationTime": types.Int64Type, - "GcpOauthToken": GcpOauthToken{}.ToAttrType(ctx), - "R2TempCredentials": R2Credentials{}.ToAttrType(ctx), - "Url": types.StringType, + "aws_temp_credentials": basetypes.ListType{ + ElemType: AwsCredentials{}.ToAttrType(ctx), + }, + "azure_aad": basetypes.ListType{ + ElemType: AzureActiveDirectoryToken{}.ToAttrType(ctx), + }, + "azure_user_delegation_sas": basetypes.ListType{ + ElemType: AzureUserDelegationSas{}.ToAttrType(ctx), + }, + "expiration_time": types.Int64Type, + "gcp_oauth_token": basetypes.ListType{ + ElemType: GcpOauthToken{}.ToAttrType(ctx), + }, + "r2_temp_credentials": basetypes.ListType{ + ElemType: R2Credentials{}.ToAttrType(ctx), + }, + "url": types.StringType, }, } } @@ -3460,7 +3564,7 @@ func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[string] func (a GetAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceId": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -3484,7 +3588,7 @@ func (a GetAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, + "metastore_id": types.StringType, }, } } @@ -3510,8 +3614,8 @@ func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes() map[string]re func (a GetAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, - "StorageCredentialName": types.StringType, + "metastore_id": types.StringType, + "storage_credential_name": types.StringType, }, } } @@ -3535,7 +3639,7 @@ func (a GetArtifactAllowlistRequest) GetComplexFieldTypes() map[string]reflect.T func (a GetArtifactAllowlistRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactType": types.StringType, + "artifact_type": types.StringType, }, } } @@ -3570,10 +3674,10 @@ func (a GetBindingsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetBindingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "SecurableName": types.StringType, - "SecurableType": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "securable_name": types.StringType, + "securable_type": types.StringType, }, } } @@ -3602,9 +3706,9 @@ func (a GetByAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetByAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alias": types.StringType, - "FullName": types.StringType, - "IncludeAliases": types.BoolType, + "alias": types.StringType, + "full_name": types.StringType, + "include_aliases": types.BoolType, }, } } @@ -3631,8 +3735,8 @@ func (a GetCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeBrowse": types.BoolType, - "Name": types.StringType, + "include_browse": types.BoolType, + "name": types.StringType, }, } } @@ -3656,7 +3760,7 @@ func (a GetConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -3680,7 +3784,7 @@ func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NameArg": types.StringType, + "name_arg": types.StringType, }, } } @@ -3709,9 +3813,9 @@ func (a GetEffectiveRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetEffectiveRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "Principal": types.StringType, - "SecurableType": types.StringType, + "full_name": types.StringType, + "principal": types.StringType, + "securable_type": types.StringType, }, } } @@ -3738,8 +3842,8 @@ func (a GetExternalLocationRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeBrowse": types.BoolType, - "Name": types.StringType, + "include_browse": types.BoolType, + "name": types.StringType, }, } } @@ -3767,8 +3871,8 @@ func (a GetFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeBrowse": types.BoolType, - "Name": types.StringType, + "include_browse": types.BoolType, + "name": types.StringType, }, } } @@ -3797,9 +3901,9 @@ func (a GetGrantRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetGrantRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "Principal": types.StringType, - "SecurableType": types.StringType, + "full_name": types.StringType, + "principal": types.StringType, + "securable_type": types.StringType, }, } } @@ -3823,7 +3927,7 @@ func (a GetMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -3886,25 +3990,25 @@ func (a GetMetastoreSummaryResponse) GetComplexFieldTypes() map[string]reflect.T func (a GetMetastoreSummaryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cloud": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DefaultDataAccessConfigId": types.StringType, - "DeltaSharingOrganizationName": types.StringType, - "DeltaSharingRecipientTokenLifetimeInSeconds": types.Int64Type, - "DeltaSharingScope": types.StringType, - "ExternalAccessEnabled": types.BoolType, - "GlobalMetastoreId": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "PrivilegeModelVersion": types.StringType, - "Region": types.StringType, - "StorageRoot": types.StringType, - "StorageRootCredentialId": types.StringType, - "StorageRootCredentialName": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "cloud": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "default_data_access_config_id": types.StringType, + "delta_sharing_organization_name": types.StringType, + "delta_sharing_recipient_token_lifetime_in_seconds": types.Int64Type, + "delta_sharing_scope": types.StringType, + "external_access_enabled": types.BoolType, + "global_metastore_id": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "privilege_model_version": types.StringType, + "region": types.StringType, + "storage_root": types.StringType, + "storage_root_credential_id": types.StringType, + "storage_root_credential_name": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -3936,10 +4040,10 @@ func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "IncludeAliases": types.BoolType, - "IncludeBrowse": types.BoolType, - "Version": types.Int64Type, + "full_name": types.StringType, + "include_aliases": types.BoolType, + "include_browse": types.BoolType, + "version": types.Int64Type, }, } } @@ -3963,7 +4067,7 @@ func (a GetOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -3987,7 +4091,7 @@ func (a GetQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableName": types.StringType, + "table_name": types.StringType, }, } } @@ -4017,9 +4121,9 @@ func (a GetQuotaRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetQuotaRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ParentFullName": types.StringType, - "ParentSecurableType": types.StringType, - "QuotaName": types.StringType, + "parent_full_name": types.StringType, + "parent_securable_type": types.StringType, + "quota_name": types.StringType, }, } } @@ -4037,14 +4141,16 @@ func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringRead(existingState Ge func (a GetQuotaResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "QuotaInfo": reflect.TypeOf(QuotaInfo{}), + "quota_info": reflect.TypeOf(QuotaInfo{}), } } func (a GetQuotaResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QuotaInfo": QuotaInfo{}.ToAttrType(ctx), + "quota_info": basetypes.ListType{ + ElemType: QuotaInfo{}.ToAttrType(ctx), + }, }, } } @@ -4070,8 +4176,8 @@ func (a GetRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RefreshId": types.StringType, - "TableName": types.StringType, + "refresh_id": types.StringType, + "table_name": types.StringType, }, } } @@ -4100,9 +4206,9 @@ func (a GetRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a GetRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "IncludeAliases": types.BoolType, - "IncludeBrowse": types.BoolType, + "full_name": types.StringType, + "include_aliases": types.BoolType, + "include_browse": types.BoolType, }, } } @@ -4129,8 +4235,8 @@ func (a GetSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "IncludeBrowse": types.BoolType, + "full_name": types.StringType, + "include_browse": types.BoolType, }, } } @@ -4154,7 +4260,7 @@ func (a GetStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.T func (a GetStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -4185,10 +4291,10 @@ func (a GetTableRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "IncludeBrowse": types.BoolType, - "IncludeDeltaMetadata": types.BoolType, - "IncludeManifestCapabilities": types.BoolType, + "full_name": types.StringType, + "include_browse": types.BoolType, + "include_delta_metadata": types.BoolType, + "include_manifest_capabilities": types.BoolType, }, } } @@ -4212,7 +4318,7 @@ func (a GetWorkspaceBindingRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetWorkspaceBindingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -4236,7 +4342,7 @@ func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes() map[strin func (a ListAccountMetastoreAssignmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, + "metastore_id": types.StringType, }, } } @@ -4254,14 +4360,14 @@ func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuri func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "WorkspaceIds": reflect.TypeOf(types.Int64Type), + "workspace_ids": reflect.TypeOf(types.Int64Type), } } func (a ListAccountMetastoreAssignmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceIds": basetypes.ListType{ + "workspace_ids": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -4287,7 +4393,7 @@ func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes() map[string] func (a ListAccountStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, + "metastore_id": types.StringType, }, } } @@ -4305,14 +4411,14 @@ func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuring func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "StorageCredentials": reflect.TypeOf(StorageCredentialInfo{}), + "storage_credentials": reflect.TypeOf(StorageCredentialInfo{}), } } func (a ListAccountStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StorageCredentials": basetypes.ListType{ + "storage_credentials": basetypes.ListType{ ElemType: StorageCredentialInfo{}.ToAttrType(ctx), }, }, @@ -4351,9 +4457,9 @@ func (a ListCatalogsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListCatalogsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4375,17 +4481,17 @@ func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringRead(existingStat func (a ListCatalogsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Catalogs": reflect.TypeOf(CatalogInfo{}), + "catalogs": reflect.TypeOf(CatalogInfo{}), } } func (a ListCatalogsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Catalogs": basetypes.ListType{ + "catalogs": basetypes.ListType{ ElemType: CatalogInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4416,8 +4522,8 @@ func (a ListConnectionsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListConnectionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4439,17 +4545,17 @@ func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringRead(existingS func (a ListConnectionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Connections": reflect.TypeOf(ConnectionInfo{}), + "connections": reflect.TypeOf(ConnectionInfo{}), } } func (a ListConnectionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Connections": basetypes.ListType{ + "connections": basetypes.ListType{ ElemType: ConnectionInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4481,9 +4587,9 @@ func (a ListCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "Purpose": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "purpose": types.StringType, }, } } @@ -4504,17 +4610,17 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingS func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Credentials": reflect.TypeOf(CredentialInfo{}), + "credentials": reflect.TypeOf(CredentialInfo{}), } } func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Credentials": basetypes.ListType{ + "credentials": basetypes.ListType{ ElemType: CredentialInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4548,9 +4654,9 @@ func (a ListExternalLocationsRequest) GetComplexFieldTypes() map[string]reflect. func (a ListExternalLocationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4572,17 +4678,17 @@ func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringRead(exi func (a ListExternalLocationsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExternalLocations": reflect.TypeOf(ExternalLocationInfo{}), + "external_locations": reflect.TypeOf(ExternalLocationInfo{}), } } func (a ListExternalLocationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExternalLocations": basetypes.ListType{ + "external_locations": basetypes.ListType{ ElemType: ExternalLocationInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4620,11 +4726,11 @@ func (a ListFunctionsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListFunctionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "SchemaName": types.StringType, + "catalog_name": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "schema_name": types.StringType, }, } } @@ -4646,17 +4752,17 @@ func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListFunctionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Functions": reflect.TypeOf(FunctionInfo{}), + "functions": reflect.TypeOf(FunctionInfo{}), } } func (a ListFunctionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Functions": basetypes.ListType{ + "functions": basetypes.ListType{ ElemType: FunctionInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4674,14 +4780,14 @@ func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringRead(existingSt func (a ListMetastoresResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Metastores": reflect.TypeOf(MetastoreInfo{}), + "metastores": reflect.TypeOf(MetastoreInfo{}), } } func (a ListMetastoresResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Metastores": basetypes.ListType{ + "metastores": basetypes.ListType{ ElemType: MetastoreInfo{}.ToAttrType(ctx), }, }, @@ -4721,10 +4827,10 @@ func (a ListModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "full_name": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4745,17 +4851,17 @@ func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringRead(existin func (a ListModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ModelVersions": reflect.TypeOf(ModelVersionInfo{}), + "model_versions": reflect.TypeOf(ModelVersionInfo{}), } } func (a ListModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelVersions": basetypes.ListType{ + "model_versions": basetypes.ListType{ ElemType: ModelVersionInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4781,8 +4887,8 @@ func (a ListQuotasRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListQuotasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4804,15 +4910,15 @@ func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListQuotasResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Quotas": reflect.TypeOf(QuotaInfo{}), + "quotas": reflect.TypeOf(QuotaInfo{}), } } func (a ListQuotasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Quotas": basetypes.ListType{ + "next_page_token": types.StringType, + "quotas": basetypes.ListType{ ElemType: QuotaInfo{}.ToAttrType(ctx), }, }, @@ -4838,7 +4944,7 @@ func (a ListRefreshesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListRefreshesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableName": types.StringType, + "table_name": types.StringType, }, } } @@ -4889,11 +4995,11 @@ func (a ListRegisteredModelsRequest) GetComplexFieldTypes() map[string]reflect.T func (a ListRegisteredModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "SchemaName": types.StringType, + "catalog_name": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "schema_name": types.StringType, }, } } @@ -4914,15 +5020,15 @@ func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringRead(exis func (a ListRegisteredModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RegisteredModels": reflect.TypeOf(RegisteredModelInfo{}), + "registered_models": reflect.TypeOf(RegisteredModelInfo{}), } } func (a ListRegisteredModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "RegisteredModels": basetypes.ListType{ + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ ElemType: RegisteredModelInfo{}.ToAttrType(ctx), }, }, @@ -4960,10 +5066,10 @@ func (a ListSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "catalog_name": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4985,15 +5091,15 @@ func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Schemas": reflect.TypeOf(SchemaInfo{}), + "schemas": reflect.TypeOf(SchemaInfo{}), } } func (a ListSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Schemas": basetypes.ListType{ + "next_page_token": types.StringType, + "schemas": basetypes.ListType{ ElemType: SchemaInfo{}.ToAttrType(ctx), }, }, @@ -5026,8 +5132,8 @@ func (a ListStorageCredentialsRequest) GetComplexFieldTypes() map[string]reflect func (a ListStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -5049,15 +5155,15 @@ func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(ex func (a ListStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "StorageCredentials": reflect.TypeOf(StorageCredentialInfo{}), + "storage_credentials": reflect.TypeOf(StorageCredentialInfo{}), } } func (a ListStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "StorageCredentials": basetypes.ListType{ + "next_page_token": types.StringType, + "storage_credentials": basetypes.ListType{ ElemType: StorageCredentialInfo{}.ToAttrType(ctx), }, }, @@ -5101,12 +5207,12 @@ func (a ListSummariesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListSummariesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "IncludeManifestCapabilities": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "SchemaNamePattern": types.StringType, - "TableNamePattern": types.StringType, + "catalog_name": types.StringType, + "include_manifest_capabilities": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "schema_name_pattern": types.StringType, + "table_name_pattern": types.StringType, }, } } @@ -5139,9 +5245,9 @@ func (a ListSystemSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListSystemSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "MetastoreId": types.StringType, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "metastore_id": types.StringType, + "page_token": types.StringType, }, } } @@ -5163,15 +5269,15 @@ func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringRead(existin func (a ListSystemSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Schemas": reflect.TypeOf(SystemSchemaInfo{}), + "schemas": reflect.TypeOf(SystemSchemaInfo{}), } } func (a ListSystemSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Schemas": basetypes.ListType{ + "next_page_token": types.StringType, + "schemas": basetypes.ListType{ ElemType: SystemSchemaInfo{}.ToAttrType(ctx), }, }, @@ -5195,15 +5301,15 @@ func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringRead(existi func (a ListTableSummariesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tables": reflect.TypeOf(TableSummary{}), + "tables": reflect.TypeOf(TableSummary{}), } } func (a ListTableSummariesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Tables": basetypes.ListType{ + "next_page_token": types.StringType, + "tables": basetypes.ListType{ ElemType: TableSummary{}.ToAttrType(ctx), }, }, @@ -5254,16 +5360,16 @@ func (a ListTablesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListTablesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "IncludeBrowse": types.BoolType, - "IncludeDeltaMetadata": types.BoolType, - "IncludeManifestCapabilities": types.BoolType, - "MaxResults": types.Int64Type, - "OmitColumns": types.BoolType, - "OmitProperties": types.BoolType, - "OmitUsername": types.BoolType, - "PageToken": types.StringType, - "SchemaName": types.StringType, + "catalog_name": types.StringType, + "include_browse": types.BoolType, + "include_delta_metadata": types.BoolType, + "include_manifest_capabilities": types.BoolType, + "max_results": types.Int64Type, + "omit_columns": types.BoolType, + "omit_properties": types.BoolType, + "omit_username": types.BoolType, + "page_token": types.StringType, + "schema_name": types.StringType, }, } } @@ -5285,15 +5391,15 @@ func (newState *ListTablesResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListTablesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tables": reflect.TypeOf(TableInfo{}), + "tables": reflect.TypeOf(TableInfo{}), } } func (a ListTablesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Tables": basetypes.ListType{ + "next_page_token": types.StringType, + "tables": basetypes.ListType{ ElemType: TableInfo{}.ToAttrType(ctx), }, }, @@ -5340,11 +5446,11 @@ func (a ListVolumesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListVolumesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "IncludeBrowse": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "SchemaName": types.StringType, + "catalog_name": types.StringType, + "include_browse": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "schema_name": types.StringType, }, } } @@ -5366,15 +5472,15 @@ func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringRead(existi func (a ListVolumesResponseContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Volumes": reflect.TypeOf(VolumeInfo{}), + "volumes": reflect.TypeOf(VolumeInfo{}), } } func (a ListVolumesResponseContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Volumes": basetypes.ListType{ + "next_page_token": types.StringType, + "volumes": basetypes.ListType{ ElemType: VolumeInfo{}.ToAttrType(ctx), }, }, @@ -5403,9 +5509,9 @@ func (a MetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { func (a MetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DefaultCatalogName": types.StringType, - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "default_catalog_name": types.StringType, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -5468,25 +5574,25 @@ func (a MetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a MetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cloud": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DefaultDataAccessConfigId": types.StringType, - "DeltaSharingOrganizationName": types.StringType, - "DeltaSharingRecipientTokenLifetimeInSeconds": types.Int64Type, - "DeltaSharingScope": types.StringType, - "ExternalAccessEnabled": types.BoolType, - "GlobalMetastoreId": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "PrivilegeModelVersion": types.StringType, - "Region": types.StringType, - "StorageRoot": types.StringType, - "StorageRootCredentialId": types.StringType, - "StorageRootCredentialName": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "cloud": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "default_data_access_config_id": types.StringType, + "delta_sharing_organization_name": types.StringType, + "delta_sharing_recipient_token_lifetime_in_seconds": types.Int64Type, + "delta_sharing_scope": types.StringType, + "external_access_enabled": types.BoolType, + "global_metastore_id": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "privilege_model_version": types.StringType, + "region": types.StringType, + "storage_root": types.StringType, + "storage_root_credential_id": types.StringType, + "storage_root_credential_name": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -5552,35 +5658,37 @@ func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringRead(existingState Mo func (a ModelVersionInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Aliases": reflect.TypeOf(RegisteredModelAlias{}), - "ModelVersionDependencies": reflect.TypeOf(DependencyList{}), + "aliases": reflect.TypeOf(RegisteredModelAlias{}), + "model_version_dependencies": reflect.TypeOf(DependencyList{}), } } func (a ModelVersionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Aliases": basetypes.ListType{ + "aliases": basetypes.ListType{ ElemType: RegisteredModelAlias{}.ToAttrType(ctx), }, - "BrowseOnly": types.BoolType, - "CatalogName": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "Id": types.StringType, - "MetastoreId": types.StringType, - "ModelName": types.StringType, - "ModelVersionDependencies": DependencyList{}.ToAttrType(ctx), - "RunId": types.StringType, - "RunWorkspaceId": types.Int64Type, - "SchemaName": types.StringType, - "Source": types.StringType, - "Status": types.StringType, - "StorageLocation": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "Version": types.Int64Type, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "id": types.StringType, + "metastore_id": types.StringType, + "model_name": types.StringType, + "model_version_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.ToAttrType(ctx), + }, + "run_id": types.StringType, + "run_workspace_id": types.Int64Type, + "schema_name": types.StringType, + "source": types.StringType, + "status": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "version": types.Int64Type, }, } } @@ -5610,9 +5718,9 @@ func (a MonitorCronSchedule) GetComplexFieldTypes() map[string]reflect.Type { func (a MonitorCronSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PauseStatus": types.StringType, - "QuartzCronExpression": types.StringType, - "TimezoneId": types.StringType, + "pause_status": types.StringType, + "quartz_cron_expression": types.StringType, + "timezone_id": types.StringType, }, } } @@ -5635,7 +5743,7 @@ func (a MonitorDataClassificationConfig) GetComplexFieldTypes() map[string]refle func (a MonitorDataClassificationConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, + "enabled": types.BoolType, }, } } @@ -5654,14 +5762,14 @@ func (newState *MonitorDestination) SyncEffectiveFieldsDuringRead(existingState func (a MonitorDestination) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EmailAddresses": reflect.TypeOf(types.StringType), + "email_addresses": reflect.TypeOf(types.StringType), } } func (a MonitorDestination) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EmailAddresses": basetypes.ListType{ + "email_addresses": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -5707,22 +5815,22 @@ func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringRead(existingState func (a MonitorInferenceLog) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Granularities": reflect.TypeOf(types.StringType), + "granularities": reflect.TypeOf(types.StringType), } } func (a MonitorInferenceLog) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Granularities": basetypes.ListType{ + "granularities": basetypes.ListType{ ElemType: types.StringType, }, - "LabelCol": types.StringType, - "ModelIdCol": types.StringType, - "PredictionCol": types.StringType, - "PredictionProbaCol": types.StringType, - "ProblemType": types.StringType, - "TimestampCol": types.StringType, + "label_col": types.StringType, + "model_id_col": types.StringType, + "prediction_col": types.StringType, + "prediction_proba_col": types.StringType, + "problem_type": types.StringType, + "timestamp_col": types.StringType, }, } } @@ -5787,42 +5895,54 @@ func (newState *MonitorInfo) SyncEffectiveFieldsDuringRead(existingState Monitor func (a MonitorInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomMetrics": reflect.TypeOf(MonitorMetric{}), - "DataClassificationConfig": reflect.TypeOf(MonitorDataClassificationConfig{}), - "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), - "Notifications": reflect.TypeOf(MonitorNotifications{}), - "Schedule": reflect.TypeOf(MonitorCronSchedule{}), - "SlicingExprs": reflect.TypeOf(types.StringType), - "Snapshot": reflect.TypeOf(MonitorSnapshot{}), - "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), + "custom_metrics": reflect.TypeOf(MonitorMetric{}), + "data_classification_config": reflect.TypeOf(MonitorDataClassificationConfig{}), + "inference_log": reflect.TypeOf(MonitorInferenceLog{}), + "notifications": reflect.TypeOf(MonitorNotifications{}), + "schedule": reflect.TypeOf(MonitorCronSchedule{}), + "slicing_exprs": reflect.TypeOf(types.StringType), + "snapshot": reflect.TypeOf(MonitorSnapshot{}), + "time_series": reflect.TypeOf(MonitorTimeSeries{}), } } func (a MonitorInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AssetsDir": types.StringType, - "BaselineTableName": types.StringType, - "CustomMetrics": basetypes.ListType{ + "assets_dir": types.StringType, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ ElemType: MonitorMetric{}.ToAttrType(ctx), }, - "DashboardId": types.StringType, - "DataClassificationConfig": MonitorDataClassificationConfig{}.ToAttrType(ctx), - "DriftMetricsTableName": types.StringType, - "InferenceLog": MonitorInferenceLog{}.ToAttrType(ctx), - "LatestMonitorFailureMsg": types.StringType, - "MonitorVersion": types.StringType, - "Notifications": MonitorNotifications{}.ToAttrType(ctx), - "OutputSchemaName": types.StringType, - "ProfileMetricsTableName": types.StringType, - "Schedule": MonitorCronSchedule{}.ToAttrType(ctx), - "SlicingExprs": basetypes.ListType{ + "dashboard_id": types.StringType, + "data_classification_config": basetypes.ListType{ + ElemType: MonitorDataClassificationConfig{}.ToAttrType(ctx), + }, + "drift_metrics_table_name": types.StringType, + "inference_log": basetypes.ListType{ + ElemType: MonitorInferenceLog{}.ToAttrType(ctx), + }, + "latest_monitor_failure_msg": types.StringType, + "monitor_version": types.StringType, + "notifications": basetypes.ListType{ + ElemType: MonitorNotifications{}.ToAttrType(ctx), + }, + "output_schema_name": types.StringType, + "profile_metrics_table_name": types.StringType, + "schedule": basetypes.ListType{ + ElemType: MonitorCronSchedule{}.ToAttrType(ctx), + }, + "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, - "Snapshot": MonitorSnapshot{}.ToAttrType(ctx), - "Status": types.StringType, - "TableName": types.StringType, - "TimeSeries": MonitorTimeSeries{}.ToAttrType(ctx), + "snapshot": basetypes.ListType{ + ElemType: MonitorSnapshot{}.ToAttrType(ctx), + }, + "status": types.StringType, + "table_name": types.StringType, + "time_series": basetypes.ListType{ + ElemType: MonitorTimeSeries{}.ToAttrType(ctx), + }, }, } } @@ -5862,20 +5982,20 @@ func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState Monit func (a MonitorMetric) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InputColumns": reflect.TypeOf(types.StringType), + "input_columns": reflect.TypeOf(types.StringType), } } func (a MonitorMetric) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Definition": types.StringType, - "InputColumns": basetypes.ListType{ + "definition": types.StringType, + "input_columns": basetypes.ListType{ ElemType: types.StringType, }, - "Name": types.StringType, - "OutputDataType": types.StringType, - "Type": types.StringType, + "name": types.StringType, + "output_data_type": types.StringType, + "type": types.StringType, }, } } @@ -5896,16 +6016,20 @@ func (newState *MonitorNotifications) SyncEffectiveFieldsDuringRead(existingStat func (a MonitorNotifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OnFailure": reflect.TypeOf(MonitorDestination{}), - "OnNewClassificationTagDetected": reflect.TypeOf(MonitorDestination{}), + "on_failure": reflect.TypeOf(MonitorDestination{}), + "on_new_classification_tag_detected": reflect.TypeOf(MonitorDestination{}), } } func (a MonitorNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "OnFailure": MonitorDestination{}.ToAttrType(ctx), - "OnNewClassificationTagDetected": MonitorDestination{}.ToAttrType(ctx), + "on_failure": basetypes.ListType{ + ElemType: MonitorDestination{}.ToAttrType(ctx), + }, + "on_new_classification_tag_detected": basetypes.ListType{ + ElemType: MonitorDestination{}.ToAttrType(ctx), + }, }, } } @@ -5941,12 +6065,12 @@ func (a MonitorRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a MonitorRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndTimeMs": types.Int64Type, - "Message": types.StringType, - "RefreshId": types.Int64Type, - "StartTimeMs": types.Int64Type, - "State": types.StringType, - "Trigger": types.StringType, + "end_time_ms": types.Int64Type, + "message": types.StringType, + "refresh_id": types.Int64Type, + "start_time_ms": types.Int64Type, + "state": types.StringType, + "trigger": types.StringType, }, } } @@ -5964,14 +6088,14 @@ func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringRead(existi func (a MonitorRefreshListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Refreshes": reflect.TypeOf(MonitorRefreshInfo{}), + "refreshes": reflect.TypeOf(MonitorRefreshInfo{}), } } func (a MonitorRefreshListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Refreshes": basetypes.ListType{ + "refreshes": basetypes.ListType{ ElemType: MonitorRefreshInfo{}.ToAttrType(ctx), }, }, @@ -6020,17 +6144,17 @@ func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringRead(existingState M func (a MonitorTimeSeries) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Granularities": reflect.TypeOf(types.StringType), + "granularities": reflect.TypeOf(types.StringType), } } func (a MonitorTimeSeries) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Granularities": basetypes.ListType{ + "granularities": basetypes.ListType{ ElemType: types.StringType, }, - "TimestampCol": types.StringType, + "timestamp_col": types.StringType, }, } } @@ -6053,7 +6177,7 @@ func (a NamedTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { func (a NamedTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -6083,19 +6207,23 @@ func (newState *OnlineTable) SyncEffectiveFieldsDuringRead(existingState OnlineT func (a OnlineTable) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Spec": reflect.TypeOf(OnlineTableSpec{}), - "Status": reflect.TypeOf(OnlineTableStatus{}), + "spec": reflect.TypeOf(OnlineTableSpec{}), + "status": reflect.TypeOf(OnlineTableStatus{}), } } func (a OnlineTable) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Spec": OnlineTableSpec{}.ToAttrType(ctx), - "Status": OnlineTableStatus{}.ToAttrType(ctx), - "TableServingUrl": types.StringType, - "UnityCatalogProvisioningState": types.StringType, + "name": types.StringType, + "spec": basetypes.ListType{ + ElemType: OnlineTableSpec{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: OnlineTableStatus{}.ToAttrType(ctx), + }, + "table_serving_url": types.StringType, + "unity_catalog_provisioning_state": types.StringType, }, } } @@ -6135,24 +6263,28 @@ func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringRead(existingState Onl func (a OnlineTableSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrimaryKeyColumns": reflect.TypeOf(types.StringType), - "RunContinuously": reflect.TypeOf(OnlineTableSpecContinuousSchedulingPolicy{}), - "RunTriggered": reflect.TypeOf(OnlineTableSpecTriggeredSchedulingPolicy{}), + "primary_key_columns": reflect.TypeOf(types.StringType), + "run_continuously": reflect.TypeOf(OnlineTableSpecContinuousSchedulingPolicy{}), + "run_triggered": reflect.TypeOf(OnlineTableSpecTriggeredSchedulingPolicy{}), } } func (a OnlineTableSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PerformFullCopy": types.BoolType, - "PipelineId": types.StringType, - "PrimaryKeyColumns": basetypes.ListType{ + "perform_full_copy": types.BoolType, + "pipeline_id": types.StringType, + "primary_key_columns": basetypes.ListType{ ElemType: types.StringType, }, - "RunContinuously": OnlineTableSpecContinuousSchedulingPolicy{}.ToAttrType(ctx), - "RunTriggered": OnlineTableSpecTriggeredSchedulingPolicy{}.ToAttrType(ctx), - "SourceTableFullName": types.StringType, - "TimeseriesKey": types.StringType, + "run_continuously": basetypes.ListType{ + ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.ToAttrType(ctx), + }, + "run_triggered": basetypes.ListType{ + ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.ToAttrType(ctx), + }, + "source_table_full_name": types.StringType, + "timeseries_key": types.StringType, }, } } @@ -6224,22 +6356,30 @@ func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringRead(existingState O func (a OnlineTableStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ContinuousUpdateStatus": reflect.TypeOf(ContinuousUpdateStatus{}), - "FailedStatus": reflect.TypeOf(FailedStatus{}), - "ProvisioningStatus": reflect.TypeOf(ProvisioningStatus{}), - "TriggeredUpdateStatus": reflect.TypeOf(TriggeredUpdateStatus{}), + "continuous_update_status": reflect.TypeOf(ContinuousUpdateStatus{}), + "failed_status": reflect.TypeOf(FailedStatus{}), + "provisioning_status": reflect.TypeOf(ProvisioningStatus{}), + "triggered_update_status": reflect.TypeOf(TriggeredUpdateStatus{}), } } func (a OnlineTableStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ContinuousUpdateStatus": ContinuousUpdateStatus{}.ToAttrType(ctx), - "DetailedState": types.StringType, - "FailedStatus": FailedStatus{}.ToAttrType(ctx), - "Message": types.StringType, - "ProvisioningStatus": ProvisioningStatus{}.ToAttrType(ctx), - "TriggeredUpdateStatus": TriggeredUpdateStatus{}.ToAttrType(ctx), + "continuous_update_status": basetypes.ListType{ + ElemType: ContinuousUpdateStatus{}.ToAttrType(ctx), + }, + "detailed_state": types.StringType, + "failed_status": basetypes.ListType{ + ElemType: FailedStatus{}.ToAttrType(ctx), + }, + "message": types.StringType, + "provisioning_status": basetypes.ListType{ + ElemType: ProvisioningStatus{}.ToAttrType(ctx), + }, + "triggered_update_status": basetypes.ListType{ + ElemType: TriggeredUpdateStatus{}.ToAttrType(ctx), + }, }, } } @@ -6261,19 +6401,19 @@ func (newState *PermissionsChange) SyncEffectiveFieldsDuringRead(existingState P func (a PermissionsChange) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Add": reflect.TypeOf(types.StringType), - "Remove": reflect.TypeOf(types.StringType), + "add": reflect.TypeOf(types.StringType), + "remove": reflect.TypeOf(types.StringType), } } func (a PermissionsChange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Add": basetypes.ListType{ + "add": basetypes.ListType{ ElemType: types.StringType, }, - "Principal": types.StringType, - "Remove": basetypes.ListType{ + "principal": types.StringType, + "remove": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -6293,14 +6433,14 @@ func (newState *PermissionsList) SyncEffectiveFieldsDuringRead(existingState Per func (a PermissionsList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrivilegeAssignments": reflect.TypeOf(PrivilegeAssignment{}), + "privilege_assignments": reflect.TypeOf(PrivilegeAssignment{}), } } func (a PermissionsList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrivilegeAssignments": basetypes.ListType{ + "privilege_assignments": basetypes.ListType{ ElemType: PrivilegeAssignment{}.ToAttrType(ctx), }, }, @@ -6336,11 +6476,11 @@ func (a PipelineProgress) GetComplexFieldTypes() map[string]reflect.Type { func (a PipelineProgress) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EstimatedCompletionTimeSeconds": types.Float64Type, - "LatestVersionCurrentlyProcessing": types.Int64Type, - "SyncProgressCompletion": types.Float64Type, - "SyncedRowCount": types.Int64Type, - "TotalRowCount": types.Int64Type, + "estimated_completion_time_seconds": types.Float64Type, + "latest_version_currently_processing": types.Int64Type, + "sync_progress_completion": types.Float64Type, + "synced_row_count": types.Int64Type, + "total_row_count": types.Int64Type, }, } } @@ -6360,17 +6500,17 @@ func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringRead(existingStat func (a PrimaryKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ChildColumns": reflect.TypeOf(types.StringType), + "child_columns": reflect.TypeOf(types.StringType), } } func (a PrimaryKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ChildColumns": basetypes.ListType{ + "child_columns": basetypes.ListType{ ElemType: types.StringType, }, - "Name": types.StringType, + "name": types.StringType, }, } } @@ -6390,15 +6530,15 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Privileges": reflect.TypeOf(types.StringType), + "privileges": reflect.TypeOf(types.StringType), } } func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Principal": types.StringType, - "Privileges": basetypes.ListType{ + "principal": types.StringType, + "privileges": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -6423,7 +6563,7 @@ func (a ProvisioningInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ProvisioningInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "State": types.StringType, + "state": types.StringType, }, } } @@ -6444,14 +6584,16 @@ func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringRead(existingState func (a ProvisioningStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InitialPipelineSyncProgress": reflect.TypeOf(PipelineProgress{}), + "initial_pipeline_sync_progress": reflect.TypeOf(PipelineProgress{}), } } func (a ProvisioningStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InitialPipelineSyncProgress": PipelineProgress{}.ToAttrType(ctx), + "initial_pipeline_sync_progress": basetypes.ListType{ + ElemType: PipelineProgress{}.ToAttrType(ctx), + }, }, } } @@ -6485,12 +6627,12 @@ func (a QuotaInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a QuotaInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LastRefreshedAt": types.Int64Type, - "ParentFullName": types.StringType, - "ParentSecurableType": types.StringType, - "QuotaCount": types.Int64Type, - "QuotaLimit": types.Int64Type, - "QuotaName": types.StringType, + "last_refreshed_at": types.Int64Type, + "parent_full_name": types.StringType, + "parent_securable_type": types.StringType, + "quota_count": types.Int64Type, + "quota_limit": types.Int64Type, + "quota_name": types.StringType, }, } } @@ -6519,9 +6661,9 @@ func (a R2Credentials) GetComplexFieldTypes() map[string]reflect.Type { func (a R2Credentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessKeyId": types.StringType, - "SecretAccessKey": types.StringType, - "SessionToken": types.StringType, + "access_key_id": types.StringType, + "secret_access_key": types.StringType, + "session_token": types.StringType, }, } } @@ -6548,8 +6690,8 @@ func (a ReadVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ReadVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeBrowse": types.BoolType, - "Name": types.StringType, + "include_browse": types.BoolType, + "name": types.StringType, }, } } @@ -6575,8 +6717,8 @@ func (a RegenerateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a RegenerateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableName": types.StringType, - "WarehouseId": types.StringType, + "table_name": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -6601,8 +6743,8 @@ func (a RegenerateDashboardResponse) GetComplexFieldTypes() map[string]reflect.T func (a RegenerateDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "ParentFolder": types.StringType, + "dashboard_id": types.StringType, + "parent_folder": types.StringType, }, } } @@ -6628,8 +6770,8 @@ func (a RegisteredModelAlias) GetComplexFieldTypes() map[string]reflect.Type { func (a RegisteredModelAlias) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AliasName": types.StringType, - "VersionNum": types.Int64Type, + "alias_name": types.StringType, + "version_num": types.Int64Type, }, } } @@ -6678,29 +6820,29 @@ func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringRead(existingState func (a RegisteredModelInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Aliases": reflect.TypeOf(RegisteredModelAlias{}), + "aliases": reflect.TypeOf(RegisteredModelAlias{}), } } func (a RegisteredModelInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Aliases": basetypes.ListType{ + "aliases": basetypes.ListType{ ElemType: RegisteredModelAlias{}.ToAttrType(ctx), }, - "BrowseOnly": types.BoolType, - "CatalogName": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "FullName": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "SchemaName": types.StringType, - "StorageLocation": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "schema_name": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -6724,7 +6866,7 @@ func (a RunRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a RunRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableName": types.StringType, + "table_name": types.StringType, }, } } @@ -6779,34 +6921,36 @@ func (newState *SchemaInfo) SyncEffectiveFieldsDuringRead(existingState SchemaIn func (a SchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "Properties": reflect.TypeOf(types.StringType), + "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), + "properties": reflect.TypeOf(types.StringType), } } func (a SchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BrowseOnly": types.BoolType, - "CatalogName": types.StringType, - "CatalogType": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "EffectivePredictiveOptimizationFlag": EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), - "EnablePredictiveOptimization": types.StringType, - "FullName": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "Properties": basetypes.MapType{ + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "catalog_type": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "effective_predictive_optimization_flag": basetypes.ListType{ + ElemType: EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + }, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "SchemaId": types.StringType, - "StorageLocation": types.StringType, - "StorageRoot": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "schema_id": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -6826,17 +6970,17 @@ func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringRead(existingStat func (a SetArtifactAllowlist) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ArtifactMatchers": reflect.TypeOf(ArtifactMatcher{}), + "artifact_matchers": reflect.TypeOf(ArtifactMatcher{}), } } func (a SetArtifactAllowlist) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactMatchers": basetypes.ListType{ + "artifact_matchers": basetypes.ListType{ ElemType: ArtifactMatcher{}.ToAttrType(ctx), }, - "ArtifactType": types.StringType, + "artifact_type": types.StringType, }, } } @@ -6863,9 +7007,9 @@ func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes() map[string]reflec func (a SetRegisteredModelAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alias": types.StringType, - "FullName": types.StringType, - "VersionNum": types.Int64Type, + "alias": types.StringType, + "full_name": types.StringType, + "version_num": types.Int64Type, }, } } @@ -6892,8 +7036,8 @@ func (a SseEncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { func (a SseEncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Algorithm": types.StringType, - "AwsKmsKeyArn": types.StringType, + "algorithm": types.StringType, + "aws_kms_key_arn": types.StringType, }, } } @@ -6946,35 +7090,45 @@ func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingSta func (a StorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRoleResponse{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityResponse{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), - "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), - "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountResponse{}), + "aws_iam_role": reflect.TypeOf(AwsIamRoleResponse{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityResponse{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), + "cloudflare_api_token": reflect.TypeOf(CloudflareApiToken{}), + "databricks_gcp_service_account": reflect.TypeOf(DatabricksGcpServiceAccountResponse{}), } } func (a StorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRoleResponse{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentityResponse{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountResponse{}.ToAttrType(ctx), - "FullName": types.StringType, - "Id": types.StringType, - "IsolationMode": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "ReadOnly": types.BoolType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "UsedForManagedStorage": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleResponse{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityResponse{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountResponse{}.ToAttrType(ctx), + }, + "full_name": types.StringType, + "id": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "used_for_managed_storage": types.BoolType, }, } } @@ -7000,8 +7154,8 @@ func (a SystemSchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a SystemSchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Schema": types.StringType, - "State": types.StringType, + "schema": types.StringType, + "state": types.StringType, }, } } @@ -7025,18 +7179,24 @@ func (newState *TableConstraint) SyncEffectiveFieldsDuringRead(existingState Tab func (a TableConstraint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ForeignKeyConstraint": reflect.TypeOf(ForeignKeyConstraint{}), - "NamedTableConstraint": reflect.TypeOf(NamedTableConstraint{}), - "PrimaryKeyConstraint": reflect.TypeOf(PrimaryKeyConstraint{}), + "foreign_key_constraint": reflect.TypeOf(ForeignKeyConstraint{}), + "named_table_constraint": reflect.TypeOf(NamedTableConstraint{}), + "primary_key_constraint": reflect.TypeOf(PrimaryKeyConstraint{}), } } func (a TableConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ForeignKeyConstraint": ForeignKeyConstraint{}.ToAttrType(ctx), - "NamedTableConstraint": NamedTableConstraint{}.ToAttrType(ctx), - "PrimaryKeyConstraint": PrimaryKeyConstraint{}.ToAttrType(ctx), + "foreign_key_constraint": basetypes.ListType{ + ElemType: ForeignKeyConstraint{}.ToAttrType(ctx), + }, + "named_table_constraint": basetypes.ListType{ + ElemType: NamedTableConstraint{}.ToAttrType(ctx), + }, + "primary_key_constraint": basetypes.ListType{ + ElemType: PrimaryKeyConstraint{}.ToAttrType(ctx), + }, }, } } @@ -7061,7 +7221,7 @@ func (a TableDependency) GetComplexFieldTypes() map[string]reflect.Type { func (a TableDependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableFullName": types.StringType, + "table_full_name": types.StringType, }, } } @@ -7084,7 +7244,7 @@ func (a TableExistsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a TableExistsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TableExists": types.BoolType, + "table_exists": types.BoolType, }, } } @@ -7177,58 +7337,68 @@ func (newState *TableInfo) SyncEffectiveFieldsDuringRead(existingState TableInfo func (a TableInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Columns": reflect.TypeOf(ColumnInfo{}), - "DeltaRuntimePropertiesKvpairs": reflect.TypeOf(DeltaRuntimePropertiesKvPairs{}), - "EffectivePredictiveOptimizationFlag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), - "Properties": reflect.TypeOf(types.StringType), - "RowFilter": reflect.TypeOf(TableRowFilter{}), - "TableConstraints": reflect.TypeOf(TableConstraint{}), - "ViewDependencies": reflect.TypeOf(DependencyList{}), + "columns": reflect.TypeOf(ColumnInfo{}), + "delta_runtime_properties_kvpairs": reflect.TypeOf(DeltaRuntimePropertiesKvPairs{}), + "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), + "encryption_details": reflect.TypeOf(EncryptionDetails{}), + "properties": reflect.TypeOf(types.StringType), + "row_filter": reflect.TypeOf(TableRowFilter{}), + "table_constraints": reflect.TypeOf(TableConstraint{}), + "view_dependencies": reflect.TypeOf(DependencyList{}), } } func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessPoint": types.StringType, - "BrowseOnly": types.BoolType, - "CatalogName": types.StringType, - "Columns": basetypes.ListType{ + "access_point": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "columns": basetypes.ListType{ ElemType: ColumnInfo{}.ToAttrType(ctx), }, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DataAccessConfigurationId": types.StringType, - "DataSourceFormat": types.StringType, - "DeletedAt": types.Int64Type, - "DeltaRuntimePropertiesKvpairs": DeltaRuntimePropertiesKvPairs{}.ToAttrType(ctx), - "EffectivePredictiveOptimizationFlag": EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), - "EnablePredictiveOptimization": types.StringType, - "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), - "FullName": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "PipelineId": types.StringType, - "Properties": basetypes.MapType{ + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_access_configuration_id": types.StringType, + "data_source_format": types.StringType, + "deleted_at": types.Int64Type, + "delta_runtime_properties_kvpairs": basetypes.ListType{ + ElemType: DeltaRuntimePropertiesKvPairs{}.ToAttrType(ctx), + }, + "effective_predictive_optimization_flag": basetypes.ListType{ + ElemType: EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + }, + "enable_predictive_optimization": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.ToAttrType(ctx), + }, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "pipeline_id": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, - "RowFilter": TableRowFilter{}.ToAttrType(ctx), - "SchemaName": types.StringType, - "SqlPath": types.StringType, - "StorageCredentialName": types.StringType, - "StorageLocation": types.StringType, - "TableConstraints": basetypes.ListType{ + "row_filter": basetypes.ListType{ + ElemType: TableRowFilter{}.ToAttrType(ctx), + }, + "schema_name": types.StringType, + "sql_path": types.StringType, + "storage_credential_name": types.StringType, + "storage_location": types.StringType, + "table_constraints": basetypes.ListType{ ElemType: TableConstraint{}.ToAttrType(ctx), }, - "TableId": types.StringType, - "TableType": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "ViewDefinition": types.StringType, - "ViewDependencies": DependencyList{}.ToAttrType(ctx), + "table_id": types.StringType, + "table_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "view_definition": types.StringType, + "view_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.ToAttrType(ctx), + }, }, } } @@ -7250,15 +7420,15 @@ func (newState *TableRowFilter) SyncEffectiveFieldsDuringRead(existingState Tabl func (a TableRowFilter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InputColumnNames": reflect.TypeOf(types.StringType), + "input_column_names": reflect.TypeOf(types.StringType), } } func (a TableRowFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FunctionName": types.StringType, - "InputColumnNames": basetypes.ListType{ + "function_name": types.StringType, + "input_column_names": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -7285,8 +7455,8 @@ func (a TableSummary) GetComplexFieldTypes() map[string]reflect.Type { func (a TableSummary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "TableType": types.StringType, + "full_name": types.StringType, + "table_type": types.StringType, }, } } @@ -7312,17 +7482,21 @@ func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringRead(existingStat func (a TemporaryCredentials) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsTempCredentials": reflect.TypeOf(AwsCredentials{}), - "AzureAad": reflect.TypeOf(AzureActiveDirectoryToken{}), + "aws_temp_credentials": reflect.TypeOf(AwsCredentials{}), + "azure_aad": reflect.TypeOf(AzureActiveDirectoryToken{}), } } func (a TemporaryCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsTempCredentials": AwsCredentials{}.ToAttrType(ctx), - "AzureAad": AzureActiveDirectoryToken{}.ToAttrType(ctx), - "ExpirationTime": types.Int64Type, + "aws_temp_credentials": basetypes.ListType{ + ElemType: AwsCredentials{}.ToAttrType(ctx), + }, + "azure_aad": basetypes.ListType{ + ElemType: AzureActiveDirectoryToken{}.ToAttrType(ctx), + }, + "expiration_time": types.Int64Type, }, } } @@ -7349,16 +7523,18 @@ func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringRead(existingSta func (a TriggeredUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TriggeredUpdateProgress": reflect.TypeOf(PipelineProgress{}), + "triggered_update_progress": reflect.TypeOf(PipelineProgress{}), } } func (a TriggeredUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LastProcessedCommitVersion": types.Int64Type, - "Timestamp": types.StringType, - "TriggeredUpdateProgress": PipelineProgress{}.ToAttrType(ctx), + "last_processed_commit_version": types.Int64Type, + "timestamp": types.StringType, + "triggered_update_progress": basetypes.ListType{ + ElemType: PipelineProgress{}.ToAttrType(ctx), + }, }, } } @@ -7384,8 +7560,8 @@ func (a UnassignRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a UnassignRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -7455,20 +7631,20 @@ func (newState *UpdateCatalog) SyncEffectiveFieldsDuringRead(existingState Updat func (a UpdateCatalog) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), } } func (a UpdateCatalog) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "EnablePredictiveOptimization": types.StringType, - "IsolationMode": types.StringType, - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "Properties": basetypes.MapType{ + "comment": types.StringType, + "enable_predictive_optimization": types.StringType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -7494,19 +7670,19 @@ func (newState *UpdateConnection) SyncEffectiveFieldsDuringRead(existingState Up func (a UpdateConnection) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.StringType), } } func (a UpdateConnection) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "NewName": types.StringType, - "Options": basetypes.MapType{ + "name": types.StringType, + "new_name": types.StringType, + "options": basetypes.MapType{ ElemType: types.StringType, }, - "Owner": types.StringType, + "owner": types.StringType, }, } } @@ -7549,26 +7725,32 @@ func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringRead(existingS func (a UpdateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRole{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), + "aws_iam_role": reflect.TypeOf(AwsIamRole{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), } } func (a UpdateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "Comment": types.StringType, - "Force": types.BoolType, - "IsolationMode": types.StringType, - "NameArg": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "ReadOnly": types.BoolType, - "SkipValidation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name_arg": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -7614,26 +7796,28 @@ func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } func (a UpdateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessPoint": types.StringType, - "Comment": types.StringType, - "CredentialName": types.StringType, - "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), - "Fallback": types.BoolType, - "Force": types.BoolType, - "IsolationMode": types.StringType, - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "ReadOnly": types.BoolType, - "SkipValidation": types.BoolType, - "Url": types.StringType, + "access_point": types.StringType, + "comment": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.ToAttrType(ctx), + }, + "fallback": types.BoolType, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, + "url": types.StringType, }, } } @@ -7659,8 +7843,8 @@ func (a UpdateFunction) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateFunction) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Owner": types.StringType, + "name": types.StringType, + "owner": types.StringType, }, } } @@ -7699,14 +7883,14 @@ func (a UpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DeltaSharingOrganizationName": types.StringType, - "DeltaSharingRecipientTokenLifetimeInSeconds": types.Int64Type, - "DeltaSharingScope": types.StringType, - "Id": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "PrivilegeModelVersion": types.StringType, - "StorageRootCredentialId": types.StringType, + "delta_sharing_organization_name": types.StringType, + "delta_sharing_recipient_token_lifetime_in_seconds": types.Int64Type, + "delta_sharing_scope": types.StringType, + "id": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "privilege_model_version": types.StringType, + "storage_root_credential_id": types.StringType, }, } } @@ -7735,9 +7919,9 @@ func (a UpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Typ func (a UpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DefaultCatalogName": types.StringType, - "MetastoreId": types.StringType, - "WorkspaceId": types.Int64Type, + "default_catalog_name": types.StringType, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -7764,9 +7948,9 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "FullName": types.StringType, - "Version": types.Int64Type, + "comment": types.StringType, + "full_name": types.StringType, + "version": types.Int64Type, }, } } @@ -7815,36 +7999,48 @@ func (newState *UpdateMonitor) SyncEffectiveFieldsDuringRead(existingState Updat func (a UpdateMonitor) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomMetrics": reflect.TypeOf(MonitorMetric{}), - "DataClassificationConfig": reflect.TypeOf(MonitorDataClassificationConfig{}), - "InferenceLog": reflect.TypeOf(MonitorInferenceLog{}), - "Notifications": reflect.TypeOf(MonitorNotifications{}), - "Schedule": reflect.TypeOf(MonitorCronSchedule{}), - "SlicingExprs": reflect.TypeOf(types.StringType), - "Snapshot": reflect.TypeOf(MonitorSnapshot{}), - "TimeSeries": reflect.TypeOf(MonitorTimeSeries{}), + "custom_metrics": reflect.TypeOf(MonitorMetric{}), + "data_classification_config": reflect.TypeOf(MonitorDataClassificationConfig{}), + "inference_log": reflect.TypeOf(MonitorInferenceLog{}), + "notifications": reflect.TypeOf(MonitorNotifications{}), + "schedule": reflect.TypeOf(MonitorCronSchedule{}), + "slicing_exprs": reflect.TypeOf(types.StringType), + "snapshot": reflect.TypeOf(MonitorSnapshot{}), + "time_series": reflect.TypeOf(MonitorTimeSeries{}), } } func (a UpdateMonitor) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BaselineTableName": types.StringType, - "CustomMetrics": basetypes.ListType{ + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ ElemType: MonitorMetric{}.ToAttrType(ctx), }, - "DashboardId": types.StringType, - "DataClassificationConfig": MonitorDataClassificationConfig{}.ToAttrType(ctx), - "InferenceLog": MonitorInferenceLog{}.ToAttrType(ctx), - "Notifications": MonitorNotifications{}.ToAttrType(ctx), - "OutputSchemaName": types.StringType, - "Schedule": MonitorCronSchedule{}.ToAttrType(ctx), - "SlicingExprs": basetypes.ListType{ + "dashboard_id": types.StringType, + "data_classification_config": basetypes.ListType{ + ElemType: MonitorDataClassificationConfig{}.ToAttrType(ctx), + }, + "inference_log": basetypes.ListType{ + ElemType: MonitorInferenceLog{}.ToAttrType(ctx), + }, + "notifications": basetypes.ListType{ + ElemType: MonitorNotifications{}.ToAttrType(ctx), + }, + "output_schema_name": types.StringType, + "schedule": basetypes.ListType{ + ElemType: MonitorCronSchedule{}.ToAttrType(ctx), + }, + "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, - "Snapshot": MonitorSnapshot{}.ToAttrType(ctx), - "TableName": types.StringType, - "TimeSeries": MonitorTimeSeries{}.ToAttrType(ctx), + "snapshot": basetypes.ListType{ + ElemType: MonitorSnapshot{}.ToAttrType(ctx), + }, + "table_name": types.StringType, + "time_series": basetypes.ListType{ + ElemType: MonitorTimeSeries{}.ToAttrType(ctx), + }, }, } } @@ -7866,18 +8062,18 @@ func (newState *UpdatePermissions) SyncEffectiveFieldsDuringRead(existingState U func (a UpdatePermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Changes": reflect.TypeOf(PermissionsChange{}), + "changes": reflect.TypeOf(PermissionsChange{}), } } func (a UpdatePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Changes": basetypes.ListType{ + "changes": basetypes.ListType{ ElemType: PermissionsChange{}.ToAttrType(ctx), }, - "FullName": types.StringType, - "SecurableType": types.StringType, + "full_name": types.StringType, + "securable_type": types.StringType, }, } } @@ -7906,10 +8102,10 @@ func (a UpdateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect. func (a UpdateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "FullName": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, + "comment": types.StringType, + "full_name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, }, } } @@ -7957,19 +8153,19 @@ func (newState *UpdateSchema) SyncEffectiveFieldsDuringRead(existingState Update func (a UpdateSchema) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), } } func (a UpdateSchema) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "EnablePredictiveOptimization": types.StringType, - "FullName": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "Properties": basetypes.MapType{ + "comment": types.StringType, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "properties": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -8015,30 +8211,40 @@ func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingS func (a UpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRoleRequest{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityResponse{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), - "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), - "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), + "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityResponse{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), + "cloudflare_api_token": reflect.TypeOf(CloudflareApiToken{}), + "databricks_gcp_service_account": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), } } func (a UpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRoleRequest{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentityResponse{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), - "Comment": types.StringType, - "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), - "Force": types.BoolType, - "IsolationMode": types.StringType, - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "ReadOnly": types.BoolType, - "SkipValidation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleRequest{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityResponse{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + }, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -8064,8 +8270,8 @@ func (a UpdateTableRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullName": types.StringType, - "Owner": types.StringType, + "full_name": types.StringType, + "owner": types.StringType, }, } } @@ -8094,10 +8300,10 @@ func (a UpdateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Ty func (a UpdateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, }, } } @@ -8119,19 +8325,19 @@ func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingS func (a UpdateWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AssignWorkspaces": reflect.TypeOf(types.Int64Type), - "UnassignWorkspaces": reflect.TypeOf(types.Int64Type), + "assign_workspaces": reflect.TypeOf(types.Int64Type), + "unassign_workspaces": reflect.TypeOf(types.Int64Type), } } func (a UpdateWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AssignWorkspaces": basetypes.ListType{ + "assign_workspaces": basetypes.ListType{ ElemType: types.Int64Type, }, - "Name": types.StringType, - "UnassignWorkspaces": basetypes.ListType{ + "name": types.StringType, + "unassign_workspaces": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -8157,22 +8363,22 @@ func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringRead func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Add": reflect.TypeOf(WorkspaceBinding{}), - "Remove": reflect.TypeOf(WorkspaceBinding{}), + "add": reflect.TypeOf(WorkspaceBinding{}), + "remove": reflect.TypeOf(WorkspaceBinding{}), } } func (a UpdateWorkspaceBindingsParameters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Add": basetypes.ListType{ + "add": basetypes.ListType{ ElemType: WorkspaceBinding{}.ToAttrType(ctx), }, - "Remove": basetypes.ListType{ + "remove": basetypes.ListType{ ElemType: WorkspaceBinding{}.ToAttrType(ctx), }, - "SecurableName": types.StringType, - "SecurableType": types.StringType, + "securable_name": types.StringType, + "securable_type": types.StringType, }, } } @@ -8207,21 +8413,25 @@ func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringRead(existin func (a ValidateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRole{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentity{}), + "aws_iam_role": reflect.TypeOf(AwsIamRole{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), } } func (a ValidateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRole{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentity{}.ToAttrType(ctx), - "CredentialName": types.StringType, - "ExternalLocationName": types.StringType, - "Purpose": types.StringType, - "ReadOnly": types.BoolType, - "Url": types.StringType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + }, + "credential_name": types.StringType, + "external_location_name": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "url": types.StringType, }, } } @@ -8242,15 +8452,15 @@ func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringRead(existi func (a ValidateCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(CredentialValidationResult{}), + "results": reflect.TypeOf(CredentialValidationResult{}), } } func (a ValidateCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsDir": types.BoolType, - "Results": basetypes.ListType{ + "isDir": types.BoolType, + "results": basetypes.ListType{ ElemType: CredentialValidationResult{}.ToAttrType(ctx), }, }, @@ -8286,26 +8496,36 @@ func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringRead(existin func (a ValidateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsIamRole": reflect.TypeOf(AwsIamRoleRequest{}), - "AzureManagedIdentity": reflect.TypeOf(AzureManagedIdentityRequest{}), - "AzureServicePrincipal": reflect.TypeOf(AzureServicePrincipal{}), - "CloudflareApiToken": reflect.TypeOf(CloudflareApiToken{}), - "DatabricksGcpServiceAccount": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), + "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), + "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityRequest{}), + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), + "cloudflare_api_token": reflect.TypeOf(CloudflareApiToken{}), + "databricks_gcp_service_account": reflect.TypeOf(DatabricksGcpServiceAccountRequest{}), } } func (a ValidateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsIamRole": AwsIamRoleRequest{}.ToAttrType(ctx), - "AzureManagedIdentity": AzureManagedIdentityRequest{}.ToAttrType(ctx), - "AzureServicePrincipal": AzureServicePrincipal{}.ToAttrType(ctx), - "CloudflareApiToken": CloudflareApiToken{}.ToAttrType(ctx), - "DatabricksGcpServiceAccount": DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), - "ExternalLocationName": types.StringType, - "ReadOnly": types.BoolType, - "StorageCredentialName": types.StringType, - "Url": types.StringType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleRequest{}.ToAttrType(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityRequest{}.ToAttrType(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.ToAttrType(ctx), + }, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + }, + "external_location_name": types.StringType, + "read_only": types.BoolType, + "storage_credential_name": types.StringType, + "url": types.StringType, }, } } @@ -8325,15 +8545,15 @@ func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringRead func (a ValidateStorageCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(ValidationResult{}), + "results": reflect.TypeOf(ValidationResult{}), } } func (a ValidateStorageCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsDir": types.BoolType, - "Results": basetypes.ListType{ + "isDir": types.BoolType, + "results": basetypes.ListType{ ElemType: ValidationResult{}.ToAttrType(ctx), }, }, @@ -8362,9 +8582,9 @@ func (a ValidationResult) GetComplexFieldTypes() map[string]reflect.Type { func (a ValidationResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, - "Operation": types.StringType, - "Result": types.StringType, + "message": types.StringType, + "operation": types.StringType, + "result": types.StringType, }, } } @@ -8416,30 +8636,32 @@ func (newState *VolumeInfo) SyncEffectiveFieldsDuringRead(existingState VolumeIn func (a VolumeInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EncryptionDetails": reflect.TypeOf(EncryptionDetails{}), + "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } func (a VolumeInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessPoint": types.StringType, - "BrowseOnly": types.BoolType, - "CatalogName": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "EncryptionDetails": EncryptionDetails{}.ToAttrType(ctx), - "FullName": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "SchemaName": types.StringType, - "StorageLocation": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "VolumeId": types.StringType, - "VolumeType": types.StringType, + "access_point": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.ToAttrType(ctx), + }, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "schema_name": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "volume_id": types.StringType, + "volume_type": types.StringType, }, } } @@ -8463,8 +8685,8 @@ func (a WorkspaceBinding) GetComplexFieldTypes() map[string]reflect.Type { func (a WorkspaceBinding) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BindingType": types.StringType, - "WorkspaceId": types.Int64Type, + "binding_type": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -8487,17 +8709,17 @@ func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringRead(existin func (a WorkspaceBindingsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Bindings": reflect.TypeOf(WorkspaceBinding{}), + "bindings": reflect.TypeOf(WorkspaceBinding{}), } } func (a WorkspaceBindingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Bindings": basetypes.ListType{ + "bindings": basetypes.ListType{ ElemType: WorkspaceBinding{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 7742acceb3..9a269050fa 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -61,10 +61,10 @@ func (a AddInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { func (a AddInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IamRoleArn": types.StringType, - "InstanceProfileArn": types.StringType, - "IsMetaInstanceProfile": types.BoolType, - "SkipValidation": types.BoolType, + "iam_role_arn": types.StringType, + "instance_profile_arn": types.StringType, + "is_meta_instance_profile": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -107,7 +107,7 @@ func (a Adlsgen2Info) GetComplexFieldTypes() map[string]reflect.Type { func (a Adlsgen2Info) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Destination": types.StringType, + "destination": types.StringType, }, } } @@ -136,8 +136,8 @@ func (a AutoScale) GetComplexFieldTypes() map[string]reflect.Type { func (a AutoScale) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxWorkers": types.Int64Type, - "MinWorkers": types.Int64Type, + "max_workers": types.Int64Type, + "min_workers": types.Int64Type, }, } } @@ -241,16 +241,16 @@ func (a AwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { func (a AwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Availability": types.StringType, - "EbsVolumeCount": types.Int64Type, - "EbsVolumeIops": types.Int64Type, - "EbsVolumeSize": types.Int64Type, - "EbsVolumeThroughput": types.Int64Type, - "EbsVolumeType": types.StringType, - "FirstOnDemand": types.Int64Type, - "InstanceProfileArn": types.StringType, - "SpotBidPricePercent": types.Int64Type, - "ZoneId": types.StringType, + "availability": types.StringType, + "ebs_volume_count": types.Int64Type, + "ebs_volume_iops": types.Int64Type, + "ebs_volume_size": types.Int64Type, + "ebs_volume_throughput": types.Int64Type, + "ebs_volume_type": types.StringType, + "first_on_demand": types.Int64Type, + "instance_profile_arn": types.StringType, + "spot_bid_price_percent": types.Int64Type, + "zone_id": types.StringType, }, } } @@ -289,17 +289,19 @@ func (newState *AzureAttributes) SyncEffectiveFieldsDuringRead(existingState Azu func (a AzureAttributes) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LogAnalyticsInfo": reflect.TypeOf(LogAnalyticsInfo{}), + "log_analytics_info": reflect.TypeOf(LogAnalyticsInfo{}), } } func (a AzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Availability": types.StringType, - "FirstOnDemand": types.Int64Type, - "LogAnalyticsInfo": LogAnalyticsInfo{}.ToAttrType(ctx), - "SpotBidMaxPrice": types.Float64Type, + "availability": types.StringType, + "first_on_demand": types.Int64Type, + "log_analytics_info": basetypes.ListType{ + ElemType: LogAnalyticsInfo{}.ToAttrType(ctx), + }, + "spot_bid_max_price": types.Float64Type, }, } } @@ -325,9 +327,9 @@ func (a CancelCommand) GetComplexFieldTypes() map[string]reflect.Type { func (a CancelCommand) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "CommandId": types.StringType, - "ContextId": types.StringType, + "clusterId": types.StringType, + "commandId": types.StringType, + "contextId": types.StringType, }, } } @@ -371,8 +373,8 @@ func (a ChangeClusterOwner) GetComplexFieldTypes() map[string]reflect.Type { func (a ChangeClusterOwner) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "OwnerUsername": types.StringType, + "cluster_id": types.StringType, + "owner_username": types.StringType, }, } } @@ -416,8 +418,8 @@ func (a ClientsTypes) GetComplexFieldTypes() map[string]reflect.Type { func (a ClientsTypes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Jobs": types.BoolType, - "Notebooks": types.BoolType, + "jobs": types.BoolType, + "notebooks": types.BoolType, }, } } @@ -440,7 +442,7 @@ func (a CloneCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a CloneCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "SourceClusterId": types.StringType, + "source_cluster_id": types.StringType, }, } } @@ -457,14 +459,14 @@ func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringRead(existingSta func (a CloudProviderNodeInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Status": reflect.TypeOf(types.StringType), + "status": reflect.TypeOf(types.StringType), } } func (a CloudProviderNodeInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Status": basetypes.ListType{ + "status": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -495,10 +497,10 @@ func (a ClusterAccessControlRequest) GetComplexFieldTypes() map[string]reflect.T func (a ClusterAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -524,20 +526,20 @@ func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringRead(exis func (a ClusterAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(ClusterPermission{}), + "all_permissions": reflect.TypeOf(ClusterPermission{}), } } func (a ClusterAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: ClusterPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -683,57 +685,69 @@ func (newState *ClusterAttributes) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterAttributes) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsAttributes": reflect.TypeOf(AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(AzureAttributes{}), - "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DockerImage": reflect.TypeOf(DockerImage{}), - "GcpAttributes": reflect.TypeOf(GcpAttributes{}), - "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "SshPublicKeys": reflect.TypeOf(types.StringType), - "WorkloadType": reflect.TypeOf(WorkloadType{}), + "aws_attributes": reflect.TypeOf(AwsAttributes{}), + "azure_attributes": reflect.TypeOf(AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), + "custom_tags": reflect.TypeOf(types.StringType), + "docker_image": reflect.TypeOf(DockerImage{}), + "gcp_attributes": reflect.TypeOf(GcpAttributes{}), + "init_scripts": reflect.TypeOf(InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.StringType), + "workload_type": reflect.TypeOf(WorkloadType{}), } } func (a ClusterAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoterminationMinutes": types.Int64Type, - "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), - "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), - "ClusterName": types.StringType, - "CustomTags": basetypes.MapType{ + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.ToAttrType(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.ToAttrType(ctx), + }, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DataSecurityMode": types.StringType, - "DockerImage": DockerImage{}.ToAttrType(ctx), - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableElasticDisk": types.BoolType, - "EnableLocalDiskEncryption": types.BoolType, - "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_elastic_disk": types.BoolType, + "enable_local_disk_encryption": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "NodeTypeId": types.StringType, - "PolicyId": types.StringType, - "RuntimeEngine": types.StringType, - "SingleUserName": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkEnvVars": basetypes.MapType{ + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SparkVersion": types.StringType, - "SshPublicKeys": basetypes.ListType{ + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "WorkloadType": WorkloadType{}.ToAttrType(ctx), + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.ToAttrType(ctx), + }, }, } } @@ -759,16 +773,16 @@ func (newState *ClusterCompliance) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterCompliance) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.StringType), } } func (a ClusterCompliance) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "IsCompliant": types.BoolType, - "Violations": basetypes.MapType{ + "cluster_id": types.StringType, + "is_compliant": types.BoolType, + "violations": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -999,89 +1013,111 @@ func (newState *ClusterDetails) SyncEffectiveFieldsDuringRead(existingState Clus func (a ClusterDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), - "AwsAttributes": reflect.TypeOf(AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(AzureAttributes{}), - "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "ClusterLogStatus": reflect.TypeOf(LogSyncStatus{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DefaultTags": reflect.TypeOf(types.StringType), - "DockerImage": reflect.TypeOf(DockerImage{}), - "Driver": reflect.TypeOf(SparkNode{}), - "Executors": reflect.TypeOf(SparkNode{}), - "GcpAttributes": reflect.TypeOf(GcpAttributes{}), - "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "Spec": reflect.TypeOf(ClusterSpec{}), - "SshPublicKeys": reflect.TypeOf(types.StringType), - "TerminationReason": reflect.TypeOf(TerminationReason{}), - "WorkloadType": reflect.TypeOf(WorkloadType{}), + "autoscale": reflect.TypeOf(AutoScale{}), + "aws_attributes": reflect.TypeOf(AwsAttributes{}), + "azure_attributes": reflect.TypeOf(AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), + "cluster_log_status": reflect.TypeOf(LogSyncStatus{}), + "custom_tags": reflect.TypeOf(types.StringType), + "default_tags": reflect.TypeOf(types.StringType), + "docker_image": reflect.TypeOf(DockerImage{}), + "driver": reflect.TypeOf(SparkNode{}), + "executors": reflect.TypeOf(SparkNode{}), + "gcp_attributes": reflect.TypeOf(GcpAttributes{}), + "init_scripts": reflect.TypeOf(InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "spec": reflect.TypeOf(ClusterSpec{}), + "ssh_public_keys": reflect.TypeOf(types.StringType), + "termination_reason": reflect.TypeOf(TerminationReason{}), + "workload_type": reflect.TypeOf(WorkloadType{}), } } func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Autoscale": AutoScale{}.ToAttrType(ctx), - "AutoterminationMinutes": types.Int64Type, - "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), - "ClusterCores": types.Float64Type, - "ClusterId": types.StringType, - "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), - "ClusterLogStatus": LogSyncStatus{}.ToAttrType(ctx), - "ClusterMemoryMb": types.Int64Type, - "ClusterName": types.StringType, - "ClusterSource": types.StringType, - "CreatorUserName": types.StringType, - "CustomTags": basetypes.MapType{ + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.ToAttrType(ctx), + }, + "cluster_cores": types.Float64Type, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.ToAttrType(ctx), + }, + "cluster_log_status": basetypes.ListType{ + ElemType: LogSyncStatus{}.ToAttrType(ctx), + }, + "cluster_memory_mb": types.Int64Type, + "cluster_name": types.StringType, + "cluster_source": types.StringType, + "creator_user_name": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DataSecurityMode": types.StringType, - "DefaultTags": basetypes.MapType{ + "data_security_mode": types.StringType, + "default_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DockerImage": DockerImage{}.ToAttrType(ctx), - "Driver": SparkNode{}.ToAttrType(ctx), - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableElasticDisk": types.BoolType, - "EnableLocalDiskEncryption": types.BoolType, - "Executors": basetypes.ListType{ + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "driver": basetypes.ListType{ + ElemType: SparkNode{}.ToAttrType(ctx), + }, + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_elastic_disk": types.BoolType, + "enable_local_disk_encryption": types.BoolType, + "executors": basetypes.ListType{ ElemType: SparkNode{}.ToAttrType(ctx), }, - "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "JdbcPort": types.Int64Type, - "LastRestartedTime": types.Int64Type, - "LastStateLossTime": types.Int64Type, - "NodeTypeId": types.StringType, - "NumWorkers": types.Int64Type, - "PolicyId": types.StringType, - "RuntimeEngine": types.StringType, - "SingleUserName": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "jdbc_port": types.Int64Type, + "last_restarted_time": types.Int64Type, + "last_state_loss_time": types.Int64Type, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkContextId": types.Int64Type, - "SparkEnvVars": basetypes.MapType{ + "spark_context_id": types.Int64Type, + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SparkVersion": types.StringType, - "Spec": ClusterSpec{}.ToAttrType(ctx), - "SshPublicKeys": basetypes.ListType{ + "spark_version": types.StringType, + "spec": basetypes.ListType{ + ElemType: ClusterSpec{}.ToAttrType(ctx), + }, + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "StartTime": types.Int64Type, - "State": types.StringType, - "StateMessage": types.StringType, - "TerminatedTime": types.Int64Type, - "TerminationReason": TerminationReason{}.ToAttrType(ctx), - "WorkloadType": WorkloadType{}.ToAttrType(ctx), + "start_time": types.Int64Type, + "state": types.StringType, + "state_message": types.StringType, + "terminated_time": types.Int64Type, + "termination_reason": basetypes.ListType{ + ElemType: TerminationReason{}.ToAttrType(ctx), + }, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.ToAttrType(ctx), + }, }, } } @@ -1109,19 +1145,23 @@ func (newState *ClusterEvent) SyncEffectiveFieldsDuringRead(existingState Cluste func (a ClusterEvent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataPlaneEventDetails": reflect.TypeOf(DataPlaneEventDetails{}), - "Details": reflect.TypeOf(EventDetails{}), + "data_plane_event_details": reflect.TypeOf(DataPlaneEventDetails{}), + "details": reflect.TypeOf(EventDetails{}), } } func (a ClusterEvent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "DataPlaneEventDetails": DataPlaneEventDetails{}.ToAttrType(ctx), - "Details": EventDetails{}.ToAttrType(ctx), - "Timestamp": types.Int64Type, - "Type": types.StringType, + "cluster_id": types.StringType, + "data_plane_event_details": basetypes.ListType{ + ElemType: DataPlaneEventDetails{}.ToAttrType(ctx), + }, + "details": basetypes.ListType{ + ElemType: EventDetails{}.ToAttrType(ctx), + }, + "timestamp": types.Int64Type, + "type": types.StringType, }, } } @@ -1141,15 +1181,15 @@ func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringRead(existingSt func (a ClusterLibraryStatuses) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LibraryStatuses": reflect.TypeOf(LibraryFullStatus{}), + "library_statuses": reflect.TypeOf(LibraryFullStatus{}), } } func (a ClusterLibraryStatuses) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "LibraryStatuses": basetypes.ListType{ + "cluster_id": types.StringType, + "library_statuses": basetypes.ListType{ ElemType: LibraryFullStatus{}.ToAttrType(ctx), }, }, @@ -1176,16 +1216,20 @@ func (newState *ClusterLogConf) SyncEffectiveFieldsDuringRead(existingState Clus func (a ClusterLogConf) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dbfs": reflect.TypeOf(DbfsStorageInfo{}), - "S3": reflect.TypeOf(S3StorageInfo{}), + "dbfs": reflect.TypeOf(DbfsStorageInfo{}), + "s3": reflect.TypeOf(S3StorageInfo{}), } } func (a ClusterLogConf) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Dbfs": DbfsStorageInfo{}.ToAttrType(ctx), - "S3": S3StorageInfo{}.ToAttrType(ctx), + "dbfs": basetypes.ListType{ + ElemType: DbfsStorageInfo{}.ToAttrType(ctx), + }, + "s3": basetypes.ListType{ + ElemType: S3StorageInfo{}.ToAttrType(ctx), + }, }, } } @@ -1206,18 +1250,18 @@ func (newState *ClusterPermission) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a ClusterPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1238,18 +1282,18 @@ func (newState *ClusterPermissions) SyncEffectiveFieldsDuringRead(existingState func (a ClusterPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ClusterAccessControlResponse{}), + "access_control_list": reflect.TypeOf(ClusterAccessControlResponse{}), } } func (a ClusterPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ClusterAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1273,8 +1317,8 @@ func (a ClusterPermissionsDescription) GetComplexFieldTypes() map[string]reflect func (a ClusterPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1293,17 +1337,17 @@ func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existin func (a ClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ClusterAccessControlRequest{}), + "access_control_list": reflect.TypeOf(ClusterAccessControlRequest{}), } } func (a ClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ClusterAccessControlRequest{}.ToAttrType(ctx), }, - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -1332,10 +1376,10 @@ func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes() map[string]ref func (a ClusterPolicyAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1361,20 +1405,20 @@ func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringRea func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(ClusterPolicyPermission{}), + "all_permissions": reflect.TypeOf(ClusterPolicyPermission{}), } } func (a ClusterPolicyAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: ClusterPolicyPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1395,18 +1439,18 @@ func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringRead(existingS func (a ClusterPolicyPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a ClusterPolicyPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1427,18 +1471,18 @@ func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringRead(existing func (a ClusterPolicyPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ClusterPolicyAccessControlResponse{}), + "access_control_list": reflect.TypeOf(ClusterPolicyAccessControlResponse{}), } } func (a ClusterPolicyPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ClusterPolicyAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1462,8 +1506,8 @@ func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes() map[string]r func (a ClusterPolicyPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1482,17 +1526,17 @@ func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(e func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ClusterPolicyAccessControlRequest{}), + "access_control_list": reflect.TypeOf(ClusterPolicyAccessControlRequest{}), } } func (a ClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ClusterPolicyAccessControlRequest{}.ToAttrType(ctx), }, - "ClusterPolicyId": types.StringType, + "cluster_policy_id": types.StringType, }, } } @@ -1527,9 +1571,9 @@ func (a ClusterSettingsChange) GetComplexFieldTypes() map[string]reflect.Type { func (a ClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Field": types.StringType, - "NewValue": types.StringType, - "PreviousValue": types.StringType, + "field": types.StringType, + "new_value": types.StringType, + "previous_value": types.StringType, }, } } @@ -1560,15 +1604,17 @@ func (newState *ClusterSize) SyncEffectiveFieldsDuringRead(existingState Cluster func (a ClusterSize) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), + "autoscale": reflect.TypeOf(AutoScale{}), } } func (a ClusterSize) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Autoscale": AutoScale{}.ToAttrType(ctx), - "NumWorkers": types.Int64Type, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "num_workers": types.Int64Type, }, } } @@ -1733,61 +1779,75 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState Cluster func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), - "AwsAttributes": reflect.TypeOf(AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(AzureAttributes{}), - "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DockerImage": reflect.TypeOf(DockerImage{}), - "GcpAttributes": reflect.TypeOf(GcpAttributes{}), - "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "SshPublicKeys": reflect.TypeOf(types.StringType), - "WorkloadType": reflect.TypeOf(WorkloadType{}), + "autoscale": reflect.TypeOf(AutoScale{}), + "aws_attributes": reflect.TypeOf(AwsAttributes{}), + "azure_attributes": reflect.TypeOf(AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), + "custom_tags": reflect.TypeOf(types.StringType), + "docker_image": reflect.TypeOf(DockerImage{}), + "gcp_attributes": reflect.TypeOf(GcpAttributes{}), + "init_scripts": reflect.TypeOf(InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.StringType), + "workload_type": reflect.TypeOf(WorkloadType{}), } } func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyPolicyDefaultValues": types.BoolType, - "Autoscale": AutoScale{}.ToAttrType(ctx), - "AutoterminationMinutes": types.Int64Type, - "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), - "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), - "ClusterName": types.StringType, - "CustomTags": basetypes.MapType{ + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.ToAttrType(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.ToAttrType(ctx), + }, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DataSecurityMode": types.StringType, - "DockerImage": DockerImage{}.ToAttrType(ctx), - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableElasticDisk": types.BoolType, - "EnableLocalDiskEncryption": types.BoolType, - "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_elastic_disk": types.BoolType, + "enable_local_disk_encryption": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "NodeTypeId": types.StringType, - "NumWorkers": types.Int64Type, - "PolicyId": types.StringType, - "RuntimeEngine": types.StringType, - "SingleUserName": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkEnvVars": basetypes.MapType{ + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SparkVersion": types.StringType, - "SshPublicKeys": basetypes.ListType{ + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "WorkloadType": WorkloadType{}.ToAttrType(ctx), + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.ToAttrType(ctx), + }, }, } } @@ -1811,7 +1871,7 @@ func (a ClusterStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a ClusterStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -1840,10 +1900,10 @@ func (a Command) GetComplexFieldTypes() map[string]reflect.Type { func (a Command) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "Command": types.StringType, - "ContextId": types.StringType, - "Language": types.StringType, + "clusterId": types.StringType, + "command": types.StringType, + "contextId": types.StringType, + "language": types.StringType, }, } } @@ -1870,9 +1930,9 @@ func (a CommandStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a CommandStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "CommandId": types.StringType, - "ContextId": types.StringType, + "clusterId": types.StringType, + "commandId": types.StringType, + "contextId": types.StringType, }, } } @@ -1893,16 +1953,18 @@ func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringRead(existingSta func (a CommandStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(Results{}), + "results": reflect.TypeOf(Results{}), } } func (a CommandStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Results": Results{}.ToAttrType(ctx), - "Status": types.StringType, + "id": types.StringType, + "results": basetypes.ListType{ + ElemType: Results{}.ToAttrType(ctx), + }, + "status": types.StringType, }, } } @@ -1927,8 +1989,8 @@ func (a ContextStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ContextStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "ContextId": types.StringType, + "clusterId": types.StringType, + "contextId": types.StringType, }, } } @@ -1952,8 +2014,8 @@ func (a ContextStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a ContextStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Status": types.StringType, + "id": types.StringType, + "status": types.StringType, }, } } @@ -2121,63 +2183,79 @@ func (newState *CreateCluster) SyncEffectiveFieldsDuringRead(existingState Creat func (a CreateCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), - "AwsAttributes": reflect.TypeOf(AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(AzureAttributes{}), - "CloneFrom": reflect.TypeOf(CloneCluster{}), - "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DockerImage": reflect.TypeOf(DockerImage{}), - "GcpAttributes": reflect.TypeOf(GcpAttributes{}), - "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "SshPublicKeys": reflect.TypeOf(types.StringType), - "WorkloadType": reflect.TypeOf(WorkloadType{}), + "autoscale": reflect.TypeOf(AutoScale{}), + "aws_attributes": reflect.TypeOf(AwsAttributes{}), + "azure_attributes": reflect.TypeOf(AzureAttributes{}), + "clone_from": reflect.TypeOf(CloneCluster{}), + "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), + "custom_tags": reflect.TypeOf(types.StringType), + "docker_image": reflect.TypeOf(DockerImage{}), + "gcp_attributes": reflect.TypeOf(GcpAttributes{}), + "init_scripts": reflect.TypeOf(InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.StringType), + "workload_type": reflect.TypeOf(WorkloadType{}), } } func (a CreateCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyPolicyDefaultValues": types.BoolType, - "Autoscale": AutoScale{}.ToAttrType(ctx), - "AutoterminationMinutes": types.Int64Type, - "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), - "CloneFrom": CloneCluster{}.ToAttrType(ctx), - "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), - "ClusterName": types.StringType, - "CustomTags": basetypes.MapType{ + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.ToAttrType(ctx), + }, + "clone_from": basetypes.ListType{ + ElemType: CloneCluster{}.ToAttrType(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.ToAttrType(ctx), + }, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DataSecurityMode": types.StringType, - "DockerImage": DockerImage{}.ToAttrType(ctx), - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableElasticDisk": types.BoolType, - "EnableLocalDiskEncryption": types.BoolType, - "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_elastic_disk": types.BoolType, + "enable_local_disk_encryption": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "NodeTypeId": types.StringType, - "NumWorkers": types.Int64Type, - "PolicyId": types.StringType, - "RuntimeEngine": types.StringType, - "SingleUserName": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkEnvVars": basetypes.MapType{ + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SparkVersion": types.StringType, - "SshPublicKeys": basetypes.ListType{ + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "WorkloadType": WorkloadType{}.ToAttrType(ctx), + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.ToAttrType(ctx), + }, }, } } @@ -2199,7 +2277,7 @@ func (a CreateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -2224,8 +2302,8 @@ func (a CreateContext) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateContext) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "Language": types.StringType, + "clusterId": types.StringType, + "language": types.StringType, }, } } @@ -2295,36 +2373,44 @@ func (newState *CreateInstancePool) SyncEffectiveFieldsDuringRead(existingState func (a CreateInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), - "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DiskSpec": reflect.TypeOf(DiskSpec{}), - "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), - "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), - "PreloadedSparkVersions": reflect.TypeOf(types.StringType), + "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), + "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), + "custom_tags": reflect.TypeOf(types.StringType), + "disk_spec": reflect.TypeOf(DiskSpec{}), + "gcp_attributes": reflect.TypeOf(InstancePoolGcpAttributes{}), + "preloaded_docker_images": reflect.TypeOf(DockerImage{}), + "preloaded_spark_versions": reflect.TypeOf(types.StringType), } } func (a CreateInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsAttributes": InstancePoolAwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": InstancePoolAzureAttributes{}.ToAttrType(ctx), - "CustomTags": basetypes.MapType{ + "aws_attributes": basetypes.ListType{ + ElemType: InstancePoolAwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: InstancePoolAzureAttributes{}.ToAttrType(ctx), + }, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DiskSpec": DiskSpec{}.ToAttrType(ctx), - "EnableElasticDisk": types.BoolType, - "GcpAttributes": InstancePoolGcpAttributes{}.ToAttrType(ctx), - "IdleInstanceAutoterminationMinutes": types.Int64Type, - "InstancePoolName": types.StringType, - "MaxCapacity": types.Int64Type, - "MinIdleInstances": types.Int64Type, - "NodeTypeId": types.StringType, - "PreloadedDockerImages": basetypes.ListType{ + "disk_spec": basetypes.ListType{ + ElemType: DiskSpec{}.ToAttrType(ctx), + }, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: InstancePoolGcpAttributes{}.ToAttrType(ctx), + }, + "idle_instance_autotermination_minutes": types.Int64Type, + "instance_pool_name": types.StringType, + "max_capacity": types.Int64Type, + "min_idle_instances": types.Int64Type, + "node_type_id": types.StringType, + "preloaded_docker_images": basetypes.ListType{ ElemType: DockerImage{}.ToAttrType(ctx), }, - "PreloadedSparkVersions": basetypes.ListType{ + "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -2349,7 +2435,7 @@ func (a CreateInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Ty func (a CreateInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstancePoolId": types.StringType, + "instance_pool_id": types.StringType, }, } } @@ -2398,22 +2484,22 @@ func (newState *CreatePolicy) SyncEffectiveFieldsDuringRead(existingState Create func (a CreatePolicy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Libraries": reflect.TypeOf(Library{}), + "libraries": reflect.TypeOf(Library{}), } } func (a CreatePolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Definition": types.StringType, - "Description": types.StringType, - "Libraries": basetypes.ListType{ + "definition": types.StringType, + "description": types.StringType, + "libraries": basetypes.ListType{ ElemType: Library{}.ToAttrType(ctx), }, - "MaxClustersPerUser": types.Int64Type, - "Name": types.StringType, - "PolicyFamilyDefinitionOverrides": types.StringType, - "PolicyFamilyId": types.StringType, + "max_clusters_per_user": types.Int64Type, + "name": types.StringType, + "policy_family_definition_overrides": types.StringType, + "policy_family_id": types.StringType, }, } } @@ -2436,7 +2522,7 @@ func (a CreatePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreatePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PolicyId": types.StringType, + "policy_id": types.StringType, }, } } @@ -2459,7 +2545,7 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ScriptId": types.StringType, + "script_id": types.StringType, }, } } @@ -2481,7 +2567,7 @@ func (a Created) GetComplexFieldTypes() map[string]reflect.Type { func (a Created) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2510,10 +2596,10 @@ func (a DataPlaneEventDetails) GetComplexFieldTypes() map[string]reflect.Type { func (a DataPlaneEventDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EventType": types.StringType, - "ExecutorFailures": types.Int64Type, - "HostId": types.StringType, - "Timestamp": types.Int64Type, + "event_type": types.StringType, + "executor_failures": types.Int64Type, + "host_id": types.StringType, + "timestamp": types.Int64Type, }, } } @@ -2536,7 +2622,7 @@ func (a DbfsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a DbfsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Destination": types.StringType, + "destination": types.StringType, }, } } @@ -2559,7 +2645,7 @@ func (a DeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -2602,7 +2688,7 @@ func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect func (a DeleteGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ScriptId": types.StringType, + "script_id": types.StringType, }, } } @@ -2625,7 +2711,7 @@ func (a DeleteInstancePool) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstancePoolId": types.StringType, + "instance_pool_id": types.StringType, }, } } @@ -2667,7 +2753,7 @@ func (a DeletePolicy) GetComplexFieldTypes() map[string]reflect.Type { func (a DeletePolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PolicyId": types.StringType, + "policy_id": types.StringType, }, } } @@ -2729,8 +2815,8 @@ func (a DestroyContext) GetComplexFieldTypes() map[string]reflect.Type { func (a DestroyContext) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "ContextId": types.StringType, + "clusterId": types.StringType, + "contextId": types.StringType, }, } } @@ -2797,18 +2883,20 @@ func (newState *DiskSpec) SyncEffectiveFieldsDuringRead(existingState DiskSpec) func (a DiskSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DiskType": reflect.TypeOf(DiskType{}), + "disk_type": reflect.TypeOf(DiskType{}), } } func (a DiskSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DiskCount": types.Int64Type, - "DiskIops": types.Int64Type, - "DiskSize": types.Int64Type, - "DiskThroughput": types.Int64Type, - "DiskType": DiskType{}.ToAttrType(ctx), + "disk_count": types.Int64Type, + "disk_iops": types.Int64Type, + "disk_size": types.Int64Type, + "disk_throughput": types.Int64Type, + "disk_type": basetypes.ListType{ + ElemType: DiskType{}.ToAttrType(ctx), + }, }, } } @@ -2832,8 +2920,8 @@ func (a DiskType) GetComplexFieldTypes() map[string]reflect.Type { func (a DiskType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AzureDiskVolumeType": types.StringType, - "EbsVolumeType": types.StringType, + "azure_disk_volume_type": types.StringType, + "ebs_volume_type": types.StringType, }, } } @@ -2858,8 +2946,8 @@ func (a DockerBasicAuth) GetComplexFieldTypes() map[string]reflect.Type { func (a DockerBasicAuth) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Password": types.StringType, - "Username": types.StringType, + "password": types.StringType, + "username": types.StringType, }, } } @@ -2878,15 +2966,17 @@ func (newState *DockerImage) SyncEffectiveFieldsDuringRead(existingState DockerI func (a DockerImage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "BasicAuth": reflect.TypeOf(DockerBasicAuth{}), + "basic_auth": reflect.TypeOf(DockerBasicAuth{}), } } func (a DockerImage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BasicAuth": DockerBasicAuth{}.ToAttrType(ctx), - "Url": types.StringType, + "basic_auth": basetypes.ListType{ + ElemType: DockerBasicAuth{}.ToAttrType(ctx), + }, + "url": types.StringType, }, } } @@ -3053,62 +3143,76 @@ func (newState *EditCluster) SyncEffectiveFieldsDuringRead(existingState EditClu func (a EditCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), - "AwsAttributes": reflect.TypeOf(AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(AzureAttributes{}), - "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DockerImage": reflect.TypeOf(DockerImage{}), - "GcpAttributes": reflect.TypeOf(GcpAttributes{}), - "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "SshPublicKeys": reflect.TypeOf(types.StringType), - "WorkloadType": reflect.TypeOf(WorkloadType{}), + "autoscale": reflect.TypeOf(AutoScale{}), + "aws_attributes": reflect.TypeOf(AwsAttributes{}), + "azure_attributes": reflect.TypeOf(AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), + "custom_tags": reflect.TypeOf(types.StringType), + "docker_image": reflect.TypeOf(DockerImage{}), + "gcp_attributes": reflect.TypeOf(GcpAttributes{}), + "init_scripts": reflect.TypeOf(InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.StringType), + "workload_type": reflect.TypeOf(WorkloadType{}), } } func (a EditCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyPolicyDefaultValues": types.BoolType, - "Autoscale": AutoScale{}.ToAttrType(ctx), - "AutoterminationMinutes": types.Int64Type, - "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), - "ClusterId": types.StringType, - "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), - "ClusterName": types.StringType, - "CustomTags": basetypes.MapType{ + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.ToAttrType(ctx), + }, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.ToAttrType(ctx), + }, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DataSecurityMode": types.StringType, - "DockerImage": DockerImage{}.ToAttrType(ctx), - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableElasticDisk": types.BoolType, - "EnableLocalDiskEncryption": types.BoolType, - "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_elastic_disk": types.BoolType, + "enable_local_disk_encryption": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "NodeTypeId": types.StringType, - "NumWorkers": types.Int64Type, - "PolicyId": types.StringType, - "RuntimeEngine": types.StringType, - "SingleUserName": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkEnvVars": basetypes.MapType{ + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SparkVersion": types.StringType, - "SshPublicKeys": basetypes.ListType{ + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "WorkloadType": WorkloadType{}.ToAttrType(ctx), + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.ToAttrType(ctx), + }, }, } } @@ -3174,22 +3278,22 @@ func (newState *EditInstancePool) SyncEffectiveFieldsDuringRead(existingState Ed func (a EditInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomTags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.StringType), } } func (a EditInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CustomTags": basetypes.MapType{ + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "IdleInstanceAutoterminationMinutes": types.Int64Type, - "InstancePoolId": types.StringType, - "InstancePoolName": types.StringType, - "MaxCapacity": types.Int64Type, - "MinIdleInstances": types.Int64Type, - "NodeTypeId": types.StringType, + "idle_instance_autotermination_minutes": types.Int64Type, + "instance_pool_id": types.StringType, + "instance_pool_name": types.StringType, + "max_capacity": types.Int64Type, + "min_idle_instances": types.Int64Type, + "node_type_id": types.StringType, }, } } @@ -3259,23 +3363,23 @@ func (newState *EditPolicy) SyncEffectiveFieldsDuringRead(existingState EditPoli func (a EditPolicy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Libraries": reflect.TypeOf(Library{}), + "libraries": reflect.TypeOf(Library{}), } } func (a EditPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Definition": types.StringType, - "Description": types.StringType, - "Libraries": basetypes.ListType{ + "definition": types.StringType, + "description": types.StringType, + "libraries": basetypes.ListType{ ElemType: Library{}.ToAttrType(ctx), }, - "MaxClustersPerUser": types.Int64Type, - "Name": types.StringType, - "PolicyFamilyDefinitionOverrides": types.StringType, - "PolicyFamilyId": types.StringType, - "PolicyId": types.StringType, + "max_clusters_per_user": types.Int64Type, + "name": types.StringType, + "policy_family_definition_overrides": types.StringType, + "policy_family_id": types.StringType, + "policy_id": types.StringType, }, } } @@ -3339,8 +3443,8 @@ func (a EnforceClusterComplianceRequest) GetComplexFieldTypes() map[string]refle func (a EnforceClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "ValidateOnly": types.BoolType, + "cluster_id": types.StringType, + "validate_only": types.BoolType, }, } } @@ -3362,17 +3466,17 @@ func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringRead( func (a EnforceClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Changes": reflect.TypeOf(ClusterSettingsChange{}), + "changes": reflect.TypeOf(ClusterSettingsChange{}), } } func (a EnforceClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Changes": basetypes.ListType{ + "changes": basetypes.ListType{ ElemType: ClusterSettingsChange{}.ToAttrType(ctx), }, - "HasChanges": types.BoolType, + "has_changes": types.BoolType, }, } } @@ -3403,15 +3507,15 @@ func (newState *Environment) SyncEffectiveFieldsDuringRead(existingState Environ func (a Environment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dependencies": reflect.TypeOf(types.StringType), + "dependencies": reflect.TypeOf(types.StringType), } } func (a Environment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Client": types.StringType, - "Dependencies": basetypes.ListType{ + "client": types.StringType, + "dependencies": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3477,38 +3581,50 @@ func (newState *EventDetails) SyncEffectiveFieldsDuringRead(existingState EventD func (a EventDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Attributes": reflect.TypeOf(ClusterAttributes{}), - "ClusterSize": reflect.TypeOf(ClusterSize{}), - "InitScripts": reflect.TypeOf(InitScriptEventDetails{}), - "PreviousAttributes": reflect.TypeOf(ClusterAttributes{}), - "PreviousClusterSize": reflect.TypeOf(ClusterSize{}), - "Reason": reflect.TypeOf(TerminationReason{}), + "attributes": reflect.TypeOf(ClusterAttributes{}), + "cluster_size": reflect.TypeOf(ClusterSize{}), + "init_scripts": reflect.TypeOf(InitScriptEventDetails{}), + "previous_attributes": reflect.TypeOf(ClusterAttributes{}), + "previous_cluster_size": reflect.TypeOf(ClusterSize{}), + "reason": reflect.TypeOf(TerminationReason{}), } } func (a EventDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": ClusterAttributes{}.ToAttrType(ctx), - "Cause": types.StringType, - "ClusterSize": ClusterSize{}.ToAttrType(ctx), - "CurrentNumVcpus": types.Int64Type, - "CurrentNumWorkers": types.Int64Type, - "DidNotExpandReason": types.StringType, - "DiskSize": types.Int64Type, - "DriverStateMessage": types.StringType, - "EnableTerminationForNodeBlocklisted": types.BoolType, - "FreeSpace": types.Int64Type, - "InitScripts": InitScriptEventDetails{}.ToAttrType(ctx), - "InstanceId": types.StringType, - "JobRunName": types.StringType, - "PreviousAttributes": ClusterAttributes{}.ToAttrType(ctx), - "PreviousClusterSize": ClusterSize{}.ToAttrType(ctx), - "PreviousDiskSize": types.Int64Type, - "Reason": TerminationReason{}.ToAttrType(ctx), - "TargetNumVcpus": types.Int64Type, - "TargetNumWorkers": types.Int64Type, - "User": types.StringType, + "attributes": basetypes.ListType{ + ElemType: ClusterAttributes{}.ToAttrType(ctx), + }, + "cause": types.StringType, + "cluster_size": basetypes.ListType{ + ElemType: ClusterSize{}.ToAttrType(ctx), + }, + "current_num_vcpus": types.Int64Type, + "current_num_workers": types.Int64Type, + "did_not_expand_reason": types.StringType, + "disk_size": types.Int64Type, + "driver_state_message": types.StringType, + "enable_termination_for_node_blocklisted": types.BoolType, + "free_space": types.Int64Type, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptEventDetails{}.ToAttrType(ctx), + }, + "instance_id": types.StringType, + "job_run_name": types.StringType, + "previous_attributes": basetypes.ListType{ + ElemType: ClusterAttributes{}.ToAttrType(ctx), + }, + "previous_cluster_size": basetypes.ListType{ + ElemType: ClusterSize{}.ToAttrType(ctx), + }, + "previous_disk_size": types.Int64Type, + "reason": basetypes.ListType{ + ElemType: TerminationReason{}.ToAttrType(ctx), + }, + "target_num_vcpus": types.Int64Type, + "target_num_workers": types.Int64Type, + "user": types.StringType, }, } } @@ -3560,12 +3676,12 @@ func (a GcpAttributes) GetComplexFieldTypes() map[string]reflect.Type { func (a GcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Availability": types.StringType, - "BootDiskSize": types.Int64Type, - "GoogleServiceAccount": types.StringType, - "LocalSsdCount": types.Int64Type, - "UsePreemptibleExecutors": types.BoolType, - "ZoneId": types.StringType, + "availability": types.StringType, + "boot_disk_size": types.Int64Type, + "google_service_account": types.StringType, + "local_ssd_count": types.Int64Type, + "use_preemptible_executors": types.BoolType, + "zone_id": types.StringType, }, } } @@ -3588,7 +3704,7 @@ func (a GcsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a GcsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Destination": types.StringType, + "destination": types.StringType, }, } } @@ -3612,7 +3728,7 @@ func (a GetClusterComplianceRequest) GetComplexFieldTypes() map[string]reflect.T func (a GetClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -3637,15 +3753,15 @@ func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringRead(exis func (a GetClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.StringType), } } func (a GetClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsCompliant": types.BoolType, - "Violations": basetypes.MapType{ + "is_compliant": types.BoolType, + "violations": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -3671,7 +3787,7 @@ func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes() map[string]ref func (a GetClusterPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -3689,14 +3805,14 @@ func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringRea func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(ClusterPermissionsDescription{}), + "permission_levels": reflect.TypeOf(ClusterPermissionsDescription{}), } } func (a GetClusterPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: ClusterPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -3722,7 +3838,7 @@ func (a GetClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect. func (a GetClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -3746,7 +3862,7 @@ func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes() map[stri func (a GetClusterPolicyPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterPolicyId": types.StringType, + "cluster_policy_id": types.StringType, }, } } @@ -3764,14 +3880,14 @@ func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDur func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(ClusterPolicyPermissionsDescription{}), + "permission_levels": reflect.TypeOf(ClusterPolicyPermissionsDescription{}), } } func (a GetClusterPolicyPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: ClusterPolicyPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -3797,7 +3913,7 @@ func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]re func (a GetClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterPolicyId": types.StringType, + "cluster_policy_id": types.StringType, }, } } @@ -3821,7 +3937,7 @@ func (a GetClusterPolicyRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetClusterPolicyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PolicyId": types.StringType, + "policy_id": types.StringType, }, } } @@ -3845,7 +3961,7 @@ func (a GetClusterRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetClusterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -3881,22 +3997,22 @@ func (newState *GetEvents) SyncEffectiveFieldsDuringRead(existingState GetEvents func (a GetEvents) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EventTypes": reflect.TypeOf(types.StringType), + "event_types": reflect.TypeOf(types.StringType), } } func (a GetEvents) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "EndTime": types.Int64Type, - "EventTypes": basetypes.ListType{ + "cluster_id": types.StringType, + "end_time": types.Int64Type, + "event_types": basetypes.ListType{ ElemType: types.StringType, }, - "Limit": types.Int64Type, - "Offset": types.Int64Type, - "Order": types.StringType, - "StartTime": types.Int64Type, + "limit": types.Int64Type, + "offset": types.Int64Type, + "order": types.StringType, + "start_time": types.Int64Type, }, } } @@ -3920,19 +4036,21 @@ func (newState *GetEventsResponse) SyncEffectiveFieldsDuringRead(existingState G func (a GetEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(ClusterEvent{}), - "NextPage": reflect.TypeOf(GetEvents{}), + "events": reflect.TypeOf(ClusterEvent{}), + "next_page": reflect.TypeOf(GetEvents{}), } } func (a GetEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Events": basetypes.ListType{ + "events": basetypes.ListType{ ElemType: ClusterEvent{}.ToAttrType(ctx), }, - "NextPage": GetEvents{}.ToAttrType(ctx), - "TotalCount": types.Int64Type, + "next_page": basetypes.ListType{ + ElemType: GetEvents{}.ToAttrType(ctx), + }, + "total_count": types.Int64Type, }, } } @@ -3956,7 +4074,7 @@ func (a GetGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ScriptId": types.StringType, + "script_id": types.StringType, }, } } @@ -4045,48 +4163,60 @@ func (newState *GetInstancePool) SyncEffectiveFieldsDuringRead(existingState Get func (a GetInstancePool) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), - "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DefaultTags": reflect.TypeOf(types.StringType), - "DiskSpec": reflect.TypeOf(DiskSpec{}), - "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), - "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), - "PreloadedSparkVersions": reflect.TypeOf(types.StringType), - "Stats": reflect.TypeOf(InstancePoolStats{}), - "Status": reflect.TypeOf(InstancePoolStatus{}), + "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), + "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), + "custom_tags": reflect.TypeOf(types.StringType), + "default_tags": reflect.TypeOf(types.StringType), + "disk_spec": reflect.TypeOf(DiskSpec{}), + "gcp_attributes": reflect.TypeOf(InstancePoolGcpAttributes{}), + "preloaded_docker_images": reflect.TypeOf(DockerImage{}), + "preloaded_spark_versions": reflect.TypeOf(types.StringType), + "stats": reflect.TypeOf(InstancePoolStats{}), + "status": reflect.TypeOf(InstancePoolStatus{}), } } func (a GetInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsAttributes": InstancePoolAwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": InstancePoolAzureAttributes{}.ToAttrType(ctx), - "CustomTags": basetypes.MapType{ + "aws_attributes": basetypes.ListType{ + ElemType: InstancePoolAwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: InstancePoolAzureAttributes{}.ToAttrType(ctx), + }, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DefaultTags": basetypes.MapType{ + "default_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DiskSpec": DiskSpec{}.ToAttrType(ctx), - "EnableElasticDisk": types.BoolType, - "GcpAttributes": InstancePoolGcpAttributes{}.ToAttrType(ctx), - "IdleInstanceAutoterminationMinutes": types.Int64Type, - "InstancePoolId": types.StringType, - "InstancePoolName": types.StringType, - "MaxCapacity": types.Int64Type, - "MinIdleInstances": types.Int64Type, - "NodeTypeId": types.StringType, - "PreloadedDockerImages": basetypes.ListType{ + "disk_spec": basetypes.ListType{ + ElemType: DiskSpec{}.ToAttrType(ctx), + }, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: InstancePoolGcpAttributes{}.ToAttrType(ctx), + }, + "idle_instance_autotermination_minutes": types.Int64Type, + "instance_pool_id": types.StringType, + "instance_pool_name": types.StringType, + "max_capacity": types.Int64Type, + "min_idle_instances": types.Int64Type, + "node_type_id": types.StringType, + "preloaded_docker_images": basetypes.ListType{ ElemType: DockerImage{}.ToAttrType(ctx), }, - "PreloadedSparkVersions": basetypes.ListType{ + "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, - "State": types.StringType, - "Stats": InstancePoolStats{}.ToAttrType(ctx), - "Status": InstancePoolStatus{}.ToAttrType(ctx), + "state": types.StringType, + "stats": basetypes.ListType{ + ElemType: InstancePoolStats{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: InstancePoolStatus{}.ToAttrType(ctx), + }, }, } } @@ -4110,7 +4240,7 @@ func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes() map[strin func (a GetInstancePoolPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstancePoolId": types.StringType, + "instance_pool_id": types.StringType, }, } } @@ -4128,14 +4258,14 @@ func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuri func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(InstancePoolPermissionsDescription{}), + "permission_levels": reflect.TypeOf(InstancePoolPermissionsDescription{}), } } func (a GetInstancePoolPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: InstancePoolPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -4161,7 +4291,7 @@ func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]ref func (a GetInstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstancePoolId": types.StringType, + "instance_pool_id": types.StringType, }, } } @@ -4185,7 +4315,7 @@ func (a GetInstancePoolRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetInstancePoolRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstancePoolId": types.StringType, + "instance_pool_id": types.StringType, }, } } @@ -4212,8 +4342,8 @@ func (a GetPolicyFamilyRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetPolicyFamilyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PolicyFamilyId": types.StringType, - "Version": types.Int64Type, + "policy_family_id": types.StringType, + "version": types.Int64Type, }, } } @@ -4231,14 +4361,14 @@ func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringRead(existing func (a GetSparkVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Versions": reflect.TypeOf(SparkVersion{}), + "versions": reflect.TypeOf(SparkVersion{}), } } func (a GetSparkVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Versions": basetypes.ListType{ + "versions": basetypes.ListType{ ElemType: SparkVersion{}.ToAttrType(ctx), }, }, @@ -4279,10 +4409,10 @@ func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes() map[string]reflect func (a GlobalInitScriptCreateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, - "Name": types.StringType, - "Position": types.Int64Type, - "Script": types.StringType, + "enabled": types.BoolType, + "name": types.StringType, + "position": types.Int64Type, + "script": types.StringType, }, } } @@ -4322,14 +4452,14 @@ func (a GlobalInitScriptDetails) GetComplexFieldTypes() map[string]reflect.Type func (a GlobalInitScriptDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "Enabled": types.BoolType, - "Name": types.StringType, - "Position": types.Int64Type, - "ScriptId": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "enabled": types.BoolType, + "name": types.StringType, + "position": types.Int64Type, + "script_id": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -4371,15 +4501,15 @@ func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes() map[string]re func (a GlobalInitScriptDetailsWithContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "Enabled": types.BoolType, - "Name": types.StringType, - "Position": types.Int64Type, - "Script": types.StringType, - "ScriptId": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "enabled": types.BoolType, + "name": types.StringType, + "position": types.Int64Type, + "script": types.StringType, + "script_id": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -4421,11 +4551,11 @@ func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes() map[string]reflect func (a GlobalInitScriptUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, - "Name": types.StringType, - "Position": types.Int64Type, - "Script": types.StringType, - "ScriptId": types.StringType, + "enabled": types.BoolType, + "name": types.StringType, + "position": types.Int64Type, + "script": types.StringType, + "script_id": types.StringType, }, } } @@ -4447,21 +4577,21 @@ func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringRead(existingSt func (a InitScriptEventDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Cluster": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), - "Global": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), + "cluster": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), + "global": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), } } func (a InitScriptEventDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cluster": basetypes.ListType{ + "cluster": basetypes.ListType{ ElemType: InitScriptInfoAndExecutionDetails{}.ToAttrType(ctx), }, - "Global": basetypes.ListType{ + "global": basetypes.ListType{ ElemType: InitScriptInfoAndExecutionDetails{}.ToAttrType(ctx), }, - "ReportedForNode": types.StringType, + "reported_for_node": types.StringType, }, } } @@ -4488,9 +4618,9 @@ func (a InitScriptExecutionDetails) GetComplexFieldTypes() map[string]reflect.Ty func (a InitScriptExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ErrorMessage": types.StringType, - "ExecutionDurationSeconds": types.Int64Type, - "Status": types.StringType, + "error_message": types.StringType, + "execution_duration_seconds": types.Int64Type, + "status": types.StringType, }, } } @@ -4531,26 +4661,40 @@ func (newState *InitScriptInfo) SyncEffectiveFieldsDuringRead(existingState Init func (a InitScriptInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Abfss": reflect.TypeOf(Adlsgen2Info{}), - "Dbfs": reflect.TypeOf(DbfsStorageInfo{}), - "File": reflect.TypeOf(LocalFileInfo{}), - "Gcs": reflect.TypeOf(GcsStorageInfo{}), - "S3": reflect.TypeOf(S3StorageInfo{}), - "Volumes": reflect.TypeOf(VolumesStorageInfo{}), - "Workspace": reflect.TypeOf(WorkspaceStorageInfo{}), + "abfss": reflect.TypeOf(Adlsgen2Info{}), + "dbfs": reflect.TypeOf(DbfsStorageInfo{}), + "file": reflect.TypeOf(LocalFileInfo{}), + "gcs": reflect.TypeOf(GcsStorageInfo{}), + "s3": reflect.TypeOf(S3StorageInfo{}), + "volumes": reflect.TypeOf(VolumesStorageInfo{}), + "workspace": reflect.TypeOf(WorkspaceStorageInfo{}), } } func (a InitScriptInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Abfss": Adlsgen2Info{}.ToAttrType(ctx), - "Dbfs": DbfsStorageInfo{}.ToAttrType(ctx), - "File": LocalFileInfo{}.ToAttrType(ctx), - "Gcs": GcsStorageInfo{}.ToAttrType(ctx), - "S3": S3StorageInfo{}.ToAttrType(ctx), - "Volumes": VolumesStorageInfo{}.ToAttrType(ctx), - "Workspace": WorkspaceStorageInfo{}.ToAttrType(ctx), + "abfss": basetypes.ListType{ + ElemType: Adlsgen2Info{}.ToAttrType(ctx), + }, + "dbfs": basetypes.ListType{ + ElemType: DbfsStorageInfo{}.ToAttrType(ctx), + }, + "file": basetypes.ListType{ + ElemType: LocalFileInfo{}.ToAttrType(ctx), + }, + "gcs": basetypes.ListType{ + ElemType: GcsStorageInfo{}.ToAttrType(ctx), + }, + "s3": basetypes.ListType{ + ElemType: S3StorageInfo{}.ToAttrType(ctx), + }, + "volumes": basetypes.ListType{ + ElemType: VolumesStorageInfo{}.ToAttrType(ctx), + }, + "workspace": basetypes.ListType{ + ElemType: WorkspaceStorageInfo{}.ToAttrType(ctx), + }, }, } } @@ -4570,16 +4714,20 @@ func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringRead func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExecutionDetails": reflect.TypeOf(InitScriptExecutionDetails{}), - "Script": reflect.TypeOf(InitScriptInfo{}), + "execution_details": reflect.TypeOf(InitScriptExecutionDetails{}), + "script": reflect.TypeOf(InitScriptInfo{}), } } func (a InitScriptInfoAndExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExecutionDetails": InitScriptExecutionDetails{}.ToAttrType(ctx), - "Script": InitScriptInfo{}.ToAttrType(ctx), + "execution_details": basetypes.ListType{ + ElemType: InitScriptExecutionDetails{}.ToAttrType(ctx), + }, + "script": basetypes.ListType{ + ElemType: InitScriptInfo{}.ToAttrType(ctx), + }, }, } } @@ -4599,15 +4747,15 @@ func (newState *InstallLibraries) SyncEffectiveFieldsDuringRead(existingState In func (a InstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Libraries": reflect.TypeOf(Library{}), + "libraries": reflect.TypeOf(Library{}), } } func (a InstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "Libraries": basetypes.ListType{ + "cluster_id": types.StringType, + "libraries": basetypes.ListType{ ElemType: Library{}.ToAttrType(ctx), }, }, @@ -4657,10 +4805,10 @@ func (a InstancePoolAccessControlRequest) GetComplexFieldTypes() map[string]refl func (a InstancePoolAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -4686,20 +4834,20 @@ func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringRead func (a InstancePoolAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(InstancePoolPermission{}), + "all_permissions": reflect.TypeOf(InstancePoolPermission{}), } } func (a InstancePoolAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: InstancePoolPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -4788,48 +4936,60 @@ func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringRead(existingStat func (a InstancePoolAndStats) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsAttributes": reflect.TypeOf(InstancePoolAwsAttributes{}), - "AzureAttributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DefaultTags": reflect.TypeOf(types.StringType), - "DiskSpec": reflect.TypeOf(DiskSpec{}), - "GcpAttributes": reflect.TypeOf(InstancePoolGcpAttributes{}), - "PreloadedDockerImages": reflect.TypeOf(DockerImage{}), - "PreloadedSparkVersions": reflect.TypeOf(types.StringType), - "Stats": reflect.TypeOf(InstancePoolStats{}), - "Status": reflect.TypeOf(InstancePoolStatus{}), + "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), + "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), + "custom_tags": reflect.TypeOf(types.StringType), + "default_tags": reflect.TypeOf(types.StringType), + "disk_spec": reflect.TypeOf(DiskSpec{}), + "gcp_attributes": reflect.TypeOf(InstancePoolGcpAttributes{}), + "preloaded_docker_images": reflect.TypeOf(DockerImage{}), + "preloaded_spark_versions": reflect.TypeOf(types.StringType), + "stats": reflect.TypeOf(InstancePoolStats{}), + "status": reflect.TypeOf(InstancePoolStatus{}), } } func (a InstancePoolAndStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsAttributes": InstancePoolAwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": InstancePoolAzureAttributes{}.ToAttrType(ctx), - "CustomTags": basetypes.MapType{ + "aws_attributes": basetypes.ListType{ + ElemType: InstancePoolAwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: InstancePoolAzureAttributes{}.ToAttrType(ctx), + }, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DefaultTags": basetypes.MapType{ + "default_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DiskSpec": DiskSpec{}.ToAttrType(ctx), - "EnableElasticDisk": types.BoolType, - "GcpAttributes": InstancePoolGcpAttributes{}.ToAttrType(ctx), - "IdleInstanceAutoterminationMinutes": types.Int64Type, - "InstancePoolId": types.StringType, - "InstancePoolName": types.StringType, - "MaxCapacity": types.Int64Type, - "MinIdleInstances": types.Int64Type, - "NodeTypeId": types.StringType, - "PreloadedDockerImages": basetypes.ListType{ + "disk_spec": basetypes.ListType{ + ElemType: DiskSpec{}.ToAttrType(ctx), + }, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: InstancePoolGcpAttributes{}.ToAttrType(ctx), + }, + "idle_instance_autotermination_minutes": types.Int64Type, + "instance_pool_id": types.StringType, + "instance_pool_name": types.StringType, + "max_capacity": types.Int64Type, + "min_idle_instances": types.Int64Type, + "node_type_id": types.StringType, + "preloaded_docker_images": basetypes.ListType{ ElemType: DockerImage{}.ToAttrType(ctx), }, - "PreloadedSparkVersions": basetypes.ListType{ + "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, - "State": types.StringType, - "Stats": InstancePoolStats{}.ToAttrType(ctx), - "Status": InstancePoolStatus{}.ToAttrType(ctx), + "state": types.StringType, + "stats": basetypes.ListType{ + ElemType: InstancePoolStats{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: InstancePoolStatus{}.ToAttrType(ctx), + }, }, } } @@ -4879,9 +5039,9 @@ func (a InstancePoolAwsAttributes) GetComplexFieldTypes() map[string]reflect.Typ func (a InstancePoolAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Availability": types.StringType, - "SpotBidPricePercent": types.Int64Type, - "ZoneId": types.StringType, + "availability": types.StringType, + "spot_bid_price_percent": types.Int64Type, + "zone_id": types.StringType, }, } } @@ -4910,8 +5070,8 @@ func (a InstancePoolAzureAttributes) GetComplexFieldTypes() map[string]reflect.T func (a InstancePoolAzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Availability": types.StringType, - "SpotBidMaxPrice": types.Float64Type, + "availability": types.StringType, + "spot_bid_max_price": types.Float64Type, }, } } @@ -4960,9 +5120,9 @@ func (a InstancePoolGcpAttributes) GetComplexFieldTypes() map[string]reflect.Typ func (a InstancePoolGcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GcpAvailability": types.StringType, - "LocalSsdCount": types.Int64Type, - "ZoneId": types.StringType, + "gcp_availability": types.StringType, + "local_ssd_count": types.Int64Type, + "zone_id": types.StringType, }, } } @@ -4983,18 +5143,18 @@ func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringRead(existingSt func (a InstancePoolPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a InstancePoolPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -5015,18 +5175,18 @@ func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringRead(existingS func (a InstancePoolPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(InstancePoolAccessControlResponse{}), + "access_control_list": reflect.TypeOf(InstancePoolAccessControlResponse{}), } } func (a InstancePoolPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: InstancePoolAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -5050,8 +5210,8 @@ func (a InstancePoolPermissionsDescription) GetComplexFieldTypes() map[string]re func (a InstancePoolPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -5070,17 +5230,17 @@ func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(ex func (a InstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(InstancePoolAccessControlRequest{}), + "access_control_list": reflect.TypeOf(InstancePoolAccessControlRequest{}), } } func (a InstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: InstancePoolAccessControlRequest{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, + "instance_pool_id": types.StringType, }, } } @@ -5109,10 +5269,10 @@ func (a InstancePoolStats) GetComplexFieldTypes() map[string]reflect.Type { func (a InstancePoolStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IdleCount": types.Int64Type, - "PendingIdleCount": types.Int64Type, - "PendingUsedCount": types.Int64Type, - "UsedCount": types.Int64Type, + "idle_count": types.Int64Type, + "pending_idle_count": types.Int64Type, + "pending_used_count": types.Int64Type, + "used_count": types.Int64Type, }, } } @@ -5133,14 +5293,14 @@ func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringRead(existingState func (a InstancePoolStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PendingInstanceErrors": reflect.TypeOf(PendingInstanceError{}), + "pending_instance_errors": reflect.TypeOf(PendingInstanceError{}), } } func (a InstancePoolStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PendingInstanceErrors": basetypes.ListType{ + "pending_instance_errors": basetypes.ListType{ ElemType: PendingInstanceError{}.ToAttrType(ctx), }, }, @@ -5181,9 +5341,9 @@ func (a InstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { func (a InstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IamRoleArn": types.StringType, - "InstanceProfileArn": types.StringType, - "IsMetaInstanceProfile": types.BoolType, + "iam_role_arn": types.StringType, + "instance_profile_arn": types.StringType, + "is_meta_instance_profile": types.BoolType, }, } } @@ -5232,22 +5392,28 @@ func (newState *Library) SyncEffectiveFieldsDuringRead(existingState Library) { func (a Library) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Cran": reflect.TypeOf(RCranLibrary{}), - "Maven": reflect.TypeOf(MavenLibrary{}), - "Pypi": reflect.TypeOf(PythonPyPiLibrary{}), + "cran": reflect.TypeOf(RCranLibrary{}), + "maven": reflect.TypeOf(MavenLibrary{}), + "pypi": reflect.TypeOf(PythonPyPiLibrary{}), } } func (a Library) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cran": RCranLibrary{}.ToAttrType(ctx), - "Egg": types.StringType, - "Jar": types.StringType, - "Maven": MavenLibrary{}.ToAttrType(ctx), - "Pypi": PythonPyPiLibrary{}.ToAttrType(ctx), - "Requirements": types.StringType, - "Whl": types.StringType, + "cran": basetypes.ListType{ + ElemType: RCranLibrary{}.ToAttrType(ctx), + }, + "egg": types.StringType, + "jar": types.StringType, + "maven": basetypes.ListType{ + ElemType: MavenLibrary{}.ToAttrType(ctx), + }, + "pypi": basetypes.ListType{ + ElemType: PythonPyPiLibrary{}.ToAttrType(ctx), + }, + "requirements": types.StringType, + "whl": types.StringType, }, } } @@ -5274,20 +5440,22 @@ func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringRead(existingState L func (a LibraryFullStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Library": reflect.TypeOf(Library{}), - "Messages": reflect.TypeOf(types.StringType), + "library": reflect.TypeOf(Library{}), + "messages": reflect.TypeOf(types.StringType), } } func (a LibraryFullStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsLibraryForAllClusters": types.BoolType, - "Library": Library{}.ToAttrType(ctx), - "Messages": basetypes.ListType{ + "is_library_for_all_clusters": types.BoolType, + "library": basetypes.ListType{ + ElemType: Library{}.ToAttrType(ctx), + }, + "messages": basetypes.ListType{ ElemType: types.StringType, }, - "Status": types.StringType, + "status": types.StringType, }, } } @@ -5305,14 +5473,14 @@ func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuring func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Statuses": reflect.TypeOf(ClusterLibraryStatuses{}), + "statuses": reflect.TypeOf(ClusterLibraryStatuses{}), } } func (a ListAllClusterLibraryStatusesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Statuses": basetypes.ListType{ + "statuses": basetypes.ListType{ ElemType: ClusterLibraryStatuses{}.ToAttrType(ctx), }, }, @@ -5335,15 +5503,15 @@ func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringRead(existi func (a ListAvailableZonesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Zones": reflect.TypeOf(types.StringType), + "zones": reflect.TypeOf(types.StringType), } } func (a ListAvailableZonesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DefaultZone": types.StringType, - "Zones": basetypes.ListType{ + "default_zone": types.StringType, + "zones": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -5376,9 +5544,9 @@ func (a ListClusterCompliancesRequest) GetComplexFieldTypes() map[string]reflect func (a ListClusterCompliancesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "PolicyId": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, + "policy_id": types.StringType, }, } } @@ -5403,18 +5571,18 @@ func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringRead(ex func (a ListClusterCompliancesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Clusters": reflect.TypeOf(ClusterCompliance{}), + "clusters": reflect.TypeOf(ClusterCompliance{}), } } func (a ListClusterCompliancesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Clusters": basetypes.ListType{ + "clusters": basetypes.ListType{ ElemType: ClusterCompliance{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, + "next_page_token": types.StringType, + "prev_page_token": types.StringType, }, } } @@ -5443,8 +5611,8 @@ func (a ListClusterPoliciesRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a ListClusterPoliciesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "SortColumn": types.StringType, - "SortOrder": types.StringType, + "sort_column": types.StringType, + "sort_order": types.StringType, }, } } @@ -5468,22 +5636,22 @@ func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringRead(existingStat func (a ListClustersFilterBy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ClusterSources": reflect.TypeOf(types.StringType), - "ClusterStates": reflect.TypeOf(types.StringType), + "cluster_sources": reflect.TypeOf(types.StringType), + "cluster_states": reflect.TypeOf(types.StringType), } } func (a ListClustersFilterBy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterSources": basetypes.ListType{ + "cluster_sources": basetypes.ListType{ ElemType: types.StringType, }, - "ClusterStates": basetypes.ListType{ + "cluster_states": basetypes.ListType{ ElemType: types.StringType, }, - "IsPinned": types.BoolType, - "PolicyId": types.StringType, + "is_pinned": types.BoolType, + "policy_id": types.StringType, }, } } @@ -5511,18 +5679,22 @@ func (newState *ListClustersRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListClustersRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FilterBy": reflect.TypeOf(ListClustersFilterBy{}), - "SortBy": reflect.TypeOf(ListClustersSortBy{}), + "filter_by": reflect.TypeOf(ListClustersFilterBy{}), + "sort_by": reflect.TypeOf(ListClustersSortBy{}), } } func (a ListClustersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FilterBy": ListClustersFilterBy{}.ToAttrType(ctx), - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "SortBy": ListClustersSortBy{}.ToAttrType(ctx), + "filter_by": basetypes.ListType{ + ElemType: ListClustersFilterBy{}.ToAttrType(ctx), + }, + "page_size": types.Int64Type, + "page_token": types.StringType, + "sort_by": basetypes.ListType{ + ElemType: ListClustersSortBy{}.ToAttrType(ctx), + }, }, } } @@ -5547,18 +5719,18 @@ func (newState *ListClustersResponse) SyncEffectiveFieldsDuringRead(existingStat func (a ListClustersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Clusters": reflect.TypeOf(ClusterDetails{}), + "clusters": reflect.TypeOf(ClusterDetails{}), } } func (a ListClustersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Clusters": basetypes.ListType{ + "clusters": basetypes.ListType{ ElemType: ClusterDetails{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, + "next_page_token": types.StringType, + "prev_page_token": types.StringType, }, } } @@ -5585,8 +5757,8 @@ func (a ListClustersSortBy) GetComplexFieldTypes() map[string]reflect.Type { func (a ListClustersSortBy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Direction": types.StringType, - "Field": types.StringType, + "direction": types.StringType, + "field": types.StringType, }, } } @@ -5603,14 +5775,14 @@ func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringRead(exi func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Scripts": reflect.TypeOf(GlobalInitScriptDetails{}), + "scripts": reflect.TypeOf(GlobalInitScriptDetails{}), } } func (a ListGlobalInitScriptsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Scripts": basetypes.ListType{ + "scripts": basetypes.ListType{ ElemType: GlobalInitScriptDetails{}.ToAttrType(ctx), }, }, @@ -5629,14 +5801,14 @@ func (newState *ListInstancePools) SyncEffectiveFieldsDuringRead(existingState L func (a ListInstancePools) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InstancePools": reflect.TypeOf(InstancePoolAndStats{}), + "instance_pools": reflect.TypeOf(InstancePoolAndStats{}), } } func (a ListInstancePools) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstancePools": basetypes.ListType{ + "instance_pools": basetypes.ListType{ ElemType: InstancePoolAndStats{}.ToAttrType(ctx), }, }, @@ -5656,14 +5828,14 @@ func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringRead(exis func (a ListInstanceProfilesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InstanceProfiles": reflect.TypeOf(InstanceProfile{}), + "instance_profiles": reflect.TypeOf(InstanceProfile{}), } } func (a ListInstanceProfilesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstanceProfiles": basetypes.ListType{ + "instance_profiles": basetypes.ListType{ ElemType: InstanceProfile{}.ToAttrType(ctx), }, }, @@ -5683,14 +5855,14 @@ func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListNodeTypesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NodeTypes": reflect.TypeOf(NodeType{}), + "node_types": reflect.TypeOf(NodeType{}), } } func (a ListNodeTypesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NodeTypes": basetypes.ListType{ + "node_types": basetypes.ListType{ ElemType: NodeType{}.ToAttrType(ctx), }, }, @@ -5710,14 +5882,14 @@ func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringRead(existingStat func (a ListPoliciesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Policies": reflect.TypeOf(Policy{}), + "policies": reflect.TypeOf(Policy{}), } } func (a ListPoliciesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Policies": basetypes.ListType{ + "policies": basetypes.ListType{ ElemType: Policy{}.ToAttrType(ctx), }, }, @@ -5745,8 +5917,8 @@ func (a ListPolicyFamiliesRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a ListPolicyFamiliesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -5767,15 +5939,15 @@ func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringRead(existi func (a ListPolicyFamiliesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PolicyFamilies": reflect.TypeOf(PolicyFamily{}), + "policy_families": reflect.TypeOf(PolicyFamily{}), } } func (a ListPolicyFamiliesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "PolicyFamilies": basetypes.ListType{ + "next_page_token": types.StringType, + "policy_families": basetypes.ListType{ ElemType: PolicyFamily{}.ToAttrType(ctx), }, }, @@ -5800,7 +5972,7 @@ func (a LocalFileInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a LocalFileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Destination": types.StringType, + "destination": types.StringType, }, } } @@ -5825,8 +5997,8 @@ func (a LogAnalyticsInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a LogAnalyticsInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LogAnalyticsPrimaryKey": types.StringType, - "LogAnalyticsWorkspaceId": types.StringType, + "log_analytics_primary_key": types.StringType, + "log_analytics_workspace_id": types.StringType, }, } } @@ -5853,8 +6025,8 @@ func (a LogSyncStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a LogSyncStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LastAttempted": types.Int64Type, - "LastException": types.StringType, + "last_attempted": types.Int64Type, + "last_exception": types.StringType, }, } } @@ -5881,18 +6053,18 @@ func (newState *MavenLibrary) SyncEffectiveFieldsDuringRead(existingState MavenL func (a MavenLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exclusions": reflect.TypeOf(types.StringType), + "exclusions": reflect.TypeOf(types.StringType), } } func (a MavenLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Coordinates": types.StringType, - "Exclusions": basetypes.ListType{ + "coordinates": types.StringType, + "exclusions": basetypes.ListType{ ElemType: types.StringType, }, - "Repo": types.StringType, + "repo": types.StringType, }, } } @@ -5922,11 +6094,11 @@ func (a NodeInstanceType) GetComplexFieldTypes() map[string]reflect.Type { func (a NodeInstanceType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstanceTypeId": types.StringType, - "LocalDiskSizeGb": types.Int64Type, - "LocalDisks": types.Int64Type, - "LocalNvmeDiskSizeGb": types.Int64Type, - "LocalNvmeDisks": types.Int64Type, + "instance_type_id": types.StringType, + "local_disk_size_gb": types.Int64Type, + "local_disks": types.Int64Type, + "local_nvme_disk_size_gb": types.Int64Type, + "local_nvme_disks": types.Int64Type, }, } } @@ -5989,35 +6161,39 @@ func (newState *NodeType) SyncEffectiveFieldsDuringRead(existingState NodeType) func (a NodeType) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NodeInfo": reflect.TypeOf(CloudProviderNodeInfo{}), - "NodeInstanceType": reflect.TypeOf(NodeInstanceType{}), + "node_info": reflect.TypeOf(CloudProviderNodeInfo{}), + "node_instance_type": reflect.TypeOf(NodeInstanceType{}), } } func (a NodeType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Category": types.StringType, - "Description": types.StringType, - "DisplayOrder": types.Int64Type, - "InstanceTypeId": types.StringType, - "IsDeprecated": types.BoolType, - "IsEncryptedInTransit": types.BoolType, - "IsGraviton": types.BoolType, - "IsHidden": types.BoolType, - "IsIoCacheEnabled": types.BoolType, - "MemoryMb": types.Int64Type, - "NodeInfo": CloudProviderNodeInfo{}.ToAttrType(ctx), - "NodeInstanceType": NodeInstanceType{}.ToAttrType(ctx), - "NodeTypeId": types.StringType, - "NumCores": types.Float64Type, - "NumGpus": types.Int64Type, - "PhotonDriverCapable": types.BoolType, - "PhotonWorkerCapable": types.BoolType, - "SupportClusterTags": types.BoolType, - "SupportEbsVolumes": types.BoolType, - "SupportPortForwarding": types.BoolType, - "SupportsElasticDisk": types.BoolType, + "category": types.StringType, + "description": types.StringType, + "display_order": types.Int64Type, + "instance_type_id": types.StringType, + "is_deprecated": types.BoolType, + "is_encrypted_in_transit": types.BoolType, + "is_graviton": types.BoolType, + "is_hidden": types.BoolType, + "is_io_cache_enabled": types.BoolType, + "memory_mb": types.Int64Type, + "node_info": basetypes.ListType{ + ElemType: CloudProviderNodeInfo{}.ToAttrType(ctx), + }, + "node_instance_type": basetypes.ListType{ + ElemType: NodeInstanceType{}.ToAttrType(ctx), + }, + "node_type_id": types.StringType, + "num_cores": types.Float64Type, + "num_gpus": types.Int64Type, + "photon_driver_capable": types.BoolType, + "photon_worker_capable": types.BoolType, + "support_cluster_tags": types.BoolType, + "support_ebs_volumes": types.BoolType, + "support_port_forwarding": types.BoolType, + "supports_elastic_disk": types.BoolType, }, } } @@ -6041,8 +6217,8 @@ func (a PendingInstanceError) GetComplexFieldTypes() map[string]reflect.Type { func (a PendingInstanceError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstanceId": types.StringType, - "Message": types.StringType, + "instance_id": types.StringType, + "message": types.StringType, }, } } @@ -6065,7 +6241,7 @@ func (a PermanentDeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a PermanentDeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -6107,7 +6283,7 @@ func (a PinCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a PinCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -6188,26 +6364,26 @@ func (newState *Policy) SyncEffectiveFieldsDuringRead(existingState Policy) { func (a Policy) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Libraries": reflect.TypeOf(Library{}), + "libraries": reflect.TypeOf(Library{}), } } func (a Policy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAtTimestamp": types.Int64Type, - "CreatorUserName": types.StringType, - "Definition": types.StringType, - "Description": types.StringType, - "IsDefault": types.BoolType, - "Libraries": basetypes.ListType{ + "created_at_timestamp": types.Int64Type, + "creator_user_name": types.StringType, + "definition": types.StringType, + "description": types.StringType, + "is_default": types.BoolType, + "libraries": basetypes.ListType{ ElemType: Library{}.ToAttrType(ctx), }, - "MaxClustersPerUser": types.Int64Type, - "Name": types.StringType, - "PolicyFamilyDefinitionOverrides": types.StringType, - "PolicyFamilyId": types.StringType, - "PolicyId": types.StringType, + "max_clusters_per_user": types.Int64Type, + "name": types.StringType, + "policy_family_definition_overrides": types.StringType, + "policy_family_id": types.StringType, + "policy_id": types.StringType, }, } } @@ -6239,10 +6415,10 @@ func (a PolicyFamily) GetComplexFieldTypes() map[string]reflect.Type { func (a PolicyFamily) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Definition": types.StringType, - "Description": types.StringType, - "Name": types.StringType, - "PolicyFamilyId": types.StringType, + "definition": types.StringType, + "description": types.StringType, + "name": types.StringType, + "policy_family_id": types.StringType, }, } } @@ -6270,8 +6446,8 @@ func (a PythonPyPiLibrary) GetComplexFieldTypes() map[string]reflect.Type { func (a PythonPyPiLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Package": types.StringType, - "Repo": types.StringType, + "package": types.StringType, + "repo": types.StringType, }, } } @@ -6297,8 +6473,8 @@ func (a RCranLibrary) GetComplexFieldTypes() map[string]reflect.Type { func (a RCranLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Package": types.StringType, - "Repo": types.StringType, + "package": types.StringType, + "repo": types.StringType, }, } } @@ -6321,7 +6497,7 @@ func (a RemoveInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { func (a RemoveInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstanceProfileArn": types.StringType, + "instance_profile_arn": types.StringType, }, } } @@ -6373,16 +6549,18 @@ func (newState *ResizeCluster) SyncEffectiveFieldsDuringRead(existingState Resiz func (a ResizeCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), + "autoscale": reflect.TypeOf(AutoScale{}), } } func (a ResizeCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Autoscale": AutoScale{}.ToAttrType(ctx), - "ClusterId": types.StringType, - "NumWorkers": types.Int64Type, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "cluster_id": types.StringType, + "num_workers": types.Int64Type, }, } } @@ -6426,8 +6604,8 @@ func (a RestartCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a RestartCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "RestartUser": types.StringType, + "cluster_id": types.StringType, + "restart_user": types.StringType, }, } } @@ -6483,30 +6661,30 @@ func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { func (a Results) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileNames": reflect.TypeOf(types.StringType), - "Schema": reflect.TypeOf(struct{}{}), + "fileNames": reflect.TypeOf(types.StringType), + "schema": reflect.TypeOf(struct{}{}), } } func (a Results) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cause": types.StringType, - "Data": types.ObjectType{}, - "FileName": types.StringType, - "FileNames": basetypes.ListType{ + "cause": types.StringType, + "data": types.ObjectType{}, + "fileName": types.StringType, + "fileNames": basetypes.ListType{ ElemType: types.StringType, }, - "IsJsonSchema": types.BoolType, - "Pos": types.Int64Type, - "ResultType": types.StringType, - "Schema": basetypes.ListType{ + "isJsonSchema": types.BoolType, + "pos": types.Int64Type, + "resultType": types.StringType, + "schema": basetypes.ListType{ ElemType: basetypes.MapType{ ElemType: types.ObjectType{}, }, }, - "Summary": types.StringType, - "Truncated": types.BoolType, + "summary": types.StringType, + "truncated": types.BoolType, }, } } @@ -6557,13 +6735,13 @@ func (a S3StorageInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a S3StorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CannedAcl": types.StringType, - "Destination": types.StringType, - "EnableEncryption": types.BoolType, - "EncryptionType": types.StringType, - "Endpoint": types.StringType, - "KmsKey": types.StringType, - "Region": types.StringType, + "canned_acl": types.StringType, + "destination": types.StringType, + "enable_encryption": types.BoolType, + "encryption_type": types.StringType, + "endpoint": types.StringType, + "kms_key": types.StringType, + "region": types.StringType, }, } } @@ -6604,20 +6782,22 @@ func (newState *SparkNode) SyncEffectiveFieldsDuringRead(existingState SparkNode func (a SparkNode) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NodeAwsAttributes": reflect.TypeOf(SparkNodeAwsAttributes{}), + "node_aws_attributes": reflect.TypeOf(SparkNodeAwsAttributes{}), } } func (a SparkNode) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "HostPrivateIp": types.StringType, - "InstanceId": types.StringType, - "NodeAwsAttributes": SparkNodeAwsAttributes{}.ToAttrType(ctx), - "NodeId": types.StringType, - "PrivateIp": types.StringType, - "PublicDns": types.StringType, - "StartTimestamp": types.Int64Type, + "host_private_ip": types.StringType, + "instance_id": types.StringType, + "node_aws_attributes": basetypes.ListType{ + ElemType: SparkNodeAwsAttributes{}.ToAttrType(ctx), + }, + "node_id": types.StringType, + "private_ip": types.StringType, + "public_dns": types.StringType, + "start_timestamp": types.Int64Type, }, } } @@ -6640,7 +6820,7 @@ func (a SparkNodeAwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { func (a SparkNodeAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsSpot": types.BoolType, + "is_spot": types.BoolType, }, } } @@ -6669,8 +6849,8 @@ func (a SparkVersion) GetComplexFieldTypes() map[string]reflect.Type { func (a SparkVersion) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Name": types.StringType, + "key": types.StringType, + "name": types.StringType, }, } } @@ -6693,7 +6873,7 @@ func (a StartCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a StartCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -6735,18 +6915,18 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState T func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Code": types.StringType, - "Parameters": basetypes.MapType{ + "code": types.StringType, + "parameters": basetypes.MapType{ ElemType: types.StringType, }, - "Type": types.StringType, + "type": types.StringType, }, } } @@ -6766,15 +6946,15 @@ func (newState *UninstallLibraries) SyncEffectiveFieldsDuringRead(existingState func (a UninstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Libraries": reflect.TypeOf(Library{}), + "libraries": reflect.TypeOf(Library{}), } } func (a UninstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "Libraries": basetypes.ListType{ + "cluster_id": types.StringType, + "libraries": basetypes.ListType{ ElemType: Library{}.ToAttrType(ctx), }, }, @@ -6818,7 +6998,7 @@ func (a UnpinCluster) GetComplexFieldTypes() map[string]reflect.Type { func (a UnpinCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, + "cluster_id": types.StringType, }, } } @@ -6863,16 +7043,18 @@ func (newState *UpdateCluster) SyncEffectiveFieldsDuringRead(existingState Updat func (a UpdateCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Cluster": reflect.TypeOf(UpdateClusterResource{}), + "cluster": reflect.TypeOf(UpdateClusterResource{}), } } func (a UpdateCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cluster": UpdateClusterResource{}.ToAttrType(ctx), - "ClusterId": types.StringType, - "UpdateMask": types.StringType, + "cluster": basetypes.ListType{ + ElemType: UpdateClusterResource{}.ToAttrType(ctx), + }, + "cluster_id": types.StringType, + "update_mask": types.StringType, }, } } @@ -7033,60 +7215,74 @@ func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateClusterResource) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(AutoScale{}), - "AwsAttributes": reflect.TypeOf(AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(AzureAttributes{}), - "ClusterLogConf": reflect.TypeOf(ClusterLogConf{}), - "CustomTags": reflect.TypeOf(types.StringType), - "DockerImage": reflect.TypeOf(DockerImage{}), - "GcpAttributes": reflect.TypeOf(GcpAttributes{}), - "InitScripts": reflect.TypeOf(InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "SshPublicKeys": reflect.TypeOf(types.StringType), - "WorkloadType": reflect.TypeOf(WorkloadType{}), + "autoscale": reflect.TypeOf(AutoScale{}), + "aws_attributes": reflect.TypeOf(AwsAttributes{}), + "azure_attributes": reflect.TypeOf(AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), + "custom_tags": reflect.TypeOf(types.StringType), + "docker_image": reflect.TypeOf(DockerImage{}), + "gcp_attributes": reflect.TypeOf(GcpAttributes{}), + "init_scripts": reflect.TypeOf(InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.StringType), + "workload_type": reflect.TypeOf(WorkloadType{}), } } func (a UpdateClusterResource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Autoscale": AutoScale{}.ToAttrType(ctx), - "AutoterminationMinutes": types.Int64Type, - "AwsAttributes": AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": AzureAttributes{}.ToAttrType(ctx), - "ClusterLogConf": ClusterLogConf{}.ToAttrType(ctx), - "ClusterName": types.StringType, - "CustomTags": basetypes.MapType{ + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.ToAttrType(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.ToAttrType(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.ToAttrType(ctx), + }, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DataSecurityMode": types.StringType, - "DockerImage": DockerImage{}.ToAttrType(ctx), - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableElasticDisk": types.BoolType, - "EnableLocalDiskEncryption": types.BoolType, - "GcpAttributes": GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.ToAttrType(ctx), + }, + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_elastic_disk": types.BoolType, + "enable_local_disk_encryption": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "NodeTypeId": types.StringType, - "NumWorkers": types.Int64Type, - "PolicyId": types.StringType, - "RuntimeEngine": types.StringType, - "SingleUserName": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkEnvVars": basetypes.MapType{ + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SparkVersion": types.StringType, - "SshPublicKeys": basetypes.ListType{ + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "WorkloadType": WorkloadType{}.ToAttrType(ctx), + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.ToAttrType(ctx), + }, }, } } @@ -7147,7 +7343,7 @@ func (a VolumesStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a VolumesStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Destination": types.StringType, + "destination": types.StringType, }, } } @@ -7165,14 +7361,16 @@ func (newState *WorkloadType) SyncEffectiveFieldsDuringRead(existingState Worklo func (a WorkloadType) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Clients": reflect.TypeOf(ClientsTypes{}), + "clients": reflect.TypeOf(ClientsTypes{}), } } func (a WorkloadType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Clients": ClientsTypes{}.ToAttrType(ctx), + "clients": basetypes.ListType{ + ElemType: ClientsTypes{}.ToAttrType(ctx), + }, }, } } @@ -7196,7 +7394,7 @@ func (a WorkspaceStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a WorkspaceStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Destination": types.StringType, + "destination": types.StringType, }, } } diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index ecf1da7ce6..703ccb06f6 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -34,14 +34,16 @@ func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringRead(existingSt func (a CreateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dashboard": reflect.TypeOf(Dashboard{}), + "dashboard": reflect.TypeOf(Dashboard{}), } } func (a CreateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Dashboard": Dashboard{}.ToAttrType(ctx), + "dashboard": basetypes.ListType{ + ElemType: Dashboard{}.ToAttrType(ctx), + }, }, } } @@ -62,15 +64,17 @@ func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringRead(existingSta func (a CreateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Schedule": reflect.TypeOf(Schedule{}), + "schedule": reflect.TypeOf(Schedule{}), } } func (a CreateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Schedule": Schedule{}.ToAttrType(ctx), + "dashboard_id": types.StringType, + "schedule": basetypes.ListType{ + ElemType: Schedule{}.ToAttrType(ctx), + }, }, } } @@ -93,16 +97,18 @@ func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringRead(existin func (a CreateSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subscription": reflect.TypeOf(Subscription{}), + "subscription": reflect.TypeOf(Subscription{}), } } func (a CreateSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "ScheduleId": types.StringType, - "Subscription": Subscription{}.ToAttrType(ctx), + "dashboard_id": types.StringType, + "schedule_id": types.StringType, + "subscription": basetypes.ListType{ + ElemType: Subscription{}.ToAttrType(ctx), + }, }, } } @@ -133,8 +139,8 @@ func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QuartzCronExpression": types.StringType, - "TimezoneId": types.StringType, + "quartz_cron_expression": types.StringType, + "timezone_id": types.StringType, }, } } @@ -188,16 +194,16 @@ func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "DashboardId": types.StringType, - "DisplayName": types.StringType, - "Etag": types.StringType, - "LifecycleState": types.StringType, - "ParentPath": types.StringType, - "Path": types.StringType, - "SerializedDashboard": types.StringType, - "UpdateTime": types.StringType, - "WarehouseId": types.StringType, + "create_time": types.StringType, + "dashboard_id": types.StringType, + "display_name": types.StringType, + "etag": types.StringType, + "lifecycle_state": types.StringType, + "parent_path": types.StringType, + "path": types.StringType, + "serialized_dashboard": types.StringType, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -226,9 +232,9 @@ func (a DeleteScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Etag": types.StringType, - "ScheduleId": types.StringType, + "dashboard_id": types.StringType, + "etag": types.StringType, + "schedule_id": types.StringType, }, } } @@ -278,10 +284,10 @@ func (a DeleteSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Etag": types.StringType, - "ScheduleId": types.StringType, - "SubscriptionId": types.StringType, + "dashboard_id": types.StringType, + "etag": types.StringType, + "schedule_id": types.StringType, + "subscription_id": types.StringType, }, } } @@ -320,16 +326,20 @@ func (newState *GenieAttachment) SyncEffectiveFieldsDuringRead(existingState Gen func (a GenieAttachment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Query": reflect.TypeOf(QueryAttachment{}), - "Text": reflect.TypeOf(TextAttachment{}), + "query": reflect.TypeOf(QueryAttachment{}), + "text": reflect.TypeOf(TextAttachment{}), } } func (a GenieAttachment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Query": QueryAttachment{}.ToAttrType(ctx), - "Text": TextAttachment{}.ToAttrType(ctx), + "query": basetypes.ListType{ + ElemType: QueryAttachment{}.ToAttrType(ctx), + }, + "text": basetypes.ListType{ + ElemType: TextAttachment{}.ToAttrType(ctx), + }, }, } } @@ -362,12 +372,12 @@ func (a GenieConversation) GetComplexFieldTypes() map[string]reflect.Type { func (a GenieConversation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedTimestamp": types.Int64Type, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "SpaceId": types.StringType, - "Title": types.StringType, - "UserId": types.Int64Type, + "created_timestamp": types.Int64Type, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "space_id": types.StringType, + "title": types.StringType, + "user_id": types.Int64Type, }, } } @@ -394,9 +404,9 @@ func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes() map[string func (a GenieCreateConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "ConversationId": types.StringType, - "SpaceId": types.StringType, + "content": types.StringType, + "conversation_id": types.StringType, + "space_id": types.StringType, }, } } @@ -424,9 +434,9 @@ func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes() map[string]refle func (a GenieExecuteMessageQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConversationId": types.StringType, - "MessageId": types.StringType, - "SpaceId": types.StringType, + "conversation_id": types.StringType, + "message_id": types.StringType, + "space_id": types.StringType, }, } } @@ -456,9 +466,9 @@ func (a GenieGetConversationMessageRequest) GetComplexFieldTypes() map[string]re func (a GenieGetConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConversationId": types.StringType, - "MessageId": types.StringType, - "SpaceId": types.StringType, + "conversation_id": types.StringType, + "message_id": types.StringType, + "space_id": types.StringType, }, } } @@ -486,9 +496,9 @@ func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes() map[string]ref func (a GenieGetMessageQueryResultRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConversationId": types.StringType, - "MessageId": types.StringType, - "SpaceId": types.StringType, + "conversation_id": types.StringType, + "message_id": types.StringType, + "space_id": types.StringType, }, } } @@ -507,14 +517,16 @@ func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringRea func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "StatementResponse": reflect.TypeOf(sql.StatementResponse{}), + "statement_response": reflect.TypeOf(sql.StatementResponse{}), } } func (a GenieGetMessageQueryResultResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StatementResponse": sql_tf.StatementResponse{}.ToAttrType(ctx), + "statement_response": basetypes.ListType{ + ElemType: sql_tf.StatementResponse{}.ToAttrType(ctx), + }, }, } } @@ -567,28 +579,32 @@ func (newState *GenieMessage) SyncEffectiveFieldsDuringRead(existingState GenieM func (a GenieMessage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Attachments": reflect.TypeOf(GenieAttachment{}), - "Error": reflect.TypeOf(MessageError{}), - "QueryResult": reflect.TypeOf(Result{}), + "attachments": reflect.TypeOf(GenieAttachment{}), + "error": reflect.TypeOf(MessageError{}), + "query_result": reflect.TypeOf(Result{}), } } func (a GenieMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attachments": basetypes.ListType{ + "attachments": basetypes.ListType{ ElemType: GenieAttachment{}.ToAttrType(ctx), }, - "Content": types.StringType, - "ConversationId": types.StringType, - "CreatedTimestamp": types.Int64Type, - "Error": MessageError{}.ToAttrType(ctx), - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "QueryResult": Result{}.ToAttrType(ctx), - "SpaceId": types.StringType, - "Status": types.StringType, - "UserId": types.Int64Type, + "content": types.StringType, + "conversation_id": types.StringType, + "created_timestamp": types.Int64Type, + "error": basetypes.ListType{ + ElemType: MessageError{}.ToAttrType(ctx), + }, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "query_result": basetypes.ListType{ + ElemType: Result{}.ToAttrType(ctx), + }, + "space_id": types.StringType, + "status": types.StringType, + "user_id": types.Int64Type, }, } } @@ -614,8 +630,8 @@ func (a GenieStartConversationMessageRequest) GetComplexFieldTypes() map[string] func (a GenieStartConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "SpaceId": types.StringType, + "content": types.StringType, + "space_id": types.StringType, }, } } @@ -638,18 +654,22 @@ func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringRead(ex func (a GenieStartConversationResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Conversation": reflect.TypeOf(GenieConversation{}), - "Message": reflect.TypeOf(GenieMessage{}), + "conversation": reflect.TypeOf(GenieConversation{}), + "message": reflect.TypeOf(GenieMessage{}), } } func (a GenieStartConversationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Conversation": GenieConversation{}.ToAttrType(ctx), - "ConversationId": types.StringType, - "Message": GenieMessage{}.ToAttrType(ctx), - "MessageId": types.StringType, + "conversation": basetypes.ListType{ + ElemType: GenieConversation{}.ToAttrType(ctx), + }, + "conversation_id": types.StringType, + "message": basetypes.ListType{ + ElemType: GenieMessage{}.ToAttrType(ctx), + }, + "message_id": types.StringType, }, } } @@ -673,7 +693,7 @@ func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -697,7 +717,7 @@ func (a GetPublishedDashboardRequest) GetComplexFieldTypes() map[string]reflect. func (a GetPublishedDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -723,8 +743,8 @@ func (a GetScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "ScheduleId": types.StringType, + "dashboard_id": types.StringType, + "schedule_id": types.StringType, }, } } @@ -752,9 +772,9 @@ func (a GetSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "ScheduleId": types.StringType, - "SubscriptionId": types.StringType, + "dashboard_id": types.StringType, + "schedule_id": types.StringType, + "subscription_id": types.StringType, }, } } @@ -786,10 +806,10 @@ func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "ShowTrashed": types.BoolType, - "View": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, + "show_trashed": types.BoolType, + "view": types.StringType, }, } } @@ -809,17 +829,17 @@ func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringRead(existingSt func (a ListDashboardsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dashboards": reflect.TypeOf(Dashboard{}), + "dashboards": reflect.TypeOf(Dashboard{}), } } func (a ListDashboardsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Dashboards": basetypes.ListType{ + "dashboards": basetypes.ListType{ ElemType: Dashboard{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -848,9 +868,9 @@ func (a ListSchedulesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListSchedulesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "dashboard_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -872,15 +892,15 @@ func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListSchedulesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Schedules": reflect.TypeOf(Schedule{}), + "schedules": reflect.TypeOf(Schedule{}), } } func (a ListSchedulesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Schedules": basetypes.ListType{ + "next_page_token": types.StringType, + "schedules": basetypes.ListType{ ElemType: Schedule{}.ToAttrType(ctx), }, }, @@ -913,10 +933,10 @@ func (a ListSubscriptionsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListSubscriptionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "ScheduleId": types.StringType, + "dashboard_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, + "schedule_id": types.StringType, }, } } @@ -938,15 +958,15 @@ func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringRead(existin func (a ListSubscriptionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subscriptions": reflect.TypeOf(Subscription{}), + "subscriptions": reflect.TypeOf(Subscription{}), } } func (a ListSubscriptionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Subscriptions": basetypes.ListType{ + "next_page_token": types.StringType, + "subscriptions": basetypes.ListType{ ElemType: Subscription{}.ToAttrType(ctx), }, }, @@ -972,8 +992,8 @@ func (a MessageError) GetComplexFieldTypes() map[string]reflect.Type { func (a MessageError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Error": types.StringType, - "Type": types.StringType, + "error": types.StringType, + "type": types.StringType, }, } } @@ -1001,9 +1021,9 @@ func (a MigrateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type func (a MigrateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "ParentPath": types.StringType, - "SourceDashboardId": types.StringType, + "display_name": types.StringType, + "parent_path": types.StringType, + "source_dashboard_id": types.StringType, }, } } @@ -1033,9 +1053,9 @@ func (a PublishRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a PublishRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "EmbedCredentials": types.BoolType, - "WarehouseId": types.StringType, + "dashboard_id": types.StringType, + "embed_credentials": types.BoolType, + "warehouse_id": types.StringType, }, } } @@ -1064,10 +1084,10 @@ func (a PublishedDashboard) GetComplexFieldTypes() map[string]reflect.Type { func (a PublishedDashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "EmbedCredentials": types.BoolType, - "RevisionCreateTime": types.StringType, - "WarehouseId": types.StringType, + "display_name": types.StringType, + "embed_credentials": types.BoolType, + "revision_create_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -1104,13 +1124,13 @@ func (a QueryAttachment) GetComplexFieldTypes() map[string]reflect.Type { func (a QueryAttachment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Id": types.StringType, - "InstructionId": types.StringType, - "InstructionTitle": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "Query": types.StringType, - "Title": types.StringType, + "description": types.StringType, + "id": types.StringType, + "instruction_id": types.StringType, + "instruction_title": types.StringType, + "last_updated_timestamp": types.Int64Type, + "query": types.StringType, + "title": types.StringType, }, } } @@ -1139,9 +1159,9 @@ func (a Result) GetComplexFieldTypes() map[string]reflect.Type { func (a Result) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsTruncated": types.BoolType, - "RowCount": types.Int64Type, - "StatementId": types.StringType, + "is_truncated": types.BoolType, + "row_count": types.Int64Type, + "statement_id": types.StringType, }, } } @@ -1178,22 +1198,24 @@ func (newState *Schedule) SyncEffectiveFieldsDuringRead(existingState Schedule) func (a Schedule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CronSchedule": reflect.TypeOf(CronSchedule{}), + "cron_schedule": reflect.TypeOf(CronSchedule{}), } } func (a Schedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "CronSchedule": CronSchedule{}.ToAttrType(ctx), - "DashboardId": types.StringType, - "DisplayName": types.StringType, - "Etag": types.StringType, - "PauseStatus": types.StringType, - "ScheduleId": types.StringType, - "UpdateTime": types.StringType, - "WarehouseId": types.StringType, + "create_time": types.StringType, + "cron_schedule": basetypes.ListType{ + ElemType: CronSchedule{}.ToAttrType(ctx), + }, + "dashboard_id": types.StringType, + "display_name": types.StringType, + "etag": types.StringType, + "pause_status": types.StringType, + "schedule_id": types.StringType, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -1215,16 +1237,20 @@ func (newState *Subscriber) SyncEffectiveFieldsDuringRead(existingState Subscrib func (a Subscriber) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DestinationSubscriber": reflect.TypeOf(SubscriptionSubscriberDestination{}), - "UserSubscriber": reflect.TypeOf(SubscriptionSubscriberUser{}), + "destination_subscriber": reflect.TypeOf(SubscriptionSubscriberDestination{}), + "user_subscriber": reflect.TypeOf(SubscriptionSubscriberUser{}), } } func (a Subscriber) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationSubscriber": SubscriptionSubscriberDestination{}.ToAttrType(ctx), - "UserSubscriber": SubscriptionSubscriberUser{}.ToAttrType(ctx), + "destination_subscriber": basetypes.ListType{ + ElemType: SubscriptionSubscriberDestination{}.ToAttrType(ctx), + }, + "user_subscriber": basetypes.ListType{ + ElemType: SubscriptionSubscriberUser{}.ToAttrType(ctx), + }, }, } } @@ -1260,21 +1286,23 @@ func (newState *Subscription) SyncEffectiveFieldsDuringRead(existingState Subscr func (a Subscription) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subscriber": reflect.TypeOf(Subscriber{}), + "subscriber": reflect.TypeOf(Subscriber{}), } } func (a Subscription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "CreatedByUserId": types.Int64Type, - "DashboardId": types.StringType, - "Etag": types.StringType, - "ScheduleId": types.StringType, - "Subscriber": Subscriber{}.ToAttrType(ctx), - "SubscriptionId": types.StringType, - "UpdateTime": types.StringType, + "create_time": types.StringType, + "created_by_user_id": types.Int64Type, + "dashboard_id": types.StringType, + "etag": types.StringType, + "schedule_id": types.StringType, + "subscriber": basetypes.ListType{ + ElemType: Subscriber{}.ToAttrType(ctx), + }, + "subscription_id": types.StringType, + "update_time": types.StringType, }, } } @@ -1298,7 +1326,7 @@ func (a SubscriptionSubscriberDestination) GetComplexFieldTypes() map[string]ref func (a SubscriptionSubscriberDestination) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationId": types.StringType, + "destination_id": types.StringType, }, } } @@ -1321,7 +1349,7 @@ func (a SubscriptionSubscriberUser) GetComplexFieldTypes() map[string]reflect.Ty func (a SubscriptionSubscriberUser) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "UserId": types.Int64Type, + "user_id": types.Int64Type, }, } } @@ -1346,8 +1374,8 @@ func (a TextAttachment) GetComplexFieldTypes() map[string]reflect.Type { func (a TextAttachment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "Id": types.StringType, + "content": types.StringType, + "id": types.StringType, }, } } @@ -1371,7 +1399,7 @@ func (a TrashDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a TrashDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -1414,7 +1442,7 @@ func (a UnpublishDashboardRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a UnpublishDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -1453,15 +1481,17 @@ func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dashboard": reflect.TypeOf(Dashboard{}), + "dashboard": reflect.TypeOf(Dashboard{}), } } func (a UpdateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Dashboard": Dashboard{}.ToAttrType(ctx), - "DashboardId": types.StringType, + "dashboard": basetypes.ListType{ + ElemType: Dashboard{}.ToAttrType(ctx), + }, + "dashboard_id": types.StringType, }, } } @@ -1484,16 +1514,18 @@ func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Schedule": reflect.TypeOf(Schedule{}), + "schedule": reflect.TypeOf(Schedule{}), } } func (a UpdateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Schedule": Schedule{}.ToAttrType(ctx), - "ScheduleId": types.StringType, + "dashboard_id": types.StringType, + "schedule": basetypes.ListType{ + ElemType: Schedule{}.ToAttrType(ctx), + }, + "schedule_id": types.StringType, }, } } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 299b0bce93..dcb8284d9e 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -41,8 +41,8 @@ func (a AddBlock) GetComplexFieldTypes() map[string]reflect.Type { func (a AddBlock) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Data": types.StringType, - "Handle": types.Int64Type, + "data": types.StringType, + "handle": types.Int64Type, }, } } @@ -84,7 +84,7 @@ func (a Close) GetComplexFieldTypes() map[string]reflect.Type { func (a Close) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Handle": types.Int64Type, + "handle": types.Int64Type, }, } } @@ -128,8 +128,8 @@ func (a Create) GetComplexFieldTypes() map[string]reflect.Type { func (a Create) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Overwrite": types.BoolType, - "Path": types.StringType, + "overwrite": types.BoolType, + "path": types.StringType, }, } } @@ -153,7 +153,7 @@ func (a CreateDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DirectoryPath": types.StringType, + "directory_path": types.StringType, }, } } @@ -196,7 +196,7 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Handle": types.Int64Type, + "handle": types.Int64Type, }, } } @@ -223,8 +223,8 @@ func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, - "Recursive": types.BoolType, + "path": types.StringType, + "recursive": types.BoolType, }, } } @@ -248,7 +248,7 @@ func (a DeleteDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DirectoryPath": types.StringType, + "directory_path": types.StringType, }, } } @@ -291,7 +291,7 @@ func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FilePath": types.StringType, + "file_path": types.StringType, }, } } @@ -342,11 +342,11 @@ func (a DirectoryEntry) GetComplexFieldTypes() map[string]reflect.Type { func (a DirectoryEntry) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileSize": types.Int64Type, - "IsDirectory": types.BoolType, - "LastModified": types.Int64Type, - "Name": types.StringType, - "Path": types.StringType, + "file_size": types.Int64Type, + "is_directory": types.BoolType, + "last_modified": types.Int64Type, + "name": types.StringType, + "path": types.StringType, }, } } @@ -370,7 +370,7 @@ func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FilePath": types.StringType, + "file_path": types.StringType, }, } } @@ -398,10 +398,10 @@ func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ContentLength": types.Int64Type, - "ContentType": types.StringType, - "Contents": types.ObjectType{}, - "LastModified": types.StringType, + "content-length": types.Int64Type, + "content-type": types.StringType, + "contents": types.ObjectType{}, + "last-modified": types.StringType, }, } } @@ -430,10 +430,10 @@ func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileSize": types.Int64Type, - "IsDir": types.BoolType, - "ModificationTime": types.Int64Type, - "Path": types.StringType, + "file_size": types.Int64Type, + "is_dir": types.BoolType, + "modification_time": types.Int64Type, + "path": types.StringType, }, } } @@ -457,7 +457,7 @@ func (a GetDirectoryMetadataRequest) GetComplexFieldTypes() map[string]reflect.T func (a GetDirectoryMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DirectoryPath": types.StringType, + "directory_path": types.StringType, }, } } @@ -500,7 +500,7 @@ func (a GetMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FilePath": types.StringType, + "file_path": types.StringType, }, } } @@ -526,9 +526,9 @@ func (a GetMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a GetMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ContentLength": types.Int64Type, - "ContentType": types.StringType, - "LastModified": types.StringType, + "content-length": types.Int64Type, + "content-type": types.StringType, + "last-modified": types.StringType, }, } } @@ -553,7 +553,7 @@ func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -578,7 +578,7 @@ func (a ListDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -622,9 +622,9 @@ func (a ListDirectoryContentsRequest) GetComplexFieldTypes() map[string]reflect. func (a ListDirectoryContentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DirectoryPath": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "directory_path": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -644,17 +644,17 @@ func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Contents": reflect.TypeOf(DirectoryEntry{}), + "contents": reflect.TypeOf(DirectoryEntry{}), } } func (a ListDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Contents": basetypes.ListType{ + "contents": basetypes.ListType{ ElemType: DirectoryEntry{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -673,14 +673,14 @@ func (newState *ListStatusResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Files": reflect.TypeOf(FileInfo{}), + "files": reflect.TypeOf(FileInfo{}), } } func (a ListStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Files": basetypes.ListType{ + "files": basetypes.ListType{ ElemType: FileInfo{}.ToAttrType(ctx), }, }, @@ -705,7 +705,7 @@ func (a MkDirs) GetComplexFieldTypes() map[string]reflect.Type { func (a MkDirs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -751,8 +751,8 @@ func (a Move) GetComplexFieldTypes() map[string]reflect.Type { func (a Move) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationPath": types.StringType, - "SourcePath": types.StringType, + "destination_path": types.StringType, + "source_path": types.StringType, }, } } @@ -798,9 +798,9 @@ func (a Put) GetComplexFieldTypes() map[string]reflect.Type { func (a Put) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Contents": types.StringType, - "Overwrite": types.BoolType, - "Path": types.StringType, + "contents": types.StringType, + "overwrite": types.BoolType, + "path": types.StringType, }, } } @@ -848,9 +848,9 @@ func (a ReadDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ReadDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Length": types.Int64Type, - "Offset": types.Int64Type, - "Path": types.StringType, + "length": types.Int64Type, + "offset": types.Int64Type, + "path": types.StringType, }, } } @@ -877,8 +877,8 @@ func (a ReadResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a ReadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BytesRead": types.Int64Type, - "Data": types.StringType, + "bytes_read": types.Int64Type, + "data": types.StringType, }, } } @@ -905,9 +905,9 @@ func (a UploadRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a UploadRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Contents": types.ObjectType{}, - "FilePath": types.StringType, - "Overwrite": types.BoolType, + "contents": types.ObjectType{}, + "file_path": types.StringType, + "overwrite": types.BoolType, }, } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 07e13095b4..d0e22810e8 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -43,10 +43,10 @@ func (a AccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a AccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -72,20 +72,20 @@ func (newState *AccessControlResponse) SyncEffectiveFieldsDuringRead(existingSta func (a AccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(Permission{}), + "all_permissions": reflect.TypeOf(Permission{}), } } func (a AccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: Permission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -115,11 +115,11 @@ func (a ComplexValue) GetComplexFieldTypes() map[string]reflect.Type { func (a ComplexValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Display": types.StringType, - "Primary": types.BoolType, - "Ref": types.StringType, - "Type": types.StringType, - "Value": types.StringType, + "display": types.StringType, + "primary": types.BoolType, + "$ref": types.StringType, + "type": types.StringType, + "value": types.StringType, }, } } @@ -143,7 +143,7 @@ func (a DeleteAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -167,7 +167,7 @@ func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes() map[string] func (a DeleteAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -191,7 +191,7 @@ func (a DeleteAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -215,7 +215,7 @@ func (a DeleteGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -258,7 +258,7 @@ func (a DeleteServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect func (a DeleteServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -282,7 +282,7 @@ func (a DeleteUserRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -308,8 +308,8 @@ func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]refl func (a DeleteWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrincipalId": types.Int64Type, - "WorkspaceId": types.Int64Type, + "principal_id": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -352,7 +352,7 @@ func (a GetAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -376,7 +376,7 @@ func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes() map[string]ref func (a GetAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -421,14 +421,14 @@ func (a GetAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "Id": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "id": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -452,7 +452,7 @@ func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes() map[string] func (a GetAssignableRolesForResourceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Resource": types.StringType, + "resource": types.StringType, }, } } @@ -469,14 +469,14 @@ func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuring func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Roles": reflect.TypeOf(Role{}), + "roles": reflect.TypeOf(Role{}), } } func (a GetAssignableRolesForResourceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Roles": basetypes.ListType{ + "roles": basetypes.ListType{ ElemType: Role{}.ToAttrType(ctx), }, }, @@ -502,7 +502,7 @@ func (a GetGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -520,14 +520,14 @@ func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringRe func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(PasswordPermissionsDescription{}), + "permission_levels": reflect.TypeOf(PasswordPermissionsDescription{}), } } func (a GetPasswordPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: PasswordPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -555,8 +555,8 @@ func (a GetPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RequestObjectId": types.StringType, - "RequestObjectType": types.StringType, + "request_object_id": types.StringType, + "request_object_type": types.StringType, }, } } @@ -574,14 +574,14 @@ func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(exist func (a GetPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(PermissionsDescription{}), + "permission_levels": reflect.TypeOf(PermissionsDescription{}), } } func (a GetPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: PermissionsDescription{}.ToAttrType(ctx), }, }, @@ -613,8 +613,8 @@ func (a GetPermissionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RequestObjectId": types.StringType, - "RequestObjectType": types.StringType, + "request_object_id": types.StringType, + "request_object_type": types.StringType, }, } } @@ -647,8 +647,8 @@ func (a GetRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, - "Name": types.StringType, + "etag": types.StringType, + "name": types.StringType, }, } } @@ -672,7 +672,7 @@ func (a GetServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -717,14 +717,14 @@ func (a GetUserRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "Id": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "id": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -748,7 +748,7 @@ func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect func (a GetWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceId": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -768,17 +768,17 @@ func (newState *GrantRule) SyncEffectiveFieldsDuringRead(existingState GrantRule func (a GrantRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Principals": reflect.TypeOf(types.StringType), + "principals": reflect.TypeOf(types.StringType), } } func (a GrantRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Principals": basetypes.ListType{ + "principals": basetypes.ListType{ ElemType: types.StringType, }, - "Role": types.StringType, + "role": types.StringType, }, } } @@ -815,35 +815,37 @@ func (newState *Group) SyncEffectiveFieldsDuringRead(existingState Group) { func (a Group) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Entitlements": reflect.TypeOf(ComplexValue{}), - "Groups": reflect.TypeOf(ComplexValue{}), - "Members": reflect.TypeOf(ComplexValue{}), - "Meta": reflect.TypeOf(ResourceMeta{}), - "Roles": reflect.TypeOf(ComplexValue{}), - "Schemas": reflect.TypeOf(types.StringType), + "entitlements": reflect.TypeOf(ComplexValue{}), + "groups": reflect.TypeOf(ComplexValue{}), + "members": reflect.TypeOf(ComplexValue{}), + "meta": reflect.TypeOf(ResourceMeta{}), + "roles": reflect.TypeOf(ComplexValue{}), + "schemas": reflect.TypeOf(types.StringType), } } func (a Group) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "Entitlements": basetypes.ListType{ + "displayName": types.StringType, + "entitlements": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "ExternalId": types.StringType, - "Groups": basetypes.ListType{ + "externalId": types.StringType, + "groups": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Id": types.StringType, - "Members": basetypes.ListType{ + "id": types.StringType, + "members": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Meta": ResourceMeta{}.ToAttrType(ctx), - "Roles": basetypes.ListType{ + "meta": basetypes.ListType{ + ElemType: ResourceMeta{}.ToAttrType(ctx), + }, + "roles": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -887,13 +889,13 @@ func (a ListAccountGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListAccountGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -935,13 +937,13 @@ func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes() map[string]r func (a ListAccountServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -984,13 +986,13 @@ func (a ListAccountUsersRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListAccountUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -1032,13 +1034,13 @@ func (a ListGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -1066,22 +1068,22 @@ func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListGroupsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(Group{}), - "Schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.StringType), } } func (a ListGroupsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ItemsPerPage": types.Int64Type, + "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ ElemType: Group{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, - "StartIndex": types.Int64Type, - "TotalResults": types.Int64Type, + "startIndex": types.Int64Type, + "totalResults": types.Int64Type, }, } } @@ -1109,22 +1111,22 @@ func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringRead(exis func (a ListServicePrincipalResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(ServicePrincipal{}), - "Schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.StringType), } } func (a ListServicePrincipalResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ItemsPerPage": types.Int64Type, + "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ ElemType: ServicePrincipal{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, - "StartIndex": types.Int64Type, - "TotalResults": types.Int64Type, + "startIndex": types.Int64Type, + "totalResults": types.Int64Type, }, } } @@ -1166,13 +1168,13 @@ func (a ListServicePrincipalsRequest) GetComplexFieldTypes() map[string]reflect. func (a ListServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -1215,13 +1217,13 @@ func (a ListUsersRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Attributes": types.StringType, - "Count": types.Int64Type, - "ExcludedAttributes": types.StringType, - "Filter": types.StringType, - "SortBy": types.StringType, - "SortOrder": types.StringType, - "StartIndex": types.Int64Type, + "attributes": types.StringType, + "count": types.Int64Type, + "excludedAttributes": types.StringType, + "filter": types.StringType, + "sortBy": types.StringType, + "sortOrder": types.StringType, + "startIndex": types.Int64Type, }, } } @@ -1249,22 +1251,22 @@ func (newState *ListUsersResponse) SyncEffectiveFieldsDuringRead(existingState L func (a ListUsersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(User{}), - "Schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.StringType), } } func (a ListUsersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ItemsPerPage": types.Int64Type, + "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ ElemType: User{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, - "StartIndex": types.Int64Type, - "TotalResults": types.Int64Type, + "startIndex": types.Int64Type, + "totalResults": types.Int64Type, }, } } @@ -1288,7 +1290,7 @@ func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflec func (a ListWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceId": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -1318,10 +1320,10 @@ func (a MigratePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a MigratePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FromWorkspaceGroupName": types.StringType, - "Size": types.Int64Type, - "ToAccountGroupName": types.StringType, - "WorkspaceId": types.Int64Type, + "from_workspace_group_name": types.StringType, + "size": types.Int64Type, + "to_account_group_name": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -1344,7 +1346,7 @@ func (a MigratePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Ty func (a MigratePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionsMigrated": types.Int64Type, + "permissions_migrated": types.Int64Type, }, } } @@ -1369,8 +1371,8 @@ func (a Name) GetComplexFieldTypes() map[string]reflect.Type { func (a Name) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FamilyName": types.StringType, - "GivenName": types.StringType, + "familyName": types.StringType, + "givenName": types.StringType, }, } } @@ -1391,18 +1393,18 @@ func (newState *ObjectPermissions) SyncEffectiveFieldsDuringRead(existingState O func (a ObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AccessControlResponse{}), + "access_control_list": reflect.TypeOf(AccessControlResponse{}), } } func (a ObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1426,18 +1428,18 @@ func (newState *PartialUpdate) SyncEffectiveFieldsDuringRead(existingState Parti func (a PartialUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ "Operations": reflect.TypeOf(Patch{}), - "Schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.StringType), } } func (a PartialUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, "Operations": basetypes.ListType{ ElemType: Patch{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1468,10 +1470,10 @@ func (a PasswordAccessControlRequest) GetComplexFieldTypes() map[string]reflect. func (a PasswordAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1497,20 +1499,20 @@ func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringRead(exi func (a PasswordAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(PasswordPermission{}), + "all_permissions": reflect.TypeOf(PasswordPermission{}), } } func (a PasswordAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: PasswordPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1531,18 +1533,18 @@ func (newState *PasswordPermission) SyncEffectiveFieldsDuringRead(existingState func (a PasswordPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a PasswordPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1563,18 +1565,18 @@ func (newState *PasswordPermissions) SyncEffectiveFieldsDuringRead(existingState func (a PasswordPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(PasswordAccessControlResponse{}), + "access_control_list": reflect.TypeOf(PasswordAccessControlResponse{}), } } func (a PasswordPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: PasswordAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1598,8 +1600,8 @@ func (a PasswordPermissionsDescription) GetComplexFieldTypes() map[string]reflec func (a PasswordPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1616,14 +1618,14 @@ func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringRead(existi func (a PasswordPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(PasswordAccessControlRequest{}), + "access_control_list": reflect.TypeOf(PasswordAccessControlRequest{}), } } func (a PasswordPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: PasswordAccessControlRequest{}.ToAttrType(ctx), }, }, @@ -1652,9 +1654,9 @@ func (a Patch) GetComplexFieldTypes() map[string]reflect.Type { func (a Patch) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Op": types.StringType, - "Path": types.StringType, - "Value": types.ObjectType{}, + "op": types.StringType, + "path": types.StringType, + "value": types.ObjectType{}, }, } } @@ -1694,18 +1696,18 @@ func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permissi func (a Permission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a Permission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1729,19 +1731,21 @@ func (newState *PermissionAssignment) SyncEffectiveFieldsDuringRead(existingStat func (a PermissionAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Permissions": reflect.TypeOf(types.StringType), - "Principal": reflect.TypeOf(PrincipalOutput{}), + "permissions": reflect.TypeOf(types.StringType), + "principal": reflect.TypeOf(PrincipalOutput{}), } } func (a PermissionAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Error": types.StringType, - "Permissions": basetypes.ListType{ + "error": types.StringType, + "permissions": basetypes.ListType{ ElemType: types.StringType, }, - "Principal": PrincipalOutput{}.ToAttrType(ctx), + "principal": basetypes.ListType{ + ElemType: PrincipalOutput{}.ToAttrType(ctx), + }, }, } } @@ -1759,14 +1763,14 @@ func (newState *PermissionAssignments) SyncEffectiveFieldsDuringRead(existingSta func (a PermissionAssignments) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionAssignments": reflect.TypeOf(PermissionAssignment{}), + "permission_assignments": reflect.TypeOf(PermissionAssignment{}), } } func (a PermissionAssignments) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionAssignments": basetypes.ListType{ + "permission_assignments": basetypes.ListType{ ElemType: PermissionAssignment{}.ToAttrType(ctx), }, }, @@ -1793,8 +1797,8 @@ func (a PermissionOutput) GetComplexFieldTypes() map[string]reflect.Type { func (a PermissionOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1818,8 +1822,8 @@ func (a PermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { func (a PermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1844,18 +1848,18 @@ func (newState *PermissionsRequest) SyncEffectiveFieldsDuringRead(existingState func (a PermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AccessControlRequest{}), + "access_control_list": reflect.TypeOf(AccessControlRequest{}), } } func (a PermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AccessControlRequest{}.ToAttrType(ctx), }, - "RequestObjectId": types.StringType, - "RequestObjectType": types.StringType, + "request_object_id": types.StringType, + "request_object_type": types.StringType, }, } } @@ -1888,11 +1892,11 @@ func (a PrincipalOutput) GetComplexFieldTypes() map[string]reflect.Type { func (a PrincipalOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "GroupName": types.StringType, - "PrincipalId": types.Int64Type, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "principal_id": types.Int64Type, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1916,7 +1920,7 @@ func (a ResourceMeta) GetComplexFieldTypes() map[string]reflect.Type { func (a ResourceMeta) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ResourceType": types.StringType, + "resourceType": types.StringType, }, } } @@ -1939,7 +1943,7 @@ func (a Role) GetComplexFieldTypes() map[string]reflect.Type { func (a Role) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1961,18 +1965,18 @@ func (newState *RuleSetResponse) SyncEffectiveFieldsDuringRead(existingState Rul func (a RuleSetResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "GrantRules": reflect.TypeOf(GrantRule{}), + "grant_rules": reflect.TypeOf(GrantRule{}), } } func (a RuleSetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, - "GrantRules": basetypes.ListType{ + "etag": types.StringType, + "grant_rules": basetypes.ListType{ ElemType: GrantRule{}.ToAttrType(ctx), }, - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1996,18 +2000,18 @@ func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringRead(existingStat func (a RuleSetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "GrantRules": reflect.TypeOf(GrantRule{}), + "grant_rules": reflect.TypeOf(GrantRule{}), } } func (a RuleSetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, - "GrantRules": basetypes.ListType{ + "etag": types.StringType, + "grant_rules": basetypes.ListType{ ElemType: GrantRule{}.ToAttrType(ctx), }, - "Name": types.StringType, + "name": types.StringType, }, } } @@ -2044,31 +2048,31 @@ func (newState *ServicePrincipal) SyncEffectiveFieldsDuringRead(existingState Se func (a ServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Entitlements": reflect.TypeOf(ComplexValue{}), - "Groups": reflect.TypeOf(ComplexValue{}), - "Roles": reflect.TypeOf(ComplexValue{}), - "Schemas": reflect.TypeOf(types.StringType), + "entitlements": reflect.TypeOf(ComplexValue{}), + "groups": reflect.TypeOf(ComplexValue{}), + "roles": reflect.TypeOf(ComplexValue{}), + "schemas": reflect.TypeOf(types.StringType), } } func (a ServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Active": types.BoolType, - "ApplicationId": types.StringType, - "DisplayName": types.StringType, - "Entitlements": basetypes.ListType{ + "active": types.BoolType, + "applicationId": types.StringType, + "displayName": types.StringType, + "entitlements": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "ExternalId": types.StringType, - "Groups": basetypes.ListType{ + "externalId": types.StringType, + "groups": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Id": types.StringType, - "Roles": basetypes.ListType{ + "id": types.StringType, + "roles": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -2109,15 +2113,17 @@ func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringRead(existingStat func (a UpdateRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RuleSet": reflect.TypeOf(RuleSetUpdateRequest{}), + "rule_set": reflect.TypeOf(RuleSetUpdateRequest{}), } } func (a UpdateRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "RuleSet": RuleSetUpdateRequest{}.ToAttrType(ctx), + "name": types.StringType, + "rule_set": basetypes.ListType{ + ElemType: RuleSetUpdateRequest{}.ToAttrType(ctx), + }, }, } } @@ -2144,18 +2150,18 @@ func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringRead(existi func (a UpdateWorkspaceAssignments) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Permissions": reflect.TypeOf(types.StringType), + "permissions": reflect.TypeOf(types.StringType), } } func (a UpdateWorkspaceAssignments) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Permissions": basetypes.ListType{ + "permissions": basetypes.ListType{ ElemType: types.StringType, }, - "PrincipalId": types.Int64Type, - "WorkspaceId": types.Int64Type, + "principal_id": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -2202,39 +2208,41 @@ func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { func (a User) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Emails": reflect.TypeOf(ComplexValue{}), - "Entitlements": reflect.TypeOf(ComplexValue{}), - "Groups": reflect.TypeOf(ComplexValue{}), - "Name": reflect.TypeOf(Name{}), - "Roles": reflect.TypeOf(ComplexValue{}), - "Schemas": reflect.TypeOf(types.StringType), + "emails": reflect.TypeOf(ComplexValue{}), + "entitlements": reflect.TypeOf(ComplexValue{}), + "groups": reflect.TypeOf(ComplexValue{}), + "name": reflect.TypeOf(Name{}), + "roles": reflect.TypeOf(ComplexValue{}), + "schemas": reflect.TypeOf(types.StringType), } } func (a User) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Active": types.BoolType, - "DisplayName": types.StringType, - "Emails": basetypes.ListType{ + "active": types.BoolType, + "displayName": types.StringType, + "emails": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Entitlements": basetypes.ListType{ + "entitlements": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "ExternalId": types.StringType, - "Groups": basetypes.ListType{ + "externalId": types.StringType, + "groups": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Id": types.StringType, - "Name": Name{}.ToAttrType(ctx), - "Roles": basetypes.ListType{ + "id": types.StringType, + "name": basetypes.ListType{ + ElemType: Name{}.ToAttrType(ctx), + }, + "roles": basetypes.ListType{ ElemType: ComplexValue{}.ToAttrType(ctx), }, - "Schemas": basetypes.ListType{ + "schemas": basetypes.ListType{ ElemType: types.StringType, }, - "UserName": types.StringType, + "userName": types.StringType, }, } } @@ -2252,14 +2260,14 @@ func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringRead(existingStat func (a WorkspacePermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Permissions": reflect.TypeOf(PermissionOutput{}), + "permissions": reflect.TypeOf(PermissionOutput{}), } } func (a WorkspacePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Permissions": basetypes.ListType{ + "permissions": basetypes.ListType{ ElemType: PermissionOutput{}.ToAttrType(ctx), }, }, diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 80fb341808..1d61caac98 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -50,18 +50,20 @@ func (newState *BaseJob) SyncEffectiveFieldsDuringRead(existingState BaseJob) { func (a BaseJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Settings": reflect.TypeOf(JobSettings{}), + "settings": reflect.TypeOf(JobSettings{}), } } func (a BaseJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedTime": types.Int64Type, - "CreatorUserName": types.StringType, - "EffectiveBudgetPolicyId": types.StringType, - "JobId": types.Int64Type, - "Settings": JobSettings{}.ToAttrType(ctx), + "created_time": types.Int64Type, + "creator_user_name": types.StringType, + "effective_budget_policy_id": types.StringType, + "job_id": types.Int64Type, + "settings": basetypes.ListType{ + ElemType: JobSettings{}.ToAttrType(ctx), + }, }, } } @@ -204,63 +206,79 @@ func (newState *BaseRun) SyncEffectiveFieldsDuringRead(existingState BaseRun) { func (a BaseRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ClusterInstance": reflect.TypeOf(ClusterInstance{}), - "ClusterSpec": reflect.TypeOf(ClusterSpec{}), - "GitSource": reflect.TypeOf(GitSource{}), - "JobClusters": reflect.TypeOf(JobCluster{}), - "JobParameters": reflect.TypeOf(JobParameter{}), - "OverridingParameters": reflect.TypeOf(RunParameters{}), - "RepairHistory": reflect.TypeOf(RepairHistoryItem{}), - "Schedule": reflect.TypeOf(CronSchedule{}), - "State": reflect.TypeOf(RunState{}), - "Status": reflect.TypeOf(RunStatus{}), - "Tasks": reflect.TypeOf(RunTask{}), - "TriggerInfo": reflect.TypeOf(TriggerInfo{}), + "cluster_instance": reflect.TypeOf(ClusterInstance{}), + "cluster_spec": reflect.TypeOf(ClusterSpec{}), + "git_source": reflect.TypeOf(GitSource{}), + "job_clusters": reflect.TypeOf(JobCluster{}), + "job_parameters": reflect.TypeOf(JobParameter{}), + "overriding_parameters": reflect.TypeOf(RunParameters{}), + "repair_history": reflect.TypeOf(RepairHistoryItem{}), + "schedule": reflect.TypeOf(CronSchedule{}), + "state": reflect.TypeOf(RunState{}), + "status": reflect.TypeOf(RunStatus{}), + "tasks": reflect.TypeOf(RunTask{}), + "trigger_info": reflect.TypeOf(TriggerInfo{}), } } func (a BaseRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AttemptNumber": types.Int64Type, - "CleanupDuration": types.Int64Type, - "ClusterInstance": ClusterInstance{}.ToAttrType(ctx), - "ClusterSpec": ClusterSpec{}.ToAttrType(ctx), - "CreatorUserName": types.StringType, - "Description": types.StringType, - "EndTime": types.Int64Type, - "ExecutionDuration": types.Int64Type, - "GitSource": GitSource{}.ToAttrType(ctx), - "JobClusters": basetypes.ListType{ + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ + ElemType: ClusterInstance{}.ToAttrType(ctx), + }, + "cluster_spec": basetypes.ListType{ + ElemType: ClusterSpec{}.ToAttrType(ctx), + }, + "creator_user_name": types.StringType, + "description": types.StringType, + "end_time": types.Int64Type, + "execution_duration": types.Int64Type, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.ToAttrType(ctx), + }, + "job_clusters": basetypes.ListType{ ElemType: JobCluster{}.ToAttrType(ctx), }, - "JobId": types.Int64Type, - "JobParameters": basetypes.ListType{ + "job_id": types.Int64Type, + "job_parameters": basetypes.ListType{ ElemType: JobParameter{}.ToAttrType(ctx), }, - "JobRunId": types.Int64Type, - "NumberInJob": types.Int64Type, - "OriginalAttemptRunId": types.Int64Type, - "OverridingParameters": RunParameters{}.ToAttrType(ctx), - "QueueDuration": types.Int64Type, - "RepairHistory": basetypes.ListType{ + "job_run_id": types.Int64Type, + "number_in_job": types.Int64Type, + "original_attempt_run_id": types.Int64Type, + "overriding_parameters": basetypes.ListType{ + ElemType: RunParameters{}.ToAttrType(ctx), + }, + "queue_duration": types.Int64Type, + "repair_history": basetypes.ListType{ ElemType: RepairHistoryItem{}.ToAttrType(ctx), }, - "RunDuration": types.Int64Type, - "RunId": types.Int64Type, - "RunName": types.StringType, - "RunPageUrl": types.StringType, - "RunType": types.StringType, - "Schedule": CronSchedule{}.ToAttrType(ctx), - "SetupDuration": types.Int64Type, - "StartTime": types.Int64Type, - "State": RunState{}.ToAttrType(ctx), - "Status": RunStatus{}.ToAttrType(ctx), - "Tasks": basetypes.ListType{ + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.ToAttrType(ctx), + }, + "setup_duration": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ + ElemType: RunState{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.ToAttrType(ctx), + }, + "tasks": basetypes.ListType{ ElemType: RunTask{}.ToAttrType(ctx), }, - "Trigger": types.StringType, - "TriggerInfo": TriggerInfo{}.ToAttrType(ctx), + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ + ElemType: TriggerInfo{}.ToAttrType(ctx), + }, }, } } @@ -286,8 +304,8 @@ func (a CancelAllRuns) GetComplexFieldTypes() map[string]reflect.Type { func (a CancelAllRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllQueuedRuns": types.BoolType, - "JobId": types.Int64Type, + "all_queued_runs": types.BoolType, + "job_id": types.Int64Type, }, } } @@ -329,7 +347,7 @@ func (a CancelRun) GetComplexFieldTypes() map[string]reflect.Type { func (a CancelRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -387,8 +405,8 @@ func (a ClusterInstance) GetComplexFieldTypes() map[string]reflect.Type { func (a ClusterInstance) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "SparkContextId": types.StringType, + "cluster_id": types.StringType, + "spark_context_id": types.StringType, }, } } @@ -418,20 +436,22 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState Cluster func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Libraries": reflect.TypeOf(compute.Library{}), - "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + "library": reflect.TypeOf(compute.Library{}), + "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), } } func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExistingClusterId": types.StringType, - "JobClusterKey": types.StringType, - "Libraries": basetypes.ListType{ + "existing_cluster_id": types.StringType, + "job_cluster_key": types.StringType, + "library": basetypes.ListType{ ElemType: compute_tf.Library{}.ToAttrType(ctx), }, - "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, }, } } @@ -469,9 +489,9 @@ func (a ConditionTask) GetComplexFieldTypes() map[string]reflect.Type { func (a ConditionTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Left": types.StringType, - "Op": types.StringType, - "Right": types.StringType, + "left": types.StringType, + "op": types.StringType, + "right": types.StringType, }, } } @@ -495,7 +515,7 @@ func (a Continuous) GetComplexFieldTypes() map[string]reflect.Type { func (a Continuous) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PauseStatus": types.StringType, + "pause_status": types.StringType, }, } } @@ -614,65 +634,87 @@ func (newState *CreateJob) SyncEffectiveFieldsDuringRead(existingState CreateJob func (a CreateJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(JobAccessControlRequest{}), - "Continuous": reflect.TypeOf(Continuous{}), - "Deployment": reflect.TypeOf(JobDeployment{}), - "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), - "Environments": reflect.TypeOf(JobEnvironment{}), - "GitSource": reflect.TypeOf(GitSource{}), - "Health": reflect.TypeOf(JobsHealthRules{}), - "JobClusters": reflect.TypeOf(JobCluster{}), - "NotificationSettings": reflect.TypeOf(JobNotificationSettings{}), - "Parameters": reflect.TypeOf(JobParameterDefinition{}), - "Queue": reflect.TypeOf(QueueSettings{}), - "RunAs": reflect.TypeOf(JobRunAs{}), - "Schedule": reflect.TypeOf(CronSchedule{}), - "Tags": reflect.TypeOf(types.StringType), - "Tasks": reflect.TypeOf(Task{}), - "Trigger": reflect.TypeOf(TriggerSettings{}), - "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), + "continuous": reflect.TypeOf(Continuous{}), + "deployment": reflect.TypeOf(JobDeployment{}), + "email_notifications": reflect.TypeOf(JobEmailNotifications{}), + "environment": reflect.TypeOf(JobEnvironment{}), + "git_source": reflect.TypeOf(GitSource{}), + "health": reflect.TypeOf(JobsHealthRules{}), + "job_cluster": reflect.TypeOf(JobCluster{}), + "notification_settings": reflect.TypeOf(JobNotificationSettings{}), + "parameter": reflect.TypeOf(JobParameterDefinition{}), + "queue": reflect.TypeOf(QueueSettings{}), + "run_as": reflect.TypeOf(JobRunAs{}), + "schedule": reflect.TypeOf(CronSchedule{}), + "tags": reflect.TypeOf(types.StringType), + "task": reflect.TypeOf(Task{}), + "trigger": reflect.TypeOf(TriggerSettings{}), + "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), } } func (a CreateJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: JobAccessControlRequest{}.ToAttrType(ctx), }, - "BudgetPolicyId": types.StringType, - "Continuous": Continuous{}.ToAttrType(ctx), - "Deployment": JobDeployment{}.ToAttrType(ctx), - "Description": types.StringType, - "EditMode": types.StringType, - "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), - "Environments": basetypes.ListType{ + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ + ElemType: Continuous{}.ToAttrType(ctx), + }, + "deployment": basetypes.ListType{ + ElemType: JobDeployment{}.ToAttrType(ctx), + }, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.ToAttrType(ctx), + }, + "environment": basetypes.ListType{ ElemType: JobEnvironment{}.ToAttrType(ctx), }, - "Format": types.StringType, - "GitSource": GitSource{}.ToAttrType(ctx), - "Health": JobsHealthRules{}.ToAttrType(ctx), - "JobClusters": basetypes.ListType{ + "format": types.StringType, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.ToAttrType(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.ToAttrType(ctx), + }, + "job_cluster": basetypes.ListType{ ElemType: JobCluster{}.ToAttrType(ctx), }, - "MaxConcurrentRuns": types.Int64Type, - "Name": types.StringType, - "NotificationSettings": JobNotificationSettings{}.ToAttrType(ctx), - "Parameters": basetypes.ListType{ + "max_concurrent_runs": types.Int64Type, + "name": types.StringType, + "notification_settings": basetypes.ListType{ + ElemType: JobNotificationSettings{}.ToAttrType(ctx), + }, + "parameter": basetypes.ListType{ ElemType: JobParameterDefinition{}.ToAttrType(ctx), }, - "Queue": QueueSettings{}.ToAttrType(ctx), - "RunAs": JobRunAs{}.ToAttrType(ctx), - "Schedule": CronSchedule{}.ToAttrType(ctx), - "Tags": basetypes.MapType{ + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.ToAttrType(ctx), + }, + "run_as": basetypes.ListType{ + ElemType: JobRunAs{}.ToAttrType(ctx), + }, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.ToAttrType(ctx), + }, + "tags": basetypes.MapType{ ElemType: types.StringType, }, - "Tasks": basetypes.ListType{ + "task": basetypes.ListType{ ElemType: Task{}.ToAttrType(ctx), }, - "TimeoutSeconds": types.Int64Type, - "Trigger": TriggerSettings{}.ToAttrType(ctx), - "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + "timeout_seconds": types.Int64Type, + "trigger": basetypes.ListType{ + ElemType: TriggerSettings{}.ToAttrType(ctx), + }, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.ToAttrType(ctx), + }, }, } } @@ -696,7 +738,7 @@ func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.Int64Type, + "job_id": types.Int64Type, }, } } @@ -729,9 +771,9 @@ func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PauseStatus": types.StringType, - "QuartzCronExpression": types.StringType, - "TimezoneId": types.StringType, + "pause_status": types.StringType, + "quartz_cron_expression": types.StringType, + "timezone_id": types.StringType, }, } } @@ -754,17 +796,17 @@ func (newState *DbtOutput) SyncEffectiveFieldsDuringRead(existingState DbtOutput func (a DbtOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ArtifactsHeaders": reflect.TypeOf(types.StringType), + "artifacts_headers": reflect.TypeOf(types.StringType), } } func (a DbtOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactsHeaders": basetypes.MapType{ + "artifacts_headers": basetypes.MapType{ ElemType: types.StringType, }, - "ArtifactsLink": types.StringType, + "artifacts_link": types.StringType, }, } } @@ -814,22 +856,22 @@ func (newState *DbtTask) SyncEffectiveFieldsDuringRead(existingState DbtTask) { func (a DbtTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Commands": reflect.TypeOf(types.StringType), + "commands": reflect.TypeOf(types.StringType), } } func (a DbtTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Catalog": types.StringType, - "Commands": basetypes.ListType{ + "catalog": types.StringType, + "commands": basetypes.ListType{ ElemType: types.StringType, }, - "ProfilesDirectory": types.StringType, - "ProjectDirectory": types.StringType, - "Schema": types.StringType, - "Source": types.StringType, - "WarehouseId": types.StringType, + "profiles_directory": types.StringType, + "project_directory": types.StringType, + "schema": types.StringType, + "source": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -852,7 +894,7 @@ func (a DeleteJob) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.Int64Type, + "job_id": types.Int64Type, }, } } @@ -894,7 +936,7 @@ func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -949,9 +991,9 @@ func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComple func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Field": types.StringType, - "NewValue": types.StringType, - "PreviousValue": types.StringType, + "field": types.StringType, + "new_value": types.StringType, + "previous_value": types.StringType, }, } } @@ -977,8 +1019,8 @@ func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes() map[string]reflec func (a EnforcePolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.Int64Type, - "ValidateOnly": types.BoolType, + "job_id": types.Int64Type, + "validate_only": types.BoolType, }, } } @@ -1008,19 +1050,21 @@ func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringRead(e func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "JobClusterChanges": reflect.TypeOf(EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}), - "Settings": reflect.TypeOf(JobSettings{}), + "job_cluster_changes": reflect.TypeOf(EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}), + "settings": reflect.TypeOf(JobSettings{}), } } func (a EnforcePolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "HasChanges": types.BoolType, - "JobClusterChanges": basetypes.ListType{ + "has_changes": types.BoolType, + "job_cluster_changes": basetypes.ListType{ ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.ToAttrType(ctx), }, - "Settings": JobSettings{}.ToAttrType(ctx), + "settings": basetypes.ListType{ + ElemType: JobSettings{}.ToAttrType(ctx), + }, }, } } @@ -1043,14 +1087,14 @@ func (newState *ExportRunOutput) SyncEffectiveFieldsDuringRead(existingState Exp func (a ExportRunOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Views": reflect.TypeOf(ViewItem{}), + "views": reflect.TypeOf(ViewItem{}), } } func (a ExportRunOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Views": basetypes.ListType{ + "views": basetypes.ListType{ ElemType: ViewItem{}.ToAttrType(ctx), }, }, @@ -1078,8 +1122,8 @@ func (a ExportRunRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ExportRunRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, - "ViewsToExport": types.StringType, + "run_id": types.Int64Type, + "views_to_export": types.StringType, }, } } @@ -1112,9 +1156,9 @@ func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes() map[string]refle func (a FileArrivalTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MinTimeBetweenTriggersSeconds": types.Int64Type, - "Url": types.StringType, - "WaitAfterLastChangeSeconds": types.Int64Type, + "min_time_between_triggers_seconds": types.Int64Type, + "url": types.StringType, + "wait_after_last_change_seconds": types.Int64Type, }, } } @@ -1134,18 +1178,20 @@ func (newState *ForEachStats) SyncEffectiveFieldsDuringRead(existingState ForEac func (a ForEachStats) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ErrorMessageStats": reflect.TypeOf(ForEachTaskErrorMessageStats{}), - "TaskRunStats": reflect.TypeOf(ForEachTaskTaskRunStats{}), + "error_message_stats": reflect.TypeOf(ForEachTaskErrorMessageStats{}), + "task_run_stats": reflect.TypeOf(ForEachTaskTaskRunStats{}), } } func (a ForEachStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ErrorMessageStats": basetypes.ListType{ + "error_message_stats": basetypes.ListType{ ElemType: ForEachTaskErrorMessageStats{}.ToAttrType(ctx), }, - "TaskRunStats": ForEachTaskTaskRunStats{}.ToAttrType(ctx), + "task_run_stats": basetypes.ListType{ + ElemType: ForEachTaskTaskRunStats{}.ToAttrType(ctx), + }, }, } } @@ -1170,16 +1216,18 @@ func (newState *ForEachTask) SyncEffectiveFieldsDuringRead(existingState ForEach func (a ForEachTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Task": reflect.TypeOf(Task{}), + "task": reflect.TypeOf(Task{}), } } func (a ForEachTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Concurrency": types.Int64Type, - "Inputs": types.StringType, - "Task": Task{}.ToAttrType(ctx), + "concurrency": types.Int64Type, + "inputs": types.StringType, + "task": basetypes.ListType{ + ElemType: Task{}.ToAttrType(ctx), + }, }, } } @@ -1207,9 +1255,9 @@ func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes() map[string]reflect. func (a ForEachTaskErrorMessageStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Count": types.Int64Type, - "ErrorMessage": types.StringType, - "TerminationCategory": types.StringType, + "count": types.Int64Type, + "error_message": types.StringType, + "termination_category": types.StringType, }, } } @@ -1243,12 +1291,12 @@ func (a ForEachTaskTaskRunStats) GetComplexFieldTypes() map[string]reflect.Type func (a ForEachTaskTaskRunStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActiveIterations": types.Int64Type, - "CompletedIterations": types.Int64Type, - "FailedIterations": types.Int64Type, - "ScheduledIterations": types.Int64Type, - "SucceededIterations": types.Int64Type, - "TotalIterations": types.Int64Type, + "active_iterations": types.Int64Type, + "completed_iterations": types.Int64Type, + "failed_iterations": types.Int64Type, + "scheduled_iterations": types.Int64Type, + "succeeded_iterations": types.Int64Type, + "total_iterations": types.Int64Type, }, } } @@ -1272,7 +1320,7 @@ func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect func (a GetJobPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.StringType, + "job_id": types.StringType, }, } } @@ -1290,14 +1338,14 @@ func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(ex func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(JobPermissionsDescription{}), + "permission_levels": reflect.TypeOf(JobPermissionsDescription{}), } } func (a GetJobPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: JobPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -1323,7 +1371,7 @@ func (a GetJobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetJobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.StringType, + "job_id": types.StringType, }, } } @@ -1348,7 +1396,7 @@ func (a GetJobRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetJobRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.Int64Type, + "job_id": types.Int64Type, }, } } @@ -1372,7 +1420,7 @@ func (a GetPolicyComplianceRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a GetPolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.Int64Type, + "job_id": types.Int64Type, }, } } @@ -1399,15 +1447,15 @@ func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringRead(exist func (a GetPolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.StringType), } } func (a GetPolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsCompliant": types.BoolType, - "Violations": basetypes.MapType{ + "is_compliant": types.BoolType, + "violations": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -1433,7 +1481,7 @@ func (a GetRunOutputRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRunOutputRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -1465,10 +1513,10 @@ func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeHistory": types.BoolType, - "IncludeResolvedValues": types.BoolType, - "PageToken": types.StringType, - "RunId": types.Int64Type, + "include_history": types.BoolType, + "include_resolved_values": types.BoolType, + "page_token": types.StringType, + "run_id": types.Int64Type, }, } } @@ -1495,7 +1543,7 @@ func (a GitSnapshot) GetComplexFieldTypes() map[string]reflect.Type { func (a GitSnapshot) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "UsedCommit": types.StringType, + "used_commit": types.StringType, }, } } @@ -1541,21 +1589,25 @@ func (newState *GitSource) SyncEffectiveFieldsDuringRead(existingState GitSource func (a GitSource) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "GitSnapshot": reflect.TypeOf(GitSnapshot{}), - "JobSource": reflect.TypeOf(JobSource{}), + "git_snapshot": reflect.TypeOf(GitSnapshot{}), + "job_source": reflect.TypeOf(JobSource{}), } } func (a GitSource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GitBranch": types.StringType, - "GitCommit": types.StringType, - "GitProvider": types.StringType, - "GitSnapshot": GitSnapshot{}.ToAttrType(ctx), - "GitTag": types.StringType, - "GitUrl": types.StringType, - "JobSource": JobSource{}.ToAttrType(ctx), + "branch": types.StringType, + "commit": types.StringType, + "git_provider": types.StringType, + "git_snapshot": basetypes.ListType{ + ElemType: GitSnapshot{}.ToAttrType(ctx), + }, + "tag": types.StringType, + "url": types.StringType, + "job_source": basetypes.ListType{ + ElemType: JobSource{}.ToAttrType(ctx), + }, }, } } @@ -1598,19 +1650,21 @@ func (newState *Job) SyncEffectiveFieldsDuringRead(existingState Job) { func (a Job) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Settings": reflect.TypeOf(JobSettings{}), + "settings": reflect.TypeOf(JobSettings{}), } } func (a Job) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedTime": types.Int64Type, - "CreatorUserName": types.StringType, - "EffectiveBudgetPolicyId": types.StringType, - "JobId": types.Int64Type, - "RunAsUserName": types.StringType, - "Settings": JobSettings{}.ToAttrType(ctx), + "created_time": types.Int64Type, + "creator_user_name": types.StringType, + "effective_budget_policy_id": types.StringType, + "job_id": types.Int64Type, + "run_as_user_name": types.StringType, + "settings": basetypes.ListType{ + ElemType: JobSettings{}.ToAttrType(ctx), + }, }, } } @@ -1639,10 +1693,10 @@ func (a JobAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type func (a JobAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1668,20 +1722,20 @@ func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringRead(existing func (a JobAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(JobPermission{}), + "all_permissions": reflect.TypeOf(JobPermission{}), } } func (a JobAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: JobPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1703,15 +1757,17 @@ func (newState *JobCluster) SyncEffectiveFieldsDuringRead(existingState JobClust func (a JobCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), + "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), } } func (a JobCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobClusterKey": types.StringType, - "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), + "job_cluster_key": types.StringType, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, }, } } @@ -1737,16 +1793,16 @@ func (newState *JobCompliance) SyncEffectiveFieldsDuringRead(existingState JobCo func (a JobCompliance) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.StringType), } } func (a JobCompliance) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsCompliant": types.BoolType, - "JobId": types.Int64Type, - "Violations": basetypes.MapType{ + "is_compliant": types.BoolType, + "job_id": types.Int64Type, + "violations": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -1775,8 +1831,8 @@ func (a JobDeployment) GetComplexFieldTypes() map[string]reflect.Type { func (a JobDeployment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Kind": types.StringType, - "MetadataFilePath": types.StringType, + "kind": types.StringType, + "metadata_file_path": types.StringType, }, } } @@ -1825,31 +1881,31 @@ func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringRead(existingSta func (a JobEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OnDurationWarningThresholdExceeded": reflect.TypeOf(types.StringType), - "OnFailure": reflect.TypeOf(types.StringType), - "OnStart": reflect.TypeOf(types.StringType), - "OnStreamingBacklogExceeded": reflect.TypeOf(types.StringType), - "OnSuccess": reflect.TypeOf(types.StringType), + "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.StringType), + "on_failure": reflect.TypeOf(types.StringType), + "on_start": reflect.TypeOf(types.StringType), + "on_streaming_backlog_exceeded": reflect.TypeOf(types.StringType), + "on_success": reflect.TypeOf(types.StringType), } } func (a JobEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NoAlertForSkippedRuns": types.BoolType, - "OnDurationWarningThresholdExceeded": basetypes.ListType{ + "no_alert_for_skipped_runs": types.BoolType, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ ElemType: types.StringType, }, - "OnFailure": basetypes.ListType{ + "on_failure": basetypes.ListType{ ElemType: types.StringType, }, - "OnStart": basetypes.ListType{ + "on_start": basetypes.ListType{ ElemType: types.StringType, }, - "OnStreamingBacklogExceeded": basetypes.ListType{ + "on_streaming_backlog_exceeded": basetypes.ListType{ ElemType: types.StringType, }, - "OnSuccess": basetypes.ListType{ + "on_success": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1873,15 +1929,17 @@ func (newState *JobEnvironment) SyncEffectiveFieldsDuringRead(existingState JobE func (a JobEnvironment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Spec": reflect.TypeOf(compute.Environment{}), + "spec": reflect.TypeOf(compute.Environment{}), } } func (a JobEnvironment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EnvironmentKey": types.StringType, - "Spec": compute_tf.Environment{}.ToAttrType(ctx), + "environment_key": types.StringType, + "spec": basetypes.ListType{ + ElemType: compute_tf.Environment{}.ToAttrType(ctx), + }, }, } } @@ -1908,8 +1966,8 @@ func (a JobNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type func (a JobNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NoAlertForCanceledRuns": types.BoolType, - "NoAlertForSkippedRuns": types.BoolType, + "no_alert_for_canceled_runs": types.BoolType, + "no_alert_for_skipped_runs": types.BoolType, }, } } @@ -1936,9 +1994,9 @@ func (a JobParameter) GetComplexFieldTypes() map[string]reflect.Type { func (a JobParameter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Default": types.StringType, - "Name": types.StringType, - "Value": types.StringType, + "default": types.StringType, + "name": types.StringType, + "value": types.StringType, }, } } @@ -1964,8 +2022,8 @@ func (a JobParameterDefinition) GetComplexFieldTypes() map[string]reflect.Type { func (a JobParameterDefinition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Default": types.StringType, - "Name": types.StringType, + "default": types.StringType, + "name": types.StringType, }, } } @@ -1986,18 +2044,18 @@ func (newState *JobPermission) SyncEffectiveFieldsDuringRead(existingState JobPe func (a JobPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a JobPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -2018,18 +2076,18 @@ func (newState *JobPermissions) SyncEffectiveFieldsDuringRead(existingState JobP func (a JobPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(JobAccessControlResponse{}), + "access_control_list": reflect.TypeOf(JobAccessControlResponse{}), } } func (a JobPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: JobAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2053,8 +2111,8 @@ func (a JobPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Typ func (a JobPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -2073,17 +2131,17 @@ func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingSta func (a JobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(JobAccessControlRequest{}), + "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), } } func (a JobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: JobAccessControlRequest{}.ToAttrType(ctx), }, - "JobId": types.StringType, + "job_id": types.StringType, }, } } @@ -2116,8 +2174,8 @@ func (a JobRunAs) GetComplexFieldTypes() map[string]reflect.Type { func (a JobRunAs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -2234,61 +2292,83 @@ func (newState *JobSettings) SyncEffectiveFieldsDuringRead(existingState JobSett func (a JobSettings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Continuous": reflect.TypeOf(Continuous{}), - "Deployment": reflect.TypeOf(JobDeployment{}), - "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), - "Environments": reflect.TypeOf(JobEnvironment{}), - "GitSource": reflect.TypeOf(GitSource{}), - "Health": reflect.TypeOf(JobsHealthRules{}), - "JobClusters": reflect.TypeOf(JobCluster{}), - "NotificationSettings": reflect.TypeOf(JobNotificationSettings{}), - "Parameters": reflect.TypeOf(JobParameterDefinition{}), - "Queue": reflect.TypeOf(QueueSettings{}), - "RunAs": reflect.TypeOf(JobRunAs{}), - "Schedule": reflect.TypeOf(CronSchedule{}), - "Tags": reflect.TypeOf(types.StringType), - "Tasks": reflect.TypeOf(Task{}), - "Trigger": reflect.TypeOf(TriggerSettings{}), - "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + "continuous": reflect.TypeOf(Continuous{}), + "deployment": reflect.TypeOf(JobDeployment{}), + "email_notifications": reflect.TypeOf(JobEmailNotifications{}), + "environment": reflect.TypeOf(JobEnvironment{}), + "git_source": reflect.TypeOf(GitSource{}), + "health": reflect.TypeOf(JobsHealthRules{}), + "job_cluster": reflect.TypeOf(JobCluster{}), + "notification_settings": reflect.TypeOf(JobNotificationSettings{}), + "parameter": reflect.TypeOf(JobParameterDefinition{}), + "queue": reflect.TypeOf(QueueSettings{}), + "run_as": reflect.TypeOf(JobRunAs{}), + "schedule": reflect.TypeOf(CronSchedule{}), + "tags": reflect.TypeOf(types.StringType), + "task": reflect.TypeOf(Task{}), + "trigger": reflect.TypeOf(TriggerSettings{}), + "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), } } func (a JobSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BudgetPolicyId": types.StringType, - "Continuous": Continuous{}.ToAttrType(ctx), - "Deployment": JobDeployment{}.ToAttrType(ctx), - "Description": types.StringType, - "EditMode": types.StringType, - "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), - "Environments": basetypes.ListType{ + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ + ElemType: Continuous{}.ToAttrType(ctx), + }, + "deployment": basetypes.ListType{ + ElemType: JobDeployment{}.ToAttrType(ctx), + }, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.ToAttrType(ctx), + }, + "environment": basetypes.ListType{ ElemType: JobEnvironment{}.ToAttrType(ctx), }, - "Format": types.StringType, - "GitSource": GitSource{}.ToAttrType(ctx), - "Health": JobsHealthRules{}.ToAttrType(ctx), - "JobClusters": basetypes.ListType{ + "format": types.StringType, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.ToAttrType(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.ToAttrType(ctx), + }, + "job_cluster": basetypes.ListType{ ElemType: JobCluster{}.ToAttrType(ctx), }, - "MaxConcurrentRuns": types.Int64Type, - "Name": types.StringType, - "NotificationSettings": JobNotificationSettings{}.ToAttrType(ctx), - "Parameters": basetypes.ListType{ + "max_concurrent_runs": types.Int64Type, + "name": types.StringType, + "notification_settings": basetypes.ListType{ + ElemType: JobNotificationSettings{}.ToAttrType(ctx), + }, + "parameter": basetypes.ListType{ ElemType: JobParameterDefinition{}.ToAttrType(ctx), }, - "Queue": QueueSettings{}.ToAttrType(ctx), - "RunAs": JobRunAs{}.ToAttrType(ctx), - "Schedule": CronSchedule{}.ToAttrType(ctx), - "Tags": basetypes.MapType{ + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.ToAttrType(ctx), + }, + "run_as": basetypes.ListType{ + ElemType: JobRunAs{}.ToAttrType(ctx), + }, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.ToAttrType(ctx), + }, + "tags": basetypes.MapType{ ElemType: types.StringType, }, - "Tasks": basetypes.ListType{ + "task": basetypes.ListType{ ElemType: Task{}.ToAttrType(ctx), }, - "TimeoutSeconds": types.Int64Type, - "Trigger": TriggerSettings{}.ToAttrType(ctx), - "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + "timeout_seconds": types.Int64Type, + "trigger": basetypes.ListType{ + ElemType: TriggerSettings{}.ToAttrType(ctx), + }, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.ToAttrType(ctx), + }, }, } } @@ -2325,9 +2405,9 @@ func (a JobSource) GetComplexFieldTypes() map[string]reflect.Type { func (a JobSource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DirtyState": types.StringType, - "ImportFromGitBranch": types.StringType, - "JobConfigPath": types.StringType, + "dirty_state": types.StringType, + "import_from_git_branch": types.StringType, + "job_config_path": types.StringType, }, } } @@ -2367,9 +2447,9 @@ func (a JobsHealthRule) GetComplexFieldTypes() map[string]reflect.Type { func (a JobsHealthRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Metric": types.StringType, - "Op": types.StringType, - "Value": types.Int64Type, + "metric": types.StringType, + "op": types.StringType, + "value": types.Int64Type, }, } } @@ -2387,14 +2467,14 @@ func (newState *JobsHealthRules) SyncEffectiveFieldsDuringRead(existingState Job func (a JobsHealthRules) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Rules": reflect.TypeOf(JobsHealthRule{}), + "rules": reflect.TypeOf(JobsHealthRule{}), } } func (a JobsHealthRules) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Rules": basetypes.ListType{ + "rules": basetypes.ListType{ ElemType: JobsHealthRule{}.ToAttrType(ctx), }, }, @@ -2422,18 +2502,18 @@ func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringRea func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Jobs": reflect.TypeOf(JobCompliance{}), + "jobs": reflect.TypeOf(JobCompliance{}), } } func (a ListJobComplianceForPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Jobs": basetypes.ListType{ + "jobs": basetypes.ListType{ ElemType: JobCompliance{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, + "next_page_token": types.StringType, + "prev_page_token": types.StringType, }, } } @@ -2464,9 +2544,9 @@ func (a ListJobComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListJobComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "PolicyId": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, + "policy_id": types.StringType, }, } } @@ -2502,11 +2582,11 @@ func (a ListJobsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListJobsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExpandTasks": types.BoolType, - "Limit": types.Int64Type, - "Name": types.StringType, - "Offset": types.Int64Type, - "PageToken": types.StringType, + "expand_tasks": types.BoolType, + "limit": types.Int64Type, + "name": types.StringType, + "offset": types.Int64Type, + "page_token": types.StringType, }, } } @@ -2534,19 +2614,19 @@ func (newState *ListJobsResponse) SyncEffectiveFieldsDuringRead(existingState Li func (a ListJobsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Jobs": reflect.TypeOf(BaseJob{}), + "jobs": reflect.TypeOf(BaseJob{}), } } func (a ListJobsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "HasMore": types.BoolType, - "Jobs": basetypes.ListType{ + "has_more": types.BoolType, + "jobs": basetypes.ListType{ ElemType: BaseJob{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, + "next_page_token": types.StringType, + "prev_page_token": types.StringType, }, } } @@ -2604,16 +2684,16 @@ func (a ListRunsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListRunsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActiveOnly": types.BoolType, - "CompletedOnly": types.BoolType, - "ExpandTasks": types.BoolType, - "JobId": types.Int64Type, - "Limit": types.Int64Type, - "Offset": types.Int64Type, - "PageToken": types.StringType, - "RunType": types.StringType, - "StartTimeFrom": types.Int64Type, - "StartTimeTo": types.Int64Type, + "active_only": types.BoolType, + "completed_only": types.BoolType, + "expand_tasks": types.BoolType, + "job_id": types.Int64Type, + "limit": types.Int64Type, + "offset": types.Int64Type, + "page_token": types.StringType, + "run_type": types.StringType, + "start_time_from": types.Int64Type, + "start_time_to": types.Int64Type, }, } } @@ -2641,17 +2721,17 @@ func (newState *ListRunsResponse) SyncEffectiveFieldsDuringRead(existingState Li func (a ListRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Runs": reflect.TypeOf(BaseRun{}), + "runs": reflect.TypeOf(BaseRun{}), } } func (a ListRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "HasMore": types.BoolType, - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, - "Runs": basetypes.ListType{ + "has_more": types.BoolType, + "next_page_token": types.StringType, + "prev_page_token": types.StringType, + "runs": basetypes.ListType{ ElemType: BaseRun{}.ToAttrType(ctx), }, }, @@ -2683,8 +2763,8 @@ func (a NotebookOutput) GetComplexFieldTypes() map[string]reflect.Type { func (a NotebookOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Result": types.StringType, - "Truncated": types.BoolType, + "result": types.StringType, + "truncated": types.BoolType, }, } } @@ -2738,19 +2818,19 @@ func (newState *NotebookTask) SyncEffectiveFieldsDuringRead(existingState Notebo func (a NotebookTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "BaseParameters": reflect.TypeOf(types.StringType), + "base_parameters": reflect.TypeOf(types.StringType), } } func (a NotebookTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BaseParameters": basetypes.MapType{ + "base_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "NotebookPath": types.StringType, - "Source": types.StringType, - "WarehouseId": types.StringType, + "notebook_path": types.StringType, + "source": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -2775,8 +2855,8 @@ func (a PeriodicTriggerConfiguration) GetComplexFieldTypes() map[string]reflect. func (a PeriodicTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Interval": types.Int64Type, - "Unit": types.StringType, + "interval": types.Int64Type, + "unit": types.StringType, }, } } @@ -2799,7 +2879,7 @@ func (a PipelineParams) GetComplexFieldTypes() map[string]reflect.Type { func (a PipelineParams) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullRefresh": types.BoolType, + "full_refresh": types.BoolType, }, } } @@ -2824,8 +2904,8 @@ func (a PipelineTask) GetComplexFieldTypes() map[string]reflect.Type { func (a PipelineTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FullRefresh": types.BoolType, - "PipelineId": types.StringType, + "full_refresh": types.BoolType, + "pipeline_id": types.StringType, }, } } @@ -2854,20 +2934,20 @@ func (newState *PythonWheelTask) SyncEffectiveFieldsDuringRead(existingState Pyt func (a PythonWheelTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NamedParameters": reflect.TypeOf(types.StringType), - "Parameters": reflect.TypeOf(types.StringType), + "named_parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a PythonWheelTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EntryPoint": types.StringType, - "NamedParameters": basetypes.MapType{ + "entry_point": types.StringType, + "named_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "PackageName": types.StringType, - "Parameters": basetypes.ListType{ + "package_name": types.StringType, + "parameters": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -2900,8 +2980,8 @@ func (a QueueDetails) GetComplexFieldTypes() map[string]reflect.Type { func (a QueueDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Code": types.StringType, - "Message": types.StringType, + "code": types.StringType, + "message": types.StringType, }, } } @@ -2924,7 +3004,7 @@ func (a QueueSettings) GetComplexFieldTypes() map[string]reflect.Type { func (a QueueSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, + "enabled": types.BoolType, }, } } @@ -2957,24 +3037,28 @@ func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringRead(existingState R func (a RepairHistoryItem) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "State": reflect.TypeOf(RunState{}), - "Status": reflect.TypeOf(RunStatus{}), - "TaskRunIds": reflect.TypeOf(types.Int64Type), + "state": reflect.TypeOf(RunState{}), + "status": reflect.TypeOf(RunStatus{}), + "task_run_ids": reflect.TypeOf(types.Int64Type), } } func (a RepairHistoryItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndTime": types.Int64Type, - "Id": types.Int64Type, - "StartTime": types.Int64Type, - "State": RunState{}.ToAttrType(ctx), - "Status": RunStatus{}.ToAttrType(ctx), - "TaskRunIds": basetypes.ListType{ + "end_time": types.Int64Type, + "id": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ + ElemType: RunState{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.ToAttrType(ctx), + }, + "task_run_ids": basetypes.ListType{ ElemType: types.Int64Type, }, - "Type": types.StringType, + "type": types.StringType, }, } } @@ -3090,52 +3174,54 @@ func (newState *RepairRun) SyncEffectiveFieldsDuringRead(existingState RepairRun func (a RepairRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(types.StringType), - "JarParams": reflect.TypeOf(types.StringType), - "JobParameters": reflect.TypeOf(types.StringType), - "NotebookParams": reflect.TypeOf(types.StringType), - "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(types.StringType), - "PythonParams": reflect.TypeOf(types.StringType), - "RerunTasks": reflect.TypeOf(types.StringType), - "SparkSubmitParams": reflect.TypeOf(types.StringType), - "SqlParams": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.StringType), + "jar_params": reflect.TypeOf(types.StringType), + "job_parameters": reflect.TypeOf(types.StringType), + "notebook_params": reflect.TypeOf(types.StringType), + "pipeline_params": reflect.TypeOf(PipelineParams{}), + "python_named_params": reflect.TypeOf(types.StringType), + "python_params": reflect.TypeOf(types.StringType), + "rerun_tasks": reflect.TypeOf(types.StringType), + "spark_submit_params": reflect.TypeOf(types.StringType), + "sql_params": reflect.TypeOf(types.StringType), } } func (a RepairRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbtCommands": basetypes.ListType{ + "dbt_commands": basetypes.ListType{ ElemType: types.StringType, }, - "JarParams": basetypes.ListType{ + "jar_params": basetypes.ListType{ ElemType: types.StringType, }, - "JobParameters": basetypes.MapType{ + "job_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "LatestRepairId": types.Int64Type, - "NotebookParams": basetypes.MapType{ + "latest_repair_id": types.Int64Type, + "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "PipelineParams": PipelineParams{}.ToAttrType(ctx), - "PythonNamedParams": basetypes.MapType{ + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.ToAttrType(ctx), + }, + "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, - "PythonParams": basetypes.ListType{ + "python_params": basetypes.ListType{ ElemType: types.StringType, }, - "RerunAllFailedTasks": types.BoolType, - "RerunDependentTasks": types.BoolType, - "RerunTasks": basetypes.ListType{ + "rerun_all_failed_tasks": types.BoolType, + "rerun_dependent_tasks": types.BoolType, + "rerun_tasks": basetypes.ListType{ ElemType: types.StringType, }, - "RunId": types.Int64Type, - "SparkSubmitParams": basetypes.ListType{ + "run_id": types.Int64Type, + "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, }, - "SqlParams": basetypes.MapType{ + "sql_params": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -3162,7 +3248,7 @@ func (a RepairRunResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a RepairRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RepairId": types.Int64Type, + "repair_id": types.Int64Type, }, } } @@ -3186,15 +3272,17 @@ func (newState *ResetJob) SyncEffectiveFieldsDuringRead(existingState ResetJob) func (a ResetJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NewSettings": reflect.TypeOf(JobSettings{}), + "new_settings": reflect.TypeOf(JobSettings{}), } } func (a ResetJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.Int64Type, - "NewSettings": JobSettings{}.ToAttrType(ctx), + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ + ElemType: JobSettings{}.ToAttrType(ctx), + }, }, } } @@ -3237,8 +3325,8 @@ func (a ResolvedConditionTaskValues) GetComplexFieldTypes() map[string]reflect.T func (a ResolvedConditionTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Left": types.StringType, - "Right": types.StringType, + "left": types.StringType, + "right": types.StringType, }, } } @@ -3255,14 +3343,14 @@ func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringRead(existingSta func (a ResolvedDbtTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Commands": reflect.TypeOf(types.StringType), + "commands": reflect.TypeOf(types.StringType), } } func (a ResolvedDbtTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Commands": basetypes.ListType{ + "commands": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3281,14 +3369,14 @@ func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existi func (a ResolvedNotebookTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "BaseParameters": reflect.TypeOf(types.StringType), + "base_parameters": reflect.TypeOf(types.StringType), } } func (a ResolvedNotebookTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BaseParameters": basetypes.MapType{ + "base_parameters": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -3307,14 +3395,14 @@ func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringRead(existingS func (a ResolvedParamPairValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a ResolvedParamPairValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Parameters": basetypes.MapType{ + "parameters": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -3335,18 +3423,18 @@ func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringRead(exi func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "NamedParameters": reflect.TypeOf(types.StringType), - "Parameters": reflect.TypeOf(types.StringType), + "named_parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a ResolvedPythonWheelTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NamedParameters": basetypes.MapType{ + "named_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "Parameters": basetypes.ListType{ + "parameters": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3367,18 +3455,18 @@ func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringRead(existing func (a ResolvedRunJobTaskValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "JobParameters": reflect.TypeOf(types.StringType), - "Parameters": reflect.TypeOf(types.StringType), + "job_parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a ResolvedRunJobTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobParameters": basetypes.MapType{ + "job_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "Parameters": basetypes.MapType{ + "parameters": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -3397,14 +3485,14 @@ func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringRead(existi func (a ResolvedStringParamsValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a ResolvedStringParamsValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Parameters": basetypes.ListType{ + "parameters": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3441,32 +3529,52 @@ func (newState *ResolvedValues) SyncEffectiveFieldsDuringRead(existingState Reso func (a ResolvedValues) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ConditionTask": reflect.TypeOf(ResolvedConditionTaskValues{}), - "DbtTask": reflect.TypeOf(ResolvedDbtTaskValues{}), - "NotebookTask": reflect.TypeOf(ResolvedNotebookTaskValues{}), - "PythonWheelTask": reflect.TypeOf(ResolvedPythonWheelTaskValues{}), - "RunJobTask": reflect.TypeOf(ResolvedRunJobTaskValues{}), - "SimulationTask": reflect.TypeOf(ResolvedParamPairValues{}), - "SparkJarTask": reflect.TypeOf(ResolvedStringParamsValues{}), - "SparkPythonTask": reflect.TypeOf(ResolvedStringParamsValues{}), - "SparkSubmitTask": reflect.TypeOf(ResolvedStringParamsValues{}), - "SqlTask": reflect.TypeOf(ResolvedParamPairValues{}), + "condition_task": reflect.TypeOf(ResolvedConditionTaskValues{}), + "dbt_task": reflect.TypeOf(ResolvedDbtTaskValues{}), + "notebook_task": reflect.TypeOf(ResolvedNotebookTaskValues{}), + "python_wheel_task": reflect.TypeOf(ResolvedPythonWheelTaskValues{}), + "run_job_task": reflect.TypeOf(ResolvedRunJobTaskValues{}), + "simulation_task": reflect.TypeOf(ResolvedParamPairValues{}), + "spark_jar_task": reflect.TypeOf(ResolvedStringParamsValues{}), + "spark_python_task": reflect.TypeOf(ResolvedStringParamsValues{}), + "spark_submit_task": reflect.TypeOf(ResolvedStringParamsValues{}), + "sql_task": reflect.TypeOf(ResolvedParamPairValues{}), } } func (a ResolvedValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConditionTask": ResolvedConditionTaskValues{}.ToAttrType(ctx), - "DbtTask": ResolvedDbtTaskValues{}.ToAttrType(ctx), - "NotebookTask": ResolvedNotebookTaskValues{}.ToAttrType(ctx), - "PythonWheelTask": ResolvedPythonWheelTaskValues{}.ToAttrType(ctx), - "RunJobTask": ResolvedRunJobTaskValues{}.ToAttrType(ctx), - "SimulationTask": ResolvedParamPairValues{}.ToAttrType(ctx), - "SparkJarTask": ResolvedStringParamsValues{}.ToAttrType(ctx), - "SparkPythonTask": ResolvedStringParamsValues{}.ToAttrType(ctx), - "SparkSubmitTask": ResolvedStringParamsValues{}.ToAttrType(ctx), - "SqlTask": ResolvedParamPairValues{}.ToAttrType(ctx), + "condition_task": basetypes.ListType{ + ElemType: ResolvedConditionTaskValues{}.ToAttrType(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: ResolvedDbtTaskValues{}.ToAttrType(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: ResolvedNotebookTaskValues{}.ToAttrType(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: ResolvedPythonWheelTaskValues{}.ToAttrType(ctx), + }, + "run_job_task": basetypes.ListType{ + ElemType: ResolvedRunJobTaskValues{}.ToAttrType(ctx), + }, + "simulation_task": basetypes.ListType{ + ElemType: ResolvedParamPairValues{}.ToAttrType(ctx), + }, + "spark_jar_task": basetypes.ListType{ + ElemType: ResolvedStringParamsValues{}.ToAttrType(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: ResolvedStringParamsValues{}.ToAttrType(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: ResolvedStringParamsValues{}.ToAttrType(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: ResolvedParamPairValues{}.ToAttrType(ctx), + }, }, } } @@ -3615,68 +3723,84 @@ func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { func (a Run) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ClusterInstance": reflect.TypeOf(ClusterInstance{}), - "ClusterSpec": reflect.TypeOf(ClusterSpec{}), - "GitSource": reflect.TypeOf(GitSource{}), - "Iterations": reflect.TypeOf(RunTask{}), - "JobClusters": reflect.TypeOf(JobCluster{}), - "JobParameters": reflect.TypeOf(JobParameter{}), - "OverridingParameters": reflect.TypeOf(RunParameters{}), - "RepairHistory": reflect.TypeOf(RepairHistoryItem{}), - "Schedule": reflect.TypeOf(CronSchedule{}), - "State": reflect.TypeOf(RunState{}), - "Status": reflect.TypeOf(RunStatus{}), - "Tasks": reflect.TypeOf(RunTask{}), - "TriggerInfo": reflect.TypeOf(TriggerInfo{}), + "cluster_instance": reflect.TypeOf(ClusterInstance{}), + "cluster_spec": reflect.TypeOf(ClusterSpec{}), + "git_source": reflect.TypeOf(GitSource{}), + "iterations": reflect.TypeOf(RunTask{}), + "job_clusters": reflect.TypeOf(JobCluster{}), + "job_parameters": reflect.TypeOf(JobParameter{}), + "overriding_parameters": reflect.TypeOf(RunParameters{}), + "repair_history": reflect.TypeOf(RepairHistoryItem{}), + "schedule": reflect.TypeOf(CronSchedule{}), + "state": reflect.TypeOf(RunState{}), + "status": reflect.TypeOf(RunStatus{}), + "tasks": reflect.TypeOf(RunTask{}), + "trigger_info": reflect.TypeOf(TriggerInfo{}), } } func (a Run) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AttemptNumber": types.Int64Type, - "CleanupDuration": types.Int64Type, - "ClusterInstance": ClusterInstance{}.ToAttrType(ctx), - "ClusterSpec": ClusterSpec{}.ToAttrType(ctx), - "CreatorUserName": types.StringType, - "Description": types.StringType, - "EndTime": types.Int64Type, - "ExecutionDuration": types.Int64Type, - "GitSource": GitSource{}.ToAttrType(ctx), - "Iterations": basetypes.ListType{ + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ + ElemType: ClusterInstance{}.ToAttrType(ctx), + }, + "cluster_spec": basetypes.ListType{ + ElemType: ClusterSpec{}.ToAttrType(ctx), + }, + "creator_user_name": types.StringType, + "description": types.StringType, + "end_time": types.Int64Type, + "execution_duration": types.Int64Type, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.ToAttrType(ctx), + }, + "iterations": basetypes.ListType{ ElemType: RunTask{}.ToAttrType(ctx), }, - "JobClusters": basetypes.ListType{ + "job_clusters": basetypes.ListType{ ElemType: JobCluster{}.ToAttrType(ctx), }, - "JobId": types.Int64Type, - "JobParameters": basetypes.ListType{ + "job_id": types.Int64Type, + "job_parameters": basetypes.ListType{ ElemType: JobParameter{}.ToAttrType(ctx), }, - "JobRunId": types.Int64Type, - "NextPageToken": types.StringType, - "NumberInJob": types.Int64Type, - "OriginalAttemptRunId": types.Int64Type, - "OverridingParameters": RunParameters{}.ToAttrType(ctx), - "QueueDuration": types.Int64Type, - "RepairHistory": basetypes.ListType{ + "job_run_id": types.Int64Type, + "next_page_token": types.StringType, + "number_in_job": types.Int64Type, + "original_attempt_run_id": types.Int64Type, + "overriding_parameters": basetypes.ListType{ + ElemType: RunParameters{}.ToAttrType(ctx), + }, + "queue_duration": types.Int64Type, + "repair_history": basetypes.ListType{ ElemType: RepairHistoryItem{}.ToAttrType(ctx), }, - "RunDuration": types.Int64Type, - "RunId": types.Int64Type, - "RunName": types.StringType, - "RunPageUrl": types.StringType, - "RunType": types.StringType, - "Schedule": CronSchedule{}.ToAttrType(ctx), - "SetupDuration": types.Int64Type, - "StartTime": types.Int64Type, - "State": RunState{}.ToAttrType(ctx), - "Status": RunStatus{}.ToAttrType(ctx), - "Tasks": basetypes.ListType{ + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.ToAttrType(ctx), + }, + "setup_duration": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ + ElemType: RunState{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.ToAttrType(ctx), + }, + "tasks": basetypes.ListType{ ElemType: RunTask{}.ToAttrType(ctx), }, - "Trigger": types.StringType, - "TriggerInfo": TriggerInfo{}.ToAttrType(ctx), + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ + ElemType: TriggerInfo{}.ToAttrType(ctx), + }, }, } } @@ -3717,10 +3841,10 @@ func (a RunConditionTask) GetComplexFieldTypes() map[string]reflect.Type { func (a RunConditionTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Left": types.StringType, - "Op": types.StringType, - "Outcome": types.StringType, - "Right": types.StringType, + "left": types.StringType, + "op": types.StringType, + "outcome": types.StringType, + "right": types.StringType, }, } } @@ -3748,18 +3872,22 @@ func (newState *RunForEachTask) SyncEffectiveFieldsDuringRead(existingState RunF func (a RunForEachTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Stats": reflect.TypeOf(ForEachStats{}), - "Task": reflect.TypeOf(Task{}), + "stats": reflect.TypeOf(ForEachStats{}), + "task": reflect.TypeOf(Task{}), } } func (a RunForEachTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Concurrency": types.Int64Type, - "Inputs": types.StringType, - "Stats": ForEachStats{}.ToAttrType(ctx), - "Task": Task{}.ToAttrType(ctx), + "concurrency": types.Int64Type, + "inputs": types.StringType, + "stats": basetypes.ListType{ + ElemType: ForEachStats{}.ToAttrType(ctx), + }, + "task": basetypes.ListType{ + ElemType: Task{}.ToAttrType(ctx), + }, }, } } @@ -3782,7 +3910,7 @@ func (a RunJobOutput) GetComplexFieldTypes() map[string]reflect.Type { func (a RunJobOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -3884,45 +4012,47 @@ func (newState *RunJobTask) SyncEffectiveFieldsDuringRead(existingState RunJobTa func (a RunJobTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(types.StringType), - "JarParams": reflect.TypeOf(types.StringType), - "JobParameters": reflect.TypeOf(types.StringType), - "NotebookParams": reflect.TypeOf(types.StringType), - "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(types.StringType), - "PythonParams": reflect.TypeOf(types.StringType), - "SparkSubmitParams": reflect.TypeOf(types.StringType), - "SqlParams": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.StringType), + "jar_params": reflect.TypeOf(types.StringType), + "job_parameters": reflect.TypeOf(types.StringType), + "notebook_params": reflect.TypeOf(types.StringType), + "pipeline_params": reflect.TypeOf(PipelineParams{}), + "python_named_params": reflect.TypeOf(types.StringType), + "python_params": reflect.TypeOf(types.StringType), + "spark_submit_params": reflect.TypeOf(types.StringType), + "sql_params": reflect.TypeOf(types.StringType), } } func (a RunJobTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbtCommands": basetypes.ListType{ + "dbt_commands": basetypes.ListType{ ElemType: types.StringType, }, - "JarParams": basetypes.ListType{ + "jar_params": basetypes.ListType{ ElemType: types.StringType, }, - "JobId": types.Int64Type, - "JobParameters": basetypes.MapType{ + "job_id": types.Int64Type, + "job_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "NotebookParams": basetypes.MapType{ + "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "PipelineParams": PipelineParams{}.ToAttrType(ctx), - "PythonNamedParams": basetypes.MapType{ + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.ToAttrType(ctx), + }, + "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, - "PythonParams": basetypes.ListType{ + "python_params": basetypes.ListType{ ElemType: types.StringType, }, - "SparkSubmitParams": basetypes.ListType{ + "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, }, - "SqlParams": basetypes.MapType{ + "sql_params": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -4047,52 +4177,56 @@ func (newState *RunNow) SyncEffectiveFieldsDuringRead(existingState RunNow) { func (a RunNow) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(types.StringType), - "JarParams": reflect.TypeOf(types.StringType), - "JobParameters": reflect.TypeOf(types.StringType), - "NotebookParams": reflect.TypeOf(types.StringType), - "Only": reflect.TypeOf(types.StringType), - "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(types.StringType), - "PythonParams": reflect.TypeOf(types.StringType), - "Queue": reflect.TypeOf(QueueSettings{}), - "SparkSubmitParams": reflect.TypeOf(types.StringType), - "SqlParams": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.StringType), + "jar_params": reflect.TypeOf(types.StringType), + "job_parameters": reflect.TypeOf(types.StringType), + "notebook_params": reflect.TypeOf(types.StringType), + "only": reflect.TypeOf(types.StringType), + "pipeline_params": reflect.TypeOf(PipelineParams{}), + "python_named_params": reflect.TypeOf(types.StringType), + "python_params": reflect.TypeOf(types.StringType), + "queue": reflect.TypeOf(QueueSettings{}), + "spark_submit_params": reflect.TypeOf(types.StringType), + "sql_params": reflect.TypeOf(types.StringType), } } func (a RunNow) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbtCommands": basetypes.ListType{ + "dbt_commands": basetypes.ListType{ ElemType: types.StringType, }, - "IdempotencyToken": types.StringType, - "JarParams": basetypes.ListType{ + "idempotency_token": types.StringType, + "jar_params": basetypes.ListType{ ElemType: types.StringType, }, - "JobId": types.Int64Type, - "JobParameters": basetypes.MapType{ + "job_id": types.Int64Type, + "job_parameters": basetypes.MapType{ ElemType: types.StringType, }, - "NotebookParams": basetypes.MapType{ + "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "Only": basetypes.ListType{ + "only": basetypes.ListType{ ElemType: types.StringType, }, - "PipelineParams": PipelineParams{}.ToAttrType(ctx), - "PythonNamedParams": basetypes.MapType{ + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.ToAttrType(ctx), + }, + "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, - "PythonParams": basetypes.ListType{ + "python_params": basetypes.ListType{ ElemType: types.StringType, }, - "Queue": QueueSettings{}.ToAttrType(ctx), - "SparkSubmitParams": basetypes.ListType{ + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.ToAttrType(ctx), + }, + "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, }, - "SqlParams": basetypes.MapType{ + "sql_params": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -4121,8 +4255,8 @@ func (a RunNowResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a RunNowResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NumberInJob": types.Int64Type, - "RunId": types.Int64Type, + "number_in_job": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -4175,27 +4309,37 @@ func (newState *RunOutput) SyncEffectiveFieldsDuringRead(existingState RunOutput func (a RunOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtOutput": reflect.TypeOf(DbtOutput{}), - "Metadata": reflect.TypeOf(Run{}), - "NotebookOutput": reflect.TypeOf(NotebookOutput{}), - "RunJobOutput": reflect.TypeOf(RunJobOutput{}), - "SqlOutput": reflect.TypeOf(SqlOutput{}), + "dbt_output": reflect.TypeOf(DbtOutput{}), + "metadata": reflect.TypeOf(Run{}), + "notebook_output": reflect.TypeOf(NotebookOutput{}), + "run_job_output": reflect.TypeOf(RunJobOutput{}), + "sql_output": reflect.TypeOf(SqlOutput{}), } } func (a RunOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbtOutput": DbtOutput{}.ToAttrType(ctx), - "Error": types.StringType, - "ErrorTrace": types.StringType, - "Info": types.StringType, - "Logs": types.StringType, - "LogsTruncated": types.BoolType, - "Metadata": Run{}.ToAttrType(ctx), - "NotebookOutput": NotebookOutput{}.ToAttrType(ctx), - "RunJobOutput": RunJobOutput{}.ToAttrType(ctx), - "SqlOutput": SqlOutput{}.ToAttrType(ctx), + "dbt_output": basetypes.ListType{ + ElemType: DbtOutput{}.ToAttrType(ctx), + }, + "error": types.StringType, + "error_trace": types.StringType, + "info": types.StringType, + "logs": types.StringType, + "logs_truncated": types.BoolType, + "metadata": basetypes.ListType{ + ElemType: Run{}.ToAttrType(ctx), + }, + "notebook_output": basetypes.ListType{ + ElemType: NotebookOutput{}.ToAttrType(ctx), + }, + "run_job_output": basetypes.ListType{ + ElemType: RunJobOutput{}.ToAttrType(ctx), + }, + "sql_output": basetypes.ListType{ + ElemType: SqlOutput{}.ToAttrType(ctx), + }, }, } } @@ -4293,40 +4437,42 @@ func (newState *RunParameters) SyncEffectiveFieldsDuringRead(existingState RunPa func (a RunParameters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DbtCommands": reflect.TypeOf(types.StringType), - "JarParams": reflect.TypeOf(types.StringType), - "NotebookParams": reflect.TypeOf(types.StringType), - "PipelineParams": reflect.TypeOf(PipelineParams{}), - "PythonNamedParams": reflect.TypeOf(types.StringType), - "PythonParams": reflect.TypeOf(types.StringType), - "SparkSubmitParams": reflect.TypeOf(types.StringType), - "SqlParams": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.StringType), + "jar_params": reflect.TypeOf(types.StringType), + "notebook_params": reflect.TypeOf(types.StringType), + "pipeline_params": reflect.TypeOf(PipelineParams{}), + "python_named_params": reflect.TypeOf(types.StringType), + "python_params": reflect.TypeOf(types.StringType), + "spark_submit_params": reflect.TypeOf(types.StringType), + "sql_params": reflect.TypeOf(types.StringType), } } func (a RunParameters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbtCommands": basetypes.ListType{ + "dbt_commands": basetypes.ListType{ ElemType: types.StringType, }, - "JarParams": basetypes.ListType{ + "jar_params": basetypes.ListType{ ElemType: types.StringType, }, - "NotebookParams": basetypes.MapType{ + "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "PipelineParams": PipelineParams{}.ToAttrType(ctx), - "PythonNamedParams": basetypes.MapType{ + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.ToAttrType(ctx), + }, + "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, - "PythonParams": basetypes.ListType{ + "python_params": basetypes.ListType{ ElemType: types.StringType, }, - "SparkSubmitParams": basetypes.ListType{ + "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, }, - "SqlParams": basetypes.MapType{ + "sql_params": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -4364,11 +4510,11 @@ func (a RunState) GetComplexFieldTypes() map[string]reflect.Type { func (a RunState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LifeCycleState": types.StringType, - "QueueReason": types.StringType, - "ResultState": types.StringType, - "StateMessage": types.StringType, - "UserCancelledOrTimedout": types.BoolType, + "life_cycle_state": types.StringType, + "queue_reason": types.StringType, + "result_state": types.StringType, + "state_message": types.StringType, + "user_cancelled_or_timedout": types.BoolType, }, } } @@ -4392,17 +4538,21 @@ func (newState *RunStatus) SyncEffectiveFieldsDuringRead(existingState RunStatus func (a RunStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "QueueDetails": reflect.TypeOf(QueueDetails{}), - "TerminationDetails": reflect.TypeOf(TerminationDetails{}), + "queue_details": reflect.TypeOf(QueueDetails{}), + "termination_details": reflect.TypeOf(TerminationDetails{}), } } func (a RunStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueueDetails": QueueDetails{}.ToAttrType(ctx), - "State": types.StringType, - "TerminationDetails": TerminationDetails{}.ToAttrType(ctx), + "queue_details": basetypes.ListType{ + ElemType: QueueDetails{}.ToAttrType(ctx), + }, + "state": types.StringType, + "termination_details": basetypes.ListType{ + ElemType: TerminationDetails{}.ToAttrType(ctx), + }, }, } } @@ -4583,77 +4733,117 @@ func (newState *RunTask) SyncEffectiveFieldsDuringRead(existingState RunTask) { func (a RunTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ClusterInstance": reflect.TypeOf(ClusterInstance{}), - "ConditionTask": reflect.TypeOf(RunConditionTask{}), - "DbtTask": reflect.TypeOf(DbtTask{}), - "DependsOn": reflect.TypeOf(TaskDependency{}), - "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), - "ForEachTask": reflect.TypeOf(RunForEachTask{}), - "GitSource": reflect.TypeOf(GitSource{}), - "Libraries": reflect.TypeOf(compute.Library{}), - "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), - "NotebookTask": reflect.TypeOf(NotebookTask{}), - "NotificationSettings": reflect.TypeOf(TaskNotificationSettings{}), - "PipelineTask": reflect.TypeOf(PipelineTask{}), - "PythonWheelTask": reflect.TypeOf(PythonWheelTask{}), - "ResolvedValues": reflect.TypeOf(ResolvedValues{}), - "RunJobTask": reflect.TypeOf(RunJobTask{}), - "SparkJarTask": reflect.TypeOf(SparkJarTask{}), - "SparkPythonTask": reflect.TypeOf(SparkPythonTask{}), - "SparkSubmitTask": reflect.TypeOf(SparkSubmitTask{}), - "SqlTask": reflect.TypeOf(SqlTask{}), - "State": reflect.TypeOf(RunState{}), - "Status": reflect.TypeOf(RunStatus{}), - "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + "cluster_instance": reflect.TypeOf(ClusterInstance{}), + "condition_task": reflect.TypeOf(RunConditionTask{}), + "dbt_task": reflect.TypeOf(DbtTask{}), + "depends_on": reflect.TypeOf(TaskDependency{}), + "email_notifications": reflect.TypeOf(JobEmailNotifications{}), + "for_each_task": reflect.TypeOf(RunForEachTask{}), + "git_source": reflect.TypeOf(GitSource{}), + "library": reflect.TypeOf(compute.Library{}), + "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "notebook_task": reflect.TypeOf(NotebookTask{}), + "notification_settings": reflect.TypeOf(TaskNotificationSettings{}), + "pipeline_task": reflect.TypeOf(PipelineTask{}), + "python_wheel_task": reflect.TypeOf(PythonWheelTask{}), + "resolved_values": reflect.TypeOf(ResolvedValues{}), + "run_job_task": reflect.TypeOf(RunJobTask{}), + "spark_jar_task": reflect.TypeOf(SparkJarTask{}), + "spark_python_task": reflect.TypeOf(SparkPythonTask{}), + "spark_submit_task": reflect.TypeOf(SparkSubmitTask{}), + "sql_task": reflect.TypeOf(SqlTask{}), + "state": reflect.TypeOf(RunState{}), + "status": reflect.TypeOf(RunStatus{}), + "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), } } func (a RunTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AttemptNumber": types.Int64Type, - "CleanupDuration": types.Int64Type, - "ClusterInstance": ClusterInstance{}.ToAttrType(ctx), - "ConditionTask": RunConditionTask{}.ToAttrType(ctx), - "DbtTask": DbtTask{}.ToAttrType(ctx), - "DependsOn": basetypes.ListType{ + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ + ElemType: ClusterInstance{}.ToAttrType(ctx), + }, + "condition_task": basetypes.ListType{ + ElemType: RunConditionTask{}.ToAttrType(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: DbtTask{}.ToAttrType(ctx), + }, + "depends_on": basetypes.ListType{ ElemType: TaskDependency{}.ToAttrType(ctx), }, - "Description": types.StringType, - "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), - "EndTime": types.Int64Type, - "EnvironmentKey": types.StringType, - "ExecutionDuration": types.Int64Type, - "ExistingClusterId": types.StringType, - "ForEachTask": RunForEachTask{}.ToAttrType(ctx), - "GitSource": GitSource{}.ToAttrType(ctx), - "JobClusterKey": types.StringType, - "Libraries": basetypes.ListType{ + "description": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.ToAttrType(ctx), + }, + "end_time": types.Int64Type, + "environment_key": types.StringType, + "execution_duration": types.Int64Type, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ + ElemType: RunForEachTask{}.ToAttrType(ctx), + }, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.ToAttrType(ctx), + }, + "job_cluster_key": types.StringType, + "library": basetypes.ListType{ ElemType: compute_tf.Library{}.ToAttrType(ctx), }, - "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), - "NotebookTask": NotebookTask{}.ToAttrType(ctx), - "NotificationSettings": TaskNotificationSettings{}.ToAttrType(ctx), - "PipelineTask": PipelineTask{}.ToAttrType(ctx), - "PythonWheelTask": PythonWheelTask{}.ToAttrType(ctx), - "QueueDuration": types.Int64Type, - "ResolvedValues": ResolvedValues{}.ToAttrType(ctx), - "RunDuration": types.Int64Type, - "RunId": types.Int64Type, - "RunIf": types.StringType, - "RunJobTask": RunJobTask{}.ToAttrType(ctx), - "RunPageUrl": types.StringType, - "SetupDuration": types.Int64Type, - "SparkJarTask": SparkJarTask{}.ToAttrType(ctx), - "SparkPythonTask": SparkPythonTask{}.ToAttrType(ctx), - "SparkSubmitTask": SparkSubmitTask{}.ToAttrType(ctx), - "SqlTask": SqlTask{}.ToAttrType(ctx), - "StartTime": types.Int64Type, - "State": RunState{}.ToAttrType(ctx), - "Status": RunStatus{}.ToAttrType(ctx), - "TaskKey": types.StringType, - "TimeoutSeconds": types.Int64Type, - "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: NotebookTask{}.ToAttrType(ctx), + }, + "notification_settings": basetypes.ListType{ + ElemType: TaskNotificationSettings{}.ToAttrType(ctx), + }, + "pipeline_task": basetypes.ListType{ + ElemType: PipelineTask{}.ToAttrType(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: PythonWheelTask{}.ToAttrType(ctx), + }, + "queue_duration": types.Int64Type, + "resolved_values": basetypes.ListType{ + ElemType: ResolvedValues{}.ToAttrType(ctx), + }, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ + ElemType: RunJobTask{}.ToAttrType(ctx), + }, + "run_page_url": types.StringType, + "setup_duration": types.Int64Type, + "spark_jar_task": basetypes.ListType{ + ElemType: SparkJarTask{}.ToAttrType(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: SparkPythonTask{}.ToAttrType(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: SparkSubmitTask{}.ToAttrType(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: SqlTask{}.ToAttrType(ctx), + }, + "start_time": types.Int64Type, + "state": basetypes.ListType{ + ElemType: RunState{}.ToAttrType(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.ToAttrType(ctx), + }, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.ToAttrType(ctx), + }, }, } } @@ -4685,16 +4875,16 @@ func (newState *SparkJarTask) SyncEffectiveFieldsDuringRead(existingState SparkJ func (a SparkJarTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a SparkJarTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JarUri": types.StringType, - "MainClassName": types.StringType, - "Parameters": basetypes.ListType{ + "jar_uri": types.StringType, + "main_class_name": types.StringType, + "parameters": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -4735,18 +4925,18 @@ func (newState *SparkPythonTask) SyncEffectiveFieldsDuringRead(existingState Spa func (a SparkPythonTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a SparkPythonTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Parameters": basetypes.ListType{ + "parameters": basetypes.ListType{ ElemType: types.StringType, }, - "PythonFile": types.StringType, - "Source": types.StringType, + "python_file": types.StringType, + "source": types.StringType, }, } } @@ -4769,14 +4959,14 @@ func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringRead(existingState Spa func (a SparkSubmitTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a SparkSubmitTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Parameters": basetypes.ListType{ + "parameters": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -4809,20 +4999,20 @@ func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringRead(existingState SqlA func (a SqlAlertOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SqlStatements": reflect.TypeOf(SqlStatementOutput{}), + "sql_statements": reflect.TypeOf(SqlStatementOutput{}), } } func (a SqlAlertOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertState": types.StringType, - "OutputLink": types.StringType, - "QueryText": types.StringType, - "SqlStatements": basetypes.ListType{ + "alert_state": types.StringType, + "output_link": types.StringType, + "query_text": types.StringType, + "sql_statements": basetypes.ListType{ ElemType: SqlStatementOutput{}.ToAttrType(ctx), }, - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -4842,15 +5032,15 @@ func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringRead(existingState func (a SqlDashboardOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Widgets": reflect.TypeOf(SqlDashboardWidgetOutput{}), + "widgets": reflect.TypeOf(SqlDashboardWidgetOutput{}), } } func (a SqlDashboardOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WarehouseId": types.StringType, - "Widgets": basetypes.ListType{ + "warehouse_id": types.StringType, + "widgets": basetypes.ListType{ ElemType: SqlDashboardWidgetOutput{}.ToAttrType(ctx), }, }, @@ -4882,20 +5072,22 @@ func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringRead(existing func (a SqlDashboardWidgetOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Error": reflect.TypeOf(SqlOutputError{}), + "error": reflect.TypeOf(SqlOutputError{}), } } func (a SqlDashboardWidgetOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndTime": types.Int64Type, - "Error": SqlOutputError{}.ToAttrType(ctx), - "OutputLink": types.StringType, - "StartTime": types.Int64Type, - "Status": types.StringType, - "WidgetId": types.StringType, - "WidgetTitle": types.StringType, + "end_time": types.Int64Type, + "error": basetypes.ListType{ + ElemType: SqlOutputError{}.ToAttrType(ctx), + }, + "output_link": types.StringType, + "start_time": types.Int64Type, + "status": types.StringType, + "widget_id": types.StringType, + "widget_title": types.StringType, }, } } @@ -4917,18 +5109,24 @@ func (newState *SqlOutput) SyncEffectiveFieldsDuringRead(existingState SqlOutput func (a SqlOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AlertOutput": reflect.TypeOf(SqlAlertOutput{}), - "DashboardOutput": reflect.TypeOf(SqlDashboardOutput{}), - "QueryOutput": reflect.TypeOf(SqlQueryOutput{}), + "alert_output": reflect.TypeOf(SqlAlertOutput{}), + "dashboard_output": reflect.TypeOf(SqlDashboardOutput{}), + "query_output": reflect.TypeOf(SqlQueryOutput{}), } } func (a SqlOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertOutput": SqlAlertOutput{}.ToAttrType(ctx), - "DashboardOutput": SqlDashboardOutput{}.ToAttrType(ctx), - "QueryOutput": SqlQueryOutput{}.ToAttrType(ctx), + "alert_output": basetypes.ListType{ + ElemType: SqlAlertOutput{}.ToAttrType(ctx), + }, + "dashboard_output": basetypes.ListType{ + ElemType: SqlDashboardOutput{}.ToAttrType(ctx), + }, + "query_output": basetypes.ListType{ + ElemType: SqlQueryOutput{}.ToAttrType(ctx), + }, }, } } @@ -4951,7 +5149,7 @@ func (a SqlOutputError) GetComplexFieldTypes() map[string]reflect.Type { func (a SqlOutputError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, + "message": types.StringType, }, } } @@ -4977,20 +5175,20 @@ func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringRead(existingState SqlQ func (a SqlQueryOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SqlStatements": reflect.TypeOf(SqlStatementOutput{}), + "sql_statements": reflect.TypeOf(SqlStatementOutput{}), } } func (a SqlQueryOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointId": types.StringType, - "OutputLink": types.StringType, - "QueryText": types.StringType, - "SqlStatements": basetypes.ListType{ + "endpoint_id": types.StringType, + "output_link": types.StringType, + "query_text": types.StringType, + "sql_statements": basetypes.ListType{ ElemType: SqlStatementOutput{}.ToAttrType(ctx), }, - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -5013,7 +5211,7 @@ func (a SqlStatementOutput) GetComplexFieldTypes() map[string]reflect.Type { func (a SqlStatementOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "LookupKey": types.StringType, + "lookup_key": types.StringType, }, } } @@ -5046,25 +5244,33 @@ func (newState *SqlTask) SyncEffectiveFieldsDuringRead(existingState SqlTask) { func (a SqlTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Alert": reflect.TypeOf(SqlTaskAlert{}), - "Dashboard": reflect.TypeOf(SqlTaskDashboard{}), - "File": reflect.TypeOf(SqlTaskFile{}), - "Parameters": reflect.TypeOf(types.StringType), - "Query": reflect.TypeOf(SqlTaskQuery{}), + "alert": reflect.TypeOf(SqlTaskAlert{}), + "dashboard": reflect.TypeOf(SqlTaskDashboard{}), + "file": reflect.TypeOf(SqlTaskFile{}), + "parameters": reflect.TypeOf(types.StringType), + "query": reflect.TypeOf(SqlTaskQuery{}), } } func (a SqlTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alert": SqlTaskAlert{}.ToAttrType(ctx), - "Dashboard": SqlTaskDashboard{}.ToAttrType(ctx), - "File": SqlTaskFile{}.ToAttrType(ctx), - "Parameters": basetypes.MapType{ + "alert": basetypes.ListType{ + ElemType: SqlTaskAlert{}.ToAttrType(ctx), + }, + "dashboard": basetypes.ListType{ + ElemType: SqlTaskDashboard{}.ToAttrType(ctx), + }, + "file": basetypes.ListType{ + ElemType: SqlTaskFile{}.ToAttrType(ctx), + }, + "parameters": basetypes.MapType{ ElemType: types.StringType, }, - "Query": SqlTaskQuery{}.ToAttrType(ctx), - "WarehouseId": types.StringType, + "query": basetypes.ListType{ + ElemType: SqlTaskQuery{}.ToAttrType(ctx), + }, + "warehouse_id": types.StringType, }, } } @@ -5086,16 +5292,16 @@ func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringRead(existingState SqlTas func (a SqlTaskAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subscriptions": reflect.TypeOf(SqlTaskSubscription{}), + "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), } } func (a SqlTaskAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertId": types.StringType, - "PauseSubscriptions": types.BoolType, - "Subscriptions": basetypes.ListType{ + "alert_id": types.StringType, + "pause_subscriptions": types.BoolType, + "subscriptions": basetypes.ListType{ ElemType: SqlTaskSubscription{}.ToAttrType(ctx), }, }, @@ -5122,17 +5328,17 @@ func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringRead(existingState Sq func (a SqlTaskDashboard) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subscriptions": reflect.TypeOf(SqlTaskSubscription{}), + "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), } } func (a SqlTaskDashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CustomSubject": types.StringType, - "DashboardId": types.StringType, - "PauseSubscriptions": types.BoolType, - "Subscriptions": basetypes.ListType{ + "custom_subject": types.StringType, + "dashboard_id": types.StringType, + "pause_subscriptions": types.BoolType, + "subscriptions": basetypes.ListType{ ElemType: SqlTaskSubscription{}.ToAttrType(ctx), }, }, @@ -5167,8 +5373,8 @@ func (a SqlTaskFile) GetComplexFieldTypes() map[string]reflect.Type { func (a SqlTaskFile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, - "Source": types.StringType, + "path": types.StringType, + "source": types.StringType, }, } } @@ -5191,7 +5397,7 @@ func (a SqlTaskQuery) GetComplexFieldTypes() map[string]reflect.Type { func (a SqlTaskQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueryId": types.StringType, + "query_id": types.StringType, }, } } @@ -5221,8 +5427,8 @@ func (a SqlTaskSubscription) GetComplexFieldTypes() map[string]reflect.Type { func (a SqlTaskSubscription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationId": types.StringType, - "UserName": types.StringType, + "destination_id": types.StringType, + "user_name": types.StringType, }, } } @@ -5297,42 +5503,56 @@ func (newState *SubmitRun) SyncEffectiveFieldsDuringRead(existingState SubmitRun func (a SubmitRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(JobAccessControlRequest{}), - "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), - "Environments": reflect.TypeOf(JobEnvironment{}), - "GitSource": reflect.TypeOf(GitSource{}), - "Health": reflect.TypeOf(JobsHealthRules{}), - "NotificationSettings": reflect.TypeOf(JobNotificationSettings{}), - "Queue": reflect.TypeOf(QueueSettings{}), - "RunAs": reflect.TypeOf(JobRunAs{}), - "Tasks": reflect.TypeOf(SubmitTask{}), - "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), + "email_notifications": reflect.TypeOf(JobEmailNotifications{}), + "environments": reflect.TypeOf(JobEnvironment{}), + "git_source": reflect.TypeOf(GitSource{}), + "health": reflect.TypeOf(JobsHealthRules{}), + "notification_settings": reflect.TypeOf(JobNotificationSettings{}), + "queue": reflect.TypeOf(QueueSettings{}), + "run_as": reflect.TypeOf(JobRunAs{}), + "tasks": reflect.TypeOf(SubmitTask{}), + "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), } } func (a SubmitRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: JobAccessControlRequest{}.ToAttrType(ctx), }, - "BudgetPolicyId": types.StringType, - "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), - "Environments": basetypes.ListType{ + "budget_policy_id": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.ToAttrType(ctx), + }, + "environments": basetypes.ListType{ ElemType: JobEnvironment{}.ToAttrType(ctx), }, - "GitSource": GitSource{}.ToAttrType(ctx), - "Health": JobsHealthRules{}.ToAttrType(ctx), - "IdempotencyToken": types.StringType, - "NotificationSettings": JobNotificationSettings{}.ToAttrType(ctx), - "Queue": QueueSettings{}.ToAttrType(ctx), - "RunAs": JobRunAs{}.ToAttrType(ctx), - "RunName": types.StringType, - "Tasks": basetypes.ListType{ + "git_source": basetypes.ListType{ + ElemType: GitSource{}.ToAttrType(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.ToAttrType(ctx), + }, + "idempotency_token": types.StringType, + "notification_settings": basetypes.ListType{ + ElemType: JobNotificationSettings{}.ToAttrType(ctx), + }, + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.ToAttrType(ctx), + }, + "run_as": basetypes.ListType{ + ElemType: JobRunAs{}.ToAttrType(ctx), + }, + "run_name": types.StringType, + "tasks": basetypes.ListType{ ElemType: SubmitTask{}.ToAttrType(ctx), }, - "TimeoutSeconds": types.Int64Type, - "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.ToAttrType(ctx), + }, }, } } @@ -5356,7 +5576,7 @@ func (a SubmitRunResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a SubmitRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -5469,58 +5689,90 @@ func (newState *SubmitTask) SyncEffectiveFieldsDuringRead(existingState SubmitTa func (a SubmitTask) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ConditionTask": reflect.TypeOf(ConditionTask{}), - "DbtTask": reflect.TypeOf(DbtTask{}), - "DependsOn": reflect.TypeOf(TaskDependency{}), - "EmailNotifications": reflect.TypeOf(JobEmailNotifications{}), - "ForEachTask": reflect.TypeOf(ForEachTask{}), - "Health": reflect.TypeOf(JobsHealthRules{}), - "Libraries": reflect.TypeOf(compute.Library{}), - "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), - "NotebookTask": reflect.TypeOf(NotebookTask{}), - "NotificationSettings": reflect.TypeOf(TaskNotificationSettings{}), - "PipelineTask": reflect.TypeOf(PipelineTask{}), - "PythonWheelTask": reflect.TypeOf(PythonWheelTask{}), - "RunJobTask": reflect.TypeOf(RunJobTask{}), - "SparkJarTask": reflect.TypeOf(SparkJarTask{}), - "SparkPythonTask": reflect.TypeOf(SparkPythonTask{}), - "SparkSubmitTask": reflect.TypeOf(SparkSubmitTask{}), - "SqlTask": reflect.TypeOf(SqlTask{}), - "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + "condition_task": reflect.TypeOf(ConditionTask{}), + "dbt_task": reflect.TypeOf(DbtTask{}), + "depends_on": reflect.TypeOf(TaskDependency{}), + "email_notifications": reflect.TypeOf(JobEmailNotifications{}), + "for_each_task": reflect.TypeOf(ForEachTask{}), + "health": reflect.TypeOf(JobsHealthRules{}), + "library": reflect.TypeOf(compute.Library{}), + "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "notebook_task": reflect.TypeOf(NotebookTask{}), + "notification_settings": reflect.TypeOf(TaskNotificationSettings{}), + "pipeline_task": reflect.TypeOf(PipelineTask{}), + "python_wheel_task": reflect.TypeOf(PythonWheelTask{}), + "run_job_task": reflect.TypeOf(RunJobTask{}), + "spark_jar_task": reflect.TypeOf(SparkJarTask{}), + "spark_python_task": reflect.TypeOf(SparkPythonTask{}), + "spark_submit_task": reflect.TypeOf(SparkSubmitTask{}), + "sql_task": reflect.TypeOf(SqlTask{}), + "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), } } func (a SubmitTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConditionTask": ConditionTask{}.ToAttrType(ctx), - "DbtTask": DbtTask{}.ToAttrType(ctx), - "DependsOn": basetypes.ListType{ + "condition_task": basetypes.ListType{ + ElemType: ConditionTask{}.ToAttrType(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: DbtTask{}.ToAttrType(ctx), + }, + "depends_on": basetypes.ListType{ ElemType: TaskDependency{}.ToAttrType(ctx), }, - "Description": types.StringType, - "EmailNotifications": JobEmailNotifications{}.ToAttrType(ctx), - "EnvironmentKey": types.StringType, - "ExistingClusterId": types.StringType, - "ForEachTask": ForEachTask{}.ToAttrType(ctx), - "Health": JobsHealthRules{}.ToAttrType(ctx), - "Libraries": basetypes.ListType{ + "description": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.ToAttrType(ctx), + }, + "environment_key": types.StringType, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ + ElemType: ForEachTask{}.ToAttrType(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.ToAttrType(ctx), + }, + "library": basetypes.ListType{ ElemType: compute_tf.Library{}.ToAttrType(ctx), }, - "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), - "NotebookTask": NotebookTask{}.ToAttrType(ctx), - "NotificationSettings": TaskNotificationSettings{}.ToAttrType(ctx), - "PipelineTask": PipelineTask{}.ToAttrType(ctx), - "PythonWheelTask": PythonWheelTask{}.ToAttrType(ctx), - "RunIf": types.StringType, - "RunJobTask": RunJobTask{}.ToAttrType(ctx), - "SparkJarTask": SparkJarTask{}.ToAttrType(ctx), - "SparkPythonTask": SparkPythonTask{}.ToAttrType(ctx), - "SparkSubmitTask": SparkSubmitTask{}.ToAttrType(ctx), - "SqlTask": SqlTask{}.ToAttrType(ctx), - "TaskKey": types.StringType, - "TimeoutSeconds": types.Int64Type, - "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: NotebookTask{}.ToAttrType(ctx), + }, + "notification_settings": basetypes.ListType{ + ElemType: TaskNotificationSettings{}.ToAttrType(ctx), + }, + "pipeline_task": basetypes.ListType{ + ElemType: PipelineTask{}.ToAttrType(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: PythonWheelTask{}.ToAttrType(ctx), + }, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ + ElemType: RunJobTask{}.ToAttrType(ctx), + }, + "spark_jar_task": basetypes.ListType{ + ElemType: SparkJarTask{}.ToAttrType(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: SparkPythonTask{}.ToAttrType(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: SparkSubmitTask{}.ToAttrType(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: SqlTask{}.ToAttrType(ctx), + }, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.ToAttrType(ctx), + }, }, } } @@ -5550,19 +5802,19 @@ func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringRead(e func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TableNames": reflect.TypeOf(types.StringType), + "table_names": reflect.TypeOf(types.StringType), } } func (a TableUpdateTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Condition": types.StringType, - "MinTimeBetweenTriggersSeconds": types.Int64Type, - "TableNames": basetypes.ListType{ + "condition": types.StringType, + "min_time_between_triggers_seconds": types.Int64Type, + "table_names": basetypes.ListType{ ElemType: types.StringType, }, - "WaitAfterLastChangeSeconds": types.Int64Type, + "wait_after_last_change_seconds": types.Int64Type, }, } } @@ -5698,63 +5950,95 @@ func (newState *Task) SyncEffectiveFieldsDuringRead(existingState Task) { func (a Task) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ConditionTask": reflect.TypeOf(ConditionTask{}), - "DbtTask": reflect.TypeOf(DbtTask{}), - "DependsOn": reflect.TypeOf(TaskDependency{}), - "EmailNotifications": reflect.TypeOf(TaskEmailNotifications{}), - "ForEachTask": reflect.TypeOf(ForEachTask{}), - "Health": reflect.TypeOf(JobsHealthRules{}), - "Libraries": reflect.TypeOf(compute.Library{}), - "NewCluster": reflect.TypeOf(compute.ClusterSpec{}), - "NotebookTask": reflect.TypeOf(NotebookTask{}), - "NotificationSettings": reflect.TypeOf(TaskNotificationSettings{}), - "PipelineTask": reflect.TypeOf(PipelineTask{}), - "PythonWheelTask": reflect.TypeOf(PythonWheelTask{}), - "RunJobTask": reflect.TypeOf(RunJobTask{}), - "SparkJarTask": reflect.TypeOf(SparkJarTask{}), - "SparkPythonTask": reflect.TypeOf(SparkPythonTask{}), - "SparkSubmitTask": reflect.TypeOf(SparkSubmitTask{}), - "SqlTask": reflect.TypeOf(SqlTask{}), - "WebhookNotifications": reflect.TypeOf(WebhookNotifications{}), + "condition_task": reflect.TypeOf(ConditionTask{}), + "dbt_task": reflect.TypeOf(DbtTask{}), + "depends_on": reflect.TypeOf(TaskDependency{}), + "email_notifications": reflect.TypeOf(TaskEmailNotifications{}), + "for_each_task": reflect.TypeOf(ForEachTask{}), + "health": reflect.TypeOf(JobsHealthRules{}), + "library": reflect.TypeOf(compute.Library{}), + "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "notebook_task": reflect.TypeOf(NotebookTask{}), + "notification_settings": reflect.TypeOf(TaskNotificationSettings{}), + "pipeline_task": reflect.TypeOf(PipelineTask{}), + "python_wheel_task": reflect.TypeOf(PythonWheelTask{}), + "run_job_task": reflect.TypeOf(RunJobTask{}), + "spark_jar_task": reflect.TypeOf(SparkJarTask{}), + "spark_python_task": reflect.TypeOf(SparkPythonTask{}), + "spark_submit_task": reflect.TypeOf(SparkSubmitTask{}), + "sql_task": reflect.TypeOf(SqlTask{}), + "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), } } func (a Task) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConditionTask": ConditionTask{}.ToAttrType(ctx), - "DbtTask": DbtTask{}.ToAttrType(ctx), - "DependsOn": basetypes.ListType{ + "condition_task": basetypes.ListType{ + ElemType: ConditionTask{}.ToAttrType(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: DbtTask{}.ToAttrType(ctx), + }, + "depends_on": basetypes.ListType{ ElemType: TaskDependency{}.ToAttrType(ctx), }, - "Description": types.StringType, - "DisableAutoOptimization": types.BoolType, - "EmailNotifications": TaskEmailNotifications{}.ToAttrType(ctx), - "EnvironmentKey": types.StringType, - "ExistingClusterId": types.StringType, - "ForEachTask": ForEachTask{}.ToAttrType(ctx), - "Health": JobsHealthRules{}.ToAttrType(ctx), - "JobClusterKey": types.StringType, - "Libraries": basetypes.ListType{ + "description": types.StringType, + "disable_auto_optimization": types.BoolType, + "email_notifications": basetypes.ListType{ + ElemType: TaskEmailNotifications{}.ToAttrType(ctx), + }, + "environment_key": types.StringType, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ + ElemType: ForEachTask{}.ToAttrType(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.ToAttrType(ctx), + }, + "job_cluster_key": types.StringType, + "library": basetypes.ListType{ ElemType: compute_tf.Library{}.ToAttrType(ctx), }, - "MaxRetries": types.Int64Type, - "MinRetryIntervalMillis": types.Int64Type, - "NewCluster": compute_tf.ClusterSpec{}.ToAttrType(ctx), - "NotebookTask": NotebookTask{}.ToAttrType(ctx), - "NotificationSettings": TaskNotificationSettings{}.ToAttrType(ctx), - "PipelineTask": PipelineTask{}.ToAttrType(ctx), - "PythonWheelTask": PythonWheelTask{}.ToAttrType(ctx), - "RetryOnTimeout": types.BoolType, - "RunIf": types.StringType, - "RunJobTask": RunJobTask{}.ToAttrType(ctx), - "SparkJarTask": SparkJarTask{}.ToAttrType(ctx), - "SparkPythonTask": SparkPythonTask{}.ToAttrType(ctx), - "SparkSubmitTask": SparkSubmitTask{}.ToAttrType(ctx), - "SqlTask": SqlTask{}.ToAttrType(ctx), - "TaskKey": types.StringType, - "TimeoutSeconds": types.Int64Type, - "WebhookNotifications": WebhookNotifications{}.ToAttrType(ctx), + "max_retries": types.Int64Type, + "min_retry_interval_millis": types.Int64Type, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: NotebookTask{}.ToAttrType(ctx), + }, + "notification_settings": basetypes.ListType{ + ElemType: TaskNotificationSettings{}.ToAttrType(ctx), + }, + "pipeline_task": basetypes.ListType{ + ElemType: PipelineTask{}.ToAttrType(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: PythonWheelTask{}.ToAttrType(ctx), + }, + "retry_on_timeout": types.BoolType, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ + ElemType: RunJobTask{}.ToAttrType(ctx), + }, + "spark_jar_task": basetypes.ListType{ + ElemType: SparkJarTask{}.ToAttrType(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: SparkPythonTask{}.ToAttrType(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: SparkSubmitTask{}.ToAttrType(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: SqlTask{}.ToAttrType(ctx), + }, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.ToAttrType(ctx), + }, }, } } @@ -5780,8 +6064,8 @@ func (a TaskDependency) GetComplexFieldTypes() map[string]reflect.Type { func (a TaskDependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Outcome": types.StringType, - "TaskKey": types.StringType, + "outcome": types.StringType, + "task_key": types.StringType, }, } } @@ -5830,31 +6114,31 @@ func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringRead(existingSt func (a TaskEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OnDurationWarningThresholdExceeded": reflect.TypeOf(types.StringType), - "OnFailure": reflect.TypeOf(types.StringType), - "OnStart": reflect.TypeOf(types.StringType), - "OnStreamingBacklogExceeded": reflect.TypeOf(types.StringType), - "OnSuccess": reflect.TypeOf(types.StringType), + "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.StringType), + "on_failure": reflect.TypeOf(types.StringType), + "on_start": reflect.TypeOf(types.StringType), + "on_streaming_backlog_exceeded": reflect.TypeOf(types.StringType), + "on_success": reflect.TypeOf(types.StringType), } } func (a TaskEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NoAlertForSkippedRuns": types.BoolType, - "OnDurationWarningThresholdExceeded": basetypes.ListType{ + "no_alert_for_skipped_runs": types.BoolType, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ ElemType: types.StringType, }, - "OnFailure": basetypes.ListType{ + "on_failure": basetypes.ListType{ ElemType: types.StringType, }, - "OnStart": basetypes.ListType{ + "on_start": basetypes.ListType{ ElemType: types.StringType, }, - "OnStreamingBacklogExceeded": basetypes.ListType{ + "on_streaming_backlog_exceeded": basetypes.ListType{ ElemType: types.StringType, }, - "OnSuccess": basetypes.ListType{ + "on_success": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -5887,9 +6171,9 @@ func (a TaskNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type func (a TaskNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertOnLastAttempt": types.BoolType, - "NoAlertForCanceledRuns": types.BoolType, - "NoAlertForSkippedRuns": types.BoolType, + "alert_on_last_attempt": types.BoolType, + "no_alert_for_canceled_runs": types.BoolType, + "no_alert_for_skipped_runs": types.BoolType, }, } } @@ -5968,9 +6252,9 @@ func (a TerminationDetails) GetComplexFieldTypes() map[string]reflect.Type { func (a TerminationDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Code": types.StringType, - "Message": types.StringType, - "Type": types.StringType, + "code": types.StringType, + "message": types.StringType, + "type": types.StringType, }, } } @@ -5994,7 +6278,7 @@ func (a TriggerInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a TriggerInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.Int64Type, + "run_id": types.Int64Type, }, } } @@ -6020,21 +6304,29 @@ func (newState *TriggerSettings) SyncEffectiveFieldsDuringRead(existingState Tri func (a TriggerSettings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileArrival": reflect.TypeOf(FileArrivalTriggerConfiguration{}), - "Periodic": reflect.TypeOf(PeriodicTriggerConfiguration{}), - "Table": reflect.TypeOf(TableUpdateTriggerConfiguration{}), - "TableUpdate": reflect.TypeOf(TableUpdateTriggerConfiguration{}), + "file_arrival": reflect.TypeOf(FileArrivalTriggerConfiguration{}), + "periodic": reflect.TypeOf(PeriodicTriggerConfiguration{}), + "table": reflect.TypeOf(TableUpdateTriggerConfiguration{}), + "table_update": reflect.TypeOf(TableUpdateTriggerConfiguration{}), } } func (a TriggerSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileArrival": FileArrivalTriggerConfiguration{}.ToAttrType(ctx), - "PauseStatus": types.StringType, - "Periodic": PeriodicTriggerConfiguration{}.ToAttrType(ctx), - "Table": TableUpdateTriggerConfiguration{}.ToAttrType(ctx), - "TableUpdate": TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + "file_arrival": basetypes.ListType{ + ElemType: FileArrivalTriggerConfiguration{}.ToAttrType(ctx), + }, + "pause_status": types.StringType, + "periodic": basetypes.ListType{ + ElemType: PeriodicTriggerConfiguration{}.ToAttrType(ctx), + }, + "table": basetypes.ListType{ + ElemType: TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + }, + "table_update": basetypes.ListType{ + ElemType: TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + }, }, } } @@ -6068,19 +6360,21 @@ func (newState *UpdateJob) SyncEffectiveFieldsDuringRead(existingState UpdateJob func (a UpdateJob) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FieldsToRemove": reflect.TypeOf(types.StringType), - "NewSettings": reflect.TypeOf(JobSettings{}), + "fields_to_remove": reflect.TypeOf(types.StringType), + "new_settings": reflect.TypeOf(JobSettings{}), } } func (a UpdateJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FieldsToRemove": basetypes.ListType{ + "fields_to_remove": basetypes.ListType{ ElemType: types.StringType, }, - "JobId": types.Int64Type, - "NewSettings": JobSettings{}.ToAttrType(ctx), + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ + ElemType: JobSettings{}.ToAttrType(ctx), + }, }, } } @@ -6128,9 +6422,9 @@ func (a ViewItem) GetComplexFieldTypes() map[string]reflect.Type { func (a ViewItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "Name": types.StringType, - "Type": types.StringType, + "content": types.StringType, + "name": types.StringType, + "type": types.StringType, }, } } @@ -6152,7 +6446,7 @@ func (a Webhook) GetComplexFieldTypes() map[string]reflect.Type { func (a Webhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -6192,30 +6486,30 @@ func (newState *WebhookNotifications) SyncEffectiveFieldsDuringRead(existingStat func (a WebhookNotifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OnDurationWarningThresholdExceeded": reflect.TypeOf(Webhook{}), - "OnFailure": reflect.TypeOf(Webhook{}), - "OnStart": reflect.TypeOf(Webhook{}), - "OnStreamingBacklogExceeded": reflect.TypeOf(Webhook{}), - "OnSuccess": reflect.TypeOf(Webhook{}), + "on_duration_warning_threshold_exceeded": reflect.TypeOf(Webhook{}), + "on_failure": reflect.TypeOf(Webhook{}), + "on_start": reflect.TypeOf(Webhook{}), + "on_streaming_backlog_exceeded": reflect.TypeOf(Webhook{}), + "on_success": reflect.TypeOf(Webhook{}), } } func (a WebhookNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "OnDurationWarningThresholdExceeded": basetypes.ListType{ + "on_duration_warning_threshold_exceeded": basetypes.ListType{ ElemType: Webhook{}.ToAttrType(ctx), }, - "OnFailure": basetypes.ListType{ + "on_failure": basetypes.ListType{ ElemType: Webhook{}.ToAttrType(ctx), }, - "OnStart": basetypes.ListType{ + "on_start": basetypes.ListType{ ElemType: Webhook{}.ToAttrType(ctx), }, - "OnStreamingBacklogExceeded": basetypes.ListType{ + "on_streaming_backlog_exceeded": basetypes.ListType{ ElemType: Webhook{}.ToAttrType(ctx), }, - "OnSuccess": basetypes.ListType{ + "on_success": basetypes.ListType{ ElemType: Webhook{}.ToAttrType(ctx), }, }, diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 67577e4a9e..bb6e21f8a3 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -38,8 +38,8 @@ func (a AddExchangeForListingRequest) GetComplexFieldTypes() map[string]reflect. func (a AddExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeId": types.StringType, - "ListingId": types.StringType, + "exchange_id": types.StringType, + "listing_id": types.StringType, }, } } @@ -56,14 +56,16 @@ func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringRead(exi func (a AddExchangeForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExchangeForListing": reflect.TypeOf(ExchangeListing{}), + "exchange_for_listing": reflect.TypeOf(ExchangeListing{}), } } func (a AddExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeForListing": ExchangeListing{}.ToAttrType(ctx), + "exchange_for_listing": basetypes.ListType{ + ElemType: ExchangeListing{}.ToAttrType(ctx), + }, }, } } @@ -81,14 +83,14 @@ func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringRead(existingS func (a BatchGetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Ids": reflect.TypeOf(types.StringType), + "ids": reflect.TypeOf(types.StringType), } } func (a BatchGetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Ids": basetypes.ListType{ + "ids": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -107,14 +109,14 @@ func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringRead(existing func (a BatchGetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listings": reflect.TypeOf(Listing{}), + "listings": reflect.TypeOf(Listing{}), } } func (a BatchGetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listings": basetypes.ListType{ + "listings": basetypes.ListType{ ElemType: Listing{}.ToAttrType(ctx), }, }, @@ -134,14 +136,14 @@ func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringRead(existing func (a BatchGetProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Ids": reflect.TypeOf(types.StringType), + "ids": reflect.TypeOf(types.StringType), } } func (a BatchGetProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Ids": basetypes.ListType{ + "ids": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -160,14 +162,14 @@ func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringRead(existin func (a BatchGetProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Providers": reflect.TypeOf(ProviderInfo{}), + "providers": reflect.TypeOf(ProviderInfo{}), } } func (a BatchGetProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Providers": basetypes.ListType{ + "providers": basetypes.ListType{ ElemType: ProviderInfo{}.ToAttrType(ctx), }, }, @@ -191,7 +193,7 @@ func (a ConsumerTerms) GetComplexFieldTypes() map[string]reflect.Type { func (a ConsumerTerms) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Version": types.StringType, + "version": types.StringType, }, } } @@ -221,10 +223,10 @@ func (a ContactInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ContactInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Company": types.StringType, - "Email": types.StringType, - "FirstName": types.StringType, - "LastName": types.StringType, + "company": types.StringType, + "email": types.StringType, + "first_name": types.StringType, + "last_name": types.StringType, }, } } @@ -241,14 +243,16 @@ func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(exist func (a CreateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Filter": reflect.TypeOf(ExchangeFilter{}), + "filter": reflect.TypeOf(ExchangeFilter{}), } } func (a CreateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": ExchangeFilter{}.ToAttrType(ctx), + "filter": basetypes.ListType{ + ElemType: ExchangeFilter{}.ToAttrType(ctx), + }, }, } } @@ -270,7 +274,7 @@ func (a CreateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect. func (a CreateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FilterId": types.StringType, + "filter_id": types.StringType, }, } } @@ -287,14 +291,16 @@ func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringRead(existingSta func (a CreateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exchange": reflect.TypeOf(Exchange{}), + "exchange": reflect.TypeOf(Exchange{}), } } func (a CreateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exchange": Exchange{}.ToAttrType(ctx), + "exchange": basetypes.ListType{ + ElemType: Exchange{}.ToAttrType(ctx), + }, }, } } @@ -316,7 +322,7 @@ func (a CreateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeId": types.StringType, + "exchange_id": types.StringType, }, } } @@ -339,17 +345,19 @@ func (newState *CreateFileRequest) SyncEffectiveFieldsDuringRead(existingState C func (a CreateFileRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileParent": reflect.TypeOf(FileParent{}), + "file_parent": reflect.TypeOf(FileParent{}), } } func (a CreateFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "FileParent": FileParent{}.ToAttrType(ctx), - "MarketplaceFileType": types.StringType, - "MimeType": types.StringType, + "display_name": types.StringType, + "file_parent": basetypes.ListType{ + ElemType: FileParent{}.ToAttrType(ctx), + }, + "marketplace_file_type": types.StringType, + "mime_type": types.StringType, }, } } @@ -368,15 +376,17 @@ func (newState *CreateFileResponse) SyncEffectiveFieldsDuringRead(existingState func (a CreateFileResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileInfo": reflect.TypeOf(FileInfo{}), + "file_info": reflect.TypeOf(FileInfo{}), } } func (a CreateFileResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileInfo": FileInfo{}.ToAttrType(ctx), - "UploadUrl": types.StringType, + "file_info": basetypes.ListType{ + ElemType: FileInfo{}.ToAttrType(ctx), + }, + "upload_url": types.StringType, }, } } @@ -403,20 +413,24 @@ func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringRead(existin func (a CreateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AcceptedConsumerTerms": reflect.TypeOf(ConsumerTerms{}), - "RepoDetail": reflect.TypeOf(RepoInstallation{}), + "accepted_consumer_terms": reflect.TypeOf(ConsumerTerms{}), + "repo_detail": reflect.TypeOf(RepoInstallation{}), } } func (a CreateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AcceptedConsumerTerms": ConsumerTerms{}.ToAttrType(ctx), - "CatalogName": types.StringType, - "ListingId": types.StringType, - "RecipientType": types.StringType, - "RepoDetail": RepoInstallation{}.ToAttrType(ctx), - "ShareName": types.StringType, + "accepted_consumer_terms": basetypes.ListType{ + ElemType: ConsumerTerms{}.ToAttrType(ctx), + }, + "catalog_name": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, + "repo_detail": basetypes.ListType{ + ElemType: RepoInstallation{}.ToAttrType(ctx), + }, + "share_name": types.StringType, }, } } @@ -433,14 +447,16 @@ func (newState *CreateListingRequest) SyncEffectiveFieldsDuringRead(existingStat func (a CreateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listing": reflect.TypeOf(Listing{}), + "listing": reflect.TypeOf(Listing{}), } } func (a CreateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listing": Listing{}.ToAttrType(ctx), + "listing": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, }, } } @@ -462,7 +478,7 @@ func (a CreateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, + "listing_id": types.StringType, }, } } @@ -496,22 +512,24 @@ func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringRead(exis func (a CreatePersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AcceptedConsumerTerms": reflect.TypeOf(ConsumerTerms{}), + "accepted_consumer_terms": reflect.TypeOf(ConsumerTerms{}), } } func (a CreatePersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AcceptedConsumerTerms": ConsumerTerms{}.ToAttrType(ctx), - "Comment": types.StringType, - "Company": types.StringType, - "FirstName": types.StringType, - "IntendedUse": types.StringType, - "IsFromLighthouse": types.BoolType, - "LastName": types.StringType, - "ListingId": types.StringType, - "RecipientType": types.StringType, + "accepted_consumer_terms": basetypes.ListType{ + ElemType: ConsumerTerms{}.ToAttrType(ctx), + }, + "comment": types.StringType, + "company": types.StringType, + "first_name": types.StringType, + "intended_use": types.StringType, + "is_from_lighthouse": types.BoolType, + "last_name": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, }, } } @@ -533,7 +551,7 @@ func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes() map[string] func (a CreatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -550,14 +568,16 @@ func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringRead(existingSta func (a CreateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Provider": reflect.TypeOf(ProviderInfo{}), + "provider": reflect.TypeOf(ProviderInfo{}), } } func (a CreateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Provider": ProviderInfo{}.ToAttrType(ctx), + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, }, } } @@ -579,7 +599,7 @@ func (a CreateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -603,8 +623,8 @@ func (a DataRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a DataRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Interval": types.Int64Type, - "Unit": types.StringType, + "interval": types.Int64Type, + "unit": types.StringType, }, } } @@ -627,7 +647,7 @@ func (a DeleteExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.T func (a DeleteExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -669,7 +689,7 @@ func (a DeleteExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -711,7 +731,7 @@ func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileId": types.StringType, + "file_id": types.StringType, }, } } @@ -755,8 +775,8 @@ func (a DeleteInstallationRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InstallationId": types.StringType, - "ListingId": types.StringType, + "installation_id": types.StringType, + "listing_id": types.StringType, }, } } @@ -798,7 +818,7 @@ func (a DeleteListingRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -840,7 +860,7 @@ func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -892,27 +912,27 @@ func (newState *Exchange) SyncEffectiveFieldsDuringRead(existingState Exchange) func (a Exchange) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Filters": reflect.TypeOf(ExchangeFilter{}), - "LinkedListings": reflect.TypeOf(ExchangeListing{}), + "filters": reflect.TypeOf(ExchangeFilter{}), + "linked_listings": reflect.TypeOf(ExchangeListing{}), } } func (a Exchange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "Filters": basetypes.ListType{ + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "filters": basetypes.ListType{ ElemType: ExchangeFilter{}.ToAttrType(ctx), }, - "Id": types.StringType, - "LinkedListings": basetypes.ListType{ + "id": types.StringType, + "linked_listings": basetypes.ListType{ ElemType: ExchangeListing{}.ToAttrType(ctx), }, - "Name": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "name": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -950,15 +970,15 @@ func (a ExchangeFilter) GetComplexFieldTypes() map[string]reflect.Type { func (a ExchangeFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "ExchangeId": types.StringType, - "FilterType": types.StringType, - "FilterValue": types.StringType, - "Id": types.StringType, - "Name": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "exchange_id": types.StringType, + "filter_type": types.StringType, + "filter_value": types.StringType, + "id": types.StringType, + "name": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -992,13 +1012,13 @@ func (a ExchangeListing) GetComplexFieldTypes() map[string]reflect.Type { func (a ExchangeListing) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "ExchangeId": types.StringType, - "ExchangeName": types.StringType, - "Id": types.StringType, - "ListingId": types.StringType, - "ListingName": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "exchange_id": types.StringType, + "exchange_name": types.StringType, + "id": types.StringType, + "listing_id": types.StringType, + "listing_name": types.StringType, }, } } @@ -1034,23 +1054,25 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileParent": reflect.TypeOf(FileParent{}), + "file_parent": reflect.TypeOf(FileParent{}), } } func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.Int64Type, - "DisplayName": types.StringType, - "DownloadLink": types.StringType, - "FileParent": FileParent{}.ToAttrType(ctx), - "Id": types.StringType, - "MarketplaceFileType": types.StringType, - "MimeType": types.StringType, - "Status": types.StringType, - "StatusMessage": types.StringType, - "UpdatedAt": types.Int64Type, + "created_at": types.Int64Type, + "display_name": types.StringType, + "download_link": types.StringType, + "file_parent": basetypes.ListType{ + ElemType: FileParent{}.ToAttrType(ctx), + }, + "id": types.StringType, + "marketplace_file_type": types.StringType, + "mime_type": types.StringType, + "status": types.StringType, + "status_message": types.StringType, + "updated_at": types.Int64Type, }, } } @@ -1074,8 +1096,8 @@ func (a FileParent) GetComplexFieldTypes() map[string]reflect.Type { func (a FileParent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileParentType": types.StringType, - "ParentId": types.StringType, + "file_parent_type": types.StringType, + "parent_id": types.StringType, }, } } @@ -1098,7 +1120,7 @@ func (a GetExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1115,14 +1137,16 @@ func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringRead(existingState func (a GetExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exchange": reflect.TypeOf(Exchange{}), + "exchange": reflect.TypeOf(Exchange{}), } } func (a GetExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exchange": Exchange{}.ToAttrType(ctx), + "exchange": basetypes.ListType{ + ElemType: Exchange{}.ToAttrType(ctx), + }, }, } } @@ -1145,7 +1169,7 @@ func (a GetFileRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileId": types.StringType, + "file_id": types.StringType, }, } } @@ -1162,14 +1186,16 @@ func (newState *GetFileResponse) SyncEffectiveFieldsDuringRead(existingState Get func (a GetFileResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileInfo": reflect.TypeOf(FileInfo{}), + "file_info": reflect.TypeOf(FileInfo{}), } } func (a GetFileResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileInfo": FileInfo{}.ToAttrType(ctx), + "file_info": basetypes.ListType{ + ElemType: FileInfo{}.ToAttrType(ctx), + }, }, } } @@ -1192,7 +1218,7 @@ func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes func (a GetLatestVersionProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Version": types.Int64Type, + "version": types.Int64Type, }, } } @@ -1219,9 +1245,9 @@ func (a GetListingContentMetadataRequest) GetComplexFieldTypes() map[string]refl func (a GetListingContentMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "listing_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1240,15 +1266,15 @@ func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringRead func (a GetListingContentMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SharedDataObjects": reflect.TypeOf(SharedDataObject{}), + "shared_data_objects": reflect.TypeOf(SharedDataObject{}), } } func (a GetListingContentMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "SharedDataObjects": basetypes.ListType{ + "next_page_token": types.StringType, + "shared_data_objects": basetypes.ListType{ ElemType: SharedDataObject{}.ToAttrType(ctx), }, }, @@ -1273,7 +1299,7 @@ func (a GetListingRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1290,14 +1316,16 @@ func (newState *GetListingResponse) SyncEffectiveFieldsDuringRead(existingState func (a GetListingResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listing": reflect.TypeOf(Listing{}), + "listing": reflect.TypeOf(Listing{}), } } func (a GetListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listing": Listing{}.ToAttrType(ctx), + "listing": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, }, } } @@ -1322,8 +1350,8 @@ func (a GetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1342,17 +1370,17 @@ func (newState *GetListingsResponse) SyncEffectiveFieldsDuringRead(existingState func (a GetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listings": reflect.TypeOf(Listing{}), + "listings": reflect.TypeOf(Listing{}), } } func (a GetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listings": basetypes.ListType{ + "listings": basetypes.ListType{ ElemType: Listing{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1375,7 +1403,7 @@ func (a GetPersonalizationRequestRequest) GetComplexFieldTypes() map[string]refl func (a GetPersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, + "listing_id": types.StringType, }, } } @@ -1392,14 +1420,14 @@ func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringRead func (a GetPersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PersonalizationRequests": reflect.TypeOf(PersonalizationRequest{}), + "personalization_requests": reflect.TypeOf(PersonalizationRequest{}), } } func (a GetPersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PersonalizationRequests": basetypes.ListType{ + "personalization_requests": basetypes.ListType{ ElemType: PersonalizationRequest{}.ToAttrType(ctx), }, }, @@ -1424,7 +1452,7 @@ func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1441,14 +1469,16 @@ func (newState *GetProviderResponse) SyncEffectiveFieldsDuringRead(existingState func (a GetProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Provider": reflect.TypeOf(ProviderInfo{}), + "provider": reflect.TypeOf(ProviderInfo{}), } } func (a GetProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Provider": ProviderInfo{}.ToAttrType(ctx), + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, }, } } @@ -1465,14 +1495,16 @@ func (newState *Installation) SyncEffectiveFieldsDuringRead(existingState Instal func (a Installation) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Installation": reflect.TypeOf(InstallationDetail{}), + "installation": reflect.TypeOf(InstallationDetail{}), } } func (a Installation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Installation": InstallationDetail{}.ToAttrType(ctx), + "installation": basetypes.ListType{ + ElemType: InstallationDetail{}.ToAttrType(ctx), + }, }, } } @@ -1513,27 +1545,29 @@ func (newState *InstallationDetail) SyncEffectiveFieldsDuringRead(existingState func (a InstallationDetail) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenDetail": reflect.TypeOf(TokenDetail{}), - "Tokens": reflect.TypeOf(TokenInfo{}), + "token_detail": reflect.TypeOf(TokenDetail{}), + "tokens": reflect.TypeOf(TokenInfo{}), } } func (a InstallationDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "ErrorMessage": types.StringType, - "Id": types.StringType, - "InstalledOn": types.Int64Type, - "ListingId": types.StringType, - "ListingName": types.StringType, - "RecipientType": types.StringType, - "RepoName": types.StringType, - "RepoPath": types.StringType, - "ShareName": types.StringType, - "Status": types.StringType, - "TokenDetail": TokenDetail{}.ToAttrType(ctx), - "Tokens": basetypes.ListType{ + "catalog_name": types.StringType, + "error_message": types.StringType, + "id": types.StringType, + "installed_on": types.Int64Type, + "listing_id": types.StringType, + "listing_name": types.StringType, + "recipient_type": types.StringType, + "repo_name": types.StringType, + "repo_path": types.StringType, + "share_name": types.StringType, + "status": types.StringType, + "token_detail": basetypes.ListType{ + ElemType: TokenDetail{}.ToAttrType(ctx), + }, + "tokens": basetypes.ListType{ ElemType: TokenInfo{}.ToAttrType(ctx), }, }, @@ -1560,8 +1594,8 @@ func (a ListAllInstallationsRequest) GetComplexFieldTypes() map[string]reflect.T func (a ListAllInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1580,17 +1614,17 @@ func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringRead(exis func (a ListAllInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Installations": reflect.TypeOf(InstallationDetail{}), + "installations": reflect.TypeOf(InstallationDetail{}), } } func (a ListAllInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Installations": basetypes.ListType{ + "installations": basetypes.ListType{ ElemType: InstallationDetail{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1615,8 +1649,8 @@ func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes() map[string func (a ListAllPersonalizationRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1635,15 +1669,15 @@ func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDurin func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PersonalizationRequests": reflect.TypeOf(PersonalizationRequest{}), + "personalization_requests": reflect.TypeOf(PersonalizationRequest{}), } } func (a ListAllPersonalizationRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "PersonalizationRequests": basetypes.ListType{ + "next_page_token": types.StringType, + "personalization_requests": basetypes.ListType{ ElemType: PersonalizationRequest{}.ToAttrType(ctx), }, }, @@ -1672,9 +1706,9 @@ func (a ListExchangeFiltersRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a ListExchangeFiltersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "exchange_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1693,17 +1727,17 @@ func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringRead(exist func (a ListExchangeFiltersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Filters": reflect.TypeOf(ExchangeFilter{}), + "filters": reflect.TypeOf(ExchangeFilter{}), } } func (a ListExchangeFiltersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filters": basetypes.ListType{ + "filters": basetypes.ListType{ ElemType: ExchangeFilter{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1730,9 +1764,9 @@ func (a ListExchangesForListingRequest) GetComplexFieldTypes() map[string]reflec func (a ListExchangesForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "listing_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1751,17 +1785,17 @@ func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringRead(e func (a ListExchangesForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExchangeListing": reflect.TypeOf(ExchangeListing{}), + "exchange_listing": reflect.TypeOf(ExchangeListing{}), } } func (a ListExchangesForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeListing": basetypes.ListType{ + "exchange_listing": basetypes.ListType{ ElemType: ExchangeListing{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1786,8 +1820,8 @@ func (a ListExchangesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListExchangesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1806,17 +1840,17 @@ func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListExchangesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exchanges": reflect.TypeOf(Exchange{}), + "exchanges": reflect.TypeOf(Exchange{}), } } func (a ListExchangesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exchanges": basetypes.ListType{ + "exchanges": basetypes.ListType{ ElemType: Exchange{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1838,16 +1872,18 @@ func (newState *ListFilesRequest) SyncEffectiveFieldsDuringRead(existingState Li func (a ListFilesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileParent": reflect.TypeOf(FileParent{}), + "file_parent": reflect.TypeOf(FileParent{}), } } func (a ListFilesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileParent": FileParent{}.ToAttrType(ctx), - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "file_parent": basetypes.ListType{ + ElemType: FileParent{}.ToAttrType(ctx), + }, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1866,17 +1902,17 @@ func (newState *ListFilesResponse) SyncEffectiveFieldsDuringRead(existingState L func (a ListFilesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FileInfos": reflect.TypeOf(FileInfo{}), + "file_infos": reflect.TypeOf(FileInfo{}), } } func (a ListFilesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileInfos": basetypes.ListType{ + "file_infos": basetypes.ListType{ ElemType: FileInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1903,9 +1939,9 @@ func (a ListFulfillmentsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListFulfillmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "listing_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1924,17 +1960,17 @@ func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringRead(existing func (a ListFulfillmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Fulfillments": reflect.TypeOf(ListingFulfillment{}), + "fulfillments": reflect.TypeOf(ListingFulfillment{}), } } func (a ListFulfillmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Fulfillments": basetypes.ListType{ + "fulfillments": basetypes.ListType{ ElemType: ListingFulfillment{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1961,9 +1997,9 @@ func (a ListInstallationsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "listing_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -1982,17 +2018,17 @@ func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringRead(existin func (a ListInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Installations": reflect.TypeOf(InstallationDetail{}), + "installations": reflect.TypeOf(InstallationDetail{}), } } func (a ListInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Installations": basetypes.ListType{ + "installations": basetypes.ListType{ ElemType: InstallationDetail{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2019,9 +2055,9 @@ func (a ListListingsForExchangeRequest) GetComplexFieldTypes() map[string]reflec func (a ListListingsForExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeId": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "exchange_id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -2040,17 +2076,17 @@ func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringRead(e func (a ListListingsForExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExchangeListings": reflect.TypeOf(ExchangeListing{}), + "exchange_listings": reflect.TypeOf(ExchangeListing{}), } } func (a ListListingsForExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExchangeListings": basetypes.ListType{ + "exchange_listings": basetypes.ListType{ ElemType: ExchangeListing{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2085,31 +2121,31 @@ func (newState *ListListingsRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Assets": reflect.TypeOf(types.StringType), - "Categories": reflect.TypeOf(types.StringType), - "ProviderIds": reflect.TypeOf(types.StringType), - "Tags": reflect.TypeOf(ListingTag{}), + "assets": reflect.TypeOf(types.StringType), + "categories": reflect.TypeOf(types.StringType), + "provider_ids": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(ListingTag{}), } } func (a ListListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Assets": basetypes.ListType{ + "assets": basetypes.ListType{ ElemType: types.StringType, }, - "Categories": basetypes.ListType{ + "categories": basetypes.ListType{ ElemType: types.StringType, }, - "IsFree": types.BoolType, - "IsPrivateExchange": types.BoolType, - "IsStaffPick": types.BoolType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "ProviderIds": basetypes.ListType{ + "is_free": types.BoolType, + "is_private_exchange": types.BoolType, + "is_staff_pick": types.BoolType, + "page_size": types.Int64Type, + "page_token": types.StringType, + "provider_ids": basetypes.ListType{ ElemType: types.StringType, }, - "Tags": basetypes.ListType{ + "tags": basetypes.ListType{ ElemType: ListingTag{}.ToAttrType(ctx), }, }, @@ -2130,17 +2166,17 @@ func (newState *ListListingsResponse) SyncEffectiveFieldsDuringRead(existingStat func (a ListListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listings": reflect.TypeOf(Listing{}), + "listings": reflect.TypeOf(Listing{}), } } func (a ListListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listings": basetypes.ListType{ + "listings": basetypes.ListType{ ElemType: Listing{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2167,9 +2203,9 @@ func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[strin func (a ListProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Id": types.StringType, - "Version": types.Int64Type, + "dashboard_id": types.StringType, + "id": types.StringType, + "version": types.Int64Type, }, } } @@ -2196,9 +2232,9 @@ func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsFeatured": types.BoolType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "is_featured": types.BoolType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -2217,15 +2253,15 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Providers": reflect.TypeOf(ProviderInfo{}), + "providers": reflect.TypeOf(ProviderInfo{}), } } func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Providers": basetypes.ListType{ + "next_page_token": types.StringType, + "providers": basetypes.ListType{ ElemType: ProviderInfo{}.ToAttrType(ctx), }, }, @@ -2248,17 +2284,21 @@ func (newState *Listing) SyncEffectiveFieldsDuringRead(existingState Listing) { func (a Listing) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Detail": reflect.TypeOf(ListingDetail{}), - "Summary": reflect.TypeOf(ListingSummary{}), + "detail": reflect.TypeOf(ListingDetail{}), + "summary": reflect.TypeOf(ListingSummary{}), } } func (a Listing) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Detail": ListingDetail{}.ToAttrType(ctx), - "Id": types.StringType, - "Summary": ListingSummary{}.ToAttrType(ctx), + "detail": basetypes.ListType{ + ElemType: ListingDetail{}.ToAttrType(ctx), + }, + "id": types.StringType, + "summary": basetypes.ListType{ + ElemType: ListingSummary{}.ToAttrType(ctx), + }, }, } } @@ -2322,45 +2362,49 @@ func (newState *ListingDetail) SyncEffectiveFieldsDuringRead(existingState Listi func (a ListingDetail) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Assets": reflect.TypeOf(types.StringType), - "CollectionGranularity": reflect.TypeOf(DataRefreshInfo{}), - "EmbeddedNotebookFileInfos": reflect.TypeOf(FileInfo{}), - "FileIds": reflect.TypeOf(types.StringType), - "Tags": reflect.TypeOf(ListingTag{}), - "UpdateFrequency": reflect.TypeOf(DataRefreshInfo{}), + "assets": reflect.TypeOf(types.StringType), + "collection_granularity": reflect.TypeOf(DataRefreshInfo{}), + "embedded_notebook_file_infos": reflect.TypeOf(FileInfo{}), + "file_ids": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(ListingTag{}), + "update_frequency": reflect.TypeOf(DataRefreshInfo{}), } } func (a ListingDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Assets": basetypes.ListType{ + "assets": basetypes.ListType{ ElemType: types.StringType, }, - "CollectionDateEnd": types.Int64Type, - "CollectionDateStart": types.Int64Type, - "CollectionGranularity": DataRefreshInfo{}.ToAttrType(ctx), - "Cost": types.StringType, - "DataSource": types.StringType, - "Description": types.StringType, - "DocumentationLink": types.StringType, - "EmbeddedNotebookFileInfos": basetypes.ListType{ + "collection_date_end": types.Int64Type, + "collection_date_start": types.Int64Type, + "collection_granularity": basetypes.ListType{ + ElemType: DataRefreshInfo{}.ToAttrType(ctx), + }, + "cost": types.StringType, + "data_source": types.StringType, + "description": types.StringType, + "documentation_link": types.StringType, + "embedded_notebook_file_infos": basetypes.ListType{ ElemType: FileInfo{}.ToAttrType(ctx), }, - "FileIds": basetypes.ListType{ + "file_ids": basetypes.ListType{ ElemType: types.StringType, }, - "GeographicalCoverage": types.StringType, - "License": types.StringType, - "PricingModel": types.StringType, - "PrivacyPolicyLink": types.StringType, - "Size": types.Float64Type, - "SupportLink": types.StringType, - "Tags": basetypes.ListType{ + "geographical_coverage": types.StringType, + "license": types.StringType, + "pricing_model": types.StringType, + "privacy_policy_link": types.StringType, + "size": types.Float64Type, + "support_link": types.StringType, + "tags": basetypes.ListType{ ElemType: ListingTag{}.ToAttrType(ctx), }, - "TermsOfService": types.StringType, - "UpdateFrequency": DataRefreshInfo{}.ToAttrType(ctx), + "terms_of_service": types.StringType, + "update_frequency": basetypes.ListType{ + ElemType: DataRefreshInfo{}.ToAttrType(ctx), + }, }, } } @@ -2385,19 +2429,23 @@ func (newState *ListingFulfillment) SyncEffectiveFieldsDuringRead(existingState func (a ListingFulfillment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RepoInfo": reflect.TypeOf(RepoInfo{}), - "ShareInfo": reflect.TypeOf(ShareInfo{}), + "repo_info": reflect.TypeOf(RepoInfo{}), + "share_info": reflect.TypeOf(ShareInfo{}), } } func (a ListingFulfillment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FulfillmentType": types.StringType, - "ListingId": types.StringType, - "RecipientType": types.StringType, - "RepoInfo": RepoInfo{}.ToAttrType(ctx), - "ShareInfo": ShareInfo{}.ToAttrType(ctx), + "fulfillment_type": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, + "repo_info": basetypes.ListType{ + ElemType: RepoInfo{}.ToAttrType(ctx), + }, + "share_info": basetypes.ListType{ + ElemType: ShareInfo{}.ToAttrType(ctx), + }, }, } } @@ -2419,7 +2467,7 @@ func (a ListingSetting) GetComplexFieldTypes() map[string]reflect.Type { func (a ListingSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Visibility": types.StringType, + "visibility": types.StringType, }, } } @@ -2474,41 +2522,49 @@ func (newState *ListingSummary) SyncEffectiveFieldsDuringRead(existingState List func (a ListingSummary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Categories": reflect.TypeOf(types.StringType), - "ExchangeIds": reflect.TypeOf(types.StringType), - "GitRepo": reflect.TypeOf(RepoInfo{}), - "ProviderRegion": reflect.TypeOf(RegionInfo{}), - "Setting": reflect.TypeOf(ListingSetting{}), - "Share": reflect.TypeOf(ShareInfo{}), + "categories": reflect.TypeOf(types.StringType), + "exchange_ids": reflect.TypeOf(types.StringType), + "git_repo": reflect.TypeOf(RepoInfo{}), + "provider_region": reflect.TypeOf(RegionInfo{}), + "setting": reflect.TypeOf(ListingSetting{}), + "share": reflect.TypeOf(ShareInfo{}), } } func (a ListingSummary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Categories": basetypes.ListType{ + "categories": basetypes.ListType{ ElemType: types.StringType, }, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "CreatedById": types.Int64Type, - "ExchangeIds": basetypes.ListType{ + "created_at": types.Int64Type, + "created_by": types.StringType, + "created_by_id": types.Int64Type, + "exchange_ids": basetypes.ListType{ ElemType: types.StringType, }, - "GitRepo": RepoInfo{}.ToAttrType(ctx), - "ListingType": types.StringType, - "Name": types.StringType, - "ProviderId": types.StringType, - "ProviderRegion": RegionInfo{}.ToAttrType(ctx), - "PublishedAt": types.Int64Type, - "PublishedBy": types.StringType, - "Setting": ListingSetting{}.ToAttrType(ctx), - "Share": ShareInfo{}.ToAttrType(ctx), - "Status": types.StringType, - "Subtitle": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, - "UpdatedById": types.Int64Type, + "git_repo": basetypes.ListType{ + ElemType: RepoInfo{}.ToAttrType(ctx), + }, + "listingType": types.StringType, + "name": types.StringType, + "provider_id": types.StringType, + "provider_region": basetypes.ListType{ + ElemType: RegionInfo{}.ToAttrType(ctx), + }, + "published_at": types.Int64Type, + "published_by": types.StringType, + "setting": basetypes.ListType{ + ElemType: ListingSetting{}.ToAttrType(ctx), + }, + "share": basetypes.ListType{ + ElemType: ShareInfo{}.ToAttrType(ctx), + }, + "status": types.StringType, + "subtitle": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "updated_by_id": types.Int64Type, }, } } @@ -2529,15 +2585,15 @@ func (newState *ListingTag) SyncEffectiveFieldsDuringRead(existingState ListingT func (a ListingTag) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TagValues": reflect.TypeOf(types.StringType), + "tag_values": reflect.TypeOf(types.StringType), } } func (a ListingTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TagName": types.StringType, - "TagValues": basetypes.ListType{ + "tag_name": types.StringType, + "tag_values": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -2587,31 +2643,37 @@ func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringRead(existingSt func (a PersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ConsumerRegion": reflect.TypeOf(RegionInfo{}), - "ContactInfo": reflect.TypeOf(ContactInfo{}), - "Share": reflect.TypeOf(ShareInfo{}), + "consumer_region": reflect.TypeOf(RegionInfo{}), + "contact_info": reflect.TypeOf(ContactInfo{}), + "share": reflect.TypeOf(ShareInfo{}), } } func (a PersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "ConsumerRegion": RegionInfo{}.ToAttrType(ctx), - "ContactInfo": ContactInfo{}.ToAttrType(ctx), - "CreatedAt": types.Int64Type, - "Id": types.StringType, - "IntendedUse": types.StringType, - "IsFromLighthouse": types.BoolType, - "ListingId": types.StringType, - "ListingName": types.StringType, - "MetastoreId": types.StringType, - "ProviderId": types.StringType, - "RecipientType": types.StringType, - "Share": ShareInfo{}.ToAttrType(ctx), - "Status": types.StringType, - "StatusMessage": types.StringType, - "UpdatedAt": types.Int64Type, + "comment": types.StringType, + "consumer_region": basetypes.ListType{ + ElemType: RegionInfo{}.ToAttrType(ctx), + }, + "contact_info": basetypes.ListType{ + ElemType: ContactInfo{}.ToAttrType(ctx), + }, + "created_at": types.Int64Type, + "id": types.StringType, + "intended_use": types.StringType, + "is_from_lighthouse": types.BoolType, + "listing_id": types.StringType, + "listing_name": types.StringType, + "metastore_id": types.StringType, + "provider_id": types.StringType, + "recipient_type": types.StringType, + "share": basetypes.ListType{ + ElemType: ShareInfo{}.ToAttrType(ctx), + }, + "status": types.StringType, + "status_message": types.StringType, + "updated_at": types.Int64Type, }, } } @@ -2633,7 +2695,7 @@ func (a ProviderAnalyticsDashboard) GetComplexFieldTypes() map[string]reflect.Ty func (a ProviderAnalyticsDashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2681,20 +2743,20 @@ func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BusinessContactEmail": types.StringType, - "CompanyWebsiteLink": types.StringType, - "DarkModeIconFileId": types.StringType, - "DarkModeIconFilePath": types.StringType, - "Description": types.StringType, - "IconFileId": types.StringType, - "IconFilePath": types.StringType, - "Id": types.StringType, - "IsFeatured": types.BoolType, - "Name": types.StringType, - "PrivacyPolicyLink": types.StringType, - "PublishedBy": types.StringType, - "SupportContactEmail": types.StringType, - "TermOfServiceLink": types.StringType, + "business_contact_email": types.StringType, + "company_website_link": types.StringType, + "dark_mode_icon_file_id": types.StringType, + "dark_mode_icon_file_path": types.StringType, + "description": types.StringType, + "icon_file_id": types.StringType, + "icon_file_path": types.StringType, + "id": types.StringType, + "is_featured": types.BoolType, + "name": types.StringType, + "privacy_policy_link": types.StringType, + "published_by": types.StringType, + "support_contact_email": types.StringType, + "term_of_service_link": types.StringType, }, } } @@ -2718,8 +2780,8 @@ func (a RegionInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a RegionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cloud": types.StringType, - "Region": types.StringType, + "cloud": types.StringType, + "region": types.StringType, }, } } @@ -2742,7 +2804,7 @@ func (a RemoveExchangeForListingRequest) GetComplexFieldTypes() map[string]refle func (a RemoveExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2784,7 +2846,7 @@ func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GitRepoUrl": types.StringType, + "git_repo_url": types.StringType, }, } } @@ -2811,8 +2873,8 @@ func (a RepoInstallation) GetComplexFieldTypes() map[string]reflect.Type { func (a RepoInstallation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RepoName": types.StringType, - "RepoPath": types.StringType, + "repo_name": types.StringType, + "repo_path": types.StringType, }, } } @@ -2845,29 +2907,29 @@ func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringRead(existingSta func (a SearchListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Assets": reflect.TypeOf(types.StringType), - "Categories": reflect.TypeOf(types.StringType), - "ProviderIds": reflect.TypeOf(types.StringType), + "assets": reflect.TypeOf(types.StringType), + "categories": reflect.TypeOf(types.StringType), + "provider_ids": reflect.TypeOf(types.StringType), } } func (a SearchListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Assets": basetypes.ListType{ + "assets": basetypes.ListType{ ElemType: types.StringType, }, - "Categories": basetypes.ListType{ + "categories": basetypes.ListType{ ElemType: types.StringType, }, - "IsFree": types.BoolType, - "IsPrivateExchange": types.BoolType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, - "ProviderIds": basetypes.ListType{ + "is_free": types.BoolType, + "is_private_exchange": types.BoolType, + "page_size": types.Int64Type, + "page_token": types.StringType, + "provider_ids": basetypes.ListType{ ElemType: types.StringType, }, - "Query": types.StringType, + "query": types.StringType, }, } } @@ -2886,17 +2948,17 @@ func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringRead(existingSt func (a SearchListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listings": reflect.TypeOf(Listing{}), + "listings": reflect.TypeOf(Listing{}), } } func (a SearchListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listings": basetypes.ListType{ + "listings": basetypes.ListType{ ElemType: Listing{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2920,8 +2982,8 @@ func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Type": types.StringType, + "name": types.StringType, + "type": types.StringType, }, } } @@ -2947,8 +3009,8 @@ func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataObjectType": types.StringType, - "Name": types.StringType, + "data_object_type": types.StringType, + "name": types.StringType, }, } } @@ -2978,10 +3040,10 @@ func (a TokenDetail) GetComplexFieldTypes() map[string]reflect.Type { func (a TokenDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BearerToken": types.StringType, - "Endpoint": types.StringType, - "ExpirationTime": types.StringType, - "ShareCredentialsVersion": types.Int64Type, + "bearerToken": types.StringType, + "endpoint": types.StringType, + "expirationTime": types.StringType, + "shareCredentialsVersion": types.Int64Type, }, } } @@ -3017,13 +3079,13 @@ func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActivationUrl": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "ExpirationTime": types.Int64Type, - "Id": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "activation_url": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "expiration_time": types.Int64Type, + "id": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -3042,15 +3104,17 @@ func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(exist func (a UpdateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Filter": reflect.TypeOf(ExchangeFilter{}), + "filter": reflect.TypeOf(ExchangeFilter{}), } } func (a UpdateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": ExchangeFilter{}.ToAttrType(ctx), - "Id": types.StringType, + "filter": basetypes.ListType{ + ElemType: ExchangeFilter{}.ToAttrType(ctx), + }, + "id": types.StringType, }, } } @@ -3067,14 +3131,16 @@ func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(exis func (a UpdateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Filter": reflect.TypeOf(ExchangeFilter{}), + "filter": reflect.TypeOf(ExchangeFilter{}), } } func (a UpdateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": ExchangeFilter{}.ToAttrType(ctx), + "filter": basetypes.ListType{ + ElemType: ExchangeFilter{}.ToAttrType(ctx), + }, }, } } @@ -3093,15 +3159,17 @@ func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exchange": reflect.TypeOf(Exchange{}), + "exchange": reflect.TypeOf(Exchange{}), } } func (a UpdateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exchange": Exchange{}.ToAttrType(ctx), - "Id": types.StringType, + "exchange": basetypes.ListType{ + ElemType: Exchange{}.ToAttrType(ctx), + }, + "id": types.StringType, }, } } @@ -3118,14 +3186,16 @@ func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exchange": reflect.TypeOf(Exchange{}), + "exchange": reflect.TypeOf(Exchange{}), } } func (a UpdateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exchange": Exchange{}.ToAttrType(ctx), + "exchange": basetypes.ListType{ + ElemType: Exchange{}.ToAttrType(ctx), + }, }, } } @@ -3148,17 +3218,19 @@ func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringRead(existin func (a UpdateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Installation": reflect.TypeOf(InstallationDetail{}), + "installation": reflect.TypeOf(InstallationDetail{}), } } func (a UpdateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Installation": InstallationDetail{}.ToAttrType(ctx), - "InstallationId": types.StringType, - "ListingId": types.StringType, - "RotateToken": types.BoolType, + "installation": basetypes.ListType{ + ElemType: InstallationDetail{}.ToAttrType(ctx), + }, + "installation_id": types.StringType, + "listing_id": types.StringType, + "rotate_token": types.BoolType, }, } } @@ -3175,14 +3247,16 @@ func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringRead(existi func (a UpdateInstallationResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Installation": reflect.TypeOf(InstallationDetail{}), + "installation": reflect.TypeOf(InstallationDetail{}), } } func (a UpdateInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Installation": InstallationDetail{}.ToAttrType(ctx), + "installation": basetypes.ListType{ + ElemType: InstallationDetail{}.ToAttrType(ctx), + }, }, } } @@ -3201,15 +3275,17 @@ func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringRead(existingStat func (a UpdateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listing": reflect.TypeOf(Listing{}), + "listing": reflect.TypeOf(Listing{}), } } func (a UpdateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Listing": Listing{}.ToAttrType(ctx), + "id": types.StringType, + "listing": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, }, } } @@ -3226,14 +3302,16 @@ func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Listing": reflect.TypeOf(Listing{}), + "listing": reflect.TypeOf(Listing{}), } } func (a UpdateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Listing": Listing{}.ToAttrType(ctx), + "listing": basetypes.ListType{ + ElemType: Listing{}.ToAttrType(ctx), + }, }, } } @@ -3258,18 +3336,20 @@ func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringRe func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Share": reflect.TypeOf(ShareInfo{}), + "share": reflect.TypeOf(ShareInfo{}), } } func (a UpdatePersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ListingId": types.StringType, - "Reason": types.StringType, - "RequestId": types.StringType, - "Share": ShareInfo{}.ToAttrType(ctx), - "Status": types.StringType, + "listing_id": types.StringType, + "reason": types.StringType, + "request_id": types.StringType, + "share": basetypes.ListType{ + ElemType: ShareInfo{}.ToAttrType(ctx), + }, + "status": types.StringType, }, } } @@ -3286,14 +3366,16 @@ func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringR func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Request": reflect.TypeOf(PersonalizationRequest{}), + "request": reflect.TypeOf(PersonalizationRequest{}), } } func (a UpdatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Request": PersonalizationRequest{}.ToAttrType(ctx), + "request": basetypes.ListType{ + ElemType: PersonalizationRequest{}.ToAttrType(ctx), + }, }, } } @@ -3320,8 +3402,8 @@ func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes() map[stri func (a UpdateProviderAnalyticsDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Version": types.Int64Type, + "id": types.StringType, + "version": types.Int64Type, }, } } @@ -3348,9 +3430,9 @@ func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[str func (a UpdateProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Id": types.StringType, - "Version": types.Int64Type, + "dashboard_id": types.StringType, + "id": types.StringType, + "version": types.Int64Type, }, } } @@ -3369,15 +3451,17 @@ func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Provider": reflect.TypeOf(ProviderInfo{}), + "provider": reflect.TypeOf(ProviderInfo{}), } } func (a UpdateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Provider": ProviderInfo{}.ToAttrType(ctx), + "id": types.StringType, + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, }, } } @@ -3394,14 +3478,16 @@ func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Provider": reflect.TypeOf(ProviderInfo{}), + "provider": reflect.TypeOf(ProviderInfo{}), } } func (a UpdateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Provider": ProviderInfo{}.ToAttrType(ctx), + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.ToAttrType(ctx), + }, }, } } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index c8621dbedd..d86f9cf06f 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -88,15 +88,15 @@ func (a Activity) GetComplexFieldTypes() map[string]reflect.Type { func (a Activity) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActivityType": types.StringType, - "Comment": types.StringType, - "CreationTimestamp": types.Int64Type, - "FromStage": types.StringType, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "SystemComment": types.StringType, - "ToStage": types.StringType, - "UserId": types.StringType, + "activity_type": types.StringType, + "comment": types.StringType, + "creation_timestamp": types.Int64Type, + "from_stage": types.StringType, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "system_comment": types.StringType, + "to_stage": types.StringType, + "user_id": types.StringType, }, } } @@ -136,11 +136,11 @@ func (a ApproveTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ApproveTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArchiveExistingVersions": types.BoolType, - "Comment": types.StringType, - "Name": types.StringType, - "Stage": types.StringType, - "Version": types.StringType, + "archive_existing_versions": types.BoolType, + "comment": types.StringType, + "name": types.StringType, + "stage": types.StringType, + "version": types.StringType, }, } } @@ -158,14 +158,16 @@ func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringRead( func (a ApproveTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Activity": reflect.TypeOf(Activity{}), + "activity": reflect.TypeOf(Activity{}), } } func (a ApproveTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Activity": Activity{}.ToAttrType(ctx), + "activity": basetypes.ListType{ + ElemType: Activity{}.ToAttrType(ctx), + }, }, } } @@ -194,21 +196,21 @@ func (newState *CommentObject) SyncEffectiveFieldsDuringRead(existingState Comme func (a CommentObject) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AvailableActions": reflect.TypeOf(types.StringType), + "available_actions": reflect.TypeOf(types.StringType), } } func (a CommentObject) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AvailableActions": basetypes.ListType{ + "available_actions": basetypes.ListType{ ElemType: types.StringType, }, - "Comment": types.StringType, - "CreationTimestamp": types.Int64Type, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "UserId": types.StringType, + "comment": types.StringType, + "creation_timestamp": types.Int64Type, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "user_id": types.StringType, }, } } @@ -235,9 +237,9 @@ func (a CreateComment) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateComment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "Version": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -255,14 +257,16 @@ func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringRead(existingSta func (a CreateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Comment": reflect.TypeOf(CommentObject{}), + "comment": reflect.TypeOf(CommentObject{}), } } func (a CreateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": CommentObject{}.ToAttrType(ctx), + "comment": basetypes.ListType{ + ElemType: CommentObject{}.ToAttrType(ctx), + }, }, } } @@ -289,16 +293,16 @@ func (newState *CreateExperiment) SyncEffectiveFieldsDuringRead(existingState Cr func (a CreateExperiment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(ExperimentTag{}), + "tags": reflect.TypeOf(ExperimentTag{}), } } func (a CreateExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactLocation": types.StringType, - "Name": types.StringType, - "Tags": basetypes.ListType{ + "artifact_location": types.StringType, + "name": types.StringType, + "tags": basetypes.ListType{ ElemType: ExperimentTag{}.ToAttrType(ctx), }, }, @@ -323,7 +327,7 @@ func (a CreateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type func (a CreateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -345,16 +349,16 @@ func (newState *CreateModelRequest) SyncEffectiveFieldsDuringRead(existingState func (a CreateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(ModelTag{}), + "tags": reflect.TypeOf(ModelTag{}), } } func (a CreateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Name": types.StringType, - "Tags": basetypes.ListType{ + "description": types.StringType, + "name": types.StringType, + "tags": basetypes.ListType{ ElemType: ModelTag{}.ToAttrType(ctx), }, }, @@ -373,14 +377,16 @@ func (newState *CreateModelResponse) SyncEffectiveFieldsDuringRead(existingState func (a CreateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RegisteredModel": reflect.TypeOf(Model{}), + "registered_model": reflect.TypeOf(Model{}), } } func (a CreateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RegisteredModel": Model{}.ToAttrType(ctx), + "registered_model": basetypes.ListType{ + ElemType: Model{}.ToAttrType(ctx), + }, }, } } @@ -410,19 +416,19 @@ func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringRead(existin func (a CreateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(ModelVersionTag{}), + "tags": reflect.TypeOf(ModelVersionTag{}), } } func (a CreateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Name": types.StringType, - "RunId": types.StringType, - "RunLink": types.StringType, - "Source": types.StringType, - "Tags": basetypes.ListType{ + "description": types.StringType, + "name": types.StringType, + "run_id": types.StringType, + "run_link": types.StringType, + "source": types.StringType, + "tags": basetypes.ListType{ ElemType: ModelVersionTag{}.ToAttrType(ctx), }, }, @@ -442,14 +448,16 @@ func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringRead(existi func (a CreateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ModelVersion": reflect.TypeOf(ModelVersion{}), + "model_version": reflect.TypeOf(ModelVersion{}), } } func (a CreateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelVersion": ModelVersion{}.ToAttrType(ctx), + "model_version": basetypes.ListType{ + ElemType: ModelVersion{}.ToAttrType(ctx), + }, }, } } @@ -516,23 +524,27 @@ func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingSta func (a CreateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(types.StringType), - "HttpUrlSpec": reflect.TypeOf(HttpUrlSpec{}), - "JobSpec": reflect.TypeOf(JobSpec{}), + "events": reflect.TypeOf(types.StringType), + "http_url_spec": reflect.TypeOf(HttpUrlSpec{}), + "job_spec": reflect.TypeOf(JobSpec{}), } } func (a CreateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Events": basetypes.ListType{ + "description": types.StringType, + "events": basetypes.ListType{ ElemType: types.StringType, }, - "HttpUrlSpec": HttpUrlSpec{}.ToAttrType(ctx), - "JobSpec": JobSpec{}.ToAttrType(ctx), - "ModelName": types.StringType, - "Status": types.StringType, + "http_url_spec": basetypes.ListType{ + ElemType: HttpUrlSpec{}.ToAttrType(ctx), + }, + "job_spec": basetypes.ListType{ + ElemType: JobSpec{}.ToAttrType(ctx), + }, + "model_name": types.StringType, + "status": types.StringType, }, } } @@ -558,19 +570,19 @@ func (newState *CreateRun) SyncEffectiveFieldsDuringRead(existingState CreateRun func (a CreateRun) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(RunTag{}), + "tags": reflect.TypeOf(RunTag{}), } } func (a CreateRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, - "StartTime": types.Int64Type, - "Tags": basetypes.ListType{ + "experiment_id": types.StringType, + "start_time": types.Int64Type, + "tags": basetypes.ListType{ ElemType: RunTag{}.ToAttrType(ctx), }, - "UserId": types.StringType, + "user_id": types.StringType, }, } } @@ -588,14 +600,16 @@ func (newState *CreateRunResponse) SyncEffectiveFieldsDuringRead(existingState C func (a CreateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Run": reflect.TypeOf(Run{}), + "run": reflect.TypeOf(Run{}), } } func (a CreateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Run": Run{}.ToAttrType(ctx), + "run": basetypes.ListType{ + ElemType: Run{}.ToAttrType(ctx), + }, }, } } @@ -632,10 +646,10 @@ func (a CreateTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type func (a CreateTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "Stage": types.StringType, - "Version": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "stage": types.StringType, + "version": types.StringType, }, } } @@ -653,14 +667,16 @@ func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringRead(e func (a CreateTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Request": reflect.TypeOf(TransitionRequest{}), + "request": reflect.TypeOf(TransitionRequest{}), } } func (a CreateTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Request": TransitionRequest{}.ToAttrType(ctx), + "request": basetypes.ListType{ + ElemType: TransitionRequest{}.ToAttrType(ctx), + }, }, } } @@ -677,14 +693,16 @@ func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringRead(existingSta func (a CreateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Webhook": reflect.TypeOf(RegistryWebhook{}), + "webhook": reflect.TypeOf(RegistryWebhook{}), } } func (a CreateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Webhook": RegistryWebhook{}.ToAttrType(ctx), + "webhook": basetypes.ListType{ + ElemType: RegistryWebhook{}.ToAttrType(ctx), + }, }, } } @@ -725,12 +743,12 @@ func (a Dataset) GetComplexFieldTypes() map[string]reflect.Type { func (a Dataset) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Digest": types.StringType, - "Name": types.StringType, - "Profile": types.StringType, - "Schema": types.StringType, - "Source": types.StringType, - "SourceType": types.StringType, + "digest": types.StringType, + "name": types.StringType, + "profile": types.StringType, + "schema": types.StringType, + "source": types.StringType, + "source_type": types.StringType, }, } } @@ -751,16 +769,18 @@ func (newState *DatasetInput) SyncEffectiveFieldsDuringRead(existingState Datase func (a DatasetInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Dataset": reflect.TypeOf(Dataset{}), - "Tags": reflect.TypeOf(InputTag{}), + "dataset": reflect.TypeOf(Dataset{}), + "tags": reflect.TypeOf(InputTag{}), } } func (a DatasetInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Dataset": Dataset{}.ToAttrType(ctx), - "Tags": basetypes.ListType{ + "dataset": basetypes.ListType{ + ElemType: Dataset{}.ToAttrType(ctx), + }, + "tags": basetypes.ListType{ ElemType: InputTag{}.ToAttrType(ctx), }, }, @@ -785,7 +805,7 @@ func (a DeleteCommentRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteCommentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -827,7 +847,7 @@ func (a DeleteExperiment) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -870,7 +890,7 @@ func (a DeleteModelRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -916,8 +936,8 @@ func (a DeleteModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Name": types.StringType, + "key": types.StringType, + "name": types.StringType, }, } } @@ -962,8 +982,8 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Version": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -1011,9 +1031,9 @@ func (a DeleteModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect. func (a DeleteModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Name": types.StringType, - "Version": types.StringType, + "key": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -1055,7 +1075,7 @@ func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.StringType, + "run_id": types.StringType, }, } } @@ -1104,9 +1124,9 @@ func (a DeleteRuns) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, - "MaxRuns": types.Int64Type, - "MaxTimestampMillis": types.Int64Type, + "experiment_id": types.StringType, + "max_runs": types.Int64Type, + "max_timestamp_millis": types.Int64Type, }, } } @@ -1129,7 +1149,7 @@ func (a DeleteRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunsDeleted": types.Int64Type, + "runs_deleted": types.Int64Type, }, } } @@ -1154,8 +1174,8 @@ func (a DeleteTag) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "RunId": types.StringType, + "key": types.StringType, + "run_id": types.StringType, }, } } @@ -1216,11 +1236,11 @@ func (a DeleteTransitionRequestRequest) GetComplexFieldTypes() map[string]reflec func (a DeleteTransitionRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Creator": types.StringType, - "Name": types.StringType, - "Stage": types.StringType, - "Version": types.StringType, + "comment": types.StringType, + "creator": types.StringType, + "name": types.StringType, + "stage": types.StringType, + "version": types.StringType, }, } } @@ -1263,7 +1283,7 @@ func (a DeleteWebhookRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1313,20 +1333,20 @@ func (newState *Experiment) SyncEffectiveFieldsDuringRead(existingState Experime func (a Experiment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(ExperimentTag{}), + "tags": reflect.TypeOf(ExperimentTag{}), } } func (a Experiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactLocation": types.StringType, - "CreationTime": types.Int64Type, - "ExperimentId": types.StringType, - "LastUpdateTime": types.Int64Type, - "LifecycleStage": types.StringType, - "Name": types.StringType, - "Tags": basetypes.ListType{ + "artifact_location": types.StringType, + "creation_time": types.Int64Type, + "experiment_id": types.StringType, + "last_update_time": types.Int64Type, + "lifecycle_stage": types.StringType, + "name": types.StringType, + "tags": basetypes.ListType{ ElemType: ExperimentTag{}.ToAttrType(ctx), }, }, @@ -1357,10 +1377,10 @@ func (a ExperimentAccessControlRequest) GetComplexFieldTypes() map[string]reflec func (a ExperimentAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1386,20 +1406,20 @@ func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringRead(e func (a ExperimentAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(ExperimentPermission{}), + "all_permissions": reflect.TypeOf(ExperimentPermission{}), } } func (a ExperimentAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: ExperimentPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1420,18 +1440,18 @@ func (newState *ExperimentPermission) SyncEffectiveFieldsDuringRead(existingStat func (a ExperimentPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a ExperimentPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1452,18 +1472,18 @@ func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringRead(existingSta func (a ExperimentPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ExperimentAccessControlResponse{}), + "access_control_list": reflect.TypeOf(ExperimentAccessControlResponse{}), } } func (a ExperimentPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ExperimentAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1487,8 +1507,8 @@ func (a ExperimentPermissionsDescription) GetComplexFieldTypes() map[string]refl func (a ExperimentPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1507,17 +1527,17 @@ func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(exis func (a ExperimentPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ExperimentAccessControlRequest{}), + "access_control_list": reflect.TypeOf(ExperimentAccessControlRequest{}), } } func (a ExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ExperimentAccessControlRequest{}.ToAttrType(ctx), }, - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -1542,8 +1562,8 @@ func (a ExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { func (a ExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -1570,9 +1590,9 @@ func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FileSize": types.Int64Type, - "IsDir": types.BoolType, - "Path": types.StringType, + "file_size": types.Int64Type, + "is_dir": types.BoolType, + "path": types.StringType, }, } } @@ -1596,7 +1616,7 @@ func (a GetByNameRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetByNameRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentName": types.StringType, + "experiment_name": types.StringType, }, } } @@ -1620,7 +1640,7 @@ func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes() map[string] func (a GetExperimentPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -1638,14 +1658,14 @@ func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuring func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(ExperimentPermissionsDescription{}), + "permission_levels": reflect.TypeOf(ExperimentPermissionsDescription{}), } } func (a GetExperimentPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: ExperimentPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -1671,7 +1691,7 @@ func (a GetExperimentPermissionsRequest) GetComplexFieldTypes() map[string]refle func (a GetExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -1695,7 +1715,7 @@ func (a GetExperimentRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetExperimentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -1713,14 +1733,16 @@ func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringRead(existingSta func (a GetExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Experiment": reflect.TypeOf(Experiment{}), + "experiment": reflect.TypeOf(Experiment{}), } } func (a GetExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Experiment": Experiment{}.ToAttrType(ctx), + "experiment": basetypes.ListType{ + ElemType: Experiment{}.ToAttrType(ctx), + }, }, } } @@ -1755,11 +1777,11 @@ func (a GetHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "MetricKey": types.StringType, - "PageToken": types.StringType, - "RunId": types.StringType, - "RunUuid": types.StringType, + "max_results": types.Int64Type, + "metric_key": types.StringType, + "page_token": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, }, } } @@ -1779,15 +1801,15 @@ func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringRead(existing func (a GetLatestVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Stages": reflect.TypeOf(types.StringType), + "stages": reflect.TypeOf(types.StringType), } } func (a GetLatestVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Stages": basetypes.ListType{ + "name": types.StringType, + "stages": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1809,14 +1831,14 @@ func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringRead(existin func (a GetLatestVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ModelVersions": reflect.TypeOf(ModelVersion{}), + "model_versions": reflect.TypeOf(ModelVersion{}), } } func (a GetLatestVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelVersions": basetypes.ListType{ + "model_versions": basetypes.ListType{ ElemType: ModelVersion{}.ToAttrType(ctx), }, }, @@ -1839,17 +1861,17 @@ func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringRead(existing func (a GetMetricHistoryResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Metrics": reflect.TypeOf(Metric{}), + "metrics": reflect.TypeOf(Metric{}), } } func (a GetMetricHistoryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Metrics": basetypes.ListType{ + "metrics": basetypes.ListType{ ElemType: Metric{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -1873,7 +1895,7 @@ func (a GetModelRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1890,14 +1912,16 @@ func (newState *GetModelResponse) SyncEffectiveFieldsDuringRead(existingState Ge func (a GetModelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RegisteredModelDatabricks": reflect.TypeOf(ModelDatabricks{}), + "registered_model_databricks": reflect.TypeOf(ModelDatabricks{}), } } func (a GetModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RegisteredModelDatabricks": ModelDatabricks{}.ToAttrType(ctx), + "registered_model_databricks": basetypes.ListType{ + ElemType: ModelDatabricks{}.ToAttrType(ctx), + }, }, } } @@ -1923,8 +1947,8 @@ func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes() map[string]ref func (a GetModelVersionDownloadUriRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Version": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -1947,7 +1971,7 @@ func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes() map[string]re func (a GetModelVersionDownloadUriResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactUri": types.StringType, + "artifact_uri": types.StringType, }, } } @@ -1973,8 +1997,8 @@ func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Version": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -1991,14 +2015,16 @@ func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringRead(existingS func (a GetModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ModelVersion": reflect.TypeOf(ModelVersion{}), + "model_version": reflect.TypeOf(ModelVersion{}), } } func (a GetModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelVersion": ModelVersion{}.ToAttrType(ctx), + "model_version": basetypes.ListType{ + ElemType: ModelVersion{}.ToAttrType(ctx), + }, }, } } @@ -2022,7 +2048,7 @@ func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes() map[st func (a GetRegisteredModelPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RegisteredModelId": types.StringType, + "registered_model_id": types.StringType, }, } } @@ -2040,14 +2066,14 @@ func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsD func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(RegisteredModelPermissionsDescription{}), + "permission_levels": reflect.TypeOf(RegisteredModelPermissionsDescription{}), } } func (a GetRegisteredModelPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: RegisteredModelPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -2073,7 +2099,7 @@ func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string] func (a GetRegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RegisteredModelId": types.StringType, + "registered_model_id": types.StringType, }, } } @@ -2100,8 +2126,8 @@ func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.StringType, - "RunUuid": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, }, } } @@ -2120,14 +2146,16 @@ func (newState *GetRunResponse) SyncEffectiveFieldsDuringRead(existingState GetR func (a GetRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Run": reflect.TypeOf(Run{}), + "run": reflect.TypeOf(Run{}), } } func (a GetRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Run": Run{}.ToAttrType(ctx), + "run": basetypes.ListType{ + ElemType: Run{}.ToAttrType(ctx), + }, }, } } @@ -2167,10 +2195,10 @@ func (a HttpUrlSpec) GetComplexFieldTypes() map[string]reflect.Type { func (a HttpUrlSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Authorization": types.StringType, - "EnableSslVerification": types.BoolType, - "Secret": types.StringType, - "Url": types.StringType, + "authorization": types.StringType, + "enable_ssl_verification": types.BoolType, + "secret": types.StringType, + "url": types.StringType, }, } } @@ -2201,8 +2229,8 @@ func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type func (a HttpUrlSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EnableSslVerification": types.BoolType, - "Url": types.StringType, + "enable_ssl_verification": types.BoolType, + "url": types.StringType, }, } } @@ -2227,8 +2255,8 @@ func (a InputTag) GetComplexFieldTypes() map[string]reflect.Type { func (a InputTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -2257,9 +2285,9 @@ func (a JobSpec) GetComplexFieldTypes() map[string]reflect.Type { func (a JobSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessToken": types.StringType, - "JobId": types.StringType, - "WorkspaceUrl": types.StringType, + "access_token": types.StringType, + "job_id": types.StringType, + "workspace_url": types.StringType, }, } } @@ -2286,8 +2314,8 @@ func (a JobSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type { func (a JobSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "JobId": types.StringType, - "WorkspaceUrl": types.StringType, + "job_id": types.StringType, + "workspace_url": types.StringType, }, } } @@ -2324,10 +2352,10 @@ func (a ListArtifactsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListArtifactsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageToken": types.StringType, - "Path": types.StringType, - "RunId": types.StringType, - "RunUuid": types.StringType, + "page_token": types.StringType, + "path": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, }, } } @@ -2349,18 +2377,18 @@ func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListArtifactsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Files": reflect.TypeOf(FileInfo{}), + "files": reflect.TypeOf(FileInfo{}), } } func (a ListArtifactsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Files": basetypes.ListType{ + "files": basetypes.ListType{ ElemType: FileInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, - "RootUri": types.StringType, + "next_page_token": types.StringType, + "root_uri": types.StringType, }, } } @@ -2393,9 +2421,9 @@ func (a ListExperimentsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListExperimentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "ViewType": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "view_type": types.StringType, }, } } @@ -2417,17 +2445,17 @@ func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringRead(existingS func (a ListExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Experiments": reflect.TypeOf(Experiment{}), + "experiments": reflect.TypeOf(Experiment{}), } } func (a ListExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Experiments": basetypes.ListType{ + "experiments": basetypes.ListType{ ElemType: Experiment{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2453,8 +2481,8 @@ func (a ListModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -2474,15 +2502,15 @@ func (newState *ListModelsResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RegisteredModels": reflect.TypeOf(Model{}), + "registered_models": reflect.TypeOf(Model{}), } } func (a ListModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "RegisteredModels": basetypes.ListType{ + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ ElemType: Model{}.ToAttrType(ctx), }, }, @@ -2504,15 +2532,15 @@ func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringRead(existingStat func (a ListRegistryWebhooks) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Webhooks": reflect.TypeOf(RegistryWebhook{}), + "webhooks": reflect.TypeOf(RegistryWebhook{}), } } func (a ListRegistryWebhooks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Webhooks": basetypes.ListType{ + "next_page_token": types.StringType, + "webhooks": basetypes.ListType{ ElemType: RegistryWebhook{}.ToAttrType(ctx), }, }, @@ -2540,8 +2568,8 @@ func (a ListTransitionRequestsRequest) GetComplexFieldTypes() map[string]reflect func (a ListTransitionRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Version": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -2559,14 +2587,14 @@ func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringRead(ex func (a ListTransitionRequestsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Requests": reflect.TypeOf(Activity{}), + "requests": reflect.TypeOf(Activity{}), } } func (a ListTransitionRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Requests": basetypes.ListType{ + "requests": basetypes.ListType{ ElemType: Activity{}.ToAttrType(ctx), }, }, @@ -2594,18 +2622,18 @@ func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListWebhooksRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(types.StringType), + "events": reflect.TypeOf(types.StringType), } } func (a ListWebhooksRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Events": basetypes.ListType{ + "events": basetypes.ListType{ ElemType: types.StringType, }, - "ModelName": types.StringType, - "PageToken": types.StringType, + "model_name": types.StringType, + "page_token": types.StringType, }, } } @@ -2632,23 +2660,23 @@ func (newState *LogBatch) SyncEffectiveFieldsDuringRead(existingState LogBatch) func (a LogBatch) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Metrics": reflect.TypeOf(Metric{}), - "Params": reflect.TypeOf(Param{}), - "Tags": reflect.TypeOf(RunTag{}), + "metrics": reflect.TypeOf(Metric{}), + "params": reflect.TypeOf(Param{}), + "tags": reflect.TypeOf(RunTag{}), } } func (a LogBatch) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Metrics": basetypes.ListType{ + "metrics": basetypes.ListType{ ElemType: Metric{}.ToAttrType(ctx), }, - "Params": basetypes.ListType{ + "params": basetypes.ListType{ ElemType: Param{}.ToAttrType(ctx), }, - "RunId": types.StringType, - "Tags": basetypes.ListType{ + "run_id": types.StringType, + "tags": basetypes.ListType{ ElemType: RunTag{}.ToAttrType(ctx), }, }, @@ -2689,17 +2717,17 @@ func (newState *LogInputs) SyncEffectiveFieldsDuringRead(existingState LogInputs func (a LogInputs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Datasets": reflect.TypeOf(DatasetInput{}), + "datasets": reflect.TypeOf(DatasetInput{}), } } func (a LogInputs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Datasets": basetypes.ListType{ + "datasets": basetypes.ListType{ ElemType: DatasetInput{}.ToAttrType(ctx), }, - "RunId": types.StringType, + "run_id": types.StringType, }, } } @@ -2752,12 +2780,12 @@ func (a LogMetric) GetComplexFieldTypes() map[string]reflect.Type { func (a LogMetric) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "RunId": types.StringType, - "RunUuid": types.StringType, - "Step": types.Int64Type, - "Timestamp": types.Int64Type, - "Value": types.Float64Type, + "key": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, + "step": types.Int64Type, + "timestamp": types.Int64Type, + "value": types.Float64Type, }, } } @@ -2801,8 +2829,8 @@ func (a LogModel) GetComplexFieldTypes() map[string]reflect.Type { func (a LogModel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelJson": types.StringType, - "RunId": types.StringType, + "model_json": types.StringType, + "run_id": types.StringType, }, } } @@ -2851,10 +2879,10 @@ func (a LogParam) GetComplexFieldTypes() map[string]reflect.Type { func (a LogParam) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "RunId": types.StringType, - "RunUuid": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, + "value": types.StringType, }, } } @@ -2902,10 +2930,10 @@ func (a Metric) GetComplexFieldTypes() map[string]reflect.Type { func (a Metric) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Step": types.Int64Type, - "Timestamp": types.Int64Type, - "Value": types.Float64Type, + "key": types.StringType, + "step": types.Int64Type, + "timestamp": types.Int64Type, + "value": types.Float64Type, }, } } @@ -2937,25 +2965,25 @@ func (newState *Model) SyncEffectiveFieldsDuringRead(existingState Model) { func (a Model) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LatestVersions": reflect.TypeOf(ModelVersion{}), - "Tags": reflect.TypeOf(ModelTag{}), + "latest_versions": reflect.TypeOf(ModelVersion{}), + "tags": reflect.TypeOf(ModelTag{}), } } func (a Model) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "Description": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "LatestVersions": basetypes.ListType{ + "creation_timestamp": types.Int64Type, + "description": types.StringType, + "last_updated_timestamp": types.Int64Type, + "latest_versions": basetypes.ListType{ ElemType: ModelVersion{}.ToAttrType(ctx), }, - "Name": types.StringType, - "Tags": basetypes.ListType{ + "name": types.StringType, + "tags": basetypes.ListType{ ElemType: ModelTag{}.ToAttrType(ctx), }, - "UserId": types.StringType, + "user_id": types.StringType, }, } } @@ -2990,27 +3018,27 @@ func (newState *ModelDatabricks) SyncEffectiveFieldsDuringRead(existingState Mod func (a ModelDatabricks) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LatestVersions": reflect.TypeOf(ModelVersion{}), - "Tags": reflect.TypeOf(ModelTag{}), + "latest_versions": reflect.TypeOf(ModelVersion{}), + "tags": reflect.TypeOf(ModelTag{}), } } func (a ModelDatabricks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "Description": types.StringType, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "LatestVersions": basetypes.ListType{ + "creation_timestamp": types.Int64Type, + "description": types.StringType, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "latest_versions": basetypes.ListType{ ElemType: ModelVersion{}.ToAttrType(ctx), }, - "Name": types.StringType, - "PermissionLevel": types.StringType, - "Tags": basetypes.ListType{ + "name": types.StringType, + "permission_level": types.StringType, + "tags": basetypes.ListType{ ElemType: ModelTag{}.ToAttrType(ctx), }, - "UserId": types.StringType, + "user_id": types.StringType, }, } } @@ -3035,8 +3063,8 @@ func (a ModelTag) GetComplexFieldTypes() map[string]reflect.Type { func (a ModelTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -3081,28 +3109,28 @@ func (newState *ModelVersion) SyncEffectiveFieldsDuringRead(existingState ModelV func (a ModelVersion) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(ModelVersionTag{}), + "tags": reflect.TypeOf(ModelVersionTag{}), } } func (a ModelVersion) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "CurrentStage": types.StringType, - "Description": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "Name": types.StringType, - "RunId": types.StringType, - "RunLink": types.StringType, - "Source": types.StringType, - "Status": types.StringType, - "StatusMessage": types.StringType, - "Tags": basetypes.ListType{ + "creation_timestamp": types.Int64Type, + "current_stage": types.StringType, + "description": types.StringType, + "last_updated_timestamp": types.Int64Type, + "name": types.StringType, + "run_id": types.StringType, + "run_link": types.StringType, + "source": types.StringType, + "status": types.StringType, + "status_message": types.StringType, + "tags": basetypes.ListType{ ElemType: ModelVersionTag{}.ToAttrType(ctx), }, - "UserId": types.StringType, - "Version": types.StringType, + "user_id": types.StringType, + "version": types.StringType, }, } } @@ -3166,29 +3194,29 @@ func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringRead(existingSt func (a ModelVersionDatabricks) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(ModelVersionTag{}), + "tags": reflect.TypeOf(ModelVersionTag{}), } } func (a ModelVersionDatabricks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "CurrentStage": types.StringType, - "Description": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "Name": types.StringType, - "PermissionLevel": types.StringType, - "RunId": types.StringType, - "RunLink": types.StringType, - "Source": types.StringType, - "Status": types.StringType, - "StatusMessage": types.StringType, - "Tags": basetypes.ListType{ + "creation_timestamp": types.Int64Type, + "current_stage": types.StringType, + "description": types.StringType, + "last_updated_timestamp": types.Int64Type, + "name": types.StringType, + "permission_level": types.StringType, + "run_id": types.StringType, + "run_link": types.StringType, + "source": types.StringType, + "status": types.StringType, + "status_message": types.StringType, + "tags": basetypes.ListType{ ElemType: ModelVersionTag{}.ToAttrType(ctx), }, - "UserId": types.StringType, - "Version": types.StringType, + "user_id": types.StringType, + "version": types.StringType, }, } } @@ -3213,8 +3241,8 @@ func (a ModelVersionTag) GetComplexFieldTypes() map[string]reflect.Type { func (a ModelVersionTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -3239,8 +3267,8 @@ func (a Param) GetComplexFieldTypes() map[string]reflect.Type { func (a Param) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -3269,10 +3297,10 @@ func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes() map[string]r func (a RegisteredModelAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -3298,20 +3326,20 @@ func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringR func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(RegisteredModelPermission{}), + "all_permissions": reflect.TypeOf(RegisteredModelPermission{}), } } func (a RegisteredModelAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: RegisteredModelPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -3332,18 +3360,18 @@ func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringRead(existin func (a RegisteredModelPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a RegisteredModelPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -3364,18 +3392,18 @@ func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringRead(existi func (a RegisteredModelPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(RegisteredModelAccessControlResponse{}), + "access_control_list": reflect.TypeOf(RegisteredModelAccessControlResponse{}), } } func (a RegisteredModelPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: RegisteredModelAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3399,8 +3427,8 @@ func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes() map[string func (a RegisteredModelPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -3419,17 +3447,17 @@ func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(RegisteredModelAccessControlRequest{}), + "access_control_list": reflect.TypeOf(RegisteredModelAccessControlRequest{}), } } func (a RegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: RegisteredModelAccessControlRequest{}.ToAttrType(ctx), }, - "RegisteredModelId": types.StringType, + "registered_model_id": types.StringType, }, } } @@ -3502,26 +3530,30 @@ func (newState *RegistryWebhook) SyncEffectiveFieldsDuringRead(existingState Reg func (a RegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(types.StringType), - "HttpUrlSpec": reflect.TypeOf(HttpUrlSpecWithoutSecret{}), - "JobSpec": reflect.TypeOf(JobSpecWithoutSecret{}), + "events": reflect.TypeOf(types.StringType), + "http_url_spec": reflect.TypeOf(HttpUrlSpecWithoutSecret{}), + "job_spec": reflect.TypeOf(JobSpecWithoutSecret{}), } } func (a RegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "Description": types.StringType, - "Events": basetypes.ListType{ + "creation_timestamp": types.Int64Type, + "description": types.StringType, + "events": basetypes.ListType{ ElemType: types.StringType, }, - "HttpUrlSpec": HttpUrlSpecWithoutSecret{}.ToAttrType(ctx), - "Id": types.StringType, - "JobSpec": JobSpecWithoutSecret{}.ToAttrType(ctx), - "LastUpdatedTimestamp": types.Int64Type, - "ModelName": types.StringType, - "Status": types.StringType, + "http_url_spec": basetypes.ListType{ + ElemType: HttpUrlSpecWithoutSecret{}.ToAttrType(ctx), + }, + "id": types.StringType, + "job_spec": basetypes.ListType{ + ElemType: JobSpecWithoutSecret{}.ToAttrType(ctx), + }, + "last_updated_timestamp": types.Int64Type, + "model_name": types.StringType, + "status": types.StringType, }, } } @@ -3558,10 +3590,10 @@ func (a RejectTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type func (a RejectTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "Stage": types.StringType, - "Version": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "stage": types.StringType, + "version": types.StringType, }, } } @@ -3579,14 +3611,16 @@ func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringRead(e func (a RejectTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Activity": reflect.TypeOf(Activity{}), + "activity": reflect.TypeOf(Activity{}), } } func (a RejectTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Activity": Activity{}.ToAttrType(ctx), + "activity": basetypes.ListType{ + ElemType: Activity{}.ToAttrType(ctx), + }, }, } } @@ -3611,8 +3645,8 @@ func (a RenameModelRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a RenameModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "NewName": types.StringType, + "name": types.StringType, + "new_name": types.StringType, }, } } @@ -3629,14 +3663,16 @@ func (newState *RenameModelResponse) SyncEffectiveFieldsDuringRead(existingState func (a RenameModelResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RegisteredModel": reflect.TypeOf(Model{}), + "registered_model": reflect.TypeOf(Model{}), } } func (a RenameModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RegisteredModel": Model{}.ToAttrType(ctx), + "registered_model": basetypes.ListType{ + ElemType: Model{}.ToAttrType(ctx), + }, }, } } @@ -3659,7 +3695,7 @@ func (a RestoreExperiment) GetComplexFieldTypes() map[string]reflect.Type { func (a RestoreExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, + "experiment_id": types.StringType, }, } } @@ -3701,7 +3737,7 @@ func (a RestoreRun) GetComplexFieldTypes() map[string]reflect.Type { func (a RestoreRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunId": types.StringType, + "run_id": types.StringType, }, } } @@ -3750,9 +3786,9 @@ func (a RestoreRuns) GetComplexFieldTypes() map[string]reflect.Type { func (a RestoreRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, - "MaxRuns": types.Int64Type, - "MinTimestampMillis": types.Int64Type, + "experiment_id": types.StringType, + "max_runs": types.Int64Type, + "min_timestamp_millis": types.Int64Type, }, } } @@ -3775,7 +3811,7 @@ func (a RestoreRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a RestoreRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunsRestored": types.Int64Type, + "runs_restored": types.Int64Type, }, } } @@ -3797,18 +3833,24 @@ func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { func (a Run) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Data": reflect.TypeOf(RunData{}), - "Info": reflect.TypeOf(RunInfo{}), - "Inputs": reflect.TypeOf(RunInputs{}), + "data": reflect.TypeOf(RunData{}), + "info": reflect.TypeOf(RunInfo{}), + "inputs": reflect.TypeOf(RunInputs{}), } } func (a Run) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Data": RunData{}.ToAttrType(ctx), - "Info": RunInfo{}.ToAttrType(ctx), - "Inputs": RunInputs{}.ToAttrType(ctx), + "data": basetypes.ListType{ + ElemType: RunData{}.ToAttrType(ctx), + }, + "info": basetypes.ListType{ + ElemType: RunInfo{}.ToAttrType(ctx), + }, + "inputs": basetypes.ListType{ + ElemType: RunInputs{}.ToAttrType(ctx), + }, }, } } @@ -3830,22 +3872,22 @@ func (newState *RunData) SyncEffectiveFieldsDuringRead(existingState RunData) { func (a RunData) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Metrics": reflect.TypeOf(Metric{}), - "Params": reflect.TypeOf(Param{}), - "Tags": reflect.TypeOf(RunTag{}), + "metrics": reflect.TypeOf(Metric{}), + "params": reflect.TypeOf(Param{}), + "tags": reflect.TypeOf(RunTag{}), } } func (a RunData) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Metrics": basetypes.ListType{ + "metrics": basetypes.ListType{ ElemType: Metric{}.ToAttrType(ctx), }, - "Params": basetypes.ListType{ + "params": basetypes.ListType{ ElemType: Param{}.ToAttrType(ctx), }, - "Tags": basetypes.ListType{ + "tags": basetypes.ListType{ ElemType: RunTag{}.ToAttrType(ctx), }, }, @@ -3892,15 +3934,15 @@ func (a RunInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a RunInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArtifactUri": types.StringType, - "EndTime": types.Int64Type, - "ExperimentId": types.StringType, - "LifecycleStage": types.StringType, - "RunId": types.StringType, - "RunUuid": types.StringType, - "StartTime": types.Int64Type, - "Status": types.StringType, - "UserId": types.StringType, + "artifact_uri": types.StringType, + "end_time": types.Int64Type, + "experiment_id": types.StringType, + "lifecycle_stage": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, + "start_time": types.Int64Type, + "status": types.StringType, + "user_id": types.StringType, }, } } @@ -3918,14 +3960,14 @@ func (newState *RunInputs) SyncEffectiveFieldsDuringRead(existingState RunInputs func (a RunInputs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DatasetInputs": reflect.TypeOf(DatasetInput{}), + "dataset_inputs": reflect.TypeOf(DatasetInput{}), } } func (a RunInputs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DatasetInputs": basetypes.ListType{ + "dataset_inputs": basetypes.ListType{ ElemType: DatasetInput{}.ToAttrType(ctx), }, }, @@ -3952,8 +3994,8 @@ func (a RunTag) GetComplexFieldTypes() map[string]reflect.Type { func (a RunTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -3984,20 +4026,20 @@ func (newState *SearchExperiments) SyncEffectiveFieldsDuringRead(existingState S func (a SearchExperiments) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.StringType), } } func (a SearchExperiments) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": types.StringType, - "MaxResults": types.Int64Type, - "OrderBy": basetypes.ListType{ + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ ElemType: types.StringType, }, - "PageToken": types.StringType, - "ViewType": types.StringType, + "page_token": types.StringType, + "view_type": types.StringType, }, } } @@ -4018,17 +4060,17 @@ func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringRead(existin func (a SearchExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Experiments": reflect.TypeOf(Experiment{}), + "experiments": reflect.TypeOf(Experiment{}), } } func (a SearchExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Experiments": basetypes.ListType{ + "experiments": basetypes.ListType{ ElemType: Experiment{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4057,19 +4099,19 @@ func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringRead(existi func (a SearchModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.StringType), } } func (a SearchModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": types.StringType, - "MaxResults": types.Int64Type, - "OrderBy": basetypes.ListType{ + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ ElemType: types.StringType, }, - "PageToken": types.StringType, + "page_token": types.StringType, }, } } @@ -4090,17 +4132,17 @@ func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringRead(exist func (a SearchModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ModelVersions": reflect.TypeOf(ModelVersion{}), + "model_versions": reflect.TypeOf(ModelVersion{}), } } func (a SearchModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelVersions": basetypes.ListType{ + "model_versions": basetypes.ListType{ ElemType: ModelVersion{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -4129,19 +4171,19 @@ func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringRead(existingState func (a SearchModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.StringType), } } func (a SearchModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": types.StringType, - "MaxResults": types.Int64Type, - "OrderBy": basetypes.ListType{ + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ ElemType: types.StringType, }, - "PageToken": types.StringType, + "page_token": types.StringType, }, } } @@ -4161,15 +4203,15 @@ func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringRead(existingStat func (a SearchModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RegisteredModels": reflect.TypeOf(Model{}), + "registered_models": reflect.TypeOf(Model{}), } } func (a SearchModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "RegisteredModels": basetypes.ListType{ + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ ElemType: Model{}.ToAttrType(ctx), }, }, @@ -4216,24 +4258,24 @@ func (newState *SearchRuns) SyncEffectiveFieldsDuringRead(existingState SearchRu func (a SearchRuns) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExperimentIds": reflect.TypeOf(types.StringType), - "OrderBy": reflect.TypeOf(types.StringType), + "experiment_ids": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.StringType), } } func (a SearchRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentIds": basetypes.ListType{ + "experiment_ids": basetypes.ListType{ ElemType: types.StringType, }, - "Filter": types.StringType, - "MaxResults": types.Int64Type, - "OrderBy": basetypes.ListType{ + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ ElemType: types.StringType, }, - "PageToken": types.StringType, - "RunViewType": types.StringType, + "page_token": types.StringType, + "run_view_type": types.StringType, }, } } @@ -4253,15 +4295,15 @@ func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringRead(existingState func (a SearchRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Runs": reflect.TypeOf(Run{}), + "runs": reflect.TypeOf(Run{}), } } func (a SearchRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Runs": basetypes.ListType{ + "next_page_token": types.StringType, + "runs": basetypes.ListType{ ElemType: Run{}.ToAttrType(ctx), }, }, @@ -4293,9 +4335,9 @@ func (a SetExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { func (a SetExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, - "Key": types.StringType, - "Value": types.StringType, + "experiment_id": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -4346,9 +4388,9 @@ func (a SetModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a SetModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Name": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "name": types.StringType, + "value": types.StringType, }, } } @@ -4401,10 +4443,10 @@ func (a SetModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a SetModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Name": types.StringType, - "Value": types.StringType, - "Version": types.StringType, + "key": types.StringType, + "name": types.StringType, + "value": types.StringType, + "version": types.StringType, }, } } @@ -4456,10 +4498,10 @@ func (a SetTag) GetComplexFieldTypes() map[string]reflect.Type { func (a SetTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "RunId": types.StringType, - "RunUuid": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "run_id": types.StringType, + "run_uuid": types.StringType, + "value": types.StringType, }, } } @@ -4504,8 +4546,8 @@ func (a TestRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { func (a TestRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Body": types.StringType, - "StatusCode": types.Int64Type, + "body": types.StringType, + "status_code": types.Int64Type, }, } } @@ -4532,8 +4574,8 @@ func (a TestRegistryWebhookRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a TestRegistryWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Event": types.StringType, - "Id": types.StringType, + "event": types.StringType, + "id": types.StringType, }, } } @@ -4551,14 +4593,16 @@ func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringRead(exist func (a TestRegistryWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Webhook": reflect.TypeOf(TestRegistryWebhook{}), + "webhook": reflect.TypeOf(TestRegistryWebhook{}), } } func (a TestRegistryWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Webhook": TestRegistryWebhook{}.ToAttrType(ctx), + "webhook": basetypes.ListType{ + ElemType: TestRegistryWebhook{}.ToAttrType(ctx), + }, }, } } @@ -4598,11 +4642,11 @@ func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes() map[string func (a TransitionModelVersionStageDatabricks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ArchiveExistingVersions": types.BoolType, - "Comment": types.StringType, - "Name": types.StringType, - "Stage": types.StringType, - "Version": types.StringType, + "archive_existing_versions": types.BoolType, + "comment": types.StringType, + "name": types.StringType, + "stage": types.StringType, + "version": types.StringType, }, } } @@ -4638,20 +4682,20 @@ func (newState *TransitionRequest) SyncEffectiveFieldsDuringRead(existingState T func (a TransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AvailableActions": reflect.TypeOf(types.StringType), + "available_actions": reflect.TypeOf(types.StringType), } } func (a TransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AvailableActions": basetypes.ListType{ + "available_actions": basetypes.ListType{ ElemType: types.StringType, }, - "Comment": types.StringType, - "CreationTimestamp": types.Int64Type, - "ToStage": types.StringType, - "UserId": types.StringType, + "comment": types.StringType, + "creation_timestamp": types.Int64Type, + "to_stage": types.StringType, + "user_id": types.StringType, }, } } @@ -4668,14 +4712,16 @@ func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringRead(existingS func (a TransitionStageResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ModelVersion": reflect.TypeOf(ModelVersionDatabricks{}), + "model_version": reflect.TypeOf(ModelVersionDatabricks{}), } } func (a TransitionStageResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelVersion": ModelVersionDatabricks{}.ToAttrType(ctx), + "model_version": basetypes.ListType{ + ElemType: ModelVersionDatabricks{}.ToAttrType(ctx), + }, }, } } @@ -4700,8 +4746,8 @@ func (a UpdateComment) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateComment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Id": types.StringType, + "comment": types.StringType, + "id": types.StringType, }, } } @@ -4719,14 +4765,16 @@ func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Comment": reflect.TypeOf(CommentObject{}), + "comment": reflect.TypeOf(CommentObject{}), } } func (a UpdateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": CommentObject{}.ToAttrType(ctx), + "comment": basetypes.ListType{ + ElemType: CommentObject{}.ToAttrType(ctx), + }, }, } } @@ -4752,8 +4800,8 @@ func (a UpdateExperiment) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExperimentId": types.StringType, - "NewName": types.StringType, + "experiment_id": types.StringType, + "new_name": types.StringType, }, } } @@ -4797,8 +4845,8 @@ func (a UpdateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Name": types.StringType, + "description": types.StringType, + "name": types.StringType, }, } } @@ -4844,9 +4892,9 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Name": types.StringType, - "Version": types.StringType, + "description": types.StringType, + "name": types.StringType, + "version": types.StringType, }, } } @@ -4932,23 +4980,27 @@ func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(types.StringType), - "HttpUrlSpec": reflect.TypeOf(HttpUrlSpec{}), - "JobSpec": reflect.TypeOf(JobSpec{}), + "events": reflect.TypeOf(types.StringType), + "http_url_spec": reflect.TypeOf(HttpUrlSpec{}), + "job_spec": reflect.TypeOf(JobSpec{}), } } func (a UpdateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Events": basetypes.ListType{ + "description": types.StringType, + "events": basetypes.ListType{ ElemType: types.StringType, }, - "HttpUrlSpec": HttpUrlSpec{}.ToAttrType(ctx), - "Id": types.StringType, - "JobSpec": JobSpec{}.ToAttrType(ctx), - "Status": types.StringType, + "http_url_spec": basetypes.ListType{ + ElemType: HttpUrlSpec{}.ToAttrType(ctx), + }, + "id": types.StringType, + "job_spec": basetypes.ListType{ + ElemType: JobSpec{}.ToAttrType(ctx), + }, + "status": types.StringType, }, } } @@ -4978,10 +5030,10 @@ func (a UpdateRun) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndTime": types.Int64Type, - "RunId": types.StringType, - "RunUuid": types.StringType, - "Status": types.StringType, + "end_time": types.Int64Type, + "run_id": types.StringType, + "run_uuid": types.StringType, + "status": types.StringType, }, } } @@ -4999,14 +5051,16 @@ func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringRead(existingState U func (a UpdateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RunInfo": reflect.TypeOf(RunInfo{}), + "run_info": reflect.TypeOf(RunInfo{}), } } func (a UpdateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunInfo": RunInfo{}.ToAttrType(ctx), + "run_info": basetypes.ListType{ + ElemType: RunInfo{}.ToAttrType(ctx), + }, }, } } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 7c8ea0076c..71c99ceb0b 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -42,24 +42,26 @@ func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existi func (a CreateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(types.StringType), - "Scopes": reflect.TypeOf(types.StringType), - "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + "redirect_urls": reflect.TypeOf(types.StringType), + "scopes": reflect.TypeOf(types.StringType), + "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } func (a CreateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Confidential": types.BoolType, - "Name": types.StringType, - "RedirectUrls": basetypes.ListType{ + "confidential": types.BoolType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ ElemType: types.StringType, }, - "Scopes": basetypes.ListType{ + "scopes": basetypes.ListType{ ElemType: types.StringType, }, - "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + }, }, } } @@ -87,9 +89,9 @@ func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]refl func (a CreateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClientId": types.StringType, - "ClientSecret": types.StringType, - "IntegrationId": types.StringType, + "client_id": types.StringType, + "client_secret": types.StringType, + "integration_id": types.StringType, }, } } @@ -110,15 +112,17 @@ func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(exi func (a CreatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } func (a CreatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppId": types.StringType, - "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + "app_id": types.StringType, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + }, }, } } @@ -141,7 +145,7 @@ func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]r func (a CreatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, + "integration_id": types.StringType, }, } } @@ -165,7 +169,7 @@ func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]r func (a CreateServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ServicePrincipalId": types.Int64Type, + "service_principal_id": types.Int64Type, }, } } @@ -198,12 +202,12 @@ func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes() map[string] func (a CreateServicePrincipalSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "Id": types.StringType, - "Secret": types.StringType, - "SecretHash": types.StringType, - "Status": types.StringType, - "UpdateTime": types.StringType, + "create_time": types.StringType, + "id": types.StringType, + "secret": types.StringType, + "secret_hash": types.StringType, + "status": types.StringType, + "update_time": types.StringType, }, } } @@ -228,8 +232,8 @@ func (a DataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a DataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AuthorizationDetails": types.StringType, - "EndpointUrl": types.StringType, + "authorization_details": types.StringType, + "endpoint_url": types.StringType, }, } } @@ -271,7 +275,7 @@ func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]ref func (a DeleteCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, + "integration_id": types.StringType, }, } } @@ -313,7 +317,7 @@ func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes() map[string] func (a DeletePublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, + "integration_id": types.StringType, }, } } @@ -358,8 +362,8 @@ func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]r func (a DeleteServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "SecretId": types.StringType, - "ServicePrincipalId": types.Int64Type, + "secret_id": types.StringType, + "service_principal_id": types.Int64Type, }, } } @@ -396,29 +400,31 @@ func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(exi func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(types.StringType), - "Scopes": reflect.TypeOf(types.StringType), - "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + "redirect_urls": reflect.TypeOf(types.StringType), + "scopes": reflect.TypeOf(types.StringType), + "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } func (a GetCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClientId": types.StringType, - "Confidential": types.BoolType, - "CreateTime": types.StringType, - "CreatedBy": types.Int64Type, - "CreatorUsername": types.StringType, - "IntegrationId": types.StringType, - "Name": types.StringType, - "RedirectUrls": basetypes.ListType{ + "client_id": types.StringType, + "confidential": types.BoolType, + "create_time": types.StringType, + "created_by": types.Int64Type, + "creator_username": types.StringType, + "integration_id": types.StringType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ ElemType: types.StringType, }, - "Scopes": basetypes.ListType{ + "scopes": basetypes.ListType{ ElemType: types.StringType, }, - "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + }, }, } } @@ -442,7 +448,7 @@ func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]reflec func (a GetCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, + "integration_id": types.StringType, }, } } @@ -462,17 +468,17 @@ func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(ex func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Apps": reflect.TypeOf(GetCustomAppIntegrationOutput{}), + "apps": reflect.TypeOf(GetCustomAppIntegrationOutput{}), } } func (a GetCustomAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Apps": basetypes.ListType{ + "apps": basetypes.ListType{ ElemType: GetCustomAppIntegrationOutput{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -500,19 +506,21 @@ func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead( func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } func (a GetPublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppId": types.StringType, - "CreateTime": types.StringType, - "CreatedBy": types.Int64Type, - "IntegrationId": types.StringType, - "Name": types.StringType, - "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + "app_id": types.StringType, + "create_time": types.StringType, + "created_by": types.Int64Type, + "integration_id": types.StringType, + "name": types.StringType, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + }, }, } } @@ -535,7 +543,7 @@ func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes() map[string]ref func (a GetPublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, + "integration_id": types.StringType, }, } } @@ -555,17 +563,17 @@ func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringRead func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Apps": reflect.TypeOf(GetPublishedAppIntegrationOutput{}), + "apps": reflect.TypeOf(GetPublishedAppIntegrationOutput{}), } } func (a GetPublishedAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Apps": basetypes.ListType{ + "apps": basetypes.ListType{ ElemType: GetPublishedAppIntegrationOutput{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -586,17 +594,17 @@ func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringRead(existingSt func (a GetPublishedAppsOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Apps": reflect.TypeOf(PublishedAppOutput{}), + "apps": reflect.TypeOf(PublishedAppOutput{}), } } func (a GetPublishedAppsOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Apps": basetypes.ListType{ + "apps": basetypes.ListType{ ElemType: PublishedAppOutput{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -623,9 +631,9 @@ func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes() map[string]refl func (a ListCustomAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeCreatorUsername": types.BoolType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "include_creator_username": types.BoolType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -651,8 +659,8 @@ func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes() map[string]reflect func (a ListOAuthPublishedAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -677,8 +685,8 @@ func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes() map[string]r func (a ListPublishedAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -712,8 +720,8 @@ func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes() map[string]re func (a ListServicePrincipalSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageToken": types.StringType, - "ServicePrincipalId": types.Int64Type, + "page_token": types.StringType, + "service_principal_id": types.Int64Type, }, } } @@ -733,15 +741,15 @@ func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringRe func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Secrets": reflect.TypeOf(SecretInfo{}), + "secrets": reflect.TypeOf(SecretInfo{}), } } func (a ListServicePrincipalSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Secrets": basetypes.ListType{ + "next_page_token": types.StringType, + "secrets": basetypes.ListType{ ElemType: SecretInfo{}.ToAttrType(ctx), }, }, @@ -775,23 +783,23 @@ func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringRead(existingState func (a PublishedAppOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(types.StringType), - "Scopes": reflect.TypeOf(types.StringType), + "redirect_urls": reflect.TypeOf(types.StringType), + "scopes": reflect.TypeOf(types.StringType), } } func (a PublishedAppOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AppId": types.StringType, - "ClientId": types.StringType, - "Description": types.StringType, - "IsConfidentialClient": types.BoolType, - "Name": types.StringType, - "RedirectUrls": basetypes.ListType{ + "app_id": types.StringType, + "client_id": types.StringType, + "description": types.StringType, + "is_confidential_client": types.BoolType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ ElemType: types.StringType, }, - "Scopes": basetypes.ListType{ + "scopes": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -824,11 +832,11 @@ func (a SecretInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a SecretInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "Id": types.StringType, - "SecretHash": types.StringType, - "Status": types.StringType, - "UpdateTime": types.StringType, + "create_time": types.StringType, + "id": types.StringType, + "secret_hash": types.StringType, + "status": types.StringType, + "update_time": types.StringType, }, } } @@ -853,8 +861,8 @@ func (a TokenAccessPolicy) GetComplexFieldTypes() map[string]reflect.Type { func (a TokenAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessTokenTtlInMinutes": types.Int64Type, - "RefreshTokenTtlInMinutes": types.Int64Type, + "access_token_ttl_in_minutes": types.Int64Type, + "refresh_token_ttl_in_minutes": types.Int64Type, }, } } @@ -876,19 +884,21 @@ func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existi func (a UpdateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RedirectUrls": reflect.TypeOf(types.StringType), - "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + "redirect_urls": reflect.TypeOf(types.StringType), + "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } func (a UpdateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, - "RedirectUrls": basetypes.ListType{ + "integration_id": types.StringType, + "redirect_urls": basetypes.ListType{ ElemType: types.StringType, }, - "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + }, }, } } @@ -926,15 +936,17 @@ func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(exi func (a UpdatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenAccessPolicy": reflect.TypeOf(TokenAccessPolicy{}), + "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } func (a UpdatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationId": types.StringType, - "TokenAccessPolicy": TokenAccessPolicy{}.ToAttrType(ctx), + "integration_id": types.StringType, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + }, }, } } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 64a62752b8..5e2488fe95 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -92,55 +92,67 @@ func (newState *CreatePipeline) SyncEffectiveFieldsDuringRead(existingState Crea func (a CreatePipeline) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Clusters": reflect.TypeOf(PipelineCluster{}), - "Configuration": reflect.TypeOf(types.StringType), - "Deployment": reflect.TypeOf(PipelineDeployment{}), - "Filters": reflect.TypeOf(Filters{}), - "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), - "IngestionDefinition": reflect.TypeOf(IngestionPipelineDefinition{}), - "Libraries": reflect.TypeOf(PipelineLibrary{}), - "Notifications": reflect.TypeOf(Notifications{}), - "RestartWindow": reflect.TypeOf(RestartWindow{}), - "Trigger": reflect.TypeOf(PipelineTrigger{}), + "clusters": reflect.TypeOf(PipelineCluster{}), + "configuration": reflect.TypeOf(types.StringType), + "deployment": reflect.TypeOf(PipelineDeployment{}), + "filters": reflect.TypeOf(Filters{}), + "gateway_definition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), + "ingestion_definition": reflect.TypeOf(IngestionPipelineDefinition{}), + "libraries": reflect.TypeOf(PipelineLibrary{}), + "notifications": reflect.TypeOf(Notifications{}), + "restart_window": reflect.TypeOf(RestartWindow{}), + "trigger": reflect.TypeOf(PipelineTrigger{}), } } func (a CreatePipeline) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowDuplicateNames": types.BoolType, - "BudgetPolicyId": types.StringType, - "Catalog": types.StringType, - "Channel": types.StringType, - "Clusters": basetypes.ListType{ + "allow_duplicate_names": types.BoolType, + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ ElemType: PipelineCluster{}.ToAttrType(ctx), }, - "Configuration": basetypes.MapType{ + "configuration": basetypes.MapType{ ElemType: types.StringType, }, - "Continuous": types.BoolType, - "Deployment": PipelineDeployment{}.ToAttrType(ctx), - "Development": types.BoolType, - "DryRun": types.BoolType, - "Edition": types.StringType, - "Filters": Filters{}.ToAttrType(ctx), - "GatewayDefinition": IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), - "Id": types.StringType, - "IngestionDefinition": IngestionPipelineDefinition{}.ToAttrType(ctx), - "Libraries": basetypes.ListType{ + "continuous": types.BoolType, + "deployment": basetypes.ListType{ + ElemType: PipelineDeployment{}.ToAttrType(ctx), + }, + "development": types.BoolType, + "dry_run": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ + ElemType: Filters{}.ToAttrType(ctx), + }, + "gateway_definition": basetypes.ListType{ + ElemType: IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + }, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ + ElemType: IngestionPipelineDefinition{}.ToAttrType(ctx), + }, + "libraries": basetypes.ListType{ ElemType: PipelineLibrary{}.ToAttrType(ctx), }, - "Name": types.StringType, - "Notifications": basetypes.ListType{ + "name": types.StringType, + "notifications": basetypes.ListType{ ElemType: Notifications{}.ToAttrType(ctx), }, - "Photon": types.BoolType, - "RestartWindow": RestartWindow{}.ToAttrType(ctx), - "Schema": types.StringType, - "Serverless": types.BoolType, - "Storage": types.StringType, - "Target": types.StringType, - "Trigger": PipelineTrigger{}.ToAttrType(ctx), + "photon": types.BoolType, + "restart_window": basetypes.ListType{ + ElemType: RestartWindow{}.ToAttrType(ctx), + }, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ + ElemType: PipelineTrigger{}.ToAttrType(ctx), + }, }, } } @@ -161,15 +173,17 @@ func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringRead(existingSt func (a CreatePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EffectiveSettings": reflect.TypeOf(PipelineSpec{}), + "effective_settings": reflect.TypeOf(PipelineSpec{}), } } func (a CreatePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EffectiveSettings": PipelineSpec{}.ToAttrType(ctx), - "PipelineId": types.StringType, + "effective_settings": basetypes.ListType{ + ElemType: PipelineSpec{}.ToAttrType(ctx), + }, + "pipeline_id": types.StringType, }, } } @@ -193,8 +207,8 @@ func (a CronTrigger) GetComplexFieldTypes() map[string]reflect.Type { func (a CronTrigger) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QuartzCronSchedule": types.StringType, - "TimezoneId": types.StringType, + "quartz_cron_schedule": types.StringType, + "timezone_id": types.StringType, }, } } @@ -219,8 +233,8 @@ func (a DataPlaneId) GetComplexFieldTypes() map[string]reflect.Type { func (a DataPlaneId) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Instance": types.StringType, - "SeqNo": types.Int64Type, + "instance": types.StringType, + "seq_no": types.Int64Type, }, } } @@ -243,7 +257,7 @@ func (a DeletePipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeletePipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PipelineId": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -342,56 +356,68 @@ func (newState *EditPipeline) SyncEffectiveFieldsDuringRead(existingState EditPi func (a EditPipeline) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Clusters": reflect.TypeOf(PipelineCluster{}), - "Configuration": reflect.TypeOf(types.StringType), - "Deployment": reflect.TypeOf(PipelineDeployment{}), - "Filters": reflect.TypeOf(Filters{}), - "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), - "IngestionDefinition": reflect.TypeOf(IngestionPipelineDefinition{}), - "Libraries": reflect.TypeOf(PipelineLibrary{}), - "Notifications": reflect.TypeOf(Notifications{}), - "RestartWindow": reflect.TypeOf(RestartWindow{}), - "Trigger": reflect.TypeOf(PipelineTrigger{}), + "clusters": reflect.TypeOf(PipelineCluster{}), + "configuration": reflect.TypeOf(types.StringType), + "deployment": reflect.TypeOf(PipelineDeployment{}), + "filters": reflect.TypeOf(Filters{}), + "gateway_definition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), + "ingestion_definition": reflect.TypeOf(IngestionPipelineDefinition{}), + "libraries": reflect.TypeOf(PipelineLibrary{}), + "notifications": reflect.TypeOf(Notifications{}), + "restart_window": reflect.TypeOf(RestartWindow{}), + "trigger": reflect.TypeOf(PipelineTrigger{}), } } func (a EditPipeline) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowDuplicateNames": types.BoolType, - "BudgetPolicyId": types.StringType, - "Catalog": types.StringType, - "Channel": types.StringType, - "Clusters": basetypes.ListType{ + "allow_duplicate_names": types.BoolType, + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ ElemType: PipelineCluster{}.ToAttrType(ctx), }, - "Configuration": basetypes.MapType{ + "configuration": basetypes.MapType{ ElemType: types.StringType, }, - "Continuous": types.BoolType, - "Deployment": PipelineDeployment{}.ToAttrType(ctx), - "Development": types.BoolType, - "Edition": types.StringType, - "ExpectedLastModified": types.Int64Type, - "Filters": Filters{}.ToAttrType(ctx), - "GatewayDefinition": IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), - "Id": types.StringType, - "IngestionDefinition": IngestionPipelineDefinition{}.ToAttrType(ctx), - "Libraries": basetypes.ListType{ + "continuous": types.BoolType, + "deployment": basetypes.ListType{ + ElemType: PipelineDeployment{}.ToAttrType(ctx), + }, + "development": types.BoolType, + "edition": types.StringType, + "expected_last_modified": types.Int64Type, + "filters": basetypes.ListType{ + ElemType: Filters{}.ToAttrType(ctx), + }, + "gateway_definition": basetypes.ListType{ + ElemType: IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + }, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ + ElemType: IngestionPipelineDefinition{}.ToAttrType(ctx), + }, + "libraries": basetypes.ListType{ ElemType: PipelineLibrary{}.ToAttrType(ctx), }, - "Name": types.StringType, - "Notifications": basetypes.ListType{ + "name": types.StringType, + "notifications": basetypes.ListType{ ElemType: Notifications{}.ToAttrType(ctx), }, - "Photon": types.BoolType, - "PipelineId": types.StringType, - "RestartWindow": RestartWindow{}.ToAttrType(ctx), - "Schema": types.StringType, - "Serverless": types.BoolType, - "Storage": types.StringType, - "Target": types.StringType, - "Trigger": PipelineTrigger{}.ToAttrType(ctx), + "photon": types.BoolType, + "pipeline_id": types.StringType, + "restart_window": basetypes.ListType{ + ElemType: RestartWindow{}.ToAttrType(ctx), + }, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ + ElemType: PipelineTrigger{}.ToAttrType(ctx), + }, }, } } @@ -430,17 +456,17 @@ func (newState *ErrorDetail) SyncEffectiveFieldsDuringRead(existingState ErrorDe func (a ErrorDetail) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exceptions": reflect.TypeOf(SerializedException{}), + "exceptions": reflect.TypeOf(SerializedException{}), } } func (a ErrorDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exceptions": basetypes.ListType{ + "exceptions": basetypes.ListType{ ElemType: SerializedException{}.ToAttrType(ctx), }, - "Fatal": types.BoolType, + "fatal": types.BoolType, }, } } @@ -463,7 +489,7 @@ func (a FileLibrary) GetComplexFieldTypes() map[string]reflect.Type { func (a FileLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -483,18 +509,18 @@ func (newState *Filters) SyncEffectiveFieldsDuringRead(existingState Filters) { func (a Filters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Exclude": reflect.TypeOf(types.StringType), - "Include": reflect.TypeOf(types.StringType), + "exclude": reflect.TypeOf(types.StringType), + "include": reflect.TypeOf(types.StringType), } } func (a Filters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Exclude": basetypes.ListType{ + "exclude": basetypes.ListType{ ElemType: types.StringType, }, - "Include": basetypes.ListType{ + "include": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -520,7 +546,7 @@ func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes() map[string]re func (a GetPipelinePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PipelineId": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -538,14 +564,14 @@ func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringRe func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(PipelinePermissionsDescription{}), + "permission_levels": reflect.TypeOf(PipelinePermissionsDescription{}), } } func (a GetPipelinePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: PipelinePermissionsDescription{}.ToAttrType(ctx), }, }, @@ -571,7 +597,7 @@ func (a GetPipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect func (a GetPipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PipelineId": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -594,7 +620,7 @@ func (a GetPipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetPipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PipelineId": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -636,28 +662,30 @@ func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringRead(existingState func (a GetPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LatestUpdates": reflect.TypeOf(UpdateStateInfo{}), - "Spec": reflect.TypeOf(PipelineSpec{}), + "latest_updates": reflect.TypeOf(UpdateStateInfo{}), + "spec": reflect.TypeOf(PipelineSpec{}), } } func (a GetPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cause": types.StringType, - "ClusterId": types.StringType, - "CreatorUserName": types.StringType, - "EffectiveBudgetPolicyId": types.StringType, - "Health": types.StringType, - "LastModified": types.Int64Type, - "LatestUpdates": basetypes.ListType{ + "cause": types.StringType, + "cluster_id": types.StringType, + "creator_user_name": types.StringType, + "effective_budget_policy_id": types.StringType, + "health": types.StringType, + "last_modified": types.Int64Type, + "latest_updates": basetypes.ListType{ ElemType: UpdateStateInfo{}.ToAttrType(ctx), }, - "Name": types.StringType, - "PipelineId": types.StringType, - "RunAsUserName": types.StringType, - "Spec": PipelineSpec{}.ToAttrType(ctx), - "State": types.StringType, + "name": types.StringType, + "pipeline_id": types.StringType, + "run_as_user_name": types.StringType, + "spec": basetypes.ListType{ + ElemType: PipelineSpec{}.ToAttrType(ctx), + }, + "state": types.StringType, }, } } @@ -683,8 +711,8 @@ func (a GetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PipelineId": types.StringType, - "UpdateId": types.StringType, + "pipeline_id": types.StringType, + "update_id": types.StringType, }, } } @@ -702,14 +730,16 @@ func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringRead(existingState G func (a GetUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Update": reflect.TypeOf(UpdateInfo{}), + "update": reflect.TypeOf(UpdateInfo{}), } } func (a GetUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Update": UpdateInfo{}.ToAttrType(ctx), + "update": basetypes.ListType{ + ElemType: UpdateInfo{}.ToAttrType(ctx), + }, }, } } @@ -731,18 +761,24 @@ func (newState *IngestionConfig) SyncEffectiveFieldsDuringRead(existingState Ing func (a IngestionConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Report": reflect.TypeOf(ReportSpec{}), - "Schema": reflect.TypeOf(SchemaSpec{}), - "Table": reflect.TypeOf(TableSpec{}), + "report": reflect.TypeOf(ReportSpec{}), + "schema": reflect.TypeOf(SchemaSpec{}), + "table": reflect.TypeOf(TableSpec{}), } } func (a IngestionConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Report": ReportSpec{}.ToAttrType(ctx), - "Schema": SchemaSpec{}.ToAttrType(ctx), - "Table": TableSpec{}.ToAttrType(ctx), + "report": basetypes.ListType{ + ElemType: ReportSpec{}.ToAttrType(ctx), + }, + "schema": basetypes.ListType{ + ElemType: SchemaSpec{}.ToAttrType(ctx), + }, + "table": basetypes.ListType{ + ElemType: TableSpec{}.ToAttrType(ctx), + }, }, } } @@ -781,11 +817,11 @@ func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes() map[string]re func (a IngestionGatewayPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConnectionId": types.StringType, - "ConnectionName": types.StringType, - "GatewayStorageCatalog": types.StringType, - "GatewayStorageName": types.StringType, - "GatewayStorageSchema": types.StringType, + "connection_id": types.StringType, + "connection_name": types.StringType, + "gateway_storage_catalog": types.StringType, + "gateway_storage_name": types.StringType, + "gateway_storage_schema": types.StringType, }, } } @@ -815,20 +851,22 @@ func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringRead(exist func (a IngestionPipelineDefinition) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Objects": reflect.TypeOf(IngestionConfig{}), - "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + "objects": reflect.TypeOf(IngestionConfig{}), + "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } func (a IngestionPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConnectionName": types.StringType, - "IngestionGatewayId": types.StringType, - "Objects": basetypes.ListType{ + "connection_name": types.StringType, + "ingestion_gateway_id": types.StringType, + "objects": basetypes.ListType{ ElemType: IngestionConfig{}.ToAttrType(ctx), }, - "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.ToAttrType(ctx), + }, }, } } @@ -868,20 +906,20 @@ func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringRead(existin func (a ListPipelineEventsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.StringType), } } func (a ListPipelineEventsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": types.StringType, - "MaxResults": types.Int64Type, - "OrderBy": basetypes.ListType{ + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ ElemType: types.StringType, }, - "PageToken": types.StringType, - "PipelineId": types.StringType, + "page_token": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -903,18 +941,18 @@ func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringRead(existi func (a ListPipelineEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Events": reflect.TypeOf(PipelineEvent{}), + "events": reflect.TypeOf(PipelineEvent{}), } } func (a ListPipelineEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Events": basetypes.ListType{ + "events": basetypes.ListType{ ElemType: PipelineEvent{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, + "next_page_token": types.StringType, + "prev_page_token": types.StringType, }, } } @@ -952,19 +990,19 @@ func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringRead(existingStat func (a ListPipelinesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "OrderBy": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.StringType), } } func (a ListPipelinesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Filter": types.StringType, - "MaxResults": types.Int64Type, - "OrderBy": basetypes.ListType{ + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ ElemType: types.StringType, }, - "PageToken": types.StringType, + "page_token": types.StringType, }, } } @@ -984,15 +1022,15 @@ func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListPipelinesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Statuses": reflect.TypeOf(PipelineStateInfo{}), + "statuses": reflect.TypeOf(PipelineStateInfo{}), } } func (a ListPipelinesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Statuses": basetypes.ListType{ + "next_page_token": types.StringType, + "statuses": basetypes.ListType{ ElemType: PipelineStateInfo{}.ToAttrType(ctx), }, }, @@ -1024,10 +1062,10 @@ func (a ListUpdatesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListUpdatesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "PageToken": types.StringType, - "PipelineId": types.StringType, - "UntilUpdateId": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, + "pipeline_id": types.StringType, + "until_update_id": types.StringType, }, } } @@ -1051,16 +1089,16 @@ func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListUpdatesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Updates": reflect.TypeOf(UpdateInfo{}), + "updates": reflect.TypeOf(UpdateInfo{}), } } func (a ListUpdatesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "PrevPageToken": types.StringType, - "Updates": basetypes.ListType{ + "next_page_token": types.StringType, + "prev_page_token": types.StringType, + "updates": basetypes.ListType{ ElemType: UpdateInfo{}.ToAttrType(ctx), }, }, @@ -1104,7 +1142,7 @@ func (a NotebookLibrary) GetComplexFieldTypes() map[string]reflect.Type { func (a NotebookLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -1130,18 +1168,18 @@ func (newState *Notifications) SyncEffectiveFieldsDuringRead(existingState Notif func (a Notifications) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Alerts": reflect.TypeOf(types.StringType), - "EmailRecipients": reflect.TypeOf(types.StringType), + "alerts": reflect.TypeOf(types.StringType), + "email_recipients": reflect.TypeOf(types.StringType), } } func (a Notifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alerts": basetypes.ListType{ + "alerts": basetypes.ListType{ ElemType: types.StringType, }, - "EmailRecipients": basetypes.ListType{ + "email_recipients": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1199,23 +1237,23 @@ func (a Origin) GetComplexFieldTypes() map[string]reflect.Type { func (a Origin) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BatchId": types.Int64Type, - "Cloud": types.StringType, - "ClusterId": types.StringType, - "DatasetName": types.StringType, - "FlowId": types.StringType, - "FlowName": types.StringType, - "Host": types.StringType, - "MaintenanceId": types.StringType, - "MaterializationName": types.StringType, - "OrgId": types.Int64Type, - "PipelineId": types.StringType, - "PipelineName": types.StringType, - "Region": types.StringType, - "RequestId": types.StringType, - "TableId": types.StringType, - "UcResourceId": types.StringType, - "UpdateId": types.StringType, + "batch_id": types.Int64Type, + "cloud": types.StringType, + "cluster_id": types.StringType, + "dataset_name": types.StringType, + "flow_id": types.StringType, + "flow_name": types.StringType, + "host": types.StringType, + "maintenance_id": types.StringType, + "materialization_name": types.StringType, + "org_id": types.Int64Type, + "pipeline_id": types.StringType, + "pipeline_name": types.StringType, + "region": types.StringType, + "request_id": types.StringType, + "table_id": types.StringType, + "uc_resource_id": types.StringType, + "update_id": types.StringType, }, } } @@ -1244,10 +1282,10 @@ func (a PipelineAccessControlRequest) GetComplexFieldTypes() map[string]reflect. func (a PipelineAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1273,20 +1311,20 @@ func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringRead(exi func (a PipelineAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(PipelinePermission{}), + "all_permissions": reflect.TypeOf(PipelinePermission{}), } } func (a PipelineAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: PipelinePermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1396,49 +1434,59 @@ func (newState *PipelineCluster) SyncEffectiveFieldsDuringRead(existingState Pip func (a PipelineCluster) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Autoscale": reflect.TypeOf(PipelineClusterAutoscale{}), - "AwsAttributes": reflect.TypeOf(compute.AwsAttributes{}), - "AzureAttributes": reflect.TypeOf(compute.AzureAttributes{}), - "ClusterLogConf": reflect.TypeOf(compute.ClusterLogConf{}), - "CustomTags": reflect.TypeOf(types.StringType), - "GcpAttributes": reflect.TypeOf(compute.GcpAttributes{}), - "InitScripts": reflect.TypeOf(compute.InitScriptInfo{}), - "SparkConf": reflect.TypeOf(types.StringType), - "SparkEnvVars": reflect.TypeOf(types.StringType), - "SshPublicKeys": reflect.TypeOf(types.StringType), + "autoscale": reflect.TypeOf(PipelineClusterAutoscale{}), + "aws_attributes": reflect.TypeOf(compute.AwsAttributes{}), + "azure_attributes": reflect.TypeOf(compute.AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(compute.ClusterLogConf{}), + "custom_tags": reflect.TypeOf(types.StringType), + "gcp_attributes": reflect.TypeOf(compute.GcpAttributes{}), + "init_scripts": reflect.TypeOf(compute.InitScriptInfo{}), + "spark_conf": reflect.TypeOf(types.StringType), + "spark_env_vars": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.StringType), } } func (a PipelineCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyPolicyDefaultValues": types.BoolType, - "Autoscale": PipelineClusterAutoscale{}.ToAttrType(ctx), - "AwsAttributes": compute_tf.AwsAttributes{}.ToAttrType(ctx), - "AzureAttributes": compute_tf.AzureAttributes{}.ToAttrType(ctx), - "ClusterLogConf": compute_tf.ClusterLogConf{}.ToAttrType(ctx), - "CustomTags": basetypes.MapType{ + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ + ElemType: PipelineClusterAutoscale{}.ToAttrType(ctx), + }, + "aws_attributes": basetypes.ListType{ + ElemType: compute_tf.AwsAttributes{}.ToAttrType(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: compute_tf.AzureAttributes{}.ToAttrType(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: compute_tf.ClusterLogConf{}.ToAttrType(ctx), + }, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DriverInstancePoolId": types.StringType, - "DriverNodeTypeId": types.StringType, - "EnableLocalDiskEncryption": types.BoolType, - "GcpAttributes": compute_tf.GcpAttributes{}.ToAttrType(ctx), - "InitScripts": basetypes.ListType{ + "driver_instance_pool_id": types.StringType, + "driver_node_type_id": types.StringType, + "enable_local_disk_encryption": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: compute_tf.GcpAttributes{}.ToAttrType(ctx), + }, + "init_scripts": basetypes.ListType{ ElemType: compute_tf.InitScriptInfo{}.ToAttrType(ctx), }, - "InstancePoolId": types.StringType, - "Label": types.StringType, - "NodeTypeId": types.StringType, - "NumWorkers": types.Int64Type, - "PolicyId": types.StringType, - "SparkConf": basetypes.MapType{ + "instance_pool_id": types.StringType, + "label": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "spark_conf": basetypes.MapType{ ElemType: types.StringType, }, - "SparkEnvVars": basetypes.MapType{ + "spark_env_vars": basetypes.MapType{ ElemType: types.StringType, }, - "SshPublicKeys": basetypes.ListType{ + "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1474,9 +1522,9 @@ func (a PipelineClusterAutoscale) GetComplexFieldTypes() map[string]reflect.Type func (a PipelineClusterAutoscale) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxWorkers": types.Int64Type, - "MinWorkers": types.Int64Type, - "Mode": types.StringType, + "max_workers": types.Int64Type, + "min_workers": types.Int64Type, + "mode": types.StringType, }, } } @@ -1501,8 +1549,8 @@ func (a PipelineDeployment) GetComplexFieldTypes() map[string]reflect.Type { func (a PipelineDeployment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Kind": types.StringType, - "MetadataFilePath": types.StringType, + "kind": types.StringType, + "metadata_file_path": types.StringType, }, } } @@ -1536,24 +1584,30 @@ func (newState *PipelineEvent) SyncEffectiveFieldsDuringRead(existingState Pipel func (a PipelineEvent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Error": reflect.TypeOf(ErrorDetail{}), - "Origin": reflect.TypeOf(Origin{}), - "Sequence": reflect.TypeOf(Sequencing{}), + "error": reflect.TypeOf(ErrorDetail{}), + "origin": reflect.TypeOf(Origin{}), + "sequence": reflect.TypeOf(Sequencing{}), } } func (a PipelineEvent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Error": ErrorDetail{}.ToAttrType(ctx), - "EventType": types.StringType, - "Id": types.StringType, - "Level": types.StringType, - "MaturityLevel": types.StringType, - "Message": types.StringType, - "Origin": Origin{}.ToAttrType(ctx), - "Sequence": Sequencing{}.ToAttrType(ctx), - "Timestamp": types.StringType, + "error": basetypes.ListType{ + ElemType: ErrorDetail{}.ToAttrType(ctx), + }, + "event_type": types.StringType, + "id": types.StringType, + "level": types.StringType, + "maturity_level": types.StringType, + "message": types.StringType, + "origin": basetypes.ListType{ + ElemType: Origin{}.ToAttrType(ctx), + }, + "sequence": basetypes.ListType{ + ElemType: Sequencing{}.ToAttrType(ctx), + }, + "timestamp": types.StringType, }, } } @@ -1581,20 +1635,26 @@ func (newState *PipelineLibrary) SyncEffectiveFieldsDuringRead(existingState Pip func (a PipelineLibrary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "File": reflect.TypeOf(FileLibrary{}), - "Maven": reflect.TypeOf(compute.MavenLibrary{}), - "Notebook": reflect.TypeOf(NotebookLibrary{}), + "file": reflect.TypeOf(FileLibrary{}), + "maven": reflect.TypeOf(compute.MavenLibrary{}), + "notebook": reflect.TypeOf(NotebookLibrary{}), } } func (a PipelineLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "File": FileLibrary{}.ToAttrType(ctx), - "Jar": types.StringType, - "Maven": compute_tf.MavenLibrary{}.ToAttrType(ctx), - "Notebook": NotebookLibrary{}.ToAttrType(ctx), - "Whl": types.StringType, + "file": basetypes.ListType{ + ElemType: FileLibrary{}.ToAttrType(ctx), + }, + "jar": types.StringType, + "maven": basetypes.ListType{ + ElemType: compute_tf.MavenLibrary{}.ToAttrType(ctx), + }, + "notebook": basetypes.ListType{ + ElemType: NotebookLibrary{}.ToAttrType(ctx), + }, + "whl": types.StringType, }, } } @@ -1615,18 +1675,18 @@ func (newState *PipelinePermission) SyncEffectiveFieldsDuringRead(existingState func (a PipelinePermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a PipelinePermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1647,18 +1707,18 @@ func (newState *PipelinePermissions) SyncEffectiveFieldsDuringRead(existingState func (a PipelinePermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(PipelineAccessControlResponse{}), + "access_control_list": reflect.TypeOf(PipelineAccessControlResponse{}), } } func (a PipelinePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: PipelineAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1682,8 +1742,8 @@ func (a PipelinePermissionsDescription) GetComplexFieldTypes() map[string]reflec func (a PipelinePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1702,17 +1762,17 @@ func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existi func (a PipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(PipelineAccessControlRequest{}), + "access_control_list": reflect.TypeOf(PipelineAccessControlRequest{}), } } func (a PipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: PipelineAccessControlRequest{}.ToAttrType(ctx), }, - "PipelineId": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -1783,53 +1843,65 @@ func (newState *PipelineSpec) SyncEffectiveFieldsDuringRead(existingState Pipeli func (a PipelineSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Clusters": reflect.TypeOf(PipelineCluster{}), - "Configuration": reflect.TypeOf(types.StringType), - "Deployment": reflect.TypeOf(PipelineDeployment{}), - "Filters": reflect.TypeOf(Filters{}), - "GatewayDefinition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), - "IngestionDefinition": reflect.TypeOf(IngestionPipelineDefinition{}), - "Libraries": reflect.TypeOf(PipelineLibrary{}), - "Notifications": reflect.TypeOf(Notifications{}), - "RestartWindow": reflect.TypeOf(RestartWindow{}), - "Trigger": reflect.TypeOf(PipelineTrigger{}), + "clusters": reflect.TypeOf(PipelineCluster{}), + "configuration": reflect.TypeOf(types.StringType), + "deployment": reflect.TypeOf(PipelineDeployment{}), + "filters": reflect.TypeOf(Filters{}), + "gateway_definition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), + "ingestion_definition": reflect.TypeOf(IngestionPipelineDefinition{}), + "libraries": reflect.TypeOf(PipelineLibrary{}), + "notifications": reflect.TypeOf(Notifications{}), + "restart_window": reflect.TypeOf(RestartWindow{}), + "trigger": reflect.TypeOf(PipelineTrigger{}), } } func (a PipelineSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BudgetPolicyId": types.StringType, - "Catalog": types.StringType, - "Channel": types.StringType, - "Clusters": basetypes.ListType{ + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ ElemType: PipelineCluster{}.ToAttrType(ctx), }, - "Configuration": basetypes.MapType{ + "configuration": basetypes.MapType{ ElemType: types.StringType, }, - "Continuous": types.BoolType, - "Deployment": PipelineDeployment{}.ToAttrType(ctx), - "Development": types.BoolType, - "Edition": types.StringType, - "Filters": Filters{}.ToAttrType(ctx), - "GatewayDefinition": IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), - "Id": types.StringType, - "IngestionDefinition": IngestionPipelineDefinition{}.ToAttrType(ctx), - "Libraries": basetypes.ListType{ + "continuous": types.BoolType, + "deployment": basetypes.ListType{ + ElemType: PipelineDeployment{}.ToAttrType(ctx), + }, + "development": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ + ElemType: Filters{}.ToAttrType(ctx), + }, + "gateway_definition": basetypes.ListType{ + ElemType: IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + }, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ + ElemType: IngestionPipelineDefinition{}.ToAttrType(ctx), + }, + "libraries": basetypes.ListType{ ElemType: PipelineLibrary{}.ToAttrType(ctx), }, - "Name": types.StringType, - "Notifications": basetypes.ListType{ + "name": types.StringType, + "notifications": basetypes.ListType{ ElemType: Notifications{}.ToAttrType(ctx), }, - "Photon": types.BoolType, - "RestartWindow": RestartWindow{}.ToAttrType(ctx), - "Schema": types.StringType, - "Serverless": types.BoolType, - "Storage": types.StringType, - "Target": types.StringType, - "Trigger": PipelineTrigger{}.ToAttrType(ctx), + "photon": types.BoolType, + "restart_window": basetypes.ListType{ + ElemType: RestartWindow{}.ToAttrType(ctx), + }, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ + ElemType: PipelineTrigger{}.ToAttrType(ctx), + }, }, } } @@ -1863,23 +1935,23 @@ func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringRead(existingState P func (a PipelineStateInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LatestUpdates": reflect.TypeOf(UpdateStateInfo{}), + "latest_updates": reflect.TypeOf(UpdateStateInfo{}), } } func (a PipelineStateInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClusterId": types.StringType, - "CreatorUserName": types.StringType, - "Health": types.StringType, - "LatestUpdates": basetypes.ListType{ + "cluster_id": types.StringType, + "creator_user_name": types.StringType, + "health": types.StringType, + "latest_updates": basetypes.ListType{ ElemType: UpdateStateInfo{}.ToAttrType(ctx), }, - "Name": types.StringType, - "PipelineId": types.StringType, - "RunAsUserName": types.StringType, - "State": types.StringType, + "name": types.StringType, + "pipeline_id": types.StringType, + "run_as_user_name": types.StringType, + "state": types.StringType, }, } } @@ -1898,16 +1970,20 @@ func (newState *PipelineTrigger) SyncEffectiveFieldsDuringRead(existingState Pip func (a PipelineTrigger) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Cron": reflect.TypeOf(CronTrigger{}), - "Manual": reflect.TypeOf(ManualTrigger{}), + "cron": reflect.TypeOf(CronTrigger{}), + "manual": reflect.TypeOf(ManualTrigger{}), } } func (a PipelineTrigger) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cron": CronTrigger{}.ToAttrType(ctx), - "Manual": ManualTrigger{}.ToAttrType(ctx), + "cron": basetypes.ListType{ + ElemType: CronTrigger{}.ToAttrType(ctx), + }, + "manual": basetypes.ListType{ + ElemType: ManualTrigger{}.ToAttrType(ctx), + }, }, } } @@ -1936,18 +2012,20 @@ func (newState *ReportSpec) SyncEffectiveFieldsDuringRead(existingState ReportSp func (a ReportSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } func (a ReportSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationCatalog": types.StringType, - "DestinationSchema": types.StringType, - "DestinationTable": types.StringType, - "SourceUrl": types.StringType, - "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + "destination_catalog": types.StringType, + "destination_schema": types.StringType, + "destination_table": types.StringType, + "source_url": types.StringType, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.ToAttrType(ctx), + }, }, } } @@ -1980,9 +2058,9 @@ func (a RestartWindow) GetComplexFieldTypes() map[string]reflect.Type { func (a RestartWindow) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DaysOfWeek": types.StringType, - "StartHour": types.Int64Type, - "TimeZoneId": types.StringType, + "days_of_week": types.StringType, + "start_hour": types.Int64Type, + "time_zone_id": types.StringType, }, } } @@ -2013,18 +2091,20 @@ func (newState *SchemaSpec) SyncEffectiveFieldsDuringRead(existingState SchemaSp func (a SchemaSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } func (a SchemaSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationCatalog": types.StringType, - "DestinationSchema": types.StringType, - "SourceCatalog": types.StringType, - "SourceSchema": types.StringType, - "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + "destination_catalog": types.StringType, + "destination_schema": types.StringType, + "source_catalog": types.StringType, + "source_schema": types.StringType, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.ToAttrType(ctx), + }, }, } } @@ -2044,15 +2124,17 @@ func (newState *Sequencing) SyncEffectiveFieldsDuringRead(existingState Sequenci func (a Sequencing) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataPlaneId": reflect.TypeOf(DataPlaneId{}), + "data_plane_id": reflect.TypeOf(DataPlaneId{}), } } func (a Sequencing) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ControlPlaneSeqNo": types.Int64Type, - "DataPlaneId": DataPlaneId{}.ToAttrType(ctx), + "control_plane_seq_no": types.Int64Type, + "data_plane_id": basetypes.ListType{ + ElemType: DataPlaneId{}.ToAttrType(ctx), + }, }, } } @@ -2074,16 +2156,16 @@ func (newState *SerializedException) SyncEffectiveFieldsDuringRead(existingState func (a SerializedException) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Stack": reflect.TypeOf(StackFrame{}), + "stack": reflect.TypeOf(StackFrame{}), } } func (a SerializedException) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ClassName": types.StringType, - "Message": types.StringType, - "Stack": basetypes.ListType{ + "class_name": types.StringType, + "message": types.StringType, + "stack": basetypes.ListType{ ElemType: StackFrame{}.ToAttrType(ctx), }, }, @@ -2114,10 +2196,10 @@ func (a StackFrame) GetComplexFieldTypes() map[string]reflect.Type { func (a StackFrame) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DeclaringClass": types.StringType, - "FileName": types.StringType, - "LineNumber": types.Int64Type, - "MethodName": types.StringType, + "declaring_class": types.StringType, + "file_name": types.StringType, + "line_number": types.Int64Type, + "method_name": types.StringType, }, } } @@ -2151,24 +2233,24 @@ func (newState *StartUpdate) SyncEffectiveFieldsDuringRead(existingState StartUp func (a StartUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FullRefreshSelection": reflect.TypeOf(types.StringType), - "RefreshSelection": reflect.TypeOf(types.StringType), + "full_refresh_selection": reflect.TypeOf(types.StringType), + "refresh_selection": reflect.TypeOf(types.StringType), } } func (a StartUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cause": types.StringType, - "FullRefresh": types.BoolType, - "FullRefreshSelection": basetypes.ListType{ + "cause": types.StringType, + "full_refresh": types.BoolType, + "full_refresh_selection": basetypes.ListType{ ElemType: types.StringType, }, - "PipelineId": types.StringType, - "RefreshSelection": basetypes.ListType{ + "pipeline_id": types.StringType, + "refresh_selection": basetypes.ListType{ ElemType: types.StringType, }, - "ValidateOnly": types.BoolType, + "validate_only": types.BoolType, }, } } @@ -2190,7 +2272,7 @@ func (a StartUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a StartUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "UpdateId": types.StringType, + "update_id": types.StringType, }, } } @@ -2232,7 +2314,7 @@ func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PipelineId": types.StringType, + "pipeline_id": types.StringType, }, } } @@ -2266,20 +2348,22 @@ func (newState *TableSpec) SyncEffectiveFieldsDuringRead(existingState TableSpec func (a TableSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TableConfiguration": reflect.TypeOf(TableSpecificConfig{}), + "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } func (a TableSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationCatalog": types.StringType, - "DestinationSchema": types.StringType, - "DestinationTable": types.StringType, - "SourceCatalog": types.StringType, - "SourceSchema": types.StringType, - "SourceTable": types.StringType, - "TableConfiguration": TableSpecificConfig{}.ToAttrType(ctx), + "destination_catalog": types.StringType, + "destination_schema": types.StringType, + "destination_table": types.StringType, + "source_catalog": types.StringType, + "source_schema": types.StringType, + "source_table": types.StringType, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.ToAttrType(ctx), + }, }, } } @@ -2306,20 +2390,20 @@ func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringRead(existingState func (a TableSpecificConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrimaryKeys": reflect.TypeOf(types.StringType), - "SequenceBy": reflect.TypeOf(types.StringType), + "primary_keys": reflect.TypeOf(types.StringType), + "sequence_by": reflect.TypeOf(types.StringType), } } func (a TableSpecificConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrimaryKeys": basetypes.ListType{ + "primary_keys": basetypes.ListType{ ElemType: types.StringType, }, - "SalesforceIncludeFormulaFields": types.BoolType, - "ScdType": types.StringType, - "SequenceBy": basetypes.ListType{ + "salesforce_include_formula_fields": types.BoolType, + "scd_type": types.StringType, + "sequence_by": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -2367,30 +2451,32 @@ func (newState *UpdateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateIn func (a UpdateInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Config": reflect.TypeOf(PipelineSpec{}), - "FullRefreshSelection": reflect.TypeOf(types.StringType), - "RefreshSelection": reflect.TypeOf(types.StringType), + "config": reflect.TypeOf(PipelineSpec{}), + "full_refresh_selection": reflect.TypeOf(types.StringType), + "refresh_selection": reflect.TypeOf(types.StringType), } } func (a UpdateInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Cause": types.StringType, - "ClusterId": types.StringType, - "Config": PipelineSpec{}.ToAttrType(ctx), - "CreationTime": types.Int64Type, - "FullRefresh": types.BoolType, - "FullRefreshSelection": basetypes.ListType{ + "cause": types.StringType, + "cluster_id": types.StringType, + "config": basetypes.ListType{ + ElemType: PipelineSpec{}.ToAttrType(ctx), + }, + "creation_time": types.Int64Type, + "full_refresh": types.BoolType, + "full_refresh_selection": basetypes.ListType{ ElemType: types.StringType, }, - "PipelineId": types.StringType, - "RefreshSelection": basetypes.ListType{ + "pipeline_id": types.StringType, + "refresh_selection": basetypes.ListType{ ElemType: types.StringType, }, - "State": types.StringType, - "UpdateId": types.StringType, - "ValidateOnly": types.BoolType, + "state": types.StringType, + "update_id": types.StringType, + "validate_only": types.BoolType, }, } } @@ -2416,9 +2502,9 @@ func (a UpdateStateInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateStateInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTime": types.StringType, - "State": types.StringType, - "UpdateId": types.StringType, + "creation_time": types.StringType, + "state": types.StringType, + "update_id": types.StringType, }, } } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index dbb72277f9..fa5af4b517 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -31,14 +31,16 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsC func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "StsRole": reflect.TypeOf(StsRole{}), + "sts_role": reflect.TypeOf(StsRole{}), } } func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StsRole": StsRole{}.ToAttrType(ctx), + "sts_role": basetypes.ListType{ + ElemType: StsRole{}.ToAttrType(ctx), + }, }, } } @@ -70,10 +72,10 @@ func (a AwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a AwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "KeyAlias": types.StringType, - "KeyArn": types.StringType, - "KeyRegion": types.StringType, - "ReuseKeyForClusterVolumes": types.BoolType, + "key_alias": types.StringType, + "key_arn": types.StringType, + "key_region": types.StringType, + "reuse_key_for_cluster_volumes": types.BoolType, }, } } @@ -98,8 +100,8 @@ func (a AzureWorkspaceInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a AzureWorkspaceInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ResourceGroup": types.StringType, - "SubscriptionId": types.StringType, + "resource_group": types.StringType, + "subscription_id": types.StringType, }, } } @@ -118,14 +120,16 @@ func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringRead(existingSt func (a CloudResourceContainer) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Gcp": reflect.TypeOf(CustomerFacingGcpCloudResourceContainer{}), + "gcp": reflect.TypeOf(CustomerFacingGcpCloudResourceContainer{}), } } func (a CloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Gcp": CustomerFacingGcpCloudResourceContainer{}.ToAttrType(ctx), + "gcp": basetypes.ListType{ + ElemType: CustomerFacingGcpCloudResourceContainer{}.ToAttrType(ctx), + }, }, } } @@ -156,9 +160,9 @@ func (a CreateAwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateAwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "KeyAlias": types.StringType, - "KeyArn": types.StringType, - "ReuseKeyForClusterVolumes": types.BoolType, + "key_alias": types.StringType, + "key_arn": types.StringType, + "reuse_key_for_cluster_volumes": types.BoolType, }, } } @@ -175,14 +179,16 @@ func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringRead(ex func (a CreateCredentialAwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "StsRole": reflect.TypeOf(CreateCredentialStsRole{}), + "sts_role": reflect.TypeOf(CreateCredentialStsRole{}), } } func (a CreateCredentialAwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StsRole": CreateCredentialStsRole{}.ToAttrType(ctx), + "sts_role": basetypes.ListType{ + ElemType: CreateCredentialStsRole{}.ToAttrType(ctx), + }, }, } } @@ -201,15 +207,17 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingS func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsCredentials": reflect.TypeOf(CreateCredentialAwsCredentials{}), + "aws_credentials": reflect.TypeOf(CreateCredentialAwsCredentials{}), } } func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsCredentials": CreateCredentialAwsCredentials{}.ToAttrType(ctx), - "CredentialsName": types.StringType, + "aws_credentials": basetypes.ListType{ + ElemType: CreateCredentialAwsCredentials{}.ToAttrType(ctx), + }, + "credentials_name": types.StringType, }, } } @@ -232,7 +240,7 @@ func (a CreateCredentialStsRole) GetComplexFieldTypes() map[string]reflect.Type func (a CreateCredentialStsRole) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RoleArn": types.StringType, + "role_arn": types.StringType, }, } } @@ -253,18 +261,22 @@ func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringRead(e func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsKeyInfo": reflect.TypeOf(CreateAwsKeyInfo{}), - "GcpKeyInfo": reflect.TypeOf(CreateGcpKeyInfo{}), - "UseCases": reflect.TypeOf(types.StringType), + "aws_key_info": reflect.TypeOf(CreateAwsKeyInfo{}), + "gcp_key_info": reflect.TypeOf(CreateGcpKeyInfo{}), + "use_cases": reflect.TypeOf(types.StringType), } } func (a CreateCustomerManagedKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsKeyInfo": CreateAwsKeyInfo{}.ToAttrType(ctx), - "GcpKeyInfo": CreateGcpKeyInfo{}.ToAttrType(ctx), - "UseCases": basetypes.ListType{ + "aws_key_info": basetypes.ListType{ + ElemType: CreateAwsKeyInfo{}.ToAttrType(ctx), + }, + "gcp_key_info": basetypes.ListType{ + ElemType: CreateGcpKeyInfo{}.ToAttrType(ctx), + }, + "use_cases": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -289,7 +301,7 @@ func (a CreateGcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateGcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "KmsKeyId": types.StringType, + "kms_key_id": types.StringType, }, } } @@ -324,26 +336,30 @@ func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringRead(existingStat func (a CreateNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "GcpNetworkInfo": reflect.TypeOf(GcpNetworkInfo{}), - "SecurityGroupIds": reflect.TypeOf(types.StringType), - "SubnetIds": reflect.TypeOf(types.StringType), - "VpcEndpoints": reflect.TypeOf(NetworkVpcEndpoints{}), + "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), + "security_group_ids": reflect.TypeOf(types.StringType), + "subnet_ids": reflect.TypeOf(types.StringType), + "vpc_endpoints": reflect.TypeOf(NetworkVpcEndpoints{}), } } func (a CreateNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GcpNetworkInfo": GcpNetworkInfo{}.ToAttrType(ctx), - "NetworkName": types.StringType, - "SecurityGroupIds": basetypes.ListType{ + "gcp_network_info": basetypes.ListType{ + ElemType: GcpNetworkInfo{}.ToAttrType(ctx), + }, + "network_name": types.StringType, + "security_group_ids": basetypes.ListType{ ElemType: types.StringType, }, - "SubnetIds": basetypes.ListType{ + "subnet_ids": basetypes.ListType{ ElemType: types.StringType, }, - "VpcEndpoints": NetworkVpcEndpoints{}.ToAttrType(ctx), - "VpcId": types.StringType, + "vpc_endpoints": basetypes.ListType{ + ElemType: NetworkVpcEndpoints{}.ToAttrType(ctx), + }, + "vpc_id": types.StringType, }, } } @@ -363,15 +379,17 @@ func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringRead func (a CreateStorageConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RootBucketInfo": reflect.TypeOf(RootBucketInfo{}), + "root_bucket_info": reflect.TypeOf(RootBucketInfo{}), } } func (a CreateStorageConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RootBucketInfo": RootBucketInfo{}.ToAttrType(ctx), - "StorageConfigurationName": types.StringType, + "root_bucket_info": basetypes.ListType{ + ElemType: RootBucketInfo{}.ToAttrType(ctx), + }, + "storage_configuration_name": types.StringType, }, } } @@ -396,17 +414,19 @@ func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existing func (a CreateVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "GcpVpcEndpointInfo": reflect.TypeOf(GcpVpcEndpointInfo{}), + "gcp_vpc_endpoint_info": reflect.TypeOf(GcpVpcEndpointInfo{}), } } func (a CreateVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsVpcEndpointId": types.StringType, - "GcpVpcEndpointInfo": GcpVpcEndpointInfo{}.ToAttrType(ctx), - "Region": types.StringType, - "VpcEndpointName": types.StringType, + "aws_vpc_endpoint_id": types.StringType, + "gcp_vpc_endpoint_info": basetypes.ListType{ + ElemType: GcpVpcEndpointInfo{}.ToAttrType(ctx), + }, + "region": types.StringType, + "vpc_endpoint_name": types.StringType, }, } } @@ -532,35 +552,41 @@ func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingSt func (a CreateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CloudResourceContainer": reflect.TypeOf(CloudResourceContainer{}), - "CustomTags": reflect.TypeOf(types.StringType), - "GcpManagedNetworkConfig": reflect.TypeOf(GcpManagedNetworkConfig{}), - "GkeConfig": reflect.TypeOf(GkeConfig{}), + "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), + "custom_tags": reflect.TypeOf(types.StringType), + "gcp_managed_network_config": reflect.TypeOf(GcpManagedNetworkConfig{}), + "gke_config": reflect.TypeOf(GkeConfig{}), } } func (a CreateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsRegion": types.StringType, - "Cloud": types.StringType, - "CloudResourceContainer": CloudResourceContainer{}.ToAttrType(ctx), - "CredentialsId": types.StringType, - "CustomTags": basetypes.MapType{ + "aws_region": types.StringType, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ + ElemType: CloudResourceContainer{}.ToAttrType(ctx), + }, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DeploymentName": types.StringType, - "GcpManagedNetworkConfig": GcpManagedNetworkConfig{}.ToAttrType(ctx), - "GkeConfig": GkeConfig{}.ToAttrType(ctx), - "IsNoPublicIpEnabled": types.BoolType, - "Location": types.StringType, - "ManagedServicesCustomerManagedKeyId": types.StringType, - "NetworkId": types.StringType, - "PricingTier": types.StringType, - "PrivateAccessSettingsId": types.StringType, - "StorageConfigurationId": types.StringType, - "StorageCustomerManagedKeyId": types.StringType, - "WorkspaceName": types.StringType, + "deployment_name": types.StringType, + "gcp_managed_network_config": basetypes.ListType{ + ElemType: GcpManagedNetworkConfig{}.ToAttrType(ctx), + }, + "gke_config": basetypes.ListType{ + ElemType: GkeConfig{}.ToAttrType(ctx), + }, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, + "managed_services_customer_managed_key_id": types.StringType, + "network_id": types.StringType, + "pricing_tier": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_name": types.StringType, }, } } @@ -586,18 +612,20 @@ func (newState *Credential) SyncEffectiveFieldsDuringRead(existingState Credenti func (a Credential) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsCredentials": reflect.TypeOf(AwsCredentials{}), + "aws_credentials": reflect.TypeOf(AwsCredentials{}), } } func (a Credential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AwsCredentials": AwsCredentials{}.ToAttrType(ctx), - "CreationTime": types.Int64Type, - "CredentialsId": types.StringType, - "CredentialsName": types.StringType, + "account_id": types.StringType, + "aws_credentials": basetypes.ListType{ + ElemType: AwsCredentials{}.ToAttrType(ctx), + }, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "credentials_name": types.StringType, }, } } @@ -622,7 +650,7 @@ func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes() map[stri func (a CustomerFacingGcpCloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ProjectId": types.StringType, + "project_id": types.StringType, }, } } @@ -650,21 +678,25 @@ func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringRead(existingState func (a CustomerManagedKey) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsKeyInfo": reflect.TypeOf(AwsKeyInfo{}), - "GcpKeyInfo": reflect.TypeOf(GcpKeyInfo{}), - "UseCases": reflect.TypeOf(types.StringType), + "aws_key_info": reflect.TypeOf(AwsKeyInfo{}), + "gcp_key_info": reflect.TypeOf(GcpKeyInfo{}), + "use_cases": reflect.TypeOf(types.StringType), } } func (a CustomerManagedKey) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AwsKeyInfo": AwsKeyInfo{}.ToAttrType(ctx), - "CreationTime": types.Int64Type, - "CustomerManagedKeyId": types.StringType, - "GcpKeyInfo": GcpKeyInfo{}.ToAttrType(ctx), - "UseCases": basetypes.ListType{ + "account_id": types.StringType, + "aws_key_info": basetypes.ListType{ + ElemType: AwsKeyInfo{}.ToAttrType(ctx), + }, + "creation_time": types.Int64Type, + "customer_managed_key_id": types.StringType, + "gcp_key_info": basetypes.ListType{ + ElemType: GcpKeyInfo{}.ToAttrType(ctx), + }, + "use_cases": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -690,7 +722,7 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialsId": types.StringType, + "credentials_id": types.StringType, }, } } @@ -714,7 +746,7 @@ func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a DeleteEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CustomerManagedKeyId": types.StringType, + "customer_managed_key_id": types.StringType, }, } } @@ -738,7 +770,7 @@ func (a DeleteNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkId": types.StringType, + "network_id": types.StringType, }, } } @@ -762,7 +794,7 @@ func (a DeletePrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeletePrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrivateAccessSettingsId": types.StringType, + "private_access_settings_id": types.StringType, }, } } @@ -805,7 +837,7 @@ func (a DeleteStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StorageConfigurationId": types.StringType, + "storage_configuration_id": types.StringType, }, } } @@ -829,7 +861,7 @@ func (a DeleteVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "VpcEndpointId": types.StringType, + "vpc_endpoint_id": types.StringType, }, } } @@ -853,7 +885,7 @@ func (a DeleteWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceId": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -880,9 +912,9 @@ func (a ExternalCustomerInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ExternalCustomerInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AuthoritativeUserEmail": types.StringType, - "AuthoritativeUserFullName": types.StringType, - "CustomerName": types.StringType, + "authoritative_user_email": types.StringType, + "authoritative_user_full_name": types.StringType, + "customer_name": types.StringType, }, } } @@ -905,7 +937,7 @@ func (a GcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a GcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "KmsKeyId": types.StringType, + "kms_key_id": types.StringType, }, } } @@ -958,9 +990,9 @@ func (a GcpManagedNetworkConfig) GetComplexFieldTypes() map[string]reflect.Type func (a GcpManagedNetworkConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GkeClusterPodIpRange": types.StringType, - "GkeClusterServiceIpRange": types.StringType, - "SubnetCidr": types.StringType, + "gke_cluster_pod_ip_range": types.StringType, + "gke_cluster_service_ip_range": types.StringType, + "subnet_cidr": types.StringType, }, } } @@ -1001,12 +1033,12 @@ func (a GcpNetworkInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a GcpNetworkInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkProjectId": types.StringType, - "PodIpRangeName": types.StringType, - "ServiceIpRangeName": types.StringType, - "SubnetId": types.StringType, - "SubnetRegion": types.StringType, - "VpcId": types.StringType, + "network_project_id": types.StringType, + "pod_ip_range_name": types.StringType, + "service_ip_range_name": types.StringType, + "subnet_id": types.StringType, + "subnet_region": types.StringType, + "vpc_id": types.StringType, }, } } @@ -1040,11 +1072,11 @@ func (a GcpVpcEndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a GcpVpcEndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointRegion": types.StringType, - "ProjectId": types.StringType, - "PscConnectionId": types.StringType, - "PscEndpointName": types.StringType, - "ServiceAttachmentId": types.StringType, + "endpoint_region": types.StringType, + "project_id": types.StringType, + "psc_connection_id": types.StringType, + "psc_endpoint_name": types.StringType, + "service_attachment_id": types.StringType, }, } } @@ -1068,7 +1100,7 @@ func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialsId": types.StringType, + "credentials_id": types.StringType, }, } } @@ -1092,7 +1124,7 @@ func (a GetEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CustomerManagedKeyId": types.StringType, + "customer_managed_key_id": types.StringType, }, } } @@ -1116,7 +1148,7 @@ func (a GetNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkId": types.StringType, + "network_id": types.StringType, }, } } @@ -1140,7 +1172,7 @@ func (a GetPrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetPrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrivateAccessSettingsId": types.StringType, + "private_access_settings_id": types.StringType, }, } } @@ -1164,7 +1196,7 @@ func (a GetStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StorageConfigurationId": types.StringType, + "storage_configuration_id": types.StringType, }, } } @@ -1188,7 +1220,7 @@ func (a GetVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "VpcEndpointId": types.StringType, + "vpc_endpoint_id": types.StringType, }, } } @@ -1212,7 +1244,7 @@ func (a GetWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceId": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -1248,8 +1280,8 @@ func (a GkeConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a GkeConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConnectivityType": types.StringType, - "MasterIpRange": types.StringType, + "connectivity_type": types.StringType, + "master_ip_range": types.StringType, }, } } @@ -1298,39 +1330,43 @@ func (newState *Network) SyncEffectiveFieldsDuringRead(existingState Network) { func (a Network) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ErrorMessages": reflect.TypeOf(NetworkHealth{}), - "GcpNetworkInfo": reflect.TypeOf(GcpNetworkInfo{}), - "SecurityGroupIds": reflect.TypeOf(types.StringType), - "SubnetIds": reflect.TypeOf(types.StringType), - "VpcEndpoints": reflect.TypeOf(NetworkVpcEndpoints{}), - "WarningMessages": reflect.TypeOf(NetworkWarning{}), + "error_messages": reflect.TypeOf(NetworkHealth{}), + "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), + "security_group_ids": reflect.TypeOf(types.StringType), + "subnet_ids": reflect.TypeOf(types.StringType), + "vpc_endpoints": reflect.TypeOf(NetworkVpcEndpoints{}), + "warning_messages": reflect.TypeOf(NetworkWarning{}), } } func (a Network) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "CreationTime": types.Int64Type, - "ErrorMessages": basetypes.ListType{ + "account_id": types.StringType, + "creation_time": types.Int64Type, + "error_messages": basetypes.ListType{ ElemType: NetworkHealth{}.ToAttrType(ctx), }, - "GcpNetworkInfo": GcpNetworkInfo{}.ToAttrType(ctx), - "NetworkId": types.StringType, - "NetworkName": types.StringType, - "SecurityGroupIds": basetypes.ListType{ + "gcp_network_info": basetypes.ListType{ + ElemType: GcpNetworkInfo{}.ToAttrType(ctx), + }, + "network_id": types.StringType, + "network_name": types.StringType, + "security_group_ids": basetypes.ListType{ ElemType: types.StringType, }, - "SubnetIds": basetypes.ListType{ + "subnet_ids": basetypes.ListType{ ElemType: types.StringType, }, - "VpcEndpoints": NetworkVpcEndpoints{}.ToAttrType(ctx), - "VpcId": types.StringType, - "VpcStatus": types.StringType, - "WarningMessages": basetypes.ListType{ + "vpc_endpoints": basetypes.ListType{ + ElemType: NetworkVpcEndpoints{}.ToAttrType(ctx), + }, + "vpc_id": types.StringType, + "vpc_status": types.StringType, + "warning_messages": basetypes.ListType{ ElemType: NetworkWarning{}.ToAttrType(ctx), }, - "WorkspaceId": types.Int64Type, + "workspace_id": types.Int64Type, }, } } @@ -1356,8 +1392,8 @@ func (a NetworkHealth) GetComplexFieldTypes() map[string]reflect.Type { func (a NetworkHealth) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ErrorMessage": types.StringType, - "ErrorType": types.StringType, + "error_message": types.StringType, + "error_type": types.StringType, }, } } @@ -1383,18 +1419,18 @@ func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringRead(existingState func (a NetworkVpcEndpoints) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataplaneRelay": reflect.TypeOf(types.StringType), - "RestApi": reflect.TypeOf(types.StringType), + "dataplane_relay": reflect.TypeOf(types.StringType), + "rest_api": reflect.TypeOf(types.StringType), } } func (a NetworkVpcEndpoints) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataplaneRelay": basetypes.ListType{ + "dataplane_relay": basetypes.ListType{ ElemType: types.StringType, }, - "RestApi": basetypes.ListType{ + "rest_api": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1422,8 +1458,8 @@ func (a NetworkWarning) GetComplexFieldTypes() map[string]reflect.Type { func (a NetworkWarning) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WarningMessage": types.StringType, - "WarningType": types.StringType, + "warning_message": types.StringType, + "warning_type": types.StringType, }, } } @@ -1463,22 +1499,22 @@ func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringRead(existingSta func (a PrivateAccessSettings) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllowedVpcEndpointIds": reflect.TypeOf(types.StringType), + "allowed_vpc_endpoint_ids": reflect.TypeOf(types.StringType), } } func (a PrivateAccessSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AllowedVpcEndpointIds": basetypes.ListType{ + "account_id": types.StringType, + "allowed_vpc_endpoint_ids": basetypes.ListType{ ElemType: types.StringType, }, - "PrivateAccessLevel": types.StringType, - "PrivateAccessSettingsId": types.StringType, - "PrivateAccessSettingsName": types.StringType, - "PublicAccessEnabled": types.BoolType, - "Region": types.StringType, + "private_access_level": types.StringType, + "private_access_settings_id": types.StringType, + "private_access_settings_name": types.StringType, + "public_access_enabled": types.BoolType, + "region": types.StringType, }, } } @@ -1521,7 +1557,7 @@ func (a RootBucketInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a RootBucketInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BucketName": types.StringType, + "bucket_name": types.StringType, }, } } @@ -1547,18 +1583,20 @@ func (newState *StorageConfiguration) SyncEffectiveFieldsDuringRead(existingStat func (a StorageConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RootBucketInfo": reflect.TypeOf(RootBucketInfo{}), + "root_bucket_info": reflect.TypeOf(RootBucketInfo{}), } } func (a StorageConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "CreationTime": types.Int64Type, - "RootBucketInfo": RootBucketInfo{}.ToAttrType(ctx), - "StorageConfigurationId": types.StringType, - "StorageConfigurationName": types.StringType, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "root_bucket_info": basetypes.ListType{ + ElemType: RootBucketInfo{}.ToAttrType(ctx), + }, + "storage_configuration_id": types.StringType, + "storage_configuration_name": types.StringType, }, } } @@ -1584,8 +1622,8 @@ func (a StsRole) GetComplexFieldTypes() map[string]reflect.Type { func (a StsRole) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExternalId": types.StringType, - "RoleArn": types.StringType, + "external_id": types.StringType, + "role_arn": types.StringType, }, } } @@ -1652,25 +1690,25 @@ func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomTags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.StringType), } } func (a UpdateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsRegion": types.StringType, - "CredentialsId": types.StringType, - "CustomTags": basetypes.MapType{ + "aws_region": types.StringType, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "ManagedServicesCustomerManagedKeyId": types.StringType, - "NetworkConnectivityConfigId": types.StringType, - "NetworkId": types.StringType, - "PrivateAccessSettingsId": types.StringType, - "StorageConfigurationId": types.StringType, - "StorageCustomerManagedKeyId": types.StringType, - "WorkspaceId": types.Int64Type, + "managed_services_customer_managed_key_id": types.StringType, + "network_connectivity_config_id": types.StringType, + "network_id": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -1721,21 +1759,21 @@ func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringRea func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllowedVpcEndpointIds": reflect.TypeOf(types.StringType), + "allowed_vpc_endpoint_ids": reflect.TypeOf(types.StringType), } } func (a UpsertPrivateAccessSettingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowedVpcEndpointIds": basetypes.ListType{ + "allowed_vpc_endpoint_ids": basetypes.ListType{ ElemType: types.StringType, }, - "PrivateAccessLevel": types.StringType, - "PrivateAccessSettingsId": types.StringType, - "PrivateAccessSettingsName": types.StringType, - "PublicAccessEnabled": types.BoolType, - "Region": types.StringType, + "private_access_level": types.StringType, + "private_access_settings_id": types.StringType, + "private_access_settings_name": types.StringType, + "public_access_enabled": types.BoolType, + "region": types.StringType, }, } } @@ -1786,23 +1824,25 @@ func (newState *VpcEndpoint) SyncEffectiveFieldsDuringRead(existingState VpcEndp func (a VpcEndpoint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "GcpVpcEndpointInfo": reflect.TypeOf(GcpVpcEndpointInfo{}), + "gcp_vpc_endpoint_info": reflect.TypeOf(GcpVpcEndpointInfo{}), } } func (a VpcEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AwsAccountId": types.StringType, - "AwsEndpointServiceId": types.StringType, - "AwsVpcEndpointId": types.StringType, - "GcpVpcEndpointInfo": GcpVpcEndpointInfo{}.ToAttrType(ctx), - "Region": types.StringType, - "State": types.StringType, - "UseCase": types.StringType, - "VpcEndpointId": types.StringType, - "VpcEndpointName": types.StringType, + "account_id": types.StringType, + "aws_account_id": types.StringType, + "aws_endpoint_service_id": types.StringType, + "aws_vpc_endpoint_id": types.StringType, + "gcp_vpc_endpoint_info": basetypes.ListType{ + ElemType: GcpVpcEndpointInfo{}.ToAttrType(ctx), + }, + "region": types.StringType, + "state": types.StringType, + "use_case": types.StringType, + "vpc_endpoint_id": types.StringType, + "vpc_endpoint_name": types.StringType, }, } } @@ -1915,44 +1955,54 @@ func (newState *Workspace) SyncEffectiveFieldsDuringRead(existingState Workspace func (a Workspace) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AzureWorkspaceInfo": reflect.TypeOf(AzureWorkspaceInfo{}), - "CloudResourceContainer": reflect.TypeOf(CloudResourceContainer{}), - "CustomTags": reflect.TypeOf(types.StringType), - "ExternalCustomerInfo": reflect.TypeOf(ExternalCustomerInfo{}), - "GcpManagedNetworkConfig": reflect.TypeOf(GcpManagedNetworkConfig{}), - "GkeConfig": reflect.TypeOf(GkeConfig{}), + "azure_workspace_info": reflect.TypeOf(AzureWorkspaceInfo{}), + "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), + "custom_tags": reflect.TypeOf(types.StringType), + "external_customer_info": reflect.TypeOf(ExternalCustomerInfo{}), + "gcp_managed_network_config": reflect.TypeOf(GcpManagedNetworkConfig{}), + "gke_config": reflect.TypeOf(GkeConfig{}), } } func (a Workspace) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "AwsRegion": types.StringType, - "AzureWorkspaceInfo": AzureWorkspaceInfo{}.ToAttrType(ctx), - "Cloud": types.StringType, - "CloudResourceContainer": CloudResourceContainer{}.ToAttrType(ctx), - "CreationTime": types.Int64Type, - "CredentialsId": types.StringType, - "CustomTags": basetypes.MapType{ + "account_id": types.StringType, + "aws_region": types.StringType, + "azure_workspace_info": basetypes.ListType{ + ElemType: AzureWorkspaceInfo{}.ToAttrType(ctx), + }, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ + ElemType: CloudResourceContainer{}.ToAttrType(ctx), + }, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "DeploymentName": types.StringType, - "ExternalCustomerInfo": ExternalCustomerInfo{}.ToAttrType(ctx), - "GcpManagedNetworkConfig": GcpManagedNetworkConfig{}.ToAttrType(ctx), - "GkeConfig": GkeConfig{}.ToAttrType(ctx), - "IsNoPublicIpEnabled": types.BoolType, - "Location": types.StringType, - "ManagedServicesCustomerManagedKeyId": types.StringType, - "NetworkId": types.StringType, - "PricingTier": types.StringType, - "PrivateAccessSettingsId": types.StringType, - "StorageConfigurationId": types.StringType, - "StorageCustomerManagedKeyId": types.StringType, - "WorkspaceId": types.Int64Type, - "WorkspaceName": types.StringType, - "WorkspaceStatus": types.StringType, - "WorkspaceStatusMessage": types.StringType, + "deployment_name": types.StringType, + "external_customer_info": basetypes.ListType{ + ElemType: ExternalCustomerInfo{}.ToAttrType(ctx), + }, + "gcp_managed_network_config": basetypes.ListType{ + ElemType: GcpManagedNetworkConfig{}.ToAttrType(ctx), + }, + "gke_config": basetypes.ListType{ + ElemType: GkeConfig{}.ToAttrType(ctx), + }, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, + "managed_services_customer_managed_key_id": types.StringType, + "network_id": types.StringType, + "pricing_tier": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_id": types.Int64Type, + "workspace_name": types.StringType, + "workspace_status": types.StringType, + "workspace_status_message": types.StringType, }, } } diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 53997e207c..2745943049 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -48,8 +48,8 @@ func (a Ai21LabsConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a Ai21LabsConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Ai21labsApiKey": types.StringType, - "Ai21labsApiKeyPlaintext": types.StringType, + "ai21labs_api_key": types.StringType, + "ai21labs_api_key_plaintext": types.StringType, }, } } @@ -78,22 +78,28 @@ func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringRead(existingState AiG func (a AiGatewayConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Guardrails": reflect.TypeOf(AiGatewayGuardrails{}), - "InferenceTableConfig": reflect.TypeOf(AiGatewayInferenceTableConfig{}), - "RateLimits": reflect.TypeOf(AiGatewayRateLimit{}), - "UsageTrackingConfig": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), + "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), + "inference_table_config": reflect.TypeOf(AiGatewayInferenceTableConfig{}), + "rate_limits": reflect.TypeOf(AiGatewayRateLimit{}), + "usage_tracking_config": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), } } func (a AiGatewayConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Guardrails": AiGatewayGuardrails{}.ToAttrType(ctx), - "InferenceTableConfig": AiGatewayInferenceTableConfig{}.ToAttrType(ctx), - "RateLimits": basetypes.ListType{ + "guardrails": basetypes.ListType{ + ElemType: AiGatewayGuardrails{}.ToAttrType(ctx), + }, + "inference_table_config": basetypes.ListType{ + ElemType: AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + }, + "rate_limits": basetypes.ListType{ ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), }, - "UsageTrackingConfig": AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + "usage_tracking_config": basetypes.ListType{ + ElemType: AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + }, }, } } @@ -119,21 +125,23 @@ func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringRead(exis func (a AiGatewayGuardrailParameters) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InvalidKeywords": reflect.TypeOf(types.StringType), - "Pii": reflect.TypeOf(AiGatewayGuardrailPiiBehavior{}), - "ValidTopics": reflect.TypeOf(types.StringType), + "invalid_keywords": reflect.TypeOf(types.StringType), + "pii": reflect.TypeOf(AiGatewayGuardrailPiiBehavior{}), + "valid_topics": reflect.TypeOf(types.StringType), } } func (a AiGatewayGuardrailParameters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "InvalidKeywords": basetypes.ListType{ + "invalid_keywords": basetypes.ListType{ ElemType: types.StringType, }, - "Pii": AiGatewayGuardrailPiiBehavior{}.ToAttrType(ctx), - "Safety": types.BoolType, - "ValidTopics": basetypes.ListType{ + "pii": basetypes.ListType{ + ElemType: AiGatewayGuardrailPiiBehavior{}.ToAttrType(ctx), + }, + "safety": types.BoolType, + "valid_topics": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -163,7 +171,7 @@ func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes() map[string]reflect func (a AiGatewayGuardrailPiiBehavior) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Behavior": types.StringType, + "behavior": types.StringType, }, } } @@ -183,16 +191,20 @@ func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringRead(existingState func (a AiGatewayGuardrails) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Input": reflect.TypeOf(AiGatewayGuardrailParameters{}), - "Output": reflect.TypeOf(AiGatewayGuardrailParameters{}), + "input": reflect.TypeOf(AiGatewayGuardrailParameters{}), + "output": reflect.TypeOf(AiGatewayGuardrailParameters{}), } } func (a AiGatewayGuardrails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Input": AiGatewayGuardrailParameters{}.ToAttrType(ctx), - "Output": AiGatewayGuardrailParameters{}.ToAttrType(ctx), + "input": basetypes.ListType{ + ElemType: AiGatewayGuardrailParameters{}.ToAttrType(ctx), + }, + "output": basetypes.ListType{ + ElemType: AiGatewayGuardrailParameters{}.ToAttrType(ctx), + }, }, } } @@ -226,10 +238,10 @@ func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes() map[string]reflect func (a AiGatewayInferenceTableConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Enabled": types.BoolType, - "SchemaName": types.StringType, - "TableNamePrefix": types.StringType, + "catalog_name": types.StringType, + "enabled": types.BoolType, + "schema_name": types.StringType, + "table_name_prefix": types.StringType, }, } } @@ -259,9 +271,9 @@ func (a AiGatewayRateLimit) GetComplexFieldTypes() map[string]reflect.Type { func (a AiGatewayRateLimit) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Calls": types.Int64Type, - "Key": types.StringType, - "RenewalPeriod": types.StringType, + "calls": types.Int64Type, + "key": types.StringType, + "renewal_period": types.StringType, }, } } @@ -284,7 +296,7 @@ func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes() map[string]reflect. func (a AiGatewayUsageTrackingConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, + "enabled": types.BoolType, }, } } @@ -336,12 +348,12 @@ func (a AmazonBedrockConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a AmazonBedrockConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsAccessKeyId": types.StringType, - "AwsAccessKeyIdPlaintext": types.StringType, - "AwsRegion": types.StringType, - "AwsSecretAccessKey": types.StringType, - "AwsSecretAccessKeyPlaintext": types.StringType, - "BedrockProvider": types.StringType, + "aws_access_key_id": types.StringType, + "aws_access_key_id_plaintext": types.StringType, + "aws_region": types.StringType, + "aws_secret_access_key": types.StringType, + "aws_secret_access_key_plaintext": types.StringType, + "bedrock_provider": types.StringType, }, } } @@ -372,8 +384,8 @@ func (a AnthropicConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a AnthropicConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AnthropicApiKey": types.StringType, - "AnthropicApiKeyPlaintext": types.StringType, + "anthropic_api_key": types.StringType, + "anthropic_api_key_plaintext": types.StringType, }, } } @@ -405,10 +417,10 @@ func (a AutoCaptureConfigInput) GetComplexFieldTypes() map[string]reflect.Type { func (a AutoCaptureConfigInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Enabled": types.BoolType, - "SchemaName": types.StringType, - "TableNamePrefix": types.StringType, + "catalog_name": types.StringType, + "enabled": types.BoolType, + "schema_name": types.StringType, + "table_name_prefix": types.StringType, }, } } @@ -434,18 +446,20 @@ func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringRead(existingS func (a AutoCaptureConfigOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "State": reflect.TypeOf(AutoCaptureState{}), + "state": reflect.TypeOf(AutoCaptureState{}), } } func (a AutoCaptureConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CatalogName": types.StringType, - "Enabled": types.BoolType, - "SchemaName": types.StringType, - "State": AutoCaptureState{}.ToAttrType(ctx), - "TableNamePrefix": types.StringType, + "catalog_name": types.StringType, + "enabled": types.BoolType, + "schema_name": types.StringType, + "state": basetypes.ListType{ + ElemType: AutoCaptureState{}.ToAttrType(ctx), + }, + "table_name_prefix": types.StringType, }, } } @@ -462,14 +476,16 @@ func (newState *AutoCaptureState) SyncEffectiveFieldsDuringRead(existingState Au func (a AutoCaptureState) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PayloadTable": reflect.TypeOf(PayloadTable{}), + "payload_table": reflect.TypeOf(PayloadTable{}), } } func (a AutoCaptureState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PayloadTable": PayloadTable{}.ToAttrType(ctx), + "payload_table": basetypes.ListType{ + ElemType: PayloadTable{}.ToAttrType(ctx), + }, }, } } @@ -497,8 +513,8 @@ func (a BuildLogsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a BuildLogsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "ServedModelName": types.StringType, + "name": types.StringType, + "served_model_name": types.StringType, }, } } @@ -521,7 +537,7 @@ func (a BuildLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a BuildLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Logs": types.StringType, + "logs": types.StringType, }, } } @@ -546,8 +562,8 @@ func (a ChatMessage) GetComplexFieldTypes() map[string]reflect.Type { func (a ChatMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "Role": types.StringType, + "content": types.StringType, + "role": types.StringType, }, } } @@ -581,9 +597,9 @@ func (a CohereConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a CohereConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CohereApiBase": types.StringType, - "CohereApiKey": types.StringType, - "CohereApiKeyPlaintext": types.StringType, + "cohere_api_base": types.StringType, + "cohere_api_key": types.StringType, + "cohere_api_key_plaintext": types.StringType, }, } } @@ -616,24 +632,28 @@ func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringRead(existingSta func (a CreateServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AiGateway": reflect.TypeOf(AiGatewayConfig{}), - "Config": reflect.TypeOf(EndpointCoreConfigInput{}), - "RateLimits": reflect.TypeOf(RateLimit{}), - "Tags": reflect.TypeOf(EndpointTag{}), + "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), + "config": reflect.TypeOf(EndpointCoreConfigInput{}), + "rate_limits": reflect.TypeOf(RateLimit{}), + "tags": reflect.TypeOf(EndpointTag{}), } } func (a CreateServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AiGateway": AiGatewayConfig{}.ToAttrType(ctx), - "Config": EndpointCoreConfigInput{}.ToAttrType(ctx), - "Name": types.StringType, - "RateLimits": basetypes.ListType{ + "ai_gateway": basetypes.ListType{ + ElemType: AiGatewayConfig{}.ToAttrType(ctx), + }, + "config": basetypes.ListType{ + ElemType: EndpointCoreConfigInput{}.ToAttrType(ctx), + }, + "name": types.StringType, + "rate_limits": basetypes.ListType{ ElemType: RateLimit{}.ToAttrType(ctx), }, - "RouteOptimized": types.BoolType, - "Tags": basetypes.ListType{ + "route_optimized": types.BoolType, + "tags": basetypes.ListType{ ElemType: EndpointTag{}.ToAttrType(ctx), }, }, @@ -673,9 +693,9 @@ func (a DatabricksModelServingConfig) GetComplexFieldTypes() map[string]reflect. func (a DatabricksModelServingConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DatabricksApiToken": types.StringType, - "DatabricksApiTokenPlaintext": types.StringType, - "DatabricksWorkspaceUrl": types.StringType, + "databricks_api_token": types.StringType, + "databricks_api_token_plaintext": types.StringType, + "databricks_workspace_url": types.StringType, }, } } @@ -696,22 +716,22 @@ func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringRead(existingState func (a DataframeSplitInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Columns": reflect.TypeOf(struct{}{}), - "Data": reflect.TypeOf(struct{}{}), - "Index": reflect.TypeOf(types.Int64Type), + "columns": reflect.TypeOf(struct{}{}), + "data": reflect.TypeOf(struct{}{}), + "index": reflect.TypeOf(types.Int64Type), } } func (a DataframeSplitInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Columns": basetypes.ListType{ + "columns": basetypes.ListType{ ElemType: types.ObjectType{}, }, - "Data": basetypes.ListType{ + "data": basetypes.ListType{ ElemType: types.ObjectType{}, }, - "Index": basetypes.ListType{ + "index": basetypes.ListType{ ElemType: types.Int64Type, }, }, @@ -756,7 +776,7 @@ func (a DeleteServingEndpointRequest) GetComplexFieldTypes() map[string]reflect. func (a DeleteServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -777,18 +797,18 @@ func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringR func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Embedding": reflect.TypeOf(types.Float64Type), + "embedding": reflect.TypeOf(types.Float64Type), } } func (a EmbeddingsV1ResponseEmbeddingElement) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Embedding": basetypes.ListType{ + "embedding": basetypes.ListType{ ElemType: types.Float64Type, }, - "Index": types.Int64Type, - "Object": types.StringType, + "index": types.Int64Type, + "object": types.StringType, }, } } @@ -818,25 +838,29 @@ func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringRead(existingS func (a EndpointCoreConfigInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AutoCaptureConfig": reflect.TypeOf(AutoCaptureConfigInput{}), - "ServedEntities": reflect.TypeOf(ServedEntityInput{}), - "ServedModels": reflect.TypeOf(ServedModelInput{}), - "TrafficConfig": reflect.TypeOf(TrafficConfig{}), + "auto_capture_config": reflect.TypeOf(AutoCaptureConfigInput{}), + "served_entities": reflect.TypeOf(ServedEntityInput{}), + "served_models": reflect.TypeOf(ServedModelInput{}), + "traffic_config": reflect.TypeOf(TrafficConfig{}), } } func (a EndpointCoreConfigInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoCaptureConfig": AutoCaptureConfigInput{}.ToAttrType(ctx), - "Name": types.StringType, - "ServedEntities": basetypes.ListType{ + "auto_capture_config": basetypes.ListType{ + ElemType: AutoCaptureConfigInput{}.ToAttrType(ctx), + }, + "name": types.StringType, + "served_entities": basetypes.ListType{ ElemType: ServedEntityInput{}.ToAttrType(ctx), }, - "ServedModels": basetypes.ListType{ + "served_models": basetypes.ListType{ ElemType: ServedModelInput{}.ToAttrType(ctx), }, - "TrafficConfig": TrafficConfig{}.ToAttrType(ctx), + "traffic_config": basetypes.ListType{ + ElemType: TrafficConfig{}.ToAttrType(ctx), + }, }, } } @@ -864,25 +888,29 @@ func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringRead(existing func (a EndpointCoreConfigOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AutoCaptureConfig": reflect.TypeOf(AutoCaptureConfigOutput{}), - "ServedEntities": reflect.TypeOf(ServedEntityOutput{}), - "ServedModels": reflect.TypeOf(ServedModelOutput{}), - "TrafficConfig": reflect.TypeOf(TrafficConfig{}), + "auto_capture_config": reflect.TypeOf(AutoCaptureConfigOutput{}), + "served_entities": reflect.TypeOf(ServedEntityOutput{}), + "served_models": reflect.TypeOf(ServedModelOutput{}), + "traffic_config": reflect.TypeOf(TrafficConfig{}), } } func (a EndpointCoreConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoCaptureConfig": AutoCaptureConfigOutput{}.ToAttrType(ctx), - "ConfigVersion": types.Int64Type, - "ServedEntities": basetypes.ListType{ + "auto_capture_config": basetypes.ListType{ + ElemType: AutoCaptureConfigOutput{}.ToAttrType(ctx), + }, + "config_version": types.Int64Type, + "served_entities": basetypes.ListType{ ElemType: ServedEntityOutput{}.ToAttrType(ctx), }, - "ServedModels": basetypes.ListType{ + "served_models": basetypes.ListType{ ElemType: ServedModelOutput{}.ToAttrType(ctx), }, - "TrafficConfig": TrafficConfig{}.ToAttrType(ctx), + "traffic_config": basetypes.ListType{ + ElemType: TrafficConfig{}.ToAttrType(ctx), + }, }, } } @@ -903,18 +931,18 @@ func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringRead(existin func (a EndpointCoreConfigSummary) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ServedEntities": reflect.TypeOf(ServedEntitySpec{}), - "ServedModels": reflect.TypeOf(ServedModelSpec{}), + "served_entities": reflect.TypeOf(ServedEntitySpec{}), + "served_models": reflect.TypeOf(ServedModelSpec{}), } } func (a EndpointCoreConfigSummary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ServedEntities": basetypes.ListType{ + "served_entities": basetypes.ListType{ ElemType: ServedEntitySpec{}.ToAttrType(ctx), }, - "ServedModels": basetypes.ListType{ + "served_models": basetypes.ListType{ ElemType: ServedModelSpec{}.ToAttrType(ctx), }, }, @@ -948,26 +976,30 @@ func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringRead(existingSta func (a EndpointPendingConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AutoCaptureConfig": reflect.TypeOf(AutoCaptureConfigOutput{}), - "ServedEntities": reflect.TypeOf(ServedEntityOutput{}), - "ServedModels": reflect.TypeOf(ServedModelOutput{}), - "TrafficConfig": reflect.TypeOf(TrafficConfig{}), + "auto_capture_config": reflect.TypeOf(AutoCaptureConfigOutput{}), + "served_entities": reflect.TypeOf(ServedEntityOutput{}), + "served_models": reflect.TypeOf(ServedModelOutput{}), + "traffic_config": reflect.TypeOf(TrafficConfig{}), } } func (a EndpointPendingConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoCaptureConfig": AutoCaptureConfigOutput{}.ToAttrType(ctx), - "ConfigVersion": types.Int64Type, - "ServedEntities": basetypes.ListType{ + "auto_capture_config": basetypes.ListType{ + ElemType: AutoCaptureConfigOutput{}.ToAttrType(ctx), + }, + "config_version": types.Int64Type, + "served_entities": basetypes.ListType{ ElemType: ServedEntityOutput{}.ToAttrType(ctx), }, - "ServedModels": basetypes.ListType{ + "served_models": basetypes.ListType{ ElemType: ServedModelOutput{}.ToAttrType(ctx), }, - "StartTime": types.Int64Type, - "TrafficConfig": TrafficConfig{}.ToAttrType(ctx), + "start_time": types.Int64Type, + "traffic_config": basetypes.ListType{ + ElemType: TrafficConfig{}.ToAttrType(ctx), + }, }, } } @@ -999,8 +1031,8 @@ func (a EndpointState) GetComplexFieldTypes() map[string]reflect.Type { func (a EndpointState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConfigUpdate": types.StringType, - "Ready": types.StringType, + "config_update": types.StringType, + "ready": types.StringType, }, } } @@ -1025,8 +1057,8 @@ func (a EndpointTag) GetComplexFieldTypes() map[string]reflect.Type { func (a EndpointTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -1051,7 +1083,7 @@ func (a ExportMetricsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ExportMetricsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1073,7 +1105,7 @@ func (a ExportMetricsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a ExportMetricsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Contents": types.ObjectType{}, + "contents": types.ObjectType{}, }, } } @@ -1116,31 +1148,47 @@ func (newState *ExternalModel) SyncEffectiveFieldsDuringRead(existingState Exter func (a ExternalModel) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Ai21labsConfig": reflect.TypeOf(Ai21LabsConfig{}), - "AmazonBedrockConfig": reflect.TypeOf(AmazonBedrockConfig{}), - "AnthropicConfig": reflect.TypeOf(AnthropicConfig{}), - "CohereConfig": reflect.TypeOf(CohereConfig{}), - "DatabricksModelServingConfig": reflect.TypeOf(DatabricksModelServingConfig{}), - "GoogleCloudVertexAiConfig": reflect.TypeOf(GoogleCloudVertexAiConfig{}), - "OpenaiConfig": reflect.TypeOf(OpenAiConfig{}), - "PalmConfig": reflect.TypeOf(PaLmConfig{}), + "ai21labs_config": reflect.TypeOf(Ai21LabsConfig{}), + "amazon_bedrock_config": reflect.TypeOf(AmazonBedrockConfig{}), + "anthropic_config": reflect.TypeOf(AnthropicConfig{}), + "cohere_config": reflect.TypeOf(CohereConfig{}), + "databricks_model_serving_config": reflect.TypeOf(DatabricksModelServingConfig{}), + "google_cloud_vertex_ai_config": reflect.TypeOf(GoogleCloudVertexAiConfig{}), + "openai_config": reflect.TypeOf(OpenAiConfig{}), + "palm_config": reflect.TypeOf(PaLmConfig{}), } } func (a ExternalModel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Ai21labsConfig": Ai21LabsConfig{}.ToAttrType(ctx), - "AmazonBedrockConfig": AmazonBedrockConfig{}.ToAttrType(ctx), - "AnthropicConfig": AnthropicConfig{}.ToAttrType(ctx), - "CohereConfig": CohereConfig{}.ToAttrType(ctx), - "DatabricksModelServingConfig": DatabricksModelServingConfig{}.ToAttrType(ctx), - "GoogleCloudVertexAiConfig": GoogleCloudVertexAiConfig{}.ToAttrType(ctx), - "Name": types.StringType, - "OpenaiConfig": OpenAiConfig{}.ToAttrType(ctx), - "PalmConfig": PaLmConfig{}.ToAttrType(ctx), - "Provider": types.StringType, - "Task": types.StringType, + "ai21labs_config": basetypes.ListType{ + ElemType: Ai21LabsConfig{}.ToAttrType(ctx), + }, + "amazon_bedrock_config": basetypes.ListType{ + ElemType: AmazonBedrockConfig{}.ToAttrType(ctx), + }, + "anthropic_config": basetypes.ListType{ + ElemType: AnthropicConfig{}.ToAttrType(ctx), + }, + "cohere_config": basetypes.ListType{ + ElemType: CohereConfig{}.ToAttrType(ctx), + }, + "databricks_model_serving_config": basetypes.ListType{ + ElemType: DatabricksModelServingConfig{}.ToAttrType(ctx), + }, + "google_cloud_vertex_ai_config": basetypes.ListType{ + ElemType: GoogleCloudVertexAiConfig{}.ToAttrType(ctx), + }, + "name": types.StringType, + "openai_config": basetypes.ListType{ + ElemType: OpenAiConfig{}.ToAttrType(ctx), + }, + "palm_config": basetypes.ListType{ + ElemType: PaLmConfig{}.ToAttrType(ctx), + }, + "provider": types.StringType, + "task": types.StringType, }, } } @@ -1167,9 +1215,9 @@ func (a ExternalModelUsageElement) GetComplexFieldTypes() map[string]reflect.Typ func (a ExternalModelUsageElement) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CompletionTokens": types.Int64Type, - "PromptTokens": types.Int64Type, - "TotalTokens": types.Int64Type, + "completion_tokens": types.Int64Type, + "prompt_tokens": types.Int64Type, + "total_tokens": types.Int64Type, }, } } @@ -1198,10 +1246,10 @@ func (a FoundationModel) GetComplexFieldTypes() map[string]reflect.Type { func (a FoundationModel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "DisplayName": types.StringType, - "Docs": types.StringType, - "Name": types.StringType, + "description": types.StringType, + "display_name": types.StringType, + "docs": types.StringType, + "name": types.StringType, }, } } @@ -1226,7 +1274,7 @@ func (a GetOpenApiRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetOpenApiRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1271,7 +1319,7 @@ func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes() map[st func (a GetServingEndpointPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ServingEndpointId": types.StringType, + "serving_endpoint_id": types.StringType, }, } } @@ -1289,14 +1337,14 @@ func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsD func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(ServingEndpointPermissionsDescription{}), + "permission_levels": reflect.TypeOf(ServingEndpointPermissionsDescription{}), } } func (a GetServingEndpointPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: ServingEndpointPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -1322,7 +1370,7 @@ func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string] func (a GetServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ServingEndpointId": types.StringType, + "serving_endpoint_id": types.StringType, }, } } @@ -1346,7 +1394,7 @@ func (a GetServingEndpointRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a GetServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1394,10 +1442,10 @@ func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes() map[string]reflect.Typ func (a GoogleCloudVertexAiConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrivateKey": types.StringType, - "PrivateKeyPlaintext": types.StringType, - "ProjectId": types.StringType, - "Region": types.StringType, + "private_key": types.StringType, + "private_key_plaintext": types.StringType, + "project_id": types.StringType, + "region": types.StringType, }, } } @@ -1415,14 +1463,14 @@ func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListEndpointsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Endpoints": reflect.TypeOf(ServingEndpoint{}), + "endpoints": reflect.TypeOf(ServingEndpoint{}), } } func (a ListEndpointsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Endpoints": basetypes.ListType{ + "endpoints": basetypes.ListType{ ElemType: ServingEndpoint{}.ToAttrType(ctx), }, }, @@ -1452,8 +1500,8 @@ func (a LogsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a LogsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "ServedModelName": types.StringType, + "name": types.StringType, + "served_model_name": types.StringType, }, } } @@ -1471,14 +1519,16 @@ func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState func (a ModelDataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "QueryInfo": reflect.TypeOf(oauth2.DataPlaneInfo{}), + "query_info": reflect.TypeOf(oauth2.DataPlaneInfo{}), } } func (a ModelDataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueryInfo": oauth2_tf.DataPlaneInfo{}.ToAttrType(ctx), + "query_info": basetypes.ListType{ + ElemType: oauth2_tf.DataPlaneInfo{}.ToAttrType(ctx), + }, }, } } @@ -1550,17 +1600,17 @@ func (a OpenAiConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a OpenAiConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MicrosoftEntraClientId": types.StringType, - "MicrosoftEntraClientSecret": types.StringType, - "MicrosoftEntraClientSecretPlaintext": types.StringType, - "MicrosoftEntraTenantId": types.StringType, - "OpenaiApiBase": types.StringType, - "OpenaiApiKey": types.StringType, - "OpenaiApiKeyPlaintext": types.StringType, - "OpenaiApiType": types.StringType, - "OpenaiApiVersion": types.StringType, - "OpenaiDeploymentName": types.StringType, - "OpenaiOrganization": types.StringType, + "microsoft_entra_client_id": types.StringType, + "microsoft_entra_client_secret": types.StringType, + "microsoft_entra_client_secret_plaintext": types.StringType, + "microsoft_entra_tenant_id": types.StringType, + "openai_api_base": types.StringType, + "openai_api_key": types.StringType, + "openai_api_key_plaintext": types.StringType, + "openai_api_type": types.StringType, + "openai_api_version": types.StringType, + "openai_deployment_name": types.StringType, + "openai_organization": types.StringType, }, } } @@ -1591,8 +1641,8 @@ func (a PaLmConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a PaLmConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PalmApiKey": types.StringType, - "PalmApiKeyPlaintext": types.StringType, + "palm_api_key": types.StringType, + "palm_api_key_plaintext": types.StringType, }, } } @@ -1615,21 +1665,21 @@ func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringRead(existing func (a PatchServingEndpointTags) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AddTags": reflect.TypeOf(EndpointTag{}), - "DeleteTags": reflect.TypeOf(types.StringType), + "add_tags": reflect.TypeOf(EndpointTag{}), + "delete_tags": reflect.TypeOf(types.StringType), } } func (a PatchServingEndpointTags) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AddTags": basetypes.ListType{ + "add_tags": basetypes.ListType{ ElemType: EndpointTag{}.ToAttrType(ctx), }, - "DeleteTags": basetypes.ListType{ + "delete_tags": basetypes.ListType{ ElemType: types.StringType, }, - "Name": types.StringType, + "name": types.StringType, }, } } @@ -1656,9 +1706,9 @@ func (a PayloadTable) GetComplexFieldTypes() map[string]reflect.Type { func (a PayloadTable) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Status": types.StringType, - "StatusMessage": types.StringType, + "name": types.StringType, + "status": types.StringType, + "status_message": types.StringType, }, } } @@ -1691,23 +1741,29 @@ func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringRead(existingState func (a PutAiGatewayRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Guardrails": reflect.TypeOf(AiGatewayGuardrails{}), - "InferenceTableConfig": reflect.TypeOf(AiGatewayInferenceTableConfig{}), - "RateLimits": reflect.TypeOf(AiGatewayRateLimit{}), - "UsageTrackingConfig": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), + "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), + "inference_table_config": reflect.TypeOf(AiGatewayInferenceTableConfig{}), + "rate_limits": reflect.TypeOf(AiGatewayRateLimit{}), + "usage_tracking_config": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), } } func (a PutAiGatewayRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Guardrails": AiGatewayGuardrails{}.ToAttrType(ctx), - "InferenceTableConfig": AiGatewayInferenceTableConfig{}.ToAttrType(ctx), - "Name": types.StringType, - "RateLimits": basetypes.ListType{ + "guardrails": basetypes.ListType{ + ElemType: AiGatewayGuardrails{}.ToAttrType(ctx), + }, + "inference_table_config": basetypes.ListType{ + ElemType: AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + }, + "name": types.StringType, + "rate_limits": basetypes.ListType{ ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), }, - "UsageTrackingConfig": AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + "usage_tracking_config": basetypes.ListType{ + ElemType: AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + }, }, } } @@ -1736,22 +1792,28 @@ func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringRead(existingStat func (a PutAiGatewayResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Guardrails": reflect.TypeOf(AiGatewayGuardrails{}), - "InferenceTableConfig": reflect.TypeOf(AiGatewayInferenceTableConfig{}), - "RateLimits": reflect.TypeOf(AiGatewayRateLimit{}), - "UsageTrackingConfig": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), + "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), + "inference_table_config": reflect.TypeOf(AiGatewayInferenceTableConfig{}), + "rate_limits": reflect.TypeOf(AiGatewayRateLimit{}), + "usage_tracking_config": reflect.TypeOf(AiGatewayUsageTrackingConfig{}), } } func (a PutAiGatewayResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Guardrails": AiGatewayGuardrails{}.ToAttrType(ctx), - "InferenceTableConfig": AiGatewayInferenceTableConfig{}.ToAttrType(ctx), - "RateLimits": basetypes.ListType{ + "guardrails": basetypes.ListType{ + ElemType: AiGatewayGuardrails{}.ToAttrType(ctx), + }, + "inference_table_config": basetypes.ListType{ + ElemType: AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + }, + "rate_limits": basetypes.ListType{ ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), }, - "UsageTrackingConfig": AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + "usage_tracking_config": basetypes.ListType{ + ElemType: AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + }, }, } } @@ -1773,15 +1835,15 @@ func (newState *PutRequest) SyncEffectiveFieldsDuringRead(existingState PutReque func (a PutRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RateLimits": reflect.TypeOf(RateLimit{}), + "rate_limits": reflect.TypeOf(RateLimit{}), } } func (a PutRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "RateLimits": basetypes.ListType{ + "name": types.StringType, + "rate_limits": basetypes.ListType{ ElemType: RateLimit{}.ToAttrType(ctx), }, }, @@ -1801,14 +1863,14 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResp func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RateLimits": reflect.TypeOf(RateLimit{}), + "rate_limits": reflect.TypeOf(RateLimit{}), } } func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RateLimits": basetypes.ListType{ + "rate_limits": basetypes.ListType{ ElemType: RateLimit{}.ToAttrType(ctx), }, }, @@ -1875,42 +1937,44 @@ func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringRead(existingState func (a QueryEndpointInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataframeRecords": reflect.TypeOf(struct{}{}), - "DataframeSplit": reflect.TypeOf(DataframeSplitInput{}), - "ExtraParams": reflect.TypeOf(types.StringType), - "Instances": reflect.TypeOf(struct{}{}), - "Messages": reflect.TypeOf(ChatMessage{}), - "Stop": reflect.TypeOf(types.StringType), + "dataframe_records": reflect.TypeOf(struct{}{}), + "dataframe_split": reflect.TypeOf(DataframeSplitInput{}), + "extra_params": reflect.TypeOf(types.StringType), + "instances": reflect.TypeOf(struct{}{}), + "messages": reflect.TypeOf(ChatMessage{}), + "stop": reflect.TypeOf(types.StringType), } } func (a QueryEndpointInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataframeRecords": basetypes.ListType{ + "dataframe_records": basetypes.ListType{ ElemType: types.ObjectType{}, }, - "DataframeSplit": DataframeSplitInput{}.ToAttrType(ctx), - "ExtraParams": basetypes.MapType{ + "dataframe_split": basetypes.ListType{ + ElemType: DataframeSplitInput{}.ToAttrType(ctx), + }, + "extra_params": basetypes.MapType{ ElemType: types.StringType, }, - "Input": types.ObjectType{}, - "Inputs": types.ObjectType{}, - "Instances": basetypes.ListType{ + "input": types.ObjectType{}, + "inputs": types.ObjectType{}, + "instances": basetypes.ListType{ ElemType: types.ObjectType{}, }, - "MaxTokens": types.Int64Type, - "Messages": basetypes.ListType{ + "max_tokens": types.Int64Type, + "messages": basetypes.ListType{ ElemType: ChatMessage{}.ToAttrType(ctx), }, - "N": types.Int64Type, - "Name": types.StringType, - "Prompt": types.ObjectType{}, - "Stop": basetypes.ListType{ + "n": types.Int64Type, + "name": types.StringType, + "prompt": types.ObjectType{}, + "stop": basetypes.ListType{ ElemType: types.StringType, }, - "Stream": types.BoolType, - "Temperature": types.Float64Type, + "stream": types.BoolType, + "temperature": types.Float64Type, }, } } @@ -1954,31 +2018,33 @@ func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringRead(existingSta func (a QueryEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Choices": reflect.TypeOf(V1ResponseChoiceElement{}), - "Data": reflect.TypeOf(EmbeddingsV1ResponseEmbeddingElement{}), - "Predictions": reflect.TypeOf(struct{}{}), - "Usage": reflect.TypeOf(ExternalModelUsageElement{}), + "choices": reflect.TypeOf(V1ResponseChoiceElement{}), + "data": reflect.TypeOf(EmbeddingsV1ResponseEmbeddingElement{}), + "predictions": reflect.TypeOf(struct{}{}), + "usage": reflect.TypeOf(ExternalModelUsageElement{}), } } func (a QueryEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Choices": basetypes.ListType{ + "choices": basetypes.ListType{ ElemType: V1ResponseChoiceElement{}.ToAttrType(ctx), }, - "Created": types.Int64Type, - "Data": basetypes.ListType{ + "created": types.Int64Type, + "data": basetypes.ListType{ ElemType: EmbeddingsV1ResponseEmbeddingElement{}.ToAttrType(ctx), }, - "Id": types.StringType, - "Model": types.StringType, - "Object": types.StringType, - "Predictions": basetypes.ListType{ + "id": types.StringType, + "model": types.StringType, + "object": types.StringType, + "predictions": basetypes.ListType{ ElemType: types.ObjectType{}, }, - "ServedModelName": types.StringType, - "Usage": ExternalModelUsageElement{}.ToAttrType(ctx), + "served-model-name": types.StringType, + "usage": basetypes.ListType{ + ElemType: ExternalModelUsageElement{}.ToAttrType(ctx), + }, }, } } @@ -2009,9 +2075,9 @@ func (a RateLimit) GetComplexFieldTypes() map[string]reflect.Type { func (a RateLimit) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Calls": types.Int64Type, - "Key": types.StringType, - "RenewalPeriod": types.StringType, + "calls": types.Int64Type, + "key": types.StringType, + "renewal_period": types.StringType, }, } } @@ -2037,8 +2103,8 @@ func (a Route) GetComplexFieldTypes() map[string]reflect.Type { func (a Route) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ServedModelName": types.StringType, - "TrafficPercentage": types.Int64Type, + "served_model_name": types.StringType, + "traffic_percentage": types.Int64Type, }, } } @@ -2112,27 +2178,29 @@ func (newState *ServedEntityInput) SyncEffectiveFieldsDuringRead(existingState S func (a ServedEntityInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(types.StringType), - "ExternalModel": reflect.TypeOf(ExternalModel{}), + "environment_vars": reflect.TypeOf(types.StringType), + "external_model": reflect.TypeOf(ExternalModel{}), } } func (a ServedEntityInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EntityName": types.StringType, - "EntityVersion": types.StringType, - "EnvironmentVars": basetypes.MapType{ + "entity_name": types.StringType, + "entity_version": types.StringType, + "environment_vars": basetypes.MapType{ ElemType: types.StringType, }, - "ExternalModel": ExternalModel{}.ToAttrType(ctx), - "InstanceProfileArn": types.StringType, - "MaxProvisionedThroughput": types.Int64Type, - "MinProvisionedThroughput": types.Int64Type, - "Name": types.StringType, - "ScaleToZeroEnabled": types.BoolType, - "WorkloadSize": types.StringType, - "WorkloadType": types.StringType, + "external_model": basetypes.ListType{ + ElemType: ExternalModel{}.ToAttrType(ctx), + }, + "instance_profile_arn": types.StringType, + "max_provisioned_throughput": types.Int64Type, + "min_provisioned_throughput": types.Int64Type, + "name": types.StringType, + "scale_to_zero_enabled": types.BoolType, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -2208,33 +2276,39 @@ func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringRead(existingState func (a ServedEntityOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(types.StringType), - "ExternalModel": reflect.TypeOf(ExternalModel{}), - "FoundationModel": reflect.TypeOf(FoundationModel{}), - "State": reflect.TypeOf(ServedModelState{}), + "environment_vars": reflect.TypeOf(types.StringType), + "external_model": reflect.TypeOf(ExternalModel{}), + "foundation_model": reflect.TypeOf(FoundationModel{}), + "state": reflect.TypeOf(ServedModelState{}), } } func (a ServedEntityOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "Creator": types.StringType, - "EntityName": types.StringType, - "EntityVersion": types.StringType, - "EnvironmentVars": basetypes.MapType{ + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "entity_name": types.StringType, + "entity_version": types.StringType, + "environment_vars": basetypes.MapType{ ElemType: types.StringType, }, - "ExternalModel": ExternalModel{}.ToAttrType(ctx), - "FoundationModel": FoundationModel{}.ToAttrType(ctx), - "InstanceProfileArn": types.StringType, - "MaxProvisionedThroughput": types.Int64Type, - "MinProvisionedThroughput": types.Int64Type, - "Name": types.StringType, - "ScaleToZeroEnabled": types.BoolType, - "State": ServedModelState{}.ToAttrType(ctx), - "WorkloadSize": types.StringType, - "WorkloadType": types.StringType, + "external_model": basetypes.ListType{ + ElemType: ExternalModel{}.ToAttrType(ctx), + }, + "foundation_model": basetypes.ListType{ + ElemType: FoundationModel{}.ToAttrType(ctx), + }, + "instance_profile_arn": types.StringType, + "max_provisioned_throughput": types.Int64Type, + "min_provisioned_throughput": types.Int64Type, + "name": types.StringType, + "scale_to_zero_enabled": types.BoolType, + "state": basetypes.ListType{ + ElemType: ServedModelState{}.ToAttrType(ctx), + }, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -2269,19 +2343,23 @@ func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringRead(existingState Se func (a ServedEntitySpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ExternalModel": reflect.TypeOf(ExternalModel{}), - "FoundationModel": reflect.TypeOf(FoundationModel{}), + "external_model": reflect.TypeOf(ExternalModel{}), + "foundation_model": reflect.TypeOf(FoundationModel{}), } } func (a ServedEntitySpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EntityName": types.StringType, - "EntityVersion": types.StringType, - "ExternalModel": ExternalModel{}.ToAttrType(ctx), - "FoundationModel": FoundationModel{}.ToAttrType(ctx), - "Name": types.StringType, + "entity_name": types.StringType, + "entity_version": types.StringType, + "external_model": basetypes.ListType{ + ElemType: ExternalModel{}.ToAttrType(ctx), + }, + "foundation_model": basetypes.ListType{ + ElemType: FoundationModel{}.ToAttrType(ctx), + }, + "name": types.StringType, }, } } @@ -2342,25 +2420,25 @@ func (newState *ServedModelInput) SyncEffectiveFieldsDuringRead(existingState Se func (a ServedModelInput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(types.StringType), + "environment_vars": reflect.TypeOf(types.StringType), } } func (a ServedModelInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EnvironmentVars": basetypes.MapType{ + "environment_vars": basetypes.MapType{ ElemType: types.StringType, }, - "InstanceProfileArn": types.StringType, - "MaxProvisionedThroughput": types.Int64Type, - "MinProvisionedThroughput": types.Int64Type, - "ModelName": types.StringType, - "ModelVersion": types.StringType, - "Name": types.StringType, - "ScaleToZeroEnabled": types.BoolType, - "WorkloadSize": types.StringType, - "WorkloadType": types.StringType, + "instance_profile_arn": types.StringType, + "max_provisioned_throughput": types.Int64Type, + "min_provisioned_throughput": types.Int64Type, + "model_name": types.StringType, + "model_version": types.StringType, + "name": types.StringType, + "scale_to_zero_enabled": types.BoolType, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -2419,27 +2497,29 @@ func (newState *ServedModelOutput) SyncEffectiveFieldsDuringRead(existingState S func (a ServedModelOutput) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnvironmentVars": reflect.TypeOf(types.StringType), - "State": reflect.TypeOf(ServedModelState{}), + "environment_vars": reflect.TypeOf(types.StringType), + "state": reflect.TypeOf(ServedModelState{}), } } func (a ServedModelOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "Creator": types.StringType, - "EnvironmentVars": basetypes.MapType{ + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "environment_vars": basetypes.MapType{ ElemType: types.StringType, }, - "InstanceProfileArn": types.StringType, - "ModelName": types.StringType, - "ModelVersion": types.StringType, - "Name": types.StringType, - "ScaleToZeroEnabled": types.BoolType, - "State": ServedModelState{}.ToAttrType(ctx), - "WorkloadSize": types.StringType, - "WorkloadType": types.StringType, + "instance_profile_arn": types.StringType, + "model_name": types.StringType, + "model_version": types.StringType, + "name": types.StringType, + "scale_to_zero_enabled": types.BoolType, + "state": basetypes.ListType{ + ElemType: ServedModelState{}.ToAttrType(ctx), + }, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -2468,9 +2548,9 @@ func (a ServedModelSpec) GetComplexFieldTypes() map[string]reflect.Type { func (a ServedModelSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ModelName": types.StringType, - "ModelVersion": types.StringType, - "Name": types.StringType, + "model_name": types.StringType, + "model_version": types.StringType, + "name": types.StringType, }, } } @@ -2506,8 +2586,8 @@ func (a ServedModelState) GetComplexFieldTypes() map[string]reflect.Type { func (a ServedModelState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Deployment": types.StringType, - "DeploymentStateMessage": types.StringType, + "deployment": types.StringType, + "deployment_state_message": types.StringType, }, } } @@ -2531,7 +2611,7 @@ func (a ServerLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a ServerLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Logs": types.StringType, + "logs": types.StringType, }, } } @@ -2569,28 +2649,34 @@ func (newState *ServingEndpoint) SyncEffectiveFieldsDuringRead(existingState Ser func (a ServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AiGateway": reflect.TypeOf(AiGatewayConfig{}), - "Config": reflect.TypeOf(EndpointCoreConfigSummary{}), - "State": reflect.TypeOf(EndpointState{}), - "Tags": reflect.TypeOf(EndpointTag{}), + "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), + "config": reflect.TypeOf(EndpointCoreConfigSummary{}), + "state": reflect.TypeOf(EndpointState{}), + "tags": reflect.TypeOf(EndpointTag{}), } } func (a ServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AiGateway": AiGatewayConfig{}.ToAttrType(ctx), - "Config": EndpointCoreConfigSummary{}.ToAttrType(ctx), - "CreationTimestamp": types.Int64Type, - "Creator": types.StringType, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "Name": types.StringType, - "State": EndpointState{}.ToAttrType(ctx), - "Tags": basetypes.ListType{ + "ai_gateway": basetypes.ListType{ + ElemType: AiGatewayConfig{}.ToAttrType(ctx), + }, + "config": basetypes.ListType{ + ElemType: EndpointCoreConfigSummary{}.ToAttrType(ctx), + }, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "name": types.StringType, + "state": basetypes.ListType{ + ElemType: EndpointState{}.ToAttrType(ctx), + }, + "tags": basetypes.ListType{ ElemType: EndpointTag{}.ToAttrType(ctx), }, - "Task": types.StringType, + "task": types.StringType, }, } } @@ -2619,10 +2705,10 @@ func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes() map[string]r func (a ServingEndpointAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -2648,20 +2734,20 @@ func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringR func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(ServingEndpointPermission{}), + "all_permissions": reflect.TypeOf(ServingEndpointPermission{}), } } func (a ServingEndpointAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: ServingEndpointPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -2710,35 +2796,45 @@ func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringRead(existingS func (a ServingEndpointDetailed) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AiGateway": reflect.TypeOf(AiGatewayConfig{}), - "Config": reflect.TypeOf(EndpointCoreConfigOutput{}), - "DataPlaneInfo": reflect.TypeOf(ModelDataPlaneInfo{}), - "PendingConfig": reflect.TypeOf(EndpointPendingConfig{}), - "State": reflect.TypeOf(EndpointState{}), - "Tags": reflect.TypeOf(EndpointTag{}), + "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), + "config": reflect.TypeOf(EndpointCoreConfigOutput{}), + "data_plane_info": reflect.TypeOf(ModelDataPlaneInfo{}), + "pending_config": reflect.TypeOf(EndpointPendingConfig{}), + "state": reflect.TypeOf(EndpointState{}), + "tags": reflect.TypeOf(EndpointTag{}), } } func (a ServingEndpointDetailed) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AiGateway": AiGatewayConfig{}.ToAttrType(ctx), - "Config": EndpointCoreConfigOutput{}.ToAttrType(ctx), - "CreationTimestamp": types.Int64Type, - "Creator": types.StringType, - "DataPlaneInfo": ModelDataPlaneInfo{}.ToAttrType(ctx), - "EndpointUrl": types.StringType, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "Name": types.StringType, - "PendingConfig": EndpointPendingConfig{}.ToAttrType(ctx), - "PermissionLevel": types.StringType, - "RouteOptimized": types.BoolType, - "State": EndpointState{}.ToAttrType(ctx), - "Tags": basetypes.ListType{ + "ai_gateway": basetypes.ListType{ + ElemType: AiGatewayConfig{}.ToAttrType(ctx), + }, + "config": basetypes.ListType{ + ElemType: EndpointCoreConfigOutput{}.ToAttrType(ctx), + }, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "data_plane_info": basetypes.ListType{ + ElemType: ModelDataPlaneInfo{}.ToAttrType(ctx), + }, + "endpoint_url": types.StringType, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "name": types.StringType, + "pending_config": basetypes.ListType{ + ElemType: EndpointPendingConfig{}.ToAttrType(ctx), + }, + "permission_level": types.StringType, + "route_optimized": types.BoolType, + "state": basetypes.ListType{ + ElemType: EndpointState{}.ToAttrType(ctx), + }, + "tags": basetypes.ListType{ ElemType: EndpointTag{}.ToAttrType(ctx), }, - "Task": types.StringType, + "task": types.StringType, }, } } @@ -2759,18 +2855,18 @@ func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringRead(existin func (a ServingEndpointPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a ServingEndpointPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -2791,18 +2887,18 @@ func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringRead(existi func (a ServingEndpointPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ServingEndpointAccessControlResponse{}), + "access_control_list": reflect.TypeOf(ServingEndpointAccessControlResponse{}), } } func (a ServingEndpointPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ServingEndpointAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2826,8 +2922,8 @@ func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes() map[string func (a ServingEndpointPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -2846,17 +2942,17 @@ func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(ServingEndpointAccessControlRequest{}), + "access_control_list": reflect.TypeOf(ServingEndpointAccessControlRequest{}), } } func (a ServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: ServingEndpointAccessControlRequest{}.ToAttrType(ctx), }, - "ServingEndpointId": types.StringType, + "serving_endpoint_id": types.StringType, }, } } @@ -2874,14 +2970,14 @@ func (newState *TrafficConfig) SyncEffectiveFieldsDuringRead(existingState Traff func (a TrafficConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Routes": reflect.TypeOf(Route{}), + "routes": reflect.TypeOf(Route{}), } } func (a TrafficConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Routes": basetypes.ListType{ + "routes": basetypes.ListType{ ElemType: Route{}.ToAttrType(ctx), }, }, @@ -2909,18 +3005,20 @@ func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringRead(existingS func (a V1ResponseChoiceElement) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Message": reflect.TypeOf(ChatMessage{}), + "message": reflect.TypeOf(ChatMessage{}), } } func (a V1ResponseChoiceElement) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FinishReason": types.StringType, - "Index": types.Int64Type, - "Logprobs": types.Int64Type, - "Message": ChatMessage{}.ToAttrType(ctx), - "Text": types.StringType, + "finishReason": types.StringType, + "index": types.Int64Type, + "logprobs": types.Int64Type, + "message": basetypes.ListType{ + ElemType: ChatMessage{}.ToAttrType(ctx), + }, + "text": types.StringType, }, } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 7ddd947a05..7c9309030a 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -36,7 +36,7 @@ func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes() map[string]re func (a AibiDashboardEmbeddingAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessPolicyType": types.StringType, + "access_policy_type": types.StringType, }, } } @@ -67,16 +67,18 @@ func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDu func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AibiDashboardEmbeddingAccessPolicy": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicy{}), + "aibi_dashboard_embedding_access_policy": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicy{}), } } func (a AibiDashboardEmbeddingAccessPolicySetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AibiDashboardEmbeddingAccessPolicy": AibiDashboardEmbeddingAccessPolicy{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "aibi_dashboard_embedding_access_policy": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingAccessPolicy{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -93,14 +95,14 @@ func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuring func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ApprovedDomains": reflect.TypeOf(types.StringType), + "approved_domains": reflect.TypeOf(types.StringType), } } func (a AibiDashboardEmbeddingApprovedDomains) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApprovedDomains": basetypes.ListType{ + "approved_domains": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -133,16 +135,18 @@ func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveField func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AibiDashboardEmbeddingApprovedDomains": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomains{}), + "aibi_dashboard_embedding_approved_domains": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomains{}), } } func (a AibiDashboardEmbeddingApprovedDomainsSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AibiDashboardEmbeddingApprovedDomains": AibiDashboardEmbeddingApprovedDomains{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingApprovedDomains{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -173,16 +177,18 @@ func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringRead(exi func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AutomaticClusterUpdateWorkspace": reflect.TypeOf(ClusterAutoRestartMessage{}), + "automatic_cluster_update_workspace": reflect.TypeOf(ClusterAutoRestartMessage{}), } } func (a AutomaticClusterUpdateSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutomaticClusterUpdateWorkspace": ClusterAutoRestartMessage{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "automatic_cluster_update_workspace": basetypes.ListType{ + ElemType: ClusterAutoRestartMessage{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -204,7 +210,7 @@ func (a BooleanMessage) GetComplexFieldTypes() map[string]reflect.Type { func (a BooleanMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Value": types.BoolType, + "value": types.BoolType, }, } } @@ -234,19 +240,23 @@ func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringRead(existin func (a ClusterAutoRestartMessage) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnablementDetails": reflect.TypeOf(ClusterAutoRestartMessageEnablementDetails{}), - "MaintenanceWindow": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindow{}), + "enablement_details": reflect.TypeOf(ClusterAutoRestartMessageEnablementDetails{}), + "maintenance_window": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindow{}), } } func (a ClusterAutoRestartMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CanToggle": types.BoolType, - "Enabled": types.BoolType, - "EnablementDetails": ClusterAutoRestartMessageEnablementDetails{}.ToAttrType(ctx), - "MaintenanceWindow": ClusterAutoRestartMessageMaintenanceWindow{}.ToAttrType(ctx), - "RestartEvenIfNoUpdatesAvailable": types.BoolType, + "can_toggle": types.BoolType, + "enabled": types.BoolType, + "enablement_details": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageEnablementDetails{}.ToAttrType(ctx), + }, + "maintenance_window": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.ToAttrType(ctx), + }, + "restart_even_if_no_updates_available": types.BoolType, }, } } @@ -280,9 +290,9 @@ func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes() map[s func (a ClusterAutoRestartMessageEnablementDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ForcedForComplianceMode": types.BoolType, - "UnavailableForDisabledEntitlement": types.BoolType, - "UnavailableForNonEnterpriseTier": types.BoolType, + "forced_for_compliance_mode": types.BoolType, + "unavailable_for_disabled_entitlement": types.BoolType, + "unavailable_for_non_enterprise_tier": types.BoolType, }, } } @@ -299,14 +309,16 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsD func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "WeekDayBasedSchedule": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}), + "week_day_based_schedule": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}), } } func (a ClusterAutoRestartMessageMaintenanceWindow) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WeekDayBasedSchedule": ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.ToAttrType(ctx), + "week_day_based_schedule": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.ToAttrType(ctx), + }, }, } } @@ -327,16 +339,18 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "WindowStartTime": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}), + "window_start_time": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}), } } func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DayOfWeek": types.StringType, - "Frequency": types.StringType, - "WindowStartTime": ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.ToAttrType(ctx), + "day_of_week": types.StringType, + "frequency": types.StringType, + "window_start_time": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.ToAttrType(ctx), + }, }, } } @@ -360,8 +374,8 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFie func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Hours": types.Int64Type, - "Minutes": types.Int64Type, + "hours": types.Int64Type, + "minutes": types.Int64Type, }, } } @@ -382,17 +396,17 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existin func (a ComplianceSecurityProfile) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ComplianceStandards": reflect.TypeOf(types.StringType), + "compliance_standards": reflect.TypeOf(types.StringType), } } func (a ComplianceSecurityProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ComplianceStandards": basetypes.ListType{ + "compliance_standards": basetypes.ListType{ ElemType: types.StringType, }, - "IsEnabled": types.BoolType, + "is_enabled": types.BoolType, }, } } @@ -424,16 +438,18 @@ func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringRead( func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ComplianceSecurityProfileWorkspace": reflect.TypeOf(ComplianceSecurityProfile{}), + "compliance_security_profile_workspace": reflect.TypeOf(ComplianceSecurityProfile{}), } } func (a ComplianceSecurityProfileSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ComplianceSecurityProfileWorkspace": ComplianceSecurityProfile{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "compliance_security_profile_workspace": basetypes.ListType{ + ElemType: ComplianceSecurityProfile{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -458,22 +474,32 @@ func (newState *Config) SyncEffectiveFieldsDuringRead(existingState Config) { func (a Config) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Email": reflect.TypeOf(EmailConfig{}), - "GenericWebhook": reflect.TypeOf(GenericWebhookConfig{}), - "MicrosoftTeams": reflect.TypeOf(MicrosoftTeamsConfig{}), - "Pagerduty": reflect.TypeOf(PagerdutyConfig{}), - "Slack": reflect.TypeOf(SlackConfig{}), + "email": reflect.TypeOf(EmailConfig{}), + "generic_webhook": reflect.TypeOf(GenericWebhookConfig{}), + "microsoft_teams": reflect.TypeOf(MicrosoftTeamsConfig{}), + "pagerduty": reflect.TypeOf(PagerdutyConfig{}), + "slack": reflect.TypeOf(SlackConfig{}), } } func (a Config) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Email": EmailConfig{}.ToAttrType(ctx), - "GenericWebhook": GenericWebhookConfig{}.ToAttrType(ctx), - "MicrosoftTeams": MicrosoftTeamsConfig{}.ToAttrType(ctx), - "Pagerduty": PagerdutyConfig{}.ToAttrType(ctx), - "Slack": SlackConfig{}.ToAttrType(ctx), + "email": basetypes.ListType{ + ElemType: EmailConfig{}.ToAttrType(ctx), + }, + "generic_webhook": basetypes.ListType{ + ElemType: GenericWebhookConfig{}.ToAttrType(ctx), + }, + "microsoft_teams": basetypes.ListType{ + ElemType: MicrosoftTeamsConfig{}.ToAttrType(ctx), + }, + "pagerduty": basetypes.ListType{ + ElemType: PagerdutyConfig{}.ToAttrType(ctx), + }, + "slack": basetypes.ListType{ + ElemType: SlackConfig{}.ToAttrType(ctx), + }, }, } } @@ -500,18 +526,18 @@ func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a CreateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.StringType), } } func (a CreateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAddresses": basetypes.ListType{ + "ip_addresses": basetypes.ListType{ ElemType: types.StringType, }, - "Label": types.StringType, - "ListType": types.StringType, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -530,14 +556,16 @@ func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringRead(existi func (a CreateIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessList": reflect.TypeOf(IpAccessListInfo{}), + "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } } func (a CreateIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessList": IpAccessListInfo{}.ToAttrType(ctx), + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.ToAttrType(ctx), + }, }, } } @@ -567,8 +595,8 @@ func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes() map[strin func (a CreateNetworkConnectivityConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Region": types.StringType, + "name": types.StringType, + "region": types.StringType, }, } } @@ -589,15 +617,17 @@ func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringR func (a CreateNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Config": reflect.TypeOf(Config{}), + "config": reflect.TypeOf(Config{}), } } func (a CreateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Config": Config{}.ToAttrType(ctx), - "DisplayName": types.StringType, + "config": basetypes.ListType{ + ElemType: Config{}.ToAttrType(ctx), + }, + "display_name": types.StringType, }, } } @@ -625,9 +655,9 @@ func (a CreateOboTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateOboTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplicationId": types.StringType, - "Comment": types.StringType, - "LifetimeSeconds": types.Int64Type, + "application_id": types.StringType, + "comment": types.StringType, + "lifetime_seconds": types.Int64Type, }, } } @@ -647,15 +677,17 @@ func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringRead(existingSt func (a CreateOboTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenInfo": reflect.TypeOf(TokenInfo{}), + "token_info": reflect.TypeOf(TokenInfo{}), } } func (a CreateOboTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenInfo": TokenInfo{}.ToAttrType(ctx), - "TokenValue": types.StringType, + "token_info": basetypes.ListType{ + ElemType: TokenInfo{}.ToAttrType(ctx), + }, + "token_value": types.StringType, }, } } @@ -684,9 +716,9 @@ func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]refl func (a CreatePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupId": types.StringType, - "NetworkConnectivityConfigId": types.StringType, - "ResourceId": types.StringType, + "group_id": types.StringType, + "network_connectivity_config_id": types.StringType, + "resource_id": types.StringType, }, } } @@ -713,8 +745,8 @@ func (a CreateTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "LifetimeSeconds": types.Int64Type, + "comment": types.StringType, + "lifetime_seconds": types.Int64Type, }, } } @@ -734,15 +766,17 @@ func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringRead(existingState func (a CreateTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenInfo": reflect.TypeOf(PublicTokenInfo{}), + "token_info": reflect.TypeOf(PublicTokenInfo{}), } } func (a CreateTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenInfo": PublicTokenInfo{}.ToAttrType(ctx), - "TokenValue": types.StringType, + "token_info": basetypes.ListType{ + ElemType: PublicTokenInfo{}.ToAttrType(ctx), + }, + "token_value": types.StringType, }, } } @@ -764,17 +798,17 @@ func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringRead(existingStat func (a CspEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ComplianceStandards": reflect.TypeOf(types.StringType), + "compliance_standards": reflect.TypeOf(types.StringType), } } func (a CspEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ComplianceStandards": basetypes.ListType{ + "compliance_standards": basetypes.ListType{ ElemType: types.StringType, }, - "IsEnforced": types.BoolType, + "is_enforced": types.BoolType, }, } } @@ -806,16 +840,18 @@ func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringRead(exist func (a CspEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CspEnablementAccount": reflect.TypeOf(CspEnablementAccount{}), + "csp_enablement_account": reflect.TypeOf(CspEnablementAccount{}), } } func (a CspEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CspEnablementAccount": CspEnablementAccount{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "csp_enablement_account": basetypes.ListType{ + ElemType: CspEnablementAccount{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -856,16 +892,18 @@ func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringRead(existingS func (a DefaultNamespaceSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Namespace": reflect.TypeOf(StringMessage{}), + "namespace": reflect.TypeOf(StringMessage{}), } } func (a DefaultNamespaceSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, - "Namespace": StringMessage{}.ToAttrType(ctx), - "SettingName": types.StringType, + "etag": types.StringType, + "namespace": basetypes.ListType{ + ElemType: StringMessage{}.ToAttrType(ctx), + }, + "setting_name": types.StringType, }, } } @@ -889,7 +927,7 @@ func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes() map[string]refl func (a DeleteAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessListId": types.StringType, + "ip_access_list_id": types.StringType, }, } } @@ -919,7 +957,7 @@ func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string] func (a DeleteDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -949,7 +987,7 @@ func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes() map[string func (a DeleteDefaultNamespaceSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -979,7 +1017,7 @@ func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]refl func (a DeleteDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1009,7 +1047,7 @@ func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes() map[string]ref func (a DeleteDisableLegacyAccessResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1039,7 +1077,7 @@ func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflec func (a DeleteDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1069,7 +1107,7 @@ func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes() map[string]refle func (a DeleteDisableLegacyDbfsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1099,7 +1137,7 @@ func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]re func (a DeleteDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1129,7 +1167,7 @@ func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes() map[string]r func (a DeleteDisableLegacyFeaturesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1153,7 +1191,7 @@ func (a DeleteIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessListId": types.StringType, + "ip_access_list_id": types.StringType, }, } } @@ -1177,7 +1215,7 @@ func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() ma func (a DeleteNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkConnectivityConfigId": types.StringType, + "network_connectivity_config_id": types.StringType, }, } } @@ -1219,7 +1257,7 @@ func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes() map[string] func (a DeleteNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1249,7 +1287,7 @@ func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]r func (a DeletePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1279,7 +1317,7 @@ func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes() map[string] func (a DeletePersonalComputeSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1305,8 +1343,8 @@ func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]refl func (a DeletePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkConnectivityConfigId": types.StringType, - "PrivateEndpointRuleId": types.StringType, + "network_connectivity_config_id": types.StringType, + "private_endpoint_rule_id": types.StringType, }, } } @@ -1355,7 +1393,7 @@ func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[ func (a DeleteRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1385,7 +1423,7 @@ func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes() map func (a DeleteRestrictWorkspaceAdminsSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1409,7 +1447,7 @@ func (a DeleteTokenManagementRequest) GetComplexFieldTypes() map[string]reflect. func (a DeleteTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenId": types.StringType, + "token_id": types.StringType, }, } } @@ -1440,16 +1478,18 @@ func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringRead(existingState func (a DisableLegacyAccess) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DisableLegacyAccess": reflect.TypeOf(BooleanMessage{}), + "disable_legacy_access": reflect.TypeOf(BooleanMessage{}), } } func (a DisableLegacyAccess) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisableLegacyAccess": BooleanMessage{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "disable_legacy_access": basetypes.ListType{ + ElemType: BooleanMessage{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1480,16 +1520,18 @@ func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringRead(existingState D func (a DisableLegacyDbfs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DisableLegacyDbfs": reflect.TypeOf(BooleanMessage{}), + "disable_legacy_dbfs": reflect.TypeOf(BooleanMessage{}), } } func (a DisableLegacyDbfs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisableLegacyDbfs": BooleanMessage{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "disable_legacy_dbfs": basetypes.ListType{ + ElemType: BooleanMessage{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1520,16 +1562,18 @@ func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringRead(existingSta func (a DisableLegacyFeatures) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DisableLegacyFeatures": reflect.TypeOf(BooleanMessage{}), + "disable_legacy_features": reflect.TypeOf(BooleanMessage{}), } } func (a DisableLegacyFeatures) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisableLegacyFeatures": BooleanMessage{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "disable_legacy_features": basetypes.ListType{ + ElemType: BooleanMessage{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1547,14 +1591,14 @@ func (newState *EmailConfig) SyncEffectiveFieldsDuringRead(existingState EmailCo func (a EmailConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Addresses": reflect.TypeOf(types.StringType), + "addresses": reflect.TypeOf(types.StringType), } } func (a EmailConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Addresses": basetypes.ListType{ + "addresses": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1598,7 +1642,7 @@ func (a EnhancedSecurityMonitoring) GetComplexFieldTypes() map[string]reflect.Ty func (a EnhancedSecurityMonitoring) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsEnabled": types.BoolType, + "is_enabled": types.BoolType, }, } } @@ -1630,16 +1674,18 @@ func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringRead func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EnhancedSecurityMonitoringWorkspace": reflect.TypeOf(EnhancedSecurityMonitoring{}), + "enhanced_security_monitoring_workspace": reflect.TypeOf(EnhancedSecurityMonitoring{}), } } func (a EnhancedSecurityMonitoringSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EnhancedSecurityMonitoringWorkspace": EnhancedSecurityMonitoring{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "enhanced_security_monitoring_workspace": basetypes.ListType{ + ElemType: EnhancedSecurityMonitoring{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1662,7 +1708,7 @@ func (a EsmEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { func (a EsmEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IsEnforced": types.BoolType, + "is_enforced": types.BoolType, }, } } @@ -1694,16 +1740,18 @@ func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringRead(exist func (a EsmEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EsmEnablementAccount": reflect.TypeOf(EsmEnablementAccount{}), + "esm_enablement_account": reflect.TypeOf(EsmEnablementAccount{}), } } func (a EsmEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EsmEnablementAccount": EsmEnablementAccount{}.ToAttrType(ctx), - "Etag": types.StringType, - "SettingName": types.StringType, + "esm_enablement_account": basetypes.ListType{ + ElemType: EsmEnablementAccount{}.ToAttrType(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1731,20 +1779,20 @@ func (newState *ExchangeToken) SyncEffectiveFieldsDuringRead(existingState Excha func (a ExchangeToken) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Scopes": reflect.TypeOf(types.StringType), + "scopes": reflect.TypeOf(types.StringType), } } func (a ExchangeToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Credential": types.StringType, - "CredentialEolTime": types.Int64Type, - "OwnerId": types.Int64Type, - "Scopes": basetypes.ListType{ + "credential": types.StringType, + "credentialEolTime": types.Int64Type, + "ownerId": types.Int64Type, + "scopes": basetypes.ListType{ ElemType: types.StringType, }, - "TokenType": types.StringType, + "tokenType": types.StringType, }, } } @@ -1767,20 +1815,22 @@ func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringRead(existingStat func (a ExchangeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PartitionId": reflect.TypeOf(PartitionId{}), - "Scopes": reflect.TypeOf(types.StringType), - "TokenType": reflect.TypeOf(types.StringType), + "partitionId": reflect.TypeOf(PartitionId{}), + "scopes": reflect.TypeOf(types.StringType), + "tokenType": reflect.TypeOf(types.StringType), } } func (a ExchangeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PartitionId": PartitionId{}.ToAttrType(ctx), - "Scopes": basetypes.ListType{ + "partitionId": basetypes.ListType{ + ElemType: PartitionId{}.ToAttrType(ctx), + }, + "scopes": basetypes.ListType{ ElemType: types.StringType, }, - "TokenType": basetypes.ListType{ + "tokenType": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1800,14 +1850,14 @@ func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ExchangeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(ExchangeToken{}), + "values": reflect.TypeOf(ExchangeToken{}), } } func (a ExchangeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Values": basetypes.ListType{ + "values": basetypes.ListType{ ElemType: ExchangeToken{}.ToAttrType(ctx), }, }, @@ -1828,14 +1878,16 @@ func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringRead(existin func (a FetchIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessList": reflect.TypeOf(IpAccessListInfo{}), + "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } } func (a FetchIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessList": IpAccessListInfo{}.ToAttrType(ctx), + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.ToAttrType(ctx), + }, }, } } @@ -1868,12 +1920,12 @@ func (a GenericWebhookConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a GenericWebhookConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Password": types.StringType, - "PasswordSet": types.BoolType, - "Url": types.StringType, - "UrlSet": types.BoolType, - "Username": types.StringType, - "UsernameSet": types.BoolType, + "password": types.StringType, + "password_set": types.BoolType, + "url": types.StringType, + "url_set": types.BoolType, + "username": types.StringType, + "username_set": types.BoolType, }, } } @@ -1897,7 +1949,7 @@ func (a GetAccountIpAccessListRequest) GetComplexFieldTypes() map[string]reflect func (a GetAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessListId": types.StringType, + "ip_access_list_id": types.StringType, }, } } @@ -1927,7 +1979,7 @@ func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldType func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1957,7 +2009,7 @@ func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldT func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -1987,7 +2039,7 @@ func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[stri func (a GetAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2017,7 +2069,7 @@ func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[s func (a GetComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2047,7 +2099,7 @@ func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string func (a GetCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2077,7 +2129,7 @@ func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]ref func (a GetDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2107,7 +2159,7 @@ func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect func (a GetDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2137,7 +2189,7 @@ func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.T func (a GetDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2167,7 +2219,7 @@ func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]refle func (a GetDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2197,7 +2249,7 @@ func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[ func (a GetEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2227,7 +2279,7 @@ func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string func (a GetEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2251,7 +2303,7 @@ func (a GetIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessListId": types.StringType, + "ip_access_list_id": types.StringType, }, } } @@ -2269,14 +2321,16 @@ func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingS func (a GetIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessList": reflect.TypeOf(IpAccessListInfo{}), + "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } } func (a GetIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessList": IpAccessListInfo{}.ToAttrType(ctx), + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.ToAttrType(ctx), + }, }, } } @@ -2294,14 +2348,14 @@ func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringRead(existing func (a GetIpAccessListsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessLists": reflect.TypeOf(IpAccessListInfo{}), + "ip_access_lists": reflect.TypeOf(IpAccessListInfo{}), } } func (a GetIpAccessListsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessLists": basetypes.ListType{ + "ip_access_lists": basetypes.ListType{ ElemType: IpAccessListInfo{}.ToAttrType(ctx), }, }, @@ -2327,7 +2381,7 @@ func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() map[s func (a GetNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkConnectivityConfigId": types.StringType, + "network_connectivity_config_id": types.StringType, }, } } @@ -2350,7 +2404,7 @@ func (a GetNotificationDestinationRequest) GetComplexFieldTypes() map[string]ref func (a GetNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2380,7 +2434,7 @@ func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes() map[string]refl func (a GetPersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2406,8 +2460,8 @@ func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect func (a GetPrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkConnectivityConfigId": types.StringType, - "PrivateEndpointRuleId": types.StringType, + "network_connectivity_config_id": types.StringType, + "private_endpoint_rule_id": types.StringType, }, } } @@ -2437,7 +2491,7 @@ func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[str func (a GetRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, + "etag": types.StringType, }, } } @@ -2460,7 +2514,7 @@ func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Keys": types.StringType, + "keys": types.StringType, }, } } @@ -2484,7 +2538,7 @@ func (a GetTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a GetTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenId": types.StringType, + "token_id": types.StringType, }, } } @@ -2502,14 +2556,14 @@ func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringRead( func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(TokenPermissionsDescription{}), + "permission_levels": reflect.TypeOf(TokenPermissionsDescription{}), } } func (a GetTokenPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: TokenPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -2529,14 +2583,16 @@ func (newState *GetTokenResponse) SyncEffectiveFieldsDuringRead(existingState Ge func (a GetTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenInfo": reflect.TypeOf(TokenInfo{}), + "token_info": reflect.TypeOf(TokenInfo{}), } } func (a GetTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenInfo": TokenInfo{}.ToAttrType(ctx), + "token_info": basetypes.ListType{ + ElemType: TokenInfo{}.ToAttrType(ctx), + }, }, } } @@ -2578,25 +2634,25 @@ func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringRead(existingState Ip func (a IpAccessListInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.StringType), } } func (a IpAccessListInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AddressCount": types.Int64Type, - "CreatedAt": types.Int64Type, - "CreatedBy": types.Int64Type, - "Enabled": types.BoolType, - "IpAddresses": basetypes.ListType{ + "address_count": types.Int64Type, + "created_at": types.Int64Type, + "created_by": types.Int64Type, + "enabled": types.BoolType, + "ip_addresses": basetypes.ListType{ ElemType: types.StringType, }, - "Label": types.StringType, - "ListId": types.StringType, - "ListType": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.Int64Type, + "label": types.StringType, + "list_id": types.StringType, + "list_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.Int64Type, }, } } @@ -2614,14 +2670,14 @@ func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringRead(existing func (a ListIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessLists": reflect.TypeOf(IpAccessListInfo{}), + "ip_access_lists": reflect.TypeOf(IpAccessListInfo{}), } } func (a ListIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IpAccessLists": basetypes.ListType{ + "ip_access_lists": basetypes.ListType{ ElemType: IpAccessListInfo{}.ToAttrType(ctx), }, }, @@ -2643,17 +2699,17 @@ func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDur func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Items": reflect.TypeOf(NccAzurePrivateEndpointRule{}), + "items": reflect.TypeOf(NccAzurePrivateEndpointRule{}), } } func (a ListNccAzurePrivateEndpointRulesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Items": basetypes.ListType{ + "items": basetypes.ListType{ ElemType: NccAzurePrivateEndpointRule{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2677,7 +2733,7 @@ func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes() map func (a ListNetworkConnectivityConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageToken": types.StringType, + "page_token": types.StringType, }, } } @@ -2697,17 +2753,17 @@ func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFiel func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Items": reflect.TypeOf(NetworkConnectivityConfiguration{}), + "items": reflect.TypeOf(NetworkConnectivityConfiguration{}), } } func (a ListNetworkConnectivityConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Items": basetypes.ListType{ + "items": basetypes.ListType{ ElemType: NetworkConnectivityConfiguration{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -2732,8 +2788,8 @@ func (a ListNotificationDestinationsRequest) GetComplexFieldTypes() map[string]r func (a ListNotificationDestinationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -2753,15 +2809,15 @@ func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringR func (a ListNotificationDestinationsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(ListNotificationDestinationsResult{}), + "results": reflect.TypeOf(ListNotificationDestinationsResult{}), } } func (a ListNotificationDestinationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Results": basetypes.ListType{ + "next_page_token": types.StringType, + "results": basetypes.ListType{ ElemType: ListNotificationDestinationsResult{}.ToAttrType(ctx), }, }, @@ -2791,9 +2847,9 @@ func (a ListNotificationDestinationsResult) GetComplexFieldTypes() map[string]re func (a ListNotificationDestinationsResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DestinationType": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, + "destination_type": types.StringType, + "display_name": types.StringType, + "id": types.StringType, }, } } @@ -2819,8 +2875,8 @@ func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes() map[string]refle func (a ListPrivateEndpointRulesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NetworkConnectivityConfigId": types.StringType, - "PageToken": types.StringType, + "network_connectivity_config_id": types.StringType, + "page_token": types.StringType, }, } } @@ -2838,14 +2894,14 @@ func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringRead(existing func (a ListPublicTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenInfos": reflect.TypeOf(PublicTokenInfo{}), + "token_infos": reflect.TypeOf(PublicTokenInfo{}), } } func (a ListPublicTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenInfos": basetypes.ListType{ + "token_infos": basetypes.ListType{ ElemType: PublicTokenInfo{}.ToAttrType(ctx), }, }, @@ -2873,8 +2929,8 @@ func (a ListTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a ListTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedById": types.Int64Type, - "CreatedByUsername": types.StringType, + "created_by_id": types.Int64Type, + "created_by_username": types.StringType, }, } } @@ -2893,14 +2949,14 @@ func (newState *ListTokensResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "TokenInfos": reflect.TypeOf(TokenInfo{}), + "token_infos": reflect.TypeOf(TokenInfo{}), } } func (a ListTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenInfos": basetypes.ListType{ + "token_infos": basetypes.ListType{ ElemType: TokenInfo{}.ToAttrType(ctx), }, }, @@ -2927,8 +2983,8 @@ func (a MicrosoftTeamsConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a MicrosoftTeamsConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Url": types.StringType, - "UrlSet": types.BoolType, + "url": types.StringType, + "url_set": types.BoolType, }, } } @@ -2949,14 +3005,14 @@ func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringRead(existingState func (a NccAwsStableIpRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CidrBlocks": reflect.TypeOf(types.StringType), + "cidr_blocks": reflect.TypeOf(types.StringType), } } func (a NccAwsStableIpRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CidrBlocks": basetypes.ListType{ + "cidr_blocks": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3014,16 +3070,16 @@ func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes() map[string]reflect.T func (a NccAzurePrivateEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConnectionState": types.StringType, - "CreationTime": types.Int64Type, - "Deactivated": types.BoolType, - "DeactivatedAt": types.Int64Type, - "EndpointName": types.StringType, - "GroupId": types.StringType, - "NetworkConnectivityConfigId": types.StringType, - "ResourceId": types.StringType, - "RuleId": types.StringType, - "UpdatedTime": types.Int64Type, + "connection_state": types.StringType, + "creation_time": types.Int64Type, + "deactivated": types.BoolType, + "deactivated_at": types.Int64Type, + "endpoint_name": types.StringType, + "group_id": types.StringType, + "network_connectivity_config_id": types.StringType, + "resource_id": types.StringType, + "rule_id": types.StringType, + "updated_time": types.Int64Type, }, } } @@ -3049,19 +3105,19 @@ func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringRead(exist func (a NccAzureServiceEndpointRule) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Subnets": reflect.TypeOf(types.StringType), - "TargetServices": reflect.TypeOf(types.StringType), + "subnets": reflect.TypeOf(types.StringType), + "target_services": reflect.TypeOf(types.StringType), } } func (a NccAzureServiceEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Subnets": basetypes.ListType{ + "subnets": basetypes.ListType{ ElemType: types.StringType, }, - "TargetRegion": types.StringType, - "TargetServices": basetypes.ListType{ + "target_region": types.StringType, + "target_services": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3088,16 +3144,20 @@ func (newState *NccEgressConfig) SyncEffectiveFieldsDuringRead(existingState Ncc func (a NccEgressConfig) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DefaultRules": reflect.TypeOf(NccEgressDefaultRules{}), - "TargetRules": reflect.TypeOf(NccEgressTargetRules{}), + "default_rules": reflect.TypeOf(NccEgressDefaultRules{}), + "target_rules": reflect.TypeOf(NccEgressTargetRules{}), } } func (a NccEgressConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DefaultRules": NccEgressDefaultRules{}.ToAttrType(ctx), - "TargetRules": NccEgressTargetRules{}.ToAttrType(ctx), + "default_rules": basetypes.ListType{ + ElemType: NccEgressDefaultRules{}.ToAttrType(ctx), + }, + "target_rules": basetypes.ListType{ + ElemType: NccEgressTargetRules{}.ToAttrType(ctx), + }, }, } } @@ -3124,16 +3184,20 @@ func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringRead(existingSta func (a NccEgressDefaultRules) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AwsStableIpRule": reflect.TypeOf(NccAwsStableIpRule{}), - "AzureServiceEndpointRule": reflect.TypeOf(NccAzureServiceEndpointRule{}), + "aws_stable_ip_rule": reflect.TypeOf(NccAwsStableIpRule{}), + "azure_service_endpoint_rule": reflect.TypeOf(NccAzureServiceEndpointRule{}), } } func (a NccEgressDefaultRules) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AwsStableIpRule": NccAwsStableIpRule{}.ToAttrType(ctx), - "AzureServiceEndpointRule": NccAzureServiceEndpointRule{}.ToAttrType(ctx), + "aws_stable_ip_rule": basetypes.ListType{ + ElemType: NccAwsStableIpRule{}.ToAttrType(ctx), + }, + "azure_service_endpoint_rule": basetypes.ListType{ + ElemType: NccAzureServiceEndpointRule{}.ToAttrType(ctx), + }, }, } } @@ -3152,14 +3216,14 @@ func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringRead(existingStat func (a NccEgressTargetRules) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AzurePrivateEndpointRules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), + "azure_private_endpoint_rules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), } } func (a NccEgressTargetRules) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AzurePrivateEndpointRules": basetypes.ListType{ + "azure_private_endpoint_rules": basetypes.ListType{ ElemType: NccAzurePrivateEndpointRule{}.ToAttrType(ctx), }, }, @@ -3197,20 +3261,22 @@ func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringRead( func (a NetworkConnectivityConfiguration) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EgressConfig": reflect.TypeOf(NccEgressConfig{}), + "egress_config": reflect.TypeOf(NccEgressConfig{}), } } func (a NetworkConnectivityConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccountId": types.StringType, - "CreationTime": types.Int64Type, - "EgressConfig": NccEgressConfig{}.ToAttrType(ctx), - "Name": types.StringType, - "NetworkConnectivityConfigId": types.StringType, - "Region": types.StringType, - "UpdatedTime": types.Int64Type, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "egress_config": basetypes.ListType{ + ElemType: NccEgressConfig{}.ToAttrType(ctx), + }, + "name": types.StringType, + "network_connectivity_config_id": types.StringType, + "region": types.StringType, + "updated_time": types.Int64Type, }, } } @@ -3237,17 +3303,19 @@ func (newState *NotificationDestination) SyncEffectiveFieldsDuringRead(existingS func (a NotificationDestination) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Config": reflect.TypeOf(Config{}), + "config": reflect.TypeOf(Config{}), } } func (a NotificationDestination) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Config": Config{}.ToAttrType(ctx), - "DestinationType": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, + "config": basetypes.ListType{ + ElemType: Config{}.ToAttrType(ctx), + }, + "destination_type": types.StringType, + "display_name": types.StringType, + "id": types.StringType, }, } } @@ -3272,8 +3340,8 @@ func (a PagerdutyConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a PagerdutyConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IntegrationKey": types.StringType, - "IntegrationKeySet": types.BoolType, + "integration_key": types.StringType, + "integration_key_set": types.BoolType, }, } } @@ -3297,7 +3365,7 @@ func (a PartitionId) GetComplexFieldTypes() map[string]reflect.Type { func (a PartitionId) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceId": types.Int64Type, + "workspaceId": types.Int64Type, }, } } @@ -3326,7 +3394,7 @@ func (a PersonalComputeMessage) GetComplexFieldTypes() map[string]reflect.Type { func (a PersonalComputeMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Value": types.StringType, + "value": types.StringType, }, } } @@ -3358,16 +3426,18 @@ func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringRead(existingSt func (a PersonalComputeSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PersonalCompute": reflect.TypeOf(PersonalComputeMessage{}), + "personal_compute": reflect.TypeOf(PersonalComputeMessage{}), } } func (a PersonalComputeSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, - "PersonalCompute": PersonalComputeMessage{}.ToAttrType(ctx), - "SettingName": types.StringType, + "etag": types.StringType, + "personal_compute": basetypes.ListType{ + ElemType: PersonalComputeMessage{}.ToAttrType(ctx), + }, + "setting_name": types.StringType, }, } } @@ -3397,10 +3467,10 @@ func (a PublicTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a PublicTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "CreationTime": types.Int64Type, - "ExpiryTime": types.Int64Type, - "TokenId": types.StringType, + "comment": types.StringType, + "creation_time": types.Int64Type, + "expiry_time": types.Int64Type, + "token_id": types.StringType, }, } } @@ -3432,20 +3502,20 @@ func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a ReplaceIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.StringType), } } func (a ReplaceIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, - "IpAccessListId": types.StringType, - "IpAddresses": basetypes.ListType{ + "enabled": types.BoolType, + "ip_access_list_id": types.StringType, + "ip_addresses": basetypes.ListType{ ElemType: types.StringType, }, - "Label": types.StringType, - "ListType": types.StringType, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -3486,7 +3556,7 @@ func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes() map[string]reflec func (a RestrictWorkspaceAdminsMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Status": types.StringType, + "status": types.StringType, }, } } @@ -3518,16 +3588,18 @@ func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringRead(ex func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RestrictWorkspaceAdmins": reflect.TypeOf(RestrictWorkspaceAdminsMessage{}), + "restrict_workspace_admins": reflect.TypeOf(RestrictWorkspaceAdminsMessage{}), } } func (a RestrictWorkspaceAdminsSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Etag": types.StringType, - "RestrictWorkspaceAdmins": RestrictWorkspaceAdminsMessage{}.ToAttrType(ctx), - "SettingName": types.StringType, + "etag": types.StringType, + "restrict_workspace_admins": basetypes.ListType{ + ElemType: RestrictWorkspaceAdminsMessage{}.ToAttrType(ctx), + }, + "setting_name": types.StringType, }, } } @@ -3550,7 +3622,7 @@ func (a RevokeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a RevokeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "TokenId": types.StringType, + "token_id": types.StringType, }, } } @@ -3613,8 +3685,8 @@ func (a SlackConfig) GetComplexFieldTypes() map[string]reflect.Type { func (a SlackConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Url": types.StringType, - "UrlSet": types.BoolType, + "url": types.StringType, + "url_set": types.BoolType, }, } } @@ -3637,7 +3709,7 @@ func (a StringMessage) GetComplexFieldTypes() map[string]reflect.Type { func (a StringMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Value": types.StringType, + "value": types.StringType, }, } } @@ -3666,10 +3738,10 @@ func (a TokenAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a TokenAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -3695,20 +3767,20 @@ func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringRead(existi func (a TokenAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(TokenPermission{}), + "all_permissions": reflect.TypeOf(TokenPermission{}), } } func (a TokenAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: TokenPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -3749,15 +3821,15 @@ func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "CreatedById": types.Int64Type, - "CreatedByUsername": types.StringType, - "CreationTime": types.Int64Type, - "ExpiryTime": types.Int64Type, - "LastUsedDay": types.Int64Type, - "OwnerId": types.Int64Type, - "TokenId": types.StringType, - "WorkspaceId": types.Int64Type, + "comment": types.StringType, + "created_by_id": types.Int64Type, + "created_by_username": types.StringType, + "creation_time": types.Int64Type, + "expiry_time": types.Int64Type, + "last_used_day": types.Int64Type, + "owner_id": types.Int64Type, + "token_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -3778,18 +3850,18 @@ func (newState *TokenPermission) SyncEffectiveFieldsDuringRead(existingState Tok func (a TokenPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a TokenPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -3810,18 +3882,18 @@ func (newState *TokenPermissions) SyncEffectiveFieldsDuringRead(existingState To func (a TokenPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(TokenAccessControlResponse{}), + "access_control_list": reflect.TypeOf(TokenAccessControlResponse{}), } } func (a TokenPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: TokenAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3845,8 +3917,8 @@ func (a TokenPermissionsDescription) GetComplexFieldTypes() map[string]reflect.T func (a TokenPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -3863,14 +3935,14 @@ func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringRead(existingS func (a TokenPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(TokenAccessControlRequest{}), + "access_control_list": reflect.TypeOf(TokenAccessControlRequest{}), } } func (a TokenPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: TokenAccessControlRequest{}.ToAttrType(ctx), }, }, @@ -3899,16 +3971,18 @@ func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffe func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicySetting{}), + "setting": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicySetting{}), } } func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": AibiDashboardEmbeddingAccessPolicySetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.ToAttrType(ctx), + }, }, } } @@ -3935,16 +4009,18 @@ func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncE func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomainsSetting{}), + "setting": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomainsSetting{}), } } func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": AibiDashboardEmbeddingApprovedDomainsSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.ToAttrType(ctx), + }, }, } } @@ -3971,16 +4047,18 @@ func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsD func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(AutomaticClusterUpdateSetting{}), + "setting": reflect.TypeOf(AutomaticClusterUpdateSetting{}), } } func (a UpdateAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": AutomaticClusterUpdateSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: AutomaticClusterUpdateSetting{}.ToAttrType(ctx), + }, }, } } @@ -4007,16 +4085,18 @@ func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFiel func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(ComplianceSecurityProfileSetting{}), + "setting": reflect.TypeOf(ComplianceSecurityProfileSetting{}), } } func (a UpdateComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": ComplianceSecurityProfileSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: ComplianceSecurityProfileSetting{}.ToAttrType(ctx), + }, }, } } @@ -4043,16 +4123,18 @@ func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(CspEnablementAccountSetting{}), + "setting": reflect.TypeOf(CspEnablementAccountSetting{}), } } func (a UpdateCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": CspEnablementAccountSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: CspEnablementAccountSetting{}.ToAttrType(ctx), + }, }, } } @@ -4087,16 +4169,18 @@ func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringR func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(DefaultNamespaceSetting{}), + "setting": reflect.TypeOf(DefaultNamespaceSetting{}), } } func (a UpdateDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": DefaultNamespaceSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: DefaultNamespaceSetting{}.ToAttrType(ctx), + }, }, } } @@ -4123,16 +4207,18 @@ func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead( func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(DisableLegacyAccess{}), + "setting": reflect.TypeOf(DisableLegacyAccess{}), } } func (a UpdateDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": DisableLegacyAccess{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: DisableLegacyAccess{}.ToAttrType(ctx), + }, }, } } @@ -4159,16 +4245,18 @@ func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(ex func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(DisableLegacyDbfs{}), + "setting": reflect.TypeOf(DisableLegacyDbfs{}), } } func (a UpdateDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": DisableLegacyDbfs{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: DisableLegacyDbfs{}.ToAttrType(ctx), + }, }, } } @@ -4195,16 +4283,18 @@ func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRea func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(DisableLegacyFeatures{}), + "setting": reflect.TypeOf(DisableLegacyFeatures{}), } } func (a UpdateDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": DisableLegacyFeatures{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: DisableLegacyFeatures{}.ToAttrType(ctx), + }, }, } } @@ -4231,16 +4321,18 @@ func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFie func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(EnhancedSecurityMonitoringSetting{}), + "setting": reflect.TypeOf(EnhancedSecurityMonitoringSetting{}), } } func (a UpdateEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": EnhancedSecurityMonitoringSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: EnhancedSecurityMonitoringSetting{}.ToAttrType(ctx), + }, }, } } @@ -4267,16 +4359,18 @@ func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(EsmEnablementAccountSetting{}), + "setting": reflect.TypeOf(EsmEnablementAccountSetting{}), } } func (a UpdateEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": EsmEnablementAccountSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: EsmEnablementAccountSetting{}.ToAttrType(ctx), + }, }, } } @@ -4308,20 +4402,20 @@ func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a UpdateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAddresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.StringType), } } func (a UpdateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, - "IpAccessListId": types.StringType, - "IpAddresses": basetypes.ListType{ + "enabled": types.BoolType, + "ip_access_list_id": types.StringType, + "ip_addresses": basetypes.ListType{ ElemType: types.StringType, }, - "Label": types.StringType, - "ListType": types.StringType, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -4344,16 +4438,18 @@ func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringR func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Config": reflect.TypeOf(Config{}), + "config": reflect.TypeOf(Config{}), } } func (a UpdateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Config": Config{}.ToAttrType(ctx), - "DisplayName": types.StringType, - "Id": types.StringType, + "config": basetypes.ListType{ + ElemType: Config{}.ToAttrType(ctx), + }, + "display_name": types.StringType, + "id": types.StringType, }, } } @@ -4380,16 +4476,18 @@ func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRe func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(PersonalComputeSetting{}), + "setting": reflect.TypeOf(PersonalComputeSetting{}), } } func (a UpdatePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": PersonalComputeSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: PersonalComputeSetting{}.ToAttrType(ctx), + }, }, } } @@ -4435,16 +4533,18 @@ func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Setting": reflect.TypeOf(RestrictWorkspaceAdminsSetting{}), + "setting": reflect.TypeOf(RestrictWorkspaceAdminsSetting{}), } } func (a UpdateRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowMissing": types.BoolType, - "FieldMask": types.StringType, - "Setting": RestrictWorkspaceAdminsSetting{}.ToAttrType(ctx), + "allow_missing": types.BoolType, + "field_mask": types.StringType, + "setting": basetypes.ListType{ + ElemType: RestrictWorkspaceAdminsSetting{}.ToAttrType(ctx), + }, }, } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index a0dd929e05..d30ae49365 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -46,10 +46,10 @@ func (a CreateProvider) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateProvider) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AuthenticationType": types.StringType, - "Comment": types.StringType, - "Name": types.StringType, - "RecipientProfileStr": types.StringType, + "authentication_type": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "recipient_profile_str": types.StringType, }, } } @@ -87,23 +87,27 @@ func (newState *CreateRecipient) SyncEffectiveFieldsDuringRead(existingState Cre func (a CreateRecipient) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessList": reflect.TypeOf(IpAccessList{}), - "PropertiesKvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), + "ip_access_list": reflect.TypeOf(IpAccessList{}), + "properties_kvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), } } func (a CreateRecipient) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AuthenticationType": types.StringType, - "Comment": types.StringType, - "DataRecipientGlobalMetastoreId": types.StringType, - "ExpirationTime": types.Int64Type, - "IpAccessList": IpAccessList{}.ToAttrType(ctx), - "Name": types.StringType, - "Owner": types.StringType, - "PropertiesKvpairs": SecurablePropertiesKvPairs{}.ToAttrType(ctx), - "SharingCode": types.StringType, + "authentication_type": types.StringType, + "comment": types.StringType, + "data_recipient_global_metastore_id": types.StringType, + "expiration_time": types.Int64Type, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessList{}.ToAttrType(ctx), + }, + "name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ + ElemType: SecurablePropertiesKvPairs{}.ToAttrType(ctx), + }, + "sharing_code": types.StringType, }, } } @@ -130,9 +134,9 @@ func (a CreateShare) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateShare) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "StorageRoot": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "storage_root": types.StringType, }, } } @@ -156,7 +160,7 @@ func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -180,7 +184,7 @@ func (a DeleteRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -223,7 +227,7 @@ func (a DeleteShareRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteShareRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -247,7 +251,7 @@ func (a GetActivationUrlInfoRequest) GetComplexFieldTypes() map[string]reflect.T func (a GetActivationUrlInfoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActivationUrl": types.StringType, + "activation_url": types.StringType, }, } } @@ -290,7 +294,7 @@ func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -314,7 +318,7 @@ func (a GetRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -336,15 +340,15 @@ func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringR func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionsOut": reflect.TypeOf(ShareToPrivilegeAssignment{}), + "permissions_out": reflect.TypeOf(ShareToPrivilegeAssignment{}), } } func (a GetRecipientSharePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "PermissionsOut": basetypes.ListType{ + "next_page_token": types.StringType, + "permissions_out": basetypes.ListType{ ElemType: ShareToPrivilegeAssignment{}.ToAttrType(ctx), }, }, @@ -372,8 +376,8 @@ func (a GetShareRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetShareRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IncludeSharedData": types.BoolType, - "Name": types.StringType, + "include_shared_data": types.BoolType, + "name": types.StringType, }, } } @@ -391,14 +395,14 @@ func (newState *IpAccessList) SyncEffectiveFieldsDuringRead(existingState IpAcce func (a IpAccessList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllowedIpAddresses": reflect.TypeOf(types.StringType), + "allowed_ip_addresses": reflect.TypeOf(types.StringType), } } func (a IpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllowedIpAddresses": basetypes.ListType{ + "allowed_ip_addresses": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -422,15 +426,15 @@ func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringRead(existi func (a ListProviderSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Shares": reflect.TypeOf(ProviderShare{}), + "shares": reflect.TypeOf(ProviderShare{}), } } func (a ListProviderSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Shares": basetypes.ListType{ + "next_page_token": types.StringType, + "shares": basetypes.ListType{ ElemType: ProviderShare{}.ToAttrType(ctx), }, }, @@ -469,9 +473,9 @@ func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataProviderGlobalMetastoreId": types.StringType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "data_provider_global_metastore_id": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -493,15 +497,15 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingSta func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Providers": reflect.TypeOf(ProviderInfo{}), + "providers": reflect.TypeOf(ProviderInfo{}), } } func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Providers": basetypes.ListType{ + "next_page_token": types.StringType, + "providers": basetypes.ListType{ ElemType: ProviderInfo{}.ToAttrType(ctx), }, }, @@ -540,9 +544,9 @@ func (a ListRecipientsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListRecipientsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataRecipientGlobalMetastoreId": types.StringType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "data_recipient_global_metastore_id": types.StringType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -564,15 +568,15 @@ func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringRead(existingSt func (a ListRecipientsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Recipients": reflect.TypeOf(RecipientInfo{}), + "recipients": reflect.TypeOf(RecipientInfo{}), } } func (a ListRecipientsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Recipients": basetypes.ListType{ + "next_page_token": types.StringType, + "recipients": basetypes.ListType{ ElemType: RecipientInfo{}.ToAttrType(ctx), }, }, @@ -610,9 +614,9 @@ func (a ListSharesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListSharesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "Name": types.StringType, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "name": types.StringType, + "page_token": types.StringType, }, } } @@ -634,15 +638,15 @@ func (newState *ListSharesResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Shares": reflect.TypeOf(ShareInfo{}), + "shares": reflect.TypeOf(ShareInfo{}), } } func (a ListSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Shares": basetypes.ListType{ + "next_page_token": types.StringType, + "shares": basetypes.ListType{ ElemType: ShareInfo{}.ToAttrType(ctx), }, }, @@ -662,14 +666,14 @@ func (newState *Partition) SyncEffectiveFieldsDuringRead(existingState Partition func (a Partition) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(PartitionValue{}), + "value": reflect.TypeOf(PartitionValue{}), } } func (a Partition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Values": basetypes.ListType{ + "value": basetypes.ListType{ ElemType: PartitionValue{}.ToAttrType(ctx), }, }, @@ -704,10 +708,10 @@ func (a PartitionValue) GetComplexFieldTypes() map[string]reflect.Type { func (a PartitionValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Op": types.StringType, - "RecipientPropertyKey": types.StringType, - "Value": types.StringType, + "name": types.StringType, + "op": types.StringType, + "recipient_property_key": types.StringType, + "value": types.StringType, }, } } @@ -727,15 +731,15 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Privileges": reflect.TypeOf(types.StringType), + "privileges": reflect.TypeOf(types.StringType), } } func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Principal": types.StringType, - "Privileges": basetypes.ListType{ + "principal": types.StringType, + "privileges": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -788,27 +792,29 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState Provid func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "RecipientProfile": reflect.TypeOf(RecipientProfile{}), + "recipient_profile": reflect.TypeOf(RecipientProfile{}), } } func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AuthenticationType": types.StringType, - "Cloud": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DataProviderGlobalMetastoreId": types.StringType, - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "RecipientProfile": RecipientProfile{}.ToAttrType(ctx), - "RecipientProfileStr": types.StringType, - "Region": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "authentication_type": types.StringType, + "cloud": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_provider_global_metastore_id": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "recipient_profile": basetypes.ListType{ + ElemType: RecipientProfile{}.ToAttrType(ctx), + }, + "recipient_profile_str": types.StringType, + "region": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -831,7 +837,7 @@ func (a ProviderShare) GetComplexFieldTypes() map[string]reflect.Type { func (a ProviderShare) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -892,35 +898,39 @@ func (newState *RecipientInfo) SyncEffectiveFieldsDuringRead(existingState Recip func (a RecipientInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessList": reflect.TypeOf(IpAccessList{}), - "PropertiesKvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), - "Tokens": reflect.TypeOf(RecipientTokenInfo{}), + "ip_access_list": reflect.TypeOf(IpAccessList{}), + "properties_kvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), + "tokens": reflect.TypeOf(RecipientTokenInfo{}), } } func (a RecipientInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Activated": types.BoolType, - "ActivationUrl": types.StringType, - "AuthenticationType": types.StringType, - "Cloud": types.StringType, - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "DataRecipientGlobalMetastoreId": types.StringType, - "IpAccessList": IpAccessList{}.ToAttrType(ctx), - "MetastoreId": types.StringType, - "Name": types.StringType, - "Owner": types.StringType, - "PropertiesKvpairs": SecurablePropertiesKvPairs{}.ToAttrType(ctx), - "Region": types.StringType, - "SharingCode": types.StringType, - "Tokens": basetypes.ListType{ + "activated": types.BoolType, + "activation_url": types.StringType, + "authentication_type": types.StringType, + "cloud": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_recipient_global_metastore_id": types.StringType, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessList{}.ToAttrType(ctx), + }, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ + ElemType: SecurablePropertiesKvPairs{}.ToAttrType(ctx), + }, + "region": types.StringType, + "sharing_code": types.StringType, + "tokens": basetypes.ListType{ ElemType: RecipientTokenInfo{}.ToAttrType(ctx), }, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -947,9 +957,9 @@ func (a RecipientProfile) GetComplexFieldTypes() map[string]reflect.Type { func (a RecipientProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BearerToken": types.StringType, - "Endpoint": types.StringType, - "ShareCredentialsVersion": types.Int64Type, + "bearer_token": types.StringType, + "endpoint": types.StringType, + "share_credentials_version": types.Int64Type, }, } } @@ -985,13 +995,13 @@ func (a RecipientTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a RecipientTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActivationUrl": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "ExpirationTime": types.Int64Type, - "Id": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "activation_url": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "expiration_time": types.Int64Type, + "id": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1015,7 +1025,7 @@ func (a RetrieveTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a RetrieveTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ActivationUrl": types.StringType, + "activation_url": types.StringType, }, } } @@ -1044,10 +1054,10 @@ func (a RetrieveTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a RetrieveTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BearerToken": types.StringType, - "Endpoint": types.StringType, - "ExpirationTime": types.StringType, - "ShareCredentialsVersion": types.Int64Type, + "bearerToken": types.StringType, + "endpoint": types.StringType, + "expirationTime": types.StringType, + "shareCredentialsVersion": types.Int64Type, }, } } @@ -1075,8 +1085,8 @@ func (a RotateRecipientToken) GetComplexFieldTypes() map[string]reflect.Type { func (a RotateRecipientToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ExistingTokenExpireInSeconds": types.Int64Type, - "Name": types.StringType, + "existing_token_expire_in_seconds": types.Int64Type, + "name": types.StringType, }, } } @@ -1096,14 +1106,14 @@ func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existi func (a SecurablePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.StringType), } } func (a SecurablePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Properties": basetypes.MapType{ + "properties": basetypes.MapType{ ElemType: types.StringType, }, }, @@ -1141,25 +1151,25 @@ func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Objects": reflect.TypeOf(SharedDataObject{}), + "object": reflect.TypeOf(SharedDataObject{}), } } func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "CreatedAt": types.Int64Type, - "CreatedBy": types.StringType, - "Name": types.StringType, - "Objects": basetypes.ListType{ + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "name": types.StringType, + "object": basetypes.ListType{ ElemType: SharedDataObject{}.ToAttrType(ctx), }, - "Owner": types.StringType, - "StorageLocation": types.StringType, - "StorageRoot": types.StringType, - "UpdatedAt": types.Int64Type, - "UpdatedBy": types.StringType, + "owner": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1195,9 +1205,9 @@ func (a SharePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a SharePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MaxResults": types.Int64Type, - "Name": types.StringType, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "name": types.StringType, + "page_token": types.StringType, }, } } @@ -1217,17 +1227,17 @@ func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringRead(existi func (a ShareToPrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrivilegeAssignments": reflect.TypeOf(PrivilegeAssignment{}), + "privilege_assignments": reflect.TypeOf(PrivilegeAssignment{}), } } func (a ShareToPrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PrivilegeAssignments": basetypes.ListType{ + "privilege_assignments": basetypes.ListType{ ElemType: PrivilegeAssignment{}.ToAttrType(ctx), }, - "ShareName": types.StringType, + "share_name": types.StringType, }, } } @@ -1290,28 +1300,28 @@ func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState Sh func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Partitions": reflect.TypeOf(Partition{}), + "partition": reflect.TypeOf(Partition{}), } } func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AddedAt": types.Int64Type, - "AddedBy": types.StringType, - "CdfEnabled": types.BoolType, - "Comment": types.StringType, - "Content": types.StringType, - "DataObjectType": types.StringType, - "HistoryDataSharingStatus": types.StringType, - "Name": types.StringType, - "Partitions": basetypes.ListType{ + "added_at": types.Int64Type, + "added_by": types.StringType, + "cdf_enabled": types.BoolType, + "comment": types.StringType, + "content": types.StringType, + "data_object_type": types.StringType, + "history_data_sharing_status": types.StringType, + "name": types.StringType, + "partition": basetypes.ListType{ ElemType: Partition{}.ToAttrType(ctx), }, - "SharedAs": types.StringType, - "StartVersion": types.Int64Type, - "Status": types.StringType, - "StringSharedAs": types.StringType, + "shared_as": types.StringType, + "start_version": types.Int64Type, + "status": types.StringType, + "string_shared_as": types.StringType, }, } } @@ -1331,15 +1341,17 @@ func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringRead(existingSt func (a SharedDataObjectUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataObject": reflect.TypeOf(SharedDataObject{}), + "data_object": reflect.TypeOf(SharedDataObject{}), } } func (a SharedDataObjectUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Action": types.StringType, - "DataObject": SharedDataObject{}.ToAttrType(ctx), + "action": types.StringType, + "data_object": basetypes.ListType{ + ElemType: SharedDataObject{}.ToAttrType(ctx), + }, }, } } @@ -1390,11 +1402,11 @@ func (a UpdateProvider) GetComplexFieldTypes() map[string]reflect.Type { func (a UpdateProvider) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "RecipientProfileStr": types.StringType, + "comment": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "recipient_profile_str": types.StringType, }, } } @@ -1427,21 +1439,25 @@ func (newState *UpdateRecipient) SyncEffectiveFieldsDuringRead(existingState Upd func (a UpdateRecipient) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "IpAccessList": reflect.TypeOf(IpAccessList{}), - "PropertiesKvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), + "ip_access_list": reflect.TypeOf(IpAccessList{}), + "properties_kvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), } } func (a UpdateRecipient) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "ExpirationTime": types.Int64Type, - "IpAccessList": IpAccessList{}.ToAttrType(ctx), - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "PropertiesKvpairs": SecurablePropertiesKvPairs{}.ToAttrType(ctx), + "comment": types.StringType, + "expiration_time": types.Int64Type, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessList{}.ToAttrType(ctx), + }, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ + ElemType: SecurablePropertiesKvPairs{}.ToAttrType(ctx), + }, }, } } @@ -1488,19 +1504,19 @@ func (newState *UpdateShare) SyncEffectiveFieldsDuringRead(existingState UpdateS func (a UpdateShare) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Updates": reflect.TypeOf(SharedDataObjectUpdate{}), + "updates": reflect.TypeOf(SharedDataObjectUpdate{}), } } func (a UpdateShare) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Comment": types.StringType, - "Name": types.StringType, - "NewName": types.StringType, - "Owner": types.StringType, - "StorageRoot": types.StringType, - "Updates": basetypes.ListType{ + "comment": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "storage_root": types.StringType, + "updates": basetypes.ListType{ ElemType: SharedDataObjectUpdate{}.ToAttrType(ctx), }, }, @@ -1534,19 +1550,19 @@ func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateSharePermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Changes": reflect.TypeOf(catalog.PermissionsChange{}), + "changes": reflect.TypeOf(catalog.PermissionsChange{}), } } func (a UpdateSharePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Changes": basetypes.ListType{ + "changes": basetypes.ListType{ ElemType: catalog_tf.PermissionsChange{}.ToAttrType(ctx), }, - "MaxResults": types.Int64Type, - "Name": types.StringType, - "PageToken": types.StringType, + "max_results": types.Int64Type, + "name": types.StringType, + "page_token": types.StringType, }, } } diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 6f3895f377..927a68b3fb 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -41,9 +41,9 @@ func (a AccessControl) GetComplexFieldTypes() map[string]reflect.Type { func (a AccessControl) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "user_name": types.StringType, }, } } @@ -102,28 +102,30 @@ func (newState *Alert) SyncEffectiveFieldsDuringRead(existingState Alert) { func (a Alert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Condition": reflect.TypeOf(AlertCondition{}), + "condition": reflect.TypeOf(AlertCondition{}), } } func (a Alert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Condition": AlertCondition{}.ToAttrType(ctx), - "CreateTime": types.StringType, - "CustomBody": types.StringType, - "CustomSubject": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, - "LifecycleState": types.StringType, - "NotifyOnOk": types.BoolType, - "OwnerUserName": types.StringType, - "ParentPath": types.StringType, - "QueryId": types.StringType, - "SecondsToRetrigger": types.Int64Type, - "State": types.StringType, - "TriggerTime": types.StringType, - "UpdateTime": types.StringType, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.ToAttrType(ctx), + }, + "create_time": types.StringType, + "custom_body": types.StringType, + "custom_subject": types.StringType, + "display_name": types.StringType, + "id": types.StringType, + "lifecycle_state": types.StringType, + "notify_on_ok": types.BoolType, + "owner_user_name": types.StringType, + "parent_path": types.StringType, + "query_id": types.StringType, + "seconds_to_retrigger": types.Int64Type, + "state": types.StringType, + "trigger_time": types.StringType, + "update_time": types.StringType, }, } } @@ -148,18 +150,22 @@ func (newState *AlertCondition) SyncEffectiveFieldsDuringRead(existingState Aler func (a AlertCondition) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Operand": reflect.TypeOf(AlertConditionOperand{}), - "Threshold": reflect.TypeOf(AlertConditionThreshold{}), + "operand": reflect.TypeOf(AlertConditionOperand{}), + "threshold": reflect.TypeOf(AlertConditionThreshold{}), } } func (a AlertCondition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EmptyResultState": types.StringType, - "Op": types.StringType, - "Operand": AlertConditionOperand{}.ToAttrType(ctx), - "Threshold": AlertConditionThreshold{}.ToAttrType(ctx), + "empty_result_state": types.StringType, + "op": types.StringType, + "operand": basetypes.ListType{ + ElemType: AlertConditionOperand{}.ToAttrType(ctx), + }, + "threshold": basetypes.ListType{ + ElemType: AlertConditionThreshold{}.ToAttrType(ctx), + }, }, } } @@ -176,14 +182,16 @@ func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringRead(existingSta func (a AlertConditionOperand) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Column": reflect.TypeOf(AlertOperandColumn{}), + "column": reflect.TypeOf(AlertOperandColumn{}), } } func (a AlertConditionOperand) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Column": AlertOperandColumn{}.ToAttrType(ctx), + "column": basetypes.ListType{ + ElemType: AlertOperandColumn{}.ToAttrType(ctx), + }, }, } } @@ -200,14 +208,16 @@ func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringRead(existingS func (a AlertConditionThreshold) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Value": reflect.TypeOf(AlertOperandValue{}), + "value": reflect.TypeOf(AlertOperandValue{}), } } func (a AlertConditionThreshold) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Value": AlertOperandValue{}.ToAttrType(ctx), + "value": basetypes.ListType{ + ElemType: AlertOperandValue{}.ToAttrType(ctx), + }, }, } } @@ -229,7 +239,7 @@ func (a AlertOperandColumn) GetComplexFieldTypes() map[string]reflect.Type { func (a AlertOperandColumn) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -255,9 +265,9 @@ func (a AlertOperandValue) GetComplexFieldTypes() map[string]reflect.Type { func (a AlertOperandValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BoolValue": types.BoolType, - "DoubleValue": types.Float64Type, - "StringValue": types.StringType, + "bool_value": types.BoolType, + "double_value": types.Float64Type, + "string_value": types.StringType, }, } } @@ -303,13 +313,13 @@ func (a AlertOptions) GetComplexFieldTypes() map[string]reflect.Type { func (a AlertOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Column": types.StringType, - "CustomBody": types.StringType, - "CustomSubject": types.StringType, - "EmptyResultState": types.StringType, - "Muted": types.BoolType, - "Op": types.StringType, - "Value": types.ObjectType{}, + "column": types.StringType, + "custom_body": types.StringType, + "custom_subject": types.StringType, + "empty_result_state": types.StringType, + "muted": types.BoolType, + "op": types.StringType, + "value": types.ObjectType{}, }, } } @@ -364,29 +374,31 @@ func (newState *AlertQuery) SyncEffectiveFieldsDuringRead(existingState AlertQue func (a AlertQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(QueryOptions{}), - "Tags": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(QueryOptions{}), + "tags": reflect.TypeOf(types.StringType), } } func (a AlertQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.StringType, - "DataSourceId": types.StringType, - "Description": types.StringType, - "Id": types.StringType, - "IsArchived": types.BoolType, - "IsDraft": types.BoolType, - "IsSafe": types.BoolType, - "Name": types.StringType, - "Options": QueryOptions{}.ToAttrType(ctx), - "Query": types.StringType, - "Tags": basetypes.ListType{ + "created_at": types.StringType, + "data_source_id": types.StringType, + "description": types.StringType, + "id": types.StringType, + "is_archived": types.BoolType, + "is_draft": types.BoolType, + "is_safe": types.BoolType, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: QueryOptions{}.ToAttrType(ctx), + }, + "query": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "UpdatedAt": types.StringType, - "UserId": types.Int64Type, + "updated_at": types.StringType, + "user_id": types.Int64Type, }, } } @@ -419,10 +431,10 @@ func (a BaseChunkInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a BaseChunkInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ByteCount": types.Int64Type, - "ChunkIndex": types.Int64Type, - "RowCount": types.Int64Type, - "RowOffset": types.Int64Type, + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "row_count": types.Int64Type, + "row_offset": types.Int64Type, }, } } @@ -447,7 +459,7 @@ func (a CancelExecutionRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a CancelExecutionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StatementId": types.StringType, + "statement_id": types.StringType, }, } } @@ -492,8 +504,8 @@ func (a Channel) GetComplexFieldTypes() map[string]reflect.Type { func (a Channel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbsqlVersion": types.StringType, - "Name": types.StringType, + "dbsql_version": types.StringType, + "name": types.StringType, }, } } @@ -519,8 +531,8 @@ func (a ChannelInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ChannelInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DbsqlVersion": types.StringType, - "Name": types.StringType, + "dbsql_version": types.StringType, + "name": types.StringType, }, } } @@ -558,13 +570,13 @@ func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Position": types.Int64Type, - "TypeIntervalType": types.StringType, - "TypeName": types.StringType, - "TypePrecision": types.Int64Type, - "TypeScale": types.Int64Type, - "TypeText": types.StringType, + "name": types.StringType, + "position": types.Int64Type, + "type_interval_type": types.StringType, + "type_name": types.StringType, + "type_precision": types.Int64Type, + "type_scale": types.Int64Type, + "type_text": types.StringType, }, } } @@ -592,18 +604,20 @@ func (newState *CreateAlert) SyncEffectiveFieldsDuringRead(existingState CreateA func (a CreateAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(AlertOptions{}), + "options": reflect.TypeOf(AlertOptions{}), } } func (a CreateAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Options": AlertOptions{}.ToAttrType(ctx), - "Parent": types.StringType, - "QueryId": types.StringType, - "Rearm": types.Int64Type, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: AlertOptions{}.ToAttrType(ctx), + }, + "parent": types.StringType, + "query_id": types.StringType, + "rearm": types.Int64Type, }, } } @@ -620,14 +634,16 @@ func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringRead(existingState func (a CreateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Alert": reflect.TypeOf(CreateAlertRequestAlert{}), + "alert": reflect.TypeOf(CreateAlertRequestAlert{}), } } func (a CreateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alert": CreateAlertRequestAlert{}.ToAttrType(ctx), + "alert": basetypes.ListType{ + ElemType: CreateAlertRequestAlert{}.ToAttrType(ctx), + }, }, } } @@ -668,21 +684,23 @@ func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingS func (a CreateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Condition": reflect.TypeOf(AlertCondition{}), + "condition": reflect.TypeOf(AlertCondition{}), } } func (a CreateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Condition": AlertCondition{}.ToAttrType(ctx), - "CustomBody": types.StringType, - "CustomSubject": types.StringType, - "DisplayName": types.StringType, - "NotifyOnOk": types.BoolType, - "ParentPath": types.StringType, - "QueryId": types.StringType, - "SecondsToRetrigger": types.Int64Type, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.ToAttrType(ctx), + }, + "custom_body": types.StringType, + "custom_subject": types.StringType, + "display_name": types.StringType, + "notify_on_ok": types.BoolType, + "parent_path": types.StringType, + "query_id": types.StringType, + "seconds_to_retrigger": types.Int64Type, }, } } @@ -699,14 +717,16 @@ func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringRead(existingState func (a CreateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Query": reflect.TypeOf(CreateQueryRequestQuery{}), + "query": reflect.TypeOf(CreateQueryRequestQuery{}), } } func (a CreateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Query": CreateQueryRequestQuery{}.ToAttrType(ctx), + "query": basetypes.ListType{ + ElemType: CreateQueryRequestQuery{}.ToAttrType(ctx), + }, }, } } @@ -746,29 +766,29 @@ func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingS func (a CreateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(QueryParameter{}), + "tags": reflect.TypeOf(types.StringType), } } func (a CreateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyAutoLimit": types.BoolType, - "Catalog": types.StringType, - "Description": types.StringType, - "DisplayName": types.StringType, - "Parameters": basetypes.ListType{ + "apply_auto_limit": types.BoolType, + "catalog": types.StringType, + "description": types.StringType, + "display_name": types.StringType, + "parameters": basetypes.ListType{ ElemType: QueryParameter{}.ToAttrType(ctx), }, - "ParentPath": types.StringType, - "QueryText": types.StringType, - "RunAsMode": types.StringType, - "Schema": types.StringType, - "Tags": basetypes.ListType{ + "parent_path": types.StringType, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -804,11 +824,11 @@ func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[strin func (a CreateQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "Name": types.StringType, - "Options": types.ObjectType{}, - "QueryId": types.StringType, - "Type": types.StringType, + "description": types.StringType, + "name": types.StringType, + "options": types.ObjectType{}, + "query_id": types.StringType, + "type": types.StringType, }, } } @@ -825,14 +845,16 @@ func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringRead(existi func (a CreateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Visualization": reflect.TypeOf(CreateVisualizationRequestVisualization{}), + "visualization": reflect.TypeOf(CreateVisualizationRequestVisualization{}), } } func (a CreateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Visualization": CreateVisualizationRequestVisualization{}.ToAttrType(ctx), + "visualization": basetypes.ListType{ + ElemType: CreateVisualizationRequestVisualization{}.ToAttrType(ctx), + }, }, } } @@ -867,11 +889,11 @@ func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes() map[stri func (a CreateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "QueryId": types.StringType, - "SerializedOptions": types.StringType, - "SerializedQueryPlan": types.StringType, - "Type": types.StringType, + "display_name": types.StringType, + "query_id": types.StringType, + "serialized_options": types.StringType, + "serialized_query_plan": types.StringType, + "type": types.StringType, }, } } @@ -948,27 +970,31 @@ func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringRead(existingSt func (a CreateWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Channel": reflect.TypeOf(Channel{}), - "Tags": reflect.TypeOf(EndpointTags{}), + "channel": reflect.TypeOf(Channel{}), + "tags": reflect.TypeOf(EndpointTags{}), } } func (a CreateWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoStopMins": types.Int64Type, - "Channel": Channel{}.ToAttrType(ctx), - "ClusterSize": types.StringType, - "CreatorName": types.StringType, - "EnablePhoton": types.BoolType, - "EnableServerlessCompute": types.BoolType, - "InstanceProfileArn": types.StringType, - "MaxNumClusters": types.Int64Type, - "MinNumClusters": types.Int64Type, - "Name": types.StringType, - "SpotInstancePolicy": types.StringType, - "Tags": EndpointTags{}.ToAttrType(ctx), - "WarehouseType": types.StringType, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.ToAttrType(ctx), + }, + "cluster_size": types.StringType, + "creator_name": types.StringType, + "enable_photon": types.BoolType, + "enable_serverless_compute": types.BoolType, + "instance_profile_arn": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "spot_instance_policy": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.ToAttrType(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -991,7 +1017,7 @@ func (a CreateWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type func (a CreateWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1021,19 +1047,21 @@ func (newState *CreateWidget) SyncEffectiveFieldsDuringRead(existingState Create func (a CreateWidget) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(WidgetOptions{}), + "options": reflect.TypeOf(WidgetOptions{}), } } func (a CreateWidget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Id": types.StringType, - "Options": WidgetOptions{}.ToAttrType(ctx), - "Text": types.StringType, - "VisualizationId": types.StringType, - "Width": types.Int64Type, + "dashboard_id": types.StringType, + "id": types.StringType, + "options": basetypes.ListType{ + ElemType: WidgetOptions{}.ToAttrType(ctx), + }, + "text": types.StringType, + "visualization_id": types.StringType, + "width": types.Int64Type, }, } } @@ -1095,35 +1123,39 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(DashboardOptions{}), - "Tags": reflect.TypeOf(types.StringType), - "User": reflect.TypeOf(User{}), - "Widgets": reflect.TypeOf(Widget{}), + "options": reflect.TypeOf(DashboardOptions{}), + "tags": reflect.TypeOf(types.StringType), + "user": reflect.TypeOf(User{}), + "widgets": reflect.TypeOf(Widget{}), } } func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CanEdit": types.BoolType, - "CreatedAt": types.StringType, - "DashboardFiltersEnabled": types.BoolType, - "Id": types.StringType, - "IsArchived": types.BoolType, - "IsDraft": types.BoolType, - "IsFavorite": types.BoolType, - "Name": types.StringType, - "Options": DashboardOptions{}.ToAttrType(ctx), - "Parent": types.StringType, - "PermissionTier": types.StringType, - "Slug": types.StringType, - "Tags": basetypes.ListType{ + "can_edit": types.BoolType, + "created_at": types.StringType, + "dashboard_filters_enabled": types.BoolType, + "id": types.StringType, + "is_archived": types.BoolType, + "is_draft": types.BoolType, + "is_favorite": types.BoolType, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: DashboardOptions{}.ToAttrType(ctx), + }, + "parent": types.StringType, + "permission_tier": types.StringType, + "slug": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "UpdatedAt": types.StringType, - "User": User{}.ToAttrType(ctx), - "UserId": types.Int64Type, - "Widgets": basetypes.ListType{ + "updated_at": types.StringType, + "user": basetypes.ListType{ + ElemType: User{}.ToAttrType(ctx), + }, + "user_id": types.Int64Type, + "widgets": basetypes.ListType{ ElemType: Widget{}.ToAttrType(ctx), }, }, @@ -1151,17 +1183,17 @@ func (newState *DashboardEditContent) SyncEffectiveFieldsDuringRead(existingStat func (a DashboardEditContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.StringType), } } func (a DashboardEditContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, - "Name": types.StringType, - "RunAsRole": types.StringType, - "Tags": basetypes.ListType{ + "dashboard_id": types.StringType, + "name": types.StringType, + "run_as_role": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1188,7 +1220,7 @@ func (a DashboardOptions) GetComplexFieldTypes() map[string]reflect.Type { func (a DashboardOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MovedToTrashAt": types.StringType, + "moved_to_trash_at": types.StringType, }, } } @@ -1220,19 +1252,19 @@ func (newState *DashboardPostContent) SyncEffectiveFieldsDuringRead(existingStat func (a DashboardPostContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.StringType), } } func (a DashboardPostContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardFiltersEnabled": types.BoolType, - "IsFavorite": types.BoolType, - "Name": types.StringType, - "Parent": types.StringType, - "RunAsRole": types.StringType, - "Tags": basetypes.ListType{ + "dashboard_filters_enabled": types.BoolType, + "is_favorite": types.BoolType, + "name": types.StringType, + "parent": types.StringType, + "run_as_role": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1280,15 +1312,15 @@ func (a DataSource) GetComplexFieldTypes() map[string]reflect.Type { func (a DataSource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Name": types.StringType, - "PauseReason": types.StringType, - "Paused": types.Int64Type, - "SupportsAutoLimit": types.BoolType, - "Syntax": types.StringType, - "Type": types.StringType, - "ViewOnly": types.BoolType, - "WarehouseId": types.StringType, + "id": types.StringType, + "name": types.StringType, + "pause_reason": types.StringType, + "paused": types.Int64Type, + "supports_auto_limit": types.BoolType, + "syntax": types.StringType, + "type": types.StringType, + "view_only": types.BoolType, + "warehouse_id": types.StringType, }, } } @@ -1312,8 +1344,8 @@ func (a DateRange) GetComplexFieldTypes() map[string]reflect.Type { func (a DateRange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "End": types.StringType, - "Start": types.StringType, + "end": types.StringType, + "start": types.StringType, }, } } @@ -1338,17 +1370,19 @@ func (newState *DateRangeValue) SyncEffectiveFieldsDuringRead(existingState Date func (a DateRangeValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DateRangeValue": reflect.TypeOf(DateRange{}), + "date_range_value": reflect.TypeOf(DateRange{}), } } func (a DateRangeValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DateRangeValue": DateRange{}.ToAttrType(ctx), - "DynamicDateRangeValue": types.StringType, - "Precision": types.StringType, - "StartDayOfWeek": types.Int64Type, + "date_range_value": basetypes.ListType{ + ElemType: DateRange{}.ToAttrType(ctx), + }, + "dynamic_date_range_value": types.StringType, + "precision": types.StringType, + "start_day_of_week": types.Int64Type, }, } } @@ -1376,9 +1410,9 @@ func (a DateValue) GetComplexFieldTypes() map[string]reflect.Type { func (a DateValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DateValue": types.StringType, - "DynamicDateValue": types.StringType, - "Precision": types.StringType, + "date_value": types.StringType, + "dynamic_date_value": types.StringType, + "precision": types.StringType, }, } } @@ -1401,7 +1435,7 @@ func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a DeleteAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertId": types.StringType, + "alert_id": types.StringType, }, } } @@ -1424,7 +1458,7 @@ func (a DeleteDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -1448,7 +1482,7 @@ func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes() map[string]reflect. func (a DeleteDashboardWidgetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1471,7 +1505,7 @@ func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a DeleteQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueryId": types.StringType, + "query_id": types.StringType, }, } } @@ -1495,7 +1529,7 @@ func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[strin func (a DeleteQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1537,7 +1571,7 @@ func (a DeleteVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Ty func (a DeleteVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1561,7 +1595,7 @@ func (a DeleteWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -1607,18 +1641,20 @@ func (newState *EditAlert) SyncEffectiveFieldsDuringRead(existingState EditAlert func (a EditAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(AlertOptions{}), + "options": reflect.TypeOf(AlertOptions{}), } } func (a EditAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertId": types.StringType, - "Name": types.StringType, - "Options": AlertOptions{}.ToAttrType(ctx), - "QueryId": types.StringType, - "Rearm": types.Int64Type, + "alert_id": types.StringType, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: AlertOptions{}.ToAttrType(ctx), + }, + "query_id": types.StringType, + "rearm": types.Int64Type, }, } } @@ -1695,28 +1731,32 @@ func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringRead(existingStat func (a EditWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Channel": reflect.TypeOf(Channel{}), - "Tags": reflect.TypeOf(EndpointTags{}), + "channel": reflect.TypeOf(Channel{}), + "tags": reflect.TypeOf(EndpointTags{}), } } func (a EditWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoStopMins": types.Int64Type, - "Channel": Channel{}.ToAttrType(ctx), - "ClusterSize": types.StringType, - "CreatorName": types.StringType, - "EnablePhoton": types.BoolType, - "EnableServerlessCompute": types.BoolType, - "Id": types.StringType, - "InstanceProfileArn": types.StringType, - "MaxNumClusters": types.Int64Type, - "MinNumClusters": types.Int64Type, - "Name": types.StringType, - "SpotInstancePolicy": types.StringType, - "Tags": EndpointTags{}.ToAttrType(ctx), - "WarehouseType": types.StringType, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.ToAttrType(ctx), + }, + "cluster_size": types.StringType, + "creator_name": types.StringType, + "enable_photon": types.BoolType, + "enable_serverless_compute": types.BoolType, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "spot_instance_policy": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.ToAttrType(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -1780,8 +1820,8 @@ func (a EndpointConfPair) GetComplexFieldTypes() map[string]reflect.Type { func (a EndpointConfPair) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -1809,18 +1849,20 @@ func (newState *EndpointHealth) SyncEffectiveFieldsDuringRead(existingState Endp func (a EndpointHealth) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FailureReason": reflect.TypeOf(TerminationReason{}), + "failure_reason": reflect.TypeOf(TerminationReason{}), } } func (a EndpointHealth) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Details": types.StringType, - "FailureReason": TerminationReason{}.ToAttrType(ctx), - "Message": types.StringType, - "Status": types.StringType, - "Summary": types.StringType, + "details": types.StringType, + "failure_reason": basetypes.ListType{ + ElemType: TerminationReason{}.ToAttrType(ctx), + }, + "message": types.StringType, + "status": types.StringType, + "summary": types.StringType, }, } } @@ -1910,36 +1952,44 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState Endpoi func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Channel": reflect.TypeOf(Channel{}), - "Health": reflect.TypeOf(EndpointHealth{}), - "OdbcParams": reflect.TypeOf(OdbcParams{}), - "Tags": reflect.TypeOf(EndpointTags{}), + "channel": reflect.TypeOf(Channel{}), + "health": reflect.TypeOf(EndpointHealth{}), + "odbc_params": reflect.TypeOf(OdbcParams{}), + "tags": reflect.TypeOf(EndpointTags{}), } } func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoStopMins": types.Int64Type, - "Channel": Channel{}.ToAttrType(ctx), - "ClusterSize": types.StringType, - "CreatorName": types.StringType, - "EnablePhoton": types.BoolType, - "EnableServerlessCompute": types.BoolType, - "Health": EndpointHealth{}.ToAttrType(ctx), - "Id": types.StringType, - "InstanceProfileArn": types.StringType, - "JdbcUrl": types.StringType, - "MaxNumClusters": types.Int64Type, - "MinNumClusters": types.Int64Type, - "Name": types.StringType, - "NumActiveSessions": types.Int64Type, - "NumClusters": types.Int64Type, - "OdbcParams": OdbcParams{}.ToAttrType(ctx), - "SpotInstancePolicy": types.StringType, - "State": types.StringType, - "Tags": EndpointTags{}.ToAttrType(ctx), - "WarehouseType": types.StringType, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.ToAttrType(ctx), + }, + "cluster_size": types.StringType, + "creator_name": types.StringType, + "enable_photon": types.BoolType, + "enable_serverless_compute": types.BoolType, + "health": basetypes.ListType{ + ElemType: EndpointHealth{}.ToAttrType(ctx), + }, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "jdbc_url": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "num_active_sessions": types.Int64Type, + "num_clusters": types.Int64Type, + "odbc_params": basetypes.ListType{ + ElemType: OdbcParams{}.ToAttrType(ctx), + }, + "spot_instance_policy": types.StringType, + "state": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.ToAttrType(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -1963,8 +2013,8 @@ func (a EndpointTagPair) GetComplexFieldTypes() map[string]reflect.Type { func (a EndpointTagPair) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -1981,14 +2031,14 @@ func (newState *EndpointTags) SyncEffectiveFieldsDuringRead(existingState Endpoi func (a EndpointTags) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "CustomTags": reflect.TypeOf(EndpointTagPair{}), + "custom_tags": reflect.TypeOf(EndpointTagPair{}), } } func (a EndpointTags) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CustomTags": basetypes.ListType{ + "custom_tags": basetypes.ListType{ ElemType: EndpointTagPair{}.ToAttrType(ctx), }, }, @@ -2012,17 +2062,19 @@ func (newState *EnumValue) SyncEffectiveFieldsDuringRead(existingState EnumValue func (a EnumValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), - "Values": reflect.TypeOf(types.StringType), + "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), + "values": reflect.TypeOf(types.StringType), } } func (a EnumValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EnumOptions": types.StringType, - "MultiValuesOptions": MultiValuesOptions{}.ToAttrType(ctx), - "Values": basetypes.ListType{ + "enum_options": types.StringType, + "multi_values_options": basetypes.ListType{ + ElemType: MultiValuesOptions{}.ToAttrType(ctx), + }, + "values": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -2163,26 +2215,26 @@ func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringRead(existingS func (a ExecuteStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(StatementParameterListItem{}), + "parameters": reflect.TypeOf(StatementParameterListItem{}), } } func (a ExecuteStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ByteLimit": types.Int64Type, - "Catalog": types.StringType, - "Disposition": types.StringType, - "Format": types.StringType, - "OnWaitTimeout": types.StringType, - "Parameters": basetypes.ListType{ + "byte_limit": types.Int64Type, + "catalog": types.StringType, + "disposition": types.StringType, + "format": types.StringType, + "on_wait_timeout": types.StringType, + "parameters": basetypes.ListType{ ElemType: StatementParameterListItem{}.ToAttrType(ctx), }, - "RowLimit": types.Int64Type, - "Schema": types.StringType, - "Statement": types.StringType, - "WaitTimeout": types.StringType, - "WarehouseId": types.StringType, + "row_limit": types.Int64Type, + "schema": types.StringType, + "statement": types.StringType, + "wait_timeout": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -2228,24 +2280,24 @@ func (newState *ExternalLink) SyncEffectiveFieldsDuringRead(existingState Extern func (a ExternalLink) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "HttpHeaders": reflect.TypeOf(types.StringType), + "http_headers": reflect.TypeOf(types.StringType), } } func (a ExternalLink) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ByteCount": types.Int64Type, - "ChunkIndex": types.Int64Type, - "Expiration": types.StringType, - "ExternalLink": types.StringType, - "HttpHeaders": basetypes.MapType{ + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "expiration": types.StringType, + "external_link": types.StringType, + "http_headers": basetypes.MapType{ ElemType: types.StringType, }, - "NextChunkIndex": types.Int64Type, - "NextChunkInternalLink": types.StringType, - "RowCount": types.Int64Type, - "RowOffset": types.Int64Type, + "next_chunk_index": types.Int64Type, + "next_chunk_internal_link": types.StringType, + "row_count": types.Int64Type, + "row_offset": types.Int64Type, }, } } @@ -2268,7 +2320,7 @@ func (a GetAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2291,7 +2343,7 @@ func (a GetAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AlertId": types.StringType, + "alert_id": types.StringType, }, } } @@ -2314,7 +2366,7 @@ func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -2340,8 +2392,8 @@ func (a GetDbsqlPermissionRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a GetDbsqlPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "objectId": types.StringType, + "objectType": types.StringType, }, } } @@ -2364,7 +2416,7 @@ func (a GetQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type func (a GetQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueryId": types.StringType, + "query_id": types.StringType, }, } } @@ -2387,7 +2439,7 @@ func (a GetQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2408,18 +2460,18 @@ func (newState *GetResponse) SyncEffectiveFieldsDuringRead(existingState GetResp func (a GetResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AccessControl{}), + "access_control_list": reflect.TypeOf(AccessControl{}), } } func (a GetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AccessControl{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2444,7 +2496,7 @@ func (a GetStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "StatementId": types.StringType, + "statement_id": types.StringType, }, } } @@ -2470,8 +2522,8 @@ func (a GetStatementResultChunkNRequest) GetComplexFieldTypes() map[string]refle func (a GetStatementResultChunkNRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ChunkIndex": types.Int64Type, - "StatementId": types.StringType, + "chunk_index": types.Int64Type, + "statement_id": types.StringType, }, } } @@ -2495,7 +2547,7 @@ func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes() map[string]r func (a GetWarehousePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -2513,14 +2565,14 @@ func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringR func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(WarehousePermissionsDescription{}), + "permission_levels": reflect.TypeOf(WarehousePermissionsDescription{}), } } func (a GetWarehousePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: WarehousePermissionsDescription{}.ToAttrType(ctx), }, }, @@ -2546,7 +2598,7 @@ func (a GetWarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflec func (a GetWarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -2570,7 +2622,7 @@ func (a GetWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -2660,36 +2712,44 @@ func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringRead(existingStat func (a GetWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Channel": reflect.TypeOf(Channel{}), - "Health": reflect.TypeOf(EndpointHealth{}), - "OdbcParams": reflect.TypeOf(OdbcParams{}), - "Tags": reflect.TypeOf(EndpointTags{}), + "channel": reflect.TypeOf(Channel{}), + "health": reflect.TypeOf(EndpointHealth{}), + "odbc_params": reflect.TypeOf(OdbcParams{}), + "tags": reflect.TypeOf(EndpointTags{}), } } func (a GetWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoStopMins": types.Int64Type, - "Channel": Channel{}.ToAttrType(ctx), - "ClusterSize": types.StringType, - "CreatorName": types.StringType, - "EnablePhoton": types.BoolType, - "EnableServerlessCompute": types.BoolType, - "Health": EndpointHealth{}.ToAttrType(ctx), - "Id": types.StringType, - "InstanceProfileArn": types.StringType, - "JdbcUrl": types.StringType, - "MaxNumClusters": types.Int64Type, - "MinNumClusters": types.Int64Type, - "Name": types.StringType, - "NumActiveSessions": types.Int64Type, - "NumClusters": types.Int64Type, - "OdbcParams": OdbcParams{}.ToAttrType(ctx), - "SpotInstancePolicy": types.StringType, - "State": types.StringType, - "Tags": EndpointTags{}.ToAttrType(ctx), - "WarehouseType": types.StringType, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.ToAttrType(ctx), + }, + "cluster_size": types.StringType, + "creator_name": types.StringType, + "enable_photon": types.BoolType, + "enable_serverless_compute": types.BoolType, + "health": basetypes.ListType{ + ElemType: EndpointHealth{}.ToAttrType(ctx), + }, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "jdbc_url": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "num_active_sessions": types.Int64Type, + "num_clusters": types.Int64Type, + "odbc_params": basetypes.ListType{ + ElemType: OdbcParams{}.ToAttrType(ctx), + }, + "spot_instance_policy": types.StringType, + "state": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.ToAttrType(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -2730,31 +2790,39 @@ func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRe func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Channel": reflect.TypeOf(Channel{}), - "ConfigParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), - "DataAccessConfig": reflect.TypeOf(EndpointConfPair{}), - "EnabledWarehouseTypes": reflect.TypeOf(WarehouseTypePair{}), - "GlobalParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), - "SqlConfigurationParameters": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "channel": reflect.TypeOf(Channel{}), + "config_param": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "data_access_config": reflect.TypeOf(EndpointConfPair{}), + "enabled_warehouse_types": reflect.TypeOf(WarehouseTypePair{}), + "global_param": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "sql_configuration_parameters": reflect.TypeOf(RepeatedEndpointConfPairs{}), } } func (a GetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Channel": Channel{}.ToAttrType(ctx), - "ConfigParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), - "DataAccessConfig": basetypes.ListType{ + "channel": basetypes.ListType{ + ElemType: Channel{}.ToAttrType(ctx), + }, + "config_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, + "data_access_config": basetypes.ListType{ ElemType: EndpointConfPair{}.ToAttrType(ctx), }, - "EnabledWarehouseTypes": basetypes.ListType{ + "enabled_warehouse_types": basetypes.ListType{ ElemType: WarehouseTypePair{}.ToAttrType(ctx), }, - "GlobalParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), - "GoogleServiceAccount": types.StringType, - "InstanceProfileArn": types.StringType, - "SecurityPolicy": types.StringType, - "SqlConfigurationParameters": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + "global_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, + "google_service_account": types.StringType, + "instance_profile_arn": types.StringType, + "security_policy": types.StringType, + "sql_configuration_parameters": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, }, } } @@ -2796,26 +2864,32 @@ func (newState *LegacyAlert) SyncEffectiveFieldsDuringRead(existingState LegacyA func (a LegacyAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(AlertOptions{}), - "Query": reflect.TypeOf(AlertQuery{}), - "User": reflect.TypeOf(User{}), + "options": reflect.TypeOf(AlertOptions{}), + "query": reflect.TypeOf(AlertQuery{}), + "user": reflect.TypeOf(User{}), } } func (a LegacyAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.StringType, - "Id": types.StringType, - "LastTriggeredAt": types.StringType, - "Name": types.StringType, - "Options": AlertOptions{}.ToAttrType(ctx), - "Parent": types.StringType, - "Query": AlertQuery{}.ToAttrType(ctx), - "Rearm": types.Int64Type, - "State": types.StringType, - "UpdatedAt": types.StringType, - "User": User{}.ToAttrType(ctx), + "created_at": types.StringType, + "id": types.StringType, + "last_triggered_at": types.StringType, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: AlertOptions{}.ToAttrType(ctx), + }, + "parent": types.StringType, + "query": basetypes.ListType{ + ElemType: AlertQuery{}.ToAttrType(ctx), + }, + "rearm": types.Int64Type, + "state": types.StringType, + "updated_at": types.StringType, + "user": basetypes.ListType{ + ElemType: User{}.ToAttrType(ctx), + }, }, } } @@ -2899,43 +2973,49 @@ func (newState *LegacyQuery) SyncEffectiveFieldsDuringRead(existingState LegacyQ func (a LegacyQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "LastModifiedBy": reflect.TypeOf(User{}), - "Options": reflect.TypeOf(QueryOptions{}), - "Tags": reflect.TypeOf(types.StringType), - "User": reflect.TypeOf(User{}), - "Visualizations": reflect.TypeOf(LegacyVisualization{}), + "last_modified_by": reflect.TypeOf(User{}), + "options": reflect.TypeOf(QueryOptions{}), + "tags": reflect.TypeOf(types.StringType), + "user": reflect.TypeOf(User{}), + "visualizations": reflect.TypeOf(LegacyVisualization{}), } } func (a LegacyQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CanEdit": types.BoolType, - "CreatedAt": types.StringType, - "DataSourceId": types.StringType, - "Description": types.StringType, - "Id": types.StringType, - "IsArchived": types.BoolType, - "IsDraft": types.BoolType, - "IsFavorite": types.BoolType, - "IsSafe": types.BoolType, - "LastModifiedBy": User{}.ToAttrType(ctx), - "LastModifiedById": types.Int64Type, - "LatestQueryDataId": types.StringType, - "Name": types.StringType, - "Options": QueryOptions{}.ToAttrType(ctx), - "Parent": types.StringType, - "PermissionTier": types.StringType, - "Query": types.StringType, - "QueryHash": types.StringType, - "RunAsRole": types.StringType, - "Tags": basetypes.ListType{ + "can_edit": types.BoolType, + "created_at": types.StringType, + "data_source_id": types.StringType, + "description": types.StringType, + "id": types.StringType, + "is_archived": types.BoolType, + "is_draft": types.BoolType, + "is_favorite": types.BoolType, + "is_safe": types.BoolType, + "last_modified_by": basetypes.ListType{ + ElemType: User{}.ToAttrType(ctx), + }, + "last_modified_by_id": types.Int64Type, + "latest_query_data_id": types.StringType, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: QueryOptions{}.ToAttrType(ctx), + }, + "parent": types.StringType, + "permission_tier": types.StringType, + "query": types.StringType, + "query_hash": types.StringType, + "run_as_role": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "UpdatedAt": types.StringType, - "User": User{}.ToAttrType(ctx), - "UserId": types.Int64Type, - "Visualizations": basetypes.ListType{ + "updated_at": types.StringType, + "user": basetypes.ListType{ + ElemType: User{}.ToAttrType(ctx), + }, + "user_id": types.Int64Type, + "visualizations": basetypes.ListType{ ElemType: LegacyVisualization{}.ToAttrType(ctx), }, }, @@ -2977,21 +3057,23 @@ func (newState *LegacyVisualization) SyncEffectiveFieldsDuringRead(existingState func (a LegacyVisualization) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Query": reflect.TypeOf(LegacyQuery{}), + "query": reflect.TypeOf(LegacyQuery{}), } } func (a LegacyVisualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.StringType, - "Description": types.StringType, - "Id": types.StringType, - "Name": types.StringType, - "Options": types.ObjectType{}, - "Query": LegacyQuery{}.ToAttrType(ctx), - "Type": types.StringType, - "UpdatedAt": types.StringType, + "created_at": types.StringType, + "description": types.StringType, + "id": types.StringType, + "name": types.StringType, + "options": types.ObjectType{}, + "query": basetypes.ListType{ + ElemType: LegacyQuery{}.ToAttrType(ctx), + }, + "type": types.StringType, + "updated_at": types.StringType, }, } } @@ -3016,8 +3098,8 @@ func (a ListAlertsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListAlertsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -3036,15 +3118,15 @@ func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListAlertsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(ListAlertsResponseAlert{}), + "results": reflect.TypeOf(ListAlertsResponseAlert{}), } } func (a ListAlertsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Results": basetypes.ListType{ + "next_page_token": types.StringType, + "results": basetypes.ListType{ ElemType: ListAlertsResponseAlert{}.ToAttrType(ctx), }, }, @@ -3103,27 +3185,29 @@ func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringRead(existingS func (a ListAlertsResponseAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Condition": reflect.TypeOf(AlertCondition{}), + "condition": reflect.TypeOf(AlertCondition{}), } } func (a ListAlertsResponseAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Condition": AlertCondition{}.ToAttrType(ctx), - "CreateTime": types.StringType, - "CustomBody": types.StringType, - "CustomSubject": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, - "LifecycleState": types.StringType, - "NotifyOnOk": types.BoolType, - "OwnerUserName": types.StringType, - "QueryId": types.StringType, - "SecondsToRetrigger": types.Int64Type, - "State": types.StringType, - "TriggerTime": types.StringType, - "UpdateTime": types.StringType, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.ToAttrType(ctx), + }, + "create_time": types.StringType, + "custom_body": types.StringType, + "custom_subject": types.StringType, + "display_name": types.StringType, + "id": types.StringType, + "lifecycle_state": types.StringType, + "notify_on_ok": types.BoolType, + "owner_user_name": types.StringType, + "query_id": types.StringType, + "seconds_to_retrigger": types.Int64Type, + "state": types.StringType, + "trigger_time": types.StringType, + "update_time": types.StringType, }, } } @@ -3153,10 +3237,10 @@ func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Order": types.StringType, - "Page": types.Int64Type, - "PageSize": types.Int64Type, - "Q": types.StringType, + "order": types.StringType, + "page": types.Int64Type, + "page_size": types.Int64Type, + "q": types.StringType, }, } } @@ -3199,10 +3283,10 @@ func (a ListQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type func (a ListQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Order": types.StringType, - "Page": types.Int64Type, - "PageSize": types.Int64Type, - "Q": types.StringType, + "order": types.StringType, + "page": types.Int64Type, + "page_size": types.Int64Type, + "q": types.StringType, }, } } @@ -3227,8 +3311,8 @@ func (a ListQueriesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListQueriesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -3250,16 +3334,16 @@ func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListQueriesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Res": reflect.TypeOf(QueryInfo{}), + "res": reflect.TypeOf(QueryInfo{}), } } func (a ListQueriesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "HasNextPage": types.BoolType, - "NextPageToken": types.StringType, - "Res": basetypes.ListType{ + "has_next_page": types.BoolType, + "next_page_token": types.StringType, + "res": basetypes.ListType{ ElemType: QueryInfo{}.ToAttrType(ctx), }, }, @@ -3291,17 +3375,19 @@ func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringRead(existingS func (a ListQueryHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FilterBy": reflect.TypeOf(QueryFilter{}), + "filter_by": reflect.TypeOf(QueryFilter{}), } } func (a ListQueryHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FilterBy": QueryFilter{}.ToAttrType(ctx), - "IncludeMetrics": types.BoolType, - "MaxResults": types.Int64Type, - "PageToken": types.StringType, + "filter_by": basetypes.ListType{ + ElemType: QueryFilter{}.ToAttrType(ctx), + }, + "include_metrics": types.BoolType, + "max_results": types.Int64Type, + "page_token": types.StringType, }, } } @@ -3320,15 +3406,15 @@ func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringRead(existing func (a ListQueryObjectsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(ListQueryObjectsResponseQuery{}), + "results": reflect.TypeOf(ListQueryObjectsResponseQuery{}), } } func (a ListQueryObjectsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Results": basetypes.ListType{ + "next_page_token": types.StringType, + "results": basetypes.ListType{ ElemType: ListQueryObjectsResponseQuery{}.ToAttrType(ctx), }, }, @@ -3380,34 +3466,34 @@ func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringRead(exi func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(QueryParameter{}), + "tags": reflect.TypeOf(types.StringType), } } func (a ListQueryObjectsResponseQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyAutoLimit": types.BoolType, - "Catalog": types.StringType, - "CreateTime": types.StringType, - "Description": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, - "LastModifierUserName": types.StringType, - "LifecycleState": types.StringType, - "OwnerUserName": types.StringType, - "Parameters": basetypes.ListType{ + "apply_auto_limit": types.BoolType, + "catalog": types.StringType, + "create_time": types.StringType, + "description": types.StringType, + "display_name": types.StringType, + "id": types.StringType, + "last_modifier_user_name": types.StringType, + "lifecycle_state": types.StringType, + "owner_user_name": types.StringType, + "parameters": basetypes.ListType{ ElemType: QueryParameter{}.ToAttrType(ctx), }, - "QueryText": types.StringType, - "RunAsMode": types.StringType, - "Schema": types.StringType, - "Tags": basetypes.ListType{ + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "UpdateTime": types.StringType, - "WarehouseId": types.StringType, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -3431,17 +3517,17 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListRe func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(Dashboard{}), + "results": reflect.TypeOf(Dashboard{}), } } func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Count": types.Int64Type, - "Page": types.Int64Type, - "PageSize": types.Int64Type, - "Results": basetypes.ListType{ + "count": types.Int64Type, + "page": types.Int64Type, + "page_size": types.Int64Type, + "results": basetypes.ListType{ ElemType: Dashboard{}.ToAttrType(ctx), }, }, @@ -3470,9 +3556,9 @@ func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes() map[string]ref func (a ListVisualizationsForQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "PageSize": types.Int64Type, - "PageToken": types.StringType, + "id": types.StringType, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -3491,15 +3577,15 @@ func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringRea func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(Visualization{}), + "results": reflect.TypeOf(Visualization{}), } } func (a ListVisualizationsForQueryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Results": basetypes.ListType{ + "next_page_token": types.StringType, + "results": basetypes.ListType{ ElemType: Visualization{}.ToAttrType(ctx), }, }, @@ -3526,7 +3612,7 @@ func (a ListWarehousesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListWarehousesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RunAsUserId": types.Int64Type, + "run_as_user_id": types.Int64Type, }, } } @@ -3544,14 +3630,14 @@ func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringRead(existingSt func (a ListWarehousesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Warehouses": reflect.TypeOf(EndpointInfo{}), + "warehouses": reflect.TypeOf(EndpointInfo{}), } } func (a ListWarehousesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Warehouses": basetypes.ListType{ + "warehouses": basetypes.ListType{ ElemType: EndpointInfo{}.ToAttrType(ctx), }, }, @@ -3581,9 +3667,9 @@ func (a MultiValuesOptions) GetComplexFieldTypes() map[string]reflect.Type { func (a MultiValuesOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Prefix": types.StringType, - "Separator": types.StringType, - "Suffix": types.StringType, + "prefix": types.StringType, + "separator": types.StringType, + "suffix": types.StringType, }, } } @@ -3605,7 +3691,7 @@ func (a NumericValue) GetComplexFieldTypes() map[string]reflect.Type { func (a NumericValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Value": types.Float64Type, + "value": types.Float64Type, }, } } @@ -3633,10 +3719,10 @@ func (a OdbcParams) GetComplexFieldTypes() map[string]reflect.Type { func (a OdbcParams) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Hostname": types.StringType, - "Path": types.StringType, - "Port": types.Int64Type, - "Protocol": types.StringType, + "hostname": types.StringType, + "path": types.StringType, + "port": types.Int64Type, + "protocol": types.StringType, }, } } @@ -3670,20 +3756,22 @@ func (newState *Parameter) SyncEffectiveFieldsDuringRead(existingState Parameter func (a Parameter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), + "multiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), } } func (a Parameter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EnumOptions": types.StringType, - "MultiValuesOptions": MultiValuesOptions{}.ToAttrType(ctx), - "Name": types.StringType, - "QueryId": types.StringType, - "Title": types.StringType, - "Type": types.StringType, - "Value": types.ObjectType{}, + "enumOptions": types.StringType, + "multiValuesOptions": basetypes.ListType{ + ElemType: MultiValuesOptions{}.ToAttrType(ctx), + }, + "name": types.StringType, + "queryId": types.StringType, + "title": types.StringType, + "type": types.StringType, + "value": types.ObjectType{}, }, } } @@ -3735,35 +3823,35 @@ func (newState *Query) SyncEffectiveFieldsDuringRead(existingState Query) { func (a Query) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(QueryParameter{}), + "tags": reflect.TypeOf(types.StringType), } } func (a Query) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyAutoLimit": types.BoolType, - "Catalog": types.StringType, - "CreateTime": types.StringType, - "Description": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, - "LastModifierUserName": types.StringType, - "LifecycleState": types.StringType, - "OwnerUserName": types.StringType, - "Parameters": basetypes.ListType{ + "apply_auto_limit": types.BoolType, + "catalog": types.StringType, + "create_time": types.StringType, + "description": types.StringType, + "display_name": types.StringType, + "id": types.StringType, + "last_modifier_user_name": types.StringType, + "lifecycle_state": types.StringType, + "owner_user_name": types.StringType, + "parameters": basetypes.ListType{ ElemType: QueryParameter{}.ToAttrType(ctx), }, - "ParentPath": types.StringType, - "QueryText": types.StringType, - "RunAsMode": types.StringType, - "Schema": types.StringType, - "Tags": basetypes.ListType{ + "parent_path": types.StringType, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "UpdateTime": types.StringType, - "WarehouseId": types.StringType, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -3785,17 +3873,19 @@ func (newState *QueryBackedValue) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryBackedValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "MultiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), - "Values": reflect.TypeOf(types.StringType), + "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), + "values": reflect.TypeOf(types.StringType), } } func (a QueryBackedValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "MultiValuesOptions": MultiValuesOptions{}.ToAttrType(ctx), - "QueryId": types.StringType, - "Values": basetypes.ListType{ + "multi_values_options": basetypes.ListType{ + ElemType: MultiValuesOptions{}.ToAttrType(ctx), + }, + "query_id": types.StringType, + "values": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3838,21 +3928,21 @@ func (newState *QueryEditContent) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryEditContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.StringType), } } func (a QueryEditContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataSourceId": types.StringType, - "Description": types.StringType, - "Name": types.StringType, - "Options": types.ObjectType{}, - "Query": types.StringType, - "QueryId": types.StringType, - "RunAsRole": types.StringType, - "Tags": basetypes.ListType{ + "data_source_id": types.StringType, + "description": types.StringType, + "name": types.StringType, + "options": types.ObjectType{}, + "query": types.StringType, + "query_id": types.StringType, + "run_as_role": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3881,28 +3971,30 @@ func (newState *QueryFilter) SyncEffectiveFieldsDuringRead(existingState QueryFi func (a QueryFilter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "QueryStartTimeRange": reflect.TypeOf(TimeRange{}), - "StatementIds": reflect.TypeOf(types.StringType), - "Statuses": reflect.TypeOf(types.StringType), - "UserIds": reflect.TypeOf(types.Int64Type), - "WarehouseIds": reflect.TypeOf(types.StringType), + "query_start_time_range": reflect.TypeOf(TimeRange{}), + "statement_ids": reflect.TypeOf(types.StringType), + "statuses": reflect.TypeOf(types.StringType), + "user_ids": reflect.TypeOf(types.Int64Type), + "warehouse_ids": reflect.TypeOf(types.StringType), } } func (a QueryFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueryStartTimeRange": TimeRange{}.ToAttrType(ctx), - "StatementIds": basetypes.ListType{ + "query_start_time_range": basetypes.ListType{ + ElemType: TimeRange{}.ToAttrType(ctx), + }, + "statement_ids": basetypes.ListType{ ElemType: types.StringType, }, - "Statuses": basetypes.ListType{ + "statuses": basetypes.ListType{ ElemType: types.StringType, }, - "UserIds": basetypes.ListType{ + "user_ids": basetypes.ListType{ ElemType: types.Int64Type, }, - "WarehouseIds": basetypes.ListType{ + "warehouse_ids": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -3969,36 +4061,40 @@ func (newState *QueryInfo) SyncEffectiveFieldsDuringRead(existingState QueryInfo func (a QueryInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ChannelUsed": reflect.TypeOf(ChannelInfo{}), - "Metrics": reflect.TypeOf(QueryMetrics{}), + "channel_used": reflect.TypeOf(ChannelInfo{}), + "metrics": reflect.TypeOf(QueryMetrics{}), } } func (a QueryInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ChannelUsed": ChannelInfo{}.ToAttrType(ctx), - "Duration": types.Int64Type, - "EndpointId": types.StringType, - "ErrorMessage": types.StringType, - "ExecutedAsUserId": types.Int64Type, - "ExecutedAsUserName": types.StringType, - "ExecutionEndTimeMs": types.Int64Type, - "IsFinal": types.BoolType, - "LookupKey": types.StringType, - "Metrics": QueryMetrics{}.ToAttrType(ctx), - "PlansState": types.StringType, - "QueryEndTimeMs": types.Int64Type, - "QueryId": types.StringType, - "QueryStartTimeMs": types.Int64Type, - "QueryText": types.StringType, - "RowsProduced": types.Int64Type, - "SparkUiUrl": types.StringType, - "StatementType": types.StringType, - "Status": types.StringType, - "UserId": types.Int64Type, - "UserName": types.StringType, - "WarehouseId": types.StringType, + "channel_used": basetypes.ListType{ + ElemType: ChannelInfo{}.ToAttrType(ctx), + }, + "duration": types.Int64Type, + "endpoint_id": types.StringType, + "error_message": types.StringType, + "executed_as_user_id": types.Int64Type, + "executed_as_user_name": types.StringType, + "execution_end_time_ms": types.Int64Type, + "is_final": types.BoolType, + "lookup_key": types.StringType, + "metrics": basetypes.ListType{ + ElemType: QueryMetrics{}.ToAttrType(ctx), + }, + "plans_state": types.StringType, + "query_end_time_ms": types.Int64Type, + "query_id": types.StringType, + "query_start_time_ms": types.Int64Type, + "query_text": types.StringType, + "rows_produced": types.Int64Type, + "spark_ui_url": types.StringType, + "statement_type": types.StringType, + "status": types.StringType, + "user_id": types.Int64Type, + "user_name": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -4022,17 +4118,17 @@ func (newState *QueryList) SyncEffectiveFieldsDuringRead(existingState QueryList func (a QueryList) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Results": reflect.TypeOf(LegacyQuery{}), + "results": reflect.TypeOf(LegacyQuery{}), } } func (a QueryList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Count": types.Int64Type, - "Page": types.Int64Type, - "PageSize": types.Int64Type, - "Results": basetypes.ListType{ + "count": types.Int64Type, + "page": types.Int64Type, + "page_size": types.Int64Type, + "results": basetypes.ListType{ ElemType: LegacyQuery{}.ToAttrType(ctx), }, }, @@ -4113,28 +4209,28 @@ func (a QueryMetrics) GetComplexFieldTypes() map[string]reflect.Type { func (a QueryMetrics) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CompilationTimeMs": types.Int64Type, - "ExecutionTimeMs": types.Int64Type, - "NetworkSentBytes": types.Int64Type, - "OverloadingQueueStartTimestamp": types.Int64Type, - "PhotonTotalTimeMs": types.Int64Type, - "ProvisioningQueueStartTimestamp": types.Int64Type, - "PrunedBytes": types.Int64Type, - "PrunedFilesCount": types.Int64Type, - "QueryCompilationStartTimestamp": types.Int64Type, - "ReadBytes": types.Int64Type, - "ReadCacheBytes": types.Int64Type, - "ReadFilesCount": types.Int64Type, - "ReadPartitionsCount": types.Int64Type, - "ReadRemoteBytes": types.Int64Type, - "ResultFetchTimeMs": types.Int64Type, - "ResultFromCache": types.BoolType, - "RowsProducedCount": types.Int64Type, - "RowsReadCount": types.Int64Type, - "SpillToDiskBytes": types.Int64Type, - "TaskTotalTimeMs": types.Int64Type, - "TotalTimeMs": types.Int64Type, - "WriteRemoteBytes": types.Int64Type, + "compilation_time_ms": types.Int64Type, + "execution_time_ms": types.Int64Type, + "network_sent_bytes": types.Int64Type, + "overloading_queue_start_timestamp": types.Int64Type, + "photon_total_time_ms": types.Int64Type, + "provisioning_queue_start_timestamp": types.Int64Type, + "pruned_bytes": types.Int64Type, + "pruned_files_count": types.Int64Type, + "query_compilation_start_timestamp": types.Int64Type, + "read_bytes": types.Int64Type, + "read_cache_bytes": types.Int64Type, + "read_files_count": types.Int64Type, + "read_partitions_count": types.Int64Type, + "read_remote_bytes": types.Int64Type, + "result_fetch_time_ms": types.Int64Type, + "result_from_cache": types.BoolType, + "rows_produced_count": types.Int64Type, + "rows_read_count": types.Int64Type, + "spill_to_disk_bytes": types.Int64Type, + "task_total_time_ms": types.Int64Type, + "total_time_ms": types.Int64Type, + "write_remote_bytes": types.Int64Type, }, } } @@ -4160,19 +4256,19 @@ func (newState *QueryOptions) SyncEffectiveFieldsDuringRead(existingState QueryO func (a QueryOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(Parameter{}), + "parameters": reflect.TypeOf(Parameter{}), } } func (a QueryOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Catalog": types.StringType, - "MovedToTrashAt": types.StringType, - "Parameters": basetypes.ListType{ + "catalog": types.StringType, + "moved_to_trash_at": types.StringType, + "parameters": basetypes.ListType{ ElemType: Parameter{}.ToAttrType(ctx), }, - "Schema": types.StringType, + "schema": types.StringType, }, } } @@ -4207,26 +4303,38 @@ func (newState *QueryParameter) SyncEffectiveFieldsDuringRead(existingState Quer func (a QueryParameter) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DateRangeValue": reflect.TypeOf(DateRangeValue{}), - "DateValue": reflect.TypeOf(DateValue{}), - "EnumValue": reflect.TypeOf(EnumValue{}), - "NumericValue": reflect.TypeOf(NumericValue{}), - "QueryBackedValue": reflect.TypeOf(QueryBackedValue{}), - "TextValue": reflect.TypeOf(TextValue{}), + "date_range_value": reflect.TypeOf(DateRangeValue{}), + "date_value": reflect.TypeOf(DateValue{}), + "enum_value": reflect.TypeOf(EnumValue{}), + "numeric_value": reflect.TypeOf(NumericValue{}), + "query_backed_value": reflect.TypeOf(QueryBackedValue{}), + "text_value": reflect.TypeOf(TextValue{}), } } func (a QueryParameter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DateRangeValue": DateRangeValue{}.ToAttrType(ctx), - "DateValue": DateValue{}.ToAttrType(ctx), - "EnumValue": EnumValue{}.ToAttrType(ctx), - "Name": types.StringType, - "NumericValue": NumericValue{}.ToAttrType(ctx), - "QueryBackedValue": QueryBackedValue{}.ToAttrType(ctx), - "TextValue": TextValue{}.ToAttrType(ctx), - "Title": types.StringType, + "date_range_value": basetypes.ListType{ + ElemType: DateRangeValue{}.ToAttrType(ctx), + }, + "date_value": basetypes.ListType{ + ElemType: DateValue{}.ToAttrType(ctx), + }, + "enum_value": basetypes.ListType{ + ElemType: EnumValue{}.ToAttrType(ctx), + }, + "name": types.StringType, + "numeric_value": basetypes.ListType{ + ElemType: NumericValue{}.ToAttrType(ctx), + }, + "query_backed_value": basetypes.ListType{ + ElemType: QueryBackedValue{}.ToAttrType(ctx), + }, + "text_value": basetypes.ListType{ + ElemType: TextValue{}.ToAttrType(ctx), + }, + "title": types.StringType, }, } } @@ -4267,21 +4375,21 @@ func (newState *QueryPostContent) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryPostContent) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.StringType), } } func (a QueryPostContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataSourceId": types.StringType, - "Description": types.StringType, - "Name": types.StringType, - "Options": types.ObjectType{}, - "Parent": types.StringType, - "Query": types.StringType, - "RunAsRole": types.StringType, - "Tags": basetypes.ListType{ + "data_source_id": types.StringType, + "description": types.StringType, + "name": types.StringType, + "options": types.ObjectType{}, + "parent": types.StringType, + "query": types.StringType, + "run_as_role": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -4303,18 +4411,18 @@ func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringRead(existin func (a RepeatedEndpointConfPairs) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ConfigPair": reflect.TypeOf(EndpointConfPair{}), - "ConfigurationPairs": reflect.TypeOf(EndpointConfPair{}), + "config_pair": reflect.TypeOf(EndpointConfPair{}), + "configuration_pairs": reflect.TypeOf(EndpointConfPair{}), } } func (a RepeatedEndpointConfPairs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ConfigPair": basetypes.ListType{ + "config_pair": basetypes.ListType{ ElemType: EndpointConfPair{}.ToAttrType(ctx), }, - "ConfigurationPairs": basetypes.ListType{ + "configuration_pairs": basetypes.ListType{ ElemType: EndpointConfPair{}.ToAttrType(ctx), }, }, @@ -4339,7 +4447,7 @@ func (a RestoreDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type func (a RestoreDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DashboardId": types.StringType, + "dashboard_id": types.StringType, }, } } @@ -4362,7 +4470,7 @@ func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.T func (a RestoreQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "QueryId": types.StringType, + "query_id": types.StringType, }, } } @@ -4421,28 +4529,28 @@ func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultDa func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataArray": reflect.TypeOf(types.StringType), - "ExternalLinks": reflect.TypeOf(ExternalLink{}), + "data_array": reflect.TypeOf(types.StringType), + "external_links": reflect.TypeOf(ExternalLink{}), } } func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ByteCount": types.Int64Type, - "ChunkIndex": types.Int64Type, - "DataArray": basetypes.ListType{ + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "data_array": basetypes.ListType{ ElemType: basetypes.ListType{ ElemType: types.StringType, }, }, - "ExternalLinks": basetypes.ListType{ + "external_links": basetypes.ListType{ ElemType: ExternalLink{}.ToAttrType(ctx), }, - "NextChunkIndex": types.Int64Type, - "NextChunkInternalLink": types.StringType, - "RowCount": types.Int64Type, - "RowOffset": types.Int64Type, + "next_chunk_index": types.Int64Type, + "next_chunk_internal_link": types.StringType, + "row_count": types.Int64Type, + "row_offset": types.Int64Type, }, } } @@ -4475,23 +4583,25 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState Resu func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Chunks": reflect.TypeOf(BaseChunkInfo{}), - "Schema": reflect.TypeOf(ResultSchema{}), + "chunks": reflect.TypeOf(BaseChunkInfo{}), + "schema": reflect.TypeOf(ResultSchema{}), } } func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Chunks": basetypes.ListType{ + "chunks": basetypes.ListType{ ElemType: BaseChunkInfo{}.ToAttrType(ctx), }, - "Format": types.StringType, - "Schema": ResultSchema{}.ToAttrType(ctx), - "TotalByteCount": types.Int64Type, - "TotalChunkCount": types.Int64Type, - "TotalRowCount": types.Int64Type, - "Truncated": types.BoolType, + "format": types.StringType, + "schema": basetypes.ListType{ + ElemType: ResultSchema{}.ToAttrType(ctx), + }, + "total_byte_count": types.Int64Type, + "total_chunk_count": types.Int64Type, + "total_row_count": types.Int64Type, + "truncated": types.BoolType, }, } } @@ -4511,15 +4621,15 @@ func (newState *ResultSchema) SyncEffectiveFieldsDuringRead(existingState Result func (a ResultSchema) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Columns": reflect.TypeOf(ColumnInfo{}), + "columns": reflect.TypeOf(ColumnInfo{}), } } func (a ResultSchema) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ColumnCount": types.Int64Type, - "Columns": basetypes.ListType{ + "column_count": types.Int64Type, + "columns": basetypes.ListType{ ElemType: ColumnInfo{}.ToAttrType(ctx), }, }, @@ -4545,8 +4655,8 @@ func (a ServiceError) GetComplexFieldTypes() map[string]reflect.Type { func (a ServiceError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ErrorCode": types.StringType, - "Message": types.StringType, + "error_code": types.StringType, + "message": types.StringType, }, } } @@ -4569,18 +4679,18 @@ func (newState *SetRequest) SyncEffectiveFieldsDuringRead(existingState SetReque func (a SetRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AccessControl{}), + "access_control_list": reflect.TypeOf(AccessControl{}), } } func (a SetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AccessControl{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "objectId": types.StringType, + "objectType": types.StringType, }, } } @@ -4601,18 +4711,18 @@ func (newState *SetResponse) SyncEffectiveFieldsDuringRead(existingState SetResp func (a SetResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(AccessControl{}), + "access_control_list": reflect.TypeOf(AccessControl{}), } } func (a SetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: AccessControl{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4653,31 +4763,39 @@ func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringRea func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Channel": reflect.TypeOf(Channel{}), - "ConfigParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), - "DataAccessConfig": reflect.TypeOf(EndpointConfPair{}), - "EnabledWarehouseTypes": reflect.TypeOf(WarehouseTypePair{}), - "GlobalParam": reflect.TypeOf(RepeatedEndpointConfPairs{}), - "SqlConfigurationParameters": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "channel": reflect.TypeOf(Channel{}), + "config_param": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "data_access_config": reflect.TypeOf(EndpointConfPair{}), + "enabled_warehouse_types": reflect.TypeOf(WarehouseTypePair{}), + "global_param": reflect.TypeOf(RepeatedEndpointConfPairs{}), + "sql_configuration_parameters": reflect.TypeOf(RepeatedEndpointConfPairs{}), } } func (a SetWorkspaceWarehouseConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Channel": Channel{}.ToAttrType(ctx), - "ConfigParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), - "DataAccessConfig": basetypes.ListType{ + "channel": basetypes.ListType{ + ElemType: Channel{}.ToAttrType(ctx), + }, + "config_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, + "data_access_config": basetypes.ListType{ ElemType: EndpointConfPair{}.ToAttrType(ctx), }, - "EnabledWarehouseTypes": basetypes.ListType{ + "enabled_warehouse_types": basetypes.ListType{ ElemType: WarehouseTypePair{}.ToAttrType(ctx), }, - "GlobalParam": RepeatedEndpointConfPairs{}.ToAttrType(ctx), - "GoogleServiceAccount": types.StringType, - "InstanceProfileArn": types.StringType, - "SecurityPolicy": types.StringType, - "SqlConfigurationParameters": RepeatedEndpointConfPairs{}.ToAttrType(ctx), + "global_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, + "google_service_account": types.StringType, + "instance_profile_arn": types.StringType, + "security_policy": types.StringType, + "sql_configuration_parameters": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + }, }, } } @@ -4720,7 +4838,7 @@ func (a StartRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a StartRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -4773,9 +4891,9 @@ func (a StatementParameterListItem) GetComplexFieldTypes() map[string]reflect.Ty func (a StatementParameterListItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, - "Type": types.StringType, - "Value": types.StringType, + "name": types.StringType, + "type": types.StringType, + "value": types.StringType, }, } } @@ -4801,19 +4919,25 @@ func (newState *StatementResponse) SyncEffectiveFieldsDuringRead(existingState S func (a StatementResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Manifest": reflect.TypeOf(ResultManifest{}), - "Result": reflect.TypeOf(ResultData{}), - "Status": reflect.TypeOf(StatementStatus{}), + "manifest": reflect.TypeOf(ResultManifest{}), + "result": reflect.TypeOf(ResultData{}), + "status": reflect.TypeOf(StatementStatus{}), } } func (a StatementResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Manifest": ResultManifest{}.ToAttrType(ctx), - "Result": ResultData{}.ToAttrType(ctx), - "StatementId": types.StringType, - "Status": StatementStatus{}.ToAttrType(ctx), + "manifest": basetypes.ListType{ + ElemType: ResultManifest{}.ToAttrType(ctx), + }, + "result": basetypes.ListType{ + ElemType: ResultData{}.ToAttrType(ctx), + }, + "statement_id": types.StringType, + "status": basetypes.ListType{ + ElemType: StatementStatus{}.ToAttrType(ctx), + }, }, } } @@ -4840,15 +4964,17 @@ func (newState *StatementStatus) SyncEffectiveFieldsDuringRead(existingState Sta func (a StatementStatus) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Error": reflect.TypeOf(ServiceError{}), + "error": reflect.TypeOf(ServiceError{}), } } func (a StatementStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Error": ServiceError{}.ToAttrType(ctx), - "State": types.StringType, + "error": basetypes.ListType{ + ElemType: ServiceError{}.ToAttrType(ctx), + }, + "state": types.StringType, }, } } @@ -4872,7 +4998,7 @@ func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -4913,7 +5039,7 @@ func (a Success) GetComplexFieldTypes() map[string]reflect.Type { func (a Success) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, + "message": types.StringType, }, } } @@ -4936,18 +5062,18 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState T func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.StringType), } } func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Code": types.StringType, - "Parameters": basetypes.MapType{ + "code": types.StringType, + "parameters": basetypes.MapType{ ElemType: types.StringType, }, - "Type": types.StringType, + "type": types.StringType, }, } } @@ -4969,7 +5095,7 @@ func (a TextValue) GetComplexFieldTypes() map[string]reflect.Type { func (a TextValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Value": types.StringType, + "value": types.StringType, }, } } @@ -4994,8 +5120,8 @@ func (a TimeRange) GetComplexFieldTypes() map[string]reflect.Type { func (a TimeRange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndTimeMs": types.Int64Type, - "StartTimeMs": types.Int64Type, + "end_time_ms": types.Int64Type, + "start_time_ms": types.Int64Type, }, } } @@ -5018,7 +5144,7 @@ func (a TransferOwnershipObjectId) GetComplexFieldTypes() map[string]reflect.Typ func (a TransferOwnershipObjectId) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NewOwner": types.StringType, + "new_owner": types.StringType, }, } } @@ -5041,16 +5167,18 @@ func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringRead(existing func (a TransferOwnershipRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ObjectId": reflect.TypeOf(TransferOwnershipObjectId{}), + "objectId": reflect.TypeOf(TransferOwnershipObjectId{}), } } func (a TransferOwnershipRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NewOwner": types.StringType, - "ObjectId": TransferOwnershipObjectId{}.ToAttrType(ctx), - "ObjectType": types.StringType, + "new_owner": types.StringType, + "objectId": basetypes.ListType{ + ElemType: TransferOwnershipObjectId{}.ToAttrType(ctx), + }, + "objectType": types.StringType, }, } } @@ -5073,7 +5201,7 @@ func (a TrashAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a TrashAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -5096,7 +5224,7 @@ func (a TrashQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a TrashQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, + "id": types.StringType, }, } } @@ -5120,16 +5248,18 @@ func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringRead(existingState func (a UpdateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Alert": reflect.TypeOf(UpdateAlertRequestAlert{}), + "alert": reflect.TypeOf(UpdateAlertRequestAlert{}), } } func (a UpdateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Alert": UpdateAlertRequestAlert{}.ToAttrType(ctx), - "Id": types.StringType, - "UpdateMask": types.StringType, + "alert": basetypes.ListType{ + ElemType: UpdateAlertRequestAlert{}.ToAttrType(ctx), + }, + "id": types.StringType, + "update_mask": types.StringType, }, } } @@ -5171,21 +5301,23 @@ func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingS func (a UpdateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Condition": reflect.TypeOf(AlertCondition{}), + "condition": reflect.TypeOf(AlertCondition{}), } } func (a UpdateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Condition": AlertCondition{}.ToAttrType(ctx), - "CustomBody": types.StringType, - "CustomSubject": types.StringType, - "DisplayName": types.StringType, - "NotifyOnOk": types.BoolType, - "OwnerUserName": types.StringType, - "QueryId": types.StringType, - "SecondsToRetrigger": types.Int64Type, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.ToAttrType(ctx), + }, + "custom_body": types.StringType, + "custom_subject": types.StringType, + "display_name": types.StringType, + "notify_on_ok": types.BoolType, + "owner_user_name": types.StringType, + "query_id": types.StringType, + "seconds_to_retrigger": types.Int64Type, }, } } @@ -5209,16 +5341,18 @@ func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringRead(existingState func (a UpdateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Query": reflect.TypeOf(UpdateQueryRequestQuery{}), + "query": reflect.TypeOf(UpdateQueryRequestQuery{}), } } func (a UpdateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Query": UpdateQueryRequestQuery{}.ToAttrType(ctx), - "UpdateMask": types.StringType, + "id": types.StringType, + "query": basetypes.ListType{ + ElemType: UpdateQueryRequestQuery{}.ToAttrType(ctx), + }, + "update_mask": types.StringType, }, } } @@ -5258,29 +5392,29 @@ func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingS func (a UpdateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Parameters": reflect.TypeOf(QueryParameter{}), - "Tags": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(QueryParameter{}), + "tags": reflect.TypeOf(types.StringType), } } func (a UpdateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ApplyAutoLimit": types.BoolType, - "Catalog": types.StringType, - "Description": types.StringType, - "DisplayName": types.StringType, - "OwnerUserName": types.StringType, - "Parameters": basetypes.ListType{ + "apply_auto_limit": types.BoolType, + "catalog": types.StringType, + "description": types.StringType, + "display_name": types.StringType, + "owner_user_name": types.StringType, + "parameters": basetypes.ListType{ ElemType: QueryParameter{}.ToAttrType(ctx), }, - "QueryText": types.StringType, - "RunAsMode": types.StringType, - "Schema": types.StringType, - "Tags": basetypes.ListType{ + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ ElemType: types.StringType, }, - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -5323,16 +5457,18 @@ func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringRead(existi func (a UpdateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Visualization": reflect.TypeOf(UpdateVisualizationRequestVisualization{}), + "visualization": reflect.TypeOf(UpdateVisualizationRequestVisualization{}), } } func (a UpdateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "UpdateMask": types.StringType, - "Visualization": UpdateVisualizationRequestVisualization{}.ToAttrType(ctx), + "id": types.StringType, + "update_mask": types.StringType, + "visualization": basetypes.ListType{ + ElemType: UpdateVisualizationRequestVisualization{}.ToAttrType(ctx), + }, }, } } @@ -5365,10 +5501,10 @@ func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes() map[stri func (a UpdateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DisplayName": types.StringType, - "SerializedOptions": types.StringType, - "SerializedQueryPlan": types.StringType, - "Type": types.StringType, + "display_name": types.StringType, + "serialized_options": types.StringType, + "serialized_query_plan": types.StringType, + "type": types.StringType, }, } } @@ -5394,9 +5530,9 @@ func (a User) GetComplexFieldTypes() map[string]reflect.Type { func (a User) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Email": types.StringType, - "Id": types.Int64Type, - "Name": types.StringType, + "email": types.StringType, + "id": types.Int64Type, + "name": types.StringType, }, } } @@ -5437,14 +5573,14 @@ func (a Visualization) GetComplexFieldTypes() map[string]reflect.Type { func (a Visualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreateTime": types.StringType, - "DisplayName": types.StringType, - "Id": types.StringType, - "QueryId": types.StringType, - "SerializedOptions": types.StringType, - "SerializedQueryPlan": types.StringType, - "Type": types.StringType, - "UpdateTime": types.StringType, + "create_time": types.StringType, + "display_name": types.StringType, + "id": types.StringType, + "query_id": types.StringType, + "serialized_options": types.StringType, + "serialized_query_plan": types.StringType, + "type": types.StringType, + "update_time": types.StringType, }, } } @@ -5473,10 +5609,10 @@ func (a WarehouseAccessControlRequest) GetComplexFieldTypes() map[string]reflect func (a WarehouseAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -5502,20 +5638,20 @@ func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringRead(ex func (a WarehouseAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(WarehousePermission{}), + "all_permissions": reflect.TypeOf(WarehousePermission{}), } } func (a WarehouseAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: WarehousePermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -5536,18 +5672,18 @@ func (newState *WarehousePermission) SyncEffectiveFieldsDuringRead(existingState func (a WarehousePermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a WarehousePermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -5568,18 +5704,18 @@ func (newState *WarehousePermissions) SyncEffectiveFieldsDuringRead(existingStat func (a WarehousePermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(WarehouseAccessControlResponse{}), + "access_control_list": reflect.TypeOf(WarehouseAccessControlResponse{}), } } func (a WarehousePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: WarehouseAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -5603,8 +5739,8 @@ func (a WarehousePermissionsDescription) GetComplexFieldTypes() map[string]refle func (a WarehousePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -5623,17 +5759,17 @@ func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(exist func (a WarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(WarehouseAccessControlRequest{}), + "access_control_list": reflect.TypeOf(WarehouseAccessControlRequest{}), } } func (a WarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: WarehouseAccessControlRequest{}.ToAttrType(ctx), }, - "WarehouseId": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -5659,8 +5795,8 @@ func (a WarehouseTypePair) GetComplexFieldTypes() map[string]reflect.Type { func (a WarehouseTypePair) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Enabled": types.BoolType, - "WarehouseType": types.StringType, + "enabled": types.BoolType, + "warehouse_type": types.StringType, }, } } @@ -5688,18 +5824,22 @@ func (newState *Widget) SyncEffectiveFieldsDuringRead(existingState Widget) { func (a Widget) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Options": reflect.TypeOf(WidgetOptions{}), - "Visualization": reflect.TypeOf(LegacyVisualization{}), + "options": reflect.TypeOf(WidgetOptions{}), + "visualization": reflect.TypeOf(LegacyVisualization{}), } } func (a Widget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Id": types.StringType, - "Options": WidgetOptions{}.ToAttrType(ctx), - "Visualization": LegacyVisualization{}.ToAttrType(ctx), - "Width": types.Int64Type, + "id": types.StringType, + "options": basetypes.ListType{ + ElemType: WidgetOptions{}.ToAttrType(ctx), + }, + "visualization": basetypes.ListType{ + ElemType: LegacyVisualization{}.ToAttrType(ctx), + }, + "width": types.Int64Type, }, } } @@ -5732,20 +5872,22 @@ func (newState *WidgetOptions) SyncEffectiveFieldsDuringRead(existingState Widge func (a WidgetOptions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Position": reflect.TypeOf(WidgetPosition{}), + "position": reflect.TypeOf(WidgetPosition{}), } } func (a WidgetOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.StringType, - "Description": types.StringType, - "IsHidden": types.BoolType, - "ParameterMappings": types.ObjectType{}, - "Position": WidgetPosition{}.ToAttrType(ctx), - "Title": types.StringType, - "UpdatedAt": types.StringType, + "created_at": types.StringType, + "description": types.StringType, + "isHidden": types.BoolType, + "parameterMappings": types.ObjectType{}, + "position": basetypes.ListType{ + ElemType: WidgetPosition{}.ToAttrType(ctx), + }, + "title": types.StringType, + "updated_at": types.StringType, }, } } @@ -5778,11 +5920,11 @@ func (a WidgetPosition) GetComplexFieldTypes() map[string]reflect.Type { func (a WidgetPosition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AutoHeight": types.BoolType, - "Col": types.Int64Type, - "Row": types.Int64Type, - "SizeX": types.Int64Type, - "SizeY": types.Int64Type, + "autoHeight": types.BoolType, + "col": types.Int64Type, + "row": types.Int64Type, + "sizeX": types.Int64Type, + "sizeY": types.Int64Type, }, } } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 5fd9a28086..94c020f5de 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -37,7 +37,7 @@ func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Name": types.StringType, + "name": types.StringType, }, } } @@ -62,8 +62,8 @@ func (a CreateEndpoint) GetComplexFieldTypes() map[string]reflect.Type { func (a CreateEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointType": types.StringType, - "Name": types.StringType, + "endpoint_type": types.StringType, + "name": types.StringType, }, } } @@ -99,20 +99,24 @@ func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringRead(existing func (a CreateVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DeltaSyncIndexSpec": reflect.TypeOf(DeltaSyncVectorIndexSpecRequest{}), - "DirectAccessIndexSpec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), + "delta_sync_index_spec": reflect.TypeOf(DeltaSyncVectorIndexSpecRequest{}), + "direct_access_index_spec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), } } func (a CreateVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DeltaSyncIndexSpec": DeltaSyncVectorIndexSpecRequest{}.ToAttrType(ctx), - "DirectAccessIndexSpec": DirectAccessVectorIndexSpec{}.ToAttrType(ctx), - "EndpointName": types.StringType, - "IndexType": types.StringType, - "Name": types.StringType, - "PrimaryKey": types.StringType, + "delta_sync_index_spec": basetypes.ListType{ + ElemType: DeltaSyncVectorIndexSpecRequest{}.ToAttrType(ctx), + }, + "direct_access_index_spec": basetypes.ListType{ + ElemType: DirectAccessVectorIndexSpec{}.ToAttrType(ctx), + }, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, }, } } @@ -129,14 +133,16 @@ func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringRead(existin func (a CreateVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "VectorIndex": reflect.TypeOf(VectorIndex{}), + "vector_index": reflect.TypeOf(VectorIndex{}), } } func (a CreateVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "VectorIndex": VectorIndex{}.ToAttrType(ctx), + "vector_index": basetypes.ListType{ + ElemType: VectorIndex{}.ToAttrType(ctx), + }, }, } } @@ -157,17 +163,17 @@ func (newState *DeleteDataResult) SyncEffectiveFieldsDuringRead(existingState De func (a DeleteDataResult) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FailedPrimaryKeys": reflect.TypeOf(types.StringType), + "failed_primary_keys": reflect.TypeOf(types.StringType), } } func (a DeleteDataResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FailedPrimaryKeys": basetypes.ListType{ + "failed_primary_keys": basetypes.ListType{ ElemType: types.StringType, }, - "SuccessRowCount": types.Int64Type, + "success_row_count": types.Int64Type, }, } } @@ -189,15 +195,15 @@ func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(exis func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PrimaryKeys": reflect.TypeOf(types.StringType), + "primary_keys": reflect.TypeOf(types.StringType), } } func (a DeleteDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexName": types.StringType, - "PrimaryKeys": basetypes.ListType{ + "index_name": types.StringType, + "primary_keys": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -220,15 +226,17 @@ func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(exi func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Result": reflect.TypeOf(DeleteDataResult{}), + "result": reflect.TypeOf(DeleteDataResult{}), } } func (a DeleteDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Result": DeleteDataResult{}.ToAttrType(ctx), - "Status": types.StringType, + "result": basetypes.ListType{ + ElemType: DeleteDataResult{}.ToAttrType(ctx), + }, + "status": types.StringType, }, } } @@ -252,7 +260,7 @@ func (a DeleteEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointName": types.StringType, + "endpoint_name": types.StringType, }, } } @@ -295,7 +303,7 @@ func (a DeleteIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexName": types.StringType, + "index_name": types.StringType, }, } } @@ -355,27 +363,27 @@ func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringRead(e func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ColumnsToSync": reflect.TypeOf(types.StringType), - "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), - "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), + "columns_to_sync": reflect.TypeOf(types.StringType), + "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), + "embedding_vector_columns": reflect.TypeOf(EmbeddingVectorColumn{}), } } func (a DeltaSyncVectorIndexSpecRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ColumnsToSync": basetypes.ListType{ + "columns_to_sync": basetypes.ListType{ ElemType: types.StringType, }, - "EmbeddingSourceColumns": basetypes.ListType{ + "embedding_source_columns": basetypes.ListType{ ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), }, - "EmbeddingVectorColumns": basetypes.ListType{ + "embedding_vector_columns": basetypes.ListType{ ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), }, - "EmbeddingWritebackTable": types.StringType, - "PipelineType": types.StringType, - "SourceTable": types.StringType, + "embedding_writeback_table": types.StringType, + "pipeline_type": types.StringType, + "source_table": types.StringType, }, } } @@ -411,24 +419,24 @@ func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringRead( func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), - "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), + "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), + "embedding_vector_columns": reflect.TypeOf(EmbeddingVectorColumn{}), } } func (a DeltaSyncVectorIndexSpecResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EmbeddingSourceColumns": basetypes.ListType{ + "embedding_source_columns": basetypes.ListType{ ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), }, - "EmbeddingVectorColumns": basetypes.ListType{ + "embedding_vector_columns": basetypes.ListType{ ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), }, - "EmbeddingWritebackTable": types.StringType, - "PipelineId": types.StringType, - "PipelineType": types.StringType, - "SourceTable": types.StringType, + "embedding_writeback_table": types.StringType, + "pipeline_id": types.StringType, + "pipeline_type": types.StringType, + "source_table": types.StringType, }, } } @@ -455,21 +463,21 @@ func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringRead(exist func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EmbeddingSourceColumns": reflect.TypeOf(EmbeddingSourceColumn{}), - "EmbeddingVectorColumns": reflect.TypeOf(EmbeddingVectorColumn{}), + "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), + "embedding_vector_columns": reflect.TypeOf(EmbeddingVectorColumn{}), } } func (a DirectAccessVectorIndexSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EmbeddingSourceColumns": basetypes.ListType{ + "embedding_source_columns": basetypes.ListType{ ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), }, - "EmbeddingVectorColumns": basetypes.ListType{ + "embedding_vector_columns": basetypes.ListType{ ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), }, - "SchemaJson": types.StringType, + "schema_json": types.StringType, }, } } @@ -494,8 +502,8 @@ func (a EmbeddingSourceColumn) GetComplexFieldTypes() map[string]reflect.Type { func (a EmbeddingSourceColumn) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EmbeddingModelEndpointName": types.StringType, - "Name": types.StringType, + "embedding_model_endpoint_name": types.StringType, + "name": types.StringType, }, } } @@ -520,8 +528,8 @@ func (a EmbeddingVectorColumn) GetComplexFieldTypes() map[string]reflect.Type { func (a EmbeddingVectorColumn) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EmbeddingDimension": types.Int64Type, - "Name": types.StringType, + "embedding_dimension": types.Int64Type, + "name": types.StringType, }, } } @@ -555,22 +563,24 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState Endpoi func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "EndpointStatus": reflect.TypeOf(EndpointStatus{}), + "endpoint_status": reflect.TypeOf(EndpointStatus{}), } } func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreationTimestamp": types.Int64Type, - "Creator": types.StringType, - "EndpointStatus": EndpointStatus{}.ToAttrType(ctx), - "EndpointType": types.StringType, - "Id": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, - "LastUpdatedUser": types.StringType, - "Name": types.StringType, - "NumIndexes": types.Int64Type, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "endpoint_status": basetypes.ListType{ + ElemType: EndpointStatus{}.ToAttrType(ctx), + }, + "endpoint_type": types.StringType, + "id": types.StringType, + "last_updated_timestamp": types.Int64Type, + "last_updated_user": types.StringType, + "name": types.StringType, + "num_indexes": types.Int64Type, }, } } @@ -596,8 +606,8 @@ func (a EndpointStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a EndpointStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Message": types.StringType, - "State": types.StringType, + "message": types.StringType, + "state": types.StringType, }, } } @@ -621,7 +631,7 @@ func (a GetEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointName": types.StringType, + "endpoint_name": types.StringType, }, } } @@ -645,7 +655,7 @@ func (a GetIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexName": types.StringType, + "index_name": types.StringType, }, } } @@ -666,17 +676,17 @@ func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringRead(existingStat func (a ListEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Endpoints": reflect.TypeOf(EndpointInfo{}), + "endpoints": reflect.TypeOf(EndpointInfo{}), } } func (a ListEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Endpoints": basetypes.ListType{ + "endpoints": basetypes.ListType{ ElemType: EndpointInfo{}.ToAttrType(ctx), }, - "NextPageToken": types.StringType, + "next_page_token": types.StringType, }, } } @@ -700,7 +710,7 @@ func (a ListEndpointsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListEndpointsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PageToken": types.StringType, + "page_token": types.StringType, }, } } @@ -726,8 +736,8 @@ func (a ListIndexesRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListIndexesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointName": types.StringType, - "PageToken": types.StringType, + "endpoint_name": types.StringType, + "page_token": types.StringType, }, } } @@ -744,14 +754,14 @@ func (newState *ListValue) SyncEffectiveFieldsDuringRead(existingState ListValue func (a ListValue) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Values": reflect.TypeOf(Value{}), + "values": reflect.TypeOf(Value{}), } } func (a ListValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Values": basetypes.ListType{ + "values": basetypes.ListType{ ElemType: Value{}.ToAttrType(ctx), }, }, @@ -774,15 +784,15 @@ func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringRead(existin func (a ListVectorIndexesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "VectorIndexes": reflect.TypeOf(MiniVectorIndex{}), + "vector_indexes": reflect.TypeOf(MiniVectorIndex{}), } } func (a ListVectorIndexesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "VectorIndexes": basetypes.ListType{ + "next_page_token": types.StringType, + "vector_indexes": basetypes.ListType{ ElemType: MiniVectorIndex{}.ToAttrType(ctx), }, }, @@ -805,15 +815,17 @@ func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringRead(existingState func (a MapStringValueEntry) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Value": reflect.TypeOf(Value{}), + "value": reflect.TypeOf(Value{}), } } func (a MapStringValueEntry) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": Value{}.ToAttrType(ctx), + "key": types.StringType, + "value": basetypes.ListType{ + ElemType: Value{}.ToAttrType(ctx), + }, }, } } @@ -850,11 +862,11 @@ func (a MiniVectorIndex) GetComplexFieldTypes() map[string]reflect.Type { func (a MiniVectorIndex) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Creator": types.StringType, - "EndpointName": types.StringType, - "IndexType": types.StringType, - "Name": types.StringType, - "PrimaryKey": types.StringType, + "creator": types.StringType, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, }, } } @@ -883,9 +895,9 @@ func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes() map[string]refle func (a QueryVectorIndexNextPageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "EndpointName": types.StringType, - "IndexName": types.StringType, - "PageToken": types.StringType, + "endpoint_name": types.StringType, + "index_name": types.StringType, + "page_token": types.StringType, }, } } @@ -923,26 +935,26 @@ func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingS func (a QueryVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Columns": reflect.TypeOf(types.StringType), - "QueryVector": reflect.TypeOf(types.Float64Type), + "columns": reflect.TypeOf(types.StringType), + "query_vector": reflect.TypeOf(types.Float64Type), } } func (a QueryVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Columns": basetypes.ListType{ + "columns": basetypes.ListType{ ElemType: types.StringType, }, - "FiltersJson": types.StringType, - "IndexName": types.StringType, - "NumResults": types.Int64Type, - "QueryText": types.StringType, - "QueryType": types.StringType, - "QueryVector": basetypes.ListType{ + "filters_json": types.StringType, + "index_name": types.StringType, + "num_results": types.Int64Type, + "query_text": types.StringType, + "query_type": types.StringType, + "query_vector": basetypes.ListType{ ElemType: types.Float64Type, }, - "ScoreThreshold": types.Float64Type, + "score_threshold": types.Float64Type, }, } } @@ -966,17 +978,21 @@ func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringRead(existing func (a QueryVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Manifest": reflect.TypeOf(ResultManifest{}), - "Result": reflect.TypeOf(ResultData{}), + "manifest": reflect.TypeOf(ResultManifest{}), + "result": reflect.TypeOf(ResultData{}), } } func (a QueryVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Manifest": ResultManifest{}.ToAttrType(ctx), - "NextPageToken": types.StringType, - "Result": ResultData{}.ToAttrType(ctx), + "manifest": basetypes.ListType{ + ElemType: ResultManifest{}.ToAttrType(ctx), + }, + "next_page_token": types.StringType, + "result": basetypes.ListType{ + ElemType: ResultData{}.ToAttrType(ctx), + }, }, } } @@ -997,19 +1013,19 @@ func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultDa func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DataArray": reflect.TypeOf(types.StringType), + "data_array": reflect.TypeOf(types.StringType), } } func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DataArray": basetypes.ListType{ + "data_array": basetypes.ListType{ ElemType: basetypes.ListType{ ElemType: types.StringType, }, }, - "RowCount": types.Int64Type, + "row_count": types.Int64Type, }, } } @@ -1030,15 +1046,15 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState Resu func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Columns": reflect.TypeOf(ColumnInfo{}), + "columns": reflect.TypeOf(ColumnInfo{}), } } func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ColumnCount": types.Int64Type, - "Columns": basetypes.ListType{ + "column_count": types.Int64Type, + "columns": basetypes.ListType{ ElemType: ColumnInfo{}.ToAttrType(ctx), }, }, @@ -1068,9 +1084,9 @@ func (a ScanVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ScanVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexName": types.StringType, - "LastPrimaryKey": types.StringType, - "NumResults": types.Int64Type, + "index_name": types.StringType, + "last_primary_key": types.StringType, + "num_results": types.Int64Type, }, } } @@ -1091,17 +1107,17 @@ func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingS func (a ScanVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Data": reflect.TypeOf(Struct{}), + "data": reflect.TypeOf(Struct{}), } } func (a ScanVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Data": basetypes.ListType{ + "data": basetypes.ListType{ ElemType: Struct{}.ToAttrType(ctx), }, - "LastPrimaryKey": types.StringType, + "last_primary_key": types.StringType, }, } } @@ -1119,14 +1135,14 @@ func (newState *Struct) SyncEffectiveFieldsDuringRead(existingState Struct) { func (a Struct) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Fields": reflect.TypeOf(MapStringValueEntry{}), + "fields": reflect.TypeOf(MapStringValueEntry{}), } } func (a Struct) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Fields": basetypes.ListType{ + "fields": basetypes.ListType{ ElemType: MapStringValueEntry{}.ToAttrType(ctx), }, }, @@ -1152,7 +1168,7 @@ func (a SyncIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a SyncIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexName": types.StringType, + "index_name": types.StringType, }, } } @@ -1192,17 +1208,17 @@ func (newState *UpsertDataResult) SyncEffectiveFieldsDuringRead(existingState Up func (a UpsertDataResult) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "FailedPrimaryKeys": reflect.TypeOf(types.StringType), + "failed_primary_keys": reflect.TypeOf(types.StringType), } } func (a UpsertDataResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "FailedPrimaryKeys": basetypes.ListType{ + "failed_primary_keys": basetypes.ListType{ ElemType: types.StringType, }, - "SuccessRowCount": types.Int64Type, + "success_row_count": types.Int64Type, }, } } @@ -1229,8 +1245,8 @@ func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect. func (a UpsertDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexName": types.StringType, - "InputsJson": types.StringType, + "index_name": types.StringType, + "inputs_json": types.StringType, }, } } @@ -1251,15 +1267,17 @@ func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(exi func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Result": reflect.TypeOf(UpsertDataResult{}), + "result": reflect.TypeOf(UpsertDataResult{}), } } func (a UpsertDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Result": UpsertDataResult{}.ToAttrType(ctx), - "Status": types.StringType, + "result": basetypes.ListType{ + ElemType: UpsertDataResult{}.ToAttrType(ctx), + }, + "status": types.StringType, }, } } @@ -1286,20 +1304,24 @@ func (newState *Value) SyncEffectiveFieldsDuringRead(existingState Value) { func (a Value) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "ListValue": reflect.TypeOf(ListValue{}), - "StructValue": reflect.TypeOf(Struct{}), + "list_value": reflect.TypeOf(ListValue{}), + "struct_value": reflect.TypeOf(Struct{}), } } func (a Value) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BoolValue": types.BoolType, - "ListValue": ListValue{}.ToAttrType(ctx), - "NullValue": types.StringType, - "NumberValue": types.Float64Type, - "StringValue": types.StringType, - "StructValue": Struct{}.ToAttrType(ctx), + "bool_value": types.BoolType, + "list_value": basetypes.ListType{ + ElemType: ListValue{}.ToAttrType(ctx), + }, + "null_value": types.StringType, + "number_value": types.Float64Type, + "string_value": types.StringType, + "struct_value": basetypes.ListType{ + ElemType: Struct{}.ToAttrType(ctx), + }, }, } } @@ -1337,23 +1359,29 @@ func (newState *VectorIndex) SyncEffectiveFieldsDuringRead(existingState VectorI func (a VectorIndex) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "DeltaSyncIndexSpec": reflect.TypeOf(DeltaSyncVectorIndexSpecResponse{}), - "DirectAccessIndexSpec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), - "Status": reflect.TypeOf(VectorIndexStatus{}), + "delta_sync_index_spec": reflect.TypeOf(DeltaSyncVectorIndexSpecResponse{}), + "direct_access_index_spec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), + "status": reflect.TypeOf(VectorIndexStatus{}), } } func (a VectorIndex) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Creator": types.StringType, - "DeltaSyncIndexSpec": DeltaSyncVectorIndexSpecResponse{}.ToAttrType(ctx), - "DirectAccessIndexSpec": DirectAccessVectorIndexSpec{}.ToAttrType(ctx), - "EndpointName": types.StringType, - "IndexType": types.StringType, - "Name": types.StringType, - "PrimaryKey": types.StringType, - "Status": VectorIndexStatus{}.ToAttrType(ctx), + "creator": types.StringType, + "delta_sync_index_spec": basetypes.ListType{ + ElemType: DeltaSyncVectorIndexSpecResponse{}.ToAttrType(ctx), + }, + "direct_access_index_spec": basetypes.ListType{ + ElemType: DirectAccessVectorIndexSpec{}.ToAttrType(ctx), + }, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, + "status": basetypes.ListType{ + ElemType: VectorIndexStatus{}.ToAttrType(ctx), + }, }, } } @@ -1382,10 +1410,10 @@ func (a VectorIndexStatus) GetComplexFieldTypes() map[string]reflect.Type { func (a VectorIndexStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "IndexUrl": types.StringType, - "IndexedRowCount": types.Int64Type, - "Message": types.StringType, - "Ready": types.BoolType, + "index_url": types.StringType, + "indexed_row_count": types.Int64Type, + "message": types.StringType, + "ready": types.BoolType, }, } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 737e3941b0..dd0cc8f31d 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -39,8 +39,8 @@ func (a AclItem) GetComplexFieldTypes() map[string]reflect.Type { func (a AclItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Permission": types.StringType, - "Principal": types.StringType, + "permission": types.StringType, + "principal": types.StringType, }, } } @@ -66,8 +66,8 @@ func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes() map[string]refl func (a AzureKeyVaultSecretScopeMetadata) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "DnsName": types.StringType, - "ResourceId": types.StringType, + "dns_name": types.StringType, + "resource_id": types.StringType, }, } } @@ -107,9 +107,9 @@ func (a CreateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a CreateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GitProvider": types.StringType, - "GitUsername": types.StringType, - "PersonalAccessToken": types.StringType, + "git_provider": types.StringType, + "git_username": types.StringType, + "personal_access_token": types.StringType, }, } } @@ -137,9 +137,9 @@ func (a CreateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Typ func (a CreateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.Int64Type, - "GitProvider": types.StringType, - "GitUsername": types.StringType, + "credential_id": types.Int64Type, + "git_provider": types.StringType, + "git_username": types.StringType, }, } } @@ -169,17 +169,19 @@ func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringRead(existingState C func (a CreateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } func (a CreateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, - "Provider": types.StringType, - "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), - "Url": types.StringType, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.ToAttrType(ctx), + }, + "url": types.StringType, }, } } @@ -210,20 +212,22 @@ func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringRead(existingState func (a CreateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } func (a CreateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Branch": types.StringType, - "HeadCommitId": types.StringType, - "Id": types.Int64Type, - "Path": types.StringType, - "Provider": types.StringType, - "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), - "Url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.ToAttrType(ctx), + }, + "url": types.StringType, }, } } @@ -249,17 +253,19 @@ func (newState *CreateScope) SyncEffectiveFieldsDuringRead(existingState CreateS func (a CreateScope) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "BackendAzureKeyvault": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), + "backend_azure_keyvault": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), } } func (a CreateScope) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BackendAzureKeyvault": AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), - "InitialManagePrincipal": types.StringType, - "Scope": types.StringType, - "ScopeBackendType": types.StringType, + "backend_azure_keyvault": basetypes.ListType{ + ElemType: AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), + }, + "initial_manage_principal": types.StringType, + "scope": types.StringType, + "scope_backend_type": types.StringType, }, } } @@ -306,9 +312,9 @@ func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.Int64Type, - "GitProvider": types.StringType, - "GitUsername": types.StringType, + "credential_id": types.Int64Type, + "git_provider": types.StringType, + "git_username": types.StringType, }, } } @@ -336,8 +342,8 @@ func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, - "Recursive": types.BoolType, + "path": types.StringType, + "recursive": types.BoolType, }, } } @@ -362,8 +368,8 @@ func (a DeleteAcl) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteAcl) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Principal": types.StringType, - "Scope": types.StringType, + "principal": types.StringType, + "scope": types.StringType, }, } } @@ -406,7 +412,7 @@ func (a DeleteCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a DeleteCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.Int64Type, + "credential_id": types.Int64Type, }, } } @@ -449,7 +455,7 @@ func (a DeleteRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RepoId": types.Int64Type, + "repo_id": types.Int64Type, }, } } @@ -510,7 +516,7 @@ func (a DeleteScope) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteScope) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Scope": types.StringType, + "scope": types.StringType, }, } } @@ -554,8 +560,8 @@ func (a DeleteSecret) GetComplexFieldTypes() map[string]reflect.Type { func (a DeleteSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Scope": types.StringType, + "key": types.StringType, + "scope": types.StringType, }, } } @@ -614,8 +620,8 @@ func (a ExportRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ExportRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Format": types.StringType, - "Path": types.StringType, + "format": types.StringType, + "path": types.StringType, }, } } @@ -641,8 +647,8 @@ func (a ExportResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a ExportResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "FileType": types.StringType, + "content": types.StringType, + "file_type": types.StringType, }, } } @@ -668,8 +674,8 @@ func (a GetAclRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetAclRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Principal": types.StringType, - "Scope": types.StringType, + "principal": types.StringType, + "scope": types.StringType, }, } } @@ -693,7 +699,7 @@ func (a GetCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.Int64Type, + "credential_id": types.Int64Type, }, } } @@ -721,9 +727,9 @@ func (a GetCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a GetCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.Int64Type, - "GitProvider": types.StringType, - "GitUsername": types.StringType, + "credential_id": types.Int64Type, + "git_provider": types.StringType, + "git_username": types.StringType, }, } } @@ -747,7 +753,7 @@ func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflec func (a GetRepoPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RepoId": types.StringType, + "repo_id": types.StringType, }, } } @@ -765,14 +771,14 @@ func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(e func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(RepoPermissionsDescription{}), + "permission_levels": reflect.TypeOf(RepoPermissionsDescription{}), } } func (a GetRepoPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: RepoPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -798,7 +804,7 @@ func (a GetRepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Typ func (a GetRepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RepoId": types.StringType, + "repo_id": types.StringType, }, } } @@ -822,7 +828,7 @@ func (a GetRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "RepoId": types.Int64Type, + "repo_id": types.Int64Type, }, } } @@ -852,20 +858,22 @@ func (newState *GetRepoResponse) SyncEffectiveFieldsDuringRead(existingState Get func (a GetRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } func (a GetRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Branch": types.StringType, - "HeadCommitId": types.StringType, - "Id": types.Int64Type, - "Path": types.StringType, - "Provider": types.StringType, - "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), - "Url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.ToAttrType(ctx), + }, + "url": types.StringType, }, } } @@ -891,8 +899,8 @@ func (a GetSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Scope": types.StringType, + "key": types.StringType, + "scope": types.StringType, }, } } @@ -917,8 +925,8 @@ func (a GetSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { func (a GetSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "Value": types.StringType, + "key": types.StringType, + "value": types.StringType, }, } } @@ -942,7 +950,7 @@ func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -968,8 +976,8 @@ func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes() map[st func (a GetWorkspaceObjectPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceObjectId": types.StringType, - "WorkspaceObjectType": types.StringType, + "workspace_object_id": types.StringType, + "workspace_object_type": types.StringType, }, } } @@ -987,14 +995,14 @@ func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsD func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "PermissionLevels": reflect.TypeOf(WorkspaceObjectPermissionsDescription{}), + "permission_levels": reflect.TypeOf(WorkspaceObjectPermissionsDescription{}), } } func (a GetWorkspaceObjectPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "PermissionLevels": basetypes.ListType{ + "permission_levels": basetypes.ListType{ ElemType: WorkspaceObjectPermissionsDescription{}.ToAttrType(ctx), }, }, @@ -1022,8 +1030,8 @@ func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string] func (a GetWorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "WorkspaceObjectId": types.StringType, - "WorkspaceObjectType": types.StringType, + "workspace_object_id": types.StringType, + "workspace_object_type": types.StringType, }, } } @@ -1074,11 +1082,11 @@ func (a Import) GetComplexFieldTypes() map[string]reflect.Type { func (a Import) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Content": types.StringType, - "Format": types.StringType, - "Language": types.StringType, - "Overwrite": types.BoolType, - "Path": types.StringType, + "content": types.StringType, + "format": types.StringType, + "language": types.StringType, + "overwrite": types.BoolType, + "path": types.StringType, }, } } @@ -1121,7 +1129,7 @@ func (a ListAclsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListAclsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Scope": types.StringType, + "scope": types.StringType, }, } } @@ -1139,14 +1147,14 @@ func (newState *ListAclsResponse) SyncEffectiveFieldsDuringRead(existingState Li func (a ListAclsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Items": reflect.TypeOf(AclItem{}), + "items": reflect.TypeOf(AclItem{}), } } func (a ListAclsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Items": basetypes.ListType{ + "items": basetypes.ListType{ ElemType: AclItem{}.ToAttrType(ctx), }, }, @@ -1166,14 +1174,14 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingS func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Credentials": reflect.TypeOf(CredentialInfo{}), + "credentials": reflect.TypeOf(CredentialInfo{}), } } func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Credentials": basetypes.ListType{ + "credentials": basetypes.ListType{ ElemType: CredentialInfo{}.ToAttrType(ctx), }, }, @@ -1205,8 +1213,8 @@ func (a ListReposRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListReposRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "PathPrefix": types.StringType, + "next_page_token": types.StringType, + "path_prefix": types.StringType, }, } } @@ -1227,15 +1235,15 @@ func (newState *ListReposResponse) SyncEffectiveFieldsDuringRead(existingState L func (a ListReposResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Repos": reflect.TypeOf(RepoInfo{}), + "repos": reflect.TypeOf(RepoInfo{}), } } func (a ListReposResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NextPageToken": types.StringType, - "Repos": basetypes.ListType{ + "next_page_token": types.StringType, + "repos": basetypes.ListType{ ElemType: RepoInfo{}.ToAttrType(ctx), }, }, @@ -1255,14 +1263,14 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListRe func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Objects": reflect.TypeOf(ObjectInfo{}), + "objects": reflect.TypeOf(ObjectInfo{}), } } func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Objects": basetypes.ListType{ + "objects": basetypes.ListType{ ElemType: ObjectInfo{}.ToAttrType(ctx), }, }, @@ -1282,14 +1290,14 @@ func (newState *ListScopesResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListScopesResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Scopes": reflect.TypeOf(SecretScope{}), + "scopes": reflect.TypeOf(SecretScope{}), } } func (a ListScopesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Scopes": basetypes.ListType{ + "scopes": basetypes.ListType{ ElemType: SecretScope{}.ToAttrType(ctx), }, }, @@ -1315,7 +1323,7 @@ func (a ListSecretsRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Scope": types.StringType, + "scope": types.StringType, }, } } @@ -1333,14 +1341,14 @@ func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Secrets": reflect.TypeOf(SecretMetadata{}), + "secrets": reflect.TypeOf(SecretMetadata{}), } } func (a ListSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Secrets": basetypes.ListType{ + "secrets": basetypes.ListType{ ElemType: SecretMetadata{}.ToAttrType(ctx), }, }, @@ -1368,8 +1376,8 @@ func (a ListWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { func (a ListWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "NotebooksModifiedAfter": types.Int64Type, - "Path": types.StringType, + "notebooks_modified_after": types.Int64Type, + "path": types.StringType, }, } } @@ -1394,7 +1402,7 @@ func (a Mkdirs) GetComplexFieldTypes() map[string]reflect.Type { func (a Mkdirs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Path": types.StringType, + "path": types.StringType, }, } } @@ -1456,14 +1464,14 @@ func (a ObjectInfo) GetComplexFieldTypes() map[string]reflect.Type { func (a ObjectInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CreatedAt": types.Int64Type, - "Language": types.StringType, - "ModifiedAt": types.Int64Type, - "ObjectId": types.Int64Type, - "ObjectType": types.StringType, - "Path": types.StringType, - "ResourceId": types.StringType, - "Size": types.Int64Type, + "created_at": types.Int64Type, + "language": types.StringType, + "modified_at": types.Int64Type, + "object_id": types.Int64Type, + "object_type": types.StringType, + "path": types.StringType, + "resource_id": types.StringType, + "size": types.Int64Type, }, } } @@ -1490,9 +1498,9 @@ func (a PutAcl) GetComplexFieldTypes() map[string]reflect.Type { func (a PutAcl) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Permission": types.StringType, - "Principal": types.StringType, - "Scope": types.StringType, + "permission": types.StringType, + "principal": types.StringType, + "scope": types.StringType, }, } } @@ -1540,10 +1548,10 @@ func (a PutSecret) GetComplexFieldTypes() map[string]reflect.Type { func (a PutSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BytesValue": types.StringType, - "Key": types.StringType, - "Scope": types.StringType, - "StringValue": types.StringType, + "bytes_value": types.StringType, + "key": types.StringType, + "scope": types.StringType, + "string_value": types.StringType, }, } } @@ -1591,10 +1599,10 @@ func (a RepoAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type func (a RepoAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1620,20 +1628,20 @@ func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringRead(existin func (a RepoAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(RepoPermission{}), + "all_permissions": reflect.TypeOf(RepoPermission{}), } } func (a RepoAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: RepoPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -1664,20 +1672,22 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SparseCheckout": reflect.TypeOf(SparseCheckout{}), + "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Branch": types.StringType, - "HeadCommitId": types.StringType, - "Id": types.Int64Type, - "Path": types.StringType, - "Provider": types.StringType, - "SparseCheckout": SparseCheckout{}.ToAttrType(ctx), - "Url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.ToAttrType(ctx), + }, + "url": types.StringType, }, } } @@ -1698,18 +1708,18 @@ func (newState *RepoPermission) SyncEffectiveFieldsDuringRead(existingState Repo func (a RepoPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a RepoPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -1730,18 +1740,18 @@ func (newState *RepoPermissions) SyncEffectiveFieldsDuringRead(existingState Rep func (a RepoPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(RepoAccessControlResponse{}), + "access_control_list": reflect.TypeOf(RepoAccessControlResponse{}), } } func (a RepoPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: RepoAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -1765,8 +1775,8 @@ func (a RepoPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Ty func (a RepoPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -1785,17 +1795,17 @@ func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingSt func (a RepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(RepoAccessControlRequest{}), + "access_control_list": reflect.TypeOf(RepoAccessControlRequest{}), } } func (a RepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: RepoAccessControlRequest{}.ToAttrType(ctx), }, - "RepoId": types.StringType, + "repo_id": types.StringType, }, } } @@ -1820,8 +1830,8 @@ func (a SecretMetadata) GetComplexFieldTypes() map[string]reflect.Type { func (a SecretMetadata) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Key": types.StringType, - "LastUpdatedTimestamp": types.Int64Type, + "key": types.StringType, + "last_updated_timestamp": types.Int64Type, }, } } @@ -1843,16 +1853,18 @@ func (newState *SecretScope) SyncEffectiveFieldsDuringRead(existingState SecretS func (a SecretScope) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "KeyvaultMetadata": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), + "keyvault_metadata": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), } } func (a SecretScope) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "BackendType": types.StringType, - "KeyvaultMetadata": AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), - "Name": types.StringType, + "backend_type": types.StringType, + "keyvault_metadata": basetypes.ListType{ + ElemType: AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), + }, + "name": types.StringType, }, } } @@ -1874,14 +1886,14 @@ func (newState *SparseCheckout) SyncEffectiveFieldsDuringRead(existingState Spar func (a SparseCheckout) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Patterns": reflect.TypeOf(types.StringType), + "patterns": reflect.TypeOf(types.StringType), } } func (a SparseCheckout) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Patterns": basetypes.ListType{ + "patterns": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1905,14 +1917,14 @@ func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringRead(existingStat func (a SparseCheckoutUpdate) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "Patterns": reflect.TypeOf(types.StringType), + "patterns": reflect.TypeOf(types.StringType), } } func (a SparseCheckoutUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Patterns": basetypes.ListType{ + "patterns": basetypes.ListType{ ElemType: types.StringType, }, }, @@ -1956,10 +1968,10 @@ func (a UpdateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type func (a UpdateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "CredentialId": types.Int64Type, - "GitProvider": types.StringType, - "GitUsername": types.StringType, - "PersonalAccessToken": types.StringType, + "credential_id": types.Int64Type, + "git_provider": types.StringType, + "git_username": types.StringType, + "personal_access_token": types.StringType, }, } } @@ -2006,17 +2018,19 @@ func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringRead(existingState U func (a UpdateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "SparseCheckout": reflect.TypeOf(SparseCheckoutUpdate{}), + "sparse_checkout": reflect.TypeOf(SparseCheckoutUpdate{}), } } func (a UpdateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Branch": types.StringType, - "RepoId": types.Int64Type, - "SparseCheckout": SparseCheckoutUpdate{}.ToAttrType(ctx), - "Tag": types.StringType, + "branch": types.StringType, + "repo_id": types.Int64Type, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckoutUpdate{}.ToAttrType(ctx), + }, + "tag": types.StringType, }, } } @@ -2064,10 +2078,10 @@ func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes() map[string]r func (a WorkspaceObjectAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "GroupName": types.StringType, - "PermissionLevel": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "group_name": types.StringType, + "permission_level": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -2093,20 +2107,20 @@ func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringR func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AllPermissions": reflect.TypeOf(WorkspaceObjectPermission{}), + "all_permissions": reflect.TypeOf(WorkspaceObjectPermission{}), } } func (a WorkspaceObjectAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AllPermissions": basetypes.ListType{ + "all_permissions": basetypes.ListType{ ElemType: WorkspaceObjectPermission{}.ToAttrType(ctx), }, - "DisplayName": types.StringType, - "GroupName": types.StringType, - "ServicePrincipalName": types.StringType, - "UserName": types.StringType, + "display_name": types.StringType, + "group_name": types.StringType, + "service_principal_name": types.StringType, + "user_name": types.StringType, }, } } @@ -2127,18 +2141,18 @@ func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringRead(existin func (a WorkspaceObjectPermission) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "InheritedFromObject": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.StringType), } } func (a WorkspaceObjectPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Inherited": types.BoolType, - "InheritedFromObject": basetypes.ListType{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ ElemType: types.StringType, }, - "PermissionLevel": types.StringType, + "permission_level": types.StringType, }, } } @@ -2159,18 +2173,18 @@ func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringRead(existi func (a WorkspaceObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(WorkspaceObjectAccessControlResponse{}), + "access_control_list": reflect.TypeOf(WorkspaceObjectAccessControlResponse{}), } } func (a WorkspaceObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: WorkspaceObjectAccessControlResponse{}.ToAttrType(ctx), }, - "ObjectId": types.StringType, - "ObjectType": types.StringType, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2194,8 +2208,8 @@ func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes() map[string func (a WorkspaceObjectPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "Description": types.StringType, - "PermissionLevel": types.StringType, + "description": types.StringType, + "permission_level": types.StringType, }, } } @@ -2216,18 +2230,18 @@ func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ - "AccessControlList": reflect.TypeOf(WorkspaceObjectAccessControlRequest{}), + "access_control_list": reflect.TypeOf(WorkspaceObjectAccessControlRequest{}), } } func (a WorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "AccessControlList": basetypes.ListType{ + "access_control_list": basetypes.ListType{ ElemType: WorkspaceObjectAccessControlRequest{}.ToAttrType(ctx), }, - "WorkspaceObjectId": types.StringType, - "WorkspaceObjectType": types.StringType, + "workspace_object_id": types.StringType, + "workspace_object_type": types.StringType, }, } } From c4c9375f5789ba1db40f9ebad082ee887350d792 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 09:20:26 +0100 Subject: [PATCH 31/91] work --- .codegen/model.go.tmpl | 39 ++++++++++++++++++++------ internal/acceptance/credential_test.go | 4 +-- 2 files changed, 32 insertions(+), 11 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index 3344d1f8f5..fa98aa898e 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -25,7 +25,12 @@ type {{.PascalName}} struct { {{- range .Fields}} {{.Comment " // " 80}} {{- $data := dict "field" . }} - {{template "field" $data}}{{if and (ne .Entity.Terraform nil) .Entity.Terraform.IsServiceProposedIfEmpty}}{{ $data := dict "field" . "effective" true }}{{printf "\n"}}{{template "field" $data}}{{end}}{{end}} + {{template "field" $data}} + {{- if and .Entity.Terraform .Entity.Terraform.IsServiceProposedIfEmpty -}} + {{- $data := dict "field" . "effective" true }} + {{template "field" $data}} + {{- end -}} + {{end}} } func (newState *{{.PascalName}}) SyncEffectiveFieldsDuringCreateOrUpdate(plan {{.PascalName}}) { @@ -59,7 +64,8 @@ func (a {{.PascalName}}) GetComplexFieldTypes() map[string]reflect.Type { return map[string]reflect.Type{ {{- range .Fields -}} {{- if or .Entity.IsObject .Entity.ArrayValue .Entity.MapValue}} - "{{.PascalName}}": reflect.TypeOf({{ template "complex-field-value" .Entity }}), + {{ $data := dict "field" . -}} + "{{template "tfsdk-name" $data}}": reflect.TypeOf({{ template "complex-field-value" .Entity }}), {{- end}} {{- end}} } @@ -69,7 +75,8 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ {{ range .Fields -}} - "{{.PascalName}}": {{ template "attr-type" .Entity }}, + {{ $data := dict "field" . -}} + "{{template "tfsdk-name" $data}}": {{ template "attr-type" .Entity }}, {{ end}} }, } @@ -79,14 +86,18 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { {{end}} {{/* TODO: Handle recursive Jobs structure */}} {{- define "attr-type" -}} - {{- if .ArrayValue }}basetypes.ListType{ - ElemType: {{ template "attr-type" .ArrayValue }}, - } + {{- if .ArrayValue -}} + {{- if .ArrayValue.IsObject -}}{{/* Objects are wraped in lists automatically. */}} + {{ template "attr-type" .ArrayValue }} + {{- else -}} + basetypes.ListType{ + ElemType: {{ template "attr-type" .ArrayValue }}, + } + {{- end -}} {{- else if .MapValue }}basetypes.MapType{ ElemType: {{ template "attr-type" .MapValue }}, } {{- else -}} - {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}} {{- if or .IsString .Enum -}}types.StringType {{- else if .IsBool -}}types.BoolType {{- else if .IsInt64 -}}types.Int64Type @@ -94,7 +105,9 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { {{- else if .IsInt -}}types.Int64Type {{- else if .IsAny -}}types.ObjectType{} {{- else if .IsByteStream}}types.ObjectType{} - {{- else if .IsObject -}}{{.PascalName}}{}.ToAttrType(ctx) + {{- else if .IsObject -}}{{/* Objects are treated as lists from a TFSDK type perspective. */}}basetypes.ListType{ + ElemType: {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}}{{.PascalName}}{}.ToAttrType(ctx), + } {{- end -}} {{- end -}} {{- end -}} @@ -134,7 +147,15 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { {{- if gt (len $annotations) 0 -}} {{- $annotations = (printf "%s" (trimSuffix "," $annotations)) -}} {{- end -}} - {{if .field.IsJson}}tfsdk:"{{if and (ne .field.Entity.Terraform nil) (ne .field.Entity.Terraform.Alias "") }}{{.field.Entity.Terraform.Alias}}{{else}}{{if .effective}}effective_{{end}}{{.field.Name}}{{end}}" tf:"{{$annotations}}"{{else}}tfsdk:"-"{{end -}} + {{if .field.IsJson}}tfsdk:"{{ template "tfsdk-name" . }}" tf:"{{$annotations}}"{{else}}tfsdk:"-"{{end -}} +{{- end -}} + +{{- define "tfsdk-name" -}} +{{- if and (ne .field.Entity.Terraform nil) (ne .field.Entity.Terraform.Alias "") -}} +{{.field.Entity.Terraform.Alias}} +{{- else -}} +{{if .effective}}effective_{{end}}{{.field.Name}} +{{- end -}} {{- end -}} {{- define "type" -}} diff --git a/internal/acceptance/credential_test.go b/internal/acceptance/credential_test.go index efbd492318..73a2b15b31 100644 --- a/internal/acceptance/credential_test.go +++ b/internal/acceptance/credential_test.go @@ -5,8 +5,8 @@ import ( ) func TestUcAccCredential(t *testing.T) { - LoadUcwsEnv(t) - if IsAws(t) { + loadUcwsEnv(t) + if isAws(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_credential" "external" { From 3e26f55acdcecbcd017ecc28a3e7ea6548a5e2bf Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 13:10:03 +0100 Subject: [PATCH 32/91] some work --- .codegen/model.go.tmpl | 2 +- go.mod | 1 - .../common/complex_field_type_provider.go | 7 +- .../pluginfw/converters/converters_test.go | 185 ++++--- .../providers/pluginfw/converters/go_to_tf.go | 173 ++++--- .../providers/pluginfw/converters/tf_to_go.go | 201 +++----- .../products/catalog/data_functions.go | 2 +- .../pluginfw/products/cluster/data_cluster.go | 2 +- .../products/library/resource_library.go | 2 +- .../data_notification_destinations.go | 2 +- .../resource_quality_monitor.go | 9 +- .../registered_model/data_registered_model.go | 2 +- .../data_registered_model_versions.go | 2 +- .../serving/data_serving_endpoints.go | 2 +- .../pluginfw/products/sharing/data_share.go | 2 +- .../pluginfw/products/sharing/data_shares.go | 2 +- .../products/sharing/resource_share.go | 9 +- .../pluginfw/products/volume/data_volumes.go | 2 +- .../tfschema/customizable_schema_test.go | 72 ++- .../pluginfw/tfschema/struct_to_schema.go | 302 +++-------- .../tfschema/struct_to_schema_test.go | 170 ++++--- internal/service/apps_tf/model.go | 64 +-- internal/service/billing_tf/model.go | 74 +-- internal/service/catalog_tf/model.go | 474 +++++++++--------- internal/service/compute_tf/model.go | 358 ++++++------- internal/service/dashboards_tf/model.go | 94 ++-- internal/service/files_tf/model.go | 72 +-- internal/service/iam_tf/model.go | 136 ++--- internal/service/jobs_tf/model.go | 260 +++++----- internal/service/marketplace_tf/model.go | 226 ++++----- internal/service/ml_tf/model.go | 322 ++++++------ internal/service/oauth2_tf/model.go | 64 +-- internal/service/pipelines_tf/model.go | 118 ++--- internal/service/provisioning_tf/model.go | 104 ++-- internal/service/serving_tf/model.go | 148 +++--- internal/service/settings_tf/model.go | 284 +++++------ internal/service/sharing_tf/model.go | 88 ++-- internal/service/sql_tf/model.go | 296 +++++------ internal/service/vectorsearch_tf/model.go | 86 ++-- internal/service/workspace_tf/model.go | 154 +++--- 40 files changed, 2261 insertions(+), 2312 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index fa98aa898e..7d7e6cbdf3 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -60,7 +60,7 @@ func (newState *{{.PascalName}}) SyncEffectiveFieldsDuringRead(existingState {{. {{- end}} } -func (a {{.PascalName}}) GetComplexFieldTypes() map[string]reflect.Type { +func (a {{.PascalName}}) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ {{- range .Fields -}} {{- if or .Entity.IsObject .Entity.ArrayValue .Entity.MapValue}} diff --git a/go.mod b/go.mod index 2911926b60..3d720939ce 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,6 @@ require ( github.com/hashicorp/hcl v1.0.0 github.com/hashicorp/hcl/v2 v2.23.0 github.com/hashicorp/terraform-plugin-framework v1.13.0 - github.com/hashicorp/terraform-plugin-framework-validators v0.15.0 github.com/hashicorp/terraform-plugin-go v0.25.0 github.com/hashicorp/terraform-plugin-log v0.9.0 github.com/hashicorp/terraform-plugin-mux v0.17.0 diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go index d5538c73b1..c3658c97de 100644 --- a/internal/providers/pluginfw/common/complex_field_type_provider.go +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -8,6 +8,9 @@ import ( ) type ComplexFieldTypeProvider interface { - GetComplexFieldTypes() map[string]reflect.Type - ToAttrType(context.Context) types.ObjectType + GetComplexFieldTypes(context.Context) map[string]reflect.Type +} + +type ObjectTypable interface { + ToObjectType(context.Context) types.ObjectType } diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index 75f4cef630..a30d78cf0b 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -4,32 +4,70 @@ import ( "context" "fmt" "reflect" + "strings" "testing" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/stretchr/testify/assert" ) type DummyTfSdk struct { - Enabled types.Bool `tfsdk:"enabled" tf:"optional"` - Workers types.Int64 `tfsdk:"workers" tf:""` - Floats types.Float64 `tfsdk:"floats" tf:""` - Description types.String `tfsdk:"description" tf:""` - Tasks types.String `tfsdk:"task" tf:"optional"` - NoPointerNested DummyNestedTfSdk `tfsdk:"no_pointer_nested" tf:"optional"` - NestedList []DummyNestedTfSdk `tfsdk:"nested_list" tf:"optional"` - NestedPointerList []*DummyNestedTfSdk `tfsdk:"nested_pointer_list" tf:"optional"` - Map map[string]types.String `tfsdk:"map" tf:"optional"` - NestedMap map[string]DummyNestedTfSdk `tfsdk:"nested_map" tf:"optional"` - Repeated []types.Int64 `tfsdk:"repeated" tf:"optional"` - Attributes map[string]types.String `tfsdk:"attributes" tf:"optional"` - EnumField types.String `tfsdk:"enum_field" tf:"optional"` - AdditionalField types.String `tfsdk:"additional_field" tf:"optional"` - DistinctField types.String `tfsdk:"distinct_field" tf:"optional"` - SliceStruct []DummyNestedTfSdk `tfsdk:"slice_struct" tf:"optional"` - SliceStructPtr []DummyNestedTfSdk `tfsdk:"slice_struct_ptr" tf:"optional"` - Irrelevant types.String `tfsdk:"-"` + Enabled types.Bool `tfsdk:"enabled" tf:"optional"` + Workers types.Int64 `tfsdk:"workers" tf:""` + Floats types.Float64 `tfsdk:"floats" tf:""` + Description types.String `tfsdk:"description" tf:""` + Tasks types.String `tfsdk:"task" tf:"optional"` + NoPointerNested types.List `tfsdk:"no_pointer_nested" tf:"optional"` + NestedList types.List `tfsdk:"nested_list" tf:"optional"` + NestedPointerList types.List `tfsdk:"nested_pointer_list" tf:"optional"` + Map types.Map `tfsdk:"map" tf:"optional"` + NestedMap types.Map `tfsdk:"nested_map" tf:"optional"` + Repeated types.List `tfsdk:"repeated" tf:"optional"` + Attributes types.Map `tfsdk:"attributes" tf:"optional"` + EnumField types.String `tfsdk:"enum_field" tf:"optional"` + AdditionalField types.String `tfsdk:"additional_field" tf:"optional"` + DistinctField types.String `tfsdk:"distinct_field" tf:"optional"` + SliceStructPtr types.List `tfsdk:"slice_struct_ptr" tf:"optional"` + Irrelevant types.String `tfsdk:"-"` +} + +func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "no_pointer_nested": reflect.TypeOf(DummyNestedTfSdk{}), + "nested_list": reflect.TypeOf(DummyNestedTfSdk{}), + "nested_pointer_list": reflect.TypeOf(DummyNestedTfSdk{}), + "map": reflect.TypeOf(""), + "nested_map": reflect.TypeOf(DummyNestedTfSdk{}), + "repeated": reflect.TypeOf(int64(0)), + "attributes": reflect.TypeOf(""), + "slice_struct": reflect.TypeOf(DummyNestedTfSdk{}), + "slice_struct_ptr": reflect.TypeOf(DummyNestedTfSdk{}), + } +} + +func (DummyTfSdk) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "enabled": types.BoolType, + "workers": types.Int64Type, + "floats": types.Float64Type, + "description": types.StringType, + "task": types.StringType, + "no_pointer_nested": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, + "nested_list": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, + "nested_pointer_list": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, + "map": types.MapType{ElemType: types.StringType}, + "nested_map": types.MapType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, + "repeated": types.ListType{ElemType: types.Int64Type}, + "attributes": types.MapType{ElemType: types.StringType}, + "enum_field": types.StringType, + "additional_field": types.StringType, + "distinct_field": types.StringType, + "slice_struct_ptr": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, + }, + } } type TestEnum string @@ -64,6 +102,15 @@ type DummyNestedTfSdk struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } +func (DummyNestedTfSdk) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "name": types.StringType, + "enabled": types.BoolType, + }, + } +} + type DummyGoSdk struct { Enabled bool `json:"enabled"` Workers int64 `json:"workers"` @@ -80,7 +127,6 @@ type DummyGoSdk struct { EnumField TestEnum `json:"enum_field"` AdditionalField string `json:"additional_field"` DistinctField string `json:"distinct_field"` // distinct field that the tfsdk struct doesn't have - SliceStruct DummyNestedGoSdk `json:"slice_struct"` SliceStructPtr *DummyNestedGoSdk `json:"slice_struct_ptr"` ForceSendFields []string `json:"-"` } @@ -91,11 +137,22 @@ type DummyNestedGoSdk struct { ForceSendFields []string `json:"-"` } +func diagToString(d diag.Diagnostics) string { + b := strings.Builder{} + for _, diag := range d { + b.WriteString(fmt.Sprintf("[%s] %s: %s\n", diag.Severity(), diag.Summary(), diag.Detail())) + } + return b.String() +} + // Function to construct individual test case with a pair of matching tfSdkStruct and gosdkStruct. // Verifies that the conversion both ways are working as expected. func RunConverterTest(t *testing.T, description string, tfSdkStruct DummyTfSdk, goSdkStruct DummyGoSdk) { convertedGoSdkStruct := DummyGoSdk{} - assert.True(t, !TfSdkToGoSdkStruct(context.Background(), tfSdkStruct, &convertedGoSdkStruct).HasError()) + d := TfSdkToGoSdkStruct(context.Background(), tfSdkStruct, &convertedGoSdkStruct) + if d.HasError() { + t.Errorf("tfsdk to gosdk conversion: %s", diagToString(d)) + } assert.True(t, reflect.DeepEqual(convertedGoSdkStruct, goSdkStruct), fmt.Sprintf("tfsdk to gosdk conversion - %s", description)) convertedTfSdkStruct := DummyTfSdk{} @@ -121,6 +178,8 @@ func TestGoSdkToTfSdkStructConversionFailure(t *testing.T) { assert.True(t, actualDiagnostics.Equal(expectedDiagnostics)) } +var dummyType = DummyNestedTfSdk{}.ToObjectType(context.Background()) + var tests = []struct { name string tfSdkStruct DummyTfSdk @@ -178,10 +237,14 @@ var tests = []struct { }, { "struct conversion", - DummyTfSdk{NoPointerNested: DummyNestedTfSdk{ - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }}, + DummyTfSdk{NoPointerNested: types.ListValueMust( + dummyType, []attr.Value{ + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(true), + }), + }), + }, DummyGoSdk{NoPointerNested: DummyNestedGoSdk{ Name: "def", Enabled: true, @@ -190,26 +253,28 @@ var tests = []struct { }, { "list conversion", - DummyTfSdk{Repeated: []types.Int64{types.Int64Value(12), types.Int64Value(34)}}, + DummyTfSdk{Repeated: types.ListValueMust(types.Int64Type, []attr.Value{types.Int64Value(12), types.Int64Value(34)})}, DummyGoSdk{Repeated: []int64{12, 34}}, }, { "map conversion", - DummyTfSdk{Attributes: map[string]types.String{"key": types.StringValue("value")}}, + DummyTfSdk{Attributes: types.MapValueMust(types.StringType, map[string]attr.Value{"key": types.StringValue("value")})}, DummyGoSdk{Attributes: map[string]string{"key": "value"}}, }, { "nested list conversion", - DummyTfSdk{NestedList: []DummyNestedTfSdk{ - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }, - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }, - }}, + DummyTfSdk{NestedList: types.ListValueMust(dummyType, + []attr.Value{ + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(true), + }), + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(true), + }), + }), + }, DummyGoSdk{NestedList: []DummyNestedGoSdk{ { Name: "def", @@ -225,16 +290,16 @@ var tests = []struct { }, { "nested map conversion", - DummyTfSdk{NestedMap: map[string]DummyNestedTfSdk{ - "key1": { - Name: types.StringValue("abc"), - Enabled: types.BoolValue(true), - }, - "key2": { - Name: types.StringValue("def"), - Enabled: types.BoolValue(false), - }, - }}, + DummyTfSdk{NestedMap: types.MapValueMust(dummyType, map[string]attr.Value{ + "key1": types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("abc"), + "enabled": types.BoolValue(true), + }), + "key2": types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(false), + }), + })}, DummyGoSdk{NestedMap: map[string]DummyNestedGoSdk{ "key1": { Name: "abc", @@ -248,28 +313,16 @@ var tests = []struct { }, }}, }, - { - "list representation of struct conversion", // we use list with one element in the tfsdk to represent struct in gosdk - DummyTfSdk{SliceStruct: []DummyNestedTfSdk{ - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }, - }}, - DummyGoSdk{SliceStruct: DummyNestedGoSdk{ - Name: "def", - Enabled: true, - ForceSendFields: []string{"Name", "Enabled"}, - }}, - }, { "list representation of struct pointer conversion", // we use list with one element in the tfsdk to represent struct in gosdk - DummyTfSdk{SliceStructPtr: []DummyNestedTfSdk{ - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }, - }}, + DummyTfSdk{SliceStructPtr: types.ListValueMust(dummyType, + []attr.Value{ + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(true), + }), + }), + }, DummyGoSdk{SliceStructPtr: &DummyNestedGoSdk{ Name: "def", Enabled: true, diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index d04e16ca58..24c578a9e1 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -9,7 +9,6 @@ import ( "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" - "github.com/hashicorp/terraform-plugin-log/tflog" "github.com/databricks/terraform-provider-databricks/common" tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" @@ -36,8 +35,7 @@ const goSdkToTfSdkFieldConversionFailureMessage = "gosdk to tfsdk field conversi // map keys should always be a string // tfsdk structs use types.String for all enum values // non-json fields will be omitted -func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{}) diag.Diagnostics { - +func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{}) (d diag.Diagnostics) { srcVal := reflect.ValueOf(gosdk) destVal := reflect.ValueOf(tfsdk) @@ -46,19 +44,27 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ } if destVal.Kind() != reflect.Ptr { - return diag.Diagnostics{diag.NewErrorDiagnostic(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("please provide a pointer for the tfsdk struct, got %s", destVal.Type().Name()))} + d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("please provide a pointer for the tfsdk struct, got %s", destVal.Type().Name())) + return } destVal = destVal.Elem() if srcVal.Kind() != reflect.Struct || destVal.Kind() != reflect.Struct { - return diag.Diagnostics{diag.NewErrorDiagnostic(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("input should be structs %s, %s", srcVal.Type().Name(), destVal.Type().Name()))} + d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("input should be structs, got %s, %s", srcVal.Type().Name(), destVal.Type().Name())) + return } + // complexFieldTypes captures the elements within a types.List, types.Object, or types.Map. var complexFieldTypes map[string]reflect.Type - var objectType types.ObjectType if cftp, ok := destVal.Interface().(tfcommon.ComplexFieldTypeProvider); ok { - complexFieldTypes = cftp.GetComplexFieldTypes() - objectType = cftp.ToAttrType(ctx) + complexFieldTypes = cftp.GetComplexFieldTypes(ctx) + } + + // objectType is the type of the destination struct. Entries from this are used when constructing + // plugin framework attr.Values for fields in the object. + var objectType types.ObjectType + if ot, ok := destVal.Interface().(tfcommon.ObjectTypable); ok { + objectType = ot.ToObjectType(ctx) } var forceSendFieldVal []string @@ -95,12 +101,12 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ innerType := objectType.AttrTypes[destFieldName] complexFieldType := complexFieldTypes[destFieldName] - err := goSdkToTfSdkSingleField(ctx, srcField, destField, fieldInForceSendFields(srcFieldName, forceSendFieldVal), innerType, complexFieldType) - if err != nil { - return diag.Diagnostics{diag.NewErrorDiagnostic(goSdkToTfSdkFieldConversionFailureMessage, err.Error())} + d.Append(goSdkToTfSdkSingleField(ctx, srcField, destField, fieldInForceSendFields(srcFieldName, forceSendFieldVal), innerType, complexFieldType)...) + if d.HasError() { + return } } - return nil + return } func goSdkToTfSdkSingleField( @@ -109,10 +115,10 @@ func goSdkToTfSdkSingleField( destField reflect.Value, forceSendField bool, innerType attr.Type, - complexFieldType reflect.Type) error { - + complexFieldType reflect.Type) (d diag.Diagnostics) { if !destField.CanSet() { - panic(fmt.Errorf("destination field can not be set: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("destination field can not be set: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) + return d } srcFieldValue := srcField.Interface() @@ -122,6 +128,7 @@ func goSdkToTfSdkSingleField( } if srcField.Kind() == reflect.Ptr { + // Skip nils, but make sure to set the destination fields of type list to an empty list. if srcField.IsNil() { // If the destination field is a types.List, treat the source field as an empty slice. if destField.Type() == reflect.TypeOf(types.List{}) { @@ -129,7 +136,6 @@ func goSdkToTfSdkSingleField( emptyList := types.ListNull(listType.ElemType) destField.Set(reflect.ValueOf(emptyList)) } - // Skip nils return nil } srcField = srcField.Elem() @@ -168,7 +174,12 @@ func goSdkToTfSdkSingleField( var strVal string if srcField.Type().Name() != "string" { // This case is for Enum Types. - strVal = getStringFromEnum(srcField) + var ds diag.Diagnostics + strVal, ds = getStringFromEnum(srcField) + d.Append(ds...) + if d.HasError() { + return + } } else { strVal = srcFieldValue.(string) } @@ -189,6 +200,7 @@ func goSdkToTfSdkSingleField( // Skip zeros return nil } + // If the destination field is a types.List, treat the source field as a slice with length 1 // containing only this struct. if destField.Type() == reflect.TypeOf(types.List{}) { @@ -197,84 +209,84 @@ func goSdkToTfSdkSingleField( return goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, innerType, complexFieldType) } - var dest any - if destField.Kind() == reflect.Slice { - // allocate a slice first - destSlice := reflect.MakeSlice(destField.Type(), 1, 1) - destField.Set(destSlice) - dest = destSlice.Index(0).Addr().Interface() - } else { - dest = destField.Addr().Interface() + // Otherwise, the destination field is a types.Object. Convert the nested struct to the corresponding + // TFSDK struct, then set the destination field to the object + dest := reflect.New(complexFieldType).Elem() + d.Append(GoSdkToTfSdkStruct(ctx, srcFieldValue, dest)...) + if d.HasError() { + return + } + objectType, ok := innerType.(types.ObjectType) + if !ok { + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not an object type: %s. %s", innerType, common.TerraformBugErrorMessage)) + return } - // resolve the nested struct by recursively calling the function - if GoSdkToTfSdkStruct(ctx, srcFieldValue, dest).HasError() { - panic(fmt.Sprintf("%s. %s", goSdkToTfSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) + objectVal, ds := types.ObjectValueFrom(ctx, objectType.AttrTypes, dest.Interface()) + d.Append(ds...) + if d.HasError() { + return } + destField.Set(reflect.ValueOf(objectVal)) case reflect.Slice: - // If the target is a types.List, we first convert each element of the slice to the corresponding inner type - // and then set the list. - if destField.Type() == reflect.TypeOf(types.List{}) { - listType, ok := innerType.(types.ListType) - if !ok { - panic(fmt.Errorf("inner type is not a list type: %s. %s", innerType, common.TerraformBugErrorMessage)) - } - elements := make([]any, 0, srcField.Len()) - for i := 0; i < srcField.Len(); i++ { - element := reflect.New(complexFieldType).Elem() - if err := goSdkToTfSdkSingleField(ctx, srcField.Index(i), element, true, listType.ElemType, complexFieldType); err != nil { - return err - } - elements = append(elements, element.Interface()) - } - destVal, d := types.ListValueFrom(ctx, listType.ElemType, elements) + listType, ok := innerType.(types.ListType) + if !ok { + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a list type: %s. %s", innerType, common.TerraformBugErrorMessage)) + return + } + + // Convert each element of the slice to the corresponding inner type. + elements := make([]any, 0, srcField.Len()) + for i := 0; i < srcField.Len(); i++ { + element := reflect.New(complexFieldType).Elem() + d.Append(goSdkToTfSdkSingleField(ctx, srcField.Index(i), element, true, listType.ElemType, complexFieldType)...) if d.HasError() { - for _, diag := range d { - tflog.Error(ctx, diag.Detail()) - } - panic(fmt.Sprintf("%s. %s", goSdkToTfSdkFieldConversionFailureMessage, common.TerraformBugErrorMessage)) - } - destField.Set(reflect.ValueOf(destVal)) - } else { - if srcField.IsNil() { - // Skip nils - return nil + return } - destSlice := reflect.MakeSlice(destField.Type(), srcField.Len(), srcField.Cap()) - for j := 0; j < srcField.Len(); j++ { - - srcElem := srcField.Index(j) + elements = append(elements, element.Interface()) + } - destElem := destSlice.Index(j) - if err := goSdkToTfSdkSingleField(ctx, srcElem, destElem, true, innerType, complexFieldType); err != nil { - return err - } - } - destField.Set(destSlice) + // Construct the Terraform value and set it. + destVal, ds := types.ListValueFrom(ctx, listType.ElemType, elements) + d.Append(ds...) + if d.HasError() { + return } + destField.Set(reflect.ValueOf(destVal)) case reflect.Map: - if srcField.IsNil() { - // Skip nils - return nil + mapType, ok := innerType.(types.MapType) + if !ok { + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a map type: %s. %s", innerType, common.TerraformBugErrorMessage)) + return } - destMap := reflect.MakeMap(destField.Type()) + + // Convert each key-value pair of the map to the corresponding inner type. + destMap := map[string]attr.Value{} for _, key := range srcField.MapKeys() { srcMapValue := srcField.MapIndex(key) destMapValue := reflect.New(destField.Type().Elem()).Elem() destMapKey := reflect.ValueOf(key.Interface()) - if err := goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue, true, innerType, complexFieldType); err != nil { - return err + d.Append(goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue, true, mapType.ElemType, complexFieldType)...) + if d.HasError() { + return } - destMap.SetMapIndex(destMapKey, destMapValue) + destMap[destMapKey.String()] = destMapValue.Interface().(attr.Value) } - destField.Set(destMap) + + // Construct the Terraform value and set it. + destVal, ds := types.MapValueFrom(ctx, mapType.ElemType, destMap) + d.Append(ds...) + if d.HasError() { + return + } + destField.Set(reflect.ValueOf(destVal)) default: - panic(fmt.Errorf("unknown type for field: %s. %s", srcField.Type().Name(), common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("%s is not currently supported as a source field. %s", srcField.Type().Name(), common.TerraformBugErrorMessage)) } - return nil + return } // Get the string value of an enum by calling the .String() method on the enum object. -func getStringFromEnum(srcField reflect.Value) string { +func getStringFromEnum(srcField reflect.Value) (s string, d diag.Diagnostics) { var stringMethod reflect.Value if srcField.CanAddr() { stringMethod = srcField.Addr().MethodByName("String") @@ -288,13 +300,14 @@ func getStringFromEnum(srcField reflect.Value) string { if stringMethod.IsValid() { stringResult := stringMethod.Call(nil) if len(stringResult) == 1 { - return stringResult[0].Interface().(string) - } else { - panic(fmt.Sprintf("num get string has more than one result. %s", common.TerraformBugErrorMessage)) + s = stringResult[0].Interface().(string) + return } - } else { - panic(fmt.Sprintf("enum does not have valid .String() method. %s", common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("num get string has more than one result. %s", common.TerraformBugErrorMessage)) + return } + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("enum does not have valid .String() method. %s", common.TerraformBugErrorMessage)) + return } func fieldInForceSendFields(fieldName string, forceSendFields []string) bool { diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 78da633214..419cc4c110 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -5,10 +5,11 @@ import ( "fmt" "reflect" - "github.com/databricks/databricks-sdk-go/logger" tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" "github.com/hashicorp/terraform-plugin-log/tflog" "github.com/databricks/terraform-provider-databricks/common" @@ -34,7 +35,7 @@ const tfSdkToGoSdkFieldConversionFailureMessage = "tfsdk to gosdk field conversi // types.list and types.map are not supported // map keys should always be a string // tfsdk structs use types.String for all enum values -func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{}) diag.Diagnostics { +func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{}) (d diag.Diagnostics) { srcVal := reflect.ValueOf(tfsdk) destVal := reflect.ValueOf(gosdk) @@ -43,19 +44,21 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ } if destVal.Kind() != reflect.Ptr { - return diag.Diagnostics{diag.NewErrorDiagnostic(tfSdkToGoSdkStructConversionFailureMessage, fmt.Sprintf("please provide a pointer for the gosdk struct, got %s", destVal.Type().Name()))} + d.AddError(tfSdkToGoSdkStructConversionFailureMessage, fmt.Sprintf("please provide a pointer for the gosdk struct, got %s", destVal.Type().Name())) + return } destVal = destVal.Elem() if srcVal.Kind() != reflect.Struct { - return diag.Diagnostics{diag.NewErrorDiagnostic(tfSdkToGoSdkStructConversionFailureMessage, fmt.Sprintf("input should be structs, got %s,", srcVal.Type().Name()))} + d.AddError(tfSdkToGoSdkStructConversionFailureMessage, fmt.Sprintf("input should be structs, got %s,", srcVal.Type().Name())) + return } forceSendFieldsField := destVal.FieldByName("ForceSendFields") var innerTypes map[string]reflect.Type if cftp, ok := tfsdk.(tfcommon.ComplexFieldTypeProvider); ok { - innerTypes = cftp.GetComplexFieldTypes() + innerTypes = cftp.GetComplexFieldTypes(ctx) } allFields := tfreflect.ListAllFields(srcVal) @@ -71,9 +74,9 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ destField := destVal.FieldByName(srcFieldName) innerType := innerTypes[srcFieldTag] - err := tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField, innerType) - if err != nil { - return diag.Diagnostics{diag.NewErrorDiagnostic(tfSdkToGoSdkFieldConversionFailureMessage, err.Error())} + d.Append(tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField, innerType)...) + if d.HasError() { + return } } @@ -86,92 +89,25 @@ func tfSdkToGoSdkSingleField( destField reflect.Value, srcFieldName string, forceSendFieldsField *reflect.Value, - innerType reflect.Type) error { + innerType reflect.Type) (d diag.Diagnostics) { if !destField.IsValid() { // Skip field that destination struct does not have. - logger.Tracef(ctx, fmt.Sprintf("field skipped in tfsdk to gosdk conversion: destination struct does not have field %s", srcFieldName)) - return nil + tflog.Trace(ctx, fmt.Sprintf("field skipped in tfsdk to gosdk conversion: destination struct does not have field %s", srcFieldName)) + return } if !destField.CanSet() { - panic(fmt.Errorf("destination field can not be set: %T. %s", destField.Type(), common.TerraformBugErrorMessage)) + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("destination field can not be set: %T. %s", destField.Type(), common.TerraformBugErrorMessage)) + return } - srcFieldValue := srcField.Interface() - - if srcFieldValue == nil { - return nil - } else if srcField.Kind() == reflect.Ptr { - if srcField.IsNil() { - // Skip nils - return nil - } - // Allocate new memory for the destination field - destField.Set(reflect.New(destField.Type().Elem())) - // Recursively populate the nested struct. - if TfSdkToGoSdkStruct(ctx, srcFieldValue, destField.Interface()).HasError() { - panic(fmt.Sprintf("%s. %s", tfSdkToGoSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) - } - } else if srcField.Kind() == reflect.Slice && destField.Kind() == reflect.Struct { - if srcField.IsNil() { - // Skip nils - return nil - } - assertStructSliceLengthIsOne(srcField) - tfsdkToGoSdkStructField(srcField.Index(0), destField, srcFieldName, forceSendFieldsField, ctx, innerType) - } else if srcField.Kind() == reflect.Slice && destField.Kind() == reflect.Ptr { - if srcField.IsNil() { - // Skip nils - return nil - } - destField.Set(reflect.New(destField.Type().Elem())) - - assertStructSliceLengthIsOne(srcField) - - // Recursively populate the nested struct. - if TfSdkToGoSdkStruct(ctx, srcField.Index(0).Interface(), destField.Interface()).HasError() { - panic(fmt.Sprintf("%s. %s", tfSdkToGoSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) - } - } else if srcField.Kind() == reflect.Struct { - tfsdkToGoSdkStructField(srcField, destField, srcFieldName, forceSendFieldsField, ctx, innerType) - } else if srcField.Kind() == reflect.Slice { - if srcField.IsNil() { - // Skip nils - return nil - } - destSlice := reflect.MakeSlice(destField.Type(), srcField.Len(), srcField.Cap()) - for j := 0; j < srcField.Len(); j++ { - - srcElem := srcField.Index(j) - - destElem := destSlice.Index(j) - if err := tfSdkToGoSdkSingleField(ctx, srcElem, destElem, "", nil, innerType); err != nil { - return err - } - } - destField.Set(destSlice) - } else if srcField.Kind() == reflect.Map { - if srcField.IsNil() { - // Skip nils - return nil - } - destMap := reflect.MakeMap(destField.Type()) - for _, key := range srcField.MapKeys() { - srcMapValue := srcField.MapIndex(key) - destMapValue := reflect.New(destField.Type().Elem()).Elem() - destMapKey := reflect.ValueOf(key.Interface()) - if err := tfSdkToGoSdkSingleField(ctx, srcMapValue, destMapValue, "", nil, innerType); err != nil { - return err - } - destMap.SetMapIndex(destMapKey, destMapValue) - } - destField.Set(destMap) - } else { - panic(fmt.Errorf("unknown type for field: %s. %s", srcField.Type().Name(), common.TerraformBugErrorMessage)) + if srcField.Kind() == reflect.Struct { + d.Append(tfsdkToGoSdkStructField(srcField, destField, srcFieldName, forceSendFieldsField, ctx, innerType)...) + return } - return nil - + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", srcField.Interface(), common.TerraformBugErrorMessage)) + return } // Returns a reflect.Value of the enum type with the value set to the given string. @@ -202,24 +138,21 @@ func tfsdkToGoSdkStructField( srcFieldName string, forceSendFieldsField *reflect.Value, ctx context.Context, - innerType reflect.Type) { - srcFieldValue := srcField.Interface() + innerType reflect.Type) (d diag.Diagnostics) { + srcFieldValue := srcField.Interface().(attr.Value) + if srcFieldValue.IsUnknown() { + return + } + if !srcFieldValue.IsNull() { + addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) + } switch v := srcFieldValue.(type) { case types.Bool: destField.SetBool(v.ValueBool()) - if !v.IsNull() { - addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) - } case types.Int64: destField.SetInt(v.ValueInt64()) - if !v.IsNull() { - addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) - } case types.Float64: destField.SetFloat(v.ValueFloat64()) - if !v.IsNull() { - addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) - } case types.String: if destField.Type().Name() != "string" { // This is the case for enum. @@ -234,33 +167,30 @@ func tfsdkToGoSdkStructField( destField.Set(destVal) } else { destField.SetString(v.ValueString()) - if !v.IsNull() { - addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) - } } case types.List: - if v.IsNull() || v.IsUnknown() { + // Empty lists correspond to nil slices or the struct zero value. + if v.IsNull() { return } - var d diag.Diagnostics - innerValue := reflect.New(reflect.SliceOf(innerType)) - // Read the nested elements into the TFSDK struct slice - d = v.ElementsAs(ctx, innerValue.Interface(), true) + innerValue := reflect.MakeSlice(reflect.SliceOf(innerType), 0, len(v.Elements())).Interface() + d.Append(v.ElementsAs(ctx, &innerValue, true)...) if d.HasError() { - for _, diag := range d { - tflog.Error(ctx, fmt.Sprintf("[ERROR] %s: %s", diag.Summary(), diag.Detail())) - } - panic("failed to convert list") + return } + innerValues := innerValue.([]interface{}) // Recursively call TFSDK to GOSDK conversion for each element in the list var destInnerType reflect.Type if destField.Type().Kind() == reflect.Slice { destInnerType = destField.Type().Elem() } else { - assertStructSliceLengthIsOne(innerValue.Elem()) + if len(innerValues) > 1 { + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("The length of a slice can not be greater than 1 if it is representing a struct, %s", common.TerraformBugErrorMessage)) + return + } // Case of types.List <-> struct or ptr if destField.Type().Kind() == reflect.Ptr { destInnerType = destField.Type().Elem() @@ -269,12 +199,12 @@ func tfsdkToGoSdkStructField( } } - converted := reflect.MakeSlice(reflect.SliceOf(destInnerType), 0, innerValue.Elem().Len()) - for i := 0; i < innerValue.Elem().Len(); i++ { + converted := reflect.MakeSlice(reflect.SliceOf(destInnerType), 0, len(innerValues)) + for _, vv := range innerValues { next := reflect.New(destInnerType).Elem() - err := tfSdkToGoSdkSingleField(ctx, innerValue.Elem().Index(i), next, srcFieldName, forceSendFieldsField, innerType) - if err != nil { - panic(err) + d.Append(tfSdkToGoSdkSingleField(ctx, reflect.ValueOf(vv), next, srcFieldName, forceSendFieldsField, innerType)...) + if d.HasError() { + return } converted = reflect.Append(converted, next) } @@ -286,24 +216,41 @@ func tfsdkToGoSdkStructField( } else { destField.Set(converted.Index(0)) } - case types.Object, types.Map, types.Set, types.Tuple: - panic(fmt.Sprintf("%T should never be used, use go native maps instead. %s", v, common.TerraformBugErrorMessage)) - default: - if srcField.IsZero() { - // Skip zeros + case types.Map: + // Empty maps correspond to nil maps or the struct zero value. + if v.IsNull() { return } - // If it is a real stuct instead of a tfsdk type, recursively resolve it. - if TfSdkToGoSdkStruct(ctx, srcFieldValue, destField.Addr().Interface()).HasError() { - panic(fmt.Sprintf("%s. %s", tfSdkToGoSdkStructConversionFailureMessage, common.TerraformBugErrorMessage)) + + // Read the nested elements into the TFSDK struct map + innerValue := reflect.MakeMap(reflect.MapOf(reflect.TypeOf(""), innerType)) + d.Append(v.ElementsAs(ctx, innerValue.Interface(), true)...) + if d.HasError() { + return + } + + // Recursively call TFSDK to GOSDK conversion for each element in the map + converted := reflect.MakeMap(destField.Type()) + for _, key := range innerValue.MapKeys() { + next := reflect.New(innerType).Elem() + d.Append(tfSdkToGoSdkSingleField(ctx, innerValue.MapIndex(key), next, srcFieldName, forceSendFieldsField, innerType)...) + if d.HasError() { + return + } + converted.SetMapIndex(key, next) } - } -} -func assertStructSliceLengthIsOne(srcSlice reflect.Value) { - if srcSlice.Len() > 1 { - panic(fmt.Sprintf("The length of a slice can not be greater than 1 if it is representing a struct, %s", common.TerraformBugErrorMessage)) + destField.Set(converted) + case types.Object: + d.Append(v.As(ctx, destField.Addr().Interface(), basetypes.ObjectAsOptions{UnhandledNullAsEmpty: true, UnhandledUnknownAsEmpty: true})...) + case types.Set, types.Tuple: + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("%T is not currently supported as a source field. %s", v, common.TerraformBugErrorMessage)) + return + default: + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", v, common.TerraformBugErrorMessage)) + return } + return } func addToForceSendFields(ctx context.Context, fieldName string, forceSendFieldsField *reflect.Value) { diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index 9f6c3aba6c..900055e47e 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -41,7 +41,7 @@ func (d *FunctionsDataSource) Metadata(ctx context.Context, req datasource.Metad } func (d *FunctionsDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(FunctionsData{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, FunctionsData{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index 8d0499ccb8..b0fafc189d 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -42,7 +42,7 @@ func (d *ClusterDataSource) Metadata(ctx context.Context, req datasource.Metadat } func (d *ClusterDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(ClusterInfo{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, ClusterInfo{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/library/resource_library.go b/internal/providers/pluginfw/products/library/resource_library.go index 2f9d8b9ea8..178687495d 100644 --- a/internal/providers/pluginfw/products/library/resource_library.go +++ b/internal/providers/pluginfw/products/library/resource_library.go @@ -87,7 +87,7 @@ func (r *LibraryResource) Metadata(ctx context.Context, req resource.MetadataReq } func (r *LibraryResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { - attrs, blocks := tfschema.ResourceStructToSchemaMap(LibraryExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, LibraryExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { for field, attribute := range c.ToNestedBlockObject().Attributes { switch attribute.(type) { case tfschema.StringAttributeBuilder: diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index 8b48a74e33..e28a6b3043 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -42,7 +42,7 @@ func (d *NotificationDestinationsDataSource) Metadata(ctx context.Context, req d } func (d *NotificationDestinationsDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(NotificationDestinationsInfo{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, NotificationDestinationsInfo{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go index d7939241a6..5641c0a9c4 100644 --- a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go +++ b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go @@ -63,12 +63,13 @@ type MonitorInfoExtended struct { } var _ pluginfwcommon.ComplexFieldTypeProvider = MonitorInfoExtended{} +var _ pluginfwcommon.ObjectTypable = MonitorInfoExtended{} -func (m MonitorInfoExtended) GetComplexFieldTypes() map[string]reflect.Type { - return m.MonitorInfo.GetComplexFieldTypes() +func (m MonitorInfoExtended) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return m.MonitorInfo.GetComplexFieldTypes(ctx) } -func (m MonitorInfoExtended) ToAttrType(ctx context.Context) types.ObjectType { +func (m MonitorInfoExtended) ToObjectType(ctx context.Context) types.ObjectType { tpe := m.MonitorInfo.ToAttrType(ctx) tpe.AttrTypes["warehouse_id"] = types.StringType tpe.AttrTypes["skip_builtin_dashboard"] = types.BoolType @@ -85,7 +86,7 @@ func (r *QualityMonitorResource) Metadata(ctx context.Context, req resource.Meta } func (r *QualityMonitorResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { - attrs, blocks := tfschema.ResourceStructToSchemaMap(MonitorInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, MonitorInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { c.SetRequired("assets_dir") c.SetRequired("output_schema_name") c.SetReadOnly("monitor_version") diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index e98b69bde8..2f6b0bf7a8 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -43,7 +43,7 @@ func (d *RegisteredModelDataSource) Metadata(ctx context.Context, req datasource } func (d *RegisteredModelDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(RegisteredModelData{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, RegisteredModelData{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go index 916221032a..d70f6e44df 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go @@ -34,7 +34,7 @@ func (d *RegisteredModelVersionsDataSource) Metadata(ctx context.Context, req da } func (d *RegisteredModelVersionsDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(RegisteredModelVersionsData{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, RegisteredModelVersionsData{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go index 48068ad072..4f007d7ac6 100644 --- a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go +++ b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go @@ -32,7 +32,7 @@ func (d *ServingEndpointsDataSource) Metadata(ctx context.Context, req datasourc } func (d *ServingEndpointsDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(ServingEndpointsData{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, ServingEndpointsData{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/sharing/data_share.go b/internal/providers/pluginfw/products/sharing/data_share.go index 5855283c14..bfb9cbb9d4 100644 --- a/internal/providers/pluginfw/products/sharing/data_share.go +++ b/internal/providers/pluginfw/products/sharing/data_share.go @@ -32,7 +32,7 @@ func (d *ShareDataSource) Metadata(ctx context.Context, req datasource.MetadataR } func (d *ShareDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(sharing_tf.ShareInfo{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, sharing_tf.ShareInfo{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/sharing/data_shares.go b/internal/providers/pluginfw/products/sharing/data_shares.go index 7b996ab33e..51a50210ef 100644 --- a/internal/providers/pluginfw/products/sharing/data_shares.go +++ b/internal/providers/pluginfw/products/sharing/data_shares.go @@ -35,7 +35,7 @@ func (d *SharesDataSource) Metadata(ctx context.Context, req datasource.Metadata } func (d *SharesDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(SharesList{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, SharesList{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index d6f099bbc5..6fa49e6c8e 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -36,12 +36,13 @@ type ShareInfoExtended struct { } var _ pluginfwcommon.ComplexFieldTypeProvider = ShareInfoExtended{} +var _ pluginfwcommon.ObjectTypable = ShareInfoExtended{} -func (s ShareInfoExtended) GetComplexFieldTypes() map[string]reflect.Type { - return s.ShareInfo.GetComplexFieldTypes() +func (s ShareInfoExtended) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return s.ShareInfo.GetComplexFieldTypes(ctx) } -func (s ShareInfoExtended) ToAttrType(ctx context.Context) types.ObjectType { +func (s ShareInfoExtended) ToObjectType(ctx context.Context) types.ObjectType { return s.ShareInfo.ToAttrType(ctx) } @@ -150,7 +151,7 @@ func (r *ShareResource) Metadata(ctx context.Context, req resource.MetadataReque } func (r *ShareResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { - attrs, blocks := tfschema.ResourceStructToSchemaMap(ShareInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, ShareInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { c.SetRequired("name") c.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") // ForceNew diff --git a/internal/providers/pluginfw/products/volume/data_volumes.go b/internal/providers/pluginfw/products/volume/data_volumes.go index 6a4af53ba0..17988e2685 100644 --- a/internal/providers/pluginfw/products/volume/data_volumes.go +++ b/internal/providers/pluginfw/products/volume/data_volumes.go @@ -39,7 +39,7 @@ func (d *VolumesDataSource) Metadata(ctx context.Context, req datasource.Metadat } func (d *VolumesDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(VolumesList{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, VolumesList{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 512e3d93a1..27350ddb4a 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -3,8 +3,10 @@ package tfschema import ( "context" "fmt" + "reflect" "testing" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" @@ -14,10 +16,33 @@ import ( ) type TestTfSdk struct { - Description types.String `tfsdk:"description" tf:""` - Nested *NestedTfSdk `tfsdk:"nested" tf:"optional"` - NestedSliceObject []NestedTfSdk `tfsdk:"nested_slice_object" tf:"optional,object"` - Map map[string]types.String `tfsdk:"map" tf:"optional"` + Description types.String `tfsdk:"description" tf:""` + Nested types.List `tfsdk:"nested" tf:"optional"` + NestedSliceObject types.List `tfsdk:"nested_slice_object" tf:"optional,object"` + Map types.Map `tfsdk:"map" tf:"optional"` +} + +func (TestTfSdk) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "nested": reflect.TypeOf(NestedTfSdk{}), + "nested_slice_object": reflect.TypeOf(NestedTfSdk{}), + "map": reflect.TypeOf(types.StringType), + } +} + +func (TestTfSdk) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "description": types.StringType, + "nested": types.ListType{ + ElemType: NestedTfSdk{}.ToAttrType(ctx), + }, + "nested_slice_object": types.ListType{ + ElemType: NestedTfSdk{}.ToAttrType(ctx), + }, + "map": types.StringType, + }, + } } type NestedTfSdk struct { @@ -25,6 +50,19 @@ type NestedTfSdk struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } +func (NestedTfSdk) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + +func (NestedTfSdk) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "name": types.StringType, + "enabled": types.BoolType, + }, + } +} + type stringLengthBetweenValidator struct { Max int Min int @@ -61,7 +99,7 @@ func (v stringLengthBetweenValidator) ValidateString(ctx context.Context, req va } func TestCustomizeSchemaSetRequired(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetRequired("nested", "enabled") return c }) @@ -70,7 +108,7 @@ func TestCustomizeSchemaSetRequired(t *testing.T) { } func TestCustomizeSchemaSetOptional(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetOptional("description") return c }) @@ -79,7 +117,7 @@ func TestCustomizeSchemaSetOptional(t *testing.T) { } func TestCustomizeSchemaSetSensitive(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetSensitive("nested", "name") return c }) @@ -88,7 +126,7 @@ func TestCustomizeSchemaSetSensitive(t *testing.T) { } func TestCustomizeSchemaSetDeprecated(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetDeprecated("deprecated", "map") return c }) @@ -97,7 +135,7 @@ func TestCustomizeSchemaSetDeprecated(t *testing.T) { } func TestCustomizeSchemaSetReadOnly(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetReadOnly("map") return c }) @@ -107,7 +145,7 @@ func TestCustomizeSchemaSetReadOnly(t *testing.T) { } func TestCustomizeSchemaAddValidator(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.AddValidator(stringLengthBetweenValidator{}, "description") return c }) @@ -116,7 +154,7 @@ func TestCustomizeSchemaAddValidator(t *testing.T) { } func TestCustomizeSchemaAddPlanModifier(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.AddPlanModifier(stringplanmodifier.RequiresReplace(), "description") return c }) @@ -125,7 +163,7 @@ func TestCustomizeSchemaAddPlanModifier(t *testing.T) { } func TestCustomizeSchemaObjectTypeValidatorAdded(t *testing.T) { - scm := ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { return c }) @@ -134,7 +172,7 @@ func TestCustomizeSchemaObjectTypeValidatorAdded(t *testing.T) { func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { - _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetRequired("nested") return c }) @@ -143,7 +181,7 @@ func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { - _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetOptional("nested") return c }) @@ -152,7 +190,7 @@ func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { - _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetSensitive("nested") return c }) @@ -161,7 +199,7 @@ func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { - _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetReadOnly("nested") return c }) @@ -170,7 +208,7 @@ func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetComputed_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { - _ = ResourceStructToSchema(TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.SetComputed("nested") return c }) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 80f7f4d445..7d8f0c9887 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -1,6 +1,7 @@ package tfschema import ( + "context" "fmt" "reflect" "strings" @@ -8,11 +9,9 @@ import ( "github.com/databricks/terraform-provider-databricks/common" tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" - "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" "github.com/hashicorp/terraform-plugin-framework/attr" dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" - "github.com/hashicorp/terraform-plugin-framework/schema/validator" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -22,7 +21,7 @@ type structTag struct { singleObject bool } -func typeToSchema(v reflect.Value) NestedBlockObject { +func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { scmAttr := map[string]AttributeBuilder{} scmBlock := map[string]BlockBuilder{} rk := v.Kind() @@ -33,240 +32,91 @@ func typeToSchema(v reflect.Value) NestedBlockObject { if rk != reflect.Struct { panic(fmt.Errorf("schema value of Struct is expected, but got %s: %#v. %s", rk.String(), v, common.TerraformBugErrorMessage)) } - fields := tfreflect.ListAllFields(v) - // Get metadata about complex fields - var complexFieldTypes map[string]reflect.Type - if provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider); ok { - complexFieldTypes = provider.GetComplexFieldTypes() - } - - for _, field := range fields { + for _, field := range tfreflect.ListAllFields(v) { typeField := field.StructField fieldName := typeField.Tag.Get("tfsdk") if fieldName == "-" { continue } structTag := getStructTag(typeField) - kind := typeField.Type.Kind() - value := field.Value - typeFieldType := typeField.Type - if kind == reflect.Ptr { - typeFieldType = typeFieldType.Elem() - kind = typeFieldType.Kind() - value = reflect.New(typeFieldType).Elem() - } - if kind == reflect.Slice { - elemType := typeFieldType.Elem() - if elemType.Kind() == reflect.Ptr { - elemType = elemType.Elem() + value := field.Value.Interface() + switch value.(type) { + case types.Bool: + scmAttr[fieldName] = BoolAttributeBuilder{} + case types.Int64: + scmAttr[fieldName] = Int64AttributeBuilder{} + case types.Float64: + scmAttr[fieldName] = Float64AttributeBuilder{} + case types.String: + scmAttr[fieldName] = StringAttributeBuilder{} + case types.List, types.Map, types.Object: + // Additional metadata is required to determine the type of the list elements. + // This is available via the ComplexFieldTypeProvider interface, implemented on the parent type. + provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider) + if !ok { + panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) } - if elemType.Kind() != reflect.Struct { - panic(fmt.Errorf("unsupported slice value for %s: %s. %s", fieldName, elemType.Kind().String(), common.TerraformBugErrorMessage)) + complexFieldTypes := provider.GetComplexFieldTypes(ctx) + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } - switch elemType { - case reflect.TypeOf(types.Bool{}): - scmAttr[fieldName] = ListAttributeBuilder{ - ElementType: types.BoolType, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case reflect.TypeOf(types.Int64{}): - scmAttr[fieldName] = ListAttributeBuilder{ - ElementType: types.Int64Type, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case reflect.TypeOf(types.Float64{}): - scmAttr[fieldName] = ListAttributeBuilder{ - ElementType: types.Float64Type, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case reflect.TypeOf(types.String{}): - scmAttr[fieldName] = ListAttributeBuilder{ - ElementType: types.StringType, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, + // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. + // Otherwise, use ListNestedBlockBuilder. + switch fieldType { + // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. + // If new types are added there, they must also be added here to work properly. + case reflect.TypeOf(types.BoolType), reflect.TypeOf(types.Int64Type), reflect.TypeOf(types.Float64Type), reflect.TypeOf(types.StringType): + elementType := reflect.New(fieldType).Elem().Interface().(attr.Type) + switch value.(type) { + case types.List: + scmAttr[fieldName] = ListAttributeBuilder{ElementType: elementType} + case types.Map: + scmAttr[fieldName] = MapAttributeBuilder{ElementType: elementType} + case types.Object: + panic(fmt.Errorf("object fields must correspond to a complex type, got %s. %s", fieldType.Name(), common.TerraformBugErrorMessage)) } default: - // Nested struct - nestedScm := typeToSchema(reflect.New(elemType).Elem()) - var validators []validator.List - if structTag.singleObject { - validators = append(validators, listvalidator.SizeAtMost(1)) - } - scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Attributes: nestedScm.Attributes, - Blocks: nestedScm.Blocks, - }, - Validators: validators, - } - } - } else if kind == reflect.Map { - elemType := typeFieldType.Elem() - if elemType.Kind() == reflect.Ptr { - elemType = elemType.Elem() - } - if elemType.Kind() != reflect.Struct { - panic(fmt.Errorf("unsupported map value for %s: %s. %s", fieldName, elemType.Kind().String(), common.TerraformBugErrorMessage)) - } - switch elemType { - case reflect.TypeOf(types.Bool{}): - scmAttr[fieldName] = MapAttributeBuilder{ - ElementType: types.BoolType, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case reflect.TypeOf(types.Int64{}): - scmAttr[fieldName] = MapAttributeBuilder{ - ElementType: types.Int64Type, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case reflect.TypeOf(types.Float64{}): - scmAttr[fieldName] = MapAttributeBuilder{ - ElementType: types.Float64Type, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case reflect.TypeOf(types.String{}): - scmAttr[fieldName] = MapAttributeBuilder{ - ElementType: types.StringType, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - default: - // Nested struct - nestedScm := typeToSchema(reflect.New(elemType).Elem()) - scmAttr[fieldName] = MapNestedAttributeBuilder{ - NestedObject: NestedAttributeObject{ - Attributes: nestedScm.Attributes, - }, - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - } - } else if kind == reflect.Struct { - switch value.Interface().(type) { - case types.Bool: - scmAttr[fieldName] = BoolAttributeBuilder{ - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case types.Int64: - scmAttr[fieldName] = Int64AttributeBuilder{ - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case types.Float64: - scmAttr[fieldName] = Float64AttributeBuilder{ - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case types.String: - scmAttr[fieldName] = StringAttributeBuilder{ - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - case types.List: - // Look up nested struct type - if complexFieldTypes == nil { - panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) - } - fieldType, ok := complexFieldTypes[fieldName] - if !ok { - panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) - } - // If the field type is a "primitive", use ListAttributeBuilder - // otherwise use ListNestedBlockBuilder - switch fieldType { - case reflect.TypeOf(types.BoolType), reflect.TypeOf(types.Int64Type), reflect.TypeOf(types.Float64Type), reflect.TypeOf(types.StringType): - scmAttr[fieldName] = ListAttributeBuilder{ - ElementType: reflect.New(fieldType).Elem().Interface().(attr.Type), - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, - } - default: - fieldValue := reflect.New(fieldType).Elem() - - // Generate the nested block schema - // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). - scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: typeToSchema(fieldValue), - } - } - case types.Object: - // Look up nested struct type - if complexFieldTypes == nil { - panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) - } - fieldType, ok := complexFieldTypes[fieldName] - if !ok { - panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) - } + // The element type is a TFSDK type. Map fields are treated as MapNestedAttributes. For compatibility, + // list fields are treated as ListNestedBlocks. + // TODO: Change the default for lists to ListNestedAttribute. fieldValue := reflect.New(fieldType).Elem() // Generate the nested block schema - scmBlock[fieldName] = SingleNestedBlockBuilder{ - NestedObject: typeToSchema(fieldValue), - } - case types.Map: - // Look up nested struct type - if complexFieldTypes == nil { - panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) - } - fieldType, ok := complexFieldTypes[fieldName] - if !ok { - panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) - } - // If the field type is a "primitive", use MapAttributeBuilder - // otherwise use MapNestedAttributeBuilder - switch fieldType { - case reflect.TypeOf(types.BoolType), reflect.TypeOf(types.Int64Type), reflect.TypeOf(types.Float64Type), reflect.TypeOf(types.StringType): - scmAttr[fieldName] = MapAttributeBuilder{ - ElementType: reflect.New(fieldType).Elem().Interface().(attr.Type), - Optional: structTag.optional, - Required: !structTag.optional, - Computed: structTag.computed, + // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). + switch value.(type) { + case types.List: + scmBlock[fieldName] = ListNestedBlockBuilder{ + NestedObject: typeToSchema(ctx, fieldValue), } - default: - fieldValue := reflect.New(fieldType).Elem() - - // Generate the nested block schema - // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). + case types.Map: scmAttr[fieldName] = MapNestedAttributeBuilder{ - NestedObject: typeToSchema(fieldValue).ToNestedAttributeObject(), + NestedObject: typeToSchema(ctx, fieldValue).ToNestedAttributeObject(), + } + case types.Object: + scmAttr[fieldName] = SingleNestedAttributeBuilder{ + Attributes: typeToSchema(ctx, fieldValue).ToNestedAttributeObject().Attributes, } } - case types.Set, types.Tuple: - panic(fmt.Errorf("%T should never be used in tfsdk structs. %s", value.Interface(), common.TerraformBugErrorMessage)) - default: - // If it is a real stuct instead of a tfsdk type, recursively resolve it. - elem := typeFieldType - sv := reflect.New(elem) - nestedScm := typeToSchema(sv) - scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: nestedScm, - } } - } else { - panic(fmt.Errorf("unknown type for field: %s. %s", typeField.Name, common.TerraformBugErrorMessage)) + case types.Set, types.Tuple: + panic(fmt.Errorf("%T is not currently supported in tfsdk structs. %s", value, common.TerraformBugErrorMessage)) + default: + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", value, common.TerraformBugErrorMessage)) + } + // types.List fields of complex types correspond to ListNestedBlock, which don't have optional/required/computed flags. + // When these fields are later changed to use ListNestedAttribute, we can inline the if statement below, as all fields + // will be attributes. + if attr, ok := scmAttr[fieldName]; ok { + if structTag.optional { + attr.SetOptional() + } else { + attr.SetRequired() + } + if structTag.computed { + attr.SetComputed() + } } } return NestedBlockObject{Attributes: scmAttr, Blocks: scmBlock} @@ -282,20 +132,20 @@ func getStructTag(field reflect.StructField) structTag { } // ResourceStructToSchema builds a resource schema from a tfsdk struct, with custoimzations applied. -func ResourceStructToSchema(v any, customizeSchema func(CustomizableSchema) CustomizableSchema) schema.Schema { - attributes, blocks := ResourceStructToSchemaMap(v, customizeSchema) +func ResourceStructToSchema(ctx context.Context, v any, customizeSchema func(CustomizableSchema) CustomizableSchema) schema.Schema { + attributes, blocks := ResourceStructToSchemaMap(ctx, v, customizeSchema) return schema.Schema{Attributes: attributes, Blocks: blocks} } // DataSourceStructToSchema builds a data source schema from a tfsdk struct, with custoimzations applied. -func DataSourceStructToSchema(v any, customizeSchema func(CustomizableSchema) CustomizableSchema) dataschema.Schema { - attributes, blocks := DataSourceStructToSchemaMap(v, customizeSchema) +func DataSourceStructToSchema(ctx context.Context, v any, customizeSchema func(CustomizableSchema) CustomizableSchema) dataschema.Schema { + attributes, blocks := DataSourceStructToSchemaMap(ctx, v, customizeSchema) return dataschema.Schema{Attributes: attributes, Blocks: blocks} } // ResourceStructToSchemaMap returns two maps from string to resource schema attributes and blocks using a tfsdk struct, with custoimzations applied. -func ResourceStructToSchemaMap(v any, customizeSchema func(CustomizableSchema) CustomizableSchema) (map[string]schema.Attribute, map[string]schema.Block) { - nestedBlockObj := typeToSchema(reflect.ValueOf(v)) +func ResourceStructToSchemaMap(ctx context.Context, v any, customizeSchema func(CustomizableSchema) CustomizableSchema) (map[string]schema.Attribute, map[string]schema.Block) { + nestedBlockObj := typeToSchema(ctx, reflect.ValueOf(v)) if customizeSchema != nil { cs := customizeSchema(*ConstructCustomizableSchema(nestedBlockObj)) @@ -306,8 +156,8 @@ func ResourceStructToSchemaMap(v any, customizeSchema func(CustomizableSchema) C } // DataSourceStructToSchemaMap returns twp maps from string to data source schema attributes and blocks using a tfsdk struct, with custoimzations applied. -func DataSourceStructToSchemaMap(v any, customizeSchema func(CustomizableSchema) CustomizableSchema) (map[string]dataschema.Attribute, map[string]dataschema.Block) { - nestedBlockObj := typeToSchema(reflect.ValueOf(v)) +func DataSourceStructToSchemaMap(ctx context.Context, v any, customizeSchema func(CustomizableSchema) CustomizableSchema) (map[string]dataschema.Attribute, map[string]dataschema.Block) { + nestedBlockObj := typeToSchema(ctx, reflect.ValueOf(v)) if customizeSchema != nil { cs := customizeSchema(*ConstructCustomizableSchema(nestedBlockObj)) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go index a6005844c0..818c77f5c0 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go @@ -3,10 +3,12 @@ package tfschema import ( "context" "fmt" + "reflect" "strings" "testing" "github.com/databricks/terraform-provider-databricks/common" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/tfsdk" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/stretchr/testify/assert" @@ -35,15 +37,63 @@ type TestFloatTfSdk struct { } type TestListTfSdk struct { - Repeated []types.Int64 `tfsdk:"repeated" tf:"optional"` + Repeated types.List `tfsdk:"repeated" tf:"optional"` +} + +func (TestListTfSdk) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "repeated": reflect.TypeOf(types.Int64Type), + } +} + +func (TestListTfSdk) ToAttrType(context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "repeated": types.ListType{ + ElemType: types.Int64Type, + }, + }, + } } type TestMapTfSdk struct { - Attributes map[string]types.String `tfsdk:"attributes" tf:"optional"` + Attributes types.Map `tfsdk:"attributes" tf:"optional"` +} + +func (TestMapTfSdk) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "attributes": reflect.TypeOf(types.StringType), + } +} + +func (TestMapTfSdk) ToAttrType(context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "attributes": types.MapType{ + ElemType: types.StringType, + }, + }, + } } type TestNestedListTfSdk struct { - NestedList []DummyNested `tfsdk:"nested_list" tf:"optional"` + NestedList types.List `tfsdk:"nested_list" tf:"optional"` +} + +func (TestNestedListTfSdk) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{ + "nested_list": reflect.TypeOf(DummyNested{}), + } +} + +func (TestNestedListTfSdk) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "nested_list": types.ListType{ + ElemType: DummyNested{}.ToAttrType(ctx), + }, + }, + } } type DummyNested struct { @@ -51,20 +101,37 @@ type DummyNested struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } -type DummyDoubleNested struct { - Nested []*DummyNested `tfsdk:"nested" tf:"optional"` +func (DummyNested) GetComplexFieldTypes() map[string]reflect.Type { + return map[string]reflect.Type{} +} + +func (DummyNested) ToAttrType(context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "name": types.StringType, + "enabled": types.BoolType, + }, + } } type TestNestedMapTfSdk struct { - NestedMap map[string]DummyNested `tfsdk:"nested_map" tf:"optional"` + NestedMap types.Map `tfsdk:"nested_map" tf:"optional"` } -type TestPointerTfSdk struct { - Nested *[]DummyNested `tfsdk:"nested" tf:"optional"` +func (TestNestedMapTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "nested_map": reflect.TypeOf(DummyNested{}), + } } -type TestNestedPointerTfSdk struct { - Nested []DummyDoubleNested `tfsdk:"nested" tf:"optional"` +func (TestNestedMapTfSdk) ToAttrType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "nested_map": types.MapType{ + ElemType: DummyNested{}.ToAttrType(ctx), + }, + }, + } } var tests = []struct { @@ -89,76 +156,53 @@ var tests = []struct { }, { "list conversion", - TestListTfSdk{Repeated: []types.Int64{types.Int64Value(12), types.Int64Value(34)}}, + TestListTfSdk{Repeated: types.ListValueMust(types.Int64Type, []attr.Value{types.Int64Value(12), types.Int64Value(34)})}, }, { "map conversion", - TestMapTfSdk{Attributes: map[string]types.String{"key": types.StringValue("value")}}, + TestMapTfSdk{Attributes: types.MapValueMust(types.StringType, map[string]attr.Value{"key": types.StringValue("value")})}, }, { "nested list conversion", - TestNestedListTfSdk{NestedList: []DummyNested{ - { - Name: types.StringValue("abc"), - Enabled: types.BoolValue(true), - }, - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(false), - }, - }}, - }, - { - "nested map conversion", - TestNestedMapTfSdk{NestedMap: map[string]DummyNested{ - "key1": { - Name: types.StringValue("abc"), - Enabled: types.BoolValue(true), - }, - "key2": { - Name: types.StringValue("def"), - Enabled: types.BoolValue(false), - }, - }}, - }, - { - "pointer to a struct conversion", - TestPointerTfSdk{ - &[]DummyNested{ - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }, - }, + TestNestedListTfSdk{NestedList: types.ListValueMust(DummyNested{}.ToAttrType(context.Background()), + []attr.Value{ + types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + "name": types.StringValue("abc"), + "enabled": types.BoolValue(true), + }), + types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(false), + }), + }), }, }, { - "nested pointer to a struct conversion", - TestNestedPointerTfSdk{ - []DummyDoubleNested{ - { - Nested: []*DummyNested{ - { - Name: types.StringValue("def"), - Enabled: types.BoolValue(true), - }, - }, - }, - }, + "nested map conversion", + TestNestedMapTfSdk{NestedMap: types.MapValueMust(DummyNested{}.ToAttrType(context.Background()), map[string]attr.Value{ + "key1": types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + "name": types.StringValue("abc"), + "enabled": types.BoolValue(true), + }), + "key2": types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(false), + }), + }), }, }, } // StructToSchemaConversionTestCase runs a single test case to verify StructToSchema works for both data source and resource. func StructToSchemaConversionTestCase(t *testing.T, description string, testStruct any) { - scm := ResourceStructToSchema(testStruct, nil) + scm := ResourceStructToSchema(context.Background(), testStruct, nil) state := tfsdk.State{ Schema: scm, } // Assert we can properly set the state, this means the schema and the struct are consistent. assert.True(t, !state.Set(context.Background(), testStruct).HasError(), fmt.Sprintf("ResourceStructToSchema - %s", description)) - data_scm := DataSourceStructToSchema(testStruct, nil) + data_scm := DataSourceStructToSchema(context.Background(), testStruct, nil) data_state := tfsdk.State{ Schema: data_scm, } @@ -174,12 +218,12 @@ func TestStructToSchemaConversion(t *testing.T) { func TestStructToSchemaOptionalVsRequiredField(t *testing.T) { // Test that description is an optional field. - scm := ResourceStructToSchema(TestStringTfSdk{}, nil) + scm := ResourceStructToSchema(context.Background(), TestStringTfSdk{}, nil) assert.True(t, scm.Attributes["description"].IsOptional()) assert.True(t, !scm.Attributes["description"].IsRequired()) // Test that enabled is a required field. - data_scm := DataSourceStructToSchema(TestBoolTfSdk{}, nil) + data_scm := DataSourceStructToSchema(context.Background(), TestBoolTfSdk{}, nil) assert.True(t, !data_scm.Attributes["enabled"].IsOptional()) assert.True(t, data_scm.Attributes["enabled"].IsRequired()) } @@ -204,7 +248,7 @@ func testStructToSchemaPanics(t *testing.T, testStruct any, expectedError string t.Fatalf("error %s did not include expected error message %q", errMsg, expectedError) } }() - ResourceStructToSchema(testStruct, nil) + ResourceStructToSchema(context.Background(), testStruct, nil) } type TestTfSdkList struct { @@ -263,7 +307,7 @@ func TestStructToSchemaExpectedError(t *testing.T) { func TestComputedField(t *testing.T) { // Test that ComputedTag field is computed and required - scm := ResourceStructToSchema(TestComputedTfSdk{}, nil) + scm := ResourceStructToSchema(context.Background(), TestComputedTfSdk{}, nil) assert.True(t, scm.Attributes["computedtag"].IsComputed()) assert.True(t, scm.Attributes["computedtag"].IsRequired()) diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 743548e169..51c9b1b84b 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -65,7 +65,7 @@ func (newState *App) SyncEffectiveFieldsDuringCreateOrUpdate(plan App) { func (newState *App) SyncEffectiveFieldsDuringRead(existingState App) { } -func (a App) GetComplexFieldTypes() map[string]reflect.Type { +func (a App) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "active_deployment": reflect.TypeOf(AppDeployment{}), "app_status": reflect.TypeOf(ApplicationStatus{}), @@ -125,7 +125,7 @@ func (newState *AppAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState AppAccessControlRequest) { } -func (a AppAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -159,7 +159,7 @@ func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AppAccessControlResponse) { } -func (a AppAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(AppPermission{}), } @@ -210,7 +210,7 @@ func (newState *AppDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppD func (newState *AppDeployment) SyncEffectiveFieldsDuringRead(existingState AppDeployment) { } -func (a AppDeployment) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppDeployment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "deployment_artifacts": reflect.TypeOf(AppDeploymentArtifacts{}), "status": reflect.TypeOf(AppDeploymentStatus{}), @@ -248,7 +248,7 @@ func (newState *AppDeploymentArtifacts) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AppDeploymentArtifacts) SyncEffectiveFieldsDuringRead(existingState AppDeploymentArtifacts) { } -func (a AppDeploymentArtifacts) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppDeploymentArtifacts) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -273,7 +273,7 @@ func (newState *AppDeploymentStatus) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AppDeploymentStatus) SyncEffectiveFieldsDuringRead(existingState AppDeploymentStatus) { } -func (a AppDeploymentStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppDeploymentStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -300,7 +300,7 @@ func (newState *AppPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppP func (newState *AppPermission) SyncEffectiveFieldsDuringRead(existingState AppPermission) { } -func (a AppPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -332,7 +332,7 @@ func (newState *AppPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan App func (newState *AppPermissions) SyncEffectiveFieldsDuringRead(existingState AppPermissions) { } -func (a AppPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AppAccessControlResponse{}), } @@ -362,7 +362,7 @@ func (newState *AppPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpda func (newState *AppPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState AppPermissionsDescription) { } -func (a AppPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -387,7 +387,7 @@ func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState AppPermissionsRequest) { } -func (a AppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AppAccessControlRequest{}), } @@ -425,7 +425,7 @@ func (newState *AppResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppRes func (newState *AppResource) SyncEffectiveFieldsDuringRead(existingState AppResource) { } -func (a AppResource) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppResource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "job": reflect.TypeOf(AppResourceJob{}), "secret": reflect.TypeOf(AppResourceSecret{}), @@ -469,7 +469,7 @@ func (newState *AppResourceJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan App func (newState *AppResourceJob) SyncEffectiveFieldsDuringRead(existingState AppResourceJob) { } -func (a AppResourceJob) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppResourceJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -498,7 +498,7 @@ func (newState *AppResourceSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AppResourceSecret) SyncEffectiveFieldsDuringRead(existingState AppResourceSecret) { } -func (a AppResourceSecret) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppResourceSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -526,7 +526,7 @@ func (newState *AppResourceServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpd func (newState *AppResourceServingEndpoint) SyncEffectiveFieldsDuringRead(existingState AppResourceServingEndpoint) { } -func (a AppResourceServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppResourceServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -553,7 +553,7 @@ func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringRead(existingState AppResourceSqlWarehouse) { } -func (a AppResourceSqlWarehouse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AppResourceSqlWarehouse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -579,7 +579,7 @@ func (newState *ApplicationStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ApplicationStatus) SyncEffectiveFieldsDuringRead(existingState ApplicationStatus) { } -func (a ApplicationStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a ApplicationStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -605,7 +605,7 @@ func (newState *ComputeStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Comp func (newState *ComputeStatus) SyncEffectiveFieldsDuringRead(existingState ComputeStatus) { } -func (a ComputeStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a ComputeStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -631,7 +631,7 @@ func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existingState CreateAppDeploymentRequest) { } -func (a CreateAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app_deployment": reflect.TypeOf(AppDeployment{}), } @@ -659,7 +659,7 @@ func (newState *CreateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateAppRequest) SyncEffectiveFieldsDuringRead(existingState CreateAppRequest) { } -func (a CreateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app": reflect.TypeOf(App{}), } @@ -687,7 +687,7 @@ func (newState *DeleteAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteAppRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAppRequest) { } -func (a DeleteAppRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -713,7 +713,7 @@ func (newState *GetAppDeploymentRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existingState GetAppDeploymentRequest) { } -func (a GetAppDeploymentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -738,7 +738,7 @@ func (newState *GetAppPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetAppPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionLevelsRequest) { } -func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -761,7 +761,7 @@ func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionLevelsResponse) { } -func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(AppPermissionsDescription{}), } @@ -789,7 +789,7 @@ func (newState *GetAppPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetAppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionsRequest) { } -func (a GetAppPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -813,7 +813,7 @@ func (newState *GetAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetA func (newState *GetAppRequest) SyncEffectiveFieldsDuringRead(existingState GetAppRequest) { } -func (a GetAppRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -842,7 +842,7 @@ func (newState *ListAppDeploymentsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListAppDeploymentsRequest) SyncEffectiveFieldsDuringRead(existingState ListAppDeploymentsRequest) { } -func (a ListAppDeploymentsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAppDeploymentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -869,7 +869,7 @@ func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringRead(existingState ListAppDeploymentsResponse) { } -func (a ListAppDeploymentsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAppDeploymentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app_deployments": reflect.TypeOf(AppDeployment{}), } @@ -901,7 +901,7 @@ func (newState *ListAppsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListAppsRequest) SyncEffectiveFieldsDuringRead(existingState ListAppsRequest) { } -func (a ListAppsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -926,7 +926,7 @@ func (newState *ListAppsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListAppsResponse) SyncEffectiveFieldsDuringRead(existingState ListAppsResponse) { } -func (a ListAppsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAppsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(App{}), } @@ -954,7 +954,7 @@ func (newState *StartAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan St func (newState *StartAppRequest) SyncEffectiveFieldsDuringRead(existingState StartAppRequest) { } -func (a StartAppRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -977,7 +977,7 @@ func (newState *StopAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sto func (newState *StopAppRequest) SyncEffectiveFieldsDuringRead(existingState StopAppRequest) { } -func (a StopAppRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a StopAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1003,7 +1003,7 @@ func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAppRequest) { } -func (a UpdateAppRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app": reflect.TypeOf(App{}), } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 65186eff44..9db83eb6b3 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -35,7 +35,7 @@ func (newState *ActionConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ActionConfiguration) SyncEffectiveFieldsDuringRead(existingState ActionConfiguration) { } -func (a ActionConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a ActionConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -74,7 +74,7 @@ func (newState *AlertConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertConfiguration) SyncEffectiveFieldsDuringRead(existingState AlertConfiguration) { } -func (a AlertConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "action_configurations": reflect.TypeOf(ActionConfiguration{}), } @@ -122,7 +122,7 @@ func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringRead(existingState BudgetConfiguration) { } -func (a BudgetConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a BudgetConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_configurations": reflect.TypeOf(AlertConfiguration{}), "filter": reflect.TypeOf(BudgetConfigurationFilter{}), @@ -162,7 +162,7 @@ func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringCreateOrUpda func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilter) { } -func (a BudgetConfigurationFilter) GetComplexFieldTypes() map[string]reflect.Type { +func (a BudgetConfigurationFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(BudgetConfigurationFilterTagClause{}), "workspace_id": reflect.TypeOf(BudgetConfigurationFilterWorkspaceIdClause{}), @@ -194,7 +194,7 @@ func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringCreate func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterClause) { } -func (a BudgetConfigurationFilterClause) GetComplexFieldTypes() map[string]reflect.Type { +func (a BudgetConfigurationFilterClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(types.StringType), } @@ -223,7 +223,7 @@ func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringCre func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterTagClause) { } -func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes() map[string]reflect.Type { +func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(BudgetConfigurationFilterClause{}), } @@ -252,7 +252,7 @@ func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsD func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterWorkspaceIdClause) { } -func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes() map[string]reflect.Type { +func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(types.Int64Type), } @@ -285,7 +285,7 @@ func (newState *CreateBillingUsageDashboardRequest) SyncEffectiveFieldsDuringCre func (newState *CreateBillingUsageDashboardRequest) SyncEffectiveFieldsDuringRead(existingState CreateBillingUsageDashboardRequest) { } -func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -309,7 +309,7 @@ func (newState *CreateBillingUsageDashboardResponse) SyncEffectiveFieldsDuringCr func (newState *CreateBillingUsageDashboardResponse) SyncEffectiveFieldsDuringRead(existingState CreateBillingUsageDashboardResponse) { } -func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -342,7 +342,7 @@ func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreate func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudget) { } -func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_configurations": reflect.TypeOf(CreateBudgetConfigurationBudgetAlertConfigurations{}), "filter": reflect.TypeOf(BudgetConfigurationFilter{}), @@ -377,7 +377,7 @@ func (newState *CreateBudgetConfigurationBudgetActionConfigurations) SyncEffecti func (newState *CreateBudgetConfigurationBudgetActionConfigurations) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudgetActionConfigurations) { } -func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -413,7 +413,7 @@ func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiv func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudgetAlertConfigurations) { } -func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "action_configurations": reflect.TypeOf(CreateBudgetConfigurationBudgetActionConfigurations{}), } @@ -444,7 +444,7 @@ func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationRequest) { } -func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(CreateBudgetConfigurationBudget{}), } @@ -471,7 +471,7 @@ func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationResponse) { } -func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(BudgetConfiguration{}), } @@ -565,7 +565,7 @@ func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringC func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringRead(existingState CreateLogDeliveryConfigurationParams) { } -func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "workspace_ids_filter": reflect.TypeOf(types.Int64Type), } @@ -601,7 +601,7 @@ func (newState *DeleteBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteBudgetConfigurationRequest) { } -func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -622,7 +622,7 @@ func (newState *DeleteBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *DeleteBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteBudgetConfigurationResponse) { } -func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -652,7 +652,7 @@ func (newState *DownloadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DownloadRequest) SyncEffectiveFieldsDuringRead(existingState DownloadRequest) { } -func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -676,7 +676,7 @@ func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DownloadResponse) SyncEffectiveFieldsDuringRead(existingState DownloadResponse) { } -func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -705,7 +705,7 @@ func (newState *GetBillingUsageDashboardRequest) SyncEffectiveFieldsDuringCreate func (newState *GetBillingUsageDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetBillingUsageDashboardRequest) { } -func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -731,7 +731,7 @@ func (newState *GetBillingUsageDashboardResponse) SyncEffectiveFieldsDuringCreat func (newState *GetBillingUsageDashboardResponse) SyncEffectiveFieldsDuringRead(existingState GetBillingUsageDashboardResponse) { } -func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -756,7 +756,7 @@ func (newState *GetBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState GetBudgetConfigurationRequest) { } -func (a GetBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -778,7 +778,7 @@ func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState GetBudgetConfigurationResponse) { } -func (a GetBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(BudgetConfiguration{}), } @@ -806,7 +806,7 @@ func (newState *GetLogDeliveryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetLogDeliveryRequest) SyncEffectiveFieldsDuringRead(existingState GetLogDeliveryRequest) { } -func (a GetLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -832,7 +832,7 @@ func (newState *ListBudgetConfigurationsRequest) SyncEffectiveFieldsDuringCreate func (newState *ListBudgetConfigurationsRequest) SyncEffectiveFieldsDuringRead(existingState ListBudgetConfigurationsRequest) { } -func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -857,7 +857,7 @@ func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringCreat func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringRead(existingState ListBudgetConfigurationsResponse) { } -func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budgets": reflect.TypeOf(BudgetConfiguration{}), } @@ -890,7 +890,7 @@ func (newState *ListLogDeliveryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListLogDeliveryRequest) SyncEffectiveFieldsDuringRead(existingState ListLogDeliveryRequest) { } -func (a ListLogDeliveryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -994,7 +994,7 @@ func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState LogDeliveryConfiguration) { } -func (a LogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_status": reflect.TypeOf(LogDeliveryStatus{}), "workspace_ids_filter": reflect.TypeOf(types.Int64Type), @@ -1055,7 +1055,7 @@ func (newState *LogDeliveryStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogDeliveryStatus) SyncEffectiveFieldsDuringRead(existingState LogDeliveryStatus) { } -func (a LogDeliveryStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogDeliveryStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1079,7 +1079,7 @@ func (newState *PatchStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PatchStatusResponse) SyncEffectiveFieldsDuringRead(existingState PatchStatusResponse) { } -func (a PatchStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PatchStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1112,7 +1112,7 @@ func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreate func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationBudget) { } -func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_configurations": reflect.TypeOf(AlertConfiguration{}), "filter": reflect.TypeOf(BudgetConfigurationFilter{}), @@ -1149,7 +1149,7 @@ func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationRequest) { } -func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(UpdateBudgetConfigurationBudget{}), } @@ -1177,7 +1177,7 @@ func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationResponse) { } -func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(BudgetConfiguration{}), } @@ -1210,7 +1210,7 @@ func (newState *UpdateLogDeliveryConfigurationStatusRequest) SyncEffectiveFields func (newState *UpdateLogDeliveryConfigurationStatusRequest) SyncEffectiveFieldsDuringRead(existingState UpdateLogDeliveryConfigurationStatusRequest) { } -func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1233,7 +1233,7 @@ func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuring func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState WrappedCreateLogDeliveryConfiguration) { } -func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_configuration": reflect.TypeOf(CreateLogDeliveryConfigurationParams{}), } @@ -1259,7 +1259,7 @@ func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreate func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState WrappedLogDeliveryConfiguration) { } -func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_configuration": reflect.TypeOf(LogDeliveryConfiguration{}), } @@ -1285,7 +1285,7 @@ func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringCreat func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringRead(existingState WrappedLogDeliveryConfigurations) { } -func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes() map[string]reflect.Type { +func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_configurations": reflect.TypeOf(LogDeliveryConfiguration{}), } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index c83e678656..e5c94e0eae 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -29,7 +29,7 @@ func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringRead(existingState AccountsCreateMetastore) { } -func (a AccountsCreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsCreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_info": reflect.TypeOf(CreateMetastore{}), } @@ -59,7 +59,7 @@ func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringCrea func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsCreateMetastoreAssignment) { } -func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_assignment": reflect.TypeOf(CreateMetastoreAssignment{}), } @@ -89,7 +89,7 @@ func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringCreate func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringRead(existingState AccountsCreateStorageCredential) { } -func (a AccountsCreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsCreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credential_info": reflect.TypeOf(CreateStorageCredential{}), } @@ -116,7 +116,7 @@ func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUp func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsMetastoreAssignment) { } -func (a AccountsMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_assignment": reflect.TypeOf(MetastoreAssignment{}), } @@ -142,7 +142,7 @@ func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringRead(existingState AccountsMetastoreInfo) { } -func (a AccountsMetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsMetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_info": reflect.TypeOf(MetastoreInfo{}), } @@ -168,7 +168,7 @@ func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringCreateOr func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingState AccountsStorageCredentialInfo) { } -func (a AccountsStorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsStorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credential_info": reflect.TypeOf(StorageCredentialInfo{}), } @@ -197,7 +197,7 @@ func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateMetastore) { } -func (a AccountsUpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsUpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_info": reflect.TypeOf(UpdateMetastore{}), } @@ -228,7 +228,7 @@ func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringCrea func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateMetastoreAssignment) { } -func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_assignment": reflect.TypeOf(UpdateMetastoreAssignment{}), } @@ -260,7 +260,7 @@ func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringCreate func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateStorageCredential) { } -func (a AccountsUpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccountsUpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credential_info": reflect.TypeOf(UpdateStorageCredential{}), } @@ -295,7 +295,7 @@ func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringRead(existingState ArtifactAllowlistInfo) { } -func (a ArtifactAllowlistInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ArtifactAllowlistInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "artifact_matchers": reflect.TypeOf(ArtifactMatcher{}), } @@ -327,7 +327,7 @@ func (newState *ArtifactMatcher) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ar func (newState *ArtifactMatcher) SyncEffectiveFieldsDuringRead(existingState ArtifactMatcher) { } -func (a ArtifactMatcher) GetComplexFieldTypes() map[string]reflect.Type { +func (a ArtifactMatcher) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -349,7 +349,7 @@ func (newState *AssignResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ass func (newState *AssignResponse) SyncEffectiveFieldsDuringRead(existingState AssignResponse) { } -func (a AssignResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AssignResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -380,7 +380,7 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan Aws func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsCredentials) { } -func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -414,7 +414,7 @@ func (newState *AwsIamRole) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsIamR func (newState *AwsIamRole) SyncEffectiveFieldsDuringRead(existingState AwsIamRole) { } -func (a AwsIamRole) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsIamRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -439,7 +439,7 @@ func (newState *AwsIamRoleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AwsIamRoleRequest) SyncEffectiveFieldsDuringRead(existingState AwsIamRoleRequest) { } -func (a AwsIamRoleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsIamRoleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -468,7 +468,7 @@ func (newState *AwsIamRoleResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AwsIamRoleResponse) SyncEffectiveFieldsDuringRead(existingState AwsIamRoleResponse) { } -func (a AwsIamRoleResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsIamRoleResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -497,7 +497,7 @@ func (newState *AzureActiveDirectoryToken) SyncEffectiveFieldsDuringCreateOrUpda func (newState *AzureActiveDirectoryToken) SyncEffectiveFieldsDuringRead(existingState AzureActiveDirectoryToken) { } -func (a AzureActiveDirectoryToken) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureActiveDirectoryToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -535,7 +535,7 @@ func (newState *AzureManagedIdentity) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *AzureManagedIdentity) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentity) { } -func (a AzureManagedIdentity) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureManagedIdentity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -569,7 +569,7 @@ func (newState *AzureManagedIdentityRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *AzureManagedIdentityRequest) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentityRequest) { } -func (a AzureManagedIdentityRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureManagedIdentityRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -604,7 +604,7 @@ func (newState *AzureManagedIdentityResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *AzureManagedIdentityResponse) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentityResponse) { } -func (a AzureManagedIdentityResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureManagedIdentityResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -636,7 +636,7 @@ func (newState *AzureServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AzureServicePrincipal) SyncEffectiveFieldsDuringRead(existingState AzureServicePrincipal) { } -func (a AzureServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -663,7 +663,7 @@ func (newState *AzureUserDelegationSas) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AzureUserDelegationSas) SyncEffectiveFieldsDuringRead(existingState AzureUserDelegationSas) { } -func (a AzureUserDelegationSas) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureUserDelegationSas) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -689,7 +689,7 @@ func (newState *CancelRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CancelRefreshRequest) SyncEffectiveFieldsDuringRead(existingState CancelRefreshRequest) { } -func (a CancelRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -711,7 +711,7 @@ func (newState *CancelRefreshResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CancelRefreshResponse) SyncEffectiveFieldsDuringRead(existingState CancelRefreshResponse) { } -func (a CancelRefreshResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelRefreshResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -785,7 +785,7 @@ func (newState *CatalogInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Catalo func (newState *CatalogInfo) SyncEffectiveFieldsDuringRead(existingState CatalogInfo) { } -func (a CatalogInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), "options": reflect.TypeOf(types.StringType), @@ -848,7 +848,7 @@ func (newState *CloudflareApiToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CloudflareApiToken) SyncEffectiveFieldsDuringRead(existingState CloudflareApiToken) { } -func (a CloudflareApiToken) GetComplexFieldTypes() map[string]reflect.Type { +func (a CloudflareApiToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -895,7 +895,7 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } -func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "mask": reflect.TypeOf(ColumnMask{}), } @@ -938,7 +938,7 @@ func (newState *ColumnMask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnM func (newState *ColumnMask) SyncEffectiveFieldsDuringRead(existingState ColumnMask) { } -func (a ColumnMask) GetComplexFieldTypes() map[string]reflect.Type { +func (a ColumnMask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "using_column_names": reflect.TypeOf(types.StringType), } @@ -1003,7 +1003,7 @@ func (newState *ConnectionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Con func (newState *ConnectionInfo) SyncEffectiveFieldsDuringRead(existingState ConnectionInfo) { } -func (a ConnectionInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.StringType), "properties": reflect.TypeOf(types.StringType), @@ -1063,7 +1063,7 @@ func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringRead(existingState ContinuousUpdateStatus) { } -func (a ContinuousUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a ContinuousUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "initial_pipeline_sync_progress": reflect.TypeOf(PipelineProgress{}), } @@ -1109,7 +1109,7 @@ func (newState *CreateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateCatalog) SyncEffectiveFieldsDuringRead(existingState CreateCatalog) { } -func (a CreateCatalog) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.StringType), "properties": reflect.TypeOf(types.StringType), @@ -1157,7 +1157,7 @@ func (newState *CreateConnection) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateConnection) SyncEffectiveFieldsDuringRead(existingState CreateConnection) { } -func (a CreateConnection) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.StringType), "properties": reflect.TypeOf(types.StringType), @@ -1212,7 +1212,7 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialRequest) { } -func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), @@ -1275,7 +1275,7 @@ func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringRead(existingState CreateExternalLocation) { } -func (a CreateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } @@ -1354,7 +1354,7 @@ func (newState *CreateFunction) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateFunction) SyncEffectiveFieldsDuringRead(existingState CreateFunction) { } -func (a CreateFunction) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateFunction) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_params": reflect.TypeOf(FunctionParameterInfos{}), "return_params": reflect.TypeOf(FunctionParameterInfos{}), @@ -1407,7 +1407,7 @@ func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringRead(existingState CreateFunctionRequest) { } -func (a CreateFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "function_info": reflect.TypeOf(CreateFunction{}), } @@ -1441,7 +1441,7 @@ func (newState *CreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cr func (newState *CreateMetastore) SyncEffectiveFieldsDuringRead(existingState CreateMetastore) { } -func (a CreateMetastore) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1472,7 +1472,7 @@ func (newState *CreateMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState CreateMetastoreAssignment) { } -func (a CreateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1533,7 +1533,7 @@ func (newState *CreateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateMonitor) SyncEffectiveFieldsDuringRead(existingState CreateMonitor) { } -func (a CreateMonitor) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_metrics": reflect.TypeOf(MonitorMetric{}), "data_classification_config": reflect.TypeOf(MonitorDataClassificationConfig{}), @@ -1595,7 +1595,7 @@ func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState CreateOnlineTableRequest) { } -func (a CreateOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table": reflect.TypeOf(OnlineTable{}), } @@ -1631,7 +1631,7 @@ func (newState *CreateRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *CreateRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState CreateRegisteredModelRequest) { } -func (a CreateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1656,7 +1656,7 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } -func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1685,7 +1685,7 @@ func (newState *CreateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreateSchema) SyncEffectiveFieldsDuringRead(existingState CreateSchema) { } -func (a CreateSchema) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.StringType), } @@ -1733,7 +1733,7 @@ func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringRead(existingState CreateStorageCredential) { } -func (a CreateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityRequest{}), @@ -1784,7 +1784,7 @@ func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringRead(existingState CreateTableConstraint) { } -func (a CreateTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateTableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "constraint": reflect.TypeOf(TableConstraint{}), } @@ -1822,7 +1822,7 @@ func (newState *CreateVolumeRequestContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateVolumeRequestContent) SyncEffectiveFieldsDuringRead(existingState CreateVolumeRequestContent) { } -func (a CreateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1886,7 +1886,7 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState CredentialInfo) { } -func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), @@ -1937,7 +1937,7 @@ func (newState *CredentialValidationResult) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CredentialValidationResult) SyncEffectiveFieldsDuringRead(existingState CredentialValidationResult) { } -func (a CredentialValidationResult) GetComplexFieldTypes() map[string]reflect.Type { +func (a CredentialValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1962,7 +1962,7 @@ func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingState CurrentWorkspaceBindings) { } -func (a CurrentWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { +func (a CurrentWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "workspaces": reflect.TypeOf(types.Int64Type), } @@ -1987,7 +1987,7 @@ func (newState *DatabricksGcpServiceAccountRequest) SyncEffectiveFieldsDuringCre func (newState *DatabricksGcpServiceAccountRequest) SyncEffectiveFieldsDuringRead(existingState DatabricksGcpServiceAccountRequest) { } -func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2011,7 +2011,7 @@ func (newState *DatabricksGcpServiceAccountResponse) SyncEffectiveFieldsDuringCr func (newState *DatabricksGcpServiceAccountResponse) SyncEffectiveFieldsDuringRead(existingState DatabricksGcpServiceAccountResponse) { } -func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2038,7 +2038,7 @@ func (newState *DeleteAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuri func (newState *DeleteAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountMetastoreAssignmentRequest) { } -func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2065,7 +2065,7 @@ func (newState *DeleteAccountMetastoreRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteAccountMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountMetastoreRequest) { } -func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2095,7 +2095,7 @@ func (newState *DeleteAccountStorageCredentialRequest) SyncEffectiveFieldsDuring func (newState *DeleteAccountStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountStorageCredentialRequest) { } -func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2123,7 +2123,7 @@ func (newState *DeleteAliasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteAliasRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAliasRequest) { } -func (a DeleteAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2145,7 +2145,7 @@ func (newState *DeleteAliasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteAliasResponse) SyncEffectiveFieldsDuringRead(existingState DeleteAliasResponse) { } -func (a DeleteAliasResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAliasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2169,7 +2169,7 @@ func (newState *DeleteCatalogRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteCatalogRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCatalogRequest) { } -func (a DeleteCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2194,7 +2194,7 @@ func (newState *DeleteConnectionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteConnectionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteConnectionRequest) { } -func (a DeleteConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2222,7 +2222,7 @@ func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialRequest) { } -func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2244,7 +2244,7 @@ func (newState *DeleteCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteCredentialResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialResponse) { } -func (a DeleteCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2268,7 +2268,7 @@ func (newState *DeleteExternalLocationRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteExternalLocationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExternalLocationRequest) { } -func (a DeleteExternalLocationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2296,7 +2296,7 @@ func (newState *DeleteFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteFunctionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFunctionRequest) { } -func (a DeleteFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2323,7 +2323,7 @@ func (newState *DeleteMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState DeleteMetastoreRequest) { } -func (a DeleteMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2350,7 +2350,7 @@ func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionRequest) { } -func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2375,7 +2375,7 @@ func (newState *DeleteOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteOnlineTableRequest) { } -func (a DeleteOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2399,7 +2399,7 @@ func (newState *DeleteQualityMonitorRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *DeleteQualityMonitorRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQualityMonitorRequest) { } -func (a DeleteQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2423,7 +2423,7 @@ func (newState *DeleteRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRegisteredModelRequest) { } -func (a DeleteRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2444,7 +2444,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2468,7 +2468,7 @@ func (newState *DeleteSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteSchemaRequest) SyncEffectiveFieldsDuringRead(existingState DeleteSchemaRequest) { } -func (a DeleteSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2496,7 +2496,7 @@ func (newState *DeleteStorageCredentialRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteStorageCredentialRequest) { } -func (a DeleteStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2527,7 +2527,7 @@ func (newState *DeleteTableConstraintRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteTableConstraintRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableConstraintRequest) { } -func (a DeleteTableConstraintRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTableConstraintRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2553,7 +2553,7 @@ func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableRequest) { } -func (a DeleteTableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2577,7 +2577,7 @@ func (newState *DeleteVolumeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteVolumeRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVolumeRequest) { } -func (a DeleteVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2603,7 +2603,7 @@ func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOr func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existingState DeltaRuntimePropertiesKvPairs) { } -func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "delta_runtime_properties": reflect.TypeOf(types.StringType), } @@ -2634,7 +2634,7 @@ func (newState *Dependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Depende func (newState *Dependency) SyncEffectiveFieldsDuringRead(existingState Dependency) { } -func (a Dependency) GetComplexFieldTypes() map[string]reflect.Type { +func (a Dependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "function": reflect.TypeOf(FunctionDependency{}), "table": reflect.TypeOf(TableDependency{}), @@ -2666,7 +2666,7 @@ func (newState *DependencyList) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dep func (newState *DependencyList) SyncEffectiveFieldsDuringRead(existingState DependencyList) { } -func (a DependencyList) GetComplexFieldTypes() map[string]reflect.Type { +func (a DependencyList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dependencies": reflect.TypeOf(Dependency{}), } @@ -2696,7 +2696,7 @@ func (newState *DisableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dis func (newState *DisableRequest) SyncEffectiveFieldsDuringRead(existingState DisableRequest) { } -func (a DisableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DisableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2718,7 +2718,7 @@ func (newState *DisableResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Di func (newState *DisableResponse) SyncEffectiveFieldsDuringRead(existingState DisableResponse) { } -func (a DisableResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DisableResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2740,7 +2740,7 @@ func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringRead(existingState EffectivePermissionsList) { } -func (a EffectivePermissionsList) GetComplexFieldTypes() map[string]reflect.Type { +func (a EffectivePermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privilege_assignments": reflect.TypeOf(EffectivePrivilegeAssignment{}), } @@ -2774,7 +2774,7 @@ func (newState *EffectivePredictiveOptimizationFlag) SyncEffectiveFieldsDuringCr func (newState *EffectivePredictiveOptimizationFlag) SyncEffectiveFieldsDuringRead(existingState EffectivePredictiveOptimizationFlag) { } -func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes() map[string]reflect.Type { +func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2807,7 +2807,7 @@ func (newState *EffectivePrivilege) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EffectivePrivilege) SyncEffectiveFieldsDuringRead(existingState EffectivePrivilege) { } -func (a EffectivePrivilege) GetComplexFieldTypes() map[string]reflect.Type { +func (a EffectivePrivilege) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2835,7 +2835,7 @@ func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrU func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState EffectivePrivilegeAssignment) { } -func (a EffectivePrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a EffectivePrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privileges": reflect.TypeOf(EffectivePrivilege{}), } @@ -2866,7 +2866,7 @@ func (newState *EnableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Enab func (newState *EnableRequest) SyncEffectiveFieldsDuringRead(existingState EnableRequest) { } -func (a EnableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2888,7 +2888,7 @@ func (newState *EnableResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ena func (newState *EnableResponse) SyncEffectiveFieldsDuringRead(existingState EnableResponse) { } -func (a EnableResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnableResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2910,7 +2910,7 @@ func (newState *EncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EncryptionDetails) SyncEffectiveFieldsDuringRead(existingState EncryptionDetails) { } -func (a EncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a EncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sse_encryption_details": reflect.TypeOf(SseEncryptionDetails{}), } @@ -2938,7 +2938,7 @@ func (newState *ExistsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exis func (newState *ExistsRequest) SyncEffectiveFieldsDuringRead(existingState ExistsRequest) { } -func (a ExistsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExistsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2998,7 +2998,7 @@ func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringRead(existingState ExternalLocationInfo) { } -func (a ExternalLocationInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExternalLocationInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } @@ -3050,7 +3050,7 @@ func (newState *FailedStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Faile func (newState *FailedStatus) SyncEffectiveFieldsDuringRead(existingState FailedStatus) { } -func (a FailedStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a FailedStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3080,7 +3080,7 @@ func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringRead(existingState ForeignKeyConstraint) { } -func (a ForeignKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { +func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "child_columns": reflect.TypeOf(types.StringType), "parent_columns": reflect.TypeOf(types.StringType), @@ -3115,7 +3115,7 @@ func (newState *FunctionDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *FunctionDependency) SyncEffectiveFieldsDuringRead(existingState FunctionDependency) { } -func (a FunctionDependency) GetComplexFieldTypes() map[string]reflect.Type { +func (a FunctionDependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3203,7 +3203,7 @@ func (newState *FunctionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Funct func (newState *FunctionInfo) SyncEffectiveFieldsDuringRead(existingState FunctionInfo) { } -func (a FunctionInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a FunctionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_params": reflect.TypeOf(FunctionParameterInfos{}), "return_params": reflect.TypeOf(FunctionParameterInfos{}), @@ -3287,7 +3287,7 @@ func (newState *FunctionParameterInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *FunctionParameterInfo) SyncEffectiveFieldsDuringRead(existingState FunctionParameterInfo) { } -func (a FunctionParameterInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a FunctionParameterInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3322,7 +3322,7 @@ func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringRead(existingState FunctionParameterInfos) { } -func (a FunctionParameterInfos) GetComplexFieldTypes() map[string]reflect.Type { +func (a FunctionParameterInfos) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(FunctionParameterInfo{}), } @@ -3350,7 +3350,7 @@ func (newState *GcpOauthToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpO func (newState *GcpOauthToken) SyncEffectiveFieldsDuringRead(existingState GcpOauthToken) { } -func (a GcpOauthToken) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpOauthToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3378,7 +3378,7 @@ func (newState *GcpServiceAccountKey) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GcpServiceAccountKey) SyncEffectiveFieldsDuringRead(existingState GcpServiceAccountKey) { } -func (a GcpServiceAccountKey) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpServiceAccountKey) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3406,7 +3406,7 @@ func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFie func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryServiceCredentialAzureOptions) { } -func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "resources": reflect.TypeOf(types.StringType), } @@ -3436,7 +3436,7 @@ func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDu func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryServiceCredentialRequest) { } -func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "azure_options": reflect.TypeOf(GenerateTemporaryServiceCredentialAzureOptions{}), } @@ -3468,7 +3468,7 @@ func (newState *GenerateTemporaryTableCredentialRequest) SyncEffectiveFieldsDuri func (newState *GenerateTemporaryTableCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryTableCredentialRequest) { } -func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3511,7 +3511,7 @@ func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDur func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryTableCredentialResponse) { } -func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_temp_credentials": reflect.TypeOf(AwsCredentials{}), "azure_aad": reflect.TypeOf(AzureActiveDirectoryToken{}), @@ -3557,7 +3557,7 @@ func (newState *GetAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringC func (newState *GetAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountMetastoreAssignmentRequest) { } -func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3581,7 +3581,7 @@ func (newState *GetAccountMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetAccountMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountMetastoreRequest) { } -func (a GetAccountMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3607,7 +3607,7 @@ func (newState *GetAccountStorageCredentialRequest) SyncEffectiveFieldsDuringCre func (newState *GetAccountStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountStorageCredentialRequest) { } -func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3632,7 +3632,7 @@ func (newState *GetArtifactAllowlistRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetArtifactAllowlistRequest) SyncEffectiveFieldsDuringRead(existingState GetArtifactAllowlistRequest) { } -func (a GetArtifactAllowlistRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetArtifactAllowlistRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3667,7 +3667,7 @@ func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringRead(existingState GetBindingsRequest) { } -func (a GetBindingsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetBindingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3699,7 +3699,7 @@ func (newState *GetByAliasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetByAliasRequest) SyncEffectiveFieldsDuringRead(existingState GetByAliasRequest) { } -func (a GetByAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetByAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3728,7 +3728,7 @@ func (newState *GetCatalogRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetCatalogRequest) SyncEffectiveFieldsDuringRead(existingState GetCatalogRequest) { } -func (a GetCatalogRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3753,7 +3753,7 @@ func (newState *GetConnectionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetConnectionRequest) SyncEffectiveFieldsDuringRead(existingState GetConnectionRequest) { } -func (a GetConnectionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3777,7 +3777,7 @@ func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialRequest) { } -func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3806,7 +3806,7 @@ func (newState *GetEffectiveRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetEffectiveRequest) SyncEffectiveFieldsDuringRead(existingState GetEffectiveRequest) { } -func (a GetEffectiveRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEffectiveRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3835,7 +3835,7 @@ func (newState *GetExternalLocationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetExternalLocationRequest) SyncEffectiveFieldsDuringRead(existingState GetExternalLocationRequest) { } -func (a GetExternalLocationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3864,7 +3864,7 @@ func (newState *GetFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetFunctionRequest) SyncEffectiveFieldsDuringRead(existingState GetFunctionRequest) { } -func (a GetFunctionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3894,7 +3894,7 @@ func (newState *GetGrantRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetGrantRequest) SyncEffectiveFieldsDuringRead(existingState GetGrantRequest) { } -func (a GetGrantRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetGrantRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3920,7 +3920,7 @@ func (newState *GetMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState GetMetastoreRequest) { } -func (a GetMetastoreRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3983,7 +3983,7 @@ func (newState *GetMetastoreSummaryResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetMetastoreSummaryResponse) SyncEffectiveFieldsDuringRead(existingState GetMetastoreSummaryResponse) { } -func (a GetMetastoreSummaryResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetMetastoreSummaryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4033,7 +4033,7 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionRequest) { } -func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4060,7 +4060,7 @@ func (newState *GetOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState GetOnlineTableRequest) { } -func (a GetOnlineTableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4084,7 +4084,7 @@ func (newState *GetQualityMonitorRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetQualityMonitorRequest) SyncEffectiveFieldsDuringRead(existingState GetQualityMonitorRequest) { } -func (a GetQualityMonitorRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4114,7 +4114,7 @@ func (newState *GetQuotaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetQuotaRequest) SyncEffectiveFieldsDuringRead(existingState GetQuotaRequest) { } -func (a GetQuotaRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetQuotaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4139,7 +4139,7 @@ func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringRead(existingState GetQuotaResponse) { } -func (a GetQuotaResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetQuotaResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "quota_info": reflect.TypeOf(QuotaInfo{}), } @@ -4169,7 +4169,7 @@ func (newState *GetRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetRefreshRequest) SyncEffectiveFieldsDuringRead(existingState GetRefreshRequest) { } -func (a GetRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4199,7 +4199,7 @@ func (newState *GetRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelRequest) { } -func (a GetRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4228,7 +4228,7 @@ func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringRead(existingState GetSchemaRequest) { } -func (a GetSchemaRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4253,7 +4253,7 @@ func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetStorageCredentialRequest) { } -func (a GetStorageCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4284,7 +4284,7 @@ func (newState *GetTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetTableRequest) SyncEffectiveFieldsDuringRead(existingState GetTableRequest) { } -func (a GetTableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4311,7 +4311,7 @@ func (newState *GetWorkspaceBindingRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetWorkspaceBindingRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceBindingRequest) { } -func (a GetWorkspaceBindingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceBindingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4335,7 +4335,7 @@ func (newState *ListAccountMetastoreAssignmentsRequest) SyncEffectiveFieldsDurin func (newState *ListAccountMetastoreAssignmentsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountMetastoreAssignmentsRequest) { } -func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4358,7 +4358,7 @@ func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuri func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuringRead(existingState ListAccountMetastoreAssignmentsResponse) { } -func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "workspace_ids": reflect.TypeOf(types.Int64Type), } @@ -4386,7 +4386,7 @@ func (newState *ListAccountStorageCredentialsRequest) SyncEffectiveFieldsDuringC func (newState *ListAccountStorageCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountStorageCredentialsRequest) { } -func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4409,7 +4409,7 @@ func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuring func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListAccountStorageCredentialsResponse) { } -func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "storage_credentials": reflect.TypeOf(StorageCredentialInfo{}), } @@ -4450,7 +4450,7 @@ func (newState *ListCatalogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListCatalogsRequest) SyncEffectiveFieldsDuringRead(existingState ListCatalogsRequest) { } -func (a ListCatalogsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListCatalogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4479,7 +4479,7 @@ func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringRead(existingState ListCatalogsResponse) { } -func (a ListCatalogsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListCatalogsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "catalogs": reflect.TypeOf(CatalogInfo{}), } @@ -4515,7 +4515,7 @@ func (newState *ListConnectionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListConnectionsRequest) SyncEffectiveFieldsDuringRead(existingState ListConnectionsRequest) { } -func (a ListConnectionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListConnectionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4543,7 +4543,7 @@ func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringRead(existingState ListConnectionsResponse) { } -func (a ListConnectionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListConnectionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "connections": reflect.TypeOf(ConnectionInfo{}), } @@ -4580,7 +4580,7 @@ func (newState *ListCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListCredentialsRequest) { } -func (a ListCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4608,7 +4608,7 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListCredentialsResponse) { } -func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credentials": reflect.TypeOf(CredentialInfo{}), } @@ -4647,7 +4647,7 @@ func (newState *ListExternalLocationsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListExternalLocationsRequest) SyncEffectiveFieldsDuringRead(existingState ListExternalLocationsRequest) { } -func (a ListExternalLocationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExternalLocationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4676,7 +4676,7 @@ func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringCreateOr func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringRead(existingState ListExternalLocationsResponse) { } -func (a ListExternalLocationsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExternalLocationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "external_locations": reflect.TypeOf(ExternalLocationInfo{}), } @@ -4719,7 +4719,7 @@ func (newState *ListFunctionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListFunctionsRequest) SyncEffectiveFieldsDuringRead(existingState ListFunctionsRequest) { } -func (a ListFunctionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListFunctionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4750,7 +4750,7 @@ func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringRead(existingState ListFunctionsResponse) { } -func (a ListFunctionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListFunctionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "functions": reflect.TypeOf(FunctionInfo{}), } @@ -4778,7 +4778,7 @@ func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringRead(existingState ListMetastoresResponse) { } -func (a ListMetastoresResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListMetastoresResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastores": reflect.TypeOf(MetastoreInfo{}), } @@ -4820,7 +4820,7 @@ func (newState *ListModelVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListModelVersionsRequest) SyncEffectiveFieldsDuringRead(existingState ListModelVersionsRequest) { } -func (a ListModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4849,7 +4849,7 @@ func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringRead(existingState ListModelVersionsResponse) { } -func (a ListModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_versions": reflect.TypeOf(ModelVersionInfo{}), } @@ -4880,7 +4880,7 @@ func (newState *ListQuotasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQuotasRequest) SyncEffectiveFieldsDuringRead(existingState ListQuotasRequest) { } -func (a ListQuotasRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQuotasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4908,7 +4908,7 @@ func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringRead(existingState ListQuotasResponse) { } -func (a ListQuotasResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQuotasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "quotas": reflect.TypeOf(QuotaInfo{}), } @@ -4937,7 +4937,7 @@ func (newState *ListRefreshesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListRefreshesRequest) SyncEffectiveFieldsDuringRead(existingState ListRefreshesRequest) { } -func (a ListRefreshesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRefreshesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4988,7 +4988,7 @@ func (newState *ListRegisteredModelsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListRegisteredModelsRequest) SyncEffectiveFieldsDuringRead(existingState ListRegisteredModelsRequest) { } -func (a ListRegisteredModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRegisteredModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5018,7 +5018,7 @@ func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringRead(existingState ListRegisteredModelsResponse) { } -func (a ListRegisteredModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRegisteredModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_models": reflect.TypeOf(RegisteredModelInfo{}), } @@ -5059,7 +5059,7 @@ func (newState *ListSchemasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSchemasRequest) SyncEffectiveFieldsDuringRead(existingState ListSchemasRequest) { } -func (a ListSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5089,7 +5089,7 @@ func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringRead(existingState ListSchemasResponse) { } -func (a ListSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schemas": reflect.TypeOf(SchemaInfo{}), } @@ -5125,7 +5125,7 @@ func (newState *ListStorageCredentialsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListStorageCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListStorageCredentialsRequest) { } -func (a ListStorageCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5153,7 +5153,7 @@ func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListStorageCredentialsResponse) { } -func (a ListStorageCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "storage_credentials": reflect.TypeOf(StorageCredentialInfo{}), } @@ -5200,7 +5200,7 @@ func (newState *ListSummariesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListSummariesRequest) SyncEffectiveFieldsDuringRead(existingState ListSummariesRequest) { } -func (a ListSummariesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSummariesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5238,7 +5238,7 @@ func (newState *ListSystemSchemasRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListSystemSchemasRequest) SyncEffectiveFieldsDuringRead(existingState ListSystemSchemasRequest) { } -func (a ListSystemSchemasRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSystemSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5267,7 +5267,7 @@ func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringRead(existingState ListSystemSchemasResponse) { } -func (a ListSystemSchemasResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSystemSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schemas": reflect.TypeOf(SystemSchemaInfo{}), } @@ -5299,7 +5299,7 @@ func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringRead(existingState ListTableSummariesResponse) { } -func (a ListTableSummariesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTableSummariesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tables": reflect.TypeOf(TableSummary{}), } @@ -5353,7 +5353,7 @@ func (newState *ListTablesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTablesRequest) SyncEffectiveFieldsDuringRead(existingState ListTablesRequest) { } -func (a ListTablesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTablesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5389,7 +5389,7 @@ func (newState *ListTablesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTablesResponse) SyncEffectiveFieldsDuringRead(existingState ListTablesResponse) { } -func (a ListTablesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTablesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tables": reflect.TypeOf(TableInfo{}), } @@ -5439,7 +5439,7 @@ func (newState *ListVolumesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListVolumesRequest) SyncEffectiveFieldsDuringRead(existingState ListVolumesRequest) { } -func (a ListVolumesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListVolumesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5470,7 +5470,7 @@ func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringRead(existingState ListVolumesResponseContent) { } -func (a ListVolumesResponseContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListVolumesResponseContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "volumes": reflect.TypeOf(VolumeInfo{}), } @@ -5502,7 +5502,7 @@ func (newState *MetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState MetastoreAssignment) { } -func (a MetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a MetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5567,7 +5567,7 @@ func (newState *MetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Meta func (newState *MetastoreInfo) SyncEffectiveFieldsDuringRead(existingState MetastoreInfo) { } -func (a MetastoreInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a MetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5656,7 +5656,7 @@ func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan M func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringRead(existingState ModelVersionInfo) { } -func (a ModelVersionInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelVersionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aliases": reflect.TypeOf(RegisteredModelAlias{}), "model_version_dependencies": reflect.TypeOf(DependencyList{}), @@ -5711,7 +5711,7 @@ func (newState *MonitorCronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MonitorCronSchedule) SyncEffectiveFieldsDuringRead(existingState MonitorCronSchedule) { } -func (a MonitorCronSchedule) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorCronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5736,7 +5736,7 @@ func (newState *MonitorDataClassificationConfig) SyncEffectiveFieldsDuringCreate func (newState *MonitorDataClassificationConfig) SyncEffectiveFieldsDuringRead(existingState MonitorDataClassificationConfig) { } -func (a MonitorDataClassificationConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorDataClassificationConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5760,7 +5760,7 @@ func (newState *MonitorDestination) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorDestination) SyncEffectiveFieldsDuringRead(existingState MonitorDestination) { } -func (a MonitorDestination) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "email_addresses": reflect.TypeOf(types.StringType), } @@ -5813,7 +5813,7 @@ func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringRead(existingState MonitorInferenceLog) { } -func (a MonitorInferenceLog) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorInferenceLog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "granularities": reflect.TypeOf(types.StringType), } @@ -5893,7 +5893,7 @@ func (newState *MonitorInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Monito func (newState *MonitorInfo) SyncEffectiveFieldsDuringRead(existingState MonitorInfo) { } -func (a MonitorInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_metrics": reflect.TypeOf(MonitorMetric{}), "data_classification_config": reflect.TypeOf(MonitorDataClassificationConfig{}), @@ -5980,7 +5980,7 @@ func (newState *MonitorMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan Moni func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState MonitorMetric) { } -func (a MonitorMetric) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_columns": reflect.TypeOf(types.StringType), } @@ -6014,7 +6014,7 @@ func (newState *MonitorNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *MonitorNotifications) SyncEffectiveFieldsDuringRead(existingState MonitorNotifications) { } -func (a MonitorNotifications) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_failure": reflect.TypeOf(MonitorDestination{}), "on_new_classification_tag_detected": reflect.TypeOf(MonitorDestination{}), @@ -6058,7 +6058,7 @@ func (newState *MonitorRefreshInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorRefreshInfo) SyncEffectiveFieldsDuringRead(existingState MonitorRefreshInfo) { } -func (a MonitorRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6086,7 +6086,7 @@ func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringRead(existingState MonitorRefreshListResponse) { } -func (a MonitorRefreshListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorRefreshListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "refreshes": reflect.TypeOf(MonitorRefreshInfo{}), } @@ -6111,7 +6111,7 @@ func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringRead(existingState MonitorSnapshot) { } -func (a MonitorSnapshot) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6142,7 +6142,7 @@ func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringRead(existingState MonitorTimeSeries) { } -func (a MonitorTimeSeries) GetComplexFieldTypes() map[string]reflect.Type { +func (a MonitorTimeSeries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "granularities": reflect.TypeOf(types.StringType), } @@ -6170,7 +6170,7 @@ func (newState *NamedTableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *NamedTableConstraint) SyncEffectiveFieldsDuringRead(existingState NamedTableConstraint) { } -func (a NamedTableConstraint) GetComplexFieldTypes() map[string]reflect.Type { +func (a NamedTableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6205,7 +6205,7 @@ func (newState *OnlineTable) SyncEffectiveFieldsDuringCreateOrUpdate(plan Online func (newState *OnlineTable) SyncEffectiveFieldsDuringRead(existingState OnlineTable) { } -func (a OnlineTable) GetComplexFieldTypes() map[string]reflect.Type { +func (a OnlineTable) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "spec": reflect.TypeOf(OnlineTableSpec{}), "status": reflect.TypeOf(OnlineTableStatus{}), @@ -6261,7 +6261,7 @@ func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan On func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpec) { } -func (a OnlineTableSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "primary_key_columns": reflect.TypeOf(types.StringType), "run_continuously": reflect.TypeOf(OnlineTableSpecContinuousSchedulingPolicy{}), @@ -6298,7 +6298,7 @@ func (newState *OnlineTableSpecContinuousSchedulingPolicy) SyncEffectiveFieldsDu func (newState *OnlineTableSpecContinuousSchedulingPolicy) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpecContinuousSchedulingPolicy) { } -func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6317,7 +6317,7 @@ func (newState *OnlineTableSpecTriggeredSchedulingPolicy) SyncEffectiveFieldsDur func (newState *OnlineTableSpecTriggeredSchedulingPolicy) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpecTriggeredSchedulingPolicy) { } -func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6354,7 +6354,7 @@ func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringRead(existingState OnlineTableStatus) { } -func (a OnlineTableStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a OnlineTableStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "continuous_update_status": reflect.TypeOf(ContinuousUpdateStatus{}), "failed_status": reflect.TypeOf(FailedStatus{}), @@ -6399,7 +6399,7 @@ func (newState *PermissionsChange) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PermissionsChange) SyncEffectiveFieldsDuringRead(existingState PermissionsChange) { } -func (a PermissionsChange) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add": reflect.TypeOf(types.StringType), "remove": reflect.TypeOf(types.StringType), @@ -6431,7 +6431,7 @@ func (newState *PermissionsList) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pe func (newState *PermissionsList) SyncEffectiveFieldsDuringRead(existingState PermissionsList) { } -func (a PermissionsList) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privilege_assignments": reflect.TypeOf(PrivilegeAssignment{}), } @@ -6469,7 +6469,7 @@ func (newState *PipelineProgress) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *PipelineProgress) SyncEffectiveFieldsDuringRead(existingState PipelineProgress) { } -func (a PipelineProgress) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineProgress) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6498,7 +6498,7 @@ func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringRead(existingState PrimaryKeyConstraint) { } -func (a PrimaryKeyConstraint) GetComplexFieldTypes() map[string]reflect.Type { +func (a PrimaryKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "child_columns": reflect.TypeOf(types.StringType), } @@ -6528,7 +6528,7 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState PrivilegeAssignment) { } -func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privileges": reflect.TypeOf(types.StringType), } @@ -6556,7 +6556,7 @@ func (newState *ProvisioningInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *ProvisioningInfo) SyncEffectiveFieldsDuringRead(existingState ProvisioningInfo) { } -func (a ProvisioningInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ProvisioningInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6582,7 +6582,7 @@ func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringRead(existingState ProvisioningStatus) { } -func (a ProvisioningStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a ProvisioningStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "initial_pipeline_sync_progress": reflect.TypeOf(PipelineProgress{}), } @@ -6620,7 +6620,7 @@ func (newState *QuotaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan QuotaInf func (newState *QuotaInfo) SyncEffectiveFieldsDuringRead(existingState QuotaInfo) { } -func (a QuotaInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a QuotaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6654,7 +6654,7 @@ func (newState *R2Credentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan R2Cr func (newState *R2Credentials) SyncEffectiveFieldsDuringRead(existingState R2Credentials) { } -func (a R2Credentials) GetComplexFieldTypes() map[string]reflect.Type { +func (a R2Credentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6683,7 +6683,7 @@ func (newState *ReadVolumeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ReadVolumeRequest) SyncEffectiveFieldsDuringRead(existingState ReadVolumeRequest) { } -func (a ReadVolumeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReadVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6710,7 +6710,7 @@ func (newState *RegenerateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RegenerateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState RegenerateDashboardRequest) { } -func (a RegenerateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegenerateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6736,7 +6736,7 @@ func (newState *RegenerateDashboardResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *RegenerateDashboardResponse) SyncEffectiveFieldsDuringRead(existingState RegenerateDashboardResponse) { } -func (a RegenerateDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegenerateDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6763,7 +6763,7 @@ func (newState *RegisteredModelAlias) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RegisteredModelAlias) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAlias) { } -func (a RegisteredModelAlias) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelAlias) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6818,7 +6818,7 @@ func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringRead(existingState RegisteredModelInfo) { } -func (a RegisteredModelInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aliases": reflect.TypeOf(RegisteredModelAlias{}), } @@ -6859,7 +6859,7 @@ func (newState *RunRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RunRefreshRequest) SyncEffectiveFieldsDuringRead(existingState RunRefreshRequest) { } -func (a RunRefreshRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6919,7 +6919,7 @@ func (newState *SchemaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaI func (newState *SchemaInfo) SyncEffectiveFieldsDuringRead(existingState SchemaInfo) { } -func (a SchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), "properties": reflect.TypeOf(types.StringType), @@ -6968,7 +6968,7 @@ func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringRead(existingState SetArtifactAllowlist) { } -func (a SetArtifactAllowlist) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetArtifactAllowlist) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "artifact_matchers": reflect.TypeOf(ArtifactMatcher{}), } @@ -7000,7 +7000,7 @@ func (newState *SetRegisteredModelAliasRequest) SyncEffectiveFieldsDuringCreateO func (newState *SetRegisteredModelAliasRequest) SyncEffectiveFieldsDuringRead(existingState SetRegisteredModelAliasRequest) { } -func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7029,7 +7029,7 @@ func (newState *SseEncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SseEncryptionDetails) SyncEffectiveFieldsDuringRead(existingState SseEncryptionDetails) { } -func (a SseEncryptionDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a SseEncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7088,7 +7088,7 @@ func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingState StorageCredentialInfo) { } -func (a StorageCredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a StorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleResponse{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityResponse{}), @@ -7147,7 +7147,7 @@ func (newState *SystemSchemaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SystemSchemaInfo) SyncEffectiveFieldsDuringRead(existingState SystemSchemaInfo) { } -func (a SystemSchemaInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a SystemSchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7177,7 +7177,7 @@ func (newState *TableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ta func (newState *TableConstraint) SyncEffectiveFieldsDuringRead(existingState TableConstraint) { } -func (a TableConstraint) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "foreign_key_constraint": reflect.TypeOf(ForeignKeyConstraint{}), "named_table_constraint": reflect.TypeOf(NamedTableConstraint{}), @@ -7214,7 +7214,7 @@ func (newState *TableDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ta func (newState *TableDependency) SyncEffectiveFieldsDuringRead(existingState TableDependency) { } -func (a TableDependency) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableDependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7237,7 +7237,7 @@ func (newState *TableExistsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TableExistsResponse) SyncEffectiveFieldsDuringRead(existingState TableExistsResponse) { } -func (a TableExistsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableExistsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7335,7 +7335,7 @@ func (newState *TableInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableInf func (newState *TableInfo) SyncEffectiveFieldsDuringRead(existingState TableInfo) { } -func (a TableInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(ColumnInfo{}), "delta_runtime_properties_kvpairs": reflect.TypeOf(DeltaRuntimePropertiesKvPairs{}), @@ -7418,7 +7418,7 @@ func (newState *TableRowFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tab func (newState *TableRowFilter) SyncEffectiveFieldsDuringRead(existingState TableRowFilter) { } -func (a TableRowFilter) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableRowFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_column_names": reflect.TypeOf(types.StringType), } @@ -7448,7 +7448,7 @@ func (newState *TableSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Table func (newState *TableSummary) SyncEffectiveFieldsDuringRead(existingState TableSummary) { } -func (a TableSummary) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7480,7 +7480,7 @@ func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringRead(existingState TemporaryCredentials) { } -func (a TemporaryCredentials) GetComplexFieldTypes() map[string]reflect.Type { +func (a TemporaryCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_temp_credentials": reflect.TypeOf(AwsCredentials{}), "azure_aad": reflect.TypeOf(AzureActiveDirectoryToken{}), @@ -7521,7 +7521,7 @@ func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringRead(existingState TriggeredUpdateStatus) { } -func (a TriggeredUpdateStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a TriggeredUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "triggered_update_progress": reflect.TypeOf(PipelineProgress{}), } @@ -7553,7 +7553,7 @@ func (newState *UnassignRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Un func (newState *UnassignRequest) SyncEffectiveFieldsDuringRead(existingState UnassignRequest) { } -func (a UnassignRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UnassignRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7575,7 +7575,7 @@ func (newState *UnassignResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UnassignResponse) SyncEffectiveFieldsDuringRead(existingState UnassignResponse) { } -func (a UnassignResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UnassignResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7594,7 +7594,7 @@ func (newState *UpdateAssignmentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateAssignmentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateAssignmentResponse) { } -func (a UpdateAssignmentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7629,7 +7629,7 @@ func (newState *UpdateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateCatalog) SyncEffectiveFieldsDuringRead(existingState UpdateCatalog) { } -func (a UpdateCatalog) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.StringType), } @@ -7668,7 +7668,7 @@ func (newState *UpdateConnection) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateConnection) SyncEffectiveFieldsDuringRead(existingState UpdateConnection) { } -func (a UpdateConnection) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateConnection) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.StringType), } @@ -7723,7 +7723,7 @@ func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialRequest) { } -func (a UpdateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), @@ -7794,7 +7794,7 @@ func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringRead(existingState UpdateExternalLocation) { } -func (a UpdateExternalLocation) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } @@ -7836,7 +7836,7 @@ func (newState *UpdateFunction) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateFunction) SyncEffectiveFieldsDuringRead(existingState UpdateFunction) { } -func (a UpdateFunction) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateFunction) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7876,7 +7876,7 @@ func (newState *UpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateMetastore) SyncEffectiveFieldsDuringRead(existingState UpdateMetastore) { } -func (a UpdateMetastore) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7912,7 +7912,7 @@ func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState UpdateMetastoreAssignment) { } -func (a UpdateMetastoreAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7941,7 +7941,7 @@ func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionRequest) { } -func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7997,7 +7997,7 @@ func (newState *UpdateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateMonitor) SyncEffectiveFieldsDuringRead(existingState UpdateMonitor) { } -func (a UpdateMonitor) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_metrics": reflect.TypeOf(MonitorMetric{}), "data_classification_config": reflect.TypeOf(MonitorDataClassificationConfig{}), @@ -8060,7 +8060,7 @@ func (newState *UpdatePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdatePermissions) SyncEffectiveFieldsDuringRead(existingState UpdatePermissions) { } -func (a UpdatePermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "changes": reflect.TypeOf(PermissionsChange{}), } @@ -8095,7 +8095,7 @@ func (newState *UpdateRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *UpdateRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRegisteredModelRequest) { } -func (a UpdateRegisteredModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -8119,7 +8119,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -8151,7 +8151,7 @@ func (newState *UpdateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Updat func (newState *UpdateSchema) SyncEffectiveFieldsDuringRead(existingState UpdateSchema) { } -func (a UpdateSchema) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.StringType), } @@ -8209,7 +8209,7 @@ func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingState UpdateStorageCredential) { } -func (a UpdateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityResponse{}), @@ -8263,7 +8263,7 @@ func (newState *UpdateTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateTableRequest) SyncEffectiveFieldsDuringRead(existingState UpdateTableRequest) { } -func (a UpdateTableRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -8293,7 +8293,7 @@ func (newState *UpdateVolumeRequestContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateVolumeRequestContent) SyncEffectiveFieldsDuringRead(existingState UpdateVolumeRequestContent) { } -func (a UpdateVolumeRequestContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -8323,7 +8323,7 @@ func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceBindings) { } -func (a UpdateWorkspaceBindings) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assign_workspaces": reflect.TypeOf(types.Int64Type), "unassign_workspaces": reflect.TypeOf(types.Int64Type), @@ -8361,7 +8361,7 @@ func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringCrea func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceBindingsParameters) { } -func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add": reflect.TypeOf(WorkspaceBinding{}), "remove": reflect.TypeOf(WorkspaceBinding{}), @@ -8411,7 +8411,7 @@ func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState ValidateCredentialRequest) { } -func (a ValidateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ValidateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentity{}), @@ -8450,7 +8450,7 @@ func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringRead(existingState ValidateCredentialResponse) { } -func (a ValidateCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ValidateCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(CredentialValidationResult{}), } @@ -8494,7 +8494,7 @@ func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringRead(existingState ValidateStorageCredential) { } -func (a ValidateStorageCredential) GetComplexFieldTypes() map[string]reflect.Type { +func (a ValidateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityRequest{}), @@ -8543,7 +8543,7 @@ func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringCrea func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringRead(existingState ValidateStorageCredentialResponse) { } -func (a ValidateStorageCredentialResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ValidateStorageCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ValidationResult{}), } @@ -8575,7 +8575,7 @@ func (newState *ValidationResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan V func (newState *ValidationResult) SyncEffectiveFieldsDuringRead(existingState ValidationResult) { } -func (a ValidationResult) GetComplexFieldTypes() map[string]reflect.Type { +func (a ValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -8634,7 +8634,7 @@ func (newState *VolumeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan VolumeI func (newState *VolumeInfo) SyncEffectiveFieldsDuringRead(existingState VolumeInfo) { } -func (a VolumeInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a VolumeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } @@ -8678,7 +8678,7 @@ func (newState *WorkspaceBinding) SyncEffectiveFieldsDuringCreateOrUpdate(plan W func (newState *WorkspaceBinding) SyncEffectiveFieldsDuringRead(existingState WorkspaceBinding) { } -func (a WorkspaceBinding) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceBinding) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -8707,7 +8707,7 @@ func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringRead(existingState WorkspaceBindingsResponse) { } -func (a WorkspaceBindingsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceBindingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "bindings": reflect.TypeOf(WorkspaceBinding{}), } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 9a269050fa..953fd0f14d 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -54,7 +54,7 @@ func (newState *AddInstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AddInstanceProfile) SyncEffectiveFieldsDuringRead(existingState AddInstanceProfile) { } -func (a AddInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { +func (a AddInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -78,7 +78,7 @@ func (newState *AddResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddRes func (newState *AddResponse) SyncEffectiveFieldsDuringRead(existingState AddResponse) { } -func (a AddResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AddResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -100,7 +100,7 @@ func (newState *Adlsgen2Info) SyncEffectiveFieldsDuringCreateOrUpdate(plan Adlsg func (newState *Adlsgen2Info) SyncEffectiveFieldsDuringRead(existingState Adlsgen2Info) { } -func (a Adlsgen2Info) GetComplexFieldTypes() map[string]reflect.Type { +func (a Adlsgen2Info) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -129,7 +129,7 @@ func (newState *AutoScale) SyncEffectiveFieldsDuringCreateOrUpdate(plan AutoScal func (newState *AutoScale) SyncEffectiveFieldsDuringRead(existingState AutoScale) { } -func (a AutoScale) GetComplexFieldTypes() map[string]reflect.Type { +func (a AutoScale) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -234,7 +234,7 @@ func (newState *AwsAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsA func (newState *AwsAttributes) SyncEffectiveFieldsDuringRead(existingState AwsAttributes) { } -func (a AwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -287,7 +287,7 @@ func (newState *AzureAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan Az func (newState *AzureAttributes) SyncEffectiveFieldsDuringRead(existingState AzureAttributes) { } -func (a AzureAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_analytics_info": reflect.TypeOf(LogAnalyticsInfo{}), } @@ -320,7 +320,7 @@ func (newState *CancelCommand) SyncEffectiveFieldsDuringCreateOrUpdate(plan Canc func (newState *CancelCommand) SyncEffectiveFieldsDuringRead(existingState CancelCommand) { } -func (a CancelCommand) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelCommand) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -343,7 +343,7 @@ func (newState *CancelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Can func (newState *CancelResponse) SyncEffectiveFieldsDuringRead(existingState CancelResponse) { } -func (a CancelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -366,7 +366,7 @@ func (newState *ChangeClusterOwner) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ChangeClusterOwner) SyncEffectiveFieldsDuringRead(existingState ChangeClusterOwner) { } -func (a ChangeClusterOwner) GetComplexFieldTypes() map[string]reflect.Type { +func (a ChangeClusterOwner) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -388,7 +388,7 @@ func (newState *ChangeClusterOwnerResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ChangeClusterOwnerResponse) SyncEffectiveFieldsDuringRead(existingState ChangeClusterOwnerResponse) { } -func (a ChangeClusterOwnerResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ChangeClusterOwnerResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -411,7 +411,7 @@ func (newState *ClientsTypes) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clien func (newState *ClientsTypes) SyncEffectiveFieldsDuringRead(existingState ClientsTypes) { } -func (a ClientsTypes) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClientsTypes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -435,7 +435,7 @@ func (newState *CloneCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clone func (newState *CloneCluster) SyncEffectiveFieldsDuringRead(existingState CloneCluster) { } -func (a CloneCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a CloneCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -457,7 +457,7 @@ func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringRead(existingState CloudProviderNodeInfo) { } -func (a CloudProviderNodeInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a CloudProviderNodeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "status": reflect.TypeOf(types.StringType), } @@ -490,7 +490,7 @@ func (newState *ClusterAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ClusterAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ClusterAccessControlRequest) { } -func (a ClusterAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -524,7 +524,7 @@ func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ClusterAccessControlResponse) { } -func (a ClusterAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ClusterPermission{}), } @@ -683,7 +683,7 @@ func (newState *ClusterAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterAttributes) SyncEffectiveFieldsDuringRead(existingState ClusterAttributes) { } -func (a ClusterAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(AwsAttributes{}), "azure_attributes": reflect.TypeOf(AzureAttributes{}), @@ -771,7 +771,7 @@ func (newState *ClusterCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterCompliance) SyncEffectiveFieldsDuringRead(existingState ClusterCompliance) { } -func (a ClusterCompliance) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterCompliance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.StringType), } @@ -1011,7 +1011,7 @@ func (newState *ClusterDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clu func (newState *ClusterDetails) SyncEffectiveFieldsDuringRead(existingState ClusterDetails) { } -func (a ClusterDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), "aws_attributes": reflect.TypeOf(AwsAttributes{}), @@ -1143,7 +1143,7 @@ func (newState *ClusterEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clust func (newState *ClusterEvent) SyncEffectiveFieldsDuringRead(existingState ClusterEvent) { } -func (a ClusterEvent) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterEvent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_plane_event_details": reflect.TypeOf(DataPlaneEventDetails{}), "details": reflect.TypeOf(EventDetails{}), @@ -1179,7 +1179,7 @@ func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringRead(existingState ClusterLibraryStatuses) { } -func (a ClusterLibraryStatuses) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterLibraryStatuses) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library_statuses": reflect.TypeOf(LibraryFullStatus{}), } @@ -1214,7 +1214,7 @@ func (newState *ClusterLogConf) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clu func (newState *ClusterLogConf) SyncEffectiveFieldsDuringRead(existingState ClusterLogConf) { } -func (a ClusterLogConf) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterLogConf) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbfs": reflect.TypeOf(DbfsStorageInfo{}), "s3": reflect.TypeOf(S3StorageInfo{}), @@ -1248,7 +1248,7 @@ func (newState *ClusterPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterPermission) SyncEffectiveFieldsDuringRead(existingState ClusterPermission) { } -func (a ClusterPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1280,7 +1280,7 @@ func (newState *ClusterPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterPermissions) SyncEffectiveFieldsDuringRead(existingState ClusterPermissions) { } -func (a ClusterPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterAccessControlResponse{}), } @@ -1310,7 +1310,7 @@ func (newState *ClusterPermissionsDescription) SyncEffectiveFieldsDuringCreateOr func (newState *ClusterPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ClusterPermissionsDescription) { } -func (a ClusterPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1335,7 +1335,7 @@ func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPermissionsRequest) { } -func (a ClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterAccessControlRequest{}), } @@ -1369,7 +1369,7 @@ func (newState *ClusterPolicyAccessControlRequest) SyncEffectiveFieldsDuringCrea func (newState *ClusterPolicyAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyAccessControlRequest) { } -func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1403,7 +1403,7 @@ func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringCre func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyAccessControlResponse) { } -func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ClusterPolicyPermission{}), } @@ -1437,7 +1437,7 @@ func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermission) { } -func (a ClusterPolicyPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPolicyPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1469,7 +1469,7 @@ func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissions) { } -func (a ClusterPolicyPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPolicyPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterPolicyAccessControlResponse{}), } @@ -1499,7 +1499,7 @@ func (newState *ClusterPolicyPermissionsDescription) SyncEffectiveFieldsDuringCr func (newState *ClusterPolicyPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissionsDescription) { } -func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1524,7 +1524,7 @@ func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringCreate func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissionsRequest) { } -func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterPolicyAccessControlRequest{}), } @@ -1564,7 +1564,7 @@ func (newState *ClusterSettingsChange) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ClusterSettingsChange) SyncEffectiveFieldsDuringRead(existingState ClusterSettingsChange) { } -func (a ClusterSettingsChange) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1602,7 +1602,7 @@ func (newState *ClusterSize) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSize) SyncEffectiveFieldsDuringRead(existingState ClusterSize) { } -func (a ClusterSize) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterSize) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), } @@ -1777,7 +1777,7 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState ClusterSpec) { } -func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), "aws_attributes": reflect.TypeOf(AwsAttributes{}), @@ -1864,7 +1864,7 @@ func (newState *ClusterStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clus func (newState *ClusterStatus) SyncEffectiveFieldsDuringRead(existingState ClusterStatus) { } -func (a ClusterStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1893,7 +1893,7 @@ func (newState *Command) SyncEffectiveFieldsDuringCreateOrUpdate(plan Command) { func (newState *Command) SyncEffectiveFieldsDuringRead(existingState Command) { } -func (a Command) GetComplexFieldTypes() map[string]reflect.Type { +func (a Command) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1923,7 +1923,7 @@ func (newState *CommandStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CommandStatusRequest) SyncEffectiveFieldsDuringRead(existingState CommandStatusRequest) { } -func (a CommandStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CommandStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1951,7 +1951,7 @@ func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringRead(existingState CommandStatusResponse) { } -func (a CommandStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CommandStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(Results{}), } @@ -1982,7 +1982,7 @@ func (newState *ContextStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ContextStatusRequest) SyncEffectiveFieldsDuringRead(existingState ContextStatusRequest) { } -func (a ContextStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ContextStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2007,7 +2007,7 @@ func (newState *ContextStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ContextStatusResponse) SyncEffectiveFieldsDuringRead(existingState ContextStatusResponse) { } -func (a ContextStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ContextStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2181,7 +2181,7 @@ func (newState *CreateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateCluster) SyncEffectiveFieldsDuringRead(existingState CreateCluster) { } -func (a CreateCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), "aws_attributes": reflect.TypeOf(AwsAttributes{}), @@ -2270,7 +2270,7 @@ func (newState *CreateClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateClusterResponse) SyncEffectiveFieldsDuringRead(existingState CreateClusterResponse) { } -func (a CreateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2295,7 +2295,7 @@ func (newState *CreateContext) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateContext) SyncEffectiveFieldsDuringRead(existingState CreateContext) { } -func (a CreateContext) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateContext) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2371,7 +2371,7 @@ func (newState *CreateInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateInstancePool) SyncEffectiveFieldsDuringRead(existingState CreateInstancePool) { } -func (a CreateInstancePool) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), @@ -2428,7 +2428,7 @@ func (newState *CreateInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState CreateInstancePoolResponse) { } -func (a CreateInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2482,7 +2482,7 @@ func (newState *CreatePolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreatePolicy) SyncEffectiveFieldsDuringRead(existingState CreatePolicy) { } -func (a CreatePolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } @@ -2515,7 +2515,7 @@ func (newState *CreatePolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreatePolicyResponse) SyncEffectiveFieldsDuringRead(existingState CreatePolicyResponse) { } -func (a CreatePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2538,7 +2538,7 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } -func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2560,7 +2560,7 @@ func (newState *Created) SyncEffectiveFieldsDuringCreateOrUpdate(plan Created) { func (newState *Created) SyncEffectiveFieldsDuringRead(existingState Created) { } -func (a Created) GetComplexFieldTypes() map[string]reflect.Type { +func (a Created) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2589,7 +2589,7 @@ func (newState *DataPlaneEventDetails) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DataPlaneEventDetails) SyncEffectiveFieldsDuringRead(existingState DataPlaneEventDetails) { } -func (a DataPlaneEventDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a DataPlaneEventDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2615,7 +2615,7 @@ func (newState *DbfsStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Db func (newState *DbfsStorageInfo) SyncEffectiveFieldsDuringRead(existingState DbfsStorageInfo) { } -func (a DbfsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a DbfsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2638,7 +2638,7 @@ func (newState *DeleteCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dele func (newState *DeleteCluster) SyncEffectiveFieldsDuringRead(existingState DeleteCluster) { } -func (a DeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2659,7 +2659,7 @@ func (newState *DeleteClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteClusterResponse) SyncEffectiveFieldsDuringRead(existingState DeleteClusterResponse) { } -func (a DeleteClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2681,7 +2681,7 @@ func (newState *DeleteGlobalInitScriptRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteGlobalInitScriptRequest) SyncEffectiveFieldsDuringRead(existingState DeleteGlobalInitScriptRequest) { } -func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2704,7 +2704,7 @@ func (newState *DeleteInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteInstancePool) SyncEffectiveFieldsDuringRead(existingState DeleteInstancePool) { } -func (a DeleteInstancePool) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2725,7 +2725,7 @@ func (newState *DeleteInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState DeleteInstancePoolResponse) { } -func (a DeleteInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2746,7 +2746,7 @@ func (newState *DeletePolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delet func (newState *DeletePolicy) SyncEffectiveFieldsDuringRead(existingState DeletePolicy) { } -func (a DeletePolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2767,7 +2767,7 @@ func (newState *DeletePolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeletePolicyResponse) SyncEffectiveFieldsDuringRead(existingState DeletePolicyResponse) { } -func (a DeletePolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2786,7 +2786,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2808,7 +2808,7 @@ func (newState *DestroyContext) SyncEffectiveFieldsDuringCreateOrUpdate(plan Des func (newState *DestroyContext) SyncEffectiveFieldsDuringRead(existingState DestroyContext) { } -func (a DestroyContext) GetComplexFieldTypes() map[string]reflect.Type { +func (a DestroyContext) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2830,7 +2830,7 @@ func (newState *DestroyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan De func (newState *DestroyResponse) SyncEffectiveFieldsDuringRead(existingState DestroyResponse) { } -func (a DestroyResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DestroyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2881,7 +2881,7 @@ func (newState *DiskSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskSpec) func (newState *DiskSpec) SyncEffectiveFieldsDuringRead(existingState DiskSpec) { } -func (a DiskSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a DiskSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disk_type": reflect.TypeOf(DiskType{}), } @@ -2913,7 +2913,7 @@ func (newState *DiskType) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskType) func (newState *DiskType) SyncEffectiveFieldsDuringRead(existingState DiskType) { } -func (a DiskType) GetComplexFieldTypes() map[string]reflect.Type { +func (a DiskType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2939,7 +2939,7 @@ func (newState *DockerBasicAuth) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DockerBasicAuth) SyncEffectiveFieldsDuringRead(existingState DockerBasicAuth) { } -func (a DockerBasicAuth) GetComplexFieldTypes() map[string]reflect.Type { +func (a DockerBasicAuth) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2964,7 +2964,7 @@ func (newState *DockerImage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Docker func (newState *DockerImage) SyncEffectiveFieldsDuringRead(existingState DockerImage) { } -func (a DockerImage) GetComplexFieldTypes() map[string]reflect.Type { +func (a DockerImage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "basic_auth": reflect.TypeOf(DockerBasicAuth{}), } @@ -3141,7 +3141,7 @@ func (newState *EditCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditCl func (newState *EditCluster) SyncEffectiveFieldsDuringRead(existingState EditCluster) { } -func (a EditCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), "aws_attributes": reflect.TypeOf(AwsAttributes{}), @@ -3226,7 +3226,7 @@ func (newState *EditClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *EditClusterResponse) SyncEffectiveFieldsDuringRead(existingState EditClusterResponse) { } -func (a EditClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3276,7 +3276,7 @@ func (newState *EditInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *EditInstancePool) SyncEffectiveFieldsDuringRead(existingState EditInstancePool) { } -func (a EditInstancePool) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_tags": reflect.TypeOf(types.StringType), } @@ -3307,7 +3307,7 @@ func (newState *EditInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EditInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState EditInstancePoolResponse) { } -func (a EditInstancePoolResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3361,7 +3361,7 @@ func (newState *EditPolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditPol func (newState *EditPolicy) SyncEffectiveFieldsDuringRead(existingState EditPolicy) { } -func (a EditPolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } @@ -3393,7 +3393,7 @@ func (newState *EditPolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EditPolicyResponse) SyncEffectiveFieldsDuringRead(existingState EditPolicyResponse) { } -func (a EditPolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3412,7 +3412,7 @@ func (newState *EditResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditR func (newState *EditResponse) SyncEffectiveFieldsDuringRead(existingState EditResponse) { } -func (a EditResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3436,7 +3436,7 @@ func (newState *EnforceClusterComplianceRequest) SyncEffectiveFieldsDuringCreate func (newState *EnforceClusterComplianceRequest) SyncEffectiveFieldsDuringRead(existingState EnforceClusterComplianceRequest) { } -func (a EnforceClusterComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnforceClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3464,7 +3464,7 @@ func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringCreat func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringRead(existingState EnforceClusterComplianceResponse) { } -func (a EnforceClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnforceClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "changes": reflect.TypeOf(ClusterSettingsChange{}), } @@ -3505,7 +3505,7 @@ func (newState *Environment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Enviro func (newState *Environment) SyncEffectiveFieldsDuringRead(existingState Environment) { } -func (a Environment) GetComplexFieldTypes() map[string]reflect.Type { +func (a Environment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dependencies": reflect.TypeOf(types.StringType), } @@ -3579,7 +3579,7 @@ func (newState *EventDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Event func (newState *EventDetails) SyncEffectiveFieldsDuringRead(existingState EventDetails) { } -func (a EventDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a EventDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "attributes": reflect.TypeOf(ClusterAttributes{}), "cluster_size": reflect.TypeOf(ClusterSize{}), @@ -3669,7 +3669,7 @@ func (newState *GcpAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpA func (newState *GcpAttributes) SyncEffectiveFieldsDuringRead(existingState GcpAttributes) { } -func (a GcpAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3697,7 +3697,7 @@ func (newState *GcsStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Gcs func (newState *GcsStorageInfo) SyncEffectiveFieldsDuringRead(existingState GcsStorageInfo) { } -func (a GcsStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3721,7 +3721,7 @@ func (newState *GetClusterComplianceRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetClusterComplianceRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterComplianceRequest) { } -func (a GetClusterComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3751,7 +3751,7 @@ func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterComplianceResponse) { } -func (a GetClusterComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.StringType), } @@ -3780,7 +3780,7 @@ func (newState *GetClusterPermissionLevelsRequest) SyncEffectiveFieldsDuringCrea func (newState *GetClusterPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionLevelsRequest) { } -func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3803,7 +3803,7 @@ func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringCre func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionLevelsResponse) { } -func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ClusterPermissionsDescription{}), } @@ -3831,7 +3831,7 @@ func (newState *GetClusterPermissionsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *GetClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionsRequest) { } -func (a GetClusterPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3855,7 +3855,7 @@ func (newState *GetClusterPolicyPermissionLevelsRequest) SyncEffectiveFieldsDuri func (newState *GetClusterPolicyPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionLevelsRequest) { } -func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3878,7 +3878,7 @@ func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDur func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionLevelsResponse) { } -func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ClusterPolicyPermissionsDescription{}), } @@ -3906,7 +3906,7 @@ func (newState *GetClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringCre func (newState *GetClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionsRequest) { } -func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3930,7 +3930,7 @@ func (newState *GetClusterPolicyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetClusterPolicyRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyRequest) { } -func (a GetClusterPolicyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterPolicyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3954,7 +3954,7 @@ func (newState *GetClusterRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetClusterRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterRequest) { } -func (a GetClusterRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetClusterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3995,7 +3995,7 @@ func (newState *GetEvents) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetEvent func (newState *GetEvents) SyncEffectiveFieldsDuringRead(existingState GetEvents) { } -func (a GetEvents) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEvents) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "event_types": reflect.TypeOf(types.StringType), } @@ -4034,7 +4034,7 @@ func (newState *GetEventsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetEventsResponse) SyncEffectiveFieldsDuringRead(existingState GetEventsResponse) { } -func (a GetEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(ClusterEvent{}), "next_page": reflect.TypeOf(GetEvents{}), @@ -4067,7 +4067,7 @@ func (newState *GetGlobalInitScriptRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetGlobalInitScriptRequest) SyncEffectiveFieldsDuringRead(existingState GetGlobalInitScriptRequest) { } -func (a GetGlobalInitScriptRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4161,7 +4161,7 @@ func (newState *GetInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetInstancePool) SyncEffectiveFieldsDuringRead(existingState GetInstancePool) { } -func (a GetInstancePool) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), @@ -4233,7 +4233,7 @@ func (newState *GetInstancePoolPermissionLevelsRequest) SyncEffectiveFieldsDurin func (newState *GetInstancePoolPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionLevelsRequest) { } -func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4256,7 +4256,7 @@ func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuri func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionLevelsResponse) { } -func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(InstancePoolPermissionsDescription{}), } @@ -4284,7 +4284,7 @@ func (newState *GetInstancePoolPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *GetInstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionsRequest) { } -func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4308,7 +4308,7 @@ func (newState *GetInstancePoolRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetInstancePoolRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolRequest) { } -func (a GetInstancePoolRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetInstancePoolRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4335,7 +4335,7 @@ func (newState *GetPolicyFamilyRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPolicyFamilyRequest) SyncEffectiveFieldsDuringRead(existingState GetPolicyFamilyRequest) { } -func (a GetPolicyFamilyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPolicyFamilyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4359,7 +4359,7 @@ func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringRead(existingState GetSparkVersionsResponse) { } -func (a GetSparkVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetSparkVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "versions": reflect.TypeOf(SparkVersion{}), } @@ -4402,7 +4402,7 @@ func (newState *GlobalInitScriptCreateRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GlobalInitScriptCreateRequest) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptCreateRequest) { } -func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4445,7 +4445,7 @@ func (newState *GlobalInitScriptDetails) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GlobalInitScriptDetails) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptDetails) { } -func (a GlobalInitScriptDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a GlobalInitScriptDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4494,7 +4494,7 @@ func (newState *GlobalInitScriptDetailsWithContent) SyncEffectiveFieldsDuringCre func (newState *GlobalInitScriptDetailsWithContent) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptDetailsWithContent) { } -func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4544,7 +4544,7 @@ func (newState *GlobalInitScriptUpdateRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GlobalInitScriptUpdateRequest) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptUpdateRequest) { } -func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4575,7 +4575,7 @@ func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptEventDetails) { } -func (a InitScriptEventDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a InitScriptEventDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), "global": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), @@ -4611,7 +4611,7 @@ func (newState *InitScriptExecutionDetails) SyncEffectiveFieldsDuringCreateOrUpd func (newState *InitScriptExecutionDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptExecutionDetails) { } -func (a InitScriptExecutionDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a InitScriptExecutionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4659,7 +4659,7 @@ func (newState *InitScriptInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ini func (newState *InitScriptInfo) SyncEffectiveFieldsDuringRead(existingState InitScriptInfo) { } -func (a InitScriptInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a InitScriptInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "abfss": reflect.TypeOf(Adlsgen2Info{}), "dbfs": reflect.TypeOf(DbfsStorageInfo{}), @@ -4712,7 +4712,7 @@ func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringCrea func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptInfoAndExecutionDetails) { } -func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "execution_details": reflect.TypeOf(InitScriptExecutionDetails{}), "script": reflect.TypeOf(InitScriptInfo{}), @@ -4745,7 +4745,7 @@ func (newState *InstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan I func (newState *InstallLibraries) SyncEffectiveFieldsDuringRead(existingState InstallLibraries) { } -func (a InstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } @@ -4771,7 +4771,7 @@ func (newState *InstallLibrariesResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *InstallLibrariesResponse) SyncEffectiveFieldsDuringRead(existingState InstallLibrariesResponse) { } -func (a InstallLibrariesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4798,7 +4798,7 @@ func (newState *InstancePoolAccessControlRequest) SyncEffectiveFieldsDuringCreat func (newState *InstancePoolAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState InstancePoolAccessControlRequest) { } -func (a InstancePoolAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4832,7 +4832,7 @@ func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringCrea func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState InstancePoolAccessControlResponse) { } -func (a InstancePoolAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(InstancePoolPermission{}), } @@ -4934,7 +4934,7 @@ func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringRead(existingState InstancePoolAndStats) { } -func (a InstancePoolAndStats) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), @@ -5032,7 +5032,7 @@ func (newState *InstancePoolAwsAttributes) SyncEffectiveFieldsDuringCreateOrUpda func (newState *InstancePoolAwsAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolAwsAttributes) { } -func (a InstancePoolAwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5063,7 +5063,7 @@ func (newState *InstancePoolAzureAttributes) SyncEffectiveFieldsDuringCreateOrUp func (newState *InstancePoolAzureAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolAzureAttributes) { } -func (a InstancePoolAzureAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolAzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5113,7 +5113,7 @@ func (newState *InstancePoolGcpAttributes) SyncEffectiveFieldsDuringCreateOrUpda func (newState *InstancePoolGcpAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolGcpAttributes) { } -func (a InstancePoolGcpAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolGcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5141,7 +5141,7 @@ func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermission) { } -func (a InstancePoolPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -5173,7 +5173,7 @@ func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissions) { } -func (a InstancePoolPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(InstancePoolAccessControlResponse{}), } @@ -5203,7 +5203,7 @@ func (newState *InstancePoolPermissionsDescription) SyncEffectiveFieldsDuringCre func (newState *InstancePoolPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissionsDescription) { } -func (a InstancePoolPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5228,7 +5228,7 @@ func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringCreateO func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissionsRequest) { } -func (a InstancePoolPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(InstancePoolAccessControlRequest{}), } @@ -5262,7 +5262,7 @@ func (newState *InstancePoolStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstancePoolStats) SyncEffectiveFieldsDuringRead(existingState InstancePoolStats) { } -func (a InstancePoolStats) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5291,7 +5291,7 @@ func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringRead(existingState InstancePoolStatus) { } -func (a InstancePoolStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstancePoolStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "pending_instance_errors": reflect.TypeOf(PendingInstanceError{}), } @@ -5334,7 +5334,7 @@ func (newState *InstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan In func (newState *InstanceProfile) SyncEffectiveFieldsDuringRead(existingState InstanceProfile) { } -func (a InstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5390,7 +5390,7 @@ func (newState *Library) SyncEffectiveFieldsDuringCreateOrUpdate(plan Library) { func (newState *Library) SyncEffectiveFieldsDuringRead(existingState Library) { } -func (a Library) GetComplexFieldTypes() map[string]reflect.Type { +func (a Library) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cran": reflect.TypeOf(RCranLibrary{}), "maven": reflect.TypeOf(MavenLibrary{}), @@ -5438,7 +5438,7 @@ func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringRead(existingState LibraryFullStatus) { } -func (a LibraryFullStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library": reflect.TypeOf(Library{}), "messages": reflect.TypeOf(types.StringType), @@ -5471,7 +5471,7 @@ func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuring func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuringRead(existingState ListAllClusterLibraryStatusesResponse) { } -func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "statuses": reflect.TypeOf(ClusterLibraryStatuses{}), } @@ -5501,7 +5501,7 @@ func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringRead(existingState ListAvailableZonesResponse) { } -func (a ListAvailableZonesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAvailableZonesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "zones": reflect.TypeOf(types.StringType), } @@ -5537,7 +5537,7 @@ func (newState *ListClusterCompliancesRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListClusterCompliancesRequest) SyncEffectiveFieldsDuringRead(existingState ListClusterCompliancesRequest) { } -func (a ListClusterCompliancesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClusterCompliancesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5569,7 +5569,7 @@ func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringRead(existingState ListClusterCompliancesResponse) { } -func (a ListClusterCompliancesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClusterCompliancesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(ClusterCompliance{}), } @@ -5604,7 +5604,7 @@ func (newState *ListClusterPoliciesRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListClusterPoliciesRequest) SyncEffectiveFieldsDuringRead(existingState ListClusterPoliciesRequest) { } -func (a ListClusterPoliciesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClusterPoliciesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5634,7 +5634,7 @@ func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringRead(existingState ListClustersFilterBy) { } -func (a ListClustersFilterBy) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_sources": reflect.TypeOf(types.StringType), "cluster_states": reflect.TypeOf(types.StringType), @@ -5677,7 +5677,7 @@ func (newState *ListClustersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListClustersRequest) SyncEffectiveFieldsDuringRead(existingState ListClustersRequest) { } -func (a ListClustersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClustersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter_by": reflect.TypeOf(ListClustersFilterBy{}), "sort_by": reflect.TypeOf(ListClustersSortBy{}), @@ -5717,7 +5717,7 @@ func (newState *ListClustersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListClustersResponse) SyncEffectiveFieldsDuringRead(existingState ListClustersResponse) { } -func (a ListClustersResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClustersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(ClusterDetails{}), } @@ -5750,7 +5750,7 @@ func (newState *ListClustersSortBy) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListClustersSortBy) SyncEffectiveFieldsDuringRead(existingState ListClustersSortBy) { } -func (a ListClustersSortBy) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListClustersSortBy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5773,7 +5773,7 @@ func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringCreateOr func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringRead(existingState ListGlobalInitScriptsResponse) { } -func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "scripts": reflect.TypeOf(GlobalInitScriptDetails{}), } @@ -5799,7 +5799,7 @@ func (newState *ListInstancePools) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListInstancePools) SyncEffectiveFieldsDuringRead(existingState ListInstancePools) { } -func (a ListInstancePools) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListInstancePools) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "instance_pools": reflect.TypeOf(InstancePoolAndStats{}), } @@ -5826,7 +5826,7 @@ func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringRead(existingState ListInstanceProfilesResponse) { } -func (a ListInstanceProfilesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListInstanceProfilesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "instance_profiles": reflect.TypeOf(InstanceProfile{}), } @@ -5853,7 +5853,7 @@ func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringRead(existingState ListNodeTypesResponse) { } -func (a ListNodeTypesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNodeTypesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "node_types": reflect.TypeOf(NodeType{}), } @@ -5880,7 +5880,7 @@ func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringRead(existingState ListPoliciesResponse) { } -func (a ListPoliciesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPoliciesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "policies": reflect.TypeOf(Policy{}), } @@ -5910,7 +5910,7 @@ func (newState *ListPolicyFamiliesRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListPolicyFamiliesRequest) SyncEffectiveFieldsDuringRead(existingState ListPolicyFamiliesRequest) { } -func (a ListPolicyFamiliesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPolicyFamiliesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5937,7 +5937,7 @@ func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringRead(existingState ListPolicyFamiliesResponse) { } -func (a ListPolicyFamiliesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPolicyFamiliesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "policy_families": reflect.TypeOf(PolicyFamily{}), } @@ -5965,7 +5965,7 @@ func (newState *LocalFileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Loca func (newState *LocalFileInfo) SyncEffectiveFieldsDuringRead(existingState LocalFileInfo) { } -func (a LocalFileInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a LocalFileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5990,7 +5990,7 @@ func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringRead(existingState LogAnalyticsInfo) { } -func (a LogAnalyticsInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogAnalyticsInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6018,7 +6018,7 @@ func (newState *LogSyncStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogS func (newState *LogSyncStatus) SyncEffectiveFieldsDuringRead(existingState LogSyncStatus) { } -func (a LogSyncStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogSyncStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6051,7 +6051,7 @@ func (newState *MavenLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Maven func (newState *MavenLibrary) SyncEffectiveFieldsDuringRead(existingState MavenLibrary) { } -func (a MavenLibrary) GetComplexFieldTypes() map[string]reflect.Type { +func (a MavenLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exclusions": reflect.TypeOf(types.StringType), } @@ -6087,7 +6087,7 @@ func (newState *NodeInstanceType) SyncEffectiveFieldsDuringCreateOrUpdate(plan N func (newState *NodeInstanceType) SyncEffectiveFieldsDuringRead(existingState NodeInstanceType) { } -func (a NodeInstanceType) GetComplexFieldTypes() map[string]reflect.Type { +func (a NodeInstanceType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6159,7 +6159,7 @@ func (newState *NodeType) SyncEffectiveFieldsDuringCreateOrUpdate(plan NodeType) func (newState *NodeType) SyncEffectiveFieldsDuringRead(existingState NodeType) { } -func (a NodeType) GetComplexFieldTypes() map[string]reflect.Type { +func (a NodeType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "node_info": reflect.TypeOf(CloudProviderNodeInfo{}), "node_instance_type": reflect.TypeOf(NodeInstanceType{}), @@ -6210,7 +6210,7 @@ func (newState *PendingInstanceError) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PendingInstanceError) SyncEffectiveFieldsDuringRead(existingState PendingInstanceError) { } -func (a PendingInstanceError) GetComplexFieldTypes() map[string]reflect.Type { +func (a PendingInstanceError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6234,7 +6234,7 @@ func (newState *PermanentDeleteCluster) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PermanentDeleteCluster) SyncEffectiveFieldsDuringRead(existingState PermanentDeleteCluster) { } -func (a PermanentDeleteCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermanentDeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6255,7 +6255,7 @@ func (newState *PermanentDeleteClusterResponse) SyncEffectiveFieldsDuringCreateO func (newState *PermanentDeleteClusterResponse) SyncEffectiveFieldsDuringRead(existingState PermanentDeleteClusterResponse) { } -func (a PermanentDeleteClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermanentDeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6276,7 +6276,7 @@ func (newState *PinCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan PinClus func (newState *PinCluster) SyncEffectiveFieldsDuringRead(existingState PinCluster) { } -func (a PinCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a PinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6297,7 +6297,7 @@ func (newState *PinClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PinClusterResponse) SyncEffectiveFieldsDuringRead(existingState PinClusterResponse) { } -func (a PinClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6362,7 +6362,7 @@ func (newState *Policy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Policy) { func (newState *Policy) SyncEffectiveFieldsDuringRead(existingState Policy) { } -func (a Policy) GetComplexFieldTypes() map[string]reflect.Type { +func (a Policy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } @@ -6408,7 +6408,7 @@ func (newState *PolicyFamily) SyncEffectiveFieldsDuringCreateOrUpdate(plan Polic func (newState *PolicyFamily) SyncEffectiveFieldsDuringRead(existingState PolicyFamily) { } -func (a PolicyFamily) GetComplexFieldTypes() map[string]reflect.Type { +func (a PolicyFamily) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6439,7 +6439,7 @@ func (newState *PythonPyPiLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PythonPyPiLibrary) SyncEffectiveFieldsDuringRead(existingState PythonPyPiLibrary) { } -func (a PythonPyPiLibrary) GetComplexFieldTypes() map[string]reflect.Type { +func (a PythonPyPiLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6466,7 +6466,7 @@ func (newState *RCranLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan RCran func (newState *RCranLibrary) SyncEffectiveFieldsDuringRead(existingState RCranLibrary) { } -func (a RCranLibrary) GetComplexFieldTypes() map[string]reflect.Type { +func (a RCranLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6490,7 +6490,7 @@ func (newState *RemoveInstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *RemoveInstanceProfile) SyncEffectiveFieldsDuringRead(existingState RemoveInstanceProfile) { } -func (a RemoveInstanceProfile) GetComplexFieldTypes() map[string]reflect.Type { +func (a RemoveInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6511,7 +6511,7 @@ func (newState *RemoveResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rem func (newState *RemoveResponse) SyncEffectiveFieldsDuringRead(existingState RemoveResponse) { } -func (a RemoveResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RemoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6547,7 +6547,7 @@ func (newState *ResizeCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resi func (newState *ResizeCluster) SyncEffectiveFieldsDuringRead(existingState ResizeCluster) { } -func (a ResizeCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResizeCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), } @@ -6574,7 +6574,7 @@ func (newState *ResizeClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ResizeClusterResponse) SyncEffectiveFieldsDuringRead(existingState ResizeClusterResponse) { } -func (a ResizeClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResizeClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6597,7 +6597,7 @@ func (newState *RestartCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *RestartCluster) SyncEffectiveFieldsDuringRead(existingState RestartCluster) { } -func (a RestartCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestartCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6619,7 +6619,7 @@ func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringRead(existingState RestartClusterResponse) { } -func (a RestartClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6659,7 +6659,7 @@ func (newState *Results) SyncEffectiveFieldsDuringCreateOrUpdate(plan Results) { func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { } -func (a Results) GetComplexFieldTypes() map[string]reflect.Type { +func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fileNames": reflect.TypeOf(types.StringType), "schema": reflect.TypeOf(struct{}{}), @@ -6728,7 +6728,7 @@ func (newState *S3StorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan S3St func (newState *S3StorageInfo) SyncEffectiveFieldsDuringRead(existingState S3StorageInfo) { } -func (a S3StorageInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a S3StorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6780,7 +6780,7 @@ func (newState *SparkNode) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparkNod func (newState *SparkNode) SyncEffectiveFieldsDuringRead(existingState SparkNode) { } -func (a SparkNode) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparkNode) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "node_aws_attributes": reflect.TypeOf(SparkNodeAwsAttributes{}), } @@ -6813,7 +6813,7 @@ func (newState *SparkNodeAwsAttributes) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SparkNodeAwsAttributes) SyncEffectiveFieldsDuringRead(existingState SparkNodeAwsAttributes) { } -func (a SparkNodeAwsAttributes) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparkNodeAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6842,7 +6842,7 @@ func (newState *SparkVersion) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spark func (newState *SparkVersion) SyncEffectiveFieldsDuringRead(existingState SparkVersion) { } -func (a SparkVersion) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparkVersion) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6866,7 +6866,7 @@ func (newState *StartCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Start func (newState *StartCluster) SyncEffectiveFieldsDuringRead(existingState StartCluster) { } -func (a StartCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6887,7 +6887,7 @@ func (newState *StartClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StartClusterResponse) SyncEffectiveFieldsDuringRead(existingState StartClusterResponse) { } -func (a StartClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6913,7 +6913,7 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState TerminationReason) { } -func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { +func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -6944,7 +6944,7 @@ func (newState *UninstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UninstallLibraries) SyncEffectiveFieldsDuringRead(existingState UninstallLibraries) { } -func (a UninstallLibraries) GetComplexFieldTypes() map[string]reflect.Type { +func (a UninstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } @@ -6970,7 +6970,7 @@ func (newState *UninstallLibrariesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UninstallLibrariesResponse) SyncEffectiveFieldsDuringRead(existingState UninstallLibrariesResponse) { } -func (a UninstallLibrariesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UninstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6991,7 +6991,7 @@ func (newState *UnpinCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Unpin func (newState *UnpinCluster) SyncEffectiveFieldsDuringRead(existingState UnpinCluster) { } -func (a UnpinCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a UnpinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7012,7 +7012,7 @@ func (newState *UnpinClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UnpinClusterResponse) SyncEffectiveFieldsDuringRead(existingState UnpinClusterResponse) { } -func (a UnpinClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UnpinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7041,7 +7041,7 @@ func (newState *UpdateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateCluster) SyncEffectiveFieldsDuringRead(existingState UpdateCluster) { } -func (a UpdateCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster": reflect.TypeOf(UpdateClusterResource{}), } @@ -7213,7 +7213,7 @@ func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringRead(existingState UpdateClusterResource) { } -func (a UpdateClusterResource) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), "aws_attributes": reflect.TypeOf(AwsAttributes{}), @@ -7296,7 +7296,7 @@ func (newState *UpdateClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateClusterResponse) SyncEffectiveFieldsDuringRead(existingState UpdateClusterResponse) { } -func (a UpdateClusterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7315,7 +7315,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7336,7 +7336,7 @@ func (newState *VolumesStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *VolumesStorageInfo) SyncEffectiveFieldsDuringRead(existingState VolumesStorageInfo) { } -func (a VolumesStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a VolumesStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -7359,7 +7359,7 @@ func (newState *WorkloadType) SyncEffectiveFieldsDuringCreateOrUpdate(plan Workl func (newState *WorkloadType) SyncEffectiveFieldsDuringRead(existingState WorkloadType) { } -func (a WorkloadType) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkloadType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clients": reflect.TypeOf(ClientsTypes{}), } @@ -7387,7 +7387,7 @@ func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringRead(existingState WorkspaceStorageInfo) { } -func (a WorkspaceStorageInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 703ccb06f6..cbafe79a14 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -32,7 +32,7 @@ func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState CreateDashboardRequest) { } -func (a CreateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dashboard": reflect.TypeOf(Dashboard{}), } @@ -62,7 +62,7 @@ func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringRead(existingState CreateScheduleRequest) { } -func (a CreateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schedule": reflect.TypeOf(Schedule{}), } @@ -95,7 +95,7 @@ func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState CreateSubscriptionRequest) { } -func (a CreateSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscription": reflect.TypeOf(Subscription{}), } @@ -132,7 +132,7 @@ func (newState *CronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronS func (newState *CronSchedule) SyncEffectiveFieldsDuringRead(existingState CronSchedule) { } -func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { +func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -187,7 +187,7 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboar func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard) { } -func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { +func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -225,7 +225,7 @@ func (newState *DeleteScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteScheduleRequest) SyncEffectiveFieldsDuringRead(existingState DeleteScheduleRequest) { } -func (a DeleteScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -248,7 +248,7 @@ func (newState *DeleteScheduleResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteScheduleResponse) SyncEffectiveFieldsDuringRead(existingState DeleteScheduleResponse) { } -func (a DeleteScheduleResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteScheduleResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -277,7 +277,7 @@ func (newState *DeleteSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteSubscriptionRequest) { } -func (a DeleteSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -301,7 +301,7 @@ func (newState *DeleteSubscriptionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteSubscriptionResponse) SyncEffectiveFieldsDuringRead(existingState DeleteSubscriptionResponse) { } -func (a DeleteSubscriptionResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteSubscriptionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -324,7 +324,7 @@ func (newState *GenieAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GenieAttachment) SyncEffectiveFieldsDuringRead(existingState GenieAttachment) { } -func (a GenieAttachment) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieAttachment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(QueryAttachment{}), "text": reflect.TypeOf(TextAttachment{}), @@ -365,7 +365,7 @@ func (newState *GenieConversation) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GenieConversation) SyncEffectiveFieldsDuringRead(existingState GenieConversation) { } -func (a GenieConversation) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieConversation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -397,7 +397,7 @@ func (newState *GenieCreateConversationMessageRequest) SyncEffectiveFieldsDuring func (newState *GenieCreateConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieCreateConversationMessageRequest) { } -func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -427,7 +427,7 @@ func (newState *GenieExecuteMessageQueryRequest) SyncEffectiveFieldsDuringCreate func (newState *GenieExecuteMessageQueryRequest) SyncEffectiveFieldsDuringRead(existingState GenieExecuteMessageQueryRequest) { } -func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -459,7 +459,7 @@ func (newState *GenieGetConversationMessageRequest) SyncEffectiveFieldsDuringCre func (newState *GenieGetConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieGetConversationMessageRequest) { } -func (a GenieGetConversationMessageRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieGetConversationMessageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -489,7 +489,7 @@ func (newState *GenieGetMessageQueryResultRequest) SyncEffectiveFieldsDuringCrea func (newState *GenieGetMessageQueryResultRequest) SyncEffectiveFieldsDuringRead(existingState GenieGetMessageQueryResultRequest) { } -func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -515,7 +515,7 @@ func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringCre func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringRead(existingState GenieGetMessageQueryResultResponse) { } -func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "statement_response": reflect.TypeOf(sql.StatementResponse{}), } @@ -577,7 +577,7 @@ func (newState *GenieMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Genie func (newState *GenieMessage) SyncEffectiveFieldsDuringRead(existingState GenieMessage) { } -func (a GenieMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "attachments": reflect.TypeOf(GenieAttachment{}), "error": reflect.TypeOf(MessageError{}), @@ -623,7 +623,7 @@ func (newState *GenieStartConversationMessageRequest) SyncEffectiveFieldsDuringC func (newState *GenieStartConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieStartConversationMessageRequest) { } -func (a GenieStartConversationMessageRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieStartConversationMessageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -652,7 +652,7 @@ func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringCreateO func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringRead(existingState GenieStartConversationResponse) { } -func (a GenieStartConversationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenieStartConversationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "conversation": reflect.TypeOf(GenieConversation{}), "message": reflect.TypeOf(GenieMessage{}), @@ -686,7 +686,7 @@ func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetDashboardRequest) { } -func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -710,7 +710,7 @@ func (newState *GetPublishedDashboardRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *GetPublishedDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetPublishedDashboardRequest) { } -func (a GetPublishedDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPublishedDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -736,7 +736,7 @@ func (newState *GetScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetScheduleRequest) SyncEffectiveFieldsDuringRead(existingState GetScheduleRequest) { } -func (a GetScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -765,7 +765,7 @@ func (newState *GetSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState GetSubscriptionRequest) { } -func (a GetSubscriptionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -799,7 +799,7 @@ func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringRead(existingState ListDashboardsRequest) { } -func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -827,7 +827,7 @@ func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringRead(existingState ListDashboardsResponse) { } -func (a ListDashboardsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListDashboardsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dashboards": reflect.TypeOf(Dashboard{}), } @@ -861,7 +861,7 @@ func (newState *ListSchedulesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListSchedulesRequest) SyncEffectiveFieldsDuringRead(existingState ListSchedulesRequest) { } -func (a ListSchedulesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSchedulesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -890,7 +890,7 @@ func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringRead(existingState ListSchedulesResponse) { } -func (a ListSchedulesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSchedulesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schedules": reflect.TypeOf(Schedule{}), } @@ -926,7 +926,7 @@ func (newState *ListSubscriptionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListSubscriptionsRequest) SyncEffectiveFieldsDuringRead(existingState ListSubscriptionsRequest) { } -func (a ListSubscriptionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSubscriptionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -956,7 +956,7 @@ func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringRead(existingState ListSubscriptionsResponse) { } -func (a ListSubscriptionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSubscriptionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriptions": reflect.TypeOf(Subscription{}), } @@ -985,7 +985,7 @@ func (newState *MessageError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Messa func (newState *MessageError) SyncEffectiveFieldsDuringRead(existingState MessageError) { } -func (a MessageError) GetComplexFieldTypes() map[string]reflect.Type { +func (a MessageError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1014,7 +1014,7 @@ func (newState *MigrateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *MigrateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState MigrateDashboardRequest) { } -func (a MigrateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a MigrateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1046,7 +1046,7 @@ func (newState *PublishRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pub func (newState *PublishRequest) SyncEffectiveFieldsDuringRead(existingState PublishRequest) { } -func (a PublishRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PublishRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1077,7 +1077,7 @@ func (newState *PublishedDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PublishedDashboard) SyncEffectiveFieldsDuringRead(existingState PublishedDashboard) { } -func (a PublishedDashboard) GetComplexFieldTypes() map[string]reflect.Type { +func (a PublishedDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1117,7 +1117,7 @@ func (newState *QueryAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Qu func (newState *QueryAttachment) SyncEffectiveFieldsDuringRead(existingState QueryAttachment) { } -func (a QueryAttachment) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryAttachment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1152,7 +1152,7 @@ func (newState *Result) SyncEffectiveFieldsDuringCreateOrUpdate(plan Result) { func (newState *Result) SyncEffectiveFieldsDuringRead(existingState Result) { } -func (a Result) GetComplexFieldTypes() map[string]reflect.Type { +func (a Result) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1196,7 +1196,7 @@ func (newState *Schedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan Schedule) func (newState *Schedule) SyncEffectiveFieldsDuringRead(existingState Schedule) { } -func (a Schedule) GetComplexFieldTypes() map[string]reflect.Type { +func (a Schedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cron_schedule": reflect.TypeOf(CronSchedule{}), } @@ -1235,7 +1235,7 @@ func (newState *Subscriber) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subscri func (newState *Subscriber) SyncEffectiveFieldsDuringRead(existingState Subscriber) { } -func (a Subscriber) GetComplexFieldTypes() map[string]reflect.Type { +func (a Subscriber) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "destination_subscriber": reflect.TypeOf(SubscriptionSubscriberDestination{}), "user_subscriber": reflect.TypeOf(SubscriptionSubscriberUser{}), @@ -1284,7 +1284,7 @@ func (newState *Subscription) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subsc func (newState *Subscription) SyncEffectiveFieldsDuringRead(existingState Subscription) { } -func (a Subscription) GetComplexFieldTypes() map[string]reflect.Type { +func (a Subscription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriber": reflect.TypeOf(Subscriber{}), } @@ -1319,7 +1319,7 @@ func (newState *SubscriptionSubscriberDestination) SyncEffectiveFieldsDuringCrea func (newState *SubscriptionSubscriberDestination) SyncEffectiveFieldsDuringRead(existingState SubscriptionSubscriberDestination) { } -func (a SubscriptionSubscriberDestination) GetComplexFieldTypes() map[string]reflect.Type { +func (a SubscriptionSubscriberDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1342,7 +1342,7 @@ func (newState *SubscriptionSubscriberUser) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SubscriptionSubscriberUser) SyncEffectiveFieldsDuringRead(existingState SubscriptionSubscriberUser) { } -func (a SubscriptionSubscriberUser) GetComplexFieldTypes() map[string]reflect.Type { +func (a SubscriptionSubscriberUser) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1367,7 +1367,7 @@ func (newState *TextAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tex func (newState *TextAttachment) SyncEffectiveFieldsDuringRead(existingState TextAttachment) { } -func (a TextAttachment) GetComplexFieldTypes() map[string]reflect.Type { +func (a TextAttachment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1392,7 +1392,7 @@ func (newState *TrashDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *TrashDashboardRequest) SyncEffectiveFieldsDuringRead(existingState TrashDashboardRequest) { } -func (a TrashDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TrashDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1413,7 +1413,7 @@ func (newState *TrashDashboardResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *TrashDashboardResponse) SyncEffectiveFieldsDuringRead(existingState TrashDashboardResponse) { } -func (a TrashDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a TrashDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1435,7 +1435,7 @@ func (newState *UnpublishDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UnpublishDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UnpublishDashboardRequest) { } -func (a UnpublishDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UnpublishDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1456,7 +1456,7 @@ func (newState *UnpublishDashboardResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UnpublishDashboardResponse) SyncEffectiveFieldsDuringRead(existingState UnpublishDashboardResponse) { } -func (a UnpublishDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UnpublishDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1479,7 +1479,7 @@ func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDashboardRequest) { } -func (a UpdateDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dashboard": reflect.TypeOf(Dashboard{}), } @@ -1512,7 +1512,7 @@ func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringRead(existingState UpdateScheduleRequest) { } -func (a UpdateScheduleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schedule": reflect.TypeOf(Schedule{}), } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index dcb8284d9e..3581ab4739 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -34,7 +34,7 @@ func (newState *AddBlock) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddBlock) func (newState *AddBlock) SyncEffectiveFieldsDuringRead(existingState AddBlock) { } -func (a AddBlock) GetComplexFieldTypes() map[string]reflect.Type { +func (a AddBlock) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -56,7 +56,7 @@ func (newState *AddBlockResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan A func (newState *AddBlockResponse) SyncEffectiveFieldsDuringRead(existingState AddBlockResponse) { } -func (a AddBlockResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AddBlockResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -77,7 +77,7 @@ func (newState *Close) SyncEffectiveFieldsDuringCreateOrUpdate(plan Close) { func (newState *Close) SyncEffectiveFieldsDuringRead(existingState Close) { } -func (a Close) GetComplexFieldTypes() map[string]reflect.Type { +func (a Close) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -98,7 +98,7 @@ func (newState *CloseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clos func (newState *CloseResponse) SyncEffectiveFieldsDuringRead(existingState CloseResponse) { } -func (a CloseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CloseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -121,7 +121,7 @@ func (newState *Create) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create) { func (newState *Create) SyncEffectiveFieldsDuringRead(existingState Create) { } -func (a Create) GetComplexFieldTypes() map[string]reflect.Type { +func (a Create) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -146,7 +146,7 @@ func (newState *CreateDirectoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateDirectoryRequest) SyncEffectiveFieldsDuringRead(existingState CreateDirectoryRequest) { } -func (a CreateDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -167,7 +167,7 @@ func (newState *CreateDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState CreateDirectoryResponse) { } -func (a CreateDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -189,7 +189,7 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } -func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -216,7 +216,7 @@ func (newState *Delete) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete) { func (newState *Delete) SyncEffectiveFieldsDuringRead(existingState Delete) { } -func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { +func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -241,7 +241,7 @@ func (newState *DeleteDirectoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteDirectoryRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDirectoryRequest) { } -func (a DeleteDirectoryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -262,7 +262,7 @@ func (newState *DeleteDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDirectoryResponse) { } -func (a DeleteDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -284,7 +284,7 @@ func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFileRequest) { } -func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -305,7 +305,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -335,7 +335,7 @@ func (newState *DirectoryEntry) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dir func (newState *DirectoryEntry) SyncEffectiveFieldsDuringRead(existingState DirectoryEntry) { } -func (a DirectoryEntry) GetComplexFieldTypes() map[string]reflect.Type { +func (a DirectoryEntry) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -363,7 +363,7 @@ func (newState *DownloadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DownloadRequest) SyncEffectiveFieldsDuringRead(existingState DownloadRequest) { } -func (a DownloadRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -391,7 +391,7 @@ func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DownloadResponse) SyncEffectiveFieldsDuringRead(existingState DownloadResponse) { } -func (a DownloadResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -423,7 +423,7 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } -func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -450,7 +450,7 @@ func (newState *GetDirectoryMetadataRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetDirectoryMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetDirectoryMetadataRequest) { } -func (a GetDirectoryMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDirectoryMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -471,7 +471,7 @@ func (newState *GetDirectoryMetadataResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetDirectoryMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetDirectoryMetadataResponse) { } -func (a GetDirectoryMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDirectoryMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -493,7 +493,7 @@ func (newState *GetMetadataRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetMetadataRequest) { } -func (a GetMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -519,7 +519,7 @@ func (newState *GetMetadataResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetMetadataResponse) { } -func (a GetMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -546,7 +546,7 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } -func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -571,7 +571,7 @@ func (newState *ListDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListDbfsRequest) SyncEffectiveFieldsDuringRead(existingState ListDbfsRequest) { } -func (a ListDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -615,7 +615,7 @@ func (newState *ListDirectoryContentsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListDirectoryContentsRequest) SyncEffectiveFieldsDuringRead(existingState ListDirectoryContentsRequest) { } -func (a ListDirectoryContentsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListDirectoryContentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -642,7 +642,7 @@ func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState ListDirectoryResponse) { } -func (a ListDirectoryResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "contents": reflect.TypeOf(DirectoryEntry{}), } @@ -671,7 +671,7 @@ func (newState *ListStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListStatusResponse) SyncEffectiveFieldsDuringRead(existingState ListStatusResponse) { } -func (a ListStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "files": reflect.TypeOf(FileInfo{}), } @@ -698,7 +698,7 @@ func (newState *MkDirs) SyncEffectiveFieldsDuringCreateOrUpdate(plan MkDirs) { func (newState *MkDirs) SyncEffectiveFieldsDuringRead(existingState MkDirs) { } -func (a MkDirs) GetComplexFieldTypes() map[string]reflect.Type { +func (a MkDirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -719,7 +719,7 @@ func (newState *MkDirsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MkD func (newState *MkDirsResponse) SyncEffectiveFieldsDuringRead(existingState MkDirsResponse) { } -func (a MkDirsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a MkDirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -744,7 +744,7 @@ func (newState *Move) SyncEffectiveFieldsDuringCreateOrUpdate(plan Move) { func (newState *Move) SyncEffectiveFieldsDuringRead(existingState Move) { } -func (a Move) GetComplexFieldTypes() map[string]reflect.Type { +func (a Move) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -766,7 +766,7 @@ func (newState *MoveResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MoveR func (newState *MoveResponse) SyncEffectiveFieldsDuringRead(existingState MoveResponse) { } -func (a MoveResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a MoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -791,7 +791,7 @@ func (newState *Put) SyncEffectiveFieldsDuringCreateOrUpdate(plan Put) { func (newState *Put) SyncEffectiveFieldsDuringRead(existingState Put) { } -func (a Put) GetComplexFieldTypes() map[string]reflect.Type { +func (a Put) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -814,7 +814,7 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRes func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResponse) { } -func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -841,7 +841,7 @@ func (newState *ReadDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReadDbfsRequest) SyncEffectiveFieldsDuringRead(existingState ReadDbfsRequest) { } -func (a ReadDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReadDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -870,7 +870,7 @@ func (newState *ReadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReadR func (newState *ReadResponse) SyncEffectiveFieldsDuringRead(existingState ReadResponse) { } -func (a ReadResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -898,7 +898,7 @@ func (newState *UploadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Uplo func (newState *UploadRequest) SyncEffectiveFieldsDuringRead(existingState UploadRequest) { } -func (a UploadRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UploadRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -921,7 +921,7 @@ func (newState *UploadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upl func (newState *UploadResponse) SyncEffectiveFieldsDuringRead(existingState UploadResponse) { } -func (a UploadResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UploadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index d0e22810e8..114cb36797 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -36,7 +36,7 @@ func (newState *AccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *AccessControlRequest) SyncEffectiveFieldsDuringRead(existingState AccessControlRequest) { } -func (a AccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -70,7 +70,7 @@ func (newState *AccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AccessControlResponse) { } -func (a AccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(Permission{}), } @@ -108,7 +108,7 @@ func (newState *ComplexValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Compl func (newState *ComplexValue) SyncEffectiveFieldsDuringRead(existingState ComplexValue) { } -func (a ComplexValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a ComplexValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -136,7 +136,7 @@ func (newState *DeleteAccountGroupRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteAccountGroupRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountGroupRequest) { } -func (a DeleteAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -160,7 +160,7 @@ func (newState *DeleteAccountServicePrincipalRequest) SyncEffectiveFieldsDuringC func (newState *DeleteAccountServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountServicePrincipalRequest) { } -func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -184,7 +184,7 @@ func (newState *DeleteAccountUserRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteAccountUserRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountUserRequest) { } -func (a DeleteAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -208,7 +208,7 @@ func (newState *DeleteGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteGroupRequest) SyncEffectiveFieldsDuringRead(existingState DeleteGroupRequest) { } -func (a DeleteGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -229,7 +229,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -251,7 +251,7 @@ func (newState *DeleteServicePrincipalRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServicePrincipalRequest) { } -func (a DeleteServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -275,7 +275,7 @@ func (newState *DeleteUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteUserRequest) SyncEffectiveFieldsDuringRead(existingState DeleteUserRequest) { } -func (a DeleteUserRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -301,7 +301,7 @@ func (newState *DeleteWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspaceAssignmentRequest) { } -func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -323,7 +323,7 @@ func (newState *DeleteWorkspacePermissionAssignmentResponse) SyncEffectiveFields func (newState *DeleteWorkspacePermissionAssignmentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspacePermissionAssignmentResponse) { } -func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -345,7 +345,7 @@ func (newState *GetAccountGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetAccountGroupRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountGroupRequest) { } -func (a GetAccountGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -369,7 +369,7 @@ func (newState *GetAccountServicePrincipalRequest) SyncEffectiveFieldsDuringCrea func (newState *GetAccountServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountServicePrincipalRequest) { } -func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -414,7 +414,7 @@ func (newState *GetAccountUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetAccountUserRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountUserRequest) { } -func (a GetAccountUserRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -445,7 +445,7 @@ func (newState *GetAssignableRolesForResourceRequest) SyncEffectiveFieldsDuringC func (newState *GetAssignableRolesForResourceRequest) SyncEffectiveFieldsDuringRead(existingState GetAssignableRolesForResourceRequest) { } -func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -467,7 +467,7 @@ func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuring func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuringRead(existingState GetAssignableRolesForResourceResponse) { } -func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "roles": reflect.TypeOf(Role{}), } @@ -495,7 +495,7 @@ func (newState *GetGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetGroupRequest) SyncEffectiveFieldsDuringRead(existingState GetGroupRequest) { } -func (a GetGroupRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -518,7 +518,7 @@ func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringCr func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPasswordPermissionLevelsResponse) { } -func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(PasswordPermissionsDescription{}), } @@ -548,7 +548,7 @@ func (newState *GetPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetPermissionLevelsRequest) { } -func (a GetPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -572,7 +572,7 @@ func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPermissionLevelsResponse) { } -func (a GetPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(PermissionsDescription{}), } @@ -606,7 +606,7 @@ func (newState *GetPermissionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetPermissionRequest) SyncEffectiveFieldsDuringRead(existingState GetPermissionRequest) { } -func (a GetPermissionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -640,7 +640,7 @@ func (newState *GetRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetRuleSetRequest) SyncEffectiveFieldsDuringRead(existingState GetRuleSetRequest) { } -func (a GetRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -665,7 +665,7 @@ func (newState *GetServicePrincipalRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState GetServicePrincipalRequest) { } -func (a GetServicePrincipalRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -710,7 +710,7 @@ func (newState *GetUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetUserRequest) SyncEffectiveFieldsDuringRead(existingState GetUserRequest) { } -func (a GetUserRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -741,7 +741,7 @@ func (newState *GetWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceAssignmentRequest) { } -func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -766,7 +766,7 @@ func (newState *GrantRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan GrantRul func (newState *GrantRule) SyncEffectiveFieldsDuringRead(existingState GrantRule) { } -func (a GrantRule) GetComplexFieldTypes() map[string]reflect.Type { +func (a GrantRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "principals": reflect.TypeOf(types.StringType), } @@ -813,7 +813,7 @@ func (newState *Group) SyncEffectiveFieldsDuringCreateOrUpdate(plan Group) { func (newState *Group) SyncEffectiveFieldsDuringRead(existingState Group) { } -func (a Group) GetComplexFieldTypes() map[string]reflect.Type { +func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "entitlements": reflect.TypeOf(ComplexValue{}), "groups": reflect.TypeOf(ComplexValue{}), @@ -882,7 +882,7 @@ func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountGroupsRequest) { } -func (a ListAccountGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -930,7 +930,7 @@ func (newState *ListAccountServicePrincipalsRequest) SyncEffectiveFieldsDuringCr func (newState *ListAccountServicePrincipalsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountServicePrincipalsRequest) { } -func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -979,7 +979,7 @@ func (newState *ListAccountUsersRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListAccountUsersRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountUsersRequest) { } -func (a ListAccountUsersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAccountUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1027,7 +1027,7 @@ func (newState *ListGroupsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListGroupsRequest) SyncEffectiveFieldsDuringRead(existingState ListGroupsRequest) { } -func (a ListGroupsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1065,7 +1065,7 @@ func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringRead(existingState ListGroupsResponse) { } -func (a ListGroupsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(Group{}), "schemas": reflect.TypeOf(types.StringType), @@ -1108,7 +1108,7 @@ func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalResponse) { } -func (a ListServicePrincipalResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(ServicePrincipal{}), "schemas": reflect.TypeOf(types.StringType), @@ -1161,7 +1161,7 @@ func (newState *ListServicePrincipalsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListServicePrincipalsRequest) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalsRequest) { } -func (a ListServicePrincipalsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1210,7 +1210,7 @@ func (newState *ListUsersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListUsersRequest) SyncEffectiveFieldsDuringRead(existingState ListUsersRequest) { } -func (a ListUsersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1248,7 +1248,7 @@ func (newState *ListUsersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListUsersResponse) SyncEffectiveFieldsDuringRead(existingState ListUsersResponse) { } -func (a ListUsersResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(User{}), "schemas": reflect.TypeOf(types.StringType), @@ -1283,7 +1283,7 @@ func (newState *ListWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState ListWorkspaceAssignmentRequest) { } -func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1313,7 +1313,7 @@ func (newState *MigratePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *MigratePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState MigratePermissionsRequest) { } -func (a MigratePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a MigratePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1339,7 +1339,7 @@ func (newState *MigratePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *MigratePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState MigratePermissionsResponse) { } -func (a MigratePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a MigratePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1364,7 +1364,7 @@ func (newState *Name) SyncEffectiveFieldsDuringCreateOrUpdate(plan Name) { func (newState *Name) SyncEffectiveFieldsDuringRead(existingState Name) { } -func (a Name) GetComplexFieldTypes() map[string]reflect.Type { +func (a Name) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1391,7 +1391,7 @@ func (newState *ObjectPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ObjectPermissions) SyncEffectiveFieldsDuringRead(existingState ObjectPermissions) { } -func (a ObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a ObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControlResponse{}), } @@ -1425,7 +1425,7 @@ func (newState *PartialUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan Part func (newState *PartialUpdate) SyncEffectiveFieldsDuringRead(existingState PartialUpdate) { } -func (a PartialUpdate) GetComplexFieldTypes() map[string]reflect.Type { +func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Operations": reflect.TypeOf(Patch{}), "schemas": reflect.TypeOf(types.StringType), @@ -1463,7 +1463,7 @@ func (newState *PasswordAccessControlRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *PasswordAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState PasswordAccessControlRequest) { } -func (a PasswordAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PasswordAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1497,7 +1497,7 @@ func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringCreateOr func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState PasswordAccessControlResponse) { } -func (a PasswordAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PasswordAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(PasswordPermission{}), } @@ -1531,7 +1531,7 @@ func (newState *PasswordPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PasswordPermission) SyncEffectiveFieldsDuringRead(existingState PasswordPermission) { } -func (a PasswordPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a PasswordPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1563,7 +1563,7 @@ func (newState *PasswordPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PasswordPermissions) SyncEffectiveFieldsDuringRead(existingState PasswordPermissions) { } -func (a PasswordPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a PasswordPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PasswordAccessControlResponse{}), } @@ -1593,7 +1593,7 @@ func (newState *PasswordPermissionsDescription) SyncEffectiveFieldsDuringCreateO func (newState *PasswordPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PasswordPermissionsDescription) { } -func (a PasswordPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a PasswordPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1616,7 +1616,7 @@ func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PasswordPermissionsRequest) { } -func (a PasswordPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PasswordPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PasswordAccessControlRequest{}), } @@ -1647,7 +1647,7 @@ func (newState *Patch) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patch) { func (newState *Patch) SyncEffectiveFieldsDuringRead(existingState Patch) { } -func (a Patch) GetComplexFieldTypes() map[string]reflect.Type { +func (a Patch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1670,7 +1670,7 @@ func (newState *PatchResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patc func (newState *PatchResponse) SyncEffectiveFieldsDuringRead(existingState PatchResponse) { } -func (a PatchResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1694,7 +1694,7 @@ func (newState *Permission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Permiss func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permission) { } -func (a Permission) GetComplexFieldTypes() map[string]reflect.Type { +func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1729,7 +1729,7 @@ func (newState *PermissionAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PermissionAssignment) SyncEffectiveFieldsDuringRead(existingState PermissionAssignment) { } -func (a PermissionAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions": reflect.TypeOf(types.StringType), "principal": reflect.TypeOf(PrincipalOutput{}), @@ -1761,7 +1761,7 @@ func (newState *PermissionAssignments) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *PermissionAssignments) SyncEffectiveFieldsDuringRead(existingState PermissionAssignments) { } -func (a PermissionAssignments) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionAssignments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_assignments": reflect.TypeOf(PermissionAssignment{}), } @@ -1790,7 +1790,7 @@ func (newState *PermissionOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *PermissionOutput) SyncEffectiveFieldsDuringRead(existingState PermissionOutput) { } -func (a PermissionOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1815,7 +1815,7 @@ func (newState *PermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PermissionsDescription) { } -func (a PermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1846,7 +1846,7 @@ func (newState *PermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PermissionsRequest) { } -func (a PermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControlRequest{}), } @@ -1885,7 +1885,7 @@ func (newState *PrincipalOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pr func (newState *PrincipalOutput) SyncEffectiveFieldsDuringRead(existingState PrincipalOutput) { } -func (a PrincipalOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a PrincipalOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1913,7 +1913,7 @@ func (newState *ResourceMeta) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resou func (newState *ResourceMeta) SyncEffectiveFieldsDuringRead(existingState ResourceMeta) { } -func (a ResourceMeta) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResourceMeta) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1936,7 +1936,7 @@ func (newState *Role) SyncEffectiveFieldsDuringCreateOrUpdate(plan Role) { func (newState *Role) SyncEffectiveFieldsDuringRead(existingState Role) { } -func (a Role) GetComplexFieldTypes() map[string]reflect.Type { +func (a Role) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1963,7 +1963,7 @@ func (newState *RuleSetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ru func (newState *RuleSetResponse) SyncEffectiveFieldsDuringRead(existingState RuleSetResponse) { } -func (a RuleSetResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RuleSetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "grant_rules": reflect.TypeOf(GrantRule{}), } @@ -1998,7 +1998,7 @@ func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringRead(existingState RuleSetUpdateRequest) { } -func (a RuleSetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RuleSetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "grant_rules": reflect.TypeOf(GrantRule{}), } @@ -2046,7 +2046,7 @@ func (newState *ServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServicePrincipal) SyncEffectiveFieldsDuringRead(existingState ServicePrincipal) { } -func (a ServicePrincipal) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "entitlements": reflect.TypeOf(ComplexValue{}), "groups": reflect.TypeOf(ComplexValue{}), @@ -2088,7 +2088,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2111,7 +2111,7 @@ func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRuleSetRequest) { } -func (a UpdateRuleSetRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rule_set": reflect.TypeOf(RuleSetUpdateRequest{}), } @@ -2148,7 +2148,7 @@ func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceAssignments) { } -func (a UpdateWorkspaceAssignments) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateWorkspaceAssignments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions": reflect.TypeOf(types.StringType), } @@ -2206,7 +2206,7 @@ func (newState *User) SyncEffectiveFieldsDuringCreateOrUpdate(plan User) { func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { } -func (a User) GetComplexFieldTypes() map[string]reflect.Type { +func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "emails": reflect.TypeOf(ComplexValue{}), "entitlements": reflect.TypeOf(ComplexValue{}), @@ -2258,7 +2258,7 @@ func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringRead(existingState WorkspacePermissions) { } -func (a WorkspacePermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspacePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions": reflect.TypeOf(PermissionOutput{}), } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 1d61caac98..86f53339d7 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -48,7 +48,7 @@ func (newState *BaseJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseJob) { func (newState *BaseJob) SyncEffectiveFieldsDuringRead(existingState BaseJob) { } -func (a BaseJob) GetComplexFieldTypes() map[string]reflect.Type { +func (a BaseJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "settings": reflect.TypeOf(JobSettings{}), } @@ -204,7 +204,7 @@ func (newState *BaseRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseRun) { func (newState *BaseRun) SyncEffectiveFieldsDuringRead(existingState BaseRun) { } -func (a BaseRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a BaseRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_instance": reflect.TypeOf(ClusterInstance{}), "cluster_spec": reflect.TypeOf(ClusterSpec{}), @@ -297,7 +297,7 @@ func (newState *CancelAllRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan Canc func (newState *CancelAllRuns) SyncEffectiveFieldsDuringRead(existingState CancelAllRuns) { } -func (a CancelAllRuns) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelAllRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -319,7 +319,7 @@ func (newState *CancelAllRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CancelAllRunsResponse) SyncEffectiveFieldsDuringRead(existingState CancelAllRunsResponse) { } -func (a CancelAllRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelAllRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -340,7 +340,7 @@ func (newState *CancelRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan CancelRu func (newState *CancelRun) SyncEffectiveFieldsDuringRead(existingState CancelRun) { } -func (a CancelRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -361,7 +361,7 @@ func (newState *CancelRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CancelRunResponse) SyncEffectiveFieldsDuringRead(existingState CancelRunResponse) { } -func (a CancelRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -398,7 +398,7 @@ func (newState *ClusterInstance) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cl func (newState *ClusterInstance) SyncEffectiveFieldsDuringRead(existingState ClusterInstance) { } -func (a ClusterInstance) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterInstance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -434,7 +434,7 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState ClusterSpec) { } -func (a ClusterSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library": reflect.TypeOf(compute.Library{}), "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), @@ -482,7 +482,7 @@ func (newState *ConditionTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cond func (newState *ConditionTask) SyncEffectiveFieldsDuringRead(existingState ConditionTask) { } -func (a ConditionTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a ConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -508,7 +508,7 @@ func (newState *Continuous) SyncEffectiveFieldsDuringCreateOrUpdate(plan Continu func (newState *Continuous) SyncEffectiveFieldsDuringRead(existingState Continuous) { } -func (a Continuous) GetComplexFieldTypes() map[string]reflect.Type { +func (a Continuous) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -632,7 +632,7 @@ func (newState *CreateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateJo func (newState *CreateJob) SyncEffectiveFieldsDuringRead(existingState CreateJob) { } -func (a CreateJob) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), "continuous": reflect.TypeOf(Continuous{}), @@ -731,7 +731,7 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } -func (a CreateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -764,7 +764,7 @@ func (newState *CronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronS func (newState *CronSchedule) SyncEffectiveFieldsDuringRead(existingState CronSchedule) { } -func (a CronSchedule) GetComplexFieldTypes() map[string]reflect.Type { +func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -794,7 +794,7 @@ func (newState *DbtOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan DbtOutpu func (newState *DbtOutput) SyncEffectiveFieldsDuringRead(existingState DbtOutput) { } -func (a DbtOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a DbtOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "artifacts_headers": reflect.TypeOf(types.StringType), } @@ -854,7 +854,7 @@ func (newState *DbtTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan DbtTask) { func (newState *DbtTask) SyncEffectiveFieldsDuringRead(existingState DbtTask) { } -func (a DbtTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a DbtTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "commands": reflect.TypeOf(types.StringType), } @@ -887,7 +887,7 @@ func (newState *DeleteJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteJo func (newState *DeleteJob) SyncEffectiveFieldsDuringRead(existingState DeleteJob) { } -func (a DeleteJob) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -908,7 +908,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -929,7 +929,7 @@ func (newState *DeleteRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteRu func (newState *DeleteRun) SyncEffectiveFieldsDuringRead(existingState DeleteRun) { } -func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -950,7 +950,7 @@ func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunResponse) { } -func (a DeleteRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -984,7 +984,7 @@ func (newState *EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) S func (newState *EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) { } -func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1012,7 +1012,7 @@ func (newState *EnforcePolicyComplianceRequest) SyncEffectiveFieldsDuringCreateO func (newState *EnforcePolicyComplianceRequest) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceRequest) { } -func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1048,7 +1048,7 @@ func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringCreate func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceResponse) { } -func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "job_cluster_changes": reflect.TypeOf(EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}), "settings": reflect.TypeOf(JobSettings{}), @@ -1085,7 +1085,7 @@ func (newState *ExportRunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ex func (newState *ExportRunOutput) SyncEffectiveFieldsDuringRead(existingState ExportRunOutput) { } -func (a ExportRunOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExportRunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "views": reflect.TypeOf(ViewItem{}), } @@ -1115,7 +1115,7 @@ func (newState *ExportRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *ExportRunRequest) SyncEffectiveFieldsDuringRead(existingState ExportRunRequest) { } -func (a ExportRunRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExportRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1149,7 +1149,7 @@ func (newState *FileArrivalTriggerConfiguration) SyncEffectiveFieldsDuringCreate func (newState *FileArrivalTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState FileArrivalTriggerConfiguration) { } -func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1176,7 +1176,7 @@ func (newState *ForEachStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEa func (newState *ForEachStats) SyncEffectiveFieldsDuringRead(existingState ForEachStats) { } -func (a ForEachStats) GetComplexFieldTypes() map[string]reflect.Type { +func (a ForEachStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error_message_stats": reflect.TypeOf(ForEachTaskErrorMessageStats{}), "task_run_stats": reflect.TypeOf(ForEachTaskTaskRunStats{}), @@ -1214,7 +1214,7 @@ func (newState *ForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEac func (newState *ForEachTask) SyncEffectiveFieldsDuringRead(existingState ForEachTask) { } -func (a ForEachTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a ForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "task": reflect.TypeOf(Task{}), } @@ -1248,7 +1248,7 @@ func (newState *ForEachTaskErrorMessageStats) SyncEffectiveFieldsDuringCreateOrU func (newState *ForEachTaskErrorMessageStats) SyncEffectiveFieldsDuringRead(existingState ForEachTaskErrorMessageStats) { } -func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes() map[string]reflect.Type { +func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1284,7 +1284,7 @@ func (newState *ForEachTaskTaskRunStats) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ForEachTaskTaskRunStats) SyncEffectiveFieldsDuringRead(existingState ForEachTaskTaskRunStats) { } -func (a ForEachTaskTaskRunStats) GetComplexFieldTypes() map[string]reflect.Type { +func (a ForEachTaskTaskRunStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1313,7 +1313,7 @@ func (newState *GetJobPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetJobPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionLevelsRequest) { } -func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1336,7 +1336,7 @@ func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionLevelsResponse) { } -func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(JobPermissionsDescription{}), } @@ -1364,7 +1364,7 @@ func (newState *GetJobPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetJobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionsRequest) { } -func (a GetJobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetJobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1389,7 +1389,7 @@ func (newState *GetJobRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetJ func (newState *GetJobRequest) SyncEffectiveFieldsDuringRead(existingState GetJobRequest) { } -func (a GetJobRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetJobRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1413,7 +1413,7 @@ func (newState *GetPolicyComplianceRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetPolicyComplianceRequest) SyncEffectiveFieldsDuringRead(existingState GetPolicyComplianceRequest) { } -func (a GetPolicyComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1445,7 +1445,7 @@ func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringRead(existingState GetPolicyComplianceResponse) { } -func (a GetPolicyComplianceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.StringType), } @@ -1474,7 +1474,7 @@ func (newState *GetRunOutputRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetRunOutputRequest) SyncEffectiveFieldsDuringRead(existingState GetRunOutputRequest) { } -func (a GetRunOutputRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRunOutputRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1506,7 +1506,7 @@ func (newState *GetRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetR func (newState *GetRunRequest) SyncEffectiveFieldsDuringRead(existingState GetRunRequest) { } -func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1536,7 +1536,7 @@ func (newState *GitSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSna func (newState *GitSnapshot) SyncEffectiveFieldsDuringRead(existingState GitSnapshot) { } -func (a GitSnapshot) GetComplexFieldTypes() map[string]reflect.Type { +func (a GitSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1587,7 +1587,7 @@ func (newState *GitSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSourc func (newState *GitSource) SyncEffectiveFieldsDuringRead(existingState GitSource) { } -func (a GitSource) GetComplexFieldTypes() map[string]reflect.Type { +func (a GitSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "git_snapshot": reflect.TypeOf(GitSnapshot{}), "job_source": reflect.TypeOf(JobSource{}), @@ -1648,7 +1648,7 @@ func (newState *Job) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job) { func (newState *Job) SyncEffectiveFieldsDuringRead(existingState Job) { } -func (a Job) GetComplexFieldTypes() map[string]reflect.Type { +func (a Job) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "settings": reflect.TypeOf(JobSettings{}), } @@ -1686,7 +1686,7 @@ func (newState *JobAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *JobAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState JobAccessControlRequest) { } -func (a JobAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1720,7 +1720,7 @@ func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState JobAccessControlResponse) { } -func (a JobAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(JobPermission{}), } @@ -1755,7 +1755,7 @@ func (newState *JobCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobClus func (newState *JobCluster) SyncEffectiveFieldsDuringRead(existingState JobCluster) { } -func (a JobCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), } @@ -1791,7 +1791,7 @@ func (newState *JobCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobC func (newState *JobCompliance) SyncEffectiveFieldsDuringRead(existingState JobCompliance) { } -func (a JobCompliance) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobCompliance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.StringType), } @@ -1824,7 +1824,7 @@ func (newState *JobDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobD func (newState *JobDeployment) SyncEffectiveFieldsDuringRead(existingState JobDeployment) { } -func (a JobDeployment) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobDeployment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1879,7 +1879,7 @@ func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringRead(existingState JobEmailNotifications) { } -func (a JobEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.StringType), "on_failure": reflect.TypeOf(types.StringType), @@ -1927,7 +1927,7 @@ func (newState *JobEnvironment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobEnvironment) SyncEffectiveFieldsDuringRead(existingState JobEnvironment) { } -func (a JobEnvironment) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobEnvironment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "spec": reflect.TypeOf(compute.Environment{}), } @@ -1959,7 +1959,7 @@ func (newState *JobNotificationSettings) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *JobNotificationSettings) SyncEffectiveFieldsDuringRead(existingState JobNotificationSettings) { } -func (a JobNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1987,7 +1987,7 @@ func (newState *JobParameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobPa func (newState *JobParameter) SyncEffectiveFieldsDuringRead(existingState JobParameter) { } -func (a JobParameter) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobParameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2015,7 +2015,7 @@ func (newState *JobParameterDefinition) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *JobParameterDefinition) SyncEffectiveFieldsDuringRead(existingState JobParameterDefinition) { } -func (a JobParameterDefinition) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobParameterDefinition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2042,7 +2042,7 @@ func (newState *JobPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobP func (newState *JobPermission) SyncEffectiveFieldsDuringRead(existingState JobPermission) { } -func (a JobPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -2074,7 +2074,7 @@ func (newState *JobPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobPermissions) SyncEffectiveFieldsDuringRead(existingState JobPermissions) { } -func (a JobPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlResponse{}), } @@ -2104,7 +2104,7 @@ func (newState *JobPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpda func (newState *JobPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState JobPermissionsDescription) { } -func (a JobPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2129,7 +2129,7 @@ func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState JobPermissionsRequest) { } -func (a JobPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), } @@ -2167,7 +2167,7 @@ func (newState *JobRunAs) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobRunAs) func (newState *JobRunAs) SyncEffectiveFieldsDuringRead(existingState JobRunAs) { } -func (a JobRunAs) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobRunAs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2290,7 +2290,7 @@ func (newState *JobSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSet func (newState *JobSettings) SyncEffectiveFieldsDuringRead(existingState JobSettings) { } -func (a JobSettings) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "continuous": reflect.TypeOf(Continuous{}), "deployment": reflect.TypeOf(JobDeployment{}), @@ -2398,7 +2398,7 @@ func (newState *JobSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSourc func (newState *JobSource) SyncEffectiveFieldsDuringRead(existingState JobSource) { } -func (a JobSource) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2440,7 +2440,7 @@ func (newState *JobsHealthRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobsHealthRule) SyncEffectiveFieldsDuringRead(existingState JobsHealthRule) { } -func (a JobsHealthRule) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2465,7 +2465,7 @@ func (newState *JobsHealthRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan Jo func (newState *JobsHealthRules) SyncEffectiveFieldsDuringRead(existingState JobsHealthRules) { } -func (a JobsHealthRules) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobsHealthRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rules": reflect.TypeOf(JobsHealthRule{}), } @@ -2500,7 +2500,7 @@ func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringCre func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringRead(existingState ListJobComplianceForPolicyResponse) { } -func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "jobs": reflect.TypeOf(JobCompliance{}), } @@ -2537,7 +2537,7 @@ func (newState *ListJobComplianceRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListJobComplianceRequest) SyncEffectiveFieldsDuringRead(existingState ListJobComplianceRequest) { } -func (a ListJobComplianceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListJobComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2575,7 +2575,7 @@ func (newState *ListJobsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListJobsRequest) SyncEffectiveFieldsDuringRead(existingState ListJobsRequest) { } -func (a ListJobsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListJobsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2612,7 +2612,7 @@ func (newState *ListJobsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListJobsResponse) SyncEffectiveFieldsDuringRead(existingState ListJobsResponse) { } -func (a ListJobsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListJobsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "jobs": reflect.TypeOf(BaseJob{}), } @@ -2677,7 +2677,7 @@ func (newState *ListRunsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListRunsRequest) SyncEffectiveFieldsDuringRead(existingState ListRunsRequest) { } -func (a ListRunsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRunsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2719,7 +2719,7 @@ func (newState *ListRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListRunsResponse) SyncEffectiveFieldsDuringRead(existingState ListRunsResponse) { } -func (a ListRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "runs": reflect.TypeOf(BaseRun{}), } @@ -2756,7 +2756,7 @@ func (newState *NotebookOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Not func (newState *NotebookOutput) SyncEffectiveFieldsDuringRead(existingState NotebookOutput) { } -func (a NotebookOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a NotebookOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2816,7 +2816,7 @@ func (newState *NotebookTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Noteb func (newState *NotebookTask) SyncEffectiveFieldsDuringRead(existingState NotebookTask) { } -func (a NotebookTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a NotebookTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "base_parameters": reflect.TypeOf(types.StringType), } @@ -2848,7 +2848,7 @@ func (newState *PeriodicTriggerConfiguration) SyncEffectiveFieldsDuringCreateOrU func (newState *PeriodicTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState PeriodicTriggerConfiguration) { } -func (a PeriodicTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a PeriodicTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2872,7 +2872,7 @@ func (newState *PipelineParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pip func (newState *PipelineParams) SyncEffectiveFieldsDuringRead(existingState PipelineParams) { } -func (a PipelineParams) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2897,7 +2897,7 @@ func (newState *PipelineTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipel func (newState *PipelineTask) SyncEffectiveFieldsDuringRead(existingState PipelineTask) { } -func (a PipelineTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2932,7 +2932,7 @@ func (newState *PythonWheelTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Py func (newState *PythonWheelTask) SyncEffectiveFieldsDuringRead(existingState PythonWheelTask) { } -func (a PythonWheelTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "named_parameters": reflect.TypeOf(types.StringType), "parameters": reflect.TypeOf(types.StringType), @@ -2973,7 +2973,7 @@ func (newState *QueueDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Queue func (newState *QueueDetails) SyncEffectiveFieldsDuringRead(existingState QueueDetails) { } -func (a QueueDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueueDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2997,7 +2997,7 @@ func (newState *QueueSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan Queu func (newState *QueueSettings) SyncEffectiveFieldsDuringRead(existingState QueueSettings) { } -func (a QueueSettings) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueueSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3035,7 +3035,7 @@ func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringRead(existingState RepairHistoryItem) { } -func (a RepairHistoryItem) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "state": reflect.TypeOf(RunState{}), "status": reflect.TypeOf(RunStatus{}), @@ -3172,7 +3172,7 @@ func (newState *RepairRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepairRu func (newState *RepairRun) SyncEffectiveFieldsDuringRead(existingState RepairRun) { } -func (a RepairRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.StringType), "jar_params": reflect.TypeOf(types.StringType), @@ -3241,7 +3241,7 @@ func (newState *RepairRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RepairRunResponse) SyncEffectiveFieldsDuringRead(existingState RepairRunResponse) { } -func (a RepairRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepairRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3270,7 +3270,7 @@ func (newState *ResetJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResetJob) func (newState *ResetJob) SyncEffectiveFieldsDuringRead(existingState ResetJob) { } -func (a ResetJob) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResetJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "new_settings": reflect.TypeOf(JobSettings{}), } @@ -3296,7 +3296,7 @@ func (newState *ResetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rese func (newState *ResetResponse) SyncEffectiveFieldsDuringRead(existingState ResetResponse) { } -func (a ResetResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3318,7 +3318,7 @@ func (newState *ResolvedConditionTaskValues) SyncEffectiveFieldsDuringCreateOrUp func (newState *ResolvedConditionTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedConditionTaskValues) { } -func (a ResolvedConditionTaskValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedConditionTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3341,7 +3341,7 @@ func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedDbtTaskValues) { } -func (a ResolvedDbtTaskValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedDbtTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "commands": reflect.TypeOf(types.StringType), } @@ -3367,7 +3367,7 @@ func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedNotebookTaskValues) { } -func (a ResolvedNotebookTaskValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "base_parameters": reflect.TypeOf(types.StringType), } @@ -3393,7 +3393,7 @@ func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringRead(existingState ResolvedParamPairValues) { } -func (a ResolvedParamPairValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedParamPairValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -3421,7 +3421,7 @@ func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringCreateOr func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedPythonWheelTaskValues) { } -func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "named_parameters": reflect.TypeOf(types.StringType), "parameters": reflect.TypeOf(types.StringType), @@ -3453,7 +3453,7 @@ func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedRunJobTaskValues) { } -func (a ResolvedRunJobTaskValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "job_parameters": reflect.TypeOf(types.StringType), "parameters": reflect.TypeOf(types.StringType), @@ -3483,7 +3483,7 @@ func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringRead(existingState ResolvedStringParamsValues) { } -func (a ResolvedStringParamsValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedStringParamsValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -3527,7 +3527,7 @@ func (newState *ResolvedValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResolvedValues) SyncEffectiveFieldsDuringRead(existingState ResolvedValues) { } -func (a ResolvedValues) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResolvedValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition_task": reflect.TypeOf(ResolvedConditionTaskValues{}), "dbt_task": reflect.TypeOf(ResolvedDbtTaskValues{}), @@ -3721,7 +3721,7 @@ func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { } -func (a Run) GetComplexFieldTypes() map[string]reflect.Type { +func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_instance": reflect.TypeOf(ClusterInstance{}), "cluster_spec": reflect.TypeOf(ClusterSpec{}), @@ -3834,7 +3834,7 @@ func (newState *RunConditionTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RunConditionTask) SyncEffectiveFieldsDuringRead(existingState RunConditionTask) { } -func (a RunConditionTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3870,7 +3870,7 @@ func (newState *RunForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run func (newState *RunForEachTask) SyncEffectiveFieldsDuringRead(existingState RunForEachTask) { } -func (a RunForEachTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "stats": reflect.TypeOf(ForEachStats{}), "task": reflect.TypeOf(Task{}), @@ -3903,7 +3903,7 @@ func (newState *RunJobOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJo func (newState *RunJobOutput) SyncEffectiveFieldsDuringRead(existingState RunJobOutput) { } -func (a RunJobOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunJobOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4010,7 +4010,7 @@ func (newState *RunJobTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJobT func (newState *RunJobTask) SyncEffectiveFieldsDuringRead(existingState RunJobTask) { } -func (a RunJobTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.StringType), "jar_params": reflect.TypeOf(types.StringType), @@ -4175,7 +4175,7 @@ func (newState *RunNow) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunNow) { func (newState *RunNow) SyncEffectiveFieldsDuringRead(existingState RunNow) { } -func (a RunNow) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.StringType), "jar_params": reflect.TypeOf(types.StringType), @@ -4248,7 +4248,7 @@ func (newState *RunNowResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run func (newState *RunNowResponse) SyncEffectiveFieldsDuringRead(existingState RunNowResponse) { } -func (a RunNowResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunNowResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4307,7 +4307,7 @@ func (newState *RunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunOutpu func (newState *RunOutput) SyncEffectiveFieldsDuringRead(existingState RunOutput) { } -func (a RunOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_output": reflect.TypeOf(DbtOutput{}), "metadata": reflect.TypeOf(Run{}), @@ -4435,7 +4435,7 @@ func (newState *RunParameters) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunP func (newState *RunParameters) SyncEffectiveFieldsDuringRead(existingState RunParameters) { } -func (a RunParameters) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.StringType), "jar_params": reflect.TypeOf(types.StringType), @@ -4503,7 +4503,7 @@ func (newState *RunState) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunState) func (newState *RunState) SyncEffectiveFieldsDuringRead(existingState RunState) { } -func (a RunState) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4536,7 +4536,7 @@ func (newState *RunStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunStatu func (newState *RunStatus) SyncEffectiveFieldsDuringRead(existingState RunStatus) { } -func (a RunStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "queue_details": reflect.TypeOf(QueueDetails{}), "termination_details": reflect.TypeOf(TerminationDetails{}), @@ -4731,7 +4731,7 @@ func (newState *RunTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTask) { func (newState *RunTask) SyncEffectiveFieldsDuringRead(existingState RunTask) { } -func (a RunTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_instance": reflect.TypeOf(ClusterInstance{}), "condition_task": reflect.TypeOf(RunConditionTask{}), @@ -4873,7 +4873,7 @@ func (newState *SparkJarTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spark func (newState *SparkJarTask) SyncEffectiveFieldsDuringRead(existingState SparkJarTask) { } -func (a SparkJarTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparkJarTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -4923,7 +4923,7 @@ func (newState *SparkPythonTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sp func (newState *SparkPythonTask) SyncEffectiveFieldsDuringRead(existingState SparkPythonTask) { } -func (a SparkPythonTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparkPythonTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -4957,7 +4957,7 @@ func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sp func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringRead(existingState SparkSubmitTask) { } -func (a SparkSubmitTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparkSubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -4997,7 +4997,7 @@ func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringRead(existingState SqlAlertOutput) { } -func (a SqlAlertOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlAlertOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sql_statements": reflect.TypeOf(SqlStatementOutput{}), } @@ -5030,7 +5030,7 @@ func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringRead(existingState SqlDashboardOutput) { } -func (a SqlDashboardOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlDashboardOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "widgets": reflect.TypeOf(SqlDashboardWidgetOutput{}), } @@ -5070,7 +5070,7 @@ func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringRead(existingState SqlDashboardWidgetOutput) { } -func (a SqlDashboardWidgetOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlDashboardWidgetOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error": reflect.TypeOf(SqlOutputError{}), } @@ -5107,7 +5107,7 @@ func (newState *SqlOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlOutpu func (newState *SqlOutput) SyncEffectiveFieldsDuringRead(existingState SqlOutput) { } -func (a SqlOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_output": reflect.TypeOf(SqlAlertOutput{}), "dashboard_output": reflect.TypeOf(SqlDashboardOutput{}), @@ -5142,7 +5142,7 @@ func (newState *SqlOutputError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlOutputError) SyncEffectiveFieldsDuringRead(existingState SqlOutputError) { } -func (a SqlOutputError) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlOutputError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5173,7 +5173,7 @@ func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringRead(existingState SqlQueryOutput) { } -func (a SqlQueryOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlQueryOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sql_statements": reflect.TypeOf(SqlStatementOutput{}), } @@ -5204,7 +5204,7 @@ func (newState *SqlStatementOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SqlStatementOutput) SyncEffectiveFieldsDuringRead(existingState SqlStatementOutput) { } -func (a SqlStatementOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlStatementOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5242,7 +5242,7 @@ func (newState *SqlTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTask) { func (newState *SqlTask) SyncEffectiveFieldsDuringRead(existingState SqlTask) { } -func (a SqlTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert": reflect.TypeOf(SqlTaskAlert{}), "dashboard": reflect.TypeOf(SqlTaskDashboard{}), @@ -5290,7 +5290,7 @@ func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTa func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringRead(existingState SqlTaskAlert) { } -func (a SqlTaskAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlTaskAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), } @@ -5326,7 +5326,7 @@ func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringRead(existingState SqlTaskDashboard) { } -func (a SqlTaskDashboard) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlTaskDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), } @@ -5366,7 +5366,7 @@ func (newState *SqlTaskFile) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTas func (newState *SqlTaskFile) SyncEffectiveFieldsDuringRead(existingState SqlTaskFile) { } -func (a SqlTaskFile) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlTaskFile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5390,7 +5390,7 @@ func (newState *SqlTaskQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTa func (newState *SqlTaskQuery) SyncEffectiveFieldsDuringRead(existingState SqlTaskQuery) { } -func (a SqlTaskQuery) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlTaskQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5420,7 +5420,7 @@ func (newState *SqlTaskSubscription) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SqlTaskSubscription) SyncEffectiveFieldsDuringRead(existingState SqlTaskSubscription) { } -func (a SqlTaskSubscription) GetComplexFieldTypes() map[string]reflect.Type { +func (a SqlTaskSubscription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5501,7 +5501,7 @@ func (newState *SubmitRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitRu func (newState *SubmitRun) SyncEffectiveFieldsDuringRead(existingState SubmitRun) { } -func (a SubmitRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a SubmitRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), "email_notifications": reflect.TypeOf(JobEmailNotifications{}), @@ -5569,7 +5569,7 @@ func (newState *SubmitRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SubmitRunResponse) SyncEffectiveFieldsDuringRead(existingState SubmitRunResponse) { } -func (a SubmitRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SubmitRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5687,7 +5687,7 @@ func (newState *SubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitT func (newState *SubmitTask) SyncEffectiveFieldsDuringRead(existingState SubmitTask) { } -func (a SubmitTask) GetComplexFieldTypes() map[string]reflect.Type { +func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition_task": reflect.TypeOf(ConditionTask{}), "dbt_task": reflect.TypeOf(DbtTask{}), @@ -5800,7 +5800,7 @@ func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringCreate func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState TableUpdateTriggerConfiguration) { } -func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_names": reflect.TypeOf(types.StringType), } @@ -5948,7 +5948,7 @@ func (newState *Task) SyncEffectiveFieldsDuringCreateOrUpdate(plan Task) { func (newState *Task) SyncEffectiveFieldsDuringRead(existingState Task) { } -func (a Task) GetComplexFieldTypes() map[string]reflect.Type { +func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition_task": reflect.TypeOf(ConditionTask{}), "dbt_task": reflect.TypeOf(DbtTask{}), @@ -6057,7 +6057,7 @@ func (newState *TaskDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tas func (newState *TaskDependency) SyncEffectiveFieldsDuringRead(existingState TaskDependency) { } -func (a TaskDependency) GetComplexFieldTypes() map[string]reflect.Type { +func (a TaskDependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6112,7 +6112,7 @@ func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringRead(existingState TaskEmailNotifications) { } -func (a TaskEmailNotifications) GetComplexFieldTypes() map[string]reflect.Type { +func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.StringType), "on_failure": reflect.TypeOf(types.StringType), @@ -6164,7 +6164,7 @@ func (newState *TaskNotificationSettings) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *TaskNotificationSettings) SyncEffectiveFieldsDuringRead(existingState TaskNotificationSettings) { } -func (a TaskNotificationSettings) GetComplexFieldTypes() map[string]reflect.Type { +func (a TaskNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6245,7 +6245,7 @@ func (newState *TerminationDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationDetails) SyncEffectiveFieldsDuringRead(existingState TerminationDetails) { } -func (a TerminationDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a TerminationDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6271,7 +6271,7 @@ func (newState *TriggerInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Trigge func (newState *TriggerInfo) SyncEffectiveFieldsDuringRead(existingState TriggerInfo) { } -func (a TriggerInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a TriggerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6302,7 +6302,7 @@ func (newState *TriggerSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tr func (newState *TriggerSettings) SyncEffectiveFieldsDuringRead(existingState TriggerSettings) { } -func (a TriggerSettings) GetComplexFieldTypes() map[string]reflect.Type { +func (a TriggerSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_arrival": reflect.TypeOf(FileArrivalTriggerConfiguration{}), "periodic": reflect.TypeOf(PeriodicTriggerConfiguration{}), @@ -6358,7 +6358,7 @@ func (newState *UpdateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateJo func (newState *UpdateJob) SyncEffectiveFieldsDuringRead(existingState UpdateJob) { } -func (a UpdateJob) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fields_to_remove": reflect.TypeOf(types.StringType), "new_settings": reflect.TypeOf(JobSettings{}), @@ -6388,7 +6388,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6415,7 +6415,7 @@ func (newState *ViewItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan ViewItem) func (newState *ViewItem) SyncEffectiveFieldsDuringRead(existingState ViewItem) { } -func (a ViewItem) GetComplexFieldTypes() map[string]reflect.Type { +func (a ViewItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6439,7 +6439,7 @@ func (newState *Webhook) SyncEffectiveFieldsDuringCreateOrUpdate(plan Webhook) { func (newState *Webhook) SyncEffectiveFieldsDuringRead(existingState Webhook) { } -func (a Webhook) GetComplexFieldTypes() map[string]reflect.Type { +func (a Webhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -6484,7 +6484,7 @@ func (newState *WebhookNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WebhookNotifications) SyncEffectiveFieldsDuringRead(existingState WebhookNotifications) { } -func (a WebhookNotifications) GetComplexFieldTypes() map[string]reflect.Type { +func (a WebhookNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_duration_warning_threshold_exceeded": reflect.TypeOf(Webhook{}), "on_failure": reflect.TypeOf(Webhook{}), diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index bb6e21f8a3..abc910c905 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -31,7 +31,7 @@ func (newState *AddExchangeForListingRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *AddExchangeForListingRequest) SyncEffectiveFieldsDuringRead(existingState AddExchangeForListingRequest) { } -func (a AddExchangeForListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a AddExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -54,7 +54,7 @@ func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringCreateOr func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringRead(existingState AddExchangeForListingResponse) { } -func (a AddExchangeForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a AddExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange_for_listing": reflect.TypeOf(ExchangeListing{}), } @@ -81,7 +81,7 @@ func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringRead(existingState BatchGetListingsRequest) { } -func (a BatchGetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a BatchGetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ids": reflect.TypeOf(types.StringType), } @@ -107,7 +107,7 @@ func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringRead(existingState BatchGetListingsResponse) { } -func (a BatchGetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a BatchGetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } @@ -134,7 +134,7 @@ func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringRead(existingState BatchGetProvidersRequest) { } -func (a BatchGetProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a BatchGetProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ids": reflect.TypeOf(types.StringType), } @@ -160,7 +160,7 @@ func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringRead(existingState BatchGetProvidersResponse) { } -func (a BatchGetProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a BatchGetProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "providers": reflect.TypeOf(ProviderInfo{}), } @@ -186,7 +186,7 @@ func (newState *ConsumerTerms) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cons func (newState *ConsumerTerms) SyncEffectiveFieldsDuringRead(existingState ConsumerTerms) { } -func (a ConsumerTerms) GetComplexFieldTypes() map[string]reflect.Type { +func (a ConsumerTerms) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -216,7 +216,7 @@ func (newState *ContactInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Contac func (newState *ContactInfo) SyncEffectiveFieldsDuringRead(existingState ContactInfo) { } -func (a ContactInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ContactInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -241,7 +241,7 @@ func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState CreateExchangeFilterRequest) { } -func (a CreateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter": reflect.TypeOf(ExchangeFilter{}), } @@ -267,7 +267,7 @@ func (newState *CreateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *CreateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState CreateExchangeFilterResponse) { } -func (a CreateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -289,7 +289,7 @@ func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringRead(existingState CreateExchangeRequest) { } -func (a CreateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } @@ -315,7 +315,7 @@ func (newState *CreateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateExchangeResponse) SyncEffectiveFieldsDuringRead(existingState CreateExchangeResponse) { } -func (a CreateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -343,7 +343,7 @@ func (newState *CreateFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateFileRequest) SyncEffectiveFieldsDuringRead(existingState CreateFileRequest) { } -func (a CreateFileRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_parent": reflect.TypeOf(FileParent{}), } @@ -374,7 +374,7 @@ func (newState *CreateFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateFileResponse) SyncEffectiveFieldsDuringRead(existingState CreateFileResponse) { } -func (a CreateFileResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_info": reflect.TypeOf(FileInfo{}), } @@ -411,7 +411,7 @@ func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringRead(existingState CreateInstallationRequest) { } -func (a CreateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "accepted_consumer_terms": reflect.TypeOf(ConsumerTerms{}), "repo_detail": reflect.TypeOf(RepoInstallation{}), @@ -445,7 +445,7 @@ func (newState *CreateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreateListingRequest) SyncEffectiveFieldsDuringRead(existingState CreateListingRequest) { } -func (a CreateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } @@ -471,7 +471,7 @@ func (newState *CreateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateListingResponse) SyncEffectiveFieldsDuringRead(existingState CreateListingResponse) { } -func (a CreateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -510,7 +510,7 @@ func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringRead(existingState CreatePersonalizationRequest) { } -func (a CreatePersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "accepted_consumer_terms": reflect.TypeOf(ConsumerTerms{}), } @@ -544,7 +544,7 @@ func (newState *CreatePersonalizationRequestResponse) SyncEffectiveFieldsDuringC func (newState *CreatePersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState CreatePersonalizationRequestResponse) { } -func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -566,7 +566,7 @@ func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringRead(existingState CreateProviderRequest) { } -func (a CreateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } @@ -592,7 +592,7 @@ func (newState *CreateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateProviderResponse) SyncEffectiveFieldsDuringRead(existingState CreateProviderResponse) { } -func (a CreateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -616,7 +616,7 @@ func (newState *DataRefreshInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Da func (newState *DataRefreshInfo) SyncEffectiveFieldsDuringRead(existingState DataRefreshInfo) { } -func (a DataRefreshInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a DataRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -640,7 +640,7 @@ func (newState *DeleteExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *DeleteExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeFilterRequest) { } -func (a DeleteExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -661,7 +661,7 @@ func (newState *DeleteExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeFilterResponse) { } -func (a DeleteExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -682,7 +682,7 @@ func (newState *DeleteExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteExchangeRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeRequest) { } -func (a DeleteExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -703,7 +703,7 @@ func (newState *DeleteExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteExchangeResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeResponse) { } -func (a DeleteExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -724,7 +724,7 @@ func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFileRequest) { } -func (a DeleteFileRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -745,7 +745,7 @@ func (newState *DeleteFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileResponse) SyncEffectiveFieldsDuringRead(existingState DeleteFileResponse) { } -func (a DeleteFileResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -768,7 +768,7 @@ func (newState *DeleteInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteInstallationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteInstallationRequest) { } -func (a DeleteInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteInstallationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -790,7 +790,7 @@ func (newState *DeleteInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteInstallationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteInstallationResponse) { } -func (a DeleteInstallationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteInstallationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -811,7 +811,7 @@ func (newState *DeleteListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteListingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteListingRequest) { } -func (a DeleteListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -832,7 +832,7 @@ func (newState *DeleteListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteListingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteListingResponse) { } -func (a DeleteListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -853,7 +853,7 @@ func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringRead(existingState DeleteProviderRequest) { } -func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -874,7 +874,7 @@ func (newState *DeleteProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteProviderResponse) SyncEffectiveFieldsDuringRead(existingState DeleteProviderResponse) { } -func (a DeleteProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -910,7 +910,7 @@ func (newState *Exchange) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exchange) func (newState *Exchange) SyncEffectiveFieldsDuringRead(existingState Exchange) { } -func (a Exchange) GetComplexFieldTypes() map[string]reflect.Type { +func (a Exchange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filters": reflect.TypeOf(ExchangeFilter{}), "linked_listings": reflect.TypeOf(ExchangeListing{}), @@ -963,7 +963,7 @@ func (newState *ExchangeFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exc func (newState *ExchangeFilter) SyncEffectiveFieldsDuringRead(existingState ExchangeFilter) { } -func (a ExchangeFilter) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExchangeFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1005,7 +1005,7 @@ func (newState *ExchangeListing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ex func (newState *ExchangeListing) SyncEffectiveFieldsDuringRead(existingState ExchangeListing) { } -func (a ExchangeListing) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExchangeListing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1052,7 +1052,7 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } -func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_parent": reflect.TypeOf(FileParent{}), } @@ -1089,7 +1089,7 @@ func (newState *FileParent) SyncEffectiveFieldsDuringCreateOrUpdate(plan FilePar func (newState *FileParent) SyncEffectiveFieldsDuringRead(existingState FileParent) { } -func (a FileParent) GetComplexFieldTypes() map[string]reflect.Type { +func (a FileParent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1113,7 +1113,7 @@ func (newState *GetExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetExchangeRequest) SyncEffectiveFieldsDuringRead(existingState GetExchangeRequest) { } -func (a GetExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1135,7 +1135,7 @@ func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringRead(existingState GetExchangeResponse) { } -func (a GetExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } @@ -1162,7 +1162,7 @@ func (newState *GetFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetFileRequest) SyncEffectiveFieldsDuringRead(existingState GetFileRequest) { } -func (a GetFileRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1184,7 +1184,7 @@ func (newState *GetFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetFileResponse) SyncEffectiveFieldsDuringRead(existingState GetFileResponse) { } -func (a GetFileResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_info": reflect.TypeOf(FileInfo{}), } @@ -1211,7 +1211,7 @@ func (newState *GetLatestVersionProviderAnalyticsDashboardResponse) SyncEffectiv func (newState *GetLatestVersionProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionProviderAnalyticsDashboardResponse) { } -func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1238,7 +1238,7 @@ func (newState *GetListingContentMetadataRequest) SyncEffectiveFieldsDuringCreat func (newState *GetListingContentMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetListingContentMetadataRequest) { } -func (a GetListingContentMetadataRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetListingContentMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1264,7 +1264,7 @@ func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringCrea func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetListingContentMetadataResponse) { } -func (a GetListingContentMetadataResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetListingContentMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "shared_data_objects": reflect.TypeOf(SharedDataObject{}), } @@ -1292,7 +1292,7 @@ func (newState *GetListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingRequest) SyncEffectiveFieldsDuringRead(existingState GetListingRequest) { } -func (a GetListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1314,7 +1314,7 @@ func (newState *GetListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingResponse) SyncEffectiveFieldsDuringRead(existingState GetListingResponse) { } -func (a GetListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } @@ -1343,7 +1343,7 @@ func (newState *GetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingsRequest) SyncEffectiveFieldsDuringRead(existingState GetListingsRequest) { } -func (a GetListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1368,7 +1368,7 @@ func (newState *GetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetListingsResponse) SyncEffectiveFieldsDuringRead(existingState GetListingsResponse) { } -func (a GetListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } @@ -1396,7 +1396,7 @@ func (newState *GetPersonalizationRequestRequest) SyncEffectiveFieldsDuringCreat func (newState *GetPersonalizationRequestRequest) SyncEffectiveFieldsDuringRead(existingState GetPersonalizationRequestRequest) { } -func (a GetPersonalizationRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1418,7 +1418,7 @@ func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringCrea func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState GetPersonalizationRequestResponse) { } -func (a GetPersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "personalization_requests": reflect.TypeOf(PersonalizationRequest{}), } @@ -1445,7 +1445,7 @@ func (newState *GetProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetProviderRequest) SyncEffectiveFieldsDuringRead(existingState GetProviderRequest) { } -func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1467,7 +1467,7 @@ func (newState *GetProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetProviderResponse) SyncEffectiveFieldsDuringRead(existingState GetProviderResponse) { } -func (a GetProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } @@ -1493,7 +1493,7 @@ func (newState *Installation) SyncEffectiveFieldsDuringCreateOrUpdate(plan Insta func (newState *Installation) SyncEffectiveFieldsDuringRead(existingState Installation) { } -func (a Installation) GetComplexFieldTypes() map[string]reflect.Type { +func (a Installation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installation": reflect.TypeOf(InstallationDetail{}), } @@ -1543,7 +1543,7 @@ func (newState *InstallationDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstallationDetail) SyncEffectiveFieldsDuringRead(existingState InstallationDetail) { } -func (a InstallationDetail) GetComplexFieldTypes() map[string]reflect.Type { +func (a InstallationDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_detail": reflect.TypeOf(TokenDetail{}), "tokens": reflect.TypeOf(TokenInfo{}), @@ -1587,7 +1587,7 @@ func (newState *ListAllInstallationsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListAllInstallationsRequest) SyncEffectiveFieldsDuringRead(existingState ListAllInstallationsRequest) { } -func (a ListAllInstallationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAllInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1612,7 +1612,7 @@ func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringRead(existingState ListAllInstallationsResponse) { } -func (a ListAllInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAllInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installations": reflect.TypeOf(InstallationDetail{}), } @@ -1642,7 +1642,7 @@ func (newState *ListAllPersonalizationRequestsRequest) SyncEffectiveFieldsDuring func (newState *ListAllPersonalizationRequestsRequest) SyncEffectiveFieldsDuringRead(existingState ListAllPersonalizationRequestsRequest) { } -func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1667,7 +1667,7 @@ func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDurin func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDuringRead(existingState ListAllPersonalizationRequestsResponse) { } -func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "personalization_requests": reflect.TypeOf(PersonalizationRequest{}), } @@ -1699,7 +1699,7 @@ func (newState *ListExchangeFiltersRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListExchangeFiltersRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangeFiltersRequest) { } -func (a ListExchangeFiltersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExchangeFiltersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1725,7 +1725,7 @@ func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangeFiltersResponse) { } -func (a ListExchangeFiltersResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExchangeFiltersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filters": reflect.TypeOf(ExchangeFilter{}), } @@ -1757,7 +1757,7 @@ func (newState *ListExchangesForListingRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListExchangesForListingRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangesForListingRequest) { } -func (a ListExchangesForListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExchangesForListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1783,7 +1783,7 @@ func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringCreate func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangesForListingResponse) { } -func (a ListExchangesForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExchangesForListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange_listing": reflect.TypeOf(ExchangeListing{}), } @@ -1813,7 +1813,7 @@ func (newState *ListExchangesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListExchangesRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangesRequest) { } -func (a ListExchangesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExchangesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1838,7 +1838,7 @@ func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangesResponse) { } -func (a ListExchangesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExchangesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchanges": reflect.TypeOf(Exchange{}), } @@ -1870,7 +1870,7 @@ func (newState *ListFilesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListFilesRequest) SyncEffectiveFieldsDuringRead(existingState ListFilesRequest) { } -func (a ListFilesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListFilesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_parent": reflect.TypeOf(FileParent{}), } @@ -1900,7 +1900,7 @@ func (newState *ListFilesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListFilesResponse) SyncEffectiveFieldsDuringRead(existingState ListFilesResponse) { } -func (a ListFilesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListFilesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_infos": reflect.TypeOf(FileInfo{}), } @@ -1932,7 +1932,7 @@ func (newState *ListFulfillmentsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListFulfillmentsRequest) SyncEffectiveFieldsDuringRead(existingState ListFulfillmentsRequest) { } -func (a ListFulfillmentsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListFulfillmentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1958,7 +1958,7 @@ func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringRead(existingState ListFulfillmentsResponse) { } -func (a ListFulfillmentsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListFulfillmentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fulfillments": reflect.TypeOf(ListingFulfillment{}), } @@ -1990,7 +1990,7 @@ func (newState *ListInstallationsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListInstallationsRequest) SyncEffectiveFieldsDuringRead(existingState ListInstallationsRequest) { } -func (a ListInstallationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2016,7 +2016,7 @@ func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringRead(existingState ListInstallationsResponse) { } -func (a ListInstallationsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installations": reflect.TypeOf(InstallationDetail{}), } @@ -2048,7 +2048,7 @@ func (newState *ListListingsForExchangeRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListListingsForExchangeRequest) SyncEffectiveFieldsDuringRead(existingState ListListingsForExchangeRequest) { } -func (a ListListingsForExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListListingsForExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2074,7 +2074,7 @@ func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringCreate func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringRead(existingState ListListingsForExchangeResponse) { } -func (a ListListingsForExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListListingsForExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange_listings": reflect.TypeOf(ExchangeListing{}), } @@ -2119,7 +2119,7 @@ func (newState *ListListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListListingsRequest) SyncEffectiveFieldsDuringRead(existingState ListListingsRequest) { } -func (a ListListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assets": reflect.TypeOf(types.StringType), "categories": reflect.TypeOf(types.StringType), @@ -2164,7 +2164,7 @@ func (newState *ListListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListListingsResponse) SyncEffectiveFieldsDuringRead(existingState ListListingsResponse) { } -func (a ListListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } @@ -2196,7 +2196,7 @@ func (newState *ListProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDurin func (newState *ListProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState ListProviderAnalyticsDashboardResponse) { } -func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2225,7 +2225,7 @@ func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringRead(existingState ListProvidersRequest) { } -func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2251,7 +2251,7 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingState ListProvidersResponse) { } -func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "providers": reflect.TypeOf(ProviderInfo{}), } @@ -2282,7 +2282,7 @@ func (newState *Listing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing) { func (newState *Listing) SyncEffectiveFieldsDuringRead(existingState Listing) { } -func (a Listing) GetComplexFieldTypes() map[string]reflect.Type { +func (a Listing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "detail": reflect.TypeOf(ListingDetail{}), "summary": reflect.TypeOf(ListingSummary{}), @@ -2360,7 +2360,7 @@ func (newState *ListingDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan List func (newState *ListingDetail) SyncEffectiveFieldsDuringRead(existingState ListingDetail) { } -func (a ListingDetail) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assets": reflect.TypeOf(types.StringType), "collection_granularity": reflect.TypeOf(DataRefreshInfo{}), @@ -2427,7 +2427,7 @@ func (newState *ListingFulfillment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListingFulfillment) SyncEffectiveFieldsDuringRead(existingState ListingFulfillment) { } -func (a ListingFulfillment) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListingFulfillment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "repo_info": reflect.TypeOf(RepoInfo{}), "share_info": reflect.TypeOf(ShareInfo{}), @@ -2460,7 +2460,7 @@ func (newState *ListingSetting) SyncEffectiveFieldsDuringCreateOrUpdate(plan Lis func (newState *ListingSetting) SyncEffectiveFieldsDuringRead(existingState ListingSetting) { } -func (a ListingSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListingSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2520,7 +2520,7 @@ func (newState *ListingSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Lis func (newState *ListingSummary) SyncEffectiveFieldsDuringRead(existingState ListingSummary) { } -func (a ListingSummary) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "categories": reflect.TypeOf(types.StringType), "exchange_ids": reflect.TypeOf(types.StringType), @@ -2583,7 +2583,7 @@ func (newState *ListingTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing func (newState *ListingTag) SyncEffectiveFieldsDuringRead(existingState ListingTag) { } -func (a ListingTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListingTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tag_values": reflect.TypeOf(types.StringType), } @@ -2641,7 +2641,7 @@ func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringRead(existingState PersonalizationRequest) { } -func (a PersonalizationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "consumer_region": reflect.TypeOf(RegionInfo{}), "contact_info": reflect.TypeOf(ContactInfo{}), @@ -2688,7 +2688,7 @@ func (newState *ProviderAnalyticsDashboard) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ProviderAnalyticsDashboard) SyncEffectiveFieldsDuringRead(existingState ProviderAnalyticsDashboard) { } -func (a ProviderAnalyticsDashboard) GetComplexFieldTypes() map[string]reflect.Type { +func (a ProviderAnalyticsDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2736,7 +2736,7 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Provi func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState ProviderInfo) { } -func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2773,7 +2773,7 @@ func (newState *RegionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RegionI func (newState *RegionInfo) SyncEffectiveFieldsDuringRead(existingState RegionInfo) { } -func (a RegionInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2797,7 +2797,7 @@ func (newState *RemoveExchangeForListingRequest) SyncEffectiveFieldsDuringCreate func (newState *RemoveExchangeForListingRequest) SyncEffectiveFieldsDuringRead(existingState RemoveExchangeForListingRequest) { } -func (a RemoveExchangeForListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RemoveExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2818,7 +2818,7 @@ func (newState *RemoveExchangeForListingResponse) SyncEffectiveFieldsDuringCreat func (newState *RemoveExchangeForListingResponse) SyncEffectiveFieldsDuringRead(existingState RemoveExchangeForListingResponse) { } -func (a RemoveExchangeForListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RemoveExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2839,7 +2839,7 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoInfo) func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) { } -func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2866,7 +2866,7 @@ func (newState *RepoInstallation) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RepoInstallation) SyncEffectiveFieldsDuringRead(existingState RepoInstallation) { } -func (a RepoInstallation) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoInstallation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2905,7 +2905,7 @@ func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringRead(existingState SearchListingsRequest) { } -func (a SearchListingsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assets": reflect.TypeOf(types.StringType), "categories": reflect.TypeOf(types.StringType), @@ -2946,7 +2946,7 @@ func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringRead(existingState SearchListingsResponse) { } -func (a SearchListingsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } @@ -2975,7 +2975,7 @@ func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInf func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo) { } -func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3002,7 +3002,7 @@ func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { } -func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { +func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3033,7 +3033,7 @@ func (newState *TokenDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenD func (newState *TokenDetail) SyncEffectiveFieldsDuringRead(existingState TokenDetail) { } -func (a TokenDetail) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3072,7 +3072,7 @@ func (newState *TokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenInf func (newState *TokenInfo) SyncEffectiveFieldsDuringRead(existingState TokenInfo) { } -func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3102,7 +3102,7 @@ func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeFilterRequest) { } -func (a UpdateExchangeFilterRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter": reflect.TypeOf(ExchangeFilter{}), } @@ -3129,7 +3129,7 @@ func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeFilterResponse) { } -func (a UpdateExchangeFilterResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter": reflect.TypeOf(ExchangeFilter{}), } @@ -3157,7 +3157,7 @@ func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeRequest) { } -func (a UpdateExchangeRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } @@ -3184,7 +3184,7 @@ func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeResponse) { } -func (a UpdateExchangeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } @@ -3216,7 +3216,7 @@ func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateInstallationRequest) { } -func (a UpdateInstallationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installation": reflect.TypeOf(InstallationDetail{}), } @@ -3245,7 +3245,7 @@ func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringRead(existingState UpdateInstallationResponse) { } -func (a UpdateInstallationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateInstallationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installation": reflect.TypeOf(InstallationDetail{}), } @@ -3273,7 +3273,7 @@ func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateListingRequest) { } -func (a UpdateListingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } @@ -3300,7 +3300,7 @@ func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringRead(existingState UpdateListingResponse) { } -func (a UpdateListingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } @@ -3334,7 +3334,7 @@ func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringCr func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalizationRequestRequest) { } -func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "share": reflect.TypeOf(ShareInfo{}), } @@ -3364,7 +3364,7 @@ func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringC func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalizationRequestResponse) { } -func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "request": reflect.TypeOf(PersonalizationRequest{}), } @@ -3395,7 +3395,7 @@ func (newState *UpdateProviderAnalyticsDashboardRequest) SyncEffectiveFieldsDuri func (newState *UpdateProviderAnalyticsDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UpdateProviderAnalyticsDashboardRequest) { } -func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3423,7 +3423,7 @@ func (newState *UpdateProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDur func (newState *UpdateProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState UpdateProviderAnalyticsDashboardResponse) { } -func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3449,7 +3449,7 @@ func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringRead(existingState UpdateProviderRequest) { } -func (a UpdateProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } @@ -3476,7 +3476,7 @@ func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringRead(existingState UpdateProviderResponse) { } -func (a UpdateProviderResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index d86f9cf06f..79778e86e1 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -81,7 +81,7 @@ func (newState *Activity) SyncEffectiveFieldsDuringCreateOrUpdate(plan Activity) func (newState *Activity) SyncEffectiveFieldsDuringRead(existingState Activity) { } -func (a Activity) GetComplexFieldTypes() map[string]reflect.Type { +func (a Activity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -129,7 +129,7 @@ func (newState *ApproveTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ApproveTransitionRequest) SyncEffectiveFieldsDuringRead(existingState ApproveTransitionRequest) { } -func (a ApproveTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ApproveTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -156,7 +156,7 @@ func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringCreat func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState ApproveTransitionRequestResponse) { } -func (a ApproveTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ApproveTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "activity": reflect.TypeOf(Activity{}), } @@ -194,7 +194,7 @@ func (newState *CommentObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan Comm func (newState *CommentObject) SyncEffectiveFieldsDuringRead(existingState CommentObject) { } -func (a CommentObject) GetComplexFieldTypes() map[string]reflect.Type { +func (a CommentObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "available_actions": reflect.TypeOf(types.StringType), } @@ -230,7 +230,7 @@ func (newState *CreateComment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateComment) SyncEffectiveFieldsDuringRead(existingState CreateComment) { } -func (a CreateComment) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateComment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -255,7 +255,7 @@ func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringRead(existingState CreateCommentResponse) { } -func (a CreateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "comment": reflect.TypeOf(CommentObject{}), } @@ -291,7 +291,7 @@ func (newState *CreateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateExperiment) SyncEffectiveFieldsDuringRead(existingState CreateExperiment) { } -func (a CreateExperiment) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ExperimentTag{}), } @@ -320,7 +320,7 @@ func (newState *CreateExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateExperimentResponse) SyncEffectiveFieldsDuringRead(existingState CreateExperimentResponse) { } -func (a CreateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -347,7 +347,7 @@ func (newState *CreateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateModelRequest) SyncEffectiveFieldsDuringRead(existingState CreateModelRequest) { } -func (a CreateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelTag{}), } @@ -375,7 +375,7 @@ func (newState *CreateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateModelResponse) SyncEffectiveFieldsDuringRead(existingState CreateModelResponse) { } -func (a CreateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_model": reflect.TypeOf(Model{}), } @@ -414,7 +414,7 @@ func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState CreateModelVersionRequest) { } -func (a CreateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelVersionTag{}), } @@ -446,7 +446,7 @@ func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState CreateModelVersionResponse) { } -func (a CreateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_version": reflect.TypeOf(ModelVersion{}), } @@ -522,7 +522,7 @@ func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState CreateRegistryWebhook) { } -func (a CreateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.StringType), "http_url_spec": reflect.TypeOf(HttpUrlSpec{}), @@ -568,7 +568,7 @@ func (newState *CreateRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateRu func (newState *CreateRun) SyncEffectiveFieldsDuringRead(existingState CreateRun) { } -func (a CreateRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(RunTag{}), } @@ -598,7 +598,7 @@ func (newState *CreateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRunResponse) SyncEffectiveFieldsDuringRead(existingState CreateRunResponse) { } -func (a CreateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "run": reflect.TypeOf(Run{}), } @@ -639,7 +639,7 @@ func (newState *CreateTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateTransitionRequest) SyncEffectiveFieldsDuringRead(existingState CreateTransitionRequest) { } -func (a CreateTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -665,7 +665,7 @@ func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState CreateTransitionRequestResponse) { } -func (a CreateTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "request": reflect.TypeOf(TransitionRequest{}), } @@ -691,7 +691,7 @@ func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringRead(existingState CreateWebhookResponse) { } -func (a CreateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "webhook": reflect.TypeOf(RegistryWebhook{}), } @@ -736,7 +736,7 @@ func (newState *Dataset) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dataset) { func (newState *Dataset) SyncEffectiveFieldsDuringRead(existingState Dataset) { } -func (a Dataset) GetComplexFieldTypes() map[string]reflect.Type { +func (a Dataset) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -767,7 +767,7 @@ func (newState *DatasetInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Datas func (newState *DatasetInput) SyncEffectiveFieldsDuringRead(existingState DatasetInput) { } -func (a DatasetInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a DatasetInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataset": reflect.TypeOf(Dataset{}), "tags": reflect.TypeOf(InputTag{}), @@ -798,7 +798,7 @@ func (newState *DeleteCommentRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteCommentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCommentRequest) { } -func (a DeleteCommentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCommentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -819,7 +819,7 @@ func (newState *DeleteCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteCommentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCommentResponse) { } -func (a DeleteCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCommentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -840,7 +840,7 @@ func (newState *DeleteExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteExperiment) SyncEffectiveFieldsDuringRead(existingState DeleteExperiment) { } -func (a DeleteExperiment) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -861,7 +861,7 @@ func (newState *DeleteExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteExperimentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExperimentResponse) { } -func (a DeleteExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -883,7 +883,7 @@ func (newState *DeleteModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteModelRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelRequest) { } -func (a DeleteModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -904,7 +904,7 @@ func (newState *DeleteModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteModelResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelResponse) { } -func (a DeleteModelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -929,7 +929,7 @@ func (newState *DeleteModelTagRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteModelTagRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelTagRequest) { } -func (a DeleteModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -951,7 +951,7 @@ func (newState *DeleteModelTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteModelTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelTagResponse) { } -func (a DeleteModelTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -975,7 +975,7 @@ func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionRequest) { } -func (a DeleteModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -997,7 +997,7 @@ func (newState *DeleteModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionResponse) { } -func (a DeleteModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1024,7 +1024,7 @@ func (newState *DeleteModelVersionTagRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteModelVersionTagRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionTagRequest) { } -func (a DeleteModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1047,7 +1047,7 @@ func (newState *DeleteModelVersionTagResponse) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteModelVersionTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionTagResponse) { } -func (a DeleteModelVersionTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1068,7 +1068,7 @@ func (newState *DeleteRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteRu func (newState *DeleteRun) SyncEffectiveFieldsDuringRead(existingState DeleteRun) { } -func (a DeleteRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1089,7 +1089,7 @@ func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunResponse) { } -func (a DeleteRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1117,7 +1117,7 @@ func (newState *DeleteRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteR func (newState *DeleteRuns) SyncEffectiveFieldsDuringRead(existingState DeleteRuns) { } -func (a DeleteRuns) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1142,7 +1142,7 @@ func (newState *DeleteRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunsResponse) { } -func (a DeleteRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1167,7 +1167,7 @@ func (newState *DeleteTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteTa func (newState *DeleteTag) SyncEffectiveFieldsDuringRead(existingState DeleteTag) { } -func (a DeleteTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1189,7 +1189,7 @@ func (newState *DeleteTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteTagResponse) { } -func (a DeleteTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1229,7 +1229,7 @@ func (newState *DeleteTransitionRequestRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteTransitionRequestRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTransitionRequestRequest) { } -func (a DeleteTransitionRequestRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTransitionRequestRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1254,7 +1254,7 @@ func (newState *DeleteTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *DeleteTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState DeleteTransitionRequestResponse) { } -func (a DeleteTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1276,7 +1276,7 @@ func (newState *DeleteWebhookRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteWebhookRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWebhookRequest) { } -func (a DeleteWebhookRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1297,7 +1297,7 @@ func (newState *DeleteWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteWebhookResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWebhookResponse) { } -func (a DeleteWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1331,7 +1331,7 @@ func (newState *Experiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Experim func (newState *Experiment) SyncEffectiveFieldsDuringRead(existingState Experiment) { } -func (a Experiment) GetComplexFieldTypes() map[string]reflect.Type { +func (a Experiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ExperimentTag{}), } @@ -1370,7 +1370,7 @@ func (newState *ExperimentAccessControlRequest) SyncEffectiveFieldsDuringCreateO func (newState *ExperimentAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ExperimentAccessControlRequest) { } -func (a ExperimentAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1404,7 +1404,7 @@ func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringCreate func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ExperimentAccessControlResponse) { } -func (a ExperimentAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ExperimentPermission{}), } @@ -1438,7 +1438,7 @@ func (newState *ExperimentPermission) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExperimentPermission) SyncEffectiveFieldsDuringRead(existingState ExperimentPermission) { } -func (a ExperimentPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1470,7 +1470,7 @@ func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissions) { } -func (a ExperimentPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ExperimentAccessControlResponse{}), } @@ -1500,7 +1500,7 @@ func (newState *ExperimentPermissionsDescription) SyncEffectiveFieldsDuringCreat func (newState *ExperimentPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissionsDescription) { } -func (a ExperimentPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1525,7 +1525,7 @@ func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissionsRequest) { } -func (a ExperimentPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ExperimentAccessControlRequest{}), } @@ -1555,7 +1555,7 @@ func (newState *ExperimentTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Expe func (newState *ExperimentTag) SyncEffectiveFieldsDuringRead(existingState ExperimentTag) { } -func (a ExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1583,7 +1583,7 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } -func (a FileInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1609,7 +1609,7 @@ func (newState *GetByNameRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetByNameRequest) SyncEffectiveFieldsDuringRead(existingState GetByNameRequest) { } -func (a GetByNameRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetByNameRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1633,7 +1633,7 @@ func (newState *GetExperimentPermissionLevelsRequest) SyncEffectiveFieldsDuringC func (newState *GetExperimentPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionLevelsRequest) { } -func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1656,7 +1656,7 @@ func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuring func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionLevelsResponse) { } -func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ExperimentPermissionsDescription{}), } @@ -1684,7 +1684,7 @@ func (newState *GetExperimentPermissionsRequest) SyncEffectiveFieldsDuringCreate func (newState *GetExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionsRequest) { } -func (a GetExperimentPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1708,7 +1708,7 @@ func (newState *GetExperimentRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetExperimentRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentRequest) { } -func (a GetExperimentRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExperimentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1731,7 +1731,7 @@ func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringRead(existingState GetExperimentResponse) { } -func (a GetExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiment": reflect.TypeOf(Experiment{}), } @@ -1770,7 +1770,7 @@ func (newState *GetHistoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetHistoryRequest) SyncEffectiveFieldsDuringRead(existingState GetHistoryRequest) { } -func (a GetHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1799,7 +1799,7 @@ func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionsRequest) { } -func (a GetLatestVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetLatestVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "stages": reflect.TypeOf(types.StringType), } @@ -1829,7 +1829,7 @@ func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionsResponse) { } -func (a GetLatestVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetLatestVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_versions": reflect.TypeOf(ModelVersion{}), } @@ -1859,7 +1859,7 @@ func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringRead(existingState GetMetricHistoryResponse) { } -func (a GetMetricHistoryResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetMetricHistoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metrics": reflect.TypeOf(Metric{}), } @@ -1888,7 +1888,7 @@ func (newState *GetModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetModelRequest) SyncEffectiveFieldsDuringRead(existingState GetModelRequest) { } -func (a GetModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1910,7 +1910,7 @@ func (newState *GetModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetModelResponse) SyncEffectiveFieldsDuringRead(existingState GetModelResponse) { } -func (a GetModelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_model_databricks": reflect.TypeOf(ModelDatabricks{}), } @@ -1940,7 +1940,7 @@ func (newState *GetModelVersionDownloadUriRequest) SyncEffectiveFieldsDuringCrea func (newState *GetModelVersionDownloadUriRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionDownloadUriRequest) { } -func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1964,7 +1964,7 @@ func (newState *GetModelVersionDownloadUriResponse) SyncEffectiveFieldsDuringCre func (newState *GetModelVersionDownloadUriResponse) SyncEffectiveFieldsDuringRead(existingState GetModelVersionDownloadUriResponse) { } -func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1990,7 +1990,7 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionRequest) { } -func (a GetModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2013,7 +2013,7 @@ func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState GetModelVersionResponse) { } -func (a GetModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_version": reflect.TypeOf(ModelVersion{}), } @@ -2041,7 +2041,7 @@ func (newState *GetRegisteredModelPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetRegisteredModelPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionLevelsRequest) { } -func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2064,7 +2064,7 @@ func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionLevelsResponse) { } -func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(RegisteredModelPermissionsDescription{}), } @@ -2092,7 +2092,7 @@ func (newState *GetRegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetRegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionsRequest) { } -func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2119,7 +2119,7 @@ func (newState *GetRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetR func (newState *GetRunRequest) SyncEffectiveFieldsDuringRead(existingState GetRunRequest) { } -func (a GetRunRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2144,7 +2144,7 @@ func (newState *GetRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetRunResponse) SyncEffectiveFieldsDuringRead(existingState GetRunResponse) { } -func (a GetRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "run": reflect.TypeOf(Run{}), } @@ -2188,7 +2188,7 @@ func (newState *HttpUrlSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan HttpUr func (newState *HttpUrlSpec) SyncEffectiveFieldsDuringRead(existingState HttpUrlSpec) { } -func (a HttpUrlSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a HttpUrlSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2222,7 +2222,7 @@ func (newState *HttpUrlSpecWithoutSecret) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *HttpUrlSpecWithoutSecret) SyncEffectiveFieldsDuringRead(existingState HttpUrlSpecWithoutSecret) { } -func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type { +func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2248,7 +2248,7 @@ func (newState *InputTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan InputTag) func (newState *InputTag) SyncEffectiveFieldsDuringRead(existingState InputTag) { } -func (a InputTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a InputTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2278,7 +2278,7 @@ func (newState *JobSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSpec) { func (newState *JobSpec) SyncEffectiveFieldsDuringRead(existingState JobSpec) { } -func (a JobSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2307,7 +2307,7 @@ func (newState *JobSpecWithoutSecret) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *JobSpecWithoutSecret) SyncEffectiveFieldsDuringRead(existingState JobSpecWithoutSecret) { } -func (a JobSpecWithoutSecret) GetComplexFieldTypes() map[string]reflect.Type { +func (a JobSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2345,7 +2345,7 @@ func (newState *ListArtifactsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListArtifactsRequest) SyncEffectiveFieldsDuringRead(existingState ListArtifactsRequest) { } -func (a ListArtifactsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListArtifactsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2375,7 +2375,7 @@ func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringRead(existingState ListArtifactsResponse) { } -func (a ListArtifactsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListArtifactsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "files": reflect.TypeOf(FileInfo{}), } @@ -2414,7 +2414,7 @@ func (newState *ListExperimentsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListExperimentsRequest) SyncEffectiveFieldsDuringRead(existingState ListExperimentsRequest) { } -func (a ListExperimentsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExperimentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2443,7 +2443,7 @@ func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringRead(existingState ListExperimentsResponse) { } -func (a ListExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiments": reflect.TypeOf(Experiment{}), } @@ -2474,7 +2474,7 @@ func (newState *ListModelsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListModelsRequest) SyncEffectiveFieldsDuringRead(existingState ListModelsRequest) { } -func (a ListModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2500,7 +2500,7 @@ func (newState *ListModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListModelsResponse) SyncEffectiveFieldsDuringRead(existingState ListModelsResponse) { } -func (a ListModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_models": reflect.TypeOf(Model{}), } @@ -2530,7 +2530,7 @@ func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringRead(existingState ListRegistryWebhooks) { } -func (a ListRegistryWebhooks) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRegistryWebhooks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "webhooks": reflect.TypeOf(RegistryWebhook{}), } @@ -2561,7 +2561,7 @@ func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringRead(existingState ListTransitionRequestsRequest) { } -func (a ListTransitionRequestsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTransitionRequestsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2585,7 +2585,7 @@ func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringRead(existingState ListTransitionRequestsResponse) { } -func (a ListTransitionRequestsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTransitionRequestsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "requests": reflect.TypeOf(Activity{}), } @@ -2620,7 +2620,7 @@ func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringRead(existingState ListWebhooksRequest) { } -func (a ListWebhooksRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListWebhooksRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.StringType), } @@ -2658,7 +2658,7 @@ func (newState *LogBatch) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogBatch) func (newState *LogBatch) SyncEffectiveFieldsDuringRead(existingState LogBatch) { } -func (a LogBatch) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogBatch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metrics": reflect.TypeOf(Metric{}), "params": reflect.TypeOf(Param{}), @@ -2692,7 +2692,7 @@ func (newState *LogBatchResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogBatchResponse) SyncEffectiveFieldsDuringRead(existingState LogBatchResponse) { } -func (a LogBatchResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogBatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2715,7 +2715,7 @@ func (newState *LogInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogInput func (newState *LogInputs) SyncEffectiveFieldsDuringRead(existingState LogInputs) { } -func (a LogInputs) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "datasets": reflect.TypeOf(DatasetInput{}), } @@ -2741,7 +2741,7 @@ func (newState *LogInputsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogInputsResponse) SyncEffectiveFieldsDuringRead(existingState LogInputsResponse) { } -func (a LogInputsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogInputsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2773,7 +2773,7 @@ func (newState *LogMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogMetri func (newState *LogMetric) SyncEffectiveFieldsDuringRead(existingState LogMetric) { } -func (a LogMetric) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2799,7 +2799,7 @@ func (newState *LogMetricResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogMetricResponse) SyncEffectiveFieldsDuringRead(existingState LogMetricResponse) { } -func (a LogMetricResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogMetricResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2822,7 +2822,7 @@ func (newState *LogModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogModel) func (newState *LogModel) SyncEffectiveFieldsDuringRead(existingState LogModel) { } -func (a LogModel) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2844,7 +2844,7 @@ func (newState *LogModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogModelResponse) SyncEffectiveFieldsDuringRead(existingState LogModelResponse) { } -func (a LogModelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2872,7 +2872,7 @@ func (newState *LogParam) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogParam) func (newState *LogParam) SyncEffectiveFieldsDuringRead(existingState LogParam) { } -func (a LogParam) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogParam) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2896,7 +2896,7 @@ func (newState *LogParamResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogParamResponse) SyncEffectiveFieldsDuringRead(existingState LogParamResponse) { } -func (a LogParamResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogParamResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2923,7 +2923,7 @@ func (newState *Metric) SyncEffectiveFieldsDuringCreateOrUpdate(plan Metric) { func (newState *Metric) SyncEffectiveFieldsDuringRead(existingState Metric) { } -func (a Metric) GetComplexFieldTypes() map[string]reflect.Type { +func (a Metric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2963,7 +2963,7 @@ func (newState *Model) SyncEffectiveFieldsDuringCreateOrUpdate(plan Model) { func (newState *Model) SyncEffectiveFieldsDuringRead(existingState Model) { } -func (a Model) GetComplexFieldTypes() map[string]reflect.Type { +func (a Model) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_versions": reflect.TypeOf(ModelVersion{}), "tags": reflect.TypeOf(ModelTag{}), @@ -3016,7 +3016,7 @@ func (newState *ModelDatabricks) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *ModelDatabricks) SyncEffectiveFieldsDuringRead(existingState ModelDatabricks) { } -func (a ModelDatabricks) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_versions": reflect.TypeOf(ModelVersion{}), "tags": reflect.TypeOf(ModelTag{}), @@ -3056,7 +3056,7 @@ func (newState *ModelTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan ModelTag) func (newState *ModelTag) SyncEffectiveFieldsDuringRead(existingState ModelTag) { } -func (a ModelTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3107,7 +3107,7 @@ func (newState *ModelVersion) SyncEffectiveFieldsDuringCreateOrUpdate(plan Model func (newState *ModelVersion) SyncEffectiveFieldsDuringRead(existingState ModelVersion) { } -func (a ModelVersion) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelVersion) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelVersionTag{}), } @@ -3192,7 +3192,7 @@ func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringRead(existingState ModelVersionDatabricks) { } -func (a ModelVersionDatabricks) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelVersionDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelVersionTag{}), } @@ -3234,7 +3234,7 @@ func (newState *ModelVersionTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *ModelVersionTag) SyncEffectiveFieldsDuringRead(existingState ModelVersionTag) { } -func (a ModelVersionTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelVersionTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3260,7 +3260,7 @@ func (newState *Param) SyncEffectiveFieldsDuringCreateOrUpdate(plan Param) { func (newState *Param) SyncEffectiveFieldsDuringRead(existingState Param) { } -func (a Param) GetComplexFieldTypes() map[string]reflect.Type { +func (a Param) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3290,7 +3290,7 @@ func (newState *RegisteredModelAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *RegisteredModelAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAccessControlRequest) { } -func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3324,7 +3324,7 @@ func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAccessControlResponse) { } -func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(RegisteredModelPermission{}), } @@ -3358,7 +3358,7 @@ func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermission) { } -func (a RegisteredModelPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -3390,7 +3390,7 @@ func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissions) { } -func (a RegisteredModelPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RegisteredModelAccessControlResponse{}), } @@ -3420,7 +3420,7 @@ func (newState *RegisteredModelPermissionsDescription) SyncEffectiveFieldsDuring func (newState *RegisteredModelPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissionsDescription) { } -func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3445,7 +3445,7 @@ func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissionsRequest) { } -func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RegisteredModelAccessControlRequest{}), } @@ -3528,7 +3528,7 @@ func (newState *RegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RegistryWebhook) SyncEffectiveFieldsDuringRead(existingState RegistryWebhook) { } -func (a RegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { +func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.StringType), "http_url_spec": reflect.TypeOf(HttpUrlSpecWithoutSecret{}), @@ -3583,7 +3583,7 @@ func (newState *RejectTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *RejectTransitionRequest) SyncEffectiveFieldsDuringRead(existingState RejectTransitionRequest) { } -func (a RejectTransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RejectTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3609,7 +3609,7 @@ func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState RejectTransitionRequestResponse) { } -func (a RejectTransitionRequestResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RejectTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "activity": reflect.TypeOf(Activity{}), } @@ -3638,7 +3638,7 @@ func (newState *RenameModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RenameModelRequest) SyncEffectiveFieldsDuringRead(existingState RenameModelRequest) { } -func (a RenameModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RenameModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3661,7 +3661,7 @@ func (newState *RenameModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RenameModelResponse) SyncEffectiveFieldsDuringRead(existingState RenameModelResponse) { } -func (a RenameModelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RenameModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_model": reflect.TypeOf(Model{}), } @@ -3688,7 +3688,7 @@ func (newState *RestoreExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RestoreExperiment) SyncEffectiveFieldsDuringRead(existingState RestoreExperiment) { } -func (a RestoreExperiment) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3709,7 +3709,7 @@ func (newState *RestoreExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RestoreExperimentResponse) SyncEffectiveFieldsDuringRead(existingState RestoreExperimentResponse) { } -func (a RestoreExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3730,7 +3730,7 @@ func (newState *RestoreRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan Restore func (newState *RestoreRun) SyncEffectiveFieldsDuringRead(existingState RestoreRun) { } -func (a RestoreRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3751,7 +3751,7 @@ func (newState *RestoreRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RestoreRunResponse) SyncEffectiveFieldsDuringRead(existingState RestoreRunResponse) { } -func (a RestoreRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3779,7 +3779,7 @@ func (newState *RestoreRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan Restor func (newState *RestoreRuns) SyncEffectiveFieldsDuringRead(existingState RestoreRuns) { } -func (a RestoreRuns) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3804,7 +3804,7 @@ func (newState *RestoreRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RestoreRunsResponse) SyncEffectiveFieldsDuringRead(existingState RestoreRunsResponse) { } -func (a RestoreRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3831,7 +3831,7 @@ func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { } -func (a Run) GetComplexFieldTypes() map[string]reflect.Type { +func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data": reflect.TypeOf(RunData{}), "info": reflect.TypeOf(RunInfo{}), @@ -3870,7 +3870,7 @@ func (newState *RunData) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunData) { func (newState *RunData) SyncEffectiveFieldsDuringRead(existingState RunData) { } -func (a RunData) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metrics": reflect.TypeOf(Metric{}), "params": reflect.TypeOf(Param{}), @@ -3927,7 +3927,7 @@ func (newState *RunInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInfo) { func (newState *RunInfo) SyncEffectiveFieldsDuringRead(existingState RunInfo) { } -func (a RunInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3958,7 +3958,7 @@ func (newState *RunInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInput func (newState *RunInputs) SyncEffectiveFieldsDuringRead(existingState RunInputs) { } -func (a RunInputs) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataset_inputs": reflect.TypeOf(DatasetInput{}), } @@ -3987,7 +3987,7 @@ func (newState *RunTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTag) { func (newState *RunTag) SyncEffectiveFieldsDuringRead(existingState RunTag) { } -func (a RunTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a RunTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4024,7 +4024,7 @@ func (newState *SearchExperiments) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SearchExperiments) SyncEffectiveFieldsDuringRead(existingState SearchExperiments) { } -func (a SearchExperiments) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchExperiments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.StringType), } @@ -4058,7 +4058,7 @@ func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringRead(existingState SearchExperimentsResponse) { } -func (a SearchExperimentsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiments": reflect.TypeOf(Experiment{}), } @@ -4097,7 +4097,7 @@ func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringRead(existingState SearchModelVersionsRequest) { } -func (a SearchModelVersionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.StringType), } @@ -4130,7 +4130,7 @@ func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringRead(existingState SearchModelVersionsResponse) { } -func (a SearchModelVersionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_versions": reflect.TypeOf(ModelVersion{}), } @@ -4169,7 +4169,7 @@ func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringRead(existingState SearchModelsRequest) { } -func (a SearchModelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.StringType), } @@ -4201,7 +4201,7 @@ func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringRead(existingState SearchModelsResponse) { } -func (a SearchModelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_models": reflect.TypeOf(Model{}), } @@ -4256,7 +4256,7 @@ func (newState *SearchRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan SearchR func (newState *SearchRuns) SyncEffectiveFieldsDuringRead(existingState SearchRuns) { } -func (a SearchRuns) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiment_ids": reflect.TypeOf(types.StringType), "order_by": reflect.TypeOf(types.StringType), @@ -4293,7 +4293,7 @@ func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringRead(existingState SearchRunsResponse) { } -func (a SearchRunsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SearchRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "runs": reflect.TypeOf(Run{}), } @@ -4328,7 +4328,7 @@ func (newState *SetExperimentTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SetExperimentTag) SyncEffectiveFieldsDuringRead(existingState SetExperimentTag) { } -func (a SetExperimentTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4351,7 +4351,7 @@ func (newState *SetExperimentTagResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *SetExperimentTagResponse) SyncEffectiveFieldsDuringRead(existingState SetExperimentTagResponse) { } -func (a SetExperimentTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetExperimentTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4381,7 +4381,7 @@ func (newState *SetModelTagRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SetModelTagRequest) SyncEffectiveFieldsDuringRead(existingState SetModelTagRequest) { } -func (a SetModelTagRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4404,7 +4404,7 @@ func (newState *SetModelTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SetModelTagResponse) SyncEffectiveFieldsDuringRead(existingState SetModelTagResponse) { } -func (a SetModelTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4436,7 +4436,7 @@ func (newState *SetModelVersionTagRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *SetModelVersionTagRequest) SyncEffectiveFieldsDuringRead(existingState SetModelVersionTagRequest) { } -func (a SetModelVersionTagRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4460,7 +4460,7 @@ func (newState *SetModelVersionTagResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SetModelVersionTagResponse) SyncEffectiveFieldsDuringRead(existingState SetModelVersionTagResponse) { } -func (a SetModelVersionTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4491,7 +4491,7 @@ func (newState *SetTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetTag) { func (newState *SetTag) SyncEffectiveFieldsDuringRead(existingState SetTag) { } -func (a SetTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4515,7 +4515,7 @@ func (newState *SetTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Set func (newState *SetTagResponse) SyncEffectiveFieldsDuringRead(existingState SetTagResponse) { } -func (a SetTagResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4539,7 +4539,7 @@ func (newState *TestRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TestRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhook) { } -func (a TestRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { +func (a TestRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4567,7 +4567,7 @@ func (newState *TestRegistryWebhookRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *TestRegistryWebhookRequest) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhookRequest) { } -func (a TestRegistryWebhookRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TestRegistryWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4591,7 +4591,7 @@ func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhookResponse) { } -func (a TestRegistryWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a TestRegistryWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "webhook": reflect.TypeOf(TestRegistryWebhook{}), } @@ -4635,7 +4635,7 @@ func (newState *TransitionModelVersionStageDatabricks) SyncEffectiveFieldsDuring func (newState *TransitionModelVersionStageDatabricks) SyncEffectiveFieldsDuringRead(existingState TransitionModelVersionStageDatabricks) { } -func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes() map[string]reflect.Type { +func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4680,7 +4680,7 @@ func (newState *TransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TransitionRequest) SyncEffectiveFieldsDuringRead(existingState TransitionRequest) { } -func (a TransitionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "available_actions": reflect.TypeOf(types.StringType), } @@ -4710,7 +4710,7 @@ func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringRead(existingState TransitionStageResponse) { } -func (a TransitionStageResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a TransitionStageResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_version": reflect.TypeOf(ModelVersionDatabricks{}), } @@ -4739,7 +4739,7 @@ func (newState *UpdateComment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateComment) SyncEffectiveFieldsDuringRead(existingState UpdateComment) { } -func (a UpdateComment) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateComment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4763,7 +4763,7 @@ func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateCommentResponse) { } -func (a UpdateCommentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "comment": reflect.TypeOf(CommentObject{}), } @@ -4793,7 +4793,7 @@ func (newState *UpdateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateExperiment) SyncEffectiveFieldsDuringRead(existingState UpdateExperiment) { } -func (a UpdateExperiment) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4815,7 +4815,7 @@ func (newState *UpdateExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateExperimentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExperimentResponse) { } -func (a UpdateExperimentResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4838,7 +4838,7 @@ func (newState *UpdateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateModelRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelRequest) { } -func (a UpdateModelRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4860,7 +4860,7 @@ func (newState *UpdateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *UpdateModelResponse) SyncEffectiveFieldsDuringRead(existingState UpdateModelResponse) { } -func (a UpdateModelResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4885,7 +4885,7 @@ func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionRequest) { } -func (a UpdateModelVersionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4908,7 +4908,7 @@ func (newState *UpdateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionResponse) { } -func (a UpdateModelVersionResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4978,7 +4978,7 @@ func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState UpdateRegistryWebhook) { } -func (a UpdateRegistryWebhook) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.StringType), "http_url_spec": reflect.TypeOf(HttpUrlSpec{}), @@ -5023,7 +5023,7 @@ func (newState *UpdateRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRu func (newState *UpdateRun) SyncEffectiveFieldsDuringRead(existingState UpdateRun) { } -func (a UpdateRun) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5049,7 +5049,7 @@ func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringRead(existingState UpdateRunResponse) { } -func (a UpdateRunResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "run_info": reflect.TypeOf(RunInfo{}), } @@ -5074,7 +5074,7 @@ func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringRead(existingState UpdateWebhookResponse) { } -func (a UpdateWebhookResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 71c99ceb0b..57e340baa6 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -40,7 +40,7 @@ func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existingState CreateCustomAppIntegration) { } -func (a CreateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.StringType), "scopes": reflect.TypeOf(types.StringType), @@ -82,7 +82,7 @@ func (newState *CreateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *CreateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState CreateCustomAppIntegrationOutput) { } -func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -110,7 +110,7 @@ func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOr func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(existingState CreatePublishedAppIntegration) { } -func (a CreatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } @@ -138,7 +138,7 @@ func (newState *CreatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *CreatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState CreatePublishedAppIntegrationOutput) { } -func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -162,7 +162,7 @@ func (newState *CreateServicePrincipalSecretRequest) SyncEffectiveFieldsDuringCr func (newState *CreateServicePrincipalSecretRequest) SyncEffectiveFieldsDuringRead(existingState CreateServicePrincipalSecretRequest) { } -func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -195,7 +195,7 @@ func (newState *CreateServicePrincipalSecretResponse) SyncEffectiveFieldsDuringC func (newState *CreateServicePrincipalSecretResponse) SyncEffectiveFieldsDuringRead(existingState CreateServicePrincipalSecretResponse) { } -func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -225,7 +225,7 @@ func (newState *DataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Data func (newState *DataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState DataPlaneInfo) { } -func (a DataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a DataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -247,7 +247,7 @@ func (newState *DeleteCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *DeleteCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState DeleteCustomAppIntegrationOutput) { } -func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -268,7 +268,7 @@ func (newState *DeleteCustomAppIntegrationRequest) SyncEffectiveFieldsDuringCrea func (newState *DeleteCustomAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCustomAppIntegrationRequest) { } -func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -289,7 +289,7 @@ func (newState *DeletePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *DeletePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState DeletePublishedAppIntegrationOutput) { } -func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -310,7 +310,7 @@ func (newState *DeletePublishedAppIntegrationRequest) SyncEffectiveFieldsDuringC func (newState *DeletePublishedAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState DeletePublishedAppIntegrationRequest) { } -func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -331,7 +331,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -355,7 +355,7 @@ func (newState *DeleteServicePrincipalSecretRequest) SyncEffectiveFieldsDuringCr func (newState *DeleteServicePrincipalSecretRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServicePrincipalSecretRequest) { } -func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -398,7 +398,7 @@ func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOr func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationOutput) { } -func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.StringType), "scopes": reflect.TypeOf(types.StringType), @@ -441,7 +441,7 @@ func (newState *GetCustomAppIntegrationRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetCustomAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationRequest) { } -func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -466,7 +466,7 @@ func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringCreateO func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationsOutput) { } -func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(GetCustomAppIntegrationOutput{}), } @@ -504,7 +504,7 @@ func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationOutput) { } -func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } @@ -536,7 +536,7 @@ func (newState *GetPublishedAppIntegrationRequest) SyncEffectiveFieldsDuringCrea func (newState *GetPublishedAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationRequest) { } -func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -561,7 +561,7 @@ func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringCrea func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationsOutput) { } -func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(GetPublishedAppIntegrationOutput{}), } @@ -592,7 +592,7 @@ func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppsOutput) { } -func (a GetPublishedAppsOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPublishedAppsOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(PublishedAppOutput{}), } @@ -624,7 +624,7 @@ func (newState *ListCustomAppIntegrationsRequest) SyncEffectiveFieldsDuringCreat func (newState *ListCustomAppIntegrationsRequest) SyncEffectiveFieldsDuringRead(existingState ListCustomAppIntegrationsRequest) { } -func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -652,7 +652,7 @@ func (newState *ListOAuthPublishedAppsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListOAuthPublishedAppsRequest) SyncEffectiveFieldsDuringRead(existingState ListOAuthPublishedAppsRequest) { } -func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -678,7 +678,7 @@ func (newState *ListPublishedAppIntegrationsRequest) SyncEffectiveFieldsDuringCr func (newState *ListPublishedAppIntegrationsRequest) SyncEffectiveFieldsDuringRead(existingState ListPublishedAppIntegrationsRequest) { } -func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -713,7 +713,7 @@ func (newState *ListServicePrincipalSecretsRequest) SyncEffectiveFieldsDuringCre func (newState *ListServicePrincipalSecretsRequest) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalSecretsRequest) { } -func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -739,7 +739,7 @@ func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringCr func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalSecretsResponse) { } -func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "secrets": reflect.TypeOf(SecretInfo{}), } @@ -781,7 +781,7 @@ func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringRead(existingState PublishedAppOutput) { } -func (a PublishedAppOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.StringType), "scopes": reflect.TypeOf(types.StringType), @@ -825,7 +825,7 @@ func (newState *SecretInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan SecretI func (newState *SecretInfo) SyncEffectiveFieldsDuringRead(existingState SecretInfo) { } -func (a SecretInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a SecretInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -854,7 +854,7 @@ func (newState *TokenAccessPolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TokenAccessPolicy) SyncEffectiveFieldsDuringRead(existingState TokenAccessPolicy) { } -func (a TokenAccessPolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -882,7 +882,7 @@ func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existingState UpdateCustomAppIntegration) { } -func (a UpdateCustomAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.StringType), "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), @@ -912,7 +912,7 @@ func (newState *UpdateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *UpdateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState UpdateCustomAppIntegrationOutput) { } -func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -934,7 +934,7 @@ func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOr func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(existingState UpdatePublishedAppIntegration) { } -func (a UpdatePublishedAppIntegration) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } @@ -960,7 +960,7 @@ func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState UpdatePublishedAppIntegrationOutput) { } -func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 5e2488fe95..a670a2cc5a 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -90,7 +90,7 @@ func (newState *CreatePipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreatePipeline) SyncEffectiveFieldsDuringRead(existingState CreatePipeline) { } -func (a CreatePipeline) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), "configuration": reflect.TypeOf(types.StringType), @@ -171,7 +171,7 @@ func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringRead(existingState CreatePipelineResponse) { } -func (a CreatePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_settings": reflect.TypeOf(PipelineSpec{}), } @@ -200,7 +200,7 @@ func (newState *CronTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronTr func (newState *CronTrigger) SyncEffectiveFieldsDuringRead(existingState CronTrigger) { } -func (a CronTrigger) GetComplexFieldTypes() map[string]reflect.Type { +func (a CronTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -226,7 +226,7 @@ func (newState *DataPlaneId) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataPl func (newState *DataPlaneId) SyncEffectiveFieldsDuringRead(existingState DataPlaneId) { } -func (a DataPlaneId) GetComplexFieldTypes() map[string]reflect.Type { +func (a DataPlaneId) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -250,7 +250,7 @@ func (newState *DeletePipelineRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeletePipelineRequest) SyncEffectiveFieldsDuringRead(existingState DeletePipelineRequest) { } -func (a DeletePipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -271,7 +271,7 @@ func (newState *DeletePipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeletePipelineResponse) SyncEffectiveFieldsDuringRead(existingState DeletePipelineResponse) { } -func (a DeletePipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -354,7 +354,7 @@ func (newState *EditPipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditP func (newState *EditPipeline) SyncEffectiveFieldsDuringRead(existingState EditPipeline) { } -func (a EditPipeline) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), "configuration": reflect.TypeOf(types.StringType), @@ -431,7 +431,7 @@ func (newState *EditPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EditPipelineResponse) SyncEffectiveFieldsDuringRead(existingState EditPipelineResponse) { } -func (a EditPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -454,7 +454,7 @@ func (newState *ErrorDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan ErrorD func (newState *ErrorDetail) SyncEffectiveFieldsDuringRead(existingState ErrorDetail) { } -func (a ErrorDetail) GetComplexFieldTypes() map[string]reflect.Type { +func (a ErrorDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exceptions": reflect.TypeOf(SerializedException{}), } @@ -482,7 +482,7 @@ func (newState *FileLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileLi func (newState *FileLibrary) SyncEffectiveFieldsDuringRead(existingState FileLibrary) { } -func (a FileLibrary) GetComplexFieldTypes() map[string]reflect.Type { +func (a FileLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -507,7 +507,7 @@ func (newState *Filters) SyncEffectiveFieldsDuringCreateOrUpdate(plan Filters) { func (newState *Filters) SyncEffectiveFieldsDuringRead(existingState Filters) { } -func (a Filters) GetComplexFieldTypes() map[string]reflect.Type { +func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exclude": reflect.TypeOf(types.StringType), "include": reflect.TypeOf(types.StringType), @@ -539,7 +539,7 @@ func (newState *GetPipelinePermissionLevelsRequest) SyncEffectiveFieldsDuringCre func (newState *GetPipelinePermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionLevelsRequest) { } -func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -562,7 +562,7 @@ func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringCr func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionLevelsResponse) { } -func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(PipelinePermissionsDescription{}), } @@ -590,7 +590,7 @@ func (newState *GetPipelinePermissionsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetPipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionsRequest) { } -func (a GetPipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -613,7 +613,7 @@ func (newState *GetPipelineRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetPipelineRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelineRequest) { } -func (a GetPipelineRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -660,7 +660,7 @@ func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringRead(existingState GetPipelineResponse) { } -func (a GetPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_updates": reflect.TypeOf(UpdateStateInfo{}), "spec": reflect.TypeOf(PipelineSpec{}), @@ -704,7 +704,7 @@ func (newState *GetUpdateRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetUpdateRequest) SyncEffectiveFieldsDuringRead(existingState GetUpdateRequest) { } -func (a GetUpdateRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -728,7 +728,7 @@ func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringRead(existingState GetUpdateResponse) { } -func (a GetUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "update": reflect.TypeOf(UpdateInfo{}), } @@ -759,7 +759,7 @@ func (newState *IngestionConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan In func (newState *IngestionConfig) SyncEffectiveFieldsDuringRead(existingState IngestionConfig) { } -func (a IngestionConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a IngestionConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "report": reflect.TypeOf(ReportSpec{}), "schema": reflect.TypeOf(SchemaSpec{}), @@ -810,7 +810,7 @@ func (newState *IngestionGatewayPipelineDefinition) SyncEffectiveFieldsDuringCre func (newState *IngestionGatewayPipelineDefinition) SyncEffectiveFieldsDuringRead(existingState IngestionGatewayPipelineDefinition) { } -func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes() map[string]reflect.Type { +func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -849,7 +849,7 @@ func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringCreateOrUp func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringRead(existingState IngestionPipelineDefinition) { } -func (a IngestionPipelineDefinition) GetComplexFieldTypes() map[string]reflect.Type { +func (a IngestionPipelineDefinition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "objects": reflect.TypeOf(IngestionConfig{}), "table_configuration": reflect.TypeOf(TableSpecificConfig{}), @@ -904,7 +904,7 @@ func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringRead(existingState ListPipelineEventsRequest) { } -func (a ListPipelineEventsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPipelineEventsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.StringType), } @@ -939,7 +939,7 @@ func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringRead(existingState ListPipelineEventsResponse) { } -func (a ListPipelineEventsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPipelineEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(PipelineEvent{}), } @@ -988,7 +988,7 @@ func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringRead(existingState ListPipelinesRequest) { } -func (a ListPipelinesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPipelinesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.StringType), } @@ -1020,7 +1020,7 @@ func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringRead(existingState ListPipelinesResponse) { } -func (a ListPipelinesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPipelinesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "statuses": reflect.TypeOf(PipelineStateInfo{}), } @@ -1055,7 +1055,7 @@ func (newState *ListUpdatesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListUpdatesRequest) SyncEffectiveFieldsDuringRead(existingState ListUpdatesRequest) { } -func (a ListUpdatesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListUpdatesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1087,7 +1087,7 @@ func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringRead(existingState ListUpdatesResponse) { } -func (a ListUpdatesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListUpdatesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "updates": reflect.TypeOf(UpdateInfo{}), } @@ -1114,7 +1114,7 @@ func (newState *ManualTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan Manu func (newState *ManualTrigger) SyncEffectiveFieldsDuringRead(existingState ManualTrigger) { } -func (a ManualTrigger) GetComplexFieldTypes() map[string]reflect.Type { +func (a ManualTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1135,7 +1135,7 @@ func (newState *NotebookLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan No func (newState *NotebookLibrary) SyncEffectiveFieldsDuringRead(existingState NotebookLibrary) { } -func (a NotebookLibrary) GetComplexFieldTypes() map[string]reflect.Type { +func (a NotebookLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1166,7 +1166,7 @@ func (newState *Notifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan Noti func (newState *Notifications) SyncEffectiveFieldsDuringRead(existingState Notifications) { } -func (a Notifications) GetComplexFieldTypes() map[string]reflect.Type { +func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alerts": reflect.TypeOf(types.StringType), "email_recipients": reflect.TypeOf(types.StringType), @@ -1230,7 +1230,7 @@ func (newState *Origin) SyncEffectiveFieldsDuringCreateOrUpdate(plan Origin) { func (newState *Origin) SyncEffectiveFieldsDuringRead(existingState Origin) { } -func (a Origin) GetComplexFieldTypes() map[string]reflect.Type { +func (a Origin) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1275,7 +1275,7 @@ func (newState *PipelineAccessControlRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *PipelineAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState PipelineAccessControlRequest) { } -func (a PipelineAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1309,7 +1309,7 @@ func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringCreateOr func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState PipelineAccessControlResponse) { } -func (a PipelineAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(PipelinePermission{}), } @@ -1432,7 +1432,7 @@ func (newState *PipelineCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineCluster) SyncEffectiveFieldsDuringRead(existingState PipelineCluster) { } -func (a PipelineCluster) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(PipelineClusterAutoscale{}), "aws_attributes": reflect.TypeOf(compute.AwsAttributes{}), @@ -1515,7 +1515,7 @@ func (newState *PipelineClusterAutoscale) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *PipelineClusterAutoscale) SyncEffectiveFieldsDuringRead(existingState PipelineClusterAutoscale) { } -func (a PipelineClusterAutoscale) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineClusterAutoscale) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1542,7 +1542,7 @@ func (newState *PipelineDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelineDeployment) SyncEffectiveFieldsDuringRead(existingState PipelineDeployment) { } -func (a PipelineDeployment) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineDeployment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1582,7 +1582,7 @@ func (newState *PipelineEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipe func (newState *PipelineEvent) SyncEffectiveFieldsDuringRead(existingState PipelineEvent) { } -func (a PipelineEvent) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineEvent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error": reflect.TypeOf(ErrorDetail{}), "origin": reflect.TypeOf(Origin{}), @@ -1633,7 +1633,7 @@ func (newState *PipelineLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineLibrary) SyncEffectiveFieldsDuringRead(existingState PipelineLibrary) { } -func (a PipelineLibrary) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file": reflect.TypeOf(FileLibrary{}), "maven": reflect.TypeOf(compute.MavenLibrary{}), @@ -1673,7 +1673,7 @@ func (newState *PipelinePermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelinePermission) SyncEffectiveFieldsDuringRead(existingState PipelinePermission) { } -func (a PipelinePermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelinePermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1705,7 +1705,7 @@ func (newState *PipelinePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PipelinePermissions) SyncEffectiveFieldsDuringRead(existingState PipelinePermissions) { } -func (a PipelinePermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelinePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PipelineAccessControlResponse{}), } @@ -1735,7 +1735,7 @@ func (newState *PipelinePermissionsDescription) SyncEffectiveFieldsDuringCreateO func (newState *PipelinePermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PipelinePermissionsDescription) { } -func (a PipelinePermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelinePermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1760,7 +1760,7 @@ func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PipelinePermissionsRequest) { } -func (a PipelinePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PipelineAccessControlRequest{}), } @@ -1841,7 +1841,7 @@ func (newState *PipelineSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipel func (newState *PipelineSpec) SyncEffectiveFieldsDuringRead(existingState PipelineSpec) { } -func (a PipelineSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), "configuration": reflect.TypeOf(types.StringType), @@ -1933,7 +1933,7 @@ func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringRead(existingState PipelineStateInfo) { } -func (a PipelineStateInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_updates": reflect.TypeOf(UpdateStateInfo{}), } @@ -1968,7 +1968,7 @@ func (newState *PipelineTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineTrigger) SyncEffectiveFieldsDuringRead(existingState PipelineTrigger) { } -func (a PipelineTrigger) GetComplexFieldTypes() map[string]reflect.Type { +func (a PipelineTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cron": reflect.TypeOf(CronTrigger{}), "manual": reflect.TypeOf(ManualTrigger{}), @@ -2010,7 +2010,7 @@ func (newState *ReportSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReportS func (newState *ReportSpec) SyncEffectiveFieldsDuringRead(existingState ReportSpec) { } -func (a ReportSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReportSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } @@ -2051,7 +2051,7 @@ func (newState *RestartWindow) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rest func (newState *RestartWindow) SyncEffectiveFieldsDuringRead(existingState RestartWindow) { } -func (a RestartWindow) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestartWindow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2089,7 +2089,7 @@ func (newState *SchemaSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaS func (newState *SchemaSpec) SyncEffectiveFieldsDuringRead(existingState SchemaSpec) { } -func (a SchemaSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a SchemaSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } @@ -2122,7 +2122,7 @@ func (newState *Sequencing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sequenc func (newState *Sequencing) SyncEffectiveFieldsDuringRead(existingState Sequencing) { } -func (a Sequencing) GetComplexFieldTypes() map[string]reflect.Type { +func (a Sequencing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_plane_id": reflect.TypeOf(DataPlaneId{}), } @@ -2154,7 +2154,7 @@ func (newState *SerializedException) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SerializedException) SyncEffectiveFieldsDuringRead(existingState SerializedException) { } -func (a SerializedException) GetComplexFieldTypes() map[string]reflect.Type { +func (a SerializedException) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "stack": reflect.TypeOf(StackFrame{}), } @@ -2189,7 +2189,7 @@ func (newState *StackFrame) SyncEffectiveFieldsDuringCreateOrUpdate(plan StackFr func (newState *StackFrame) SyncEffectiveFieldsDuringRead(existingState StackFrame) { } -func (a StackFrame) GetComplexFieldTypes() map[string]reflect.Type { +func (a StackFrame) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2231,7 +2231,7 @@ func (newState *StartUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan StartU func (newState *StartUpdate) SyncEffectiveFieldsDuringRead(existingState StartUpdate) { } -func (a StartUpdate) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "full_refresh_selection": reflect.TypeOf(types.StringType), "refresh_selection": reflect.TypeOf(types.StringType), @@ -2265,7 +2265,7 @@ func (newState *StartUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *StartUpdateResponse) SyncEffectiveFieldsDuringRead(existingState StartUpdateResponse) { } -func (a StartUpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2286,7 +2286,7 @@ func (newState *StopPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StopPipelineResponse) SyncEffectiveFieldsDuringRead(existingState StopPipelineResponse) { } -func (a StopPipelineResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a StopPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2307,7 +2307,7 @@ func (newState *StopRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan StopRe func (newState *StopRequest) SyncEffectiveFieldsDuringRead(existingState StopRequest) { } -func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2346,7 +2346,7 @@ func (newState *TableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableSpe func (newState *TableSpec) SyncEffectiveFieldsDuringRead(existingState TableSpec) { } -func (a TableSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } @@ -2388,7 +2388,7 @@ func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringRead(existingState TableSpecificConfig) { } -func (a TableSpecificConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "primary_keys": reflect.TypeOf(types.StringType), "sequence_by": reflect.TypeOf(types.StringType), @@ -2449,7 +2449,7 @@ func (newState *UpdateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateI func (newState *UpdateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateInfo) { } -func (a UpdateInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(PipelineSpec{}), "full_refresh_selection": reflect.TypeOf(types.StringType), @@ -2495,7 +2495,7 @@ func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateStateInfo) { } -func (a UpdateStateInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index fa5af4b517..367f2f1410 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -29,7 +29,7 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan Aws func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsCredentials) { } -func (a AwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sts_role": reflect.TypeOf(StsRole{}), } @@ -65,7 +65,7 @@ func (newState *AwsKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsKeyI func (newState *AwsKeyInfo) SyncEffectiveFieldsDuringRead(existingState AwsKeyInfo) { } -func (a AwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a AwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -93,7 +93,7 @@ func (newState *AzureWorkspaceInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AzureWorkspaceInfo) SyncEffectiveFieldsDuringRead(existingState AzureWorkspaceInfo) { } -func (a AzureWorkspaceInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureWorkspaceInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -118,7 +118,7 @@ func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringRead(existingState CloudResourceContainer) { } -func (a CloudResourceContainer) GetComplexFieldTypes() map[string]reflect.Type { +func (a CloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp": reflect.TypeOf(CustomerFacingGcpCloudResourceContainer{}), } @@ -153,7 +153,7 @@ func (newState *CreateAwsKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateAwsKeyInfo) SyncEffectiveFieldsDuringRead(existingState CreateAwsKeyInfo) { } -func (a CreateAwsKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateAwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -177,7 +177,7 @@ func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringCreateO func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringRead(existingState CreateCredentialAwsCredentials) { } -func (a CreateCredentialAwsCredentials) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCredentialAwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sts_role": reflect.TypeOf(CreateCredentialStsRole{}), } @@ -205,7 +205,7 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialRequest) { } -func (a CreateCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_credentials": reflect.TypeOf(CreateCredentialAwsCredentials{}), } @@ -233,7 +233,7 @@ func (newState *CreateCredentialStsRole) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialStsRole) SyncEffectiveFieldsDuringRead(existingState CreateCredentialStsRole) { } -func (a CreateCredentialStsRole) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCredentialStsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -259,7 +259,7 @@ func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringCreate func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringRead(existingState CreateCustomerManagedKeyRequest) { } -func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_key_info": reflect.TypeOf(CreateAwsKeyInfo{}), "gcp_key_info": reflect.TypeOf(CreateGcpKeyInfo{}), @@ -294,7 +294,7 @@ func (newState *CreateGcpKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateGcpKeyInfo) SyncEffectiveFieldsDuringRead(existingState CreateGcpKeyInfo) { } -func (a CreateGcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateGcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -334,7 +334,7 @@ func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringRead(existingState CreateNetworkRequest) { } -func (a CreateNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), "security_group_ids": reflect.TypeOf(types.StringType), @@ -377,7 +377,7 @@ func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringCrea func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState CreateStorageConfigurationRequest) { } -func (a CreateStorageConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateStorageConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "root_bucket_info": reflect.TypeOf(RootBucketInfo{}), } @@ -412,7 +412,7 @@ func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState CreateVpcEndpointRequest) { } -func (a CreateVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_vpc_endpoint_info": reflect.TypeOf(GcpVpcEndpointInfo{}), } @@ -550,7 +550,7 @@ func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState CreateWorkspaceRequest) { } -func (a CreateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), "custom_tags": reflect.TypeOf(types.StringType), @@ -610,7 +610,7 @@ func (newState *Credential) SyncEffectiveFieldsDuringCreateOrUpdate(plan Credent func (newState *Credential) SyncEffectiveFieldsDuringRead(existingState Credential) { } -func (a Credential) GetComplexFieldTypes() map[string]reflect.Type { +func (a Credential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_credentials": reflect.TypeOf(AwsCredentials{}), } @@ -643,7 +643,7 @@ func (newState *CustomerFacingGcpCloudResourceContainer) SyncEffectiveFieldsDuri func (newState *CustomerFacingGcpCloudResourceContainer) SyncEffectiveFieldsDuringRead(existingState CustomerFacingGcpCloudResourceContainer) { } -func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes() map[string]reflect.Type { +func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -676,7 +676,7 @@ func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringRead(existingState CustomerManagedKey) { } -func (a CustomerManagedKey) GetComplexFieldTypes() map[string]reflect.Type { +func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_key_info": reflect.TypeOf(AwsKeyInfo{}), "gcp_key_info": reflect.TypeOf(GcpKeyInfo{}), @@ -715,7 +715,7 @@ func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialRequest) { } -func (a DeleteCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -739,7 +739,7 @@ func (newState *DeleteEncryptionKeyRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteEncryptionKeyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteEncryptionKeyRequest) { } -func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -763,7 +763,7 @@ func (newState *DeleteNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteNetworkRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkRequest) { } -func (a DeleteNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -787,7 +787,7 @@ func (newState *DeletePrivateAccesRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeletePrivateAccesRequest) SyncEffectiveFieldsDuringRead(existingState DeletePrivateAccesRequest) { } -func (a DeletePrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -808,7 +808,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -830,7 +830,7 @@ func (newState *DeleteStorageRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteStorageRequest) SyncEffectiveFieldsDuringRead(existingState DeleteStorageRequest) { } -func (a DeleteStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -854,7 +854,7 @@ func (newState *DeleteVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVpcEndpointRequest) { } -func (a DeleteVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -878,7 +878,7 @@ func (newState *DeleteWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspaceRequest) { } -func (a DeleteWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -905,7 +905,7 @@ func (newState *ExternalCustomerInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExternalCustomerInfo) SyncEffectiveFieldsDuringRead(existingState ExternalCustomerInfo) { } -func (a ExternalCustomerInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExternalCustomerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -930,7 +930,7 @@ func (newState *GcpKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpKeyI func (newState *GcpKeyInfo) SyncEffectiveFieldsDuringRead(existingState GcpKeyInfo) { } -func (a GcpKeyInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -983,7 +983,7 @@ func (newState *GcpManagedNetworkConfig) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GcpManagedNetworkConfig) SyncEffectiveFieldsDuringRead(existingState GcpManagedNetworkConfig) { } -func (a GcpManagedNetworkConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpManagedNetworkConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1026,7 +1026,7 @@ func (newState *GcpNetworkInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Gcp func (newState *GcpNetworkInfo) SyncEffectiveFieldsDuringRead(existingState GcpNetworkInfo) { } -func (a GcpNetworkInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpNetworkInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1065,7 +1065,7 @@ func (newState *GcpVpcEndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GcpVpcEndpointInfo) SyncEffectiveFieldsDuringRead(existingState GcpVpcEndpointInfo) { } -func (a GcpVpcEndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a GcpVpcEndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1093,7 +1093,7 @@ func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialRequest) { } -func (a GetCredentialRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1117,7 +1117,7 @@ func (newState *GetEncryptionKeyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetEncryptionKeyRequest) SyncEffectiveFieldsDuringRead(existingState GetEncryptionKeyRequest) { } -func (a GetEncryptionKeyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1141,7 +1141,7 @@ func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringRead(existingState GetNetworkRequest) { } -func (a GetNetworkRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1165,7 +1165,7 @@ func (newState *GetPrivateAccesRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPrivateAccesRequest) SyncEffectiveFieldsDuringRead(existingState GetPrivateAccesRequest) { } -func (a GetPrivateAccesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1189,7 +1189,7 @@ func (newState *GetStorageRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetStorageRequest) SyncEffectiveFieldsDuringRead(existingState GetStorageRequest) { } -func (a GetStorageRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1213,7 +1213,7 @@ func (newState *GetVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetVpcEndpointRequest) { } -func (a GetVpcEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1237,7 +1237,7 @@ func (newState *GetWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceRequest) { } -func (a GetWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1273,7 +1273,7 @@ func (newState *GkeConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan GkeConfi func (newState *GkeConfig) SyncEffectiveFieldsDuringRead(existingState GkeConfig) { } -func (a GkeConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a GkeConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1328,7 +1328,7 @@ func (newState *Network) SyncEffectiveFieldsDuringCreateOrUpdate(plan Network) { func (newState *Network) SyncEffectiveFieldsDuringRead(existingState Network) { } -func (a Network) GetComplexFieldTypes() map[string]reflect.Type { +func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error_messages": reflect.TypeOf(NetworkHealth{}), "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), @@ -1385,7 +1385,7 @@ func (newState *NetworkHealth) SyncEffectiveFieldsDuringCreateOrUpdate(plan Netw func (newState *NetworkHealth) SyncEffectiveFieldsDuringRead(existingState NetworkHealth) { } -func (a NetworkHealth) GetComplexFieldTypes() map[string]reflect.Type { +func (a NetworkHealth) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1417,7 +1417,7 @@ func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringRead(existingState NetworkVpcEndpoints) { } -func (a NetworkVpcEndpoints) GetComplexFieldTypes() map[string]reflect.Type { +func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataplane_relay": reflect.TypeOf(types.StringType), "rest_api": reflect.TypeOf(types.StringType), @@ -1451,7 +1451,7 @@ func (newState *NetworkWarning) SyncEffectiveFieldsDuringCreateOrUpdate(plan Net func (newState *NetworkWarning) SyncEffectiveFieldsDuringRead(existingState NetworkWarning) { } -func (a NetworkWarning) GetComplexFieldTypes() map[string]reflect.Type { +func (a NetworkWarning) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1497,7 +1497,7 @@ func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringRead(existingState PrivateAccessSettings) { } -func (a PrivateAccessSettings) GetComplexFieldTypes() map[string]reflect.Type { +func (a PrivateAccessSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "allowed_vpc_endpoint_ids": reflect.TypeOf(types.StringType), } @@ -1528,7 +1528,7 @@ func (newState *ReplaceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReplaceResponse) SyncEffectiveFieldsDuringRead(existingState ReplaceResponse) { } -func (a ReplaceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1550,7 +1550,7 @@ func (newState *RootBucketInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Roo func (newState *RootBucketInfo) SyncEffectiveFieldsDuringRead(existingState RootBucketInfo) { } -func (a RootBucketInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RootBucketInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1581,7 +1581,7 @@ func (newState *StorageConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StorageConfiguration) SyncEffectiveFieldsDuringRead(existingState StorageConfiguration) { } -func (a StorageConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a StorageConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "root_bucket_info": reflect.TypeOf(RootBucketInfo{}), } @@ -1615,7 +1615,7 @@ func (newState *StsRole) SyncEffectiveFieldsDuringCreateOrUpdate(plan StsRole) { func (newState *StsRole) SyncEffectiveFieldsDuringRead(existingState StsRole) { } -func (a StsRole) GetComplexFieldTypes() map[string]reflect.Type { +func (a StsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1637,7 +1637,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1688,7 +1688,7 @@ func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceRequest) { } -func (a UpdateWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_tags": reflect.TypeOf(types.StringType), } @@ -1757,7 +1757,7 @@ func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringCre func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringRead(existingState UpsertPrivateAccessSettingsRequest) { } -func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "allowed_vpc_endpoint_ids": reflect.TypeOf(types.StringType), } @@ -1822,7 +1822,7 @@ func (newState *VpcEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan VpcEnd func (newState *VpcEndpoint) SyncEffectiveFieldsDuringRead(existingState VpcEndpoint) { } -func (a VpcEndpoint) GetComplexFieldTypes() map[string]reflect.Type { +func (a VpcEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_vpc_endpoint_info": reflect.TypeOf(GcpVpcEndpointInfo{}), } @@ -1953,7 +1953,7 @@ func (newState *Workspace) SyncEffectiveFieldsDuringCreateOrUpdate(plan Workspac func (newState *Workspace) SyncEffectiveFieldsDuringRead(existingState Workspace) { } -func (a Workspace) GetComplexFieldTypes() map[string]reflect.Type { +func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "azure_workspace_info": reflect.TypeOf(AzureWorkspaceInfo{}), "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 2745943049..4c7f86b5e3 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -41,7 +41,7 @@ func (newState *Ai21LabsConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ai2 func (newState *Ai21LabsConfig) SyncEffectiveFieldsDuringRead(existingState Ai21LabsConfig) { } -func (a Ai21LabsConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a Ai21LabsConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -76,7 +76,7 @@ func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ai func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayConfig) { } -func (a AiGatewayConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), "inference_table_config": reflect.TypeOf(AiGatewayInferenceTableConfig{}), @@ -123,7 +123,7 @@ func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringCreateOrU func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrailParameters) { } -func (a AiGatewayGuardrailParameters) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "invalid_keywords": reflect.TypeOf(types.StringType), "pii": reflect.TypeOf(AiGatewayGuardrailPiiBehavior{}), @@ -164,7 +164,7 @@ func (newState *AiGatewayGuardrailPiiBehavior) SyncEffectiveFieldsDuringCreateOr func (newState *AiGatewayGuardrailPiiBehavior) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrailPiiBehavior) { } -func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -189,7 +189,7 @@ func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrails) { } -func (a AiGatewayGuardrails) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayGuardrails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input": reflect.TypeOf(AiGatewayGuardrailParameters{}), "output": reflect.TypeOf(AiGatewayGuardrailParameters{}), @@ -231,7 +231,7 @@ func (newState *AiGatewayInferenceTableConfig) SyncEffectiveFieldsDuringCreateOr func (newState *AiGatewayInferenceTableConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayInferenceTableConfig) { } -func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -264,7 +264,7 @@ func (newState *AiGatewayRateLimit) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AiGatewayRateLimit) SyncEffectiveFieldsDuringRead(existingState AiGatewayRateLimit) { } -func (a AiGatewayRateLimit) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayRateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -289,7 +289,7 @@ func (newState *AiGatewayUsageTrackingConfig) SyncEffectiveFieldsDuringCreateOrU func (newState *AiGatewayUsageTrackingConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayUsageTrackingConfig) { } -func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -341,7 +341,7 @@ func (newState *AmazonBedrockConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AmazonBedrockConfig) SyncEffectiveFieldsDuringRead(existingState AmazonBedrockConfig) { } -func (a AmazonBedrockConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a AmazonBedrockConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -377,7 +377,7 @@ func (newState *AnthropicConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan An func (newState *AnthropicConfig) SyncEffectiveFieldsDuringRead(existingState AnthropicConfig) { } -func (a AnthropicConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a AnthropicConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -410,7 +410,7 @@ func (newState *AutoCaptureConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AutoCaptureConfigInput) SyncEffectiveFieldsDuringRead(existingState AutoCaptureConfigInput) { } -func (a AutoCaptureConfigInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a AutoCaptureConfigInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -444,7 +444,7 @@ func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringRead(existingState AutoCaptureConfigOutput) { } -func (a AutoCaptureConfigOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a AutoCaptureConfigOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "state": reflect.TypeOf(AutoCaptureState{}), } @@ -474,7 +474,7 @@ func (newState *AutoCaptureState) SyncEffectiveFieldsDuringCreateOrUpdate(plan A func (newState *AutoCaptureState) SyncEffectiveFieldsDuringRead(existingState AutoCaptureState) { } -func (a AutoCaptureState) GetComplexFieldTypes() map[string]reflect.Type { +func (a AutoCaptureState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "payload_table": reflect.TypeOf(PayloadTable{}), } @@ -506,7 +506,7 @@ func (newState *BuildLogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan B func (newState *BuildLogsRequest) SyncEffectiveFieldsDuringRead(existingState BuildLogsRequest) { } -func (a BuildLogsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a BuildLogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -530,7 +530,7 @@ func (newState *BuildLogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *BuildLogsResponse) SyncEffectiveFieldsDuringRead(existingState BuildLogsResponse) { } -func (a BuildLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a BuildLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -555,7 +555,7 @@ func (newState *ChatMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan ChatMe func (newState *ChatMessage) SyncEffectiveFieldsDuringRead(existingState ChatMessage) { } -func (a ChatMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a ChatMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -590,7 +590,7 @@ func (newState *CohereConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Coher func (newState *CohereConfig) SyncEffectiveFieldsDuringRead(existingState CohereConfig) { } -func (a CohereConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a CohereConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -630,7 +630,7 @@ func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringRead(existingState CreateServingEndpoint) { } -func (a CreateServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), "config": reflect.TypeOf(EndpointCoreConfigInput{}), @@ -686,7 +686,7 @@ func (newState *DatabricksModelServingConfig) SyncEffectiveFieldsDuringCreateOrU func (newState *DatabricksModelServingConfig) SyncEffectiveFieldsDuringRead(existingState DatabricksModelServingConfig) { } -func (a DatabricksModelServingConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a DatabricksModelServingConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -714,7 +714,7 @@ func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringRead(existingState DataframeSplitInput) { } -func (a DataframeSplitInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(struct{}{}), "data": reflect.TypeOf(struct{}{}), @@ -747,7 +747,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -769,7 +769,7 @@ func (newState *DeleteServingEndpointRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteServingEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServingEndpointRequest) { } -func (a DeleteServingEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -795,7 +795,7 @@ func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringC func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringRead(existingState EmbeddingsV1ResponseEmbeddingElement) { } -func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes() map[string]reflect.Type { +func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "embedding": reflect.TypeOf(types.Float64Type), } @@ -836,7 +836,7 @@ func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigInput) { } -func (a EndpointCoreConfigInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointCoreConfigInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "auto_capture_config": reflect.TypeOf(AutoCaptureConfigInput{}), "served_entities": reflect.TypeOf(ServedEntityInput{}), @@ -886,7 +886,7 @@ func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigOutput) { } -func (a EndpointCoreConfigOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointCoreConfigOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "auto_capture_config": reflect.TypeOf(AutoCaptureConfigOutput{}), "served_entities": reflect.TypeOf(ServedEntityOutput{}), @@ -929,7 +929,7 @@ func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringCreateOrUpda func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigSummary) { } -func (a EndpointCoreConfigSummary) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointCoreConfigSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "served_entities": reflect.TypeOf(ServedEntitySpec{}), "served_models": reflect.TypeOf(ServedModelSpec{}), @@ -974,7 +974,7 @@ func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringRead(existingState EndpointPendingConfig) { } -func (a EndpointPendingConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointPendingConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "auto_capture_config": reflect.TypeOf(AutoCaptureConfigOutput{}), "served_entities": reflect.TypeOf(ServedEntityOutput{}), @@ -1024,7 +1024,7 @@ func (newState *EndpointState) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endp func (newState *EndpointState) SyncEffectiveFieldsDuringRead(existingState EndpointState) { } -func (a EndpointState) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1050,7 +1050,7 @@ func (newState *EndpointTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpoi func (newState *EndpointTag) SyncEffectiveFieldsDuringRead(existingState EndpointTag) { } -func (a EndpointTag) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1076,7 +1076,7 @@ func (newState *ExportMetricsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExportMetricsRequest) SyncEffectiveFieldsDuringRead(existingState ExportMetricsRequest) { } -func (a ExportMetricsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExportMetricsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1098,7 +1098,7 @@ func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringRead(existingState ExportMetricsResponse) { } -func (a ExportMetricsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExportMetricsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1146,7 +1146,7 @@ func (newState *ExternalModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exte func (newState *ExternalModel) SyncEffectiveFieldsDuringRead(existingState ExternalModel) { } -func (a ExternalModel) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExternalModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai21labs_config": reflect.TypeOf(Ai21LabsConfig{}), "amazon_bedrock_config": reflect.TypeOf(AmazonBedrockConfig{}), @@ -1208,7 +1208,7 @@ func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringRead(existingState ExternalModelUsageElement) { } -func (a ExternalModelUsageElement) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1239,7 +1239,7 @@ func (newState *FoundationModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Fo func (newState *FoundationModel) SyncEffectiveFieldsDuringRead(existingState FoundationModel) { } -func (a FoundationModel) GetComplexFieldTypes() map[string]reflect.Type { +func (a FoundationModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1267,7 +1267,7 @@ func (newState *GetOpenApiRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetOpenApiRequest) SyncEffectiveFieldsDuringRead(existingState GetOpenApiRequest) { } -func (a GetOpenApiRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetOpenApiRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1290,7 +1290,7 @@ func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringRead(existingState GetOpenApiResponse) { } -func (a GetOpenApiResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetOpenApiResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1312,7 +1312,7 @@ func (newState *GetServingEndpointPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetServingEndpointPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionLevelsRequest) { } -func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1335,7 +1335,7 @@ func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionLevelsResponse) { } -func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ServingEndpointPermissionsDescription{}), } @@ -1363,7 +1363,7 @@ func (newState *GetServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionsRequest) { } -func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1387,7 +1387,7 @@ func (newState *GetServingEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetServingEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointRequest) { } -func (a GetServingEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1435,7 +1435,7 @@ func (newState *GoogleCloudVertexAiConfig) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GoogleCloudVertexAiConfig) SyncEffectiveFieldsDuringRead(existingState GoogleCloudVertexAiConfig) { } -func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1461,7 +1461,7 @@ func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringRead(existingState ListEndpointsResponse) { } -func (a ListEndpointsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListEndpointsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "endpoints": reflect.TypeOf(ServingEndpoint{}), } @@ -1493,7 +1493,7 @@ func (newState *LogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogsRe func (newState *LogsRequest) SyncEffectiveFieldsDuringRead(existingState LogsRequest) { } -func (a LogsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a LogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1517,7 +1517,7 @@ func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState ModelDataPlaneInfo) { } -func (a ModelDataPlaneInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ModelDataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query_info": reflect.TypeOf(oauth2.DataPlaneInfo{}), } @@ -1593,7 +1593,7 @@ func (newState *OpenAiConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan OpenA func (newState *OpenAiConfig) SyncEffectiveFieldsDuringRead(existingState OpenAiConfig) { } -func (a OpenAiConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a OpenAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1634,7 +1634,7 @@ func (newState *PaLmConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan PaLmCon func (newState *PaLmConfig) SyncEffectiveFieldsDuringRead(existingState PaLmConfig) { } -func (a PaLmConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a PaLmConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1663,7 +1663,7 @@ func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringRead(existingState PatchServingEndpointTags) { } -func (a PatchServingEndpointTags) GetComplexFieldTypes() map[string]reflect.Type { +func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add_tags": reflect.TypeOf(EndpointTag{}), "delete_tags": reflect.TypeOf(types.StringType), @@ -1699,7 +1699,7 @@ func (newState *PayloadTable) SyncEffectiveFieldsDuringCreateOrUpdate(plan Paylo func (newState *PayloadTable) SyncEffectiveFieldsDuringRead(existingState PayloadTable) { } -func (a PayloadTable) GetComplexFieldTypes() map[string]reflect.Type { +func (a PayloadTable) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1739,7 +1739,7 @@ func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringRead(existingState PutAiGatewayRequest) { } -func (a PutAiGatewayRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutAiGatewayRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), "inference_table_config": reflect.TypeOf(AiGatewayInferenceTableConfig{}), @@ -1790,7 +1790,7 @@ func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringRead(existingState PutAiGatewayResponse) { } -func (a PutAiGatewayResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutAiGatewayResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), "inference_table_config": reflect.TypeOf(AiGatewayInferenceTableConfig{}), @@ -1833,7 +1833,7 @@ func (newState *PutRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRequ func (newState *PutRequest) SyncEffectiveFieldsDuringRead(existingState PutRequest) { } -func (a PutRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rate_limits": reflect.TypeOf(RateLimit{}), } @@ -1861,7 +1861,7 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRes func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResponse) { } -func (a PutResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rate_limits": reflect.TypeOf(RateLimit{}), } @@ -1935,7 +1935,7 @@ func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringRead(existingState QueryEndpointInput) { } -func (a QueryEndpointInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataframe_records": reflect.TypeOf(struct{}{}), "dataframe_split": reflect.TypeOf(DataframeSplitInput{}), @@ -2016,7 +2016,7 @@ func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringRead(existingState QueryEndpointResponse) { } -func (a QueryEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "choices": reflect.TypeOf(V1ResponseChoiceElement{}), "data": reflect.TypeOf(EmbeddingsV1ResponseEmbeddingElement{}), @@ -2068,7 +2068,7 @@ func (newState *RateLimit) SyncEffectiveFieldsDuringCreateOrUpdate(plan RateLimi func (newState *RateLimit) SyncEffectiveFieldsDuringRead(existingState RateLimit) { } -func (a RateLimit) GetComplexFieldTypes() map[string]reflect.Type { +func (a RateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2096,7 +2096,7 @@ func (newState *Route) SyncEffectiveFieldsDuringCreateOrUpdate(plan Route) { func (newState *Route) SyncEffectiveFieldsDuringRead(existingState Route) { } -func (a Route) GetComplexFieldTypes() map[string]reflect.Type { +func (a Route) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2176,7 +2176,7 @@ func (newState *ServedEntityInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedEntityInput) SyncEffectiveFieldsDuringRead(existingState ServedEntityInput) { } -func (a ServedEntityInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.StringType), "external_model": reflect.TypeOf(ExternalModel{}), @@ -2274,7 +2274,7 @@ func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringRead(existingState ServedEntityOutput) { } -func (a ServedEntityOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.StringType), "external_model": reflect.TypeOf(ExternalModel{}), @@ -2341,7 +2341,7 @@ func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringRead(existingState ServedEntitySpec) { } -func (a ServedEntitySpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "external_model": reflect.TypeOf(ExternalModel{}), "foundation_model": reflect.TypeOf(FoundationModel{}), @@ -2418,7 +2418,7 @@ func (newState *ServedModelInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedModelInput) SyncEffectiveFieldsDuringRead(existingState ServedModelInput) { } -func (a ServedModelInput) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedModelInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.StringType), } @@ -2495,7 +2495,7 @@ func (newState *ServedModelOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedModelOutput) SyncEffectiveFieldsDuringRead(existingState ServedModelOutput) { } -func (a ServedModelOutput) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.StringType), "state": reflect.TypeOf(ServedModelState{}), @@ -2541,7 +2541,7 @@ func (newState *ServedModelSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Se func (newState *ServedModelSpec) SyncEffectiveFieldsDuringRead(existingState ServedModelSpec) { } -func (a ServedModelSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedModelSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2579,7 +2579,7 @@ func (newState *ServedModelState) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedModelState) SyncEffectiveFieldsDuringRead(existingState ServedModelState) { } -func (a ServedModelState) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServedModelState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2604,7 +2604,7 @@ func (newState *ServerLogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServerLogsResponse) SyncEffectiveFieldsDuringRead(existingState ServerLogsResponse) { } -func (a ServerLogsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServerLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2647,7 +2647,7 @@ func (newState *ServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Se func (newState *ServingEndpoint) SyncEffectiveFieldsDuringRead(existingState ServingEndpoint) { } -func (a ServingEndpoint) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), "config": reflect.TypeOf(EndpointCoreConfigSummary{}), @@ -2698,7 +2698,7 @@ func (newState *ServingEndpointAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *ServingEndpointAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ServingEndpointAccessControlRequest) { } -func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2732,7 +2732,7 @@ func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ServingEndpointAccessControlResponse) { } -func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ServingEndpointPermission{}), } @@ -2794,7 +2794,7 @@ func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringRead(existingState ServingEndpointDetailed) { } -func (a ServingEndpointDetailed) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointDetailed) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), "config": reflect.TypeOf(EndpointCoreConfigOutput{}), @@ -2853,7 +2853,7 @@ func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermission) { } -func (a ServingEndpointPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -2885,7 +2885,7 @@ func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissions) { } -func (a ServingEndpointPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ServingEndpointAccessControlResponse{}), } @@ -2915,7 +2915,7 @@ func (newState *ServingEndpointPermissionsDescription) SyncEffectiveFieldsDuring func (newState *ServingEndpointPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissionsDescription) { } -func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2940,7 +2940,7 @@ func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissionsRequest) { } -func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ServingEndpointAccessControlRequest{}), } @@ -2968,7 +2968,7 @@ func (newState *TrafficConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Traf func (newState *TrafficConfig) SyncEffectiveFieldsDuringRead(existingState TrafficConfig) { } -func (a TrafficConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a TrafficConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "routes": reflect.TypeOf(Route{}), } @@ -3003,7 +3003,7 @@ func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringRead(existingState V1ResponseChoiceElement) { } -func (a V1ResponseChoiceElement) GetComplexFieldTypes() map[string]reflect.Type { +func (a V1ResponseChoiceElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "message": reflect.TypeOf(ChatMessage{}), } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 7c9309030a..db08297202 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -29,7 +29,7 @@ func (newState *AibiDashboardEmbeddingAccessPolicy) SyncEffectiveFieldsDuringCre func (newState *AibiDashboardEmbeddingAccessPolicy) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingAccessPolicy) { } -func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes() map[string]reflect.Type { +func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -65,7 +65,7 @@ func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDu func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingAccessPolicySetting) { } -func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aibi_dashboard_embedding_access_policy": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicy{}), } @@ -93,7 +93,7 @@ func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuring func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingApprovedDomains) { } -func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes() map[string]reflect.Type { +func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "approved_domains": reflect.TypeOf(types.StringType), } @@ -133,7 +133,7 @@ func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveField func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingApprovedDomainsSetting) { } -func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aibi_dashboard_embedding_approved_domains": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomains{}), } @@ -175,7 +175,7 @@ func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringCreateOr func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringRead(existingState AutomaticClusterUpdateSetting) { } -func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "automatic_cluster_update_workspace": reflect.TypeOf(ClusterAutoRestartMessage{}), } @@ -203,7 +203,7 @@ func (newState *BooleanMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Boo func (newState *BooleanMessage) SyncEffectiveFieldsDuringRead(existingState BooleanMessage) { } -func (a BooleanMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a BooleanMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -238,7 +238,7 @@ func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessage) { } -func (a ClusterAutoRestartMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAutoRestartMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "enablement_details": reflect.TypeOf(ClusterAutoRestartMessageEnablementDetails{}), "maintenance_window": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindow{}), @@ -283,7 +283,7 @@ func (newState *ClusterAutoRestartMessageEnablementDetails) SyncEffectiveFieldsD func (newState *ClusterAutoRestartMessageEnablementDetails) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageEnablementDetails) { } -func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -307,7 +307,7 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsD func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindow) { } -func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "week_day_based_schedule": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}), } @@ -337,7 +337,7 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) { } -func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "window_start_time": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}), } @@ -367,7 +367,7 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) SyncE func (newState *ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) { } -func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFieldTypes() map[string]reflect.Type { +func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -394,7 +394,7 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existingState ComplianceSecurityProfile) { } -func (a ComplianceSecurityProfile) GetComplexFieldTypes() map[string]reflect.Type { +func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "compliance_standards": reflect.TypeOf(types.StringType), } @@ -436,7 +436,7 @@ func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringCreat func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringRead(existingState ComplianceSecurityProfileSetting) { } -func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "compliance_security_profile_workspace": reflect.TypeOf(ComplianceSecurityProfile{}), } @@ -472,7 +472,7 @@ func (newState *Config) SyncEffectiveFieldsDuringCreateOrUpdate(plan Config) { func (newState *Config) SyncEffectiveFieldsDuringRead(existingState Config) { } -func (a Config) GetComplexFieldTypes() map[string]reflect.Type { +func (a Config) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "email": reflect.TypeOf(EmailConfig{}), "generic_webhook": reflect.TypeOf(GenericWebhookConfig{}), @@ -524,7 +524,7 @@ func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringRead(existingState CreateIpAccessList) { } -func (a CreateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.StringType), } @@ -554,7 +554,7 @@ func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState CreateIpAccessListResponse) { } -func (a CreateIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } @@ -588,7 +588,7 @@ func (newState *CreateNetworkConnectivityConfigRequest) SyncEffectiveFieldsDurin func (newState *CreateNetworkConnectivityConfigRequest) SyncEffectiveFieldsDuringRead(existingState CreateNetworkConnectivityConfigRequest) { } -func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -615,7 +615,7 @@ func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState CreateNotificationDestinationRequest) { } -func (a CreateNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(Config{}), } @@ -648,7 +648,7 @@ func (newState *CreateOboTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateOboTokenRequest) SyncEffectiveFieldsDuringRead(existingState CreateOboTokenRequest) { } -func (a CreateOboTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateOboTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -675,7 +675,7 @@ func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringRead(existingState CreateOboTokenResponse) { } -func (a CreateOboTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateOboTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_info": reflect.TypeOf(TokenInfo{}), } @@ -709,7 +709,7 @@ func (newState *CreatePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreat func (newState *CreatePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState CreatePrivateEndpointRuleRequest) { } -func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -738,7 +738,7 @@ func (newState *CreateTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateTokenRequest) SyncEffectiveFieldsDuringRead(existingState CreateTokenRequest) { } -func (a CreateTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -764,7 +764,7 @@ func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringRead(existingState CreateTokenResponse) { } -func (a CreateTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_info": reflect.TypeOf(PublicTokenInfo{}), } @@ -796,7 +796,7 @@ func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringRead(existingState CspEnablementAccount) { } -func (a CspEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { +func (a CspEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "compliance_standards": reflect.TypeOf(types.StringType), } @@ -838,7 +838,7 @@ func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringCreateOrUp func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringRead(existingState CspEnablementAccountSetting) { } -func (a CspEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a CspEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "csp_enablement_account": reflect.TypeOf(CspEnablementAccount{}), } @@ -890,7 +890,7 @@ func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringRead(existingState DefaultNamespaceSetting) { } -func (a DefaultNamespaceSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a DefaultNamespaceSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "namespace": reflect.TypeOf(StringMessage{}), } @@ -920,7 +920,7 @@ func (newState *DeleteAccountIpAccessListRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteAccountIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountIpAccessListRequest) { } -func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -950,7 +950,7 @@ func (newState *DeleteDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringC func (newState *DeleteDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDefaultNamespaceSettingRequest) { } -func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -980,7 +980,7 @@ func (newState *DeleteDefaultNamespaceSettingResponse) SyncEffectiveFieldsDuring func (newState *DeleteDefaultNamespaceSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDefaultNamespaceSettingResponse) { } -func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1010,7 +1010,7 @@ func (newState *DeleteDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyAccessRequest) { } -func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1040,7 +1040,7 @@ func (newState *DeleteDisableLegacyAccessResponse) SyncEffectiveFieldsDuringCrea func (newState *DeleteDisableLegacyAccessResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyAccessResponse) { } -func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1070,7 +1070,7 @@ func (newState *DeleteDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyDbfsRequest) { } -func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1100,7 +1100,7 @@ func (newState *DeleteDisableLegacyDbfsResponse) SyncEffectiveFieldsDuringCreate func (newState *DeleteDisableLegacyDbfsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyDbfsResponse) { } -func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1130,7 +1130,7 @@ func (newState *DeleteDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCre func (newState *DeleteDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyFeaturesRequest) { } -func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1160,7 +1160,7 @@ func (newState *DeleteDisableLegacyFeaturesResponse) SyncEffectiveFieldsDuringCr func (newState *DeleteDisableLegacyFeaturesResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyFeaturesResponse) { } -func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1184,7 +1184,7 @@ func (newState *DeleteIpAccessListRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState DeleteIpAccessListRequest) { } -func (a DeleteIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1208,7 +1208,7 @@ func (newState *DeleteNetworkConnectivityConfigurationRequest) SyncEffectiveFiel func (newState *DeleteNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkConnectivityConfigurationRequest) { } -func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1229,7 +1229,7 @@ func (newState *DeleteNetworkConnectivityConfigurationResponse) SyncEffectiveFie func (newState *DeleteNetworkConnectivityConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkConnectivityConfigurationResponse) { } -func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1250,7 +1250,7 @@ func (newState *DeleteNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *DeleteNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNotificationDestinationRequest) { } -func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1280,7 +1280,7 @@ func (newState *DeletePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCr func (newState *DeletePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeletePersonalComputeSettingRequest) { } -func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1310,7 +1310,7 @@ func (newState *DeletePersonalComputeSettingResponse) SyncEffectiveFieldsDuringC func (newState *DeletePersonalComputeSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeletePersonalComputeSettingResponse) { } -func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1336,7 +1336,7 @@ func (newState *DeletePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreat func (newState *DeletePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState DeletePrivateEndpointRuleRequest) { } -func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1358,7 +1358,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1386,7 +1386,7 @@ func (newState *DeleteRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (newState *DeleteRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRestrictWorkspaceAdminsSettingRequest) { } -func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1416,7 +1416,7 @@ func (newState *DeleteRestrictWorkspaceAdminsSettingResponse) SyncEffectiveField func (newState *DeleteRestrictWorkspaceAdminsSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRestrictWorkspaceAdminsSettingResponse) { } -func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1440,7 +1440,7 @@ func (newState *DeleteTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTokenManagementRequest) { } -func (a DeleteTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1476,7 +1476,7 @@ func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringRead(existingState DisableLegacyAccess) { } -func (a DisableLegacyAccess) GetComplexFieldTypes() map[string]reflect.Type { +func (a DisableLegacyAccess) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disable_legacy_access": reflect.TypeOf(BooleanMessage{}), } @@ -1518,7 +1518,7 @@ func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringRead(existingState DisableLegacyDbfs) { } -func (a DisableLegacyDbfs) GetComplexFieldTypes() map[string]reflect.Type { +func (a DisableLegacyDbfs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disable_legacy_dbfs": reflect.TypeOf(BooleanMessage{}), } @@ -1560,7 +1560,7 @@ func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringRead(existingState DisableLegacyFeatures) { } -func (a DisableLegacyFeatures) GetComplexFieldTypes() map[string]reflect.Type { +func (a DisableLegacyFeatures) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disable_legacy_features": reflect.TypeOf(BooleanMessage{}), } @@ -1589,7 +1589,7 @@ func (newState *EmailConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan EmailC func (newState *EmailConfig) SyncEffectiveFieldsDuringRead(existingState EmailConfig) { } -func (a EmailConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a EmailConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "addresses": reflect.TypeOf(types.StringType), } @@ -1614,7 +1614,7 @@ func (newState *Empty) SyncEffectiveFieldsDuringCreateOrUpdate(plan Empty) { func (newState *Empty) SyncEffectiveFieldsDuringRead(existingState Empty) { } -func (a Empty) GetComplexFieldTypes() map[string]reflect.Type { +func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1635,7 +1635,7 @@ func (newState *EnhancedSecurityMonitoring) SyncEffectiveFieldsDuringCreateOrUpd func (newState *EnhancedSecurityMonitoring) SyncEffectiveFieldsDuringRead(existingState EnhancedSecurityMonitoring) { } -func (a EnhancedSecurityMonitoring) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnhancedSecurityMonitoring) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1672,7 +1672,7 @@ func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringCrea func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringRead(existingState EnhancedSecurityMonitoringSetting) { } -func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "enhanced_security_monitoring_workspace": reflect.TypeOf(EnhancedSecurityMonitoring{}), } @@ -1701,7 +1701,7 @@ func (newState *EsmEnablementAccount) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EsmEnablementAccount) SyncEffectiveFieldsDuringRead(existingState EsmEnablementAccount) { } -func (a EsmEnablementAccount) GetComplexFieldTypes() map[string]reflect.Type { +func (a EsmEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1738,7 +1738,7 @@ func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringCreateOrUp func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringRead(existingState EsmEnablementAccountSetting) { } -func (a EsmEnablementAccountSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a EsmEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "esm_enablement_account": reflect.TypeOf(EsmEnablementAccount{}), } @@ -1777,7 +1777,7 @@ func (newState *ExchangeToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exch func (newState *ExchangeToken) SyncEffectiveFieldsDuringRead(existingState ExchangeToken) { } -func (a ExchangeToken) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExchangeToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "scopes": reflect.TypeOf(types.StringType), } @@ -1813,7 +1813,7 @@ func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringRead(existingState ExchangeTokenRequest) { } -func (a ExchangeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "partitionId": reflect.TypeOf(PartitionId{}), "scopes": reflect.TypeOf(types.StringType), @@ -1848,7 +1848,7 @@ func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringRead(existingState ExchangeTokenResponse) { } -func (a ExchangeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExchangeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(ExchangeToken{}), } @@ -1876,7 +1876,7 @@ func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState FetchIpAccessListResponse) { } -func (a FetchIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a FetchIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } @@ -1913,7 +1913,7 @@ func (newState *GenericWebhookConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GenericWebhookConfig) SyncEffectiveFieldsDuringRead(existingState GenericWebhookConfig) { } -func (a GenericWebhookConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a GenericWebhookConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1942,7 +1942,7 @@ func (newState *GetAccountIpAccessListRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetAccountIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountIpAccessListRequest) { } -func (a GetAccountIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1972,7 +1972,7 @@ func (newState *GetAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffecti func (newState *GetAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAibiDashboardEmbeddingAccessPolicySettingRequest) { } -func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2002,7 +2002,7 @@ func (newState *GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffe func (newState *GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) { } -func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2032,7 +2032,7 @@ func (newState *GetAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuri func (newState *GetAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAutomaticClusterUpdateSettingRequest) { } -func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2062,7 +2062,7 @@ func (newState *GetComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsD func (newState *GetComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetComplianceSecurityProfileSettingRequest) { } -func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2092,7 +2092,7 @@ func (newState *GetCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuring func (newState *GetCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetCspEnablementAccountSettingRequest) { } -func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2122,7 +2122,7 @@ func (newState *GetDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringCrea func (newState *GetDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetDefaultNamespaceSettingRequest) { } -func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2152,7 +2152,7 @@ func (newState *GetDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyAccessRequest) { } -func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2182,7 +2182,7 @@ func (newState *GetDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyDbfsRequest) { } -func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2212,7 +2212,7 @@ func (newState *GetDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCreate func (newState *GetDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyFeaturesRequest) { } -func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2242,7 +2242,7 @@ func (newState *GetEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFields func (newState *GetEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetEnhancedSecurityMonitoringSettingRequest) { } -func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2272,7 +2272,7 @@ func (newState *GetEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuring func (newState *GetEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetEsmEnablementAccountSettingRequest) { } -func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2296,7 +2296,7 @@ func (newState *GetIpAccessListRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListRequest) { } -func (a GetIpAccessListRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2319,7 +2319,7 @@ func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListResponse) { } -func (a GetIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } @@ -2346,7 +2346,7 @@ func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListsResponse) { } -func (a GetIpAccessListsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetIpAccessListsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_lists": reflect.TypeOf(IpAccessListInfo{}), } @@ -2374,7 +2374,7 @@ func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsD func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState GetNetworkConnectivityConfigurationRequest) { } -func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2397,7 +2397,7 @@ func (newState *GetNotificationDestinationRequest) SyncEffectiveFieldsDuringCrea func (newState *GetNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState GetNotificationDestinationRequest) { } -func (a GetNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2427,7 +2427,7 @@ func (newState *GetPersonalComputeSettingRequest) SyncEffectiveFieldsDuringCreat func (newState *GetPersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetPersonalComputeSettingRequest) { } -func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2453,7 +2453,7 @@ func (newState *GetPrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetPrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState GetPrivateEndpointRuleRequest) { } -func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2484,7 +2484,7 @@ func (newState *GetRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDur func (newState *GetRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetRestrictWorkspaceAdminsSettingRequest) { } -func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2507,7 +2507,7 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } -func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2531,7 +2531,7 @@ func (newState *GetTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState GetTokenManagementRequest) { } -func (a GetTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2554,7 +2554,7 @@ func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringCreat func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetTokenPermissionLevelsResponse) { } -func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(TokenPermissionsDescription{}), } @@ -2581,7 +2581,7 @@ func (newState *GetTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetTokenResponse) SyncEffectiveFieldsDuringRead(existingState GetTokenResponse) { } -func (a GetTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_info": reflect.TypeOf(TokenInfo{}), } @@ -2632,7 +2632,7 @@ func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan I func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringRead(existingState IpAccessListInfo) { } -func (a IpAccessListInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a IpAccessListInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.StringType), } @@ -2668,7 +2668,7 @@ func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState ListIpAccessListResponse) { } -func (a ListIpAccessListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_lists": reflect.TypeOf(IpAccessListInfo{}), } @@ -2697,7 +2697,7 @@ func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDur func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDuringRead(existingState ListNccAzurePrivateEndpointRulesResponse) { } -func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "items": reflect.TypeOf(NccAzurePrivateEndpointRule{}), } @@ -2726,7 +2726,7 @@ func (newState *ListNetworkConnectivityConfigurationsRequest) SyncEffectiveField func (newState *ListNetworkConnectivityConfigurationsRequest) SyncEffectiveFieldsDuringRead(existingState ListNetworkConnectivityConfigurationsRequest) { } -func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2751,7 +2751,7 @@ func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFiel func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFieldsDuringRead(existingState ListNetworkConnectivityConfigurationsResponse) { } -func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "items": reflect.TypeOf(NetworkConnectivityConfiguration{}), } @@ -2781,7 +2781,7 @@ func (newState *ListNotificationDestinationsRequest) SyncEffectiveFieldsDuringCr func (newState *ListNotificationDestinationsRequest) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsRequest) { } -func (a ListNotificationDestinationsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNotificationDestinationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2807,7 +2807,7 @@ func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringC func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResponse) { } -func (a ListNotificationDestinationsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNotificationDestinationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ListNotificationDestinationsResult{}), } @@ -2840,7 +2840,7 @@ func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringCre func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResult) { } -func (a ListNotificationDestinationsResult) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListNotificationDestinationsResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2868,7 +2868,7 @@ func (newState *ListPrivateEndpointRulesRequest) SyncEffectiveFieldsDuringCreate func (newState *ListPrivateEndpointRulesRequest) SyncEffectiveFieldsDuringRead(existingState ListPrivateEndpointRulesRequest) { } -func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2892,7 +2892,7 @@ func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringRead(existingState ListPublicTokensResponse) { } -func (a ListPublicTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListPublicTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_infos": reflect.TypeOf(PublicTokenInfo{}), } @@ -2922,7 +2922,7 @@ func (newState *ListTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState ListTokenManagementRequest) { } -func (a ListTokenManagementRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2947,7 +2947,7 @@ func (newState *ListTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTokensResponse) SyncEffectiveFieldsDuringRead(existingState ListTokensResponse) { } -func (a ListTokensResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_infos": reflect.TypeOf(TokenInfo{}), } @@ -2976,7 +2976,7 @@ func (newState *MicrosoftTeamsConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *MicrosoftTeamsConfig) SyncEffectiveFieldsDuringRead(existingState MicrosoftTeamsConfig) { } -func (a MicrosoftTeamsConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a MicrosoftTeamsConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3003,7 +3003,7 @@ func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringRead(existingState NccAwsStableIpRule) { } -func (a NccAwsStableIpRule) GetComplexFieldTypes() map[string]reflect.Type { +func (a NccAwsStableIpRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cidr_blocks": reflect.TypeOf(types.StringType), } @@ -3063,7 +3063,7 @@ func (newState *NccAzurePrivateEndpointRule) SyncEffectiveFieldsDuringCreateOrUp func (newState *NccAzurePrivateEndpointRule) SyncEffectiveFieldsDuringRead(existingState NccAzurePrivateEndpointRule) { } -func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes() map[string]reflect.Type { +func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3103,7 +3103,7 @@ func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringCreateOrUp func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringRead(existingState NccAzureServiceEndpointRule) { } -func (a NccAzureServiceEndpointRule) GetComplexFieldTypes() map[string]reflect.Type { +func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subnets": reflect.TypeOf(types.StringType), "target_services": reflect.TypeOf(types.StringType), @@ -3142,7 +3142,7 @@ func (newState *NccEgressConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Nc func (newState *NccEgressConfig) SyncEffectiveFieldsDuringRead(existingState NccEgressConfig) { } -func (a NccEgressConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a NccEgressConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "default_rules": reflect.TypeOf(NccEgressDefaultRules{}), "target_rules": reflect.TypeOf(NccEgressTargetRules{}), @@ -3182,7 +3182,7 @@ func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringRead(existingState NccEgressDefaultRules) { } -func (a NccEgressDefaultRules) GetComplexFieldTypes() map[string]reflect.Type { +func (a NccEgressDefaultRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_stable_ip_rule": reflect.TypeOf(NccAwsStableIpRule{}), "azure_service_endpoint_rule": reflect.TypeOf(NccAzureServiceEndpointRule{}), @@ -3214,7 +3214,7 @@ func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringRead(existingState NccEgressTargetRules) { } -func (a NccEgressTargetRules) GetComplexFieldTypes() map[string]reflect.Type { +func (a NccEgressTargetRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "azure_private_endpoint_rules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), } @@ -3259,7 +3259,7 @@ func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringCreat func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringRead(existingState NetworkConnectivityConfiguration) { } -func (a NetworkConnectivityConfiguration) GetComplexFieldTypes() map[string]reflect.Type { +func (a NetworkConnectivityConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "egress_config": reflect.TypeOf(NccEgressConfig{}), } @@ -3301,7 +3301,7 @@ func (newState *NotificationDestination) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *NotificationDestination) SyncEffectiveFieldsDuringRead(existingState NotificationDestination) { } -func (a NotificationDestination) GetComplexFieldTypes() map[string]reflect.Type { +func (a NotificationDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(Config{}), } @@ -3333,7 +3333,7 @@ func (newState *PagerdutyConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pa func (newState *PagerdutyConfig) SyncEffectiveFieldsDuringRead(existingState PagerdutyConfig) { } -func (a PagerdutyConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a PagerdutyConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3358,7 +3358,7 @@ func (newState *PartitionId) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partit func (newState *PartitionId) SyncEffectiveFieldsDuringRead(existingState PartitionId) { } -func (a PartitionId) GetComplexFieldTypes() map[string]reflect.Type { +func (a PartitionId) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3387,7 +3387,7 @@ func (newState *PersonalComputeMessage) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalComputeMessage) SyncEffectiveFieldsDuringRead(existingState PersonalComputeMessage) { } -func (a PersonalComputeMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a PersonalComputeMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3424,7 +3424,7 @@ func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringRead(existingState PersonalComputeSetting) { } -func (a PersonalComputeSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a PersonalComputeSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "personal_compute": reflect.TypeOf(PersonalComputeMessage{}), } @@ -3460,7 +3460,7 @@ func (newState *PublicTokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pu func (newState *PublicTokenInfo) SyncEffectiveFieldsDuringRead(existingState PublicTokenInfo) { } -func (a PublicTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a PublicTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3500,7 +3500,7 @@ func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringRead(existingState ReplaceIpAccessList) { } -func (a ReplaceIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReplaceIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.StringType), } @@ -3529,7 +3529,7 @@ func (newState *ReplaceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReplaceResponse) SyncEffectiveFieldsDuringRead(existingState ReplaceResponse) { } -func (a ReplaceResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3549,7 +3549,7 @@ func (newState *RestrictWorkspaceAdminsMessage) SyncEffectiveFieldsDuringCreateO func (newState *RestrictWorkspaceAdminsMessage) SyncEffectiveFieldsDuringRead(existingState RestrictWorkspaceAdminsMessage) { } -func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3586,7 +3586,7 @@ func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringCreateO func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringRead(existingState RestrictWorkspaceAdminsSetting) { } -func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "restrict_workspace_admins": reflect.TypeOf(RestrictWorkspaceAdminsMessage{}), } @@ -3615,7 +3615,7 @@ func (newState *RevokeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RevokeTokenRequest) SyncEffectiveFieldsDuringRead(existingState RevokeTokenRequest) { } -func (a RevokeTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RevokeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3636,7 +3636,7 @@ func (newState *RevokeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RevokeTokenResponse) SyncEffectiveFieldsDuringRead(existingState RevokeTokenResponse) { } -func (a RevokeTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RevokeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3655,7 +3655,7 @@ func (newState *SetStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SetStatusResponse) SyncEffectiveFieldsDuringRead(existingState SetStatusResponse) { } -func (a SetStatusResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3678,7 +3678,7 @@ func (newState *SlackConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan SlackC func (newState *SlackConfig) SyncEffectiveFieldsDuringRead(existingState SlackConfig) { } -func (a SlackConfig) GetComplexFieldTypes() map[string]reflect.Type { +func (a SlackConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3702,7 +3702,7 @@ func (newState *StringMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Stri func (newState *StringMessage) SyncEffectiveFieldsDuringRead(existingState StringMessage) { } -func (a StringMessage) GetComplexFieldTypes() map[string]reflect.Type { +func (a StringMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3731,7 +3731,7 @@ func (newState *TokenAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *TokenAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState TokenAccessControlRequest) { } -func (a TokenAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3765,7 +3765,7 @@ func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState TokenAccessControlResponse) { } -func (a TokenAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(TokenPermission{}), } @@ -3814,7 +3814,7 @@ func (newState *TokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenInf func (newState *TokenInfo) SyncEffectiveFieldsDuringRead(existingState TokenInfo) { } -func (a TokenInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3848,7 +3848,7 @@ func (newState *TokenPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan To func (newState *TokenPermission) SyncEffectiveFieldsDuringRead(existingState TokenPermission) { } -func (a TokenPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -3880,7 +3880,7 @@ func (newState *TokenPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan T func (newState *TokenPermissions) SyncEffectiveFieldsDuringRead(existingState TokenPermissions) { } -func (a TokenPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(TokenAccessControlResponse{}), } @@ -3910,7 +3910,7 @@ func (newState *TokenPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUp func (newState *TokenPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState TokenPermissionsDescription) { } -func (a TokenPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3933,7 +3933,7 @@ func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState TokenPermissionsRequest) { } -func (a TokenPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TokenPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(TokenAccessControlRequest{}), } @@ -3969,7 +3969,7 @@ func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffe func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) { } -func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicySetting{}), } @@ -4007,7 +4007,7 @@ func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncE func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) { } -func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomainsSetting{}), } @@ -4045,7 +4045,7 @@ func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsD func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAutomaticClusterUpdateSettingRequest) { } -func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(AutomaticClusterUpdateSetting{}), } @@ -4083,7 +4083,7 @@ func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFiel func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateComplianceSecurityProfileSettingRequest) { } -func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(ComplianceSecurityProfileSetting{}), } @@ -4121,7 +4121,7 @@ func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCspEnablementAccountSettingRequest) { } -func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(CspEnablementAccountSetting{}), } @@ -4167,7 +4167,7 @@ func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringC func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDefaultNamespaceSettingRequest) { } -func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DefaultNamespaceSetting{}), } @@ -4205,7 +4205,7 @@ func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreat func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyAccessRequest) { } -func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DisableLegacyAccess{}), } @@ -4243,7 +4243,7 @@ func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateO func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyDbfsRequest) { } -func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DisableLegacyDbfs{}), } @@ -4281,7 +4281,7 @@ func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCre func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyFeaturesRequest) { } -func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DisableLegacyFeatures{}), } @@ -4319,7 +4319,7 @@ func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFie func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateEnhancedSecurityMonitoringSettingRequest) { } -func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(EnhancedSecurityMonitoringSetting{}), } @@ -4357,7 +4357,7 @@ func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateEsmEnablementAccountSettingRequest) { } -func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(EsmEnablementAccountSetting{}), } @@ -4400,7 +4400,7 @@ func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringRead(existingState UpdateIpAccessList) { } -func (a UpdateIpAccessList) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.StringType), } @@ -4436,7 +4436,7 @@ func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateNotificationDestinationRequest) { } -func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(Config{}), } @@ -4474,7 +4474,7 @@ func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCr func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalComputeSettingRequest) { } -func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(PersonalComputeSetting{}), } @@ -4501,7 +4501,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4531,7 +4531,7 @@ func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRestrictWorkspaceAdminsSettingRequest) { } -func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(RestrictWorkspaceAdminsSetting{}), } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index d30ae49365..ba18fa4a14 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -39,7 +39,7 @@ func (newState *CreateProvider) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateProvider) SyncEffectiveFieldsDuringRead(existingState CreateProvider) { } -func (a CreateProvider) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateProvider) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -85,7 +85,7 @@ func (newState *CreateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cr func (newState *CreateRecipient) SyncEffectiveFieldsDuringRead(existingState CreateRecipient) { } -func (a CreateRecipient) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessList{}), "properties_kvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), @@ -127,7 +127,7 @@ func (newState *CreateShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateShare) SyncEffectiveFieldsDuringRead(existingState CreateShare) { } -func (a CreateShare) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -153,7 +153,7 @@ func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringRead(existingState DeleteProviderRequest) { } -func (a DeleteProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -177,7 +177,7 @@ func (newState *DeleteRecipientRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteRecipientRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRecipientRequest) { } -func (a DeleteRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -198,7 +198,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -220,7 +220,7 @@ func (newState *DeleteShareRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteShareRequest) SyncEffectiveFieldsDuringRead(existingState DeleteShareRequest) { } -func (a DeleteShareRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -244,7 +244,7 @@ func (newState *GetActivationUrlInfoRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetActivationUrlInfoRequest) SyncEffectiveFieldsDuringRead(existingState GetActivationUrlInfoRequest) { } -func (a GetActivationUrlInfoRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetActivationUrlInfoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -265,7 +265,7 @@ func (newState *GetActivationUrlInfoResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetActivationUrlInfoResponse) SyncEffectiveFieldsDuringRead(existingState GetActivationUrlInfoResponse) { } -func (a GetActivationUrlInfoResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetActivationUrlInfoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -287,7 +287,7 @@ func (newState *GetProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetProviderRequest) SyncEffectiveFieldsDuringRead(existingState GetProviderRequest) { } -func (a GetProviderRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -311,7 +311,7 @@ func (newState *GetRecipientRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetRecipientRequest) SyncEffectiveFieldsDuringRead(existingState GetRecipientRequest) { } -func (a GetRecipientRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -338,7 +338,7 @@ func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringC func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState GetRecipientSharePermissionsResponse) { } -func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions_out": reflect.TypeOf(ShareToPrivilegeAssignment{}), } @@ -369,7 +369,7 @@ func (newState *GetShareRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetShareRequest) SyncEffectiveFieldsDuringRead(existingState GetShareRequest) { } -func (a GetShareRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -393,7 +393,7 @@ func (newState *IpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan IpAcc func (newState *IpAccessList) SyncEffectiveFieldsDuringRead(existingState IpAccessList) { } -func (a IpAccessList) GetComplexFieldTypes() map[string]reflect.Type { +func (a IpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "allowed_ip_addresses": reflect.TypeOf(types.StringType), } @@ -424,7 +424,7 @@ func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringRead(existingState ListProviderSharesResponse) { } -func (a ListProviderSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListProviderSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "shares": reflect.TypeOf(ProviderShare{}), } @@ -466,7 +466,7 @@ func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringRead(existingState ListProvidersRequest) { } -func (a ListProvidersRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -495,7 +495,7 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingState ListProvidersResponse) { } -func (a ListProvidersResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "providers": reflect.TypeOf(ProviderInfo{}), } @@ -537,7 +537,7 @@ func (newState *ListRecipientsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListRecipientsRequest) SyncEffectiveFieldsDuringRead(existingState ListRecipientsRequest) { } -func (a ListRecipientsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRecipientsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -566,7 +566,7 @@ func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringRead(existingState ListRecipientsResponse) { } -func (a ListRecipientsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListRecipientsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "recipients": reflect.TypeOf(RecipientInfo{}), } @@ -607,7 +607,7 @@ func (newState *ListSharesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSharesRequest) SyncEffectiveFieldsDuringRead(existingState ListSharesRequest) { } -func (a ListSharesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSharesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -636,7 +636,7 @@ func (newState *ListSharesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSharesResponse) SyncEffectiveFieldsDuringRead(existingState ListSharesResponse) { } -func (a ListSharesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "shares": reflect.TypeOf(ShareInfo{}), } @@ -664,7 +664,7 @@ func (newState *Partition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partitio func (newState *Partition) SyncEffectiveFieldsDuringRead(existingState Partition) { } -func (a Partition) GetComplexFieldTypes() map[string]reflect.Type { +func (a Partition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(PartitionValue{}), } @@ -701,7 +701,7 @@ func (newState *PartitionValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Par func (newState *PartitionValue) SyncEffectiveFieldsDuringRead(existingState PartitionValue) { } -func (a PartitionValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a PartitionValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -729,7 +729,7 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState PrivilegeAssignment) { } -func (a PrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privileges": reflect.TypeOf(types.StringType), } @@ -790,7 +790,7 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Provi func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState ProviderInfo) { } -func (a ProviderInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "recipient_profile": reflect.TypeOf(RecipientProfile{}), } @@ -830,7 +830,7 @@ func (newState *ProviderShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Prov func (newState *ProviderShare) SyncEffectiveFieldsDuringRead(existingState ProviderShare) { } -func (a ProviderShare) GetComplexFieldTypes() map[string]reflect.Type { +func (a ProviderShare) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -896,7 +896,7 @@ func (newState *RecipientInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Reci func (newState *RecipientInfo) SyncEffectiveFieldsDuringRead(existingState RecipientInfo) { } -func (a RecipientInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RecipientInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessList{}), "properties_kvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), @@ -950,7 +950,7 @@ func (newState *RecipientProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RecipientProfile) SyncEffectiveFieldsDuringRead(existingState RecipientProfile) { } -func (a RecipientProfile) GetComplexFieldTypes() map[string]reflect.Type { +func (a RecipientProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -988,7 +988,7 @@ func (newState *RecipientTokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RecipientTokenInfo) SyncEffectiveFieldsDuringRead(existingState RecipientTokenInfo) { } -func (a RecipientTokenInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RecipientTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1018,7 +1018,7 @@ func (newState *RetrieveTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RetrieveTokenRequest) SyncEffectiveFieldsDuringRead(existingState RetrieveTokenRequest) { } -func (a RetrieveTokenRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RetrieveTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1047,7 +1047,7 @@ func (newState *RetrieveTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *RetrieveTokenResponse) SyncEffectiveFieldsDuringRead(existingState RetrieveTokenResponse) { } -func (a RetrieveTokenResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RetrieveTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1078,7 +1078,7 @@ func (newState *RotateRecipientToken) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RotateRecipientToken) SyncEffectiveFieldsDuringRead(existingState RotateRecipientToken) { } -func (a RotateRecipientToken) GetComplexFieldTypes() map[string]reflect.Type { +func (a RotateRecipientToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1104,7 +1104,7 @@ func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existingState SecurablePropertiesKvPairs) { } -func (a SecurablePropertiesKvPairs) GetComplexFieldTypes() map[string]reflect.Type { +func (a SecurablePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.StringType), } @@ -1149,7 +1149,7 @@ func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInf func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo) { } -func (a ShareInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "object": reflect.TypeOf(SharedDataObject{}), } @@ -1198,7 +1198,7 @@ func (newState *SharePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *SharePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState SharePermissionsRequest) { } -func (a SharePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SharePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1225,7 +1225,7 @@ func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState ShareToPrivilegeAssignment) { } -func (a ShareToPrivilegeAssignment) GetComplexFieldTypes() map[string]reflect.Type { +func (a ShareToPrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privilege_assignments": reflect.TypeOf(PrivilegeAssignment{}), } @@ -1298,7 +1298,7 @@ func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { } -func (a SharedDataObject) GetComplexFieldTypes() map[string]reflect.Type { +func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "partition": reflect.TypeOf(Partition{}), } @@ -1339,7 +1339,7 @@ func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringRead(existingState SharedDataObjectUpdate) { } -func (a SharedDataObjectUpdate) GetComplexFieldTypes() map[string]reflect.Type { +func (a SharedDataObjectUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_object": reflect.TypeOf(SharedDataObject{}), } @@ -1365,7 +1365,7 @@ func (newState *UpdatePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdatePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState UpdatePermissionsResponse) { } -func (a UpdatePermissionsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdatePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1395,7 +1395,7 @@ func (newState *UpdateProvider) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateProvider) SyncEffectiveFieldsDuringRead(existingState UpdateProvider) { } -func (a UpdateProvider) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateProvider) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1437,7 +1437,7 @@ func (newState *UpdateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateRecipient) SyncEffectiveFieldsDuringRead(existingState UpdateRecipient) { } -func (a UpdateRecipient) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessList{}), "properties_kvpairs": reflect.TypeOf(SecurablePropertiesKvPairs{}), @@ -1471,7 +1471,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1502,7 +1502,7 @@ func (newState *UpdateShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Update func (newState *UpdateShare) SyncEffectiveFieldsDuringRead(existingState UpdateShare) { } -func (a UpdateShare) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "updates": reflect.TypeOf(SharedDataObjectUpdate{}), } @@ -1548,7 +1548,7 @@ func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringRead(existingState UpdateSharePermissions) { } -func (a UpdateSharePermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateSharePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "changes": reflect.TypeOf(catalog.PermissionsChange{}), } diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 927a68b3fb..39b5e33829 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -34,7 +34,7 @@ func (newState *AccessControl) SyncEffectiveFieldsDuringCreateOrUpdate(plan Acce func (newState *AccessControl) SyncEffectiveFieldsDuringRead(existingState AccessControl) { } -func (a AccessControl) GetComplexFieldTypes() map[string]reflect.Type { +func (a AccessControl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -100,7 +100,7 @@ func (newState *Alert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Alert) { func (newState *Alert) SyncEffectiveFieldsDuringRead(existingState Alert) { } -func (a Alert) GetComplexFieldTypes() map[string]reflect.Type { +func (a Alert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } @@ -148,7 +148,7 @@ func (newState *AlertCondition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ale func (newState *AlertCondition) SyncEffectiveFieldsDuringRead(existingState AlertCondition) { } -func (a AlertCondition) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertCondition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "operand": reflect.TypeOf(AlertConditionOperand{}), "threshold": reflect.TypeOf(AlertConditionThreshold{}), @@ -180,7 +180,7 @@ func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringRead(existingState AlertConditionOperand) { } -func (a AlertConditionOperand) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertConditionOperand) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "column": reflect.TypeOf(AlertOperandColumn{}), } @@ -206,7 +206,7 @@ func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringRead(existingState AlertConditionThreshold) { } -func (a AlertConditionThreshold) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertConditionThreshold) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(AlertOperandValue{}), } @@ -232,7 +232,7 @@ func (newState *AlertOperandColumn) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertOperandColumn) SyncEffectiveFieldsDuringRead(existingState AlertOperandColumn) { } -func (a AlertOperandColumn) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertOperandColumn) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -258,7 +258,7 @@ func (newState *AlertOperandValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertOperandValue) SyncEffectiveFieldsDuringRead(existingState AlertOperandValue) { } -func (a AlertOperandValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertOperandValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -306,7 +306,7 @@ func (newState *AlertOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Alert func (newState *AlertOptions) SyncEffectiveFieldsDuringRead(existingState AlertOptions) { } -func (a AlertOptions) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -372,7 +372,7 @@ func (newState *AlertQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertQu func (newState *AlertQuery) SyncEffectiveFieldsDuringRead(existingState AlertQuery) { } -func (a AlertQuery) GetComplexFieldTypes() map[string]reflect.Type { +func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(QueryOptions{}), "tags": reflect.TypeOf(types.StringType), @@ -424,7 +424,7 @@ func (newState *BaseChunkInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Base func (newState *BaseChunkInfo) SyncEffectiveFieldsDuringRead(existingState BaseChunkInfo) { } -func (a BaseChunkInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a BaseChunkInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -452,7 +452,7 @@ func (newState *CancelExecutionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CancelExecutionRequest) SyncEffectiveFieldsDuringRead(existingState CancelExecutionRequest) { } -func (a CancelExecutionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelExecutionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -473,7 +473,7 @@ func (newState *CancelExecutionResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CancelExecutionResponse) SyncEffectiveFieldsDuringRead(existingState CancelExecutionResponse) { } -func (a CancelExecutionResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CancelExecutionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -497,7 +497,7 @@ func (newState *Channel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Channel) { func (newState *Channel) SyncEffectiveFieldsDuringRead(existingState Channel) { } -func (a Channel) GetComplexFieldTypes() map[string]reflect.Type { +func (a Channel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -524,7 +524,7 @@ func (newState *ChannelInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Channe func (newState *ChannelInfo) SyncEffectiveFieldsDuringRead(existingState ChannelInfo) { } -func (a ChannelInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ChannelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -563,7 +563,7 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } -func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -602,7 +602,7 @@ func (newState *CreateAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateAlert) SyncEffectiveFieldsDuringRead(existingState CreateAlert) { } -func (a CreateAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(AlertOptions{}), } @@ -632,7 +632,7 @@ func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringRead(existingState CreateAlertRequest) { } -func (a CreateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert": reflect.TypeOf(CreateAlertRequestAlert{}), } @@ -682,7 +682,7 @@ func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingState CreateAlertRequestAlert) { } -func (a CreateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } @@ -715,7 +715,7 @@ func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringRead(existingState CreateQueryRequest) { } -func (a CreateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(CreateQueryRequestQuery{}), } @@ -764,7 +764,7 @@ func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingState CreateQueryRequestQuery) { } -func (a CreateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), "tags": reflect.TypeOf(types.StringType), @@ -817,7 +817,7 @@ func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDurin func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState CreateQueryVisualizationsLegacyRequest) { } -func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -843,7 +843,7 @@ func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState CreateVisualizationRequest) { } -func (a CreateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "visualization": reflect.TypeOf(CreateVisualizationRequestVisualization{}), } @@ -882,7 +882,7 @@ func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuri func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuringRead(existingState CreateVisualizationRequestVisualization) { } -func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -968,7 +968,7 @@ func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState CreateWarehouseRequest) { } -func (a CreateWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), "tags": reflect.TypeOf(EndpointTags{}), @@ -1010,7 +1010,7 @@ func (newState *CreateWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState CreateWarehouseResponse) { } -func (a CreateWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1045,7 +1045,7 @@ func (newState *CreateWidget) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreateWidget) SyncEffectiveFieldsDuringRead(existingState CreateWidget) { } -func (a CreateWidget) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateWidget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(WidgetOptions{}), } @@ -1121,7 +1121,7 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboar func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard) { } -func (a Dashboard) GetComplexFieldTypes() map[string]reflect.Type { +func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(DashboardOptions{}), "tags": reflect.TypeOf(types.StringType), @@ -1181,7 +1181,7 @@ func (newState *DashboardEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DashboardEditContent) SyncEffectiveFieldsDuringRead(existingState DashboardEditContent) { } -func (a DashboardEditContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a DashboardEditContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.StringType), } @@ -1213,7 +1213,7 @@ func (newState *DashboardOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DashboardOptions) SyncEffectiveFieldsDuringRead(existingState DashboardOptions) { } -func (a DashboardOptions) GetComplexFieldTypes() map[string]reflect.Type { +func (a DashboardOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1250,7 +1250,7 @@ func (newState *DashboardPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DashboardPostContent) SyncEffectiveFieldsDuringRead(existingState DashboardPostContent) { } -func (a DashboardPostContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a DashboardPostContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.StringType), } @@ -1305,7 +1305,7 @@ func (newState *DataSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataSou func (newState *DataSource) SyncEffectiveFieldsDuringRead(existingState DataSource) { } -func (a DataSource) GetComplexFieldTypes() map[string]reflect.Type { +func (a DataSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1337,7 +1337,7 @@ func (newState *DateRange) SyncEffectiveFieldsDuringCreateOrUpdate(plan DateRang func (newState *DateRange) SyncEffectiveFieldsDuringRead(existingState DateRange) { } -func (a DateRange) GetComplexFieldTypes() map[string]reflect.Type { +func (a DateRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1368,7 +1368,7 @@ func (newState *DateRangeValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dat func (newState *DateRangeValue) SyncEffectiveFieldsDuringRead(existingState DateRangeValue) { } -func (a DateRangeValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a DateRangeValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "date_range_value": reflect.TypeOf(DateRange{}), } @@ -1403,7 +1403,7 @@ func (newState *DateValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan DateValu func (newState *DateValue) SyncEffectiveFieldsDuringRead(existingState DateValue) { } -func (a DateValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a DateValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1428,7 +1428,7 @@ func (newState *DeleteAlertsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteAlertsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAlertsLegacyRequest) { } -func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1451,7 +1451,7 @@ func (newState *DeleteDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteDashboardRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDashboardRequest) { } -func (a DeleteDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1475,7 +1475,7 @@ func (newState *DeleteDashboardWidgetRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteDashboardWidgetRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDashboardWidgetRequest) { } -func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1498,7 +1498,7 @@ func (newState *DeleteQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQueriesLegacyRequest) { } -func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1522,7 +1522,7 @@ func (newState *DeleteQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDurin func (newState *DeleteQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQueryVisualizationsLegacyRequest) { } -func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1543,7 +1543,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1564,7 +1564,7 @@ func (newState *DeleteVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVisualizationRequest) { } -func (a DeleteVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteVisualizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1588,7 +1588,7 @@ func (newState *DeleteWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWarehouseRequest) { } -func (a DeleteWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1609,7 +1609,7 @@ func (newState *DeleteWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWarehouseResponse) { } -func (a DeleteWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1639,7 +1639,7 @@ func (newState *EditAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditAler func (newState *EditAlert) SyncEffectiveFieldsDuringRead(existingState EditAlert) { } -func (a EditAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(AlertOptions{}), } @@ -1729,7 +1729,7 @@ func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState EditWarehouseRequest) { } -func (a EditWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), "tags": reflect.TypeOf(EndpointTags{}), @@ -1770,7 +1770,7 @@ func (newState *EditWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EditWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState EditWarehouseResponse) { } -func (a EditWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a EditWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1791,7 +1791,7 @@ func (newState *Empty) SyncEffectiveFieldsDuringCreateOrUpdate(plan Empty) { func (newState *Empty) SyncEffectiveFieldsDuringRead(existingState Empty) { } -func (a Empty) GetComplexFieldTypes() map[string]reflect.Type { +func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1813,7 +1813,7 @@ func (newState *EndpointConfPair) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *EndpointConfPair) SyncEffectiveFieldsDuringRead(existingState EndpointConfPair) { } -func (a EndpointConfPair) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointConfPair) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1847,7 +1847,7 @@ func (newState *EndpointHealth) SyncEffectiveFieldsDuringCreateOrUpdate(plan End func (newState *EndpointHealth) SyncEffectiveFieldsDuringRead(existingState EndpointHealth) { } -func (a EndpointHealth) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointHealth) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "failure_reason": reflect.TypeOf(TerminationReason{}), } @@ -1950,7 +1950,7 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState EndpointInfo) { } -func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), "health": reflect.TypeOf(EndpointHealth{}), @@ -2006,7 +2006,7 @@ func (newState *EndpointTagPair) SyncEffectiveFieldsDuringCreateOrUpdate(plan En func (newState *EndpointTagPair) SyncEffectiveFieldsDuringRead(existingState EndpointTagPair) { } -func (a EndpointTagPair) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointTagPair) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2029,7 +2029,7 @@ func (newState *EndpointTags) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointTags) SyncEffectiveFieldsDuringRead(existingState EndpointTags) { } -func (a EndpointTags) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_tags": reflect.TypeOf(EndpointTagPair{}), } @@ -2060,7 +2060,7 @@ func (newState *EnumValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan EnumValu func (newState *EnumValue) SyncEffectiveFieldsDuringRead(existingState EnumValue) { } -func (a EnumValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), "values": reflect.TypeOf(types.StringType), @@ -2213,7 +2213,7 @@ func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringRead(existingState ExecuteStatementRequest) { } -func (a ExecuteStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExecuteStatementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(StatementParameterListItem{}), } @@ -2278,7 +2278,7 @@ func (newState *ExternalLink) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exter func (newState *ExternalLink) SyncEffectiveFieldsDuringRead(existingState ExternalLink) { } -func (a ExternalLink) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExternalLink) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "http_headers": reflect.TypeOf(types.StringType), } @@ -2313,7 +2313,7 @@ func (newState *GetAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetAlertRequest) SyncEffectiveFieldsDuringRead(existingState GetAlertRequest) { } -func (a GetAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2336,7 +2336,7 @@ func (newState *GetAlertsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetAlertsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState GetAlertsLegacyRequest) { } -func (a GetAlertsLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2359,7 +2359,7 @@ func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetDashboardRequest) { } -func (a GetDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2385,7 +2385,7 @@ func (newState *GetDbsqlPermissionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetDbsqlPermissionRequest) SyncEffectiveFieldsDuringRead(existingState GetDbsqlPermissionRequest) { } -func (a GetDbsqlPermissionRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetDbsqlPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2409,7 +2409,7 @@ func (newState *GetQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState GetQueriesLegacyRequest) { } -func (a GetQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2432,7 +2432,7 @@ func (newState *GetQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetQueryRequest) SyncEffectiveFieldsDuringRead(existingState GetQueryRequest) { } -func (a GetQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2458,7 +2458,7 @@ func (newState *GetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRes func (newState *GetResponse) SyncEffectiveFieldsDuringRead(existingState GetResponse) { } -func (a GetResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControl{}), } @@ -2489,7 +2489,7 @@ func (newState *GetStatementRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetStatementRequest) SyncEffectiveFieldsDuringRead(existingState GetStatementRequest) { } -func (a GetStatementRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStatementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2515,7 +2515,7 @@ func (newState *GetStatementResultChunkNRequest) SyncEffectiveFieldsDuringCreate func (newState *GetStatementResultChunkNRequest) SyncEffectiveFieldsDuringRead(existingState GetStatementResultChunkNRequest) { } -func (a GetStatementResultChunkNRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStatementResultChunkNRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2540,7 +2540,7 @@ func (newState *GetWarehousePermissionLevelsRequest) SyncEffectiveFieldsDuringCr func (newState *GetWarehousePermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionLevelsRequest) { } -func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2563,7 +2563,7 @@ func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringC func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionLevelsResponse) { } -func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(WarehousePermissionsDescription{}), } @@ -2591,7 +2591,7 @@ func (newState *GetWarehousePermissionsRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetWarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionsRequest) { } -func (a GetWarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2615,7 +2615,7 @@ func (newState *GetWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehouseRequest) { } -func (a GetWarehouseRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2710,7 +2710,7 @@ func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState GetWarehouseResponse) { } -func (a GetWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), "health": reflect.TypeOf(EndpointHealth{}), @@ -2788,7 +2788,7 @@ func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCr func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceWarehouseConfigResponse) { } -func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), "config_param": reflect.TypeOf(RepeatedEndpointConfPairs{}), @@ -2862,7 +2862,7 @@ func (newState *LegacyAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Legacy func (newState *LegacyAlert) SyncEffectiveFieldsDuringRead(existingState LegacyAlert) { } -func (a LegacyAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a LegacyAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(AlertOptions{}), "query": reflect.TypeOf(AlertQuery{}), @@ -2971,7 +2971,7 @@ func (newState *LegacyQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan Legacy func (newState *LegacyQuery) SyncEffectiveFieldsDuringRead(existingState LegacyQuery) { } -func (a LegacyQuery) GetComplexFieldTypes() map[string]reflect.Type { +func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "last_modified_by": reflect.TypeOf(User{}), "options": reflect.TypeOf(QueryOptions{}), @@ -3055,7 +3055,7 @@ func (newState *LegacyVisualization) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *LegacyVisualization) SyncEffectiveFieldsDuringRead(existingState LegacyVisualization) { } -func (a LegacyVisualization) GetComplexFieldTypes() map[string]reflect.Type { +func (a LegacyVisualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(LegacyQuery{}), } @@ -3091,7 +3091,7 @@ func (newState *ListAlertsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListAlertsRequest) SyncEffectiveFieldsDuringRead(existingState ListAlertsRequest) { } -func (a ListAlertsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAlertsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3116,7 +3116,7 @@ func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringRead(existingState ListAlertsResponse) { } -func (a ListAlertsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAlertsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ListAlertsResponseAlert{}), } @@ -3183,7 +3183,7 @@ func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringRead(existingState ListAlertsResponseAlert) { } -func (a ListAlertsResponseAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAlertsResponseAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } @@ -3230,7 +3230,7 @@ func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringRead(existingState ListDashboardsRequest) { } -func (a ListDashboardsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3276,7 +3276,7 @@ func (newState *ListQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState ListQueriesLegacyRequest) { } -func (a ListQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3304,7 +3304,7 @@ func (newState *ListQueriesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQueriesRequest) SyncEffectiveFieldsDuringRead(existingState ListQueriesRequest) { } -func (a ListQueriesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQueriesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3332,7 +3332,7 @@ func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringRead(existingState ListQueriesResponse) { } -func (a ListQueriesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQueriesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "res": reflect.TypeOf(QueryInfo{}), } @@ -3373,7 +3373,7 @@ func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringRead(existingState ListQueryHistoryRequest) { } -func (a ListQueryHistoryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQueryHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter_by": reflect.TypeOf(QueryFilter{}), } @@ -3404,7 +3404,7 @@ func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringRead(existingState ListQueryObjectsResponse) { } -func (a ListQueryObjectsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQueryObjectsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ListQueryObjectsResponseQuery{}), } @@ -3464,7 +3464,7 @@ func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringCreateOr func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringRead(existingState ListQueryObjectsResponseQuery) { } -func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), "tags": reflect.TypeOf(types.StringType), @@ -3515,7 +3515,7 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListR func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListResponse) { } -func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(Dashboard{}), } @@ -3549,7 +3549,7 @@ func (newState *ListVisualizationsForQueryRequest) SyncEffectiveFieldsDuringCrea func (newState *ListVisualizationsForQueryRequest) SyncEffectiveFieldsDuringRead(existingState ListVisualizationsForQueryRequest) { } -func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3575,7 +3575,7 @@ func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringCre func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringRead(existingState ListVisualizationsForQueryResponse) { } -func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(Visualization{}), } @@ -3605,7 +3605,7 @@ func (newState *ListWarehousesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListWarehousesRequest) SyncEffectiveFieldsDuringRead(existingState ListWarehousesRequest) { } -func (a ListWarehousesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListWarehousesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3628,7 +3628,7 @@ func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringRead(existingState ListWarehousesResponse) { } -func (a ListWarehousesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListWarehousesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "warehouses": reflect.TypeOf(EndpointInfo{}), } @@ -3660,7 +3660,7 @@ func (newState *MultiValuesOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MultiValuesOptions) SyncEffectiveFieldsDuringRead(existingState MultiValuesOptions) { } -func (a MultiValuesOptions) GetComplexFieldTypes() map[string]reflect.Type { +func (a MultiValuesOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3684,7 +3684,7 @@ func (newState *NumericValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Numer func (newState *NumericValue) SyncEffectiveFieldsDuringRead(existingState NumericValue) { } -func (a NumericValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a NumericValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3712,7 +3712,7 @@ func (newState *OdbcParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan OdbcPar func (newState *OdbcParams) SyncEffectiveFieldsDuringRead(existingState OdbcParams) { } -func (a OdbcParams) GetComplexFieldTypes() map[string]reflect.Type { +func (a OdbcParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -3754,7 +3754,7 @@ func (newState *Parameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Paramete func (newState *Parameter) SyncEffectiveFieldsDuringRead(existingState Parameter) { } -func (a Parameter) GetComplexFieldTypes() map[string]reflect.Type { +func (a Parameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), } @@ -3821,7 +3821,7 @@ func (newState *Query) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query) { func (newState *Query) SyncEffectiveFieldsDuringRead(existingState Query) { } -func (a Query) GetComplexFieldTypes() map[string]reflect.Type { +func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), "tags": reflect.TypeOf(types.StringType), @@ -3871,7 +3871,7 @@ func (newState *QueryBackedValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryBackedValue) SyncEffectiveFieldsDuringRead(existingState QueryBackedValue) { } -func (a QueryBackedValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), "values": reflect.TypeOf(types.StringType), @@ -3926,7 +3926,7 @@ func (newState *QueryEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryEditContent) SyncEffectiveFieldsDuringRead(existingState QueryEditContent) { } -func (a QueryEditContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryEditContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.StringType), } @@ -3969,7 +3969,7 @@ func (newState *QueryFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryF func (newState *QueryFilter) SyncEffectiveFieldsDuringRead(existingState QueryFilter) { } -func (a QueryFilter) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query_start_time_range": reflect.TypeOf(TimeRange{}), "statement_ids": reflect.TypeOf(types.StringType), @@ -4059,7 +4059,7 @@ func (newState *QueryInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryInf func (newState *QueryInfo) SyncEffectiveFieldsDuringRead(existingState QueryInfo) { } -func (a QueryInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel_used": reflect.TypeOf(ChannelInfo{}), "metrics": reflect.TypeOf(QueryMetrics{}), @@ -4116,7 +4116,7 @@ func (newState *QueryList) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryLis func (newState *QueryList) SyncEffectiveFieldsDuringRead(existingState QueryList) { } -func (a QueryList) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(LegacyQuery{}), } @@ -4202,7 +4202,7 @@ func (newState *QueryMetrics) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query func (newState *QueryMetrics) SyncEffectiveFieldsDuringRead(existingState QueryMetrics) { } -func (a QueryMetrics) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryMetrics) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4254,7 +4254,7 @@ func (newState *QueryOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query func (newState *QueryOptions) SyncEffectiveFieldsDuringRead(existingState QueryOptions) { } -func (a QueryOptions) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(Parameter{}), } @@ -4301,7 +4301,7 @@ func (newState *QueryParameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Que func (newState *QueryParameter) SyncEffectiveFieldsDuringRead(existingState QueryParameter) { } -func (a QueryParameter) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryParameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "date_range_value": reflect.TypeOf(DateRangeValue{}), "date_value": reflect.TypeOf(DateValue{}), @@ -4373,7 +4373,7 @@ func (newState *QueryPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryPostContent) SyncEffectiveFieldsDuringRead(existingState QueryPostContent) { } -func (a QueryPostContent) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryPostContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.StringType), } @@ -4409,7 +4409,7 @@ func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringRead(existingState RepeatedEndpointConfPairs) { } -func (a RepeatedEndpointConfPairs) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepeatedEndpointConfPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config_pair": reflect.TypeOf(EndpointConfPair{}), "configuration_pairs": reflect.TypeOf(EndpointConfPair{}), @@ -4440,7 +4440,7 @@ func (newState *RestoreDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *RestoreDashboardRequest) SyncEffectiveFieldsDuringRead(existingState RestoreDashboardRequest) { } -func (a RestoreDashboardRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4463,7 +4463,7 @@ func (newState *RestoreQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *RestoreQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState RestoreQueriesLegacyRequest) { } -func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4484,7 +4484,7 @@ func (newState *RestoreResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RestoreResponse) SyncEffectiveFieldsDuringRead(existingState RestoreResponse) { } -func (a RestoreResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RestoreResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4527,7 +4527,7 @@ func (newState *ResultData) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultD func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultData) { } -func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_array": reflect.TypeOf(types.StringType), "external_links": reflect.TypeOf(ExternalLink{}), @@ -4581,7 +4581,7 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState ResultManifest) { } -func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "chunks": reflect.TypeOf(BaseChunkInfo{}), "schema": reflect.TypeOf(ResultSchema{}), @@ -4619,7 +4619,7 @@ func (newState *ResultSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resul func (newState *ResultSchema) SyncEffectiveFieldsDuringRead(existingState ResultSchema) { } -func (a ResultSchema) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResultSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(ColumnInfo{}), } @@ -4648,7 +4648,7 @@ func (newState *ServiceError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Servi func (newState *ServiceError) SyncEffectiveFieldsDuringRead(existingState ServiceError) { } -func (a ServiceError) GetComplexFieldTypes() map[string]reflect.Type { +func (a ServiceError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4677,7 +4677,7 @@ func (newState *SetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetRequ func (newState *SetRequest) SyncEffectiveFieldsDuringRead(existingState SetRequest) { } -func (a SetRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControl{}), } @@ -4709,7 +4709,7 @@ func (newState *SetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetRes func (newState *SetResponse) SyncEffectiveFieldsDuringRead(existingState SetResponse) { } -func (a SetResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControl{}), } @@ -4761,7 +4761,7 @@ func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringCre func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringRead(existingState SetWorkspaceWarehouseConfigRequest) { } -func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), "config_param": reflect.TypeOf(RepeatedEndpointConfPairs{}), @@ -4809,7 +4809,7 @@ func (newState *SetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCr func (newState *SetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRead(existingState SetWorkspaceWarehouseConfigResponse) { } -func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4831,7 +4831,7 @@ func (newState *StartRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Start func (newState *StartRequest) SyncEffectiveFieldsDuringRead(existingState StartRequest) { } -func (a StartRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4852,7 +4852,7 @@ func (newState *StartWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *StartWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState StartWarehouseResponse) { } -func (a StartWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a StartWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4884,7 +4884,7 @@ func (newState *StatementParameterListItem) SyncEffectiveFieldsDuringCreateOrUpd func (newState *StatementParameterListItem) SyncEffectiveFieldsDuringRead(existingState StatementParameterListItem) { } -func (a StatementParameterListItem) GetComplexFieldTypes() map[string]reflect.Type { +func (a StatementParameterListItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -4917,7 +4917,7 @@ func (newState *StatementResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *StatementResponse) SyncEffectiveFieldsDuringRead(existingState StatementResponse) { } -func (a StatementResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a StatementResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "manifest": reflect.TypeOf(ResultManifest{}), "result": reflect.TypeOf(ResultData{}), @@ -4962,7 +4962,7 @@ func (newState *StatementStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan St func (newState *StatementStatus) SyncEffectiveFieldsDuringRead(existingState StatementStatus) { } -func (a StatementStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a StatementStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error": reflect.TypeOf(ServiceError{}), } @@ -4991,7 +4991,7 @@ func (newState *StopRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan StopRe func (newState *StopRequest) SyncEffectiveFieldsDuringRead(existingState StopRequest) { } -func (a StopRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5012,7 +5012,7 @@ func (newState *StopWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *StopWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState StopWarehouseResponse) { } -func (a StopWarehouseResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a StopWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5032,7 +5032,7 @@ func (newState *Success) SyncEffectiveFieldsDuringCreateOrUpdate(plan Success) { func (newState *Success) SyncEffectiveFieldsDuringRead(existingState Success) { } -func (a Success) GetComplexFieldTypes() map[string]reflect.Type { +func (a Success) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5060,7 +5060,7 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState TerminationReason) { } -func (a TerminationReason) GetComplexFieldTypes() map[string]reflect.Type { +func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.StringType), } @@ -5088,7 +5088,7 @@ func (newState *TextValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan TextValu func (newState *TextValue) SyncEffectiveFieldsDuringRead(existingState TextValue) { } -func (a TextValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a TextValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5113,7 +5113,7 @@ func (newState *TimeRange) SyncEffectiveFieldsDuringCreateOrUpdate(plan TimeRang func (newState *TimeRange) SyncEffectiveFieldsDuringRead(existingState TimeRange) { } -func (a TimeRange) GetComplexFieldTypes() map[string]reflect.Type { +func (a TimeRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5137,7 +5137,7 @@ func (newState *TransferOwnershipObjectId) SyncEffectiveFieldsDuringCreateOrUpda func (newState *TransferOwnershipObjectId) SyncEffectiveFieldsDuringRead(existingState TransferOwnershipObjectId) { } -func (a TransferOwnershipObjectId) GetComplexFieldTypes() map[string]reflect.Type { +func (a TransferOwnershipObjectId) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5165,7 +5165,7 @@ func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringRead(existingState TransferOwnershipRequest) { } -func (a TransferOwnershipRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TransferOwnershipRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "objectId": reflect.TypeOf(TransferOwnershipObjectId{}), } @@ -5194,7 +5194,7 @@ func (newState *TrashAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TrashAlertRequest) SyncEffectiveFieldsDuringRead(existingState TrashAlertRequest) { } -func (a TrashAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TrashAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5217,7 +5217,7 @@ func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringRead(existingState TrashQueryRequest) { } -func (a TrashQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a TrashQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5246,7 +5246,7 @@ func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAlertRequest) { } -func (a UpdateAlertRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert": reflect.TypeOf(UpdateAlertRequestAlert{}), } @@ -5299,7 +5299,7 @@ func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingState UpdateAlertRequestAlert) { } -func (a UpdateAlertRequestAlert) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } @@ -5339,7 +5339,7 @@ func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringRead(existingState UpdateQueryRequest) { } -func (a UpdateQueryRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(UpdateQueryRequestQuery{}), } @@ -5390,7 +5390,7 @@ func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingState UpdateQueryRequestQuery) { } -func (a UpdateQueryRequestQuery) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), "tags": reflect.TypeOf(types.StringType), @@ -5428,7 +5428,7 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } -func (a UpdateResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5455,7 +5455,7 @@ func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateVisualizationRequest) { } -func (a UpdateVisualizationRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "visualization": reflect.TypeOf(UpdateVisualizationRequestVisualization{}), } @@ -5494,7 +5494,7 @@ func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuri func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuringRead(existingState UpdateVisualizationRequestVisualization) { } -func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5523,7 +5523,7 @@ func (newState *User) SyncEffectiveFieldsDuringCreateOrUpdate(plan User) { func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { } -func (a User) GetComplexFieldTypes() map[string]reflect.Type { +func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5566,7 +5566,7 @@ func (newState *Visualization) SyncEffectiveFieldsDuringCreateOrUpdate(plan Visu func (newState *Visualization) SyncEffectiveFieldsDuringRead(existingState Visualization) { } -func (a Visualization) GetComplexFieldTypes() map[string]reflect.Type { +func (a Visualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5602,7 +5602,7 @@ func (newState *WarehouseAccessControlRequest) SyncEffectiveFieldsDuringCreateOr func (newState *WarehouseAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState WarehouseAccessControlRequest) { } -func (a WarehouseAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehouseAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5636,7 +5636,7 @@ func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringCreateO func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState WarehouseAccessControlResponse) { } -func (a WarehouseAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehouseAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(WarehousePermission{}), } @@ -5670,7 +5670,7 @@ func (newState *WarehousePermission) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *WarehousePermission) SyncEffectiveFieldsDuringRead(existingState WarehousePermission) { } -func (a WarehousePermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehousePermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -5702,7 +5702,7 @@ func (newState *WarehousePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WarehousePermissions) SyncEffectiveFieldsDuringRead(existingState WarehousePermissions) { } -func (a WarehousePermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehousePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WarehouseAccessControlResponse{}), } @@ -5732,7 +5732,7 @@ func (newState *WarehousePermissionsDescription) SyncEffectiveFieldsDuringCreate func (newState *WarehousePermissionsDescription) SyncEffectiveFieldsDuringRead(existingState WarehousePermissionsDescription) { } -func (a WarehousePermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehousePermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5757,7 +5757,7 @@ func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState WarehousePermissionsRequest) { } -func (a WarehousePermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WarehouseAccessControlRequest{}), } @@ -5788,7 +5788,7 @@ func (newState *WarehouseTypePair) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *WarehouseTypePair) SyncEffectiveFieldsDuringRead(existingState WarehouseTypePair) { } -func (a WarehouseTypePair) GetComplexFieldTypes() map[string]reflect.Type { +func (a WarehouseTypePair) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -5822,7 +5822,7 @@ func (newState *Widget) SyncEffectiveFieldsDuringCreateOrUpdate(plan Widget) { func (newState *Widget) SyncEffectiveFieldsDuringRead(existingState Widget) { } -func (a Widget) GetComplexFieldTypes() map[string]reflect.Type { +func (a Widget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(WidgetOptions{}), "visualization": reflect.TypeOf(LegacyVisualization{}), @@ -5870,7 +5870,7 @@ func (newState *WidgetOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Widg func (newState *WidgetOptions) SyncEffectiveFieldsDuringRead(existingState WidgetOptions) { } -func (a WidgetOptions) GetComplexFieldTypes() map[string]reflect.Type { +func (a WidgetOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "position": reflect.TypeOf(WidgetPosition{}), } @@ -5913,7 +5913,7 @@ func (newState *WidgetPosition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Wid func (newState *WidgetPosition) SyncEffectiveFieldsDuringRead(existingState WidgetPosition) { } -func (a WidgetPosition) GetComplexFieldTypes() map[string]reflect.Type { +func (a WidgetPosition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 94c020f5de..c432235ef6 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -30,7 +30,7 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } -func (a ColumnInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -55,7 +55,7 @@ func (newState *CreateEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateEndpoint) SyncEffectiveFieldsDuringRead(existingState CreateEndpoint) { } -func (a CreateEndpoint) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -97,7 +97,7 @@ func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState CreateVectorIndexRequest) { } -func (a CreateVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "delta_sync_index_spec": reflect.TypeOf(DeltaSyncVectorIndexSpecRequest{}), "direct_access_index_spec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), @@ -131,7 +131,7 @@ func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState CreateVectorIndexResponse) { } -func (a CreateVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "vector_index": reflect.TypeOf(VectorIndex{}), } @@ -161,7 +161,7 @@ func (newState *DeleteDataResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteDataResult) SyncEffectiveFieldsDuringRead(existingState DeleteDataResult) { } -func (a DeleteDataResult) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDataResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "failed_primary_keys": reflect.TypeOf(types.StringType), } @@ -193,7 +193,7 @@ func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDataVectorIndexRequest) { } -func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "primary_keys": reflect.TypeOf(types.StringType), } @@ -224,7 +224,7 @@ func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDataVectorIndexResponse) { } -func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "result": reflect.TypeOf(DeleteDataResult{}), } @@ -253,7 +253,7 @@ func (newState *DeleteEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteEndpointRequest) { } -func (a DeleteEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -274,7 +274,7 @@ func (newState *DeleteEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteEndpointResponse) SyncEffectiveFieldsDuringRead(existingState DeleteEndpointResponse) { } -func (a DeleteEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -296,7 +296,7 @@ func (newState *DeleteIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteIndexRequest) SyncEffectiveFieldsDuringRead(existingState DeleteIndexRequest) { } -func (a DeleteIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -317,7 +317,7 @@ func (newState *DeleteIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteIndexResponse) SyncEffectiveFieldsDuringRead(existingState DeleteIndexResponse) { } -func (a DeleteIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -361,7 +361,7 @@ func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringCreate func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringRead(existingState DeltaSyncVectorIndexSpecRequest) { } -func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns_to_sync": reflect.TypeOf(types.StringType), "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), @@ -417,7 +417,7 @@ func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringCreat func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringRead(existingState DeltaSyncVectorIndexSpecResponse) { } -func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), "embedding_vector_columns": reflect.TypeOf(EmbeddingVectorColumn{}), @@ -461,7 +461,7 @@ func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringCreateOrUp func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringRead(existingState DirectAccessVectorIndexSpec) { } -func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes() map[string]reflect.Type { +func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), "embedding_vector_columns": reflect.TypeOf(EmbeddingVectorColumn{}), @@ -495,7 +495,7 @@ func (newState *EmbeddingSourceColumn) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EmbeddingSourceColumn) SyncEffectiveFieldsDuringRead(existingState EmbeddingSourceColumn) { } -func (a EmbeddingSourceColumn) GetComplexFieldTypes() map[string]reflect.Type { +func (a EmbeddingSourceColumn) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -521,7 +521,7 @@ func (newState *EmbeddingVectorColumn) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EmbeddingVectorColumn) SyncEffectiveFieldsDuringRead(existingState EmbeddingVectorColumn) { } -func (a EmbeddingVectorColumn) GetComplexFieldTypes() map[string]reflect.Type { +func (a EmbeddingVectorColumn) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -561,7 +561,7 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState EndpointInfo) { } -func (a EndpointInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "endpoint_status": reflect.TypeOf(EndpointStatus{}), } @@ -599,7 +599,7 @@ func (newState *EndpointStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan End func (newState *EndpointStatus) SyncEffectiveFieldsDuringRead(existingState EndpointStatus) { } -func (a EndpointStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a EndpointStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -624,7 +624,7 @@ func (newState *GetEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetEndpointRequest) { } -func (a GetEndpointRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -648,7 +648,7 @@ func (newState *GetIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetIndexRequest) SyncEffectiveFieldsDuringRead(existingState GetIndexRequest) { } -func (a GetIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -674,7 +674,7 @@ func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringRead(existingState ListEndpointResponse) { } -func (a ListEndpointResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "endpoints": reflect.TypeOf(EndpointInfo{}), } @@ -703,7 +703,7 @@ func (newState *ListEndpointsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListEndpointsRequest) SyncEffectiveFieldsDuringRead(existingState ListEndpointsRequest) { } -func (a ListEndpointsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListEndpointsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -729,7 +729,7 @@ func (newState *ListIndexesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListIndexesRequest) SyncEffectiveFieldsDuringRead(existingState ListIndexesRequest) { } -func (a ListIndexesRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListIndexesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -752,7 +752,7 @@ func (newState *ListValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListValu func (newState *ListValue) SyncEffectiveFieldsDuringRead(existingState ListValue) { } -func (a ListValue) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(Value{}), } @@ -782,7 +782,7 @@ func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringRead(existingState ListVectorIndexesResponse) { } -func (a ListVectorIndexesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListVectorIndexesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "vector_indexes": reflect.TypeOf(MiniVectorIndex{}), } @@ -813,7 +813,7 @@ func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringRead(existingState MapStringValueEntry) { } -func (a MapStringValueEntry) GetComplexFieldTypes() map[string]reflect.Type { +func (a MapStringValueEntry) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(Value{}), } @@ -855,7 +855,7 @@ func (newState *MiniVectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mi func (newState *MiniVectorIndex) SyncEffectiveFieldsDuringRead(existingState MiniVectorIndex) { } -func (a MiniVectorIndex) GetComplexFieldTypes() map[string]reflect.Type { +func (a MiniVectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -888,7 +888,7 @@ func (newState *QueryVectorIndexNextPageRequest) SyncEffectiveFieldsDuringCreate func (newState *QueryVectorIndexNextPageRequest) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexNextPageRequest) { } -func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -933,7 +933,7 @@ func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexRequest) { } -func (a QueryVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(types.StringType), "query_vector": reflect.TypeOf(types.Float64Type), @@ -976,7 +976,7 @@ func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexResponse) { } -func (a QueryVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a QueryVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "manifest": reflect.TypeOf(ResultManifest{}), "result": reflect.TypeOf(ResultData{}), @@ -1011,7 +1011,7 @@ func (newState *ResultData) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultD func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultData) { } -func (a ResultData) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_array": reflect.TypeOf(types.StringType), } @@ -1044,7 +1044,7 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState ResultManifest) { } -func (a ResultManifest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(ColumnInfo{}), } @@ -1077,7 +1077,7 @@ func (newState *ScanVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ScanVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState ScanVectorIndexRequest) { } -func (a ScanVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ScanVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1105,7 +1105,7 @@ func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState ScanVectorIndexResponse) { } -func (a ScanVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ScanVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data": reflect.TypeOf(Struct{}), } @@ -1133,7 +1133,7 @@ func (newState *Struct) SyncEffectiveFieldsDuringCreateOrUpdate(plan Struct) { func (newState *Struct) SyncEffectiveFieldsDuringRead(existingState Struct) { } -func (a Struct) GetComplexFieldTypes() map[string]reflect.Type { +func (a Struct) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fields": reflect.TypeOf(MapStringValueEntry{}), } @@ -1161,7 +1161,7 @@ func (newState *SyncIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SyncIndexRequest) SyncEffectiveFieldsDuringRead(existingState SyncIndexRequest) { } -func (a SyncIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a SyncIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1182,7 +1182,7 @@ func (newState *SyncIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SyncIndexResponse) SyncEffectiveFieldsDuringRead(existingState SyncIndexResponse) { } -func (a SyncIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a SyncIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1206,7 +1206,7 @@ func (newState *UpsertDataResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpsertDataResult) SyncEffectiveFieldsDuringRead(existingState UpsertDataResult) { } -func (a UpsertDataResult) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpsertDataResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "failed_primary_keys": reflect.TypeOf(types.StringType), } @@ -1238,7 +1238,7 @@ func (newState *UpsertDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *UpsertDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState UpsertDataVectorIndexRequest) { } -func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1265,7 +1265,7 @@ func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringCreateOr func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState UpsertDataVectorIndexResponse) { } -func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "result": reflect.TypeOf(UpsertDataResult{}), } @@ -1302,7 +1302,7 @@ func (newState *Value) SyncEffectiveFieldsDuringCreateOrUpdate(plan Value) { func (newState *Value) SyncEffectiveFieldsDuringRead(existingState Value) { } -func (a Value) GetComplexFieldTypes() map[string]reflect.Type { +func (a Value) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "list_value": reflect.TypeOf(ListValue{}), "struct_value": reflect.TypeOf(Struct{}), @@ -1357,7 +1357,7 @@ func (newState *VectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan Vector func (newState *VectorIndex) SyncEffectiveFieldsDuringRead(existingState VectorIndex) { } -func (a VectorIndex) GetComplexFieldTypes() map[string]reflect.Type { +func (a VectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "delta_sync_index_spec": reflect.TypeOf(DeltaSyncVectorIndexSpecResponse{}), "direct_access_index_spec": reflect.TypeOf(DirectAccessVectorIndexSpec{}), @@ -1403,7 +1403,7 @@ func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringRead(existingState VectorIndexStatus) { } -func (a VectorIndexStatus) GetComplexFieldTypes() map[string]reflect.Type { +func (a VectorIndexStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index dd0cc8f31d..6e21cf5211 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -32,7 +32,7 @@ func (newState *AclItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan AclItem) { func (newState *AclItem) SyncEffectiveFieldsDuringRead(existingState AclItem) { } -func (a AclItem) GetComplexFieldTypes() map[string]reflect.Type { +func (a AclItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -59,7 +59,7 @@ func (newState *AzureKeyVaultSecretScopeMetadata) SyncEffectiveFieldsDuringCreat func (newState *AzureKeyVaultSecretScopeMetadata) SyncEffectiveFieldsDuringRead(existingState AzureKeyVaultSecretScopeMetadata) { } -func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes() map[string]reflect.Type { +func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -100,7 +100,7 @@ func (newState *CreateCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialsRequest) { } -func (a CreateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -130,7 +130,7 @@ func (newState *CreateCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState CreateCredentialsResponse) { } -func (a CreateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -167,7 +167,7 @@ func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringRead(existingState CreateRepoRequest) { } -func (a CreateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } @@ -210,7 +210,7 @@ func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringRead(existingState CreateRepoResponse) { } -func (a CreateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } @@ -251,7 +251,7 @@ func (newState *CreateScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateScope) SyncEffectiveFieldsDuringRead(existingState CreateScope) { } -func (a CreateScope) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateScope) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "backend_azure_keyvault": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), } @@ -279,7 +279,7 @@ func (newState *CreateScopeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateScopeResponse) SyncEffectiveFieldsDuringRead(existingState CreateScopeResponse) { } -func (a CreateScopeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a CreateScopeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -305,7 +305,7 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState CredentialInfo) { } -func (a CredentialInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -335,7 +335,7 @@ func (newState *Delete) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete) { func (newState *Delete) SyncEffectiveFieldsDuringRead(existingState Delete) { } -func (a Delete) GetComplexFieldTypes() map[string]reflect.Type { +func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -361,7 +361,7 @@ func (newState *DeleteAcl) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteAc func (newState *DeleteAcl) SyncEffectiveFieldsDuringRead(existingState DeleteAcl) { } -func (a DeleteAcl) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -383,7 +383,7 @@ func (newState *DeleteAclResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteAclResponse) SyncEffectiveFieldsDuringRead(existingState DeleteAclResponse) { } -func (a DeleteAclResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -405,7 +405,7 @@ func (newState *DeleteCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialsRequest) { } -func (a DeleteCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -426,7 +426,7 @@ func (newState *DeleteCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialsResponse) { } -func (a DeleteCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -448,7 +448,7 @@ func (newState *DeleteRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRepoRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRepoRequest) { } -func (a DeleteRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -469,7 +469,7 @@ func (newState *DeleteRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRepoResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRepoResponse) { } -func (a DeleteRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -488,7 +488,7 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } -func (a DeleteResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -509,7 +509,7 @@ func (newState *DeleteScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete func (newState *DeleteScope) SyncEffectiveFieldsDuringRead(existingState DeleteScope) { } -func (a DeleteScope) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteScope) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -530,7 +530,7 @@ func (newState *DeleteScopeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteScopeResponse) SyncEffectiveFieldsDuringRead(existingState DeleteScopeResponse) { } -func (a DeleteScopeResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteScopeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -553,7 +553,7 @@ func (newState *DeleteSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delet func (newState *DeleteSecret) SyncEffectiveFieldsDuringRead(existingState DeleteSecret) { } -func (a DeleteSecret) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -575,7 +575,7 @@ func (newState *DeleteSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteSecretResponse) SyncEffectiveFieldsDuringRead(existingState DeleteSecretResponse) { } -func (a DeleteSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a DeleteSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -613,7 +613,7 @@ func (newState *ExportRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Expo func (newState *ExportRequest) SyncEffectiveFieldsDuringRead(existingState ExportRequest) { } -func (a ExportRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExportRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -640,7 +640,7 @@ func (newState *ExportResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exp func (newState *ExportResponse) SyncEffectiveFieldsDuringRead(existingState ExportResponse) { } -func (a ExportResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ExportResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -667,7 +667,7 @@ func (newState *GetAclRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetA func (newState *GetAclRequest) SyncEffectiveFieldsDuringRead(existingState GetAclRequest) { } -func (a GetAclRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetAclRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -692,7 +692,7 @@ func (newState *GetCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialsRequest) { } -func (a GetCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -720,7 +720,7 @@ func (newState *GetCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState GetCredentialsResponse) { } -func (a GetCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -746,7 +746,7 @@ func (newState *GetRepoPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetRepoPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionLevelsRequest) { } -func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -769,7 +769,7 @@ func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringCreate func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionLevelsResponse) { } -func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(RepoPermissionsDescription{}), } @@ -797,7 +797,7 @@ func (newState *GetRepoPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetRepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionsRequest) { } -func (a GetRepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -821,7 +821,7 @@ func (newState *GetRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetRepoRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoRequest) { } -func (a GetRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -856,7 +856,7 @@ func (newState *GetRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetRepoResponse) SyncEffectiveFieldsDuringRead(existingState GetRepoResponse) { } -func (a GetRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } @@ -892,7 +892,7 @@ func (newState *GetSecretRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSecretRequest) SyncEffectiveFieldsDuringRead(existingState GetSecretRequest) { } -func (a GetSecretRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -918,7 +918,7 @@ func (newState *GetSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetSecretResponse) SyncEffectiveFieldsDuringRead(existingState GetSecretResponse) { } -func (a GetSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -943,7 +943,7 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } -func (a GetStatusRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -969,7 +969,7 @@ func (newState *GetWorkspaceObjectPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetWorkspaceObjectPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionLevelsRequest) { } -func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -993,7 +993,7 @@ func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionLevelsResponse) { } -func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(WorkspaceObjectPermissionsDescription{}), } @@ -1023,7 +1023,7 @@ func (newState *GetWorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetWorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionsRequest) { } -func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1075,7 +1075,7 @@ func (newState *Import) SyncEffectiveFieldsDuringCreateOrUpdate(plan Import) { func (newState *Import) SyncEffectiveFieldsDuringRead(existingState Import) { } -func (a Import) GetComplexFieldTypes() map[string]reflect.Type { +func (a Import) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1100,7 +1100,7 @@ func (newState *ImportResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Imp func (newState *ImportResponse) SyncEffectiveFieldsDuringRead(existingState ImportResponse) { } -func (a ImportResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ImportResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1122,7 +1122,7 @@ func (newState *ListAclsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListAclsRequest) SyncEffectiveFieldsDuringRead(existingState ListAclsRequest) { } -func (a ListAclsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAclsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1145,7 +1145,7 @@ func (newState *ListAclsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListAclsResponse) SyncEffectiveFieldsDuringRead(existingState ListAclsResponse) { } -func (a ListAclsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListAclsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "items": reflect.TypeOf(AclItem{}), } @@ -1172,7 +1172,7 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListCredentialsResponse) { } -func (a ListCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credentials": reflect.TypeOf(CredentialInfo{}), } @@ -1206,7 +1206,7 @@ func (newState *ListReposRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListReposRequest) SyncEffectiveFieldsDuringRead(existingState ListReposRequest) { } -func (a ListReposRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListReposRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1233,7 +1233,7 @@ func (newState *ListReposResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListReposResponse) SyncEffectiveFieldsDuringRead(existingState ListReposResponse) { } -func (a ListReposResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListReposResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "repos": reflect.TypeOf(RepoInfo{}), } @@ -1261,7 +1261,7 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListR func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListResponse) { } -func (a ListResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "objects": reflect.TypeOf(ObjectInfo{}), } @@ -1288,7 +1288,7 @@ func (newState *ListScopesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListScopesResponse) SyncEffectiveFieldsDuringRead(existingState ListScopesResponse) { } -func (a ListScopesResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListScopesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "scopes": reflect.TypeOf(SecretScope{}), } @@ -1316,7 +1316,7 @@ func (newState *ListSecretsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSecretsRequest) SyncEffectiveFieldsDuringRead(existingState ListSecretsRequest) { } -func (a ListSecretsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1339,7 +1339,7 @@ func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringRead(existingState ListSecretsResponse) { } -func (a ListSecretsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "secrets": reflect.TypeOf(SecretMetadata{}), } @@ -1369,7 +1369,7 @@ func (newState *ListWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState ListWorkspaceRequest) { } -func (a ListWorkspaceRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a ListWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1395,7 +1395,7 @@ func (newState *Mkdirs) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mkdirs) { func (newState *Mkdirs) SyncEffectiveFieldsDuringRead(existingState Mkdirs) { } -func (a Mkdirs) GetComplexFieldTypes() map[string]reflect.Type { +func (a Mkdirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1416,7 +1416,7 @@ func (newState *MkdirsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mkd func (newState *MkdirsResponse) SyncEffectiveFieldsDuringRead(existingState MkdirsResponse) { } -func (a MkdirsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a MkdirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1457,7 +1457,7 @@ func (newState *ObjectInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ObjectI func (newState *ObjectInfo) SyncEffectiveFieldsDuringRead(existingState ObjectInfo) { } -func (a ObjectInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a ObjectInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1491,7 +1491,7 @@ func (newState *PutAcl) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAcl) { func (newState *PutAcl) SyncEffectiveFieldsDuringRead(existingState PutAcl) { } -func (a PutAcl) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1514,7 +1514,7 @@ func (newState *PutAclResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Put func (newState *PutAclResponse) SyncEffectiveFieldsDuringRead(existingState PutAclResponse) { } -func (a PutAclResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1541,7 +1541,7 @@ func (newState *PutSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutSecre func (newState *PutSecret) SyncEffectiveFieldsDuringRead(existingState PutSecret) { } -func (a PutSecret) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1565,7 +1565,7 @@ func (newState *PutSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PutSecretResponse) SyncEffectiveFieldsDuringRead(existingState PutSecretResponse) { } -func (a PutSecretResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a PutSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1592,7 +1592,7 @@ func (newState *RepoAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *RepoAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState RepoAccessControlRequest) { } -func (a RepoAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1626,7 +1626,7 @@ func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState RepoAccessControlResponse) { } -func (a RepoAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(RepoPermission{}), } @@ -1670,7 +1670,7 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoInfo) func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) { } -func (a RepoInfo) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } @@ -1706,7 +1706,7 @@ func (newState *RepoPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rep func (newState *RepoPermission) SyncEffectiveFieldsDuringRead(existingState RepoPermission) { } -func (a RepoPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -1738,7 +1738,7 @@ func (newState *RepoPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RepoPermissions) SyncEffectiveFieldsDuringRead(existingState RepoPermissions) { } -func (a RepoPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RepoAccessControlResponse{}), } @@ -1768,7 +1768,7 @@ func (newState *RepoPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RepoPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState RepoPermissionsDescription) { } -func (a RepoPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1793,7 +1793,7 @@ func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState RepoPermissionsRequest) { } -func (a RepoPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a RepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RepoAccessControlRequest{}), } @@ -1823,7 +1823,7 @@ func (newState *SecretMetadata) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sec func (newState *SecretMetadata) SyncEffectiveFieldsDuringRead(existingState SecretMetadata) { } -func (a SecretMetadata) GetComplexFieldTypes() map[string]reflect.Type { +func (a SecretMetadata) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1851,7 +1851,7 @@ func (newState *SecretScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Secret func (newState *SecretScope) SyncEffectiveFieldsDuringRead(existingState SecretScope) { } -func (a SecretScope) GetComplexFieldTypes() map[string]reflect.Type { +func (a SecretScope) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "keyvault_metadata": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), } @@ -1884,7 +1884,7 @@ func (newState *SparseCheckout) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spa func (newState *SparseCheckout) SyncEffectiveFieldsDuringRead(existingState SparseCheckout) { } -func (a SparseCheckout) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparseCheckout) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "patterns": reflect.TypeOf(types.StringType), } @@ -1915,7 +1915,7 @@ func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringRead(existingState SparseCheckoutUpdate) { } -func (a SparseCheckoutUpdate) GetComplexFieldTypes() map[string]reflect.Type { +func (a SparseCheckoutUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "patterns": reflect.TypeOf(types.StringType), } @@ -1961,7 +1961,7 @@ func (newState *UpdateCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialsRequest) { } -func (a UpdateCredentialsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -1985,7 +1985,7 @@ func (newState *UpdateCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialsResponse) { } -func (a UpdateCredentialsResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2016,7 +2016,7 @@ func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRepoRequest) { } -func (a UpdateRepoRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckoutUpdate{}), } @@ -2044,7 +2044,7 @@ func (newState *UpdateRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRepoResponse) SyncEffectiveFieldsDuringRead(existingState UpdateRepoResponse) { } -func (a UpdateRepoResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a UpdateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2071,7 +2071,7 @@ func (newState *WorkspaceObjectAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *WorkspaceObjectAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectAccessControlRequest) { } -func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2105,7 +2105,7 @@ func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectAccessControlResponse) { } -func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(WorkspaceObjectPermission{}), } @@ -2139,7 +2139,7 @@ func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermission) { } -func (a WorkspaceObjectPermission) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceObjectPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.StringType), } @@ -2171,7 +2171,7 @@ func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissions) { } -func (a WorkspaceObjectPermissions) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WorkspaceObjectAccessControlResponse{}), } @@ -2201,7 +2201,7 @@ func (newState *WorkspaceObjectPermissionsDescription) SyncEffectiveFieldsDuring func (newState *WorkspaceObjectPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissionsDescription) { } -func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } @@ -2228,7 +2228,7 @@ func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissionsRequest) { } -func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes() map[string]reflect.Type { +func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WorkspaceObjectAccessControlRequest{}), } From 733644723593e3c06fd29bf6fde48469aa1cdb3b Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 17:28:31 +0100 Subject: [PATCH 33/91] working --- .codegen/model.go.tmpl | 10 +- .../pluginfw/converters/converters_test.go | 62 ++++++-- .../providers/pluginfw/converters/go_to_tf.go | 76 ++++++---- .../providers/pluginfw/converters/tf_to_go.go | 135 +++++++++++------- 4 files changed, 191 insertions(+), 92 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index 7d7e6cbdf3..4027365416 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -117,11 +117,11 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} {{- else -}} {{- if .IsExternal -}}{{.Package.Name}}.{{- end -}} - {{- if or .IsString .Enum -}}types.StringType - {{- else if .IsBool -}}types.BoolType - {{- else if .IsInt64 -}}types.Int64Type - {{- else if .IsFloat64 -}}types.Float64Type - {{- else if .IsInt -}}types.Int64Type + {{- if or .IsString .Enum -}}types.String{} + {{- else if .IsBool -}}types.Bool{} + {{- else if .IsInt64 -}}types.Int64{} + {{- else if .IsFloat64 -}}types.Float64{} + {{- else if .IsInt -}}types.Int64{} {{- else if .IsAny -}}struct{}{} {{- else if .IsObject -}}{{.PascalName}}{} {{- end -}} diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index a30d78cf0b..618260c519 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -38,10 +38,10 @@ func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T "no_pointer_nested": reflect.TypeOf(DummyNestedTfSdk{}), "nested_list": reflect.TypeOf(DummyNestedTfSdk{}), "nested_pointer_list": reflect.TypeOf(DummyNestedTfSdk{}), - "map": reflect.TypeOf(""), + "map": reflect.TypeOf(types.String{}), "nested_map": reflect.TypeOf(DummyNestedTfSdk{}), - "repeated": reflect.TypeOf(int64(0)), - "attributes": reflect.TypeOf(""), + "repeated": reflect.TypeOf(types.Int64{}), + "attributes": reflect.TypeOf(types.String{}), "slice_struct": reflect.TypeOf(DummyNestedTfSdk{}), "slice_struct_ptr": reflect.TypeOf(DummyNestedTfSdk{}), } @@ -145,6 +145,45 @@ func diagToString(d diag.Diagnostics) string { return b.String() } +func populateEmptyFields(c DummyTfSdk) DummyTfSdk { + complexFields := c.GetComplexFieldTypes(context.Background()) + v := reflect.ValueOf(&c).Elem() + for i := 0; i < v.NumField(); i++ { + name := v.Type().Field(i).Name + tfsdkName := v.Type().Field(i).Tag.Get("tfsdk") + complexType, ok := complexFields[tfsdkName] + if !ok { + continue + } + field := v.FieldByName(name) + if !field.IsZero() { + continue + } + innerVal := reflect.New(complexType).Elem().Interface() + var typ attr.Type + if ot, ok := innerVal.(interface { + ToObjectType(context.Context) types.ObjectType + }); ok { + typ = ot.ToObjectType(context.Background()) + } else { + typ = innerVal.(attr.Value).Type(context.Background()) + } + switch field.Type() { + case reflect.TypeOf(types.List{}): + value := types.ListNull(typ) + field.Set(reflect.ValueOf(value)) + case reflect.TypeOf(types.Map{}): + value := types.MapNull(typ) + field.Set(reflect.ValueOf(value)) + case reflect.TypeOf(types.Object{}): + objectType := typ.(types.ObjectType) + value := types.ObjectNull(objectType.AttrTypes) + field.Set(reflect.ValueOf(value)) + } + } + return v.Interface().(DummyTfSdk) +} + // Function to construct individual test case with a pair of matching tfSdkStruct and gosdkStruct. // Verifies that the conversion both ways are working as expected. func RunConverterTest(t *testing.T, description string, tfSdkStruct DummyTfSdk, goSdkStruct DummyGoSdk) { @@ -153,11 +192,14 @@ func RunConverterTest(t *testing.T, description string, tfSdkStruct DummyTfSdk, if d.HasError() { t.Errorf("tfsdk to gosdk conversion: %s", diagToString(d)) } - assert.True(t, reflect.DeepEqual(convertedGoSdkStruct, goSdkStruct), fmt.Sprintf("tfsdk to gosdk conversion - %s", description)) + assert.Equal(t, goSdkStruct, convertedGoSdkStruct, fmt.Sprintf("tfsdk to gosdk conversion - %s", description)) convertedTfSdkStruct := DummyTfSdk{} - assert.True(t, !GoSdkToTfSdkStruct(context.Background(), goSdkStruct, &convertedTfSdkStruct).HasError()) - assert.True(t, reflect.DeepEqual(convertedTfSdkStruct, tfSdkStruct), fmt.Sprintf("gosdk to tfsdk conversion - %s", description)) + d = GoSdkToTfSdkStruct(context.Background(), goSdkStruct, &convertedTfSdkStruct) + if d.HasError() { + t.Errorf("gosdk to tfsdk conversion: %s", diagToString(d)) + } + assert.Equal(t, populateEmptyFields(tfSdkStruct), convertedTfSdkStruct, fmt.Sprintf("gosdk to tfsdk conversion - %s", description)) } func TestTfSdkToGoSdkStructConversionFailure(t *testing.T) { @@ -249,7 +291,7 @@ var tests = []struct { Name: "def", Enabled: true, ForceSendFields: []string{"Name", "Enabled"}, - }}, + }, ForceSendFields: []string{"NoPointerNested"}}, }, { "list conversion", @@ -259,7 +301,7 @@ var tests = []struct { { "map conversion", DummyTfSdk{Attributes: types.MapValueMust(types.StringType, map[string]attr.Value{"key": types.StringValue("value")})}, - DummyGoSdk{Attributes: map[string]string{"key": "value"}}, + DummyGoSdk{Attributes: map[string]string{"key": "value"}, ForceSendFields: []string{"Attributes"}}, }, { "nested list conversion", @@ -311,7 +353,7 @@ var tests = []struct { Enabled: false, ForceSendFields: []string{"Name", "Enabled"}, }, - }}, + }, ForceSendFields: []string{"NestedMap"}}, }, { "list representation of struct pointer conversion", // we use list with one element in the tfsdk to represent struct in gosdk @@ -327,7 +369,7 @@ var tests = []struct { Name: "def", Enabled: true, ForceSendFields: []string{"Name", "Enabled"}, - }}, + }, ForceSendFields: []string{"SliceStructPtr"}}, }, } diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index 24c578a9e1..c90a225277 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -87,7 +87,8 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ destField := destVal.FieldByName(srcFieldName) destFieldType, ok := destVal.Type().FieldByName(field.StructField.Name) if !ok { - panic(fmt.Errorf("destination struct does not have field %s. %s", srcFieldName, common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("destination struct does not have field %s. %s", srcFieldName, common.TerraformBugErrorMessage)) + return } destFieldName := destFieldType.Tag.Get("tfsdk") if destFieldName == "-" { @@ -123,27 +124,22 @@ func goSdkToTfSdkSingleField( srcFieldValue := srcField.Interface() - if srcFieldValue == nil { - return nil - } - - if srcField.Kind() == reflect.Ptr { - // Skip nils, but make sure to set the destination fields of type list to an empty list. - if srcField.IsNil() { - // If the destination field is a types.List, treat the source field as an empty slice. - if destField.Type() == reflect.TypeOf(types.List{}) { - listType := innerType.(types.ListType) - emptyList := types.ListNull(listType.ElemType) - destField.Set(reflect.ValueOf(emptyList)) - } - return nil + // Skip nils, but make sure to set the destination fields of type list to an empty list. + if srcField.Kind() == reflect.Ptr && srcField.IsNil() { + // If the destination field is a types.List, treat the source field as an empty slice. + if destField.Type() == reflect.TypeOf(types.List{}) { + listType := innerType.(types.ListType) + emptyList := types.ListNull(listType.ElemType) + destField.Set(reflect.ValueOf(emptyList)) } - srcField = srcField.Elem() + return nil } switch srcField.Kind() { case reflect.Ptr: - panic(fmt.Errorf("pointer to pointer is not supported: %s. %s", srcField.Type().Name(), common.TerraformBugErrorMessage)) + // Dereference the pointer and continue. + srcField = srcField.Elem() + d.Append(goSdkToTfSdkSingleField(ctx, srcField, destField, forceSendField, innerType, complexFieldType)...) case reflect.Bool: boolVal := srcFieldValue.(bool) // check if the value is non-zero or if the field is in the forceSendFields list @@ -193,12 +189,13 @@ func goSdkToTfSdkSingleField( if srcField.IsZero() { // If the destination field is a types.List, treat the source field as an empty slice. if destField.Type() == reflect.TypeOf(types.List{}) { - emptyList := types.ListNull(innerType) + listType := innerType.(types.ListType) + emptyList := types.ListNull(listType.ElemType) destField.Set(reflect.ValueOf(emptyList)) - return nil + return } // Skip zeros - return nil + return } // If the destination field is a types.List, treat the source field as a slice with length 1 @@ -211,7 +208,7 @@ func goSdkToTfSdkSingleField( // Otherwise, the destination field is a types.Object. Convert the nested struct to the corresponding // TFSDK struct, then set the destination field to the object - dest := reflect.New(complexFieldType).Elem() + dest := reflect.New(complexFieldType).Interface() d.Append(GoSdkToTfSdkStruct(ctx, srcFieldValue, dest)...) if d.HasError() { return @@ -221,7 +218,7 @@ func goSdkToTfSdkSingleField( d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not an object type: %s. %s", innerType, common.TerraformBugErrorMessage)) return } - objectVal, ds := types.ObjectValueFrom(ctx, objectType.AttrTypes, dest.Interface()) + objectVal, ds := types.ObjectValueFrom(ctx, objectType.AttrTypes, dest) d.Append(ds...) if d.HasError() { return @@ -233,12 +230,23 @@ func goSdkToTfSdkSingleField( d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a list type: %s. %s", innerType, common.TerraformBugErrorMessage)) return } + if srcField.Len() == 0 { + // If the destination field is a types.List, treat the source field as an empty slice. + emptyList := types.ListNull(listType.ElemType) + destField.Set(reflect.ValueOf(emptyList)) + return + } // Convert each element of the slice to the corresponding inner type. elements := make([]any, 0, srcField.Len()) for i := 0; i < srcField.Len(); i++ { - element := reflect.New(complexFieldType).Elem() - d.Append(goSdkToTfSdkSingleField(ctx, srcField.Index(i), element, true, listType.ElemType, complexFieldType)...) + element := reflect.New(complexFieldType) + switch complexFieldType { + case reflect.TypeOf(types.String{}), reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}): + d.Append(goSdkToTfSdkSingleField(ctx, srcField.Index(i), element.Elem(), true, listType.ElemType, complexFieldType)...) + default: + d.Append(GoSdkToTfSdkStruct(ctx, srcField.Index(i).Interface(), element.Interface())...) + } if d.HasError() { return } @@ -258,18 +266,28 @@ func goSdkToTfSdkSingleField( d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a map type: %s. %s", innerType, common.TerraformBugErrorMessage)) return } + if srcField.Len() == 0 { + // If the destination field is a types.Map, treat the source field as an empty map. + emptyMap := types.MapNull(mapType.ElemType) + destField.Set(reflect.ValueOf(emptyMap)) + return + } // Convert each key-value pair of the map to the corresponding inner type. - destMap := map[string]attr.Value{} + destMap := map[string]any{} for _, key := range srcField.MapKeys() { srcMapValue := srcField.MapIndex(key) - destMapValue := reflect.New(destField.Type().Elem()).Elem() - destMapKey := reflect.ValueOf(key.Interface()) - d.Append(goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue, true, mapType.ElemType, complexFieldType)...) + destMapValue := reflect.New(complexFieldType) + switch complexFieldType { + case reflect.TypeOf(types.String{}), reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}): + d.Append(goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue.Elem(), true, mapType.ElemType, complexFieldType)...) + default: + d.Append(GoSdkToTfSdkStruct(ctx, srcMapValue.Interface(), destMapValue.Interface())...) + } if d.HasError() { return } - destMap[destMapKey.String()] = destMapValue.Interface().(attr.Value) + destMap[key.String()] = destMapValue.Interface() } // Construct the Terraform value and set it. diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 419cc4c110..449f6ccdf0 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -102,50 +102,36 @@ func tfSdkToGoSdkSingleField( return } - if srcField.Kind() == reflect.Struct { - d.Append(tfsdkToGoSdkStructField(srcField, destField, srcFieldName, forceSendFieldsField, ctx, innerType)...) + if srcField.Kind() != reflect.Struct { + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", srcField.Interface(), common.TerraformBugErrorMessage)) return } - d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", srcField.Interface(), common.TerraformBugErrorMessage)) - return -} -// Returns a reflect.Value of the enum type with the value set to the given string. -func convertToEnumValue(v types.String, destType reflect.Type) reflect.Value { - // Find the Set method - destVal := reflect.New(destType) - setMethod := destVal.MethodByName("Set") - if !setMethod.IsValid() { - panic(fmt.Sprintf("set method not found on enum type: %s. %s", destType.Name(), common.TerraformBugErrorMessage)) + // The field being processed must be an attr.Value (a field of the TF SDK struct). + v, ok := srcField.Interface().(attr.Value) + if !ok { + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", v, common.TerraformBugErrorMessage)) + return } - // Prepare the argument for the Set method - arg := reflect.ValueOf(v.ValueString()) - - // Call the Set method - result := setMethod.Call([]reflect.Value{arg}) - if len(result) != 0 { - if err, ok := result[0].Interface().(error); ok && err != nil { - panic(fmt.Sprintf("%s. %s", err, common.TerraformBugErrorMessage)) - } + if v.IsUnknown() { + return } - return destVal.Elem() + if shouldSetForceSendFields(v, destField) { + addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) + } + + d.Append(tfsdkToGoSdkStructField(ctx, v, destField, srcFieldName, forceSendFieldsField, innerType)...) + return } func tfsdkToGoSdkStructField( - srcField reflect.Value, + ctx context.Context, + srcFieldValue attr.Value, destField reflect.Value, srcFieldName string, forceSendFieldsField *reflect.Value, - ctx context.Context, innerType reflect.Type) (d diag.Diagnostics) { - srcFieldValue := srcField.Interface().(attr.Value) - if srcFieldValue.IsUnknown() { - return - } - if !srcFieldValue.IsNull() { - addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) - } switch v := srcFieldValue.(type) { case types.Bool: destField.SetBool(v.ValueBool()) @@ -158,12 +144,11 @@ func tfsdkToGoSdkStructField( // This is the case for enum. // Skip unset value. - if srcField.IsZero() || v.ValueString() == "" { + if v.ValueString() == "" { return } destVal := convertToEnumValue(v, destField.Type()) - // We don't need to set ForceSendFields for enums because the value is never going to be a zero value (empty string). destField.Set(destVal) } else { destField.SetString(v.ValueString()) @@ -175,19 +160,19 @@ func tfsdkToGoSdkStructField( } // Read the nested elements into the TFSDK struct slice - innerValue := reflect.MakeSlice(reflect.SliceOf(innerType), 0, len(v.Elements())).Interface() - d.Append(v.ElementsAs(ctx, &innerValue, true)...) + // This is a slice of either TFSDK structs or bools, ints, strings, and floats from the TF plugin framework types. + innerValue := reflect.New(reflect.SliceOf(innerType)) + d.Append(v.ElementsAs(ctx, innerValue.Interface(), true)...) if d.HasError() { return } - innerValues := innerValue.([]interface{}) // Recursively call TFSDK to GOSDK conversion for each element in the list var destInnerType reflect.Type if destField.Type().Kind() == reflect.Slice { destInnerType = destField.Type().Elem() } else { - if len(innerValues) > 1 { + if innerValue.Elem().Len() > 1 { d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("The length of a slice can not be greater than 1 if it is representing a struct, %s", common.TerraformBugErrorMessage)) return } @@ -199,14 +184,21 @@ func tfsdkToGoSdkStructField( } } - converted := reflect.MakeSlice(reflect.SliceOf(destInnerType), 0, len(innerValues)) - for _, vv := range innerValues { - next := reflect.New(destInnerType).Elem() - d.Append(tfSdkToGoSdkSingleField(ctx, reflect.ValueOf(vv), next, srcFieldName, forceSendFieldsField, innerType)...) + converted := reflect.MakeSlice(reflect.SliceOf(destInnerType), 0, innerValue.Elem().Len()) + for i := 0; i < innerValue.Elem().Len(); i++ { + // Convert from the TF Value to our TFSDK struct + vv := innerValue.Elem().Index(i).Interface() + nextDest := reflect.New(destInnerType) + switch typedVv := vv.(type) { + case types.Bool, types.String, types.Int64, types.Float64: + d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), srcFieldName, forceSendFieldsField, innerType)...) + default: + d.Append(TfSdkToGoSdkStruct(ctx, vv, nextDest.Interface())...) + } if d.HasError() { return } - converted = reflect.Append(converted, next) + converted = reflect.Append(converted, reflect.Indirect(nextDest)) } if destField.Type().Kind() == reflect.Slice { @@ -223,21 +215,29 @@ func tfsdkToGoSdkStructField( } // Read the nested elements into the TFSDK struct map - innerValue := reflect.MakeMap(reflect.MapOf(reflect.TypeOf(""), innerType)) + // This is a map from string to either TFSDK structs or bools, ints, strings, and floats from the TF plugin framework types. + innerValue := reflect.New(reflect.MapOf(reflect.TypeOf(""), innerType)) d.Append(v.ElementsAs(ctx, innerValue.Interface(), true)...) if d.HasError() { return } // Recursively call TFSDK to GOSDK conversion for each element in the map - converted := reflect.MakeMap(destField.Type()) - for _, key := range innerValue.MapKeys() { - next := reflect.New(innerType).Elem() - d.Append(tfSdkToGoSdkSingleField(ctx, innerValue.MapIndex(key), next, srcFieldName, forceSendFieldsField, innerType)...) + destType := destField.Type().Elem() + converted := reflect.MakeMap(reflect.MapOf(reflect.TypeOf(""), destType)) + for _, key := range innerValue.Elem().MapKeys() { + vv := innerValue.Elem().MapIndex(key).Interface() + nextDest := reflect.New(destType) + switch typedVv := vv.(type) { + case types.Bool, types.String, types.Int64, types.Float64: + d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), srcFieldName, forceSendFieldsField, innerType)...) + default: + d.Append(TfSdkToGoSdkStruct(ctx, vv, nextDest.Interface())...) + } if d.HasError() { return } - converted.SetMapIndex(key, next) + converted.SetMapIndex(key, nextDest.Elem()) } destField.Set(converted) @@ -253,6 +253,23 @@ func tfsdkToGoSdkStructField( return } +func shouldSetForceSendFields(srcFieldValue attr.Value, destField reflect.Value) bool { + if srcFieldValue.IsNull() { + return false + } + // Don't set forceSendFields for enums + // We don't need to set ForceSendFields for enums because the value is never going to be a zero value (empty string). + if _, ok := srcFieldValue.(types.String); ok && destField.Type().Name() != "string" { + return false + } + // Don't set forceSendFields for lists + if _, ok := srcFieldValue.(types.List); ok && destField.Kind() == reflect.Slice { + return false + } + + return true +} + func addToForceSendFields(ctx context.Context, fieldName string, forceSendFieldsField *reflect.Value) { if forceSendFieldsField == nil || !forceSendFieldsField.IsValid() || !forceSendFieldsField.CanSet() { tflog.Debug(ctx, fmt.Sprintf("[Debug] forceSendFieldsField is nil, invalid or not settable. %s", fieldName)) @@ -268,3 +285,25 @@ func addToForceSendFields(ctx context.Context, fieldName string, forceSendFields forceSendFields = append(forceSendFields, fieldName) forceSendFieldsField.Set(reflect.ValueOf(forceSendFields)) } + +// Returns a reflect.Value of the enum type with the value set to the given string. +func convertToEnumValue(v types.String, destType reflect.Type) reflect.Value { + // Find the Set method + destVal := reflect.New(destType) + setMethod := destVal.MethodByName("Set") + if !setMethod.IsValid() { + panic(fmt.Sprintf("set method not found on enum type: %s. %s", destType.Name(), common.TerraformBugErrorMessage)) + } + + // Prepare the argument for the Set method + arg := reflect.ValueOf(v.ValueString()) + + // Call the Set method + result := setMethod.Call([]reflect.Value{arg}) + if len(result) != 0 { + if err, ok := result[0].Interface().(error); ok && err != nil { + panic(fmt.Sprintf("%s. %s", err, common.TerraformBugErrorMessage)) + } + } + return destVal.Elem() +} From cfdec91611bdd4aa2f65eddcfdd4859aea0fa967 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 18:54:42 +0100 Subject: [PATCH 34/91] more work --- .../tfschema/customizable_schema_test.go | 4 +- internal/service/apps_tf/model.go | 2 +- internal/service/billing_tf/model.go | 8 +- internal/service/catalog_tf/model.go | 72 +++++----- internal/service/compute_tf/model.go | 98 ++++++------- internal/service/iam_tf/model.go | 24 ++-- internal/service/jobs_tf/model.go | 136 +++++++++--------- internal/service/marketplace_tf/model.go | 26 ++-- internal/service/ml_tf/model.go | 28 ++-- internal/service/oauth2_tf/model.go | 14 +- internal/service/pipelines_tf/model.go | 40 +++--- internal/service/provisioning_tf/model.go | 26 ++-- internal/service/serving_tf/model.go | 24 ++-- internal/service/settings_tf/model.go | 30 ++-- internal/service/sharing_tf/model.go | 6 +- internal/service/sql_tf/model.go | 42 +++--- internal/service/vectorsearch_tf/model.go | 14 +- internal/service/workspace_tf/model.go | 8 +- 18 files changed, 301 insertions(+), 301 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 27350ddb4a..c33c234c32 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -22,7 +22,7 @@ type TestTfSdk struct { Map types.Map `tfsdk:"map" tf:"optional"` } -func (TestTfSdk) GetComplexFieldTypes() map[string]reflect.Type { +func (TestTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "nested": reflect.TypeOf(NestedTfSdk{}), "nested_slice_object": reflect.TypeOf(NestedTfSdk{}), @@ -50,7 +50,7 @@ type NestedTfSdk struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } -func (NestedTfSdk) GetComplexFieldTypes() map[string]reflect.Type { +func (NestedTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 51c9b1b84b..fed5279844 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -302,7 +302,7 @@ func (newState *AppPermission) SyncEffectiveFieldsDuringRead(existingState AppPe func (a AppPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 9db83eb6b3..fcd3b2a5b7 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -196,7 +196,7 @@ func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringRead(e func (a BudgetConfigurationFilterClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "values": reflect.TypeOf(types.StringType), + "values": reflect.TypeOf(types.String{}), } } @@ -254,7 +254,7 @@ func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsD func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "values": reflect.TypeOf(types.Int64Type), + "values": reflect.TypeOf(types.Int64{}), } } @@ -567,7 +567,7 @@ func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringR func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "workspace_ids_filter": reflect.TypeOf(types.Int64Type), + "workspace_ids_filter": reflect.TypeOf(types.Int64{}), } } @@ -997,7 +997,7 @@ func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existing func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_status": reflect.TypeOf(LogDeliveryStatus{}), - "workspace_ids_filter": reflect.TypeOf(types.Int64Type), + "workspace_ids_filter": reflect.TypeOf(types.Int64{}), } } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index e5c94e0eae..2b1e6ea764 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -788,8 +788,8 @@ func (newState *CatalogInfo) SyncEffectiveFieldsDuringRead(existingState Catalog func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "options": reflect.TypeOf(types.StringType), - "properties": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.String{}), + "properties": reflect.TypeOf(types.String{}), "provisioning_info": reflect.TypeOf(ProvisioningInfo{}), } } @@ -940,7 +940,7 @@ func (newState *ColumnMask) SyncEffectiveFieldsDuringRead(existingState ColumnMa func (a ColumnMask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "using_column_names": reflect.TypeOf(types.StringType), + "using_column_names": reflect.TypeOf(types.String{}), } } @@ -1005,8 +1005,8 @@ func (newState *ConnectionInfo) SyncEffectiveFieldsDuringRead(existingState Conn func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "options": reflect.TypeOf(types.StringType), - "properties": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.String{}), + "properties": reflect.TypeOf(types.String{}), "provisioning_info": reflect.TypeOf(ProvisioningInfo{}), } } @@ -1111,8 +1111,8 @@ func (newState *CreateCatalog) SyncEffectiveFieldsDuringRead(existingState Creat func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "options": reflect.TypeOf(types.StringType), - "properties": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.String{}), + "properties": reflect.TypeOf(types.String{}), } } @@ -1159,8 +1159,8 @@ func (newState *CreateConnection) SyncEffectiveFieldsDuringRead(existingState Cr func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "options": reflect.TypeOf(types.StringType), - "properties": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.String{}), + "properties": reflect.TypeOf(types.String{}), } } @@ -1540,7 +1540,7 @@ func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl "inference_log": reflect.TypeOf(MonitorInferenceLog{}), "notifications": reflect.TypeOf(MonitorNotifications{}), "schedule": reflect.TypeOf(MonitorCronSchedule{}), - "slicing_exprs": reflect.TypeOf(types.StringType), + "slicing_exprs": reflect.TypeOf(types.String{}), "snapshot": reflect.TypeOf(MonitorSnapshot{}), "time_series": reflect.TypeOf(MonitorTimeSeries{}), } @@ -1687,7 +1687,7 @@ func (newState *CreateSchema) SyncEffectiveFieldsDuringRead(existingState Create func (a CreateSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.String{}), } } @@ -1964,7 +1964,7 @@ func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringRead(existing func (a CurrentWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "workspaces": reflect.TypeOf(types.Int64Type), + "workspaces": reflect.TypeOf(types.Int64{}), } } @@ -2605,7 +2605,7 @@ func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringRead(exi func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "delta_runtime_properties": reflect.TypeOf(types.StringType), + "delta_runtime_properties": reflect.TypeOf(types.String{}), } } @@ -3082,8 +3082,8 @@ func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringRead(existingStat func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "child_columns": reflect.TypeOf(types.StringType), - "parent_columns": reflect.TypeOf(types.StringType), + "child_columns": reflect.TypeOf(types.String{}), + "parent_columns": reflect.TypeOf(types.String{}), } } @@ -3408,7 +3408,7 @@ func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFie func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "resources": reflect.TypeOf(types.StringType), + "resources": reflect.TypeOf(types.String{}), } } @@ -4360,7 +4360,7 @@ func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuri func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "workspace_ids": reflect.TypeOf(types.Int64Type), + "workspace_ids": reflect.TypeOf(types.Int64{}), } } @@ -5762,7 +5762,7 @@ func (newState *MonitorDestination) SyncEffectiveFieldsDuringRead(existingState func (a MonitorDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "email_addresses": reflect.TypeOf(types.StringType), + "email_addresses": reflect.TypeOf(types.String{}), } } @@ -5815,7 +5815,7 @@ func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringRead(existingState func (a MonitorInferenceLog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "granularities": reflect.TypeOf(types.StringType), + "granularities": reflect.TypeOf(types.String{}), } } @@ -5900,7 +5900,7 @@ func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec "inference_log": reflect.TypeOf(MonitorInferenceLog{}), "notifications": reflect.TypeOf(MonitorNotifications{}), "schedule": reflect.TypeOf(MonitorCronSchedule{}), - "slicing_exprs": reflect.TypeOf(types.StringType), + "slicing_exprs": reflect.TypeOf(types.String{}), "snapshot": reflect.TypeOf(MonitorSnapshot{}), "time_series": reflect.TypeOf(MonitorTimeSeries{}), } @@ -5982,7 +5982,7 @@ func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState Monit func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "input_columns": reflect.TypeOf(types.StringType), + "input_columns": reflect.TypeOf(types.String{}), } } @@ -6144,7 +6144,7 @@ func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringRead(existingState M func (a MonitorTimeSeries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "granularities": reflect.TypeOf(types.StringType), + "granularities": reflect.TypeOf(types.String{}), } } @@ -6263,7 +6263,7 @@ func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringRead(existingState Onl func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "primary_key_columns": reflect.TypeOf(types.StringType), + "primary_key_columns": reflect.TypeOf(types.String{}), "run_continuously": reflect.TypeOf(OnlineTableSpecContinuousSchedulingPolicy{}), "run_triggered": reflect.TypeOf(OnlineTableSpecTriggeredSchedulingPolicy{}), } @@ -6401,8 +6401,8 @@ func (newState *PermissionsChange) SyncEffectiveFieldsDuringRead(existingState P func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "add": reflect.TypeOf(types.StringType), - "remove": reflect.TypeOf(types.StringType), + "add": reflect.TypeOf(types.String{}), + "remove": reflect.TypeOf(types.String{}), } } @@ -6500,7 +6500,7 @@ func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringRead(existingStat func (a PrimaryKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "child_columns": reflect.TypeOf(types.StringType), + "child_columns": reflect.TypeOf(types.String{}), } } @@ -6530,7 +6530,7 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "privileges": reflect.TypeOf(types.StringType), + "privileges": reflect.TypeOf(types.String{}), } } @@ -6922,7 +6922,7 @@ func (newState *SchemaInfo) SyncEffectiveFieldsDuringRead(existingState SchemaIn func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), - "properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.String{}), } } @@ -7341,7 +7341,7 @@ func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. "delta_runtime_properties_kvpairs": reflect.TypeOf(DeltaRuntimePropertiesKvPairs{}), "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), "encryption_details": reflect.TypeOf(EncryptionDetails{}), - "properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.String{}), "row_filter": reflect.TypeOf(TableRowFilter{}), "table_constraints": reflect.TypeOf(TableConstraint{}), "view_dependencies": reflect.TypeOf(DependencyList{}), @@ -7420,7 +7420,7 @@ func (newState *TableRowFilter) SyncEffectiveFieldsDuringRead(existingState Tabl func (a TableRowFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "input_column_names": reflect.TypeOf(types.StringType), + "input_column_names": reflect.TypeOf(types.String{}), } } @@ -7631,7 +7631,7 @@ func (newState *UpdateCatalog) SyncEffectiveFieldsDuringRead(existingState Updat func (a UpdateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.String{}), } } @@ -7670,7 +7670,7 @@ func (newState *UpdateConnection) SyncEffectiveFieldsDuringRead(existingState Up func (a UpdateConnection) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "options": reflect.TypeOf(types.StringType), + "options": reflect.TypeOf(types.String{}), } } @@ -8004,7 +8004,7 @@ func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl "inference_log": reflect.TypeOf(MonitorInferenceLog{}), "notifications": reflect.TypeOf(MonitorNotifications{}), "schedule": reflect.TypeOf(MonitorCronSchedule{}), - "slicing_exprs": reflect.TypeOf(types.StringType), + "slicing_exprs": reflect.TypeOf(types.String{}), "snapshot": reflect.TypeOf(MonitorSnapshot{}), "time_series": reflect.TypeOf(MonitorTimeSeries{}), } @@ -8153,7 +8153,7 @@ func (newState *UpdateSchema) SyncEffectiveFieldsDuringRead(existingState Update func (a UpdateSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.String{}), } } @@ -8325,8 +8325,8 @@ func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingS func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "assign_workspaces": reflect.TypeOf(types.Int64Type), - "unassign_workspaces": reflect.TypeOf(types.Int64Type), + "assign_workspaces": reflect.TypeOf(types.Int64{}), + "unassign_workspaces": reflect.TypeOf(types.Int64{}), } } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 953fd0f14d..f5ef0d6657 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -459,7 +459,7 @@ func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringRead(existingSta func (a CloudProviderNodeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "status": reflect.TypeOf(types.StringType), + "status": reflect.TypeOf(types.String{}), } } @@ -688,13 +688,13 @@ func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string] "aws_attributes": reflect.TypeOf(AwsAttributes{}), "azure_attributes": reflect.TypeOf(AzureAttributes{}), "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "docker_image": reflect.TypeOf(DockerImage{}), "gcp_attributes": reflect.TypeOf(GcpAttributes{}), "init_scripts": reflect.TypeOf(InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), + "ssh_public_keys": reflect.TypeOf(types.String{}), "workload_type": reflect.TypeOf(WorkloadType{}), } } @@ -773,7 +773,7 @@ func (newState *ClusterCompliance) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterCompliance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.String{}), } } @@ -1018,17 +1018,17 @@ func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]ref "azure_attributes": reflect.TypeOf(AzureAttributes{}), "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), "cluster_log_status": reflect.TypeOf(LogSyncStatus{}), - "custom_tags": reflect.TypeOf(types.StringType), - "default_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), + "default_tags": reflect.TypeOf(types.String{}), "docker_image": reflect.TypeOf(DockerImage{}), "driver": reflect.TypeOf(SparkNode{}), "executors": reflect.TypeOf(SparkNode{}), "gcp_attributes": reflect.TypeOf(GcpAttributes{}), "init_scripts": reflect.TypeOf(InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), "spec": reflect.TypeOf(ClusterSpec{}), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "ssh_public_keys": reflect.TypeOf(types.String{}), "termination_reason": reflect.TypeOf(TerminationReason{}), "workload_type": reflect.TypeOf(WorkloadType{}), } @@ -1250,7 +1250,7 @@ func (newState *ClusterPermission) SyncEffectiveFieldsDuringRead(existingState C func (a ClusterPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1439,7 +1439,7 @@ func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringRead(existingS func (a ClusterPolicyPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1783,13 +1783,13 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec "aws_attributes": reflect.TypeOf(AwsAttributes{}), "azure_attributes": reflect.TypeOf(AzureAttributes{}), "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "docker_image": reflect.TypeOf(DockerImage{}), "gcp_attributes": reflect.TypeOf(GcpAttributes{}), "init_scripts": reflect.TypeOf(InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), + "ssh_public_keys": reflect.TypeOf(types.String{}), "workload_type": reflect.TypeOf(WorkloadType{}), } } @@ -2188,13 +2188,13 @@ func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl "azure_attributes": reflect.TypeOf(AzureAttributes{}), "clone_from": reflect.TypeOf(CloneCluster{}), "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "docker_image": reflect.TypeOf(DockerImage{}), "gcp_attributes": reflect.TypeOf(GcpAttributes{}), "init_scripts": reflect.TypeOf(InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), + "ssh_public_keys": reflect.TypeOf(types.String{}), "workload_type": reflect.TypeOf(WorkloadType{}), } } @@ -2375,11 +2375,11 @@ func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "disk_spec": reflect.TypeOf(DiskSpec{}), "gcp_attributes": reflect.TypeOf(InstancePoolGcpAttributes{}), "preloaded_docker_images": reflect.TypeOf(DockerImage{}), - "preloaded_spark_versions": reflect.TypeOf(types.StringType), + "preloaded_spark_versions": reflect.TypeOf(types.String{}), } } @@ -3147,13 +3147,13 @@ func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflec "aws_attributes": reflect.TypeOf(AwsAttributes{}), "azure_attributes": reflect.TypeOf(AzureAttributes{}), "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "docker_image": reflect.TypeOf(DockerImage{}), "gcp_attributes": reflect.TypeOf(GcpAttributes{}), "init_scripts": reflect.TypeOf(InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), + "ssh_public_keys": reflect.TypeOf(types.String{}), "workload_type": reflect.TypeOf(WorkloadType{}), } } @@ -3278,7 +3278,7 @@ func (newState *EditInstancePool) SyncEffectiveFieldsDuringRead(existingState Ed func (a EditInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), } } @@ -3507,7 +3507,7 @@ func (newState *Environment) SyncEffectiveFieldsDuringRead(existingState Environ func (a Environment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dependencies": reflect.TypeOf(types.StringType), + "dependencies": reflect.TypeOf(types.String{}), } } @@ -3753,7 +3753,7 @@ func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringRead(exis func (a GetClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.String{}), } } @@ -3997,7 +3997,7 @@ func (newState *GetEvents) SyncEffectiveFieldsDuringRead(existingState GetEvents func (a GetEvents) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "event_types": reflect.TypeOf(types.StringType), + "event_types": reflect.TypeOf(types.String{}), } } @@ -4165,12 +4165,12 @@ func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "custom_tags": reflect.TypeOf(types.StringType), - "default_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), + "default_tags": reflect.TypeOf(types.String{}), "disk_spec": reflect.TypeOf(DiskSpec{}), "gcp_attributes": reflect.TypeOf(InstancePoolGcpAttributes{}), "preloaded_docker_images": reflect.TypeOf(DockerImage{}), - "preloaded_spark_versions": reflect.TypeOf(types.StringType), + "preloaded_spark_versions": reflect.TypeOf(types.String{}), "stats": reflect.TypeOf(InstancePoolStats{}), "status": reflect.TypeOf(InstancePoolStatus{}), } @@ -4938,12 +4938,12 @@ func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), "azure_attributes": reflect.TypeOf(InstancePoolAzureAttributes{}), - "custom_tags": reflect.TypeOf(types.StringType), - "default_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), + "default_tags": reflect.TypeOf(types.String{}), "disk_spec": reflect.TypeOf(DiskSpec{}), "gcp_attributes": reflect.TypeOf(InstancePoolGcpAttributes{}), "preloaded_docker_images": reflect.TypeOf(DockerImage{}), - "preloaded_spark_versions": reflect.TypeOf(types.StringType), + "preloaded_spark_versions": reflect.TypeOf(types.String{}), "stats": reflect.TypeOf(InstancePoolStats{}), "status": reflect.TypeOf(InstancePoolStatus{}), } @@ -5143,7 +5143,7 @@ func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringRead(existingSt func (a InstancePoolPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -5441,7 +5441,7 @@ func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringRead(existingState L func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library": reflect.TypeOf(Library{}), - "messages": reflect.TypeOf(types.StringType), + "messages": reflect.TypeOf(types.String{}), } } @@ -5503,7 +5503,7 @@ func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringRead(existi func (a ListAvailableZonesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "zones": reflect.TypeOf(types.StringType), + "zones": reflect.TypeOf(types.String{}), } } @@ -5636,8 +5636,8 @@ func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringRead(existingStat func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "cluster_sources": reflect.TypeOf(types.StringType), - "cluster_states": reflect.TypeOf(types.StringType), + "cluster_sources": reflect.TypeOf(types.String{}), + "cluster_states": reflect.TypeOf(types.String{}), } } @@ -6053,7 +6053,7 @@ func (newState *MavenLibrary) SyncEffectiveFieldsDuringRead(existingState MavenL func (a MavenLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "exclusions": reflect.TypeOf(types.StringType), + "exclusions": reflect.TypeOf(types.String{}), } } @@ -6661,7 +6661,7 @@ func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "fileNames": reflect.TypeOf(types.StringType), + "fileNames": reflect.TypeOf(types.String{}), "schema": reflect.TypeOf(struct{}{}), } } @@ -6915,7 +6915,7 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState T func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -7219,13 +7219,13 @@ func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[str "aws_attributes": reflect.TypeOf(AwsAttributes{}), "azure_attributes": reflect.TypeOf(AzureAttributes{}), "cluster_log_conf": reflect.TypeOf(ClusterLogConf{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "docker_image": reflect.TypeOf(DockerImage{}), "gcp_attributes": reflect.TypeOf(GcpAttributes{}), "init_scripts": reflect.TypeOf(InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), + "ssh_public_keys": reflect.TypeOf(types.String{}), "workload_type": reflect.TypeOf(WorkloadType{}), } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 114cb36797..eafabb6b6b 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -768,7 +768,7 @@ func (newState *GrantRule) SyncEffectiveFieldsDuringRead(existingState GrantRule func (a GrantRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "principals": reflect.TypeOf(types.StringType), + "principals": reflect.TypeOf(types.String{}), } } @@ -820,7 +820,7 @@ func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type "members": reflect.TypeOf(ComplexValue{}), "meta": reflect.TypeOf(ResourceMeta{}), "roles": reflect.TypeOf(ComplexValue{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } @@ -1068,7 +1068,7 @@ func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringRead(existingState func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(Group{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } @@ -1111,7 +1111,7 @@ func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringRead(exis func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(ServicePrincipal{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } @@ -1251,7 +1251,7 @@ func (newState *ListUsersResponse) SyncEffectiveFieldsDuringRead(existingState L func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(User{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } @@ -1428,7 +1428,7 @@ func (newState *PartialUpdate) SyncEffectiveFieldsDuringRead(existingState Parti func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Operations": reflect.TypeOf(Patch{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } @@ -1533,7 +1533,7 @@ func (newState *PasswordPermission) SyncEffectiveFieldsDuringRead(existingState func (a PasswordPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1696,7 +1696,7 @@ func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permissi func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1731,7 +1731,7 @@ func (newState *PermissionAssignment) SyncEffectiveFieldsDuringRead(existingStat func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "permissions": reflect.TypeOf(types.StringType), + "permissions": reflect.TypeOf(types.String{}), "principal": reflect.TypeOf(PrincipalOutput{}), } } @@ -2051,7 +2051,7 @@ func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]r "entitlements": reflect.TypeOf(ComplexValue{}), "groups": reflect.TypeOf(ComplexValue{}), "roles": reflect.TypeOf(ComplexValue{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } @@ -2150,7 +2150,7 @@ func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringRead(existi func (a UpdateWorkspaceAssignments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "permissions": reflect.TypeOf(types.StringType), + "permissions": reflect.TypeOf(types.String{}), } } @@ -2213,7 +2213,7 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type "groups": reflect.TypeOf(ComplexValue{}), "name": reflect.TypeOf(Name{}), "roles": reflect.TypeOf(ComplexValue{}), - "schemas": reflect.TypeOf(types.StringType), + "schemas": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 86f53339d7..4bfc963805 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -647,7 +647,7 @@ func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. "queue": reflect.TypeOf(QueueSettings{}), "run_as": reflect.TypeOf(JobRunAs{}), "schedule": reflect.TypeOf(CronSchedule{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), "task": reflect.TypeOf(Task{}), "trigger": reflect.TypeOf(TriggerSettings{}), "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), @@ -796,7 +796,7 @@ func (newState *DbtOutput) SyncEffectiveFieldsDuringRead(existingState DbtOutput func (a DbtOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "artifacts_headers": reflect.TypeOf(types.StringType), + "artifacts_headers": reflect.TypeOf(types.String{}), } } @@ -856,7 +856,7 @@ func (newState *DbtTask) SyncEffectiveFieldsDuringRead(existingState DbtTask) { func (a DbtTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "commands": reflect.TypeOf(types.StringType), + "commands": reflect.TypeOf(types.String{}), } } @@ -1447,7 +1447,7 @@ func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringRead(exist func (a GetPolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.String{}), } } @@ -1793,7 +1793,7 @@ func (newState *JobCompliance) SyncEffectiveFieldsDuringRead(existingState JobCo func (a JobCompliance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "violations": reflect.TypeOf(types.StringType), + "violations": reflect.TypeOf(types.String{}), } } @@ -1881,11 +1881,11 @@ func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringRead(existingSta func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.StringType), - "on_failure": reflect.TypeOf(types.StringType), - "on_start": reflect.TypeOf(types.StringType), - "on_streaming_backlog_exceeded": reflect.TypeOf(types.StringType), - "on_success": reflect.TypeOf(types.StringType), + "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.String{}), + "on_failure": reflect.TypeOf(types.String{}), + "on_start": reflect.TypeOf(types.String{}), + "on_streaming_backlog_exceeded": reflect.TypeOf(types.String{}), + "on_success": reflect.TypeOf(types.String{}), } } @@ -2044,7 +2044,7 @@ func (newState *JobPermission) SyncEffectiveFieldsDuringRead(existingState JobPe func (a JobPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -2304,7 +2304,7 @@ func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflec "queue": reflect.TypeOf(QueueSettings{}), "run_as": reflect.TypeOf(JobRunAs{}), "schedule": reflect.TypeOf(CronSchedule{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), "task": reflect.TypeOf(Task{}), "trigger": reflect.TypeOf(TriggerSettings{}), "webhook_notifications": reflect.TypeOf(WebhookNotifications{}), @@ -2818,7 +2818,7 @@ func (newState *NotebookTask) SyncEffectiveFieldsDuringRead(existingState Notebo func (a NotebookTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "base_parameters": reflect.TypeOf(types.StringType), + "base_parameters": reflect.TypeOf(types.String{}), } } @@ -2934,8 +2934,8 @@ func (newState *PythonWheelTask) SyncEffectiveFieldsDuringRead(existingState Pyt func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "named_parameters": reflect.TypeOf(types.StringType), - "parameters": reflect.TypeOf(types.StringType), + "named_parameters": reflect.TypeOf(types.String{}), + "parameters": reflect.TypeOf(types.String{}), } } @@ -3039,7 +3039,7 @@ func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{ "state": reflect.TypeOf(RunState{}), "status": reflect.TypeOf(RunStatus{}), - "task_run_ids": reflect.TypeOf(types.Int64Type), + "task_run_ids": reflect.TypeOf(types.Int64{}), } } @@ -3174,16 +3174,16 @@ func (newState *RepairRun) SyncEffectiveFieldsDuringRead(existingState RepairRun func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dbt_commands": reflect.TypeOf(types.StringType), - "jar_params": reflect.TypeOf(types.StringType), - "job_parameters": reflect.TypeOf(types.StringType), - "notebook_params": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.String{}), + "jar_params": reflect.TypeOf(types.String{}), + "job_parameters": reflect.TypeOf(types.String{}), + "notebook_params": reflect.TypeOf(types.String{}), "pipeline_params": reflect.TypeOf(PipelineParams{}), - "python_named_params": reflect.TypeOf(types.StringType), - "python_params": reflect.TypeOf(types.StringType), - "rerun_tasks": reflect.TypeOf(types.StringType), - "spark_submit_params": reflect.TypeOf(types.StringType), - "sql_params": reflect.TypeOf(types.StringType), + "python_named_params": reflect.TypeOf(types.String{}), + "python_params": reflect.TypeOf(types.String{}), + "rerun_tasks": reflect.TypeOf(types.String{}), + "spark_submit_params": reflect.TypeOf(types.String{}), + "sql_params": reflect.TypeOf(types.String{}), } } @@ -3343,7 +3343,7 @@ func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringRead(existingSta func (a ResolvedDbtTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "commands": reflect.TypeOf(types.StringType), + "commands": reflect.TypeOf(types.String{}), } } @@ -3369,7 +3369,7 @@ func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existi func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "base_parameters": reflect.TypeOf(types.StringType), + "base_parameters": reflect.TypeOf(types.String{}), } } @@ -3395,7 +3395,7 @@ func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringRead(existingS func (a ResolvedParamPairValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -3423,8 +3423,8 @@ func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringRead(exi func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "named_parameters": reflect.TypeOf(types.StringType), - "parameters": reflect.TypeOf(types.StringType), + "named_parameters": reflect.TypeOf(types.String{}), + "parameters": reflect.TypeOf(types.String{}), } } @@ -3455,8 +3455,8 @@ func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringRead(existing func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "job_parameters": reflect.TypeOf(types.StringType), - "parameters": reflect.TypeOf(types.StringType), + "job_parameters": reflect.TypeOf(types.String{}), + "parameters": reflect.TypeOf(types.String{}), } } @@ -3485,7 +3485,7 @@ func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringRead(existi func (a ResolvedStringParamsValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -4012,15 +4012,15 @@ func (newState *RunJobTask) SyncEffectiveFieldsDuringRead(existingState RunJobTa func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dbt_commands": reflect.TypeOf(types.StringType), - "jar_params": reflect.TypeOf(types.StringType), - "job_parameters": reflect.TypeOf(types.StringType), - "notebook_params": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.String{}), + "jar_params": reflect.TypeOf(types.String{}), + "job_parameters": reflect.TypeOf(types.String{}), + "notebook_params": reflect.TypeOf(types.String{}), "pipeline_params": reflect.TypeOf(PipelineParams{}), - "python_named_params": reflect.TypeOf(types.StringType), - "python_params": reflect.TypeOf(types.StringType), - "spark_submit_params": reflect.TypeOf(types.StringType), - "sql_params": reflect.TypeOf(types.StringType), + "python_named_params": reflect.TypeOf(types.String{}), + "python_params": reflect.TypeOf(types.String{}), + "spark_submit_params": reflect.TypeOf(types.String{}), + "sql_params": reflect.TypeOf(types.String{}), } } @@ -4177,17 +4177,17 @@ func (newState *RunNow) SyncEffectiveFieldsDuringRead(existingState RunNow) { func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dbt_commands": reflect.TypeOf(types.StringType), - "jar_params": reflect.TypeOf(types.StringType), - "job_parameters": reflect.TypeOf(types.StringType), - "notebook_params": reflect.TypeOf(types.StringType), - "only": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.String{}), + "jar_params": reflect.TypeOf(types.String{}), + "job_parameters": reflect.TypeOf(types.String{}), + "notebook_params": reflect.TypeOf(types.String{}), + "only": reflect.TypeOf(types.String{}), "pipeline_params": reflect.TypeOf(PipelineParams{}), - "python_named_params": reflect.TypeOf(types.StringType), - "python_params": reflect.TypeOf(types.StringType), + "python_named_params": reflect.TypeOf(types.String{}), + "python_params": reflect.TypeOf(types.String{}), "queue": reflect.TypeOf(QueueSettings{}), - "spark_submit_params": reflect.TypeOf(types.StringType), - "sql_params": reflect.TypeOf(types.StringType), + "spark_submit_params": reflect.TypeOf(types.String{}), + "sql_params": reflect.TypeOf(types.String{}), } } @@ -4437,14 +4437,14 @@ func (newState *RunParameters) SyncEffectiveFieldsDuringRead(existingState RunPa func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dbt_commands": reflect.TypeOf(types.StringType), - "jar_params": reflect.TypeOf(types.StringType), - "notebook_params": reflect.TypeOf(types.StringType), + "dbt_commands": reflect.TypeOf(types.String{}), + "jar_params": reflect.TypeOf(types.String{}), + "notebook_params": reflect.TypeOf(types.String{}), "pipeline_params": reflect.TypeOf(PipelineParams{}), - "python_named_params": reflect.TypeOf(types.StringType), - "python_params": reflect.TypeOf(types.StringType), - "spark_submit_params": reflect.TypeOf(types.StringType), - "sql_params": reflect.TypeOf(types.StringType), + "python_named_params": reflect.TypeOf(types.String{}), + "python_params": reflect.TypeOf(types.String{}), + "spark_submit_params": reflect.TypeOf(types.String{}), + "sql_params": reflect.TypeOf(types.String{}), } } @@ -4875,7 +4875,7 @@ func (newState *SparkJarTask) SyncEffectiveFieldsDuringRead(existingState SparkJ func (a SparkJarTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -4925,7 +4925,7 @@ func (newState *SparkPythonTask) SyncEffectiveFieldsDuringRead(existingState Spa func (a SparkPythonTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -4959,7 +4959,7 @@ func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringRead(existingState Spa func (a SparkSubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -5247,7 +5247,7 @@ func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty "alert": reflect.TypeOf(SqlTaskAlert{}), "dashboard": reflect.TypeOf(SqlTaskDashboard{}), "file": reflect.TypeOf(SqlTaskFile{}), - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), "query": reflect.TypeOf(SqlTaskQuery{}), } } @@ -5802,7 +5802,7 @@ func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringRead(e func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "table_names": reflect.TypeOf(types.StringType), + "table_names": reflect.TypeOf(types.String{}), } } @@ -6114,11 +6114,11 @@ func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringRead(existingSt func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.StringType), - "on_failure": reflect.TypeOf(types.StringType), - "on_start": reflect.TypeOf(types.StringType), - "on_streaming_backlog_exceeded": reflect.TypeOf(types.StringType), - "on_success": reflect.TypeOf(types.StringType), + "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.String{}), + "on_failure": reflect.TypeOf(types.String{}), + "on_start": reflect.TypeOf(types.String{}), + "on_streaming_backlog_exceeded": reflect.TypeOf(types.String{}), + "on_success": reflect.TypeOf(types.String{}), } } @@ -6360,7 +6360,7 @@ func (newState *UpdateJob) SyncEffectiveFieldsDuringRead(existingState UpdateJob func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "fields_to_remove": reflect.TypeOf(types.StringType), + "fields_to_remove": reflect.TypeOf(types.String{}), "new_settings": reflect.TypeOf(JobSettings{}), } } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index abc910c905..ae2a6384fb 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -83,7 +83,7 @@ func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringRead(existingS func (a BatchGetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "ids": reflect.TypeOf(types.StringType), + "ids": reflect.TypeOf(types.String{}), } } @@ -136,7 +136,7 @@ func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringRead(existing func (a BatchGetProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "ids": reflect.TypeOf(types.StringType), + "ids": reflect.TypeOf(types.String{}), } } @@ -2121,9 +2121,9 @@ func (newState *ListListingsRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "assets": reflect.TypeOf(types.StringType), - "categories": reflect.TypeOf(types.StringType), - "provider_ids": reflect.TypeOf(types.StringType), + "assets": reflect.TypeOf(types.String{}), + "categories": reflect.TypeOf(types.String{}), + "provider_ids": reflect.TypeOf(types.String{}), "tags": reflect.TypeOf(ListingTag{}), } } @@ -2362,10 +2362,10 @@ func (newState *ListingDetail) SyncEffectiveFieldsDuringRead(existingState Listi func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "assets": reflect.TypeOf(types.StringType), + "assets": reflect.TypeOf(types.String{}), "collection_granularity": reflect.TypeOf(DataRefreshInfo{}), "embedded_notebook_file_infos": reflect.TypeOf(FileInfo{}), - "file_ids": reflect.TypeOf(types.StringType), + "file_ids": reflect.TypeOf(types.String{}), "tags": reflect.TypeOf(ListingTag{}), "update_frequency": reflect.TypeOf(DataRefreshInfo{}), } @@ -2522,8 +2522,8 @@ func (newState *ListingSummary) SyncEffectiveFieldsDuringRead(existingState List func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "categories": reflect.TypeOf(types.StringType), - "exchange_ids": reflect.TypeOf(types.StringType), + "categories": reflect.TypeOf(types.String{}), + "exchange_ids": reflect.TypeOf(types.String{}), "git_repo": reflect.TypeOf(RepoInfo{}), "provider_region": reflect.TypeOf(RegionInfo{}), "setting": reflect.TypeOf(ListingSetting{}), @@ -2585,7 +2585,7 @@ func (newState *ListingTag) SyncEffectiveFieldsDuringRead(existingState ListingT func (a ListingTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "tag_values": reflect.TypeOf(types.StringType), + "tag_values": reflect.TypeOf(types.String{}), } } @@ -2907,9 +2907,9 @@ func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringRead(existingSta func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "assets": reflect.TypeOf(types.StringType), - "categories": reflect.TypeOf(types.StringType), - "provider_ids": reflect.TypeOf(types.StringType), + "assets": reflect.TypeOf(types.String{}), + "categories": reflect.TypeOf(types.String{}), + "provider_ids": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 79778e86e1..eb0088eb01 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -196,7 +196,7 @@ func (newState *CommentObject) SyncEffectiveFieldsDuringRead(existingState Comme func (a CommentObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "available_actions": reflect.TypeOf(types.StringType), + "available_actions": reflect.TypeOf(types.String{}), } } @@ -524,7 +524,7 @@ func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingSta func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "events": reflect.TypeOf(types.StringType), + "events": reflect.TypeOf(types.String{}), "http_url_spec": reflect.TypeOf(HttpUrlSpec{}), "job_spec": reflect.TypeOf(JobSpec{}), } @@ -1440,7 +1440,7 @@ func (newState *ExperimentPermission) SyncEffectiveFieldsDuringRead(existingStat func (a ExperimentPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1801,7 +1801,7 @@ func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringRead(existing func (a GetLatestVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "stages": reflect.TypeOf(types.StringType), + "stages": reflect.TypeOf(types.String{}), } } @@ -2622,7 +2622,7 @@ func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringRead(existingState func (a ListWebhooksRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "events": reflect.TypeOf(types.StringType), + "events": reflect.TypeOf(types.String{}), } } @@ -3360,7 +3360,7 @@ func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringRead(existin func (a RegisteredModelPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -3530,7 +3530,7 @@ func (newState *RegistryWebhook) SyncEffectiveFieldsDuringRead(existingState Reg func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "events": reflect.TypeOf(types.StringType), + "events": reflect.TypeOf(types.String{}), "http_url_spec": reflect.TypeOf(HttpUrlSpecWithoutSecret{}), "job_spec": reflect.TypeOf(JobSpecWithoutSecret{}), } @@ -4026,7 +4026,7 @@ func (newState *SearchExperiments) SyncEffectiveFieldsDuringRead(existingState S func (a SearchExperiments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "order_by": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.String{}), } } @@ -4099,7 +4099,7 @@ func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringRead(existi func (a SearchModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "order_by": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.String{}), } } @@ -4171,7 +4171,7 @@ func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringRead(existingState func (a SearchModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "order_by": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.String{}), } } @@ -4258,8 +4258,8 @@ func (newState *SearchRuns) SyncEffectiveFieldsDuringRead(existingState SearchRu func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "experiment_ids": reflect.TypeOf(types.StringType), - "order_by": reflect.TypeOf(types.StringType), + "experiment_ids": reflect.TypeOf(types.String{}), + "order_by": reflect.TypeOf(types.String{}), } } @@ -4682,7 +4682,7 @@ func (newState *TransitionRequest) SyncEffectiveFieldsDuringRead(existingState T func (a TransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "available_actions": reflect.TypeOf(types.StringType), + "available_actions": reflect.TypeOf(types.String{}), } } @@ -4980,7 +4980,7 @@ func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingSta func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "events": reflect.TypeOf(types.StringType), + "events": reflect.TypeOf(types.String{}), "http_url_spec": reflect.TypeOf(HttpUrlSpec{}), "job_spec": reflect.TypeOf(JobSpec{}), } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 57e340baa6..145e13cada 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -42,8 +42,8 @@ func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existi func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "redirect_urls": reflect.TypeOf(types.StringType), - "scopes": reflect.TypeOf(types.StringType), + "redirect_urls": reflect.TypeOf(types.String{}), + "scopes": reflect.TypeOf(types.String{}), "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } @@ -400,8 +400,8 @@ func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(exi func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "redirect_urls": reflect.TypeOf(types.StringType), - "scopes": reflect.TypeOf(types.StringType), + "redirect_urls": reflect.TypeOf(types.String{}), + "scopes": reflect.TypeOf(types.String{}), "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } @@ -783,8 +783,8 @@ func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringRead(existingState func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "redirect_urls": reflect.TypeOf(types.StringType), - "scopes": reflect.TypeOf(types.StringType), + "redirect_urls": reflect.TypeOf(types.String{}), + "scopes": reflect.TypeOf(types.String{}), } } @@ -884,7 +884,7 @@ func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existi func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "redirect_urls": reflect.TypeOf(types.StringType), + "redirect_urls": reflect.TypeOf(types.String{}), "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index a670a2cc5a..8cb729a962 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -93,7 +93,7 @@ func (newState *CreatePipeline) SyncEffectiveFieldsDuringRead(existingState Crea func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), - "configuration": reflect.TypeOf(types.StringType), + "configuration": reflect.TypeOf(types.String{}), "deployment": reflect.TypeOf(PipelineDeployment{}), "filters": reflect.TypeOf(Filters{}), "gateway_definition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), @@ -357,7 +357,7 @@ func (newState *EditPipeline) SyncEffectiveFieldsDuringRead(existingState EditPi func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), - "configuration": reflect.TypeOf(types.StringType), + "configuration": reflect.TypeOf(types.String{}), "deployment": reflect.TypeOf(PipelineDeployment{}), "filters": reflect.TypeOf(Filters{}), "gateway_definition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), @@ -509,8 +509,8 @@ func (newState *Filters) SyncEffectiveFieldsDuringRead(existingState Filters) { func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "exclude": reflect.TypeOf(types.StringType), - "include": reflect.TypeOf(types.StringType), + "exclude": reflect.TypeOf(types.String{}), + "include": reflect.TypeOf(types.String{}), } } @@ -906,7 +906,7 @@ func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringRead(existin func (a ListPipelineEventsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "order_by": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.String{}), } } @@ -990,7 +990,7 @@ func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringRead(existingStat func (a ListPipelinesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "order_by": reflect.TypeOf(types.StringType), + "order_by": reflect.TypeOf(types.String{}), } } @@ -1168,8 +1168,8 @@ func (newState *Notifications) SyncEffectiveFieldsDuringRead(existingState Notif func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "alerts": reflect.TypeOf(types.StringType), - "email_recipients": reflect.TypeOf(types.StringType), + "alerts": reflect.TypeOf(types.String{}), + "email_recipients": reflect.TypeOf(types.String{}), } } @@ -1438,12 +1438,12 @@ func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]re "aws_attributes": reflect.TypeOf(compute.AwsAttributes{}), "azure_attributes": reflect.TypeOf(compute.AzureAttributes{}), "cluster_log_conf": reflect.TypeOf(compute.ClusterLogConf{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "gcp_attributes": reflect.TypeOf(compute.GcpAttributes{}), "init_scripts": reflect.TypeOf(compute.InitScriptInfo{}), - "spark_conf": reflect.TypeOf(types.StringType), - "spark_env_vars": reflect.TypeOf(types.StringType), - "ssh_public_keys": reflect.TypeOf(types.StringType), + "spark_conf": reflect.TypeOf(types.String{}), + "spark_env_vars": reflect.TypeOf(types.String{}), + "ssh_public_keys": reflect.TypeOf(types.String{}), } } @@ -1675,7 +1675,7 @@ func (newState *PipelinePermission) SyncEffectiveFieldsDuringRead(existingState func (a PipelinePermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1844,7 +1844,7 @@ func (newState *PipelineSpec) SyncEffectiveFieldsDuringRead(existingState Pipeli func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), - "configuration": reflect.TypeOf(types.StringType), + "configuration": reflect.TypeOf(types.String{}), "deployment": reflect.TypeOf(PipelineDeployment{}), "filters": reflect.TypeOf(Filters{}), "gateway_definition": reflect.TypeOf(IngestionGatewayPipelineDefinition{}), @@ -2233,8 +2233,8 @@ func (newState *StartUpdate) SyncEffectiveFieldsDuringRead(existingState StartUp func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "full_refresh_selection": reflect.TypeOf(types.StringType), - "refresh_selection": reflect.TypeOf(types.StringType), + "full_refresh_selection": reflect.TypeOf(types.String{}), + "refresh_selection": reflect.TypeOf(types.String{}), } } @@ -2390,8 +2390,8 @@ func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringRead(existingState func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "primary_keys": reflect.TypeOf(types.StringType), - "sequence_by": reflect.TypeOf(types.StringType), + "primary_keys": reflect.TypeOf(types.String{}), + "sequence_by": reflect.TypeOf(types.String{}), } } @@ -2452,8 +2452,8 @@ func (newState *UpdateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateIn func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(PipelineSpec{}), - "full_refresh_selection": reflect.TypeOf(types.StringType), - "refresh_selection": reflect.TypeOf(types.StringType), + "full_refresh_selection": reflect.TypeOf(types.String{}), + "refresh_selection": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 367f2f1410..41111661b7 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -263,7 +263,7 @@ func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{ "aws_key_info": reflect.TypeOf(CreateAwsKeyInfo{}), "gcp_key_info": reflect.TypeOf(CreateGcpKeyInfo{}), - "use_cases": reflect.TypeOf(types.StringType), + "use_cases": reflect.TypeOf(types.String{}), } } @@ -337,8 +337,8 @@ func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringRead(existingStat func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), - "security_group_ids": reflect.TypeOf(types.StringType), - "subnet_ids": reflect.TypeOf(types.StringType), + "security_group_ids": reflect.TypeOf(types.String{}), + "subnet_ids": reflect.TypeOf(types.String{}), "vpc_endpoints": reflect.TypeOf(NetworkVpcEndpoints{}), } } @@ -553,7 +553,7 @@ func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingSt func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "gcp_managed_network_config": reflect.TypeOf(GcpManagedNetworkConfig{}), "gke_config": reflect.TypeOf(GkeConfig{}), } @@ -680,7 +680,7 @@ func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{ "aws_key_info": reflect.TypeOf(AwsKeyInfo{}), "gcp_key_info": reflect.TypeOf(GcpKeyInfo{}), - "use_cases": reflect.TypeOf(types.StringType), + "use_cases": reflect.TypeOf(types.String{}), } } @@ -1332,8 +1332,8 @@ func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{ "error_messages": reflect.TypeOf(NetworkHealth{}), "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), - "security_group_ids": reflect.TypeOf(types.StringType), - "subnet_ids": reflect.TypeOf(types.StringType), + "security_group_ids": reflect.TypeOf(types.String{}), + "subnet_ids": reflect.TypeOf(types.String{}), "vpc_endpoints": reflect.TypeOf(NetworkVpcEndpoints{}), "warning_messages": reflect.TypeOf(NetworkWarning{}), } @@ -1419,8 +1419,8 @@ func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringRead(existingState func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dataplane_relay": reflect.TypeOf(types.StringType), - "rest_api": reflect.TypeOf(types.StringType), + "dataplane_relay": reflect.TypeOf(types.String{}), + "rest_api": reflect.TypeOf(types.String{}), } } @@ -1499,7 +1499,7 @@ func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringRead(existingSta func (a PrivateAccessSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "allowed_vpc_endpoint_ids": reflect.TypeOf(types.StringType), + "allowed_vpc_endpoint_ids": reflect.TypeOf(types.String{}), } } @@ -1690,7 +1690,7 @@ func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingSt func (a UpdateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), } } @@ -1759,7 +1759,7 @@ func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringRea func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "allowed_vpc_endpoint_ids": reflect.TypeOf(types.StringType), + "allowed_vpc_endpoint_ids": reflect.TypeOf(types.String{}), } } @@ -1957,7 +1957,7 @@ func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{ "azure_workspace_info": reflect.TypeOf(AzureWorkspaceInfo{}), "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), - "custom_tags": reflect.TypeOf(types.StringType), + "custom_tags": reflect.TypeOf(types.String{}), "external_customer_info": reflect.TypeOf(ExternalCustomerInfo{}), "gcp_managed_network_config": reflect.TypeOf(GcpManagedNetworkConfig{}), "gke_config": reflect.TypeOf(GkeConfig{}), diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 4c7f86b5e3..b822ed2ad4 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -125,9 +125,9 @@ func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringRead(exis func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "invalid_keywords": reflect.TypeOf(types.StringType), + "invalid_keywords": reflect.TypeOf(types.String{}), "pii": reflect.TypeOf(AiGatewayGuardrailPiiBehavior{}), - "valid_topics": reflect.TypeOf(types.StringType), + "valid_topics": reflect.TypeOf(types.String{}), } } @@ -718,7 +718,7 @@ func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{ "columns": reflect.TypeOf(struct{}{}), "data": reflect.TypeOf(struct{}{}), - "index": reflect.TypeOf(types.Int64Type), + "index": reflect.TypeOf(types.Int64{}), } } @@ -797,7 +797,7 @@ func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringR func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "embedding": reflect.TypeOf(types.Float64Type), + "embedding": reflect.TypeOf(types.Float64{}), } } @@ -1666,7 +1666,7 @@ func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringRead(existing func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add_tags": reflect.TypeOf(EndpointTag{}), - "delete_tags": reflect.TypeOf(types.StringType), + "delete_tags": reflect.TypeOf(types.String{}), } } @@ -1939,10 +1939,10 @@ func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{ "dataframe_records": reflect.TypeOf(struct{}{}), "dataframe_split": reflect.TypeOf(DataframeSplitInput{}), - "extra_params": reflect.TypeOf(types.StringType), + "extra_params": reflect.TypeOf(types.String{}), "instances": reflect.TypeOf(struct{}{}), "messages": reflect.TypeOf(ChatMessage{}), - "stop": reflect.TypeOf(types.StringType), + "stop": reflect.TypeOf(types.String{}), } } @@ -2178,7 +2178,7 @@ func (newState *ServedEntityInput) SyncEffectiveFieldsDuringRead(existingState S func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "environment_vars": reflect.TypeOf(types.StringType), + "environment_vars": reflect.TypeOf(types.String{}), "external_model": reflect.TypeOf(ExternalModel{}), } } @@ -2276,7 +2276,7 @@ func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringRead(existingState func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "environment_vars": reflect.TypeOf(types.StringType), + "environment_vars": reflect.TypeOf(types.String{}), "external_model": reflect.TypeOf(ExternalModel{}), "foundation_model": reflect.TypeOf(FoundationModel{}), "state": reflect.TypeOf(ServedModelState{}), @@ -2420,7 +2420,7 @@ func (newState *ServedModelInput) SyncEffectiveFieldsDuringRead(existingState Se func (a ServedModelInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "environment_vars": reflect.TypeOf(types.StringType), + "environment_vars": reflect.TypeOf(types.String{}), } } @@ -2497,7 +2497,7 @@ func (newState *ServedModelOutput) SyncEffectiveFieldsDuringRead(existingState S func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "environment_vars": reflect.TypeOf(types.StringType), + "environment_vars": reflect.TypeOf(types.String{}), "state": reflect.TypeOf(ServedModelState{}), } } @@ -2855,7 +2855,7 @@ func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringRead(existin func (a ServingEndpointPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index db08297202..669238568e 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -95,7 +95,7 @@ func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuring func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "approved_domains": reflect.TypeOf(types.StringType), + "approved_domains": reflect.TypeOf(types.String{}), } } @@ -396,7 +396,7 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existin func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "compliance_standards": reflect.TypeOf(types.StringType), + "compliance_standards": reflect.TypeOf(types.String{}), } } @@ -526,7 +526,7 @@ func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a CreateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "ip_addresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.String{}), } } @@ -798,7 +798,7 @@ func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringRead(existingStat func (a CspEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "compliance_standards": reflect.TypeOf(types.StringType), + "compliance_standards": reflect.TypeOf(types.String{}), } } @@ -1591,7 +1591,7 @@ func (newState *EmailConfig) SyncEffectiveFieldsDuringRead(existingState EmailCo func (a EmailConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "addresses": reflect.TypeOf(types.StringType), + "addresses": reflect.TypeOf(types.String{}), } } @@ -1779,7 +1779,7 @@ func (newState *ExchangeToken) SyncEffectiveFieldsDuringRead(existingState Excha func (a ExchangeToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "scopes": reflect.TypeOf(types.StringType), + "scopes": reflect.TypeOf(types.String{}), } } @@ -1816,8 +1816,8 @@ func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringRead(existingStat func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "partitionId": reflect.TypeOf(PartitionId{}), - "scopes": reflect.TypeOf(types.StringType), - "tokenType": reflect.TypeOf(types.StringType), + "scopes": reflect.TypeOf(types.String{}), + "tokenType": reflect.TypeOf(types.String{}), } } @@ -2634,7 +2634,7 @@ func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringRead(existingState Ip func (a IpAccessListInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "ip_addresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.String{}), } } @@ -3005,7 +3005,7 @@ func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringRead(existingState func (a NccAwsStableIpRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "cidr_blocks": reflect.TypeOf(types.StringType), + "cidr_blocks": reflect.TypeOf(types.String{}), } } @@ -3105,8 +3105,8 @@ func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringRead(exist func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "subnets": reflect.TypeOf(types.StringType), - "target_services": reflect.TypeOf(types.StringType), + "subnets": reflect.TypeOf(types.String{}), + "target_services": reflect.TypeOf(types.String{}), } } @@ -3502,7 +3502,7 @@ func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a ReplaceIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "ip_addresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.String{}), } } @@ -3850,7 +3850,7 @@ func (newState *TokenPermission) SyncEffectiveFieldsDuringRead(existingState Tok func (a TokenPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -4402,7 +4402,7 @@ func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringRead(existingState func (a UpdateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "ip_addresses": reflect.TypeOf(types.StringType), + "ip_addresses": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index ba18fa4a14..d65cca9f8a 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -395,7 +395,7 @@ func (newState *IpAccessList) SyncEffectiveFieldsDuringRead(existingState IpAcce func (a IpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "allowed_ip_addresses": reflect.TypeOf(types.StringType), + "allowed_ip_addresses": reflect.TypeOf(types.String{}), } } @@ -731,7 +731,7 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "privileges": reflect.TypeOf(types.StringType), + "privileges": reflect.TypeOf(types.String{}), } } @@ -1106,7 +1106,7 @@ func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existi func (a SecurablePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "properties": reflect.TypeOf(types.StringType), + "properties": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 39b5e33829..8309eb5534 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -375,7 +375,7 @@ func (newState *AlertQuery) SyncEffectiveFieldsDuringRead(existingState AlertQue func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(QueryOptions{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -767,7 +767,7 @@ func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingS func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -1124,7 +1124,7 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(DashboardOptions{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), "user": reflect.TypeOf(User{}), "widgets": reflect.TypeOf(Widget{}), } @@ -1183,7 +1183,7 @@ func (newState *DashboardEditContent) SyncEffectiveFieldsDuringRead(existingStat func (a DashboardEditContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -1252,7 +1252,7 @@ func (newState *DashboardPostContent) SyncEffectiveFieldsDuringRead(existingStat func (a DashboardPostContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -2063,7 +2063,7 @@ func (newState *EnumValue) SyncEffectiveFieldsDuringRead(existingState EnumValue func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), - "values": reflect.TypeOf(types.StringType), + "values": reflect.TypeOf(types.String{}), } } @@ -2280,7 +2280,7 @@ func (newState *ExternalLink) SyncEffectiveFieldsDuringRead(existingState Extern func (a ExternalLink) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "http_headers": reflect.TypeOf(types.StringType), + "http_headers": reflect.TypeOf(types.String{}), } } @@ -2975,7 +2975,7 @@ func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{ "last_modified_by": reflect.TypeOf(User{}), "options": reflect.TypeOf(QueryOptions{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), "user": reflect.TypeOf(User{}), "visualizations": reflect.TypeOf(LegacyVisualization{}), } @@ -3467,7 +3467,7 @@ func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringRead(exi func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -3824,7 +3824,7 @@ func (newState *Query) SyncEffectiveFieldsDuringRead(existingState Query) { func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -3874,7 +3874,7 @@ func (newState *QueryBackedValue) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), - "values": reflect.TypeOf(types.StringType), + "values": reflect.TypeOf(types.String{}), } } @@ -3928,7 +3928,7 @@ func (newState *QueryEditContent) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryEditContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -3972,10 +3972,10 @@ func (newState *QueryFilter) SyncEffectiveFieldsDuringRead(existingState QueryFi func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query_start_time_range": reflect.TypeOf(TimeRange{}), - "statement_ids": reflect.TypeOf(types.StringType), - "statuses": reflect.TypeOf(types.StringType), - "user_ids": reflect.TypeOf(types.Int64Type), - "warehouse_ids": reflect.TypeOf(types.StringType), + "statement_ids": reflect.TypeOf(types.String{}), + "statuses": reflect.TypeOf(types.String{}), + "user_ids": reflect.TypeOf(types.Int64{}), + "warehouse_ids": reflect.TypeOf(types.String{}), } } @@ -4375,7 +4375,7 @@ func (newState *QueryPostContent) SyncEffectiveFieldsDuringRead(existingState Qu func (a QueryPostContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -4529,7 +4529,7 @@ func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultDa func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "data_array": reflect.TypeOf(types.StringType), + "data_array": reflect.TypeOf(types.String{}), "external_links": reflect.TypeOf(ExternalLink{}), } } @@ -5062,7 +5062,7 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState T func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "parameters": reflect.TypeOf(types.StringType), + "parameters": reflect.TypeOf(types.String{}), } } @@ -5393,7 +5393,7 @@ func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingS func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), - "tags": reflect.TypeOf(types.StringType), + "tags": reflect.TypeOf(types.String{}), } } @@ -5672,7 +5672,7 @@ func (newState *WarehousePermission) SyncEffectiveFieldsDuringRead(existingState func (a WarehousePermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index c432235ef6..a9293f26df 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -163,7 +163,7 @@ func (newState *DeleteDataResult) SyncEffectiveFieldsDuringRead(existingState De func (a DeleteDataResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "failed_primary_keys": reflect.TypeOf(types.StringType), + "failed_primary_keys": reflect.TypeOf(types.String{}), } } @@ -195,7 +195,7 @@ func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(exis func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "primary_keys": reflect.TypeOf(types.StringType), + "primary_keys": reflect.TypeOf(types.String{}), } } @@ -363,7 +363,7 @@ func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringRead(e func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "columns_to_sync": reflect.TypeOf(types.StringType), + "columns_to_sync": reflect.TypeOf(types.String{}), "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), "embedding_vector_columns": reflect.TypeOf(EmbeddingVectorColumn{}), } @@ -935,8 +935,8 @@ func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingS func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "columns": reflect.TypeOf(types.StringType), - "query_vector": reflect.TypeOf(types.Float64Type), + "columns": reflect.TypeOf(types.String{}), + "query_vector": reflect.TypeOf(types.Float64{}), } } @@ -1013,7 +1013,7 @@ func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultDa func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "data_array": reflect.TypeOf(types.StringType), + "data_array": reflect.TypeOf(types.String{}), } } @@ -1208,7 +1208,7 @@ func (newState *UpsertDataResult) SyncEffectiveFieldsDuringRead(existingState Up func (a UpsertDataResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "failed_primary_keys": reflect.TypeOf(types.StringType), + "failed_primary_keys": reflect.TypeOf(types.String{}), } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 6e21cf5211..9ee42dfe02 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -1708,7 +1708,7 @@ func (newState *RepoPermission) SyncEffectiveFieldsDuringRead(existingState Repo func (a RepoPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } @@ -1886,7 +1886,7 @@ func (newState *SparseCheckout) SyncEffectiveFieldsDuringRead(existingState Spar func (a SparseCheckout) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "patterns": reflect.TypeOf(types.StringType), + "patterns": reflect.TypeOf(types.String{}), } } @@ -1917,7 +1917,7 @@ func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringRead(existingStat func (a SparseCheckoutUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "patterns": reflect.TypeOf(types.StringType), + "patterns": reflect.TypeOf(types.String{}), } } @@ -2141,7 +2141,7 @@ func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringRead(existin func (a WorkspaceObjectPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.StringType), + "inherited_from_object": reflect.TypeOf(types.String{}), } } From 4b36d5310a0de980ae9d0aeee5053429e51e08d5 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 18:58:37 +0100 Subject: [PATCH 35/91] fix --- go.mod | 1 + internal/providers/pluginfw/tfschema/struct_to_schema.go | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/go.mod b/go.mod index 3d720939ce..0c88e8ab06 100644 --- a/go.mod +++ b/go.mod @@ -54,6 +54,7 @@ require ( github.com/hashicorp/logutils v1.0.0 // indirect github.com/hashicorp/terraform-exec v0.21.0 // indirect github.com/hashicorp/terraform-json v0.23.0 // indirect + github.com/hashicorp/terraform-plugin-framework-validators v0.15.0 // indirect github.com/hashicorp/terraform-registry-address v0.2.3 // indirect github.com/hashicorp/terraform-svchost v0.1.1 // indirect github.com/hashicorp/yamux v0.1.1 // indirect diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 7d8f0c9887..3acb5a999d 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -9,9 +9,11 @@ import ( "github.com/databricks/terraform-provider-databricks/common" tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" + "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" "github.com/hashicorp/terraform-plugin-framework/attr" dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" + "github.com/hashicorp/terraform-plugin-framework/schema/validator" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -87,8 +89,13 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). switch value.(type) { case types.List: + validators := []validator.List{} + if structTag.singleObject { + validators = append(validators, listvalidator.SizeAtMost(1)) + } scmBlock[fieldName] = ListNestedBlockBuilder{ NestedObject: typeToSchema(ctx, fieldValue), + Validators: validators, } case types.Map: scmAttr[fieldName] = MapNestedAttributeBuilder{ From 93763a8ad890bc6867afdb5cf1192e8afbabe7cd Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 19:34:25 +0100 Subject: [PATCH 36/91] more work --- .codegen/model.go.tmpl | 17 +- .../pluginfw/tfschema/struct_to_schema.go | 25 +- .../tfschema/struct_to_schema_test.go | 92 +- internal/service/apps_tf/model.go | 288 +++ internal/service/billing_tf/model.go | 333 +++ internal/service/catalog_tf/model.go | 2133 +++++++++++++++++ internal/service/compute_tf/model.go | 1611 +++++++++++++ internal/service/dashboards_tf/model.go | 423 ++++ internal/service/files_tf/model.go | 324 +++ internal/service/iam_tf/model.go | 612 +++++ internal/service/jobs_tf/model.go | 1170 +++++++++ internal/service/marketplace_tf/model.go | 1017 ++++++++ internal/service/ml_tf/model.go | 1449 +++++++++++ internal/service/oauth2_tf/model.go | 288 +++ internal/service/pipelines_tf/model.go | 531 ++++ internal/service/provisioning_tf/model.go | 468 ++++ internal/service/serving_tf/model.go | 666 +++++ internal/service/settings_tf/model.go | 1278 ++++++++++ internal/service/sharing_tf/model.go | 396 +++ internal/service/sql_tf/model.go | 1332 ++++++++++ internal/service/vectorsearch_tf/model.go | 387 +++ internal/service/workspace_tf/model.go | 693 ++++++ 22 files changed, 15445 insertions(+), 88 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index 4027365416..1237aa8dec 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -60,6 +60,13 @@ func (newState *{{.PascalName}}) SyncEffectiveFieldsDuringRead(existingState {{. {{- end}} } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in {{.PascalName}}. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a {{.PascalName}}) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ {{- range .Fields -}} @@ -71,6 +78,8 @@ func (a {{.PascalName}}) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of {{.PascalName}} in the Terraform plugin framework type +// system. func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -84,7 +93,13 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { {{end}} {{end}} -{{/* TODO: Handle recursive Jobs structure */}} + +{{/* +Jobs has a recursive structure: Tasks contain ForEachTasks, which contain Tasks. +Because of this, GetComplexFieldTypes and ToAttrType will never terminate. +TODO: capture visited types in the context to ensure these methods terminate, +even when they are called recursively. +*/}} {{- define "attr-type" -}} {{- if .ArrayValue -}} {{- if .ArrayValue.IsObject -}}{{/* Objects are wraped in lists automatically. */}} diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 3acb5a999d..304f36b66e 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -10,7 +10,6 @@ import ( tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" - "github.com/hashicorp/terraform-plugin-framework/attr" dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/schema/validator" @@ -69,13 +68,12 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { switch fieldType { // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. // If new types are added there, they must also be added here to work properly. - case reflect.TypeOf(types.BoolType), reflect.TypeOf(types.Int64Type), reflect.TypeOf(types.Float64Type), reflect.TypeOf(types.StringType): - elementType := reflect.New(fieldType).Elem().Interface().(attr.Type) - switch value.(type) { + case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): + switch vv := value.(type) { case types.List: - scmAttr[fieldName] = ListAttributeBuilder{ElementType: elementType} + scmAttr[fieldName] = ListAttributeBuilder{ElementType: vv.ElementType(ctx)} case types.Map: - scmAttr[fieldName] = MapAttributeBuilder{ElementType: elementType} + scmAttr[fieldName] = MapAttributeBuilder{ElementType: vv.ElementType(ctx)} case types.Object: panic(fmt.Errorf("object fields must correspond to a complex type, got %s. %s", fieldType.Name(), common.TerraformBugErrorMessage)) } @@ -86,7 +84,7 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { fieldValue := reflect.New(fieldType).Elem() // Generate the nested block schema - // Note: Objects are treated as lists for backward compatibility with the Terraform v5 protocol (i.e. SDKv2 resources). + nestedSchema := typeToSchema(ctx, fieldValue) switch value.(type) { case types.List: validators := []validator.List{} @@ -94,16 +92,16 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { validators = append(validators, listvalidator.SizeAtMost(1)) } scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: typeToSchema(ctx, fieldValue), + NestedObject: nestedSchema, Validators: validators, } case types.Map: scmAttr[fieldName] = MapNestedAttributeBuilder{ - NestedObject: typeToSchema(ctx, fieldValue).ToNestedAttributeObject(), + NestedObject: nestedSchema.ToNestedAttributeObject(), } case types.Object: scmAttr[fieldName] = SingleNestedAttributeBuilder{ - Attributes: typeToSchema(ctx, fieldValue).ToNestedAttributeObject().Attributes, + Attributes: nestedSchema.ToNestedAttributeObject().Attributes, } } } @@ -117,13 +115,14 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { // will be attributes. if attr, ok := scmAttr[fieldName]; ok { if structTag.optional { - attr.SetOptional() + attr = attr.SetOptional() } else { - attr.SetRequired() + attr = attr.SetRequired() } if structTag.computed { - attr.SetComputed() + attr = attr.SetComputed() } + scmAttr[fieldName] = attr } } return NestedBlockObject{Attributes: scmAttr, Blocks: scmBlock} diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go index 818c77f5c0..28b1dc981b 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go @@ -40,19 +40,9 @@ type TestListTfSdk struct { Repeated types.List `tfsdk:"repeated" tf:"optional"` } -func (TestListTfSdk) GetComplexFieldTypes() map[string]reflect.Type { +func (TestListTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "repeated": reflect.TypeOf(types.Int64Type), - } -} - -func (TestListTfSdk) ToAttrType(context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "repeated": types.ListType{ - ElemType: types.Int64Type, - }, - }, + "repeated": reflect.TypeOf(types.Int64{}), } } @@ -60,19 +50,9 @@ type TestMapTfSdk struct { Attributes types.Map `tfsdk:"attributes" tf:"optional"` } -func (TestMapTfSdk) GetComplexFieldTypes() map[string]reflect.Type { +func (TestMapTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "attributes": reflect.TypeOf(types.StringType), - } -} - -func (TestMapTfSdk) ToAttrType(context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "attributes": types.MapType{ - ElemType: types.StringType, - }, - }, + "attributes": reflect.TypeOf(types.String{}), } } @@ -80,32 +60,18 @@ type TestNestedListTfSdk struct { NestedList types.List `tfsdk:"nested_list" tf:"optional"` } -func (TestNestedListTfSdk) GetComplexFieldTypes() map[string]reflect.Type { +func (TestNestedListTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "nested_list": reflect.TypeOf(DummyNested{}), } } -func (TestNestedListTfSdk) ToAttrType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "nested_list": types.ListType{ - ElemType: DummyNested{}.ToAttrType(ctx), - }, - }, - } -} - type DummyNested struct { Name types.String `tfsdk:"name" tf:"optional"` Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } -func (DummyNested) GetComplexFieldTypes() map[string]reflect.Type { - return map[string]reflect.Type{} -} - -func (DummyNested) ToAttrType(context.Context) types.ObjectType { +func (DummyNested) ToObjectType(context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -124,15 +90,7 @@ func (TestNestedMapTfSdk) GetComplexFieldTypes(context.Context) map[string]refle } } -func (TestNestedMapTfSdk) ToAttrType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "nested_map": types.MapType{ - ElemType: DummyNested{}.ToAttrType(ctx), - }, - }, - } -} +var dummyType = DummyNested{}.ToObjectType(context.Background()) var tests = []struct { name string @@ -164,13 +122,13 @@ var tests = []struct { }, { "nested list conversion", - TestNestedListTfSdk{NestedList: types.ListValueMust(DummyNested{}.ToAttrType(context.Background()), + TestNestedListTfSdk{NestedList: types.ListValueMust(dummyType, []attr.Value{ - types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ "name": types.StringValue("abc"), "enabled": types.BoolValue(true), }), - types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ "name": types.StringValue("def"), "enabled": types.BoolValue(false), }), @@ -179,12 +137,12 @@ var tests = []struct { }, { "nested map conversion", - TestNestedMapTfSdk{NestedMap: types.MapValueMust(DummyNested{}.ToAttrType(context.Background()), map[string]attr.Value{ - "key1": types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + TestNestedMapTfSdk{NestedMap: types.MapValueMust(dummyType, map[string]attr.Value{ + "key1": types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ "name": types.StringValue("abc"), "enabled": types.BoolValue(true), }), - "key2": types.ObjectValueMust(DummyNested{}.ToAttrType(context.Background()).AttrTypes, map[string]attr.Value{ + "key2": types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ "name": types.StringValue("def"), "enabled": types.BoolValue(false), }), @@ -255,7 +213,7 @@ type TestTfSdkList struct { Description types.List `tfsdk:"description" tf:"optional"` } -type TestTfSdkMap struct { +type TestTfSdkMapWithoutMetadata struct { Description types.Map `tfsdk:"description" tf:"optional"` } @@ -263,24 +221,15 @@ type TestSliceOfSlice struct { NestedList [][]string `tfsdk:"nested_list" tf:"optional"` } -type TestMapOfMap struct { - NestedMap map[string]map[string]string `tfsdk:"nested_map" tf:"optional"` -} - var error_tests = []struct { name string testStruct any expectedError string }{ { - "tf list conversion", - TestTfSdkList{}, - fmt.Sprintf("types.List should never be used in tfsdk structs. %s", common.TerraformBugErrorMessage), - }, - { - "tf map conversion", - TestTfSdkMap{}, - fmt.Sprintf("types.Map should never be used in tfsdk structs. %s", common.TerraformBugErrorMessage), + "tfsdk struct without complex field types conversion", + TestTfSdkMapWithoutMetadata{}, + fmt.Sprintf("complex field types not provided for type: tfschema.TestTfSdkMapWithoutMetadata. %s", common.TerraformBugErrorMessage), }, { "non-struct conversion", @@ -290,12 +239,7 @@ var error_tests = []struct { { "slice of slice conversion", TestSliceOfSlice{}, - fmt.Sprintf("unsupported slice value for nested_list: slice. %s", common.TerraformBugErrorMessage), - }, - { - "map of map conversion", - TestMapOfMap{}, - fmt.Sprintf("unsupported map value for nested_map: map. %s", common.TerraformBugErrorMessage), + fmt.Sprintf("unexpected type [][]string in tfsdk structs, expected a plugin framework type. %s", common.TerraformBugErrorMessage), }, } diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index fed5279844..783ba34afb 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -65,6 +65,13 @@ func (newState *App) SyncEffectiveFieldsDuringCreateOrUpdate(plan App) { func (newState *App) SyncEffectiveFieldsDuringRead(existingState App) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in App. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a App) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "active_deployment": reflect.TypeOf(AppDeployment{}), @@ -75,6 +82,8 @@ func (a App) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } +// ToAttrType returns the representation of App in the Terraform plugin framework type +// system. func (a App) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -125,10 +134,19 @@ func (newState *AppAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState AppAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppAccessControlRequest in the Terraform plugin framework type +// system. func (a AppAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -159,12 +177,21 @@ func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *AppAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AppAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(AppPermission{}), } } +// ToAttrType returns the representation of AppAccessControlResponse in the Terraform plugin framework type +// system. func (a AppAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -210,6 +237,13 @@ func (newState *AppDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppD func (newState *AppDeployment) SyncEffectiveFieldsDuringRead(existingState AppDeployment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppDeployment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppDeployment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "deployment_artifacts": reflect.TypeOf(AppDeploymentArtifacts{}), @@ -217,6 +251,8 @@ func (a AppDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of AppDeployment in the Terraform plugin framework type +// system. func (a AppDeployment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -248,10 +284,19 @@ func (newState *AppDeploymentArtifacts) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AppDeploymentArtifacts) SyncEffectiveFieldsDuringRead(existingState AppDeploymentArtifacts) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppDeploymentArtifacts. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppDeploymentArtifacts) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppDeploymentArtifacts in the Terraform plugin framework type +// system. func (a AppDeploymentArtifacts) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -273,10 +318,19 @@ func (newState *AppDeploymentStatus) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AppDeploymentStatus) SyncEffectiveFieldsDuringRead(existingState AppDeploymentStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppDeploymentStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppDeploymentStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppDeploymentStatus in the Terraform plugin framework type +// system. func (a AppDeploymentStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -300,12 +354,21 @@ func (newState *AppPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppP func (newState *AppPermission) SyncEffectiveFieldsDuringRead(existingState AppPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of AppPermission in the Terraform plugin framework type +// system. func (a AppPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -332,12 +395,21 @@ func (newState *AppPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan App func (newState *AppPermissions) SyncEffectiveFieldsDuringRead(existingState AppPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AppAccessControlResponse{}), } } +// ToAttrType returns the representation of AppPermissions in the Terraform plugin framework type +// system. func (a AppPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -362,10 +434,19 @@ func (newState *AppPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpda func (newState *AppPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState AppPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppPermissionsDescription in the Terraform plugin framework type +// system. func (a AppPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -387,12 +468,21 @@ func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState AppPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AppAccessControlRequest{}), } } +// ToAttrType returns the representation of AppPermissionsRequest in the Terraform plugin framework type +// system. func (a AppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -425,6 +515,13 @@ func (newState *AppResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppRes func (newState *AppResource) SyncEffectiveFieldsDuringRead(existingState AppResource) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppResource. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppResource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "job": reflect.TypeOf(AppResourceJob{}), @@ -434,6 +531,8 @@ func (a AppResource) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of AppResource in the Terraform plugin framework type +// system. func (a AppResource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -469,10 +568,19 @@ func (newState *AppResourceJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan App func (newState *AppResourceJob) SyncEffectiveFieldsDuringRead(existingState AppResourceJob) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppResourceJob. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppResourceJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppResourceJob in the Terraform plugin framework type +// system. func (a AppResourceJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -498,10 +606,19 @@ func (newState *AppResourceSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AppResourceSecret) SyncEffectiveFieldsDuringRead(existingState AppResourceSecret) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppResourceSecret. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppResourceSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppResourceSecret in the Terraform plugin framework type +// system. func (a AppResourceSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -526,10 +643,19 @@ func (newState *AppResourceServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpd func (newState *AppResourceServingEndpoint) SyncEffectiveFieldsDuringRead(existingState AppResourceServingEndpoint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppResourceServingEndpoint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppResourceServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppResourceServingEndpoint in the Terraform plugin framework type +// system. func (a AppResourceServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -553,10 +679,19 @@ func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AppResourceSqlWarehouse) SyncEffectiveFieldsDuringRead(existingState AppResourceSqlWarehouse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AppResourceSqlWarehouse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AppResourceSqlWarehouse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AppResourceSqlWarehouse in the Terraform plugin framework type +// system. func (a AppResourceSqlWarehouse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -579,10 +714,19 @@ func (newState *ApplicationStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ApplicationStatus) SyncEffectiveFieldsDuringRead(existingState ApplicationStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ApplicationStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ApplicationStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ApplicationStatus in the Terraform plugin framework type +// system. func (a ApplicationStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -605,10 +749,19 @@ func (newState *ComputeStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Comp func (newState *ComputeStatus) SyncEffectiveFieldsDuringRead(existingState ComputeStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ComputeStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ComputeStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ComputeStatus in the Terraform plugin framework type +// system. func (a ComputeStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -631,12 +784,21 @@ func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existingState CreateAppDeploymentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateAppDeploymentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app_deployment": reflect.TypeOf(AppDeployment{}), } } +// ToAttrType returns the representation of CreateAppDeploymentRequest in the Terraform plugin framework type +// system. func (a CreateAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -659,12 +821,21 @@ func (newState *CreateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateAppRequest) SyncEffectiveFieldsDuringRead(existingState CreateAppRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateAppRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app": reflect.TypeOf(App{}), } } +// ToAttrType returns the representation of CreateAppRequest in the Terraform plugin framework type +// system. func (a CreateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -687,10 +858,19 @@ func (newState *DeleteAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteAppRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAppRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAppRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAppRequest in the Terraform plugin framework type +// system. func (a DeleteAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -713,10 +893,19 @@ func (newState *GetAppDeploymentRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetAppDeploymentRequest) SyncEffectiveFieldsDuringRead(existingState GetAppDeploymentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAppDeploymentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAppDeploymentRequest in the Terraform plugin framework type +// system. func (a GetAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -738,10 +927,19 @@ func (newState *GetAppPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetAppPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAppPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAppPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetAppPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -761,12 +959,21 @@ func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetAppPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAppPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(AppPermissionsDescription{}), } } +// ToAttrType returns the representation of GetAppPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetAppPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -789,10 +996,19 @@ func (newState *GetAppPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetAppPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetAppPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAppPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAppPermissionsRequest in the Terraform plugin framework type +// system. func (a GetAppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -813,10 +1029,19 @@ func (newState *GetAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetA func (newState *GetAppRequest) SyncEffectiveFieldsDuringRead(existingState GetAppRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAppRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAppRequest in the Terraform plugin framework type +// system. func (a GetAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -842,10 +1067,19 @@ func (newState *ListAppDeploymentsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListAppDeploymentsRequest) SyncEffectiveFieldsDuringRead(existingState ListAppDeploymentsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAppDeploymentsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAppDeploymentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAppDeploymentsRequest in the Terraform plugin framework type +// system. func (a ListAppDeploymentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -869,12 +1103,21 @@ func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListAppDeploymentsResponse) SyncEffectiveFieldsDuringRead(existingState ListAppDeploymentsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAppDeploymentsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAppDeploymentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app_deployments": reflect.TypeOf(AppDeployment{}), } } +// ToAttrType returns the representation of ListAppDeploymentsResponse in the Terraform plugin framework type +// system. func (a ListAppDeploymentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -901,10 +1144,19 @@ func (newState *ListAppsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListAppsRequest) SyncEffectiveFieldsDuringRead(existingState ListAppsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAppsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAppsRequest in the Terraform plugin framework type +// system. func (a ListAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -926,12 +1178,21 @@ func (newState *ListAppsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListAppsResponse) SyncEffectiveFieldsDuringRead(existingState ListAppsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAppsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAppsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(App{}), } } +// ToAttrType returns the representation of ListAppsResponse in the Terraform plugin framework type +// system. func (a ListAppsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -954,10 +1215,19 @@ func (newState *StartAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan St func (newState *StartAppRequest) SyncEffectiveFieldsDuringRead(existingState StartAppRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartAppRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StartAppRequest in the Terraform plugin framework type +// system. func (a StartAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -977,10 +1247,19 @@ func (newState *StopAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sto func (newState *StopAppRequest) SyncEffectiveFieldsDuringRead(existingState StopAppRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StopAppRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StopAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StopAppRequest in the Terraform plugin framework type +// system. func (a StopAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1003,12 +1282,21 @@ func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateAppRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAppRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAppRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "app": reflect.TypeOf(App{}), } } +// ToAttrType returns the representation of UpdateAppRequest in the Terraform plugin framework type +// system. func (a UpdateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index fcd3b2a5b7..80b508ae2a 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -35,10 +35,19 @@ func (newState *ActionConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ActionConfiguration) SyncEffectiveFieldsDuringRead(existingState ActionConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ActionConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ActionConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ActionConfiguration in the Terraform plugin framework type +// system. func (a ActionConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -74,12 +83,21 @@ func (newState *AlertConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertConfiguration) SyncEffectiveFieldsDuringRead(existingState AlertConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "action_configurations": reflect.TypeOf(ActionConfiguration{}), } } +// ToAttrType returns the representation of AlertConfiguration in the Terraform plugin framework type +// system. func (a AlertConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -122,6 +140,13 @@ func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *BudgetConfiguration) SyncEffectiveFieldsDuringRead(existingState BudgetConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BudgetConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BudgetConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_configurations": reflect.TypeOf(AlertConfiguration{}), @@ -129,6 +154,8 @@ func (a BudgetConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of BudgetConfiguration in the Terraform plugin framework type +// system. func (a BudgetConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -162,6 +189,13 @@ func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringCreateOrUpda func (newState *BudgetConfigurationFilter) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BudgetConfigurationFilter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BudgetConfigurationFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(BudgetConfigurationFilterTagClause{}), @@ -169,6 +203,8 @@ func (a BudgetConfigurationFilter) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of BudgetConfigurationFilter in the Terraform plugin framework type +// system. func (a BudgetConfigurationFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -194,12 +230,21 @@ func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringCreate func (newState *BudgetConfigurationFilterClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterClause) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BudgetConfigurationFilterClause. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BudgetConfigurationFilterClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of BudgetConfigurationFilterClause in the Terraform plugin framework type +// system. func (a BudgetConfigurationFilterClause) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -223,12 +268,21 @@ func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringCre func (newState *BudgetConfigurationFilterTagClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterTagClause) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BudgetConfigurationFilterTagClause. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(BudgetConfigurationFilterClause{}), } } +// ToAttrType returns the representation of BudgetConfigurationFilterTagClause in the Terraform plugin framework type +// system. func (a BudgetConfigurationFilterTagClause) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -252,12 +306,21 @@ func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsD func (newState *BudgetConfigurationFilterWorkspaceIdClause) SyncEffectiveFieldsDuringRead(existingState BudgetConfigurationFilterWorkspaceIdClause) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BudgetConfigurationFilterWorkspaceIdClause. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(types.Int64{}), } } +// ToAttrType returns the representation of BudgetConfigurationFilterWorkspaceIdClause in the Terraform plugin framework type +// system. func (a BudgetConfigurationFilterWorkspaceIdClause) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -285,10 +348,19 @@ func (newState *CreateBillingUsageDashboardRequest) SyncEffectiveFieldsDuringCre func (newState *CreateBillingUsageDashboardRequest) SyncEffectiveFieldsDuringRead(existingState CreateBillingUsageDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBillingUsageDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateBillingUsageDashboardRequest in the Terraform plugin framework type +// system. func (a CreateBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -309,10 +381,19 @@ func (newState *CreateBillingUsageDashboardResponse) SyncEffectiveFieldsDuringCr func (newState *CreateBillingUsageDashboardResponse) SyncEffectiveFieldsDuringRead(existingState CreateBillingUsageDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBillingUsageDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateBillingUsageDashboardResponse in the Terraform plugin framework type +// system. func (a CreateBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -342,6 +423,13 @@ func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreate func (newState *CreateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudget) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBudgetConfigurationBudget. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_configurations": reflect.TypeOf(CreateBudgetConfigurationBudgetAlertConfigurations{}), @@ -349,6 +437,8 @@ func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } +// ToAttrType returns the representation of CreateBudgetConfigurationBudget in the Terraform plugin framework type +// system. func (a CreateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -377,10 +467,19 @@ func (newState *CreateBudgetConfigurationBudgetActionConfigurations) SyncEffecti func (newState *CreateBudgetConfigurationBudgetActionConfigurations) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudgetActionConfigurations) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBudgetConfigurationBudgetActionConfigurations. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateBudgetConfigurationBudgetActionConfigurations in the Terraform plugin framework type +// system. func (a CreateBudgetConfigurationBudgetActionConfigurations) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -413,12 +512,21 @@ func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiv func (newState *CreateBudgetConfigurationBudgetAlertConfigurations) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationBudgetAlertConfigurations) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBudgetConfigurationBudgetAlertConfigurations. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "action_configurations": reflect.TypeOf(CreateBudgetConfigurationBudgetActionConfigurations{}), } } +// ToAttrType returns the representation of CreateBudgetConfigurationBudgetAlertConfigurations in the Terraform plugin framework type +// system. func (a CreateBudgetConfigurationBudgetAlertConfigurations) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -444,12 +552,21 @@ func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *CreateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBudgetConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(CreateBudgetConfigurationBudget{}), } } +// ToAttrType returns the representation of CreateBudgetConfigurationRequest in the Terraform plugin framework type +// system. func (a CreateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -471,12 +588,21 @@ func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *CreateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState CreateBudgetConfigurationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateBudgetConfigurationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(BudgetConfiguration{}), } } +// ToAttrType returns the representation of CreateBudgetConfigurationResponse in the Terraform plugin framework type +// system. func (a CreateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -565,12 +691,21 @@ func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringC func (newState *CreateLogDeliveryConfigurationParams) SyncEffectiveFieldsDuringRead(existingState CreateLogDeliveryConfigurationParams) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateLogDeliveryConfigurationParams. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "workspace_ids_filter": reflect.TypeOf(types.Int64{}), } } +// ToAttrType returns the representation of CreateLogDeliveryConfigurationParams in the Terraform plugin framework type +// system. func (a CreateLogDeliveryConfigurationParams) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -601,10 +736,19 @@ func (newState *DeleteBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteBudgetConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteBudgetConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteBudgetConfigurationRequest in the Terraform plugin framework type +// system. func (a DeleteBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -622,10 +766,19 @@ func (newState *DeleteBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *DeleteBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteBudgetConfigurationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteBudgetConfigurationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteBudgetConfigurationResponse in the Terraform plugin framework type +// system. func (a DeleteBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -652,10 +805,19 @@ func (newState *DownloadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DownloadRequest) SyncEffectiveFieldsDuringRead(existingState DownloadRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DownloadRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DownloadRequest in the Terraform plugin framework type +// system. func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -676,10 +838,19 @@ func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DownloadResponse) SyncEffectiveFieldsDuringRead(existingState DownloadResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DownloadResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DownloadResponse in the Terraform plugin framework type +// system. func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -705,10 +876,19 @@ func (newState *GetBillingUsageDashboardRequest) SyncEffectiveFieldsDuringCreate func (newState *GetBillingUsageDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetBillingUsageDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetBillingUsageDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetBillingUsageDashboardRequest in the Terraform plugin framework type +// system. func (a GetBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -731,10 +911,19 @@ func (newState *GetBillingUsageDashboardResponse) SyncEffectiveFieldsDuringCreat func (newState *GetBillingUsageDashboardResponse) SyncEffectiveFieldsDuringRead(existingState GetBillingUsageDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetBillingUsageDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetBillingUsageDashboardResponse in the Terraform plugin framework type +// system. func (a GetBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -756,10 +945,19 @@ func (newState *GetBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState GetBudgetConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetBudgetConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetBudgetConfigurationRequest in the Terraform plugin framework type +// system. func (a GetBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -778,12 +976,21 @@ func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState GetBudgetConfigurationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetBudgetConfigurationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(BudgetConfiguration{}), } } +// ToAttrType returns the representation of GetBudgetConfigurationResponse in the Terraform plugin framework type +// system. func (a GetBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -806,10 +1013,19 @@ func (newState *GetLogDeliveryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetLogDeliveryRequest) SyncEffectiveFieldsDuringRead(existingState GetLogDeliveryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetLogDeliveryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetLogDeliveryRequest in the Terraform plugin framework type +// system. func (a GetLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -832,10 +1048,19 @@ func (newState *ListBudgetConfigurationsRequest) SyncEffectiveFieldsDuringCreate func (newState *ListBudgetConfigurationsRequest) SyncEffectiveFieldsDuringRead(existingState ListBudgetConfigurationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListBudgetConfigurationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListBudgetConfigurationsRequest in the Terraform plugin framework type +// system. func (a ListBudgetConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -857,12 +1082,21 @@ func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringCreat func (newState *ListBudgetConfigurationsResponse) SyncEffectiveFieldsDuringRead(existingState ListBudgetConfigurationsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListBudgetConfigurationsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budgets": reflect.TypeOf(BudgetConfiguration{}), } } +// ToAttrType returns the representation of ListBudgetConfigurationsResponse in the Terraform plugin framework type +// system. func (a ListBudgetConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -890,10 +1124,19 @@ func (newState *ListLogDeliveryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListLogDeliveryRequest) SyncEffectiveFieldsDuringRead(existingState ListLogDeliveryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListLogDeliveryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListLogDeliveryRequest in the Terraform plugin framework type +// system. func (a ListLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -994,6 +1237,13 @@ func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *LogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState LogDeliveryConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogDeliveryConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_status": reflect.TypeOf(LogDeliveryStatus{}), @@ -1001,6 +1251,8 @@ func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[ } } +// ToAttrType returns the representation of LogDeliveryConfiguration in the Terraform plugin framework type +// system. func (a LogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1055,10 +1307,19 @@ func (newState *LogDeliveryStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogDeliveryStatus) SyncEffectiveFieldsDuringRead(existingState LogDeliveryStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogDeliveryStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogDeliveryStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogDeliveryStatus in the Terraform plugin framework type +// system. func (a LogDeliveryStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1079,10 +1340,19 @@ func (newState *PatchStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PatchStatusResponse) SyncEffectiveFieldsDuringRead(existingState PatchStatusResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PatchStatusResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PatchStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PatchStatusResponse in the Terraform plugin framework type +// system. func (a PatchStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1112,6 +1382,13 @@ func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringCreate func (newState *UpdateBudgetConfigurationBudget) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationBudget) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateBudgetConfigurationBudget. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_configurations": reflect.TypeOf(AlertConfiguration{}), @@ -1119,6 +1396,8 @@ func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } +// ToAttrType returns the representation of UpdateBudgetConfigurationBudget in the Terraform plugin framework type +// system. func (a UpdateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1149,12 +1428,21 @@ func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringCreat func (newState *UpdateBudgetConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateBudgetConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(UpdateBudgetConfigurationBudget{}), } } +// ToAttrType returns the representation of UpdateBudgetConfigurationRequest in the Terraform plugin framework type +// system. func (a UpdateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1177,12 +1465,21 @@ func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringCrea func (newState *UpdateBudgetConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState UpdateBudgetConfigurationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateBudgetConfigurationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "budget": reflect.TypeOf(BudgetConfiguration{}), } } +// ToAttrType returns the representation of UpdateBudgetConfigurationResponse in the Terraform plugin framework type +// system. func (a UpdateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1210,10 +1507,19 @@ func (newState *UpdateLogDeliveryConfigurationStatusRequest) SyncEffectiveFields func (newState *UpdateLogDeliveryConfigurationStatusRequest) SyncEffectiveFieldsDuringRead(existingState UpdateLogDeliveryConfigurationStatusRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateLogDeliveryConfigurationStatusRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateLogDeliveryConfigurationStatusRequest in the Terraform plugin framework type +// system. func (a UpdateLogDeliveryConfigurationStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1233,12 +1539,21 @@ func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuring func (newState *WrappedCreateLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState WrappedCreateLogDeliveryConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WrappedCreateLogDeliveryConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_configuration": reflect.TypeOf(CreateLogDeliveryConfigurationParams{}), } } +// ToAttrType returns the representation of WrappedCreateLogDeliveryConfiguration in the Terraform plugin framework type +// system. func (a WrappedCreateLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1259,12 +1574,21 @@ func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringCreate func (newState *WrappedLogDeliveryConfiguration) SyncEffectiveFieldsDuringRead(existingState WrappedLogDeliveryConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WrappedLogDeliveryConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_configuration": reflect.TypeOf(LogDeliveryConfiguration{}), } } +// ToAttrType returns the representation of WrappedLogDeliveryConfiguration in the Terraform plugin framework type +// system. func (a WrappedLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1285,12 +1609,21 @@ func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringCreat func (newState *WrappedLogDeliveryConfigurations) SyncEffectiveFieldsDuringRead(existingState WrappedLogDeliveryConfigurations) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WrappedLogDeliveryConfigurations. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_delivery_configurations": reflect.TypeOf(LogDeliveryConfiguration{}), } } +// ToAttrType returns the representation of WrappedLogDeliveryConfigurations in the Terraform plugin framework type +// system. func (a WrappedLogDeliveryConfigurations) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 2b1e6ea764..03c386aab7 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -29,12 +29,21 @@ func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AccountsCreateMetastore) SyncEffectiveFieldsDuringRead(existingState AccountsCreateMetastore) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsCreateMetastore. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsCreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_info": reflect.TypeOf(CreateMetastore{}), } } +// ToAttrType returns the representation of AccountsCreateMetastore in the Terraform plugin framework type +// system. func (a AccountsCreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -59,12 +68,21 @@ func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringCrea func (newState *AccountsCreateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsCreateMetastoreAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsCreateMetastoreAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_assignment": reflect.TypeOf(CreateMetastoreAssignment{}), } } +// ToAttrType returns the representation of AccountsCreateMetastoreAssignment in the Terraform plugin framework type +// system. func (a AccountsCreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -89,12 +107,21 @@ func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringCreate func (newState *AccountsCreateStorageCredential) SyncEffectiveFieldsDuringRead(existingState AccountsCreateStorageCredential) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsCreateStorageCredential. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsCreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credential_info": reflect.TypeOf(CreateStorageCredential{}), } } +// ToAttrType returns the representation of AccountsCreateStorageCredential in the Terraform plugin framework type +// system. func (a AccountsCreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -116,12 +143,21 @@ func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUp func (newState *AccountsMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsMetastoreAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsMetastoreAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_assignment": reflect.TypeOf(MetastoreAssignment{}), } } +// ToAttrType returns the representation of AccountsMetastoreAssignment in the Terraform plugin framework type +// system. func (a AccountsMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -142,12 +178,21 @@ func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AccountsMetastoreInfo) SyncEffectiveFieldsDuringRead(existingState AccountsMetastoreInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsMetastoreInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsMetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_info": reflect.TypeOf(MetastoreInfo{}), } } +// ToAttrType returns the representation of AccountsMetastoreInfo in the Terraform plugin framework type +// system. func (a AccountsMetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -168,12 +213,21 @@ func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringCreateOr func (newState *AccountsStorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingState AccountsStorageCredentialInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsStorageCredentialInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsStorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credential_info": reflect.TypeOf(StorageCredentialInfo{}), } } +// ToAttrType returns the representation of AccountsStorageCredentialInfo in the Terraform plugin framework type +// system. func (a AccountsStorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -197,12 +251,21 @@ func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AccountsUpdateMetastore) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateMetastore) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsUpdateMetastore. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsUpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_info": reflect.TypeOf(UpdateMetastore{}), } } +// ToAttrType returns the representation of AccountsUpdateMetastore in the Terraform plugin framework type +// system. func (a AccountsUpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -228,12 +291,21 @@ func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringCrea func (newState *AccountsUpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateMetastoreAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsUpdateMetastoreAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastore_assignment": reflect.TypeOf(UpdateMetastoreAssignment{}), } } +// ToAttrType returns the representation of AccountsUpdateMetastoreAssignment in the Terraform plugin framework type +// system. func (a AccountsUpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -260,12 +332,21 @@ func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringCreate func (newState *AccountsUpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingState AccountsUpdateStorageCredential) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccountsUpdateStorageCredential. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccountsUpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credential_info": reflect.TypeOf(UpdateStorageCredential{}), } } +// ToAttrType returns the representation of AccountsUpdateStorageCredential in the Terraform plugin framework type +// system. func (a AccountsUpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -295,12 +376,21 @@ func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ArtifactAllowlistInfo) SyncEffectiveFieldsDuringRead(existingState ArtifactAllowlistInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ArtifactAllowlistInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ArtifactAllowlistInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "artifact_matchers": reflect.TypeOf(ArtifactMatcher{}), } } +// ToAttrType returns the representation of ArtifactAllowlistInfo in the Terraform plugin framework type +// system. func (a ArtifactAllowlistInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -327,10 +417,19 @@ func (newState *ArtifactMatcher) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ar func (newState *ArtifactMatcher) SyncEffectiveFieldsDuringRead(existingState ArtifactMatcher) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ArtifactMatcher. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ArtifactMatcher) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ArtifactMatcher in the Terraform plugin framework type +// system. func (a ArtifactMatcher) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -349,10 +448,19 @@ func (newState *AssignResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ass func (newState *AssignResponse) SyncEffectiveFieldsDuringRead(existingState AssignResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AssignResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AssignResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AssignResponse in the Terraform plugin framework type +// system. func (a AssignResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -380,10 +488,19 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan Aws func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsCredentials) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsCredentials. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AwsCredentials in the Terraform plugin framework type +// system. func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -414,10 +531,19 @@ func (newState *AwsIamRole) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsIamR func (newState *AwsIamRole) SyncEffectiveFieldsDuringRead(existingState AwsIamRole) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsIamRole. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsIamRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AwsIamRole in the Terraform plugin framework type +// system. func (a AwsIamRole) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -439,10 +565,19 @@ func (newState *AwsIamRoleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AwsIamRoleRequest) SyncEffectiveFieldsDuringRead(existingState AwsIamRoleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsIamRoleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsIamRoleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AwsIamRoleRequest in the Terraform plugin framework type +// system. func (a AwsIamRoleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -468,10 +603,19 @@ func (newState *AwsIamRoleResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AwsIamRoleResponse) SyncEffectiveFieldsDuringRead(existingState AwsIamRoleResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsIamRoleResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsIamRoleResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AwsIamRoleResponse in the Terraform plugin framework type +// system. func (a AwsIamRoleResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -497,10 +641,19 @@ func (newState *AzureActiveDirectoryToken) SyncEffectiveFieldsDuringCreateOrUpda func (newState *AzureActiveDirectoryToken) SyncEffectiveFieldsDuringRead(existingState AzureActiveDirectoryToken) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureActiveDirectoryToken. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureActiveDirectoryToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureActiveDirectoryToken in the Terraform plugin framework type +// system. func (a AzureActiveDirectoryToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -535,10 +688,19 @@ func (newState *AzureManagedIdentity) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *AzureManagedIdentity) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentity) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureManagedIdentity. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureManagedIdentity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureManagedIdentity in the Terraform plugin framework type +// system. func (a AzureManagedIdentity) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -569,10 +731,19 @@ func (newState *AzureManagedIdentityRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *AzureManagedIdentityRequest) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentityRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureManagedIdentityRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureManagedIdentityRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureManagedIdentityRequest in the Terraform plugin framework type +// system. func (a AzureManagedIdentityRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -604,10 +775,19 @@ func (newState *AzureManagedIdentityResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *AzureManagedIdentityResponse) SyncEffectiveFieldsDuringRead(existingState AzureManagedIdentityResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureManagedIdentityResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureManagedIdentityResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureManagedIdentityResponse in the Terraform plugin framework type +// system. func (a AzureManagedIdentityResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -636,10 +816,19 @@ func (newState *AzureServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AzureServicePrincipal) SyncEffectiveFieldsDuringRead(existingState AzureServicePrincipal) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureServicePrincipal. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureServicePrincipal in the Terraform plugin framework type +// system. func (a AzureServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -663,10 +852,19 @@ func (newState *AzureUserDelegationSas) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AzureUserDelegationSas) SyncEffectiveFieldsDuringRead(existingState AzureUserDelegationSas) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureUserDelegationSas. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureUserDelegationSas) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureUserDelegationSas in the Terraform plugin framework type +// system. func (a AzureUserDelegationSas) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -689,10 +887,19 @@ func (newState *CancelRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CancelRefreshRequest) SyncEffectiveFieldsDuringRead(existingState CancelRefreshRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelRefreshRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelRefreshRequest in the Terraform plugin framework type +// system. func (a CancelRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -711,10 +918,19 @@ func (newState *CancelRefreshResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CancelRefreshResponse) SyncEffectiveFieldsDuringRead(existingState CancelRefreshResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelRefreshResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelRefreshResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelRefreshResponse in the Terraform plugin framework type +// system. func (a CancelRefreshResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -785,6 +1001,13 @@ func (newState *CatalogInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Catalo func (newState *CatalogInfo) SyncEffectiveFieldsDuringRead(existingState CatalogInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CatalogInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), @@ -794,6 +1017,8 @@ func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of CatalogInfo in the Terraform plugin framework type +// system. func (a CatalogInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -848,10 +1073,19 @@ func (newState *CloudflareApiToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CloudflareApiToken) SyncEffectiveFieldsDuringRead(existingState CloudflareApiToken) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CloudflareApiToken. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CloudflareApiToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CloudflareApiToken in the Terraform plugin framework type +// system. func (a CloudflareApiToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -895,12 +1129,21 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ColumnInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "mask": reflect.TypeOf(ColumnMask{}), } } +// ToAttrType returns the representation of ColumnInfo in the Terraform plugin framework type +// system. func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -938,12 +1181,21 @@ func (newState *ColumnMask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnM func (newState *ColumnMask) SyncEffectiveFieldsDuringRead(existingState ColumnMask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ColumnMask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ColumnMask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "using_column_names": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ColumnMask in the Terraform plugin framework type +// system. func (a ColumnMask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1003,6 +1255,13 @@ func (newState *ConnectionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Con func (newState *ConnectionInfo) SyncEffectiveFieldsDuringRead(existingState ConnectionInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ConnectionInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.String{}), @@ -1011,6 +1270,8 @@ func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of ConnectionInfo in the Terraform plugin framework type +// system. func (a ConnectionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1063,12 +1324,21 @@ func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ContinuousUpdateStatus) SyncEffectiveFieldsDuringRead(existingState ContinuousUpdateStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ContinuousUpdateStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ContinuousUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "initial_pipeline_sync_progress": reflect.TypeOf(PipelineProgress{}), } } +// ToAttrType returns the representation of ContinuousUpdateStatus in the Terraform plugin framework type +// system. func (a ContinuousUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1109,6 +1379,13 @@ func (newState *CreateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateCatalog) SyncEffectiveFieldsDuringRead(existingState CreateCatalog) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCatalog. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.String{}), @@ -1116,6 +1393,8 @@ func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of CreateCatalog in the Terraform plugin framework type +// system. func (a CreateCatalog) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1157,6 +1436,13 @@ func (newState *CreateConnection) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateConnection) SyncEffectiveFieldsDuringRead(existingState CreateConnection) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateConnection. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.String{}), @@ -1164,6 +1450,8 @@ func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } +// ToAttrType returns the representation of CreateConnection in the Terraform plugin framework type +// system. func (a CreateConnection) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1212,6 +1500,13 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), @@ -1221,6 +1516,8 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of CreateCredentialRequest in the Terraform plugin framework type +// system. func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1275,12 +1572,21 @@ func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateExternalLocation) SyncEffectiveFieldsDuringRead(existingState CreateExternalLocation) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExternalLocation. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } +// ToAttrType returns the representation of CreateExternalLocation in the Terraform plugin framework type +// system. func (a CreateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1354,6 +1660,13 @@ func (newState *CreateFunction) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateFunction) SyncEffectiveFieldsDuringRead(existingState CreateFunction) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateFunction. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateFunction) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_params": reflect.TypeOf(FunctionParameterInfos{}), @@ -1362,6 +1675,8 @@ func (a CreateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of CreateFunction in the Terraform plugin framework type +// system. func (a CreateFunction) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1407,12 +1722,21 @@ func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateFunctionRequest) SyncEffectiveFieldsDuringRead(existingState CreateFunctionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateFunctionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "function_info": reflect.TypeOf(CreateFunction{}), } } +// ToAttrType returns the representation of CreateFunctionRequest in the Terraform plugin framework type +// system. func (a CreateFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1441,10 +1765,19 @@ func (newState *CreateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cr func (newState *CreateMetastore) SyncEffectiveFieldsDuringRead(existingState CreateMetastore) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateMetastore. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateMetastore in the Terraform plugin framework type +// system. func (a CreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1472,10 +1805,19 @@ func (newState *CreateMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState CreateMetastoreAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateMetastoreAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateMetastoreAssignment in the Terraform plugin framework type +// system. func (a CreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1533,6 +1875,13 @@ func (newState *CreateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateMonitor) SyncEffectiveFieldsDuringRead(existingState CreateMonitor) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateMonitor. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_metrics": reflect.TypeOf(MonitorMetric{}), @@ -1546,6 +1895,8 @@ func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of CreateMonitor in the Terraform plugin framework type +// system. func (a CreateMonitor) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1595,12 +1946,21 @@ func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState CreateOnlineTableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateOnlineTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table": reflect.TypeOf(OnlineTable{}), } } +// ToAttrType returns the representation of CreateOnlineTableRequest in the Terraform plugin framework type +// system. func (a CreateOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1631,10 +1991,19 @@ func (newState *CreateRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *CreateRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState CreateRegisteredModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRegisteredModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateRegisteredModelRequest in the Terraform plugin framework type +// system. func (a CreateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1656,10 +2025,19 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// system. func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1685,12 +2063,21 @@ func (newState *CreateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreateSchema) SyncEffectiveFieldsDuringRead(existingState CreateSchema) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateSchema. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of CreateSchema in the Terraform plugin framework type +// system. func (a CreateSchema) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1733,6 +2120,13 @@ func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateStorageCredential) SyncEffectiveFieldsDuringRead(existingState CreateStorageCredential) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateStorageCredential. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), @@ -1743,6 +2137,8 @@ func (a CreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of CreateStorageCredential in the Terraform plugin framework type +// system. func (a CreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1784,12 +2180,21 @@ func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateTableConstraint) SyncEffectiveFieldsDuringRead(existingState CreateTableConstraint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateTableConstraint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateTableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "constraint": reflect.TypeOf(TableConstraint{}), } } +// ToAttrType returns the representation of CreateTableConstraint in the Terraform plugin framework type +// system. func (a CreateTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1822,10 +2227,19 @@ func (newState *CreateVolumeRequestContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateVolumeRequestContent) SyncEffectiveFieldsDuringRead(existingState CreateVolumeRequestContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateVolumeRequestContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateVolumeRequestContent in the Terraform plugin framework type +// system. func (a CreateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1886,6 +2300,13 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState CredentialInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CredentialInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), @@ -1894,6 +2315,8 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of CredentialInfo in the Terraform plugin framework type +// system. func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1937,10 +2360,19 @@ func (newState *CredentialValidationResult) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CredentialValidationResult) SyncEffectiveFieldsDuringRead(existingState CredentialValidationResult) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CredentialValidationResult. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CredentialValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CredentialValidationResult in the Terraform plugin framework type +// system. func (a CredentialValidationResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1962,12 +2394,21 @@ func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CurrentWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingState CurrentWorkspaceBindings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CurrentWorkspaceBindings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CurrentWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "workspaces": reflect.TypeOf(types.Int64{}), } } +// ToAttrType returns the representation of CurrentWorkspaceBindings in the Terraform plugin framework type +// system. func (a CurrentWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1987,10 +2428,19 @@ func (newState *DatabricksGcpServiceAccountRequest) SyncEffectiveFieldsDuringCre func (newState *DatabricksGcpServiceAccountRequest) SyncEffectiveFieldsDuringRead(existingState DatabricksGcpServiceAccountRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DatabricksGcpServiceAccountRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DatabricksGcpServiceAccountRequest in the Terraform plugin framework type +// system. func (a DatabricksGcpServiceAccountRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2011,10 +2461,19 @@ func (newState *DatabricksGcpServiceAccountResponse) SyncEffectiveFieldsDuringCr func (newState *DatabricksGcpServiceAccountResponse) SyncEffectiveFieldsDuringRead(existingState DatabricksGcpServiceAccountResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DatabricksGcpServiceAccountResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DatabricksGcpServiceAccountResponse in the Terraform plugin framework type +// system. func (a DatabricksGcpServiceAccountResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2038,10 +2497,19 @@ func (newState *DeleteAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuri func (newState *DeleteAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountMetastoreAssignmentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountMetastoreAssignmentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountMetastoreAssignmentRequest in the Terraform plugin framework type +// system. func (a DeleteAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2065,10 +2533,19 @@ func (newState *DeleteAccountMetastoreRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteAccountMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountMetastoreRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountMetastoreRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountMetastoreRequest in the Terraform plugin framework type +// system. func (a DeleteAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2095,10 +2572,19 @@ func (newState *DeleteAccountStorageCredentialRequest) SyncEffectiveFieldsDuring func (newState *DeleteAccountStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountStorageCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountStorageCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountStorageCredentialRequest in the Terraform plugin framework type +// system. func (a DeleteAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2123,10 +2609,19 @@ func (newState *DeleteAliasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteAliasRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAliasRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAliasRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAliasRequest in the Terraform plugin framework type +// system. func (a DeleteAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2145,10 +2640,19 @@ func (newState *DeleteAliasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteAliasResponse) SyncEffectiveFieldsDuringRead(existingState DeleteAliasResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAliasResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAliasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAliasResponse in the Terraform plugin framework type +// system. func (a DeleteAliasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2169,10 +2673,19 @@ func (newState *DeleteCatalogRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteCatalogRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCatalogRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCatalogRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCatalogRequest in the Terraform plugin framework type +// system. func (a DeleteCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2194,10 +2707,19 @@ func (newState *DeleteConnectionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteConnectionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteConnectionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteConnectionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteConnectionRequest in the Terraform plugin framework type +// system. func (a DeleteConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2222,10 +2744,19 @@ func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type +// system. func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2244,10 +2775,19 @@ func (newState *DeleteCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteCredentialResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCredentialResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCredentialResponse in the Terraform plugin framework type +// system. func (a DeleteCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2268,10 +2808,19 @@ func (newState *DeleteExternalLocationRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteExternalLocationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExternalLocationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExternalLocationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExternalLocationRequest in the Terraform plugin framework type +// system. func (a DeleteExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2296,10 +2845,19 @@ func (newState *DeleteFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteFunctionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFunctionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteFunctionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteFunctionRequest in the Terraform plugin framework type +// system. func (a DeleteFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2323,10 +2881,19 @@ func (newState *DeleteMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState DeleteMetastoreRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteMetastoreRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteMetastoreRequest in the Terraform plugin framework type +// system. func (a DeleteMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2350,10 +2917,19 @@ func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type +// system. func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2375,10 +2951,19 @@ func (newState *DeleteOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteOnlineTableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteOnlineTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteOnlineTableRequest in the Terraform plugin framework type +// system. func (a DeleteOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2399,10 +2984,19 @@ func (newState *DeleteQualityMonitorRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *DeleteQualityMonitorRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQualityMonitorRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteQualityMonitorRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteQualityMonitorRequest in the Terraform plugin framework type +// system. func (a DeleteQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2423,10 +3017,19 @@ func (newState *DeleteRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRegisteredModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRegisteredModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRegisteredModelRequest in the Terraform plugin framework type +// system. func (a DeleteRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2444,10 +3047,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2468,10 +3080,19 @@ func (newState *DeleteSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteSchemaRequest) SyncEffectiveFieldsDuringRead(existingState DeleteSchemaRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteSchemaRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteSchemaRequest in the Terraform plugin framework type +// system. func (a DeleteSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2496,10 +3117,19 @@ func (newState *DeleteStorageCredentialRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteStorageCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteStorageCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteStorageCredentialRequest in the Terraform plugin framework type +// system. func (a DeleteStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2527,10 +3157,19 @@ func (newState *DeleteTableConstraintRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteTableConstraintRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableConstraintRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTableConstraintRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTableConstraintRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTableConstraintRequest in the Terraform plugin framework type +// system. func (a DeleteTableConstraintRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2553,10 +3192,19 @@ func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTableRequest in the Terraform plugin framework type +// system. func (a DeleteTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2577,10 +3225,19 @@ func (newState *DeleteVolumeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteVolumeRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVolumeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteVolumeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteVolumeRequest in the Terraform plugin framework type +// system. func (a DeleteVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2603,12 +3260,21 @@ func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOr func (newState *DeltaRuntimePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existingState DeltaRuntimePropertiesKvPairs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeltaRuntimePropertiesKvPairs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "delta_runtime_properties": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DeltaRuntimePropertiesKvPairs in the Terraform plugin framework type +// system. func (a DeltaRuntimePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2634,6 +3300,13 @@ func (newState *Dependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Depende func (newState *Dependency) SyncEffectiveFieldsDuringRead(existingState Dependency) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Dependency. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Dependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "function": reflect.TypeOf(FunctionDependency{}), @@ -2641,6 +3314,8 @@ func (a Dependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of Dependency in the Terraform plugin framework type +// system. func (a Dependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2666,12 +3341,21 @@ func (newState *DependencyList) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dep func (newState *DependencyList) SyncEffectiveFieldsDuringRead(existingState DependencyList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DependencyList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DependencyList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dependencies": reflect.TypeOf(Dependency{}), } } +// ToAttrType returns the representation of DependencyList in the Terraform plugin framework type +// system. func (a DependencyList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2696,10 +3380,19 @@ func (newState *DisableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dis func (newState *DisableRequest) SyncEffectiveFieldsDuringRead(existingState DisableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DisableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DisableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DisableRequest in the Terraform plugin framework type +// system. func (a DisableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2718,10 +3411,19 @@ func (newState *DisableResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Di func (newState *DisableResponse) SyncEffectiveFieldsDuringRead(existingState DisableResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DisableResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DisableResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DisableResponse in the Terraform plugin framework type +// system. func (a DisableResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2740,12 +3442,21 @@ func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EffectivePermissionsList) SyncEffectiveFieldsDuringRead(existingState EffectivePermissionsList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EffectivePermissionsList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EffectivePermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privilege_assignments": reflect.TypeOf(EffectivePrivilegeAssignment{}), } } +// ToAttrType returns the representation of EffectivePermissionsList in the Terraform plugin framework type +// system. func (a EffectivePermissionsList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2774,10 +3485,19 @@ func (newState *EffectivePredictiveOptimizationFlag) SyncEffectiveFieldsDuringCr func (newState *EffectivePredictiveOptimizationFlag) SyncEffectiveFieldsDuringRead(existingState EffectivePredictiveOptimizationFlag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EffectivePredictiveOptimizationFlag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EffectivePredictiveOptimizationFlag in the Terraform plugin framework type +// system. func (a EffectivePredictiveOptimizationFlag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2807,10 +3527,19 @@ func (newState *EffectivePrivilege) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EffectivePrivilege) SyncEffectiveFieldsDuringRead(existingState EffectivePrivilege) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EffectivePrivilege. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EffectivePrivilege) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EffectivePrivilege in the Terraform plugin framework type +// system. func (a EffectivePrivilege) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2835,12 +3564,21 @@ func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrU func (newState *EffectivePrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState EffectivePrivilegeAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EffectivePrivilegeAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EffectivePrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privileges": reflect.TypeOf(EffectivePrivilege{}), } } +// ToAttrType returns the representation of EffectivePrivilegeAssignment in the Terraform plugin framework type +// system. func (a EffectivePrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2866,10 +3604,19 @@ func (newState *EnableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Enab func (newState *EnableRequest) SyncEffectiveFieldsDuringRead(existingState EnableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EnableRequest in the Terraform plugin framework type +// system. func (a EnableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2888,10 +3635,19 @@ func (newState *EnableResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ena func (newState *EnableResponse) SyncEffectiveFieldsDuringRead(existingState EnableResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnableResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnableResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EnableResponse in the Terraform plugin framework type +// system. func (a EnableResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2910,12 +3666,21 @@ func (newState *EncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EncryptionDetails) SyncEffectiveFieldsDuringRead(existingState EncryptionDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EncryptionDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sse_encryption_details": reflect.TypeOf(SseEncryptionDetails{}), } } +// ToAttrType returns the representation of EncryptionDetails in the Terraform plugin framework type +// system. func (a EncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2938,10 +3703,19 @@ func (newState *ExistsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exis func (newState *ExistsRequest) SyncEffectiveFieldsDuringRead(existingState ExistsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExistsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExistsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExistsRequest in the Terraform plugin framework type +// system. func (a ExistsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2998,12 +3772,21 @@ func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExternalLocationInfo) SyncEffectiveFieldsDuringRead(existingState ExternalLocationInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalLocationInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExternalLocationInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } +// ToAttrType returns the representation of ExternalLocationInfo in the Terraform plugin framework type +// system. func (a ExternalLocationInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3050,10 +3833,19 @@ func (newState *FailedStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Faile func (newState *FailedStatus) SyncEffectiveFieldsDuringRead(existingState FailedStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FailedStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FailedStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FailedStatus in the Terraform plugin framework type +// system. func (a FailedStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3080,6 +3872,13 @@ func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ForeignKeyConstraint) SyncEffectiveFieldsDuringRead(existingState ForeignKeyConstraint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ForeignKeyConstraint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "child_columns": reflect.TypeOf(types.String{}), @@ -3087,6 +3886,8 @@ func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of ForeignKeyConstraint in the Terraform plugin framework type +// system. func (a ForeignKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3115,10 +3916,19 @@ func (newState *FunctionDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *FunctionDependency) SyncEffectiveFieldsDuringRead(existingState FunctionDependency) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FunctionDependency. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FunctionDependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FunctionDependency in the Terraform plugin framework type +// system. func (a FunctionDependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3203,6 +4013,13 @@ func (newState *FunctionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Funct func (newState *FunctionInfo) SyncEffectiveFieldsDuringRead(existingState FunctionInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FunctionInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FunctionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_params": reflect.TypeOf(FunctionParameterInfos{}), @@ -3211,6 +4028,8 @@ func (a FunctionInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of FunctionInfo in the Terraform plugin framework type +// system. func (a FunctionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3287,10 +4106,19 @@ func (newState *FunctionParameterInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *FunctionParameterInfo) SyncEffectiveFieldsDuringRead(existingState FunctionParameterInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FunctionParameterInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FunctionParameterInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FunctionParameterInfo in the Terraform plugin framework type +// system. func (a FunctionParameterInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3322,12 +4150,21 @@ func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *FunctionParameterInfos) SyncEffectiveFieldsDuringRead(existingState FunctionParameterInfos) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FunctionParameterInfos. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FunctionParameterInfos) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(FunctionParameterInfo{}), } } +// ToAttrType returns the representation of FunctionParameterInfos in the Terraform plugin framework type +// system. func (a FunctionParameterInfos) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3350,10 +4187,19 @@ func (newState *GcpOauthToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpO func (newState *GcpOauthToken) SyncEffectiveFieldsDuringRead(existingState GcpOauthToken) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpOauthToken. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpOauthToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpOauthToken in the Terraform plugin framework type +// system. func (a GcpOauthToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3378,10 +4224,19 @@ func (newState *GcpServiceAccountKey) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GcpServiceAccountKey) SyncEffectiveFieldsDuringRead(existingState GcpServiceAccountKey) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpServiceAccountKey. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpServiceAccountKey) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpServiceAccountKey in the Terraform plugin framework type +// system. func (a GcpServiceAccountKey) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3406,12 +4261,21 @@ func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFie func (newState *GenerateTemporaryServiceCredentialAzureOptions) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryServiceCredentialAzureOptions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenerateTemporaryServiceCredentialAzureOptions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "resources": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of GenerateTemporaryServiceCredentialAzureOptions in the Terraform plugin framework type +// system. func (a GenerateTemporaryServiceCredentialAzureOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3436,12 +4300,21 @@ func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDu func (newState *GenerateTemporaryServiceCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryServiceCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenerateTemporaryServiceCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "azure_options": reflect.TypeOf(GenerateTemporaryServiceCredentialAzureOptions{}), } } +// ToAttrType returns the representation of GenerateTemporaryServiceCredentialRequest in the Terraform plugin framework type +// system. func (a GenerateTemporaryServiceCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3468,10 +4341,19 @@ func (newState *GenerateTemporaryTableCredentialRequest) SyncEffectiveFieldsDuri func (newState *GenerateTemporaryTableCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryTableCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenerateTemporaryTableCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenerateTemporaryTableCredentialRequest in the Terraform plugin framework type +// system. func (a GenerateTemporaryTableCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3511,6 +4393,13 @@ func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDur func (newState *GenerateTemporaryTableCredentialResponse) SyncEffectiveFieldsDuringRead(existingState GenerateTemporaryTableCredentialResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenerateTemporaryTableCredentialResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_temp_credentials": reflect.TypeOf(AwsCredentials{}), @@ -3521,6 +4410,8 @@ func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes(ctx conte } } +// ToAttrType returns the representation of GenerateTemporaryTableCredentialResponse in the Terraform plugin framework type +// system. func (a GenerateTemporaryTableCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3557,10 +4448,19 @@ func (newState *GetAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringC func (newState *GetAccountMetastoreAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountMetastoreAssignmentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountMetastoreAssignmentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountMetastoreAssignmentRequest in the Terraform plugin framework type +// system. func (a GetAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3581,10 +4481,19 @@ func (newState *GetAccountMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetAccountMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountMetastoreRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountMetastoreRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountMetastoreRequest in the Terraform plugin framework type +// system. func (a GetAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3607,10 +4516,19 @@ func (newState *GetAccountStorageCredentialRequest) SyncEffectiveFieldsDuringCre func (newState *GetAccountStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountStorageCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountStorageCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountStorageCredentialRequest in the Terraform plugin framework type +// system. func (a GetAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3632,10 +4550,19 @@ func (newState *GetArtifactAllowlistRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetArtifactAllowlistRequest) SyncEffectiveFieldsDuringRead(existingState GetArtifactAllowlistRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetArtifactAllowlistRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetArtifactAllowlistRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetArtifactAllowlistRequest in the Terraform plugin framework type +// system. func (a GetArtifactAllowlistRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3667,10 +4594,19 @@ func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringRead(existingState GetBindingsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetBindingsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetBindingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetBindingsRequest in the Terraform plugin framework type +// system. func (a GetBindingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3699,10 +4635,19 @@ func (newState *GetByAliasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetByAliasRequest) SyncEffectiveFieldsDuringRead(existingState GetByAliasRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetByAliasRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetByAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetByAliasRequest in the Terraform plugin framework type +// system. func (a GetByAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3728,10 +4673,19 @@ func (newState *GetCatalogRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetCatalogRequest) SyncEffectiveFieldsDuringRead(existingState GetCatalogRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCatalogRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCatalogRequest in the Terraform plugin framework type +// system. func (a GetCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3753,10 +4707,19 @@ func (newState *GetConnectionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetConnectionRequest) SyncEffectiveFieldsDuringRead(existingState GetConnectionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetConnectionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetConnectionRequest in the Terraform plugin framework type +// system. func (a GetConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3777,10 +4740,19 @@ func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCredentialRequest in the Terraform plugin framework type +// system. func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3806,10 +4778,19 @@ func (newState *GetEffectiveRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetEffectiveRequest) SyncEffectiveFieldsDuringRead(existingState GetEffectiveRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEffectiveRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEffectiveRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetEffectiveRequest in the Terraform plugin framework type +// system. func (a GetEffectiveRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3835,10 +4816,19 @@ func (newState *GetExternalLocationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetExternalLocationRequest) SyncEffectiveFieldsDuringRead(existingState GetExternalLocationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExternalLocationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetExternalLocationRequest in the Terraform plugin framework type +// system. func (a GetExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3864,10 +4854,19 @@ func (newState *GetFunctionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetFunctionRequest) SyncEffectiveFieldsDuringRead(existingState GetFunctionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetFunctionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetFunctionRequest in the Terraform plugin framework type +// system. func (a GetFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3894,10 +4893,19 @@ func (newState *GetGrantRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetGrantRequest) SyncEffectiveFieldsDuringRead(existingState GetGrantRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetGrantRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetGrantRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetGrantRequest in the Terraform plugin framework type +// system. func (a GetGrantRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3920,10 +4928,19 @@ func (newState *GetMetastoreRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetMetastoreRequest) SyncEffectiveFieldsDuringRead(existingState GetMetastoreRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetMetastoreRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetMetastoreRequest in the Terraform plugin framework type +// system. func (a GetMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3983,10 +5000,19 @@ func (newState *GetMetastoreSummaryResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetMetastoreSummaryResponse) SyncEffectiveFieldsDuringRead(existingState GetMetastoreSummaryResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetMetastoreSummaryResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetMetastoreSummaryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetMetastoreSummaryResponse in the Terraform plugin framework type +// system. func (a GetMetastoreSummaryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4033,10 +5059,19 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetModelVersionRequest in the Terraform plugin framework type +// system. func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4060,10 +5095,19 @@ func (newState *GetOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState GetOnlineTableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetOnlineTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetOnlineTableRequest in the Terraform plugin framework type +// system. func (a GetOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4084,10 +5128,19 @@ func (newState *GetQualityMonitorRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetQualityMonitorRequest) SyncEffectiveFieldsDuringRead(existingState GetQualityMonitorRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetQualityMonitorRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetQualityMonitorRequest in the Terraform plugin framework type +// system. func (a GetQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4114,10 +5167,19 @@ func (newState *GetQuotaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetQuotaRequest) SyncEffectiveFieldsDuringRead(existingState GetQuotaRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetQuotaRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetQuotaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetQuotaRequest in the Terraform plugin framework type +// system. func (a GetQuotaRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4139,12 +5201,21 @@ func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetQuotaResponse) SyncEffectiveFieldsDuringRead(existingState GetQuotaResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetQuotaResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetQuotaResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "quota_info": reflect.TypeOf(QuotaInfo{}), } } +// ToAttrType returns the representation of GetQuotaResponse in the Terraform plugin framework type +// system. func (a GetQuotaResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4169,10 +5240,19 @@ func (newState *GetRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetRefreshRequest) SyncEffectiveFieldsDuringRead(existingState GetRefreshRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRefreshRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRefreshRequest in the Terraform plugin framework type +// system. func (a GetRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4199,10 +5279,19 @@ func (newState *GetRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRegisteredModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRegisteredModelRequest in the Terraform plugin framework type +// system. func (a GetRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4228,10 +5317,19 @@ func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringRead(existingState GetSchemaRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSchemaRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetSchemaRequest in the Terraform plugin framework type +// system. func (a GetSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4253,10 +5351,19 @@ func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetStorageCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStorageCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStorageCredentialRequest in the Terraform plugin framework type +// system. func (a GetStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4284,10 +5391,19 @@ func (newState *GetTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetTableRequest) SyncEffectiveFieldsDuringRead(existingState GetTableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetTableRequest in the Terraform plugin framework type +// system. func (a GetTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4311,10 +5427,19 @@ func (newState *GetWorkspaceBindingRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetWorkspaceBindingRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceBindingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceBindingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceBindingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWorkspaceBindingRequest in the Terraform plugin framework type +// system. func (a GetWorkspaceBindingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4335,10 +5460,19 @@ func (newState *ListAccountMetastoreAssignmentsRequest) SyncEffectiveFieldsDurin func (newState *ListAccountMetastoreAssignmentsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountMetastoreAssignmentsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountMetastoreAssignmentsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAccountMetastoreAssignmentsRequest in the Terraform plugin framework type +// system. func (a ListAccountMetastoreAssignmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4358,12 +5492,21 @@ func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuri func (newState *ListAccountMetastoreAssignmentsResponse) SyncEffectiveFieldsDuringRead(existingState ListAccountMetastoreAssignmentsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountMetastoreAssignmentsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "workspace_ids": reflect.TypeOf(types.Int64{}), } } +// ToAttrType returns the representation of ListAccountMetastoreAssignmentsResponse in the Terraform plugin framework type +// system. func (a ListAccountMetastoreAssignmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4386,10 +5529,19 @@ func (newState *ListAccountStorageCredentialsRequest) SyncEffectiveFieldsDuringC func (newState *ListAccountStorageCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountStorageCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountStorageCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAccountStorageCredentialsRequest in the Terraform plugin framework type +// system. func (a ListAccountStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4409,12 +5561,21 @@ func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuring func (newState *ListAccountStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListAccountStorageCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountStorageCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "storage_credentials": reflect.TypeOf(StorageCredentialInfo{}), } } +// ToAttrType returns the representation of ListAccountStorageCredentialsResponse in the Terraform plugin framework type +// system. func (a ListAccountStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4450,10 +5611,19 @@ func (newState *ListCatalogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListCatalogsRequest) SyncEffectiveFieldsDuringRead(existingState ListCatalogsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListCatalogsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListCatalogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListCatalogsRequest in the Terraform plugin framework type +// system. func (a ListCatalogsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4479,12 +5649,21 @@ func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListCatalogsResponse) SyncEffectiveFieldsDuringRead(existingState ListCatalogsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListCatalogsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListCatalogsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "catalogs": reflect.TypeOf(CatalogInfo{}), } } +// ToAttrType returns the representation of ListCatalogsResponse in the Terraform plugin framework type +// system. func (a ListCatalogsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4515,10 +5694,19 @@ func (newState *ListConnectionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListConnectionsRequest) SyncEffectiveFieldsDuringRead(existingState ListConnectionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListConnectionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListConnectionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListConnectionsRequest in the Terraform plugin framework type +// system. func (a ListConnectionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4543,12 +5731,21 @@ func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListConnectionsResponse) SyncEffectiveFieldsDuringRead(existingState ListConnectionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListConnectionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListConnectionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "connections": reflect.TypeOf(ConnectionInfo{}), } } +// ToAttrType returns the representation of ListConnectionsResponse in the Terraform plugin framework type +// system. func (a ListConnectionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4580,10 +5777,19 @@ func (newState *ListCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListCredentialsRequest in the Terraform plugin framework type +// system. func (a ListCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4608,12 +5814,21 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credentials": reflect.TypeOf(CredentialInfo{}), } } +// ToAttrType returns the representation of ListCredentialsResponse in the Terraform plugin framework type +// system. func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4647,10 +5862,19 @@ func (newState *ListExternalLocationsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListExternalLocationsRequest) SyncEffectiveFieldsDuringRead(existingState ListExternalLocationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExternalLocationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExternalLocationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListExternalLocationsRequest in the Terraform plugin framework type +// system. func (a ListExternalLocationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4676,12 +5900,21 @@ func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringCreateOr func (newState *ListExternalLocationsResponse) SyncEffectiveFieldsDuringRead(existingState ListExternalLocationsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExternalLocationsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExternalLocationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "external_locations": reflect.TypeOf(ExternalLocationInfo{}), } } +// ToAttrType returns the representation of ListExternalLocationsResponse in the Terraform plugin framework type +// system. func (a ListExternalLocationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4719,10 +5952,19 @@ func (newState *ListFunctionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListFunctionsRequest) SyncEffectiveFieldsDuringRead(existingState ListFunctionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListFunctionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListFunctionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListFunctionsRequest in the Terraform plugin framework type +// system. func (a ListFunctionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4750,12 +5992,21 @@ func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListFunctionsResponse) SyncEffectiveFieldsDuringRead(existingState ListFunctionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListFunctionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListFunctionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "functions": reflect.TypeOf(FunctionInfo{}), } } +// ToAttrType returns the representation of ListFunctionsResponse in the Terraform plugin framework type +// system. func (a ListFunctionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4778,12 +6029,21 @@ func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListMetastoresResponse) SyncEffectiveFieldsDuringRead(existingState ListMetastoresResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListMetastoresResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListMetastoresResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metastores": reflect.TypeOf(MetastoreInfo{}), } } +// ToAttrType returns the representation of ListMetastoresResponse in the Terraform plugin framework type +// system. func (a ListMetastoresResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4820,10 +6080,19 @@ func (newState *ListModelVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListModelVersionsRequest) SyncEffectiveFieldsDuringRead(existingState ListModelVersionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListModelVersionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListModelVersionsRequest in the Terraform plugin framework type +// system. func (a ListModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4849,12 +6118,21 @@ func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListModelVersionsResponse) SyncEffectiveFieldsDuringRead(existingState ListModelVersionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListModelVersionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_versions": reflect.TypeOf(ModelVersionInfo{}), } } +// ToAttrType returns the representation of ListModelVersionsResponse in the Terraform plugin framework type +// system. func (a ListModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4880,10 +6158,19 @@ func (newState *ListQuotasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQuotasRequest) SyncEffectiveFieldsDuringRead(existingState ListQuotasRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQuotasRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQuotasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListQuotasRequest in the Terraform plugin framework type +// system. func (a ListQuotasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4908,12 +6195,21 @@ func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQuotasResponse) SyncEffectiveFieldsDuringRead(existingState ListQuotasResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQuotasResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQuotasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "quotas": reflect.TypeOf(QuotaInfo{}), } } +// ToAttrType returns the representation of ListQuotasResponse in the Terraform plugin framework type +// system. func (a ListQuotasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4937,10 +6233,19 @@ func (newState *ListRefreshesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListRefreshesRequest) SyncEffectiveFieldsDuringRead(existingState ListRefreshesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRefreshesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRefreshesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListRefreshesRequest in the Terraform plugin framework type +// system. func (a ListRefreshesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4988,10 +6293,19 @@ func (newState *ListRegisteredModelsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListRegisteredModelsRequest) SyncEffectiveFieldsDuringRead(existingState ListRegisteredModelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRegisteredModelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRegisteredModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListRegisteredModelsRequest in the Terraform plugin framework type +// system. func (a ListRegisteredModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5018,12 +6332,21 @@ func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListRegisteredModelsResponse) SyncEffectiveFieldsDuringRead(existingState ListRegisteredModelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRegisteredModelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRegisteredModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_models": reflect.TypeOf(RegisteredModelInfo{}), } } +// ToAttrType returns the representation of ListRegisteredModelsResponse in the Terraform plugin framework type +// system. func (a ListRegisteredModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5059,10 +6382,19 @@ func (newState *ListSchemasRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSchemasRequest) SyncEffectiveFieldsDuringRead(existingState ListSchemasRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSchemasRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSchemasRequest in the Terraform plugin framework type +// system. func (a ListSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5089,12 +6421,21 @@ func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListSchemasResponse) SyncEffectiveFieldsDuringRead(existingState ListSchemasResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSchemasResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schemas": reflect.TypeOf(SchemaInfo{}), } } +// ToAttrType returns the representation of ListSchemasResponse in the Terraform plugin framework type +// system. func (a ListSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5125,10 +6466,19 @@ func (newState *ListStorageCredentialsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListStorageCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState ListStorageCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListStorageCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListStorageCredentialsRequest in the Terraform plugin framework type +// system. func (a ListStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5153,12 +6503,21 @@ func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListStorageCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListStorageCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListStorageCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "storage_credentials": reflect.TypeOf(StorageCredentialInfo{}), } } +// ToAttrType returns the representation of ListStorageCredentialsResponse in the Terraform plugin framework type +// system. func (a ListStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5200,10 +6559,19 @@ func (newState *ListSummariesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListSummariesRequest) SyncEffectiveFieldsDuringRead(existingState ListSummariesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSummariesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSummariesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSummariesRequest in the Terraform plugin framework type +// system. func (a ListSummariesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5238,10 +6606,19 @@ func (newState *ListSystemSchemasRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListSystemSchemasRequest) SyncEffectiveFieldsDuringRead(existingState ListSystemSchemasRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSystemSchemasRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSystemSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSystemSchemasRequest in the Terraform plugin framework type +// system. func (a ListSystemSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5267,12 +6644,21 @@ func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListSystemSchemasResponse) SyncEffectiveFieldsDuringRead(existingState ListSystemSchemasResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSystemSchemasResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSystemSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schemas": reflect.TypeOf(SystemSchemaInfo{}), } } +// ToAttrType returns the representation of ListSystemSchemasResponse in the Terraform plugin framework type +// system. func (a ListSystemSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5299,12 +6685,21 @@ func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListTableSummariesResponse) SyncEffectiveFieldsDuringRead(existingState ListTableSummariesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTableSummariesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTableSummariesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tables": reflect.TypeOf(TableSummary{}), } } +// ToAttrType returns the representation of ListTableSummariesResponse in the Terraform plugin framework type +// system. func (a ListTableSummariesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5353,10 +6748,19 @@ func (newState *ListTablesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTablesRequest) SyncEffectiveFieldsDuringRead(existingState ListTablesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTablesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTablesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListTablesRequest in the Terraform plugin framework type +// system. func (a ListTablesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5389,12 +6793,21 @@ func (newState *ListTablesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTablesResponse) SyncEffectiveFieldsDuringRead(existingState ListTablesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTablesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTablesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tables": reflect.TypeOf(TableInfo{}), } } +// ToAttrType returns the representation of ListTablesResponse in the Terraform plugin framework type +// system. func (a ListTablesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5439,10 +6852,19 @@ func (newState *ListVolumesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListVolumesRequest) SyncEffectiveFieldsDuringRead(existingState ListVolumesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListVolumesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListVolumesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListVolumesRequest in the Terraform plugin framework type +// system. func (a ListVolumesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5470,12 +6892,21 @@ func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListVolumesResponseContent) SyncEffectiveFieldsDuringRead(existingState ListVolumesResponseContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListVolumesResponseContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListVolumesResponseContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "volumes": reflect.TypeOf(VolumeInfo{}), } } +// ToAttrType returns the representation of ListVolumesResponseContent in the Terraform plugin framework type +// system. func (a ListVolumesResponseContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5502,10 +6933,19 @@ func (newState *MetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState MetastoreAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MetastoreAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MetastoreAssignment in the Terraform plugin framework type +// system. func (a MetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5567,10 +7007,19 @@ func (newState *MetastoreInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Meta func (newState *MetastoreInfo) SyncEffectiveFieldsDuringRead(existingState MetastoreInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MetastoreInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MetastoreInfo in the Terraform plugin framework type +// system. func (a MetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5656,6 +7105,13 @@ func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan M func (newState *ModelVersionInfo) SyncEffectiveFieldsDuringRead(existingState ModelVersionInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelVersionInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelVersionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aliases": reflect.TypeOf(RegisteredModelAlias{}), @@ -5663,6 +7119,8 @@ func (a ModelVersionInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } +// ToAttrType returns the representation of ModelVersionInfo in the Terraform plugin framework type +// system. func (a ModelVersionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5711,10 +7169,19 @@ func (newState *MonitorCronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MonitorCronSchedule) SyncEffectiveFieldsDuringRead(existingState MonitorCronSchedule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorCronSchedule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorCronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MonitorCronSchedule in the Terraform plugin framework type +// system. func (a MonitorCronSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5736,10 +7203,19 @@ func (newState *MonitorDataClassificationConfig) SyncEffectiveFieldsDuringCreate func (newState *MonitorDataClassificationConfig) SyncEffectiveFieldsDuringRead(existingState MonitorDataClassificationConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorDataClassificationConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorDataClassificationConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MonitorDataClassificationConfig in the Terraform plugin framework type +// system. func (a MonitorDataClassificationConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5760,12 +7236,21 @@ func (newState *MonitorDestination) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorDestination) SyncEffectiveFieldsDuringRead(existingState MonitorDestination) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorDestination. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "email_addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of MonitorDestination in the Terraform plugin framework type +// system. func (a MonitorDestination) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5813,12 +7298,21 @@ func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MonitorInferenceLog) SyncEffectiveFieldsDuringRead(existingState MonitorInferenceLog) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorInferenceLog. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorInferenceLog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "granularities": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of MonitorInferenceLog in the Terraform plugin framework type +// system. func (a MonitorInferenceLog) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5893,6 +7387,13 @@ func (newState *MonitorInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Monito func (newState *MonitorInfo) SyncEffectiveFieldsDuringRead(existingState MonitorInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_metrics": reflect.TypeOf(MonitorMetric{}), @@ -5906,6 +7407,8 @@ func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of MonitorInfo in the Terraform plugin framework type +// system. func (a MonitorInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5980,12 +7483,21 @@ func (newState *MonitorMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan Moni func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState MonitorMetric) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorMetric. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_columns": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of MonitorMetric in the Terraform plugin framework type +// system. func (a MonitorMetric) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6014,6 +7526,13 @@ func (newState *MonitorNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *MonitorNotifications) SyncEffectiveFieldsDuringRead(existingState MonitorNotifications) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorNotifications. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_failure": reflect.TypeOf(MonitorDestination{}), @@ -6021,6 +7540,8 @@ func (a MonitorNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of MonitorNotifications in the Terraform plugin framework type +// system. func (a MonitorNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6058,10 +7579,19 @@ func (newState *MonitorRefreshInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorRefreshInfo) SyncEffectiveFieldsDuringRead(existingState MonitorRefreshInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorRefreshInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MonitorRefreshInfo in the Terraform plugin framework type +// system. func (a MonitorRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6086,12 +7616,21 @@ func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *MonitorRefreshListResponse) SyncEffectiveFieldsDuringRead(existingState MonitorRefreshListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorRefreshListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorRefreshListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "refreshes": reflect.TypeOf(MonitorRefreshInfo{}), } } +// ToAttrType returns the representation of MonitorRefreshListResponse in the Terraform plugin framework type +// system. func (a MonitorRefreshListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6111,10 +7650,19 @@ func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringRead(existingState MonitorSnapshot) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorSnapshot. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MonitorSnapshot in the Terraform plugin framework type +// system. func (a MonitorSnapshot) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6142,12 +7690,21 @@ func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MonitorTimeSeries) SyncEffectiveFieldsDuringRead(existingState MonitorTimeSeries) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorTimeSeries. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MonitorTimeSeries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "granularities": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of MonitorTimeSeries in the Terraform plugin framework type +// system. func (a MonitorTimeSeries) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6170,10 +7727,19 @@ func (newState *NamedTableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *NamedTableConstraint) SyncEffectiveFieldsDuringRead(existingState NamedTableConstraint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NamedTableConstraint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NamedTableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NamedTableConstraint in the Terraform plugin framework type +// system. func (a NamedTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6205,6 +7771,13 @@ func (newState *OnlineTable) SyncEffectiveFieldsDuringCreateOrUpdate(plan Online func (newState *OnlineTable) SyncEffectiveFieldsDuringRead(existingState OnlineTable) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OnlineTable. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OnlineTable) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "spec": reflect.TypeOf(OnlineTableSpec{}), @@ -6212,6 +7785,8 @@ func (a OnlineTable) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of OnlineTable in the Terraform plugin framework type +// system. func (a OnlineTable) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6261,6 +7836,13 @@ func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan On func (newState *OnlineTableSpec) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OnlineTableSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "primary_key_columns": reflect.TypeOf(types.String{}), @@ -6269,6 +7851,8 @@ func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of OnlineTableSpec in the Terraform plugin framework type +// system. func (a OnlineTableSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6298,10 +7882,19 @@ func (newState *OnlineTableSpecContinuousSchedulingPolicy) SyncEffectiveFieldsDu func (newState *OnlineTableSpecContinuousSchedulingPolicy) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpecContinuousSchedulingPolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OnlineTableSpecContinuousSchedulingPolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of OnlineTableSpecContinuousSchedulingPolicy in the Terraform plugin framework type +// system. func (a OnlineTableSpecContinuousSchedulingPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6317,10 +7910,19 @@ func (newState *OnlineTableSpecTriggeredSchedulingPolicy) SyncEffectiveFieldsDur func (newState *OnlineTableSpecTriggeredSchedulingPolicy) SyncEffectiveFieldsDuringRead(existingState OnlineTableSpecTriggeredSchedulingPolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OnlineTableSpecTriggeredSchedulingPolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of OnlineTableSpecTriggeredSchedulingPolicy in the Terraform plugin framework type +// system. func (a OnlineTableSpecTriggeredSchedulingPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6354,6 +7956,13 @@ func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *OnlineTableStatus) SyncEffectiveFieldsDuringRead(existingState OnlineTableStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OnlineTableStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OnlineTableStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "continuous_update_status": reflect.TypeOf(ContinuousUpdateStatus{}), @@ -6363,6 +7972,8 @@ func (a OnlineTableStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of OnlineTableStatus in the Terraform plugin framework type +// system. func (a OnlineTableStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6399,6 +8010,13 @@ func (newState *PermissionsChange) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PermissionsChange) SyncEffectiveFieldsDuringRead(existingState PermissionsChange) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionsChange. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add": reflect.TypeOf(types.String{}), @@ -6406,6 +8024,8 @@ func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of PermissionsChange in the Terraform plugin framework type +// system. func (a PermissionsChange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6431,12 +8051,21 @@ func (newState *PermissionsList) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pe func (newState *PermissionsList) SyncEffectiveFieldsDuringRead(existingState PermissionsList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionsList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privilege_assignments": reflect.TypeOf(PrivilegeAssignment{}), } } +// ToAttrType returns the representation of PermissionsList in the Terraform plugin framework type +// system. func (a PermissionsList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6469,10 +8098,19 @@ func (newState *PipelineProgress) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *PipelineProgress) SyncEffectiveFieldsDuringRead(existingState PipelineProgress) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineProgress. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineProgress) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelineProgress in the Terraform plugin framework type +// system. func (a PipelineProgress) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6498,12 +8136,21 @@ func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PrimaryKeyConstraint) SyncEffectiveFieldsDuringRead(existingState PrimaryKeyConstraint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PrimaryKeyConstraint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PrimaryKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "child_columns": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of PrimaryKeyConstraint in the Terraform plugin framework type +// system. func (a PrimaryKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6528,12 +8175,21 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState PrivilegeAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PrivilegeAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privileges": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of PrivilegeAssignment in the Terraform plugin framework type +// system. func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6556,10 +8212,19 @@ func (newState *ProvisioningInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *ProvisioningInfo) SyncEffectiveFieldsDuringRead(existingState ProvisioningInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ProvisioningInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ProvisioningInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ProvisioningInfo in the Terraform plugin framework type +// system. func (a ProvisioningInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6582,12 +8247,21 @@ func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ProvisioningStatus) SyncEffectiveFieldsDuringRead(existingState ProvisioningStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ProvisioningStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ProvisioningStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "initial_pipeline_sync_progress": reflect.TypeOf(PipelineProgress{}), } } +// ToAttrType returns the representation of ProvisioningStatus in the Terraform plugin framework type +// system. func (a ProvisioningStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6620,10 +8294,19 @@ func (newState *QuotaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan QuotaInf func (newState *QuotaInfo) SyncEffectiveFieldsDuringRead(existingState QuotaInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QuotaInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QuotaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of QuotaInfo in the Terraform plugin framework type +// system. func (a QuotaInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6654,10 +8337,19 @@ func (newState *R2Credentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan R2Cr func (newState *R2Credentials) SyncEffectiveFieldsDuringRead(existingState R2Credentials) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in R2Credentials. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a R2Credentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of R2Credentials in the Terraform plugin framework type +// system. func (a R2Credentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6683,10 +8375,19 @@ func (newState *ReadVolumeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ReadVolumeRequest) SyncEffectiveFieldsDuringRead(existingState ReadVolumeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReadVolumeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReadVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ReadVolumeRequest in the Terraform plugin framework type +// system. func (a ReadVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6710,10 +8411,19 @@ func (newState *RegenerateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RegenerateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState RegenerateDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegenerateDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegenerateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RegenerateDashboardRequest in the Terraform plugin framework type +// system. func (a RegenerateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6736,10 +8446,19 @@ func (newState *RegenerateDashboardResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *RegenerateDashboardResponse) SyncEffectiveFieldsDuringRead(existingState RegenerateDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegenerateDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegenerateDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RegenerateDashboardResponse in the Terraform plugin framework type +// system. func (a RegenerateDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6763,10 +8482,19 @@ func (newState *RegisteredModelAlias) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RegisteredModelAlias) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAlias) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelAlias. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelAlias) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RegisteredModelAlias in the Terraform plugin framework type +// system. func (a RegisteredModelAlias) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6818,12 +8546,21 @@ func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RegisteredModelInfo) SyncEffectiveFieldsDuringRead(existingState RegisteredModelInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aliases": reflect.TypeOf(RegisteredModelAlias{}), } } +// ToAttrType returns the representation of RegisteredModelInfo in the Terraform plugin framework type +// system. func (a RegisteredModelInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6859,10 +8596,19 @@ func (newState *RunRefreshRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RunRefreshRequest) SyncEffectiveFieldsDuringRead(existingState RunRefreshRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunRefreshRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunRefreshRequest in the Terraform plugin framework type +// system. func (a RunRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6919,6 +8665,13 @@ func (newState *SchemaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaI func (newState *SchemaInfo) SyncEffectiveFieldsDuringRead(existingState SchemaInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SchemaInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_predictive_optimization_flag": reflect.TypeOf(EffectivePredictiveOptimizationFlag{}), @@ -6926,6 +8679,8 @@ func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of SchemaInfo in the Terraform plugin framework type +// system. func (a SchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6968,12 +8723,21 @@ func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SetArtifactAllowlist) SyncEffectiveFieldsDuringRead(existingState SetArtifactAllowlist) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetArtifactAllowlist. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetArtifactAllowlist) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "artifact_matchers": reflect.TypeOf(ArtifactMatcher{}), } } +// ToAttrType returns the representation of SetArtifactAllowlist in the Terraform plugin framework type +// system. func (a SetArtifactAllowlist) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7000,10 +8764,19 @@ func (newState *SetRegisteredModelAliasRequest) SyncEffectiveFieldsDuringCreateO func (newState *SetRegisteredModelAliasRequest) SyncEffectiveFieldsDuringRead(existingState SetRegisteredModelAliasRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetRegisteredModelAliasRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetRegisteredModelAliasRequest in the Terraform plugin framework type +// system. func (a SetRegisteredModelAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7029,10 +8802,19 @@ func (newState *SseEncryptionDetails) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SseEncryptionDetails) SyncEffectiveFieldsDuringRead(existingState SseEncryptionDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SseEncryptionDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SseEncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SseEncryptionDetails in the Terraform plugin framework type +// system. func (a SseEncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7088,6 +8870,13 @@ func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *StorageCredentialInfo) SyncEffectiveFieldsDuringRead(existingState StorageCredentialInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StorageCredentialInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleResponse{}), @@ -7098,6 +8887,8 @@ func (a StorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of StorageCredentialInfo in the Terraform plugin framework type +// system. func (a StorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7147,10 +8938,19 @@ func (newState *SystemSchemaInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SystemSchemaInfo) SyncEffectiveFieldsDuringRead(existingState SystemSchemaInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SystemSchemaInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SystemSchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SystemSchemaInfo in the Terraform plugin framework type +// system. func (a SystemSchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7177,6 +8977,13 @@ func (newState *TableConstraint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ta func (newState *TableConstraint) SyncEffectiveFieldsDuringRead(existingState TableConstraint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableConstraint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "foreign_key_constraint": reflect.TypeOf(ForeignKeyConstraint{}), @@ -7185,6 +8992,8 @@ func (a TableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of TableConstraint in the Terraform plugin framework type +// system. func (a TableConstraint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7214,10 +9023,19 @@ func (newState *TableDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ta func (newState *TableDependency) SyncEffectiveFieldsDuringRead(existingState TableDependency) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableDependency. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableDependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TableDependency in the Terraform plugin framework type +// system. func (a TableDependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7237,10 +9055,19 @@ func (newState *TableExistsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TableExistsResponse) SyncEffectiveFieldsDuringRead(existingState TableExistsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableExistsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableExistsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TableExistsResponse in the Terraform plugin framework type +// system. func (a TableExistsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7335,6 +9162,13 @@ func (newState *TableInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableInf func (newState *TableInfo) SyncEffectiveFieldsDuringRead(existingState TableInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(ColumnInfo{}), @@ -7348,6 +9182,8 @@ func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of TableInfo in the Terraform plugin framework type +// system. func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7418,12 +9254,21 @@ func (newState *TableRowFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tab func (newState *TableRowFilter) SyncEffectiveFieldsDuringRead(existingState TableRowFilter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableRowFilter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableRowFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input_column_names": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of TableRowFilter in the Terraform plugin framework type +// system. func (a TableRowFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7448,10 +9293,19 @@ func (newState *TableSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Table func (newState *TableSummary) SyncEffectiveFieldsDuringRead(existingState TableSummary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableSummary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TableSummary in the Terraform plugin framework type +// system. func (a TableSummary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7480,6 +9334,13 @@ func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *TemporaryCredentials) SyncEffectiveFieldsDuringRead(existingState TemporaryCredentials) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TemporaryCredentials. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TemporaryCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_temp_credentials": reflect.TypeOf(AwsCredentials{}), @@ -7487,6 +9348,8 @@ func (a TemporaryCredentials) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of TemporaryCredentials in the Terraform plugin framework type +// system. func (a TemporaryCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7521,12 +9384,21 @@ func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *TriggeredUpdateStatus) SyncEffectiveFieldsDuringRead(existingState TriggeredUpdateStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TriggeredUpdateStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TriggeredUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "triggered_update_progress": reflect.TypeOf(PipelineProgress{}), } } +// ToAttrType returns the representation of TriggeredUpdateStatus in the Terraform plugin framework type +// system. func (a TriggeredUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7553,10 +9425,19 @@ func (newState *UnassignRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Un func (newState *UnassignRequest) SyncEffectiveFieldsDuringRead(existingState UnassignRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UnassignRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UnassignRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UnassignRequest in the Terraform plugin framework type +// system. func (a UnassignRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7575,10 +9456,19 @@ func (newState *UnassignResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UnassignResponse) SyncEffectiveFieldsDuringRead(existingState UnassignResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UnassignResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UnassignResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UnassignResponse in the Terraform plugin framework type +// system. func (a UnassignResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -7594,10 +9484,19 @@ func (newState *UpdateAssignmentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateAssignmentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateAssignmentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAssignmentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateAssignmentResponse in the Terraform plugin framework type +// system. func (a UpdateAssignmentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -7629,12 +9528,21 @@ func (newState *UpdateCatalog) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateCatalog) SyncEffectiveFieldsDuringRead(existingState UpdateCatalog) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCatalog. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpdateCatalog in the Terraform plugin framework type +// system. func (a UpdateCatalog) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7668,12 +9576,21 @@ func (newState *UpdateConnection) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateConnection) SyncEffectiveFieldsDuringRead(existingState UpdateConnection) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateConnection. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateConnection) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpdateConnection in the Terraform plugin framework type +// system. func (a UpdateConnection) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7723,6 +9640,13 @@ func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), @@ -7731,6 +9655,8 @@ func (a UpdateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of UpdateCredentialRequest in the Terraform plugin framework type +// system. func (a UpdateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7794,12 +9720,21 @@ func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateExternalLocation) SyncEffectiveFieldsDuringRead(existingState UpdateExternalLocation) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExternalLocation. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } +// ToAttrType returns the representation of UpdateExternalLocation in the Terraform plugin framework type +// system. func (a UpdateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7836,10 +9771,19 @@ func (newState *UpdateFunction) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateFunction) SyncEffectiveFieldsDuringRead(existingState UpdateFunction) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateFunction. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateFunction) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateFunction in the Terraform plugin framework type +// system. func (a UpdateFunction) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7876,10 +9820,19 @@ func (newState *UpdateMetastore) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateMetastore) SyncEffectiveFieldsDuringRead(existingState UpdateMetastore) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateMetastore. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateMetastore in the Terraform plugin framework type +// system. func (a UpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7912,10 +9865,19 @@ func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existingState UpdateMetastoreAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateMetastoreAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateMetastoreAssignment in the Terraform plugin framework type +// system. func (a UpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7941,10 +9903,19 @@ func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type +// system. func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7997,6 +9968,13 @@ func (newState *UpdateMonitor) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateMonitor) SyncEffectiveFieldsDuringRead(existingState UpdateMonitor) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateMonitor. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_metrics": reflect.TypeOf(MonitorMetric{}), @@ -8010,6 +9988,8 @@ func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of UpdateMonitor in the Terraform plugin framework type +// system. func (a UpdateMonitor) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8060,12 +10040,21 @@ func (newState *UpdatePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdatePermissions) SyncEffectiveFieldsDuringRead(existingState UpdatePermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "changes": reflect.TypeOf(PermissionsChange{}), } } +// ToAttrType returns the representation of UpdatePermissions in the Terraform plugin framework type +// system. func (a UpdatePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8095,10 +10084,19 @@ func (newState *UpdateRegisteredModelRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *UpdateRegisteredModelRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRegisteredModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRegisteredModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateRegisteredModelRequest in the Terraform plugin framework type +// system. func (a UpdateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8119,10 +10117,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -8151,12 +10158,21 @@ func (newState *UpdateSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Updat func (newState *UpdateSchema) SyncEffectiveFieldsDuringRead(existingState UpdateSchema) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateSchema. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpdateSchema in the Terraform plugin framework type +// system. func (a UpdateSchema) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8209,6 +10225,13 @@ func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateStorageCredential) SyncEffectiveFieldsDuringRead(existingState UpdateStorageCredential) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateStorageCredential. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), @@ -8219,6 +10242,8 @@ func (a UpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of UpdateStorageCredential in the Terraform plugin framework type +// system. func (a UpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8263,10 +10288,19 @@ func (newState *UpdateTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateTableRequest) SyncEffectiveFieldsDuringRead(existingState UpdateTableRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateTableRequest in the Terraform plugin framework type +// system. func (a UpdateTableRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8293,10 +10327,19 @@ func (newState *UpdateVolumeRequestContent) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateVolumeRequestContent) SyncEffectiveFieldsDuringRead(existingState UpdateVolumeRequestContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateVolumeRequestContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateVolumeRequestContent in the Terraform plugin framework type +// system. func (a UpdateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8323,6 +10366,13 @@ func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateWorkspaceBindings) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceBindings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateWorkspaceBindings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assign_workspaces": reflect.TypeOf(types.Int64{}), @@ -8330,6 +10380,8 @@ func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of UpdateWorkspaceBindings in the Terraform plugin framework type +// system. func (a UpdateWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8361,6 +10413,13 @@ func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringCrea func (newState *UpdateWorkspaceBindingsParameters) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceBindingsParameters) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateWorkspaceBindingsParameters. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add": reflect.TypeOf(WorkspaceBinding{}), @@ -8368,6 +10427,8 @@ func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes(ctx context.Cont } } +// ToAttrType returns the representation of UpdateWorkspaceBindingsParameters in the Terraform plugin framework type +// system. func (a UpdateWorkspaceBindingsParameters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8411,6 +10472,13 @@ func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ValidateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState ValidateCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ValidateCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ValidateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRole{}), @@ -8418,6 +10486,8 @@ func (a ValidateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of ValidateCredentialRequest in the Terraform plugin framework type +// system. func (a ValidateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8450,12 +10520,21 @@ func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ValidateCredentialResponse) SyncEffectiveFieldsDuringRead(existingState ValidateCredentialResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ValidateCredentialResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ValidateCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(CredentialValidationResult{}), } } +// ToAttrType returns the representation of ValidateCredentialResponse in the Terraform plugin framework type +// system. func (a ValidateCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8494,6 +10573,13 @@ func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ValidateStorageCredential) SyncEffectiveFieldsDuringRead(existingState ValidateStorageCredential) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ValidateStorageCredential. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ValidateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleRequest{}), @@ -8504,6 +10590,8 @@ func (a ValidateStorageCredential) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of ValidateStorageCredential in the Terraform plugin framework type +// system. func (a ValidateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8543,12 +10631,21 @@ func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringCrea func (newState *ValidateStorageCredentialResponse) SyncEffectiveFieldsDuringRead(existingState ValidateStorageCredentialResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ValidateStorageCredentialResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ValidateStorageCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ValidationResult{}), } } +// ToAttrType returns the representation of ValidateStorageCredentialResponse in the Terraform plugin framework type +// system. func (a ValidateStorageCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8575,10 +10672,19 @@ func (newState *ValidationResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan V func (newState *ValidationResult) SyncEffectiveFieldsDuringRead(existingState ValidationResult) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ValidationResult. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ValidationResult in the Terraform plugin framework type +// system. func (a ValidationResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8634,12 +10740,21 @@ func (newState *VolumeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan VolumeI func (newState *VolumeInfo) SyncEffectiveFieldsDuringRead(existingState VolumeInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in VolumeInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a VolumeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "encryption_details": reflect.TypeOf(EncryptionDetails{}), } } +// ToAttrType returns the representation of VolumeInfo in the Terraform plugin framework type +// system. func (a VolumeInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8678,10 +10793,19 @@ func (newState *WorkspaceBinding) SyncEffectiveFieldsDuringCreateOrUpdate(plan W func (newState *WorkspaceBinding) SyncEffectiveFieldsDuringRead(existingState WorkspaceBinding) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceBinding. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceBinding) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WorkspaceBinding in the Terraform plugin framework type +// system. func (a WorkspaceBinding) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -8707,12 +10831,21 @@ func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *WorkspaceBindingsResponse) SyncEffectiveFieldsDuringRead(existingState WorkspaceBindingsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceBindingsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceBindingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "bindings": reflect.TypeOf(WorkspaceBinding{}), } } +// ToAttrType returns the representation of WorkspaceBindingsResponse in the Terraform plugin framework type +// system. func (a WorkspaceBindingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index f5ef0d6657..3e2d1d0582 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -54,10 +54,19 @@ func (newState *AddInstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AddInstanceProfile) SyncEffectiveFieldsDuringRead(existingState AddInstanceProfile) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AddInstanceProfile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AddInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AddInstanceProfile in the Terraform plugin framework type +// system. func (a AddInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -78,10 +87,19 @@ func (newState *AddResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddRes func (newState *AddResponse) SyncEffectiveFieldsDuringRead(existingState AddResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AddResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AddResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AddResponse in the Terraform plugin framework type +// system. func (a AddResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -100,10 +118,19 @@ func (newState *Adlsgen2Info) SyncEffectiveFieldsDuringCreateOrUpdate(plan Adlsg func (newState *Adlsgen2Info) SyncEffectiveFieldsDuringRead(existingState Adlsgen2Info) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Adlsgen2Info. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Adlsgen2Info) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Adlsgen2Info in the Terraform plugin framework type +// system. func (a Adlsgen2Info) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -129,10 +156,19 @@ func (newState *AutoScale) SyncEffectiveFieldsDuringCreateOrUpdate(plan AutoScal func (newState *AutoScale) SyncEffectiveFieldsDuringRead(existingState AutoScale) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AutoScale. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AutoScale) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AutoScale in the Terraform plugin framework type +// system. func (a AutoScale) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -234,10 +270,19 @@ func (newState *AwsAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsA func (newState *AwsAttributes) SyncEffectiveFieldsDuringRead(existingState AwsAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AwsAttributes in the Terraform plugin framework type +// system. func (a AwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -287,12 +332,21 @@ func (newState *AzureAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan Az func (newState *AzureAttributes) SyncEffectiveFieldsDuringRead(existingState AzureAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "log_analytics_info": reflect.TypeOf(LogAnalyticsInfo{}), } } +// ToAttrType returns the representation of AzureAttributes in the Terraform plugin framework type +// system. func (a AzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -320,10 +374,19 @@ func (newState *CancelCommand) SyncEffectiveFieldsDuringCreateOrUpdate(plan Canc func (newState *CancelCommand) SyncEffectiveFieldsDuringRead(existingState CancelCommand) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelCommand. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelCommand) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelCommand in the Terraform plugin framework type +// system. func (a CancelCommand) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -343,10 +406,19 @@ func (newState *CancelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Can func (newState *CancelResponse) SyncEffectiveFieldsDuringRead(existingState CancelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelResponse in the Terraform plugin framework type +// system. func (a CancelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -366,10 +438,19 @@ func (newState *ChangeClusterOwner) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ChangeClusterOwner) SyncEffectiveFieldsDuringRead(existingState ChangeClusterOwner) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ChangeClusterOwner. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ChangeClusterOwner) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ChangeClusterOwner in the Terraform plugin framework type +// system. func (a ChangeClusterOwner) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -388,10 +469,19 @@ func (newState *ChangeClusterOwnerResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ChangeClusterOwnerResponse) SyncEffectiveFieldsDuringRead(existingState ChangeClusterOwnerResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ChangeClusterOwnerResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ChangeClusterOwnerResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ChangeClusterOwnerResponse in the Terraform plugin framework type +// system. func (a ChangeClusterOwnerResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -411,10 +501,19 @@ func (newState *ClientsTypes) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clien func (newState *ClientsTypes) SyncEffectiveFieldsDuringRead(existingState ClientsTypes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClientsTypes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClientsTypes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClientsTypes in the Terraform plugin framework type +// system. func (a ClientsTypes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -435,10 +534,19 @@ func (newState *CloneCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clone func (newState *CloneCluster) SyncEffectiveFieldsDuringRead(existingState CloneCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CloneCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CloneCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CloneCluster in the Terraform plugin framework type +// system. func (a CloneCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -457,12 +565,21 @@ func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CloudProviderNodeInfo) SyncEffectiveFieldsDuringRead(existingState CloudProviderNodeInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CloudProviderNodeInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CloudProviderNodeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "status": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of CloudProviderNodeInfo in the Terraform plugin framework type +// system. func (a CloudProviderNodeInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -490,10 +607,19 @@ func (newState *ClusterAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ClusterAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ClusterAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterAccessControlRequest in the Terraform plugin framework type +// system. func (a ClusterAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -524,12 +650,21 @@ func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ClusterAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ClusterAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ClusterPermission{}), } } +// ToAttrType returns the representation of ClusterAccessControlResponse in the Terraform plugin framework type +// system. func (a ClusterAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -683,6 +818,13 @@ func (newState *ClusterAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterAttributes) SyncEffectiveFieldsDuringRead(existingState ClusterAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(AwsAttributes{}), @@ -699,6 +841,8 @@ func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of ClusterAttributes in the Terraform plugin framework type +// system. func (a ClusterAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -771,12 +915,21 @@ func (newState *ClusterCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterCompliance) SyncEffectiveFieldsDuringRead(existingState ClusterCompliance) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterCompliance. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterCompliance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ClusterCompliance in the Terraform plugin framework type +// system. func (a ClusterCompliance) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1011,6 +1164,13 @@ func (newState *ClusterDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clu func (newState *ClusterDetails) SyncEffectiveFieldsDuringRead(existingState ClusterDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), @@ -1034,6 +1194,8 @@ func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of ClusterDetails in the Terraform plugin framework type +// system. func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1143,6 +1305,13 @@ func (newState *ClusterEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clust func (newState *ClusterEvent) SyncEffectiveFieldsDuringRead(existingState ClusterEvent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterEvent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterEvent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_plane_event_details": reflect.TypeOf(DataPlaneEventDetails{}), @@ -1150,6 +1319,8 @@ func (a ClusterEvent) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of ClusterEvent in the Terraform plugin framework type +// system. func (a ClusterEvent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1179,12 +1350,21 @@ func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ClusterLibraryStatuses) SyncEffectiveFieldsDuringRead(existingState ClusterLibraryStatuses) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterLibraryStatuses. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterLibraryStatuses) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library_statuses": reflect.TypeOf(LibraryFullStatus{}), } } +// ToAttrType returns the representation of ClusterLibraryStatuses in the Terraform plugin framework type +// system. func (a ClusterLibraryStatuses) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1214,6 +1394,13 @@ func (newState *ClusterLogConf) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clu func (newState *ClusterLogConf) SyncEffectiveFieldsDuringRead(existingState ClusterLogConf) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterLogConf. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterLogConf) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbfs": reflect.TypeOf(DbfsStorageInfo{}), @@ -1221,6 +1408,8 @@ func (a ClusterLogConf) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of ClusterLogConf in the Terraform plugin framework type +// system. func (a ClusterLogConf) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1248,12 +1437,21 @@ func (newState *ClusterPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterPermission) SyncEffectiveFieldsDuringRead(existingState ClusterPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ClusterPermission in the Terraform plugin framework type +// system. func (a ClusterPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1280,12 +1478,21 @@ func (newState *ClusterPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ClusterPermissions) SyncEffectiveFieldsDuringRead(existingState ClusterPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterAccessControlResponse{}), } } +// ToAttrType returns the representation of ClusterPermissions in the Terraform plugin framework type +// system. func (a ClusterPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1310,10 +1517,19 @@ func (newState *ClusterPermissionsDescription) SyncEffectiveFieldsDuringCreateOr func (newState *ClusterPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ClusterPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterPermissionsDescription in the Terraform plugin framework type +// system. func (a ClusterPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1335,12 +1551,21 @@ func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterAccessControlRequest{}), } } +// ToAttrType returns the representation of ClusterPermissionsRequest in the Terraform plugin framework type +// system. func (a ClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1369,10 +1594,19 @@ func (newState *ClusterPolicyAccessControlRequest) SyncEffectiveFieldsDuringCrea func (newState *ClusterPolicyAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPolicyAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterPolicyAccessControlRequest in the Terraform plugin framework type +// system. func (a ClusterPolicyAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1403,12 +1637,21 @@ func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringCre func (newState *ClusterPolicyAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPolicyAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ClusterPolicyPermission{}), } } +// ToAttrType returns the representation of ClusterPolicyAccessControlResponse in the Terraform plugin framework type +// system. func (a ClusterPolicyAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1437,12 +1680,21 @@ func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ClusterPolicyPermission) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPolicyPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPolicyPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ClusterPolicyPermission in the Terraform plugin framework type +// system. func (a ClusterPolicyPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1469,12 +1721,21 @@ func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ClusterPolicyPermissions) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPolicyPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPolicyPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterPolicyAccessControlResponse{}), } } +// ToAttrType returns the representation of ClusterPolicyPermissions in the Terraform plugin framework type +// system. func (a ClusterPolicyPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1499,10 +1760,19 @@ func (newState *ClusterPolicyPermissionsDescription) SyncEffectiveFieldsDuringCr func (newState *ClusterPolicyPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPolicyPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterPolicyPermissionsDescription in the Terraform plugin framework type +// system. func (a ClusterPolicyPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1524,12 +1794,21 @@ func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringCreate func (newState *ClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ClusterPolicyPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterPolicyPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ClusterPolicyAccessControlRequest{}), } } +// ToAttrType returns the representation of ClusterPolicyPermissionsRequest in the Terraform plugin framework type +// system. func (a ClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1564,10 +1843,19 @@ func (newState *ClusterSettingsChange) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ClusterSettingsChange) SyncEffectiveFieldsDuringRead(existingState ClusterSettingsChange) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterSettingsChange. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterSettingsChange in the Terraform plugin framework type +// system. func (a ClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1602,12 +1890,21 @@ func (newState *ClusterSize) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSize) SyncEffectiveFieldsDuringRead(existingState ClusterSize) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterSize. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterSize) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), } } +// ToAttrType returns the representation of ClusterSize in the Terraform plugin framework type +// system. func (a ClusterSize) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1777,6 +2074,13 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState ClusterSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), @@ -1794,6 +2098,8 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of ClusterSpec in the Terraform plugin framework type +// system. func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1864,10 +2170,19 @@ func (newState *ClusterStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clus func (newState *ClusterStatus) SyncEffectiveFieldsDuringRead(existingState ClusterStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterStatus in the Terraform plugin framework type +// system. func (a ClusterStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1893,10 +2208,19 @@ func (newState *Command) SyncEffectiveFieldsDuringCreateOrUpdate(plan Command) { func (newState *Command) SyncEffectiveFieldsDuringRead(existingState Command) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Command. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Command) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Command in the Terraform plugin framework type +// system. func (a Command) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1923,10 +2247,19 @@ func (newState *CommandStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CommandStatusRequest) SyncEffectiveFieldsDuringRead(existingState CommandStatusRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CommandStatusRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CommandStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CommandStatusRequest in the Terraform plugin framework type +// system. func (a CommandStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1951,12 +2284,21 @@ func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CommandStatusResponse) SyncEffectiveFieldsDuringRead(existingState CommandStatusResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CommandStatusResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CommandStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(Results{}), } } +// ToAttrType returns the representation of CommandStatusResponse in the Terraform plugin framework type +// system. func (a CommandStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1982,10 +2324,19 @@ func (newState *ContextStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ContextStatusRequest) SyncEffectiveFieldsDuringRead(existingState ContextStatusRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ContextStatusRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ContextStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ContextStatusRequest in the Terraform plugin framework type +// system. func (a ContextStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2007,10 +2358,19 @@ func (newState *ContextStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ContextStatusResponse) SyncEffectiveFieldsDuringRead(existingState ContextStatusResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ContextStatusResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ContextStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ContextStatusResponse in the Terraform plugin framework type +// system. func (a ContextStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2181,6 +2541,13 @@ func (newState *CreateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateCluster) SyncEffectiveFieldsDuringRead(existingState CreateCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), @@ -2199,6 +2566,8 @@ func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of CreateCluster in the Terraform plugin framework type +// system. func (a CreateCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2270,10 +2639,19 @@ func (newState *CreateClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateClusterResponse) SyncEffectiveFieldsDuringRead(existingState CreateClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateClusterResponse in the Terraform plugin framework type +// system. func (a CreateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2295,10 +2673,19 @@ func (newState *CreateContext) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateContext) SyncEffectiveFieldsDuringRead(existingState CreateContext) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateContext. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateContext) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateContext in the Terraform plugin framework type +// system. func (a CreateContext) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2371,6 +2758,13 @@ func (newState *CreateInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateInstancePool) SyncEffectiveFieldsDuringRead(existingState CreateInstancePool) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateInstancePool. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), @@ -2383,6 +2777,8 @@ func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of CreateInstancePool in the Terraform plugin framework type +// system. func (a CreateInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2428,10 +2824,19 @@ func (newState *CreateInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState CreateInstancePoolResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateInstancePoolResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateInstancePoolResponse in the Terraform plugin framework type +// system. func (a CreateInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2482,12 +2887,21 @@ func (newState *CreatePolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreatePolicy) SyncEffectiveFieldsDuringRead(existingState CreatePolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } } +// ToAttrType returns the representation of CreatePolicy in the Terraform plugin framework type +// system. func (a CreatePolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2515,10 +2929,19 @@ func (newState *CreatePolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreatePolicyResponse) SyncEffectiveFieldsDuringRead(existingState CreatePolicyResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePolicyResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreatePolicyResponse in the Terraform plugin framework type +// system. func (a CreatePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2538,10 +2961,19 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// system. func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2560,10 +2992,19 @@ func (newState *Created) SyncEffectiveFieldsDuringCreateOrUpdate(plan Created) { func (newState *Created) SyncEffectiveFieldsDuringRead(existingState Created) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Created. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Created) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Created in the Terraform plugin framework type +// system. func (a Created) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2589,10 +3030,19 @@ func (newState *DataPlaneEventDetails) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DataPlaneEventDetails) SyncEffectiveFieldsDuringRead(existingState DataPlaneEventDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DataPlaneEventDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DataPlaneEventDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DataPlaneEventDetails in the Terraform plugin framework type +// system. func (a DataPlaneEventDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2615,10 +3065,19 @@ func (newState *DbfsStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Db func (newState *DbfsStorageInfo) SyncEffectiveFieldsDuringRead(existingState DbfsStorageInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DbfsStorageInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DbfsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DbfsStorageInfo in the Terraform plugin framework type +// system. func (a DbfsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2638,10 +3097,19 @@ func (newState *DeleteCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dele func (newState *DeleteCluster) SyncEffectiveFieldsDuringRead(existingState DeleteCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCluster in the Terraform plugin framework type +// system. func (a DeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2659,10 +3127,19 @@ func (newState *DeleteClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteClusterResponse) SyncEffectiveFieldsDuringRead(existingState DeleteClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteClusterResponse in the Terraform plugin framework type +// system. func (a DeleteClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2681,10 +3158,19 @@ func (newState *DeleteGlobalInitScriptRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteGlobalInitScriptRequest) SyncEffectiveFieldsDuringRead(existingState DeleteGlobalInitScriptRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteGlobalInitScriptRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteGlobalInitScriptRequest in the Terraform plugin framework type +// system. func (a DeleteGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2704,10 +3190,19 @@ func (newState *DeleteInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteInstancePool) SyncEffectiveFieldsDuringRead(existingState DeleteInstancePool) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteInstancePool. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteInstancePool in the Terraform plugin framework type +// system. func (a DeleteInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2725,10 +3220,19 @@ func (newState *DeleteInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState DeleteInstancePoolResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteInstancePoolResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteInstancePoolResponse in the Terraform plugin framework type +// system. func (a DeleteInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2746,10 +3250,19 @@ func (newState *DeletePolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delet func (newState *DeletePolicy) SyncEffectiveFieldsDuringRead(existingState DeletePolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePolicy in the Terraform plugin framework type +// system. func (a DeletePolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2767,10 +3280,19 @@ func (newState *DeletePolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeletePolicyResponse) SyncEffectiveFieldsDuringRead(existingState DeletePolicyResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePolicyResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePolicyResponse in the Terraform plugin framework type +// system. func (a DeletePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2786,10 +3308,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2808,10 +3339,19 @@ func (newState *DestroyContext) SyncEffectiveFieldsDuringCreateOrUpdate(plan Des func (newState *DestroyContext) SyncEffectiveFieldsDuringRead(existingState DestroyContext) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DestroyContext. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DestroyContext) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DestroyContext in the Terraform plugin framework type +// system. func (a DestroyContext) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2830,10 +3370,19 @@ func (newState *DestroyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan De func (newState *DestroyResponse) SyncEffectiveFieldsDuringRead(existingState DestroyResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DestroyResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DestroyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DestroyResponse in the Terraform plugin framework type +// system. func (a DestroyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2881,12 +3430,21 @@ func (newState *DiskSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskSpec) func (newState *DiskSpec) SyncEffectiveFieldsDuringRead(existingState DiskSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DiskSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DiskSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disk_type": reflect.TypeOf(DiskType{}), } } +// ToAttrType returns the representation of DiskSpec in the Terraform plugin framework type +// system. func (a DiskSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2913,10 +3471,19 @@ func (newState *DiskType) SyncEffectiveFieldsDuringCreateOrUpdate(plan DiskType) func (newState *DiskType) SyncEffectiveFieldsDuringRead(existingState DiskType) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DiskType. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DiskType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DiskType in the Terraform plugin framework type +// system. func (a DiskType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2939,10 +3506,19 @@ func (newState *DockerBasicAuth) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DockerBasicAuth) SyncEffectiveFieldsDuringRead(existingState DockerBasicAuth) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DockerBasicAuth. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DockerBasicAuth) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DockerBasicAuth in the Terraform plugin framework type +// system. func (a DockerBasicAuth) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2964,12 +3540,21 @@ func (newState *DockerImage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Docker func (newState *DockerImage) SyncEffectiveFieldsDuringRead(existingState DockerImage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DockerImage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DockerImage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "basic_auth": reflect.TypeOf(DockerBasicAuth{}), } } +// ToAttrType returns the representation of DockerImage in the Terraform plugin framework type +// system. func (a DockerImage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3141,6 +3726,13 @@ func (newState *EditCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditCl func (newState *EditCluster) SyncEffectiveFieldsDuringRead(existingState EditCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), @@ -3158,6 +3750,8 @@ func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of EditCluster in the Terraform plugin framework type +// system. func (a EditCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3226,10 +3820,19 @@ func (newState *EditClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *EditClusterResponse) SyncEffectiveFieldsDuringRead(existingState EditClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EditClusterResponse in the Terraform plugin framework type +// system. func (a EditClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3276,12 +3879,21 @@ func (newState *EditInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *EditInstancePool) SyncEffectiveFieldsDuringRead(existingState EditInstancePool) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditInstancePool. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_tags": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of EditInstancePool in the Terraform plugin framework type +// system. func (a EditInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3307,10 +3919,19 @@ func (newState *EditInstancePoolResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EditInstancePoolResponse) SyncEffectiveFieldsDuringRead(existingState EditInstancePoolResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditInstancePoolResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EditInstancePoolResponse in the Terraform plugin framework type +// system. func (a EditInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3361,12 +3982,21 @@ func (newState *EditPolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditPol func (newState *EditPolicy) SyncEffectiveFieldsDuringRead(existingState EditPolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditPolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } } +// ToAttrType returns the representation of EditPolicy in the Terraform plugin framework type +// system. func (a EditPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3393,10 +4023,19 @@ func (newState *EditPolicyResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *EditPolicyResponse) SyncEffectiveFieldsDuringRead(existingState EditPolicyResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditPolicyResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EditPolicyResponse in the Terraform plugin framework type +// system. func (a EditPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3412,10 +4051,19 @@ func (newState *EditResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditR func (newState *EditResponse) SyncEffectiveFieldsDuringRead(existingState EditResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EditResponse in the Terraform plugin framework type +// system. func (a EditResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3436,10 +4084,19 @@ func (newState *EnforceClusterComplianceRequest) SyncEffectiveFieldsDuringCreate func (newState *EnforceClusterComplianceRequest) SyncEffectiveFieldsDuringRead(existingState EnforceClusterComplianceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnforceClusterComplianceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnforceClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EnforceClusterComplianceRequest in the Terraform plugin framework type +// system. func (a EnforceClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3464,12 +4121,21 @@ func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringCreat func (newState *EnforceClusterComplianceResponse) SyncEffectiveFieldsDuringRead(existingState EnforceClusterComplianceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnforceClusterComplianceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnforceClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "changes": reflect.TypeOf(ClusterSettingsChange{}), } } +// ToAttrType returns the representation of EnforceClusterComplianceResponse in the Terraform plugin framework type +// system. func (a EnforceClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3505,12 +4171,21 @@ func (newState *Environment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Enviro func (newState *Environment) SyncEffectiveFieldsDuringRead(existingState Environment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Environment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Environment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dependencies": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of Environment in the Terraform plugin framework type +// system. func (a Environment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3579,6 +4254,13 @@ func (newState *EventDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Event func (newState *EventDetails) SyncEffectiveFieldsDuringRead(existingState EventDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EventDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EventDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "attributes": reflect.TypeOf(ClusterAttributes{}), @@ -3590,6 +4272,8 @@ func (a EventDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of EventDetails in the Terraform plugin framework type +// system. func (a EventDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3669,10 +4353,19 @@ func (newState *GcpAttributes) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpA func (newState *GcpAttributes) SyncEffectiveFieldsDuringRead(existingState GcpAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpAttributes in the Terraform plugin framework type +// system. func (a GcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3697,10 +4390,19 @@ func (newState *GcsStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Gcs func (newState *GcsStorageInfo) SyncEffectiveFieldsDuringRead(existingState GcsStorageInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcsStorageInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcsStorageInfo in the Terraform plugin framework type +// system. func (a GcsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3721,10 +4423,19 @@ func (newState *GetClusterComplianceRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetClusterComplianceRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterComplianceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterComplianceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterComplianceRequest in the Terraform plugin framework type +// system. func (a GetClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3751,12 +4462,21 @@ func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetClusterComplianceResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterComplianceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterComplianceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of GetClusterComplianceResponse in the Terraform plugin framework type +// system. func (a GetClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3780,10 +4500,19 @@ func (newState *GetClusterPermissionLevelsRequest) SyncEffectiveFieldsDuringCrea func (newState *GetClusterPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetClusterPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3803,12 +4532,21 @@ func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringCre func (newState *GetClusterPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ClusterPermissionsDescription{}), } } +// ToAttrType returns the representation of GetClusterPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetClusterPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3831,10 +4569,19 @@ func (newState *GetClusterPermissionsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *GetClusterPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterPermissionsRequest in the Terraform plugin framework type +// system. func (a GetClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3855,10 +4602,19 @@ func (newState *GetClusterPolicyPermissionLevelsRequest) SyncEffectiveFieldsDuri func (newState *GetClusterPolicyPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPolicyPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterPolicyPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetClusterPolicyPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3878,12 +4634,21 @@ func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDur func (newState *GetClusterPolicyPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPolicyPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ClusterPolicyPermissionsDescription{}), } } +// ToAttrType returns the representation of GetClusterPolicyPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetClusterPolicyPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3906,10 +4671,19 @@ func (newState *GetClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringCre func (newState *GetClusterPolicyPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPolicyPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterPolicyPermissionsRequest in the Terraform plugin framework type +// system. func (a GetClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3930,10 +4704,19 @@ func (newState *GetClusterPolicyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetClusterPolicyRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterPolicyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterPolicyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterPolicyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterPolicyRequest in the Terraform plugin framework type +// system. func (a GetClusterPolicyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3954,10 +4737,19 @@ func (newState *GetClusterRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetClusterRequest) SyncEffectiveFieldsDuringRead(existingState GetClusterRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetClusterRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetClusterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetClusterRequest in the Terraform plugin framework type +// system. func (a GetClusterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3995,12 +4787,21 @@ func (newState *GetEvents) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetEvent func (newState *GetEvents) SyncEffectiveFieldsDuringRead(existingState GetEvents) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEvents. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEvents) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "event_types": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of GetEvents in the Terraform plugin framework type +// system. func (a GetEvents) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4034,6 +4835,13 @@ func (newState *GetEventsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetEventsResponse) SyncEffectiveFieldsDuringRead(existingState GetEventsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEventsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(ClusterEvent{}), @@ -4041,6 +4849,8 @@ func (a GetEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of GetEventsResponse in the Terraform plugin framework type +// system. func (a GetEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4067,10 +4877,19 @@ func (newState *GetGlobalInitScriptRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetGlobalInitScriptRequest) SyncEffectiveFieldsDuringRead(existingState GetGlobalInitScriptRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetGlobalInitScriptRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetGlobalInitScriptRequest in the Terraform plugin framework type +// system. func (a GetGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4161,6 +4980,13 @@ func (newState *GetInstancePool) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetInstancePool) SyncEffectiveFieldsDuringRead(existingState GetInstancePool) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetInstancePool. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), @@ -4176,6 +5002,8 @@ func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of GetInstancePool in the Terraform plugin framework type +// system. func (a GetInstancePool) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4233,10 +5061,19 @@ func (newState *GetInstancePoolPermissionLevelsRequest) SyncEffectiveFieldsDurin func (newState *GetInstancePoolPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetInstancePoolPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetInstancePoolPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetInstancePoolPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4256,12 +5093,21 @@ func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuri func (newState *GetInstancePoolPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetInstancePoolPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(InstancePoolPermissionsDescription{}), } } +// ToAttrType returns the representation of GetInstancePoolPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetInstancePoolPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4284,10 +5130,19 @@ func (newState *GetInstancePoolPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *GetInstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetInstancePoolPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetInstancePoolPermissionsRequest in the Terraform plugin framework type +// system. func (a GetInstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4308,10 +5163,19 @@ func (newState *GetInstancePoolRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetInstancePoolRequest) SyncEffectiveFieldsDuringRead(existingState GetInstancePoolRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetInstancePoolRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetInstancePoolRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetInstancePoolRequest in the Terraform plugin framework type +// system. func (a GetInstancePoolRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4335,10 +5199,19 @@ func (newState *GetPolicyFamilyRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPolicyFamilyRequest) SyncEffectiveFieldsDuringRead(existingState GetPolicyFamilyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPolicyFamilyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPolicyFamilyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPolicyFamilyRequest in the Terraform plugin framework type +// system. func (a GetPolicyFamilyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4359,12 +5232,21 @@ func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetSparkVersionsResponse) SyncEffectiveFieldsDuringRead(existingState GetSparkVersionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSparkVersionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetSparkVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "versions": reflect.TypeOf(SparkVersion{}), } } +// ToAttrType returns the representation of GetSparkVersionsResponse in the Terraform plugin framework type +// system. func (a GetSparkVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4402,10 +5284,19 @@ func (newState *GlobalInitScriptCreateRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GlobalInitScriptCreateRequest) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptCreateRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GlobalInitScriptCreateRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GlobalInitScriptCreateRequest in the Terraform plugin framework type +// system. func (a GlobalInitScriptCreateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4445,10 +5336,19 @@ func (newState *GlobalInitScriptDetails) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GlobalInitScriptDetails) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GlobalInitScriptDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GlobalInitScriptDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GlobalInitScriptDetails in the Terraform plugin framework type +// system. func (a GlobalInitScriptDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4494,10 +5394,19 @@ func (newState *GlobalInitScriptDetailsWithContent) SyncEffectiveFieldsDuringCre func (newState *GlobalInitScriptDetailsWithContent) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptDetailsWithContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GlobalInitScriptDetailsWithContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GlobalInitScriptDetailsWithContent in the Terraform plugin framework type +// system. func (a GlobalInitScriptDetailsWithContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4544,10 +5453,19 @@ func (newState *GlobalInitScriptUpdateRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GlobalInitScriptUpdateRequest) SyncEffectiveFieldsDuringRead(existingState GlobalInitScriptUpdateRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GlobalInitScriptUpdateRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GlobalInitScriptUpdateRequest in the Terraform plugin framework type +// system. func (a GlobalInitScriptUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4575,6 +5493,13 @@ func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *InitScriptEventDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptEventDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InitScriptEventDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InitScriptEventDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster": reflect.TypeOf(InitScriptInfoAndExecutionDetails{}), @@ -4582,6 +5507,8 @@ func (a InitScriptEventDetails) GetComplexFieldTypes(ctx context.Context) map[st } } +// ToAttrType returns the representation of InitScriptEventDetails in the Terraform plugin framework type +// system. func (a InitScriptEventDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4611,10 +5538,19 @@ func (newState *InitScriptExecutionDetails) SyncEffectiveFieldsDuringCreateOrUpd func (newState *InitScriptExecutionDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptExecutionDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InitScriptExecutionDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InitScriptExecutionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InitScriptExecutionDetails in the Terraform plugin framework type +// system. func (a InitScriptExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4659,6 +5595,13 @@ func (newState *InitScriptInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ini func (newState *InitScriptInfo) SyncEffectiveFieldsDuringRead(existingState InitScriptInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InitScriptInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InitScriptInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "abfss": reflect.TypeOf(Adlsgen2Info{}), @@ -4671,6 +5614,8 @@ func (a InitScriptInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of InitScriptInfo in the Terraform plugin framework type +// system. func (a InitScriptInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4712,6 +5657,13 @@ func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringCrea func (newState *InitScriptInfoAndExecutionDetails) SyncEffectiveFieldsDuringRead(existingState InitScriptInfoAndExecutionDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InitScriptInfoAndExecutionDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "execution_details": reflect.TypeOf(InitScriptExecutionDetails{}), @@ -4719,6 +5671,8 @@ func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes(ctx context.Cont } } +// ToAttrType returns the representation of InitScriptInfoAndExecutionDetails in the Terraform plugin framework type +// system. func (a InitScriptInfoAndExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4745,12 +5699,21 @@ func (newState *InstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan I func (newState *InstallLibraries) SyncEffectiveFieldsDuringRead(existingState InstallLibraries) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstallLibraries. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } } +// ToAttrType returns the representation of InstallLibraries in the Terraform plugin framework type +// system. func (a InstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4771,10 +5734,19 @@ func (newState *InstallLibrariesResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *InstallLibrariesResponse) SyncEffectiveFieldsDuringRead(existingState InstallLibrariesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstallLibrariesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstallLibrariesResponse in the Terraform plugin framework type +// system. func (a InstallLibrariesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4798,10 +5770,19 @@ func (newState *InstancePoolAccessControlRequest) SyncEffectiveFieldsDuringCreat func (newState *InstancePoolAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState InstancePoolAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstancePoolAccessControlRequest in the Terraform plugin framework type +// system. func (a InstancePoolAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4832,12 +5813,21 @@ func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringCrea func (newState *InstancePoolAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState InstancePoolAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(InstancePoolPermission{}), } } +// ToAttrType returns the representation of InstancePoolAccessControlResponse in the Terraform plugin framework type +// system. func (a InstancePoolAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4934,6 +5924,13 @@ func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *InstancePoolAndStats) SyncEffectiveFieldsDuringRead(existingState InstancePoolAndStats) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolAndStats. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_attributes": reflect.TypeOf(InstancePoolAwsAttributes{}), @@ -4949,6 +5946,8 @@ func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of InstancePoolAndStats in the Terraform plugin framework type +// system. func (a InstancePoolAndStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5032,10 +6031,19 @@ func (newState *InstancePoolAwsAttributes) SyncEffectiveFieldsDuringCreateOrUpda func (newState *InstancePoolAwsAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolAwsAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolAwsAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstancePoolAwsAttributes in the Terraform plugin framework type +// system. func (a InstancePoolAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5063,10 +6071,19 @@ func (newState *InstancePoolAzureAttributes) SyncEffectiveFieldsDuringCreateOrUp func (newState *InstancePoolAzureAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolAzureAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolAzureAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolAzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstancePoolAzureAttributes in the Terraform plugin framework type +// system. func (a InstancePoolAzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5113,10 +6130,19 @@ func (newState *InstancePoolGcpAttributes) SyncEffectiveFieldsDuringCreateOrUpda func (newState *InstancePoolGcpAttributes) SyncEffectiveFieldsDuringRead(existingState InstancePoolGcpAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolGcpAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolGcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstancePoolGcpAttributes in the Terraform plugin framework type +// system. func (a InstancePoolGcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5141,12 +6167,21 @@ func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *InstancePoolPermission) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of InstancePoolPermission in the Terraform plugin framework type +// system. func (a InstancePoolPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5173,12 +6208,21 @@ func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *InstancePoolPermissions) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(InstancePoolAccessControlResponse{}), } } +// ToAttrType returns the representation of InstancePoolPermissions in the Terraform plugin framework type +// system. func (a InstancePoolPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5203,10 +6247,19 @@ func (newState *InstancePoolPermissionsDescription) SyncEffectiveFieldsDuringCre func (newState *InstancePoolPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstancePoolPermissionsDescription in the Terraform plugin framework type +// system. func (a InstancePoolPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5228,12 +6281,21 @@ func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringCreateO func (newState *InstancePoolPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState InstancePoolPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(InstancePoolAccessControlRequest{}), } } +// ToAttrType returns the representation of InstancePoolPermissionsRequest in the Terraform plugin framework type +// system. func (a InstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5262,10 +6324,19 @@ func (newState *InstancePoolStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstancePoolStats) SyncEffectiveFieldsDuringRead(existingState InstancePoolStats) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolStats. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstancePoolStats in the Terraform plugin framework type +// system. func (a InstancePoolStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5291,12 +6362,21 @@ func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstancePoolStatus) SyncEffectiveFieldsDuringRead(existingState InstancePoolStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstancePoolStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstancePoolStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "pending_instance_errors": reflect.TypeOf(PendingInstanceError{}), } } +// ToAttrType returns the representation of InstancePoolStatus in the Terraform plugin framework type +// system. func (a InstancePoolStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5334,10 +6414,19 @@ func (newState *InstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan In func (newState *InstanceProfile) SyncEffectiveFieldsDuringRead(existingState InstanceProfile) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstanceProfile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InstanceProfile in the Terraform plugin framework type +// system. func (a InstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5390,6 +6479,13 @@ func (newState *Library) SyncEffectiveFieldsDuringCreateOrUpdate(plan Library) { func (newState *Library) SyncEffectiveFieldsDuringRead(existingState Library) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Library. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Library) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cran": reflect.TypeOf(RCranLibrary{}), @@ -5398,6 +6494,8 @@ func (a Library) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of Library in the Terraform plugin framework type +// system. func (a Library) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5438,6 +6536,13 @@ func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LibraryFullStatus) SyncEffectiveFieldsDuringRead(existingState LibraryFullStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LibraryFullStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library": reflect.TypeOf(Library{}), @@ -5445,6 +6550,8 @@ func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of LibraryFullStatus in the Terraform plugin framework type +// system. func (a LibraryFullStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5471,12 +6578,21 @@ func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuring func (newState *ListAllClusterLibraryStatusesResponse) SyncEffectiveFieldsDuringRead(existingState ListAllClusterLibraryStatusesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAllClusterLibraryStatusesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "statuses": reflect.TypeOf(ClusterLibraryStatuses{}), } } +// ToAttrType returns the representation of ListAllClusterLibraryStatusesResponse in the Terraform plugin framework type +// system. func (a ListAllClusterLibraryStatusesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5501,12 +6617,21 @@ func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListAvailableZonesResponse) SyncEffectiveFieldsDuringRead(existingState ListAvailableZonesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAvailableZonesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAvailableZonesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "zones": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ListAvailableZonesResponse in the Terraform plugin framework type +// system. func (a ListAvailableZonesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5537,10 +6662,19 @@ func (newState *ListClusterCompliancesRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListClusterCompliancesRequest) SyncEffectiveFieldsDuringRead(existingState ListClusterCompliancesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClusterCompliancesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClusterCompliancesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListClusterCompliancesRequest in the Terraform plugin framework type +// system. func (a ListClusterCompliancesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5569,12 +6703,21 @@ func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListClusterCompliancesResponse) SyncEffectiveFieldsDuringRead(existingState ListClusterCompliancesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClusterCompliancesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClusterCompliancesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(ClusterCompliance{}), } } +// ToAttrType returns the representation of ListClusterCompliancesResponse in the Terraform plugin framework type +// system. func (a ListClusterCompliancesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5604,10 +6747,19 @@ func (newState *ListClusterPoliciesRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListClusterPoliciesRequest) SyncEffectiveFieldsDuringRead(existingState ListClusterPoliciesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClusterPoliciesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClusterPoliciesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListClusterPoliciesRequest in the Terraform plugin framework type +// system. func (a ListClusterPoliciesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5634,6 +6786,13 @@ func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListClustersFilterBy) SyncEffectiveFieldsDuringRead(existingState ListClustersFilterBy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClustersFilterBy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_sources": reflect.TypeOf(types.String{}), @@ -5641,6 +6800,8 @@ func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of ListClustersFilterBy in the Terraform plugin framework type +// system. func (a ListClustersFilterBy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5677,6 +6838,13 @@ func (newState *ListClustersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListClustersRequest) SyncEffectiveFieldsDuringRead(existingState ListClustersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClustersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClustersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter_by": reflect.TypeOf(ListClustersFilterBy{}), @@ -5684,6 +6852,8 @@ func (a ListClustersRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of ListClustersRequest in the Terraform plugin framework type +// system. func (a ListClustersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5717,12 +6887,21 @@ func (newState *ListClustersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListClustersResponse) SyncEffectiveFieldsDuringRead(existingState ListClustersResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClustersResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClustersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(ClusterDetails{}), } } +// ToAttrType returns the representation of ListClustersResponse in the Terraform plugin framework type +// system. func (a ListClustersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5750,10 +6929,19 @@ func (newState *ListClustersSortBy) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListClustersSortBy) SyncEffectiveFieldsDuringRead(existingState ListClustersSortBy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListClustersSortBy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListClustersSortBy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListClustersSortBy in the Terraform plugin framework type +// system. func (a ListClustersSortBy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5773,12 +6961,21 @@ func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringCreateOr func (newState *ListGlobalInitScriptsResponse) SyncEffectiveFieldsDuringRead(existingState ListGlobalInitScriptsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListGlobalInitScriptsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "scripts": reflect.TypeOf(GlobalInitScriptDetails{}), } } +// ToAttrType returns the representation of ListGlobalInitScriptsResponse in the Terraform plugin framework type +// system. func (a ListGlobalInitScriptsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5799,12 +6996,21 @@ func (newState *ListInstancePools) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListInstancePools) SyncEffectiveFieldsDuringRead(existingState ListInstancePools) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListInstancePools. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListInstancePools) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "instance_pools": reflect.TypeOf(InstancePoolAndStats{}), } } +// ToAttrType returns the representation of ListInstancePools in the Terraform plugin framework type +// system. func (a ListInstancePools) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5826,12 +7032,21 @@ func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListInstanceProfilesResponse) SyncEffectiveFieldsDuringRead(existingState ListInstanceProfilesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListInstanceProfilesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListInstanceProfilesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "instance_profiles": reflect.TypeOf(InstanceProfile{}), } } +// ToAttrType returns the representation of ListInstanceProfilesResponse in the Terraform plugin framework type +// system. func (a ListInstanceProfilesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5853,12 +7068,21 @@ func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListNodeTypesResponse) SyncEffectiveFieldsDuringRead(existingState ListNodeTypesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNodeTypesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNodeTypesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "node_types": reflect.TypeOf(NodeType{}), } } +// ToAttrType returns the representation of ListNodeTypesResponse in the Terraform plugin framework type +// system. func (a ListNodeTypesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5880,12 +7104,21 @@ func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListPoliciesResponse) SyncEffectiveFieldsDuringRead(existingState ListPoliciesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPoliciesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPoliciesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "policies": reflect.TypeOf(Policy{}), } } +// ToAttrType returns the representation of ListPoliciesResponse in the Terraform plugin framework type +// system. func (a ListPoliciesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5910,10 +7143,19 @@ func (newState *ListPolicyFamiliesRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListPolicyFamiliesRequest) SyncEffectiveFieldsDuringRead(existingState ListPolicyFamiliesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPolicyFamiliesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPolicyFamiliesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListPolicyFamiliesRequest in the Terraform plugin framework type +// system. func (a ListPolicyFamiliesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5937,12 +7179,21 @@ func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListPolicyFamiliesResponse) SyncEffectiveFieldsDuringRead(existingState ListPolicyFamiliesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPolicyFamiliesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPolicyFamiliesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "policy_families": reflect.TypeOf(PolicyFamily{}), } } +// ToAttrType returns the representation of ListPolicyFamiliesResponse in the Terraform plugin framework type +// system. func (a ListPolicyFamiliesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5965,10 +7216,19 @@ func (newState *LocalFileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Loca func (newState *LocalFileInfo) SyncEffectiveFieldsDuringRead(existingState LocalFileInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LocalFileInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LocalFileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LocalFileInfo in the Terraform plugin framework type +// system. func (a LocalFileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5990,10 +7250,19 @@ func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringRead(existingState LogAnalyticsInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogAnalyticsInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogAnalyticsInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogAnalyticsInfo in the Terraform plugin framework type +// system. func (a LogAnalyticsInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6018,10 +7287,19 @@ func (newState *LogSyncStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogS func (newState *LogSyncStatus) SyncEffectiveFieldsDuringRead(existingState LogSyncStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogSyncStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogSyncStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogSyncStatus in the Terraform plugin framework type +// system. func (a LogSyncStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6051,12 +7329,21 @@ func (newState *MavenLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Maven func (newState *MavenLibrary) SyncEffectiveFieldsDuringRead(existingState MavenLibrary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MavenLibrary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MavenLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exclusions": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of MavenLibrary in the Terraform plugin framework type +// system. func (a MavenLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6087,10 +7374,19 @@ func (newState *NodeInstanceType) SyncEffectiveFieldsDuringCreateOrUpdate(plan N func (newState *NodeInstanceType) SyncEffectiveFieldsDuringRead(existingState NodeInstanceType) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NodeInstanceType. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NodeInstanceType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NodeInstanceType in the Terraform plugin framework type +// system. func (a NodeInstanceType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6159,6 +7455,13 @@ func (newState *NodeType) SyncEffectiveFieldsDuringCreateOrUpdate(plan NodeType) func (newState *NodeType) SyncEffectiveFieldsDuringRead(existingState NodeType) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NodeType. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NodeType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "node_info": reflect.TypeOf(CloudProviderNodeInfo{}), @@ -6166,6 +7469,8 @@ func (a NodeType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } +// ToAttrType returns the representation of NodeType in the Terraform plugin framework type +// system. func (a NodeType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6210,10 +7515,19 @@ func (newState *PendingInstanceError) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PendingInstanceError) SyncEffectiveFieldsDuringRead(existingState PendingInstanceError) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PendingInstanceError. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PendingInstanceError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PendingInstanceError in the Terraform plugin framework type +// system. func (a PendingInstanceError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6234,10 +7548,19 @@ func (newState *PermanentDeleteCluster) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PermanentDeleteCluster) SyncEffectiveFieldsDuringRead(existingState PermanentDeleteCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermanentDeleteCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermanentDeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PermanentDeleteCluster in the Terraform plugin framework type +// system. func (a PermanentDeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6255,10 +7578,19 @@ func (newState *PermanentDeleteClusterResponse) SyncEffectiveFieldsDuringCreateO func (newState *PermanentDeleteClusterResponse) SyncEffectiveFieldsDuringRead(existingState PermanentDeleteClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermanentDeleteClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermanentDeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PermanentDeleteClusterResponse in the Terraform plugin framework type +// system. func (a PermanentDeleteClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6276,10 +7608,19 @@ func (newState *PinCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan PinClus func (newState *PinCluster) SyncEffectiveFieldsDuringRead(existingState PinCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PinCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PinCluster in the Terraform plugin framework type +// system. func (a PinCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6297,10 +7638,19 @@ func (newState *PinClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PinClusterResponse) SyncEffectiveFieldsDuringRead(existingState PinClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PinClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PinClusterResponse in the Terraform plugin framework type +// system. func (a PinClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6362,12 +7712,21 @@ func (newState *Policy) SyncEffectiveFieldsDuringCreateOrUpdate(plan Policy) { func (newState *Policy) SyncEffectiveFieldsDuringRead(existingState Policy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Policy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Policy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } } +// ToAttrType returns the representation of Policy in the Terraform plugin framework type +// system. func (a Policy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6408,10 +7767,19 @@ func (newState *PolicyFamily) SyncEffectiveFieldsDuringCreateOrUpdate(plan Polic func (newState *PolicyFamily) SyncEffectiveFieldsDuringRead(existingState PolicyFamily) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PolicyFamily. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PolicyFamily) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PolicyFamily in the Terraform plugin framework type +// system. func (a PolicyFamily) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6439,10 +7807,19 @@ func (newState *PythonPyPiLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PythonPyPiLibrary) SyncEffectiveFieldsDuringRead(existingState PythonPyPiLibrary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PythonPyPiLibrary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PythonPyPiLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PythonPyPiLibrary in the Terraform plugin framework type +// system. func (a PythonPyPiLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6466,10 +7843,19 @@ func (newState *RCranLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan RCran func (newState *RCranLibrary) SyncEffectiveFieldsDuringRead(existingState RCranLibrary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RCranLibrary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RCranLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RCranLibrary in the Terraform plugin framework type +// system. func (a RCranLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6490,10 +7876,19 @@ func (newState *RemoveInstanceProfile) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *RemoveInstanceProfile) SyncEffectiveFieldsDuringRead(existingState RemoveInstanceProfile) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RemoveInstanceProfile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RemoveInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RemoveInstanceProfile in the Terraform plugin framework type +// system. func (a RemoveInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6511,10 +7906,19 @@ func (newState *RemoveResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rem func (newState *RemoveResponse) SyncEffectiveFieldsDuringRead(existingState RemoveResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RemoveResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RemoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RemoveResponse in the Terraform plugin framework type +// system. func (a RemoveResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6547,12 +7951,21 @@ func (newState *ResizeCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resi func (newState *ResizeCluster) SyncEffectiveFieldsDuringRead(existingState ResizeCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResizeCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResizeCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), } } +// ToAttrType returns the representation of ResizeCluster in the Terraform plugin framework type +// system. func (a ResizeCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6574,10 +7987,19 @@ func (newState *ResizeClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ResizeClusterResponse) SyncEffectiveFieldsDuringRead(existingState ResizeClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResizeClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResizeClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ResizeClusterResponse in the Terraform plugin framework type +// system. func (a ResizeClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6597,10 +8019,19 @@ func (newState *RestartCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *RestartCluster) SyncEffectiveFieldsDuringRead(existingState RestartCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestartCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestartCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestartCluster in the Terraform plugin framework type +// system. func (a RestartCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6619,10 +8050,19 @@ func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringRead(existingState RestartClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestartClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestartClusterResponse in the Terraform plugin framework type +// system. func (a RestartClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6659,6 +8099,13 @@ func (newState *Results) SyncEffectiveFieldsDuringCreateOrUpdate(plan Results) { func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Results. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fileNames": reflect.TypeOf(types.String{}), @@ -6666,6 +8113,8 @@ func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of Results in the Terraform plugin framework type +// system. func (a Results) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6728,10 +8177,19 @@ func (newState *S3StorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan S3St func (newState *S3StorageInfo) SyncEffectiveFieldsDuringRead(existingState S3StorageInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in S3StorageInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a S3StorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of S3StorageInfo in the Terraform plugin framework type +// system. func (a S3StorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6780,12 +8238,21 @@ func (newState *SparkNode) SyncEffectiveFieldsDuringCreateOrUpdate(plan SparkNod func (newState *SparkNode) SyncEffectiveFieldsDuringRead(existingState SparkNode) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparkNode. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparkNode) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "node_aws_attributes": reflect.TypeOf(SparkNodeAwsAttributes{}), } } +// ToAttrType returns the representation of SparkNode in the Terraform plugin framework type +// system. func (a SparkNode) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6813,10 +8280,19 @@ func (newState *SparkNodeAwsAttributes) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SparkNodeAwsAttributes) SyncEffectiveFieldsDuringRead(existingState SparkNodeAwsAttributes) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparkNodeAwsAttributes. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparkNodeAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SparkNodeAwsAttributes in the Terraform plugin framework type +// system. func (a SparkNodeAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6842,10 +8318,19 @@ func (newState *SparkVersion) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spark func (newState *SparkVersion) SyncEffectiveFieldsDuringRead(existingState SparkVersion) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparkVersion. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparkVersion) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SparkVersion in the Terraform plugin framework type +// system. func (a SparkVersion) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6866,10 +8351,19 @@ func (newState *StartCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Start func (newState *StartCluster) SyncEffectiveFieldsDuringRead(existingState StartCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StartCluster in the Terraform plugin framework type +// system. func (a StartCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6887,10 +8381,19 @@ func (newState *StartClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StartClusterResponse) SyncEffectiveFieldsDuringRead(existingState StartClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StartClusterResponse in the Terraform plugin framework type +// system. func (a StartClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6913,12 +8416,21 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState TerminationReason) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TerminationReason. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of TerminationReason in the Terraform plugin framework type +// system. func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6944,12 +8456,21 @@ func (newState *UninstallLibraries) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UninstallLibraries) SyncEffectiveFieldsDuringRead(existingState UninstallLibraries) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UninstallLibraries. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UninstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "libraries": reflect.TypeOf(Library{}), } } +// ToAttrType returns the representation of UninstallLibraries in the Terraform plugin framework type +// system. func (a UninstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6970,10 +8491,19 @@ func (newState *UninstallLibrariesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UninstallLibrariesResponse) SyncEffectiveFieldsDuringRead(existingState UninstallLibrariesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UninstallLibrariesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UninstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UninstallLibrariesResponse in the Terraform plugin framework type +// system. func (a UninstallLibrariesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6991,10 +8521,19 @@ func (newState *UnpinCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Unpin func (newState *UnpinCluster) SyncEffectiveFieldsDuringRead(existingState UnpinCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UnpinCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UnpinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UnpinCluster in the Terraform plugin framework type +// system. func (a UnpinCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7012,10 +8551,19 @@ func (newState *UnpinClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UnpinClusterResponse) SyncEffectiveFieldsDuringRead(existingState UnpinClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UnpinClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UnpinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UnpinClusterResponse in the Terraform plugin framework type +// system. func (a UnpinClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -7041,12 +8589,21 @@ func (newState *UpdateCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateCluster) SyncEffectiveFieldsDuringRead(existingState UpdateCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster": reflect.TypeOf(UpdateClusterResource{}), } } +// ToAttrType returns the representation of UpdateCluster in the Terraform plugin framework type +// system. func (a UpdateCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7213,6 +8770,13 @@ func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateClusterResource) SyncEffectiveFieldsDuringRead(existingState UpdateClusterResource) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateClusterResource. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(AutoScale{}), @@ -7230,6 +8794,8 @@ func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of UpdateClusterResource in the Terraform plugin framework type +// system. func (a UpdateClusterResource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7296,10 +8862,19 @@ func (newState *UpdateClusterResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateClusterResponse) SyncEffectiveFieldsDuringRead(existingState UpdateClusterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateClusterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateClusterResponse in the Terraform plugin framework type +// system. func (a UpdateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -7315,10 +8890,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -7336,10 +8920,19 @@ func (newState *VolumesStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *VolumesStorageInfo) SyncEffectiveFieldsDuringRead(existingState VolumesStorageInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in VolumesStorageInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a VolumesStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of VolumesStorageInfo in the Terraform plugin framework type +// system. func (a VolumesStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7359,12 +8952,21 @@ func (newState *WorkloadType) SyncEffectiveFieldsDuringCreateOrUpdate(plan Workl func (newState *WorkloadType) SyncEffectiveFieldsDuringRead(existingState WorkloadType) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkloadType. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkloadType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clients": reflect.TypeOf(ClientsTypes{}), } } +// ToAttrType returns the representation of WorkloadType in the Terraform plugin framework type +// system. func (a WorkloadType) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -7387,10 +8989,19 @@ func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WorkspaceStorageInfo) SyncEffectiveFieldsDuringRead(existingState WorkspaceStorageInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceStorageInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WorkspaceStorageInfo in the Terraform plugin framework type +// system. func (a WorkspaceStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index cbafe79a14..7f9565ac3d 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -32,12 +32,21 @@ func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState CreateDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dashboard": reflect.TypeOf(Dashboard{}), } } +// ToAttrType returns the representation of CreateDashboardRequest in the Terraform plugin framework type +// system. func (a CreateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -62,12 +71,21 @@ func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateScheduleRequest) SyncEffectiveFieldsDuringRead(existingState CreateScheduleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateScheduleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schedule": reflect.TypeOf(Schedule{}), } } +// ToAttrType returns the representation of CreateScheduleRequest in the Terraform plugin framework type +// system. func (a CreateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -95,12 +113,21 @@ func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState CreateSubscriptionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateSubscriptionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscription": reflect.TypeOf(Subscription{}), } } +// ToAttrType returns the representation of CreateSubscriptionRequest in the Terraform plugin framework type +// system. func (a CreateSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -132,10 +159,19 @@ func (newState *CronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronS func (newState *CronSchedule) SyncEffectiveFieldsDuringRead(existingState CronSchedule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CronSchedule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CronSchedule in the Terraform plugin framework type +// system. func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -187,10 +223,19 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboar func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Dashboard. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Dashboard in the Terraform plugin framework type +// system. func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -225,10 +270,19 @@ func (newState *DeleteScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteScheduleRequest) SyncEffectiveFieldsDuringRead(existingState DeleteScheduleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteScheduleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteScheduleRequest in the Terraform plugin framework type +// system. func (a DeleteScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -248,10 +302,19 @@ func (newState *DeleteScheduleResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteScheduleResponse) SyncEffectiveFieldsDuringRead(existingState DeleteScheduleResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteScheduleResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteScheduleResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteScheduleResponse in the Terraform plugin framework type +// system. func (a DeleteScheduleResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -277,10 +340,19 @@ func (newState *DeleteSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteSubscriptionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteSubscriptionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteSubscriptionRequest in the Terraform plugin framework type +// system. func (a DeleteSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -301,10 +373,19 @@ func (newState *DeleteSubscriptionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteSubscriptionResponse) SyncEffectiveFieldsDuringRead(existingState DeleteSubscriptionResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteSubscriptionResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteSubscriptionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteSubscriptionResponse in the Terraform plugin framework type +// system. func (a DeleteSubscriptionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -324,6 +405,13 @@ func (newState *GenieAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GenieAttachment) SyncEffectiveFieldsDuringRead(existingState GenieAttachment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieAttachment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieAttachment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(QueryAttachment{}), @@ -331,6 +419,8 @@ func (a GenieAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of GenieAttachment in the Terraform plugin framework type +// system. func (a GenieAttachment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -365,10 +455,19 @@ func (newState *GenieConversation) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GenieConversation) SyncEffectiveFieldsDuringRead(existingState GenieConversation) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieConversation. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieConversation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenieConversation in the Terraform plugin framework type +// system. func (a GenieConversation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -397,10 +496,19 @@ func (newState *GenieCreateConversationMessageRequest) SyncEffectiveFieldsDuring func (newState *GenieCreateConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieCreateConversationMessageRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieCreateConversationMessageRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenieCreateConversationMessageRequest in the Terraform plugin framework type +// system. func (a GenieCreateConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -427,10 +535,19 @@ func (newState *GenieExecuteMessageQueryRequest) SyncEffectiveFieldsDuringCreate func (newState *GenieExecuteMessageQueryRequest) SyncEffectiveFieldsDuringRead(existingState GenieExecuteMessageQueryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieExecuteMessageQueryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenieExecuteMessageQueryRequest in the Terraform plugin framework type +// system. func (a GenieExecuteMessageQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -459,10 +576,19 @@ func (newState *GenieGetConversationMessageRequest) SyncEffectiveFieldsDuringCre func (newState *GenieGetConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieGetConversationMessageRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieGetConversationMessageRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieGetConversationMessageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenieGetConversationMessageRequest in the Terraform plugin framework type +// system. func (a GenieGetConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -489,10 +615,19 @@ func (newState *GenieGetMessageQueryResultRequest) SyncEffectiveFieldsDuringCrea func (newState *GenieGetMessageQueryResultRequest) SyncEffectiveFieldsDuringRead(existingState GenieGetMessageQueryResultRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieGetMessageQueryResultRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenieGetMessageQueryResultRequest in the Terraform plugin framework type +// system. func (a GenieGetMessageQueryResultRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -515,12 +650,21 @@ func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringCre func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringRead(existingState GenieGetMessageQueryResultResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieGetMessageQueryResultResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "statement_response": reflect.TypeOf(sql.StatementResponse{}), } } +// ToAttrType returns the representation of GenieGetMessageQueryResultResponse in the Terraform plugin framework type +// system. func (a GenieGetMessageQueryResultResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -577,6 +721,13 @@ func (newState *GenieMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Genie func (newState *GenieMessage) SyncEffectiveFieldsDuringRead(existingState GenieMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "attachments": reflect.TypeOf(GenieAttachment{}), @@ -585,6 +736,8 @@ func (a GenieMessage) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of GenieMessage in the Terraform plugin framework type +// system. func (a GenieMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -623,10 +776,19 @@ func (newState *GenieStartConversationMessageRequest) SyncEffectiveFieldsDuringC func (newState *GenieStartConversationMessageRequest) SyncEffectiveFieldsDuringRead(existingState GenieStartConversationMessageRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieStartConversationMessageRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieStartConversationMessageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenieStartConversationMessageRequest in the Terraform plugin framework type +// system. func (a GenieStartConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -652,6 +814,13 @@ func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringCreateO func (newState *GenieStartConversationResponse) SyncEffectiveFieldsDuringRead(existingState GenieStartConversationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenieStartConversationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenieStartConversationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "conversation": reflect.TypeOf(GenieConversation{}), @@ -659,6 +828,8 @@ func (a GenieStartConversationResponse) GetComplexFieldTypes(ctx context.Context } } +// ToAttrType returns the representation of GenieStartConversationResponse in the Terraform plugin framework type +// system. func (a GenieStartConversationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -686,10 +857,19 @@ func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDashboardRequest in the Terraform plugin framework type +// system. func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -710,10 +890,19 @@ func (newState *GetPublishedDashboardRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *GetPublishedDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetPublishedDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPublishedDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPublishedDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPublishedDashboardRequest in the Terraform plugin framework type +// system. func (a GetPublishedDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -736,10 +925,19 @@ func (newState *GetScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetScheduleRequest) SyncEffectiveFieldsDuringRead(existingState GetScheduleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetScheduleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetScheduleRequest in the Terraform plugin framework type +// system. func (a GetScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -765,10 +963,19 @@ func (newState *GetSubscriptionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetSubscriptionRequest) SyncEffectiveFieldsDuringRead(existingState GetSubscriptionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSubscriptionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetSubscriptionRequest in the Terraform plugin framework type +// system. func (a GetSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -799,10 +1006,19 @@ func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringRead(existingState ListDashboardsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListDashboardsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListDashboardsRequest in the Terraform plugin framework type +// system. func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -827,12 +1043,21 @@ func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListDashboardsResponse) SyncEffectiveFieldsDuringRead(existingState ListDashboardsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListDashboardsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListDashboardsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dashboards": reflect.TypeOf(Dashboard{}), } } +// ToAttrType returns the representation of ListDashboardsResponse in the Terraform plugin framework type +// system. func (a ListDashboardsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -861,10 +1086,19 @@ func (newState *ListSchedulesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListSchedulesRequest) SyncEffectiveFieldsDuringRead(existingState ListSchedulesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSchedulesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSchedulesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSchedulesRequest in the Terraform plugin framework type +// system. func (a ListSchedulesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -890,12 +1124,21 @@ func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListSchedulesResponse) SyncEffectiveFieldsDuringRead(existingState ListSchedulesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSchedulesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSchedulesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schedules": reflect.TypeOf(Schedule{}), } } +// ToAttrType returns the representation of ListSchedulesResponse in the Terraform plugin framework type +// system. func (a ListSchedulesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -926,10 +1169,19 @@ func (newState *ListSubscriptionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListSubscriptionsRequest) SyncEffectiveFieldsDuringRead(existingState ListSubscriptionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSubscriptionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSubscriptionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSubscriptionsRequest in the Terraform plugin framework type +// system. func (a ListSubscriptionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -956,12 +1208,21 @@ func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListSubscriptionsResponse) SyncEffectiveFieldsDuringRead(existingState ListSubscriptionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSubscriptionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSubscriptionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriptions": reflect.TypeOf(Subscription{}), } } +// ToAttrType returns the representation of ListSubscriptionsResponse in the Terraform plugin framework type +// system. func (a ListSubscriptionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -985,10 +1246,19 @@ func (newState *MessageError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Messa func (newState *MessageError) SyncEffectiveFieldsDuringRead(existingState MessageError) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MessageError. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MessageError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MessageError in the Terraform plugin framework type +// system. func (a MessageError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1014,10 +1284,19 @@ func (newState *MigrateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *MigrateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState MigrateDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MigrateDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MigrateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MigrateDashboardRequest in the Terraform plugin framework type +// system. func (a MigrateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1046,10 +1325,19 @@ func (newState *PublishRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pub func (newState *PublishRequest) SyncEffectiveFieldsDuringRead(existingState PublishRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PublishRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PublishRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PublishRequest in the Terraform plugin framework type +// system. func (a PublishRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1077,10 +1365,19 @@ func (newState *PublishedDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PublishedDashboard) SyncEffectiveFieldsDuringRead(existingState PublishedDashboard) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PublishedDashboard. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PublishedDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PublishedDashboard in the Terraform plugin framework type +// system. func (a PublishedDashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1117,10 +1414,19 @@ func (newState *QueryAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Qu func (newState *QueryAttachment) SyncEffectiveFieldsDuringRead(existingState QueryAttachment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryAttachment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryAttachment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of QueryAttachment in the Terraform plugin framework type +// system. func (a QueryAttachment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1152,10 +1458,19 @@ func (newState *Result) SyncEffectiveFieldsDuringCreateOrUpdate(plan Result) { func (newState *Result) SyncEffectiveFieldsDuringRead(existingState Result) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Result. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Result) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Result in the Terraform plugin framework type +// system. func (a Result) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1196,12 +1511,21 @@ func (newState *Schedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan Schedule) func (newState *Schedule) SyncEffectiveFieldsDuringRead(existingState Schedule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Schedule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Schedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cron_schedule": reflect.TypeOf(CronSchedule{}), } } +// ToAttrType returns the representation of Schedule in the Terraform plugin framework type +// system. func (a Schedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1235,6 +1559,13 @@ func (newState *Subscriber) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subscri func (newState *Subscriber) SyncEffectiveFieldsDuringRead(existingState Subscriber) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Subscriber. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Subscriber) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "destination_subscriber": reflect.TypeOf(SubscriptionSubscriberDestination{}), @@ -1242,6 +1573,8 @@ func (a Subscriber) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of Subscriber in the Terraform plugin framework type +// system. func (a Subscriber) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1284,12 +1617,21 @@ func (newState *Subscription) SyncEffectiveFieldsDuringCreateOrUpdate(plan Subsc func (newState *Subscription) SyncEffectiveFieldsDuringRead(existingState Subscription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Subscription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Subscription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriber": reflect.TypeOf(Subscriber{}), } } +// ToAttrType returns the representation of Subscription in the Terraform plugin framework type +// system. func (a Subscription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1319,10 +1661,19 @@ func (newState *SubscriptionSubscriberDestination) SyncEffectiveFieldsDuringCrea func (newState *SubscriptionSubscriberDestination) SyncEffectiveFieldsDuringRead(existingState SubscriptionSubscriberDestination) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SubscriptionSubscriberDestination. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SubscriptionSubscriberDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SubscriptionSubscriberDestination in the Terraform plugin framework type +// system. func (a SubscriptionSubscriberDestination) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1342,10 +1693,19 @@ func (newState *SubscriptionSubscriberUser) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SubscriptionSubscriberUser) SyncEffectiveFieldsDuringRead(existingState SubscriptionSubscriberUser) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SubscriptionSubscriberUser. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SubscriptionSubscriberUser) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SubscriptionSubscriberUser in the Terraform plugin framework type +// system. func (a SubscriptionSubscriberUser) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1367,10 +1727,19 @@ func (newState *TextAttachment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tex func (newState *TextAttachment) SyncEffectiveFieldsDuringRead(existingState TextAttachment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TextAttachment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TextAttachment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TextAttachment in the Terraform plugin framework type +// system. func (a TextAttachment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1392,10 +1761,19 @@ func (newState *TrashDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *TrashDashboardRequest) SyncEffectiveFieldsDuringRead(existingState TrashDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TrashDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TrashDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TrashDashboardRequest in the Terraform plugin framework type +// system. func (a TrashDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1413,10 +1791,19 @@ func (newState *TrashDashboardResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *TrashDashboardResponse) SyncEffectiveFieldsDuringRead(existingState TrashDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TrashDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TrashDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TrashDashboardResponse in the Terraform plugin framework type +// system. func (a TrashDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1435,10 +1822,19 @@ func (newState *UnpublishDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UnpublishDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UnpublishDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UnpublishDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UnpublishDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UnpublishDashboardRequest in the Terraform plugin framework type +// system. func (a UnpublishDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1456,10 +1852,19 @@ func (newState *UnpublishDashboardResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UnpublishDashboardResponse) SyncEffectiveFieldsDuringRead(existingState UnpublishDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UnpublishDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UnpublishDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UnpublishDashboardResponse in the Terraform plugin framework type +// system. func (a UnpublishDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1479,12 +1884,21 @@ func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dashboard": reflect.TypeOf(Dashboard{}), } } +// ToAttrType returns the representation of UpdateDashboardRequest in the Terraform plugin framework type +// system. func (a UpdateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1512,12 +1926,21 @@ func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateScheduleRequest) SyncEffectiveFieldsDuringRead(existingState UpdateScheduleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateScheduleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "schedule": reflect.TypeOf(Schedule{}), } } +// ToAttrType returns the representation of UpdateScheduleRequest in the Terraform plugin framework type +// system. func (a UpdateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 3581ab4739..b4dae86850 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -34,10 +34,19 @@ func (newState *AddBlock) SyncEffectiveFieldsDuringCreateOrUpdate(plan AddBlock) func (newState *AddBlock) SyncEffectiveFieldsDuringRead(existingState AddBlock) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AddBlock. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AddBlock) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AddBlock in the Terraform plugin framework type +// system. func (a AddBlock) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -56,10 +65,19 @@ func (newState *AddBlockResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan A func (newState *AddBlockResponse) SyncEffectiveFieldsDuringRead(existingState AddBlockResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AddBlockResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AddBlockResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AddBlockResponse in the Terraform plugin framework type +// system. func (a AddBlockResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -77,10 +95,19 @@ func (newState *Close) SyncEffectiveFieldsDuringCreateOrUpdate(plan Close) { func (newState *Close) SyncEffectiveFieldsDuringRead(existingState Close) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Close. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Close) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Close in the Terraform plugin framework type +// system. func (a Close) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -98,10 +125,19 @@ func (newState *CloseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Clos func (newState *CloseResponse) SyncEffectiveFieldsDuringRead(existingState CloseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CloseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CloseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CloseResponse in the Terraform plugin framework type +// system. func (a CloseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -121,10 +157,19 @@ func (newState *Create) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create) { func (newState *Create) SyncEffectiveFieldsDuringRead(existingState Create) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Create. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Create) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Create in the Terraform plugin framework type +// system. func (a Create) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -146,10 +191,19 @@ func (newState *CreateDirectoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateDirectoryRequest) SyncEffectiveFieldsDuringRead(existingState CreateDirectoryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateDirectoryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateDirectoryRequest in the Terraform plugin framework type +// system. func (a CreateDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -167,10 +221,19 @@ func (newState *CreateDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState CreateDirectoryResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateDirectoryResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateDirectoryResponse in the Terraform plugin framework type +// system. func (a CreateDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -189,10 +252,19 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// system. func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -216,10 +288,19 @@ func (newState *Delete) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete) { func (newState *Delete) SyncEffectiveFieldsDuringRead(existingState Delete) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Delete. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Delete in the Terraform plugin framework type +// system. func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -241,10 +322,19 @@ func (newState *DeleteDirectoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteDirectoryRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDirectoryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDirectoryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDirectoryRequest in the Terraform plugin framework type +// system. func (a DeleteDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -262,10 +352,19 @@ func (newState *DeleteDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDirectoryResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDirectoryResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDirectoryResponse in the Terraform plugin framework type +// system. func (a DeleteDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -284,10 +383,19 @@ func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFileRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteFileRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteFileRequest in the Terraform plugin framework type +// system. func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -305,10 +413,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -335,10 +452,19 @@ func (newState *DirectoryEntry) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dir func (newState *DirectoryEntry) SyncEffectiveFieldsDuringRead(existingState DirectoryEntry) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DirectoryEntry. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DirectoryEntry) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DirectoryEntry in the Terraform plugin framework type +// system. func (a DirectoryEntry) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -363,10 +489,19 @@ func (newState *DownloadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Do func (newState *DownloadRequest) SyncEffectiveFieldsDuringRead(existingState DownloadRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DownloadRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DownloadRequest in the Terraform plugin framework type +// system. func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -391,10 +526,19 @@ func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DownloadResponse) SyncEffectiveFieldsDuringRead(existingState DownloadResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DownloadResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DownloadResponse in the Terraform plugin framework type +// system. func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -423,10 +567,19 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FileInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FileInfo in the Terraform plugin framework type +// system. func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -450,10 +603,19 @@ func (newState *GetDirectoryMetadataRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetDirectoryMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetDirectoryMetadataRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDirectoryMetadataRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDirectoryMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDirectoryMetadataRequest in the Terraform plugin framework type +// system. func (a GetDirectoryMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -471,10 +633,19 @@ func (newState *GetDirectoryMetadataResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetDirectoryMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetDirectoryMetadataResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDirectoryMetadataResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDirectoryMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDirectoryMetadataResponse in the Terraform plugin framework type +// system. func (a GetDirectoryMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -493,10 +664,19 @@ func (newState *GetMetadataRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetMetadataRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetMetadataRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetMetadataRequest in the Terraform plugin framework type +// system. func (a GetMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -519,10 +699,19 @@ func (newState *GetMetadataResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetMetadataResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetMetadataResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetMetadataResponse in the Terraform plugin framework type +// system. func (a GetMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -546,10 +735,19 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStatusRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStatusRequest in the Terraform plugin framework type +// system. func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -571,10 +769,19 @@ func (newState *ListDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListDbfsRequest) SyncEffectiveFieldsDuringRead(existingState ListDbfsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListDbfsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListDbfsRequest in the Terraform plugin framework type +// system. func (a ListDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -615,10 +822,19 @@ func (newState *ListDirectoryContentsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListDirectoryContentsRequest) SyncEffectiveFieldsDuringRead(existingState ListDirectoryContentsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListDirectoryContentsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListDirectoryContentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListDirectoryContentsRequest in the Terraform plugin framework type +// system. func (a ListDirectoryContentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -642,12 +858,21 @@ func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDirectoryResponse) SyncEffectiveFieldsDuringRead(existingState ListDirectoryResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListDirectoryResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "contents": reflect.TypeOf(DirectoryEntry{}), } } +// ToAttrType returns the representation of ListDirectoryResponse in the Terraform plugin framework type +// system. func (a ListDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -671,12 +896,21 @@ func (newState *ListStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListStatusResponse) SyncEffectiveFieldsDuringRead(existingState ListStatusResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListStatusResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "files": reflect.TypeOf(FileInfo{}), } } +// ToAttrType returns the representation of ListStatusResponse in the Terraform plugin framework type +// system. func (a ListStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -698,10 +932,19 @@ func (newState *MkDirs) SyncEffectiveFieldsDuringCreateOrUpdate(plan MkDirs) { func (newState *MkDirs) SyncEffectiveFieldsDuringRead(existingState MkDirs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MkDirs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MkDirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MkDirs in the Terraform plugin framework type +// system. func (a MkDirs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -719,10 +962,19 @@ func (newState *MkDirsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MkD func (newState *MkDirsResponse) SyncEffectiveFieldsDuringRead(existingState MkDirsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MkDirsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MkDirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MkDirsResponse in the Terraform plugin framework type +// system. func (a MkDirsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -744,10 +996,19 @@ func (newState *Move) SyncEffectiveFieldsDuringCreateOrUpdate(plan Move) { func (newState *Move) SyncEffectiveFieldsDuringRead(existingState Move) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Move. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Move) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Move in the Terraform plugin framework type +// system. func (a Move) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -766,10 +1027,19 @@ func (newState *MoveResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan MoveR func (newState *MoveResponse) SyncEffectiveFieldsDuringRead(existingState MoveResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MoveResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MoveResponse in the Terraform plugin framework type +// system. func (a MoveResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -791,10 +1061,19 @@ func (newState *Put) SyncEffectiveFieldsDuringCreateOrUpdate(plan Put) { func (newState *Put) SyncEffectiveFieldsDuringRead(existingState Put) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Put. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Put) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Put in the Terraform plugin framework type +// system. func (a Put) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -814,10 +1093,19 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRes func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PutResponse in the Terraform plugin framework type +// system. func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -841,10 +1129,19 @@ func (newState *ReadDbfsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReadDbfsRequest) SyncEffectiveFieldsDuringRead(existingState ReadDbfsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReadDbfsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReadDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ReadDbfsRequest in the Terraform plugin framework type +// system. func (a ReadDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -870,10 +1167,19 @@ func (newState *ReadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReadR func (newState *ReadResponse) SyncEffectiveFieldsDuringRead(existingState ReadResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReadResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ReadResponse in the Terraform plugin framework type +// system. func (a ReadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -898,10 +1204,19 @@ func (newState *UploadRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Uplo func (newState *UploadRequest) SyncEffectiveFieldsDuringRead(existingState UploadRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UploadRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UploadRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UploadRequest in the Terraform plugin framework type +// system. func (a UploadRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -921,10 +1236,19 @@ func (newState *UploadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upl func (newState *UploadResponse) SyncEffectiveFieldsDuringRead(existingState UploadResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UploadResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UploadResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UploadResponse in the Terraform plugin framework type +// system. func (a UploadResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index eafabb6b6b..93e0689d08 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -36,10 +36,19 @@ func (newState *AccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *AccessControlRequest) SyncEffectiveFieldsDuringRead(existingState AccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AccessControlRequest in the Terraform plugin framework type +// system. func (a AccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -70,12 +79,21 @@ func (newState *AccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AccessControlResponse) SyncEffectiveFieldsDuringRead(existingState AccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(Permission{}), } } +// ToAttrType returns the representation of AccessControlResponse in the Terraform plugin framework type +// system. func (a AccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -108,10 +126,19 @@ func (newState *ComplexValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Compl func (newState *ComplexValue) SyncEffectiveFieldsDuringRead(existingState ComplexValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ComplexValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ComplexValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ComplexValue in the Terraform plugin framework type +// system. func (a ComplexValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -136,10 +163,19 @@ func (newState *DeleteAccountGroupRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteAccountGroupRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountGroupRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountGroupRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountGroupRequest in the Terraform plugin framework type +// system. func (a DeleteAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -160,10 +196,19 @@ func (newState *DeleteAccountServicePrincipalRequest) SyncEffectiveFieldsDuringC func (newState *DeleteAccountServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountServicePrincipalRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountServicePrincipalRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountServicePrincipalRequest in the Terraform plugin framework type +// system. func (a DeleteAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -184,10 +229,19 @@ func (newState *DeleteAccountUserRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteAccountUserRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountUserRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountUserRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountUserRequest in the Terraform plugin framework type +// system. func (a DeleteAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -208,10 +262,19 @@ func (newState *DeleteGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteGroupRequest) SyncEffectiveFieldsDuringRead(existingState DeleteGroupRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteGroupRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteGroupRequest in the Terraform plugin framework type +// system. func (a DeleteGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -229,10 +292,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -251,10 +323,19 @@ func (newState *DeleteServicePrincipalRequest) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServicePrincipalRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteServicePrincipalRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteServicePrincipalRequest in the Terraform plugin framework type +// system. func (a DeleteServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -275,10 +356,19 @@ func (newState *DeleteUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteUserRequest) SyncEffectiveFieldsDuringRead(existingState DeleteUserRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteUserRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteUserRequest in the Terraform plugin framework type +// system. func (a DeleteUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -301,10 +391,19 @@ func (newState *DeleteWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspaceAssignmentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWorkspaceAssignmentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWorkspaceAssignmentRequest in the Terraform plugin framework type +// system. func (a DeleteWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -323,10 +422,19 @@ func (newState *DeleteWorkspacePermissionAssignmentResponse) SyncEffectiveFields func (newState *DeleteWorkspacePermissionAssignmentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspacePermissionAssignmentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWorkspacePermissionAssignmentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWorkspacePermissionAssignmentResponse in the Terraform plugin framework type +// system. func (a DeleteWorkspacePermissionAssignmentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -345,10 +453,19 @@ func (newState *GetAccountGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetAccountGroupRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountGroupRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountGroupRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountGroupRequest in the Terraform plugin framework type +// system. func (a GetAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -369,10 +486,19 @@ func (newState *GetAccountServicePrincipalRequest) SyncEffectiveFieldsDuringCrea func (newState *GetAccountServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountServicePrincipalRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountServicePrincipalRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountServicePrincipalRequest in the Terraform plugin framework type +// system. func (a GetAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -414,10 +540,19 @@ func (newState *GetAccountUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetAccountUserRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountUserRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountUserRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountUserRequest in the Terraform plugin framework type +// system. func (a GetAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -445,10 +580,19 @@ func (newState *GetAssignableRolesForResourceRequest) SyncEffectiveFieldsDuringC func (newState *GetAssignableRolesForResourceRequest) SyncEffectiveFieldsDuringRead(existingState GetAssignableRolesForResourceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAssignableRolesForResourceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAssignableRolesForResourceRequest in the Terraform plugin framework type +// system. func (a GetAssignableRolesForResourceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -467,12 +611,21 @@ func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuring func (newState *GetAssignableRolesForResourceResponse) SyncEffectiveFieldsDuringRead(existingState GetAssignableRolesForResourceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAssignableRolesForResourceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "roles": reflect.TypeOf(Role{}), } } +// ToAttrType returns the representation of GetAssignableRolesForResourceResponse in the Terraform plugin framework type +// system. func (a GetAssignableRolesForResourceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -495,10 +648,19 @@ func (newState *GetGroupRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetGroupRequest) SyncEffectiveFieldsDuringRead(existingState GetGroupRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetGroupRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetGroupRequest in the Terraform plugin framework type +// system. func (a GetGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -518,12 +680,21 @@ func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringCr func (newState *GetPasswordPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPasswordPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPasswordPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(PasswordPermissionsDescription{}), } } +// ToAttrType returns the representation of GetPasswordPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetPasswordPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -548,10 +719,19 @@ func (newState *GetPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -572,12 +752,21 @@ func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(PermissionsDescription{}), } } +// ToAttrType returns the representation of GetPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -606,10 +795,19 @@ func (newState *GetPermissionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetPermissionRequest) SyncEffectiveFieldsDuringRead(existingState GetPermissionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPermissionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPermissionRequest in the Terraform plugin framework type +// system. func (a GetPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -640,10 +838,19 @@ func (newState *GetRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetRuleSetRequest) SyncEffectiveFieldsDuringRead(existingState GetRuleSetRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRuleSetRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRuleSetRequest in the Terraform plugin framework type +// system. func (a GetRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -665,10 +872,19 @@ func (newState *GetServicePrincipalRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetServicePrincipalRequest) SyncEffectiveFieldsDuringRead(existingState GetServicePrincipalRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetServicePrincipalRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetServicePrincipalRequest in the Terraform plugin framework type +// system. func (a GetServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -710,10 +926,19 @@ func (newState *GetUserRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetUserRequest) SyncEffectiveFieldsDuringRead(existingState GetUserRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetUserRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetUserRequest in the Terraform plugin framework type +// system. func (a GetUserRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -741,10 +966,19 @@ func (newState *GetWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceAssignmentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceAssignmentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWorkspaceAssignmentRequest in the Terraform plugin framework type +// system. func (a GetWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -766,12 +1000,21 @@ func (newState *GrantRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan GrantRul func (newState *GrantRule) SyncEffectiveFieldsDuringRead(existingState GrantRule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GrantRule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GrantRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "principals": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of GrantRule in the Terraform plugin framework type +// system. func (a GrantRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -813,6 +1056,13 @@ func (newState *Group) SyncEffectiveFieldsDuringCreateOrUpdate(plan Group) { func (newState *Group) SyncEffectiveFieldsDuringRead(existingState Group) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Group. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "entitlements": reflect.TypeOf(ComplexValue{}), @@ -824,6 +1074,8 @@ func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } +// ToAttrType returns the representation of Group in the Terraform plugin framework type +// system. func (a Group) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -882,10 +1134,19 @@ func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountGroupsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountGroupsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAccountGroupsRequest in the Terraform plugin framework type +// system. func (a ListAccountGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -930,10 +1191,19 @@ func (newState *ListAccountServicePrincipalsRequest) SyncEffectiveFieldsDuringCr func (newState *ListAccountServicePrincipalsRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountServicePrincipalsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountServicePrincipalsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAccountServicePrincipalsRequest in the Terraform plugin framework type +// system. func (a ListAccountServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -979,10 +1249,19 @@ func (newState *ListAccountUsersRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListAccountUsersRequest) SyncEffectiveFieldsDuringRead(existingState ListAccountUsersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAccountUsersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAccountUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAccountUsersRequest in the Terraform plugin framework type +// system. func (a ListAccountUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1027,10 +1306,19 @@ func (newState *ListGroupsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListGroupsRequest) SyncEffectiveFieldsDuringRead(existingState ListGroupsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListGroupsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListGroupsRequest in the Terraform plugin framework type +// system. func (a ListGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1065,6 +1353,13 @@ func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListGroupsResponse) SyncEffectiveFieldsDuringRead(existingState ListGroupsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListGroupsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(Group{}), @@ -1072,6 +1367,8 @@ func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of ListGroupsResponse in the Terraform plugin framework type +// system. func (a ListGroupsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1108,6 +1405,13 @@ func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListServicePrincipalResponse) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListServicePrincipalResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(ServicePrincipal{}), @@ -1115,6 +1419,8 @@ func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) } } +// ToAttrType returns the representation of ListServicePrincipalResponse in the Terraform plugin framework type +// system. func (a ListServicePrincipalResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1161,10 +1467,19 @@ func (newState *ListServicePrincipalsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ListServicePrincipalsRequest) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListServicePrincipalsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListServicePrincipalsRequest in the Terraform plugin framework type +// system. func (a ListServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1210,10 +1525,19 @@ func (newState *ListUsersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListUsersRequest) SyncEffectiveFieldsDuringRead(existingState ListUsersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListUsersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListUsersRequest in the Terraform plugin framework type +// system. func (a ListUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1248,6 +1572,13 @@ func (newState *ListUsersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListUsersResponse) SyncEffectiveFieldsDuringRead(existingState ListUsersResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListUsersResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Resources": reflect.TypeOf(User{}), @@ -1255,6 +1586,8 @@ func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of ListUsersResponse in the Terraform plugin framework type +// system. func (a ListUsersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1283,10 +1616,19 @@ func (newState *ListWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListWorkspaceAssignmentRequest) SyncEffectiveFieldsDuringRead(existingState ListWorkspaceAssignmentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListWorkspaceAssignmentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListWorkspaceAssignmentRequest in the Terraform plugin framework type +// system. func (a ListWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1313,10 +1655,19 @@ func (newState *MigratePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *MigratePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState MigratePermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MigratePermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MigratePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MigratePermissionsRequest in the Terraform plugin framework type +// system. func (a MigratePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1339,10 +1690,19 @@ func (newState *MigratePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *MigratePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState MigratePermissionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MigratePermissionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MigratePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MigratePermissionsResponse in the Terraform plugin framework type +// system. func (a MigratePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1364,10 +1724,19 @@ func (newState *Name) SyncEffectiveFieldsDuringCreateOrUpdate(plan Name) { func (newState *Name) SyncEffectiveFieldsDuringRead(existingState Name) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Name. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Name) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Name in the Terraform plugin framework type +// system. func (a Name) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1391,12 +1760,21 @@ func (newState *ObjectPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ObjectPermissions) SyncEffectiveFieldsDuringRead(existingState ObjectPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ObjectPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControlResponse{}), } } +// ToAttrType returns the representation of ObjectPermissions in the Terraform plugin framework type +// system. func (a ObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1425,6 +1803,13 @@ func (newState *PartialUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan Part func (newState *PartialUpdate) SyncEffectiveFieldsDuringRead(existingState PartialUpdate) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PartialUpdate. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "Operations": reflect.TypeOf(Patch{}), @@ -1432,6 +1817,8 @@ func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of PartialUpdate in the Terraform plugin framework type +// system. func (a PartialUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1463,10 +1850,19 @@ func (newState *PasswordAccessControlRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *PasswordAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState PasswordAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PasswordAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PasswordAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PasswordAccessControlRequest in the Terraform plugin framework type +// system. func (a PasswordAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1497,12 +1893,21 @@ func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringCreateOr func (newState *PasswordAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState PasswordAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PasswordAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PasswordAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(PasswordPermission{}), } } +// ToAttrType returns the representation of PasswordAccessControlResponse in the Terraform plugin framework type +// system. func (a PasswordAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1531,12 +1936,21 @@ func (newState *PasswordPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PasswordPermission) SyncEffectiveFieldsDuringRead(existingState PasswordPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PasswordPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PasswordPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of PasswordPermission in the Terraform plugin framework type +// system. func (a PasswordPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1563,12 +1977,21 @@ func (newState *PasswordPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PasswordPermissions) SyncEffectiveFieldsDuringRead(existingState PasswordPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PasswordPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PasswordPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PasswordAccessControlResponse{}), } } +// ToAttrType returns the representation of PasswordPermissions in the Terraform plugin framework type +// system. func (a PasswordPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1593,10 +2016,19 @@ func (newState *PasswordPermissionsDescription) SyncEffectiveFieldsDuringCreateO func (newState *PasswordPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PasswordPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PasswordPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PasswordPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PasswordPermissionsDescription in the Terraform plugin framework type +// system. func (a PasswordPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1616,12 +2048,21 @@ func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *PasswordPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PasswordPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PasswordPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PasswordPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PasswordAccessControlRequest{}), } } +// ToAttrType returns the representation of PasswordPermissionsRequest in the Terraform plugin framework type +// system. func (a PasswordPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1647,10 +2088,19 @@ func (newState *Patch) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patch) { func (newState *Patch) SyncEffectiveFieldsDuringRead(existingState Patch) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Patch. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Patch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Patch in the Terraform plugin framework type +// system. func (a Patch) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1670,10 +2120,19 @@ func (newState *PatchResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patc func (newState *PatchResponse) SyncEffectiveFieldsDuringRead(existingState PatchResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PatchResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PatchResponse in the Terraform plugin framework type +// system. func (a PatchResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1694,12 +2153,21 @@ func (newState *Permission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Permiss func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Permission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of Permission in the Terraform plugin framework type +// system. func (a Permission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1729,6 +2197,13 @@ func (newState *PermissionAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PermissionAssignment) SyncEffectiveFieldsDuringRead(existingState PermissionAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions": reflect.TypeOf(types.String{}), @@ -1736,6 +2211,8 @@ func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of PermissionAssignment in the Terraform plugin framework type +// system. func (a PermissionAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1761,12 +2238,21 @@ func (newState *PermissionAssignments) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *PermissionAssignments) SyncEffectiveFieldsDuringRead(existingState PermissionAssignments) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionAssignments. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionAssignments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_assignments": reflect.TypeOf(PermissionAssignment{}), } } +// ToAttrType returns the representation of PermissionAssignments in the Terraform plugin framework type +// system. func (a PermissionAssignments) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1790,10 +2276,19 @@ func (newState *PermissionOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan P func (newState *PermissionOutput) SyncEffectiveFieldsDuringRead(existingState PermissionOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PermissionOutput in the Terraform plugin framework type +// system. func (a PermissionOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1815,10 +2310,19 @@ func (newState *PermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PermissionsDescription in the Terraform plugin framework type +// system. func (a PermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1846,12 +2350,21 @@ func (newState *PermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControlRequest{}), } } +// ToAttrType returns the representation of PermissionsRequest in the Terraform plugin framework type +// system. func (a PermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1885,10 +2398,19 @@ func (newState *PrincipalOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pr func (newState *PrincipalOutput) SyncEffectiveFieldsDuringRead(existingState PrincipalOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PrincipalOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PrincipalOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PrincipalOutput in the Terraform plugin framework type +// system. func (a PrincipalOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1913,10 +2435,19 @@ func (newState *ResourceMeta) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resou func (newState *ResourceMeta) SyncEffectiveFieldsDuringRead(existingState ResourceMeta) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResourceMeta. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResourceMeta) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ResourceMeta in the Terraform plugin framework type +// system. func (a ResourceMeta) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1936,10 +2467,19 @@ func (newState *Role) SyncEffectiveFieldsDuringCreateOrUpdate(plan Role) { func (newState *Role) SyncEffectiveFieldsDuringRead(existingState Role) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Role. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Role) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Role in the Terraform plugin framework type +// system. func (a Role) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1963,12 +2503,21 @@ func (newState *RuleSetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ru func (newState *RuleSetResponse) SyncEffectiveFieldsDuringRead(existingState RuleSetResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RuleSetResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RuleSetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "grant_rules": reflect.TypeOf(GrantRule{}), } } +// ToAttrType returns the representation of RuleSetResponse in the Terraform plugin framework type +// system. func (a RuleSetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1998,12 +2547,21 @@ func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RuleSetUpdateRequest) SyncEffectiveFieldsDuringRead(existingState RuleSetUpdateRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RuleSetUpdateRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RuleSetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "grant_rules": reflect.TypeOf(GrantRule{}), } } +// ToAttrType returns the representation of RuleSetUpdateRequest in the Terraform plugin framework type +// system. func (a RuleSetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2046,6 +2604,13 @@ func (newState *ServicePrincipal) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServicePrincipal) SyncEffectiveFieldsDuringRead(existingState ServicePrincipal) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServicePrincipal. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "entitlements": reflect.TypeOf(ComplexValue{}), @@ -2055,6 +2620,8 @@ func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]r } } +// ToAttrType returns the representation of ServicePrincipal in the Terraform plugin framework type +// system. func (a ServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2088,10 +2655,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2111,12 +2687,21 @@ func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UpdateRuleSetRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRuleSetRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRuleSetRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rule_set": reflect.TypeOf(RuleSetUpdateRequest{}), } } +// ToAttrType returns the representation of UpdateRuleSetRequest in the Terraform plugin framework type +// system. func (a UpdateRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2148,12 +2733,21 @@ func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateWorkspaceAssignments) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceAssignments) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateWorkspaceAssignments. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateWorkspaceAssignments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpdateWorkspaceAssignments in the Terraform plugin framework type +// system. func (a UpdateWorkspaceAssignments) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2206,6 +2800,13 @@ func (newState *User) SyncEffectiveFieldsDuringCreateOrUpdate(plan User) { func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in User. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "emails": reflect.TypeOf(ComplexValue{}), @@ -2217,6 +2818,8 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } +// ToAttrType returns the representation of User in the Terraform plugin framework type +// system. func (a User) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2258,12 +2861,21 @@ func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WorkspacePermissions) SyncEffectiveFieldsDuringRead(existingState WorkspacePermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspacePermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspacePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions": reflect.TypeOf(PermissionOutput{}), } } +// ToAttrType returns the representation of WorkspacePermissions in the Terraform plugin framework type +// system. func (a WorkspacePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 4bfc963805..67a405aa2d 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -48,12 +48,21 @@ func (newState *BaseJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseJob) { func (newState *BaseJob) SyncEffectiveFieldsDuringRead(existingState BaseJob) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BaseJob. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BaseJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "settings": reflect.TypeOf(JobSettings{}), } } +// ToAttrType returns the representation of BaseJob in the Terraform plugin framework type +// system. func (a BaseJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -204,6 +213,13 @@ func (newState *BaseRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan BaseRun) { func (newState *BaseRun) SyncEffectiveFieldsDuringRead(existingState BaseRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BaseRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BaseRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_instance": reflect.TypeOf(ClusterInstance{}), @@ -221,6 +237,8 @@ func (a BaseRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of BaseRun in the Terraform plugin framework type +// system. func (a BaseRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -297,10 +315,19 @@ func (newState *CancelAllRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan Canc func (newState *CancelAllRuns) SyncEffectiveFieldsDuringRead(existingState CancelAllRuns) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelAllRuns. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelAllRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelAllRuns in the Terraform plugin framework type +// system. func (a CancelAllRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -319,10 +346,19 @@ func (newState *CancelAllRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CancelAllRunsResponse) SyncEffectiveFieldsDuringRead(existingState CancelAllRunsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelAllRunsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelAllRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelAllRunsResponse in the Terraform plugin framework type +// system. func (a CancelAllRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -340,10 +376,19 @@ func (newState *CancelRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan CancelRu func (newState *CancelRun) SyncEffectiveFieldsDuringRead(existingState CancelRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelRun in the Terraform plugin framework type +// system. func (a CancelRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -361,10 +406,19 @@ func (newState *CancelRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CancelRunResponse) SyncEffectiveFieldsDuringRead(existingState CancelRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelRunResponse in the Terraform plugin framework type +// system. func (a CancelRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -398,10 +452,19 @@ func (newState *ClusterInstance) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cl func (newState *ClusterInstance) SyncEffectiveFieldsDuringRead(existingState ClusterInstance) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterInstance. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterInstance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterInstance in the Terraform plugin framework type +// system. func (a ClusterInstance) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -434,6 +497,13 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cluste func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState ClusterSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "library": reflect.TypeOf(compute.Library{}), @@ -441,6 +511,8 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of ClusterSpec in the Terraform plugin framework type +// system. func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -482,10 +554,19 @@ func (newState *ConditionTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cond func (newState *ConditionTask) SyncEffectiveFieldsDuringRead(existingState ConditionTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ConditionTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ConditionTask in the Terraform plugin framework type +// system. func (a ConditionTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -508,10 +589,19 @@ func (newState *Continuous) SyncEffectiveFieldsDuringCreateOrUpdate(plan Continu func (newState *Continuous) SyncEffectiveFieldsDuringRead(existingState Continuous) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Continuous. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Continuous) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Continuous in the Terraform plugin framework type +// system. func (a Continuous) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -632,6 +722,13 @@ func (newState *CreateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateJo func (newState *CreateJob) SyncEffectiveFieldsDuringRead(existingState CreateJob) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateJob. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), @@ -654,6 +751,8 @@ func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of CreateJob in the Terraform plugin framework type +// system. func (a CreateJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -731,10 +830,19 @@ func (newState *CreateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateResponse) SyncEffectiveFieldsDuringRead(existingState CreateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// system. func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -764,10 +872,19 @@ func (newState *CronSchedule) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronS func (newState *CronSchedule) SyncEffectiveFieldsDuringRead(existingState CronSchedule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CronSchedule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CronSchedule in the Terraform plugin framework type +// system. func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -794,12 +911,21 @@ func (newState *DbtOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan DbtOutpu func (newState *DbtOutput) SyncEffectiveFieldsDuringRead(existingState DbtOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DbtOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DbtOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "artifacts_headers": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DbtOutput in the Terraform plugin framework type +// system. func (a DbtOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -854,12 +980,21 @@ func (newState *DbtTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan DbtTask) { func (newState *DbtTask) SyncEffectiveFieldsDuringRead(existingState DbtTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DbtTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DbtTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "commands": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DbtTask in the Terraform plugin framework type +// system. func (a DbtTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -887,10 +1022,19 @@ func (newState *DeleteJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteJo func (newState *DeleteJob) SyncEffectiveFieldsDuringRead(existingState DeleteJob) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteJob. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteJob in the Terraform plugin framework type +// system. func (a DeleteJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -908,10 +1052,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -929,10 +1082,19 @@ func (newState *DeleteRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteRu func (newState *DeleteRun) SyncEffectiveFieldsDuringRead(existingState DeleteRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRun in the Terraform plugin framework type +// system. func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -950,10 +1112,19 @@ func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRunResponse in the Terraform plugin framework type +// system. func (a DeleteRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -984,10 +1155,19 @@ func (newState *EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) S func (newState *EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnforcePolicyComplianceForJobResponseJobClusterSettingsChange. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EnforcePolicyComplianceForJobResponseJobClusterSettingsChange in the Terraform plugin framework type +// system. func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1012,10 +1192,19 @@ func (newState *EnforcePolicyComplianceRequest) SyncEffectiveFieldsDuringCreateO func (newState *EnforcePolicyComplianceRequest) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnforcePolicyComplianceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EnforcePolicyComplianceRequest in the Terraform plugin framework type +// system. func (a EnforcePolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1048,6 +1237,13 @@ func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringCreate func (newState *EnforcePolicyComplianceResponse) SyncEffectiveFieldsDuringRead(existingState EnforcePolicyComplianceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnforcePolicyComplianceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "job_cluster_changes": reflect.TypeOf(EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}), @@ -1055,6 +1251,8 @@ func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes(ctx context.Contex } } +// ToAttrType returns the representation of EnforcePolicyComplianceResponse in the Terraform plugin framework type +// system. func (a EnforcePolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1085,12 +1283,21 @@ func (newState *ExportRunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ex func (newState *ExportRunOutput) SyncEffectiveFieldsDuringRead(existingState ExportRunOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExportRunOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExportRunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "views": reflect.TypeOf(ViewItem{}), } } +// ToAttrType returns the representation of ExportRunOutput in the Terraform plugin framework type +// system. func (a ExportRunOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1115,10 +1322,19 @@ func (newState *ExportRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *ExportRunRequest) SyncEffectiveFieldsDuringRead(existingState ExportRunRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExportRunRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExportRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExportRunRequest in the Terraform plugin framework type +// system. func (a ExportRunRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1149,10 +1365,19 @@ func (newState *FileArrivalTriggerConfiguration) SyncEffectiveFieldsDuringCreate func (newState *FileArrivalTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState FileArrivalTriggerConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FileArrivalTriggerConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FileArrivalTriggerConfiguration in the Terraform plugin framework type +// system. func (a FileArrivalTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1176,6 +1401,13 @@ func (newState *ForEachStats) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEa func (newState *ForEachStats) SyncEffectiveFieldsDuringRead(existingState ForEachStats) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ForEachStats. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ForEachStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error_message_stats": reflect.TypeOf(ForEachTaskErrorMessageStats{}), @@ -1183,6 +1415,8 @@ func (a ForEachStats) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of ForEachStats in the Terraform plugin framework type +// system. func (a ForEachStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1214,12 +1448,21 @@ func (newState *ForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan ForEac func (newState *ForEachTask) SyncEffectiveFieldsDuringRead(existingState ForEachTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ForEachTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "task": reflect.TypeOf(Task{}), } } +// ToAttrType returns the representation of ForEachTask in the Terraform plugin framework type +// system. func (a ForEachTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1248,10 +1491,19 @@ func (newState *ForEachTaskErrorMessageStats) SyncEffectiveFieldsDuringCreateOrU func (newState *ForEachTaskErrorMessageStats) SyncEffectiveFieldsDuringRead(existingState ForEachTaskErrorMessageStats) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ForEachTaskErrorMessageStats. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ForEachTaskErrorMessageStats in the Terraform plugin framework type +// system. func (a ForEachTaskErrorMessageStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1284,10 +1536,19 @@ func (newState *ForEachTaskTaskRunStats) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ForEachTaskTaskRunStats) SyncEffectiveFieldsDuringRead(existingState ForEachTaskTaskRunStats) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ForEachTaskTaskRunStats. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ForEachTaskTaskRunStats) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ForEachTaskTaskRunStats in the Terraform plugin framework type +// system. func (a ForEachTaskTaskRunStats) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1313,10 +1574,19 @@ func (newState *GetJobPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetJobPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetJobPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetJobPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetJobPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1336,12 +1606,21 @@ func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringCreateO func (newState *GetJobPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetJobPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(JobPermissionsDescription{}), } } +// ToAttrType returns the representation of GetJobPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetJobPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1364,10 +1643,19 @@ func (newState *GetJobPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetJobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetJobPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetJobPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetJobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetJobPermissionsRequest in the Terraform plugin framework type +// system. func (a GetJobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1389,10 +1677,19 @@ func (newState *GetJobRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetJ func (newState *GetJobRequest) SyncEffectiveFieldsDuringRead(existingState GetJobRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetJobRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetJobRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetJobRequest in the Terraform plugin framework type +// system. func (a GetJobRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1413,10 +1710,19 @@ func (newState *GetPolicyComplianceRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *GetPolicyComplianceRequest) SyncEffectiveFieldsDuringRead(existingState GetPolicyComplianceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPolicyComplianceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPolicyComplianceRequest in the Terraform plugin framework type +// system. func (a GetPolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1445,12 +1751,21 @@ func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetPolicyComplianceResponse) SyncEffectiveFieldsDuringRead(existingState GetPolicyComplianceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPolicyComplianceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of GetPolicyComplianceResponse in the Terraform plugin framework type +// system. func (a GetPolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1474,10 +1789,19 @@ func (newState *GetRunOutputRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetRunOutputRequest) SyncEffectiveFieldsDuringRead(existingState GetRunOutputRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRunOutputRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRunOutputRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRunOutputRequest in the Terraform plugin framework type +// system. func (a GetRunOutputRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1506,10 +1830,19 @@ func (newState *GetRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetR func (newState *GetRunRequest) SyncEffectiveFieldsDuringRead(existingState GetRunRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRunRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRunRequest in the Terraform plugin framework type +// system. func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1536,10 +1869,19 @@ func (newState *GitSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSna func (newState *GitSnapshot) SyncEffectiveFieldsDuringRead(existingState GitSnapshot) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GitSnapshot. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GitSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GitSnapshot in the Terraform plugin framework type +// system. func (a GitSnapshot) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1587,6 +1929,13 @@ func (newState *GitSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan GitSourc func (newState *GitSource) SyncEffectiveFieldsDuringRead(existingState GitSource) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GitSource. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GitSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "git_snapshot": reflect.TypeOf(GitSnapshot{}), @@ -1594,6 +1943,8 @@ func (a GitSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of GitSource in the Terraform plugin framework type +// system. func (a GitSource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1648,12 +1999,21 @@ func (newState *Job) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job) { func (newState *Job) SyncEffectiveFieldsDuringRead(existingState Job) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Job. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Job) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "settings": reflect.TypeOf(JobSettings{}), } } +// ToAttrType returns the representation of Job in the Terraform plugin framework type +// system. func (a Job) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1686,10 +2046,19 @@ func (newState *JobAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *JobAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState JobAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobAccessControlRequest in the Terraform plugin framework type +// system. func (a JobAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1720,12 +2089,21 @@ func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *JobAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState JobAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(JobPermission{}), } } +// ToAttrType returns the representation of JobAccessControlResponse in the Terraform plugin framework type +// system. func (a JobAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1755,12 +2133,21 @@ func (newState *JobCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobClus func (newState *JobCluster) SyncEffectiveFieldsDuringRead(existingState JobCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), } } +// ToAttrType returns the representation of JobCluster in the Terraform plugin framework type +// system. func (a JobCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1791,12 +2178,21 @@ func (newState *JobCompliance) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobC func (newState *JobCompliance) SyncEffectiveFieldsDuringRead(existingState JobCompliance) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobCompliance. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobCompliance) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "violations": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of JobCompliance in the Terraform plugin framework type +// system. func (a JobCompliance) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1824,10 +2220,19 @@ func (newState *JobDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobD func (newState *JobDeployment) SyncEffectiveFieldsDuringRead(existingState JobDeployment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobDeployment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobDeployment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobDeployment in the Terraform plugin framework type +// system. func (a JobDeployment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1879,6 +2284,13 @@ func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *JobEmailNotifications) SyncEffectiveFieldsDuringRead(existingState JobEmailNotifications) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobEmailNotifications. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.String{}), @@ -1889,6 +2301,8 @@ func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of JobEmailNotifications in the Terraform plugin framework type +// system. func (a JobEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1927,12 +2341,21 @@ func (newState *JobEnvironment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobEnvironment) SyncEffectiveFieldsDuringRead(existingState JobEnvironment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobEnvironment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobEnvironment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "spec": reflect.TypeOf(compute.Environment{}), } } +// ToAttrType returns the representation of JobEnvironment in the Terraform plugin framework type +// system. func (a JobEnvironment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1959,10 +2382,19 @@ func (newState *JobNotificationSettings) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *JobNotificationSettings) SyncEffectiveFieldsDuringRead(existingState JobNotificationSettings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobNotificationSettings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobNotificationSettings in the Terraform plugin framework type +// system. func (a JobNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1987,10 +2419,19 @@ func (newState *JobParameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobPa func (newState *JobParameter) SyncEffectiveFieldsDuringRead(existingState JobParameter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobParameter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobParameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobParameter in the Terraform plugin framework type +// system. func (a JobParameter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2015,10 +2456,19 @@ func (newState *JobParameterDefinition) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *JobParameterDefinition) SyncEffectiveFieldsDuringRead(existingState JobParameterDefinition) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobParameterDefinition. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobParameterDefinition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobParameterDefinition in the Terraform plugin framework type +// system. func (a JobParameterDefinition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2042,12 +2492,21 @@ func (newState *JobPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobP func (newState *JobPermission) SyncEffectiveFieldsDuringRead(existingState JobPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of JobPermission in the Terraform plugin framework type +// system. func (a JobPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2074,12 +2533,21 @@ func (newState *JobPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobPermissions) SyncEffectiveFieldsDuringRead(existingState JobPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlResponse{}), } } +// ToAttrType returns the representation of JobPermissions in the Terraform plugin framework type +// system. func (a JobPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2104,10 +2572,19 @@ func (newState *JobPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpda func (newState *JobPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState JobPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobPermissionsDescription in the Terraform plugin framework type +// system. func (a JobPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2129,12 +2606,21 @@ func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState JobPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), } } +// ToAttrType returns the representation of JobPermissionsRequest in the Terraform plugin framework type +// system. func (a JobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2167,10 +2653,19 @@ func (newState *JobRunAs) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobRunAs) func (newState *JobRunAs) SyncEffectiveFieldsDuringRead(existingState JobRunAs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobRunAs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobRunAs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobRunAs in the Terraform plugin framework type +// system. func (a JobRunAs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2290,6 +2785,13 @@ func (newState *JobSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSet func (newState *JobSettings) SyncEffectiveFieldsDuringRead(existingState JobSettings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobSettings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "continuous": reflect.TypeOf(Continuous{}), @@ -2311,6 +2813,8 @@ func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of JobSettings in the Terraform plugin framework type +// system. func (a JobSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2398,10 +2902,19 @@ func (newState *JobSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSourc func (newState *JobSource) SyncEffectiveFieldsDuringRead(existingState JobSource) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobSource. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobSource in the Terraform plugin framework type +// system. func (a JobSource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2440,10 +2953,19 @@ func (newState *JobsHealthRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan Job func (newState *JobsHealthRule) SyncEffectiveFieldsDuringRead(existingState JobsHealthRule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobsHealthRule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobsHealthRule in the Terraform plugin framework type +// system. func (a JobsHealthRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2465,12 +2987,21 @@ func (newState *JobsHealthRules) SyncEffectiveFieldsDuringCreateOrUpdate(plan Jo func (newState *JobsHealthRules) SyncEffectiveFieldsDuringRead(existingState JobsHealthRules) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobsHealthRules. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobsHealthRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rules": reflect.TypeOf(JobsHealthRule{}), } } +// ToAttrType returns the representation of JobsHealthRules in the Terraform plugin framework type +// system. func (a JobsHealthRules) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2500,12 +3031,21 @@ func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringCre func (newState *ListJobComplianceForPolicyResponse) SyncEffectiveFieldsDuringRead(existingState ListJobComplianceForPolicyResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListJobComplianceForPolicyResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "jobs": reflect.TypeOf(JobCompliance{}), } } +// ToAttrType returns the representation of ListJobComplianceForPolicyResponse in the Terraform plugin framework type +// system. func (a ListJobComplianceForPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2537,10 +3077,19 @@ func (newState *ListJobComplianceRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListJobComplianceRequest) SyncEffectiveFieldsDuringRead(existingState ListJobComplianceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListJobComplianceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListJobComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListJobComplianceRequest in the Terraform plugin framework type +// system. func (a ListJobComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2575,10 +3124,19 @@ func (newState *ListJobsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListJobsRequest) SyncEffectiveFieldsDuringRead(existingState ListJobsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListJobsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListJobsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListJobsRequest in the Terraform plugin framework type +// system. func (a ListJobsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2612,12 +3170,21 @@ func (newState *ListJobsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListJobsResponse) SyncEffectiveFieldsDuringRead(existingState ListJobsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListJobsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListJobsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "jobs": reflect.TypeOf(BaseJob{}), } } +// ToAttrType returns the representation of ListJobsResponse in the Terraform plugin framework type +// system. func (a ListJobsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2677,10 +3244,19 @@ func (newState *ListRunsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListRunsRequest) SyncEffectiveFieldsDuringRead(existingState ListRunsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRunsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRunsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListRunsRequest in the Terraform plugin framework type +// system. func (a ListRunsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2719,12 +3295,21 @@ func (newState *ListRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListRunsResponse) SyncEffectiveFieldsDuringRead(existingState ListRunsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRunsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "runs": reflect.TypeOf(BaseRun{}), } } +// ToAttrType returns the representation of ListRunsResponse in the Terraform plugin framework type +// system. func (a ListRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2756,10 +3341,19 @@ func (newState *NotebookOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Not func (newState *NotebookOutput) SyncEffectiveFieldsDuringRead(existingState NotebookOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NotebookOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NotebookOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NotebookOutput in the Terraform plugin framework type +// system. func (a NotebookOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2816,12 +3410,21 @@ func (newState *NotebookTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Noteb func (newState *NotebookTask) SyncEffectiveFieldsDuringRead(existingState NotebookTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NotebookTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NotebookTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "base_parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of NotebookTask in the Terraform plugin framework type +// system. func (a NotebookTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2848,10 +3451,19 @@ func (newState *PeriodicTriggerConfiguration) SyncEffectiveFieldsDuringCreateOrU func (newState *PeriodicTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState PeriodicTriggerConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PeriodicTriggerConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PeriodicTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PeriodicTriggerConfiguration in the Terraform plugin framework type +// system. func (a PeriodicTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2872,10 +3484,19 @@ func (newState *PipelineParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pip func (newState *PipelineParams) SyncEffectiveFieldsDuringRead(existingState PipelineParams) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineParams. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelineParams in the Terraform plugin framework type +// system. func (a PipelineParams) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2897,10 +3518,19 @@ func (newState *PipelineTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipel func (newState *PipelineTask) SyncEffectiveFieldsDuringRead(existingState PipelineTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelineTask in the Terraform plugin framework type +// system. func (a PipelineTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2932,6 +3562,13 @@ func (newState *PythonWheelTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Py func (newState *PythonWheelTask) SyncEffectiveFieldsDuringRead(existingState PythonWheelTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PythonWheelTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "named_parameters": reflect.TypeOf(types.String{}), @@ -2939,6 +3576,8 @@ func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of PythonWheelTask in the Terraform plugin framework type +// system. func (a PythonWheelTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2973,10 +3612,19 @@ func (newState *QueueDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan Queue func (newState *QueueDetails) SyncEffectiveFieldsDuringRead(existingState QueueDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueueDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueueDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of QueueDetails in the Terraform plugin framework type +// system. func (a QueueDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2997,10 +3645,19 @@ func (newState *QueueSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan Queu func (newState *QueueSettings) SyncEffectiveFieldsDuringRead(existingState QueueSettings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueueSettings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueueSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of QueueSettings in the Terraform plugin framework type +// system. func (a QueueSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3035,6 +3692,13 @@ func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringRead(existingState RepairHistoryItem) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepairHistoryItem. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "state": reflect.TypeOf(RunState{}), @@ -3043,6 +3707,8 @@ func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of RepairHistoryItem in the Terraform plugin framework type +// system. func (a RepairHistoryItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3172,6 +3838,13 @@ func (newState *RepairRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepairRu func (newState *RepairRun) SyncEffectiveFieldsDuringRead(existingState RepairRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepairRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.String{}), @@ -3187,6 +3860,8 @@ func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of RepairRun in the Terraform plugin framework type +// system. func (a RepairRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3241,10 +3916,19 @@ func (newState *RepairRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RepairRunResponse) SyncEffectiveFieldsDuringRead(existingState RepairRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepairRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepairRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RepairRunResponse in the Terraform plugin framework type +// system. func (a RepairRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3270,12 +3954,21 @@ func (newState *ResetJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResetJob) func (newState *ResetJob) SyncEffectiveFieldsDuringRead(existingState ResetJob) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResetJob. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResetJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "new_settings": reflect.TypeOf(JobSettings{}), } } +// ToAttrType returns the representation of ResetJob in the Terraform plugin framework type +// system. func (a ResetJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3296,10 +3989,19 @@ func (newState *ResetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rese func (newState *ResetResponse) SyncEffectiveFieldsDuringRead(existingState ResetResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResetResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ResetResponse in the Terraform plugin framework type +// system. func (a ResetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3318,10 +4020,19 @@ func (newState *ResolvedConditionTaskValues) SyncEffectiveFieldsDuringCreateOrUp func (newState *ResolvedConditionTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedConditionTaskValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedConditionTaskValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedConditionTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ResolvedConditionTaskValues in the Terraform plugin framework type +// system. func (a ResolvedConditionTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3341,12 +4052,21 @@ func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ResolvedDbtTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedDbtTaskValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedDbtTaskValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedDbtTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "commands": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ResolvedDbtTaskValues in the Terraform plugin framework type +// system. func (a ResolvedDbtTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3367,12 +4087,21 @@ func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedNotebookTaskValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedNotebookTaskValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "base_parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ResolvedNotebookTaskValues in the Terraform plugin framework type +// system. func (a ResolvedNotebookTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3393,12 +4122,21 @@ func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ResolvedParamPairValues) SyncEffectiveFieldsDuringRead(existingState ResolvedParamPairValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedParamPairValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedParamPairValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ResolvedParamPairValues in the Terraform plugin framework type +// system. func (a ResolvedParamPairValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3421,6 +4159,13 @@ func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringCreateOr func (newState *ResolvedPythonWheelTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedPythonWheelTaskValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedPythonWheelTaskValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "named_parameters": reflect.TypeOf(types.String{}), @@ -3428,6 +4173,8 @@ func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) } } +// ToAttrType returns the representation of ResolvedPythonWheelTaskValues in the Terraform plugin framework type +// system. func (a ResolvedPythonWheelTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3453,6 +4200,13 @@ func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ResolvedRunJobTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedRunJobTaskValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedRunJobTaskValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "job_parameters": reflect.TypeOf(types.String{}), @@ -3460,6 +4214,8 @@ func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[ } } +// ToAttrType returns the representation of ResolvedRunJobTaskValues in the Terraform plugin framework type +// system. func (a ResolvedRunJobTaskValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3483,12 +4239,21 @@ func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ResolvedStringParamsValues) SyncEffectiveFieldsDuringRead(existingState ResolvedStringParamsValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedStringParamsValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedStringParamsValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ResolvedStringParamsValues in the Terraform plugin framework type +// system. func (a ResolvedStringParamsValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3527,6 +4292,13 @@ func (newState *ResolvedValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResolvedValues) SyncEffectiveFieldsDuringRead(existingState ResolvedValues) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResolvedValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition_task": reflect.TypeOf(ResolvedConditionTaskValues{}), @@ -3542,6 +4314,8 @@ func (a ResolvedValues) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of ResolvedValues in the Terraform plugin framework type +// system. func (a ResolvedValues) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3721,6 +4495,13 @@ func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Run. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_instance": reflect.TypeOf(ClusterInstance{}), @@ -3739,6 +4520,8 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } +// ToAttrType returns the representation of Run in the Terraform plugin framework type +// system. func (a Run) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3834,10 +4617,19 @@ func (newState *RunConditionTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RunConditionTask) SyncEffectiveFieldsDuringRead(existingState RunConditionTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunConditionTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunConditionTask in the Terraform plugin framework type +// system. func (a RunConditionTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3870,6 +4662,13 @@ func (newState *RunForEachTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run func (newState *RunForEachTask) SyncEffectiveFieldsDuringRead(existingState RunForEachTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunForEachTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "stats": reflect.TypeOf(ForEachStats{}), @@ -3877,6 +4676,8 @@ func (a RunForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of RunForEachTask in the Terraform plugin framework type +// system. func (a RunForEachTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3903,10 +4704,19 @@ func (newState *RunJobOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJo func (newState *RunJobOutput) SyncEffectiveFieldsDuringRead(existingState RunJobOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunJobOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunJobOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunJobOutput in the Terraform plugin framework type +// system. func (a RunJobOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4010,6 +4820,13 @@ func (newState *RunJobTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunJobT func (newState *RunJobTask) SyncEffectiveFieldsDuringRead(existingState RunJobTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunJobTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.String{}), @@ -4024,6 +4841,8 @@ func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of RunJobTask in the Terraform plugin framework type +// system. func (a RunJobTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4175,6 +4994,13 @@ func (newState *RunNow) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunNow) { func (newState *RunNow) SyncEffectiveFieldsDuringRead(existingState RunNow) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunNow. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.String{}), @@ -4191,6 +5017,8 @@ func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } +// ToAttrType returns the representation of RunNow in the Terraform plugin framework type +// system. func (a RunNow) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4248,10 +5076,19 @@ func (newState *RunNowResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run func (newState *RunNowResponse) SyncEffectiveFieldsDuringRead(existingState RunNowResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunNowResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunNowResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunNowResponse in the Terraform plugin framework type +// system. func (a RunNowResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4307,6 +5144,13 @@ func (newState *RunOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunOutpu func (newState *RunOutput) SyncEffectiveFieldsDuringRead(existingState RunOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_output": reflect.TypeOf(DbtOutput{}), @@ -4317,6 +5161,8 @@ func (a RunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of RunOutput in the Terraform plugin framework type +// system. func (a RunOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4435,6 +5281,13 @@ func (newState *RunParameters) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunP func (newState *RunParameters) SyncEffectiveFieldsDuringRead(existingState RunParameters) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunParameters. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dbt_commands": reflect.TypeOf(types.String{}), @@ -4448,6 +5301,8 @@ func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of RunParameters in the Terraform plugin framework type +// system. func (a RunParameters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4503,10 +5358,19 @@ func (newState *RunState) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunState) func (newState *RunState) SyncEffectiveFieldsDuringRead(existingState RunState) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunState. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunState in the Terraform plugin framework type +// system. func (a RunState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4536,6 +5400,13 @@ func (newState *RunStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunStatu func (newState *RunStatus) SyncEffectiveFieldsDuringRead(existingState RunStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "queue_details": reflect.TypeOf(QueueDetails{}), @@ -4543,6 +5414,8 @@ func (a RunStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of RunStatus in the Terraform plugin framework type +// system. func (a RunStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4731,6 +5604,13 @@ func (newState *RunTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTask) { func (newState *RunTask) SyncEffectiveFieldsDuringRead(existingState RunTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cluster_instance": reflect.TypeOf(ClusterInstance{}), @@ -4758,6 +5638,8 @@ func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of RunTask in the Terraform plugin framework type +// system. func (a RunTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4873,12 +5755,21 @@ func (newState *SparkJarTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spark func (newState *SparkJarTask) SyncEffectiveFieldsDuringRead(existingState SparkJarTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparkJarTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparkJarTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SparkJarTask in the Terraform plugin framework type +// system. func (a SparkJarTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4923,12 +5814,21 @@ func (newState *SparkPythonTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sp func (newState *SparkPythonTask) SyncEffectiveFieldsDuringRead(existingState SparkPythonTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparkPythonTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparkPythonTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SparkPythonTask in the Terraform plugin framework type +// system. func (a SparkPythonTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4957,12 +5857,21 @@ func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sp func (newState *SparkSubmitTask) SyncEffectiveFieldsDuringRead(existingState SparkSubmitTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparkSubmitTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparkSubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SparkSubmitTask in the Terraform plugin framework type +// system. func (a SparkSubmitTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4997,12 +5906,21 @@ func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlAlertOutput) SyncEffectiveFieldsDuringRead(existingState SqlAlertOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlAlertOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlAlertOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sql_statements": reflect.TypeOf(SqlStatementOutput{}), } } +// ToAttrType returns the representation of SqlAlertOutput in the Terraform plugin framework type +// system. func (a SqlAlertOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5030,12 +5948,21 @@ func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SqlDashboardOutput) SyncEffectiveFieldsDuringRead(existingState SqlDashboardOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlDashboardOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlDashboardOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "widgets": reflect.TypeOf(SqlDashboardWidgetOutput{}), } } +// ToAttrType returns the representation of SqlDashboardOutput in the Terraform plugin framework type +// system. func (a SqlDashboardOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5070,12 +5997,21 @@ func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *SqlDashboardWidgetOutput) SyncEffectiveFieldsDuringRead(existingState SqlDashboardWidgetOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlDashboardWidgetOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlDashboardWidgetOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error": reflect.TypeOf(SqlOutputError{}), } } +// ToAttrType returns the representation of SqlDashboardWidgetOutput in the Terraform plugin framework type +// system. func (a SqlDashboardWidgetOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5107,6 +6043,13 @@ func (newState *SqlOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlOutpu func (newState *SqlOutput) SyncEffectiveFieldsDuringRead(existingState SqlOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert_output": reflect.TypeOf(SqlAlertOutput{}), @@ -5115,6 +6058,8 @@ func (a SqlOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of SqlOutput in the Terraform plugin framework type +// system. func (a SqlOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5142,10 +6087,19 @@ func (newState *SqlOutputError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlOutputError) SyncEffectiveFieldsDuringRead(existingState SqlOutputError) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlOutputError. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlOutputError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SqlOutputError in the Terraform plugin framework type +// system. func (a SqlOutputError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5173,12 +6127,21 @@ func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sql func (newState *SqlQueryOutput) SyncEffectiveFieldsDuringRead(existingState SqlQueryOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlQueryOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlQueryOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sql_statements": reflect.TypeOf(SqlStatementOutput{}), } } +// ToAttrType returns the representation of SqlQueryOutput in the Terraform plugin framework type +// system. func (a SqlQueryOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5204,10 +6167,19 @@ func (newState *SqlStatementOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SqlStatementOutput) SyncEffectiveFieldsDuringRead(existingState SqlStatementOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlStatementOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlStatementOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SqlStatementOutput in the Terraform plugin framework type +// system. func (a SqlStatementOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5242,6 +6214,13 @@ func (newState *SqlTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTask) { func (newState *SqlTask) SyncEffectiveFieldsDuringRead(existingState SqlTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert": reflect.TypeOf(SqlTaskAlert{}), @@ -5252,6 +6231,8 @@ func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of SqlTask in the Terraform plugin framework type +// system. func (a SqlTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5290,12 +6271,21 @@ func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTa func (newState *SqlTaskAlert) SyncEffectiveFieldsDuringRead(existingState SqlTaskAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlTaskAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlTaskAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), } } +// ToAttrType returns the representation of SqlTaskAlert in the Terraform plugin framework type +// system. func (a SqlTaskAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5326,12 +6316,21 @@ func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringRead(existingState SqlTaskDashboard) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlTaskDashboard. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlTaskDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), } } +// ToAttrType returns the representation of SqlTaskDashboard in the Terraform plugin framework type +// system. func (a SqlTaskDashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5366,10 +6365,19 @@ func (newState *SqlTaskFile) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTas func (newState *SqlTaskFile) SyncEffectiveFieldsDuringRead(existingState SqlTaskFile) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlTaskFile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlTaskFile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SqlTaskFile in the Terraform plugin framework type +// system. func (a SqlTaskFile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5390,10 +6398,19 @@ func (newState *SqlTaskQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan SqlTa func (newState *SqlTaskQuery) SyncEffectiveFieldsDuringRead(existingState SqlTaskQuery) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlTaskQuery. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlTaskQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SqlTaskQuery in the Terraform plugin framework type +// system. func (a SqlTaskQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5420,10 +6437,19 @@ func (newState *SqlTaskSubscription) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SqlTaskSubscription) SyncEffectiveFieldsDuringRead(existingState SqlTaskSubscription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SqlTaskSubscription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SqlTaskSubscription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SqlTaskSubscription in the Terraform plugin framework type +// system. func (a SqlTaskSubscription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5501,6 +6527,13 @@ func (newState *SubmitRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitRu func (newState *SubmitRun) SyncEffectiveFieldsDuringRead(existingState SubmitRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SubmitRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SubmitRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), @@ -5516,6 +6549,8 @@ func (a SubmitRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of SubmitRun in the Terraform plugin framework type +// system. func (a SubmitRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5569,10 +6604,19 @@ func (newState *SubmitRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SubmitRunResponse) SyncEffectiveFieldsDuringRead(existingState SubmitRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SubmitRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SubmitRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SubmitRunResponse in the Terraform plugin framework type +// system. func (a SubmitRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5687,6 +6731,13 @@ func (newState *SubmitTask) SyncEffectiveFieldsDuringCreateOrUpdate(plan SubmitT func (newState *SubmitTask) SyncEffectiveFieldsDuringRead(existingState SubmitTask) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SubmitTask. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition_task": reflect.TypeOf(ConditionTask{}), @@ -5710,6 +6761,8 @@ func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of SubmitTask in the Terraform plugin framework type +// system. func (a SubmitTask) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5800,12 +6853,21 @@ func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringCreate func (newState *TableUpdateTriggerConfiguration) SyncEffectiveFieldsDuringRead(existingState TableUpdateTriggerConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableUpdateTriggerConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_names": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of TableUpdateTriggerConfiguration in the Terraform plugin framework type +// system. func (a TableUpdateTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5948,6 +7010,13 @@ func (newState *Task) SyncEffectiveFieldsDuringCreateOrUpdate(plan Task) { func (newState *Task) SyncEffectiveFieldsDuringRead(existingState Task) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Task. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition_task": reflect.TypeOf(ConditionTask{}), @@ -5971,6 +7040,8 @@ func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } +// ToAttrType returns the representation of Task in the Terraform plugin framework type +// system. func (a Task) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6057,10 +7128,19 @@ func (newState *TaskDependency) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tas func (newState *TaskDependency) SyncEffectiveFieldsDuringRead(existingState TaskDependency) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TaskDependency. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TaskDependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TaskDependency in the Terraform plugin framework type +// system. func (a TaskDependency) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6112,6 +7192,13 @@ func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *TaskEmailNotifications) SyncEffectiveFieldsDuringRead(existingState TaskEmailNotifications) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TaskEmailNotifications. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_duration_warning_threshold_exceeded": reflect.TypeOf(types.String{}), @@ -6122,6 +7209,8 @@ func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[st } } +// ToAttrType returns the representation of TaskEmailNotifications in the Terraform plugin framework type +// system. func (a TaskEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6164,10 +7253,19 @@ func (newState *TaskNotificationSettings) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *TaskNotificationSettings) SyncEffectiveFieldsDuringRead(existingState TaskNotificationSettings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TaskNotificationSettings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TaskNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TaskNotificationSettings in the Terraform plugin framework type +// system. func (a TaskNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6245,10 +7343,19 @@ func (newState *TerminationDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationDetails) SyncEffectiveFieldsDuringRead(existingState TerminationDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TerminationDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TerminationDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TerminationDetails in the Terraform plugin framework type +// system. func (a TerminationDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6271,10 +7378,19 @@ func (newState *TriggerInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Trigge func (newState *TriggerInfo) SyncEffectiveFieldsDuringRead(existingState TriggerInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TriggerInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TriggerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TriggerInfo in the Terraform plugin framework type +// system. func (a TriggerInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6302,6 +7418,13 @@ func (newState *TriggerSettings) SyncEffectiveFieldsDuringCreateOrUpdate(plan Tr func (newState *TriggerSettings) SyncEffectiveFieldsDuringRead(existingState TriggerSettings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TriggerSettings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TriggerSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_arrival": reflect.TypeOf(FileArrivalTriggerConfiguration{}), @@ -6311,6 +7434,8 @@ func (a TriggerSettings) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of TriggerSettings in the Terraform plugin framework type +// system. func (a TriggerSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6358,6 +7483,13 @@ func (newState *UpdateJob) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateJo func (newState *UpdateJob) SyncEffectiveFieldsDuringRead(existingState UpdateJob) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateJob. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fields_to_remove": reflect.TypeOf(types.String{}), @@ -6365,6 +7497,8 @@ func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of UpdateJob in the Terraform plugin framework type +// system. func (a UpdateJob) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6388,10 +7522,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -6415,10 +7558,19 @@ func (newState *ViewItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan ViewItem) func (newState *ViewItem) SyncEffectiveFieldsDuringRead(existingState ViewItem) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ViewItem. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ViewItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ViewItem in the Terraform plugin framework type +// system. func (a ViewItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6439,10 +7591,19 @@ func (newState *Webhook) SyncEffectiveFieldsDuringCreateOrUpdate(plan Webhook) { func (newState *Webhook) SyncEffectiveFieldsDuringRead(existingState Webhook) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Webhook. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Webhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Webhook in the Terraform plugin framework type +// system. func (a Webhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -6484,6 +7645,13 @@ func (newState *WebhookNotifications) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WebhookNotifications) SyncEffectiveFieldsDuringRead(existingState WebhookNotifications) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WebhookNotifications. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WebhookNotifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "on_duration_warning_threshold_exceeded": reflect.TypeOf(Webhook{}), @@ -6494,6 +7662,8 @@ func (a WebhookNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of WebhookNotifications in the Terraform plugin framework type +// system. func (a WebhookNotifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index ae2a6384fb..f2a1567633 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -31,10 +31,19 @@ func (newState *AddExchangeForListingRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *AddExchangeForListingRequest) SyncEffectiveFieldsDuringRead(existingState AddExchangeForListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AddExchangeForListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AddExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AddExchangeForListingRequest in the Terraform plugin framework type +// system. func (a AddExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -54,12 +63,21 @@ func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringCreateOr func (newState *AddExchangeForListingResponse) SyncEffectiveFieldsDuringRead(existingState AddExchangeForListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AddExchangeForListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AddExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange_for_listing": reflect.TypeOf(ExchangeListing{}), } } +// ToAttrType returns the representation of AddExchangeForListingResponse in the Terraform plugin framework type +// system. func (a AddExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -81,12 +99,21 @@ func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *BatchGetListingsRequest) SyncEffectiveFieldsDuringRead(existingState BatchGetListingsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BatchGetListingsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BatchGetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ids": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of BatchGetListingsRequest in the Terraform plugin framework type +// system. func (a BatchGetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -107,12 +134,21 @@ func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *BatchGetListingsResponse) SyncEffectiveFieldsDuringRead(existingState BatchGetListingsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BatchGetListingsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BatchGetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of BatchGetListingsResponse in the Terraform plugin framework type +// system. func (a BatchGetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -134,12 +170,21 @@ func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *BatchGetProvidersRequest) SyncEffectiveFieldsDuringRead(existingState BatchGetProvidersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BatchGetProvidersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BatchGetProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ids": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of BatchGetProvidersRequest in the Terraform plugin framework type +// system. func (a BatchGetProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -160,12 +205,21 @@ func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *BatchGetProvidersResponse) SyncEffectiveFieldsDuringRead(existingState BatchGetProvidersResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BatchGetProvidersResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BatchGetProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "providers": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of BatchGetProvidersResponse in the Terraform plugin framework type +// system. func (a BatchGetProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -186,10 +240,19 @@ func (newState *ConsumerTerms) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cons func (newState *ConsumerTerms) SyncEffectiveFieldsDuringRead(existingState ConsumerTerms) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ConsumerTerms. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ConsumerTerms) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ConsumerTerms in the Terraform plugin framework type +// system. func (a ConsumerTerms) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -216,10 +279,19 @@ func (newState *ContactInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Contac func (newState *ContactInfo) SyncEffectiveFieldsDuringRead(existingState ContactInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ContactInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ContactInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ContactInfo in the Terraform plugin framework type +// system. func (a ContactInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -241,12 +313,21 @@ func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *CreateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState CreateExchangeFilterRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExchangeFilterRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter": reflect.TypeOf(ExchangeFilter{}), } } +// ToAttrType returns the representation of CreateExchangeFilterRequest in the Terraform plugin framework type +// system. func (a CreateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -267,10 +348,19 @@ func (newState *CreateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *CreateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState CreateExchangeFilterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExchangeFilterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateExchangeFilterResponse in the Terraform plugin framework type +// system. func (a CreateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -289,12 +379,21 @@ func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateExchangeRequest) SyncEffectiveFieldsDuringRead(existingState CreateExchangeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExchangeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } } +// ToAttrType returns the representation of CreateExchangeRequest in the Terraform plugin framework type +// system. func (a CreateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -315,10 +414,19 @@ func (newState *CreateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateExchangeResponse) SyncEffectiveFieldsDuringRead(existingState CreateExchangeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExchangeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateExchangeResponse in the Terraform plugin framework type +// system. func (a CreateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -343,12 +451,21 @@ func (newState *CreateFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateFileRequest) SyncEffectiveFieldsDuringRead(existingState CreateFileRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateFileRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_parent": reflect.TypeOf(FileParent{}), } } +// ToAttrType returns the representation of CreateFileRequest in the Terraform plugin framework type +// system. func (a CreateFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -374,12 +491,21 @@ func (newState *CreateFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateFileResponse) SyncEffectiveFieldsDuringRead(existingState CreateFileResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateFileResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_info": reflect.TypeOf(FileInfo{}), } } +// ToAttrType returns the representation of CreateFileResponse in the Terraform plugin framework type +// system. func (a CreateFileResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -411,6 +537,13 @@ func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateInstallationRequest) SyncEffectiveFieldsDuringRead(existingState CreateInstallationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateInstallationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "accepted_consumer_terms": reflect.TypeOf(ConsumerTerms{}), @@ -418,6 +551,8 @@ func (a CreateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of CreateInstallationRequest in the Terraform plugin framework type +// system. func (a CreateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -445,12 +580,21 @@ func (newState *CreateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreateListingRequest) SyncEffectiveFieldsDuringRead(existingState CreateListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of CreateListingRequest in the Terraform plugin framework type +// system. func (a CreateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -471,10 +615,19 @@ func (newState *CreateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateListingResponse) SyncEffectiveFieldsDuringRead(existingState CreateListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateListingResponse in the Terraform plugin framework type +// system. func (a CreateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -510,12 +663,21 @@ func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *CreatePersonalizationRequest) SyncEffectiveFieldsDuringRead(existingState CreatePersonalizationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePersonalizationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "accepted_consumer_terms": reflect.TypeOf(ConsumerTerms{}), } } +// ToAttrType returns the representation of CreatePersonalizationRequest in the Terraform plugin framework type +// system. func (a CreatePersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -544,10 +706,19 @@ func (newState *CreatePersonalizationRequestResponse) SyncEffectiveFieldsDuringC func (newState *CreatePersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState CreatePersonalizationRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePersonalizationRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreatePersonalizationRequestResponse in the Terraform plugin framework type +// system. func (a CreatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -566,12 +737,21 @@ func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateProviderRequest) SyncEffectiveFieldsDuringRead(existingState CreateProviderRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateProviderRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of CreateProviderRequest in the Terraform plugin framework type +// system. func (a CreateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -592,10 +772,19 @@ func (newState *CreateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateProviderResponse) SyncEffectiveFieldsDuringRead(existingState CreateProviderResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateProviderResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateProviderResponse in the Terraform plugin framework type +// system. func (a CreateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -616,10 +805,19 @@ func (newState *DataRefreshInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Da func (newState *DataRefreshInfo) SyncEffectiveFieldsDuringRead(existingState DataRefreshInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DataRefreshInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DataRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DataRefreshInfo in the Terraform plugin framework type +// system. func (a DataRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -640,10 +838,19 @@ func (newState *DeleteExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *DeleteExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeFilterRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExchangeFilterRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExchangeFilterRequest in the Terraform plugin framework type +// system. func (a DeleteExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -661,10 +868,19 @@ func (newState *DeleteExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeFilterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExchangeFilterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExchangeFilterResponse in the Terraform plugin framework type +// system. func (a DeleteExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -682,10 +898,19 @@ func (newState *DeleteExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteExchangeRequest) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExchangeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExchangeRequest in the Terraform plugin framework type +// system. func (a DeleteExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -703,10 +928,19 @@ func (newState *DeleteExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteExchangeResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExchangeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExchangeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExchangeResponse in the Terraform plugin framework type +// system. func (a DeleteExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -724,10 +958,19 @@ func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileRequest) SyncEffectiveFieldsDuringRead(existingState DeleteFileRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteFileRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteFileRequest in the Terraform plugin framework type +// system. func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -745,10 +988,19 @@ func (newState *DeleteFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteFileResponse) SyncEffectiveFieldsDuringRead(existingState DeleteFileResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteFileResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteFileResponse in the Terraform plugin framework type +// system. func (a DeleteFileResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -768,10 +1020,19 @@ func (newState *DeleteInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteInstallationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteInstallationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteInstallationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteInstallationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteInstallationRequest in the Terraform plugin framework type +// system. func (a DeleteInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -790,10 +1051,19 @@ func (newState *DeleteInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteInstallationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteInstallationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteInstallationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteInstallationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteInstallationResponse in the Terraform plugin framework type +// system. func (a DeleteInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -811,10 +1081,19 @@ func (newState *DeleteListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteListingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteListingRequest in the Terraform plugin framework type +// system. func (a DeleteListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -832,10 +1111,19 @@ func (newState *DeleteListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteListingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteListingResponse in the Terraform plugin framework type +// system. func (a DeleteListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -853,10 +1141,19 @@ func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringRead(existingState DeleteProviderRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteProviderRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteProviderRequest in the Terraform plugin framework type +// system. func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -874,10 +1171,19 @@ func (newState *DeleteProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteProviderResponse) SyncEffectiveFieldsDuringRead(existingState DeleteProviderResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteProviderResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteProviderResponse in the Terraform plugin framework type +// system. func (a DeleteProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -910,6 +1216,13 @@ func (newState *Exchange) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exchange) func (newState *Exchange) SyncEffectiveFieldsDuringRead(existingState Exchange) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Exchange. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Exchange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filters": reflect.TypeOf(ExchangeFilter{}), @@ -917,6 +1230,8 @@ func (a Exchange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } +// ToAttrType returns the representation of Exchange in the Terraform plugin framework type +// system. func (a Exchange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -963,10 +1278,19 @@ func (newState *ExchangeFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exc func (newState *ExchangeFilter) SyncEffectiveFieldsDuringRead(existingState ExchangeFilter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExchangeFilter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExchangeFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExchangeFilter in the Terraform plugin framework type +// system. func (a ExchangeFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1005,10 +1329,19 @@ func (newState *ExchangeListing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ex func (newState *ExchangeListing) SyncEffectiveFieldsDuringRead(existingState ExchangeListing) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExchangeListing. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExchangeListing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExchangeListing in the Terraform plugin framework type +// system. func (a ExchangeListing) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1052,12 +1385,21 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FileInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_parent": reflect.TypeOf(FileParent{}), } } +// ToAttrType returns the representation of FileInfo in the Terraform plugin framework type +// system. func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1089,10 +1431,19 @@ func (newState *FileParent) SyncEffectiveFieldsDuringCreateOrUpdate(plan FilePar func (newState *FileParent) SyncEffectiveFieldsDuringRead(existingState FileParent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FileParent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FileParent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FileParent in the Terraform plugin framework type +// system. func (a FileParent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1113,10 +1464,19 @@ func (newState *GetExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetExchangeRequest) SyncEffectiveFieldsDuringRead(existingState GetExchangeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExchangeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetExchangeRequest in the Terraform plugin framework type +// system. func (a GetExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1135,12 +1495,21 @@ func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetExchangeResponse) SyncEffectiveFieldsDuringRead(existingState GetExchangeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExchangeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } } +// ToAttrType returns the representation of GetExchangeResponse in the Terraform plugin framework type +// system. func (a GetExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1162,10 +1531,19 @@ func (newState *GetFileRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetFileRequest) SyncEffectiveFieldsDuringRead(existingState GetFileRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetFileRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetFileRequest in the Terraform plugin framework type +// system. func (a GetFileRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1184,12 +1562,21 @@ func (newState *GetFileResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetFileResponse) SyncEffectiveFieldsDuringRead(existingState GetFileResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetFileResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_info": reflect.TypeOf(FileInfo{}), } } +// ToAttrType returns the representation of GetFileResponse in the Terraform plugin framework type +// system. func (a GetFileResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1211,10 +1598,19 @@ func (newState *GetLatestVersionProviderAnalyticsDashboardResponse) SyncEffectiv func (newState *GetLatestVersionProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionProviderAnalyticsDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetLatestVersionProviderAnalyticsDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetLatestVersionProviderAnalyticsDashboardResponse in the Terraform plugin framework type +// system. func (a GetLatestVersionProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1238,10 +1634,19 @@ func (newState *GetListingContentMetadataRequest) SyncEffectiveFieldsDuringCreat func (newState *GetListingContentMetadataRequest) SyncEffectiveFieldsDuringRead(existingState GetListingContentMetadataRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetListingContentMetadataRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetListingContentMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetListingContentMetadataRequest in the Terraform plugin framework type +// system. func (a GetListingContentMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1264,12 +1669,21 @@ func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringCrea func (newState *GetListingContentMetadataResponse) SyncEffectiveFieldsDuringRead(existingState GetListingContentMetadataResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetListingContentMetadataResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetListingContentMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "shared_data_objects": reflect.TypeOf(SharedDataObject{}), } } +// ToAttrType returns the representation of GetListingContentMetadataResponse in the Terraform plugin framework type +// system. func (a GetListingContentMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1292,10 +1706,19 @@ func (newState *GetListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingRequest) SyncEffectiveFieldsDuringRead(existingState GetListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetListingRequest in the Terraform plugin framework type +// system. func (a GetListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1314,12 +1737,21 @@ func (newState *GetListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingResponse) SyncEffectiveFieldsDuringRead(existingState GetListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of GetListingResponse in the Terraform plugin framework type +// system. func (a GetListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1343,10 +1775,19 @@ func (newState *GetListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetListingsRequest) SyncEffectiveFieldsDuringRead(existingState GetListingsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetListingsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetListingsRequest in the Terraform plugin framework type +// system. func (a GetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1368,12 +1809,21 @@ func (newState *GetListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetListingsResponse) SyncEffectiveFieldsDuringRead(existingState GetListingsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetListingsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of GetListingsResponse in the Terraform plugin framework type +// system. func (a GetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1396,10 +1846,19 @@ func (newState *GetPersonalizationRequestRequest) SyncEffectiveFieldsDuringCreat func (newState *GetPersonalizationRequestRequest) SyncEffectiveFieldsDuringRead(existingState GetPersonalizationRequestRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPersonalizationRequestRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPersonalizationRequestRequest in the Terraform plugin framework type +// system. func (a GetPersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1418,12 +1877,21 @@ func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringCrea func (newState *GetPersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState GetPersonalizationRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPersonalizationRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "personalization_requests": reflect.TypeOf(PersonalizationRequest{}), } } +// ToAttrType returns the representation of GetPersonalizationRequestResponse in the Terraform plugin framework type +// system. func (a GetPersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1445,10 +1913,19 @@ func (newState *GetProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetProviderRequest) SyncEffectiveFieldsDuringRead(existingState GetProviderRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetProviderRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetProviderRequest in the Terraform plugin framework type +// system. func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1467,12 +1944,21 @@ func (newState *GetProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetProviderResponse) SyncEffectiveFieldsDuringRead(existingState GetProviderResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetProviderResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of GetProviderResponse in the Terraform plugin framework type +// system. func (a GetProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1493,12 +1979,21 @@ func (newState *Installation) SyncEffectiveFieldsDuringCreateOrUpdate(plan Insta func (newState *Installation) SyncEffectiveFieldsDuringRead(existingState Installation) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Installation. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Installation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installation": reflect.TypeOf(InstallationDetail{}), } } +// ToAttrType returns the representation of Installation in the Terraform plugin framework type +// system. func (a Installation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1543,6 +2038,13 @@ func (newState *InstallationDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *InstallationDetail) SyncEffectiveFieldsDuringRead(existingState InstallationDetail) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InstallationDetail. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InstallationDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_detail": reflect.TypeOf(TokenDetail{}), @@ -1550,6 +2052,8 @@ func (a InstallationDetail) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of InstallationDetail in the Terraform plugin framework type +// system. func (a InstallationDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1587,10 +2091,19 @@ func (newState *ListAllInstallationsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListAllInstallationsRequest) SyncEffectiveFieldsDuringRead(existingState ListAllInstallationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAllInstallationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAllInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAllInstallationsRequest in the Terraform plugin framework type +// system. func (a ListAllInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1612,12 +2125,21 @@ func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *ListAllInstallationsResponse) SyncEffectiveFieldsDuringRead(existingState ListAllInstallationsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAllInstallationsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAllInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installations": reflect.TypeOf(InstallationDetail{}), } } +// ToAttrType returns the representation of ListAllInstallationsResponse in the Terraform plugin framework type +// system. func (a ListAllInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1642,10 +2164,19 @@ func (newState *ListAllPersonalizationRequestsRequest) SyncEffectiveFieldsDuring func (newState *ListAllPersonalizationRequestsRequest) SyncEffectiveFieldsDuringRead(existingState ListAllPersonalizationRequestsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAllPersonalizationRequestsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAllPersonalizationRequestsRequest in the Terraform plugin framework type +// system. func (a ListAllPersonalizationRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1667,12 +2198,21 @@ func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDurin func (newState *ListAllPersonalizationRequestsResponse) SyncEffectiveFieldsDuringRead(existingState ListAllPersonalizationRequestsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAllPersonalizationRequestsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "personalization_requests": reflect.TypeOf(PersonalizationRequest{}), } } +// ToAttrType returns the representation of ListAllPersonalizationRequestsResponse in the Terraform plugin framework type +// system. func (a ListAllPersonalizationRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1699,10 +2239,19 @@ func (newState *ListExchangeFiltersRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListExchangeFiltersRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangeFiltersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExchangeFiltersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExchangeFiltersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListExchangeFiltersRequest in the Terraform plugin framework type +// system. func (a ListExchangeFiltersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1725,12 +2274,21 @@ func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *ListExchangeFiltersResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangeFiltersResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExchangeFiltersResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExchangeFiltersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filters": reflect.TypeOf(ExchangeFilter{}), } } +// ToAttrType returns the representation of ListExchangeFiltersResponse in the Terraform plugin framework type +// system. func (a ListExchangeFiltersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1757,10 +2315,19 @@ func (newState *ListExchangesForListingRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListExchangesForListingRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangesForListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExchangesForListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExchangesForListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListExchangesForListingRequest in the Terraform plugin framework type +// system. func (a ListExchangesForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1783,12 +2350,21 @@ func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringCreate func (newState *ListExchangesForListingResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangesForListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExchangesForListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExchangesForListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange_listing": reflect.TypeOf(ExchangeListing{}), } } +// ToAttrType returns the representation of ListExchangesForListingResponse in the Terraform plugin framework type +// system. func (a ListExchangesForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1813,10 +2389,19 @@ func (newState *ListExchangesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListExchangesRequest) SyncEffectiveFieldsDuringRead(existingState ListExchangesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExchangesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExchangesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListExchangesRequest in the Terraform plugin framework type +// system. func (a ListExchangesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1838,12 +2423,21 @@ func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListExchangesResponse) SyncEffectiveFieldsDuringRead(existingState ListExchangesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExchangesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExchangesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchanges": reflect.TypeOf(Exchange{}), } } +// ToAttrType returns the representation of ListExchangesResponse in the Terraform plugin framework type +// system. func (a ListExchangesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1870,12 +2464,21 @@ func (newState *ListFilesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListFilesRequest) SyncEffectiveFieldsDuringRead(existingState ListFilesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListFilesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListFilesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_parent": reflect.TypeOf(FileParent{}), } } +// ToAttrType returns the representation of ListFilesRequest in the Terraform plugin framework type +// system. func (a ListFilesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1900,12 +2503,21 @@ func (newState *ListFilesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListFilesResponse) SyncEffectiveFieldsDuringRead(existingState ListFilesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListFilesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListFilesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file_infos": reflect.TypeOf(FileInfo{}), } } +// ToAttrType returns the representation of ListFilesResponse in the Terraform plugin framework type +// system. func (a ListFilesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1932,10 +2544,19 @@ func (newState *ListFulfillmentsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListFulfillmentsRequest) SyncEffectiveFieldsDuringRead(existingState ListFulfillmentsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListFulfillmentsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListFulfillmentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListFulfillmentsRequest in the Terraform plugin framework type +// system. func (a ListFulfillmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1958,12 +2579,21 @@ func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListFulfillmentsResponse) SyncEffectiveFieldsDuringRead(existingState ListFulfillmentsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListFulfillmentsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListFulfillmentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fulfillments": reflect.TypeOf(ListingFulfillment{}), } } +// ToAttrType returns the representation of ListFulfillmentsResponse in the Terraform plugin framework type +// system. func (a ListFulfillmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1990,10 +2620,19 @@ func (newState *ListInstallationsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListInstallationsRequest) SyncEffectiveFieldsDuringRead(existingState ListInstallationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListInstallationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListInstallationsRequest in the Terraform plugin framework type +// system. func (a ListInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2016,12 +2655,21 @@ func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListInstallationsResponse) SyncEffectiveFieldsDuringRead(existingState ListInstallationsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListInstallationsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installations": reflect.TypeOf(InstallationDetail{}), } } +// ToAttrType returns the representation of ListInstallationsResponse in the Terraform plugin framework type +// system. func (a ListInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2048,10 +2696,19 @@ func (newState *ListListingsForExchangeRequest) SyncEffectiveFieldsDuringCreateO func (newState *ListListingsForExchangeRequest) SyncEffectiveFieldsDuringRead(existingState ListListingsForExchangeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListListingsForExchangeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListListingsForExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListListingsForExchangeRequest in the Terraform plugin framework type +// system. func (a ListListingsForExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2074,12 +2731,21 @@ func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringCreate func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringRead(existingState ListListingsForExchangeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListListingsForExchangeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListListingsForExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange_listings": reflect.TypeOf(ExchangeListing{}), } } +// ToAttrType returns the representation of ListListingsForExchangeResponse in the Terraform plugin framework type +// system. func (a ListListingsForExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2119,6 +2785,13 @@ func (newState *ListListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListListingsRequest) SyncEffectiveFieldsDuringRead(existingState ListListingsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListListingsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assets": reflect.TypeOf(types.String{}), @@ -2128,6 +2801,8 @@ func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of ListListingsRequest in the Terraform plugin framework type +// system. func (a ListListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2164,12 +2839,21 @@ func (newState *ListListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListListingsResponse) SyncEffectiveFieldsDuringRead(existingState ListListingsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListListingsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of ListListingsResponse in the Terraform plugin framework type +// system. func (a ListListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2196,10 +2880,19 @@ func (newState *ListProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDurin func (newState *ListProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState ListProviderAnalyticsDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListProviderAnalyticsDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListProviderAnalyticsDashboardResponse in the Terraform plugin framework type +// system. func (a ListProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2225,10 +2918,19 @@ func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringRead(existingState ListProvidersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListProvidersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListProvidersRequest in the Terraform plugin framework type +// system. func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2251,12 +2953,21 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingState ListProvidersResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListProvidersResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "providers": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of ListProvidersResponse in the Terraform plugin framework type +// system. func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2282,6 +2993,13 @@ func (newState *Listing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing) { func (newState *Listing) SyncEffectiveFieldsDuringRead(existingState Listing) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Listing. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Listing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "detail": reflect.TypeOf(ListingDetail{}), @@ -2289,6 +3007,8 @@ func (a Listing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of Listing in the Terraform plugin framework type +// system. func (a Listing) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2360,6 +3080,13 @@ func (newState *ListingDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan List func (newState *ListingDetail) SyncEffectiveFieldsDuringRead(existingState ListingDetail) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListingDetail. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assets": reflect.TypeOf(types.String{}), @@ -2371,6 +3098,8 @@ func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of ListingDetail in the Terraform plugin framework type +// system. func (a ListingDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2427,6 +3156,13 @@ func (newState *ListingFulfillment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListingFulfillment) SyncEffectiveFieldsDuringRead(existingState ListingFulfillment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListingFulfillment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListingFulfillment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "repo_info": reflect.TypeOf(RepoInfo{}), @@ -2434,6 +3170,8 @@ func (a ListingFulfillment) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of ListingFulfillment in the Terraform plugin framework type +// system. func (a ListingFulfillment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2460,10 +3198,19 @@ func (newState *ListingSetting) SyncEffectiveFieldsDuringCreateOrUpdate(plan Lis func (newState *ListingSetting) SyncEffectiveFieldsDuringRead(existingState ListingSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListingSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListingSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListingSetting in the Terraform plugin framework type +// system. func (a ListingSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2520,6 +3267,13 @@ func (newState *ListingSummary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Lis func (newState *ListingSummary) SyncEffectiveFieldsDuringRead(existingState ListingSummary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListingSummary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "categories": reflect.TypeOf(types.String{}), @@ -2531,6 +3285,8 @@ func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of ListingSummary in the Terraform plugin framework type +// system. func (a ListingSummary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2583,12 +3339,21 @@ func (newState *ListingTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Listing func (newState *ListingTag) SyncEffectiveFieldsDuringRead(existingState ListingTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListingTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListingTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tag_values": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ListingTag in the Terraform plugin framework type +// system. func (a ListingTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2641,6 +3406,13 @@ func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalizationRequest) SyncEffectiveFieldsDuringRead(existingState PersonalizationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PersonalizationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "consumer_region": reflect.TypeOf(RegionInfo{}), @@ -2649,6 +3421,8 @@ func (a PersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[st } } +// ToAttrType returns the representation of PersonalizationRequest in the Terraform plugin framework type +// system. func (a PersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2688,10 +3462,19 @@ func (newState *ProviderAnalyticsDashboard) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ProviderAnalyticsDashboard) SyncEffectiveFieldsDuringRead(existingState ProviderAnalyticsDashboard) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ProviderAnalyticsDashboard. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ProviderAnalyticsDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ProviderAnalyticsDashboard in the Terraform plugin framework type +// system. func (a ProviderAnalyticsDashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2736,10 +3519,19 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Provi func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState ProviderInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ProviderInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ProviderInfo in the Terraform plugin framework type +// system. func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2773,10 +3565,19 @@ func (newState *RegionInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RegionI func (newState *RegionInfo) SyncEffectiveFieldsDuringRead(existingState RegionInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegionInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RegionInfo in the Terraform plugin framework type +// system. func (a RegionInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2797,10 +3598,19 @@ func (newState *RemoveExchangeForListingRequest) SyncEffectiveFieldsDuringCreate func (newState *RemoveExchangeForListingRequest) SyncEffectiveFieldsDuringRead(existingState RemoveExchangeForListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RemoveExchangeForListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RemoveExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RemoveExchangeForListingRequest in the Terraform plugin framework type +// system. func (a RemoveExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2818,10 +3628,19 @@ func (newState *RemoveExchangeForListingResponse) SyncEffectiveFieldsDuringCreat func (newState *RemoveExchangeForListingResponse) SyncEffectiveFieldsDuringRead(existingState RemoveExchangeForListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RemoveExchangeForListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RemoveExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RemoveExchangeForListingResponse in the Terraform plugin framework type +// system. func (a RemoveExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2839,10 +3658,19 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoInfo) func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RepoInfo in the Terraform plugin framework type +// system. func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2866,10 +3694,19 @@ func (newState *RepoInstallation) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RepoInstallation) SyncEffectiveFieldsDuringRead(existingState RepoInstallation) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoInstallation. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoInstallation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RepoInstallation in the Terraform plugin framework type +// system. func (a RepoInstallation) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2905,6 +3742,13 @@ func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *SearchListingsRequest) SyncEffectiveFieldsDuringRead(existingState SearchListingsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchListingsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "assets": reflect.TypeOf(types.String{}), @@ -2913,6 +3757,8 @@ func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of SearchListingsRequest in the Terraform plugin framework type +// system. func (a SearchListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2946,12 +3792,21 @@ func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SearchListingsResponse) SyncEffectiveFieldsDuringRead(existingState SearchListingsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchListingsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchListingsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listings": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of SearchListingsResponse in the Terraform plugin framework type +// system. func (a SearchListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2975,10 +3830,19 @@ func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInf func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ShareInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ShareInfo in the Terraform plugin framework type +// system. func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3002,10 +3866,19 @@ func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SharedDataObject. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SharedDataObject in the Terraform plugin framework type +// system. func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3033,10 +3906,19 @@ func (newState *TokenDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenD func (newState *TokenDetail) SyncEffectiveFieldsDuringRead(existingState TokenDetail) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenDetail. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TokenDetail in the Terraform plugin framework type +// system. func (a TokenDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3072,10 +3954,19 @@ func (newState *TokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenInf func (newState *TokenInfo) SyncEffectiveFieldsDuringRead(existingState TokenInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TokenInfo in the Terraform plugin framework type +// system. func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3102,12 +3993,21 @@ func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *UpdateExchangeFilterRequest) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeFilterRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExchangeFilterRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter": reflect.TypeOf(ExchangeFilter{}), } } +// ToAttrType returns the representation of UpdateExchangeFilterRequest in the Terraform plugin framework type +// system. func (a UpdateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3129,12 +4029,21 @@ func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *UpdateExchangeFilterResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeFilterResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExchangeFilterResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter": reflect.TypeOf(ExchangeFilter{}), } } +// ToAttrType returns the representation of UpdateExchangeFilterResponse in the Terraform plugin framework type +// system. func (a UpdateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3157,12 +4066,21 @@ func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateExchangeRequest) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExchangeRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } } +// ToAttrType returns the representation of UpdateExchangeRequest in the Terraform plugin framework type +// system. func (a UpdateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3184,12 +4102,21 @@ func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateExchangeResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExchangeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExchangeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exchange": reflect.TypeOf(Exchange{}), } } +// ToAttrType returns the representation of UpdateExchangeResponse in the Terraform plugin framework type +// system. func (a UpdateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3216,12 +4143,21 @@ func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateInstallationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateInstallationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateInstallationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installation": reflect.TypeOf(InstallationDetail{}), } } +// ToAttrType returns the representation of UpdateInstallationRequest in the Terraform plugin framework type +// system. func (a UpdateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3245,12 +4181,21 @@ func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateInstallationResponse) SyncEffectiveFieldsDuringRead(existingState UpdateInstallationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateInstallationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateInstallationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "installation": reflect.TypeOf(InstallationDetail{}), } } +// ToAttrType returns the representation of UpdateInstallationResponse in the Terraform plugin framework type +// system. func (a UpdateInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3273,12 +4218,21 @@ func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *UpdateListingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateListingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateListingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateListingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of UpdateListingRequest in the Terraform plugin framework type +// system. func (a UpdateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3300,12 +4254,21 @@ func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateListingResponse) SyncEffectiveFieldsDuringRead(existingState UpdateListingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateListingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateListingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "listing": reflect.TypeOf(Listing{}), } } +// ToAttrType returns the representation of UpdateListingResponse in the Terraform plugin framework type +// system. func (a UpdateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3334,12 +4297,21 @@ func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringCr func (newState *UpdatePersonalizationRequestRequest) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalizationRequestRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePersonalizationRequestRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "share": reflect.TypeOf(ShareInfo{}), } } +// ToAttrType returns the representation of UpdatePersonalizationRequestRequest in the Terraform plugin framework type +// system. func (a UpdatePersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3364,12 +4336,21 @@ func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringC func (newState *UpdatePersonalizationRequestResponse) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalizationRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePersonalizationRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "request": reflect.TypeOf(PersonalizationRequest{}), } } +// ToAttrType returns the representation of UpdatePersonalizationRequestResponse in the Terraform plugin framework type +// system. func (a UpdatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3395,10 +4376,19 @@ func (newState *UpdateProviderAnalyticsDashboardRequest) SyncEffectiveFieldsDuri func (newState *UpdateProviderAnalyticsDashboardRequest) SyncEffectiveFieldsDuringRead(existingState UpdateProviderAnalyticsDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateProviderAnalyticsDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateProviderAnalyticsDashboardRequest in the Terraform plugin framework type +// system. func (a UpdateProviderAnalyticsDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3423,10 +4413,19 @@ func (newState *UpdateProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDur func (newState *UpdateProviderAnalyticsDashboardResponse) SyncEffectiveFieldsDuringRead(existingState UpdateProviderAnalyticsDashboardResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateProviderAnalyticsDashboardResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateProviderAnalyticsDashboardResponse in the Terraform plugin framework type +// system. func (a UpdateProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3449,12 +4448,21 @@ func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateProviderRequest) SyncEffectiveFieldsDuringRead(existingState UpdateProviderRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateProviderRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of UpdateProviderRequest in the Terraform plugin framework type +// system. func (a UpdateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3476,12 +4484,21 @@ func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateProviderResponse) SyncEffectiveFieldsDuringRead(existingState UpdateProviderResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateProviderResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "provider": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of UpdateProviderResponse in the Terraform plugin framework type +// system. func (a UpdateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index eb0088eb01..488a09766d 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -81,10 +81,19 @@ func (newState *Activity) SyncEffectiveFieldsDuringCreateOrUpdate(plan Activity) func (newState *Activity) SyncEffectiveFieldsDuringRead(existingState Activity) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Activity. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Activity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Activity in the Terraform plugin framework type +// system. func (a Activity) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -129,10 +138,19 @@ func (newState *ApproveTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ApproveTransitionRequest) SyncEffectiveFieldsDuringRead(existingState ApproveTransitionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ApproveTransitionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ApproveTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ApproveTransitionRequest in the Terraform plugin framework type +// system. func (a ApproveTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -156,12 +174,21 @@ func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringCreat func (newState *ApproveTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState ApproveTransitionRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ApproveTransitionRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ApproveTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "activity": reflect.TypeOf(Activity{}), } } +// ToAttrType returns the representation of ApproveTransitionRequestResponse in the Terraform plugin framework type +// system. func (a ApproveTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -194,12 +221,21 @@ func (newState *CommentObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan Comm func (newState *CommentObject) SyncEffectiveFieldsDuringRead(existingState CommentObject) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CommentObject. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CommentObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "available_actions": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of CommentObject in the Terraform plugin framework type +// system. func (a CommentObject) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -230,10 +266,19 @@ func (newState *CreateComment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Crea func (newState *CreateComment) SyncEffectiveFieldsDuringRead(existingState CreateComment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateComment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateComment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateComment in the Terraform plugin framework type +// system. func (a CreateComment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -255,12 +300,21 @@ func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateCommentResponse) SyncEffectiveFieldsDuringRead(existingState CreateCommentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCommentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "comment": reflect.TypeOf(CommentObject{}), } } +// ToAttrType returns the representation of CreateCommentResponse in the Terraform plugin framework type +// system. func (a CreateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -291,12 +345,21 @@ func (newState *CreateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateExperiment) SyncEffectiveFieldsDuringRead(existingState CreateExperiment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExperiment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ExperimentTag{}), } } +// ToAttrType returns the representation of CreateExperiment in the Terraform plugin framework type +// system. func (a CreateExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -320,10 +383,19 @@ func (newState *CreateExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateExperimentResponse) SyncEffectiveFieldsDuringRead(existingState CreateExperimentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateExperimentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateExperimentResponse in the Terraform plugin framework type +// system. func (a CreateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -347,12 +419,21 @@ func (newState *CreateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateModelRequest) SyncEffectiveFieldsDuringRead(existingState CreateModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelTag{}), } } +// ToAttrType returns the representation of CreateModelRequest in the Terraform plugin framework type +// system. func (a CreateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -375,12 +456,21 @@ func (newState *CreateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateModelResponse) SyncEffectiveFieldsDuringRead(existingState CreateModelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateModelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_model": reflect.TypeOf(Model{}), } } +// ToAttrType returns the representation of CreateModelResponse in the Terraform plugin framework type +// system. func (a CreateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -414,12 +504,21 @@ func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState CreateModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelVersionTag{}), } } +// ToAttrType returns the representation of CreateModelVersionRequest in the Terraform plugin framework type +// system. func (a CreateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -446,12 +545,21 @@ func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState CreateModelVersionResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateModelVersionResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_version": reflect.TypeOf(ModelVersion{}), } } +// ToAttrType returns the representation of CreateModelVersionResponse in the Terraform plugin framework type +// system. func (a CreateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -522,6 +630,13 @@ func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState CreateRegistryWebhook) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRegistryWebhook. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.String{}), @@ -530,6 +645,8 @@ func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of CreateRegistryWebhook in the Terraform plugin framework type +// system. func (a CreateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -568,12 +685,21 @@ func (newState *CreateRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateRu func (newState *CreateRun) SyncEffectiveFieldsDuringRead(existingState CreateRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(RunTag{}), } } +// ToAttrType returns the representation of CreateRun in the Terraform plugin framework type +// system. func (a CreateRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -598,12 +724,21 @@ func (newState *CreateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRunResponse) SyncEffectiveFieldsDuringRead(existingState CreateRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "run": reflect.TypeOf(Run{}), } } +// ToAttrType returns the representation of CreateRunResponse in the Terraform plugin framework type +// system. func (a CreateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -639,10 +774,19 @@ func (newState *CreateTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateTransitionRequest) SyncEffectiveFieldsDuringRead(existingState CreateTransitionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateTransitionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateTransitionRequest in the Terraform plugin framework type +// system. func (a CreateTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -665,12 +809,21 @@ func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *CreateTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState CreateTransitionRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateTransitionRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "request": reflect.TypeOf(TransitionRequest{}), } } +// ToAttrType returns the representation of CreateTransitionRequestResponse in the Terraform plugin framework type +// system. func (a CreateTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -691,12 +844,21 @@ func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateWebhookResponse) SyncEffectiveFieldsDuringRead(existingState CreateWebhookResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateWebhookResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "webhook": reflect.TypeOf(RegistryWebhook{}), } } +// ToAttrType returns the representation of CreateWebhookResponse in the Terraform plugin framework type +// system. func (a CreateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -736,10 +898,19 @@ func (newState *Dataset) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dataset) { func (newState *Dataset) SyncEffectiveFieldsDuringRead(existingState Dataset) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Dataset. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Dataset) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Dataset in the Terraform plugin framework type +// system. func (a Dataset) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -767,6 +938,13 @@ func (newState *DatasetInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan Datas func (newState *DatasetInput) SyncEffectiveFieldsDuringRead(existingState DatasetInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DatasetInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DatasetInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataset": reflect.TypeOf(Dataset{}), @@ -774,6 +952,8 @@ func (a DatasetInput) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of DatasetInput in the Terraform plugin framework type +// system. func (a DatasetInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -798,10 +978,19 @@ func (newState *DeleteCommentRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteCommentRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCommentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCommentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCommentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCommentRequest in the Terraform plugin framework type +// system. func (a DeleteCommentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -819,10 +1008,19 @@ func (newState *DeleteCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteCommentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCommentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCommentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCommentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCommentResponse in the Terraform plugin framework type +// system. func (a DeleteCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -840,10 +1038,19 @@ func (newState *DeleteExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteExperiment) SyncEffectiveFieldsDuringRead(existingState DeleteExperiment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExperiment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExperiment in the Terraform plugin framework type +// system. func (a DeleteExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -861,10 +1068,19 @@ func (newState *DeleteExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteExperimentResponse) SyncEffectiveFieldsDuringRead(existingState DeleteExperimentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteExperimentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteExperimentResponse in the Terraform plugin framework type +// system. func (a DeleteExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -883,10 +1099,19 @@ func (newState *DeleteModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteModelRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelRequest in the Terraform plugin framework type +// system. func (a DeleteModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -904,10 +1129,19 @@ func (newState *DeleteModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteModelResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelResponse in the Terraform plugin framework type +// system. func (a DeleteModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -929,10 +1163,19 @@ func (newState *DeleteModelTagRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteModelTagRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelTagRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelTagRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelTagRequest in the Terraform plugin framework type +// system. func (a DeleteModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -951,10 +1194,19 @@ func (newState *DeleteModelTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteModelTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelTagResponse in the Terraform plugin framework type +// system. func (a DeleteModelTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -975,10 +1227,19 @@ func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type +// system. func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -997,10 +1258,19 @@ func (newState *DeleteModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelVersionResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelVersionResponse in the Terraform plugin framework type +// system. func (a DeleteModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1024,10 +1294,19 @@ func (newState *DeleteModelVersionTagRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteModelVersionTagRequest) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionTagRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelVersionTagRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelVersionTagRequest in the Terraform plugin framework type +// system. func (a DeleteModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1047,10 +1326,19 @@ func (newState *DeleteModelVersionTagResponse) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteModelVersionTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteModelVersionTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteModelVersionTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteModelVersionTagResponse in the Terraform plugin framework type +// system. func (a DeleteModelVersionTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1068,10 +1356,19 @@ func (newState *DeleteRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteRu func (newState *DeleteRun) SyncEffectiveFieldsDuringRead(existingState DeleteRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRun in the Terraform plugin framework type +// system. func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1089,10 +1386,19 @@ func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRunResponse in the Terraform plugin framework type +// system. func (a DeleteRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1117,10 +1423,19 @@ func (newState *DeleteRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteR func (newState *DeleteRuns) SyncEffectiveFieldsDuringRead(existingState DeleteRuns) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRuns. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRuns in the Terraform plugin framework type +// system. func (a DeleteRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1142,10 +1457,19 @@ func (newState *DeleteRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRunsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRunsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRunsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRunsResponse in the Terraform plugin framework type +// system. func (a DeleteRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1167,10 +1491,19 @@ func (newState *DeleteTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteTa func (newState *DeleteTag) SyncEffectiveFieldsDuringRead(existingState DeleteTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTag in the Terraform plugin framework type +// system. func (a DeleteTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1189,10 +1522,19 @@ func (newState *DeleteTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTagResponse) SyncEffectiveFieldsDuringRead(existingState DeleteTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTagResponse in the Terraform plugin framework type +// system. func (a DeleteTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1229,10 +1571,19 @@ func (newState *DeleteTransitionRequestRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteTransitionRequestRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTransitionRequestRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTransitionRequestRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTransitionRequestRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTransitionRequestRequest in the Terraform plugin framework type +// system. func (a DeleteTransitionRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1254,10 +1605,19 @@ func (newState *DeleteTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *DeleteTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState DeleteTransitionRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTransitionRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTransitionRequestResponse in the Terraform plugin framework type +// system. func (a DeleteTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1276,10 +1636,19 @@ func (newState *DeleteWebhookRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteWebhookRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWebhookRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWebhookRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWebhookRequest in the Terraform plugin framework type +// system. func (a DeleteWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1297,10 +1666,19 @@ func (newState *DeleteWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteWebhookResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWebhookResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWebhookResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWebhookResponse in the Terraform plugin framework type +// system. func (a DeleteWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1331,12 +1709,21 @@ func (newState *Experiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Experim func (newState *Experiment) SyncEffectiveFieldsDuringRead(existingState Experiment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Experiment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Experiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ExperimentTag{}), } } +// ToAttrType returns the representation of Experiment in the Terraform plugin framework type +// system. func (a Experiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1370,10 +1757,19 @@ func (newState *ExperimentAccessControlRequest) SyncEffectiveFieldsDuringCreateO func (newState *ExperimentAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ExperimentAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExperimentAccessControlRequest in the Terraform plugin framework type +// system. func (a ExperimentAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1404,12 +1800,21 @@ func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringCreate func (newState *ExperimentAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ExperimentAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ExperimentPermission{}), } } +// ToAttrType returns the representation of ExperimentAccessControlResponse in the Terraform plugin framework type +// system. func (a ExperimentAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1438,12 +1843,21 @@ func (newState *ExperimentPermission) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExperimentPermission) SyncEffectiveFieldsDuringRead(existingState ExperimentPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ExperimentPermission in the Terraform plugin framework type +// system. func (a ExperimentPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1470,12 +1884,21 @@ func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ExperimentAccessControlResponse{}), } } +// ToAttrType returns the representation of ExperimentPermissions in the Terraform plugin framework type +// system. func (a ExperimentPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1500,10 +1923,19 @@ func (newState *ExperimentPermissionsDescription) SyncEffectiveFieldsDuringCreat func (newState *ExperimentPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExperimentPermissionsDescription in the Terraform plugin framework type +// system. func (a ExperimentPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1525,12 +1957,21 @@ func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *ExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ExperimentPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ExperimentAccessControlRequest{}), } } +// ToAttrType returns the representation of ExperimentPermissionsRequest in the Terraform plugin framework type +// system. func (a ExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1555,10 +1996,19 @@ func (newState *ExperimentTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Expe func (newState *ExperimentTag) SyncEffectiveFieldsDuringRead(existingState ExperimentTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExperimentTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExperimentTag in the Terraform plugin framework type +// system. func (a ExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1583,10 +2033,19 @@ func (newState *FileInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileInfo) func (newState *FileInfo) SyncEffectiveFieldsDuringRead(existingState FileInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FileInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FileInfo in the Terraform plugin framework type +// system. func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1609,10 +2068,19 @@ func (newState *GetByNameRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetByNameRequest) SyncEffectiveFieldsDuringRead(existingState GetByNameRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetByNameRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetByNameRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetByNameRequest in the Terraform plugin framework type +// system. func (a GetByNameRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1633,10 +2101,19 @@ func (newState *GetExperimentPermissionLevelsRequest) SyncEffectiveFieldsDuringC func (newState *GetExperimentPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExperimentPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetExperimentPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetExperimentPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1656,12 +2133,21 @@ func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuring func (newState *GetExperimentPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExperimentPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ExperimentPermissionsDescription{}), } } +// ToAttrType returns the representation of GetExperimentPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetExperimentPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1684,10 +2170,19 @@ func (newState *GetExperimentPermissionsRequest) SyncEffectiveFieldsDuringCreate func (newState *GetExperimentPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExperimentPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetExperimentPermissionsRequest in the Terraform plugin framework type +// system. func (a GetExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1708,10 +2203,19 @@ func (newState *GetExperimentRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetExperimentRequest) SyncEffectiveFieldsDuringRead(existingState GetExperimentRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExperimentRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExperimentRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetExperimentRequest in the Terraform plugin framework type +// system. func (a GetExperimentRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1731,12 +2235,21 @@ func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetExperimentResponse) SyncEffectiveFieldsDuringRead(existingState GetExperimentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetExperimentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiment": reflect.TypeOf(Experiment{}), } } +// ToAttrType returns the representation of GetExperimentResponse in the Terraform plugin framework type +// system. func (a GetExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1770,10 +2283,19 @@ func (newState *GetHistoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetHistoryRequest) SyncEffectiveFieldsDuringRead(existingState GetHistoryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetHistoryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetHistoryRequest in the Terraform plugin framework type +// system. func (a GetHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1799,12 +2321,21 @@ func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetLatestVersionsRequest) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetLatestVersionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetLatestVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "stages": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of GetLatestVersionsRequest in the Terraform plugin framework type +// system. func (a GetLatestVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1829,12 +2360,21 @@ func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetLatestVersionsResponse) SyncEffectiveFieldsDuringRead(existingState GetLatestVersionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetLatestVersionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetLatestVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_versions": reflect.TypeOf(ModelVersion{}), } } +// ToAttrType returns the representation of GetLatestVersionsResponse in the Terraform plugin framework type +// system. func (a GetLatestVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1859,12 +2399,21 @@ func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetMetricHistoryResponse) SyncEffectiveFieldsDuringRead(existingState GetMetricHistoryResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetMetricHistoryResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetMetricHistoryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metrics": reflect.TypeOf(Metric{}), } } +// ToAttrType returns the representation of GetMetricHistoryResponse in the Terraform plugin framework type +// system. func (a GetMetricHistoryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1888,10 +2437,19 @@ func (newState *GetModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetModelRequest) SyncEffectiveFieldsDuringRead(existingState GetModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetModelRequest in the Terraform plugin framework type +// system. func (a GetModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1910,12 +2468,21 @@ func (newState *GetModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetModelResponse) SyncEffectiveFieldsDuringRead(existingState GetModelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_model_databricks": reflect.TypeOf(ModelDatabricks{}), } } +// ToAttrType returns the representation of GetModelResponse in the Terraform plugin framework type +// system. func (a GetModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1940,10 +2507,19 @@ func (newState *GetModelVersionDownloadUriRequest) SyncEffectiveFieldsDuringCrea func (newState *GetModelVersionDownloadUriRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionDownloadUriRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelVersionDownloadUriRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetModelVersionDownloadUriRequest in the Terraform plugin framework type +// system. func (a GetModelVersionDownloadUriRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1964,10 +2540,19 @@ func (newState *GetModelVersionDownloadUriResponse) SyncEffectiveFieldsDuringCre func (newState *GetModelVersionDownloadUriResponse) SyncEffectiveFieldsDuringRead(existingState GetModelVersionDownloadUriResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelVersionDownloadUriResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetModelVersionDownloadUriResponse in the Terraform plugin framework type +// system. func (a GetModelVersionDownloadUriResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1990,10 +2575,19 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState GetModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetModelVersionRequest in the Terraform plugin framework type +// system. func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2013,12 +2607,21 @@ func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState GetModelVersionResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelVersionResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_version": reflect.TypeOf(ModelVersion{}), } } +// ToAttrType returns the representation of GetModelVersionResponse in the Terraform plugin framework type +// system. func (a GetModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2041,10 +2644,19 @@ func (newState *GetRegisteredModelPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetRegisteredModelPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRegisteredModelPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRegisteredModelPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetRegisteredModelPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2064,12 +2676,21 @@ func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetRegisteredModelPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRegisteredModelPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(RegisteredModelPermissionsDescription{}), } } +// ToAttrType returns the representation of GetRegisteredModelPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetRegisteredModelPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2092,10 +2713,19 @@ func (newState *GetRegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetRegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetRegisteredModelPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRegisteredModelPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRegisteredModelPermissionsRequest in the Terraform plugin framework type +// system. func (a GetRegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2119,10 +2749,19 @@ func (newState *GetRunRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetR func (newState *GetRunRequest) SyncEffectiveFieldsDuringRead(existingState GetRunRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRunRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRunRequest in the Terraform plugin framework type +// system. func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2144,12 +2783,21 @@ func (newState *GetRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetRunResponse) SyncEffectiveFieldsDuringRead(existingState GetRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "run": reflect.TypeOf(Run{}), } } +// ToAttrType returns the representation of GetRunResponse in the Terraform plugin framework type +// system. func (a GetRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2188,10 +2836,19 @@ func (newState *HttpUrlSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan HttpUr func (newState *HttpUrlSpec) SyncEffectiveFieldsDuringRead(existingState HttpUrlSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in HttpUrlSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a HttpUrlSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of HttpUrlSpec in the Terraform plugin framework type +// system. func (a HttpUrlSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2222,10 +2879,19 @@ func (newState *HttpUrlSpecWithoutSecret) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *HttpUrlSpecWithoutSecret) SyncEffectiveFieldsDuringRead(existingState HttpUrlSpecWithoutSecret) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in HttpUrlSpecWithoutSecret. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of HttpUrlSpecWithoutSecret in the Terraform plugin framework type +// system. func (a HttpUrlSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2248,10 +2914,19 @@ func (newState *InputTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan InputTag) func (newState *InputTag) SyncEffectiveFieldsDuringRead(existingState InputTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in InputTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a InputTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of InputTag in the Terraform plugin framework type +// system. func (a InputTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2278,10 +2953,19 @@ func (newState *JobSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSpec) { func (newState *JobSpec) SyncEffectiveFieldsDuringRead(existingState JobSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobSpec in the Terraform plugin framework type +// system. func (a JobSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2307,10 +2991,19 @@ func (newState *JobSpecWithoutSecret) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *JobSpecWithoutSecret) SyncEffectiveFieldsDuringRead(existingState JobSpecWithoutSecret) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobSpecWithoutSecret. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a JobSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of JobSpecWithoutSecret in the Terraform plugin framework type +// system. func (a JobSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2345,10 +3038,19 @@ func (newState *ListArtifactsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListArtifactsRequest) SyncEffectiveFieldsDuringRead(existingState ListArtifactsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListArtifactsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListArtifactsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListArtifactsRequest in the Terraform plugin framework type +// system. func (a ListArtifactsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2375,12 +3077,21 @@ func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListArtifactsResponse) SyncEffectiveFieldsDuringRead(existingState ListArtifactsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListArtifactsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListArtifactsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "files": reflect.TypeOf(FileInfo{}), } } +// ToAttrType returns the representation of ListArtifactsResponse in the Terraform plugin framework type +// system. func (a ListArtifactsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2414,10 +3125,19 @@ func (newState *ListExperimentsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListExperimentsRequest) SyncEffectiveFieldsDuringRead(existingState ListExperimentsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExperimentsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExperimentsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListExperimentsRequest in the Terraform plugin framework type +// system. func (a ListExperimentsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2443,12 +3163,21 @@ func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListExperimentsResponse) SyncEffectiveFieldsDuringRead(existingState ListExperimentsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListExperimentsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiments": reflect.TypeOf(Experiment{}), } } +// ToAttrType returns the representation of ListExperimentsResponse in the Terraform plugin framework type +// system. func (a ListExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2474,10 +3203,19 @@ func (newState *ListModelsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListModelsRequest) SyncEffectiveFieldsDuringRead(existingState ListModelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListModelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListModelsRequest in the Terraform plugin framework type +// system. func (a ListModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2500,12 +3238,21 @@ func (newState *ListModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListModelsResponse) SyncEffectiveFieldsDuringRead(existingState ListModelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListModelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_models": reflect.TypeOf(Model{}), } } +// ToAttrType returns the representation of ListModelsResponse in the Terraform plugin framework type +// system. func (a ListModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2530,12 +3277,21 @@ func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListRegistryWebhooks) SyncEffectiveFieldsDuringRead(existingState ListRegistryWebhooks) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRegistryWebhooks. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRegistryWebhooks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "webhooks": reflect.TypeOf(RegistryWebhook{}), } } +// ToAttrType returns the representation of ListRegistryWebhooks in the Terraform plugin framework type +// system. func (a ListRegistryWebhooks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2561,10 +3317,19 @@ func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringRead(existingState ListTransitionRequestsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTransitionRequestsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTransitionRequestsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListTransitionRequestsRequest in the Terraform plugin framework type +// system. func (a ListTransitionRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2585,12 +3350,21 @@ func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringCreateO func (newState *ListTransitionRequestsResponse) SyncEffectiveFieldsDuringRead(existingState ListTransitionRequestsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTransitionRequestsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTransitionRequestsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "requests": reflect.TypeOf(Activity{}), } } +// ToAttrType returns the representation of ListTransitionRequestsResponse in the Terraform plugin framework type +// system. func (a ListTransitionRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2620,12 +3394,21 @@ func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListWebhooksRequest) SyncEffectiveFieldsDuringRead(existingState ListWebhooksRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListWebhooksRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListWebhooksRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ListWebhooksRequest in the Terraform plugin framework type +// system. func (a ListWebhooksRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2658,6 +3441,13 @@ func (newState *LogBatch) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogBatch) func (newState *LogBatch) SyncEffectiveFieldsDuringRead(existingState LogBatch) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogBatch. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogBatch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metrics": reflect.TypeOf(Metric{}), @@ -2666,6 +3456,8 @@ func (a LogBatch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } +// ToAttrType returns the representation of LogBatch in the Terraform plugin framework type +// system. func (a LogBatch) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2692,10 +3484,19 @@ func (newState *LogBatchResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogBatchResponse) SyncEffectiveFieldsDuringRead(existingState LogBatchResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogBatchResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogBatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogBatchResponse in the Terraform plugin framework type +// system. func (a LogBatchResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2715,12 +3516,21 @@ func (newState *LogInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogInput func (newState *LogInputs) SyncEffectiveFieldsDuringRead(existingState LogInputs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogInputs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "datasets": reflect.TypeOf(DatasetInput{}), } } +// ToAttrType returns the representation of LogInputs in the Terraform plugin framework type +// system. func (a LogInputs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2741,10 +3551,19 @@ func (newState *LogInputsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogInputsResponse) SyncEffectiveFieldsDuringRead(existingState LogInputsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogInputsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogInputsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogInputsResponse in the Terraform plugin framework type +// system. func (a LogInputsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2773,10 +3592,19 @@ func (newState *LogMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogMetri func (newState *LogMetric) SyncEffectiveFieldsDuringRead(existingState LogMetric) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogMetric. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogMetric in the Terraform plugin framework type +// system. func (a LogMetric) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2799,10 +3627,19 @@ func (newState *LogMetricResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *LogMetricResponse) SyncEffectiveFieldsDuringRead(existingState LogMetricResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogMetricResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogMetricResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogMetricResponse in the Terraform plugin framework type +// system. func (a LogMetricResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2822,10 +3659,19 @@ func (newState *LogModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogModel) func (newState *LogModel) SyncEffectiveFieldsDuringRead(existingState LogModel) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogModel. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogModel in the Terraform plugin framework type +// system. func (a LogModel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2844,10 +3690,19 @@ func (newState *LogModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogModelResponse) SyncEffectiveFieldsDuringRead(existingState LogModelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogModelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogModelResponse in the Terraform plugin framework type +// system. func (a LogModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2872,10 +3727,19 @@ func (newState *LogParam) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogParam) func (newState *LogParam) SyncEffectiveFieldsDuringRead(existingState LogParam) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogParam. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogParam) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogParam in the Terraform plugin framework type +// system. func (a LogParam) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2896,10 +3760,19 @@ func (newState *LogParamResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *LogParamResponse) SyncEffectiveFieldsDuringRead(existingState LogParamResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogParamResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogParamResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogParamResponse in the Terraform plugin framework type +// system. func (a LogParamResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2923,10 +3796,19 @@ func (newState *Metric) SyncEffectiveFieldsDuringCreateOrUpdate(plan Metric) { func (newState *Metric) SyncEffectiveFieldsDuringRead(existingState Metric) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Metric. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Metric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Metric in the Terraform plugin framework type +// system. func (a Metric) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2963,6 +3845,13 @@ func (newState *Model) SyncEffectiveFieldsDuringCreateOrUpdate(plan Model) { func (newState *Model) SyncEffectiveFieldsDuringRead(existingState Model) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Model. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Model) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_versions": reflect.TypeOf(ModelVersion{}), @@ -2970,6 +3859,8 @@ func (a Model) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } +// ToAttrType returns the representation of Model in the Terraform plugin framework type +// system. func (a Model) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3016,6 +3907,13 @@ func (newState *ModelDatabricks) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *ModelDatabricks) SyncEffectiveFieldsDuringRead(existingState ModelDatabricks) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelDatabricks. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_versions": reflect.TypeOf(ModelVersion{}), @@ -3023,6 +3921,8 @@ func (a ModelDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of ModelDatabricks in the Terraform plugin framework type +// system. func (a ModelDatabricks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3056,10 +3956,19 @@ func (newState *ModelTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan ModelTag) func (newState *ModelTag) SyncEffectiveFieldsDuringRead(existingState ModelTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ModelTag in the Terraform plugin framework type +// system. func (a ModelTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3107,12 +4016,21 @@ func (newState *ModelVersion) SyncEffectiveFieldsDuringCreateOrUpdate(plan Model func (newState *ModelVersion) SyncEffectiveFieldsDuringRead(existingState ModelVersion) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelVersion. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelVersion) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelVersionTag{}), } } +// ToAttrType returns the representation of ModelVersion in the Terraform plugin framework type +// system. func (a ModelVersion) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3192,12 +4110,21 @@ func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ModelVersionDatabricks) SyncEffectiveFieldsDuringRead(existingState ModelVersionDatabricks) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelVersionDatabricks. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelVersionDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(ModelVersionTag{}), } } +// ToAttrType returns the representation of ModelVersionDatabricks in the Terraform plugin framework type +// system. func (a ModelVersionDatabricks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3234,10 +4161,19 @@ func (newState *ModelVersionTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *ModelVersionTag) SyncEffectiveFieldsDuringRead(existingState ModelVersionTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelVersionTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelVersionTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ModelVersionTag in the Terraform plugin framework type +// system. func (a ModelVersionTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3260,10 +4196,19 @@ func (newState *Param) SyncEffectiveFieldsDuringCreateOrUpdate(plan Param) { func (newState *Param) SyncEffectiveFieldsDuringRead(existingState Param) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Param. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Param) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Param in the Terraform plugin framework type +// system. func (a Param) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3290,10 +4235,19 @@ func (newState *RegisteredModelAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *RegisteredModelAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RegisteredModelAccessControlRequest in the Terraform plugin framework type +// system. func (a RegisteredModelAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3324,12 +4278,21 @@ func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *RegisteredModelAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState RegisteredModelAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(RegisteredModelPermission{}), } } +// ToAttrType returns the representation of RegisteredModelAccessControlResponse in the Terraform plugin framework type +// system. func (a RegisteredModelAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3358,12 +4321,21 @@ func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RegisteredModelPermission) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of RegisteredModelPermission in the Terraform plugin framework type +// system. func (a RegisteredModelPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3390,12 +4362,21 @@ func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RegisteredModelPermissions) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RegisteredModelAccessControlResponse{}), } } +// ToAttrType returns the representation of RegisteredModelPermissions in the Terraform plugin framework type +// system. func (a RegisteredModelPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3420,10 +4401,19 @@ func (newState *RegisteredModelPermissionsDescription) SyncEffectiveFieldsDuring func (newState *RegisteredModelPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RegisteredModelPermissionsDescription in the Terraform plugin framework type +// system. func (a RegisteredModelPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3445,12 +4435,21 @@ func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *RegisteredModelPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState RegisteredModelPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegisteredModelPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RegisteredModelAccessControlRequest{}), } } +// ToAttrType returns the representation of RegisteredModelPermissionsRequest in the Terraform plugin framework type +// system. func (a RegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3528,6 +4527,13 @@ func (newState *RegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RegistryWebhook) SyncEffectiveFieldsDuringRead(existingState RegistryWebhook) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RegistryWebhook. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.String{}), @@ -3536,6 +4542,8 @@ func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of RegistryWebhook in the Terraform plugin framework type +// system. func (a RegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3583,10 +4591,19 @@ func (newState *RejectTransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *RejectTransitionRequest) SyncEffectiveFieldsDuringRead(existingState RejectTransitionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RejectTransitionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RejectTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RejectTransitionRequest in the Terraform plugin framework type +// system. func (a RejectTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3609,12 +4626,21 @@ func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringCreate func (newState *RejectTransitionRequestResponse) SyncEffectiveFieldsDuringRead(existingState RejectTransitionRequestResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RejectTransitionRequestResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RejectTransitionRequestResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "activity": reflect.TypeOf(Activity{}), } } +// ToAttrType returns the representation of RejectTransitionRequestResponse in the Terraform plugin framework type +// system. func (a RejectTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3638,10 +4664,19 @@ func (newState *RenameModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RenameModelRequest) SyncEffectiveFieldsDuringRead(existingState RenameModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RenameModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RenameModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RenameModelRequest in the Terraform plugin framework type +// system. func (a RenameModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3661,12 +4696,21 @@ func (newState *RenameModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RenameModelResponse) SyncEffectiveFieldsDuringRead(existingState RenameModelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RenameModelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RenameModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_model": reflect.TypeOf(Model{}), } } +// ToAttrType returns the representation of RenameModelResponse in the Terraform plugin framework type +// system. func (a RenameModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3688,10 +4732,19 @@ func (newState *RestoreExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RestoreExperiment) SyncEffectiveFieldsDuringRead(existingState RestoreExperiment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreExperiment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreExperiment in the Terraform plugin framework type +// system. func (a RestoreExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3709,10 +4762,19 @@ func (newState *RestoreExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RestoreExperimentResponse) SyncEffectiveFieldsDuringRead(existingState RestoreExperimentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreExperimentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreExperimentResponse in the Terraform plugin framework type +// system. func (a RestoreExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3730,10 +4792,19 @@ func (newState *RestoreRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan Restore func (newState *RestoreRun) SyncEffectiveFieldsDuringRead(existingState RestoreRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreRun in the Terraform plugin framework type +// system. func (a RestoreRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3751,10 +4822,19 @@ func (newState *RestoreRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RestoreRunResponse) SyncEffectiveFieldsDuringRead(existingState RestoreRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreRunResponse in the Terraform plugin framework type +// system. func (a RestoreRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3779,10 +4859,19 @@ func (newState *RestoreRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan Restor func (newState *RestoreRuns) SyncEffectiveFieldsDuringRead(existingState RestoreRuns) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreRuns. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreRuns in the Terraform plugin framework type +// system. func (a RestoreRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3804,10 +4893,19 @@ func (newState *RestoreRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RestoreRunsResponse) SyncEffectiveFieldsDuringRead(existingState RestoreRunsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreRunsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreRunsResponse in the Terraform plugin framework type +// system. func (a RestoreRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3831,6 +4929,13 @@ func (newState *Run) SyncEffectiveFieldsDuringCreateOrUpdate(plan Run) { func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Run. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data": reflect.TypeOf(RunData{}), @@ -3839,6 +4944,8 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } +// ToAttrType returns the representation of Run in the Terraform plugin framework type +// system. func (a Run) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3870,6 +4977,13 @@ func (newState *RunData) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunData) { func (newState *RunData) SyncEffectiveFieldsDuringRead(existingState RunData) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunData. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "metrics": reflect.TypeOf(Metric{}), @@ -3878,6 +4992,8 @@ func (a RunData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of RunData in the Terraform plugin framework type +// system. func (a RunData) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3927,10 +5043,19 @@ func (newState *RunInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInfo) { func (newState *RunInfo) SyncEffectiveFieldsDuringRead(existingState RunInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunInfo in the Terraform plugin framework type +// system. func (a RunInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3958,12 +5083,21 @@ func (newState *RunInputs) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunInput func (newState *RunInputs) SyncEffectiveFieldsDuringRead(existingState RunInputs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunInputs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataset_inputs": reflect.TypeOf(DatasetInput{}), } } +// ToAttrType returns the representation of RunInputs in the Terraform plugin framework type +// system. func (a RunInputs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3987,10 +5121,19 @@ func (newState *RunTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan RunTag) { func (newState *RunTag) SyncEffectiveFieldsDuringRead(existingState RunTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RunTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RunTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RunTag in the Terraform plugin framework type +// system. func (a RunTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4024,12 +5167,21 @@ func (newState *SearchExperiments) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SearchExperiments) SyncEffectiveFieldsDuringRead(existingState SearchExperiments) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchExperiments. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchExperiments) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SearchExperiments in the Terraform plugin framework type +// system. func (a SearchExperiments) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4058,12 +5210,21 @@ func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *SearchExperimentsResponse) SyncEffectiveFieldsDuringRead(existingState SearchExperimentsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchExperimentsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiments": reflect.TypeOf(Experiment{}), } } +// ToAttrType returns the representation of SearchExperimentsResponse in the Terraform plugin framework type +// system. func (a SearchExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4097,12 +5258,21 @@ func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SearchModelVersionsRequest) SyncEffectiveFieldsDuringRead(existingState SearchModelVersionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchModelVersionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SearchModelVersionsRequest in the Terraform plugin framework type +// system. func (a SearchModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4130,12 +5300,21 @@ func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *SearchModelVersionsResponse) SyncEffectiveFieldsDuringRead(existingState SearchModelVersionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchModelVersionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_versions": reflect.TypeOf(ModelVersion{}), } } +// ToAttrType returns the representation of SearchModelVersionsResponse in the Terraform plugin framework type +// system. func (a SearchModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4169,12 +5348,21 @@ func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SearchModelsRequest) SyncEffectiveFieldsDuringRead(existingState SearchModelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchModelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SearchModelsRequest in the Terraform plugin framework type +// system. func (a SearchModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4201,12 +5389,21 @@ func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SearchModelsResponse) SyncEffectiveFieldsDuringRead(existingState SearchModelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchModelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "registered_models": reflect.TypeOf(Model{}), } } +// ToAttrType returns the representation of SearchModelsResponse in the Terraform plugin framework type +// system. func (a SearchModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4256,6 +5453,13 @@ func (newState *SearchRuns) SyncEffectiveFieldsDuringCreateOrUpdate(plan SearchR func (newState *SearchRuns) SyncEffectiveFieldsDuringRead(existingState SearchRuns) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchRuns. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "experiment_ids": reflect.TypeOf(types.String{}), @@ -4263,6 +5467,8 @@ func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of SearchRuns in the Terraform plugin framework type +// system. func (a SearchRuns) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4293,12 +5499,21 @@ func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SearchRunsResponse) SyncEffectiveFieldsDuringRead(existingState SearchRunsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SearchRunsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SearchRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "runs": reflect.TypeOf(Run{}), } } +// ToAttrType returns the representation of SearchRunsResponse in the Terraform plugin framework type +// system. func (a SearchRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4328,10 +5543,19 @@ func (newState *SetExperimentTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SetExperimentTag) SyncEffectiveFieldsDuringRead(existingState SetExperimentTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetExperimentTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetExperimentTag in the Terraform plugin framework type +// system. func (a SetExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4351,10 +5575,19 @@ func (newState *SetExperimentTagResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *SetExperimentTagResponse) SyncEffectiveFieldsDuringRead(existingState SetExperimentTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetExperimentTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetExperimentTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetExperimentTagResponse in the Terraform plugin framework type +// system. func (a SetExperimentTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4381,10 +5614,19 @@ func (newState *SetModelTagRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SetModelTagRequest) SyncEffectiveFieldsDuringRead(existingState SetModelTagRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetModelTagRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetModelTagRequest in the Terraform plugin framework type +// system. func (a SetModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4404,10 +5646,19 @@ func (newState *SetModelTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SetModelTagResponse) SyncEffectiveFieldsDuringRead(existingState SetModelTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetModelTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetModelTagResponse in the Terraform plugin framework type +// system. func (a SetModelTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4436,10 +5687,19 @@ func (newState *SetModelVersionTagRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *SetModelVersionTagRequest) SyncEffectiveFieldsDuringRead(existingState SetModelVersionTagRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetModelVersionTagRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetModelVersionTagRequest in the Terraform plugin framework type +// system. func (a SetModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4460,10 +5720,19 @@ func (newState *SetModelVersionTagResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SetModelVersionTagResponse) SyncEffectiveFieldsDuringRead(existingState SetModelVersionTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetModelVersionTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetModelVersionTagResponse in the Terraform plugin framework type +// system. func (a SetModelVersionTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4491,10 +5760,19 @@ func (newState *SetTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetTag) { func (newState *SetTag) SyncEffectiveFieldsDuringRead(existingState SetTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetTag in the Terraform plugin framework type +// system. func (a SetTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4515,10 +5793,19 @@ func (newState *SetTagResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Set func (newState *SetTagResponse) SyncEffectiveFieldsDuringRead(existingState SetTagResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetTagResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetTagResponse in the Terraform plugin framework type +// system. func (a SetTagResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4539,10 +5826,19 @@ func (newState *TestRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TestRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhook) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TestRegistryWebhook. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TestRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TestRegistryWebhook in the Terraform plugin framework type +// system. func (a TestRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4567,10 +5863,19 @@ func (newState *TestRegistryWebhookRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *TestRegistryWebhookRequest) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhookRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TestRegistryWebhookRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TestRegistryWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TestRegistryWebhookRequest in the Terraform plugin framework type +// system. func (a TestRegistryWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4591,12 +5896,21 @@ func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringCreateOrUp func (newState *TestRegistryWebhookResponse) SyncEffectiveFieldsDuringRead(existingState TestRegistryWebhookResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TestRegistryWebhookResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TestRegistryWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "webhook": reflect.TypeOf(TestRegistryWebhook{}), } } +// ToAttrType returns the representation of TestRegistryWebhookResponse in the Terraform plugin framework type +// system. func (a TestRegistryWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4635,10 +5949,19 @@ func (newState *TransitionModelVersionStageDatabricks) SyncEffectiveFieldsDuring func (newState *TransitionModelVersionStageDatabricks) SyncEffectiveFieldsDuringRead(existingState TransitionModelVersionStageDatabricks) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TransitionModelVersionStageDatabricks. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TransitionModelVersionStageDatabricks in the Terraform plugin framework type +// system. func (a TransitionModelVersionStageDatabricks) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4680,12 +6003,21 @@ func (newState *TransitionRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TransitionRequest) SyncEffectiveFieldsDuringRead(existingState TransitionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TransitionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "available_actions": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of TransitionRequest in the Terraform plugin framework type +// system. func (a TransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4710,12 +6042,21 @@ func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *TransitionStageResponse) SyncEffectiveFieldsDuringRead(existingState TransitionStageResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TransitionStageResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TransitionStageResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "model_version": reflect.TypeOf(ModelVersionDatabricks{}), } } +// ToAttrType returns the representation of TransitionStageResponse in the Terraform plugin framework type +// system. func (a TransitionStageResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4739,10 +6080,19 @@ func (newState *UpdateComment) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upda func (newState *UpdateComment) SyncEffectiveFieldsDuringRead(existingState UpdateComment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateComment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateComment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateComment in the Terraform plugin framework type +// system. func (a UpdateComment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4763,12 +6113,21 @@ func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateCommentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateCommentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCommentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "comment": reflect.TypeOf(CommentObject{}), } } +// ToAttrType returns the representation of UpdateCommentResponse in the Terraform plugin framework type +// system. func (a UpdateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4793,10 +6152,19 @@ func (newState *UpdateExperiment) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpdateExperiment) SyncEffectiveFieldsDuringRead(existingState UpdateExperiment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExperiment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateExperiment in the Terraform plugin framework type +// system. func (a UpdateExperiment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4815,10 +6183,19 @@ func (newState *UpdateExperimentResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateExperimentResponse) SyncEffectiveFieldsDuringRead(existingState UpdateExperimentResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateExperimentResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateExperimentResponse in the Terraform plugin framework type +// system. func (a UpdateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4838,10 +6215,19 @@ func (newState *UpdateModelRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateModelRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateModelRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateModelRequest in the Terraform plugin framework type +// system. func (a UpdateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4860,10 +6246,19 @@ func (newState *UpdateModelResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *UpdateModelResponse) SyncEffectiveFieldsDuringRead(existingState UpdateModelResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateModelResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateModelResponse in the Terraform plugin framework type +// system. func (a UpdateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4885,10 +6280,19 @@ func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateModelVersionRequest) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateModelVersionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type +// system. func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4908,10 +6312,19 @@ func (newState *UpdateModelVersionResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateModelVersionResponse) SyncEffectiveFieldsDuringRead(existingState UpdateModelVersionResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateModelVersionResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateModelVersionResponse in the Terraform plugin framework type +// system. func (a UpdateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4978,6 +6391,13 @@ func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateRegistryWebhook) SyncEffectiveFieldsDuringRead(existingState UpdateRegistryWebhook) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRegistryWebhook. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(types.String{}), @@ -4986,6 +6406,8 @@ func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of UpdateRegistryWebhook in the Terraform plugin framework type +// system. func (a UpdateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5023,10 +6445,19 @@ func (newState *UpdateRun) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateRu func (newState *UpdateRun) SyncEffectiveFieldsDuringRead(existingState UpdateRun) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRun. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateRun in the Terraform plugin framework type +// system. func (a UpdateRun) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5049,12 +6480,21 @@ func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRunResponse) SyncEffectiveFieldsDuringRead(existingState UpdateRunResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRunResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "run_info": reflect.TypeOf(RunInfo{}), } } +// ToAttrType returns the representation of UpdateRunResponse in the Terraform plugin framework type +// system. func (a UpdateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5074,10 +6514,19 @@ func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *UpdateWebhookResponse) SyncEffectiveFieldsDuringRead(existingState UpdateWebhookResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateWebhookResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateWebhookResponse in the Terraform plugin framework type +// system. func (a UpdateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 145e13cada..18c8733754 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -40,6 +40,13 @@ func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existingState CreateCustomAppIntegration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCustomAppIntegration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.String{}), @@ -48,6 +55,8 @@ func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } +// ToAttrType returns the representation of CreateCustomAppIntegration in the Terraform plugin framework type +// system. func (a CreateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -82,10 +91,19 @@ func (newState *CreateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *CreateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState CreateCustomAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCustomAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateCustomAppIntegrationOutput in the Terraform plugin framework type +// system. func (a CreateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -110,12 +128,21 @@ func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOr func (newState *CreatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(existingState CreatePublishedAppIntegration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePublishedAppIntegration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } +// ToAttrType returns the representation of CreatePublishedAppIntegration in the Terraform plugin framework type +// system. func (a CreatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -138,10 +165,19 @@ func (newState *CreatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *CreatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState CreatePublishedAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePublishedAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreatePublishedAppIntegrationOutput in the Terraform plugin framework type +// system. func (a CreatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -162,10 +198,19 @@ func (newState *CreateServicePrincipalSecretRequest) SyncEffectiveFieldsDuringCr func (newState *CreateServicePrincipalSecretRequest) SyncEffectiveFieldsDuringRead(existingState CreateServicePrincipalSecretRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateServicePrincipalSecretRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateServicePrincipalSecretRequest in the Terraform plugin framework type +// system. func (a CreateServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -195,10 +240,19 @@ func (newState *CreateServicePrincipalSecretResponse) SyncEffectiveFieldsDuringC func (newState *CreateServicePrincipalSecretResponse) SyncEffectiveFieldsDuringRead(existingState CreateServicePrincipalSecretResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateServicePrincipalSecretResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateServicePrincipalSecretResponse in the Terraform plugin framework type +// system. func (a CreateServicePrincipalSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -225,10 +279,19 @@ func (newState *DataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Data func (newState *DataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState DataPlaneInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DataPlaneInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DataPlaneInfo in the Terraform plugin framework type +// system. func (a DataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -247,10 +310,19 @@ func (newState *DeleteCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *DeleteCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState DeleteCustomAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCustomAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCustomAppIntegrationOutput in the Terraform plugin framework type +// system. func (a DeleteCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -268,10 +340,19 @@ func (newState *DeleteCustomAppIntegrationRequest) SyncEffectiveFieldsDuringCrea func (newState *DeleteCustomAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCustomAppIntegrationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCustomAppIntegrationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCustomAppIntegrationRequest in the Terraform plugin framework type +// system. func (a DeleteCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -289,10 +370,19 @@ func (newState *DeletePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *DeletePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState DeletePublishedAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePublishedAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePublishedAppIntegrationOutput in the Terraform plugin framework type +// system. func (a DeletePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -310,10 +400,19 @@ func (newState *DeletePublishedAppIntegrationRequest) SyncEffectiveFieldsDuringC func (newState *DeletePublishedAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState DeletePublishedAppIntegrationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePublishedAppIntegrationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePublishedAppIntegrationRequest in the Terraform plugin framework type +// system. func (a DeletePublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -331,10 +430,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -355,10 +463,19 @@ func (newState *DeleteServicePrincipalSecretRequest) SyncEffectiveFieldsDuringCr func (newState *DeleteServicePrincipalSecretRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServicePrincipalSecretRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteServicePrincipalSecretRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteServicePrincipalSecretRequest in the Terraform plugin framework type +// system. func (a DeleteServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -398,6 +515,13 @@ func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreateOr func (newState *GetCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCustomAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.String{}), @@ -406,6 +530,8 @@ func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) } } +// ToAttrType returns the representation of GetCustomAppIntegrationOutput in the Terraform plugin framework type +// system. func (a GetCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -441,10 +567,19 @@ func (newState *GetCustomAppIntegrationRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetCustomAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCustomAppIntegrationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCustomAppIntegrationRequest in the Terraform plugin framework type +// system. func (a GetCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -466,12 +601,21 @@ func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringCreateO func (newState *GetCustomAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(existingState GetCustomAppIntegrationsOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCustomAppIntegrationsOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(GetCustomAppIntegrationOutput{}), } } +// ToAttrType returns the representation of GetCustomAppIntegrationsOutput in the Terraform plugin framework type +// system. func (a GetCustomAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -504,12 +648,21 @@ func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *GetPublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPublishedAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } +// ToAttrType returns the representation of GetPublishedAppIntegrationOutput in the Terraform plugin framework type +// system. func (a GetPublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -536,10 +689,19 @@ func (newState *GetPublishedAppIntegrationRequest) SyncEffectiveFieldsDuringCrea func (newState *GetPublishedAppIntegrationRequest) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPublishedAppIntegrationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPublishedAppIntegrationRequest in the Terraform plugin framework type +// system. func (a GetPublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -561,12 +723,21 @@ func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringCrea func (newState *GetPublishedAppIntegrationsOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppIntegrationsOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPublishedAppIntegrationsOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(GetPublishedAppIntegrationOutput{}), } } +// ToAttrType returns the representation of GetPublishedAppIntegrationsOutput in the Terraform plugin framework type +// system. func (a GetPublishedAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -592,12 +763,21 @@ func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPublishedAppsOutput) SyncEffectiveFieldsDuringRead(existingState GetPublishedAppsOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPublishedAppsOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPublishedAppsOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "apps": reflect.TypeOf(PublishedAppOutput{}), } } +// ToAttrType returns the representation of GetPublishedAppsOutput in the Terraform plugin framework type +// system. func (a GetPublishedAppsOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -624,10 +804,19 @@ func (newState *ListCustomAppIntegrationsRequest) SyncEffectiveFieldsDuringCreat func (newState *ListCustomAppIntegrationsRequest) SyncEffectiveFieldsDuringRead(existingState ListCustomAppIntegrationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListCustomAppIntegrationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListCustomAppIntegrationsRequest in the Terraform plugin framework type +// system. func (a ListCustomAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -652,10 +841,19 @@ func (newState *ListOAuthPublishedAppsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *ListOAuthPublishedAppsRequest) SyncEffectiveFieldsDuringRead(existingState ListOAuthPublishedAppsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListOAuthPublishedAppsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListOAuthPublishedAppsRequest in the Terraform plugin framework type +// system. func (a ListOAuthPublishedAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -678,10 +876,19 @@ func (newState *ListPublishedAppIntegrationsRequest) SyncEffectiveFieldsDuringCr func (newState *ListPublishedAppIntegrationsRequest) SyncEffectiveFieldsDuringRead(existingState ListPublishedAppIntegrationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPublishedAppIntegrationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListPublishedAppIntegrationsRequest in the Terraform plugin framework type +// system. func (a ListPublishedAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -713,10 +920,19 @@ func (newState *ListServicePrincipalSecretsRequest) SyncEffectiveFieldsDuringCre func (newState *ListServicePrincipalSecretsRequest) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalSecretsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListServicePrincipalSecretsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListServicePrincipalSecretsRequest in the Terraform plugin framework type +// system. func (a ListServicePrincipalSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -739,12 +955,21 @@ func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringCr func (newState *ListServicePrincipalSecretsResponse) SyncEffectiveFieldsDuringRead(existingState ListServicePrincipalSecretsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListServicePrincipalSecretsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "secrets": reflect.TypeOf(SecretInfo{}), } } +// ToAttrType returns the representation of ListServicePrincipalSecretsResponse in the Terraform plugin framework type +// system. func (a ListServicePrincipalSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -781,6 +1006,13 @@ func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PublishedAppOutput) SyncEffectiveFieldsDuringRead(existingState PublishedAppOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PublishedAppOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.String{}), @@ -788,6 +1020,8 @@ func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of PublishedAppOutput in the Terraform plugin framework type +// system. func (a PublishedAppOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -825,10 +1059,19 @@ func (newState *SecretInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan SecretI func (newState *SecretInfo) SyncEffectiveFieldsDuringRead(existingState SecretInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SecretInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SecretInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SecretInfo in the Terraform plugin framework type +// system. func (a SecretInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -854,10 +1097,19 @@ func (newState *TokenAccessPolicy) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TokenAccessPolicy) SyncEffectiveFieldsDuringRead(existingState TokenAccessPolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenAccessPolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TokenAccessPolicy in the Terraform plugin framework type +// system. func (a TokenAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -882,6 +1134,13 @@ func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateCustomAppIntegration) SyncEffectiveFieldsDuringRead(existingState UpdateCustomAppIntegration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCustomAppIntegration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "redirect_urls": reflect.TypeOf(types.String{}), @@ -889,6 +1148,8 @@ func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } +// ToAttrType returns the representation of UpdateCustomAppIntegration in the Terraform plugin framework type +// system. func (a UpdateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -912,10 +1173,19 @@ func (newState *UpdateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringCreat func (newState *UpdateCustomAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState UpdateCustomAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCustomAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateCustomAppIntegrationOutput in the Terraform plugin framework type +// system. func (a UpdateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -934,12 +1204,21 @@ func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringCreateOr func (newState *UpdatePublishedAppIntegration) SyncEffectiveFieldsDuringRead(existingState UpdatePublishedAppIntegration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePublishedAppIntegration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_access_policy": reflect.TypeOf(TokenAccessPolicy{}), } } +// ToAttrType returns the representation of UpdatePublishedAppIntegration in the Terraform plugin framework type +// system. func (a UpdatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -960,10 +1239,19 @@ func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringCr func (newState *UpdatePublishedAppIntegrationOutput) SyncEffectiveFieldsDuringRead(existingState UpdatePublishedAppIntegrationOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePublishedAppIntegrationOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdatePublishedAppIntegrationOutput in the Terraform plugin framework type +// system. func (a UpdatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 8cb729a962..ff264b0bbc 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -90,6 +90,13 @@ func (newState *CreatePipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreatePipeline) SyncEffectiveFieldsDuringRead(existingState CreatePipeline) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePipeline. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), @@ -105,6 +112,8 @@ func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of CreatePipeline in the Terraform plugin framework type +// system. func (a CreatePipeline) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -171,12 +180,21 @@ func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreatePipelineResponse) SyncEffectiveFieldsDuringRead(existingState CreatePipelineResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePipelineResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "effective_settings": reflect.TypeOf(PipelineSpec{}), } } +// ToAttrType returns the representation of CreatePipelineResponse in the Terraform plugin framework type +// system. func (a CreatePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -200,10 +218,19 @@ func (newState *CronTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan CronTr func (newState *CronTrigger) SyncEffectiveFieldsDuringRead(existingState CronTrigger) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CronTrigger. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CronTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CronTrigger in the Terraform plugin framework type +// system. func (a CronTrigger) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -226,10 +253,19 @@ func (newState *DataPlaneId) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataPl func (newState *DataPlaneId) SyncEffectiveFieldsDuringRead(existingState DataPlaneId) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DataPlaneId. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DataPlaneId) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DataPlaneId in the Terraform plugin framework type +// system. func (a DataPlaneId) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -250,10 +286,19 @@ func (newState *DeletePipelineRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeletePipelineRequest) SyncEffectiveFieldsDuringRead(existingState DeletePipelineRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePipelineRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePipelineRequest in the Terraform plugin framework type +// system. func (a DeletePipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -271,10 +316,19 @@ func (newState *DeletePipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeletePipelineResponse) SyncEffectiveFieldsDuringRead(existingState DeletePipelineResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePipelineResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePipelineResponse in the Terraform plugin framework type +// system. func (a DeletePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -354,6 +408,13 @@ func (newState *EditPipeline) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditP func (newState *EditPipeline) SyncEffectiveFieldsDuringRead(existingState EditPipeline) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditPipeline. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), @@ -369,6 +430,8 @@ func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of EditPipeline in the Terraform plugin framework type +// system. func (a EditPipeline) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -431,10 +494,19 @@ func (newState *EditPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EditPipelineResponse) SyncEffectiveFieldsDuringRead(existingState EditPipelineResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditPipelineResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EditPipelineResponse in the Terraform plugin framework type +// system. func (a EditPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -454,12 +526,21 @@ func (newState *ErrorDetail) SyncEffectiveFieldsDuringCreateOrUpdate(plan ErrorD func (newState *ErrorDetail) SyncEffectiveFieldsDuringRead(existingState ErrorDetail) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ErrorDetail. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ErrorDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exceptions": reflect.TypeOf(SerializedException{}), } } +// ToAttrType returns the representation of ErrorDetail in the Terraform plugin framework type +// system. func (a ErrorDetail) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -482,10 +563,19 @@ func (newState *FileLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan FileLi func (newState *FileLibrary) SyncEffectiveFieldsDuringRead(existingState FileLibrary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FileLibrary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FileLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FileLibrary in the Terraform plugin framework type +// system. func (a FileLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -507,6 +597,13 @@ func (newState *Filters) SyncEffectiveFieldsDuringCreateOrUpdate(plan Filters) { func (newState *Filters) SyncEffectiveFieldsDuringRead(existingState Filters) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Filters. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "exclude": reflect.TypeOf(types.String{}), @@ -514,6 +611,8 @@ func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of Filters in the Terraform plugin framework type +// system. func (a Filters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -539,10 +638,19 @@ func (newState *GetPipelinePermissionLevelsRequest) SyncEffectiveFieldsDuringCre func (newState *GetPipelinePermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPipelinePermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPipelinePermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetPipelinePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -562,12 +670,21 @@ func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringCr func (newState *GetPipelinePermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPipelinePermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(PipelinePermissionsDescription{}), } } +// ToAttrType returns the representation of GetPipelinePermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetPipelinePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -590,10 +707,19 @@ func (newState *GetPipelinePermissionsRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetPipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelinePermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPipelinePermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPipelinePermissionsRequest in the Terraform plugin framework type +// system. func (a GetPipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -613,10 +739,19 @@ func (newState *GetPipelineRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetPipelineRequest) SyncEffectiveFieldsDuringRead(existingState GetPipelineRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPipelineRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPipelineRequest in the Terraform plugin framework type +// system. func (a GetPipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -660,6 +795,13 @@ func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetPipelineResponse) SyncEffectiveFieldsDuringRead(existingState GetPipelineResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPipelineResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_updates": reflect.TypeOf(UpdateStateInfo{}), @@ -667,6 +809,8 @@ func (a GetPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of GetPipelineResponse in the Terraform plugin framework type +// system. func (a GetPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -704,10 +848,19 @@ func (newState *GetUpdateRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetUpdateRequest) SyncEffectiveFieldsDuringRead(existingState GetUpdateRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetUpdateRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetUpdateRequest in the Terraform plugin framework type +// system. func (a GetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -728,12 +881,21 @@ func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetUpdateResponse) SyncEffectiveFieldsDuringRead(existingState GetUpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetUpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "update": reflect.TypeOf(UpdateInfo{}), } } +// ToAttrType returns the representation of GetUpdateResponse in the Terraform plugin framework type +// system. func (a GetUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -759,6 +921,13 @@ func (newState *IngestionConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan In func (newState *IngestionConfig) SyncEffectiveFieldsDuringRead(existingState IngestionConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in IngestionConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a IngestionConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "report": reflect.TypeOf(ReportSpec{}), @@ -767,6 +936,8 @@ func (a IngestionConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of IngestionConfig in the Terraform plugin framework type +// system. func (a IngestionConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -810,10 +981,19 @@ func (newState *IngestionGatewayPipelineDefinition) SyncEffectiveFieldsDuringCre func (newState *IngestionGatewayPipelineDefinition) SyncEffectiveFieldsDuringRead(existingState IngestionGatewayPipelineDefinition) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in IngestionGatewayPipelineDefinition. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of IngestionGatewayPipelineDefinition in the Terraform plugin framework type +// system. func (a IngestionGatewayPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -849,6 +1029,13 @@ func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringCreateOrUp func (newState *IngestionPipelineDefinition) SyncEffectiveFieldsDuringRead(existingState IngestionPipelineDefinition) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in IngestionPipelineDefinition. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a IngestionPipelineDefinition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "objects": reflect.TypeOf(IngestionConfig{}), @@ -856,6 +1043,8 @@ func (a IngestionPipelineDefinition) GetComplexFieldTypes(ctx context.Context) m } } +// ToAttrType returns the representation of IngestionPipelineDefinition in the Terraform plugin framework type +// system. func (a IngestionPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -904,12 +1093,21 @@ func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListPipelineEventsRequest) SyncEffectiveFieldsDuringRead(existingState ListPipelineEventsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPipelineEventsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPipelineEventsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ListPipelineEventsRequest in the Terraform plugin framework type +// system. func (a ListPipelineEventsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -939,12 +1137,21 @@ func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListPipelineEventsResponse) SyncEffectiveFieldsDuringRead(existingState ListPipelineEventsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPipelineEventsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPipelineEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "events": reflect.TypeOf(PipelineEvent{}), } } +// ToAttrType returns the representation of ListPipelineEventsResponse in the Terraform plugin framework type +// system. func (a ListPipelineEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -988,12 +1195,21 @@ func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListPipelinesRequest) SyncEffectiveFieldsDuringRead(existingState ListPipelinesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPipelinesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPipelinesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "order_by": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ListPipelinesRequest in the Terraform plugin framework type +// system. func (a ListPipelinesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1020,12 +1236,21 @@ func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListPipelinesResponse) SyncEffectiveFieldsDuringRead(existingState ListPipelinesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPipelinesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPipelinesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "statuses": reflect.TypeOf(PipelineStateInfo{}), } } +// ToAttrType returns the representation of ListPipelinesResponse in the Terraform plugin framework type +// system. func (a ListPipelinesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1055,10 +1280,19 @@ func (newState *ListUpdatesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListUpdatesRequest) SyncEffectiveFieldsDuringRead(existingState ListUpdatesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListUpdatesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListUpdatesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListUpdatesRequest in the Terraform plugin framework type +// system. func (a ListUpdatesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1087,12 +1321,21 @@ func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListUpdatesResponse) SyncEffectiveFieldsDuringRead(existingState ListUpdatesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListUpdatesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListUpdatesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "updates": reflect.TypeOf(UpdateInfo{}), } } +// ToAttrType returns the representation of ListUpdatesResponse in the Terraform plugin framework type +// system. func (a ListUpdatesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1114,10 +1357,19 @@ func (newState *ManualTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan Manu func (newState *ManualTrigger) SyncEffectiveFieldsDuringRead(existingState ManualTrigger) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ManualTrigger. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ManualTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ManualTrigger in the Terraform plugin framework type +// system. func (a ManualTrigger) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1135,10 +1387,19 @@ func (newState *NotebookLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan No func (newState *NotebookLibrary) SyncEffectiveFieldsDuringRead(existingState NotebookLibrary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NotebookLibrary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NotebookLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NotebookLibrary in the Terraform plugin framework type +// system. func (a NotebookLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1166,6 +1427,13 @@ func (newState *Notifications) SyncEffectiveFieldsDuringCreateOrUpdate(plan Noti func (newState *Notifications) SyncEffectiveFieldsDuringRead(existingState Notifications) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Notifications. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alerts": reflect.TypeOf(types.String{}), @@ -1173,6 +1441,8 @@ func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of Notifications in the Terraform plugin framework type +// system. func (a Notifications) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1230,10 +1500,19 @@ func (newState *Origin) SyncEffectiveFieldsDuringCreateOrUpdate(plan Origin) { func (newState *Origin) SyncEffectiveFieldsDuringRead(existingState Origin) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Origin. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Origin) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Origin in the Terraform plugin framework type +// system. func (a Origin) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1275,10 +1554,19 @@ func (newState *PipelineAccessControlRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *PipelineAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState PipelineAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelineAccessControlRequest in the Terraform plugin framework type +// system. func (a PipelineAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1309,12 +1597,21 @@ func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringCreateOr func (newState *PipelineAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState PipelineAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(PipelinePermission{}), } } +// ToAttrType returns the representation of PipelineAccessControlResponse in the Terraform plugin framework type +// system. func (a PipelineAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1432,6 +1729,13 @@ func (newState *PipelineCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineCluster) SyncEffectiveFieldsDuringRead(existingState PipelineCluster) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineCluster. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(PipelineClusterAutoscale{}), @@ -1447,6 +1751,8 @@ func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of PipelineCluster in the Terraform plugin framework type +// system. func (a PipelineCluster) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1515,10 +1821,19 @@ func (newState *PipelineClusterAutoscale) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *PipelineClusterAutoscale) SyncEffectiveFieldsDuringRead(existingState PipelineClusterAutoscale) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineClusterAutoscale. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineClusterAutoscale) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelineClusterAutoscale in the Terraform plugin framework type +// system. func (a PipelineClusterAutoscale) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1542,10 +1857,19 @@ func (newState *PipelineDeployment) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelineDeployment) SyncEffectiveFieldsDuringRead(existingState PipelineDeployment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineDeployment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineDeployment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelineDeployment in the Terraform plugin framework type +// system. func (a PipelineDeployment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1582,6 +1906,13 @@ func (newState *PipelineEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipe func (newState *PipelineEvent) SyncEffectiveFieldsDuringRead(existingState PipelineEvent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineEvent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineEvent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error": reflect.TypeOf(ErrorDetail{}), @@ -1590,6 +1921,8 @@ func (a PipelineEvent) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of PipelineEvent in the Terraform plugin framework type +// system. func (a PipelineEvent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1633,6 +1966,13 @@ func (newState *PipelineLibrary) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineLibrary) SyncEffectiveFieldsDuringRead(existingState PipelineLibrary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineLibrary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file": reflect.TypeOf(FileLibrary{}), @@ -1641,6 +1981,8 @@ func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of PipelineLibrary in the Terraform plugin framework type +// system. func (a PipelineLibrary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1673,12 +2015,21 @@ func (newState *PipelinePermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelinePermission) SyncEffectiveFieldsDuringRead(existingState PipelinePermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelinePermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelinePermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of PipelinePermission in the Terraform plugin framework type +// system. func (a PipelinePermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1705,12 +2056,21 @@ func (newState *PipelinePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PipelinePermissions) SyncEffectiveFieldsDuringRead(existingState PipelinePermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelinePermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelinePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PipelineAccessControlResponse{}), } } +// ToAttrType returns the representation of PipelinePermissions in the Terraform plugin framework type +// system. func (a PipelinePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1735,10 +2095,19 @@ func (newState *PipelinePermissionsDescription) SyncEffectiveFieldsDuringCreateO func (newState *PipelinePermissionsDescription) SyncEffectiveFieldsDuringRead(existingState PipelinePermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelinePermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelinePermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PipelinePermissionsDescription in the Terraform plugin framework type +// system. func (a PipelinePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1760,12 +2129,21 @@ func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *PipelinePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState PipelinePermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelinePermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(PipelineAccessControlRequest{}), } } +// ToAttrType returns the representation of PipelinePermissionsRequest in the Terraform plugin framework type +// system. func (a PipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1841,6 +2219,13 @@ func (newState *PipelineSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pipel func (newState *PipelineSpec) SyncEffectiveFieldsDuringRead(existingState PipelineSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "clusters": reflect.TypeOf(PipelineCluster{}), @@ -1856,6 +2241,8 @@ func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of PipelineSpec in the Terraform plugin framework type +// system. func (a PipelineSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1933,12 +2320,21 @@ func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PipelineStateInfo) SyncEffectiveFieldsDuringRead(existingState PipelineStateInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineStateInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "latest_updates": reflect.TypeOf(UpdateStateInfo{}), } } +// ToAttrType returns the representation of PipelineStateInfo in the Terraform plugin framework type +// system. func (a PipelineStateInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1968,6 +2364,13 @@ func (newState *PipelineTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pi func (newState *PipelineTrigger) SyncEffectiveFieldsDuringRead(existingState PipelineTrigger) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PipelineTrigger. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PipelineTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cron": reflect.TypeOf(CronTrigger{}), @@ -1975,6 +2378,8 @@ func (a PipelineTrigger) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of PipelineTrigger in the Terraform plugin framework type +// system. func (a PipelineTrigger) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2010,12 +2415,21 @@ func (newState *ReportSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ReportS func (newState *ReportSpec) SyncEffectiveFieldsDuringRead(existingState ReportSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReportSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReportSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } +// ToAttrType returns the representation of ReportSpec in the Terraform plugin framework type +// system. func (a ReportSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2051,10 +2465,19 @@ func (newState *RestartWindow) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rest func (newState *RestartWindow) SyncEffectiveFieldsDuringRead(existingState RestartWindow) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestartWindow. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestartWindow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestartWindow in the Terraform plugin framework type +// system. func (a RestartWindow) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2089,12 +2512,21 @@ func (newState *SchemaSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan SchemaS func (newState *SchemaSpec) SyncEffectiveFieldsDuringRead(existingState SchemaSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SchemaSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SchemaSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } +// ToAttrType returns the representation of SchemaSpec in the Terraform plugin framework type +// system. func (a SchemaSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2122,12 +2554,21 @@ func (newState *Sequencing) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sequenc func (newState *Sequencing) SyncEffectiveFieldsDuringRead(existingState Sequencing) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Sequencing. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Sequencing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_plane_id": reflect.TypeOf(DataPlaneId{}), } } +// ToAttrType returns the representation of Sequencing in the Terraform plugin framework type +// system. func (a Sequencing) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2154,12 +2595,21 @@ func (newState *SerializedException) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *SerializedException) SyncEffectiveFieldsDuringRead(existingState SerializedException) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SerializedException. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SerializedException) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "stack": reflect.TypeOf(StackFrame{}), } } +// ToAttrType returns the representation of SerializedException in the Terraform plugin framework type +// system. func (a SerializedException) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2189,10 +2639,19 @@ func (newState *StackFrame) SyncEffectiveFieldsDuringCreateOrUpdate(plan StackFr func (newState *StackFrame) SyncEffectiveFieldsDuringRead(existingState StackFrame) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StackFrame. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StackFrame) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StackFrame in the Terraform plugin framework type +// system. func (a StackFrame) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2231,6 +2690,13 @@ func (newState *StartUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(plan StartU func (newState *StartUpdate) SyncEffectiveFieldsDuringRead(existingState StartUpdate) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartUpdate. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "full_refresh_selection": reflect.TypeOf(types.String{}), @@ -2238,6 +2704,8 @@ func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of StartUpdate in the Terraform plugin framework type +// system. func (a StartUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2265,10 +2733,19 @@ func (newState *StartUpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *StartUpdateResponse) SyncEffectiveFieldsDuringRead(existingState StartUpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartUpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StartUpdateResponse in the Terraform plugin framework type +// system. func (a StartUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2286,10 +2763,19 @@ func (newState *StopPipelineResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StopPipelineResponse) SyncEffectiveFieldsDuringRead(existingState StopPipelineResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StopPipelineResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StopPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StopPipelineResponse in the Terraform plugin framework type +// system. func (a StopPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2307,10 +2793,19 @@ func (newState *StopRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan StopRe func (newState *StopRequest) SyncEffectiveFieldsDuringRead(existingState StopRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StopRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StopRequest in the Terraform plugin framework type +// system. func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2346,12 +2841,21 @@ func (newState *TableSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan TableSpe func (newState *TableSpec) SyncEffectiveFieldsDuringRead(existingState TableSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "table_configuration": reflect.TypeOf(TableSpecificConfig{}), } } +// ToAttrType returns the representation of TableSpec in the Terraform plugin framework type +// system. func (a TableSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2388,6 +2892,13 @@ func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *TableSpecificConfig) SyncEffectiveFieldsDuringRead(existingState TableSpecificConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TableSpecificConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "primary_keys": reflect.TypeOf(types.String{}), @@ -2395,6 +2906,8 @@ func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of TableSpecificConfig in the Terraform plugin framework type +// system. func (a TableSpecificConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2449,6 +2962,13 @@ func (newState *UpdateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateI func (newState *UpdateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(PipelineSpec{}), @@ -2457,6 +2977,8 @@ func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of UpdateInfo in the Terraform plugin framework type +// system. func (a UpdateInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2495,10 +3017,19 @@ func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateStateInfo) SyncEffectiveFieldsDuringRead(existingState UpdateStateInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateStateInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateStateInfo in the Terraform plugin framework type +// system. func (a UpdateStateInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 41111661b7..de53539522 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -29,12 +29,21 @@ func (newState *AwsCredentials) SyncEffectiveFieldsDuringCreateOrUpdate(plan Aws func (newState *AwsCredentials) SyncEffectiveFieldsDuringRead(existingState AwsCredentials) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsCredentials. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sts_role": reflect.TypeOf(StsRole{}), } } +// ToAttrType returns the representation of AwsCredentials in the Terraform plugin framework type +// system. func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -65,10 +74,19 @@ func (newState *AwsKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan AwsKeyI func (newState *AwsKeyInfo) SyncEffectiveFieldsDuringRead(existingState AwsKeyInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AwsKeyInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AwsKeyInfo in the Terraform plugin framework type +// system. func (a AwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -93,10 +111,19 @@ func (newState *AzureWorkspaceInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AzureWorkspaceInfo) SyncEffectiveFieldsDuringRead(existingState AzureWorkspaceInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureWorkspaceInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureWorkspaceInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureWorkspaceInfo in the Terraform plugin framework type +// system. func (a AzureWorkspaceInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -118,12 +145,21 @@ func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CloudResourceContainer) SyncEffectiveFieldsDuringRead(existingState CloudResourceContainer) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CloudResourceContainer. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp": reflect.TypeOf(CustomerFacingGcpCloudResourceContainer{}), } } +// ToAttrType returns the representation of CloudResourceContainer in the Terraform plugin framework type +// system. func (a CloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -153,10 +189,19 @@ func (newState *CreateAwsKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateAwsKeyInfo) SyncEffectiveFieldsDuringRead(existingState CreateAwsKeyInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateAwsKeyInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateAwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateAwsKeyInfo in the Terraform plugin framework type +// system. func (a CreateAwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -177,12 +222,21 @@ func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringCreateO func (newState *CreateCredentialAwsCredentials) SyncEffectiveFieldsDuringRead(existingState CreateCredentialAwsCredentials) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCredentialAwsCredentials. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCredentialAwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sts_role": reflect.TypeOf(CreateCredentialStsRole{}), } } +// ToAttrType returns the representation of CreateCredentialAwsCredentials in the Terraform plugin framework type +// system. func (a CreateCredentialAwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -205,12 +259,21 @@ func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_credentials": reflect.TypeOf(CreateCredentialAwsCredentials{}), } } +// ToAttrType returns the representation of CreateCredentialRequest in the Terraform plugin framework type +// system. func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -233,10 +296,19 @@ func (newState *CreateCredentialStsRole) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateCredentialStsRole) SyncEffectiveFieldsDuringRead(existingState CreateCredentialStsRole) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCredentialStsRole. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCredentialStsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateCredentialStsRole in the Terraform plugin framework type +// system. func (a CreateCredentialStsRole) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -259,6 +331,13 @@ func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringCreate func (newState *CreateCustomerManagedKeyRequest) SyncEffectiveFieldsDuringRead(existingState CreateCustomerManagedKeyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCustomerManagedKeyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_key_info": reflect.TypeOf(CreateAwsKeyInfo{}), @@ -267,6 +346,8 @@ func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Contex } } +// ToAttrType returns the representation of CreateCustomerManagedKeyRequest in the Terraform plugin framework type +// system. func (a CreateCustomerManagedKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -294,10 +375,19 @@ func (newState *CreateGcpKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan C func (newState *CreateGcpKeyInfo) SyncEffectiveFieldsDuringRead(existingState CreateGcpKeyInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateGcpKeyInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateGcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateGcpKeyInfo in the Terraform plugin framework type +// system. func (a CreateGcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -334,6 +424,13 @@ func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CreateNetworkRequest) SyncEffectiveFieldsDuringRead(existingState CreateNetworkRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateNetworkRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_network_info": reflect.TypeOf(GcpNetworkInfo{}), @@ -343,6 +440,8 @@ func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of CreateNetworkRequest in the Terraform plugin framework type +// system. func (a CreateNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -377,12 +476,21 @@ func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringCrea func (newState *CreateStorageConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState CreateStorageConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateStorageConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateStorageConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "root_bucket_info": reflect.TypeOf(RootBucketInfo{}), } } +// ToAttrType returns the representation of CreateStorageConfigurationRequest in the Terraform plugin framework type +// system. func (a CreateStorageConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -412,12 +520,21 @@ func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState CreateVpcEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateVpcEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_vpc_endpoint_info": reflect.TypeOf(GcpVpcEndpointInfo{}), } } +// ToAttrType returns the representation of CreateVpcEndpointRequest in the Terraform plugin framework type +// system. func (a CreateVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -550,6 +667,13 @@ func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState CreateWorkspaceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateWorkspaceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cloud_resource_container": reflect.TypeOf(CloudResourceContainer{}), @@ -559,6 +683,8 @@ func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } +// ToAttrType returns the representation of CreateWorkspaceRequest in the Terraform plugin framework type +// system. func (a CreateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -610,12 +736,21 @@ func (newState *Credential) SyncEffectiveFieldsDuringCreateOrUpdate(plan Credent func (newState *Credential) SyncEffectiveFieldsDuringRead(existingState Credential) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Credential. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Credential) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_credentials": reflect.TypeOf(AwsCredentials{}), } } +// ToAttrType returns the representation of Credential in the Terraform plugin framework type +// system. func (a Credential) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -643,10 +778,19 @@ func (newState *CustomerFacingGcpCloudResourceContainer) SyncEffectiveFieldsDuri func (newState *CustomerFacingGcpCloudResourceContainer) SyncEffectiveFieldsDuringRead(existingState CustomerFacingGcpCloudResourceContainer) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CustomerFacingGcpCloudResourceContainer. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CustomerFacingGcpCloudResourceContainer in the Terraform plugin framework type +// system. func (a CustomerFacingGcpCloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -676,6 +820,13 @@ func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CustomerManagedKey) SyncEffectiveFieldsDuringRead(existingState CustomerManagedKey) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CustomerManagedKey. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_key_info": reflect.TypeOf(AwsKeyInfo{}), @@ -684,6 +835,8 @@ func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of CustomerManagedKey in the Terraform plugin framework type +// system. func (a CustomerManagedKey) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -715,10 +868,19 @@ func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteCredentialRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type +// system. func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -739,10 +901,19 @@ func (newState *DeleteEncryptionKeyRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteEncryptionKeyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteEncryptionKeyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteEncryptionKeyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteEncryptionKeyRequest in the Terraform plugin framework type +// system. func (a DeleteEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -763,10 +934,19 @@ func (newState *DeleteNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteNetworkRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteNetworkRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteNetworkRequest in the Terraform plugin framework type +// system. func (a DeleteNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -787,10 +967,19 @@ func (newState *DeletePrivateAccesRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeletePrivateAccesRequest) SyncEffectiveFieldsDuringRead(existingState DeletePrivateAccesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePrivateAccesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePrivateAccesRequest in the Terraform plugin framework type +// system. func (a DeletePrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -808,10 +997,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -830,10 +1028,19 @@ func (newState *DeleteStorageRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteStorageRequest) SyncEffectiveFieldsDuringRead(existingState DeleteStorageRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteStorageRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteStorageRequest in the Terraform plugin framework type +// system. func (a DeleteStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -854,10 +1061,19 @@ func (newState *DeleteVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVpcEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteVpcEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteVpcEndpointRequest in the Terraform plugin framework type +// system. func (a DeleteVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -878,10 +1094,19 @@ func (newState *DeleteWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWorkspaceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWorkspaceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWorkspaceRequest in the Terraform plugin framework type +// system. func (a DeleteWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -905,10 +1130,19 @@ func (newState *ExternalCustomerInfo) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExternalCustomerInfo) SyncEffectiveFieldsDuringRead(existingState ExternalCustomerInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalCustomerInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExternalCustomerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExternalCustomerInfo in the Terraform plugin framework type +// system. func (a ExternalCustomerInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -930,10 +1164,19 @@ func (newState *GcpKeyInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan GcpKeyI func (newState *GcpKeyInfo) SyncEffectiveFieldsDuringRead(existingState GcpKeyInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpKeyInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpKeyInfo in the Terraform plugin framework type +// system. func (a GcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -983,10 +1226,19 @@ func (newState *GcpManagedNetworkConfig) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GcpManagedNetworkConfig) SyncEffectiveFieldsDuringRead(existingState GcpManagedNetworkConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpManagedNetworkConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpManagedNetworkConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpManagedNetworkConfig in the Terraform plugin framework type +// system. func (a GcpManagedNetworkConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1026,10 +1278,19 @@ func (newState *GcpNetworkInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Gcp func (newState *GcpNetworkInfo) SyncEffectiveFieldsDuringRead(existingState GcpNetworkInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpNetworkInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpNetworkInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpNetworkInfo in the Terraform plugin framework type +// system. func (a GcpNetworkInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1065,10 +1326,19 @@ func (newState *GcpVpcEndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GcpVpcEndpointInfo) SyncEffectiveFieldsDuringRead(existingState GcpVpcEndpointInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GcpVpcEndpointInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GcpVpcEndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GcpVpcEndpointInfo in the Terraform plugin framework type +// system. func (a GcpVpcEndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1093,10 +1363,19 @@ func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetCredentialRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCredentialRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCredentialRequest in the Terraform plugin framework type +// system. func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1117,10 +1396,19 @@ func (newState *GetEncryptionKeyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetEncryptionKeyRequest) SyncEffectiveFieldsDuringRead(existingState GetEncryptionKeyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEncryptionKeyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetEncryptionKeyRequest in the Terraform plugin framework type +// system. func (a GetEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1141,10 +1429,19 @@ func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringRead(existingState GetNetworkRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetNetworkRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetNetworkRequest in the Terraform plugin framework type +// system. func (a GetNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1165,10 +1462,19 @@ func (newState *GetPrivateAccesRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetPrivateAccesRequest) SyncEffectiveFieldsDuringRead(existingState GetPrivateAccesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPrivateAccesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPrivateAccesRequest in the Terraform plugin framework type +// system. func (a GetPrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1189,10 +1495,19 @@ func (newState *GetStorageRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetStorageRequest) SyncEffectiveFieldsDuringRead(existingState GetStorageRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStorageRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStorageRequest in the Terraform plugin framework type +// system. func (a GetStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1213,10 +1528,19 @@ func (newState *GetVpcEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetVpcEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetVpcEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetVpcEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetVpcEndpointRequest in the Terraform plugin framework type +// system. func (a GetVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1237,10 +1561,19 @@ func (newState *GetWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWorkspaceRequest in the Terraform plugin framework type +// system. func (a GetWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1273,10 +1606,19 @@ func (newState *GkeConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan GkeConfi func (newState *GkeConfig) SyncEffectiveFieldsDuringRead(existingState GkeConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GkeConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GkeConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GkeConfig in the Terraform plugin framework type +// system. func (a GkeConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1328,6 +1670,13 @@ func (newState *Network) SyncEffectiveFieldsDuringCreateOrUpdate(plan Network) { func (newState *Network) SyncEffectiveFieldsDuringRead(existingState Network) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Network. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error_messages": reflect.TypeOf(NetworkHealth{}), @@ -1339,6 +1688,8 @@ func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } +// ToAttrType returns the representation of Network in the Terraform plugin framework type +// system. func (a Network) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1385,10 +1736,19 @@ func (newState *NetworkHealth) SyncEffectiveFieldsDuringCreateOrUpdate(plan Netw func (newState *NetworkHealth) SyncEffectiveFieldsDuringRead(existingState NetworkHealth) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NetworkHealth. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NetworkHealth) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NetworkHealth in the Terraform plugin framework type +// system. func (a NetworkHealth) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1417,6 +1777,13 @@ func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *NetworkVpcEndpoints) SyncEffectiveFieldsDuringRead(existingState NetworkVpcEndpoints) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NetworkVpcEndpoints. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataplane_relay": reflect.TypeOf(types.String{}), @@ -1424,6 +1791,8 @@ func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of NetworkVpcEndpoints in the Terraform plugin framework type +// system. func (a NetworkVpcEndpoints) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1451,10 +1820,19 @@ func (newState *NetworkWarning) SyncEffectiveFieldsDuringCreateOrUpdate(plan Net func (newState *NetworkWarning) SyncEffectiveFieldsDuringRead(existingState NetworkWarning) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NetworkWarning. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NetworkWarning) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NetworkWarning in the Terraform plugin framework type +// system. func (a NetworkWarning) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1497,12 +1875,21 @@ func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *PrivateAccessSettings) SyncEffectiveFieldsDuringRead(existingState PrivateAccessSettings) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PrivateAccessSettings. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PrivateAccessSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "allowed_vpc_endpoint_ids": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of PrivateAccessSettings in the Terraform plugin framework type +// system. func (a PrivateAccessSettings) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1528,10 +1915,19 @@ func (newState *ReplaceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReplaceResponse) SyncEffectiveFieldsDuringRead(existingState ReplaceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReplaceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ReplaceResponse in the Terraform plugin framework type +// system. func (a ReplaceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1550,10 +1946,19 @@ func (newState *RootBucketInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Roo func (newState *RootBucketInfo) SyncEffectiveFieldsDuringRead(existingState RootBucketInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RootBucketInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RootBucketInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RootBucketInfo in the Terraform plugin framework type +// system. func (a RootBucketInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1581,12 +1986,21 @@ func (newState *StorageConfiguration) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *StorageConfiguration) SyncEffectiveFieldsDuringRead(existingState StorageConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StorageConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StorageConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "root_bucket_info": reflect.TypeOf(RootBucketInfo{}), } } +// ToAttrType returns the representation of StorageConfiguration in the Terraform plugin framework type +// system. func (a StorageConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1615,10 +2029,19 @@ func (newState *StsRole) SyncEffectiveFieldsDuringCreateOrUpdate(plan StsRole) { func (newState *StsRole) SyncEffectiveFieldsDuringRead(existingState StsRole) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StsRole. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StsRole in the Terraform plugin framework type +// system. func (a StsRole) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1637,10 +2060,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1688,12 +2120,21 @@ func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState UpdateWorkspaceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateWorkspaceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_tags": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpdateWorkspaceRequest in the Terraform plugin framework type +// system. func (a UpdateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1757,12 +2198,21 @@ func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringCre func (newState *UpsertPrivateAccessSettingsRequest) SyncEffectiveFieldsDuringRead(existingState UpsertPrivateAccessSettingsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpsertPrivateAccessSettingsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "allowed_vpc_endpoint_ids": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpsertPrivateAccessSettingsRequest in the Terraform plugin framework type +// system. func (a UpsertPrivateAccessSettingsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1822,12 +2272,21 @@ func (newState *VpcEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan VpcEnd func (newState *VpcEndpoint) SyncEffectiveFieldsDuringRead(existingState VpcEndpoint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in VpcEndpoint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a VpcEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "gcp_vpc_endpoint_info": reflect.TypeOf(GcpVpcEndpointInfo{}), } } +// ToAttrType returns the representation of VpcEndpoint in the Terraform plugin framework type +// system. func (a VpcEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1953,6 +2412,13 @@ func (newState *Workspace) SyncEffectiveFieldsDuringCreateOrUpdate(plan Workspac func (newState *Workspace) SyncEffectiveFieldsDuringRead(existingState Workspace) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Workspace. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "azure_workspace_info": reflect.TypeOf(AzureWorkspaceInfo{}), @@ -1964,6 +2430,8 @@ func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of Workspace in the Terraform plugin framework type +// system. func (a Workspace) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index b822ed2ad4..48af16bd51 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -41,10 +41,19 @@ func (newState *Ai21LabsConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ai2 func (newState *Ai21LabsConfig) SyncEffectiveFieldsDuringRead(existingState Ai21LabsConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Ai21LabsConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Ai21LabsConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Ai21LabsConfig in the Terraform plugin framework type +// system. func (a Ai21LabsConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -76,6 +85,13 @@ func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ai func (newState *AiGatewayConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), @@ -85,6 +101,8 @@ func (a AiGatewayConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of AiGatewayConfig in the Terraform plugin framework type +// system. func (a AiGatewayConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -123,6 +141,13 @@ func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringCreateOrU func (newState *AiGatewayGuardrailParameters) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrailParameters) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayGuardrailParameters. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "invalid_keywords": reflect.TypeOf(types.String{}), @@ -131,6 +156,8 @@ func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) } } +// ToAttrType returns the representation of AiGatewayGuardrailParameters in the Terraform plugin framework type +// system. func (a AiGatewayGuardrailParameters) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -164,10 +191,19 @@ func (newState *AiGatewayGuardrailPiiBehavior) SyncEffectiveFieldsDuringCreateOr func (newState *AiGatewayGuardrailPiiBehavior) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrailPiiBehavior) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayGuardrailPiiBehavior. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AiGatewayGuardrailPiiBehavior in the Terraform plugin framework type +// system. func (a AiGatewayGuardrailPiiBehavior) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -189,6 +225,13 @@ func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AiGatewayGuardrails) SyncEffectiveFieldsDuringRead(existingState AiGatewayGuardrails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayGuardrails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayGuardrails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "input": reflect.TypeOf(AiGatewayGuardrailParameters{}), @@ -196,6 +239,8 @@ func (a AiGatewayGuardrails) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of AiGatewayGuardrails in the Terraform plugin framework type +// system. func (a AiGatewayGuardrails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -231,10 +276,19 @@ func (newState *AiGatewayInferenceTableConfig) SyncEffectiveFieldsDuringCreateOr func (newState *AiGatewayInferenceTableConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayInferenceTableConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayInferenceTableConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AiGatewayInferenceTableConfig in the Terraform plugin framework type +// system. func (a AiGatewayInferenceTableConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -264,10 +318,19 @@ func (newState *AiGatewayRateLimit) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AiGatewayRateLimit) SyncEffectiveFieldsDuringRead(existingState AiGatewayRateLimit) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayRateLimit. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayRateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AiGatewayRateLimit in the Terraform plugin framework type +// system. func (a AiGatewayRateLimit) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -289,10 +352,19 @@ func (newState *AiGatewayUsageTrackingConfig) SyncEffectiveFieldsDuringCreateOrU func (newState *AiGatewayUsageTrackingConfig) SyncEffectiveFieldsDuringRead(existingState AiGatewayUsageTrackingConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AiGatewayUsageTrackingConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AiGatewayUsageTrackingConfig in the Terraform plugin framework type +// system. func (a AiGatewayUsageTrackingConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -341,10 +413,19 @@ func (newState *AmazonBedrockConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *AmazonBedrockConfig) SyncEffectiveFieldsDuringRead(existingState AmazonBedrockConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AmazonBedrockConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AmazonBedrockConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AmazonBedrockConfig in the Terraform plugin framework type +// system. func (a AmazonBedrockConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -377,10 +458,19 @@ func (newState *AnthropicConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan An func (newState *AnthropicConfig) SyncEffectiveFieldsDuringRead(existingState AnthropicConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AnthropicConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AnthropicConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AnthropicConfig in the Terraform plugin framework type +// system. func (a AnthropicConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -410,10 +500,19 @@ func (newState *AutoCaptureConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *AutoCaptureConfigInput) SyncEffectiveFieldsDuringRead(existingState AutoCaptureConfigInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AutoCaptureConfigInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AutoCaptureConfigInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AutoCaptureConfigInput in the Terraform plugin framework type +// system. func (a AutoCaptureConfigInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -444,12 +543,21 @@ func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AutoCaptureConfigOutput) SyncEffectiveFieldsDuringRead(existingState AutoCaptureConfigOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AutoCaptureConfigOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AutoCaptureConfigOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "state": reflect.TypeOf(AutoCaptureState{}), } } +// ToAttrType returns the representation of AutoCaptureConfigOutput in the Terraform plugin framework type +// system. func (a AutoCaptureConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -474,12 +582,21 @@ func (newState *AutoCaptureState) SyncEffectiveFieldsDuringCreateOrUpdate(plan A func (newState *AutoCaptureState) SyncEffectiveFieldsDuringRead(existingState AutoCaptureState) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AutoCaptureState. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AutoCaptureState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "payload_table": reflect.TypeOf(PayloadTable{}), } } +// ToAttrType returns the representation of AutoCaptureState in the Terraform plugin framework type +// system. func (a AutoCaptureState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -506,10 +623,19 @@ func (newState *BuildLogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan B func (newState *BuildLogsRequest) SyncEffectiveFieldsDuringRead(existingState BuildLogsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BuildLogsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BuildLogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of BuildLogsRequest in the Terraform plugin framework type +// system. func (a BuildLogsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -530,10 +656,19 @@ func (newState *BuildLogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *BuildLogsResponse) SyncEffectiveFieldsDuringRead(existingState BuildLogsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BuildLogsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BuildLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of BuildLogsResponse in the Terraform plugin framework type +// system. func (a BuildLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -555,10 +690,19 @@ func (newState *ChatMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan ChatMe func (newState *ChatMessage) SyncEffectiveFieldsDuringRead(existingState ChatMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ChatMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ChatMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ChatMessage in the Terraform plugin framework type +// system. func (a ChatMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -590,10 +734,19 @@ func (newState *CohereConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Coher func (newState *CohereConfig) SyncEffectiveFieldsDuringRead(existingState CohereConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CohereConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CohereConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CohereConfig in the Terraform plugin framework type +// system. func (a CohereConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -630,6 +783,13 @@ func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateServingEndpoint) SyncEffectiveFieldsDuringRead(existingState CreateServingEndpoint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateServingEndpoint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), @@ -639,6 +799,8 @@ func (a CreateServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of CreateServingEndpoint in the Terraform plugin framework type +// system. func (a CreateServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -686,10 +848,19 @@ func (newState *DatabricksModelServingConfig) SyncEffectiveFieldsDuringCreateOrU func (newState *DatabricksModelServingConfig) SyncEffectiveFieldsDuringRead(existingState DatabricksModelServingConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DatabricksModelServingConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DatabricksModelServingConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DatabricksModelServingConfig in the Terraform plugin framework type +// system. func (a DatabricksModelServingConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -714,6 +885,13 @@ func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringRead(existingState DataframeSplitInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DataframeSplitInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(struct{}{}), @@ -722,6 +900,8 @@ func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of DataframeSplitInput in the Terraform plugin framework type +// system. func (a DataframeSplitInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -747,10 +927,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -769,10 +958,19 @@ func (newState *DeleteServingEndpointRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteServingEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteServingEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteServingEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteServingEndpointRequest in the Terraform plugin framework type +// system. func (a DeleteServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -795,12 +993,21 @@ func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringC func (newState *EmbeddingsV1ResponseEmbeddingElement) SyncEffectiveFieldsDuringRead(existingState EmbeddingsV1ResponseEmbeddingElement) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EmbeddingsV1ResponseEmbeddingElement. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "embedding": reflect.TypeOf(types.Float64{}), } } +// ToAttrType returns the representation of EmbeddingsV1ResponseEmbeddingElement in the Terraform plugin framework type +// system. func (a EmbeddingsV1ResponseEmbeddingElement) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -836,6 +1043,13 @@ func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *EndpointCoreConfigInput) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointCoreConfigInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointCoreConfigInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "auto_capture_config": reflect.TypeOf(AutoCaptureConfigInput{}), @@ -845,6 +1059,8 @@ func (a EndpointCoreConfigInput) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of EndpointCoreConfigInput in the Terraform plugin framework type +// system. func (a EndpointCoreConfigInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -886,6 +1102,13 @@ func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *EndpointCoreConfigOutput) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointCoreConfigOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointCoreConfigOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "auto_capture_config": reflect.TypeOf(AutoCaptureConfigOutput{}), @@ -895,6 +1118,8 @@ func (a EndpointCoreConfigOutput) GetComplexFieldTypes(ctx context.Context) map[ } } +// ToAttrType returns the representation of EndpointCoreConfigOutput in the Terraform plugin framework type +// system. func (a EndpointCoreConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -929,6 +1154,13 @@ func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringCreateOrUpda func (newState *EndpointCoreConfigSummary) SyncEffectiveFieldsDuringRead(existingState EndpointCoreConfigSummary) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointCoreConfigSummary. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointCoreConfigSummary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "served_entities": reflect.TypeOf(ServedEntitySpec{}), @@ -936,6 +1168,8 @@ func (a EndpointCoreConfigSummary) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of EndpointCoreConfigSummary in the Terraform plugin framework type +// system. func (a EndpointCoreConfigSummary) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -974,6 +1208,13 @@ func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EndpointPendingConfig) SyncEffectiveFieldsDuringRead(existingState EndpointPendingConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointPendingConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointPendingConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "auto_capture_config": reflect.TypeOf(AutoCaptureConfigOutput{}), @@ -983,6 +1224,8 @@ func (a EndpointPendingConfig) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of EndpointPendingConfig in the Terraform plugin framework type +// system. func (a EndpointPendingConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1024,10 +1267,19 @@ func (newState *EndpointState) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endp func (newState *EndpointState) SyncEffectiveFieldsDuringRead(existingState EndpointState) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointState. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EndpointState in the Terraform plugin framework type +// system. func (a EndpointState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1050,10 +1302,19 @@ func (newState *EndpointTag) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpoi func (newState *EndpointTag) SyncEffectiveFieldsDuringRead(existingState EndpointTag) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointTag. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EndpointTag in the Terraform plugin framework type +// system. func (a EndpointTag) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1076,10 +1337,19 @@ func (newState *ExportMetricsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExportMetricsRequest) SyncEffectiveFieldsDuringRead(existingState ExportMetricsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExportMetricsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExportMetricsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExportMetricsRequest in the Terraform plugin framework type +// system. func (a ExportMetricsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1098,10 +1368,19 @@ func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringRead(existingState ExportMetricsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExportMetricsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExportMetricsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExportMetricsResponse in the Terraform plugin framework type +// system. func (a ExportMetricsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1146,6 +1425,13 @@ func (newState *ExternalModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exte func (newState *ExternalModel) SyncEffectiveFieldsDuringRead(existingState ExternalModel) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalModel. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExternalModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai21labs_config": reflect.TypeOf(Ai21LabsConfig{}), @@ -1159,6 +1445,8 @@ func (a ExternalModel) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of ExternalModel in the Terraform plugin framework type +// system. func (a ExternalModel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1208,10 +1496,19 @@ func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringRead(existingState ExternalModelUsageElement) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalModelUsageElement. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExternalModelUsageElement in the Terraform plugin framework type +// system. func (a ExternalModelUsageElement) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1239,10 +1536,19 @@ func (newState *FoundationModel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Fo func (newState *FoundationModel) SyncEffectiveFieldsDuringRead(existingState FoundationModel) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FoundationModel. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FoundationModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of FoundationModel in the Terraform plugin framework type +// system. func (a FoundationModel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1267,10 +1573,19 @@ func (newState *GetOpenApiRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetOpenApiRequest) SyncEffectiveFieldsDuringRead(existingState GetOpenApiRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetOpenApiRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetOpenApiRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetOpenApiRequest in the Terraform plugin framework type +// system. func (a GetOpenApiRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1290,10 +1605,19 @@ func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringRead(existingState GetOpenApiResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetOpenApiResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetOpenApiResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetOpenApiResponse in the Terraform plugin framework type +// system. func (a GetOpenApiResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1312,10 +1636,19 @@ func (newState *GetServingEndpointPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetServingEndpointPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetServingEndpointPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetServingEndpointPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetServingEndpointPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1335,12 +1668,21 @@ func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetServingEndpointPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetServingEndpointPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(ServingEndpointPermissionsDescription{}), } } +// ToAttrType returns the representation of GetServingEndpointPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetServingEndpointPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1363,10 +1705,19 @@ func (newState *GetServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetServingEndpointPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetServingEndpointPermissionsRequest in the Terraform plugin framework type +// system. func (a GetServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1387,10 +1738,19 @@ func (newState *GetServingEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetServingEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetServingEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetServingEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetServingEndpointRequest in the Terraform plugin framework type +// system. func (a GetServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1435,10 +1795,19 @@ func (newState *GoogleCloudVertexAiConfig) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GoogleCloudVertexAiConfig) SyncEffectiveFieldsDuringRead(existingState GoogleCloudVertexAiConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GoogleCloudVertexAiConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GoogleCloudVertexAiConfig in the Terraform plugin framework type +// system. func (a GoogleCloudVertexAiConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1461,12 +1830,21 @@ func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListEndpointsResponse) SyncEffectiveFieldsDuringRead(existingState ListEndpointsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListEndpointsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListEndpointsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "endpoints": reflect.TypeOf(ServingEndpoint{}), } } +// ToAttrType returns the representation of ListEndpointsResponse in the Terraform plugin framework type +// system. func (a ListEndpointsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1493,10 +1871,19 @@ func (newState *LogsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan LogsRe func (newState *LogsRequest) SyncEffectiveFieldsDuringRead(existingState LogsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LogsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of LogsRequest in the Terraform plugin framework type +// system. func (a LogsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1517,12 +1904,21 @@ func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState ModelDataPlaneInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelDataPlaneInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ModelDataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query_info": reflect.TypeOf(oauth2.DataPlaneInfo{}), } } +// ToAttrType returns the representation of ModelDataPlaneInfo in the Terraform plugin framework type +// system. func (a ModelDataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1593,10 +1989,19 @@ func (newState *OpenAiConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan OpenA func (newState *OpenAiConfig) SyncEffectiveFieldsDuringRead(existingState OpenAiConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OpenAiConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OpenAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of OpenAiConfig in the Terraform plugin framework type +// system. func (a OpenAiConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1634,10 +2039,19 @@ func (newState *PaLmConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan PaLmCon func (newState *PaLmConfig) SyncEffectiveFieldsDuringRead(existingState PaLmConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PaLmConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PaLmConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PaLmConfig in the Terraform plugin framework type +// system. func (a PaLmConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1663,6 +2077,13 @@ func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *PatchServingEndpointTags) SyncEffectiveFieldsDuringRead(existingState PatchServingEndpointTags) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PatchServingEndpointTags. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "add_tags": reflect.TypeOf(EndpointTag{}), @@ -1670,6 +2091,8 @@ func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[ } } +// ToAttrType returns the representation of PatchServingEndpointTags in the Terraform plugin framework type +// system. func (a PatchServingEndpointTags) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1699,10 +2122,19 @@ func (newState *PayloadTable) SyncEffectiveFieldsDuringCreateOrUpdate(plan Paylo func (newState *PayloadTable) SyncEffectiveFieldsDuringRead(existingState PayloadTable) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PayloadTable. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PayloadTable) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PayloadTable in the Terraform plugin framework type +// system. func (a PayloadTable) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1739,6 +2171,13 @@ func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PutAiGatewayRequest) SyncEffectiveFieldsDuringRead(existingState PutAiGatewayRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutAiGatewayRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutAiGatewayRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), @@ -1748,6 +2187,8 @@ func (a PutAiGatewayRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } +// ToAttrType returns the representation of PutAiGatewayRequest in the Terraform plugin framework type +// system. func (a PutAiGatewayRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1790,6 +2231,13 @@ func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *PutAiGatewayResponse) SyncEffectiveFieldsDuringRead(existingState PutAiGatewayResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutAiGatewayResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutAiGatewayResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "guardrails": reflect.TypeOf(AiGatewayGuardrails{}), @@ -1799,6 +2247,8 @@ func (a PutAiGatewayResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of PutAiGatewayResponse in the Terraform plugin framework type +// system. func (a PutAiGatewayResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1833,12 +2283,21 @@ func (newState *PutRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRequ func (newState *PutRequest) SyncEffectiveFieldsDuringRead(existingState PutRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rate_limits": reflect.TypeOf(RateLimit{}), } } +// ToAttrType returns the representation of PutRequest in the Terraform plugin framework type +// system. func (a PutRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1861,12 +2320,21 @@ func (newState *PutResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutRes func (newState *PutResponse) SyncEffectiveFieldsDuringRead(existingState PutResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "rate_limits": reflect.TypeOf(RateLimit{}), } } +// ToAttrType returns the representation of PutResponse in the Terraform plugin framework type +// system. func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1935,6 +2403,13 @@ func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringRead(existingState QueryEndpointInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryEndpointInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "dataframe_records": reflect.TypeOf(struct{}{}), @@ -1946,6 +2421,8 @@ func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of QueryEndpointInput in the Terraform plugin framework type +// system. func (a QueryEndpointInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2016,6 +2493,13 @@ func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *QueryEndpointResponse) SyncEffectiveFieldsDuringRead(existingState QueryEndpointResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryEndpointResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "choices": reflect.TypeOf(V1ResponseChoiceElement{}), @@ -2025,6 +2509,8 @@ func (a QueryEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of QueryEndpointResponse in the Terraform plugin framework type +// system. func (a QueryEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2068,10 +2554,19 @@ func (newState *RateLimit) SyncEffectiveFieldsDuringCreateOrUpdate(plan RateLimi func (newState *RateLimit) SyncEffectiveFieldsDuringRead(existingState RateLimit) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RateLimit. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RateLimit in the Terraform plugin framework type +// system. func (a RateLimit) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2096,10 +2591,19 @@ func (newState *Route) SyncEffectiveFieldsDuringCreateOrUpdate(plan Route) { func (newState *Route) SyncEffectiveFieldsDuringRead(existingState Route) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Route. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Route) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Route in the Terraform plugin framework type +// system. func (a Route) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2176,6 +2680,13 @@ func (newState *ServedEntityInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedEntityInput) SyncEffectiveFieldsDuringRead(existingState ServedEntityInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedEntityInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.String{}), @@ -2183,6 +2694,8 @@ func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of ServedEntityInput in the Terraform plugin framework type +// system. func (a ServedEntityInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2274,6 +2787,13 @@ func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedEntityOutput) SyncEffectiveFieldsDuringRead(existingState ServedEntityOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedEntityOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.String{}), @@ -2283,6 +2803,8 @@ func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string } } +// ToAttrType returns the representation of ServedEntityOutput in the Terraform plugin framework type +// system. func (a ServedEntityOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2341,6 +2863,13 @@ func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringRead(existingState ServedEntitySpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedEntitySpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "external_model": reflect.TypeOf(ExternalModel{}), @@ -2348,6 +2877,8 @@ func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]r } } +// ToAttrType returns the representation of ServedEntitySpec in the Terraform plugin framework type +// system. func (a ServedEntitySpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2418,12 +2949,21 @@ func (newState *ServedModelInput) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedModelInput) SyncEffectiveFieldsDuringRead(existingState ServedModelInput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedModelInput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedModelInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ServedModelInput in the Terraform plugin framework type +// system. func (a ServedModelInput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2495,6 +3035,13 @@ func (newState *ServedModelOutput) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServedModelOutput) SyncEffectiveFieldsDuringRead(existingState ServedModelOutput) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedModelOutput. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "environment_vars": reflect.TypeOf(types.String{}), @@ -2502,6 +3049,8 @@ func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of ServedModelOutput in the Terraform plugin framework type +// system. func (a ServedModelOutput) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2541,10 +3090,19 @@ func (newState *ServedModelSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan Se func (newState *ServedModelSpec) SyncEffectiveFieldsDuringRead(existingState ServedModelSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedModelSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedModelSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ServedModelSpec in the Terraform plugin framework type +// system. func (a ServedModelSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2579,10 +3137,19 @@ func (newState *ServedModelState) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *ServedModelState) SyncEffectiveFieldsDuringRead(existingState ServedModelState) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedModelState. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServedModelState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ServedModelState in the Terraform plugin framework type +// system. func (a ServedModelState) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2604,10 +3171,19 @@ func (newState *ServerLogsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ServerLogsResponse) SyncEffectiveFieldsDuringRead(existingState ServerLogsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServerLogsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServerLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ServerLogsResponse in the Terraform plugin framework type +// system. func (a ServerLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2647,6 +3223,13 @@ func (newState *ServingEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Se func (newState *ServingEndpoint) SyncEffectiveFieldsDuringRead(existingState ServingEndpoint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpoint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), @@ -2656,6 +3239,8 @@ func (a ServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of ServingEndpoint in the Terraform plugin framework type +// system. func (a ServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2698,10 +3283,19 @@ func (newState *ServingEndpointAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *ServingEndpointAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState ServingEndpointAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ServingEndpointAccessControlRequest in the Terraform plugin framework type +// system. func (a ServingEndpointAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2732,12 +3326,21 @@ func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *ServingEndpointAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState ServingEndpointAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(ServingEndpointPermission{}), } } +// ToAttrType returns the representation of ServingEndpointAccessControlResponse in the Terraform plugin framework type +// system. func (a ServingEndpointAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2794,6 +3397,13 @@ func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ServingEndpointDetailed) SyncEffectiveFieldsDuringRead(existingState ServingEndpointDetailed) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointDetailed. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointDetailed) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ai_gateway": reflect.TypeOf(AiGatewayConfig{}), @@ -2805,6 +3415,8 @@ func (a ServingEndpointDetailed) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of ServingEndpointDetailed in the Terraform plugin framework type +// system. func (a ServingEndpointDetailed) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2853,12 +3465,21 @@ func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ServingEndpointPermission) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ServingEndpointPermission in the Terraform plugin framework type +// system. func (a ServingEndpointPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2885,12 +3506,21 @@ func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ServingEndpointPermissions) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ServingEndpointAccessControlResponse{}), } } +// ToAttrType returns the representation of ServingEndpointPermissions in the Terraform plugin framework type +// system. func (a ServingEndpointPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2915,10 +3545,19 @@ func (newState *ServingEndpointPermissionsDescription) SyncEffectiveFieldsDuring func (newState *ServingEndpointPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ServingEndpointPermissionsDescription in the Terraform plugin framework type +// system. func (a ServingEndpointPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2940,12 +3579,21 @@ func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *ServingEndpointPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState ServingEndpointPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServingEndpointPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(ServingEndpointAccessControlRequest{}), } } +// ToAttrType returns the representation of ServingEndpointPermissionsRequest in the Terraform plugin framework type +// system. func (a ServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2968,12 +3616,21 @@ func (newState *TrafficConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Traf func (newState *TrafficConfig) SyncEffectiveFieldsDuringRead(existingState TrafficConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TrafficConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TrafficConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "routes": reflect.TypeOf(Route{}), } } +// ToAttrType returns the representation of TrafficConfig in the Terraform plugin framework type +// system. func (a TrafficConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3003,12 +3660,21 @@ func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *V1ResponseChoiceElement) SyncEffectiveFieldsDuringRead(existingState V1ResponseChoiceElement) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in V1ResponseChoiceElement. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a V1ResponseChoiceElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "message": reflect.TypeOf(ChatMessage{}), } } +// ToAttrType returns the representation of V1ResponseChoiceElement in the Terraform plugin framework type +// system. func (a V1ResponseChoiceElement) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 669238568e..a498c70321 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -29,10 +29,19 @@ func (newState *AibiDashboardEmbeddingAccessPolicy) SyncEffectiveFieldsDuringCre func (newState *AibiDashboardEmbeddingAccessPolicy) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingAccessPolicy) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AibiDashboardEmbeddingAccessPolicy. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AibiDashboardEmbeddingAccessPolicy in the Terraform plugin framework type +// system. func (a AibiDashboardEmbeddingAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -65,12 +74,21 @@ func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDu func (newState *AibiDashboardEmbeddingAccessPolicySetting) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingAccessPolicySetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AibiDashboardEmbeddingAccessPolicySetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aibi_dashboard_embedding_access_policy": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicy{}), } } +// ToAttrType returns the representation of AibiDashboardEmbeddingAccessPolicySetting in the Terraform plugin framework type +// system. func (a AibiDashboardEmbeddingAccessPolicySetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -93,12 +111,21 @@ func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuring func (newState *AibiDashboardEmbeddingApprovedDomains) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingApprovedDomains) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AibiDashboardEmbeddingApprovedDomains. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "approved_domains": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of AibiDashboardEmbeddingApprovedDomains in the Terraform plugin framework type +// system. func (a AibiDashboardEmbeddingApprovedDomains) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -133,12 +160,21 @@ func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveField func (newState *AibiDashboardEmbeddingApprovedDomainsSetting) SyncEffectiveFieldsDuringRead(existingState AibiDashboardEmbeddingApprovedDomainsSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AibiDashboardEmbeddingApprovedDomainsSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aibi_dashboard_embedding_approved_domains": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomains{}), } } +// ToAttrType returns the representation of AibiDashboardEmbeddingApprovedDomainsSetting in the Terraform plugin framework type +// system. func (a AibiDashboardEmbeddingApprovedDomainsSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -175,12 +211,21 @@ func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringCreateOr func (newState *AutomaticClusterUpdateSetting) SyncEffectiveFieldsDuringRead(existingState AutomaticClusterUpdateSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AutomaticClusterUpdateSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "automatic_cluster_update_workspace": reflect.TypeOf(ClusterAutoRestartMessage{}), } } +// ToAttrType returns the representation of AutomaticClusterUpdateSetting in the Terraform plugin framework type +// system. func (a AutomaticClusterUpdateSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -203,10 +248,19 @@ func (newState *BooleanMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Boo func (newState *BooleanMessage) SyncEffectiveFieldsDuringRead(existingState BooleanMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BooleanMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BooleanMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of BooleanMessage in the Terraform plugin framework type +// system. func (a BooleanMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -238,6 +292,13 @@ func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ClusterAutoRestartMessage) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAutoRestartMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAutoRestartMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "enablement_details": reflect.TypeOf(ClusterAutoRestartMessageEnablementDetails{}), @@ -245,6 +306,8 @@ func (a ClusterAutoRestartMessage) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of ClusterAutoRestartMessage in the Terraform plugin framework type +// system. func (a ClusterAutoRestartMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -283,10 +346,19 @@ func (newState *ClusterAutoRestartMessageEnablementDetails) SyncEffectiveFieldsD func (newState *ClusterAutoRestartMessageEnablementDetails) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageEnablementDetails) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAutoRestartMessageEnablementDetails. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterAutoRestartMessageEnablementDetails in the Terraform plugin framework type +// system. func (a ClusterAutoRestartMessageEnablementDetails) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -307,12 +379,21 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsD func (newState *ClusterAutoRestartMessageMaintenanceWindow) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindow) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAutoRestartMessageMaintenanceWindow. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "week_day_based_schedule": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}), } } +// ToAttrType returns the representation of ClusterAutoRestartMessageMaintenanceWindow in the Terraform plugin framework type +// system. func (a ClusterAutoRestartMessageMaintenanceWindow) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -337,12 +418,21 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) func (newState *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "window_start_time": reflect.TypeOf(ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}), } } +// ToAttrType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule in the Terraform plugin framework type +// system. func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -367,10 +457,19 @@ func (newState *ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) SyncE func (newState *ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) SyncEffectiveFieldsDuringRead(existingState ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ClusterAutoRestartMessageMaintenanceWindowWindowStartTime. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWindowStartTime in the Terraform plugin framework type +// system. func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -394,12 +493,21 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existingState ComplianceSecurityProfile) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ComplianceSecurityProfile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "compliance_standards": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ComplianceSecurityProfile in the Terraform plugin framework type +// system. func (a ComplianceSecurityProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -436,12 +544,21 @@ func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringCreat func (newState *ComplianceSecurityProfileSetting) SyncEffectiveFieldsDuringRead(existingState ComplianceSecurityProfileSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ComplianceSecurityProfileSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "compliance_security_profile_workspace": reflect.TypeOf(ComplianceSecurityProfile{}), } } +// ToAttrType returns the representation of ComplianceSecurityProfileSetting in the Terraform plugin framework type +// system. func (a ComplianceSecurityProfileSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -472,6 +589,13 @@ func (newState *Config) SyncEffectiveFieldsDuringCreateOrUpdate(plan Config) { func (newState *Config) SyncEffectiveFieldsDuringRead(existingState Config) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Config. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Config) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "email": reflect.TypeOf(EmailConfig{}), @@ -482,6 +606,8 @@ func (a Config) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } +// ToAttrType returns the representation of Config in the Terraform plugin framework type +// system. func (a Config) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -524,12 +650,21 @@ func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateIpAccessList) SyncEffectiveFieldsDuringRead(existingState CreateIpAccessList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateIpAccessList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of CreateIpAccessList in the Terraform plugin framework type +// system. func (a CreateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -554,12 +689,21 @@ func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState CreateIpAccessListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateIpAccessListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } } +// ToAttrType returns the representation of CreateIpAccessListResponse in the Terraform plugin framework type +// system. func (a CreateIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -588,10 +732,19 @@ func (newState *CreateNetworkConnectivityConfigRequest) SyncEffectiveFieldsDurin func (newState *CreateNetworkConnectivityConfigRequest) SyncEffectiveFieldsDuringRead(existingState CreateNetworkConnectivityConfigRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateNetworkConnectivityConfigRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateNetworkConnectivityConfigRequest in the Terraform plugin framework type +// system. func (a CreateNetworkConnectivityConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -615,12 +768,21 @@ func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *CreateNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState CreateNotificationDestinationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateNotificationDestinationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(Config{}), } } +// ToAttrType returns the representation of CreateNotificationDestinationRequest in the Terraform plugin framework type +// system. func (a CreateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -648,10 +810,19 @@ func (newState *CreateOboTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *CreateOboTokenRequest) SyncEffectiveFieldsDuringRead(existingState CreateOboTokenRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateOboTokenRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateOboTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateOboTokenRequest in the Terraform plugin framework type +// system. func (a CreateOboTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -675,12 +846,21 @@ func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateOboTokenResponse) SyncEffectiveFieldsDuringRead(existingState CreateOboTokenResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateOboTokenResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateOboTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_info": reflect.TypeOf(TokenInfo{}), } } +// ToAttrType returns the representation of CreateOboTokenResponse in the Terraform plugin framework type +// system. func (a CreateOboTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -709,10 +889,19 @@ func (newState *CreatePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreat func (newState *CreatePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState CreatePrivateEndpointRuleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreatePrivateEndpointRuleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreatePrivateEndpointRuleRequest in the Terraform plugin framework type +// system. func (a CreatePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -738,10 +927,19 @@ func (newState *CreateTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateTokenRequest) SyncEffectiveFieldsDuringRead(existingState CreateTokenRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateTokenRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateTokenRequest in the Terraform plugin framework type +// system. func (a CreateTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -764,12 +962,21 @@ func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateTokenResponse) SyncEffectiveFieldsDuringRead(existingState CreateTokenResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateTokenResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_info": reflect.TypeOf(PublicTokenInfo{}), } } +// ToAttrType returns the representation of CreateTokenResponse in the Terraform plugin framework type +// system. func (a CreateTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -796,12 +1003,21 @@ func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *CspEnablementAccount) SyncEffectiveFieldsDuringRead(existingState CspEnablementAccount) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CspEnablementAccount. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CspEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "compliance_standards": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of CspEnablementAccount in the Terraform plugin framework type +// system. func (a CspEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -838,12 +1054,21 @@ func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringCreateOrUp func (newState *CspEnablementAccountSetting) SyncEffectiveFieldsDuringRead(existingState CspEnablementAccountSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CspEnablementAccountSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CspEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "csp_enablement_account": reflect.TypeOf(CspEnablementAccount{}), } } +// ToAttrType returns the representation of CspEnablementAccountSetting in the Terraform plugin framework type +// system. func (a CspEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -890,12 +1115,21 @@ func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DefaultNamespaceSetting) SyncEffectiveFieldsDuringRead(existingState DefaultNamespaceSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DefaultNamespaceSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DefaultNamespaceSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "namespace": reflect.TypeOf(StringMessage{}), } } +// ToAttrType returns the representation of DefaultNamespaceSetting in the Terraform plugin framework type +// system. func (a DefaultNamespaceSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -920,10 +1154,19 @@ func (newState *DeleteAccountIpAccessListRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteAccountIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAccountIpAccessListRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAccountIpAccessListRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAccountIpAccessListRequest in the Terraform plugin framework type +// system. func (a DeleteAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -950,10 +1193,19 @@ func (newState *DeleteDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringC func (newState *DeleteDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDefaultNamespaceSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDefaultNamespaceSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDefaultNamespaceSettingRequest in the Terraform plugin framework type +// system. func (a DeleteDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -980,10 +1232,19 @@ func (newState *DeleteDefaultNamespaceSettingResponse) SyncEffectiveFieldsDuring func (newState *DeleteDefaultNamespaceSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDefaultNamespaceSettingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDefaultNamespaceSettingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDefaultNamespaceSettingResponse in the Terraform plugin framework type +// system. func (a DeleteDefaultNamespaceSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1010,10 +1271,19 @@ func (newState *DeleteDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreat func (newState *DeleteDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyAccessRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDisableLegacyAccessRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDisableLegacyAccessRequest in the Terraform plugin framework type +// system. func (a DeleteDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1040,10 +1310,19 @@ func (newState *DeleteDisableLegacyAccessResponse) SyncEffectiveFieldsDuringCrea func (newState *DeleteDisableLegacyAccessResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyAccessResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDisableLegacyAccessResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDisableLegacyAccessResponse in the Terraform plugin framework type +// system. func (a DeleteDisableLegacyAccessResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1070,10 +1349,19 @@ func (newState *DeleteDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateO func (newState *DeleteDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyDbfsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDisableLegacyDbfsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDisableLegacyDbfsRequest in the Terraform plugin framework type +// system. func (a DeleteDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1100,10 +1388,19 @@ func (newState *DeleteDisableLegacyDbfsResponse) SyncEffectiveFieldsDuringCreate func (newState *DeleteDisableLegacyDbfsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyDbfsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDisableLegacyDbfsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDisableLegacyDbfsResponse in the Terraform plugin framework type +// system. func (a DeleteDisableLegacyDbfsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1130,10 +1427,19 @@ func (newState *DeleteDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCre func (newState *DeleteDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyFeaturesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDisableLegacyFeaturesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDisableLegacyFeaturesRequest in the Terraform plugin framework type +// system. func (a DeleteDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1160,10 +1466,19 @@ func (newState *DeleteDisableLegacyFeaturesResponse) SyncEffectiveFieldsDuringCr func (newState *DeleteDisableLegacyFeaturesResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDisableLegacyFeaturesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDisableLegacyFeaturesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDisableLegacyFeaturesResponse in the Terraform plugin framework type +// system. func (a DeleteDisableLegacyFeaturesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1184,10 +1499,19 @@ func (newState *DeleteIpAccessListRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState DeleteIpAccessListRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteIpAccessListRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteIpAccessListRequest in the Terraform plugin framework type +// system. func (a DeleteIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1208,10 +1532,19 @@ func (newState *DeleteNetworkConnectivityConfigurationRequest) SyncEffectiveFiel func (newState *DeleteNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkConnectivityConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteNetworkConnectivityConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteNetworkConnectivityConfigurationRequest in the Terraform plugin framework type +// system. func (a DeleteNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1229,10 +1562,19 @@ func (newState *DeleteNetworkConnectivityConfigurationResponse) SyncEffectiveFie func (newState *DeleteNetworkConnectivityConfigurationResponse) SyncEffectiveFieldsDuringRead(existingState DeleteNetworkConnectivityConfigurationResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteNetworkConnectivityConfigurationResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteNetworkConnectivityConfigurationResponse in the Terraform plugin framework type +// system. func (a DeleteNetworkConnectivityConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1250,10 +1592,19 @@ func (newState *DeleteNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *DeleteNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteNotificationDestinationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteNotificationDestinationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteNotificationDestinationRequest in the Terraform plugin framework type +// system. func (a DeleteNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1280,10 +1631,19 @@ func (newState *DeletePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCr func (newState *DeletePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeletePersonalComputeSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePersonalComputeSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePersonalComputeSettingRequest in the Terraform plugin framework type +// system. func (a DeletePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1310,10 +1670,19 @@ func (newState *DeletePersonalComputeSettingResponse) SyncEffectiveFieldsDuringC func (newState *DeletePersonalComputeSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeletePersonalComputeSettingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePersonalComputeSettingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePersonalComputeSettingResponse in the Terraform plugin framework type +// system. func (a DeletePersonalComputeSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1336,10 +1705,19 @@ func (newState *DeletePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreat func (newState *DeletePrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState DeletePrivateEndpointRuleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeletePrivateEndpointRuleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeletePrivateEndpointRuleRequest in the Terraform plugin framework type +// system. func (a DeletePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1358,10 +1736,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1386,10 +1773,19 @@ func (newState *DeleteRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (newState *DeleteRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRestrictWorkspaceAdminsSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRestrictWorkspaceAdminsSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type +// system. func (a DeleteRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1416,10 +1812,19 @@ func (newState *DeleteRestrictWorkspaceAdminsSettingResponse) SyncEffectiveField func (newState *DeleteRestrictWorkspaceAdminsSettingResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRestrictWorkspaceAdminsSettingResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRestrictWorkspaceAdminsSettingResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRestrictWorkspaceAdminsSettingResponse in the Terraform plugin framework type +// system. func (a DeleteRestrictWorkspaceAdminsSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1440,10 +1845,19 @@ func (newState *DeleteTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTokenManagementRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTokenManagementRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteTokenManagementRequest in the Terraform plugin framework type +// system. func (a DeleteTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1476,12 +1890,21 @@ func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DisableLegacyAccess) SyncEffectiveFieldsDuringRead(existingState DisableLegacyAccess) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DisableLegacyAccess. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DisableLegacyAccess) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disable_legacy_access": reflect.TypeOf(BooleanMessage{}), } } +// ToAttrType returns the representation of DisableLegacyAccess in the Terraform plugin framework type +// system. func (a DisableLegacyAccess) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1518,12 +1941,21 @@ func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DisableLegacyDbfs) SyncEffectiveFieldsDuringRead(existingState DisableLegacyDbfs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DisableLegacyDbfs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DisableLegacyDbfs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disable_legacy_dbfs": reflect.TypeOf(BooleanMessage{}), } } +// ToAttrType returns the representation of DisableLegacyDbfs in the Terraform plugin framework type +// system. func (a DisableLegacyDbfs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1560,12 +1992,21 @@ func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DisableLegacyFeatures) SyncEffectiveFieldsDuringRead(existingState DisableLegacyFeatures) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DisableLegacyFeatures. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DisableLegacyFeatures) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "disable_legacy_features": reflect.TypeOf(BooleanMessage{}), } } +// ToAttrType returns the representation of DisableLegacyFeatures in the Terraform plugin framework type +// system. func (a DisableLegacyFeatures) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1589,12 +2030,21 @@ func (newState *EmailConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan EmailC func (newState *EmailConfig) SyncEffectiveFieldsDuringRead(existingState EmailConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EmailConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EmailConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of EmailConfig in the Terraform plugin framework type +// system. func (a EmailConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1614,10 +2064,19 @@ func (newState *Empty) SyncEffectiveFieldsDuringCreateOrUpdate(plan Empty) { func (newState *Empty) SyncEffectiveFieldsDuringRead(existingState Empty) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Empty. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Empty in the Terraform plugin framework type +// system. func (a Empty) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1635,10 +2094,19 @@ func (newState *EnhancedSecurityMonitoring) SyncEffectiveFieldsDuringCreateOrUpd func (newState *EnhancedSecurityMonitoring) SyncEffectiveFieldsDuringRead(existingState EnhancedSecurityMonitoring) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnhancedSecurityMonitoring. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnhancedSecurityMonitoring) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EnhancedSecurityMonitoring in the Terraform plugin framework type +// system. func (a EnhancedSecurityMonitoring) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1672,12 +2140,21 @@ func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringCrea func (newState *EnhancedSecurityMonitoringSetting) SyncEffectiveFieldsDuringRead(existingState EnhancedSecurityMonitoringSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnhancedSecurityMonitoringSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "enhanced_security_monitoring_workspace": reflect.TypeOf(EnhancedSecurityMonitoring{}), } } +// ToAttrType returns the representation of EnhancedSecurityMonitoringSetting in the Terraform plugin framework type +// system. func (a EnhancedSecurityMonitoringSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1701,10 +2178,19 @@ func (newState *EsmEnablementAccount) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EsmEnablementAccount) SyncEffectiveFieldsDuringRead(existingState EsmEnablementAccount) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EsmEnablementAccount. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EsmEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EsmEnablementAccount in the Terraform plugin framework type +// system. func (a EsmEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1738,12 +2224,21 @@ func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringCreateOrUp func (newState *EsmEnablementAccountSetting) SyncEffectiveFieldsDuringRead(existingState EsmEnablementAccountSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EsmEnablementAccountSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EsmEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "esm_enablement_account": reflect.TypeOf(EsmEnablementAccount{}), } } +// ToAttrType returns the representation of EsmEnablementAccountSetting in the Terraform plugin framework type +// system. func (a EsmEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1777,12 +2272,21 @@ func (newState *ExchangeToken) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exch func (newState *ExchangeToken) SyncEffectiveFieldsDuringRead(existingState ExchangeToken) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExchangeToken. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExchangeToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "scopes": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ExchangeToken in the Terraform plugin framework type +// system. func (a ExchangeToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1813,6 +2317,13 @@ func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ExchangeTokenRequest) SyncEffectiveFieldsDuringRead(existingState ExchangeTokenRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExchangeTokenRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "partitionId": reflect.TypeOf(PartitionId{}), @@ -1821,6 +2332,8 @@ func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of ExchangeTokenRequest in the Terraform plugin framework type +// system. func (a ExchangeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1848,12 +2361,21 @@ func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ExchangeTokenResponse) SyncEffectiveFieldsDuringRead(existingState ExchangeTokenResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExchangeTokenResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExchangeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(ExchangeToken{}), } } +// ToAttrType returns the representation of ExchangeTokenResponse in the Terraform plugin framework type +// system. func (a ExchangeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1876,12 +2398,21 @@ func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *FetchIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState FetchIpAccessListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in FetchIpAccessListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a FetchIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } } +// ToAttrType returns the representation of FetchIpAccessListResponse in the Terraform plugin framework type +// system. func (a FetchIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1913,10 +2444,19 @@ func (newState *GenericWebhookConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GenericWebhookConfig) SyncEffectiveFieldsDuringRead(existingState GenericWebhookConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GenericWebhookConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GenericWebhookConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GenericWebhookConfig in the Terraform plugin framework type +// system. func (a GenericWebhookConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1942,10 +2482,19 @@ func (newState *GetAccountIpAccessListRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetAccountIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState GetAccountIpAccessListRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAccountIpAccessListRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAccountIpAccessListRequest in the Terraform plugin framework type +// system. func (a GetAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1972,10 +2521,19 @@ func (newState *GetAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffecti func (newState *GetAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAibiDashboardEmbeddingAccessPolicySettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAibiDashboardEmbeddingAccessPolicySettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type +// system. func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2002,10 +2560,19 @@ func (newState *GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffe func (newState *GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAibiDashboardEmbeddingApprovedDomainsSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type +// system. func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2032,10 +2599,19 @@ func (newState *GetAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuri func (newState *GetAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetAutomaticClusterUpdateSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAutomaticClusterUpdateSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type +// system. func (a GetAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2062,10 +2638,19 @@ func (newState *GetComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsD func (newState *GetComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetComplianceSecurityProfileSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetComplianceSecurityProfileSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetComplianceSecurityProfileSettingRequest in the Terraform plugin framework type +// system. func (a GetComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2092,10 +2677,19 @@ func (newState *GetCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuring func (newState *GetCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetCspEnablementAccountSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCspEnablementAccountSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCspEnablementAccountSettingRequest in the Terraform plugin framework type +// system. func (a GetCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2122,10 +2716,19 @@ func (newState *GetDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringCrea func (newState *GetDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetDefaultNamespaceSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDefaultNamespaceSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDefaultNamespaceSettingRequest in the Terraform plugin framework type +// system. func (a GetDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2152,10 +2755,19 @@ func (newState *GetDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyAccessRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDisableLegacyAccessRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDisableLegacyAccessRequest in the Terraform plugin framework type +// system. func (a GetDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2182,10 +2794,19 @@ func (newState *GetDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyDbfsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDisableLegacyDbfsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDisableLegacyDbfsRequest in the Terraform plugin framework type +// system. func (a GetDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2212,10 +2833,19 @@ func (newState *GetDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCreate func (newState *GetDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState GetDisableLegacyFeaturesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDisableLegacyFeaturesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDisableLegacyFeaturesRequest in the Terraform plugin framework type +// system. func (a GetDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2242,10 +2872,19 @@ func (newState *GetEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFields func (newState *GetEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetEnhancedSecurityMonitoringSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEnhancedSecurityMonitoringSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type +// system. func (a GetEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2272,10 +2911,19 @@ func (newState *GetEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuring func (newState *GetEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetEsmEnablementAccountSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEsmEnablementAccountSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetEsmEnablementAccountSettingRequest in the Terraform plugin framework type +// system. func (a GetEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2296,10 +2944,19 @@ func (newState *GetIpAccessListRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetIpAccessListRequest) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetIpAccessListRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetIpAccessListRequest in the Terraform plugin framework type +// system. func (a GetIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2319,12 +2976,21 @@ func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetIpAccessListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessListInfo{}), } } +// ToAttrType returns the representation of GetIpAccessListResponse in the Terraform plugin framework type +// system. func (a GetIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2346,12 +3012,21 @@ func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *GetIpAccessListsResponse) SyncEffectiveFieldsDuringRead(existingState GetIpAccessListsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetIpAccessListsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetIpAccessListsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_lists": reflect.TypeOf(IpAccessListInfo{}), } } +// ToAttrType returns the representation of GetIpAccessListsResponse in the Terraform plugin framework type +// system. func (a GetIpAccessListsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2374,10 +3049,19 @@ func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsD func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringRead(existingState GetNetworkConnectivityConfigurationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetNetworkConnectivityConfigurationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetNetworkConnectivityConfigurationRequest in the Terraform plugin framework type +// system. func (a GetNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2397,10 +3081,19 @@ func (newState *GetNotificationDestinationRequest) SyncEffectiveFieldsDuringCrea func (newState *GetNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState GetNotificationDestinationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetNotificationDestinationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetNotificationDestinationRequest in the Terraform plugin framework type +// system. func (a GetNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2427,10 +3120,19 @@ func (newState *GetPersonalComputeSettingRequest) SyncEffectiveFieldsDuringCreat func (newState *GetPersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetPersonalComputeSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPersonalComputeSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPersonalComputeSettingRequest in the Terraform plugin framework type +// system. func (a GetPersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2453,10 +3155,19 @@ func (newState *GetPrivateEndpointRuleRequest) SyncEffectiveFieldsDuringCreateOr func (newState *GetPrivateEndpointRuleRequest) SyncEffectiveFieldsDuringRead(existingState GetPrivateEndpointRuleRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetPrivateEndpointRuleRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetPrivateEndpointRuleRequest in the Terraform plugin framework type +// system. func (a GetPrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2484,10 +3195,19 @@ func (newState *GetRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDur func (newState *GetRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState GetRestrictWorkspaceAdminsSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRestrictWorkspaceAdminsSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type +// system. func (a GetRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2507,10 +3227,19 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStatusRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStatusRequest in the Terraform plugin framework type +// system. func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2531,10 +3260,19 @@ func (newState *GetTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState GetTokenManagementRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetTokenManagementRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetTokenManagementRequest in the Terraform plugin framework type +// system. func (a GetTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2554,12 +3292,21 @@ func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringCreat func (newState *GetTokenPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetTokenPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetTokenPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(TokenPermissionsDescription{}), } } +// ToAttrType returns the representation of GetTokenPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetTokenPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2581,12 +3328,21 @@ func (newState *GetTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetTokenResponse) SyncEffectiveFieldsDuringRead(existingState GetTokenResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetTokenResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_info": reflect.TypeOf(TokenInfo{}), } } +// ToAttrType returns the representation of GetTokenResponse in the Terraform plugin framework type +// system. func (a GetTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2632,12 +3388,21 @@ func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan I func (newState *IpAccessListInfo) SyncEffectiveFieldsDuringRead(existingState IpAccessListInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in IpAccessListInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a IpAccessListInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of IpAccessListInfo in the Terraform plugin framework type +// system. func (a IpAccessListInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2668,12 +3433,21 @@ func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListIpAccessListResponse) SyncEffectiveFieldsDuringRead(existingState ListIpAccessListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListIpAccessListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_lists": reflect.TypeOf(IpAccessListInfo{}), } } +// ToAttrType returns the representation of ListIpAccessListResponse in the Terraform plugin framework type +// system. func (a ListIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2697,12 +3471,21 @@ func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDur func (newState *ListNccAzurePrivateEndpointRulesResponse) SyncEffectiveFieldsDuringRead(existingState ListNccAzurePrivateEndpointRulesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNccAzurePrivateEndpointRulesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "items": reflect.TypeOf(NccAzurePrivateEndpointRule{}), } } +// ToAttrType returns the representation of ListNccAzurePrivateEndpointRulesResponse in the Terraform plugin framework type +// system. func (a ListNccAzurePrivateEndpointRulesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2726,10 +3509,19 @@ func (newState *ListNetworkConnectivityConfigurationsRequest) SyncEffectiveField func (newState *ListNetworkConnectivityConfigurationsRequest) SyncEffectiveFieldsDuringRead(existingState ListNetworkConnectivityConfigurationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNetworkConnectivityConfigurationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListNetworkConnectivityConfigurationsRequest in the Terraform plugin framework type +// system. func (a ListNetworkConnectivityConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2751,12 +3543,21 @@ func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFiel func (newState *ListNetworkConnectivityConfigurationsResponse) SyncEffectiveFieldsDuringRead(existingState ListNetworkConnectivityConfigurationsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNetworkConnectivityConfigurationsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "items": reflect.TypeOf(NetworkConnectivityConfiguration{}), } } +// ToAttrType returns the representation of ListNetworkConnectivityConfigurationsResponse in the Terraform plugin framework type +// system. func (a ListNetworkConnectivityConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2781,10 +3582,19 @@ func (newState *ListNotificationDestinationsRequest) SyncEffectiveFieldsDuringCr func (newState *ListNotificationDestinationsRequest) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNotificationDestinationsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNotificationDestinationsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListNotificationDestinationsRequest in the Terraform plugin framework type +// system. func (a ListNotificationDestinationsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2807,12 +3617,21 @@ func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringC func (newState *ListNotificationDestinationsResponse) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNotificationDestinationsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNotificationDestinationsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ListNotificationDestinationsResult{}), } } +// ToAttrType returns the representation of ListNotificationDestinationsResponse in the Terraform plugin framework type +// system. func (a ListNotificationDestinationsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2840,10 +3659,19 @@ func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringCre func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResult) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNotificationDestinationsResult. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListNotificationDestinationsResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListNotificationDestinationsResult in the Terraform plugin framework type +// system. func (a ListNotificationDestinationsResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2868,10 +3696,19 @@ func (newState *ListPrivateEndpointRulesRequest) SyncEffectiveFieldsDuringCreate func (newState *ListPrivateEndpointRulesRequest) SyncEffectiveFieldsDuringRead(existingState ListPrivateEndpointRulesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPrivateEndpointRulesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListPrivateEndpointRulesRequest in the Terraform plugin framework type +// system. func (a ListPrivateEndpointRulesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2892,12 +3729,21 @@ func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListPublicTokensResponse) SyncEffectiveFieldsDuringRead(existingState ListPublicTokensResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListPublicTokensResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListPublicTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_infos": reflect.TypeOf(PublicTokenInfo{}), } } +// ToAttrType returns the representation of ListPublicTokensResponse in the Terraform plugin framework type +// system. func (a ListPublicTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2922,10 +3768,19 @@ func (newState *ListTokenManagementRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListTokenManagementRequest) SyncEffectiveFieldsDuringRead(existingState ListTokenManagementRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTokenManagementRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListTokenManagementRequest in the Terraform plugin framework type +// system. func (a ListTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2947,12 +3802,21 @@ func (newState *ListTokensResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListTokensResponse) SyncEffectiveFieldsDuringRead(existingState ListTokensResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListTokensResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "token_infos": reflect.TypeOf(TokenInfo{}), } } +// ToAttrType returns the representation of ListTokensResponse in the Terraform plugin framework type +// system. func (a ListTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2976,10 +3840,19 @@ func (newState *MicrosoftTeamsConfig) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *MicrosoftTeamsConfig) SyncEffectiveFieldsDuringRead(existingState MicrosoftTeamsConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MicrosoftTeamsConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MicrosoftTeamsConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MicrosoftTeamsConfig in the Terraform plugin framework type +// system. func (a MicrosoftTeamsConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3003,12 +3876,21 @@ func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *NccAwsStableIpRule) SyncEffectiveFieldsDuringRead(existingState NccAwsStableIpRule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NccAwsStableIpRule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NccAwsStableIpRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "cidr_blocks": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of NccAwsStableIpRule in the Terraform plugin framework type +// system. func (a NccAwsStableIpRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3063,10 +3945,19 @@ func (newState *NccAzurePrivateEndpointRule) SyncEffectiveFieldsDuringCreateOrUp func (newState *NccAzurePrivateEndpointRule) SyncEffectiveFieldsDuringRead(existingState NccAzurePrivateEndpointRule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NccAzurePrivateEndpointRule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NccAzurePrivateEndpointRule in the Terraform plugin framework type +// system. func (a NccAzurePrivateEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3103,6 +3994,13 @@ func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringCreateOrUp func (newState *NccAzureServiceEndpointRule) SyncEffectiveFieldsDuringRead(existingState NccAzureServiceEndpointRule) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NccAzureServiceEndpointRule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "subnets": reflect.TypeOf(types.String{}), @@ -3110,6 +4008,8 @@ func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) m } } +// ToAttrType returns the representation of NccAzureServiceEndpointRule in the Terraform plugin framework type +// system. func (a NccAzureServiceEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3142,6 +4042,13 @@ func (newState *NccEgressConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Nc func (newState *NccEgressConfig) SyncEffectiveFieldsDuringRead(existingState NccEgressConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NccEgressConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NccEgressConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "default_rules": reflect.TypeOf(NccEgressDefaultRules{}), @@ -3149,6 +4056,8 @@ func (a NccEgressConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of NccEgressConfig in the Terraform plugin framework type +// system. func (a NccEgressConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3182,6 +4091,13 @@ func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *NccEgressDefaultRules) SyncEffectiveFieldsDuringRead(existingState NccEgressDefaultRules) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NccEgressDefaultRules. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NccEgressDefaultRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "aws_stable_ip_rule": reflect.TypeOf(NccAwsStableIpRule{}), @@ -3189,6 +4105,8 @@ func (a NccEgressDefaultRules) GetComplexFieldTypes(ctx context.Context) map[str } } +// ToAttrType returns the representation of NccEgressDefaultRules in the Terraform plugin framework type +// system. func (a NccEgressDefaultRules) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3214,12 +4132,21 @@ func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringRead(existingState NccEgressTargetRules) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NccEgressTargetRules. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NccEgressTargetRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "azure_private_endpoint_rules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), } } +// ToAttrType returns the representation of NccEgressTargetRules in the Terraform plugin framework type +// system. func (a NccEgressTargetRules) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3259,12 +4186,21 @@ func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringCreat func (newState *NetworkConnectivityConfiguration) SyncEffectiveFieldsDuringRead(existingState NetworkConnectivityConfiguration) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NetworkConnectivityConfiguration. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NetworkConnectivityConfiguration) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "egress_config": reflect.TypeOf(NccEgressConfig{}), } } +// ToAttrType returns the representation of NetworkConnectivityConfiguration in the Terraform plugin framework type +// system. func (a NetworkConnectivityConfiguration) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3301,12 +4237,21 @@ func (newState *NotificationDestination) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *NotificationDestination) SyncEffectiveFieldsDuringRead(existingState NotificationDestination) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NotificationDestination. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NotificationDestination) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(Config{}), } } +// ToAttrType returns the representation of NotificationDestination in the Terraform plugin framework type +// system. func (a NotificationDestination) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3333,10 +4278,19 @@ func (newState *PagerdutyConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pa func (newState *PagerdutyConfig) SyncEffectiveFieldsDuringRead(existingState PagerdutyConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PagerdutyConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PagerdutyConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PagerdutyConfig in the Terraform plugin framework type +// system. func (a PagerdutyConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3358,10 +4312,19 @@ func (newState *PartitionId) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partit func (newState *PartitionId) SyncEffectiveFieldsDuringRead(existingState PartitionId) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PartitionId. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PartitionId) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PartitionId in the Terraform plugin framework type +// system. func (a PartitionId) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3387,10 +4350,19 @@ func (newState *PersonalComputeMessage) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalComputeMessage) SyncEffectiveFieldsDuringRead(existingState PersonalComputeMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PersonalComputeMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PersonalComputeMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PersonalComputeMessage in the Terraform plugin framework type +// system. func (a PersonalComputeMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3424,12 +4396,21 @@ func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *PersonalComputeSetting) SyncEffectiveFieldsDuringRead(existingState PersonalComputeSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PersonalComputeSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PersonalComputeSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "personal_compute": reflect.TypeOf(PersonalComputeMessage{}), } } +// ToAttrType returns the representation of PersonalComputeSetting in the Terraform plugin framework type +// system. func (a PersonalComputeSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3460,10 +4441,19 @@ func (newState *PublicTokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Pu func (newState *PublicTokenInfo) SyncEffectiveFieldsDuringRead(existingState PublicTokenInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PublicTokenInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PublicTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PublicTokenInfo in the Terraform plugin framework type +// system. func (a PublicTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3500,12 +4490,21 @@ func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ReplaceIpAccessList) SyncEffectiveFieldsDuringRead(existingState ReplaceIpAccessList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReplaceIpAccessList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReplaceIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ReplaceIpAccessList in the Terraform plugin framework type +// system. func (a ReplaceIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3529,10 +4528,19 @@ func (newState *ReplaceResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *ReplaceResponse) SyncEffectiveFieldsDuringRead(existingState ReplaceResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ReplaceResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ReplaceResponse in the Terraform plugin framework type +// system. func (a ReplaceResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3549,10 +4557,19 @@ func (newState *RestrictWorkspaceAdminsMessage) SyncEffectiveFieldsDuringCreateO func (newState *RestrictWorkspaceAdminsMessage) SyncEffectiveFieldsDuringRead(existingState RestrictWorkspaceAdminsMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestrictWorkspaceAdminsMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestrictWorkspaceAdminsMessage in the Terraform plugin framework type +// system. func (a RestrictWorkspaceAdminsMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3586,12 +4603,21 @@ func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringCreateO func (newState *RestrictWorkspaceAdminsSetting) SyncEffectiveFieldsDuringRead(existingState RestrictWorkspaceAdminsSetting) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestrictWorkspaceAdminsSetting. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "restrict_workspace_admins": reflect.TypeOf(RestrictWorkspaceAdminsMessage{}), } } +// ToAttrType returns the representation of RestrictWorkspaceAdminsSetting in the Terraform plugin framework type +// system. func (a RestrictWorkspaceAdminsSetting) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3615,10 +4641,19 @@ func (newState *RevokeTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RevokeTokenRequest) SyncEffectiveFieldsDuringRead(existingState RevokeTokenRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RevokeTokenRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RevokeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RevokeTokenRequest in the Terraform plugin framework type +// system. func (a RevokeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3636,10 +4671,19 @@ func (newState *RevokeTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *RevokeTokenResponse) SyncEffectiveFieldsDuringRead(existingState RevokeTokenResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RevokeTokenResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RevokeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RevokeTokenResponse in the Terraform plugin framework type +// system. func (a RevokeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3655,10 +4699,19 @@ func (newState *SetStatusResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SetStatusResponse) SyncEffectiveFieldsDuringRead(existingState SetStatusResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetStatusResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetStatusResponse in the Terraform plugin framework type +// system. func (a SetStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -3678,10 +4731,19 @@ func (newState *SlackConfig) SyncEffectiveFieldsDuringCreateOrUpdate(plan SlackC func (newState *SlackConfig) SyncEffectiveFieldsDuringRead(existingState SlackConfig) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SlackConfig. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SlackConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SlackConfig in the Terraform plugin framework type +// system. func (a SlackConfig) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3702,10 +4764,19 @@ func (newState *StringMessage) SyncEffectiveFieldsDuringCreateOrUpdate(plan Stri func (newState *StringMessage) SyncEffectiveFieldsDuringRead(existingState StringMessage) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StringMessage. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StringMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StringMessage in the Terraform plugin framework type +// system. func (a StringMessage) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3731,10 +4802,19 @@ func (newState *TokenAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *TokenAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState TokenAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TokenAccessControlRequest in the Terraform plugin framework type +// system. func (a TokenAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3765,12 +4845,21 @@ func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *TokenAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState TokenAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(TokenPermission{}), } } +// ToAttrType returns the representation of TokenAccessControlResponse in the Terraform plugin framework type +// system. func (a TokenAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3814,10 +4903,19 @@ func (newState *TokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan TokenInf func (newState *TokenInfo) SyncEffectiveFieldsDuringRead(existingState TokenInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TokenInfo in the Terraform plugin framework type +// system. func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3848,12 +4946,21 @@ func (newState *TokenPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan To func (newState *TokenPermission) SyncEffectiveFieldsDuringRead(existingState TokenPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of TokenPermission in the Terraform plugin framework type +// system. func (a TokenPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3880,12 +4987,21 @@ func (newState *TokenPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan T func (newState *TokenPermissions) SyncEffectiveFieldsDuringRead(existingState TokenPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(TokenAccessControlResponse{}), } } +// ToAttrType returns the representation of TokenPermissions in the Terraform plugin framework type +// system. func (a TokenPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3910,10 +5026,19 @@ func (newState *TokenPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUp func (newState *TokenPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState TokenPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TokenPermissionsDescription in the Terraform plugin framework type +// system. func (a TokenPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3933,12 +5058,21 @@ func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *TokenPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState TokenPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TokenPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TokenPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(TokenAccessControlRequest{}), } } +// ToAttrType returns the representation of TokenPermissionsRequest in the Terraform plugin framework type +// system. func (a TokenPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3969,12 +5103,21 @@ func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffe func (newState *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAibiDashboardEmbeddingAccessPolicySettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(AibiDashboardEmbeddingAccessPolicySetting{}), } } +// ToAttrType returns the representation of UpdateAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type +// system. func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4007,12 +5150,21 @@ func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncE func (newState *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(AibiDashboardEmbeddingApprovedDomainsSetting{}), } } +// ToAttrType returns the representation of UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type +// system. func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4045,12 +5197,21 @@ func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsD func (newState *UpdateAutomaticClusterUpdateSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAutomaticClusterUpdateSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAutomaticClusterUpdateSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(AutomaticClusterUpdateSetting{}), } } +// ToAttrType returns the representation of UpdateAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type +// system. func (a UpdateAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4083,12 +5244,21 @@ func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFiel func (newState *UpdateComplianceSecurityProfileSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateComplianceSecurityProfileSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateComplianceSecurityProfileSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(ComplianceSecurityProfileSetting{}), } } +// ToAttrType returns the representation of UpdateComplianceSecurityProfileSettingRequest in the Terraform plugin framework type +// system. func (a UpdateComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4121,12 +5291,21 @@ func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (newState *UpdateCspEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCspEnablementAccountSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCspEnablementAccountSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(CspEnablementAccountSetting{}), } } +// ToAttrType returns the representation of UpdateCspEnablementAccountSettingRequest in the Terraform plugin framework type +// system. func (a UpdateCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4167,12 +5346,21 @@ func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringC func (newState *UpdateDefaultNamespaceSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDefaultNamespaceSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateDefaultNamespaceSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DefaultNamespaceSetting{}), } } +// ToAttrType returns the representation of UpdateDefaultNamespaceSettingRequest in the Terraform plugin framework type +// system. func (a UpdateDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4205,12 +5393,21 @@ func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringCreat func (newState *UpdateDisableLegacyAccessRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyAccessRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateDisableLegacyAccessRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DisableLegacyAccess{}), } } +// ToAttrType returns the representation of UpdateDisableLegacyAccessRequest in the Terraform plugin framework type +// system. func (a UpdateDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4243,12 +5440,21 @@ func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringCreateO func (newState *UpdateDisableLegacyDbfsRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyDbfsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateDisableLegacyDbfsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DisableLegacyDbfs{}), } } +// ToAttrType returns the representation of UpdateDisableLegacyDbfsRequest in the Terraform plugin framework type +// system. func (a UpdateDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4281,12 +5487,21 @@ func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringCre func (newState *UpdateDisableLegacyFeaturesRequest) SyncEffectiveFieldsDuringRead(existingState UpdateDisableLegacyFeaturesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateDisableLegacyFeaturesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(DisableLegacyFeatures{}), } } +// ToAttrType returns the representation of UpdateDisableLegacyFeaturesRequest in the Terraform plugin framework type +// system. func (a UpdateDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4319,12 +5534,21 @@ func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFie func (newState *UpdateEnhancedSecurityMonitoringSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateEnhancedSecurityMonitoringSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateEnhancedSecurityMonitoringSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(EnhancedSecurityMonitoringSetting{}), } } +// ToAttrType returns the representation of UpdateEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type +// system. func (a UpdateEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4357,12 +5581,21 @@ func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDur func (newState *UpdateEsmEnablementAccountSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateEsmEnablementAccountSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateEsmEnablementAccountSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(EsmEnablementAccountSetting{}), } } +// ToAttrType returns the representation of UpdateEsmEnablementAccountSettingRequest in the Terraform plugin framework type +// system. func (a UpdateEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4400,12 +5633,21 @@ func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateIpAccessList) SyncEffectiveFieldsDuringRead(existingState UpdateIpAccessList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateIpAccessList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpdateIpAccessList in the Terraform plugin framework type +// system. func (a UpdateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4436,12 +5678,21 @@ func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringC func (newState *UpdateNotificationDestinationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateNotificationDestinationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateNotificationDestinationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config": reflect.TypeOf(Config{}), } } +// ToAttrType returns the representation of UpdateNotificationDestinationRequest in the Terraform plugin framework type +// system. func (a UpdateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4474,12 +5725,21 @@ func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringCr func (newState *UpdatePersonalComputeSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdatePersonalComputeSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePersonalComputeSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(PersonalComputeSetting{}), } } +// ToAttrType returns the representation of UpdatePersonalComputeSettingRequest in the Terraform plugin framework type +// system. func (a UpdatePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4501,10 +5761,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4531,12 +5800,21 @@ func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFields func (newState *UpdateRestrictWorkspaceAdminsSettingRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRestrictWorkspaceAdminsSettingRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRestrictWorkspaceAdminsSettingRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "setting": reflect.TypeOf(RestrictWorkspaceAdminsSetting{}), } } +// ToAttrType returns the representation of UpdateRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type +// system. func (a UpdateRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index d65cca9f8a..d70988d86d 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -39,10 +39,19 @@ func (newState *CreateProvider) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateProvider) SyncEffectiveFieldsDuringRead(existingState CreateProvider) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateProvider. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateProvider) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateProvider in the Terraform plugin framework type +// system. func (a CreateProvider) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -85,6 +94,13 @@ func (newState *CreateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cr func (newState *CreateRecipient) SyncEffectiveFieldsDuringRead(existingState CreateRecipient) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRecipient. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessList{}), @@ -92,6 +108,8 @@ func (a CreateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of CreateRecipient in the Terraform plugin framework type +// system. func (a CreateRecipient) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -127,10 +145,19 @@ func (newState *CreateShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateShare) SyncEffectiveFieldsDuringRead(existingState CreateShare) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateShare. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateShare in the Terraform plugin framework type +// system. func (a CreateShare) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -153,10 +180,19 @@ func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteProviderRequest) SyncEffectiveFieldsDuringRead(existingState DeleteProviderRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteProviderRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteProviderRequest in the Terraform plugin framework type +// system. func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -177,10 +213,19 @@ func (newState *DeleteRecipientRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteRecipientRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRecipientRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRecipientRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRecipientRequest in the Terraform plugin framework type +// system. func (a DeleteRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -198,10 +243,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -220,10 +274,19 @@ func (newState *DeleteShareRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteShareRequest) SyncEffectiveFieldsDuringRead(existingState DeleteShareRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteShareRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteShareRequest in the Terraform plugin framework type +// system. func (a DeleteShareRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -244,10 +307,19 @@ func (newState *GetActivationUrlInfoRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *GetActivationUrlInfoRequest) SyncEffectiveFieldsDuringRead(existingState GetActivationUrlInfoRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetActivationUrlInfoRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetActivationUrlInfoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetActivationUrlInfoRequest in the Terraform plugin framework type +// system. func (a GetActivationUrlInfoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -265,10 +337,19 @@ func (newState *GetActivationUrlInfoResponse) SyncEffectiveFieldsDuringCreateOrU func (newState *GetActivationUrlInfoResponse) SyncEffectiveFieldsDuringRead(existingState GetActivationUrlInfoResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetActivationUrlInfoResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetActivationUrlInfoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetActivationUrlInfoResponse in the Terraform plugin framework type +// system. func (a GetActivationUrlInfoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -287,10 +368,19 @@ func (newState *GetProviderRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetProviderRequest) SyncEffectiveFieldsDuringRead(existingState GetProviderRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetProviderRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetProviderRequest in the Terraform plugin framework type +// system. func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -311,10 +401,19 @@ func (newState *GetRecipientRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetRecipientRequest) SyncEffectiveFieldsDuringRead(existingState GetRecipientRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRecipientRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRecipientRequest in the Terraform plugin framework type +// system. func (a GetRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -338,12 +437,21 @@ func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringC func (newState *GetRecipientSharePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState GetRecipientSharePermissionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRecipientSharePermissionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permissions_out": reflect.TypeOf(ShareToPrivilegeAssignment{}), } } +// ToAttrType returns the representation of GetRecipientSharePermissionsResponse in the Terraform plugin framework type +// system. func (a GetRecipientSharePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -369,10 +477,19 @@ func (newState *GetShareRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetShareRequest) SyncEffectiveFieldsDuringRead(existingState GetShareRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetShareRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetShareRequest in the Terraform plugin framework type +// system. func (a GetShareRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -393,12 +510,21 @@ func (newState *IpAccessList) SyncEffectiveFieldsDuringCreateOrUpdate(plan IpAcc func (newState *IpAccessList) SyncEffectiveFieldsDuringRead(existingState IpAccessList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in IpAccessList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a IpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "allowed_ip_addresses": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of IpAccessList in the Terraform plugin framework type +// system. func (a IpAccessList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -424,12 +550,21 @@ func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ListProviderSharesResponse) SyncEffectiveFieldsDuringRead(existingState ListProviderSharesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListProviderSharesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListProviderSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "shares": reflect.TypeOf(ProviderShare{}), } } +// ToAttrType returns the representation of ListProviderSharesResponse in the Terraform plugin framework type +// system. func (a ListProviderSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -466,10 +601,19 @@ func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListProvidersRequest) SyncEffectiveFieldsDuringRead(existingState ListProvidersRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListProvidersRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListProvidersRequest in the Terraform plugin framework type +// system. func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -495,12 +639,21 @@ func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListProvidersResponse) SyncEffectiveFieldsDuringRead(existingState ListProvidersResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListProvidersResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "providers": reflect.TypeOf(ProviderInfo{}), } } +// ToAttrType returns the representation of ListProvidersResponse in the Terraform plugin framework type +// system. func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -537,10 +690,19 @@ func (newState *ListRecipientsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListRecipientsRequest) SyncEffectiveFieldsDuringRead(existingState ListRecipientsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRecipientsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRecipientsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListRecipientsRequest in the Terraform plugin framework type +// system. func (a ListRecipientsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -566,12 +728,21 @@ func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListRecipientsResponse) SyncEffectiveFieldsDuringRead(existingState ListRecipientsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListRecipientsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListRecipientsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "recipients": reflect.TypeOf(RecipientInfo{}), } } +// ToAttrType returns the representation of ListRecipientsResponse in the Terraform plugin framework type +// system. func (a ListRecipientsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -607,10 +778,19 @@ func (newState *ListSharesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSharesRequest) SyncEffectiveFieldsDuringRead(existingState ListSharesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSharesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSharesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSharesRequest in the Terraform plugin framework type +// system. func (a ListSharesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -636,12 +816,21 @@ func (newState *ListSharesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSharesResponse) SyncEffectiveFieldsDuringRead(existingState ListSharesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSharesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "shares": reflect.TypeOf(ShareInfo{}), } } +// ToAttrType returns the representation of ListSharesResponse in the Terraform plugin framework type +// system. func (a ListSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -664,12 +853,21 @@ func (newState *Partition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Partitio func (newState *Partition) SyncEffectiveFieldsDuringRead(existingState Partition) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Partition. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Partition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(PartitionValue{}), } } +// ToAttrType returns the representation of Partition in the Terraform plugin framework type +// system. func (a Partition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -701,10 +899,19 @@ func (newState *PartitionValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Par func (newState *PartitionValue) SyncEffectiveFieldsDuringRead(existingState PartitionValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PartitionValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PartitionValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PartitionValue in the Terraform plugin framework type +// system. func (a PartitionValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -729,12 +936,21 @@ func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *PrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState PrivilegeAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PrivilegeAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privileges": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of PrivilegeAssignment in the Terraform plugin framework type +// system. func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -790,12 +1006,21 @@ func (newState *ProviderInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Provi func (newState *ProviderInfo) SyncEffectiveFieldsDuringRead(existingState ProviderInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ProviderInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "recipient_profile": reflect.TypeOf(RecipientProfile{}), } } +// ToAttrType returns the representation of ProviderInfo in the Terraform plugin framework type +// system. func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -830,10 +1055,19 @@ func (newState *ProviderShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Prov func (newState *ProviderShare) SyncEffectiveFieldsDuringRead(existingState ProviderShare) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ProviderShare. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ProviderShare) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ProviderShare in the Terraform plugin framework type +// system. func (a ProviderShare) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -896,6 +1130,13 @@ func (newState *RecipientInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Reci func (newState *RecipientInfo) SyncEffectiveFieldsDuringRead(existingState RecipientInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RecipientInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RecipientInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessList{}), @@ -904,6 +1145,8 @@ func (a RecipientInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl } } +// ToAttrType returns the representation of RecipientInfo in the Terraform plugin framework type +// system. func (a RecipientInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -950,10 +1193,19 @@ func (newState *RecipientProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RecipientProfile) SyncEffectiveFieldsDuringRead(existingState RecipientProfile) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RecipientProfile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RecipientProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RecipientProfile in the Terraform plugin framework type +// system. func (a RecipientProfile) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -988,10 +1240,19 @@ func (newState *RecipientTokenInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *RecipientTokenInfo) SyncEffectiveFieldsDuringRead(existingState RecipientTokenInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RecipientTokenInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RecipientTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RecipientTokenInfo in the Terraform plugin framework type +// system. func (a RecipientTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1018,10 +1279,19 @@ func (newState *RetrieveTokenRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RetrieveTokenRequest) SyncEffectiveFieldsDuringRead(existingState RetrieveTokenRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RetrieveTokenRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RetrieveTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RetrieveTokenRequest in the Terraform plugin framework type +// system. func (a RetrieveTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1047,10 +1317,19 @@ func (newState *RetrieveTokenResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *RetrieveTokenResponse) SyncEffectiveFieldsDuringRead(existingState RetrieveTokenResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RetrieveTokenResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RetrieveTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RetrieveTokenResponse in the Terraform plugin framework type +// system. func (a RetrieveTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1078,10 +1357,19 @@ func (newState *RotateRecipientToken) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *RotateRecipientToken) SyncEffectiveFieldsDuringRead(existingState RotateRecipientToken) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RotateRecipientToken. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RotateRecipientToken) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RotateRecipientToken in the Terraform plugin framework type +// system. func (a RotateRecipientToken) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1104,12 +1392,21 @@ func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringCreateOrUpd func (newState *SecurablePropertiesKvPairs) SyncEffectiveFieldsDuringRead(existingState SecurablePropertiesKvPairs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SecurablePropertiesKvPairs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SecurablePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "properties": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SecurablePropertiesKvPairs in the Terraform plugin framework type +// system. func (a SecurablePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1149,12 +1446,21 @@ func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInf func (newState *ShareInfo) SyncEffectiveFieldsDuringRead(existingState ShareInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ShareInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "object": reflect.TypeOf(SharedDataObject{}), } } +// ToAttrType returns the representation of ShareInfo in the Terraform plugin framework type +// system. func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1198,10 +1504,19 @@ func (newState *SharePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *SharePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState SharePermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SharePermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SharePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SharePermissionsRequest in the Terraform plugin framework type +// system. func (a SharePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1225,12 +1540,21 @@ func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringCreateOrUpd func (newState *ShareToPrivilegeAssignment) SyncEffectiveFieldsDuringRead(existingState ShareToPrivilegeAssignment) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ShareToPrivilegeAssignment. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ShareToPrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "privilege_assignments": reflect.TypeOf(PrivilegeAssignment{}), } } +// ToAttrType returns the representation of ShareToPrivilegeAssignment in the Terraform plugin framework type +// system. func (a ShareToPrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1298,12 +1622,21 @@ func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SharedDataObject. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "partition": reflect.TypeOf(Partition{}), } } +// ToAttrType returns the representation of SharedDataObject in the Terraform plugin framework type +// system. func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1339,12 +1672,21 @@ func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *SharedDataObjectUpdate) SyncEffectiveFieldsDuringRead(existingState SharedDataObjectUpdate) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SharedDataObjectUpdate. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SharedDataObjectUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_object": reflect.TypeOf(SharedDataObject{}), } } +// ToAttrType returns the representation of SharedDataObjectUpdate in the Terraform plugin framework type +// system. func (a SharedDataObjectUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1365,10 +1707,19 @@ func (newState *UpdatePermissionsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdatePermissionsResponse) SyncEffectiveFieldsDuringRead(existingState UpdatePermissionsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdatePermissionsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdatePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdatePermissionsResponse in the Terraform plugin framework type +// system. func (a UpdatePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1395,10 +1746,19 @@ func (newState *UpdateProvider) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateProvider) SyncEffectiveFieldsDuringRead(existingState UpdateProvider) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateProvider. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateProvider) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateProvider in the Terraform plugin framework type +// system. func (a UpdateProvider) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1437,6 +1797,13 @@ func (newState *UpdateRecipient) SyncEffectiveFieldsDuringCreateOrUpdate(plan Up func (newState *UpdateRecipient) SyncEffectiveFieldsDuringRead(existingState UpdateRecipient) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRecipient. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "ip_access_list": reflect.TypeOf(IpAccessList{}), @@ -1444,6 +1811,8 @@ func (a UpdateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } +// ToAttrType returns the representation of UpdateRecipient in the Terraform plugin framework type +// system. func (a UpdateRecipient) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1471,10 +1840,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1502,12 +1880,21 @@ func (newState *UpdateShare) SyncEffectiveFieldsDuringCreateOrUpdate(plan Update func (newState *UpdateShare) SyncEffectiveFieldsDuringRead(existingState UpdateShare) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateShare. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "updates": reflect.TypeOf(SharedDataObjectUpdate{}), } } +// ToAttrType returns the representation of UpdateShare in the Terraform plugin framework type +// system. func (a UpdateShare) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1548,12 +1935,21 @@ func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringRead(existingState UpdateSharePermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateSharePermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateSharePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "changes": reflect.TypeOf(catalog.PermissionsChange{}), } } +// ToAttrType returns the representation of UpdateSharePermissions in the Terraform plugin framework type +// system. func (a UpdateSharePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 8309eb5534..53bee6a24f 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -34,10 +34,19 @@ func (newState *AccessControl) SyncEffectiveFieldsDuringCreateOrUpdate(plan Acce func (newState *AccessControl) SyncEffectiveFieldsDuringRead(existingState AccessControl) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AccessControl. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AccessControl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AccessControl in the Terraform plugin framework type +// system. func (a AccessControl) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -100,12 +109,21 @@ func (newState *Alert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Alert) { func (newState *Alert) SyncEffectiveFieldsDuringRead(existingState Alert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Alert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Alert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } } +// ToAttrType returns the representation of Alert in the Terraform plugin framework type +// system. func (a Alert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -148,6 +166,13 @@ func (newState *AlertCondition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ale func (newState *AlertCondition) SyncEffectiveFieldsDuringRead(existingState AlertCondition) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertCondition. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertCondition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "operand": reflect.TypeOf(AlertConditionOperand{}), @@ -155,6 +180,8 @@ func (a AlertCondition) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of AlertCondition in the Terraform plugin framework type +// system. func (a AlertCondition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -180,12 +207,21 @@ func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *AlertConditionOperand) SyncEffectiveFieldsDuringRead(existingState AlertConditionOperand) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertConditionOperand. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertConditionOperand) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "column": reflect.TypeOf(AlertOperandColumn{}), } } +// ToAttrType returns the representation of AlertConditionOperand in the Terraform plugin framework type +// system. func (a AlertConditionOperand) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -206,12 +242,21 @@ func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *AlertConditionThreshold) SyncEffectiveFieldsDuringRead(existingState AlertConditionThreshold) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertConditionThreshold. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertConditionThreshold) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(AlertOperandValue{}), } } +// ToAttrType returns the representation of AlertConditionThreshold in the Terraform plugin framework type +// system. func (a AlertConditionThreshold) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -232,10 +277,19 @@ func (newState *AlertOperandColumn) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertOperandColumn) SyncEffectiveFieldsDuringRead(existingState AlertOperandColumn) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertOperandColumn. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertOperandColumn) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AlertOperandColumn in the Terraform plugin framework type +// system. func (a AlertOperandColumn) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -258,10 +312,19 @@ func (newState *AlertOperandValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *AlertOperandValue) SyncEffectiveFieldsDuringRead(existingState AlertOperandValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertOperandValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertOperandValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AlertOperandValue in the Terraform plugin framework type +// system. func (a AlertOperandValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -306,10 +369,19 @@ func (newState *AlertOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Alert func (newState *AlertOptions) SyncEffectiveFieldsDuringRead(existingState AlertOptions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertOptions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AlertOptions in the Terraform plugin framework type +// system. func (a AlertOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -372,6 +444,13 @@ func (newState *AlertQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertQu func (newState *AlertQuery) SyncEffectiveFieldsDuringRead(existingState AlertQuery) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AlertQuery. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(QueryOptions{}), @@ -379,6 +458,8 @@ func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of AlertQuery in the Terraform plugin framework type +// system. func (a AlertQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -424,10 +505,19 @@ func (newState *BaseChunkInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Base func (newState *BaseChunkInfo) SyncEffectiveFieldsDuringRead(existingState BaseChunkInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in BaseChunkInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a BaseChunkInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of BaseChunkInfo in the Terraform plugin framework type +// system. func (a BaseChunkInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -452,10 +542,19 @@ func (newState *CancelExecutionRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CancelExecutionRequest) SyncEffectiveFieldsDuringRead(existingState CancelExecutionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelExecutionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelExecutionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelExecutionRequest in the Terraform plugin framework type +// system. func (a CancelExecutionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -473,10 +572,19 @@ func (newState *CancelExecutionResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CancelExecutionResponse) SyncEffectiveFieldsDuringRead(existingState CancelExecutionResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CancelExecutionResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CancelExecutionResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CancelExecutionResponse in the Terraform plugin framework type +// system. func (a CancelExecutionResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -497,10 +605,19 @@ func (newState *Channel) SyncEffectiveFieldsDuringCreateOrUpdate(plan Channel) { func (newState *Channel) SyncEffectiveFieldsDuringRead(existingState Channel) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Channel. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Channel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Channel in the Terraform plugin framework type +// system. func (a Channel) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -524,10 +641,19 @@ func (newState *ChannelInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Channe func (newState *ChannelInfo) SyncEffectiveFieldsDuringRead(existingState ChannelInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ChannelInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ChannelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ChannelInfo in the Terraform plugin framework type +// system. func (a ChannelInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -563,10 +689,19 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ColumnInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ColumnInfo in the Terraform plugin framework type +// system. func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -602,12 +737,21 @@ func (newState *CreateAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateAlert) SyncEffectiveFieldsDuringRead(existingState CreateAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(AlertOptions{}), } } +// ToAttrType returns the representation of CreateAlert in the Terraform plugin framework type +// system. func (a CreateAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -632,12 +776,21 @@ func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateAlertRequest) SyncEffectiveFieldsDuringRead(existingState CreateAlertRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateAlertRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert": reflect.TypeOf(CreateAlertRequestAlert{}), } } +// ToAttrType returns the representation of CreateAlertRequest in the Terraform plugin framework type +// system. func (a CreateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -682,12 +835,21 @@ func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingState CreateAlertRequestAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateAlertRequestAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } } +// ToAttrType returns the representation of CreateAlertRequestAlert in the Terraform plugin framework type +// system. func (a CreateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -715,12 +877,21 @@ func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateQueryRequest) SyncEffectiveFieldsDuringRead(existingState CreateQueryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateQueryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(CreateQueryRequestQuery{}), } } +// ToAttrType returns the representation of CreateQueryRequest in the Terraform plugin framework type +// system. func (a CreateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -764,6 +935,13 @@ func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingState CreateQueryRequestQuery) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateQueryRequestQuery. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), @@ -771,6 +949,8 @@ func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of CreateQueryRequestQuery in the Terraform plugin framework type +// system. func (a CreateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -817,10 +997,19 @@ func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDurin func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState CreateQueryVisualizationsLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateQueryVisualizationsLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateQueryVisualizationsLegacyRequest in the Terraform plugin framework type +// system. func (a CreateQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -843,12 +1032,21 @@ func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *CreateVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState CreateVisualizationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateVisualizationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "visualization": reflect.TypeOf(CreateVisualizationRequestVisualization{}), } } +// ToAttrType returns the representation of CreateVisualizationRequest in the Terraform plugin framework type +// system. func (a CreateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -882,10 +1080,19 @@ func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuri func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuringRead(existingState CreateVisualizationRequestVisualization) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateVisualizationRequestVisualization. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateVisualizationRequestVisualization in the Terraform plugin framework type +// system. func (a CreateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -968,6 +1175,13 @@ func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *CreateWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState CreateWarehouseRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateWarehouseRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), @@ -975,6 +1189,8 @@ func (a CreateWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st } } +// ToAttrType returns the representation of CreateWarehouseRequest in the Terraform plugin framework type +// system. func (a CreateWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1010,10 +1226,19 @@ func (newState *CreateWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *CreateWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState CreateWarehouseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateWarehouseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateWarehouseResponse in the Terraform plugin framework type +// system. func (a CreateWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1045,12 +1270,21 @@ func (newState *CreateWidget) SyncEffectiveFieldsDuringCreateOrUpdate(plan Creat func (newState *CreateWidget) SyncEffectiveFieldsDuringRead(existingState CreateWidget) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateWidget. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateWidget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(WidgetOptions{}), } } +// ToAttrType returns the representation of CreateWidget in the Terraform plugin framework type +// system. func (a CreateWidget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1121,6 +1355,13 @@ func (newState *Dashboard) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dashboar func (newState *Dashboard) SyncEffectiveFieldsDuringRead(existingState Dashboard) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Dashboard. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(DashboardOptions{}), @@ -1130,6 +1371,8 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of Dashboard in the Terraform plugin framework type +// system. func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1181,12 +1424,21 @@ func (newState *DashboardEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DashboardEditContent) SyncEffectiveFieldsDuringRead(existingState DashboardEditContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DashboardEditContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DashboardEditContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DashboardEditContent in the Terraform plugin framework type +// system. func (a DashboardEditContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1213,10 +1465,19 @@ func (newState *DashboardOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DashboardOptions) SyncEffectiveFieldsDuringRead(existingState DashboardOptions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DashboardOptions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DashboardOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DashboardOptions in the Terraform plugin framework type +// system. func (a DashboardOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1250,12 +1511,21 @@ func (newState *DashboardPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DashboardPostContent) SyncEffectiveFieldsDuringRead(existingState DashboardPostContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DashboardPostContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DashboardPostContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DashboardPostContent in the Terraform plugin framework type +// system. func (a DashboardPostContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1305,10 +1575,19 @@ func (newState *DataSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan DataSou func (newState *DataSource) SyncEffectiveFieldsDuringRead(existingState DataSource) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DataSource. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DataSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DataSource in the Terraform plugin framework type +// system. func (a DataSource) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1337,10 +1616,19 @@ func (newState *DateRange) SyncEffectiveFieldsDuringCreateOrUpdate(plan DateRang func (newState *DateRange) SyncEffectiveFieldsDuringRead(existingState DateRange) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DateRange. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DateRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DateRange in the Terraform plugin framework type +// system. func (a DateRange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1368,12 +1656,21 @@ func (newState *DateRangeValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Dat func (newState *DateRangeValue) SyncEffectiveFieldsDuringRead(existingState DateRangeValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DateRangeValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DateRangeValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "date_range_value": reflect.TypeOf(DateRange{}), } } +// ToAttrType returns the representation of DateRangeValue in the Terraform plugin framework type +// system. func (a DateRangeValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1403,10 +1700,19 @@ func (newState *DateValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan DateValu func (newState *DateValue) SyncEffectiveFieldsDuringRead(existingState DateValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DateValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DateValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DateValue in the Terraform plugin framework type +// system. func (a DateValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1428,10 +1734,19 @@ func (newState *DeleteAlertsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteAlertsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteAlertsLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAlertsLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAlertsLegacyRequest in the Terraform plugin framework type +// system. func (a DeleteAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1451,10 +1766,19 @@ func (newState *DeleteDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteDashboardRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDashboardRequest in the Terraform plugin framework type +// system. func (a DeleteDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1475,10 +1799,19 @@ func (newState *DeleteDashboardWidgetRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteDashboardWidgetRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDashboardWidgetRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDashboardWidgetRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteDashboardWidgetRequest in the Terraform plugin framework type +// system. func (a DeleteDashboardWidgetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1498,10 +1831,19 @@ func (newState *DeleteQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQueriesLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteQueriesLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteQueriesLegacyRequest in the Terraform plugin framework type +// system. func (a DeleteQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1522,10 +1864,19 @@ func (newState *DeleteQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDurin func (newState *DeleteQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState DeleteQueryVisualizationsLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteQueryVisualizationsLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteQueryVisualizationsLegacyRequest in the Terraform plugin framework type +// system. func (a DeleteQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1543,10 +1894,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1564,10 +1924,19 @@ func (newState *DeleteVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *DeleteVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState DeleteVisualizationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteVisualizationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteVisualizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteVisualizationRequest in the Terraform plugin framework type +// system. func (a DeleteVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1588,10 +1957,19 @@ func (newState *DeleteWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState DeleteWarehouseRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWarehouseRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWarehouseRequest in the Terraform plugin framework type +// system. func (a DeleteWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1609,10 +1987,19 @@ func (newState *DeleteWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *DeleteWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState DeleteWarehouseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteWarehouseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteWarehouseResponse in the Terraform plugin framework type +// system. func (a DeleteWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1639,12 +2026,21 @@ func (newState *EditAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan EditAler func (newState *EditAlert) SyncEffectiveFieldsDuringRead(existingState EditAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(AlertOptions{}), } } +// ToAttrType returns the representation of EditAlert in the Terraform plugin framework type +// system. func (a EditAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1729,6 +2125,13 @@ func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *EditWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState EditWarehouseRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditWarehouseRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), @@ -1736,6 +2139,8 @@ func (a EditWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of EditWarehouseRequest in the Terraform plugin framework type +// system. func (a EditWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1770,10 +2175,19 @@ func (newState *EditWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EditWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState EditWarehouseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EditWarehouseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EditWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EditWarehouseResponse in the Terraform plugin framework type +// system. func (a EditWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1791,10 +2205,19 @@ func (newState *Empty) SyncEffectiveFieldsDuringCreateOrUpdate(plan Empty) { func (newState *Empty) SyncEffectiveFieldsDuringRead(existingState Empty) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Empty. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Empty in the Terraform plugin framework type +// system. func (a Empty) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1813,10 +2236,19 @@ func (newState *EndpointConfPair) SyncEffectiveFieldsDuringCreateOrUpdate(plan E func (newState *EndpointConfPair) SyncEffectiveFieldsDuringRead(existingState EndpointConfPair) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointConfPair. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointConfPair) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EndpointConfPair in the Terraform plugin framework type +// system. func (a EndpointConfPair) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1847,12 +2279,21 @@ func (newState *EndpointHealth) SyncEffectiveFieldsDuringCreateOrUpdate(plan End func (newState *EndpointHealth) SyncEffectiveFieldsDuringRead(existingState EndpointHealth) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointHealth. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointHealth) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "failure_reason": reflect.TypeOf(TerminationReason{}), } } +// ToAttrType returns the representation of EndpointHealth in the Terraform plugin framework type +// system. func (a EndpointHealth) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1950,6 +2391,13 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState EndpointInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), @@ -1959,6 +2407,8 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } +// ToAttrType returns the representation of EndpointInfo in the Terraform plugin framework type +// system. func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2006,10 +2456,19 @@ func (newState *EndpointTagPair) SyncEffectiveFieldsDuringCreateOrUpdate(plan En func (newState *EndpointTagPair) SyncEffectiveFieldsDuringRead(existingState EndpointTagPair) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointTagPair. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointTagPair) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EndpointTagPair in the Terraform plugin framework type +// system. func (a EndpointTagPair) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2029,12 +2488,21 @@ func (newState *EndpointTags) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointTags) SyncEffectiveFieldsDuringRead(existingState EndpointTags) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointTags. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "custom_tags": reflect.TypeOf(EndpointTagPair{}), } } +// ToAttrType returns the representation of EndpointTags in the Terraform plugin framework type +// system. func (a EndpointTags) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2060,6 +2528,13 @@ func (newState *EnumValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan EnumValu func (newState *EnumValue) SyncEffectiveFieldsDuringRead(existingState EnumValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EnumValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), @@ -2067,6 +2542,8 @@ func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of EnumValue in the Terraform plugin framework type +// system. func (a EnumValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2213,12 +2690,21 @@ func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ExecuteStatementRequest) SyncEffectiveFieldsDuringRead(existingState ExecuteStatementRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExecuteStatementRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExecuteStatementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(StatementParameterListItem{}), } } +// ToAttrType returns the representation of ExecuteStatementRequest in the Terraform plugin framework type +// system. func (a ExecuteStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2278,12 +2764,21 @@ func (newState *ExternalLink) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exter func (newState *ExternalLink) SyncEffectiveFieldsDuringRead(existingState ExternalLink) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalLink. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExternalLink) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "http_headers": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ExternalLink in the Terraform plugin framework type +// system. func (a ExternalLink) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2313,10 +2808,19 @@ func (newState *GetAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetAlertRequest) SyncEffectiveFieldsDuringRead(existingState GetAlertRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAlertRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAlertRequest in the Terraform plugin framework type +// system. func (a GetAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2336,10 +2840,19 @@ func (newState *GetAlertsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetAlertsLegacyRequest) SyncEffectiveFieldsDuringRead(existingState GetAlertsLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAlertsLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAlertsLegacyRequest in the Terraform plugin framework type +// system. func (a GetAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2359,10 +2872,19 @@ func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetDashboardRequest) SyncEffectiveFieldsDuringRead(existingState GetDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDashboardRequest in the Terraform plugin framework type +// system. func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2385,10 +2907,19 @@ func (newState *GetDbsqlPermissionRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetDbsqlPermissionRequest) SyncEffectiveFieldsDuringRead(existingState GetDbsqlPermissionRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetDbsqlPermissionRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetDbsqlPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetDbsqlPermissionRequest in the Terraform plugin framework type +// system. func (a GetDbsqlPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2409,10 +2940,19 @@ func (newState *GetQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *GetQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState GetQueriesLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetQueriesLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetQueriesLegacyRequest in the Terraform plugin framework type +// system. func (a GetQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2432,10 +2972,19 @@ func (newState *GetQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetQueryRequest) SyncEffectiveFieldsDuringRead(existingState GetQueryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetQueryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetQueryRequest in the Terraform plugin framework type +// system. func (a GetQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2458,12 +3007,21 @@ func (newState *GetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetRes func (newState *GetResponse) SyncEffectiveFieldsDuringRead(existingState GetResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControl{}), } } +// ToAttrType returns the representation of GetResponse in the Terraform plugin framework type +// system. func (a GetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2489,10 +3047,19 @@ func (newState *GetStatementRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetStatementRequest) SyncEffectiveFieldsDuringRead(existingState GetStatementRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStatementRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStatementRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStatementRequest in the Terraform plugin framework type +// system. func (a GetStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2515,10 +3082,19 @@ func (newState *GetStatementResultChunkNRequest) SyncEffectiveFieldsDuringCreate func (newState *GetStatementResultChunkNRequest) SyncEffectiveFieldsDuringRead(existingState GetStatementResultChunkNRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStatementResultChunkNRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStatementResultChunkNRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStatementResultChunkNRequest in the Terraform plugin framework type +// system. func (a GetStatementResultChunkNRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2540,10 +3116,19 @@ func (newState *GetWarehousePermissionLevelsRequest) SyncEffectiveFieldsDuringCr func (newState *GetWarehousePermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWarehousePermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWarehousePermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetWarehousePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2563,12 +3148,21 @@ func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringC func (newState *GetWarehousePermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWarehousePermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(WarehousePermissionsDescription{}), } } +// ToAttrType returns the representation of GetWarehousePermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetWarehousePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2591,10 +3185,19 @@ func (newState *GetWarehousePermissionsRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetWarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehousePermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWarehousePermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWarehousePermissionsRequest in the Terraform plugin framework type +// system. func (a GetWarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2615,10 +3218,19 @@ func (newState *GetWarehouseRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *GetWarehouseRequest) SyncEffectiveFieldsDuringRead(existingState GetWarehouseRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWarehouseRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWarehouseRequest in the Terraform plugin framework type +// system. func (a GetWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2710,6 +3322,13 @@ func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *GetWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState GetWarehouseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWarehouseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), @@ -2719,6 +3338,8 @@ func (a GetWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } +// ToAttrType returns the representation of GetWarehouseResponse in the Terraform plugin framework type +// system. func (a GetWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2788,6 +3409,13 @@ func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCr func (newState *GetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceWarehouseConfigResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceWarehouseConfigResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), @@ -2799,6 +3427,8 @@ func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co } } +// ToAttrType returns the representation of GetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type +// system. func (a GetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2862,6 +3492,13 @@ func (newState *LegacyAlert) SyncEffectiveFieldsDuringCreateOrUpdate(plan Legacy func (newState *LegacyAlert) SyncEffectiveFieldsDuringRead(existingState LegacyAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LegacyAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LegacyAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(AlertOptions{}), @@ -2870,6 +3507,8 @@ func (a LegacyAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of LegacyAlert in the Terraform plugin framework type +// system. func (a LegacyAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2971,6 +3610,13 @@ func (newState *LegacyQuery) SyncEffectiveFieldsDuringCreateOrUpdate(plan Legacy func (newState *LegacyQuery) SyncEffectiveFieldsDuringRead(existingState LegacyQuery) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LegacyQuery. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "last_modified_by": reflect.TypeOf(User{}), @@ -2981,6 +3627,8 @@ func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of LegacyQuery in the Terraform plugin framework type +// system. func (a LegacyQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3055,12 +3703,21 @@ func (newState *LegacyVisualization) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *LegacyVisualization) SyncEffectiveFieldsDuringRead(existingState LegacyVisualization) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in LegacyVisualization. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a LegacyVisualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(LegacyQuery{}), } } +// ToAttrType returns the representation of LegacyVisualization in the Terraform plugin framework type +// system. func (a LegacyVisualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3091,10 +3748,19 @@ func (newState *ListAlertsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListAlertsRequest) SyncEffectiveFieldsDuringRead(existingState ListAlertsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAlertsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAlertsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAlertsRequest in the Terraform plugin framework type +// system. func (a ListAlertsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3116,12 +3782,21 @@ func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListAlertsResponse) SyncEffectiveFieldsDuringRead(existingState ListAlertsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAlertsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAlertsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ListAlertsResponseAlert{}), } } +// ToAttrType returns the representation of ListAlertsResponse in the Terraform plugin framework type +// system. func (a ListAlertsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3183,12 +3858,21 @@ func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListAlertsResponseAlert) SyncEffectiveFieldsDuringRead(existingState ListAlertsResponseAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAlertsResponseAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAlertsResponseAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } } +// ToAttrType returns the representation of ListAlertsResponseAlert in the Terraform plugin framework type +// system. func (a ListAlertsResponseAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3230,10 +3914,19 @@ func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListDashboardsRequest) SyncEffectiveFieldsDuringRead(existingState ListDashboardsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListDashboardsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListDashboardsRequest in the Terraform plugin framework type +// system. func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3276,10 +3969,19 @@ func (newState *ListQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState ListQueriesLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQueriesLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListQueriesLegacyRequest in the Terraform plugin framework type +// system. func (a ListQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3304,10 +4006,19 @@ func (newState *ListQueriesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListQueriesRequest) SyncEffectiveFieldsDuringRead(existingState ListQueriesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQueriesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQueriesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListQueriesRequest in the Terraform plugin framework type +// system. func (a ListQueriesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3332,12 +4043,21 @@ func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListQueriesResponse) SyncEffectiveFieldsDuringRead(existingState ListQueriesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQueriesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQueriesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "res": reflect.TypeOf(QueryInfo{}), } } +// ToAttrType returns the representation of ListQueriesResponse in the Terraform plugin framework type +// system. func (a ListQueriesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3373,12 +4093,21 @@ func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListQueryHistoryRequest) SyncEffectiveFieldsDuringRead(existingState ListQueryHistoryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQueryHistoryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQueryHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "filter_by": reflect.TypeOf(QueryFilter{}), } } +// ToAttrType returns the representation of ListQueryHistoryRequest in the Terraform plugin framework type +// system. func (a ListQueryHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3404,12 +4133,21 @@ func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *ListQueryObjectsResponse) SyncEffectiveFieldsDuringRead(existingState ListQueryObjectsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQueryObjectsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQueryObjectsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(ListQueryObjectsResponseQuery{}), } } +// ToAttrType returns the representation of ListQueryObjectsResponse in the Terraform plugin framework type +// system. func (a ListQueryObjectsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3464,6 +4202,13 @@ func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringCreateOr func (newState *ListQueryObjectsResponseQuery) SyncEffectiveFieldsDuringRead(existingState ListQueryObjectsResponseQuery) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListQueryObjectsResponseQuery. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), @@ -3471,6 +4216,8 @@ func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) } } +// ToAttrType returns the representation of ListQueryObjectsResponseQuery in the Terraform plugin framework type +// system. func (a ListQueryObjectsResponseQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3515,12 +4262,21 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListR func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(Dashboard{}), } } +// ToAttrType returns the representation of ListResponse in the Terraform plugin framework type +// system. func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3549,10 +4305,19 @@ func (newState *ListVisualizationsForQueryRequest) SyncEffectiveFieldsDuringCrea func (newState *ListVisualizationsForQueryRequest) SyncEffectiveFieldsDuringRead(existingState ListVisualizationsForQueryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListVisualizationsForQueryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListVisualizationsForQueryRequest in the Terraform plugin framework type +// system. func (a ListVisualizationsForQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3575,12 +4340,21 @@ func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringCre func (newState *ListVisualizationsForQueryResponse) SyncEffectiveFieldsDuringRead(existingState ListVisualizationsForQueryResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListVisualizationsForQueryResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(Visualization{}), } } +// ToAttrType returns the representation of ListVisualizationsForQueryResponse in the Terraform plugin framework type +// system. func (a ListVisualizationsForQueryResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3605,10 +4379,19 @@ func (newState *ListWarehousesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *ListWarehousesRequest) SyncEffectiveFieldsDuringRead(existingState ListWarehousesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListWarehousesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListWarehousesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListWarehousesRequest in the Terraform plugin framework type +// system. func (a ListWarehousesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3628,12 +4411,21 @@ func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ListWarehousesResponse) SyncEffectiveFieldsDuringRead(existingState ListWarehousesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListWarehousesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListWarehousesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "warehouses": reflect.TypeOf(EndpointInfo{}), } } +// ToAttrType returns the representation of ListWarehousesResponse in the Terraform plugin framework type +// system. func (a ListWarehousesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3660,10 +4452,19 @@ func (newState *MultiValuesOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *MultiValuesOptions) SyncEffectiveFieldsDuringRead(existingState MultiValuesOptions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MultiValuesOptions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MultiValuesOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MultiValuesOptions in the Terraform plugin framework type +// system. func (a MultiValuesOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3684,10 +4485,19 @@ func (newState *NumericValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Numer func (newState *NumericValue) SyncEffectiveFieldsDuringRead(existingState NumericValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in NumericValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a NumericValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of NumericValue in the Terraform plugin framework type +// system. func (a NumericValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3712,10 +4522,19 @@ func (newState *OdbcParams) SyncEffectiveFieldsDuringCreateOrUpdate(plan OdbcPar func (newState *OdbcParams) SyncEffectiveFieldsDuringRead(existingState OdbcParams) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in OdbcParams. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a OdbcParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of OdbcParams in the Terraform plugin framework type +// system. func (a OdbcParams) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3754,12 +4573,21 @@ func (newState *Parameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Paramete func (newState *Parameter) SyncEffectiveFieldsDuringRead(existingState Parameter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Parameter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Parameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multiValuesOptions": reflect.TypeOf(MultiValuesOptions{}), } } +// ToAttrType returns the representation of Parameter in the Terraform plugin framework type +// system. func (a Parameter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3821,6 +4649,13 @@ func (newState *Query) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query) { func (newState *Query) SyncEffectiveFieldsDuringRead(existingState Query) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Query. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), @@ -3828,6 +4663,8 @@ func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } +// ToAttrType returns the representation of Query in the Terraform plugin framework type +// system. func (a Query) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3871,6 +4708,13 @@ func (newState *QueryBackedValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryBackedValue) SyncEffectiveFieldsDuringRead(existingState QueryBackedValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryBackedValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "multi_values_options": reflect.TypeOf(MultiValuesOptions{}), @@ -3878,6 +4722,8 @@ func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]r } } +// ToAttrType returns the representation of QueryBackedValue in the Terraform plugin framework type +// system. func (a QueryBackedValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3926,12 +4772,21 @@ func (newState *QueryEditContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryEditContent) SyncEffectiveFieldsDuringRead(existingState QueryEditContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryEditContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryEditContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of QueryEditContent in the Terraform plugin framework type +// system. func (a QueryEditContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -3969,6 +4824,13 @@ func (newState *QueryFilter) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryF func (newState *QueryFilter) SyncEffectiveFieldsDuringRead(existingState QueryFilter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryFilter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query_start_time_range": reflect.TypeOf(TimeRange{}), @@ -3979,6 +4841,8 @@ func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of QueryFilter in the Terraform plugin framework type +// system. func (a QueryFilter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4059,6 +4923,13 @@ func (newState *QueryInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryInf func (newState *QueryInfo) SyncEffectiveFieldsDuringRead(existingState QueryInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel_used": reflect.TypeOf(ChannelInfo{}), @@ -4066,6 +4937,8 @@ func (a QueryInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } +// ToAttrType returns the representation of QueryInfo in the Terraform plugin framework type +// system. func (a QueryInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4116,12 +4989,21 @@ func (newState *QueryList) SyncEffectiveFieldsDuringCreateOrUpdate(plan QueryLis func (newState *QueryList) SyncEffectiveFieldsDuringRead(existingState QueryList) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryList. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryList) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "results": reflect.TypeOf(LegacyQuery{}), } } +// ToAttrType returns the representation of QueryList in the Terraform plugin framework type +// system. func (a QueryList) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4202,10 +5084,19 @@ func (newState *QueryMetrics) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query func (newState *QueryMetrics) SyncEffectiveFieldsDuringRead(existingState QueryMetrics) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryMetrics. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryMetrics) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of QueryMetrics in the Terraform plugin framework type +// system. func (a QueryMetrics) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4254,12 +5145,21 @@ func (newState *QueryOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Query func (newState *QueryOptions) SyncEffectiveFieldsDuringRead(existingState QueryOptions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryOptions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(Parameter{}), } } +// ToAttrType returns the representation of QueryOptions in the Terraform plugin framework type +// system. func (a QueryOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4301,6 +5201,13 @@ func (newState *QueryParameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Que func (newState *QueryParameter) SyncEffectiveFieldsDuringRead(existingState QueryParameter) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryParameter. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryParameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "date_range_value": reflect.TypeOf(DateRangeValue{}), @@ -4312,6 +5219,8 @@ func (a QueryParameter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of QueryParameter in the Terraform plugin framework type +// system. func (a QueryParameter) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4373,12 +5282,21 @@ func (newState *QueryPostContent) SyncEffectiveFieldsDuringCreateOrUpdate(plan Q func (newState *QueryPostContent) SyncEffectiveFieldsDuringRead(existingState QueryPostContent) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryPostContent. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryPostContent) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "tags": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of QueryPostContent in the Terraform plugin framework type +// system. func (a QueryPostContent) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4409,6 +5327,13 @@ func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RepeatedEndpointConfPairs) SyncEffectiveFieldsDuringRead(existingState RepeatedEndpointConfPairs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepeatedEndpointConfPairs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepeatedEndpointConfPairs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "config_pair": reflect.TypeOf(EndpointConfPair{}), @@ -4416,6 +5341,8 @@ func (a RepeatedEndpointConfPairs) GetComplexFieldTypes(ctx context.Context) map } } +// ToAttrType returns the representation of RepeatedEndpointConfPairs in the Terraform plugin framework type +// system. func (a RepeatedEndpointConfPairs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4440,10 +5367,19 @@ func (newState *RestoreDashboardRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *RestoreDashboardRequest) SyncEffectiveFieldsDuringRead(existingState RestoreDashboardRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreDashboardRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreDashboardRequest in the Terraform plugin framework type +// system. func (a RestoreDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4463,10 +5399,19 @@ func (newState *RestoreQueriesLegacyRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *RestoreQueriesLegacyRequest) SyncEffectiveFieldsDuringRead(existingState RestoreQueriesLegacyRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreQueriesLegacyRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreQueriesLegacyRequest in the Terraform plugin framework type +// system. func (a RestoreQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4484,10 +5429,19 @@ func (newState *RestoreResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RestoreResponse) SyncEffectiveFieldsDuringRead(existingState RestoreResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RestoreResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RestoreResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RestoreResponse in the Terraform plugin framework type +// system. func (a RestoreResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4527,6 +5481,13 @@ func (newState *ResultData) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultD func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultData) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResultData. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_array": reflect.TypeOf(types.String{}), @@ -4534,6 +5495,8 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } +// ToAttrType returns the representation of ResultData in the Terraform plugin framework type +// system. func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4581,6 +5544,13 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState ResultManifest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResultManifest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "chunks": reflect.TypeOf(BaseChunkInfo{}), @@ -4588,6 +5558,8 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } +// ToAttrType returns the representation of ResultManifest in the Terraform plugin framework type +// system. func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4619,12 +5591,21 @@ func (newState *ResultSchema) SyncEffectiveFieldsDuringCreateOrUpdate(plan Resul func (newState *ResultSchema) SyncEffectiveFieldsDuringRead(existingState ResultSchema) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResultSchema. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResultSchema) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(ColumnInfo{}), } } +// ToAttrType returns the representation of ResultSchema in the Terraform plugin framework type +// system. func (a ResultSchema) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4648,10 +5629,19 @@ func (newState *ServiceError) SyncEffectiveFieldsDuringCreateOrUpdate(plan Servi func (newState *ServiceError) SyncEffectiveFieldsDuringRead(existingState ServiceError) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServiceError. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ServiceError) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ServiceError in the Terraform plugin framework type +// system. func (a ServiceError) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4677,12 +5667,21 @@ func (newState *SetRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetRequ func (newState *SetRequest) SyncEffectiveFieldsDuringRead(existingState SetRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControl{}), } } +// ToAttrType returns the representation of SetRequest in the Terraform plugin framework type +// system. func (a SetRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4709,12 +5708,21 @@ func (newState *SetResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan SetRes func (newState *SetResponse) SyncEffectiveFieldsDuringRead(existingState SetResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(AccessControl{}), } } +// ToAttrType returns the representation of SetResponse in the Terraform plugin framework type +// system. func (a SetResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4761,6 +5769,13 @@ func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringCre func (newState *SetWorkspaceWarehouseConfigRequest) SyncEffectiveFieldsDuringRead(existingState SetWorkspaceWarehouseConfigRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetWorkspaceWarehouseConfigRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "channel": reflect.TypeOf(Channel{}), @@ -4772,6 +5787,8 @@ func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes(ctx context.Con } } +// ToAttrType returns the representation of SetWorkspaceWarehouseConfigRequest in the Terraform plugin framework type +// system. func (a SetWorkspaceWarehouseConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4809,10 +5826,19 @@ func (newState *SetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringCr func (newState *SetWorkspaceWarehouseConfigResponse) SyncEffectiveFieldsDuringRead(existingState SetWorkspaceWarehouseConfigResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SetWorkspaceWarehouseConfigResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type +// system. func (a SetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4831,10 +5857,19 @@ func (newState *StartRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Start func (newState *StartRequest) SyncEffectiveFieldsDuringRead(existingState StartRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StartRequest in the Terraform plugin framework type +// system. func (a StartRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4852,10 +5887,19 @@ func (newState *StartWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *StartWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState StartWarehouseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StartWarehouseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StartWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StartWarehouseResponse in the Terraform plugin framework type +// system. func (a StartWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -4884,10 +5928,19 @@ func (newState *StatementParameterListItem) SyncEffectiveFieldsDuringCreateOrUpd func (newState *StatementParameterListItem) SyncEffectiveFieldsDuringRead(existingState StatementParameterListItem) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StatementParameterListItem. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StatementParameterListItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StatementParameterListItem in the Terraform plugin framework type +// system. func (a StatementParameterListItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4917,6 +5970,13 @@ func (newState *StatementResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *StatementResponse) SyncEffectiveFieldsDuringRead(existingState StatementResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StatementResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StatementResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "manifest": reflect.TypeOf(ResultManifest{}), @@ -4925,6 +5985,8 @@ func (a StatementResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } +// ToAttrType returns the representation of StatementResponse in the Terraform plugin framework type +// system. func (a StatementResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4962,12 +6024,21 @@ func (newState *StatementStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan St func (newState *StatementStatus) SyncEffectiveFieldsDuringRead(existingState StatementStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StatementStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StatementStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "error": reflect.TypeOf(ServiceError{}), } } +// ToAttrType returns the representation of StatementStatus in the Terraform plugin framework type +// system. func (a StatementStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -4991,10 +6062,19 @@ func (newState *StopRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan StopRe func (newState *StopRequest) SyncEffectiveFieldsDuringRead(existingState StopRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StopRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StopRequest in the Terraform plugin framework type +// system. func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5012,10 +6092,19 @@ func (newState *StopWarehouseResponse) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *StopWarehouseResponse) SyncEffectiveFieldsDuringRead(existingState StopWarehouseResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in StopWarehouseResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a StopWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of StopWarehouseResponse in the Terraform plugin framework type +// system. func (a StopWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -5032,10 +6121,19 @@ func (newState *Success) SyncEffectiveFieldsDuringCreateOrUpdate(plan Success) { func (newState *Success) SyncEffectiveFieldsDuringRead(existingState Success) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Success. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Success) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Success in the Terraform plugin framework type +// system. func (a Success) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5060,12 +6158,21 @@ func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TerminationReason) SyncEffectiveFieldsDuringRead(existingState TerminationReason) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TerminationReason. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of TerminationReason in the Terraform plugin framework type +// system. func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5088,10 +6195,19 @@ func (newState *TextValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan TextValu func (newState *TextValue) SyncEffectiveFieldsDuringRead(existingState TextValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TextValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TextValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TextValue in the Terraform plugin framework type +// system. func (a TextValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5113,10 +6229,19 @@ func (newState *TimeRange) SyncEffectiveFieldsDuringCreateOrUpdate(plan TimeRang func (newState *TimeRange) SyncEffectiveFieldsDuringRead(existingState TimeRange) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TimeRange. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TimeRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TimeRange in the Terraform plugin framework type +// system. func (a TimeRange) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5137,10 +6262,19 @@ func (newState *TransferOwnershipObjectId) SyncEffectiveFieldsDuringCreateOrUpda func (newState *TransferOwnershipObjectId) SyncEffectiveFieldsDuringRead(existingState TransferOwnershipObjectId) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TransferOwnershipObjectId. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TransferOwnershipObjectId) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TransferOwnershipObjectId in the Terraform plugin framework type +// system. func (a TransferOwnershipObjectId) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5165,12 +6299,21 @@ func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *TransferOwnershipRequest) SyncEffectiveFieldsDuringRead(existingState TransferOwnershipRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TransferOwnershipRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TransferOwnershipRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "objectId": reflect.TypeOf(TransferOwnershipObjectId{}), } } +// ToAttrType returns the representation of TransferOwnershipRequest in the Terraform plugin framework type +// system. func (a TransferOwnershipRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5194,10 +6337,19 @@ func (newState *TrashAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TrashAlertRequest) SyncEffectiveFieldsDuringRead(existingState TrashAlertRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TrashAlertRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TrashAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TrashAlertRequest in the Terraform plugin framework type +// system. func (a TrashAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5217,10 +6369,19 @@ func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringRead(existingState TrashQueryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in TrashQueryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a TrashQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of TrashQueryRequest in the Terraform plugin framework type +// system. func (a TrashQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5246,12 +6407,21 @@ func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateAlertRequest) SyncEffectiveFieldsDuringRead(existingState UpdateAlertRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAlertRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "alert": reflect.TypeOf(UpdateAlertRequestAlert{}), } } +// ToAttrType returns the representation of UpdateAlertRequest in the Terraform plugin framework type +// system. func (a UpdateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5299,12 +6469,21 @@ func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateAlertRequestAlert) SyncEffectiveFieldsDuringRead(existingState UpdateAlertRequestAlert) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateAlertRequestAlert. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "condition": reflect.TypeOf(AlertCondition{}), } } +// ToAttrType returns the representation of UpdateAlertRequestAlert in the Terraform plugin framework type +// system. func (a UpdateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5339,12 +6518,21 @@ func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateQueryRequest) SyncEffectiveFieldsDuringRead(existingState UpdateQueryRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateQueryRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "query": reflect.TypeOf(UpdateQueryRequestQuery{}), } } +// ToAttrType returns the representation of UpdateQueryRequest in the Terraform plugin framework type +// system. func (a UpdateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5390,6 +6578,13 @@ func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *UpdateQueryRequestQuery) SyncEffectiveFieldsDuringRead(existingState UpdateQueryRequestQuery) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateQueryRequestQuery. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "parameters": reflect.TypeOf(QueryParameter{}), @@ -5397,6 +6592,8 @@ func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of UpdateQueryRequestQuery in the Terraform plugin framework type +// system. func (a UpdateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5428,10 +6625,19 @@ func (newState *UpdateResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Upd func (newState *UpdateResponse) SyncEffectiveFieldsDuringRead(existingState UpdateResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// system. func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -5455,12 +6661,21 @@ func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringCreateOrUpd func (newState *UpdateVisualizationRequest) SyncEffectiveFieldsDuringRead(existingState UpdateVisualizationRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateVisualizationRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "visualization": reflect.TypeOf(UpdateVisualizationRequestVisualization{}), } } +// ToAttrType returns the representation of UpdateVisualizationRequest in the Terraform plugin framework type +// system. func (a UpdateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5494,10 +6709,19 @@ func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuri func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuringRead(existingState UpdateVisualizationRequestVisualization) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateVisualizationRequestVisualization. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateVisualizationRequestVisualization in the Terraform plugin framework type +// system. func (a UpdateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5523,10 +6747,19 @@ func (newState *User) SyncEffectiveFieldsDuringCreateOrUpdate(plan User) { func (newState *User) SyncEffectiveFieldsDuringRead(existingState User) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in User. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of User in the Terraform plugin framework type +// system. func (a User) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5566,10 +6799,19 @@ func (newState *Visualization) SyncEffectiveFieldsDuringCreateOrUpdate(plan Visu func (newState *Visualization) SyncEffectiveFieldsDuringRead(existingState Visualization) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Visualization. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Visualization) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Visualization in the Terraform plugin framework type +// system. func (a Visualization) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5602,10 +6844,19 @@ func (newState *WarehouseAccessControlRequest) SyncEffectiveFieldsDuringCreateOr func (newState *WarehouseAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState WarehouseAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehouseAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehouseAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WarehouseAccessControlRequest in the Terraform plugin framework type +// system. func (a WarehouseAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5636,12 +6887,21 @@ func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringCreateO func (newState *WarehouseAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState WarehouseAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehouseAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehouseAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(WarehousePermission{}), } } +// ToAttrType returns the representation of WarehouseAccessControlResponse in the Terraform plugin framework type +// system. func (a WarehouseAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5670,12 +6930,21 @@ func (newState *WarehousePermission) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *WarehousePermission) SyncEffectiveFieldsDuringRead(existingState WarehousePermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehousePermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehousePermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of WarehousePermission in the Terraform plugin framework type +// system. func (a WarehousePermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5702,12 +6971,21 @@ func (newState *WarehousePermissions) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *WarehousePermissions) SyncEffectiveFieldsDuringRead(existingState WarehousePermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehousePermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehousePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WarehouseAccessControlResponse{}), } } +// ToAttrType returns the representation of WarehousePermissions in the Terraform plugin framework type +// system. func (a WarehousePermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5732,10 +7010,19 @@ func (newState *WarehousePermissionsDescription) SyncEffectiveFieldsDuringCreate func (newState *WarehousePermissionsDescription) SyncEffectiveFieldsDuringRead(existingState WarehousePermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehousePermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehousePermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WarehousePermissionsDescription in the Terraform plugin framework type +// system. func (a WarehousePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5757,12 +7044,21 @@ func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringCreateOrUp func (newState *WarehousePermissionsRequest) SyncEffectiveFieldsDuringRead(existingState WarehousePermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehousePermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WarehouseAccessControlRequest{}), } } +// ToAttrType returns the representation of WarehousePermissionsRequest in the Terraform plugin framework type +// system. func (a WarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5788,10 +7084,19 @@ func (newState *WarehouseTypePair) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *WarehouseTypePair) SyncEffectiveFieldsDuringRead(existingState WarehouseTypePair) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WarehouseTypePair. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WarehouseTypePair) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WarehouseTypePair in the Terraform plugin framework type +// system. func (a WarehouseTypePair) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5822,6 +7127,13 @@ func (newState *Widget) SyncEffectiveFieldsDuringCreateOrUpdate(plan Widget) { func (newState *Widget) SyncEffectiveFieldsDuringRead(existingState Widget) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Widget. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Widget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "options": reflect.TypeOf(WidgetOptions{}), @@ -5829,6 +7141,8 @@ func (a Widget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } +// ToAttrType returns the representation of Widget in the Terraform plugin framework type +// system. func (a Widget) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5870,12 +7184,21 @@ func (newState *WidgetOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Widg func (newState *WidgetOptions) SyncEffectiveFieldsDuringRead(existingState WidgetOptions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WidgetOptions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WidgetOptions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "position": reflect.TypeOf(WidgetPosition{}), } } +// ToAttrType returns the representation of WidgetOptions in the Terraform plugin framework type +// system. func (a WidgetOptions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -5913,10 +7236,19 @@ func (newState *WidgetPosition) SyncEffectiveFieldsDuringCreateOrUpdate(plan Wid func (newState *WidgetPosition) SyncEffectiveFieldsDuringRead(existingState WidgetPosition) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WidgetPosition. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WidgetPosition) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WidgetPosition in the Terraform plugin framework type +// system. func (a WidgetPosition) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index a9293f26df..b9df9743d4 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -30,10 +30,19 @@ func (newState *ColumnInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ColumnI func (newState *ColumnInfo) SyncEffectiveFieldsDuringRead(existingState ColumnInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ColumnInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ColumnInfo in the Terraform plugin framework type +// system. func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -55,10 +64,19 @@ func (newState *CreateEndpoint) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CreateEndpoint) SyncEffectiveFieldsDuringRead(existingState CreateEndpoint) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateEndpoint. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateEndpoint in the Terraform plugin framework type +// system. func (a CreateEndpoint) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -97,6 +115,13 @@ func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState CreateVectorIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateVectorIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "delta_sync_index_spec": reflect.TypeOf(DeltaSyncVectorIndexSpecRequest{}), @@ -104,6 +129,8 @@ func (a CreateVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[ } } +// ToAttrType returns the representation of CreateVectorIndexRequest in the Terraform plugin framework type +// system. func (a CreateVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -131,12 +158,21 @@ func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState CreateVectorIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateVectorIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "vector_index": reflect.TypeOf(VectorIndex{}), } } +// ToAttrType returns the representation of CreateVectorIndexResponse in the Terraform plugin framework type +// system. func (a CreateVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -161,12 +197,21 @@ func (newState *DeleteDataResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan D func (newState *DeleteDataResult) SyncEffectiveFieldsDuringRead(existingState DeleteDataResult) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDataResult. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDataResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "failed_primary_keys": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DeleteDataResult in the Terraform plugin framework type +// system. func (a DeleteDataResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -193,12 +238,21 @@ func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *DeleteDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState DeleteDataVectorIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDataVectorIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "primary_keys": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of DeleteDataVectorIndexRequest in the Terraform plugin framework type +// system. func (a DeleteDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -224,12 +278,21 @@ func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringCreateOr func (newState *DeleteDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState DeleteDataVectorIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteDataVectorIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "result": reflect.TypeOf(DeleteDataResult{}), } } +// ToAttrType returns the representation of DeleteDataVectorIndexResponse in the Terraform plugin framework type +// system. func (a DeleteDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -253,10 +316,19 @@ func (newState *DeleteEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *DeleteEndpointRequest) SyncEffectiveFieldsDuringRead(existingState DeleteEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteEndpointRequest in the Terraform plugin framework type +// system. func (a DeleteEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -274,10 +346,19 @@ func (newState *DeleteEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *DeleteEndpointResponse) SyncEffectiveFieldsDuringRead(existingState DeleteEndpointResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteEndpointResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteEndpointResponse in the Terraform plugin framework type +// system. func (a DeleteEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -296,10 +377,19 @@ func (newState *DeleteIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteIndexRequest) SyncEffectiveFieldsDuringRead(existingState DeleteIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteIndexRequest in the Terraform plugin framework type +// system. func (a DeleteIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -317,10 +407,19 @@ func (newState *DeleteIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteIndexResponse) SyncEffectiveFieldsDuringRead(existingState DeleteIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteIndexResponse in the Terraform plugin framework type +// system. func (a DeleteIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -361,6 +460,13 @@ func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringCreate func (newState *DeltaSyncVectorIndexSpecRequest) SyncEffectiveFieldsDuringRead(existingState DeltaSyncVectorIndexSpecRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeltaSyncVectorIndexSpecRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns_to_sync": reflect.TypeOf(types.String{}), @@ -369,6 +475,8 @@ func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Contex } } +// ToAttrType returns the representation of DeltaSyncVectorIndexSpecRequest in the Terraform plugin framework type +// system. func (a DeltaSyncVectorIndexSpecRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -417,6 +525,13 @@ func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringCreat func (newState *DeltaSyncVectorIndexSpecResponse) SyncEffectiveFieldsDuringRead(existingState DeltaSyncVectorIndexSpecResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeltaSyncVectorIndexSpecResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), @@ -424,6 +539,8 @@ func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes(ctx context.Conte } } +// ToAttrType returns the representation of DeltaSyncVectorIndexSpecResponse in the Terraform plugin framework type +// system. func (a DeltaSyncVectorIndexSpecResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -461,6 +578,13 @@ func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringCreateOrUp func (newState *DirectAccessVectorIndexSpec) SyncEffectiveFieldsDuringRead(existingState DirectAccessVectorIndexSpec) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DirectAccessVectorIndexSpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "embedding_source_columns": reflect.TypeOf(EmbeddingSourceColumn{}), @@ -468,6 +592,8 @@ func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes(ctx context.Context) m } } +// ToAttrType returns the representation of DirectAccessVectorIndexSpec in the Terraform plugin framework type +// system. func (a DirectAccessVectorIndexSpec) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -495,10 +621,19 @@ func (newState *EmbeddingSourceColumn) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EmbeddingSourceColumn) SyncEffectiveFieldsDuringRead(existingState EmbeddingSourceColumn) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EmbeddingSourceColumn. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EmbeddingSourceColumn) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EmbeddingSourceColumn in the Terraform plugin framework type +// system. func (a EmbeddingSourceColumn) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -521,10 +656,19 @@ func (newState *EmbeddingVectorColumn) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *EmbeddingVectorColumn) SyncEffectiveFieldsDuringRead(existingState EmbeddingVectorColumn) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EmbeddingVectorColumn. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EmbeddingVectorColumn) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EmbeddingVectorColumn in the Terraform plugin framework type +// system. func (a EmbeddingVectorColumn) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -561,12 +705,21 @@ func (newState *EndpointInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Endpo func (newState *EndpointInfo) SyncEffectiveFieldsDuringRead(existingState EndpointInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "endpoint_status": reflect.TypeOf(EndpointStatus{}), } } +// ToAttrType returns the representation of EndpointInfo in the Terraform plugin framework type +// system. func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -599,10 +752,19 @@ func (newState *EndpointStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan End func (newState *EndpointStatus) SyncEffectiveFieldsDuringRead(existingState EndpointStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in EndpointStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a EndpointStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of EndpointStatus in the Terraform plugin framework type +// system. func (a EndpointStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -624,10 +786,19 @@ func (newState *GetEndpointRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetEndpointRequest) SyncEffectiveFieldsDuringRead(existingState GetEndpointRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetEndpointRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetEndpointRequest in the Terraform plugin framework type +// system. func (a GetEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -648,10 +819,19 @@ func (newState *GetIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetIndexRequest) SyncEffectiveFieldsDuringRead(existingState GetIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetIndexRequest in the Terraform plugin framework type +// system. func (a GetIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -674,12 +854,21 @@ func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListEndpointResponse) SyncEffectiveFieldsDuringRead(existingState ListEndpointResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListEndpointResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "endpoints": reflect.TypeOf(EndpointInfo{}), } } +// ToAttrType returns the representation of ListEndpointResponse in the Terraform plugin framework type +// system. func (a ListEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -703,10 +892,19 @@ func (newState *ListEndpointsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListEndpointsRequest) SyncEffectiveFieldsDuringRead(existingState ListEndpointsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListEndpointsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListEndpointsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListEndpointsRequest in the Terraform plugin framework type +// system. func (a ListEndpointsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -729,10 +927,19 @@ func (newState *ListIndexesRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListIndexesRequest) SyncEffectiveFieldsDuringRead(existingState ListIndexesRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListIndexesRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListIndexesRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListIndexesRequest in the Terraform plugin framework type +// system. func (a ListIndexesRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -752,12 +959,21 @@ func (newState *ListValue) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListValu func (newState *ListValue) SyncEffectiveFieldsDuringRead(existingState ListValue) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListValue. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "values": reflect.TypeOf(Value{}), } } +// ToAttrType returns the representation of ListValue in the Terraform plugin framework type +// system. func (a ListValue) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -782,12 +998,21 @@ func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *ListVectorIndexesResponse) SyncEffectiveFieldsDuringRead(existingState ListVectorIndexesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListVectorIndexesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListVectorIndexesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "vector_indexes": reflect.TypeOf(MiniVectorIndex{}), } } +// ToAttrType returns the representation of ListVectorIndexesResponse in the Terraform plugin framework type +// system. func (a ListVectorIndexesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -813,12 +1038,21 @@ func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *MapStringValueEntry) SyncEffectiveFieldsDuringRead(existingState MapStringValueEntry) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MapStringValueEntry. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MapStringValueEntry) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "value": reflect.TypeOf(Value{}), } } +// ToAttrType returns the representation of MapStringValueEntry in the Terraform plugin framework type +// system. func (a MapStringValueEntry) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -855,10 +1089,19 @@ func (newState *MiniVectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mi func (newState *MiniVectorIndex) SyncEffectiveFieldsDuringRead(existingState MiniVectorIndex) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MiniVectorIndex. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MiniVectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MiniVectorIndex in the Terraform plugin framework type +// system. func (a MiniVectorIndex) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -888,10 +1131,19 @@ func (newState *QueryVectorIndexNextPageRequest) SyncEffectiveFieldsDuringCreate func (newState *QueryVectorIndexNextPageRequest) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexNextPageRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryVectorIndexNextPageRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of QueryVectorIndexNextPageRequest in the Terraform plugin framework type +// system. func (a QueryVectorIndexNextPageRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -933,6 +1185,13 @@ func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *QueryVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryVectorIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(types.String{}), @@ -940,6 +1199,8 @@ func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[s } } +// ToAttrType returns the representation of QueryVectorIndexRequest in the Terraform plugin framework type +// system. func (a QueryVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -976,6 +1237,13 @@ func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *QueryVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState QueryVectorIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in QueryVectorIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a QueryVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "manifest": reflect.TypeOf(ResultManifest{}), @@ -983,6 +1251,8 @@ func (a QueryVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[ } } +// ToAttrType returns the representation of QueryVectorIndexResponse in the Terraform plugin framework type +// system. func (a QueryVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1011,12 +1281,21 @@ func (newState *ResultData) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResultD func (newState *ResultData) SyncEffectiveFieldsDuringRead(existingState ResultData) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResultData. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data_array": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of ResultData in the Terraform plugin framework type +// system. func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1044,12 +1323,21 @@ func (newState *ResultManifest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Res func (newState *ResultManifest) SyncEffectiveFieldsDuringRead(existingState ResultManifest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResultManifest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "columns": reflect.TypeOf(ColumnInfo{}), } } +// ToAttrType returns the representation of ResultManifest in the Terraform plugin framework type +// system. func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1077,10 +1365,19 @@ func (newState *ScanVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *ScanVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState ScanVectorIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ScanVectorIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ScanVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ScanVectorIndexRequest in the Terraform plugin framework type +// system. func (a ScanVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1105,12 +1402,21 @@ func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ScanVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState ScanVectorIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ScanVectorIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ScanVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data": reflect.TypeOf(Struct{}), } } +// ToAttrType returns the representation of ScanVectorIndexResponse in the Terraform plugin framework type +// system. func (a ScanVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1133,12 +1439,21 @@ func (newState *Struct) SyncEffectiveFieldsDuringCreateOrUpdate(plan Struct) { func (newState *Struct) SyncEffectiveFieldsDuringRead(existingState Struct) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Struct. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Struct) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fields": reflect.TypeOf(MapStringValueEntry{}), } } +// ToAttrType returns the representation of Struct in the Terraform plugin framework type +// system. func (a Struct) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1161,10 +1476,19 @@ func (newState *SyncIndexRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan S func (newState *SyncIndexRequest) SyncEffectiveFieldsDuringRead(existingState SyncIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SyncIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SyncIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SyncIndexRequest in the Terraform plugin framework type +// system. func (a SyncIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1182,10 +1506,19 @@ func (newState *SyncIndexResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *SyncIndexResponse) SyncEffectiveFieldsDuringRead(existingState SyncIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SyncIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SyncIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SyncIndexResponse in the Terraform plugin framework type +// system. func (a SyncIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1206,12 +1539,21 @@ func (newState *UpsertDataResult) SyncEffectiveFieldsDuringCreateOrUpdate(plan U func (newState *UpsertDataResult) SyncEffectiveFieldsDuringRead(existingState UpsertDataResult) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpsertDataResult. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpsertDataResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "failed_primary_keys": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of UpsertDataResult in the Terraform plugin framework type +// system. func (a UpsertDataResult) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1238,10 +1580,19 @@ func (newState *UpsertDataVectorIndexRequest) SyncEffectiveFieldsDuringCreateOrU func (newState *UpsertDataVectorIndexRequest) SyncEffectiveFieldsDuringRead(existingState UpsertDataVectorIndexRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpsertDataVectorIndexRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpsertDataVectorIndexRequest in the Terraform plugin framework type +// system. func (a UpsertDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1265,12 +1616,21 @@ func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringCreateOr func (newState *UpsertDataVectorIndexResponse) SyncEffectiveFieldsDuringRead(existingState UpsertDataVectorIndexResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpsertDataVectorIndexResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "result": reflect.TypeOf(UpsertDataResult{}), } } +// ToAttrType returns the representation of UpsertDataVectorIndexResponse in the Terraform plugin framework type +// system. func (a UpsertDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1302,6 +1662,13 @@ func (newState *Value) SyncEffectiveFieldsDuringCreateOrUpdate(plan Value) { func (newState *Value) SyncEffectiveFieldsDuringRead(existingState Value) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Value. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Value) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "list_value": reflect.TypeOf(ListValue{}), @@ -1309,6 +1676,8 @@ func (a Value) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } +// ToAttrType returns the representation of Value in the Terraform plugin framework type +// system. func (a Value) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1357,6 +1726,13 @@ func (newState *VectorIndex) SyncEffectiveFieldsDuringCreateOrUpdate(plan Vector func (newState *VectorIndex) SyncEffectiveFieldsDuringRead(existingState VectorIndex) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in VectorIndex. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a VectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "delta_sync_index_spec": reflect.TypeOf(DeltaSyncVectorIndexSpecResponse{}), @@ -1365,6 +1741,8 @@ func (a VectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } +// ToAttrType returns the representation of VectorIndex in the Terraform plugin framework type +// system. func (a VectorIndex) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1403,10 +1781,19 @@ func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *VectorIndexStatus) SyncEffectiveFieldsDuringRead(existingState VectorIndexStatus) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in VectorIndexStatus. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a VectorIndexStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of VectorIndexStatus in the Terraform plugin framework type +// system. func (a VectorIndexStatus) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 9ee42dfe02..416961b112 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -32,10 +32,19 @@ func (newState *AclItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan AclItem) { func (newState *AclItem) SyncEffectiveFieldsDuringRead(existingState AclItem) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AclItem. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AclItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AclItem in the Terraform plugin framework type +// system. func (a AclItem) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -59,10 +68,19 @@ func (newState *AzureKeyVaultSecretScopeMetadata) SyncEffectiveFieldsDuringCreat func (newState *AzureKeyVaultSecretScopeMetadata) SyncEffectiveFieldsDuringRead(existingState AzureKeyVaultSecretScopeMetadata) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in AzureKeyVaultSecretScopeMetadata. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of AzureKeyVaultSecretScopeMetadata in the Terraform plugin framework type +// system. func (a AzureKeyVaultSecretScopeMetadata) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -100,10 +118,19 @@ func (newState *CreateCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *CreateCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState CreateCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateCredentialsRequest in the Terraform plugin framework type +// system. func (a CreateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -130,10 +157,19 @@ func (newState *CreateCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *CreateCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState CreateCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateCredentialsResponse in the Terraform plugin framework type +// system. func (a CreateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -167,12 +203,21 @@ func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRepoRequest) SyncEffectiveFieldsDuringRead(existingState CreateRepoRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRepoRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } +// ToAttrType returns the representation of CreateRepoRequest in the Terraform plugin framework type +// system. func (a CreateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -210,12 +255,21 @@ func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *CreateRepoResponse) SyncEffectiveFieldsDuringRead(existingState CreateRepoResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateRepoResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } +// ToAttrType returns the representation of CreateRepoResponse in the Terraform plugin framework type +// system. func (a CreateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -251,12 +305,21 @@ func (newState *CreateScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Create func (newState *CreateScope) SyncEffectiveFieldsDuringRead(existingState CreateScope) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateScope. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateScope) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "backend_azure_keyvault": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), } } +// ToAttrType returns the representation of CreateScope in the Terraform plugin framework type +// system. func (a CreateScope) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -279,10 +342,19 @@ func (newState *CreateScopeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *CreateScopeResponse) SyncEffectiveFieldsDuringRead(existingState CreateScopeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateScopeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CreateScopeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CreateScopeResponse in the Terraform plugin framework type +// system. func (a CreateScopeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -305,10 +377,19 @@ func (newState *CredentialInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan Cre func (newState *CredentialInfo) SyncEffectiveFieldsDuringRead(existingState CredentialInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CredentialInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of CredentialInfo in the Terraform plugin framework type +// system. func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -335,10 +416,19 @@ func (newState *Delete) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete) { func (newState *Delete) SyncEffectiveFieldsDuringRead(existingState Delete) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Delete. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Delete in the Terraform plugin framework type +// system. func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -361,10 +451,19 @@ func (newState *DeleteAcl) SyncEffectiveFieldsDuringCreateOrUpdate(plan DeleteAc func (newState *DeleteAcl) SyncEffectiveFieldsDuringRead(existingState DeleteAcl) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAcl. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAcl in the Terraform plugin framework type +// system. func (a DeleteAcl) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -383,10 +482,19 @@ func (newState *DeleteAclResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteAclResponse) SyncEffectiveFieldsDuringRead(existingState DeleteAclResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteAclResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteAclResponse in the Terraform plugin framework type +// system. func (a DeleteAclResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -405,10 +513,19 @@ func (newState *DeleteCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *DeleteCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCredentialsRequest in the Terraform plugin framework type +// system. func (a DeleteCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -426,10 +543,19 @@ func (newState *DeleteCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *DeleteCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState DeleteCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteCredentialsResponse in the Terraform plugin framework type +// system. func (a DeleteCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -448,10 +574,19 @@ func (newState *DeleteRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRepoRequest) SyncEffectiveFieldsDuringRead(existingState DeleteRepoRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRepoRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRepoRequest in the Terraform plugin framework type +// system. func (a DeleteRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -469,10 +604,19 @@ func (newState *DeleteRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteRepoResponse) SyncEffectiveFieldsDuringRead(existingState DeleteRepoResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteRepoResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteRepoResponse in the Terraform plugin framework type +// system. func (a DeleteRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -488,10 +632,19 @@ func (newState *DeleteResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Del func (newState *DeleteResponse) SyncEffectiveFieldsDuringRead(existingState DeleteResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// system. func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -509,10 +662,19 @@ func (newState *DeleteScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delete func (newState *DeleteScope) SyncEffectiveFieldsDuringRead(existingState DeleteScope) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteScope. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteScope) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteScope in the Terraform plugin framework type +// system. func (a DeleteScope) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -530,10 +692,19 @@ func (newState *DeleteScopeResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *DeleteScopeResponse) SyncEffectiveFieldsDuringRead(existingState DeleteScopeResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteScopeResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteScopeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteScopeResponse in the Terraform plugin framework type +// system. func (a DeleteScopeResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -553,10 +724,19 @@ func (newState *DeleteSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan Delet func (newState *DeleteSecret) SyncEffectiveFieldsDuringRead(existingState DeleteSecret) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteSecret. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteSecret in the Terraform plugin framework type +// system. func (a DeleteSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -575,10 +755,19 @@ func (newState *DeleteSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *DeleteSecretResponse) SyncEffectiveFieldsDuringRead(existingState DeleteSecretResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteSecretResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a DeleteSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of DeleteSecretResponse in the Terraform plugin framework type +// system. func (a DeleteSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -613,10 +802,19 @@ func (newState *ExportRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Expo func (newState *ExportRequest) SyncEffectiveFieldsDuringRead(existingState ExportRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExportRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExportRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExportRequest in the Terraform plugin framework type +// system. func (a ExportRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -640,10 +838,19 @@ func (newState *ExportResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Exp func (newState *ExportResponse) SyncEffectiveFieldsDuringRead(existingState ExportResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExportResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ExportResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ExportResponse in the Terraform plugin framework type +// system. func (a ExportResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -667,10 +874,19 @@ func (newState *GetAclRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetA func (newState *GetAclRequest) SyncEffectiveFieldsDuringRead(existingState GetAclRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetAclRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetAclRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetAclRequest in the Terraform plugin framework type +// system. func (a GetAclRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -692,10 +908,19 @@ func (newState *GetCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(p func (newState *GetCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState GetCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCredentialsRequest in the Terraform plugin framework type +// system. func (a GetCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -720,10 +945,19 @@ func (newState *GetCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *GetCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState GetCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetCredentialsResponse in the Terraform plugin framework type +// system. func (a GetCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -746,10 +980,19 @@ func (newState *GetRepoPermissionLevelsRequest) SyncEffectiveFieldsDuringCreateO func (newState *GetRepoPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRepoPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRepoPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetRepoPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -769,12 +1012,21 @@ func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringCreate func (newState *GetRepoPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRepoPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(RepoPermissionsDescription{}), } } +// ToAttrType returns the representation of GetRepoPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetRepoPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -797,10 +1049,19 @@ func (newState *GetRepoPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpda func (newState *GetRepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRepoPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRepoPermissionsRequest in the Terraform plugin framework type +// system. func (a GetRepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -821,10 +1082,19 @@ func (newState *GetRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Get func (newState *GetRepoRequest) SyncEffectiveFieldsDuringRead(existingState GetRepoRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRepoRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetRepoRequest in the Terraform plugin framework type +// system. func (a GetRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -856,12 +1126,21 @@ func (newState *GetRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Ge func (newState *GetRepoResponse) SyncEffectiveFieldsDuringRead(existingState GetRepoResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetRepoResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } +// ToAttrType returns the representation of GetRepoResponse in the Terraform plugin framework type +// system. func (a GetRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -892,10 +1171,19 @@ func (newState *GetSecretRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSecretRequest) SyncEffectiveFieldsDuringRead(existingState GetSecretRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSecretRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetSecretRequest in the Terraform plugin framework type +// system. func (a GetSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -918,10 +1206,19 @@ func (newState *GetSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *GetSecretResponse) SyncEffectiveFieldsDuringRead(existingState GetSecretResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSecretResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetSecretResponse in the Terraform plugin framework type +// system. func (a GetSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -943,10 +1240,19 @@ func (newState *GetStatusRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetStatusRequest) SyncEffectiveFieldsDuringRead(existingState GetStatusRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetStatusRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetStatusRequest in the Terraform plugin framework type +// system. func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -969,10 +1275,19 @@ func (newState *GetWorkspaceObjectPermissionLevelsRequest) SyncEffectiveFieldsDu func (newState *GetWorkspaceObjectPermissionLevelsRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionLevelsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceObjectPermissionLevelsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWorkspaceObjectPermissionLevelsRequest in the Terraform plugin framework type +// system. func (a GetWorkspaceObjectPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -993,12 +1308,21 @@ func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsD func (newState *GetWorkspaceObjectPermissionLevelsResponse) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionLevelsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceObjectPermissionLevelsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "permission_levels": reflect.TypeOf(WorkspaceObjectPermissionsDescription{}), } } +// ToAttrType returns the representation of GetWorkspaceObjectPermissionLevelsResponse in the Terraform plugin framework type +// system. func (a GetWorkspaceObjectPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1023,10 +1347,19 @@ func (newState *GetWorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringC func (newState *GetWorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState GetWorkspaceObjectPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetWorkspaceObjectPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of GetWorkspaceObjectPermissionsRequest in the Terraform plugin framework type +// system. func (a GetWorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1075,10 +1408,19 @@ func (newState *Import) SyncEffectiveFieldsDuringCreateOrUpdate(plan Import) { func (newState *Import) SyncEffectiveFieldsDuringRead(existingState Import) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Import. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Import) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Import in the Terraform plugin framework type +// system. func (a Import) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1100,10 +1442,19 @@ func (newState *ImportResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Imp func (newState *ImportResponse) SyncEffectiveFieldsDuringRead(existingState ImportResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ImportResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ImportResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ImportResponse in the Terraform plugin framework type +// system. func (a ImportResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1122,10 +1473,19 @@ func (newState *ListAclsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan Li func (newState *ListAclsRequest) SyncEffectiveFieldsDuringRead(existingState ListAclsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAclsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAclsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListAclsRequest in the Terraform plugin framework type +// system. func (a ListAclsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1145,12 +1505,21 @@ func (newState *ListAclsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListAclsResponse) SyncEffectiveFieldsDuringRead(existingState ListAclsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListAclsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListAclsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "items": reflect.TypeOf(AclItem{}), } } +// ToAttrType returns the representation of ListAclsResponse in the Terraform plugin framework type +// system. func (a ListAclsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1172,12 +1541,21 @@ func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpdate func (newState *ListCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState ListCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "credentials": reflect.TypeOf(CredentialInfo{}), } } +// ToAttrType returns the representation of ListCredentialsResponse in the Terraform plugin framework type +// system. func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1206,10 +1584,19 @@ func (newState *ListReposRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan L func (newState *ListReposRequest) SyncEffectiveFieldsDuringRead(existingState ListReposRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListReposRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListReposRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListReposRequest in the Terraform plugin framework type +// system. func (a ListReposRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1233,12 +1620,21 @@ func (newState *ListReposResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListReposResponse) SyncEffectiveFieldsDuringRead(existingState ListReposResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListReposResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListReposResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "repos": reflect.TypeOf(RepoInfo{}), } } +// ToAttrType returns the representation of ListReposResponse in the Terraform plugin framework type +// system. func (a ListReposResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1261,12 +1657,21 @@ func (newState *ListResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ListR func (newState *ListResponse) SyncEffectiveFieldsDuringRead(existingState ListResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "objects": reflect.TypeOf(ObjectInfo{}), } } +// ToAttrType returns the representation of ListResponse in the Terraform plugin framework type +// system. func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1288,12 +1693,21 @@ func (newState *ListScopesResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListScopesResponse) SyncEffectiveFieldsDuringRead(existingState ListScopesResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListScopesResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListScopesResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "scopes": reflect.TypeOf(SecretScope{}), } } +// ToAttrType returns the representation of ListScopesResponse in the Terraform plugin framework type +// system. func (a ListScopesResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1316,10 +1730,19 @@ func (newState *ListSecretsRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *ListSecretsRequest) SyncEffectiveFieldsDuringRead(existingState ListSecretsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSecretsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListSecretsRequest in the Terraform plugin framework type +// system. func (a ListSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1339,12 +1762,21 @@ func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(pla func (newState *ListSecretsResponse) SyncEffectiveFieldsDuringRead(existingState ListSecretsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListSecretsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "secrets": reflect.TypeOf(SecretMetadata{}), } } +// ToAttrType returns the representation of ListSecretsResponse in the Terraform plugin framework type +// system. func (a ListSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1369,10 +1801,19 @@ func (newState *ListWorkspaceRequest) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *ListWorkspaceRequest) SyncEffectiveFieldsDuringRead(existingState ListWorkspaceRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListWorkspaceRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ListWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ListWorkspaceRequest in the Terraform plugin framework type +// system. func (a ListWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1395,10 +1836,19 @@ func (newState *Mkdirs) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mkdirs) { func (newState *Mkdirs) SyncEffectiveFieldsDuringRead(existingState Mkdirs) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Mkdirs. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a Mkdirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of Mkdirs in the Terraform plugin framework type +// system. func (a Mkdirs) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1416,10 +1866,19 @@ func (newState *MkdirsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mkd func (newState *MkdirsResponse) SyncEffectiveFieldsDuringRead(existingState MkdirsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MkdirsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a MkdirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of MkdirsResponse in the Terraform plugin framework type +// system. func (a MkdirsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1457,10 +1916,19 @@ func (newState *ObjectInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ObjectI func (newState *ObjectInfo) SyncEffectiveFieldsDuringRead(existingState ObjectInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ObjectInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a ObjectInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of ObjectInfo in the Terraform plugin framework type +// system. func (a ObjectInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1491,10 +1959,19 @@ func (newState *PutAcl) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutAcl) { func (newState *PutAcl) SyncEffectiveFieldsDuringRead(existingState PutAcl) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutAcl. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PutAcl in the Terraform plugin framework type +// system. func (a PutAcl) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1514,10 +1991,19 @@ func (newState *PutAclResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan Put func (newState *PutAclResponse) SyncEffectiveFieldsDuringRead(existingState PutAclResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutAclResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PutAclResponse in the Terraform plugin framework type +// system. func (a PutAclResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1541,10 +2027,19 @@ func (newState *PutSecret) SyncEffectiveFieldsDuringCreateOrUpdate(plan PutSecre func (newState *PutSecret) SyncEffectiveFieldsDuringRead(existingState PutSecret) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutSecret. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PutSecret in the Terraform plugin framework type +// system. func (a PutSecret) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1565,10 +2060,19 @@ func (newState *PutSecretResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *PutSecretResponse) SyncEffectiveFieldsDuringRead(existingState PutSecretResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in PutSecretResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a PutSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of PutSecretResponse in the Terraform plugin framework type +// system. func (a PutSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -1592,10 +2096,19 @@ func (newState *RepoAccessControlRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *RepoAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState RepoAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RepoAccessControlRequest in the Terraform plugin framework type +// system. func (a RepoAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1626,12 +2139,21 @@ func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *RepoAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState RepoAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(RepoPermission{}), } } +// ToAttrType returns the representation of RepoAccessControlResponse in the Terraform plugin framework type +// system. func (a RepoAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1670,12 +2192,21 @@ func (newState *RepoInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoInfo) func (newState *RepoInfo) SyncEffectiveFieldsDuringRead(existingState RepoInfo) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoInfo. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckout{}), } } +// ToAttrType returns the representation of RepoInfo in the Terraform plugin framework type +// system. func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1706,12 +2237,21 @@ func (newState *RepoPermission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Rep func (newState *RepoPermission) SyncEffectiveFieldsDuringRead(existingState RepoPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of RepoPermission in the Terraform plugin framework type +// system. func (a RepoPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1738,12 +2278,21 @@ func (newState *RepoPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan Re func (newState *RepoPermissions) SyncEffectiveFieldsDuringRead(existingState RepoPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RepoAccessControlResponse{}), } } +// ToAttrType returns the representation of RepoPermissions in the Terraform plugin framework type +// system. func (a RepoPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1768,10 +2317,19 @@ func (newState *RepoPermissionsDescription) SyncEffectiveFieldsDuringCreateOrUpd func (newState *RepoPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState RepoPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of RepoPermissionsDescription in the Terraform plugin framework type +// system. func (a RepoPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1793,12 +2351,21 @@ func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringCreateOrUpdate( func (newState *RepoPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState RepoPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a RepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(RepoAccessControlRequest{}), } } +// ToAttrType returns the representation of RepoPermissionsRequest in the Terraform plugin framework type +// system. func (a RepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1823,10 +2390,19 @@ func (newState *SecretMetadata) SyncEffectiveFieldsDuringCreateOrUpdate(plan Sec func (newState *SecretMetadata) SyncEffectiveFieldsDuringRead(existingState SecretMetadata) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SecretMetadata. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SecretMetadata) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of SecretMetadata in the Terraform plugin framework type +// system. func (a SecretMetadata) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1851,12 +2427,21 @@ func (newState *SecretScope) SyncEffectiveFieldsDuringCreateOrUpdate(plan Secret func (newState *SecretScope) SyncEffectiveFieldsDuringRead(existingState SecretScope) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SecretScope. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SecretScope) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "keyvault_metadata": reflect.TypeOf(AzureKeyVaultSecretScopeMetadata{}), } } +// ToAttrType returns the representation of SecretScope in the Terraform plugin framework type +// system. func (a SecretScope) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1884,12 +2469,21 @@ func (newState *SparseCheckout) SyncEffectiveFieldsDuringCreateOrUpdate(plan Spa func (newState *SparseCheckout) SyncEffectiveFieldsDuringRead(existingState SparseCheckout) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparseCheckout. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparseCheckout) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "patterns": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SparseCheckout in the Terraform plugin framework type +// system. func (a SparseCheckout) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1915,12 +2509,21 @@ func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringCreateOrUpdate(pl func (newState *SparseCheckoutUpdate) SyncEffectiveFieldsDuringRead(existingState SparseCheckoutUpdate) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in SparseCheckoutUpdate. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a SparseCheckoutUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "patterns": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of SparseCheckoutUpdate in the Terraform plugin framework type +// system. func (a SparseCheckoutUpdate) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1961,10 +2564,19 @@ func (newState *UpdateCredentialsRequest) SyncEffectiveFieldsDuringCreateOrUpdat func (newState *UpdateCredentialsRequest) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCredentialsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateCredentialsRequest in the Terraform plugin framework type +// system. func (a UpdateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -1985,10 +2597,19 @@ func (newState *UpdateCredentialsResponse) SyncEffectiveFieldsDuringCreateOrUpda func (newState *UpdateCredentialsResponse) SyncEffectiveFieldsDuringRead(existingState UpdateCredentialsResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateCredentialsResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateCredentialsResponse in the Terraform plugin framework type +// system. func (a UpdateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2016,12 +2637,21 @@ func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRepoRequest) SyncEffectiveFieldsDuringRead(existingState UpdateRepoRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRepoRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "sparse_checkout": reflect.TypeOf(SparseCheckoutUpdate{}), } } +// ToAttrType returns the representation of UpdateRepoRequest in the Terraform plugin framework type +// system. func (a UpdateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2044,10 +2674,19 @@ func (newState *UpdateRepoResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *UpdateRepoResponse) SyncEffectiveFieldsDuringRead(existingState UpdateRepoResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateRepoResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a UpdateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of UpdateRepoResponse in the Terraform plugin framework type +// system. func (a UpdateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, @@ -2071,10 +2710,19 @@ func (newState *WorkspaceObjectAccessControlRequest) SyncEffectiveFieldsDuringCr func (newState *WorkspaceObjectAccessControlRequest) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectAccessControlRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceObjectAccessControlRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WorkspaceObjectAccessControlRequest in the Terraform plugin framework type +// system. func (a WorkspaceObjectAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2105,12 +2753,21 @@ func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringC func (newState *WorkspaceObjectAccessControlResponse) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectAccessControlResponse) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceObjectAccessControlResponse. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "all_permissions": reflect.TypeOf(WorkspaceObjectPermission{}), } } +// ToAttrType returns the representation of WorkspaceObjectAccessControlResponse in the Terraform plugin framework type +// system. func (a WorkspaceObjectAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2139,12 +2796,21 @@ func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringCreateOrUpda func (newState *WorkspaceObjectPermission) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermission) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceObjectPermission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceObjectPermission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "inherited_from_object": reflect.TypeOf(types.String{}), } } +// ToAttrType returns the representation of WorkspaceObjectPermission in the Terraform plugin framework type +// system. func (a WorkspaceObjectPermission) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2171,12 +2837,21 @@ func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringCreateOrUpd func (newState *WorkspaceObjectPermissions) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissions) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceObjectPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WorkspaceObjectAccessControlResponse{}), } } +// ToAttrType returns the representation of WorkspaceObjectPermissions in the Terraform plugin framework type +// system. func (a WorkspaceObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2201,10 +2876,19 @@ func (newState *WorkspaceObjectPermissionsDescription) SyncEffectiveFieldsDuring func (newState *WorkspaceObjectPermissionsDescription) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissionsDescription) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceObjectPermissionsDescription. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } +// ToAttrType returns the representation of WorkspaceObjectPermissionsDescription in the Terraform plugin framework type +// system. func (a WorkspaceObjectPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ @@ -2228,12 +2912,21 @@ func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringCrea func (newState *WorkspaceObjectPermissionsRequest) SyncEffectiveFieldsDuringRead(existingState WorkspaceObjectPermissionsRequest) { } +// GetComplexFieldTypes returns a map of the types of elements in complex fields in WorkspaceObjectPermissionsRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "access_control_list": reflect.TypeOf(WorkspaceObjectAccessControlRequest{}), } } +// ToAttrType returns the representation of WorkspaceObjectPermissionsRequest in the Terraform plugin framework type +// system. func (a WorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ From 37d3f1bdf97f4167d10fb3bdffc3c130e49a5e51 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 19:35:20 +0100 Subject: [PATCH 37/91] work --- .codegen/model.go.tmpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index 1237aa8dec..b5428f35b2 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -185,8 +185,8 @@ even when they are called recursively. {{- else if .IsInt}}types.Int64 {{- else if .IsByteStream}}io.ReadCloser {{- else if .ArrayValue }}types.List - {{- else if .MapValue }}types.Map{{/* Note: we use types.List for objects for now. TODO: change this to types.Object. */}} - {{- else if .IsObject }}types.List + {{- else if .MapValue }}types.Map + {{- else if .IsObject }}types.List{{/* Note: we use types.List for objects for now. TODO: change this to types.Object. */}} {{- else if .Enum }}types.String {{- else}}any /* MISSING TYPE */ {{- end -}} From 3b5015ba81fcc8701d546da5a021fbd6514c9a3d Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 19:35:44 +0100 Subject: [PATCH 38/91] go mod tidy --- go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 0c88e8ab06..2911926b60 100644 --- a/go.mod +++ b/go.mod @@ -11,6 +11,7 @@ require ( github.com/hashicorp/hcl v1.0.0 github.com/hashicorp/hcl/v2 v2.23.0 github.com/hashicorp/terraform-plugin-framework v1.13.0 + github.com/hashicorp/terraform-plugin-framework-validators v0.15.0 github.com/hashicorp/terraform-plugin-go v0.25.0 github.com/hashicorp/terraform-plugin-log v0.9.0 github.com/hashicorp/terraform-plugin-mux v0.17.0 @@ -54,7 +55,6 @@ require ( github.com/hashicorp/logutils v1.0.0 // indirect github.com/hashicorp/terraform-exec v0.21.0 // indirect github.com/hashicorp/terraform-json v0.23.0 // indirect - github.com/hashicorp/terraform-plugin-framework-validators v0.15.0 // indirect github.com/hashicorp/terraform-registry-address v0.2.3 // indirect github.com/hashicorp/terraform-svchost v0.1.1 // indirect github.com/hashicorp/yamux v0.1.1 // indirect From 123432ce77585743db5c18aa82cde813aa75e2fc Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 20:00:01 +0100 Subject: [PATCH 39/91] comment --- .../common/complex_field_type_provider.go | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go index c3658c97de..5c8009b655 100644 --- a/internal/providers/pluginfw/common/complex_field_type_provider.go +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -7,7 +7,24 @@ import ( "github.com/hashicorp/terraform-plugin-framework/types" ) +// ComplexFieldTypeProvider must be implemented by any TFSDK structure that contains +// a complex field (list, map, object). Such fields do not include sufficient type +// information to understand the type of the contained elements in the case of a list +// or map, or the fields in the case of an object. This interface enables callers +// to recover that information. type ComplexFieldTypeProvider interface { + // GetComplexFieldTypes returns a map from field name to the type of the value in + // the list, map or object. The keys of the map must match the value of the + // `tfsdk` tag on the field. There must be one entry in the map for each field + // that has type types.List, types.Map or types.Object. + // + // If the field has type types.List or types.Map, the reflect.Type instance may + // correspond to either a primitive value (e.g. types.String) or a TFSDK structure. + // It is not allowed to return a reflect.Type that corresponds to a type value + // (e.g. types.StringType). + // + // If the field has type types.Object, the reflect.Type instance must correspond + // to a TFSDK structure. GetComplexFieldTypes(context.Context) map[string]reflect.Type } From b84854a0fabc66165d1599ddc8600f9b89b4133b Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 20:09:56 +0100 Subject: [PATCH 40/91] cleanup --- .../common/complex_field_type_provider.go | 5 ----- .../pluginfw/common/object_typable.go | 21 +++++++++++++++++++ 2 files changed, 21 insertions(+), 5 deletions(-) create mode 100644 internal/providers/pluginfw/common/object_typable.go diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go index 5c8009b655..2300691dbc 100644 --- a/internal/providers/pluginfw/common/complex_field_type_provider.go +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -4,7 +4,6 @@ import ( "context" "reflect" - "github.com/hashicorp/terraform-plugin-framework/types" ) // ComplexFieldTypeProvider must be implemented by any TFSDK structure that contains @@ -27,7 +26,3 @@ type ComplexFieldTypeProvider interface { // to a TFSDK structure. GetComplexFieldTypes(context.Context) map[string]reflect.Type } - -type ObjectTypable interface { - ToObjectType(context.Context) types.ObjectType -} diff --git a/internal/providers/pluginfw/common/object_typable.go b/internal/providers/pluginfw/common/object_typable.go new file mode 100644 index 0000000000..863f2e13c9 --- /dev/null +++ b/internal/providers/pluginfw/common/object_typable.go @@ -0,0 +1,21 @@ +package common + +import ( + "context" + + "github.com/hashicorp/terraform-plugin-framework/types" +) + +// ObjectTypable defines the Terraform type to be used for a given object. This allows +// the framework to dynamically instantiate instances of this type, either as an object, +// or as an element in a collection of objects, such as a list or map. +// +// Note that this interface is different from ObjectTypable in the plugin framework itself. +// That interface allows you to do custom serde when interacting with Terraform state. +// The TF SDK in this provider uses types from the plugin framework, and the custom handling +// of serde is mainly done at the boundary between the TFSDK and Databricks Go SDK types. +type ObjectTypable interface { + // ToObjectType returns the types.ObjectType that describes the object's type in the + // Terraform value type system. + ToObjectType(context.Context) types.ObjectType +} From 6222b90994696c825bd25067a4d56b000f56b560 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 20:21:32 +0100 Subject: [PATCH 41/91] add coverage for object types --- .../pluginfw/converters/converters_test.go | 18 ++++++++++++++++++ .../providers/pluginfw/converters/go_to_tf.go | 6 ++++++ .../providers/pluginfw/converters/tf_to_go.go | 12 +++++++++++- .../pluginfw/tfschema/struct_to_schema_test.go | 17 +++++++++++++++++ 4 files changed, 52 insertions(+), 1 deletion(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index 618260c519..fd52626619 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -31,6 +31,7 @@ type DummyTfSdk struct { DistinctField types.String `tfsdk:"distinct_field" tf:"optional"` SliceStructPtr types.List `tfsdk:"slice_struct_ptr" tf:"optional"` Irrelevant types.String `tfsdk:"-"` + Object types.Object `tfsdk:"object" tf:"optional"` } func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { @@ -44,6 +45,7 @@ func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T "attributes": reflect.TypeOf(types.String{}), "slice_struct": reflect.TypeOf(DummyNestedTfSdk{}), "slice_struct_ptr": reflect.TypeOf(DummyNestedTfSdk{}), + "object": reflect.TypeOf(DummyNestedTfSdk{}), } } @@ -66,6 +68,9 @@ func (DummyTfSdk) ToObjectType(ctx context.Context) types.ObjectType { "additional_field": types.StringType, "distinct_field": types.StringType, "slice_struct_ptr": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, + "object": types.ObjectType{ + AttrTypes: DummyNestedTfSdk{}.ToObjectType(ctx).AttrTypes, + }, }, } } @@ -129,6 +134,7 @@ type DummyGoSdk struct { DistinctField string `json:"distinct_field"` // distinct field that the tfsdk struct doesn't have SliceStructPtr *DummyNestedGoSdk `json:"slice_struct_ptr"` ForceSendFields []string `json:"-"` + Object DummyNestedGoSdk `json:"object"` } type DummyNestedGoSdk struct { @@ -371,6 +377,18 @@ var tests = []struct { ForceSendFields: []string{"Name", "Enabled"}, }, ForceSendFields: []string{"SliceStructPtr"}}, }, + { + "object conversion", + DummyTfSdk{Object: types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("def"), + "enabled": types.BoolValue(true), + })}, + DummyGoSdk{Object: DummyNestedGoSdk{ + Name: "def", + Enabled: true, + ForceSendFields: []string{"Name", "Enabled"}, + }, ForceSendFields: []string{"Object"}}, + }, } func TestConverter(t *testing.T) { diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index c90a225277..81e7b37b87 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -194,6 +194,12 @@ func goSdkToTfSdkSingleField( destField.Set(reflect.ValueOf(emptyList)) return } + if destField.Type() == reflect.TypeOf(types.Object{}) { + // If the destination field is a types.Object, treat the source field as an empty object. + innerType := innerType.(types.ObjectType) + destField.Set(reflect.ValueOf(types.ObjectNull(innerType.AttrTypes))) + return + } // Skip zeros return } diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 449f6ccdf0..1203b2b4fd 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -242,7 +242,17 @@ func tfsdkToGoSdkStructField( destField.Set(converted) case types.Object: - d.Append(v.As(ctx, destField.Addr().Interface(), basetypes.ObjectAsOptions{UnhandledNullAsEmpty: true, UnhandledUnknownAsEmpty: true})...) + if v.IsNull() { + return + } + + innerValue := reflect.New(innerType) + d.Append(v.As(ctx, innerValue.Interface(), basetypes.ObjectAsOptions{UnhandledNullAsEmpty: true, UnhandledUnknownAsEmpty: true})...) + if d.HasError() { + return + } + + d.Append(TfSdkToGoSdkStruct(ctx, innerValue.Interface(), destField.Addr().Interface())...) case types.Set, types.Tuple: d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("%T is not currently supported as a source field. %s", v, common.TerraformBugErrorMessage)) return diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go index 28b1dc981b..3faeef118c 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go @@ -56,6 +56,16 @@ func (TestMapTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Typ } } +type TestObjectTfSdk struct { + Object types.Object `tfsdk:"object" tf:"optional"` +} + +func (TestObjectTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "object": reflect.TypeOf(DummyNested{}), + } +} + type TestNestedListTfSdk struct { NestedList types.List `tfsdk:"nested_list" tf:"optional"` } @@ -120,6 +130,13 @@ var tests = []struct { "map conversion", TestMapTfSdk{Attributes: types.MapValueMust(types.StringType, map[string]attr.Value{"key": types.StringValue("value")})}, }, + { + "object conversion", + TestObjectTfSdk{Object: types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringValue("abc"), + "enabled": types.BoolValue(true), + })}, + }, { "nested list conversion", TestNestedListTfSdk{NestedList: types.ListValueMust(dummyType, From 295c97264d9fcad7fe09272d2fe60ae4de8c4545 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 20:42:39 +0100 Subject: [PATCH 42/91] more comments --- .../providers/pluginfw/common/common_test.go | 7 +- .../pluginfw/common/diag_to_string.go | 17 +++ .../pluginfw/converters/converters_test.go | 17 +-- .../providers/pluginfw/converters/go_to_tf.go | 132 ++++++++++-------- 4 files changed, 99 insertions(+), 74 deletions(-) create mode 100644 internal/providers/pluginfw/common/diag_to_string.go diff --git a/internal/providers/pluginfw/common/common_test.go b/internal/providers/pluginfw/common/common_test.go index dca9729ac8..f2fa718bb4 100644 --- a/internal/providers/pluginfw/common/common_test.go +++ b/internal/providers/pluginfw/common/common_test.go @@ -1,21 +1,22 @@ -package common +package common_test import ( "testing" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/stretchr/testify/assert" ) func TestGetDatabricksStagingName(t *testing.T) { resourceName := "test" expected := "databricks_test_pluginframework" - result := GetDatabricksStagingName(resourceName) + result := common.GetDatabricksStagingName(resourceName) assert.Equal(t, expected, result, "GetDatabricksStagingName should return the expected staging name") } func TestGetDatabricksProductionName(t *testing.T) { resourceName := "test" expected := "databricks_test" - result := GetDatabricksProductionName(resourceName) + result := common.GetDatabricksProductionName(resourceName) assert.Equal(t, expected, result, "GetDatabricksProductionName should return the expected production name") } diff --git a/internal/providers/pluginfw/common/diag_to_string.go b/internal/providers/pluginfw/common/diag_to_string.go new file mode 100644 index 0000000000..96b6edb73e --- /dev/null +++ b/internal/providers/pluginfw/common/diag_to_string.go @@ -0,0 +1,17 @@ +package common + +import ( + "fmt" + "strings" + + "github.com/hashicorp/terraform-plugin-framework/diag" +) + +// DiagToString converts a slice of diag.Diagnostics to a string. +func DiagToString(d diag.Diagnostics) string { + b := strings.Builder{} + for _, diag := range d { + b.WriteString(fmt.Sprintf("[%s] %s: %s\n", diag.Severity(), diag.Summary(), diag.Detail())) + } + return b.String() +} diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index fd52626619..aca2ac1874 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -4,9 +4,9 @@ import ( "context" "fmt" "reflect" - "strings" "testing" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" @@ -143,14 +143,9 @@ type DummyNestedGoSdk struct { ForceSendFields []string `json:"-"` } -func diagToString(d diag.Diagnostics) string { - b := strings.Builder{} - for _, diag := range d { - b.WriteString(fmt.Sprintf("[%s] %s: %s\n", diag.Severity(), diag.Summary(), diag.Detail())) - } - return b.String() -} - +// This function is used to populate empty fields in the tfsdk struct with null values. +// This is required because the Go->TF conversion function instantiates list, map, and +// object fields with empty values, which are not equal to null values in the tfsdk struct. func populateEmptyFields(c DummyTfSdk) DummyTfSdk { complexFields := c.GetComplexFieldTypes(context.Background()) v := reflect.ValueOf(&c).Elem() @@ -196,14 +191,14 @@ func RunConverterTest(t *testing.T, description string, tfSdkStruct DummyTfSdk, convertedGoSdkStruct := DummyGoSdk{} d := TfSdkToGoSdkStruct(context.Background(), tfSdkStruct, &convertedGoSdkStruct) if d.HasError() { - t.Errorf("tfsdk to gosdk conversion: %s", diagToString(d)) + t.Errorf("tfsdk to gosdk conversion: %s", pluginfwcommon.DiagToString(d)) } assert.Equal(t, goSdkStruct, convertedGoSdkStruct, fmt.Sprintf("tfsdk to gosdk conversion - %s", description)) convertedTfSdkStruct := DummyTfSdk{} d = GoSdkToTfSdkStruct(context.Background(), goSdkStruct, &convertedTfSdkStruct) if d.HasError() { - t.Errorf("gosdk to tfsdk conversion: %s", diagToString(d)) + t.Errorf("gosdk to tfsdk conversion: %s", pluginfwcommon.DiagToString(d)) } assert.Equal(t, populateEmptyFields(tfSdkStruct), convertedTfSdkStruct, fmt.Sprintf("gosdk to tfsdk conversion - %s", description)) } diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index 81e7b37b87..28832cb44f 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -20,21 +20,22 @@ const goSdkToTfSdkFieldConversionFailureMessage = "gosdk to tfsdk field conversi // GoSdkToTfSdkStruct converts a gosdk struct into a tfsdk struct, with the folowing rules. // -// string -> types.String -// bool -> types.Bool -// int64 -> types.Int64 -// float64 -> types.Float64 -// string -> types.String +// string -> types.String +// bool -> types.Bool +// int64 -> types.Int64 +// float64 -> types.Float64 +// Struct and pointer to struct -> types.List +// Slice -> types.List +// Map -> types.Map // -// NOTE: -// -// # Structs in gosdk are represented as slices of structs in tfsdk, and pointers are removed +// `gosdk` parameter must be a struct or pointer to a struct. `tfsdk` must be a pointer to the corresponding +// TF SDK structure. // +// Structs in Go SDK are represented as types.Lists. // If field name doesn't show up in ForceSendFields and the field is zero value, we set the null value on the tfsdk. -// types.list and types.map are not supported -// map keys should always be a string -// tfsdk structs use types.String for all enum values -// non-json fields will be omitted +// Map keys must always be strings. +// TF SDK structs use types.String for all enum values. +// Non-JSON fields will be omitted. func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{}) (d diag.Diagnostics) { srcVal := reflect.ValueOf(gosdk) destVal := reflect.ValueOf(tfsdk) @@ -110,38 +111,39 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ return } +// goSdkToTfSdkSingleField converts a single field from a Go SDK struct to a TF SDK struct. +// The `srcField` is the field in the Go SDK struct, and `destField` is the field on which +// the value will be set in the TF SDK struct. Note that unlike GoSdkToTfSdkStruct, the +// `destField` parameter is not a pointer to the field, but the field itself. The `tfType` +// parameter is the Terraform type of the field, and `complexFieldType` is the runtime +// type of the field. These parameters are only needed when the field is a list, object, or +// map. func goSdkToTfSdkSingleField( ctx context.Context, srcField reflect.Value, destField reflect.Value, forceSendField bool, - innerType attr.Type, - complexFieldType reflect.Type) (d diag.Diagnostics) { + tfType attr.Type, + innerType reflect.Type) (d diag.Diagnostics) { if !destField.CanSet() { d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("destination field can not be set: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) return d } - srcFieldValue := srcField.Interface() - - // Skip nils, but make sure to set the destination fields of type list to an empty list. - if srcField.Kind() == reflect.Ptr && srcField.IsNil() { - // If the destination field is a types.List, treat the source field as an empty slice. - if destField.Type() == reflect.TypeOf(types.List{}) { - listType := innerType.(types.ListType) - emptyList := types.ListNull(listType.ElemType) - destField.Set(reflect.ValueOf(emptyList)) - } - return nil - } - switch srcField.Kind() { case reflect.Ptr: - // Dereference the pointer and continue. + // This corresponds to either a types.List or types.Object. + // If nil, set the destination field to the null value of the appropriate type. + if srcField.IsNil() { + setFieldToNull(destField, tfType) + return nil + } + + // Otherwise, dereference the pointer and continue. srcField = srcField.Elem() - d.Append(goSdkToTfSdkSingleField(ctx, srcField, destField, forceSendField, innerType, complexFieldType)...) + d.Append(goSdkToTfSdkSingleField(ctx, srcField, destField, forceSendField, tfType, innerType)...) case reflect.Bool: - boolVal := srcFieldValue.(bool) + boolVal := srcField.Interface().(bool) // check if the value is non-zero or if the field is in the forceSendFields list if boolVal || forceSendField { destField.Set(reflect.ValueOf(types.BoolValue(boolVal))) @@ -177,7 +179,7 @@ func goSdkToTfSdkSingleField( return } } else { - strVal = srcFieldValue.(string) + strVal = srcField.Interface().(string) } // check if the value is non-zero or if the field is in the forceSendFields list if strVal != "" || forceSendField { @@ -186,21 +188,10 @@ func goSdkToTfSdkSingleField( destField.Set(reflect.ValueOf(types.StringNull())) } case reflect.Struct: + // This corresponds to either a types.List or types.Object. + // If the struct is zero value, set the destination field to the null value of the appropriate type. if srcField.IsZero() { - // If the destination field is a types.List, treat the source field as an empty slice. - if destField.Type() == reflect.TypeOf(types.List{}) { - listType := innerType.(types.ListType) - emptyList := types.ListNull(listType.ElemType) - destField.Set(reflect.ValueOf(emptyList)) - return - } - if destField.Type() == reflect.TypeOf(types.Object{}) { - // If the destination field is a types.Object, treat the source field as an empty object. - innerType := innerType.(types.ObjectType) - destField.Set(reflect.ValueOf(types.ObjectNull(innerType.AttrTypes))) - return - } - // Skip zeros + setFieldToNull(destField, tfType) return } @@ -209,19 +200,19 @@ func goSdkToTfSdkSingleField( if destField.Type() == reflect.TypeOf(types.List{}) { listSrc := reflect.MakeSlice(reflect.SliceOf(srcField.Type()), 1, 1) listSrc.Index(0).Set(srcField) - return goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, innerType, complexFieldType) + return goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, tfType, innerType) } // Otherwise, the destination field is a types.Object. Convert the nested struct to the corresponding // TFSDK struct, then set the destination field to the object - dest := reflect.New(complexFieldType).Interface() - d.Append(GoSdkToTfSdkStruct(ctx, srcFieldValue, dest)...) + dest := reflect.New(innerType).Interface() + d.Append(GoSdkToTfSdkStruct(ctx, srcField.Interface(), dest)...) if d.HasError() { return } - objectType, ok := innerType.(types.ObjectType) + objectType, ok := tfType.(types.ObjectType) if !ok { - d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not an object type: %s. %s", innerType, common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not an object type: %s. %s", tfType, common.TerraformBugErrorMessage)) return } objectVal, ds := types.ObjectValueFrom(ctx, objectType.AttrTypes, dest) @@ -231,9 +222,10 @@ func goSdkToTfSdkSingleField( } destField.Set(reflect.ValueOf(objectVal)) case reflect.Slice: - listType, ok := innerType.(types.ListType) + // This always corresponds to a types.List. + listType, ok := tfType.(types.ListType) if !ok { - d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a list type: %s. %s", innerType, common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a list type: %s. %s", tfType, common.TerraformBugErrorMessage)) return } if srcField.Len() == 0 { @@ -246,10 +238,12 @@ func goSdkToTfSdkSingleField( // Convert each element of the slice to the corresponding inner type. elements := make([]any, 0, srcField.Len()) for i := 0; i < srcField.Len(); i++ { - element := reflect.New(complexFieldType) - switch complexFieldType { + element := reflect.New(innerType) + // If the element is a primitive type, we can convert it by recursively calling this function. + // Otherwise, it is a struct, and we need to convert it by calling GoSdkToTfSdkStruct. + switch innerType { case reflect.TypeOf(types.String{}), reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}): - d.Append(goSdkToTfSdkSingleField(ctx, srcField.Index(i), element.Elem(), true, listType.ElemType, complexFieldType)...) + d.Append(goSdkToTfSdkSingleField(ctx, srcField.Index(i), element.Elem(), true, listType.ElemType, innerType)...) default: d.Append(GoSdkToTfSdkStruct(ctx, srcField.Index(i).Interface(), element.Interface())...) } @@ -267,9 +261,10 @@ func goSdkToTfSdkSingleField( } destField.Set(reflect.ValueOf(destVal)) case reflect.Map: - mapType, ok := innerType.(types.MapType) + // This always corresponds to a types.Map. + mapType, ok := tfType.(types.MapType) if !ok { - d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a map type: %s. %s", innerType, common.TerraformBugErrorMessage)) + d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a map type: %s. %s", tfType, common.TerraformBugErrorMessage)) return } if srcField.Len() == 0 { @@ -283,10 +278,12 @@ func goSdkToTfSdkSingleField( destMap := map[string]any{} for _, key := range srcField.MapKeys() { srcMapValue := srcField.MapIndex(key) - destMapValue := reflect.New(complexFieldType) - switch complexFieldType { + destMapValue := reflect.New(innerType) + // If the element is a primitive type, we can convert it by recursively calling this function. + // Otherwise, it is a struct, and we need to convert it by calling GoSdkToTfSdkStruct. + switch innerType { case reflect.TypeOf(types.String{}), reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}): - d.Append(goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue.Elem(), true, mapType.ElemType, complexFieldType)...) + d.Append(goSdkToTfSdkSingleField(ctx, srcMapValue, destMapValue.Elem(), true, mapType.ElemType, innerType)...) default: d.Append(GoSdkToTfSdkStruct(ctx, srcMapValue.Interface(), destMapValue.Interface())...) } @@ -309,6 +306,21 @@ func goSdkToTfSdkSingleField( return } +// setFieldToNull sets the destination field to the null value of the appropriate type. +func setFieldToNull(destField reflect.Value, innerType attr.Type) { + switch destField.Type() { + case reflect.TypeOf(types.List{}): + // If the destination field is a types.List, treat the source field as an empty slice. + listType := innerType.(types.ListType) + emptyList := types.ListNull(listType.ElemType) + destField.Set(reflect.ValueOf(emptyList)) + case reflect.TypeOf(types.Object{}): + // If the destination field is a types.Object, treat the source field as an empty object. + innerType := innerType.(types.ObjectType) + destField.Set(reflect.ValueOf(types.ObjectNull(innerType.AttrTypes))) + } +} + // Get the string value of an enum by calling the .String() method on the enum object. func getStringFromEnum(srcField reflect.Value) (s string, d diag.Diagnostics) { var stringMethod reflect.Value From 6a39e1b9e47a1979329e193a3910c0fea6dd2e08 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 20:46:09 +0100 Subject: [PATCH 43/91] more comments --- internal/providers/pluginfw/converters/tf_to_go.go | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 1203b2b4fd..9d14c05fe7 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -167,7 +167,9 @@ func tfsdkToGoSdkStructField( return } - // Recursively call TFSDK to GOSDK conversion for each element in the list + // Recursively call TFSDK to GOSDK conversion for each element in the list. If this corresponds to a slice, + // the target type is the slice element type. If it corresponds to a struct, the target type is the struct type. + // If it corresponds to a pointer, the target type is the type pointed to by the pointer. var destInnerType reflect.Type if destField.Type().Kind() == reflect.Slice { destInnerType = destField.Type().Elem() @@ -184,11 +186,13 @@ func tfsdkToGoSdkStructField( } } + // Recursively call TFSDK to GOSDK conversion for each element in the list converted := reflect.MakeSlice(reflect.SliceOf(destInnerType), 0, innerValue.Elem().Len()) for i := 0; i < innerValue.Elem().Len(); i++ { - // Convert from the TF Value to our TFSDK struct vv := innerValue.Elem().Index(i).Interface() nextDest := reflect.New(destInnerType) + // If the element is a primitive type, we can convert it by recursively calling this function. + // Otherwise, it is a TF SDK struct, and we need to call TfSdkToGoSdkStruct to convert it. switch typedVv := vv.(type) { case types.Bool, types.String, types.Int64, types.Float64: d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), srcFieldName, forceSendFieldsField, innerType)...) @@ -228,6 +232,8 @@ func tfsdkToGoSdkStructField( for _, key := range innerValue.Elem().MapKeys() { vv := innerValue.Elem().MapIndex(key).Interface() nextDest := reflect.New(destType) + // If the element is a primitive type, we can convert it by recursively calling this function. + // Otherwise, it is a TF SDK struct, and we need to call TfSdkToGoSdkStruct to convert it. switch typedVv := vv.(type) { case types.Bool, types.String, types.Int64, types.Float64: d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), srcFieldName, forceSendFieldsField, innerType)...) From e4aff40380460bc4424bff4868cf51cf9b3288c7 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 21:04:03 +0100 Subject: [PATCH 44/91] clean up resource_sahre --- .../products/sharing/resource_share.go | 90 ++++++++++++------- 1 file changed, 58 insertions(+), 32 deletions(-) diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index 6fa49e6c8e..7783f5fa63 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -227,22 +227,13 @@ func (r *ShareResource) Create(ctx context.Context, req resource.CreateRequest, return } - newState.SyncEffectiveFieldsDuringCreateOrUpdate(plan.ShareInfo) - planObjects := []sharing_tf.SharedDataObject{} - resp.Diagnostics.Append(plan.Objects.ElementsAs(ctx, &planObjects, true)...) - newStateObjects := []sharing_tf.SharedDataObject{} - resp.Diagnostics.Append(newState.Objects.ElementsAs(ctx, &newStateObjects, true)...) - for i := range newStateObjects { - newStateObjects[i].SyncEffectiveFieldsDuringCreateOrUpdate(planObjects[i]) - } - var d diag.Diagnostics - newState.Objects, d = basetypes.NewListValueFrom(ctx, newState.Objects.ElementType(ctx), newStateObjects) + newState, d := r.syncEffectiveFields(ctx, plan, newState, effectiveFieldsActionCreateOrUpdate{}) resp.Diagnostics.Append(d...) - - resp.Diagnostics.Append(resp.State.Set(ctx, newState)...) if resp.Diagnostics.HasError() { return } + + resp.Diagnostics.Append(resp.State.Set(ctx, newState)...) } func (r *ShareResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse) { @@ -292,17 +283,11 @@ func (r *ShareResource) Read(ctx context.Context, req resource.ReadRequest, resp return } - newState.SyncEffectiveFieldsDuringRead(existingState.ShareInfo) - var existingObjects []sharing_tf.SharedDataObject - resp.Diagnostics.Append(existingState.Objects.ElementsAs(ctx, &existingObjects, true)...) - var newStateObjects []sharing_tf.SharedDataObject - resp.Diagnostics.Append(newState.Objects.ElementsAs(ctx, &newStateObjects, true)...) - for i := range newStateObjects { - newStateObjects[i].SyncEffectiveFieldsDuringRead(existingObjects[i]) - } - var d diag.Diagnostics - newState.Objects, d = basetypes.NewListValueFrom(ctx, newState.Objects.ElementType(ctx), newStateObjects) + newState, d := r.syncEffectiveFields(ctx, existingState, newState, effectiveFieldsActionRead{}) resp.Diagnostics.Append(d...) + if resp.Diagnostics.HasError() { + return + } resp.Diagnostics.Append(resp.State.Set(ctx, newState)...) } @@ -398,17 +383,11 @@ func (r *ShareResource) Update(ctx context.Context, req resource.UpdateRequest, } } - state.SyncEffectiveFieldsDuringCreateOrUpdate(plan.ShareInfo) - planObjects := []sharing_tf.SharedDataObject{} - resp.Diagnostics.Append(plan.Objects.ElementsAs(ctx, &planObjects, true)...) - stateObjects := []sharing_tf.SharedDataObject{} - resp.Diagnostics.Append(state.Objects.ElementsAs(ctx, &stateObjects, true)...) - for i := range stateObjects { - stateObjects[i].SyncEffectiveFieldsDuringCreateOrUpdate(planObjects[i]) - } - var d diag.Diagnostics - state.Objects, d = basetypes.NewListValueFrom(ctx, state.Objects.ElementType(ctx), stateObjects) + state, d := r.syncEffectiveFields(ctx, plan, state, effectiveFieldsActionCreateOrUpdate{}) resp.Diagnostics.Append(d...) + if resp.Diagnostics.HasError() { + return + } resp.Diagnostics.Append(resp.State.Set(ctx, state)...) } @@ -433,3 +412,50 @@ func (r *ShareResource) Delete(ctx context.Context, req resource.DeleteRequest, return } } + +type effectiveFieldsAction interface { + resourceLevel(*ShareInfoExtended, sharing_tf.ShareInfo) + objectLevel(*sharing_tf.SharedDataObject, sharing_tf.SharedDataObject) +} + +type effectiveFieldsActionCreateOrUpdate struct{} + +func (effectiveFieldsActionCreateOrUpdate) resourceLevel(state *ShareInfoExtended, plan sharing_tf.ShareInfo) { + state.SyncEffectiveFieldsDuringCreateOrUpdate(plan) +} + +func (effectiveFieldsActionCreateOrUpdate) objectLevel(state *sharing_tf.SharedDataObject, plan sharing_tf.SharedDataObject) { + state.SyncEffectiveFieldsDuringCreateOrUpdate(plan) +} + +type effectiveFieldsActionRead struct{} + +func (effectiveFieldsActionRead) resourceLevel(state *ShareInfoExtended, plan sharing_tf.ShareInfo) { + state.SyncEffectiveFieldsDuringRead(plan) +} + +func (effectiveFieldsActionRead) objectLevel(state *sharing_tf.SharedDataObject, plan sharing_tf.SharedDataObject) { + state.SyncEffectiveFieldsDuringRead(plan) +} + +func (r *ShareResource) syncEffectiveFields(ctx context.Context, plan, state ShareInfoExtended, mode effectiveFieldsAction) (ShareInfoExtended, diag.Diagnostics) { + var d diag.Diagnostics + mode.resourceLevel(&state, plan.ShareInfo) + planObjects := []sharing_tf.SharedDataObject{} + d.Append(plan.Objects.ElementsAs(ctx, &planObjects, true)...) + if d.HasError() { + return state, d + } + stateObjects := []sharing_tf.SharedDataObject{} + d.Append(state.Objects.ElementsAs(ctx, &stateObjects, true)...) + if d.HasError() { + return state, d + } + for i := range stateObjects { + mode.objectLevel(&stateObjects[i], planObjects[i]) + } + var dd diag.Diagnostics + state.Objects, dd = basetypes.NewListValueFrom(ctx, state.Objects.ElementType(ctx), stateObjects) + d.Append(dd...) + return state, d +} From 2c3ed47092c150a9c759262f41e1d079fa4e2b3d Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 21:06:52 +0100 Subject: [PATCH 45/91] fix --- internal/providers/pluginfw/products/app/resource_app.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 4fcf9f6a35..928f2d0d3d 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -37,7 +37,7 @@ func (a resourceApp) Metadata(ctx context.Context, req resource.MetadataRequest, } func (a resourceApp) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { - resp.Schema = tfschema.ResourceStructToSchema(apps_tf.App{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { + resp.Schema = tfschema.ResourceStructToSchema(ctx, apps_tf.App{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { cs.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") // All pointers are treated as list blocks to be compatible with resources implemented in SDKv2. // The plugin framework requires that the number of blocks in the config and plan match. This means that From 5b52d7700802098ef4ce6a28606aa08fc19ecfdb Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 21:07:23 +0100 Subject: [PATCH 46/91] fix --- internal/acceptance/credential_test.go | 4 ++-- .../pluginfw/tfschema/nested_block_object.go | 13 ------------- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/internal/acceptance/credential_test.go b/internal/acceptance/credential_test.go index 73a2b15b31..efbd492318 100644 --- a/internal/acceptance/credential_test.go +++ b/internal/acceptance/credential_test.go @@ -5,8 +5,8 @@ import ( ) func TestUcAccCredential(t *testing.T) { - loadUcwsEnv(t) - if isAws(t) { + LoadUcwsEnv(t) + if IsAws(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_credential" "external" { diff --git a/internal/providers/pluginfw/tfschema/nested_block_object.go b/internal/providers/pluginfw/tfschema/nested_block_object.go index 7b61b71b88..c6a5bb31d9 100644 --- a/internal/providers/pluginfw/tfschema/nested_block_object.go +++ b/internal/providers/pluginfw/tfschema/nested_block_object.go @@ -28,19 +28,6 @@ func (a NestedBlockObject) ToNestedAttributeObject() NestedAttributeObject { } } -func (a NestedBlockObject) ToNestedAttributeObject() NestedAttributeObject { - attributes := make(map[string]AttributeBuilder) - for k, v := range a.Attributes { - attributes[k] = v - } - for k, v := range a.Blocks { - attributes[k] = v.ToAttribute() - } - return NestedAttributeObject{ - Attributes: attributes, - } -} - func (a NestedBlockObject) BuildDataSourceAttribute() dataschema.NestedBlockObject { dataSourceAttributes := BuildDataSourceAttributeMap(a.Attributes) dataSourceBlocks := BuildDataSourceBlockMap(a.Blocks) From edc1d4cecf9a5717d6bd47b0f792dda88f0691d1 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 21:09:31 +0100 Subject: [PATCH 47/91] work --- .../pluginfw/common/complex_field_type_provider.go | 1 - internal/service/apps_tf/model.go | 6 ------ 2 files changed, 7 deletions(-) diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go index 2300691dbc..ef074398bd 100644 --- a/internal/providers/pluginfw/common/complex_field_type_provider.go +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -3,7 +3,6 @@ package common import ( "context" "reflect" - ) // ComplexFieldTypeProvider must be implemented by any TFSDK structure that contains diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 0d6f8558e1..783ba34afb 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -59,12 +59,6 @@ type App struct { Url types.String `tfsdk:"url" tf:"computed,optional"` } -func (a *App) GetNestedTypes() map[string]any { - return map[string]any{ - "active_deployment": AppDeployment{}, - } -} - func (newState *App) SyncEffectiveFieldsDuringCreateOrUpdate(plan App) { } From 30398daad35f6d1b2d0cb0ea1011b0b3dd14d278 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 5 Dec 2024 22:09:40 +0100 Subject: [PATCH 48/91] it passes a test --- .codegen/model.go.tmpl | 14 +- .../products/catalog/data_functions.go | 37 +- .../pluginfw/products/cluster/data_cluster.go | 93 +- .../data_notification_destinations.go | 34 +- .../resource_quality_monitor.go | 2 +- .../registered_model/data_registered_model.go | 34 +- .../data_registered_model_versions.go | 31 +- .../serving/data_serving_endpoints.go | 29 +- .../pluginfw/products/sharing/data_shares.go | 25 +- .../products/sharing/resource_share.go | 2 +- .../pluginfw/products/volume/data_volumes.go | 28 +- .../pluginfw/tfschema/struct_to_schema.go | 15 +- internal/service/apps_tf/model.go | 168 +-- internal/service/billing_tf/model.go | 190 +-- internal/service/catalog_tf/model.go | 1260 ++++++++--------- internal/service/compute_tf/model.go | 1000 ++++++------- internal/service/dashboards_tf/model.go | 228 +-- internal/service/files_tf/model.go | 148 +- internal/service/iam_tf/model.go | 336 ++--- internal/service/jobs_tf/model.go | 912 ++++++------ internal/service/marketplace_tf/model.go | 584 ++++---- internal/service/ml_tf/model.go | 776 +++++----- internal/service/oauth2_tf/model.go | 148 +- internal/service/pipelines_tf/model.go | 368 ++--- internal/service/provisioning_tf/model.go | 262 ++-- internal/service/serving_tf/model.go | 448 +++--- internal/service/settings_tf/model.go | 694 ++++----- internal/service/sharing_tf/model.go | 216 +-- internal/service/sql_tf/model.go | 798 +++++------ internal/service/vectorsearch_tf/model.go | 224 +-- internal/service/workspace_tf/model.go | 350 ++--- 31 files changed, 4817 insertions(+), 4637 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index b5428f35b2..bbfb01cbc6 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -78,9 +78,9 @@ func (a {{.PascalName}}) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of {{.PascalName}} in the Terraform plugin framework type +// ToObjectType returns the representation of {{.PascalName}} in the Terraform plugin framework type // system. -func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { +func (a {{.PascalName}}) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ {{ range .Fields -}} @@ -96,7 +96,7 @@ func (a {{.PascalName}}) ToAttrType(ctx context.Context) types.ObjectType { {{/* Jobs has a recursive structure: Tasks contain ForEachTasks, which contain Tasks. -Because of this, GetComplexFieldTypes and ToAttrType will never terminate. +Because of this, GetComplexFieldTypes and ToObjectType will never terminate. TODO: capture visited types in the context to ensure these methods terminate, even when they are called recursively. */}} @@ -120,8 +120,8 @@ even when they are called recursively. {{- else if .IsInt -}}types.Int64Type {{- else if .IsAny -}}types.ObjectType{} {{- else if .IsByteStream}}types.ObjectType{} - {{- else if .IsObject -}}{{/* Objects are treated as lists from a TFSDK type perspective. */}}basetypes.ListType{ - ElemType: {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}}{{.PascalName}}{}.ToAttrType(ctx), + {{- else if or .IsEmpty .IsObject -}}{{/* Objects are treated as lists from a TFSDK type perspective. */}}basetypes.ListType{ + ElemType: {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}}{{.PascalName}}{}.ToObjectType(ctx), } {{- end -}} {{- end -}} @@ -138,7 +138,7 @@ even when they are called recursively. {{- else if .IsFloat64 -}}types.Float64{} {{- else if .IsInt -}}types.Int64{} {{- else if .IsAny -}}struct{}{} - {{- else if .IsObject -}}{{.PascalName}}{} + {{- else if or .IsEmpty .IsObject -}}{{.PascalName}}{} {{- end -}} {{- end -}} {{- end -}} @@ -177,7 +177,7 @@ even when they are called recursively. {{- if not . }}any /* ERROR */ {{- else if .IsExternal }}{{.Package.Name}}.{{.PascalName}} {{- else if .IsAny}}any - {{- else if .IsEmpty}}[]{{.PascalName}} + {{- else if .IsEmpty}}types.List {{- else if .IsString}}types.String {{- else if .IsBool}}types.Bool {{- else if .IsInt64}}types.Int64 diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index 900055e47e..f6c1358909 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -3,6 +3,7 @@ package catalog import ( "context" "fmt" + "reflect" "github.com/databricks/databricks-sdk-go/apierr" "github.com/databricks/databricks-sdk-go/service/catalog" @@ -12,8 +13,10 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -30,10 +33,27 @@ type FunctionsDataSource struct { } type FunctionsData struct { - CatalogName types.String `tfsdk:"catalog_name"` - SchemaName types.String `tfsdk:"schema_name"` - IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` - Functions []catalog_tf.FunctionInfo `tfsdk:"functions" tf:"optional,computed"` + CatalogName types.String `tfsdk:"catalog_name"` + SchemaName types.String `tfsdk:"schema_name"` + IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` + Functions types.List `tfsdk:"functions" tf:"optional,computed"` +} + +func (FunctionsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "functions": reflect.TypeOf(catalog_tf.FunctionInfo{}), + } +} + +func (FunctionsData) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "catalog_name": types.StringType, + "schema_name": types.StringType, + "include_browse": types.BoolType, + "functions": types.ListType{ElemType: catalog_tf.FunctionInfo{}.ToObjectType(ctx)}, + }, + } } func (d *FunctionsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -82,13 +102,20 @@ func (d *FunctionsDataSource) Read(ctx context.Context, req datasource.ReadReque resp.Diagnostics.AddError(fmt.Sprintf("failed to get functions for %s.%s schema", catalogName, schemaName), err.Error()) return } + tfFunctions := []catalog_tf.FunctionInfo{} for _, functionSdk := range functionsInfosSdk { var function catalog_tf.FunctionInfo resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, functionSdk, &function)...) if resp.Diagnostics.HasError() { return } - functions.Functions = append(functions.Functions, function) + tfFunctions = append(tfFunctions, function) + } + var dd diag.Diagnostics + functions.Functions, dd = types.ListValueFrom(ctx, catalog_tf.FunctionInfo{}.ToObjectType(ctx), tfFunctions) + resp.Diagnostics.Append(dd...) + if resp.Diagnostics.HasError() { + return } resp.Diagnostics.Append(resp.State.Set(ctx, functions)...) } diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index b0fafc189d..9da5586dd0 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -3,9 +3,10 @@ package cluster import ( "context" "fmt" + "reflect" "strings" - "github.com/databricks/databricks-sdk-go/apierr" + "github.com/databricks/databricks-sdk-go" "github.com/databricks/databricks-sdk-go/service/compute" "github.com/databricks/terraform-provider-databricks/common" pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" @@ -13,6 +14,7 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/diag" @@ -32,9 +34,25 @@ type ClusterDataSource struct { } type ClusterInfo struct { - ClusterId types.String `tfsdk:"cluster_id" tf:"optional,computed"` - Name types.String `tfsdk:"cluster_name" tf:"optional,computed"` - ClusterInfo []compute_tf.ClusterDetails `tfsdk:"cluster_info" tf:"optional,computed"` + ClusterId types.String `tfsdk:"cluster_id" tf:"optional,computed"` + Name types.String `tfsdk:"cluster_name" tf:"optional,computed"` + ClusterInfo types.List `tfsdk:"cluster_info" tf:"optional,computed"` +} + +func (ClusterInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "cluster_info": reflect.TypeOf(compute_tf.ClusterDetails{}), + } +} + +func (ClusterInfo) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "cluster_id": types.StringType, + "cluster_name": types.StringType, + "cluster_info": types.ListType{ElemType: compute_tf.ClusterDetails{}.ToObjectType(ctx)}, + }, + } } func (d *ClusterDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -84,52 +102,43 @@ func (d *ClusterDataSource) Read(ctx context.Context, req datasource.ReadRequest } clusterName := clusterInfo.Name.ValueString() clusterId := clusterInfo.ClusterId.ValueString() + c, diag := d.getClusterDetails(ctx, w, clusterName, clusterId) + resp.Diagnostics.Append(diag...) + if resp.Diagnostics.HasError() { + return + } + cc := []compute_tf.ClusterDetails{} + for _, cluster := range c { + var tfCluster compute_tf.ClusterDetails + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, cluster, &tfCluster)...) + cc = append(cc, tfCluster) + } + resp.Diagnostics.Append(validateClustersList(ctx, cc, clusterName)...) + clusterInfo.ClusterId = cc[0].ClusterId + clusterInfo.Name = cc[0].ClusterName + resp.Diagnostics.Append(resp.State.Set(ctx, clusterInfo)...) +} + +func (d *ClusterDataSource) getClusterDetails(ctx context.Context, w *databricks.WorkspaceClient, clusterName, clusterId string) (c []compute.ClusterDetails, dd diag.Diagnostics) { if clusterName != "" { - clustersGoSDk, err := w.Clusters.ListAll(ctx, compute.ListClustersRequest{}) + var err error + c, err = w.Clusters.ListAll(ctx, compute.ListClustersRequest{}) if err != nil { - resp.Diagnostics.AddError("failed to list clusters", err.Error()) - return - } - var clustersTfSDK []compute_tf.ClusterDetails - for _, cluster := range clustersGoSDk { - var clusterDetails compute_tf.ClusterDetails - resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, cluster, &clusterDetails)...) - if resp.Diagnostics.HasError() { - return - } - clustersTfSDK = append(clustersTfSDK, clusterDetails) - } - namedClusters := []compute_tf.ClusterDetails{} - for _, cluster := range clustersTfSDK { - if cluster.ClusterName == clusterInfo.Name { - namedClusters = append(namedClusters, cluster) - } - } - resp.Diagnostics.Append(validateClustersList(ctx, namedClusters, clusterName)...) - if resp.Diagnostics.HasError() { + dd.AddError("failed to list clusters", err.Error()) return } - clusterInfo.ClusterInfo = namedClusters[0:1] - } else if clusterId != "" { + return + } + if clusterId != "" { cluster, err := w.Clusters.GetByClusterId(ctx, clusterId) if err != nil { - if apierr.IsMissing(err) { - resp.State.RemoveResource(ctx) - } - resp.Diagnostics.AddError(fmt.Sprintf("failed to get cluster with cluster id: %s", clusterId), err.Error()) - return - } - var clusterDetails compute_tf.ClusterDetails - resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, cluster, &clusterDetails)...) - if resp.Diagnostics.HasError() { + dd.AddError(fmt.Sprintf("failed to get cluster with cluster id: %s", clusterId), err.Error()) return } - clusterInfo.ClusterInfo = []compute_tf.ClusterDetails{clusterDetails} - } else { - resp.Diagnostics.AddError("you need to specify either `cluster_name` or `cluster_id`", "") + c = []compute.ClusterDetails{*cluster} return } - clusterInfo.ClusterId = clusterInfo.ClusterInfo[0].ClusterId - clusterInfo.Name = clusterInfo.ClusterInfo[0].ClusterName - resp.Diagnostics.Append(resp.State.Set(ctx, clusterInfo)...) + + dd.AddError("you need to specify either `cluster_name` or `cluster_id`", "") + return } diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index e28a6b3043..b9dcf58def 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -3,6 +3,7 @@ package notificationdestinations import ( "context" "fmt" + "reflect" "slices" "strings" @@ -13,6 +14,7 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/settings_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/diag" @@ -32,9 +34,27 @@ type NotificationDestinationsDataSource struct { } type NotificationDestinationsInfo struct { - DisplayNameContains types.String `tfsdk:"display_name_contains" tf:"optional"` - Type types.String `tfsdk:"type" tf:"optional"` - NotificationDestinations []settings_tf.ListNotificationDestinationsResult `tfsdk:"notification_destinations" tf:"computed"` + DisplayNameContains types.String `tfsdk:"display_name_contains" tf:"optional"` + Type types.String `tfsdk:"type" tf:"optional"` + NotificationDestinations types.List `tfsdk:"notification_destinations" tf:"computed"` +} + +func (NotificationDestinationsInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "notification_destinations": reflect.TypeOf(settings_tf.ListNotificationDestinationsResult{}), + } +} + +func (NotificationDestinationsInfo) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "display_name_contains": types.StringType, + "type": types.StringType, + "notification_destinations": types.ListType{ + ElemType: settings_tf.ListNotificationDestinationsResult{}.ToObjectType(ctx), + }, + }, + } } func (d *NotificationDestinationsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -114,7 +134,13 @@ func (d *NotificationDestinationsDataSource) Read(ctx context.Context, req datas notificationsTfSdk = append(notificationsTfSdk, notificationDestination) } - notificationInfo.NotificationDestinations = notificationsTfSdk + var dd diag.Diagnostics + notificationInfo.NotificationDestinations, dd = types.ListValueFrom(ctx, settings_tf.ListNotificationDestinationsResult{}.ToObjectType(ctx), notificationsTfSdk) + resp.Diagnostics.Append(dd...) + if resp.Diagnostics.HasError() { + return + } + resp.Diagnostics.Append(resp.State.Set(ctx, notificationInfo)...) } diff --git a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go index 5641c0a9c4..7fc6d788d1 100644 --- a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go +++ b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go @@ -70,7 +70,7 @@ func (m MonitorInfoExtended) GetComplexFieldTypes(ctx context.Context) map[strin } func (m MonitorInfoExtended) ToObjectType(ctx context.Context) types.ObjectType { - tpe := m.MonitorInfo.ToAttrType(ctx) + tpe := m.MonitorInfo.ToObjectType(ctx) tpe.AttrTypes["warehouse_id"] = types.StringType tpe.AttrTypes["skip_builtin_dashboard"] = types.BoolType tpe.AttrTypes["id"] = types.StringType diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index 2f6b0bf7a8..9d77b72f6a 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -3,6 +3,7 @@ package registered_model import ( "context" "fmt" + "reflect" "github.com/databricks/databricks-sdk-go/apierr" "github.com/databricks/databricks-sdk-go/service/catalog" @@ -12,6 +13,7 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/diag" @@ -32,10 +34,27 @@ type RegisteredModelDataSource struct { } type RegisteredModelData struct { - FullName types.String `tfsdk:"full_name"` - IncludeAliases types.Bool `tfsdk:"include_aliases" tf:"optional"` - IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` - ModelInfo []catalog_tf.RegisteredModelInfo `tfsdk:"model_info" tf:"optional,computed"` + FullName types.String `tfsdk:"full_name"` + IncludeAliases types.Bool `tfsdk:"include_aliases" tf:"optional"` + IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` + ModelInfo types.List `tfsdk:"model_info" tf:"optional,computed"` +} + +func (RegisteredModelData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "model_info": reflect.TypeOf(catalog_tf.RegisteredModelInfo{}), + } +} + +func (RegisteredModelData) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "full_name": types.StringType, + "include_aliases": types.BoolType, + "include_browse": types.BoolType, + "model_info": types.ListType{ElemType: catalog_tf.RegisteredModelInfo{}.ToObjectType(ctx)}, + }, + } } func (d *RegisteredModelDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -93,6 +112,11 @@ func (d *RegisteredModelDataSource) Read(ctx context.Context, req datasource.Rea modelInfo.Aliases, d = basetypes.NewListValueFrom(ctx, modelInfo.Aliases.ElementType(ctx), []catalog_tf.RegisteredModelAlias{}) resp.Diagnostics.Append(d...) } - registeredModel.ModelInfo = append(registeredModel.ModelInfo, modelInfo) + var dd diag.Diagnostics + registeredModel.ModelInfo, dd = types.ListValueFrom(ctx, catalog_tf.RegisteredModelInfo{}.ToObjectType(ctx), []catalog_tf.RegisteredModelInfo{modelInfo}) + resp.Diagnostics.Append(dd...) + if resp.Diagnostics.HasError() { + return + } resp.Diagnostics.Append(resp.State.Set(ctx, registeredModel)...) } diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go index d70f6e44df..315e5c4d9d 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go @@ -3,14 +3,17 @@ package registered_model import ( "context" "fmt" + "reflect" "github.com/databricks/terraform-provider-databricks/common" pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -25,8 +28,23 @@ type RegisteredModelVersionsDataSource struct { } type RegisteredModelVersionsData struct { - FullName types.String `tfsdk:"full_name"` - ModelVersions []catalog_tf.ModelVersionInfo `tfsdk:"model_versions" tf:"optional,computed"` + FullName types.String `tfsdk:"full_name"` + ModelVersions types.List `tfsdk:"model_versions" tf:"optional,computed"` +} + +func (RegisteredModelVersionsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "model_versions": reflect.TypeOf(catalog_tf.ModelVersionInfo{}), + } +} + +func (RegisteredModelVersionsData) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "full_name": types.StringType, + "model_versions": types.ListType{ElemType: catalog_tf.ModelVersionInfo{}.ToObjectType(ctx)}, + }, + } } func (d *RegisteredModelVersionsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -66,13 +84,20 @@ func (d *RegisteredModelVersionsDataSource) Read(ctx context.Context, req dataso resp.Diagnostics.AddError(fmt.Sprintf("failed to list model versions for registered model %s", modelFullName), err.Error()) return } + var tfModelVersions []catalog_tf.ModelVersionInfo for _, modelVersionSdk := range modelVersions.ModelVersions { var modelVersion catalog_tf.ModelVersionInfo resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, modelVersionSdk, &modelVersion)...) if resp.Diagnostics.HasError() { return } - registeredModelVersions.ModelVersions = append(registeredModelVersions.ModelVersions, modelVersion) + tfModelVersions = append(tfModelVersions, modelVersion) + } + var dd diag.Diagnostics + registeredModelVersions.ModelVersions, dd = types.ListValueFrom(ctx, catalog_tf.ModelVersionInfo{}.ToObjectType(ctx), tfModelVersions) + resp.Diagnostics.Append(dd...) + if resp.Diagnostics.HasError() { + return } resp.Diagnostics.Append(resp.State.Set(ctx, registeredModelVersions)...) } diff --git a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go index 4f007d7ac6..7dfa792c42 100644 --- a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go +++ b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go @@ -2,6 +2,7 @@ package serving import ( "context" + "reflect" "github.com/databricks/databricks-sdk-go/apierr" "github.com/databricks/terraform-provider-databricks/common" @@ -9,8 +10,11 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" "github.com/databricks/terraform-provider-databricks/internal/service/serving_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" + "github.com/hashicorp/terraform-plugin-framework/diag" + "github.com/hashicorp/terraform-plugin-framework/types" ) func DataSourceServingEndpoints() datasource.DataSource { @@ -24,7 +28,21 @@ type ServingEndpointsDataSource struct { } type ServingEndpointsData struct { - Endpoints []serving_tf.ServingEndpoint `tfsdk:"endpoints" tf:"optional,computed"` + Endpoints types.List `tfsdk:"endpoints" tf:"optional,computed"` +} + +func (ServingEndpointsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "endpoints": reflect.TypeOf(serving_tf.ServingEndpoint{}), + } +} + +func (ServingEndpointsData) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "endpoints": types.ListType{ElemType: serving_tf.ServingEndpoint{}.ToObjectType(ctx)}, + }, + } } func (d *ServingEndpointsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -66,13 +84,20 @@ func (d *ServingEndpointsDataSource) Read(ctx context.Context, req datasource.Re resp.Diagnostics.AddError("failed to list endpoints", err.Error()) return } + tfEndpoints := []serving_tf.ServingEndpoint{} for _, endpoint := range endpointsInfoSdk { var endpointsInfo serving_tf.ServingEndpoint resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, endpoint, &endpointsInfo)...) if resp.Diagnostics.HasError() { return } - endpoints.Endpoints = append(endpoints.Endpoints, endpointsInfo) + tfEndpoints = append(tfEndpoints, endpointsInfo) + } + var dd diag.Diagnostics + endpoints.Endpoints, dd = types.ListValueFrom(ctx, serving_tf.ServingEndpoint{}.ToObjectType(ctx), tfEndpoints) + resp.Diagnostics.Append(dd...) + if resp.Diagnostics.HasError() { + return } resp.Diagnostics.Append(resp.State.Set(ctx, endpoints)...) } diff --git a/internal/providers/pluginfw/products/sharing/data_shares.go b/internal/providers/pluginfw/products/sharing/data_shares.go index 51a50210ef..457ba8633d 100644 --- a/internal/providers/pluginfw/products/sharing/data_shares.go +++ b/internal/providers/pluginfw/products/sharing/data_shares.go @@ -2,22 +2,37 @@ package sharing import ( "context" - - "github.com/hashicorp/terraform-plugin-framework/types" + "reflect" "github.com/databricks/databricks-sdk-go/service/sharing" "github.com/databricks/terraform-provider-databricks/common" pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" pluginfwcontext "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/context" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" + "github.com/hashicorp/terraform-plugin-framework/types" ) const dataSourceNameShares = "shares" type SharesList struct { - Shares []types.String `tfsdk:"shares" tf:"computed,optional,slice_set"` + Shares types.List `tfsdk:"shares" tf:"computed,optional,slice_set"` +} + +func (SharesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "shares": reflect.TypeOf(types.String{}), + } +} + +func (SharesList) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "shares": types.ListType{ElemType: types.StringType}, + }, + } } func DataSourceShares() datasource.DataSource { @@ -62,10 +77,10 @@ func (d *SharesDataSource) Read(ctx context.Context, req datasource.ReadRequest, return } - shareNames := make([]types.String, len(shares)) + shareNames := make([]attr.Value, len(shares)) for i, share := range shares { shareNames[i] = types.StringValue(share.Name) } - resp.Diagnostics.Append(resp.State.Set(ctx, SharesList{Shares: shareNames})...) + resp.Diagnostics.Append(resp.State.Set(ctx, SharesList{Shares: types.ListValueMust(types.StringType, shareNames)})...) } diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index 7783f5fa63..4d83310999 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -43,7 +43,7 @@ func (s ShareInfoExtended) GetComplexFieldTypes(ctx context.Context) map[string] } func (s ShareInfoExtended) ToObjectType(ctx context.Context) types.ObjectType { - return s.ShareInfo.ToAttrType(ctx) + return s.ShareInfo.ToObjectType(ctx) } func matchOrder[T any, K comparable](target, reference []T, keyFunc func(T) K) { diff --git a/internal/providers/pluginfw/products/volume/data_volumes.go b/internal/providers/pluginfw/products/volume/data_volumes.go index 17988e2685..7a2611762b 100644 --- a/internal/providers/pluginfw/products/volume/data_volumes.go +++ b/internal/providers/pluginfw/products/volume/data_volumes.go @@ -3,6 +3,7 @@ package volume import ( "context" "fmt" + "reflect" "github.com/databricks/databricks-sdk-go/apierr" "github.com/databricks/databricks-sdk-go/service/catalog" @@ -11,6 +12,7 @@ import ( pluginfwcontext "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/context" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" + "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/types" @@ -29,9 +31,25 @@ type VolumesDataSource struct { } type VolumesList struct { - CatalogName types.String `tfsdk:"catalog_name"` - SchemaName types.String `tfsdk:"schema_name"` - Ids []types.String `tfsdk:"ids" tf:"optional,computed"` + CatalogName types.String `tfsdk:"catalog_name"` + SchemaName types.String `tfsdk:"schema_name"` + Ids types.List `tfsdk:"ids" tf:"optional,computed"` +} + +func (VolumesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "ids": reflect.TypeOf(types.String{}), + } +} + +func (VolumesList) ToObjectType(ctx context.Context) types.ObjectType { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "catalog_name": types.StringType, + "schema_name": types.StringType, + "ids": types.ListType{ElemType: types.StringType}, + }, + } } func (d *VolumesDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { @@ -76,8 +94,10 @@ func (d *VolumesDataSource) Read(ctx context.Context, req datasource.ReadRequest resp.Diagnostics.AddError(fmt.Sprintf("failed to get volumes for the catalog:%s and schema%s", listVolumesRequest.CatalogName, listVolumesRequest.SchemaName), err.Error()) return } + ids := []attr.Value{} for _, v := range volumes { - volumesList.Ids = append(volumesList.Ids, types.StringValue(v.FullName)) + ids = append(ids, types.StringValue(v.FullName)) } + volumesList.Ids = types.ListValueMust(types.StringType, ids) resp.Diagnostics.Append(resp.State.Set(ctx, volumesList)...) } diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 304f36b66e..5c33043ae9 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -63,17 +63,26 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { if !ok { panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } + objectTypable, ok := v.Interface().(tfcommon.ObjectTypable) + if !ok { + panic(fmt.Errorf("object type not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) + } + objectType := objectTypable.ToObjectType(ctx) + attrType, ok := objectType.AttrTypes[fieldName] + if !ok { + panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + } // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. // Otherwise, use ListNestedBlockBuilder. switch fieldType { // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. // If new types are added there, they must also be added here to work properly. case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): - switch vv := value.(type) { + switch value.(type) { case types.List: - scmAttr[fieldName] = ListAttributeBuilder{ElementType: vv.ElementType(ctx)} + scmAttr[fieldName] = ListAttributeBuilder{ElementType: attrType} case types.Map: - scmAttr[fieldName] = MapAttributeBuilder{ElementType: vv.ElementType(ctx)} + scmAttr[fieldName] = MapAttributeBuilder{ElementType: attrType} case types.Object: panic(fmt.Errorf("object fields must correspond to a complex type, got %s. %s", fieldType.Name(), common.TerraformBugErrorMessage)) } diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 783ba34afb..b8fec23ad5 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -82,19 +82,19 @@ func (a App) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToAttrType returns the representation of App in the Terraform plugin framework type +// ToObjectType returns the representation of App in the Terraform plugin framework type // system. -func (a App) ToAttrType(ctx context.Context) types.ObjectType { +func (a App) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.ToAttrType(ctx), + ElemType: AppDeployment{}.ToObjectType(ctx), }, "app_status": basetypes.ListType{ - ElemType: ApplicationStatus{}.ToAttrType(ctx), + ElemType: ApplicationStatus{}.ToObjectType(ctx), }, "compute_status": basetypes.ListType{ - ElemType: ComputeStatus{}.ToAttrType(ctx), + ElemType: ComputeStatus{}.ToObjectType(ctx), }, "create_time": types.StringType, "creator": types.StringType, @@ -102,10 +102,10 @@ func (a App) ToAttrType(ctx context.Context) types.ObjectType { "description": types.StringType, "name": types.StringType, "pending_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.ToAttrType(ctx), + ElemType: AppDeployment{}.ToObjectType(ctx), }, "resources": basetypes.ListType{ - ElemType: AppResource{}.ToAttrType(ctx), + ElemType: AppResource{}.ToObjectType(ctx), }, "service_principal_client_id": types.StringType, "service_principal_id": types.Int64Type, @@ -145,9 +145,9 @@ func (a AppAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of AppAccessControlRequest in the Terraform plugin framework type // system. -func (a AppAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -190,13 +190,13 @@ func (a AppAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of AppAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AppAccessControlResponse in the Terraform plugin framework type // system. -func (a AppAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: AppPermission{}.ToAttrType(ctx), + ElemType: AppPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -251,21 +251,21 @@ func (a AppDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of AppDeployment in the Terraform plugin framework type +// ToObjectType returns the representation of AppDeployment in the Terraform plugin framework type // system. -func (a AppDeployment) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppDeployment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, "creator": types.StringType, "deployment_artifacts": basetypes.ListType{ - ElemType: AppDeploymentArtifacts{}.ToAttrType(ctx), + ElemType: AppDeploymentArtifacts{}.ToObjectType(ctx), }, "deployment_id": types.StringType, "mode": types.StringType, "source_code_path": types.StringType, "status": basetypes.ListType{ - ElemType: AppDeploymentStatus{}.ToAttrType(ctx), + ElemType: AppDeploymentStatus{}.ToObjectType(ctx), }, "update_time": types.StringType, }, @@ -295,9 +295,9 @@ func (a AppDeploymentArtifacts) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppDeploymentArtifacts in the Terraform plugin framework type +// ToObjectType returns the representation of AppDeploymentArtifacts in the Terraform plugin framework type // system. -func (a AppDeploymentArtifacts) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppDeploymentArtifacts) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "source_code_path": types.StringType, @@ -329,9 +329,9 @@ func (a AppDeploymentStatus) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppDeploymentStatus in the Terraform plugin framework type +// ToObjectType returns the representation of AppDeploymentStatus in the Terraform plugin framework type // system. -func (a AppDeploymentStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppDeploymentStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -367,9 +367,9 @@ func (a AppPermission) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of AppPermission in the Terraform plugin framework type +// ToObjectType returns the representation of AppPermission in the Terraform plugin framework type // system. -func (a AppPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -408,13 +408,13 @@ func (a AppPermissions) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of AppPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of AppPermissions in the Terraform plugin framework type // system. -func (a AppPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AppAccessControlResponse{}.ToAttrType(ctx), + ElemType: AppAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -445,9 +445,9 @@ func (a AppPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of AppPermissionsDescription in the Terraform plugin framework type // system. -func (a AppPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -481,13 +481,13 @@ func (a AppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of AppPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of AppPermissionsRequest in the Terraform plugin framework type // system. -func (a AppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AppAccessControlRequest{}.ToAttrType(ctx), + ElemType: AppAccessControlRequest{}.ToObjectType(ctx), }, "app_name": types.StringType, }, @@ -531,24 +531,24 @@ func (a AppResource) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of AppResource in the Terraform plugin framework type +// ToObjectType returns the representation of AppResource in the Terraform plugin framework type // system. -func (a AppResource) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppResource) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, "job": basetypes.ListType{ - ElemType: AppResourceJob{}.ToAttrType(ctx), + ElemType: AppResourceJob{}.ToObjectType(ctx), }, "name": types.StringType, "secret": basetypes.ListType{ - ElemType: AppResourceSecret{}.ToAttrType(ctx), + ElemType: AppResourceSecret{}.ToObjectType(ctx), }, "serving_endpoint": basetypes.ListType{ - ElemType: AppResourceServingEndpoint{}.ToAttrType(ctx), + ElemType: AppResourceServingEndpoint{}.ToObjectType(ctx), }, "sql_warehouse": basetypes.ListType{ - ElemType: AppResourceSqlWarehouse{}.ToAttrType(ctx), + ElemType: AppResourceSqlWarehouse{}.ToObjectType(ctx), }, }, } @@ -579,9 +579,9 @@ func (a AppResourceJob) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppResourceJob in the Terraform plugin framework type +// ToObjectType returns the representation of AppResourceJob in the Terraform plugin framework type // system. -func (a AppResourceJob) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppResourceJob) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -617,9 +617,9 @@ func (a AppResourceSecret) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppResourceSecret in the Terraform plugin framework type +// ToObjectType returns the representation of AppResourceSecret in the Terraform plugin framework type // system. -func (a AppResourceSecret) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppResourceSecret) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -654,9 +654,9 @@ func (a AppResourceServingEndpoint) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppResourceServingEndpoint in the Terraform plugin framework type +// ToObjectType returns the representation of AppResourceServingEndpoint in the Terraform plugin framework type // system. -func (a AppResourceServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppResourceServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -690,9 +690,9 @@ func (a AppResourceSqlWarehouse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of AppResourceSqlWarehouse in the Terraform plugin framework type +// ToObjectType returns the representation of AppResourceSqlWarehouse in the Terraform plugin framework type // system. -func (a AppResourceSqlWarehouse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AppResourceSqlWarehouse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -725,9 +725,9 @@ func (a ApplicationStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ApplicationStatus in the Terraform plugin framework type +// ToObjectType returns the representation of ApplicationStatus in the Terraform plugin framework type // system. -func (a ApplicationStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a ApplicationStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -760,9 +760,9 @@ func (a ComputeStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ComputeStatus in the Terraform plugin framework type +// ToObjectType returns the representation of ComputeStatus in the Terraform plugin framework type // system. -func (a ComputeStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a ComputeStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -797,13 +797,13 @@ func (a CreateAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of CreateAppDeploymentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateAppDeploymentRequest in the Terraform plugin framework type // system. -func (a CreateAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateAppDeploymentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.ToAttrType(ctx), + ElemType: AppDeployment{}.ToObjectType(ctx), }, "app_name": types.StringType, }, @@ -834,13 +834,13 @@ func (a CreateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of CreateAppRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateAppRequest in the Terraform plugin framework type // system. -func (a CreateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateAppRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app": basetypes.ListType{ - ElemType: App{}.ToAttrType(ctx), + ElemType: App{}.ToObjectType(ctx), }, }, } @@ -869,9 +869,9 @@ func (a DeleteAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAppRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAppRequest in the Terraform plugin framework type // system. -func (a DeleteAppRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAppRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -904,9 +904,9 @@ func (a GetAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAppDeploymentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAppDeploymentRequest in the Terraform plugin framework type // system. -func (a GetAppDeploymentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAppDeploymentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -938,9 +938,9 @@ func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAppPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAppPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetAppPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAppPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -972,13 +972,13 @@ func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of GetAppPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetAppPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetAppPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAppPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: AppPermissionsDescription{}.ToAttrType(ctx), + ElemType: AppPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -1007,9 +1007,9 @@ func (a GetAppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAppPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAppPermissionsRequest in the Terraform plugin framework type // system. -func (a GetAppPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAppPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -1040,9 +1040,9 @@ func (a GetAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAppRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAppRequest in the Terraform plugin framework type // system. -func (a GetAppRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAppRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1078,9 +1078,9 @@ func (a ListAppDeploymentsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAppDeploymentsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAppDeploymentsRequest in the Terraform plugin framework type // system. -func (a ListAppDeploymentsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAppDeploymentsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -1116,13 +1116,13 @@ func (a ListAppDeploymentsResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListAppDeploymentsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAppDeploymentsResponse in the Terraform plugin framework type // system. -func (a ListAppDeploymentsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAppDeploymentsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_deployments": basetypes.ListType{ - ElemType: AppDeployment{}.ToAttrType(ctx), + ElemType: AppDeployment{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -1155,9 +1155,9 @@ func (a ListAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAppsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAppsRequest in the Terraform plugin framework type // system. -func (a ListAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAppsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -1191,13 +1191,13 @@ func (a ListAppsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ListAppsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAppsResponse in the Terraform plugin framework type // system. -func (a ListAppsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAppsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: App{}.ToAttrType(ctx), + ElemType: App{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -1226,9 +1226,9 @@ func (a StartAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of StartAppRequest in the Terraform plugin framework type +// ToObjectType returns the representation of StartAppRequest in the Terraform plugin framework type // system. -func (a StartAppRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartAppRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1258,9 +1258,9 @@ func (a StopAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of StopAppRequest in the Terraform plugin framework type +// ToObjectType returns the representation of StopAppRequest in the Terraform plugin framework type // system. -func (a StopAppRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a StopAppRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1295,13 +1295,13 @@ func (a UpdateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of UpdateAppRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAppRequest in the Terraform plugin framework type // system. -func (a UpdateAppRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAppRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app": basetypes.ListType{ - ElemType: App{}.ToAttrType(ctx), + ElemType: App{}.ToObjectType(ctx), }, "name": types.StringType, }, diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 80b508ae2a..f67766303a 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -46,9 +46,9 @@ func (a ActionConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of ActionConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of ActionConfiguration in the Terraform plugin framework type // system. -func (a ActionConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a ActionConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_configuration_id": types.StringType, @@ -96,13 +96,13 @@ func (a AlertConfiguration) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of AlertConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of AlertConfiguration in the Terraform plugin framework type // system. -func (a AlertConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_configurations": basetypes.ListType{ - ElemType: ActionConfiguration{}.ToAttrType(ctx), + ElemType: ActionConfiguration{}.ToObjectType(ctx), }, "alert_configuration_id": types.StringType, "quantity_threshold": types.StringType, @@ -154,20 +154,20 @@ func (a BudgetConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of BudgetConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of BudgetConfiguration in the Terraform plugin framework type // system. -func (a BudgetConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a BudgetConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "alert_configurations": basetypes.ListType{ - ElemType: AlertConfiguration{}.ToAttrType(ctx), + ElemType: AlertConfiguration{}.ToObjectType(ctx), }, "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.ToAttrType(ctx), + ElemType: BudgetConfigurationFilter{}.ToObjectType(ctx), }, "update_time": types.Int64Type, }, @@ -203,16 +203,16 @@ func (a BudgetConfigurationFilter) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of BudgetConfigurationFilter in the Terraform plugin framework type +// ToObjectType returns the representation of BudgetConfigurationFilter in the Terraform plugin framework type // system. -func (a BudgetConfigurationFilter) ToAttrType(ctx context.Context) types.ObjectType { +func (a BudgetConfigurationFilter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "tags": basetypes.ListType{ - ElemType: BudgetConfigurationFilterTagClause{}.ToAttrType(ctx), + ElemType: BudgetConfigurationFilterTagClause{}.ToObjectType(ctx), }, "workspace_id": basetypes.ListType{ - ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.ToAttrType(ctx), + ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.ToObjectType(ctx), }, }, } @@ -243,9 +243,9 @@ func (a BudgetConfigurationFilterClause) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of BudgetConfigurationFilterClause in the Terraform plugin framework type +// ToObjectType returns the representation of BudgetConfigurationFilterClause in the Terraform plugin framework type // system. -func (a BudgetConfigurationFilterClause) ToAttrType(ctx context.Context) types.ObjectType { +func (a BudgetConfigurationFilterClause) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, @@ -281,14 +281,14 @@ func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of BudgetConfigurationFilterTagClause in the Terraform plugin framework type +// ToObjectType returns the representation of BudgetConfigurationFilterTagClause in the Terraform plugin framework type // system. -func (a BudgetConfigurationFilterTagClause) ToAttrType(ctx context.Context) types.ObjectType { +func (a BudgetConfigurationFilterTagClause) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, "value": basetypes.ListType{ - ElemType: BudgetConfigurationFilterClause{}.ToAttrType(ctx), + ElemType: BudgetConfigurationFilterClause{}.ToObjectType(ctx), }, }, } @@ -319,9 +319,9 @@ func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes(ctx con } } -// ToAttrType returns the representation of BudgetConfigurationFilterWorkspaceIdClause in the Terraform plugin framework type +// ToObjectType returns the representation of BudgetConfigurationFilterWorkspaceIdClause in the Terraform plugin framework type // system. -func (a BudgetConfigurationFilterWorkspaceIdClause) ToAttrType(ctx context.Context) types.ObjectType { +func (a BudgetConfigurationFilterWorkspaceIdClause) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, @@ -359,9 +359,9 @@ func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateBillingUsageDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBillingUsageDashboardRequest in the Terraform plugin framework type // system. -func (a CreateBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBillingUsageDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_type": types.StringType, @@ -392,9 +392,9 @@ func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateBillingUsageDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBillingUsageDashboardResponse in the Terraform plugin framework type // system. -func (a CreateBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBillingUsageDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -437,18 +437,18 @@ func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of CreateBudgetConfigurationBudget in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBudgetConfigurationBudget in the Terraform plugin framework type // system. -func (a CreateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBudgetConfigurationBudget) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "alert_configurations": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.ToAttrType(ctx), + ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.ToObjectType(ctx), }, "display_name": types.StringType, "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.ToAttrType(ctx), + ElemType: BudgetConfigurationFilter{}.ToObjectType(ctx), }, }, } @@ -478,9 +478,9 @@ func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldType return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateBudgetConfigurationBudgetActionConfigurations in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBudgetConfigurationBudgetActionConfigurations in the Terraform plugin framework type // system. -func (a CreateBudgetConfigurationBudgetActionConfigurations) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBudgetConfigurationBudgetActionConfigurations) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_type": types.StringType, @@ -525,13 +525,13 @@ func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes } } -// ToAttrType returns the representation of CreateBudgetConfigurationBudgetAlertConfigurations in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBudgetConfigurationBudgetAlertConfigurations in the Terraform plugin framework type // system. -func (a CreateBudgetConfigurationBudgetAlertConfigurations) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_configurations": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.ToAttrType(ctx), + ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.ToObjectType(ctx), }, "quantity_threshold": types.StringType, "quantity_type": types.StringType, @@ -565,13 +565,13 @@ func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of CreateBudgetConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBudgetConfigurationRequest in the Terraform plugin framework type // system. -func (a CreateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudget{}.ToAttrType(ctx), + ElemType: CreateBudgetConfigurationBudget{}.ToObjectType(ctx), }, }, } @@ -601,13 +601,13 @@ func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of CreateBudgetConfigurationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateBudgetConfigurationResponse in the Terraform plugin framework type // system. -func (a CreateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToAttrType(ctx), + ElemType: BudgetConfiguration{}.ToObjectType(ctx), }, }, } @@ -704,9 +704,9 @@ func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of CreateLogDeliveryConfigurationParams in the Terraform plugin framework type +// ToObjectType returns the representation of CreateLogDeliveryConfigurationParams in the Terraform plugin framework type // system. -func (a CreateLogDeliveryConfigurationParams) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateLogDeliveryConfigurationParams) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config_name": types.StringType, @@ -747,9 +747,9 @@ func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteBudgetConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteBudgetConfigurationRequest in the Terraform plugin framework type // system. -func (a DeleteBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_id": types.StringType, @@ -777,9 +777,9 @@ func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteBudgetConfigurationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteBudgetConfigurationResponse in the Terraform plugin framework type // system. -func (a DeleteBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -816,9 +816,9 @@ func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DownloadRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DownloadRequest in the Terraform plugin framework type // system. -func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DownloadRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_month": types.StringType, @@ -849,9 +849,9 @@ func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of DownloadResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DownloadResponse in the Terraform plugin framework type // system. -func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DownloadResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.ObjectType{}, @@ -887,9 +887,9 @@ func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetBillingUsageDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetBillingUsageDashboardRequest in the Terraform plugin framework type // system. -func (a GetBillingUsageDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetBillingUsageDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_type": types.StringType, @@ -922,9 +922,9 @@ func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetBillingUsageDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetBillingUsageDashboardResponse in the Terraform plugin framework type // system. -func (a GetBillingUsageDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetBillingUsageDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -956,9 +956,9 @@ func (a GetBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetBudgetConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetBudgetConfigurationRequest in the Terraform plugin framework type // system. -func (a GetBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_id": types.StringType, @@ -989,13 +989,13 @@ func (a GetBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of GetBudgetConfigurationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetBudgetConfigurationResponse in the Terraform plugin framework type // system. -func (a GetBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToAttrType(ctx), + ElemType: BudgetConfiguration{}.ToObjectType(ctx), }, }, } @@ -1024,9 +1024,9 @@ func (a GetLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetLogDeliveryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetLogDeliveryRequest in the Terraform plugin framework type // system. -func (a GetLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetLogDeliveryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration_id": types.StringType, @@ -1059,9 +1059,9 @@ func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListBudgetConfigurationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListBudgetConfigurationsRequest in the Terraform plugin framework type // system. -func (a ListBudgetConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListBudgetConfigurationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -1095,13 +1095,13 @@ func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of ListBudgetConfigurationsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListBudgetConfigurationsResponse in the Terraform plugin framework type // system. -func (a ListBudgetConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListBudgetConfigurationsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budgets": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToAttrType(ctx), + ElemType: BudgetConfiguration{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -1135,9 +1135,9 @@ func (a ListLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListLogDeliveryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListLogDeliveryRequest in the Terraform plugin framework type // system. -func (a ListLogDeliveryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListLogDeliveryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials_id": types.StringType, @@ -1251,9 +1251,9 @@ func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of LogDeliveryConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of LogDeliveryConfiguration in the Terraform plugin framework type // system. -func (a LogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogDeliveryConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, @@ -1264,7 +1264,7 @@ func (a LogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectTy "delivery_path_prefix": types.StringType, "delivery_start_time": types.StringType, "log_delivery_status": basetypes.ListType{ - ElemType: LogDeliveryStatus{}.ToAttrType(ctx), + ElemType: LogDeliveryStatus{}.ToObjectType(ctx), }, "log_type": types.StringType, "output_format": types.StringType, @@ -1318,9 +1318,9 @@ func (a LogDeliveryStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogDeliveryStatus in the Terraform plugin framework type +// ToObjectType returns the representation of LogDeliveryStatus in the Terraform plugin framework type // system. -func (a LogDeliveryStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogDeliveryStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_attempt_time": types.StringType, @@ -1351,9 +1351,9 @@ func (a PatchStatusResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of PatchStatusResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PatchStatusResponse in the Terraform plugin framework type // system. -func (a PatchStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PatchStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1396,19 +1396,19 @@ func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of UpdateBudgetConfigurationBudget in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateBudgetConfigurationBudget in the Terraform plugin framework type // system. -func (a UpdateBudgetConfigurationBudget) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateBudgetConfigurationBudget) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "alert_configurations": basetypes.ListType{ - ElemType: AlertConfiguration{}.ToAttrType(ctx), + ElemType: AlertConfiguration{}.ToObjectType(ctx), }, "budget_configuration_id": types.StringType, "display_name": types.StringType, "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.ToAttrType(ctx), + ElemType: BudgetConfigurationFilter{}.ToObjectType(ctx), }, }, } @@ -1441,13 +1441,13 @@ func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of UpdateBudgetConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateBudgetConfigurationRequest in the Terraform plugin framework type // system. -func (a UpdateBudgetConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: UpdateBudgetConfigurationBudget{}.ToAttrType(ctx), + ElemType: UpdateBudgetConfigurationBudget{}.ToObjectType(ctx), }, "budget_id": types.StringType, }, @@ -1478,13 +1478,13 @@ func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of UpdateBudgetConfigurationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateBudgetConfigurationResponse in the Terraform plugin framework type // system. -func (a UpdateBudgetConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToAttrType(ctx), + ElemType: BudgetConfiguration{}.ToObjectType(ctx), }, }, } @@ -1518,9 +1518,9 @@ func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateLogDeliveryConfigurationStatusRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateLogDeliveryConfigurationStatusRequest in the Terraform plugin framework type // system. -func (a UpdateLogDeliveryConfigurationStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateLogDeliveryConfigurationStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration_id": types.StringType, @@ -1552,13 +1552,13 @@ func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes(ctx context. } } -// ToAttrType returns the representation of WrappedCreateLogDeliveryConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of WrappedCreateLogDeliveryConfiguration in the Terraform plugin framework type // system. -func (a WrappedCreateLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a WrappedCreateLogDeliveryConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration": basetypes.ListType{ - ElemType: CreateLogDeliveryConfigurationParams{}.ToAttrType(ctx), + ElemType: CreateLogDeliveryConfigurationParams{}.ToObjectType(ctx), }, }, } @@ -1587,13 +1587,13 @@ func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of WrappedLogDeliveryConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of WrappedLogDeliveryConfiguration in the Terraform plugin framework type // system. -func (a WrappedLogDeliveryConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a WrappedLogDeliveryConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration": basetypes.ListType{ - ElemType: LogDeliveryConfiguration{}.ToAttrType(ctx), + ElemType: LogDeliveryConfiguration{}.ToObjectType(ctx), }, }, } @@ -1622,13 +1622,13 @@ func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of WrappedLogDeliveryConfigurations in the Terraform plugin framework type +// ToObjectType returns the representation of WrappedLogDeliveryConfigurations in the Terraform plugin framework type // system. -func (a WrappedLogDeliveryConfigurations) ToAttrType(ctx context.Context) types.ObjectType { +func (a WrappedLogDeliveryConfigurations) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configurations": basetypes.ListType{ - ElemType: LogDeliveryConfiguration{}.ToAttrType(ctx), + ElemType: LogDeliveryConfiguration{}.ToObjectType(ctx), }, }, } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 03c386aab7..6d9037c078 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -42,13 +42,13 @@ func (a AccountsCreateMetastore) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of AccountsCreateMetastore in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsCreateMetastore in the Terraform plugin framework type // system. -func (a AccountsCreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsCreateMetastore) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_info": basetypes.ListType{ - ElemType: CreateMetastore{}.ToAttrType(ctx), + ElemType: CreateMetastore{}.ToObjectType(ctx), }, }, } @@ -81,13 +81,13 @@ func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of AccountsCreateMetastoreAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsCreateMetastoreAssignment in the Terraform plugin framework type // system. -func (a AccountsCreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsCreateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_assignment": basetypes.ListType{ - ElemType: CreateMetastoreAssignment{}.ToAttrType(ctx), + ElemType: CreateMetastoreAssignment{}.ToObjectType(ctx), }, "metastore_id": types.StringType, "workspace_id": types.Int64Type, @@ -120,13 +120,13 @@ func (a AccountsCreateStorageCredential) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of AccountsCreateStorageCredential in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsCreateStorageCredential in the Terraform plugin framework type // system. -func (a AccountsCreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsCreateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_info": basetypes.ListType{ - ElemType: CreateStorageCredential{}.ToAttrType(ctx), + ElemType: CreateStorageCredential{}.ToObjectType(ctx), }, "metastore_id": types.StringType, }, @@ -156,13 +156,13 @@ func (a AccountsMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of AccountsMetastoreAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsMetastoreAssignment in the Terraform plugin framework type // system. -func (a AccountsMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_assignment": basetypes.ListType{ - ElemType: MetastoreAssignment{}.ToAttrType(ctx), + ElemType: MetastoreAssignment{}.ToObjectType(ctx), }, }, } @@ -191,13 +191,13 @@ func (a AccountsMetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of AccountsMetastoreInfo in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsMetastoreInfo in the Terraform plugin framework type // system. -func (a AccountsMetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsMetastoreInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_info": basetypes.ListType{ - ElemType: MetastoreInfo{}.ToAttrType(ctx), + ElemType: MetastoreInfo{}.ToObjectType(ctx), }, }, } @@ -226,13 +226,13 @@ func (a AccountsStorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of AccountsStorageCredentialInfo in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsStorageCredentialInfo in the Terraform plugin framework type // system. -func (a AccountsStorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsStorageCredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_info": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.ToAttrType(ctx), + ElemType: StorageCredentialInfo{}.ToObjectType(ctx), }, }, } @@ -264,14 +264,14 @@ func (a AccountsUpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of AccountsUpdateMetastore in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsUpdateMetastore in the Terraform plugin framework type // system. -func (a AccountsUpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsUpdateMetastore) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, "metastore_info": basetypes.ListType{ - ElemType: UpdateMetastore{}.ToAttrType(ctx), + ElemType: UpdateMetastore{}.ToObjectType(ctx), }, }, } @@ -304,13 +304,13 @@ func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of AccountsUpdateMetastoreAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsUpdateMetastoreAssignment in the Terraform plugin framework type // system. -func (a AccountsUpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsUpdateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_assignment": basetypes.ListType{ - ElemType: UpdateMetastoreAssignment{}.ToAttrType(ctx), + ElemType: UpdateMetastoreAssignment{}.ToObjectType(ctx), }, "metastore_id": types.StringType, "workspace_id": types.Int64Type, @@ -345,13 +345,13 @@ func (a AccountsUpdateStorageCredential) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of AccountsUpdateStorageCredential in the Terraform plugin framework type +// ToObjectType returns the representation of AccountsUpdateStorageCredential in the Terraform plugin framework type // system. -func (a AccountsUpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccountsUpdateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_info": basetypes.ListType{ - ElemType: UpdateStorageCredential{}.ToAttrType(ctx), + ElemType: UpdateStorageCredential{}.ToObjectType(ctx), }, "metastore_id": types.StringType, "storage_credential_name": types.StringType, @@ -389,13 +389,13 @@ func (a ArtifactAllowlistInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ArtifactAllowlistInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ArtifactAllowlistInfo in the Terraform plugin framework type // system. -func (a ArtifactAllowlistInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ArtifactAllowlistInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_matchers": basetypes.ListType{ - ElemType: ArtifactMatcher{}.ToAttrType(ctx), + ElemType: ArtifactMatcher{}.ToObjectType(ctx), }, "created_at": types.Int64Type, "created_by": types.StringType, @@ -428,9 +428,9 @@ func (a ArtifactMatcher) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ArtifactMatcher in the Terraform plugin framework type +// ToObjectType returns the representation of ArtifactMatcher in the Terraform plugin framework type // system. -func (a ArtifactMatcher) ToAttrType(ctx context.Context) types.ObjectType { +func (a ArtifactMatcher) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact": types.StringType, @@ -459,9 +459,9 @@ func (a AssignResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of AssignResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AssignResponse in the Terraform plugin framework type // system. -func (a AssignResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AssignResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -499,9 +499,9 @@ func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of AwsCredentials in the Terraform plugin framework type +// ToObjectType returns the representation of AwsCredentials in the Terraform plugin framework type // system. -func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsCredentials) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_key_id": types.StringType, @@ -542,9 +542,9 @@ func (a AwsIamRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of AwsIamRole in the Terraform plugin framework type +// ToObjectType returns the representation of AwsIamRole in the Terraform plugin framework type // system. -func (a AwsIamRole) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsIamRole) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_id": types.StringType, @@ -576,9 +576,9 @@ func (a AwsIamRoleRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of AwsIamRoleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of AwsIamRoleRequest in the Terraform plugin framework type // system. -func (a AwsIamRoleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsIamRoleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "role_arn": types.StringType, @@ -614,9 +614,9 @@ func (a AwsIamRoleResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of AwsIamRoleResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AwsIamRoleResponse in the Terraform plugin framework type // system. -func (a AwsIamRoleResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsIamRoleResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_id": types.StringType, @@ -652,9 +652,9 @@ func (a AzureActiveDirectoryToken) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureActiveDirectoryToken in the Terraform plugin framework type +// ToObjectType returns the representation of AzureActiveDirectoryToken in the Terraform plugin framework type // system. -func (a AzureActiveDirectoryToken) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureActiveDirectoryToken) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aad_token": types.StringType, @@ -699,9 +699,9 @@ func (a AzureManagedIdentity) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureManagedIdentity in the Terraform plugin framework type +// ToObjectType returns the representation of AzureManagedIdentity in the Terraform plugin framework type // system. -func (a AzureManagedIdentity) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureManagedIdentity) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_connector_id": types.StringType, @@ -742,9 +742,9 @@ func (a AzureManagedIdentityRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureManagedIdentityRequest in the Terraform plugin framework type +// ToObjectType returns the representation of AzureManagedIdentityRequest in the Terraform plugin framework type // system. -func (a AzureManagedIdentityRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureManagedIdentityRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_connector_id": types.StringType, @@ -786,9 +786,9 @@ func (a AzureManagedIdentityResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureManagedIdentityResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AzureManagedIdentityResponse in the Terraform plugin framework type // system. -func (a AzureManagedIdentityResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureManagedIdentityResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_connector_id": types.StringType, @@ -827,9 +827,9 @@ func (a AzureServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureServicePrincipal in the Terraform plugin framework type +// ToObjectType returns the representation of AzureServicePrincipal in the Terraform plugin framework type // system. -func (a AzureServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureServicePrincipal) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "application_id": types.StringType, @@ -863,9 +863,9 @@ func (a AzureUserDelegationSas) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureUserDelegationSas in the Terraform plugin framework type +// ToObjectType returns the representation of AzureUserDelegationSas in the Terraform plugin framework type // system. -func (a AzureUserDelegationSas) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureUserDelegationSas) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sas_token": types.StringType, @@ -898,9 +898,9 @@ func (a CancelRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelRefreshRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CancelRefreshRequest in the Terraform plugin framework type // system. -func (a CancelRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelRefreshRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "refresh_id": types.StringType, @@ -929,9 +929,9 @@ func (a CancelRefreshResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelRefreshResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CancelRefreshResponse in the Terraform plugin framework type // system. -func (a CancelRefreshResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelRefreshResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1017,9 +1017,9 @@ func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of CatalogInfo in the Terraform plugin framework type +// ToObjectType returns the representation of CatalogInfo in the Terraform plugin framework type // system. -func (a CatalogInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a CatalogInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "browse_only": types.BoolType, @@ -1029,7 +1029,7 @@ func (a CatalogInfo) ToAttrType(ctx context.Context) types.ObjectType { "created_at": types.Int64Type, "created_by": types.StringType, "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + ElemType: EffectivePredictiveOptimizationFlag{}.ToObjectType(ctx), }, "enable_predictive_optimization": types.StringType, "full_name": types.StringType, @@ -1045,7 +1045,7 @@ func (a CatalogInfo) ToAttrType(ctx context.Context) types.ObjectType { }, "provider_name": types.StringType, "provisioning_info": basetypes.ListType{ - ElemType: ProvisioningInfo{}.ToAttrType(ctx), + ElemType: ProvisioningInfo{}.ToObjectType(ctx), }, "securable_kind": types.StringType, "securable_type": types.StringType, @@ -1084,9 +1084,9 @@ func (a CloudflareApiToken) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of CloudflareApiToken in the Terraform plugin framework type +// ToObjectType returns the representation of CloudflareApiToken in the Terraform plugin framework type // system. -func (a CloudflareApiToken) ToAttrType(ctx context.Context) types.ObjectType { +func (a CloudflareApiToken) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_key_id": types.StringType, @@ -1142,14 +1142,14 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of ColumnInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ColumnInfo in the Terraform plugin framework type // system. -func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ColumnInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "mask": basetypes.ListType{ - ElemType: ColumnMask{}.ToAttrType(ctx), + ElemType: ColumnMask{}.ToObjectType(ctx), }, "name": types.StringType, "nullable": types.BoolType, @@ -1194,9 +1194,9 @@ func (a ColumnMask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of ColumnMask in the Terraform plugin framework type +// ToObjectType returns the representation of ColumnMask in the Terraform plugin framework type // system. -func (a ColumnMask) ToAttrType(ctx context.Context) types.ObjectType { +func (a ColumnMask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_name": types.StringType, @@ -1270,9 +1270,9 @@ func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ConnectionInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ConnectionInfo in the Terraform plugin framework type // system. -func (a ConnectionInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ConnectionInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1292,7 +1292,7 @@ func (a ConnectionInfo) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "provisioning_info": basetypes.ListType{ - ElemType: ProvisioningInfo{}.ToAttrType(ctx), + ElemType: ProvisioningInfo{}.ToObjectType(ctx), }, "read_only": types.BoolType, "securable_kind": types.StringType, @@ -1337,13 +1337,13 @@ func (a ContinuousUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ContinuousUpdateStatus in the Terraform plugin framework type +// ToObjectType returns the representation of ContinuousUpdateStatus in the Terraform plugin framework type // system. -func (a ContinuousUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a ContinuousUpdateStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "initial_pipeline_sync_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.ToAttrType(ctx), + ElemType: PipelineProgress{}.ToObjectType(ctx), }, "last_processed_commit_version": types.Int64Type, "timestamp": types.StringType, @@ -1393,9 +1393,9 @@ func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of CreateCatalog in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCatalog in the Terraform plugin framework type // system. -func (a CreateCatalog) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCatalog) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1450,9 +1450,9 @@ func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of CreateConnection in the Terraform plugin framework type +// ToObjectType returns the representation of CreateConnection in the Terraform plugin framework type // system. -func (a CreateConnection) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateConnection) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1516,23 +1516,23 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of CreateCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCredentialRequest in the Terraform plugin framework type // system. -func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToAttrType(ctx), + ElemType: AwsIamRole{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + ElemType: AzureManagedIdentity{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "comment": types.StringType, "gcp_service_account_key": basetypes.ListType{ - ElemType: GcpServiceAccountKey{}.ToAttrType(ctx), + ElemType: GcpServiceAccountKey{}.ToObjectType(ctx), }, "name": types.StringType, "purpose": types.StringType, @@ -1585,16 +1585,16 @@ func (a CreateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CreateExternalLocation in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExternalLocation in the Terraform plugin framework type // system. -func (a CreateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExternalLocation) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, "comment": types.StringType, "credential_name": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToAttrType(ctx), + ElemType: EncryptionDetails{}.ToObjectType(ctx), }, "fallback": types.BoolType, "name": types.StringType, @@ -1675,9 +1675,9 @@ func (a CreateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of CreateFunction in the Terraform plugin framework type +// ToObjectType returns the representation of CreateFunction in the Terraform plugin framework type // system. -func (a CreateFunction) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateFunction) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -1687,7 +1687,7 @@ func (a CreateFunction) ToAttrType(ctx context.Context) types.ObjectType { "external_name": types.StringType, "full_data_type": types.StringType, "input_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + ElemType: FunctionParameterInfos{}.ToObjectType(ctx), }, "is_deterministic": types.BoolType, "is_null_call": types.BoolType, @@ -1695,12 +1695,12 @@ func (a CreateFunction) ToAttrType(ctx context.Context) types.ObjectType { "parameter_style": types.StringType, "properties": types.StringType, "return_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + ElemType: FunctionParameterInfos{}.ToObjectType(ctx), }, "routine_body": types.StringType, "routine_definition": types.StringType, "routine_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToAttrType(ctx), + ElemType: DependencyList{}.ToObjectType(ctx), }, "schema_name": types.StringType, "security_type": types.StringType, @@ -1735,13 +1735,13 @@ func (a CreateFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateFunctionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateFunctionRequest in the Terraform plugin framework type // system. -func (a CreateFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateFunctionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_info": basetypes.ListType{ - ElemType: CreateFunction{}.ToAttrType(ctx), + ElemType: CreateFunction{}.ToObjectType(ctx), }, }, } @@ -1776,9 +1776,9 @@ func (a CreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateMetastore in the Terraform plugin framework type +// ToObjectType returns the representation of CreateMetastore in the Terraform plugin framework type // system. -func (a CreateMetastore) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateMetastore) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1816,9 +1816,9 @@ func (a CreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateMetastoreAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of CreateMetastoreAssignment in the Terraform plugin framework type // system. -func (a CreateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_catalog_name": types.StringType, @@ -1859,7 +1859,7 @@ type CreateMonitor struct { // slices. SlicingExprs types.List `tfsdk:"slicing_exprs" tf:"optional"` // Configuration for monitoring snapshot tables. - Snapshot []MonitorSnapshot `tfsdk:"snapshot" tf:"optional,object"` + Snapshot types.List `tfsdk:"snapshot" tf:"optional,object"` // Full name of the table. TableName types.String `tfsdk:"-"` // Configuration for monitoring time series tables. @@ -1895,39 +1895,39 @@ func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of CreateMonitor in the Terraform plugin framework type +// ToObjectType returns the representation of CreateMonitor in the Terraform plugin framework type // system. -func (a CreateMonitor) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateMonitor) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.ToAttrType(ctx), + ElemType: MonitorMetric{}.ToObjectType(ctx), }, "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.ToAttrType(ctx), + ElemType: MonitorDataClassificationConfig{}.ToObjectType(ctx), }, "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.ToAttrType(ctx), + ElemType: MonitorInferenceLog{}.ToObjectType(ctx), }, "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.ToAttrType(ctx), + ElemType: MonitorNotifications{}.ToObjectType(ctx), }, "output_schema_name": types.StringType, "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.ToAttrType(ctx), + ElemType: MonitorCronSchedule{}.ToObjectType(ctx), }, "skip_builtin_dashboard": types.BoolType, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.ToAttrType(ctx), + ElemType: MonitorSnapshot{}.ToObjectType(ctx), }, "table_name": types.StringType, "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.ToAttrType(ctx), + ElemType: MonitorTimeSeries{}.ToObjectType(ctx), }, "warehouse_id": types.StringType, }, @@ -1959,13 +1959,13 @@ func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of CreateOnlineTableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateOnlineTableRequest in the Terraform plugin framework type // system. -func (a CreateOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateOnlineTableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table": basetypes.ListType{ - ElemType: OnlineTable{}.ToAttrType(ctx), + ElemType: OnlineTable{}.ToObjectType(ctx), }, }, } @@ -2002,9 +2002,9 @@ func (a CreateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateRegisteredModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRegisteredModelRequest in the Terraform plugin framework type // system. -func (a CreateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2036,9 +2036,9 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type // system. -func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2076,9 +2076,9 @@ func (a CreateSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of CreateSchema in the Terraform plugin framework type +// ToObjectType returns the representation of CreateSchema in the Terraform plugin framework type // system. -func (a CreateSchema) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateSchema) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2104,7 +2104,7 @@ type CreateStorageCredential struct { // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // The Databricks managed GCP service account configuration. - DatabricksGcpServiceAccount []DatabricksGcpServiceAccountRequest `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` + DatabricksGcpServiceAccount types.List `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // The credential name. The name must be unique within the metastore. Name types.String `tfsdk:"name" tf:""` // Whether the storage credential is only usable for read operations. @@ -2137,26 +2137,26 @@ func (a CreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of CreateStorageCredential in the Terraform plugin framework type +// ToObjectType returns the representation of CreateStorageCredential in the Terraform plugin framework type // system. -func (a CreateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.ToAttrType(ctx), + ElemType: AwsIamRoleRequest{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityRequest{}.ToAttrType(ctx), + ElemType: AzureManagedIdentityRequest{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToAttrType(ctx), + ElemType: CloudflareApiToken{}.ToObjectType(ctx), }, "comment": types.StringType, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + ElemType: DatabricksGcpServiceAccountRequest{}.ToObjectType(ctx), }, "name": types.StringType, "read_only": types.BoolType, @@ -2193,13 +2193,13 @@ func (a CreateTableConstraint) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateTableConstraint in the Terraform plugin framework type +// ToObjectType returns the representation of CreateTableConstraint in the Terraform plugin framework type // system. -func (a CreateTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateTableConstraint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "constraint": basetypes.ListType{ - ElemType: TableConstraint{}.ToAttrType(ctx), + ElemType: TableConstraint{}.ToObjectType(ctx), }, "full_name_arg": types.StringType, }, @@ -2238,9 +2238,9 @@ func (a CreateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateVolumeRequestContent in the Terraform plugin framework type +// ToObjectType returns the representation of CreateVolumeRequestContent in the Terraform plugin framework type // system. -func (a CreateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateVolumeRequestContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2315,19 +2315,19 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of CredentialInfo in the Terraform plugin framework type +// ToObjectType returns the representation of CredentialInfo in the Terraform plugin framework type // system. -func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a CredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToAttrType(ctx), + ElemType: AwsIamRole{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + ElemType: AzureManagedIdentity{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "comment": types.StringType, "created_at": types.Int64Type, @@ -2371,9 +2371,9 @@ func (a CredentialValidationResult) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of CredentialValidationResult in the Terraform plugin framework type +// ToObjectType returns the representation of CredentialValidationResult in the Terraform plugin framework type // system. -func (a CredentialValidationResult) ToAttrType(ctx context.Context) types.ObjectType { +func (a CredentialValidationResult) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -2407,9 +2407,9 @@ func (a CurrentWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of CurrentWorkspaceBindings in the Terraform plugin framework type +// ToObjectType returns the representation of CurrentWorkspaceBindings in the Terraform plugin framework type // system. -func (a CurrentWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { +func (a CurrentWorkspaceBindings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspaces": basetypes.ListType{ @@ -2439,9 +2439,9 @@ func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of DatabricksGcpServiceAccountRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DatabricksGcpServiceAccountRequest in the Terraform plugin framework type // system. -func (a DatabricksGcpServiceAccountRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DatabricksGcpServiceAccountRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2472,9 +2472,9 @@ func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DatabricksGcpServiceAccountResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DatabricksGcpServiceAccountResponse in the Terraform plugin framework type // system. -func (a DatabricksGcpServiceAccountResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DatabricksGcpServiceAccountResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.StringType, @@ -2508,9 +2508,9 @@ func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountMetastoreAssignmentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountMetastoreAssignmentRequest in the Terraform plugin framework type // system. -func (a DeleteAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountMetastoreAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -2544,9 +2544,9 @@ func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountMetastoreRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountMetastoreRequest in the Terraform plugin framework type // system. -func (a DeleteAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2583,9 +2583,9 @@ func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountStorageCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountStorageCredentialRequest in the Terraform plugin framework type // system. -func (a DeleteAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2620,9 +2620,9 @@ func (a DeleteAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAliasRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAliasRequest in the Terraform plugin framework type // system. -func (a DeleteAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAliasRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias": types.StringType, @@ -2651,9 +2651,9 @@ func (a DeleteAliasResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAliasResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAliasResponse in the Terraform plugin framework type // system. -func (a DeleteAliasResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAliasResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2684,9 +2684,9 @@ func (a DeleteCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCatalogRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCatalogRequest in the Terraform plugin framework type // system. -func (a DeleteCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCatalogRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2718,9 +2718,9 @@ func (a DeleteConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteConnectionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteConnectionRequest in the Terraform plugin framework type // system. -func (a DeleteConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteConnectionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2755,9 +2755,9 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type // system. -func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2786,9 +2786,9 @@ func (a DeleteCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCredentialResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCredentialResponse in the Terraform plugin framework type // system. -func (a DeleteCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2819,9 +2819,9 @@ func (a DeleteExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExternalLocationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExternalLocationRequest in the Terraform plugin framework type // system. -func (a DeleteExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExternalLocationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2856,9 +2856,9 @@ func (a DeleteFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteFunctionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteFunctionRequest in the Terraform plugin framework type // system. -func (a DeleteFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteFunctionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2892,9 +2892,9 @@ func (a DeleteMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteMetastoreRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteMetastoreRequest in the Terraform plugin framework type // system. -func (a DeleteMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2928,9 +2928,9 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type // system. -func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -2962,9 +2962,9 @@ func (a DeleteOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteOnlineTableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteOnlineTableRequest in the Terraform plugin framework type // system. -func (a DeleteOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteOnlineTableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2995,9 +2995,9 @@ func (a DeleteQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteQualityMonitorRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteQualityMonitorRequest in the Terraform plugin framework type // system. -func (a DeleteQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteQualityMonitorRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -3028,9 +3028,9 @@ func (a DeleteRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRegisteredModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRegisteredModelRequest in the Terraform plugin framework type // system. -func (a DeleteRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -3058,9 +3058,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3091,9 +3091,9 @@ func (a DeleteSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteSchemaRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteSchemaRequest in the Terraform plugin framework type // system. -func (a DeleteSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteSchemaRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -3128,9 +3128,9 @@ func (a DeleteStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteStorageCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteStorageCredentialRequest in the Terraform plugin framework type // system. -func (a DeleteStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -3168,9 +3168,9 @@ func (a DeleteTableConstraintRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTableConstraintRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTableConstraintRequest in the Terraform plugin framework type // system. -func (a DeleteTableConstraintRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTableConstraintRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cascade": types.BoolType, @@ -3203,9 +3203,9 @@ func (a DeleteTableRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTableRequest in the Terraform plugin framework type // system. -func (a DeleteTableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -3236,9 +3236,9 @@ func (a DeleteVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteVolumeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteVolumeRequest in the Terraform plugin framework type // system. -func (a DeleteVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteVolumeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -3273,9 +3273,9 @@ func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of DeltaRuntimePropertiesKvPairs in the Terraform plugin framework type +// ToObjectType returns the representation of DeltaRuntimePropertiesKvPairs in the Terraform plugin framework type // system. -func (a DeltaRuntimePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeltaRuntimePropertiesKvPairs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "delta_runtime_properties": basetypes.MapType{ @@ -3314,16 +3314,16 @@ func (a Dependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of Dependency in the Terraform plugin framework type +// ToObjectType returns the representation of Dependency in the Terraform plugin framework type // system. -func (a Dependency) ToAttrType(ctx context.Context) types.ObjectType { +func (a Dependency) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function": basetypes.ListType{ - ElemType: FunctionDependency{}.ToAttrType(ctx), + ElemType: FunctionDependency{}.ToObjectType(ctx), }, "table": basetypes.ListType{ - ElemType: TableDependency{}.ToAttrType(ctx), + ElemType: TableDependency{}.ToObjectType(ctx), }, }, } @@ -3354,13 +3354,13 @@ func (a DependencyList) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of DependencyList in the Terraform plugin framework type +// ToObjectType returns the representation of DependencyList in the Terraform plugin framework type // system. -func (a DependencyList) ToAttrType(ctx context.Context) types.ObjectType { +func (a DependencyList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dependencies": basetypes.ListType{ - ElemType: Dependency{}.ToAttrType(ctx), + ElemType: Dependency{}.ToObjectType(ctx), }, }, } @@ -3391,9 +3391,9 @@ func (a DisableRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DisableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DisableRequest in the Terraform plugin framework type // system. -func (a DisableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DisableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -3422,9 +3422,9 @@ func (a DisableResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DisableResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DisableResponse in the Terraform plugin framework type // system. -func (a DisableResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DisableResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3455,13 +3455,13 @@ func (a EffectivePermissionsList) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of EffectivePermissionsList in the Terraform plugin framework type +// ToObjectType returns the representation of EffectivePermissionsList in the Terraform plugin framework type // system. -func (a EffectivePermissionsList) ToAttrType(ctx context.Context) types.ObjectType { +func (a EffectivePermissionsList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "privilege_assignments": basetypes.ListType{ - ElemType: EffectivePrivilegeAssignment{}.ToAttrType(ctx), + ElemType: EffectivePrivilegeAssignment{}.ToObjectType(ctx), }, }, } @@ -3496,9 +3496,9 @@ func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of EffectivePredictiveOptimizationFlag in the Terraform plugin framework type +// ToObjectType returns the representation of EffectivePredictiveOptimizationFlag in the Terraform plugin framework type // system. -func (a EffectivePredictiveOptimizationFlag) ToAttrType(ctx context.Context) types.ObjectType { +func (a EffectivePredictiveOptimizationFlag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited_from_name": types.StringType, @@ -3538,9 +3538,9 @@ func (a EffectivePrivilege) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of EffectivePrivilege in the Terraform plugin framework type +// ToObjectType returns the representation of EffectivePrivilege in the Terraform plugin framework type // system. -func (a EffectivePrivilege) ToAttrType(ctx context.Context) types.ObjectType { +func (a EffectivePrivilege) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited_from_name": types.StringType, @@ -3577,14 +3577,14 @@ func (a EffectivePrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of EffectivePrivilegeAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of EffectivePrivilegeAssignment in the Terraform plugin framework type // system. -func (a EffectivePrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a EffectivePrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, "privileges": basetypes.ListType{ - ElemType: EffectivePrivilege{}.ToAttrType(ctx), + ElemType: EffectivePrivilege{}.ToObjectType(ctx), }, }, } @@ -3615,9 +3615,9 @@ func (a EnableRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of EnableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of EnableRequest in the Terraform plugin framework type // system. -func (a EnableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -3646,9 +3646,9 @@ func (a EnableResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of EnableResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EnableResponse in the Terraform plugin framework type // system. -func (a EnableResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnableResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3679,13 +3679,13 @@ func (a EncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of EncryptionDetails in the Terraform plugin framework type +// ToObjectType returns the representation of EncryptionDetails in the Terraform plugin framework type // system. -func (a EncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a EncryptionDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sse_encryption_details": basetypes.ListType{ - ElemType: SseEncryptionDetails{}.ToAttrType(ctx), + ElemType: SseEncryptionDetails{}.ToObjectType(ctx), }, }, } @@ -3714,9 +3714,9 @@ func (a ExistsRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExistsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExistsRequest in the Terraform plugin framework type // system. -func (a ExistsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExistsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -3785,9 +3785,9 @@ func (a ExternalLocationInfo) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ExternalLocationInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ExternalLocationInfo in the Terraform plugin framework type // system. -func (a ExternalLocationInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExternalLocationInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, @@ -3798,7 +3798,7 @@ func (a ExternalLocationInfo) ToAttrType(ctx context.Context) types.ObjectType { "credential_id": types.StringType, "credential_name": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToAttrType(ctx), + ElemType: EncryptionDetails{}.ToObjectType(ctx), }, "fallback": types.BoolType, "isolation_mode": types.StringType, @@ -3844,9 +3844,9 @@ func (a FailedStatus) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of FailedStatus in the Terraform plugin framework type +// ToObjectType returns the representation of FailedStatus in the Terraform plugin framework type // system. -func (a FailedStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a FailedStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_processed_commit_version": types.Int64Type, @@ -3886,9 +3886,9 @@ func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ForeignKeyConstraint in the Terraform plugin framework type +// ToObjectType returns the representation of ForeignKeyConstraint in the Terraform plugin framework type // system. -func (a ForeignKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { +func (a ForeignKeyConstraint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "child_columns": basetypes.ListType{ @@ -3927,9 +3927,9 @@ func (a FunctionDependency) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of FunctionDependency in the Terraform plugin framework type +// ToObjectType returns the representation of FunctionDependency in the Terraform plugin framework type // system. -func (a FunctionDependency) ToAttrType(ctx context.Context) types.ObjectType { +func (a FunctionDependency) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_full_name": types.StringType, @@ -4028,9 +4028,9 @@ func (a FunctionInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of FunctionInfo in the Terraform plugin framework type +// ToObjectType returns the representation of FunctionInfo in the Terraform plugin framework type // system. -func (a FunctionInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a FunctionInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "browse_only": types.BoolType, @@ -4045,7 +4045,7 @@ func (a FunctionInfo) ToAttrType(ctx context.Context) types.ObjectType { "full_name": types.StringType, "function_id": types.StringType, "input_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + ElemType: FunctionParameterInfos{}.ToObjectType(ctx), }, "is_deterministic": types.BoolType, "is_null_call": types.BoolType, @@ -4055,12 +4055,12 @@ func (a FunctionInfo) ToAttrType(ctx context.Context) types.ObjectType { "parameter_style": types.StringType, "properties": types.StringType, "return_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToAttrType(ctx), + ElemType: FunctionParameterInfos{}.ToObjectType(ctx), }, "routine_body": types.StringType, "routine_definition": types.StringType, "routine_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToAttrType(ctx), + ElemType: DependencyList{}.ToObjectType(ctx), }, "schema_name": types.StringType, "security_type": types.StringType, @@ -4117,9 +4117,9 @@ func (a FunctionParameterInfo) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of FunctionParameterInfo in the Terraform plugin framework type +// ToObjectType returns the representation of FunctionParameterInfo in the Terraform plugin framework type // system. -func (a FunctionParameterInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a FunctionParameterInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4163,13 +4163,13 @@ func (a FunctionParameterInfos) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of FunctionParameterInfos in the Terraform plugin framework type +// ToObjectType returns the representation of FunctionParameterInfos in the Terraform plugin framework type // system. -func (a FunctionParameterInfos) ToAttrType(ctx context.Context) types.ObjectType { +func (a FunctionParameterInfos) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ - ElemType: FunctionParameterInfo{}.ToAttrType(ctx), + ElemType: FunctionParameterInfo{}.ToObjectType(ctx), }, }, } @@ -4198,9 +4198,9 @@ func (a GcpOauthToken) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpOauthToken in the Terraform plugin framework type +// ToObjectType returns the representation of GcpOauthToken in the Terraform plugin framework type // system. -func (a GcpOauthToken) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpOauthToken) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "oauth_token": types.StringType, @@ -4235,9 +4235,9 @@ func (a GcpServiceAccountKey) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpServiceAccountKey in the Terraform plugin framework type +// ToObjectType returns the representation of GcpServiceAccountKey in the Terraform plugin framework type // system. -func (a GcpServiceAccountKey) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpServiceAccountKey) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email": types.StringType, @@ -4274,9 +4274,9 @@ func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes(ctx } } -// ToAttrType returns the representation of GenerateTemporaryServiceCredentialAzureOptions in the Terraform plugin framework type +// ToObjectType returns the representation of GenerateTemporaryServiceCredentialAzureOptions in the Terraform plugin framework type // system. -func (a GenerateTemporaryServiceCredentialAzureOptions) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenerateTemporaryServiceCredentialAzureOptions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resources": basetypes.ListType{ @@ -4313,13 +4313,13 @@ func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes(ctx cont } } -// ToAttrType returns the representation of GenerateTemporaryServiceCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenerateTemporaryServiceCredentialRequest in the Terraform plugin framework type // system. -func (a GenerateTemporaryServiceCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenerateTemporaryServiceCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "azure_options": basetypes.ListType{ - ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.ToAttrType(ctx), + ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.ToObjectType(ctx), }, "credential_name": types.StringType, }, @@ -4352,9 +4352,9 @@ func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenerateTemporaryTableCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenerateTemporaryTableCredentialRequest in the Terraform plugin framework type // system. -func (a GenerateTemporaryTableCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenerateTemporaryTableCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operation": types.StringType, @@ -4410,26 +4410,26 @@ func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes(ctx conte } } -// ToAttrType returns the representation of GenerateTemporaryTableCredentialResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GenerateTemporaryTableCredentialResponse in the Terraform plugin framework type // system. -func (a GenerateTemporaryTableCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenerateTemporaryTableCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_temp_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.ToAttrType(ctx), + ElemType: AwsCredentials{}.ToObjectType(ctx), }, "azure_aad": basetypes.ListType{ - ElemType: AzureActiveDirectoryToken{}.ToAttrType(ctx), + ElemType: AzureActiveDirectoryToken{}.ToObjectType(ctx), }, "azure_user_delegation_sas": basetypes.ListType{ - ElemType: AzureUserDelegationSas{}.ToAttrType(ctx), + ElemType: AzureUserDelegationSas{}.ToObjectType(ctx), }, "expiration_time": types.Int64Type, "gcp_oauth_token": basetypes.ListType{ - ElemType: GcpOauthToken{}.ToAttrType(ctx), + ElemType: GcpOauthToken{}.ToObjectType(ctx), }, "r2_temp_credentials": basetypes.ListType{ - ElemType: R2Credentials{}.ToAttrType(ctx), + ElemType: R2Credentials{}.ToObjectType(ctx), }, "url": types.StringType, }, @@ -4459,9 +4459,9 @@ func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountMetastoreAssignmentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountMetastoreAssignmentRequest in the Terraform plugin framework type // system. -func (a GetAccountMetastoreAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountMetastoreAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -4492,9 +4492,9 @@ func (a GetAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountMetastoreRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountMetastoreRequest in the Terraform plugin framework type // system. -func (a GetAccountMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -4527,9 +4527,9 @@ func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountStorageCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountStorageCredentialRequest in the Terraform plugin framework type // system. -func (a GetAccountStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -4561,9 +4561,9 @@ func (a GetArtifactAllowlistRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetArtifactAllowlistRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetArtifactAllowlistRequest in the Terraform plugin framework type // system. -func (a GetArtifactAllowlistRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetArtifactAllowlistRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_type": types.StringType, @@ -4605,9 +4605,9 @@ func (a GetBindingsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetBindingsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetBindingsRequest in the Terraform plugin framework type // system. -func (a GetBindingsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetBindingsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -4646,9 +4646,9 @@ func (a GetByAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetByAliasRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetByAliasRequest in the Terraform plugin framework type // system. -func (a GetByAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetByAliasRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias": types.StringType, @@ -4684,9 +4684,9 @@ func (a GetCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCatalogRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetCatalogRequest in the Terraform plugin framework type // system. -func (a GetCatalogRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCatalogRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -4718,9 +4718,9 @@ func (a GetConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetConnectionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetConnectionRequest in the Terraform plugin framework type // system. -func (a GetConnectionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetConnectionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -4751,9 +4751,9 @@ func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetCredentialRequest in the Terraform plugin framework type // system. -func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name_arg": types.StringType, @@ -4789,9 +4789,9 @@ func (a GetEffectiveRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetEffectiveRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetEffectiveRequest in the Terraform plugin framework type // system. -func (a GetEffectiveRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEffectiveRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -4827,9 +4827,9 @@ func (a GetExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetExternalLocationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetExternalLocationRequest in the Terraform plugin framework type // system. -func (a GetExternalLocationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExternalLocationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -4865,9 +4865,9 @@ func (a GetFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetFunctionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetFunctionRequest in the Terraform plugin framework type // system. -func (a GetFunctionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetFunctionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -4904,9 +4904,9 @@ func (a GetGrantRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetGrantRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetGrantRequest in the Terraform plugin framework type // system. -func (a GetGrantRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetGrantRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -4939,9 +4939,9 @@ func (a GetMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetMetastoreRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetMetastoreRequest in the Terraform plugin framework type // system. -func (a GetMetastoreRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -5011,9 +5011,9 @@ func (a GetMetastoreSummaryResponse) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetMetastoreSummaryResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetMetastoreSummaryResponse in the Terraform plugin framework type // system. -func (a GetMetastoreSummaryResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetMetastoreSummaryResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cloud": types.StringType, @@ -5070,9 +5070,9 @@ func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelVersionRequest in the Terraform plugin framework type // system. -func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5106,9 +5106,9 @@ func (a GetOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetOnlineTableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetOnlineTableRequest in the Terraform plugin framework type // system. -func (a GetOnlineTableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetOnlineTableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5139,9 +5139,9 @@ func (a GetQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetQualityMonitorRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetQualityMonitorRequest in the Terraform plugin framework type // system. -func (a GetQualityMonitorRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetQualityMonitorRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -5178,9 +5178,9 @@ func (a GetQuotaRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetQuotaRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetQuotaRequest in the Terraform plugin framework type // system. -func (a GetQuotaRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetQuotaRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parent_full_name": types.StringType, @@ -5214,13 +5214,13 @@ func (a GetQuotaResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of GetQuotaResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetQuotaResponse in the Terraform plugin framework type // system. -func (a GetQuotaResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetQuotaResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "quota_info": basetypes.ListType{ - ElemType: QuotaInfo{}.ToAttrType(ctx), + ElemType: QuotaInfo{}.ToObjectType(ctx), }, }, } @@ -5251,9 +5251,9 @@ func (a GetRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRefreshRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRefreshRequest in the Terraform plugin framework type // system. -func (a GetRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRefreshRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "refresh_id": types.StringType, @@ -5290,9 +5290,9 @@ func (a GetRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRegisteredModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRegisteredModelRequest in the Terraform plugin framework type // system. -func (a GetRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5328,9 +5328,9 @@ func (a GetSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetSchemaRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetSchemaRequest in the Terraform plugin framework type // system. -func (a GetSchemaRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetSchemaRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5362,9 +5362,9 @@ func (a GetStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStorageCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStorageCredentialRequest in the Terraform plugin framework type // system. -func (a GetStorageCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5402,9 +5402,9 @@ func (a GetTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetTableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetTableRequest in the Terraform plugin framework type // system. -func (a GetTableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetTableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5438,9 +5438,9 @@ func (a GetWorkspaceBindingRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWorkspaceBindingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceBindingRequest in the Terraform plugin framework type // system. -func (a GetWorkspaceBindingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceBindingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5471,9 +5471,9 @@ func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAccountMetastoreAssignmentsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountMetastoreAssignmentsRequest in the Terraform plugin framework type // system. -func (a ListAccountMetastoreAssignmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountMetastoreAssignmentsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -5505,9 +5505,9 @@ func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes(ctx contex } } -// ToAttrType returns the representation of ListAccountMetastoreAssignmentsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountMetastoreAssignmentsResponse in the Terraform plugin framework type // system. -func (a ListAccountMetastoreAssignmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountMetastoreAssignmentsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_ids": basetypes.ListType{ @@ -5540,9 +5540,9 @@ func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAccountStorageCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountStorageCredentialsRequest in the Terraform plugin framework type // system. -func (a ListAccountStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountStorageCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -5574,13 +5574,13 @@ func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes(ctx context. } } -// ToAttrType returns the representation of ListAccountStorageCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountStorageCredentialsResponse in the Terraform plugin framework type // system. -func (a ListAccountStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountStorageCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "storage_credentials": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.ToAttrType(ctx), + ElemType: StorageCredentialInfo{}.ToObjectType(ctx), }, }, } @@ -5622,9 +5622,9 @@ func (a ListCatalogsRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListCatalogsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListCatalogsRequest in the Terraform plugin framework type // system. -func (a ListCatalogsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListCatalogsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -5662,13 +5662,13 @@ func (a ListCatalogsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListCatalogsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListCatalogsResponse in the Terraform plugin framework type // system. -func (a ListCatalogsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListCatalogsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalogs": basetypes.ListType{ - ElemType: CatalogInfo{}.ToAttrType(ctx), + ElemType: CatalogInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -5705,9 +5705,9 @@ func (a ListConnectionsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListConnectionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListConnectionsRequest in the Terraform plugin framework type // system. -func (a ListConnectionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListConnectionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -5744,13 +5744,13 @@ func (a ListConnectionsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ListConnectionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListConnectionsResponse in the Terraform plugin framework type // system. -func (a ListConnectionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListConnectionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connections": basetypes.ListType{ - ElemType: ConnectionInfo{}.ToAttrType(ctx), + ElemType: ConnectionInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -5788,9 +5788,9 @@ func (a ListCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListCredentialsRequest in the Terraform plugin framework type // system. -func (a ListCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -5827,13 +5827,13 @@ func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ListCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListCredentialsResponse in the Terraform plugin framework type // system. -func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials": basetypes.ListType{ - ElemType: CredentialInfo{}.ToAttrType(ctx), + ElemType: CredentialInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -5873,9 +5873,9 @@ func (a ListExternalLocationsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListExternalLocationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListExternalLocationsRequest in the Terraform plugin framework type // system. -func (a ListExternalLocationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExternalLocationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -5913,13 +5913,13 @@ func (a ListExternalLocationsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListExternalLocationsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListExternalLocationsResponse in the Terraform plugin framework type // system. -func (a ListExternalLocationsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExternalLocationsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_locations": basetypes.ListType{ - ElemType: ExternalLocationInfo{}.ToAttrType(ctx), + ElemType: ExternalLocationInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -5963,9 +5963,9 @@ func (a ListFunctionsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListFunctionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListFunctionsRequest in the Terraform plugin framework type // system. -func (a ListFunctionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListFunctionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6005,13 +6005,13 @@ func (a ListFunctionsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListFunctionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListFunctionsResponse in the Terraform plugin framework type // system. -func (a ListFunctionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListFunctionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "functions": basetypes.ListType{ - ElemType: FunctionInfo{}.ToAttrType(ctx), + ElemType: FunctionInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -6042,13 +6042,13 @@ func (a ListMetastoresResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ListMetastoresResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListMetastoresResponse in the Terraform plugin framework type // system. -func (a ListMetastoresResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListMetastoresResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastores": basetypes.ListType{ - ElemType: MetastoreInfo{}.ToAttrType(ctx), + ElemType: MetastoreInfo{}.ToObjectType(ctx), }, }, } @@ -6091,9 +6091,9 @@ func (a ListModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListModelVersionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListModelVersionsRequest in the Terraform plugin framework type // system. -func (a ListModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListModelVersionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -6131,13 +6131,13 @@ func (a ListModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ListModelVersionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListModelVersionsResponse in the Terraform plugin framework type // system. -func (a ListModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListModelVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_versions": basetypes.ListType{ - ElemType: ModelVersionInfo{}.ToAttrType(ctx), + ElemType: ModelVersionInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -6169,9 +6169,9 @@ func (a ListQuotasRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListQuotasRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListQuotasRequest in the Terraform plugin framework type // system. -func (a ListQuotasRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQuotasRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -6208,14 +6208,14 @@ func (a ListQuotasResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListQuotasResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListQuotasResponse in the Terraform plugin framework type // system. -func (a ListQuotasResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQuotasResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "quotas": basetypes.ListType{ - ElemType: QuotaInfo{}.ToAttrType(ctx), + ElemType: QuotaInfo{}.ToObjectType(ctx), }, }, } @@ -6244,9 +6244,9 @@ func (a ListRefreshesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListRefreshesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListRefreshesRequest in the Terraform plugin framework type // system. -func (a ListRefreshesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRefreshesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -6304,9 +6304,9 @@ func (a ListRegisteredModelsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListRegisteredModelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListRegisteredModelsRequest in the Terraform plugin framework type // system. -func (a ListRegisteredModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRegisteredModelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6345,14 +6345,14 @@ func (a ListRegisteredModelsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListRegisteredModelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListRegisteredModelsResponse in the Terraform plugin framework type // system. -func (a ListRegisteredModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRegisteredModelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "registered_models": basetypes.ListType{ - ElemType: RegisteredModelInfo{}.ToAttrType(ctx), + ElemType: RegisteredModelInfo{}.ToObjectType(ctx), }, }, } @@ -6393,9 +6393,9 @@ func (a ListSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSchemasRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSchemasRequest in the Terraform plugin framework type // system. -func (a ListSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSchemasRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6434,14 +6434,14 @@ func (a ListSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListSchemasResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListSchemasResponse in the Terraform plugin framework type // system. -func (a ListSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSchemasResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "schemas": basetypes.ListType{ - ElemType: SchemaInfo{}.ToAttrType(ctx), + ElemType: SchemaInfo{}.ToObjectType(ctx), }, }, } @@ -6477,9 +6477,9 @@ func (a ListStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListStorageCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListStorageCredentialsRequest in the Terraform plugin framework type // system. -func (a ListStorageCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListStorageCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -6516,14 +6516,14 @@ func (a ListStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of ListStorageCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListStorageCredentialsResponse in the Terraform plugin framework type // system. -func (a ListStorageCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListStorageCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "storage_credentials": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.ToAttrType(ctx), + ElemType: StorageCredentialInfo{}.ToObjectType(ctx), }, }, } @@ -6570,9 +6570,9 @@ func (a ListSummariesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSummariesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSummariesRequest in the Terraform plugin framework type // system. -func (a ListSummariesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSummariesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6617,9 +6617,9 @@ func (a ListSystemSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSystemSchemasRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSystemSchemasRequest in the Terraform plugin framework type // system. -func (a ListSystemSchemasRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSystemSchemasRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -6657,14 +6657,14 @@ func (a ListSystemSchemasResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ListSystemSchemasResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListSystemSchemasResponse in the Terraform plugin framework type // system. -func (a ListSystemSchemasResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSystemSchemasResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "schemas": basetypes.ListType{ - ElemType: SystemSchemaInfo{}.ToAttrType(ctx), + ElemType: SystemSchemaInfo{}.ToObjectType(ctx), }, }, } @@ -6698,14 +6698,14 @@ func (a ListTableSummariesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListTableSummariesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListTableSummariesResponse in the Terraform plugin framework type // system. -func (a ListTableSummariesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTableSummariesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "tables": basetypes.ListType{ - ElemType: TableSummary{}.ToAttrType(ctx), + ElemType: TableSummary{}.ToObjectType(ctx), }, }, } @@ -6759,9 +6759,9 @@ func (a ListTablesRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListTablesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListTablesRequest in the Terraform plugin framework type // system. -func (a ListTablesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTablesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6806,14 +6806,14 @@ func (a ListTablesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListTablesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListTablesResponse in the Terraform plugin framework type // system. -func (a ListTablesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTablesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "tables": basetypes.ListType{ - ElemType: TableInfo{}.ToAttrType(ctx), + ElemType: TableInfo{}.ToObjectType(ctx), }, }, } @@ -6863,9 +6863,9 @@ func (a ListVolumesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListVolumesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListVolumesRequest in the Terraform plugin framework type // system. -func (a ListVolumesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListVolumesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6905,14 +6905,14 @@ func (a ListVolumesResponseContent) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListVolumesResponseContent in the Terraform plugin framework type +// ToObjectType returns the representation of ListVolumesResponseContent in the Terraform plugin framework type // system. -func (a ListVolumesResponseContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListVolumesResponseContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "volumes": basetypes.ListType{ - ElemType: VolumeInfo{}.ToAttrType(ctx), + ElemType: VolumeInfo{}.ToObjectType(ctx), }, }, } @@ -6944,9 +6944,9 @@ func (a MetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of MetastoreAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of MetastoreAssignment in the Terraform plugin framework type // system. -func (a MetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a MetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_catalog_name": types.StringType, @@ -7018,9 +7018,9 @@ func (a MetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of MetastoreInfo in the Terraform plugin framework type +// ToObjectType returns the representation of MetastoreInfo in the Terraform plugin framework type // system. -func (a MetastoreInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a MetastoreInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cloud": types.StringType, @@ -7119,13 +7119,13 @@ func (a ModelVersionInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ModelVersionInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ModelVersionInfo in the Terraform plugin framework type // system. -func (a ModelVersionInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelVersionInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aliases": basetypes.ListType{ - ElemType: RegisteredModelAlias{}.ToAttrType(ctx), + ElemType: RegisteredModelAlias{}.ToObjectType(ctx), }, "browse_only": types.BoolType, "catalog_name": types.StringType, @@ -7136,7 +7136,7 @@ func (a ModelVersionInfo) ToAttrType(ctx context.Context) types.ObjectType { "metastore_id": types.StringType, "model_name": types.StringType, "model_version_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToAttrType(ctx), + ElemType: DependencyList{}.ToObjectType(ctx), }, "run_id": types.StringType, "run_workspace_id": types.Int64Type, @@ -7180,9 +7180,9 @@ func (a MonitorCronSchedule) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of MonitorCronSchedule in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorCronSchedule in the Terraform plugin framework type // system. -func (a MonitorCronSchedule) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorCronSchedule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pause_status": types.StringType, @@ -7214,9 +7214,9 @@ func (a MonitorDataClassificationConfig) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of MonitorDataClassificationConfig in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorDataClassificationConfig in the Terraform plugin framework type // system. -func (a MonitorDataClassificationConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorDataClassificationConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -7249,9 +7249,9 @@ func (a MonitorDestination) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of MonitorDestination in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorDestination in the Terraform plugin framework type // system. -func (a MonitorDestination) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorDestination) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email_addresses": basetypes.ListType{ @@ -7311,9 +7311,9 @@ func (a MonitorInferenceLog) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of MonitorInferenceLog in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorInferenceLog in the Terraform plugin framework type // system. -func (a MonitorInferenceLog) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorInferenceLog) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "granularities": basetypes.ListType{ @@ -7371,7 +7371,7 @@ type MonitorInfo struct { // slices. SlicingExprs types.List `tfsdk:"slicing_exprs" tf:"optional"` // Configuration for monitoring snapshot tables. - Snapshot []MonitorSnapshot `tfsdk:"snapshot" tf:"optional,object"` + Snapshot types.List `tfsdk:"snapshot" tf:"optional,object"` // The status of the monitor. Status types.String `tfsdk:"status" tf:""` // The full name of the table to monitor. Format: @@ -7407,44 +7407,44 @@ func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of MonitorInfo in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorInfo in the Terraform plugin framework type // system. -func (a MonitorInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.ToAttrType(ctx), + ElemType: MonitorMetric{}.ToObjectType(ctx), }, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.ToAttrType(ctx), + ElemType: MonitorDataClassificationConfig{}.ToObjectType(ctx), }, "drift_metrics_table_name": types.StringType, "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.ToAttrType(ctx), + ElemType: MonitorInferenceLog{}.ToObjectType(ctx), }, "latest_monitor_failure_msg": types.StringType, "monitor_version": types.StringType, "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.ToAttrType(ctx), + ElemType: MonitorNotifications{}.ToObjectType(ctx), }, "output_schema_name": types.StringType, "profile_metrics_table_name": types.StringType, "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.ToAttrType(ctx), + ElemType: MonitorCronSchedule{}.ToObjectType(ctx), }, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.ToAttrType(ctx), + ElemType: MonitorSnapshot{}.ToObjectType(ctx), }, "status": types.StringType, "table_name": types.StringType, "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.ToAttrType(ctx), + ElemType: MonitorTimeSeries{}.ToObjectType(ctx), }, }, } @@ -7496,9 +7496,9 @@ func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of MonitorMetric in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorMetric in the Terraform plugin framework type // system. -func (a MonitorMetric) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorMetric) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, @@ -7540,16 +7540,16 @@ func (a MonitorNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of MonitorNotifications in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorNotifications in the Terraform plugin framework type // system. -func (a MonitorNotifications) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorNotifications) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "on_failure": basetypes.ListType{ - ElemType: MonitorDestination{}.ToAttrType(ctx), + ElemType: MonitorDestination{}.ToObjectType(ctx), }, "on_new_classification_tag_detected": basetypes.ListType{ - ElemType: MonitorDestination{}.ToAttrType(ctx), + ElemType: MonitorDestination{}.ToObjectType(ctx), }, }, } @@ -7590,9 +7590,9 @@ func (a MonitorRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of MonitorRefreshInfo in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorRefreshInfo in the Terraform plugin framework type // system. -func (a MonitorRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorRefreshInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time_ms": types.Int64Type, @@ -7629,13 +7629,13 @@ func (a MonitorRefreshListResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of MonitorRefreshListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorRefreshListResponse in the Terraform plugin framework type // system. -func (a MonitorRefreshListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorRefreshListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "refreshes": basetypes.ListType{ - ElemType: MonitorRefreshInfo{}.ToAttrType(ctx), + ElemType: MonitorRefreshInfo{}.ToObjectType(ctx), }, }, } @@ -7661,9 +7661,9 @@ func (a MonitorSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of MonitorSnapshot in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorSnapshot in the Terraform plugin framework type // system. -func (a MonitorSnapshot) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorSnapshot) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7703,9 +7703,9 @@ func (a MonitorTimeSeries) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of MonitorTimeSeries in the Terraform plugin framework type +// ToObjectType returns the representation of MonitorTimeSeries in the Terraform plugin framework type // system. -func (a MonitorTimeSeries) ToAttrType(ctx context.Context) types.ObjectType { +func (a MonitorTimeSeries) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "granularities": basetypes.ListType{ @@ -7738,9 +7738,9 @@ func (a NamedTableConstraint) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of NamedTableConstraint in the Terraform plugin framework type +// ToObjectType returns the representation of NamedTableConstraint in the Terraform plugin framework type // system. -func (a NamedTableConstraint) ToAttrType(ctx context.Context) types.ObjectType { +func (a NamedTableConstraint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -7785,17 +7785,17 @@ func (a OnlineTable) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of OnlineTable in the Terraform plugin framework type +// ToObjectType returns the representation of OnlineTable in the Terraform plugin framework type // system. -func (a OnlineTable) ToAttrType(ctx context.Context) types.ObjectType { +func (a OnlineTable) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "spec": basetypes.ListType{ - ElemType: OnlineTableSpec{}.ToAttrType(ctx), + ElemType: OnlineTableSpec{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: OnlineTableStatus{}.ToAttrType(ctx), + ElemType: OnlineTableStatus{}.ToObjectType(ctx), }, "table_serving_url": types.StringType, "unity_catalog_provisioning_state": types.StringType, @@ -7819,10 +7819,10 @@ type OnlineTableSpec struct { // Primary Key columns to be used for data insert/update in the destination. PrimaryKeyColumns types.List `tfsdk:"primary_key_columns" tf:"optional"` // Pipeline runs continuously after generating the initial data. - RunContinuously []OnlineTableSpecContinuousSchedulingPolicy `tfsdk:"run_continuously" tf:"optional,object"` + RunContinuously types.List `tfsdk:"run_continuously" tf:"optional,object"` // Pipeline stops after generating the initial data and can be triggered // later (manually, through a cron job or through data triggers) - RunTriggered []OnlineTableSpecTriggeredSchedulingPolicy `tfsdk:"run_triggered" tf:"optional,object"` + RunTriggered types.List `tfsdk:"run_triggered" tf:"optional,object"` // Three-part (catalog, schema, table) name of the source Delta table. SourceTableFullName types.String `tfsdk:"source_table_full_name" tf:"optional"` // Time series key to deduplicate (tie-break) rows with the same primary @@ -7851,9 +7851,9 @@ func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of OnlineTableSpec in the Terraform plugin framework type +// ToObjectType returns the representation of OnlineTableSpec in the Terraform plugin framework type // system. -func (a OnlineTableSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a OnlineTableSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "perform_full_copy": types.BoolType, @@ -7862,10 +7862,10 @@ func (a OnlineTableSpec) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "run_continuously": basetypes.ListType{ - ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.ToAttrType(ctx), + ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.ToObjectType(ctx), }, "run_triggered": basetypes.ListType{ - ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.ToAttrType(ctx), + ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.ToObjectType(ctx), }, "source_table_full_name": types.StringType, "timeseries_key": types.StringType, @@ -7893,9 +7893,9 @@ func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of OnlineTableSpecContinuousSchedulingPolicy in the Terraform plugin framework type +// ToObjectType returns the representation of OnlineTableSpecContinuousSchedulingPolicy in the Terraform plugin framework type // system. -func (a OnlineTableSpecContinuousSchedulingPolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a OnlineTableSpecContinuousSchedulingPolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7921,9 +7921,9 @@ func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of OnlineTableSpecTriggeredSchedulingPolicy in the Terraform plugin framework type +// ToObjectType returns the representation of OnlineTableSpecTriggeredSchedulingPolicy in the Terraform plugin framework type // system. -func (a OnlineTableSpecTriggeredSchedulingPolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a OnlineTableSpecTriggeredSchedulingPolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7972,24 +7972,24 @@ func (a OnlineTableStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of OnlineTableStatus in the Terraform plugin framework type +// ToObjectType returns the representation of OnlineTableStatus in the Terraform plugin framework type // system. -func (a OnlineTableStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a OnlineTableStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "continuous_update_status": basetypes.ListType{ - ElemType: ContinuousUpdateStatus{}.ToAttrType(ctx), + ElemType: ContinuousUpdateStatus{}.ToObjectType(ctx), }, "detailed_state": types.StringType, "failed_status": basetypes.ListType{ - ElemType: FailedStatus{}.ToAttrType(ctx), + ElemType: FailedStatus{}.ToObjectType(ctx), }, "message": types.StringType, "provisioning_status": basetypes.ListType{ - ElemType: ProvisioningStatus{}.ToAttrType(ctx), + ElemType: ProvisioningStatus{}.ToObjectType(ctx), }, "triggered_update_status": basetypes.ListType{ - ElemType: TriggeredUpdateStatus{}.ToAttrType(ctx), + ElemType: TriggeredUpdateStatus{}.ToObjectType(ctx), }, }, } @@ -8024,9 +8024,9 @@ func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of PermissionsChange in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionsChange in the Terraform plugin framework type // system. -func (a PermissionsChange) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionsChange) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "add": basetypes.ListType{ @@ -8064,13 +8064,13 @@ func (a PermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of PermissionsList in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionsList in the Terraform plugin framework type // system. -func (a PermissionsList) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionsList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "privilege_assignments": basetypes.ListType{ - ElemType: PrivilegeAssignment{}.ToAttrType(ctx), + ElemType: PrivilegeAssignment{}.ToObjectType(ctx), }, }, } @@ -8109,9 +8109,9 @@ func (a PipelineProgress) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelineProgress in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineProgress in the Terraform plugin framework type // system. -func (a PipelineProgress) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineProgress) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "estimated_completion_time_seconds": types.Float64Type, @@ -8149,9 +8149,9 @@ func (a PrimaryKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of PrimaryKeyConstraint in the Terraform plugin framework type +// ToObjectType returns the representation of PrimaryKeyConstraint in the Terraform plugin framework type // system. -func (a PrimaryKeyConstraint) ToAttrType(ctx context.Context) types.ObjectType { +func (a PrimaryKeyConstraint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "child_columns": basetypes.ListType{ @@ -8188,9 +8188,9 @@ func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of PrivilegeAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of PrivilegeAssignment in the Terraform plugin framework type // system. -func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a PrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -8223,9 +8223,9 @@ func (a ProvisioningInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of ProvisioningInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ProvisioningInfo in the Terraform plugin framework type // system. -func (a ProvisioningInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ProvisioningInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "state": types.StringType, @@ -8260,13 +8260,13 @@ func (a ProvisioningStatus) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ProvisioningStatus in the Terraform plugin framework type +// ToObjectType returns the representation of ProvisioningStatus in the Terraform plugin framework type // system. -func (a ProvisioningStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a ProvisioningStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "initial_pipeline_sync_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.ToAttrType(ctx), + ElemType: PipelineProgress{}.ToObjectType(ctx), }, }, } @@ -8305,9 +8305,9 @@ func (a QuotaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of QuotaInfo in the Terraform plugin framework type +// ToObjectType returns the representation of QuotaInfo in the Terraform plugin framework type // system. -func (a QuotaInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a QuotaInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_refreshed_at": types.Int64Type, @@ -8348,9 +8348,9 @@ func (a R2Credentials) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of R2Credentials in the Terraform plugin framework type +// ToObjectType returns the representation of R2Credentials in the Terraform plugin framework type // system. -func (a R2Credentials) ToAttrType(ctx context.Context) types.ObjectType { +func (a R2Credentials) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_key_id": types.StringType, @@ -8386,9 +8386,9 @@ func (a ReadVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ReadVolumeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ReadVolumeRequest in the Terraform plugin framework type // system. -func (a ReadVolumeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReadVolumeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -8422,9 +8422,9 @@ func (a RegenerateDashboardRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of RegenerateDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RegenerateDashboardRequest in the Terraform plugin framework type // system. -func (a RegenerateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegenerateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -8457,9 +8457,9 @@ func (a RegenerateDashboardResponse) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of RegenerateDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RegenerateDashboardResponse in the Terraform plugin framework type // system. -func (a RegenerateDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegenerateDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -8493,9 +8493,9 @@ func (a RegisteredModelAlias) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of RegisteredModelAlias in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelAlias in the Terraform plugin framework type // system. -func (a RegisteredModelAlias) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelAlias) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias_name": types.StringType, @@ -8559,13 +8559,13 @@ func (a RegisteredModelInfo) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of RegisteredModelInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelInfo in the Terraform plugin framework type // system. -func (a RegisteredModelInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aliases": basetypes.ListType{ - ElemType: RegisteredModelAlias{}.ToAttrType(ctx), + ElemType: RegisteredModelAlias{}.ToObjectType(ctx), }, "browse_only": types.BoolType, "catalog_name": types.StringType, @@ -8607,9 +8607,9 @@ func (a RunRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunRefreshRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RunRefreshRequest in the Terraform plugin framework type // system. -func (a RunRefreshRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunRefreshRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -8679,9 +8679,9 @@ func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of SchemaInfo in the Terraform plugin framework type +// ToObjectType returns the representation of SchemaInfo in the Terraform plugin framework type // system. -func (a SchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a SchemaInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "browse_only": types.BoolType, @@ -8691,7 +8691,7 @@ func (a SchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { "created_at": types.Int64Type, "created_by": types.StringType, "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + ElemType: EffectivePredictiveOptimizationFlag{}.ToObjectType(ctx), }, "enable_predictive_optimization": types.StringType, "full_name": types.StringType, @@ -8736,13 +8736,13 @@ func (a SetArtifactAllowlist) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of SetArtifactAllowlist in the Terraform plugin framework type +// ToObjectType returns the representation of SetArtifactAllowlist in the Terraform plugin framework type // system. -func (a SetArtifactAllowlist) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetArtifactAllowlist) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_matchers": basetypes.ListType{ - ElemType: ArtifactMatcher{}.ToAttrType(ctx), + ElemType: ArtifactMatcher{}.ToObjectType(ctx), }, "artifact_type": types.StringType, }, @@ -8775,9 +8775,9 @@ func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetRegisteredModelAliasRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SetRegisteredModelAliasRequest in the Terraform plugin framework type // system. -func (a SetRegisteredModelAliasRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetRegisteredModelAliasRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias": types.StringType, @@ -8813,9 +8813,9 @@ func (a SseEncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of SseEncryptionDetails in the Terraform plugin framework type +// ToObjectType returns the representation of SseEncryptionDetails in the Terraform plugin framework type // system. -func (a SseEncryptionDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a SseEncryptionDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "algorithm": types.StringType, @@ -8887,28 +8887,28 @@ func (a StorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of StorageCredentialInfo in the Terraform plugin framework type +// ToObjectType returns the representation of StorageCredentialInfo in the Terraform plugin framework type // system. -func (a StorageCredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a StorageCredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleResponse{}.ToAttrType(ctx), + ElemType: AwsIamRoleResponse{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityResponse{}.ToAttrType(ctx), + ElemType: AzureManagedIdentityResponse{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToAttrType(ctx), + ElemType: CloudflareApiToken{}.ToObjectType(ctx), }, "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountResponse{}.ToAttrType(ctx), + ElemType: DatabricksGcpServiceAccountResponse{}.ToObjectType(ctx), }, "full_name": types.StringType, "id": types.StringType, @@ -8949,9 +8949,9 @@ func (a SystemSchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of SystemSchemaInfo in the Terraform plugin framework type +// ToObjectType returns the representation of SystemSchemaInfo in the Terraform plugin framework type // system. -func (a SystemSchemaInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a SystemSchemaInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "schema": types.StringType, @@ -8992,19 +8992,19 @@ func (a TableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of TableConstraint in the Terraform plugin framework type +// ToObjectType returns the representation of TableConstraint in the Terraform plugin framework type // system. -func (a TableConstraint) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableConstraint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "foreign_key_constraint": basetypes.ListType{ - ElemType: ForeignKeyConstraint{}.ToAttrType(ctx), + ElemType: ForeignKeyConstraint{}.ToObjectType(ctx), }, "named_table_constraint": basetypes.ListType{ - ElemType: NamedTableConstraint{}.ToAttrType(ctx), + ElemType: NamedTableConstraint{}.ToObjectType(ctx), }, "primary_key_constraint": basetypes.ListType{ - ElemType: PrimaryKeyConstraint{}.ToAttrType(ctx), + ElemType: PrimaryKeyConstraint{}.ToObjectType(ctx), }, }, } @@ -9034,9 +9034,9 @@ func (a TableDependency) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of TableDependency in the Terraform plugin framework type +// ToObjectType returns the representation of TableDependency in the Terraform plugin framework type // system. -func (a TableDependency) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableDependency) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_full_name": types.StringType, @@ -9066,9 +9066,9 @@ func (a TableExistsResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of TableExistsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of TableExistsResponse in the Terraform plugin framework type // system. -func (a TableExistsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableExistsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_exists": types.BoolType, @@ -9182,16 +9182,16 @@ func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of TableInfo in the Terraform plugin framework type +// ToObjectType returns the representation of TableInfo in the Terraform plugin framework type // system. -func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, "browse_only": types.BoolType, "catalog_name": types.StringType, "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.ToAttrType(ctx), + ElemType: ColumnInfo{}.ToObjectType(ctx), }, "comment": types.StringType, "created_at": types.Int64Type, @@ -9200,14 +9200,14 @@ func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { "data_source_format": types.StringType, "deleted_at": types.Int64Type, "delta_runtime_properties_kvpairs": basetypes.ListType{ - ElemType: DeltaRuntimePropertiesKvPairs{}.ToAttrType(ctx), + ElemType: DeltaRuntimePropertiesKvPairs{}.ToObjectType(ctx), }, "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.ToAttrType(ctx), + ElemType: EffectivePredictiveOptimizationFlag{}.ToObjectType(ctx), }, "enable_predictive_optimization": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToAttrType(ctx), + ElemType: EncryptionDetails{}.ToObjectType(ctx), }, "full_name": types.StringType, "metastore_id": types.StringType, @@ -9218,14 +9218,14 @@ func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "row_filter": basetypes.ListType{ - ElemType: TableRowFilter{}.ToAttrType(ctx), + ElemType: TableRowFilter{}.ToObjectType(ctx), }, "schema_name": types.StringType, "sql_path": types.StringType, "storage_credential_name": types.StringType, "storage_location": types.StringType, "table_constraints": basetypes.ListType{ - ElemType: TableConstraint{}.ToAttrType(ctx), + ElemType: TableConstraint{}.ToObjectType(ctx), }, "table_id": types.StringType, "table_type": types.StringType, @@ -9233,7 +9233,7 @@ func (a TableInfo) ToAttrType(ctx context.Context) types.ObjectType { "updated_by": types.StringType, "view_definition": types.StringType, "view_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToAttrType(ctx), + ElemType: DependencyList{}.ToObjectType(ctx), }, }, } @@ -9267,9 +9267,9 @@ func (a TableRowFilter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of TableRowFilter in the Terraform plugin framework type +// ToObjectType returns the representation of TableRowFilter in the Terraform plugin framework type // system. -func (a TableRowFilter) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableRowFilter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_name": types.StringType, @@ -9304,9 +9304,9 @@ func (a TableSummary) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of TableSummary in the Terraform plugin framework type +// ToObjectType returns the representation of TableSummary in the Terraform plugin framework type // system. -func (a TableSummary) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableSummary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -9348,16 +9348,16 @@ func (a TemporaryCredentials) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of TemporaryCredentials in the Terraform plugin framework type +// ToObjectType returns the representation of TemporaryCredentials in the Terraform plugin framework type // system. -func (a TemporaryCredentials) ToAttrType(ctx context.Context) types.ObjectType { +func (a TemporaryCredentials) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_temp_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.ToAttrType(ctx), + ElemType: AwsCredentials{}.ToObjectType(ctx), }, "azure_aad": basetypes.ListType{ - ElemType: AzureActiveDirectoryToken{}.ToAttrType(ctx), + ElemType: AzureActiveDirectoryToken{}.ToObjectType(ctx), }, "expiration_time": types.Int64Type, }, @@ -9397,15 +9397,15 @@ func (a TriggeredUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of TriggeredUpdateStatus in the Terraform plugin framework type +// ToObjectType returns the representation of TriggeredUpdateStatus in the Terraform plugin framework type // system. -func (a TriggeredUpdateStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a TriggeredUpdateStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_processed_commit_version": types.Int64Type, "timestamp": types.StringType, "triggered_update_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.ToAttrType(ctx), + ElemType: PipelineProgress{}.ToObjectType(ctx), }, }, } @@ -9436,9 +9436,9 @@ func (a UnassignRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of UnassignRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UnassignRequest in the Terraform plugin framework type // system. -func (a UnassignRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UnassignRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -9467,9 +9467,9 @@ func (a UnassignResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of UnassignResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UnassignResponse in the Terraform plugin framework type // system. -func (a UnassignResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UnassignResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -9495,9 +9495,9 @@ func (a UpdateAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateAssignmentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAssignmentResponse in the Terraform plugin framework type // system. -func (a UpdateAssignmentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAssignmentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -9541,9 +9541,9 @@ func (a UpdateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of UpdateCatalog in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCatalog in the Terraform plugin framework type // system. -func (a UpdateCatalog) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCatalog) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -9589,9 +9589,9 @@ func (a UpdateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of UpdateConnection in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateConnection in the Terraform plugin framework type // system. -func (a UpdateConnection) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateConnection) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -9655,19 +9655,19 @@ func (a UpdateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of UpdateCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCredentialRequest in the Terraform plugin framework type // system. -func (a UpdateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToAttrType(ctx), + ElemType: AwsIamRole{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + ElemType: AzureManagedIdentity{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "comment": types.StringType, "force": types.BoolType, @@ -9733,16 +9733,16 @@ func (a UpdateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of UpdateExternalLocation in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExternalLocation in the Terraform plugin framework type // system. -func (a UpdateExternalLocation) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExternalLocation) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, "comment": types.StringType, "credential_name": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToAttrType(ctx), + ElemType: EncryptionDetails{}.ToObjectType(ctx), }, "fallback": types.BoolType, "force": types.BoolType, @@ -9782,9 +9782,9 @@ func (a UpdateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateFunction in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateFunction in the Terraform plugin framework type // system. -func (a UpdateFunction) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateFunction) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -9831,9 +9831,9 @@ func (a UpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateMetastore in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateMetastore in the Terraform plugin framework type // system. -func (a UpdateMetastore) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateMetastore) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "delta_sharing_organization_name": types.StringType, @@ -9876,9 +9876,9 @@ func (a UpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateMetastoreAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateMetastoreAssignment in the Terraform plugin framework type // system. -func (a UpdateMetastoreAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_catalog_name": types.StringType, @@ -9914,9 +9914,9 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type // system. -func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -9955,7 +9955,7 @@ type UpdateMonitor struct { // slices. SlicingExprs types.List `tfsdk:"slicing_exprs" tf:"optional"` // Configuration for monitoring snapshot tables. - Snapshot []MonitorSnapshot `tfsdk:"snapshot" tf:"optional,object"` + Snapshot types.List `tfsdk:"snapshot" tf:"optional,object"` // Full name of the table. TableName types.String `tfsdk:"-"` // Configuration for monitoring time series tables. @@ -9988,38 +9988,38 @@ func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of UpdateMonitor in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateMonitor in the Terraform plugin framework type // system. -func (a UpdateMonitor) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateMonitor) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "baseline_table_name": types.StringType, "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.ToAttrType(ctx), + ElemType: MonitorMetric{}.ToObjectType(ctx), }, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.ToAttrType(ctx), + ElemType: MonitorDataClassificationConfig{}.ToObjectType(ctx), }, "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.ToAttrType(ctx), + ElemType: MonitorInferenceLog{}.ToObjectType(ctx), }, "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.ToAttrType(ctx), + ElemType: MonitorNotifications{}.ToObjectType(ctx), }, "output_schema_name": types.StringType, "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.ToAttrType(ctx), + ElemType: MonitorCronSchedule{}.ToObjectType(ctx), }, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.ToAttrType(ctx), + ElemType: MonitorSnapshot{}.ToObjectType(ctx), }, "table_name": types.StringType, "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.ToAttrType(ctx), + ElemType: MonitorTimeSeries{}.ToObjectType(ctx), }, }, } @@ -10053,13 +10053,13 @@ func (a UpdatePermissions) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of UpdatePermissions in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePermissions in the Terraform plugin framework type // system. -func (a UpdatePermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "changes": basetypes.ListType{ - ElemType: PermissionsChange{}.ToAttrType(ctx), + ElemType: PermissionsChange{}.ToObjectType(ctx), }, "full_name": types.StringType, "securable_type": types.StringType, @@ -10095,9 +10095,9 @@ func (a UpdateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateRegisteredModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRegisteredModelRequest in the Terraform plugin framework type // system. -func (a UpdateRegisteredModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -10128,9 +10128,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -10171,9 +10171,9 @@ func (a UpdateSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of UpdateSchema in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateSchema in the Terraform plugin framework type // system. -func (a UpdateSchema) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateSchema) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -10200,7 +10200,7 @@ type UpdateStorageCredential struct { // Comment associated with the credential. Comment types.String `tfsdk:"comment" tf:"optional"` // The Databricks managed GCP service account configuration. - DatabricksGcpServiceAccount []DatabricksGcpServiceAccountRequest `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` + DatabricksGcpServiceAccount types.List `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // Force update even if there are dependent external locations or external // tables. Force types.Bool `tfsdk:"force" tf:"optional"` @@ -10242,26 +10242,26 @@ func (a UpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of UpdateStorageCredential in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateStorageCredential in the Terraform plugin framework type // system. -func (a UpdateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.ToAttrType(ctx), + ElemType: AwsIamRoleRequest{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityResponse{}.ToAttrType(ctx), + ElemType: AzureManagedIdentityResponse{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToAttrType(ctx), + ElemType: CloudflareApiToken{}.ToObjectType(ctx), }, "comment": types.StringType, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + ElemType: DatabricksGcpServiceAccountRequest{}.ToObjectType(ctx), }, "force": types.BoolType, "isolation_mode": types.StringType, @@ -10299,9 +10299,9 @@ func (a UpdateTableRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateTableRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateTableRequest in the Terraform plugin framework type // system. -func (a UpdateTableRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateTableRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -10338,9 +10338,9 @@ func (a UpdateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateVolumeRequestContent in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateVolumeRequestContent in the Terraform plugin framework type // system. -func (a UpdateVolumeRequestContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateVolumeRequestContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -10380,9 +10380,9 @@ func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of UpdateWorkspaceBindings in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateWorkspaceBindings in the Terraform plugin framework type // system. -func (a UpdateWorkspaceBindings) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateWorkspaceBindings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assign_workspaces": basetypes.ListType{ @@ -10427,16 +10427,16 @@ func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of UpdateWorkspaceBindingsParameters in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateWorkspaceBindingsParameters in the Terraform plugin framework type // system. -func (a UpdateWorkspaceBindingsParameters) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateWorkspaceBindingsParameters) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "add": basetypes.ListType{ - ElemType: WorkspaceBinding{}.ToAttrType(ctx), + ElemType: WorkspaceBinding{}.ToObjectType(ctx), }, "remove": basetypes.ListType{ - ElemType: WorkspaceBinding{}.ToAttrType(ctx), + ElemType: WorkspaceBinding{}.ToObjectType(ctx), }, "securable_name": types.StringType, "securable_type": types.StringType, @@ -10486,16 +10486,16 @@ func (a ValidateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ValidateCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ValidateCredentialRequest in the Terraform plugin framework type // system. -func (a ValidateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ValidateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToAttrType(ctx), + ElemType: AwsIamRole{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToAttrType(ctx), + ElemType: AzureManagedIdentity{}.ToObjectType(ctx), }, "credential_name": types.StringType, "external_location_name": types.StringType, @@ -10533,14 +10533,14 @@ func (a ValidateCredentialResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ValidateCredentialResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ValidateCredentialResponse in the Terraform plugin framework type // system. -func (a ValidateCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ValidateCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, "results": basetypes.ListType{ - ElemType: CredentialValidationResult{}.ToAttrType(ctx), + ElemType: CredentialValidationResult{}.ToObjectType(ctx), }, }, } @@ -10556,7 +10556,7 @@ type ValidateStorageCredential struct { // The Cloudflare API token configuration. CloudflareApiToken types.List `tfsdk:"cloudflare_api_token" tf:"optional,object"` // The Databricks created GCP service account configuration. - DatabricksGcpServiceAccount []DatabricksGcpServiceAccountRequest `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` + DatabricksGcpServiceAccount types.List `tfsdk:"databricks_gcp_service_account" tf:"optional,object"` // The name of an existing external location to validate. ExternalLocationName types.String `tfsdk:"external_location_name" tf:"optional"` // Whether the storage credential is only usable for read operations. @@ -10590,25 +10590,25 @@ func (a ValidateStorageCredential) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ValidateStorageCredential in the Terraform plugin framework type +// ToObjectType returns the representation of ValidateStorageCredential in the Terraform plugin framework type // system. -func (a ValidateStorageCredential) ToAttrType(ctx context.Context) types.ObjectType { +func (a ValidateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.ToAttrType(ctx), + ElemType: AwsIamRoleRequest{}.ToObjectType(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityRequest{}.ToAttrType(ctx), + ElemType: AzureManagedIdentityRequest{}.ToObjectType(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToAttrType(ctx), + ElemType: AzureServicePrincipal{}.ToObjectType(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToAttrType(ctx), + ElemType: CloudflareApiToken{}.ToObjectType(ctx), }, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.ToAttrType(ctx), + ElemType: DatabricksGcpServiceAccountRequest{}.ToObjectType(ctx), }, "external_location_name": types.StringType, "read_only": types.BoolType, @@ -10644,14 +10644,14 @@ func (a ValidateStorageCredentialResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of ValidateStorageCredentialResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ValidateStorageCredentialResponse in the Terraform plugin framework type // system. -func (a ValidateStorageCredentialResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ValidateStorageCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, "results": basetypes.ListType{ - ElemType: ValidationResult{}.ToAttrType(ctx), + ElemType: ValidationResult{}.ToObjectType(ctx), }, }, } @@ -10683,9 +10683,9 @@ func (a ValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of ValidationResult in the Terraform plugin framework type +// ToObjectType returns the representation of ValidationResult in the Terraform plugin framework type // system. -func (a ValidationResult) ToAttrType(ctx context.Context) types.ObjectType { +func (a ValidationResult) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -10753,9 +10753,9 @@ func (a VolumeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of VolumeInfo in the Terraform plugin framework type +// ToObjectType returns the representation of VolumeInfo in the Terraform plugin framework type // system. -func (a VolumeInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a VolumeInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, @@ -10765,7 +10765,7 @@ func (a VolumeInfo) ToAttrType(ctx context.Context) types.ObjectType { "created_at": types.Int64Type, "created_by": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToAttrType(ctx), + ElemType: EncryptionDetails{}.ToObjectType(ctx), }, "full_name": types.StringType, "metastore_id": types.StringType, @@ -10804,9 +10804,9 @@ func (a WorkspaceBinding) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of WorkspaceBinding in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceBinding in the Terraform plugin framework type // system. -func (a WorkspaceBinding) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceBinding) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "binding_type": types.StringType, @@ -10844,13 +10844,13 @@ func (a WorkspaceBindingsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of WorkspaceBindingsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceBindingsResponse in the Terraform plugin framework type // system. -func (a WorkspaceBindingsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceBindingsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bindings": basetypes.ListType{ - ElemType: WorkspaceBinding{}.ToAttrType(ctx), + ElemType: WorkspaceBinding{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 3e2d1d0582..17f615a5e9 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -65,9 +65,9 @@ func (a AddInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of AddInstanceProfile in the Terraform plugin framework type +// ToObjectType returns the representation of AddInstanceProfile in the Terraform plugin framework type // system. -func (a AddInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { +func (a AddInstanceProfile) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "iam_role_arn": types.StringType, @@ -98,9 +98,9 @@ func (a AddResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of AddResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AddResponse in the Terraform plugin framework type // system. -func (a AddResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AddResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -129,9 +129,9 @@ func (a Adlsgen2Info) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of Adlsgen2Info in the Terraform plugin framework type +// ToObjectType returns the representation of Adlsgen2Info in the Terraform plugin framework type // system. -func (a Adlsgen2Info) ToAttrType(ctx context.Context) types.ObjectType { +func (a Adlsgen2Info) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -167,9 +167,9 @@ func (a AutoScale) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of AutoScale in the Terraform plugin framework type +// ToObjectType returns the representation of AutoScale in the Terraform plugin framework type // system. -func (a AutoScale) ToAttrType(ctx context.Context) types.ObjectType { +func (a AutoScale) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_workers": types.Int64Type, @@ -281,9 +281,9 @@ func (a AwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of AwsAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of AwsAttributes in the Terraform plugin framework type // system. -func (a AwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -345,15 +345,15 @@ func (a AzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of AzureAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of AzureAttributes in the Terraform plugin framework type // system. -func (a AzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, "first_on_demand": types.Int64Type, "log_analytics_info": basetypes.ListType{ - ElemType: LogAnalyticsInfo{}.ToAttrType(ctx), + ElemType: LogAnalyticsInfo{}.ToObjectType(ctx), }, "spot_bid_max_price": types.Float64Type, }, @@ -385,9 +385,9 @@ func (a CancelCommand) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelCommand in the Terraform plugin framework type +// ToObjectType returns the representation of CancelCommand in the Terraform plugin framework type // system. -func (a CancelCommand) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelCommand) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -417,9 +417,9 @@ func (a CancelResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CancelResponse in the Terraform plugin framework type // system. -func (a CancelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -449,9 +449,9 @@ func (a ChangeClusterOwner) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ChangeClusterOwner in the Terraform plugin framework type +// ToObjectType returns the representation of ChangeClusterOwner in the Terraform plugin framework type // system. -func (a ChangeClusterOwner) ToAttrType(ctx context.Context) types.ObjectType { +func (a ChangeClusterOwner) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -480,9 +480,9 @@ func (a ChangeClusterOwnerResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of ChangeClusterOwnerResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ChangeClusterOwnerResponse in the Terraform plugin framework type // system. -func (a ChangeClusterOwnerResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ChangeClusterOwnerResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -512,9 +512,9 @@ func (a ClientsTypes) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClientsTypes in the Terraform plugin framework type +// ToObjectType returns the representation of ClientsTypes in the Terraform plugin framework type // system. -func (a ClientsTypes) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClientsTypes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "jobs": types.BoolType, @@ -545,9 +545,9 @@ func (a CloneCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of CloneCluster in the Terraform plugin framework type +// ToObjectType returns the representation of CloneCluster in the Terraform plugin framework type // system. -func (a CloneCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a CloneCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "source_cluster_id": types.StringType, @@ -578,9 +578,9 @@ func (a CloudProviderNodeInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CloudProviderNodeInfo in the Terraform plugin framework type +// ToObjectType returns the representation of CloudProviderNodeInfo in the Terraform plugin framework type // system. -func (a CloudProviderNodeInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a CloudProviderNodeInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "status": basetypes.ListType{ @@ -618,9 +618,9 @@ func (a ClusterAccessControlRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAccessControlRequest in the Terraform plugin framework type // system. -func (a ClusterAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -663,13 +663,13 @@ func (a ClusterAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ClusterAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAccessControlResponse in the Terraform plugin framework type // system. -func (a ClusterAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ClusterPermission{}.ToAttrType(ctx), + ElemType: ClusterPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -841,20 +841,20 @@ func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ClusterAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAttributes in the Terraform plugin framework type // system. -func (a ClusterAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToAttrType(ctx), + ElemType: AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToAttrType(ctx), + ElemType: AzureAttributes{}.ToObjectType(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToAttrType(ctx), + ElemType: ClusterLogConf{}.ToObjectType(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -862,17 +862,17 @@ func (a ClusterAttributes) ToAttrType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToAttrType(ctx), + ElemType: GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -890,7 +890,7 @@ func (a ClusterAttributes) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToAttrType(ctx), + ElemType: WorkloadType{}.ToObjectType(ctx), }, }, } @@ -928,9 +928,9 @@ func (a ClusterCompliance) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ClusterCompliance in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterCompliance in the Terraform plugin framework type // system. -func (a ClusterCompliance) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterCompliance) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -1194,28 +1194,28 @@ func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ClusterDetails in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterDetails in the Terraform plugin framework type // system. -func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToAttrType(ctx), + ElemType: AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToAttrType(ctx), + ElemType: AzureAttributes{}.ToObjectType(ctx), }, "cluster_cores": types.Float64Type, "cluster_id": types.StringType, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToAttrType(ctx), + ElemType: ClusterLogConf{}.ToObjectType(ctx), }, "cluster_log_status": basetypes.ListType{ - ElemType: LogSyncStatus{}.ToAttrType(ctx), + ElemType: LogSyncStatus{}.ToObjectType(ctx), }, "cluster_memory_mb": types.Int64Type, "cluster_name": types.StringType, @@ -1229,23 +1229,23 @@ func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "driver": basetypes.ListType{ - ElemType: SparkNode{}.ToAttrType(ctx), + ElemType: SparkNode{}.ToObjectType(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "executors": basetypes.ListType{ - ElemType: SparkNode{}.ToAttrType(ctx), + ElemType: SparkNode{}.ToObjectType(ctx), }, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToAttrType(ctx), + ElemType: GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "jdbc_port": types.Int64Type, @@ -1265,7 +1265,7 @@ func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { }, "spark_version": types.StringType, "spec": basetypes.ListType{ - ElemType: ClusterSpec{}.ToAttrType(ctx), + ElemType: ClusterSpec{}.ToObjectType(ctx), }, "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, @@ -1275,10 +1275,10 @@ func (a ClusterDetails) ToAttrType(ctx context.Context) types.ObjectType { "state_message": types.StringType, "terminated_time": types.Int64Type, "termination_reason": basetypes.ListType{ - ElemType: TerminationReason{}.ToAttrType(ctx), + ElemType: TerminationReason{}.ToObjectType(ctx), }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToAttrType(ctx), + ElemType: WorkloadType{}.ToObjectType(ctx), }, }, } @@ -1319,17 +1319,17 @@ func (a ClusterEvent) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ClusterEvent in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterEvent in the Terraform plugin framework type // system. -func (a ClusterEvent) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterEvent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "data_plane_event_details": basetypes.ListType{ - ElemType: DataPlaneEventDetails{}.ToAttrType(ctx), + ElemType: DataPlaneEventDetails{}.ToObjectType(ctx), }, "details": basetypes.ListType{ - ElemType: EventDetails{}.ToAttrType(ctx), + ElemType: EventDetails{}.ToObjectType(ctx), }, "timestamp": types.Int64Type, "type": types.StringType, @@ -1363,14 +1363,14 @@ func (a ClusterLibraryStatuses) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ClusterLibraryStatuses in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterLibraryStatuses in the Terraform plugin framework type // system. -func (a ClusterLibraryStatuses) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterLibraryStatuses) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "library_statuses": basetypes.ListType{ - ElemType: LibraryFullStatus{}.ToAttrType(ctx), + ElemType: LibraryFullStatus{}.ToObjectType(ctx), }, }, } @@ -1408,16 +1408,16 @@ func (a ClusterLogConf) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ClusterLogConf in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterLogConf in the Terraform plugin framework type // system. -func (a ClusterLogConf) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterLogConf) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbfs": basetypes.ListType{ - ElemType: DbfsStorageInfo{}.ToAttrType(ctx), + ElemType: DbfsStorageInfo{}.ToObjectType(ctx), }, "s3": basetypes.ListType{ - ElemType: S3StorageInfo{}.ToAttrType(ctx), + ElemType: S3StorageInfo{}.ToObjectType(ctx), }, }, } @@ -1450,9 +1450,9 @@ func (a ClusterPermission) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ClusterPermission in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPermission in the Terraform plugin framework type // system. -func (a ClusterPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1491,13 +1491,13 @@ func (a ClusterPermissions) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ClusterPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPermissions in the Terraform plugin framework type // system. -func (a ClusterPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterAccessControlResponse{}.ToAttrType(ctx), + ElemType: ClusterAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1528,9 +1528,9 @@ func (a ClusterPermissionsDescription) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPermissionsDescription in the Terraform plugin framework type // system. -func (a ClusterPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1564,13 +1564,13 @@ func (a ClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ClusterPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPermissionsRequest in the Terraform plugin framework type // system. -func (a ClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterAccessControlRequest{}.ToAttrType(ctx), + ElemType: ClusterAccessControlRequest{}.ToObjectType(ctx), }, "cluster_id": types.StringType, }, @@ -1605,9 +1605,9 @@ func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterPolicyAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPolicyAccessControlRequest in the Terraform plugin framework type // system. -func (a ClusterPolicyAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPolicyAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1650,13 +1650,13 @@ func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of ClusterPolicyAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPolicyAccessControlResponse in the Terraform plugin framework type // system. -func (a ClusterPolicyAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPolicyAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ClusterPolicyPermission{}.ToAttrType(ctx), + ElemType: ClusterPolicyPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1693,9 +1693,9 @@ func (a ClusterPolicyPermission) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ClusterPolicyPermission in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPolicyPermission in the Terraform plugin framework type // system. -func (a ClusterPolicyPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPolicyPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1734,13 +1734,13 @@ func (a ClusterPolicyPermissions) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of ClusterPolicyPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPolicyPermissions in the Terraform plugin framework type // system. -func (a ClusterPolicyPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPolicyPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterPolicyAccessControlResponse{}.ToAttrType(ctx), + ElemType: ClusterPolicyAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1771,9 +1771,9 @@ func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterPolicyPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPolicyPermissionsDescription in the Terraform plugin framework type // system. -func (a ClusterPolicyPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPolicyPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1807,13 +1807,13 @@ func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of ClusterPolicyPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterPolicyPermissionsRequest in the Terraform plugin framework type // system. -func (a ClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterPolicyPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterPolicyAccessControlRequest{}.ToAttrType(ctx), + ElemType: ClusterPolicyAccessControlRequest{}.ToObjectType(ctx), }, "cluster_policy_id": types.StringType, }, @@ -1854,9 +1854,9 @@ func (a ClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterSettingsChange in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterSettingsChange in the Terraform plugin framework type // system. -func (a ClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterSettingsChange) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "field": types.StringType, @@ -1903,13 +1903,13 @@ func (a ClusterSize) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of ClusterSize in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterSize in the Terraform plugin framework type // system. -func (a ClusterSize) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterSize) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "num_workers": types.Int64Type, }, @@ -2098,24 +2098,24 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of ClusterSpec in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterSpec in the Terraform plugin framework type // system. -func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToAttrType(ctx), + ElemType: AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToAttrType(ctx), + ElemType: AzureAttributes{}.ToObjectType(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToAttrType(ctx), + ElemType: ClusterLogConf{}.ToObjectType(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -2123,17 +2123,17 @@ func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToAttrType(ctx), + ElemType: GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -2152,7 +2152,7 @@ func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToAttrType(ctx), + ElemType: WorkloadType{}.ToObjectType(ctx), }, }, } @@ -2181,9 +2181,9 @@ func (a ClusterStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterStatus in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterStatus in the Terraform plugin framework type // system. -func (a ClusterStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -2219,9 +2219,9 @@ func (a Command) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of Command in the Terraform plugin framework type +// ToObjectType returns the representation of Command in the Terraform plugin framework type // system. -func (a Command) ToAttrType(ctx context.Context) types.ObjectType { +func (a Command) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2258,9 +2258,9 @@ func (a CommandStatusRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of CommandStatusRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CommandStatusRequest in the Terraform plugin framework type // system. -func (a CommandStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CommandStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2297,14 +2297,14 @@ func (a CommandStatusResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CommandStatusResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CommandStatusResponse in the Terraform plugin framework type // system. -func (a CommandStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CommandStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "results": basetypes.ListType{ - ElemType: Results{}.ToAttrType(ctx), + ElemType: Results{}.ToObjectType(ctx), }, "status": types.StringType, }, @@ -2335,9 +2335,9 @@ func (a ContextStatusRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ContextStatusRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ContextStatusRequest in the Terraform plugin framework type // system. -func (a ContextStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ContextStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2369,9 +2369,9 @@ func (a ContextStatusResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ContextStatusResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ContextStatusResponse in the Terraform plugin framework type // system. -func (a ContextStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ContextStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -2566,27 +2566,27 @@ func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of CreateCluster in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCluster in the Terraform plugin framework type // system. -func (a CreateCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToAttrType(ctx), + ElemType: AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToAttrType(ctx), + ElemType: AzureAttributes{}.ToObjectType(ctx), }, "clone_from": basetypes.ListType{ - ElemType: CloneCluster{}.ToAttrType(ctx), + ElemType: CloneCluster{}.ToObjectType(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToAttrType(ctx), + ElemType: ClusterLogConf{}.ToObjectType(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -2594,17 +2594,17 @@ func (a CreateCluster) ToAttrType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToAttrType(ctx), + ElemType: GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -2623,7 +2623,7 @@ func (a CreateCluster) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToAttrType(ctx), + ElemType: WorkloadType{}.ToObjectType(ctx), }, }, } @@ -2650,9 +2650,9 @@ func (a CreateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateClusterResponse in the Terraform plugin framework type // system. -func (a CreateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -2684,9 +2684,9 @@ func (a CreateContext) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateContext in the Terraform plugin framework type +// ToObjectType returns the representation of CreateContext in the Terraform plugin framework type // system. -func (a CreateContext) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateContext) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2777,26 +2777,26 @@ func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateInstancePool in the Terraform plugin framework type +// ToObjectType returns the representation of CreateInstancePool in the Terraform plugin framework type // system. -func (a CreateInstancePool) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateInstancePool) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolAwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolAzureAttributes{}.ToObjectType(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.ToAttrType(ctx), + ElemType: DiskSpec{}.ToObjectType(ctx), }, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolGcpAttributes{}.ToObjectType(ctx), }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_name": types.StringType, @@ -2804,7 +2804,7 @@ func (a CreateInstancePool) ToAttrType(ctx context.Context) types.ObjectType { "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, @@ -2835,9 +2835,9 @@ func (a CreateInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateInstancePoolResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateInstancePoolResponse in the Terraform plugin framework type // system. -func (a CreateInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateInstancePoolResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -2900,15 +2900,15 @@ func (a CreatePolicy) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of CreatePolicy in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePolicy in the Terraform plugin framework type // system. -func (a CreatePolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToAttrType(ctx), + ElemType: Library{}.ToObjectType(ctx), }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, @@ -2940,9 +2940,9 @@ func (a CreatePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreatePolicyResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePolicyResponse in the Terraform plugin framework type // system. -func (a CreatePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_id": types.StringType, @@ -2972,9 +2972,9 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type // system. -func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "script_id": types.StringType, @@ -3003,9 +3003,9 @@ func (a Created) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of Created in the Terraform plugin framework type +// ToObjectType returns the representation of Created in the Terraform plugin framework type // system. -func (a Created) ToAttrType(ctx context.Context) types.ObjectType { +func (a Created) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3041,9 +3041,9 @@ func (a DataPlaneEventDetails) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DataPlaneEventDetails in the Terraform plugin framework type +// ToObjectType returns the representation of DataPlaneEventDetails in the Terraform plugin framework type // system. -func (a DataPlaneEventDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a DataPlaneEventDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "event_type": types.StringType, @@ -3076,9 +3076,9 @@ func (a DbfsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DbfsStorageInfo in the Terraform plugin framework type +// ToObjectType returns the representation of DbfsStorageInfo in the Terraform plugin framework type // system. -func (a DbfsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a DbfsStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -3108,9 +3108,9 @@ func (a DeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCluster in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCluster in the Terraform plugin framework type // system. -func (a DeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -3138,9 +3138,9 @@ func (a DeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteClusterResponse in the Terraform plugin framework type // system. -func (a DeleteClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3169,9 +3169,9 @@ func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteGlobalInitScriptRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteGlobalInitScriptRequest in the Terraform plugin framework type // system. -func (a DeleteGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteGlobalInitScriptRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "script_id": types.StringType, @@ -3201,9 +3201,9 @@ func (a DeleteInstancePool) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteInstancePool in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteInstancePool in the Terraform plugin framework type // system. -func (a DeleteInstancePool) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteInstancePool) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -3231,9 +3231,9 @@ func (a DeleteInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteInstancePoolResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteInstancePoolResponse in the Terraform plugin framework type // system. -func (a DeleteInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteInstancePoolResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3261,9 +3261,9 @@ func (a DeletePolicy) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePolicy in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePolicy in the Terraform plugin framework type // system. -func (a DeletePolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_id": types.StringType, @@ -3291,9 +3291,9 @@ func (a DeletePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePolicyResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePolicyResponse in the Terraform plugin framework type // system. -func (a DeletePolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3319,9 +3319,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3350,9 +3350,9 @@ func (a DestroyContext) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DestroyContext in the Terraform plugin framework type +// ToObjectType returns the representation of DestroyContext in the Terraform plugin framework type // system. -func (a DestroyContext) ToAttrType(ctx context.Context) types.ObjectType { +func (a DestroyContext) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -3381,9 +3381,9 @@ func (a DestroyResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DestroyResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DestroyResponse in the Terraform plugin framework type // system. -func (a DestroyResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DestroyResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3443,9 +3443,9 @@ func (a DiskSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of DiskSpec in the Terraform plugin framework type +// ToObjectType returns the representation of DiskSpec in the Terraform plugin framework type // system. -func (a DiskSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a DiskSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disk_count": types.Int64Type, @@ -3453,7 +3453,7 @@ func (a DiskSpec) ToAttrType(ctx context.Context) types.ObjectType { "disk_size": types.Int64Type, "disk_throughput": types.Int64Type, "disk_type": basetypes.ListType{ - ElemType: DiskType{}.ToAttrType(ctx), + ElemType: DiskType{}.ToObjectType(ctx), }, }, } @@ -3482,9 +3482,9 @@ func (a DiskType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of DiskType in the Terraform plugin framework type +// ToObjectType returns the representation of DiskType in the Terraform plugin framework type // system. -func (a DiskType) ToAttrType(ctx context.Context) types.ObjectType { +func (a DiskType) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "azure_disk_volume_type": types.StringType, @@ -3517,9 +3517,9 @@ func (a DockerBasicAuth) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DockerBasicAuth in the Terraform plugin framework type +// ToObjectType returns the representation of DockerBasicAuth in the Terraform plugin framework type // system. -func (a DockerBasicAuth) ToAttrType(ctx context.Context) types.ObjectType { +func (a DockerBasicAuth) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "password": types.StringType, @@ -3553,13 +3553,13 @@ func (a DockerImage) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of DockerImage in the Terraform plugin framework type +// ToObjectType returns the representation of DockerImage in the Terraform plugin framework type // system. -func (a DockerImage) ToAttrType(ctx context.Context) types.ObjectType { +func (a DockerImage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "basic_auth": basetypes.ListType{ - ElemType: DockerBasicAuth{}.ToAttrType(ctx), + ElemType: DockerBasicAuth{}.ToObjectType(ctx), }, "url": types.StringType, }, @@ -3750,25 +3750,25 @@ func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of EditCluster in the Terraform plugin framework type +// ToObjectType returns the representation of EditCluster in the Terraform plugin framework type // system. -func (a EditCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToAttrType(ctx), + ElemType: AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToAttrType(ctx), + ElemType: AzureAttributes{}.ToObjectType(ctx), }, "cluster_id": types.StringType, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToAttrType(ctx), + ElemType: ClusterLogConf{}.ToObjectType(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -3776,17 +3776,17 @@ func (a EditCluster) ToAttrType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToAttrType(ctx), + ElemType: GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -3805,7 +3805,7 @@ func (a EditCluster) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToAttrType(ctx), + ElemType: WorkloadType{}.ToObjectType(ctx), }, }, } @@ -3831,9 +3831,9 @@ func (a EditClusterResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of EditClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EditClusterResponse in the Terraform plugin framework type // system. -func (a EditClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3892,9 +3892,9 @@ func (a EditInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of EditInstancePool in the Terraform plugin framework type +// ToObjectType returns the representation of EditInstancePool in the Terraform plugin framework type // system. -func (a EditInstancePool) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditInstancePool) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "custom_tags": basetypes.MapType{ @@ -3930,9 +3930,9 @@ func (a EditInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of EditInstancePoolResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EditInstancePoolResponse in the Terraform plugin framework type // system. -func (a EditInstancePoolResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditInstancePoolResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3995,15 +3995,15 @@ func (a EditPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of EditPolicy in the Terraform plugin framework type +// ToObjectType returns the representation of EditPolicy in the Terraform plugin framework type // system. -func (a EditPolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditPolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToAttrType(ctx), + ElemType: Library{}.ToObjectType(ctx), }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, @@ -4034,9 +4034,9 @@ func (a EditPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of EditPolicyResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EditPolicyResponse in the Terraform plugin framework type // system. -func (a EditPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditPolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4062,9 +4062,9 @@ func (a EditResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of EditResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EditResponse in the Terraform plugin framework type // system. -func (a EditResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4095,9 +4095,9 @@ func (a EnforceClusterComplianceRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of EnforceClusterComplianceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of EnforceClusterComplianceRequest in the Terraform plugin framework type // system. -func (a EnforceClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnforceClusterComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4134,13 +4134,13 @@ func (a EnforceClusterComplianceResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of EnforceClusterComplianceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EnforceClusterComplianceResponse in the Terraform plugin framework type // system. -func (a EnforceClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnforceClusterComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "changes": basetypes.ListType{ - ElemType: ClusterSettingsChange{}.ToAttrType(ctx), + ElemType: ClusterSettingsChange{}.ToObjectType(ctx), }, "has_changes": types.BoolType, }, @@ -4184,9 +4184,9 @@ func (a Environment) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of Environment in the Terraform plugin framework type +// ToObjectType returns the representation of Environment in the Terraform plugin framework type // system. -func (a Environment) ToAttrType(ctx context.Context) types.ObjectType { +func (a Environment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "client": types.StringType, @@ -4272,17 +4272,17 @@ func (a EventDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of EventDetails in the Terraform plugin framework type +// ToObjectType returns the representation of EventDetails in the Terraform plugin framework type // system. -func (a EventDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a EventDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": basetypes.ListType{ - ElemType: ClusterAttributes{}.ToAttrType(ctx), + ElemType: ClusterAttributes{}.ToObjectType(ctx), }, "cause": types.StringType, "cluster_size": basetypes.ListType{ - ElemType: ClusterSize{}.ToAttrType(ctx), + ElemType: ClusterSize{}.ToObjectType(ctx), }, "current_num_vcpus": types.Int64Type, "current_num_workers": types.Int64Type, @@ -4292,19 +4292,19 @@ func (a EventDetails) ToAttrType(ctx context.Context) types.ObjectType { "enable_termination_for_node_blocklisted": types.BoolType, "free_space": types.Int64Type, "init_scripts": basetypes.ListType{ - ElemType: InitScriptEventDetails{}.ToAttrType(ctx), + ElemType: InitScriptEventDetails{}.ToObjectType(ctx), }, "instance_id": types.StringType, "job_run_name": types.StringType, "previous_attributes": basetypes.ListType{ - ElemType: ClusterAttributes{}.ToAttrType(ctx), + ElemType: ClusterAttributes{}.ToObjectType(ctx), }, "previous_cluster_size": basetypes.ListType{ - ElemType: ClusterSize{}.ToAttrType(ctx), + ElemType: ClusterSize{}.ToObjectType(ctx), }, "previous_disk_size": types.Int64Type, "reason": basetypes.ListType{ - ElemType: TerminationReason{}.ToAttrType(ctx), + ElemType: TerminationReason{}.ToObjectType(ctx), }, "target_num_vcpus": types.Int64Type, "target_num_workers": types.Int64Type, @@ -4364,9 +4364,9 @@ func (a GcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of GcpAttributes in the Terraform plugin framework type // system. -func (a GcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -4401,9 +4401,9 @@ func (a GcsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcsStorageInfo in the Terraform plugin framework type +// ToObjectType returns the representation of GcsStorageInfo in the Terraform plugin framework type // system. -func (a GcsStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcsStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -4434,9 +4434,9 @@ func (a GetClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterComplianceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterComplianceRequest in the Terraform plugin framework type // system. -func (a GetClusterComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4475,9 +4475,9 @@ func (a GetClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of GetClusterComplianceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterComplianceResponse in the Terraform plugin framework type // system. -func (a GetClusterComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, @@ -4511,9 +4511,9 @@ func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetClusterPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4545,13 +4545,13 @@ func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of GetClusterPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetClusterPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ClusterPermissionsDescription{}.ToAttrType(ctx), + ElemType: ClusterPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -4580,9 +4580,9 @@ func (a GetClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPermissionsRequest in the Terraform plugin framework type // system. -func (a GetClusterPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4613,9 +4613,9 @@ func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterPolicyPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPolicyPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetClusterPolicyPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPolicyPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_policy_id": types.StringType, @@ -4647,13 +4647,13 @@ func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes(ctx conte } } -// ToAttrType returns the representation of GetClusterPolicyPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPolicyPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetClusterPolicyPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPolicyPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ClusterPolicyPermissionsDescription{}.ToAttrType(ctx), + ElemType: ClusterPolicyPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -4682,9 +4682,9 @@ func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterPolicyPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPolicyPermissionsRequest in the Terraform plugin framework type // system. -func (a GetClusterPolicyPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPolicyPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_policy_id": types.StringType, @@ -4715,9 +4715,9 @@ func (a GetClusterPolicyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterPolicyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterPolicyRequest in the Terraform plugin framework type // system. -func (a GetClusterPolicyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterPolicyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_id": types.StringType, @@ -4748,9 +4748,9 @@ func (a GetClusterRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetClusterRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetClusterRequest in the Terraform plugin framework type // system. -func (a GetClusterRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetClusterRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4800,9 +4800,9 @@ func (a GetEvents) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of GetEvents in the Terraform plugin framework type +// ToObjectType returns the representation of GetEvents in the Terraform plugin framework type // system. -func (a GetEvents) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEvents) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4849,16 +4849,16 @@ func (a GetEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of GetEventsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetEventsResponse in the Terraform plugin framework type // system. -func (a GetEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEventsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "events": basetypes.ListType{ - ElemType: ClusterEvent{}.ToAttrType(ctx), + ElemType: ClusterEvent{}.ToObjectType(ctx), }, "next_page": basetypes.ListType{ - ElemType: GetEvents{}.ToAttrType(ctx), + ElemType: GetEvents{}.ToObjectType(ctx), }, "total_count": types.Int64Type, }, @@ -4888,9 +4888,9 @@ func (a GetGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetGlobalInitScriptRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetGlobalInitScriptRequest in the Terraform plugin framework type // system. -func (a GetGlobalInitScriptRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetGlobalInitScriptRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "script_id": types.StringType, @@ -5002,16 +5002,16 @@ func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of GetInstancePool in the Terraform plugin framework type +// ToObjectType returns the representation of GetInstancePool in the Terraform plugin framework type // system. -func (a GetInstancePool) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetInstancePool) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolAwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolAzureAttributes{}.ToObjectType(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, @@ -5020,11 +5020,11 @@ func (a GetInstancePool) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.ToAttrType(ctx), + ElemType: DiskSpec{}.ToObjectType(ctx), }, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolGcpAttributes{}.ToObjectType(ctx), }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, @@ -5033,17 +5033,17 @@ func (a GetInstancePool) ToAttrType(ctx context.Context) types.ObjectType { "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, "state": types.StringType, "stats": basetypes.ListType{ - ElemType: InstancePoolStats{}.ToAttrType(ctx), + ElemType: InstancePoolStats{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: InstancePoolStatus{}.ToAttrType(ctx), + ElemType: InstancePoolStatus{}.ToObjectType(ctx), }, }, } @@ -5072,9 +5072,9 @@ func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetInstancePoolPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetInstancePoolPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetInstancePoolPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetInstancePoolPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -5106,13 +5106,13 @@ func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes(ctx contex } } -// ToAttrType returns the representation of GetInstancePoolPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetInstancePoolPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetInstancePoolPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetInstancePoolPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: InstancePoolPermissionsDescription{}.ToAttrType(ctx), + ElemType: InstancePoolPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -5141,9 +5141,9 @@ func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetInstancePoolPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetInstancePoolPermissionsRequest in the Terraform plugin framework type // system. -func (a GetInstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetInstancePoolPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -5174,9 +5174,9 @@ func (a GetInstancePoolRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetInstancePoolRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetInstancePoolRequest in the Terraform plugin framework type // system. -func (a GetInstancePoolRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetInstancePoolRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -5210,9 +5210,9 @@ func (a GetPolicyFamilyRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPolicyFamilyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPolicyFamilyRequest in the Terraform plugin framework type // system. -func (a GetPolicyFamilyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPolicyFamilyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_family_id": types.StringType, @@ -5245,13 +5245,13 @@ func (a GetSparkVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of GetSparkVersionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetSparkVersionsResponse in the Terraform plugin framework type // system. -func (a GetSparkVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetSparkVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "versions": basetypes.ListType{ - ElemType: SparkVersion{}.ToAttrType(ctx), + ElemType: SparkVersion{}.ToObjectType(ctx), }, }, } @@ -5295,9 +5295,9 @@ func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GlobalInitScriptCreateRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GlobalInitScriptCreateRequest in the Terraform plugin framework type // system. -func (a GlobalInitScriptCreateRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GlobalInitScriptCreateRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -5347,9 +5347,9 @@ func (a GlobalInitScriptDetails) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of GlobalInitScriptDetails in the Terraform plugin framework type +// ToObjectType returns the representation of GlobalInitScriptDetails in the Terraform plugin framework type // system. -func (a GlobalInitScriptDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a GlobalInitScriptDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -5405,9 +5405,9 @@ func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GlobalInitScriptDetailsWithContent in the Terraform plugin framework type +// ToObjectType returns the representation of GlobalInitScriptDetailsWithContent in the Terraform plugin framework type // system. -func (a GlobalInitScriptDetailsWithContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a GlobalInitScriptDetailsWithContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -5464,9 +5464,9 @@ func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GlobalInitScriptUpdateRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GlobalInitScriptUpdateRequest in the Terraform plugin framework type // system. -func (a GlobalInitScriptUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GlobalInitScriptUpdateRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -5507,16 +5507,16 @@ func (a InitScriptEventDetails) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of InitScriptEventDetails in the Terraform plugin framework type +// ToObjectType returns the representation of InitScriptEventDetails in the Terraform plugin framework type // system. -func (a InitScriptEventDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a InitScriptEventDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.ToAttrType(ctx), + ElemType: InitScriptInfoAndExecutionDetails{}.ToObjectType(ctx), }, "global": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.ToAttrType(ctx), + ElemType: InitScriptInfoAndExecutionDetails{}.ToObjectType(ctx), }, "reported_for_node": types.StringType, }, @@ -5549,9 +5549,9 @@ func (a InitScriptExecutionDetails) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of InitScriptExecutionDetails in the Terraform plugin framework type +// ToObjectType returns the representation of InitScriptExecutionDetails in the Terraform plugin framework type // system. -func (a InitScriptExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a InitScriptExecutionDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_message": types.StringType, @@ -5614,31 +5614,31 @@ func (a InitScriptInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of InitScriptInfo in the Terraform plugin framework type +// ToObjectType returns the representation of InitScriptInfo in the Terraform plugin framework type // system. -func (a InitScriptInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a InitScriptInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "abfss": basetypes.ListType{ - ElemType: Adlsgen2Info{}.ToAttrType(ctx), + ElemType: Adlsgen2Info{}.ToObjectType(ctx), }, "dbfs": basetypes.ListType{ - ElemType: DbfsStorageInfo{}.ToAttrType(ctx), + ElemType: DbfsStorageInfo{}.ToObjectType(ctx), }, "file": basetypes.ListType{ - ElemType: LocalFileInfo{}.ToAttrType(ctx), + ElemType: LocalFileInfo{}.ToObjectType(ctx), }, "gcs": basetypes.ListType{ - ElemType: GcsStorageInfo{}.ToAttrType(ctx), + ElemType: GcsStorageInfo{}.ToObjectType(ctx), }, "s3": basetypes.ListType{ - ElemType: S3StorageInfo{}.ToAttrType(ctx), + ElemType: S3StorageInfo{}.ToObjectType(ctx), }, "volumes": basetypes.ListType{ - ElemType: VolumesStorageInfo{}.ToAttrType(ctx), + ElemType: VolumesStorageInfo{}.ToObjectType(ctx), }, "workspace": basetypes.ListType{ - ElemType: WorkspaceStorageInfo{}.ToAttrType(ctx), + ElemType: WorkspaceStorageInfo{}.ToObjectType(ctx), }, }, } @@ -5671,16 +5671,16 @@ func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of InitScriptInfoAndExecutionDetails in the Terraform plugin framework type +// ToObjectType returns the representation of InitScriptInfoAndExecutionDetails in the Terraform plugin framework type // system. -func (a InitScriptInfoAndExecutionDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a InitScriptInfoAndExecutionDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "execution_details": basetypes.ListType{ - ElemType: InitScriptExecutionDetails{}.ToAttrType(ctx), + ElemType: InitScriptExecutionDetails{}.ToObjectType(ctx), }, "script": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, }, } @@ -5712,14 +5712,14 @@ func (a InstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of InstallLibraries in the Terraform plugin framework type +// ToObjectType returns the representation of InstallLibraries in the Terraform plugin framework type // system. -func (a InstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstallLibraries) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToAttrType(ctx), + ElemType: Library{}.ToObjectType(ctx), }, }, } @@ -5745,9 +5745,9 @@ func (a InstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstallLibrariesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of InstallLibrariesResponse in the Terraform plugin framework type // system. -func (a InstallLibrariesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstallLibrariesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5781,9 +5781,9 @@ func (a InstancePoolAccessControlRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstancePoolAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolAccessControlRequest in the Terraform plugin framework type // system. -func (a InstancePoolAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -5826,13 +5826,13 @@ func (a InstancePoolAccessControlResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of InstancePoolAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolAccessControlResponse in the Terraform plugin framework type // system. -func (a InstancePoolAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: InstancePoolPermission{}.ToAttrType(ctx), + ElemType: InstancePoolPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -5946,16 +5946,16 @@ func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of InstancePoolAndStats in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolAndStats in the Terraform plugin framework type // system. -func (a InstancePoolAndStats) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolAndStats) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolAwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolAzureAttributes{}.ToObjectType(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, @@ -5964,11 +5964,11 @@ func (a InstancePoolAndStats) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.ToAttrType(ctx), + ElemType: DiskSpec{}.ToObjectType(ctx), }, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.ToAttrType(ctx), + ElemType: InstancePoolGcpAttributes{}.ToObjectType(ctx), }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, @@ -5977,17 +5977,17 @@ func (a InstancePoolAndStats) ToAttrType(ctx context.Context) types.ObjectType { "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, "state": types.StringType, "stats": basetypes.ListType{ - ElemType: InstancePoolStats{}.ToAttrType(ctx), + ElemType: InstancePoolStats{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: InstancePoolStatus{}.ToAttrType(ctx), + ElemType: InstancePoolStatus{}.ToObjectType(ctx), }, }, } @@ -6042,9 +6042,9 @@ func (a InstancePoolAwsAttributes) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstancePoolAwsAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolAwsAttributes in the Terraform plugin framework type // system. -func (a InstancePoolAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolAwsAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -6082,9 +6082,9 @@ func (a InstancePoolAzureAttributes) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstancePoolAzureAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolAzureAttributes in the Terraform plugin framework type // system. -func (a InstancePoolAzureAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolAzureAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -6141,9 +6141,9 @@ func (a InstancePoolGcpAttributes) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstancePoolGcpAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolGcpAttributes in the Terraform plugin framework type // system. -func (a InstancePoolGcpAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolGcpAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gcp_availability": types.StringType, @@ -6180,9 +6180,9 @@ func (a InstancePoolPermission) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of InstancePoolPermission in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolPermission in the Terraform plugin framework type // system. -func (a InstancePoolPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -6221,13 +6221,13 @@ func (a InstancePoolPermissions) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of InstancePoolPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolPermissions in the Terraform plugin framework type // system. -func (a InstancePoolPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: InstancePoolAccessControlResponse{}.ToAttrType(ctx), + ElemType: InstancePoolAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -6258,9 +6258,9 @@ func (a InstancePoolPermissionsDescription) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstancePoolPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolPermissionsDescription in the Terraform plugin framework type // system. -func (a InstancePoolPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6294,13 +6294,13 @@ func (a InstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of InstancePoolPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolPermissionsRequest in the Terraform plugin framework type // system. -func (a InstancePoolPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: InstancePoolAccessControlRequest{}.ToAttrType(ctx), + ElemType: InstancePoolAccessControlRequest{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, }, @@ -6335,9 +6335,9 @@ func (a InstancePoolStats) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstancePoolStats in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolStats in the Terraform plugin framework type // system. -func (a InstancePoolStats) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolStats) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "idle_count": types.Int64Type, @@ -6375,13 +6375,13 @@ func (a InstancePoolStatus) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of InstancePoolStatus in the Terraform plugin framework type +// ToObjectType returns the representation of InstancePoolStatus in the Terraform plugin framework type // system. -func (a InstancePoolStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstancePoolStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pending_instance_errors": basetypes.ListType{ - ElemType: PendingInstanceError{}.ToAttrType(ctx), + ElemType: PendingInstanceError{}.ToObjectType(ctx), }, }, } @@ -6425,9 +6425,9 @@ func (a InstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of InstanceProfile in the Terraform plugin framework type +// ToObjectType returns the representation of InstanceProfile in the Terraform plugin framework type // system. -func (a InstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstanceProfile) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "iam_role_arn": types.StringType, @@ -6494,21 +6494,21 @@ func (a Library) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of Library in the Terraform plugin framework type +// ToObjectType returns the representation of Library in the Terraform plugin framework type // system. -func (a Library) ToAttrType(ctx context.Context) types.ObjectType { +func (a Library) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cran": basetypes.ListType{ - ElemType: RCranLibrary{}.ToAttrType(ctx), + ElemType: RCranLibrary{}.ToObjectType(ctx), }, "egg": types.StringType, "jar": types.StringType, "maven": basetypes.ListType{ - ElemType: MavenLibrary{}.ToAttrType(ctx), + ElemType: MavenLibrary{}.ToObjectType(ctx), }, "pypi": basetypes.ListType{ - ElemType: PythonPyPiLibrary{}.ToAttrType(ctx), + ElemType: PythonPyPiLibrary{}.ToObjectType(ctx), }, "requirements": types.StringType, "whl": types.StringType, @@ -6550,14 +6550,14 @@ func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of LibraryFullStatus in the Terraform plugin framework type +// ToObjectType returns the representation of LibraryFullStatus in the Terraform plugin framework type // system. -func (a LibraryFullStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a LibraryFullStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_library_for_all_clusters": types.BoolType, "library": basetypes.ListType{ - ElemType: Library{}.ToAttrType(ctx), + ElemType: Library{}.ToObjectType(ctx), }, "messages": basetypes.ListType{ ElemType: types.StringType, @@ -6591,13 +6591,13 @@ func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes(ctx context. } } -// ToAttrType returns the representation of ListAllClusterLibraryStatusesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAllClusterLibraryStatusesResponse in the Terraform plugin framework type // system. -func (a ListAllClusterLibraryStatusesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAllClusterLibraryStatusesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statuses": basetypes.ListType{ - ElemType: ClusterLibraryStatuses{}.ToAttrType(ctx), + ElemType: ClusterLibraryStatuses{}.ToObjectType(ctx), }, }, } @@ -6630,9 +6630,9 @@ func (a ListAvailableZonesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListAvailableZonesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAvailableZonesResponse in the Terraform plugin framework type // system. -func (a ListAvailableZonesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAvailableZonesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_zone": types.StringType, @@ -6673,9 +6673,9 @@ func (a ListClusterCompliancesRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListClusterCompliancesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListClusterCompliancesRequest in the Terraform plugin framework type // system. -func (a ListClusterCompliancesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClusterCompliancesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -6716,13 +6716,13 @@ func (a ListClusterCompliancesResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of ListClusterCompliancesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListClusterCompliancesResponse in the Terraform plugin framework type // system. -func (a ListClusterCompliancesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClusterCompliancesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusters": basetypes.ListType{ - ElemType: ClusterCompliance{}.ToAttrType(ctx), + ElemType: ClusterCompliance{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -6758,9 +6758,9 @@ func (a ListClusterPoliciesRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListClusterPoliciesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListClusterPoliciesRequest in the Terraform plugin framework type // system. -func (a ListClusterPoliciesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClusterPoliciesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sort_column": types.StringType, @@ -6800,9 +6800,9 @@ func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListClustersFilterBy in the Terraform plugin framework type +// ToObjectType returns the representation of ListClustersFilterBy in the Terraform plugin framework type // system. -func (a ListClustersFilterBy) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClustersFilterBy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_sources": basetypes.ListType{ @@ -6852,18 +6852,18 @@ func (a ListClustersRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListClustersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListClustersRequest in the Terraform plugin framework type // system. -func (a ListClustersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClustersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter_by": basetypes.ListType{ - ElemType: ListClustersFilterBy{}.ToAttrType(ctx), + ElemType: ListClustersFilterBy{}.ToObjectType(ctx), }, "page_size": types.Int64Type, "page_token": types.StringType, "sort_by": basetypes.ListType{ - ElemType: ListClustersSortBy{}.ToAttrType(ctx), + ElemType: ListClustersSortBy{}.ToObjectType(ctx), }, }, } @@ -6900,13 +6900,13 @@ func (a ListClustersResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListClustersResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListClustersResponse in the Terraform plugin framework type // system. -func (a ListClustersResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClustersResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusters": basetypes.ListType{ - ElemType: ClusterDetails{}.ToAttrType(ctx), + ElemType: ClusterDetails{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -6940,9 +6940,9 @@ func (a ListClustersSortBy) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListClustersSortBy in the Terraform plugin framework type +// ToObjectType returns the representation of ListClustersSortBy in the Terraform plugin framework type // system. -func (a ListClustersSortBy) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListClustersSortBy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "direction": types.StringType, @@ -6974,13 +6974,13 @@ func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListGlobalInitScriptsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListGlobalInitScriptsResponse in the Terraform plugin framework type // system. -func (a ListGlobalInitScriptsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListGlobalInitScriptsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scripts": basetypes.ListType{ - ElemType: GlobalInitScriptDetails{}.ToAttrType(ctx), + ElemType: GlobalInitScriptDetails{}.ToObjectType(ctx), }, }, } @@ -7009,13 +7009,13 @@ func (a ListInstancePools) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ListInstancePools in the Terraform plugin framework type +// ToObjectType returns the representation of ListInstancePools in the Terraform plugin framework type // system. -func (a ListInstancePools) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListInstancePools) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pools": basetypes.ListType{ - ElemType: InstancePoolAndStats{}.ToAttrType(ctx), + ElemType: InstancePoolAndStats{}.ToObjectType(ctx), }, }, } @@ -7045,13 +7045,13 @@ func (a ListInstanceProfilesResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListInstanceProfilesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListInstanceProfilesResponse in the Terraform plugin framework type // system. -func (a ListInstanceProfilesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListInstanceProfilesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_profiles": basetypes.ListType{ - ElemType: InstanceProfile{}.ToAttrType(ctx), + ElemType: InstanceProfile{}.ToObjectType(ctx), }, }, } @@ -7081,13 +7081,13 @@ func (a ListNodeTypesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListNodeTypesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListNodeTypesResponse in the Terraform plugin framework type // system. -func (a ListNodeTypesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNodeTypesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "node_types": basetypes.ListType{ - ElemType: NodeType{}.ToAttrType(ctx), + ElemType: NodeType{}.ToObjectType(ctx), }, }, } @@ -7117,13 +7117,13 @@ func (a ListPoliciesResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListPoliciesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListPoliciesResponse in the Terraform plugin framework type // system. -func (a ListPoliciesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPoliciesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policies": basetypes.ListType{ - ElemType: Policy{}.ToAttrType(ctx), + ElemType: Policy{}.ToObjectType(ctx), }, }, } @@ -7154,9 +7154,9 @@ func (a ListPolicyFamiliesRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListPolicyFamiliesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListPolicyFamiliesRequest in the Terraform plugin framework type // system. -func (a ListPolicyFamiliesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPolicyFamiliesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -7192,14 +7192,14 @@ func (a ListPolicyFamiliesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListPolicyFamiliesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListPolicyFamiliesResponse in the Terraform plugin framework type // system. -func (a ListPolicyFamiliesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPolicyFamiliesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "policy_families": basetypes.ListType{ - ElemType: PolicyFamily{}.ToAttrType(ctx), + ElemType: PolicyFamily{}.ToObjectType(ctx), }, }, } @@ -7227,9 +7227,9 @@ func (a LocalFileInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of LocalFileInfo in the Terraform plugin framework type +// ToObjectType returns the representation of LocalFileInfo in the Terraform plugin framework type // system. -func (a LocalFileInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a LocalFileInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -7261,9 +7261,9 @@ func (a LogAnalyticsInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogAnalyticsInfo in the Terraform plugin framework type +// ToObjectType returns the representation of LogAnalyticsInfo in the Terraform plugin framework type // system. -func (a LogAnalyticsInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogAnalyticsInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_analytics_primary_key": types.StringType, @@ -7298,9 +7298,9 @@ func (a LogSyncStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogSyncStatus in the Terraform plugin framework type +// ToObjectType returns the representation of LogSyncStatus in the Terraform plugin framework type // system. -func (a LogSyncStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogSyncStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_attempted": types.Int64Type, @@ -7342,9 +7342,9 @@ func (a MavenLibrary) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of MavenLibrary in the Terraform plugin framework type +// ToObjectType returns the representation of MavenLibrary in the Terraform plugin framework type // system. -func (a MavenLibrary) ToAttrType(ctx context.Context) types.ObjectType { +func (a MavenLibrary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "coordinates": types.StringType, @@ -7385,9 +7385,9 @@ func (a NodeInstanceType) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of NodeInstanceType in the Terraform plugin framework type +// ToObjectType returns the representation of NodeInstanceType in the Terraform plugin framework type // system. -func (a NodeInstanceType) ToAttrType(ctx context.Context) types.ObjectType { +func (a NodeInstanceType) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_type_id": types.StringType, @@ -7469,9 +7469,9 @@ func (a NodeType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of NodeType in the Terraform plugin framework type +// ToObjectType returns the representation of NodeType in the Terraform plugin framework type // system. -func (a NodeType) ToAttrType(ctx context.Context) types.ObjectType { +func (a NodeType) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "category": types.StringType, @@ -7485,10 +7485,10 @@ func (a NodeType) ToAttrType(ctx context.Context) types.ObjectType { "is_io_cache_enabled": types.BoolType, "memory_mb": types.Int64Type, "node_info": basetypes.ListType{ - ElemType: CloudProviderNodeInfo{}.ToAttrType(ctx), + ElemType: CloudProviderNodeInfo{}.ToObjectType(ctx), }, "node_instance_type": basetypes.ListType{ - ElemType: NodeInstanceType{}.ToAttrType(ctx), + ElemType: NodeInstanceType{}.ToObjectType(ctx), }, "node_type_id": types.StringType, "num_cores": types.Float64Type, @@ -7526,9 +7526,9 @@ func (a PendingInstanceError) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of PendingInstanceError in the Terraform plugin framework type +// ToObjectType returns the representation of PendingInstanceError in the Terraform plugin framework type // system. -func (a PendingInstanceError) ToAttrType(ctx context.Context) types.ObjectType { +func (a PendingInstanceError) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_id": types.StringType, @@ -7559,9 +7559,9 @@ func (a PermanentDeleteCluster) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of PermanentDeleteCluster in the Terraform plugin framework type +// ToObjectType returns the representation of PermanentDeleteCluster in the Terraform plugin framework type // system. -func (a PermanentDeleteCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermanentDeleteCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -7589,9 +7589,9 @@ func (a PermanentDeleteClusterResponse) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of PermanentDeleteClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PermanentDeleteClusterResponse in the Terraform plugin framework type // system. -func (a PermanentDeleteClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermanentDeleteClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7619,9 +7619,9 @@ func (a PinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of PinCluster in the Terraform plugin framework type +// ToObjectType returns the representation of PinCluster in the Terraform plugin framework type // system. -func (a PinCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a PinCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -7649,9 +7649,9 @@ func (a PinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of PinClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PinClusterResponse in the Terraform plugin framework type // system. -func (a PinClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PinClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7725,9 +7725,9 @@ func (a Policy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToAttrType returns the representation of Policy in the Terraform plugin framework type +// ToObjectType returns the representation of Policy in the Terraform plugin framework type // system. -func (a Policy) ToAttrType(ctx context.Context) types.ObjectType { +func (a Policy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at_timestamp": types.Int64Type, @@ -7736,7 +7736,7 @@ func (a Policy) ToAttrType(ctx context.Context) types.ObjectType { "description": types.StringType, "is_default": types.BoolType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToAttrType(ctx), + ElemType: Library{}.ToObjectType(ctx), }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, @@ -7778,9 +7778,9 @@ func (a PolicyFamily) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of PolicyFamily in the Terraform plugin framework type +// ToObjectType returns the representation of PolicyFamily in the Terraform plugin framework type // system. -func (a PolicyFamily) ToAttrType(ctx context.Context) types.ObjectType { +func (a PolicyFamily) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, @@ -7818,9 +7818,9 @@ func (a PythonPyPiLibrary) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of PythonPyPiLibrary in the Terraform plugin framework type +// ToObjectType returns the representation of PythonPyPiLibrary in the Terraform plugin framework type // system. -func (a PythonPyPiLibrary) ToAttrType(ctx context.Context) types.ObjectType { +func (a PythonPyPiLibrary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "package": types.StringType, @@ -7854,9 +7854,9 @@ func (a RCranLibrary) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of RCranLibrary in the Terraform plugin framework type +// ToObjectType returns the representation of RCranLibrary in the Terraform plugin framework type // system. -func (a RCranLibrary) ToAttrType(ctx context.Context) types.ObjectType { +func (a RCranLibrary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "package": types.StringType, @@ -7887,9 +7887,9 @@ func (a RemoveInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of RemoveInstanceProfile in the Terraform plugin framework type +// ToObjectType returns the representation of RemoveInstanceProfile in the Terraform plugin framework type // system. -func (a RemoveInstanceProfile) ToAttrType(ctx context.Context) types.ObjectType { +func (a RemoveInstanceProfile) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_profile_arn": types.StringType, @@ -7917,9 +7917,9 @@ func (a RemoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of RemoveResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RemoveResponse in the Terraform plugin framework type // system. -func (a RemoveResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RemoveResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7964,13 +7964,13 @@ func (a ResizeCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of ResizeCluster in the Terraform plugin framework type +// ToObjectType returns the representation of ResizeCluster in the Terraform plugin framework type // system. -func (a ResizeCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResizeCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "cluster_id": types.StringType, "num_workers": types.Int64Type, @@ -7998,9 +7998,9 @@ func (a ResizeClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ResizeClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ResizeClusterResponse in the Terraform plugin framework type // system. -func (a ResizeClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResizeClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8030,9 +8030,9 @@ func (a RestartCluster) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestartCluster in the Terraform plugin framework type +// ToObjectType returns the representation of RestartCluster in the Terraform plugin framework type // system. -func (a RestartCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestartCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -8061,9 +8061,9 @@ func (a RestartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestartClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RestartClusterResponse in the Terraform plugin framework type // system. -func (a RestartClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestartClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8113,9 +8113,9 @@ func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of Results in the Terraform plugin framework type +// ToObjectType returns the representation of Results in the Terraform plugin framework type // system. -func (a Results) ToAttrType(ctx context.Context) types.ObjectType { +func (a Results) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, @@ -8188,9 +8188,9 @@ func (a S3StorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of S3StorageInfo in the Terraform plugin framework type +// ToObjectType returns the representation of S3StorageInfo in the Terraform plugin framework type // system. -func (a S3StorageInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a S3StorageInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "canned_acl": types.StringType, @@ -8251,15 +8251,15 @@ func (a SparkNode) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of SparkNode in the Terraform plugin framework type +// ToObjectType returns the representation of SparkNode in the Terraform plugin framework type // system. -func (a SparkNode) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparkNode) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "host_private_ip": types.StringType, "instance_id": types.StringType, "node_aws_attributes": basetypes.ListType{ - ElemType: SparkNodeAwsAttributes{}.ToAttrType(ctx), + ElemType: SparkNodeAwsAttributes{}.ToObjectType(ctx), }, "node_id": types.StringType, "private_ip": types.StringType, @@ -8291,9 +8291,9 @@ func (a SparkNodeAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of SparkNodeAwsAttributes in the Terraform plugin framework type +// ToObjectType returns the representation of SparkNodeAwsAttributes in the Terraform plugin framework type // system. -func (a SparkNodeAwsAttributes) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparkNodeAwsAttributes) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_spot": types.BoolType, @@ -8329,9 +8329,9 @@ func (a SparkVersion) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of SparkVersion in the Terraform plugin framework type +// ToObjectType returns the representation of SparkVersion in the Terraform plugin framework type // system. -func (a SparkVersion) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparkVersion) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -8362,9 +8362,9 @@ func (a StartCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of StartCluster in the Terraform plugin framework type +// ToObjectType returns the representation of StartCluster in the Terraform plugin framework type // system. -func (a StartCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -8392,9 +8392,9 @@ func (a StartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of StartClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of StartClusterResponse in the Terraform plugin framework type // system. -func (a StartClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8429,9 +8429,9 @@ func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of TerminationReason in the Terraform plugin framework type +// ToObjectType returns the representation of TerminationReason in the Terraform plugin framework type // system. -func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { +func (a TerminationReason) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -8469,14 +8469,14 @@ func (a UninstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of UninstallLibraries in the Terraform plugin framework type +// ToObjectType returns the representation of UninstallLibraries in the Terraform plugin framework type // system. -func (a UninstallLibraries) ToAttrType(ctx context.Context) types.ObjectType { +func (a UninstallLibraries) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToAttrType(ctx), + ElemType: Library{}.ToObjectType(ctx), }, }, } @@ -8502,9 +8502,9 @@ func (a UninstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of UninstallLibrariesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UninstallLibrariesResponse in the Terraform plugin framework type // system. -func (a UninstallLibrariesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UninstallLibrariesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8532,9 +8532,9 @@ func (a UnpinCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of UnpinCluster in the Terraform plugin framework type +// ToObjectType returns the representation of UnpinCluster in the Terraform plugin framework type // system. -func (a UnpinCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a UnpinCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -8562,9 +8562,9 @@ func (a UnpinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of UnpinClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UnpinClusterResponse in the Terraform plugin framework type // system. -func (a UnpinClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UnpinClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8602,13 +8602,13 @@ func (a UpdateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of UpdateCluster in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCluster in the Terraform plugin framework type // system. -func (a UpdateCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster": basetypes.ListType{ - ElemType: UpdateClusterResource{}.ToAttrType(ctx), + ElemType: UpdateClusterResource{}.ToObjectType(ctx), }, "cluster_id": types.StringType, "update_mask": types.StringType, @@ -8794,23 +8794,23 @@ func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateClusterResource in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateClusterResource in the Terraform plugin framework type // system. -func (a UpdateClusterResource) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateClusterResource) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToAttrType(ctx), + ElemType: AutoScale{}.ToObjectType(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToAttrType(ctx), + ElemType: AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToAttrType(ctx), + ElemType: AzureAttributes{}.ToObjectType(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToAttrType(ctx), + ElemType: ClusterLogConf{}.ToObjectType(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -8818,17 +8818,17 @@ func (a UpdateClusterResource) ToAttrType(ctx context.Context) types.ObjectType }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToAttrType(ctx), + ElemType: DockerImage{}.ToObjectType(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToAttrType(ctx), + ElemType: GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToAttrType(ctx), + ElemType: InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -8847,7 +8847,7 @@ func (a UpdateClusterResource) ToAttrType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToAttrType(ctx), + ElemType: WorkloadType{}.ToObjectType(ctx), }, }, } @@ -8873,9 +8873,9 @@ func (a UpdateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateClusterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateClusterResponse in the Terraform plugin framework type // system. -func (a UpdateClusterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8901,9 +8901,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8931,9 +8931,9 @@ func (a VolumesStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of VolumesStorageInfo in the Terraform plugin framework type +// ToObjectType returns the representation of VolumesStorageInfo in the Terraform plugin framework type // system. -func (a VolumesStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a VolumesStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -8965,13 +8965,13 @@ func (a WorkloadType) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of WorkloadType in the Terraform plugin framework type +// ToObjectType returns the representation of WorkloadType in the Terraform plugin framework type // system. -func (a WorkloadType) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkloadType) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clients": basetypes.ListType{ - ElemType: ClientsTypes{}.ToAttrType(ctx), + ElemType: ClientsTypes{}.ToObjectType(ctx), }, }, } @@ -9000,9 +9000,9 @@ func (a WorkspaceStorageInfo) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of WorkspaceStorageInfo in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceStorageInfo in the Terraform plugin framework type // system. -func (a WorkspaceStorageInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 7f9565ac3d..517f0af730 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -45,13 +45,13 @@ func (a CreateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CreateDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateDashboardRequest in the Terraform plugin framework type // system. -func (a CreateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard": basetypes.ListType{ - ElemType: Dashboard{}.ToAttrType(ctx), + ElemType: Dashboard{}.ToObjectType(ctx), }, }, } @@ -84,14 +84,14 @@ func (a CreateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateScheduleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateScheduleRequest in the Terraform plugin framework type // system. -func (a CreateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule": basetypes.ListType{ - ElemType: Schedule{}.ToAttrType(ctx), + ElemType: Schedule{}.ToObjectType(ctx), }, }, } @@ -126,15 +126,15 @@ func (a CreateSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of CreateSubscriptionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateSubscriptionRequest in the Terraform plugin framework type // system. -func (a CreateSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateSubscriptionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule_id": types.StringType, "subscription": basetypes.ListType{ - ElemType: Subscription{}.ToAttrType(ctx), + ElemType: Subscription{}.ToObjectType(ctx), }, }, } @@ -170,9 +170,9 @@ func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of CronSchedule in the Terraform plugin framework type +// ToObjectType returns the representation of CronSchedule in the Terraform plugin framework type // system. -func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { +func (a CronSchedule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "quartz_cron_expression": types.StringType, @@ -234,9 +234,9 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of Dashboard in the Terraform plugin framework type +// ToObjectType returns the representation of Dashboard in the Terraform plugin framework type // system. -func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { +func (a Dashboard) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -281,9 +281,9 @@ func (a DeleteScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteScheduleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteScheduleRequest in the Terraform plugin framework type // system. -func (a DeleteScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -313,9 +313,9 @@ func (a DeleteScheduleResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteScheduleResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteScheduleResponse in the Terraform plugin framework type // system. -func (a DeleteScheduleResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteScheduleResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -351,9 +351,9 @@ func (a DeleteSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteSubscriptionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteSubscriptionRequest in the Terraform plugin framework type // system. -func (a DeleteSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteSubscriptionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -384,9 +384,9 @@ func (a DeleteSubscriptionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteSubscriptionResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteSubscriptionResponse in the Terraform plugin framework type // system. -func (a DeleteSubscriptionResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteSubscriptionResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -419,16 +419,16 @@ func (a GenieAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of GenieAttachment in the Terraform plugin framework type +// ToObjectType returns the representation of GenieAttachment in the Terraform plugin framework type // system. -func (a GenieAttachment) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieAttachment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query": basetypes.ListType{ - ElemType: QueryAttachment{}.ToAttrType(ctx), + ElemType: QueryAttachment{}.ToObjectType(ctx), }, "text": basetypes.ListType{ - ElemType: TextAttachment{}.ToAttrType(ctx), + ElemType: TextAttachment{}.ToObjectType(ctx), }, }, } @@ -466,9 +466,9 @@ func (a GenieConversation) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenieConversation in the Terraform plugin framework type +// ToObjectType returns the representation of GenieConversation in the Terraform plugin framework type // system. -func (a GenieConversation) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieConversation) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_timestamp": types.Int64Type, @@ -507,9 +507,9 @@ func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenieCreateConversationMessageRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenieCreateConversationMessageRequest in the Terraform plugin framework type // system. -func (a GenieCreateConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieCreateConversationMessageRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -546,9 +546,9 @@ func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenieExecuteMessageQueryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenieExecuteMessageQueryRequest in the Terraform plugin framework type // system. -func (a GenieExecuteMessageQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieExecuteMessageQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation_id": types.StringType, @@ -587,9 +587,9 @@ func (a GenieGetConversationMessageRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenieGetConversationMessageRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenieGetConversationMessageRequest in the Terraform plugin framework type // system. -func (a GenieGetConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieGetConversationMessageRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation_id": types.StringType, @@ -626,9 +626,9 @@ func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenieGetMessageQueryResultRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenieGetMessageQueryResultRequest in the Terraform plugin framework type // system. -func (a GenieGetMessageQueryResultRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieGetMessageQueryResultRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation_id": types.StringType, @@ -663,13 +663,13 @@ func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of GenieGetMessageQueryResultResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GenieGetMessageQueryResultResponse in the Terraform plugin framework type // system. -func (a GenieGetMessageQueryResultResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieGetMessageQueryResultResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statement_response": basetypes.ListType{ - ElemType: sql_tf.StatementResponse{}.ToAttrType(ctx), + ElemType: sql_tf.StatementResponse{}.ToObjectType(ctx), }, }, } @@ -736,24 +736,24 @@ func (a GenieMessage) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of GenieMessage in the Terraform plugin framework type +// ToObjectType returns the representation of GenieMessage in the Terraform plugin framework type // system. -func (a GenieMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attachments": basetypes.ListType{ - ElemType: GenieAttachment{}.ToAttrType(ctx), + ElemType: GenieAttachment{}.ToObjectType(ctx), }, "content": types.StringType, "conversation_id": types.StringType, "created_timestamp": types.Int64Type, "error": basetypes.ListType{ - ElemType: MessageError{}.ToAttrType(ctx), + ElemType: MessageError{}.ToObjectType(ctx), }, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "query_result": basetypes.ListType{ - ElemType: Result{}.ToAttrType(ctx), + ElemType: Result{}.ToObjectType(ctx), }, "space_id": types.StringType, "status": types.StringType, @@ -787,9 +787,9 @@ func (a GenieStartConversationMessageRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenieStartConversationMessageRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GenieStartConversationMessageRequest in the Terraform plugin framework type // system. -func (a GenieStartConversationMessageRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieStartConversationMessageRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -828,17 +828,17 @@ func (a GenieStartConversationResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of GenieStartConversationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GenieStartConversationResponse in the Terraform plugin framework type // system. -func (a GenieStartConversationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenieStartConversationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation": basetypes.ListType{ - ElemType: GenieConversation{}.ToAttrType(ctx), + ElemType: GenieConversation{}.ToObjectType(ctx), }, "conversation_id": types.StringType, "message": basetypes.ListType{ - ElemType: GenieMessage{}.ToAttrType(ctx), + ElemType: GenieMessage{}.ToObjectType(ctx), }, "message_id": types.StringType, }, @@ -868,9 +868,9 @@ func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDashboardRequest in the Terraform plugin framework type // system. -func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -901,9 +901,9 @@ func (a GetPublishedDashboardRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPublishedDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPublishedDashboardRequest in the Terraform plugin framework type // system. -func (a GetPublishedDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPublishedDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -936,9 +936,9 @@ func (a GetScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetScheduleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetScheduleRequest in the Terraform plugin framework type // system. -func (a GetScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -974,9 +974,9 @@ func (a GetSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetSubscriptionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetSubscriptionRequest in the Terraform plugin framework type // system. -func (a GetSubscriptionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetSubscriptionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1017,9 +1017,9 @@ func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListDashboardsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListDashboardsRequest in the Terraform plugin framework type // system. -func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListDashboardsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -1056,13 +1056,13 @@ func (a ListDashboardsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ListDashboardsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListDashboardsResponse in the Terraform plugin framework type // system. -func (a ListDashboardsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListDashboardsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboards": basetypes.ListType{ - ElemType: Dashboard{}.ToAttrType(ctx), + ElemType: Dashboard{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -1097,9 +1097,9 @@ func (a ListSchedulesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSchedulesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSchedulesRequest in the Terraform plugin framework type // system. -func (a ListSchedulesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSchedulesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1137,14 +1137,14 @@ func (a ListSchedulesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListSchedulesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListSchedulesResponse in the Terraform plugin framework type // system. -func (a ListSchedulesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSchedulesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "schedules": basetypes.ListType{ - ElemType: Schedule{}.ToAttrType(ctx), + ElemType: Schedule{}.ToObjectType(ctx), }, }, } @@ -1180,9 +1180,9 @@ func (a ListSubscriptionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSubscriptionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSubscriptionsRequest in the Terraform plugin framework type // system. -func (a ListSubscriptionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSubscriptionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1221,14 +1221,14 @@ func (a ListSubscriptionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ListSubscriptionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListSubscriptionsResponse in the Terraform plugin framework type // system. -func (a ListSubscriptionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSubscriptionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "subscriptions": basetypes.ListType{ - ElemType: Subscription{}.ToAttrType(ctx), + ElemType: Subscription{}.ToObjectType(ctx), }, }, } @@ -1257,9 +1257,9 @@ func (a MessageError) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of MessageError in the Terraform plugin framework type +// ToObjectType returns the representation of MessageError in the Terraform plugin framework type // system. -func (a MessageError) ToAttrType(ctx context.Context) types.ObjectType { +func (a MessageError) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": types.StringType, @@ -1295,9 +1295,9 @@ func (a MigrateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of MigrateDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of MigrateDashboardRequest in the Terraform plugin framework type // system. -func (a MigrateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a MigrateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -1336,9 +1336,9 @@ func (a PublishRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of PublishRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PublishRequest in the Terraform plugin framework type // system. -func (a PublishRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PublishRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1376,9 +1376,9 @@ func (a PublishedDashboard) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of PublishedDashboard in the Terraform plugin framework type +// ToObjectType returns the representation of PublishedDashboard in the Terraform plugin framework type // system. -func (a PublishedDashboard) ToAttrType(ctx context.Context) types.ObjectType { +func (a PublishedDashboard) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -1425,9 +1425,9 @@ func (a QueryAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of QueryAttachment in the Terraform plugin framework type +// ToObjectType returns the representation of QueryAttachment in the Terraform plugin framework type // system. -func (a QueryAttachment) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryAttachment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1469,9 +1469,9 @@ func (a Result) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Result in the Terraform plugin framework type +// ToObjectType returns the representation of Result in the Terraform plugin framework type // system. -func (a Result) ToAttrType(ctx context.Context) types.ObjectType { +func (a Result) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_truncated": types.BoolType, @@ -1524,14 +1524,14 @@ func (a Schedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of Schedule in the Terraform plugin framework type +// ToObjectType returns the representation of Schedule in the Terraform plugin framework type // system. -func (a Schedule) ToAttrType(ctx context.Context) types.ObjectType { +func (a Schedule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, "cron_schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToAttrType(ctx), + ElemType: CronSchedule{}.ToObjectType(ctx), }, "dashboard_id": types.StringType, "display_name": types.StringType, @@ -1573,16 +1573,16 @@ func (a Subscriber) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of Subscriber in the Terraform plugin framework type +// ToObjectType returns the representation of Subscriber in the Terraform plugin framework type // system. -func (a Subscriber) ToAttrType(ctx context.Context) types.ObjectType { +func (a Subscriber) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_subscriber": basetypes.ListType{ - ElemType: SubscriptionSubscriberDestination{}.ToAttrType(ctx), + ElemType: SubscriptionSubscriberDestination{}.ToObjectType(ctx), }, "user_subscriber": basetypes.ListType{ - ElemType: SubscriptionSubscriberUser{}.ToAttrType(ctx), + ElemType: SubscriptionSubscriberUser{}.ToObjectType(ctx), }, }, } @@ -1630,9 +1630,9 @@ func (a Subscription) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of Subscription in the Terraform plugin framework type +// ToObjectType returns the representation of Subscription in the Terraform plugin framework type // system. -func (a Subscription) ToAttrType(ctx context.Context) types.ObjectType { +func (a Subscription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -1641,7 +1641,7 @@ func (a Subscription) ToAttrType(ctx context.Context) types.ObjectType { "etag": types.StringType, "schedule_id": types.StringType, "subscriber": basetypes.ListType{ - ElemType: Subscriber{}.ToAttrType(ctx), + ElemType: Subscriber{}.ToObjectType(ctx), }, "subscription_id": types.StringType, "update_time": types.StringType, @@ -1672,9 +1672,9 @@ func (a SubscriptionSubscriberDestination) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of SubscriptionSubscriberDestination in the Terraform plugin framework type +// ToObjectType returns the representation of SubscriptionSubscriberDestination in the Terraform plugin framework type // system. -func (a SubscriptionSubscriberDestination) ToAttrType(ctx context.Context) types.ObjectType { +func (a SubscriptionSubscriberDestination) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_id": types.StringType, @@ -1704,9 +1704,9 @@ func (a SubscriptionSubscriberUser) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of SubscriptionSubscriberUser in the Terraform plugin framework type +// ToObjectType returns the representation of SubscriptionSubscriberUser in the Terraform plugin framework type // system. -func (a SubscriptionSubscriberUser) ToAttrType(ctx context.Context) types.ObjectType { +func (a SubscriptionSubscriberUser) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "user_id": types.Int64Type, @@ -1738,9 +1738,9 @@ func (a TextAttachment) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of TextAttachment in the Terraform plugin framework type +// ToObjectType returns the representation of TextAttachment in the Terraform plugin framework type // system. -func (a TextAttachment) ToAttrType(ctx context.Context) types.ObjectType { +func (a TextAttachment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -1772,9 +1772,9 @@ func (a TrashDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of TrashDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TrashDashboardRequest in the Terraform plugin framework type // system. -func (a TrashDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TrashDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1802,9 +1802,9 @@ func (a TrashDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of TrashDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of TrashDashboardResponse in the Terraform plugin framework type // system. -func (a TrashDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a TrashDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1833,9 +1833,9 @@ func (a UnpublishDashboardRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of UnpublishDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UnpublishDashboardRequest in the Terraform plugin framework type // system. -func (a UnpublishDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UnpublishDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1863,9 +1863,9 @@ func (a UnpublishDashboardResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of UnpublishDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UnpublishDashboardResponse in the Terraform plugin framework type // system. -func (a UnpublishDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UnpublishDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1897,13 +1897,13 @@ func (a UpdateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of UpdateDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateDashboardRequest in the Terraform plugin framework type // system. -func (a UpdateDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard": basetypes.ListType{ - ElemType: Dashboard{}.ToAttrType(ctx), + ElemType: Dashboard{}.ToObjectType(ctx), }, "dashboard_id": types.StringType, }, @@ -1939,14 +1939,14 @@ func (a UpdateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateScheduleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateScheduleRequest in the Terraform plugin framework type // system. -func (a UpdateScheduleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule": basetypes.ListType{ - ElemType: Schedule{}.ToAttrType(ctx), + ElemType: Schedule{}.ToObjectType(ctx), }, "schedule_id": types.StringType, }, diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index b4dae86850..9c328c1474 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -45,9 +45,9 @@ func (a AddBlock) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of AddBlock in the Terraform plugin framework type +// ToObjectType returns the representation of AddBlock in the Terraform plugin framework type // system. -func (a AddBlock) ToAttrType(ctx context.Context) types.ObjectType { +func (a AddBlock) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data": types.StringType, @@ -76,9 +76,9 @@ func (a AddBlockResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of AddBlockResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AddBlockResponse in the Terraform plugin framework type // system. -func (a AddBlockResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AddBlockResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -106,9 +106,9 @@ func (a Close) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Close in the Terraform plugin framework type +// ToObjectType returns the representation of Close in the Terraform plugin framework type // system. -func (a Close) ToAttrType(ctx context.Context) types.ObjectType { +func (a Close) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "handle": types.Int64Type, @@ -136,9 +136,9 @@ func (a CloseResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of CloseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CloseResponse in the Terraform plugin framework type // system. -func (a CloseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CloseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -168,9 +168,9 @@ func (a Create) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Create in the Terraform plugin framework type +// ToObjectType returns the representation of Create in the Terraform plugin framework type // system. -func (a Create) ToAttrType(ctx context.Context) types.ObjectType { +func (a Create) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "overwrite": types.BoolType, @@ -202,9 +202,9 @@ func (a CreateDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateDirectoryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateDirectoryRequest in the Terraform plugin framework type // system. -func (a CreateDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateDirectoryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -232,9 +232,9 @@ func (a CreateDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateDirectoryResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateDirectoryResponse in the Terraform plugin framework type // system. -func (a CreateDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateDirectoryResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -263,9 +263,9 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type // system. -func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "handle": types.Int64Type, @@ -299,9 +299,9 @@ func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Delete in the Terraform plugin framework type +// ToObjectType returns the representation of Delete in the Terraform plugin framework type // system. -func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { +func (a Delete) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -333,9 +333,9 @@ func (a DeleteDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDirectoryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDirectoryRequest in the Terraform plugin framework type // system. -func (a DeleteDirectoryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDirectoryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -363,9 +363,9 @@ func (a DeleteDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDirectoryResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDirectoryResponse in the Terraform plugin framework type // system. -func (a DeleteDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDirectoryResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -394,9 +394,9 @@ func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteFileRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteFileRequest in the Terraform plugin framework type // system. -func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteFileRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_path": types.StringType, @@ -424,9 +424,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -463,9 +463,9 @@ func (a DirectoryEntry) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DirectoryEntry in the Terraform plugin framework type +// ToObjectType returns the representation of DirectoryEntry in the Terraform plugin framework type // system. -func (a DirectoryEntry) ToAttrType(ctx context.Context) types.ObjectType { +func (a DirectoryEntry) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_size": types.Int64Type, @@ -500,9 +500,9 @@ func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DownloadRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DownloadRequest in the Terraform plugin framework type // system. -func (a DownloadRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DownloadRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_path": types.StringType, @@ -537,9 +537,9 @@ func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of DownloadResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DownloadResponse in the Terraform plugin framework type // system. -func (a DownloadResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DownloadResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content-length": types.Int64Type, @@ -578,9 +578,9 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of FileInfo in the Terraform plugin framework type +// ToObjectType returns the representation of FileInfo in the Terraform plugin framework type // system. -func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a FileInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_size": types.Int64Type, @@ -614,9 +614,9 @@ func (a GetDirectoryMetadataRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDirectoryMetadataRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDirectoryMetadataRequest in the Terraform plugin framework type // system. -func (a GetDirectoryMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDirectoryMetadataRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -644,9 +644,9 @@ func (a GetDirectoryMetadataResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDirectoryMetadataResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetDirectoryMetadataResponse in the Terraform plugin framework type // system. -func (a GetDirectoryMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDirectoryMetadataResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -675,9 +675,9 @@ func (a GetMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetMetadataRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetMetadataRequest in the Terraform plugin framework type // system. -func (a GetMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetMetadataRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_path": types.StringType, @@ -710,9 +710,9 @@ func (a GetMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetMetadataResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetMetadataResponse in the Terraform plugin framework type // system. -func (a GetMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetMetadataResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content-length": types.Int64Type, @@ -746,9 +746,9 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStatusRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStatusRequest in the Terraform plugin framework type // system. -func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -780,9 +780,9 @@ func (a ListDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListDbfsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListDbfsRequest in the Terraform plugin framework type // system. -func (a ListDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -833,9 +833,9 @@ func (a ListDirectoryContentsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListDirectoryContentsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListDirectoryContentsRequest in the Terraform plugin framework type // system. -func (a ListDirectoryContentsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListDirectoryContentsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -871,13 +871,13 @@ func (a ListDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListDirectoryResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListDirectoryResponse in the Terraform plugin framework type // system. -func (a ListDirectoryResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListDirectoryResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": basetypes.ListType{ - ElemType: DirectoryEntry{}.ToAttrType(ctx), + ElemType: DirectoryEntry{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -909,13 +909,13 @@ func (a ListStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListStatusResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListStatusResponse in the Terraform plugin framework type // system. -func (a ListStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "files": basetypes.ListType{ - ElemType: FileInfo{}.ToAttrType(ctx), + ElemType: FileInfo{}.ToObjectType(ctx), }, }, } @@ -943,9 +943,9 @@ func (a MkDirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of MkDirs in the Terraform plugin framework type +// ToObjectType returns the representation of MkDirs in the Terraform plugin framework type // system. -func (a MkDirs) ToAttrType(ctx context.Context) types.ObjectType { +func (a MkDirs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -973,9 +973,9 @@ func (a MkDirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of MkDirsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of MkDirsResponse in the Terraform plugin framework type // system. -func (a MkDirsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a MkDirsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1007,9 +1007,9 @@ func (a Move) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Move in the Terraform plugin framework type +// ToObjectType returns the representation of Move in the Terraform plugin framework type // system. -func (a Move) ToAttrType(ctx context.Context) types.ObjectType { +func (a Move) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_path": types.StringType, @@ -1038,9 +1038,9 @@ func (a MoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of MoveResponse in the Terraform plugin framework type +// ToObjectType returns the representation of MoveResponse in the Terraform plugin framework type // system. -func (a MoveResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a MoveResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1072,9 +1072,9 @@ func (a Put) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } -// ToAttrType returns the representation of Put in the Terraform plugin framework type +// ToObjectType returns the representation of Put in the Terraform plugin framework type // system. -func (a Put) ToAttrType(ctx context.Context) types.ObjectType { +func (a Put) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.StringType, @@ -1104,9 +1104,9 @@ func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of PutResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PutResponse in the Terraform plugin framework type // system. -func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1140,9 +1140,9 @@ func (a ReadDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ReadDbfsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ReadDbfsRequest in the Terraform plugin framework type // system. -func (a ReadDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReadDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "length": types.Int64Type, @@ -1178,9 +1178,9 @@ func (a ReadResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of ReadResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ReadResponse in the Terraform plugin framework type // system. -func (a ReadResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReadResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bytes_read": types.Int64Type, @@ -1215,9 +1215,9 @@ func (a UploadRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of UploadRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UploadRequest in the Terraform plugin framework type // system. -func (a UploadRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UploadRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.ObjectType{}, @@ -1247,9 +1247,9 @@ func (a UploadResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UploadResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UploadResponse in the Terraform plugin framework type // system. -func (a UploadResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UploadResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 93e0689d08..273094da12 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -47,9 +47,9 @@ func (a AccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of AccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of AccessControlRequest in the Terraform plugin framework type // system. -func (a AccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -92,13 +92,13 @@ func (a AccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of AccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AccessControlResponse in the Terraform plugin framework type // system. -func (a AccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: Permission{}.ToAttrType(ctx), + ElemType: Permission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -137,9 +137,9 @@ func (a ComplexValue) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of ComplexValue in the Terraform plugin framework type +// ToObjectType returns the representation of ComplexValue in the Terraform plugin framework type // system. -func (a ComplexValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a ComplexValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display": types.StringType, @@ -174,9 +174,9 @@ func (a DeleteAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountGroupRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountGroupRequest in the Terraform plugin framework type // system. -func (a DeleteAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -207,9 +207,9 @@ func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountServicePrincipalRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountServicePrincipalRequest in the Terraform plugin framework type // system. -func (a DeleteAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -240,9 +240,9 @@ func (a DeleteAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountUserRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountUserRequest in the Terraform plugin framework type // system. -func (a DeleteAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountUserRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -273,9 +273,9 @@ func (a DeleteGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteGroupRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteGroupRequest in the Terraform plugin framework type // system. -func (a DeleteGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -303,9 +303,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -334,9 +334,9 @@ func (a DeleteServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteServicePrincipalRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteServicePrincipalRequest in the Terraform plugin framework type // system. -func (a DeleteServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -367,9 +367,9 @@ func (a DeleteUserRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteUserRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteUserRequest in the Terraform plugin framework type // system. -func (a DeleteUserRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteUserRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -402,9 +402,9 @@ func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWorkspaceAssignmentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWorkspaceAssignmentRequest in the Terraform plugin framework type // system. -func (a DeleteWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWorkspaceAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal_id": types.Int64Type, @@ -433,9 +433,9 @@ func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWorkspacePermissionAssignmentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWorkspacePermissionAssignmentResponse in the Terraform plugin framework type // system. -func (a DeleteWorkspacePermissionAssignmentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWorkspacePermissionAssignmentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -464,9 +464,9 @@ func (a GetAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountGroupRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountGroupRequest in the Terraform plugin framework type // system. -func (a GetAccountGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -497,9 +497,9 @@ func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountServicePrincipalRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountServicePrincipalRequest in the Terraform plugin framework type // system. -func (a GetAccountServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -551,9 +551,9 @@ func (a GetAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountUserRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountUserRequest in the Terraform plugin framework type // system. -func (a GetAccountUserRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountUserRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -591,9 +591,9 @@ func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAssignableRolesForResourceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAssignableRolesForResourceRequest in the Terraform plugin framework type // system. -func (a GetAssignableRolesForResourceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAssignableRolesForResourceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resource": types.StringType, @@ -624,13 +624,13 @@ func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes(ctx context. } } -// ToAttrType returns the representation of GetAssignableRolesForResourceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetAssignableRolesForResourceResponse in the Terraform plugin framework type // system. -func (a GetAssignableRolesForResourceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAssignableRolesForResourceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "roles": basetypes.ListType{ - ElemType: Role{}.ToAttrType(ctx), + ElemType: Role{}.ToObjectType(ctx), }, }, } @@ -659,9 +659,9 @@ func (a GetGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetGroupRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetGroupRequest in the Terraform plugin framework type // system. -func (a GetGroupRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -693,13 +693,13 @@ func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Co } } -// ToAttrType returns the representation of GetPasswordPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetPasswordPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetPasswordPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPasswordPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: PasswordPermissionsDescription{}.ToAttrType(ctx), + ElemType: PasswordPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -730,9 +730,9 @@ func (a GetPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request_object_id": types.StringType, @@ -765,13 +765,13 @@ func (a GetPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of GetPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: PermissionsDescription{}.ToAttrType(ctx), + ElemType: PermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -806,9 +806,9 @@ func (a GetPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPermissionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPermissionRequest in the Terraform plugin framework type // system. -func (a GetPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPermissionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request_object_id": types.StringType, @@ -849,9 +849,9 @@ func (a GetRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRuleSetRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRuleSetRequest in the Terraform plugin framework type // system. -func (a GetRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRuleSetRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -883,9 +883,9 @@ func (a GetServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetServicePrincipalRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetServicePrincipalRequest in the Terraform plugin framework type // system. -func (a GetServicePrincipalRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -937,9 +937,9 @@ func (a GetUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetUserRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetUserRequest in the Terraform plugin framework type // system. -func (a GetUserRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetUserRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -977,9 +977,9 @@ func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWorkspaceAssignmentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceAssignmentRequest in the Terraform plugin framework type // system. -func (a GetWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1013,9 +1013,9 @@ func (a GrantRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of GrantRule in the Terraform plugin framework type +// ToObjectType returns the representation of GrantRule in the Terraform plugin framework type // system. -func (a GrantRule) ToAttrType(ctx context.Context) types.ObjectType { +func (a GrantRule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principals": basetypes.ListType{ @@ -1074,28 +1074,28 @@ func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of Group in the Terraform plugin framework type +// ToObjectType returns the representation of Group in the Terraform plugin framework type // system. -func (a Group) ToAttrType(ctx context.Context) types.ObjectType { +func (a Group) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "displayName": types.StringType, "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "externalId": types.StringType, "groups": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "id": types.StringType, "members": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "meta": basetypes.ListType{ - ElemType: ResourceMeta{}.ToAttrType(ctx), + ElemType: ResourceMeta{}.ToObjectType(ctx), }, "roles": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1145,9 +1145,9 @@ func (a ListAccountGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAccountGroupsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountGroupsRequest in the Terraform plugin framework type // system. -func (a ListAccountGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountGroupsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1202,9 +1202,9 @@ func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAccountServicePrincipalsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountServicePrincipalsRequest in the Terraform plugin framework type // system. -func (a ListAccountServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountServicePrincipalsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1260,9 +1260,9 @@ func (a ListAccountUsersRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAccountUsersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAccountUsersRequest in the Terraform plugin framework type // system. -func (a ListAccountUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAccountUsersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1317,9 +1317,9 @@ func (a ListGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListGroupsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListGroupsRequest in the Terraform plugin framework type // system. -func (a ListGroupsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListGroupsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1367,14 +1367,14 @@ func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListGroupsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListGroupsResponse in the Terraform plugin framework type // system. -func (a ListGroupsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListGroupsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ - ElemType: Group{}.ToAttrType(ctx), + ElemType: Group{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1419,14 +1419,14 @@ func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListServicePrincipalResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListServicePrincipalResponse in the Terraform plugin framework type // system. -func (a ListServicePrincipalResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListServicePrincipalResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ - ElemType: ServicePrincipal{}.ToAttrType(ctx), + ElemType: ServicePrincipal{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1478,9 +1478,9 @@ func (a ListServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListServicePrincipalsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListServicePrincipalsRequest in the Terraform plugin framework type // system. -func (a ListServicePrincipalsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListServicePrincipalsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1536,9 +1536,9 @@ func (a ListUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListUsersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListUsersRequest in the Terraform plugin framework type // system. -func (a ListUsersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListUsersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1586,14 +1586,14 @@ func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ListUsersResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListUsersResponse in the Terraform plugin framework type // system. -func (a ListUsersResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListUsersResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ - ElemType: User{}.ToAttrType(ctx), + ElemType: User{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1627,9 +1627,9 @@ func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListWorkspaceAssignmentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListWorkspaceAssignmentRequest in the Terraform plugin framework type // system. -func (a ListWorkspaceAssignmentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListWorkspaceAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1666,9 +1666,9 @@ func (a MigratePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of MigratePermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of MigratePermissionsRequest in the Terraform plugin framework type // system. -func (a MigratePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a MigratePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "from_workspace_group_name": types.StringType, @@ -1701,9 +1701,9 @@ func (a MigratePermissionsResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of MigratePermissionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of MigratePermissionsResponse in the Terraform plugin framework type // system. -func (a MigratePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a MigratePermissionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permissions_migrated": types.Int64Type, @@ -1735,9 +1735,9 @@ func (a Name) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Name in the Terraform plugin framework type +// ToObjectType returns the representation of Name in the Terraform plugin framework type // system. -func (a Name) ToAttrType(ctx context.Context) types.ObjectType { +func (a Name) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "familyName": types.StringType, @@ -1773,13 +1773,13 @@ func (a ObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ObjectPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of ObjectPermissions in the Terraform plugin framework type // system. -func (a ObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a ObjectPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControlResponse{}.ToAttrType(ctx), + ElemType: AccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1817,14 +1817,14 @@ func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of PartialUpdate in the Terraform plugin framework type +// ToObjectType returns the representation of PartialUpdate in the Terraform plugin framework type // system. -func (a PartialUpdate) ToAttrType(ctx context.Context) types.ObjectType { +func (a PartialUpdate) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "Operations": basetypes.ListType{ - ElemType: Patch{}.ToAttrType(ctx), + ElemType: Patch{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1861,9 +1861,9 @@ func (a PasswordAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of PasswordAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PasswordAccessControlRequest in the Terraform plugin framework type // system. -func (a PasswordAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PasswordAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1906,13 +1906,13 @@ func (a PasswordAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of PasswordAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PasswordAccessControlResponse in the Terraform plugin framework type // system. -func (a PasswordAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PasswordAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: PasswordPermission{}.ToAttrType(ctx), + ElemType: PasswordPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1949,9 +1949,9 @@ func (a PasswordPermission) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of PasswordPermission in the Terraform plugin framework type +// ToObjectType returns the representation of PasswordPermission in the Terraform plugin framework type // system. -func (a PasswordPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a PasswordPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1990,13 +1990,13 @@ func (a PasswordPermissions) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of PasswordPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of PasswordPermissions in the Terraform plugin framework type // system. -func (a PasswordPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a PasswordPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PasswordAccessControlResponse{}.ToAttrType(ctx), + ElemType: PasswordAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2027,9 +2027,9 @@ func (a PasswordPermissionsDescription) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of PasswordPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of PasswordPermissionsDescription in the Terraform plugin framework type // system. -func (a PasswordPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a PasswordPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2061,13 +2061,13 @@ func (a PasswordPermissionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of PasswordPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PasswordPermissionsRequest in the Terraform plugin framework type // system. -func (a PasswordPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PasswordPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PasswordAccessControlRequest{}.ToAttrType(ctx), + ElemType: PasswordAccessControlRequest{}.ToObjectType(ctx), }, }, } @@ -2099,9 +2099,9 @@ func (a Patch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Patch in the Terraform plugin framework type +// ToObjectType returns the representation of Patch in the Terraform plugin framework type // system. -func (a Patch) ToAttrType(ctx context.Context) types.ObjectType { +func (a Patch) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "op": types.StringType, @@ -2131,9 +2131,9 @@ func (a PatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of PatchResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PatchResponse in the Terraform plugin framework type // system. -func (a PatchResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PatchResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2166,9 +2166,9 @@ func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of Permission in the Terraform plugin framework type +// ToObjectType returns the representation of Permission in the Terraform plugin framework type // system. -func (a Permission) ToAttrType(ctx context.Context) types.ObjectType { +func (a Permission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2211,9 +2211,9 @@ func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of PermissionAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionAssignment in the Terraform plugin framework type // system. -func (a PermissionAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": types.StringType, @@ -2221,7 +2221,7 @@ func (a PermissionAssignment) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "principal": basetypes.ListType{ - ElemType: PrincipalOutput{}.ToAttrType(ctx), + ElemType: PrincipalOutput{}.ToObjectType(ctx), }, }, } @@ -2251,13 +2251,13 @@ func (a PermissionAssignments) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of PermissionAssignments in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionAssignments in the Terraform plugin framework type // system. -func (a PermissionAssignments) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionAssignments) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_assignments": basetypes.ListType{ - ElemType: PermissionAssignment{}.ToAttrType(ctx), + ElemType: PermissionAssignment{}.ToObjectType(ctx), }, }, } @@ -2287,9 +2287,9 @@ func (a PermissionOutput) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of PermissionOutput in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionOutput in the Terraform plugin framework type // system. -func (a PermissionOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2321,9 +2321,9 @@ func (a PermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of PermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionsDescription in the Terraform plugin framework type // system. -func (a PermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2363,13 +2363,13 @@ func (a PermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of PermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PermissionsRequest in the Terraform plugin framework type // system. -func (a PermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControlRequest{}.ToAttrType(ctx), + ElemType: AccessControlRequest{}.ToObjectType(ctx), }, "request_object_id": types.StringType, "request_object_type": types.StringType, @@ -2409,9 +2409,9 @@ func (a PrincipalOutput) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of PrincipalOutput in the Terraform plugin framework type +// ToObjectType returns the representation of PrincipalOutput in the Terraform plugin framework type // system. -func (a PrincipalOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a PrincipalOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -2446,9 +2446,9 @@ func (a ResourceMeta) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of ResourceMeta in the Terraform plugin framework type +// ToObjectType returns the representation of ResourceMeta in the Terraform plugin framework type // system. -func (a ResourceMeta) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResourceMeta) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resourceType": types.StringType, @@ -2478,9 +2478,9 @@ func (a Role) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Role in the Terraform plugin framework type +// ToObjectType returns the representation of Role in the Terraform plugin framework type // system. -func (a Role) ToAttrType(ctx context.Context) types.ObjectType { +func (a Role) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2516,14 +2516,14 @@ func (a RuleSetResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of RuleSetResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RuleSetResponse in the Terraform plugin framework type // system. -func (a RuleSetResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RuleSetResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "grant_rules": basetypes.ListType{ - ElemType: GrantRule{}.ToAttrType(ctx), + ElemType: GrantRule{}.ToObjectType(ctx), }, "name": types.StringType, }, @@ -2560,14 +2560,14 @@ func (a RuleSetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of RuleSetUpdateRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RuleSetUpdateRequest in the Terraform plugin framework type // system. -func (a RuleSetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RuleSetUpdateRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "grant_rules": basetypes.ListType{ - ElemType: GrantRule{}.ToAttrType(ctx), + ElemType: GrantRule{}.ToObjectType(ctx), }, "name": types.StringType, }, @@ -2620,24 +2620,24 @@ func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ServicePrincipal in the Terraform plugin framework type +// ToObjectType returns the representation of ServicePrincipal in the Terraform plugin framework type // system. -func (a ServicePrincipal) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServicePrincipal) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active": types.BoolType, "applicationId": types.StringType, "displayName": types.StringType, "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "externalId": types.StringType, "groups": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "id": types.StringType, "roles": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -2666,9 +2666,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2700,14 +2700,14 @@ func (a UpdateRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of UpdateRuleSetRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRuleSetRequest in the Terraform plugin framework type // system. -func (a UpdateRuleSetRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRuleSetRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "rule_set": basetypes.ListType{ - ElemType: RuleSetUpdateRequest{}.ToAttrType(ctx), + ElemType: RuleSetUpdateRequest{}.ToObjectType(ctx), }, }, } @@ -2746,9 +2746,9 @@ func (a UpdateWorkspaceAssignments) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of UpdateWorkspaceAssignments in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateWorkspaceAssignments in the Terraform plugin framework type // system. -func (a UpdateWorkspaceAssignments) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateWorkspaceAssignments) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permissions": basetypes.ListType{ @@ -2818,29 +2818,29 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of User in the Terraform plugin framework type +// ToObjectType returns the representation of User in the Terraform plugin framework type // system. -func (a User) ToAttrType(ctx context.Context) types.ObjectType { +func (a User) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active": types.BoolType, "displayName": types.StringType, "emails": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "externalId": types.StringType, "groups": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "id": types.StringType, "name": basetypes.ListType{ - ElemType: Name{}.ToAttrType(ctx), + ElemType: Name{}.ToObjectType(ctx), }, "roles": basetypes.ListType{ - ElemType: ComplexValue{}.ToAttrType(ctx), + ElemType: ComplexValue{}.ToObjectType(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -2874,13 +2874,13 @@ func (a WorkspacePermissions) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of WorkspacePermissions in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspacePermissions in the Terraform plugin framework type // system. -func (a WorkspacePermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspacePermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permissions": basetypes.ListType{ - ElemType: PermissionOutput{}.ToAttrType(ctx), + ElemType: PermissionOutput{}.ToObjectType(ctx), }, }, } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 67a405aa2d..8fe91bb525 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -61,9 +61,9 @@ func (a BaseJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of BaseJob in the Terraform plugin framework type +// ToObjectType returns the representation of BaseJob in the Terraform plugin framework type // system. -func (a BaseJob) ToAttrType(ctx context.Context) types.ObjectType { +func (a BaseJob) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_time": types.Int64Type, @@ -71,7 +71,7 @@ func (a BaseJob) ToAttrType(ctx context.Context) types.ObjectType { "effective_budget_policy_id": types.StringType, "job_id": types.Int64Type, "settings": basetypes.ListType{ - ElemType: JobSettings{}.ToAttrType(ctx), + ElemType: JobSettings{}.ToObjectType(ctx), }, }, } @@ -237,42 +237,42 @@ func (a BaseRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of BaseRun in the Terraform plugin framework type +// ToObjectType returns the representation of BaseRun in the Terraform plugin framework type // system. -func (a BaseRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a BaseRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.ToAttrType(ctx), + ElemType: ClusterInstance{}.ToObjectType(ctx), }, "cluster_spec": basetypes.ListType{ - ElemType: ClusterSpec{}.ToAttrType(ctx), + ElemType: ClusterSpec{}.ToObjectType(ctx), }, "creator_user_name": types.StringType, "description": types.StringType, "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToAttrType(ctx), + ElemType: GitSource{}.ToObjectType(ctx), }, "job_clusters": basetypes.ListType{ - ElemType: JobCluster{}.ToAttrType(ctx), + ElemType: JobCluster{}.ToObjectType(ctx), }, "job_id": types.Int64Type, "job_parameters": basetypes.ListType{ - ElemType: JobParameter{}.ToAttrType(ctx), + ElemType: JobParameter{}.ToObjectType(ctx), }, "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ - ElemType: RunParameters{}.ToAttrType(ctx), + ElemType: RunParameters{}.ToObjectType(ctx), }, "queue_duration": types.Int64Type, "repair_history": basetypes.ListType{ - ElemType: RepairHistoryItem{}.ToAttrType(ctx), + ElemType: RepairHistoryItem{}.ToObjectType(ctx), }, "run_duration": types.Int64Type, "run_id": types.Int64Type, @@ -280,22 +280,22 @@ func (a BaseRun) ToAttrType(ctx context.Context) types.ObjectType { "run_page_url": types.StringType, "run_type": types.StringType, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToAttrType(ctx), + ElemType: CronSchedule{}.ToObjectType(ctx), }, "setup_duration": types.Int64Type, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToAttrType(ctx), + ElemType: RunState{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToAttrType(ctx), + ElemType: RunStatus{}.ToObjectType(ctx), }, "tasks": basetypes.ListType{ - ElemType: RunTask{}.ToAttrType(ctx), + ElemType: RunTask{}.ToObjectType(ctx), }, "trigger": types.StringType, "trigger_info": basetypes.ListType{ - ElemType: TriggerInfo{}.ToAttrType(ctx), + ElemType: TriggerInfo{}.ToObjectType(ctx), }, }, } @@ -326,9 +326,9 @@ func (a CancelAllRuns) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelAllRuns in the Terraform plugin framework type +// ToObjectType returns the representation of CancelAllRuns in the Terraform plugin framework type // system. -func (a CancelAllRuns) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelAllRuns) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_queued_runs": types.BoolType, @@ -357,9 +357,9 @@ func (a CancelAllRunsResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelAllRunsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CancelAllRunsResponse in the Terraform plugin framework type // system. -func (a CancelAllRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelAllRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -387,9 +387,9 @@ func (a CancelRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelRun in the Terraform plugin framework type +// ToObjectType returns the representation of CancelRun in the Terraform plugin framework type // system. -func (a CancelRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -417,9 +417,9 @@ func (a CancelRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CancelRunResponse in the Terraform plugin framework type // system. -func (a CancelRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -463,9 +463,9 @@ func (a ClusterInstance) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterInstance in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterInstance in the Terraform plugin framework type // system. -func (a ClusterInstance) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterInstance) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -511,18 +511,18 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of ClusterSpec in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterSpec in the Terraform plugin framework type // system. -func (a ClusterSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "existing_cluster_id": types.StringType, "job_cluster_key": types.StringType, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToAttrType(ctx), + ElemType: compute_tf.Library{}.ToObjectType(ctx), }, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), }, }, } @@ -565,9 +565,9 @@ func (a ConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ConditionTask in the Terraform plugin framework type +// ToObjectType returns the representation of ConditionTask in the Terraform plugin framework type // system. -func (a ConditionTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a ConditionTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "left": types.StringType, @@ -600,9 +600,9 @@ func (a Continuous) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of Continuous in the Terraform plugin framework type +// ToObjectType returns the representation of Continuous in the Terraform plugin framework type // system. -func (a Continuous) ToAttrType(ctx context.Context) types.ObjectType { +func (a Continuous) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pause_status": types.StringType, @@ -751,68 +751,68 @@ func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of CreateJob in the Terraform plugin framework type +// ToObjectType returns the representation of CreateJob in the Terraform plugin framework type // system. -func (a CreateJob) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateJob) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.ToAttrType(ctx), + ElemType: JobAccessControlRequest{}.ToObjectType(ctx), }, "budget_policy_id": types.StringType, "continuous": basetypes.ListType{ - ElemType: Continuous{}.ToAttrType(ctx), + ElemType: Continuous{}.ToObjectType(ctx), }, "deployment": basetypes.ListType{ - ElemType: JobDeployment{}.ToAttrType(ctx), + ElemType: JobDeployment{}.ToObjectType(ctx), }, "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToAttrType(ctx), + ElemType: JobEmailNotifications{}.ToObjectType(ctx), }, "environment": basetypes.ListType{ - ElemType: JobEnvironment{}.ToAttrType(ctx), + ElemType: JobEnvironment{}.ToObjectType(ctx), }, "format": types.StringType, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToAttrType(ctx), + ElemType: GitSource{}.ToObjectType(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToAttrType(ctx), + ElemType: JobsHealthRules{}.ToObjectType(ctx), }, "job_cluster": basetypes.ListType{ - ElemType: JobCluster{}.ToAttrType(ctx), + ElemType: JobCluster{}.ToObjectType(ctx), }, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.ToAttrType(ctx), + ElemType: JobNotificationSettings{}.ToObjectType(ctx), }, "parameter": basetypes.ListType{ - ElemType: JobParameterDefinition{}.ToAttrType(ctx), + ElemType: JobParameterDefinition{}.ToObjectType(ctx), }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToAttrType(ctx), + ElemType: QueueSettings{}.ToObjectType(ctx), }, "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.ToAttrType(ctx), + ElemType: JobRunAs{}.ToObjectType(ctx), }, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToAttrType(ctx), + ElemType: CronSchedule{}.ToObjectType(ctx), }, "tags": basetypes.MapType{ ElemType: types.StringType, }, "task": basetypes.ListType{ - ElemType: Task{}.ToAttrType(ctx), + ElemType: Task{}.ToObjectType(ctx), }, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ - ElemType: TriggerSettings{}.ToAttrType(ctx), + ElemType: TriggerSettings{}.ToObjectType(ctx), }, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToAttrType(ctx), + ElemType: WebhookNotifications{}.ToObjectType(ctx), }, }, } @@ -841,9 +841,9 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type // system. -func (a CreateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -883,9 +883,9 @@ func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of CronSchedule in the Terraform plugin framework type +// ToObjectType returns the representation of CronSchedule in the Terraform plugin framework type // system. -func (a CronSchedule) ToAttrType(ctx context.Context) types.ObjectType { +func (a CronSchedule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pause_status": types.StringType, @@ -924,9 +924,9 @@ func (a DbtOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of DbtOutput in the Terraform plugin framework type +// ToObjectType returns the representation of DbtOutput in the Terraform plugin framework type // system. -func (a DbtOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a DbtOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifacts_headers": basetypes.MapType{ @@ -993,9 +993,9 @@ func (a DbtTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of DbtTask in the Terraform plugin framework type +// ToObjectType returns the representation of DbtTask in the Terraform plugin framework type // system. -func (a DbtTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a DbtTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog": types.StringType, @@ -1033,9 +1033,9 @@ func (a DeleteJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteJob in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteJob in the Terraform plugin framework type // system. -func (a DeleteJob) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteJob) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1063,9 +1063,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1093,9 +1093,9 @@ func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRun in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRun in the Terraform plugin framework type // system. -func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -1123,9 +1123,9 @@ func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRunResponse in the Terraform plugin framework type // system. -func (a DeleteRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1166,9 +1166,9 @@ func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComple return map[string]reflect.Type{} } -// ToAttrType returns the representation of EnforcePolicyComplianceForJobResponseJobClusterSettingsChange in the Terraform plugin framework type +// ToObjectType returns the representation of EnforcePolicyComplianceForJobResponseJobClusterSettingsChange in the Terraform plugin framework type // system. -func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "field": types.StringType, @@ -1203,9 +1203,9 @@ func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of EnforcePolicyComplianceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of EnforcePolicyComplianceRequest in the Terraform plugin framework type // system. -func (a EnforcePolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnforcePolicyComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1251,17 +1251,17 @@ func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of EnforcePolicyComplianceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EnforcePolicyComplianceResponse in the Terraform plugin framework type // system. -func (a EnforcePolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnforcePolicyComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_changes": types.BoolType, "job_cluster_changes": basetypes.ListType{ - ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.ToAttrType(ctx), + ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.ToObjectType(ctx), }, "settings": basetypes.ListType{ - ElemType: JobSettings{}.ToAttrType(ctx), + ElemType: JobSettings{}.ToObjectType(ctx), }, }, } @@ -1296,13 +1296,13 @@ func (a ExportRunOutput) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of ExportRunOutput in the Terraform plugin framework type +// ToObjectType returns the representation of ExportRunOutput in the Terraform plugin framework type // system. -func (a ExportRunOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExportRunOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "views": basetypes.ListType{ - ElemType: ViewItem{}.ToAttrType(ctx), + ElemType: ViewItem{}.ToObjectType(ctx), }, }, } @@ -1333,9 +1333,9 @@ func (a ExportRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExportRunRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExportRunRequest in the Terraform plugin framework type // system. -func (a ExportRunRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExportRunRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -1376,9 +1376,9 @@ func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of FileArrivalTriggerConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of FileArrivalTriggerConfiguration in the Terraform plugin framework type // system. -func (a FileArrivalTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a FileArrivalTriggerConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "min_time_between_triggers_seconds": types.Int64Type, @@ -1415,16 +1415,16 @@ func (a ForEachStats) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ForEachStats in the Terraform plugin framework type +// ToObjectType returns the representation of ForEachStats in the Terraform plugin framework type // system. -func (a ForEachStats) ToAttrType(ctx context.Context) types.ObjectType { +func (a ForEachStats) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_message_stats": basetypes.ListType{ - ElemType: ForEachTaskErrorMessageStats{}.ToAttrType(ctx), + ElemType: ForEachTaskErrorMessageStats{}.ToObjectType(ctx), }, "task_run_stats": basetypes.ListType{ - ElemType: ForEachTaskTaskRunStats{}.ToAttrType(ctx), + ElemType: ForEachTaskTaskRunStats{}.ToObjectType(ctx), }, }, } @@ -1461,15 +1461,15 @@ func (a ForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of ForEachTask in the Terraform plugin framework type +// ToObjectType returns the representation of ForEachTask in the Terraform plugin framework type // system. -func (a ForEachTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a ForEachTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, "task": basetypes.ListType{ - ElemType: Task{}.ToAttrType(ctx), + ElemType: Task{}.ToObjectType(ctx), }, }, } @@ -1502,9 +1502,9 @@ func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ForEachTaskErrorMessageStats in the Terraform plugin framework type +// ToObjectType returns the representation of ForEachTaskErrorMessageStats in the Terraform plugin framework type // system. -func (a ForEachTaskErrorMessageStats) ToAttrType(ctx context.Context) types.ObjectType { +func (a ForEachTaskErrorMessageStats) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "count": types.Int64Type, @@ -1547,9 +1547,9 @@ func (a ForEachTaskTaskRunStats) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of ForEachTaskTaskRunStats in the Terraform plugin framework type +// ToObjectType returns the representation of ForEachTaskTaskRunStats in the Terraform plugin framework type // system. -func (a ForEachTaskTaskRunStats) ToAttrType(ctx context.Context) types.ObjectType { +func (a ForEachTaskTaskRunStats) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active_iterations": types.Int64Type, @@ -1585,9 +1585,9 @@ func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetJobPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetJobPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetJobPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetJobPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.StringType, @@ -1619,13 +1619,13 @@ func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of GetJobPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetJobPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetJobPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetJobPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: JobPermissionsDescription{}.ToAttrType(ctx), + ElemType: JobPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -1654,9 +1654,9 @@ func (a GetJobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetJobPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetJobPermissionsRequest in the Terraform plugin framework type // system. -func (a GetJobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetJobPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.StringType, @@ -1688,9 +1688,9 @@ func (a GetJobRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetJobRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetJobRequest in the Terraform plugin framework type // system. -func (a GetJobRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetJobRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1721,9 +1721,9 @@ func (a GetPolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPolicyComplianceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPolicyComplianceRequest in the Terraform plugin framework type // system. -func (a GetPolicyComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPolicyComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1764,9 +1764,9 @@ func (a GetPolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of GetPolicyComplianceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetPolicyComplianceResponse in the Terraform plugin framework type // system. -func (a GetPolicyComplianceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPolicyComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, @@ -1800,9 +1800,9 @@ func (a GetRunOutputRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRunOutputRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRunOutputRequest in the Terraform plugin framework type // system. -func (a GetRunOutputRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRunOutputRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -1841,9 +1841,9 @@ func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRunRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRunRequest in the Terraform plugin framework type // system. -func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRunRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_history": types.BoolType, @@ -1880,9 +1880,9 @@ func (a GitSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of GitSnapshot in the Terraform plugin framework type +// ToObjectType returns the representation of GitSnapshot in the Terraform plugin framework type // system. -func (a GitSnapshot) ToAttrType(ctx context.Context) types.ObjectType { +func (a GitSnapshot) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "used_commit": types.StringType, @@ -1943,21 +1943,21 @@ func (a GitSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of GitSource in the Terraform plugin framework type +// ToObjectType returns the representation of GitSource in the Terraform plugin framework type // system. -func (a GitSource) ToAttrType(ctx context.Context) types.ObjectType { +func (a GitSource) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, "commit": types.StringType, "git_provider": types.StringType, "git_snapshot": basetypes.ListType{ - ElemType: GitSnapshot{}.ToAttrType(ctx), + ElemType: GitSnapshot{}.ToObjectType(ctx), }, "tag": types.StringType, "url": types.StringType, "job_source": basetypes.ListType{ - ElemType: JobSource{}.ToAttrType(ctx), + ElemType: JobSource{}.ToObjectType(ctx), }, }, } @@ -2012,9 +2012,9 @@ func (a Job) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToAttrType returns the representation of Job in the Terraform plugin framework type +// ToObjectType returns the representation of Job in the Terraform plugin framework type // system. -func (a Job) ToAttrType(ctx context.Context) types.ObjectType { +func (a Job) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_time": types.Int64Type, @@ -2023,7 +2023,7 @@ func (a Job) ToAttrType(ctx context.Context) types.ObjectType { "job_id": types.Int64Type, "run_as_user_name": types.StringType, "settings": basetypes.ListType{ - ElemType: JobSettings{}.ToAttrType(ctx), + ElemType: JobSettings{}.ToObjectType(ctx), }, }, } @@ -2057,9 +2057,9 @@ func (a JobAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of JobAccessControlRequest in the Terraform plugin framework type // system. -func (a JobAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -2102,13 +2102,13 @@ func (a JobAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of JobAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of JobAccessControlResponse in the Terraform plugin framework type // system. -func (a JobAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: JobPermission{}.ToAttrType(ctx), + ElemType: JobPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -2146,14 +2146,14 @@ func (a JobCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of JobCluster in the Terraform plugin framework type +// ToObjectType returns the representation of JobCluster in the Terraform plugin framework type // system. -func (a JobCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_cluster_key": types.StringType, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), }, }, } @@ -2191,9 +2191,9 @@ func (a JobCompliance) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of JobCompliance in the Terraform plugin framework type +// ToObjectType returns the representation of JobCompliance in the Terraform plugin framework type // system. -func (a JobCompliance) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobCompliance) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, @@ -2231,9 +2231,9 @@ func (a JobDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobDeployment in the Terraform plugin framework type +// ToObjectType returns the representation of JobDeployment in the Terraform plugin framework type // system. -func (a JobDeployment) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobDeployment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kind": types.StringType, @@ -2301,9 +2301,9 @@ func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of JobEmailNotifications in the Terraform plugin framework type +// ToObjectType returns the representation of JobEmailNotifications in the Terraform plugin framework type // system. -func (a JobEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobEmailNotifications) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "no_alert_for_skipped_runs": types.BoolType, @@ -2354,14 +2354,14 @@ func (a JobEnvironment) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of JobEnvironment in the Terraform plugin framework type +// ToObjectType returns the representation of JobEnvironment in the Terraform plugin framework type // system. -func (a JobEnvironment) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobEnvironment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "environment_key": types.StringType, "spec": basetypes.ListType{ - ElemType: compute_tf.Environment{}.ToAttrType(ctx), + ElemType: compute_tf.Environment{}.ToObjectType(ctx), }, }, } @@ -2393,9 +2393,9 @@ func (a JobNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobNotificationSettings in the Terraform plugin framework type +// ToObjectType returns the representation of JobNotificationSettings in the Terraform plugin framework type // system. -func (a JobNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobNotificationSettings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "no_alert_for_canceled_runs": types.BoolType, @@ -2430,9 +2430,9 @@ func (a JobParameter) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobParameter in the Terraform plugin framework type +// ToObjectType returns the representation of JobParameter in the Terraform plugin framework type // system. -func (a JobParameter) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobParameter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default": types.StringType, @@ -2467,9 +2467,9 @@ func (a JobParameterDefinition) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobParameterDefinition in the Terraform plugin framework type +// ToObjectType returns the representation of JobParameterDefinition in the Terraform plugin framework type // system. -func (a JobParameterDefinition) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobParameterDefinition) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default": types.StringType, @@ -2505,9 +2505,9 @@ func (a JobPermission) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of JobPermission in the Terraform plugin framework type +// ToObjectType returns the representation of JobPermission in the Terraform plugin framework type // system. -func (a JobPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2546,13 +2546,13 @@ func (a JobPermissions) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of JobPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of JobPermissions in the Terraform plugin framework type // system. -func (a JobPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlResponse{}.ToAttrType(ctx), + ElemType: JobAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2583,9 +2583,9 @@ func (a JobPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of JobPermissionsDescription in the Terraform plugin framework type // system. -func (a JobPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2619,13 +2619,13 @@ func (a JobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of JobPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of JobPermissionsRequest in the Terraform plugin framework type // system. -func (a JobPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.ToAttrType(ctx), + ElemType: JobAccessControlRequest{}.ToObjectType(ctx), }, "job_id": types.StringType, }, @@ -2664,9 +2664,9 @@ func (a JobRunAs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobRunAs in the Terraform plugin framework type +// ToObjectType returns the representation of JobRunAs in the Terraform plugin framework type // system. -func (a JobRunAs) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobRunAs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "service_principal_name": types.StringType, @@ -2813,65 +2813,65 @@ func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of JobSettings in the Terraform plugin framework type +// ToObjectType returns the representation of JobSettings in the Terraform plugin framework type // system. -func (a JobSettings) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobSettings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_policy_id": types.StringType, "continuous": basetypes.ListType{ - ElemType: Continuous{}.ToAttrType(ctx), + ElemType: Continuous{}.ToObjectType(ctx), }, "deployment": basetypes.ListType{ - ElemType: JobDeployment{}.ToAttrType(ctx), + ElemType: JobDeployment{}.ToObjectType(ctx), }, "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToAttrType(ctx), + ElemType: JobEmailNotifications{}.ToObjectType(ctx), }, "environment": basetypes.ListType{ - ElemType: JobEnvironment{}.ToAttrType(ctx), + ElemType: JobEnvironment{}.ToObjectType(ctx), }, "format": types.StringType, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToAttrType(ctx), + ElemType: GitSource{}.ToObjectType(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToAttrType(ctx), + ElemType: JobsHealthRules{}.ToObjectType(ctx), }, "job_cluster": basetypes.ListType{ - ElemType: JobCluster{}.ToAttrType(ctx), + ElemType: JobCluster{}.ToObjectType(ctx), }, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.ToAttrType(ctx), + ElemType: JobNotificationSettings{}.ToObjectType(ctx), }, "parameter": basetypes.ListType{ - ElemType: JobParameterDefinition{}.ToAttrType(ctx), + ElemType: JobParameterDefinition{}.ToObjectType(ctx), }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToAttrType(ctx), + ElemType: QueueSettings{}.ToObjectType(ctx), }, "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.ToAttrType(ctx), + ElemType: JobRunAs{}.ToObjectType(ctx), }, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToAttrType(ctx), + ElemType: CronSchedule{}.ToObjectType(ctx), }, "tags": basetypes.MapType{ ElemType: types.StringType, }, "task": basetypes.ListType{ - ElemType: Task{}.ToAttrType(ctx), + ElemType: Task{}.ToObjectType(ctx), }, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ - ElemType: TriggerSettings{}.ToAttrType(ctx), + ElemType: TriggerSettings{}.ToObjectType(ctx), }, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToAttrType(ctx), + ElemType: WebhookNotifications{}.ToObjectType(ctx), }, }, } @@ -2913,9 +2913,9 @@ func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobSource in the Terraform plugin framework type +// ToObjectType returns the representation of JobSource in the Terraform plugin framework type // system. -func (a JobSource) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobSource) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dirty_state": types.StringType, @@ -2964,9 +2964,9 @@ func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobsHealthRule in the Terraform plugin framework type +// ToObjectType returns the representation of JobsHealthRule in the Terraform plugin framework type // system. -func (a JobsHealthRule) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobsHealthRule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metric": types.StringType, @@ -3000,13 +3000,13 @@ func (a JobsHealthRules) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of JobsHealthRules in the Terraform plugin framework type +// ToObjectType returns the representation of JobsHealthRules in the Terraform plugin framework type // system. -func (a JobsHealthRules) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobsHealthRules) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "rules": basetypes.ListType{ - ElemType: JobsHealthRule{}.ToAttrType(ctx), + ElemType: JobsHealthRule{}.ToObjectType(ctx), }, }, } @@ -3044,13 +3044,13 @@ func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of ListJobComplianceForPolicyResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListJobComplianceForPolicyResponse in the Terraform plugin framework type // system. -func (a ListJobComplianceForPolicyResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListJobComplianceForPolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "jobs": basetypes.ListType{ - ElemType: JobCompliance{}.ToAttrType(ctx), + ElemType: JobCompliance{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -3088,9 +3088,9 @@ func (a ListJobComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListJobComplianceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListJobComplianceRequest in the Terraform plugin framework type // system. -func (a ListJobComplianceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListJobComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -3135,9 +3135,9 @@ func (a ListJobsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListJobsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListJobsRequest in the Terraform plugin framework type // system. -func (a ListJobsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListJobsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "expand_tasks": types.BoolType, @@ -3183,14 +3183,14 @@ func (a ListJobsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ListJobsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListJobsResponse in the Terraform plugin framework type // system. -func (a ListJobsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListJobsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_more": types.BoolType, "jobs": basetypes.ListType{ - ElemType: BaseJob{}.ToAttrType(ctx), + ElemType: BaseJob{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -3255,9 +3255,9 @@ func (a ListRunsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListRunsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListRunsRequest in the Terraform plugin framework type // system. -func (a ListRunsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRunsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active_only": types.BoolType, @@ -3308,16 +3308,16 @@ func (a ListRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ListRunsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListRunsResponse in the Terraform plugin framework type // system. -func (a ListRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_more": types.BoolType, "next_page_token": types.StringType, "prev_page_token": types.StringType, "runs": basetypes.ListType{ - ElemType: BaseRun{}.ToAttrType(ctx), + ElemType: BaseRun{}.ToObjectType(ctx), }, }, } @@ -3352,9 +3352,9 @@ func (a NotebookOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of NotebookOutput in the Terraform plugin framework type +// ToObjectType returns the representation of NotebookOutput in the Terraform plugin framework type // system. -func (a NotebookOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a NotebookOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "result": types.StringType, @@ -3423,9 +3423,9 @@ func (a NotebookTask) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of NotebookTask in the Terraform plugin framework type +// ToObjectType returns the representation of NotebookTask in the Terraform plugin framework type // system. -func (a NotebookTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a NotebookTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "base_parameters": basetypes.MapType{ @@ -3462,9 +3462,9 @@ func (a PeriodicTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of PeriodicTriggerConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of PeriodicTriggerConfiguration in the Terraform plugin framework type // system. -func (a PeriodicTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a PeriodicTriggerConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "interval": types.Int64Type, @@ -3495,9 +3495,9 @@ func (a PipelineParams) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelineParams in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineParams in the Terraform plugin framework type // system. -func (a PipelineParams) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineParams) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_refresh": types.BoolType, @@ -3529,9 +3529,9 @@ func (a PipelineTask) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelineTask in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineTask in the Terraform plugin framework type // system. -func (a PipelineTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_refresh": types.BoolType, @@ -3576,9 +3576,9 @@ func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of PythonWheelTask in the Terraform plugin framework type +// ToObjectType returns the representation of PythonWheelTask in the Terraform plugin framework type // system. -func (a PythonWheelTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a PythonWheelTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "entry_point": types.StringType, @@ -3623,9 +3623,9 @@ func (a QueueDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of QueueDetails in the Terraform plugin framework type +// ToObjectType returns the representation of QueueDetails in the Terraform plugin framework type // system. -func (a QueueDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueueDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -3656,9 +3656,9 @@ func (a QueueSettings) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of QueueSettings in the Terraform plugin framework type +// ToObjectType returns the representation of QueueSettings in the Terraform plugin framework type // system. -func (a QueueSettings) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueueSettings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -3707,19 +3707,19 @@ func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of RepairHistoryItem in the Terraform plugin framework type +// ToObjectType returns the representation of RepairHistoryItem in the Terraform plugin framework type // system. -func (a RepairHistoryItem) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepairHistoryItem) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time": types.Int64Type, "id": types.Int64Type, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToAttrType(ctx), + ElemType: RunState{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToAttrType(ctx), + ElemType: RunStatus{}.ToObjectType(ctx), }, "task_run_ids": basetypes.ListType{ ElemType: types.Int64Type, @@ -3860,9 +3860,9 @@ func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of RepairRun in the Terraform plugin framework type +// ToObjectType returns the representation of RepairRun in the Terraform plugin framework type // system. -func (a RepairRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepairRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -3879,7 +3879,7 @@ func (a RepairRun) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToAttrType(ctx), + ElemType: PipelineParams{}.ToObjectType(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -3927,9 +3927,9 @@ func (a RepairRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of RepairRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RepairRunResponse in the Terraform plugin framework type // system. -func (a RepairRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepairRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repair_id": types.Int64Type, @@ -3967,14 +3967,14 @@ func (a ResetJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of ResetJob in the Terraform plugin framework type +// ToObjectType returns the representation of ResetJob in the Terraform plugin framework type // system. -func (a ResetJob) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResetJob) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, "new_settings": basetypes.ListType{ - ElemType: JobSettings{}.ToAttrType(ctx), + ElemType: JobSettings{}.ToObjectType(ctx), }, }, } @@ -4000,9 +4000,9 @@ func (a ResetResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ResetResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ResetResponse in the Terraform plugin framework type // system. -func (a ResetResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResetResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4031,9 +4031,9 @@ func (a ResolvedConditionTaskValues) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of ResolvedConditionTaskValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedConditionTaskValues in the Terraform plugin framework type // system. -func (a ResolvedConditionTaskValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedConditionTaskValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "left": types.StringType, @@ -4065,9 +4065,9 @@ func (a ResolvedDbtTaskValues) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ResolvedDbtTaskValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedDbtTaskValues in the Terraform plugin framework type // system. -func (a ResolvedDbtTaskValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedDbtTaskValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "commands": basetypes.ListType{ @@ -4100,9 +4100,9 @@ func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ResolvedNotebookTaskValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedNotebookTaskValues in the Terraform plugin framework type // system. -func (a ResolvedNotebookTaskValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedNotebookTaskValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "base_parameters": basetypes.MapType{ @@ -4135,9 +4135,9 @@ func (a ResolvedParamPairValues) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ResolvedParamPairValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedParamPairValues in the Terraform plugin framework type // system. -func (a ResolvedParamPairValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedParamPairValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.MapType{ @@ -4173,9 +4173,9 @@ func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ResolvedPythonWheelTaskValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedPythonWheelTaskValues in the Terraform plugin framework type // system. -func (a ResolvedPythonWheelTaskValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedPythonWheelTaskValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "named_parameters": basetypes.MapType{ @@ -4214,9 +4214,9 @@ func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of ResolvedRunJobTaskValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedRunJobTaskValues in the Terraform plugin framework type // system. -func (a ResolvedRunJobTaskValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedRunJobTaskValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_parameters": basetypes.MapType{ @@ -4252,9 +4252,9 @@ func (a ResolvedStringParamsValues) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ResolvedStringParamsValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedStringParamsValues in the Terraform plugin framework type // system. -func (a ResolvedStringParamsValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedStringParamsValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ @@ -4314,40 +4314,40 @@ func (a ResolvedValues) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ResolvedValues in the Terraform plugin framework type +// ToObjectType returns the representation of ResolvedValues in the Terraform plugin framework type // system. -func (a ResolvedValues) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResolvedValues) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ - ElemType: ResolvedConditionTaskValues{}.ToAttrType(ctx), + ElemType: ResolvedConditionTaskValues{}.ToObjectType(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: ResolvedDbtTaskValues{}.ToAttrType(ctx), + ElemType: ResolvedDbtTaskValues{}.ToObjectType(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: ResolvedNotebookTaskValues{}.ToAttrType(ctx), + ElemType: ResolvedNotebookTaskValues{}.ToObjectType(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: ResolvedPythonWheelTaskValues{}.ToAttrType(ctx), + ElemType: ResolvedPythonWheelTaskValues{}.ToObjectType(ctx), }, "run_job_task": basetypes.ListType{ - ElemType: ResolvedRunJobTaskValues{}.ToAttrType(ctx), + ElemType: ResolvedRunJobTaskValues{}.ToObjectType(ctx), }, "simulation_task": basetypes.ListType{ - ElemType: ResolvedParamPairValues{}.ToAttrType(ctx), + ElemType: ResolvedParamPairValues{}.ToObjectType(ctx), }, "spark_jar_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.ToAttrType(ctx), + ElemType: ResolvedStringParamsValues{}.ToObjectType(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.ToAttrType(ctx), + ElemType: ResolvedStringParamsValues{}.ToObjectType(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.ToAttrType(ctx), + ElemType: ResolvedStringParamsValues{}.ToObjectType(ctx), }, "sql_task": basetypes.ListType{ - ElemType: ResolvedParamPairValues{}.ToAttrType(ctx), + ElemType: ResolvedParamPairValues{}.ToObjectType(ctx), }, }, } @@ -4520,46 +4520,46 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToAttrType returns the representation of Run in the Terraform plugin framework type +// ToObjectType returns the representation of Run in the Terraform plugin framework type // system. -func (a Run) ToAttrType(ctx context.Context) types.ObjectType { +func (a Run) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.ToAttrType(ctx), + ElemType: ClusterInstance{}.ToObjectType(ctx), }, "cluster_spec": basetypes.ListType{ - ElemType: ClusterSpec{}.ToAttrType(ctx), + ElemType: ClusterSpec{}.ToObjectType(ctx), }, "creator_user_name": types.StringType, "description": types.StringType, "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToAttrType(ctx), + ElemType: GitSource{}.ToObjectType(ctx), }, "iterations": basetypes.ListType{ - ElemType: RunTask{}.ToAttrType(ctx), + ElemType: RunTask{}.ToObjectType(ctx), }, "job_clusters": basetypes.ListType{ - ElemType: JobCluster{}.ToAttrType(ctx), + ElemType: JobCluster{}.ToObjectType(ctx), }, "job_id": types.Int64Type, "job_parameters": basetypes.ListType{ - ElemType: JobParameter{}.ToAttrType(ctx), + ElemType: JobParameter{}.ToObjectType(ctx), }, "job_run_id": types.Int64Type, "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ - ElemType: RunParameters{}.ToAttrType(ctx), + ElemType: RunParameters{}.ToObjectType(ctx), }, "queue_duration": types.Int64Type, "repair_history": basetypes.ListType{ - ElemType: RepairHistoryItem{}.ToAttrType(ctx), + ElemType: RepairHistoryItem{}.ToObjectType(ctx), }, "run_duration": types.Int64Type, "run_id": types.Int64Type, @@ -4567,22 +4567,22 @@ func (a Run) ToAttrType(ctx context.Context) types.ObjectType { "run_page_url": types.StringType, "run_type": types.StringType, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToAttrType(ctx), + ElemType: CronSchedule{}.ToObjectType(ctx), }, "setup_duration": types.Int64Type, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToAttrType(ctx), + ElemType: RunState{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToAttrType(ctx), + ElemType: RunStatus{}.ToObjectType(ctx), }, "tasks": basetypes.ListType{ - ElemType: RunTask{}.ToAttrType(ctx), + ElemType: RunTask{}.ToObjectType(ctx), }, "trigger": types.StringType, "trigger_info": basetypes.ListType{ - ElemType: TriggerInfo{}.ToAttrType(ctx), + ElemType: TriggerInfo{}.ToObjectType(ctx), }, }, } @@ -4628,9 +4628,9 @@ func (a RunConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunConditionTask in the Terraform plugin framework type +// ToObjectType returns the representation of RunConditionTask in the Terraform plugin framework type // system. -func (a RunConditionTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunConditionTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "left": types.StringType, @@ -4676,18 +4676,18 @@ func (a RunForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of RunForEachTask in the Terraform plugin framework type +// ToObjectType returns the representation of RunForEachTask in the Terraform plugin framework type // system. -func (a RunForEachTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunForEachTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, "stats": basetypes.ListType{ - ElemType: ForEachStats{}.ToAttrType(ctx), + ElemType: ForEachStats{}.ToObjectType(ctx), }, "task": basetypes.ListType{ - ElemType: Task{}.ToAttrType(ctx), + ElemType: Task{}.ToObjectType(ctx), }, }, } @@ -4715,9 +4715,9 @@ func (a RunJobOutput) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunJobOutput in the Terraform plugin framework type +// ToObjectType returns the representation of RunJobOutput in the Terraform plugin framework type // system. -func (a RunJobOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunJobOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -4841,9 +4841,9 @@ func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of RunJobTask in the Terraform plugin framework type +// ToObjectType returns the representation of RunJobTask in the Terraform plugin framework type // system. -func (a RunJobTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunJobTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -4860,7 +4860,7 @@ func (a RunJobTask) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToAttrType(ctx), + ElemType: PipelineParams{}.ToObjectType(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -5017,9 +5017,9 @@ func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToAttrType returns the representation of RunNow in the Terraform plugin framework type +// ToObjectType returns the representation of RunNow in the Terraform plugin framework type // system. -func (a RunNow) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunNow) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -5040,7 +5040,7 @@ func (a RunNow) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToAttrType(ctx), + ElemType: PipelineParams{}.ToObjectType(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -5049,7 +5049,7 @@ func (a RunNow) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToAttrType(ctx), + ElemType: QueueSettings{}.ToObjectType(ctx), }, "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, @@ -5087,9 +5087,9 @@ func (a RunNowResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunNowResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RunNowResponse in the Terraform plugin framework type // system. -func (a RunNowResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunNowResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "number_in_job": types.Int64Type, @@ -5161,13 +5161,13 @@ func (a RunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of RunOutput in the Terraform plugin framework type +// ToObjectType returns the representation of RunOutput in the Terraform plugin framework type // system. -func (a RunOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_output": basetypes.ListType{ - ElemType: DbtOutput{}.ToAttrType(ctx), + ElemType: DbtOutput{}.ToObjectType(ctx), }, "error": types.StringType, "error_trace": types.StringType, @@ -5175,16 +5175,16 @@ func (a RunOutput) ToAttrType(ctx context.Context) types.ObjectType { "logs": types.StringType, "logs_truncated": types.BoolType, "metadata": basetypes.ListType{ - ElemType: Run{}.ToAttrType(ctx), + ElemType: Run{}.ToObjectType(ctx), }, "notebook_output": basetypes.ListType{ - ElemType: NotebookOutput{}.ToAttrType(ctx), + ElemType: NotebookOutput{}.ToObjectType(ctx), }, "run_job_output": basetypes.ListType{ - ElemType: RunJobOutput{}.ToAttrType(ctx), + ElemType: RunJobOutput{}.ToObjectType(ctx), }, "sql_output": basetypes.ListType{ - ElemType: SqlOutput{}.ToAttrType(ctx), + ElemType: SqlOutput{}.ToObjectType(ctx), }, }, } @@ -5301,9 +5301,9 @@ func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of RunParameters in the Terraform plugin framework type +// ToObjectType returns the representation of RunParameters in the Terraform plugin framework type // system. -func (a RunParameters) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunParameters) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -5316,7 +5316,7 @@ func (a RunParameters) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToAttrType(ctx), + ElemType: PipelineParams{}.ToObjectType(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -5369,9 +5369,9 @@ func (a RunState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunState in the Terraform plugin framework type +// ToObjectType returns the representation of RunState in the Terraform plugin framework type // system. -func (a RunState) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunState) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "life_cycle_state": types.StringType, @@ -5414,17 +5414,17 @@ func (a RunStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of RunStatus in the Terraform plugin framework type +// ToObjectType returns the representation of RunStatus in the Terraform plugin framework type // system. -func (a RunStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "queue_details": basetypes.ListType{ - ElemType: QueueDetails{}.ToAttrType(ctx), + ElemType: QueueDetails{}.ToObjectType(ctx), }, "state": types.StringType, "termination_details": basetypes.ListType{ - ElemType: TerminationDetails{}.ToAttrType(ctx), + ElemType: TerminationDetails{}.ToObjectType(ctx), }, }, } @@ -5638,93 +5638,93 @@ func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of RunTask in the Terraform plugin framework type +// ToObjectType returns the representation of RunTask in the Terraform plugin framework type // system. -func (a RunTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.ToAttrType(ctx), + ElemType: ClusterInstance{}.ToObjectType(ctx), }, "condition_task": basetypes.ListType{ - ElemType: RunConditionTask{}.ToAttrType(ctx), + ElemType: RunConditionTask{}.ToObjectType(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.ToAttrType(ctx), + ElemType: DbtTask{}.ToObjectType(ctx), }, "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.ToAttrType(ctx), + ElemType: TaskDependency{}.ToObjectType(ctx), }, "description": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToAttrType(ctx), + ElemType: JobEmailNotifications{}.ToObjectType(ctx), }, "end_time": types.Int64Type, "environment_key": types.StringType, "execution_duration": types.Int64Type, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ - ElemType: RunForEachTask{}.ToAttrType(ctx), + ElemType: RunForEachTask{}.ToObjectType(ctx), }, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToAttrType(ctx), + ElemType: GitSource{}.ToObjectType(ctx), }, "job_cluster_key": types.StringType, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToAttrType(ctx), + ElemType: compute_tf.Library{}.ToObjectType(ctx), }, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.ToAttrType(ctx), + ElemType: NotebookTask{}.ToObjectType(ctx), }, "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.ToAttrType(ctx), + ElemType: TaskNotificationSettings{}.ToObjectType(ctx), }, "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.ToAttrType(ctx), + ElemType: PipelineTask{}.ToObjectType(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.ToAttrType(ctx), + ElemType: PythonWheelTask{}.ToObjectType(ctx), }, "queue_duration": types.Int64Type, "resolved_values": basetypes.ListType{ - ElemType: ResolvedValues{}.ToAttrType(ctx), + ElemType: ResolvedValues{}.ToObjectType(ctx), }, "run_duration": types.Int64Type, "run_id": types.Int64Type, "run_if": types.StringType, "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.ToAttrType(ctx), + ElemType: RunJobTask{}.ToObjectType(ctx), }, "run_page_url": types.StringType, "setup_duration": types.Int64Type, "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.ToAttrType(ctx), + ElemType: SparkJarTask{}.ToObjectType(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.ToAttrType(ctx), + ElemType: SparkPythonTask{}.ToObjectType(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.ToAttrType(ctx), + ElemType: SparkSubmitTask{}.ToObjectType(ctx), }, "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.ToAttrType(ctx), + ElemType: SqlTask{}.ToObjectType(ctx), }, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToAttrType(ctx), + ElemType: RunState{}.ToObjectType(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToAttrType(ctx), + ElemType: RunStatus{}.ToObjectType(ctx), }, "task_key": types.StringType, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToAttrType(ctx), + ElemType: WebhookNotifications{}.ToObjectType(ctx), }, }, } @@ -5768,9 +5768,9 @@ func (a SparkJarTask) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of SparkJarTask in the Terraform plugin framework type +// ToObjectType returns the representation of SparkJarTask in the Terraform plugin framework type // system. -func (a SparkJarTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparkJarTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "jar_uri": types.StringType, @@ -5827,9 +5827,9 @@ func (a SparkPythonTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of SparkPythonTask in the Terraform plugin framework type +// ToObjectType returns the representation of SparkPythonTask in the Terraform plugin framework type // system. -func (a SparkPythonTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparkPythonTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ @@ -5870,9 +5870,9 @@ func (a SparkSubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of SparkSubmitTask in the Terraform plugin framework type +// ToObjectType returns the representation of SparkSubmitTask in the Terraform plugin framework type // system. -func (a SparkSubmitTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparkSubmitTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ @@ -5919,16 +5919,16 @@ func (a SqlAlertOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of SqlAlertOutput in the Terraform plugin framework type +// ToObjectType returns the representation of SqlAlertOutput in the Terraform plugin framework type // system. -func (a SqlAlertOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlAlertOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_state": types.StringType, "output_link": types.StringType, "query_text": types.StringType, "sql_statements": basetypes.ListType{ - ElemType: SqlStatementOutput{}.ToAttrType(ctx), + ElemType: SqlStatementOutput{}.ToObjectType(ctx), }, "warehouse_id": types.StringType, }, @@ -5961,14 +5961,14 @@ func (a SqlDashboardOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of SqlDashboardOutput in the Terraform plugin framework type +// ToObjectType returns the representation of SqlDashboardOutput in the Terraform plugin framework type // system. -func (a SqlDashboardOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlDashboardOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, "widgets": basetypes.ListType{ - ElemType: SqlDashboardWidgetOutput{}.ToAttrType(ctx), + ElemType: SqlDashboardWidgetOutput{}.ToObjectType(ctx), }, }, } @@ -6010,14 +6010,14 @@ func (a SqlDashboardWidgetOutput) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of SqlDashboardWidgetOutput in the Terraform plugin framework type +// ToObjectType returns the representation of SqlDashboardWidgetOutput in the Terraform plugin framework type // system. -func (a SqlDashboardWidgetOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlDashboardWidgetOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time": types.Int64Type, "error": basetypes.ListType{ - ElemType: SqlOutputError{}.ToAttrType(ctx), + ElemType: SqlOutputError{}.ToObjectType(ctx), }, "output_link": types.StringType, "start_time": types.Int64Type, @@ -6058,19 +6058,19 @@ func (a SqlOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of SqlOutput in the Terraform plugin framework type +// ToObjectType returns the representation of SqlOutput in the Terraform plugin framework type // system. -func (a SqlOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_output": basetypes.ListType{ - ElemType: SqlAlertOutput{}.ToAttrType(ctx), + ElemType: SqlAlertOutput{}.ToObjectType(ctx), }, "dashboard_output": basetypes.ListType{ - ElemType: SqlDashboardOutput{}.ToAttrType(ctx), + ElemType: SqlDashboardOutput{}.ToObjectType(ctx), }, "query_output": basetypes.ListType{ - ElemType: SqlQueryOutput{}.ToAttrType(ctx), + ElemType: SqlQueryOutput{}.ToObjectType(ctx), }, }, } @@ -6098,9 +6098,9 @@ func (a SqlOutputError) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of SqlOutputError in the Terraform plugin framework type +// ToObjectType returns the representation of SqlOutputError in the Terraform plugin framework type // system. -func (a SqlOutputError) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlOutputError) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -6140,16 +6140,16 @@ func (a SqlQueryOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of SqlQueryOutput in the Terraform plugin framework type +// ToObjectType returns the representation of SqlQueryOutput in the Terraform plugin framework type // system. -func (a SqlQueryOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlQueryOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_id": types.StringType, "output_link": types.StringType, "query_text": types.StringType, "sql_statements": basetypes.ListType{ - ElemType: SqlStatementOutput{}.ToAttrType(ctx), + ElemType: SqlStatementOutput{}.ToObjectType(ctx), }, "warehouse_id": types.StringType, }, @@ -6178,9 +6178,9 @@ func (a SqlStatementOutput) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of SqlStatementOutput in the Terraform plugin framework type +// ToObjectType returns the representation of SqlStatementOutput in the Terraform plugin framework type // system. -func (a SqlStatementOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlStatementOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "lookup_key": types.StringType, @@ -6231,25 +6231,25 @@ func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of SqlTask in the Terraform plugin framework type +// ToObjectType returns the representation of SqlTask in the Terraform plugin framework type // system. -func (a SqlTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert": basetypes.ListType{ - ElemType: SqlTaskAlert{}.ToAttrType(ctx), + ElemType: SqlTaskAlert{}.ToObjectType(ctx), }, "dashboard": basetypes.ListType{ - ElemType: SqlTaskDashboard{}.ToAttrType(ctx), + ElemType: SqlTaskDashboard{}.ToObjectType(ctx), }, "file": basetypes.ListType{ - ElemType: SqlTaskFile{}.ToAttrType(ctx), + ElemType: SqlTaskFile{}.ToObjectType(ctx), }, "parameters": basetypes.MapType{ ElemType: types.StringType, }, "query": basetypes.ListType{ - ElemType: SqlTaskQuery{}.ToAttrType(ctx), + ElemType: SqlTaskQuery{}.ToObjectType(ctx), }, "warehouse_id": types.StringType, }, @@ -6284,15 +6284,15 @@ func (a SqlTaskAlert) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of SqlTaskAlert in the Terraform plugin framework type +// ToObjectType returns the representation of SqlTaskAlert in the Terraform plugin framework type // system. -func (a SqlTaskAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlTaskAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "pause_subscriptions": types.BoolType, "subscriptions": basetypes.ListType{ - ElemType: SqlTaskSubscription{}.ToAttrType(ctx), + ElemType: SqlTaskSubscription{}.ToObjectType(ctx), }, }, } @@ -6329,16 +6329,16 @@ func (a SqlTaskDashboard) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of SqlTaskDashboard in the Terraform plugin framework type +// ToObjectType returns the representation of SqlTaskDashboard in the Terraform plugin framework type // system. -func (a SqlTaskDashboard) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlTaskDashboard) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "custom_subject": types.StringType, "dashboard_id": types.StringType, "pause_subscriptions": types.BoolType, "subscriptions": basetypes.ListType{ - ElemType: SqlTaskSubscription{}.ToAttrType(ctx), + ElemType: SqlTaskSubscription{}.ToObjectType(ctx), }, }, } @@ -6376,9 +6376,9 @@ func (a SqlTaskFile) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of SqlTaskFile in the Terraform plugin framework type +// ToObjectType returns the representation of SqlTaskFile in the Terraform plugin framework type // system. -func (a SqlTaskFile) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlTaskFile) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -6409,9 +6409,9 @@ func (a SqlTaskQuery) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of SqlTaskQuery in the Terraform plugin framework type +// ToObjectType returns the representation of SqlTaskQuery in the Terraform plugin framework type // system. -func (a SqlTaskQuery) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlTaskQuery) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -6448,9 +6448,9 @@ func (a SqlTaskSubscription) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of SqlTaskSubscription in the Terraform plugin framework type +// ToObjectType returns the representation of SqlTaskSubscription in the Terraform plugin framework type // system. -func (a SqlTaskSubscription) ToAttrType(ctx context.Context) types.ObjectType { +func (a SqlTaskSubscription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_id": types.StringType, @@ -6549,44 +6549,44 @@ func (a SubmitRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of SubmitRun in the Terraform plugin framework type +// ToObjectType returns the representation of SubmitRun in the Terraform plugin framework type // system. -func (a SubmitRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a SubmitRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.ToAttrType(ctx), + ElemType: JobAccessControlRequest{}.ToObjectType(ctx), }, "budget_policy_id": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToAttrType(ctx), + ElemType: JobEmailNotifications{}.ToObjectType(ctx), }, "environments": basetypes.ListType{ - ElemType: JobEnvironment{}.ToAttrType(ctx), + ElemType: JobEnvironment{}.ToObjectType(ctx), }, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToAttrType(ctx), + ElemType: GitSource{}.ToObjectType(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToAttrType(ctx), + ElemType: JobsHealthRules{}.ToObjectType(ctx), }, "idempotency_token": types.StringType, "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.ToAttrType(ctx), + ElemType: JobNotificationSettings{}.ToObjectType(ctx), }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToAttrType(ctx), + ElemType: QueueSettings{}.ToObjectType(ctx), }, "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.ToAttrType(ctx), + ElemType: JobRunAs{}.ToObjectType(ctx), }, "run_name": types.StringType, "tasks": basetypes.ListType{ - ElemType: SubmitTask{}.ToAttrType(ctx), + ElemType: SubmitTask{}.ToObjectType(ctx), }, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToAttrType(ctx), + ElemType: WebhookNotifications{}.ToObjectType(ctx), }, }, } @@ -6615,9 +6615,9 @@ func (a SubmitRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of SubmitRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SubmitRunResponse in the Terraform plugin framework type // system. -func (a SubmitRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SubmitRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -6761,70 +6761,70 @@ func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of SubmitTask in the Terraform plugin framework type +// ToObjectType returns the representation of SubmitTask in the Terraform plugin framework type // system. -func (a SubmitTask) ToAttrType(ctx context.Context) types.ObjectType { +func (a SubmitTask) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ - ElemType: ConditionTask{}.ToAttrType(ctx), + ElemType: ConditionTask{}.ToObjectType(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.ToAttrType(ctx), + ElemType: DbtTask{}.ToObjectType(ctx), }, "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.ToAttrType(ctx), + ElemType: TaskDependency{}.ToObjectType(ctx), }, "description": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToAttrType(ctx), + ElemType: JobEmailNotifications{}.ToObjectType(ctx), }, "environment_key": types.StringType, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ - ElemType: ForEachTask{}.ToAttrType(ctx), + ElemType: ForEachTask{}.ToObjectType(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToAttrType(ctx), + ElemType: JobsHealthRules{}.ToObjectType(ctx), }, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToAttrType(ctx), + ElemType: compute_tf.Library{}.ToObjectType(ctx), }, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.ToAttrType(ctx), + ElemType: NotebookTask{}.ToObjectType(ctx), }, "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.ToAttrType(ctx), + ElemType: TaskNotificationSettings{}.ToObjectType(ctx), }, "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.ToAttrType(ctx), + ElemType: PipelineTask{}.ToObjectType(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.ToAttrType(ctx), + ElemType: PythonWheelTask{}.ToObjectType(ctx), }, "run_if": types.StringType, "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.ToAttrType(ctx), + ElemType: RunJobTask{}.ToObjectType(ctx), }, "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.ToAttrType(ctx), + ElemType: SparkJarTask{}.ToObjectType(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.ToAttrType(ctx), + ElemType: SparkPythonTask{}.ToObjectType(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.ToAttrType(ctx), + ElemType: SparkSubmitTask{}.ToObjectType(ctx), }, "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.ToAttrType(ctx), + ElemType: SqlTask{}.ToObjectType(ctx), }, "task_key": types.StringType, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToAttrType(ctx), + ElemType: WebhookNotifications{}.ToObjectType(ctx), }, }, } @@ -6866,9 +6866,9 @@ func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of TableUpdateTriggerConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of TableUpdateTriggerConfiguration in the Terraform plugin framework type // system. -func (a TableUpdateTriggerConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableUpdateTriggerConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": types.StringType, @@ -7040,75 +7040,75 @@ func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of Task in the Terraform plugin framework type +// ToObjectType returns the representation of Task in the Terraform plugin framework type // system. -func (a Task) ToAttrType(ctx context.Context) types.ObjectType { +func (a Task) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ - ElemType: ConditionTask{}.ToAttrType(ctx), + ElemType: ConditionTask{}.ToObjectType(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.ToAttrType(ctx), + ElemType: DbtTask{}.ToObjectType(ctx), }, "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.ToAttrType(ctx), + ElemType: TaskDependency{}.ToObjectType(ctx), }, "description": types.StringType, "disable_auto_optimization": types.BoolType, "email_notifications": basetypes.ListType{ - ElemType: TaskEmailNotifications{}.ToAttrType(ctx), + ElemType: TaskEmailNotifications{}.ToObjectType(ctx), }, "environment_key": types.StringType, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ - ElemType: ForEachTask{}.ToAttrType(ctx), + ElemType: ForEachTask{}.ToObjectType(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToAttrType(ctx), + ElemType: JobsHealthRules{}.ToObjectType(ctx), }, "job_cluster_key": types.StringType, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToAttrType(ctx), + ElemType: compute_tf.Library{}.ToObjectType(ctx), }, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToAttrType(ctx), + ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.ToAttrType(ctx), + ElemType: NotebookTask{}.ToObjectType(ctx), }, "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.ToAttrType(ctx), + ElemType: TaskNotificationSettings{}.ToObjectType(ctx), }, "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.ToAttrType(ctx), + ElemType: PipelineTask{}.ToObjectType(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.ToAttrType(ctx), + ElemType: PythonWheelTask{}.ToObjectType(ctx), }, "retry_on_timeout": types.BoolType, "run_if": types.StringType, "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.ToAttrType(ctx), + ElemType: RunJobTask{}.ToObjectType(ctx), }, "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.ToAttrType(ctx), + ElemType: SparkJarTask{}.ToObjectType(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.ToAttrType(ctx), + ElemType: SparkPythonTask{}.ToObjectType(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.ToAttrType(ctx), + ElemType: SparkSubmitTask{}.ToObjectType(ctx), }, "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.ToAttrType(ctx), + ElemType: SqlTask{}.ToObjectType(ctx), }, "task_key": types.StringType, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToAttrType(ctx), + ElemType: WebhookNotifications{}.ToObjectType(ctx), }, }, } @@ -7139,9 +7139,9 @@ func (a TaskDependency) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of TaskDependency in the Terraform plugin framework type +// ToObjectType returns the representation of TaskDependency in the Terraform plugin framework type // system. -func (a TaskDependency) ToAttrType(ctx context.Context) types.ObjectType { +func (a TaskDependency) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "outcome": types.StringType, @@ -7209,9 +7209,9 @@ func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of TaskEmailNotifications in the Terraform plugin framework type +// ToObjectType returns the representation of TaskEmailNotifications in the Terraform plugin framework type // system. -func (a TaskEmailNotifications) ToAttrType(ctx context.Context) types.ObjectType { +func (a TaskEmailNotifications) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "no_alert_for_skipped_runs": types.BoolType, @@ -7264,9 +7264,9 @@ func (a TaskNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of TaskNotificationSettings in the Terraform plugin framework type +// ToObjectType returns the representation of TaskNotificationSettings in the Terraform plugin framework type // system. -func (a TaskNotificationSettings) ToAttrType(ctx context.Context) types.ObjectType { +func (a TaskNotificationSettings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_on_last_attempt": types.BoolType, @@ -7354,9 +7354,9 @@ func (a TerminationDetails) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of TerminationDetails in the Terraform plugin framework type +// ToObjectType returns the representation of TerminationDetails in the Terraform plugin framework type // system. -func (a TerminationDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a TerminationDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -7389,9 +7389,9 @@ func (a TriggerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of TriggerInfo in the Terraform plugin framework type +// ToObjectType returns the representation of TriggerInfo in the Terraform plugin framework type // system. -func (a TriggerInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a TriggerInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -7434,23 +7434,23 @@ func (a TriggerSettings) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of TriggerSettings in the Terraform plugin framework type +// ToObjectType returns the representation of TriggerSettings in the Terraform plugin framework type // system. -func (a TriggerSettings) ToAttrType(ctx context.Context) types.ObjectType { +func (a TriggerSettings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_arrival": basetypes.ListType{ - ElemType: FileArrivalTriggerConfiguration{}.ToAttrType(ctx), + ElemType: FileArrivalTriggerConfiguration{}.ToObjectType(ctx), }, "pause_status": types.StringType, "periodic": basetypes.ListType{ - ElemType: PeriodicTriggerConfiguration{}.ToAttrType(ctx), + ElemType: PeriodicTriggerConfiguration{}.ToObjectType(ctx), }, "table": basetypes.ListType{ - ElemType: TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + ElemType: TableUpdateTriggerConfiguration{}.ToObjectType(ctx), }, "table_update": basetypes.ListType{ - ElemType: TableUpdateTriggerConfiguration{}.ToAttrType(ctx), + ElemType: TableUpdateTriggerConfiguration{}.ToObjectType(ctx), }, }, } @@ -7497,9 +7497,9 @@ func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of UpdateJob in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateJob in the Terraform plugin framework type // system. -func (a UpdateJob) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateJob) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fields_to_remove": basetypes.ListType{ @@ -7507,7 +7507,7 @@ func (a UpdateJob) ToAttrType(ctx context.Context) types.ObjectType { }, "job_id": types.Int64Type, "new_settings": basetypes.ListType{ - ElemType: JobSettings{}.ToAttrType(ctx), + ElemType: JobSettings{}.ToObjectType(ctx), }, }, } @@ -7533,9 +7533,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7569,9 +7569,9 @@ func (a ViewItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of ViewItem in the Terraform plugin framework type +// ToObjectType returns the representation of ViewItem in the Terraform plugin framework type // system. -func (a ViewItem) ToAttrType(ctx context.Context) types.ObjectType { +func (a ViewItem) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -7602,9 +7602,9 @@ func (a Webhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of Webhook in the Terraform plugin framework type +// ToObjectType returns the representation of Webhook in the Terraform plugin framework type // system. -func (a Webhook) ToAttrType(ctx context.Context) types.ObjectType { +func (a Webhook) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -7662,25 +7662,25 @@ func (a WebhookNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of WebhookNotifications in the Terraform plugin framework type +// ToObjectType returns the representation of WebhookNotifications in the Terraform plugin framework type // system. -func (a WebhookNotifications) ToAttrType(ctx context.Context) types.ObjectType { +func (a WebhookNotifications) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "on_duration_warning_threshold_exceeded": basetypes.ListType{ - ElemType: Webhook{}.ToAttrType(ctx), + ElemType: Webhook{}.ToObjectType(ctx), }, "on_failure": basetypes.ListType{ - ElemType: Webhook{}.ToAttrType(ctx), + ElemType: Webhook{}.ToObjectType(ctx), }, "on_start": basetypes.ListType{ - ElemType: Webhook{}.ToAttrType(ctx), + ElemType: Webhook{}.ToObjectType(ctx), }, "on_streaming_backlog_exceeded": basetypes.ListType{ - ElemType: Webhook{}.ToAttrType(ctx), + ElemType: Webhook{}.ToObjectType(ctx), }, "on_success": basetypes.ListType{ - ElemType: Webhook{}.ToAttrType(ctx), + ElemType: Webhook{}.ToObjectType(ctx), }, }, } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index f2a1567633..4d284c7b8e 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -42,9 +42,9 @@ func (a AddExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of AddExchangeForListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of AddExchangeForListingRequest in the Terraform plugin framework type // system. -func (a AddExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a AddExchangeForListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -76,13 +76,13 @@ func (a AddExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of AddExchangeForListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of AddExchangeForListingResponse in the Terraform plugin framework type // system. -func (a AddExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a AddExchangeForListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_for_listing": basetypes.ListType{ - ElemType: ExchangeListing{}.ToAttrType(ctx), + ElemType: ExchangeListing{}.ToObjectType(ctx), }, }, } @@ -112,9 +112,9 @@ func (a BatchGetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of BatchGetListingsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of BatchGetListingsRequest in the Terraform plugin framework type // system. -func (a BatchGetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a BatchGetListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ids": basetypes.ListType{ @@ -147,13 +147,13 @@ func (a BatchGetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of BatchGetListingsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of BatchGetListingsResponse in the Terraform plugin framework type // system. -func (a BatchGetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a BatchGetListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, }, } @@ -183,9 +183,9 @@ func (a BatchGetProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of BatchGetProvidersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of BatchGetProvidersRequest in the Terraform plugin framework type // system. -func (a BatchGetProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a BatchGetProvidersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ids": basetypes.ListType{ @@ -218,13 +218,13 @@ func (a BatchGetProvidersResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of BatchGetProvidersResponse in the Terraform plugin framework type +// ToObjectType returns the representation of BatchGetProvidersResponse in the Terraform plugin framework type // system. -func (a BatchGetProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a BatchGetProvidersResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } @@ -251,9 +251,9 @@ func (a ConsumerTerms) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ConsumerTerms in the Terraform plugin framework type +// ToObjectType returns the representation of ConsumerTerms in the Terraform plugin framework type // system. -func (a ConsumerTerms) ToAttrType(ctx context.Context) types.ObjectType { +func (a ConsumerTerms) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "version": types.StringType, @@ -290,9 +290,9 @@ func (a ContactInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of ContactInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ContactInfo in the Terraform plugin framework type // system. -func (a ContactInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ContactInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "company": types.StringType, @@ -326,13 +326,13 @@ func (a CreateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of CreateExchangeFilterRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExchangeFilterRequest in the Terraform plugin framework type // system. -func (a CreateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExchangeFilterRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToAttrType(ctx), + ElemType: ExchangeFilter{}.ToObjectType(ctx), }, }, } @@ -359,9 +359,9 @@ func (a CreateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateExchangeFilterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExchangeFilterResponse in the Terraform plugin framework type // system. -func (a CreateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExchangeFilterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter_id": types.StringType, @@ -392,13 +392,13 @@ func (a CreateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateExchangeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExchangeRequest in the Terraform plugin framework type // system. -func (a CreateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToAttrType(ctx), + ElemType: Exchange{}.ToObjectType(ctx), }, }, } @@ -425,9 +425,9 @@ func (a CreateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateExchangeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExchangeResponse in the Terraform plugin framework type // system. -func (a CreateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -464,14 +464,14 @@ func (a CreateFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of CreateFileRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateFileRequest in the Terraform plugin framework type // system. -func (a CreateFileRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateFileRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, "file_parent": basetypes.ListType{ - ElemType: FileParent{}.ToAttrType(ctx), + ElemType: FileParent{}.ToObjectType(ctx), }, "marketplace_file_type": types.StringType, "mime_type": types.StringType, @@ -504,13 +504,13 @@ func (a CreateFileResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateFileResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateFileResponse in the Terraform plugin framework type // system. -func (a CreateFileResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateFileResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_info": basetypes.ListType{ - ElemType: FileInfo{}.ToAttrType(ctx), + ElemType: FileInfo{}.ToObjectType(ctx), }, "upload_url": types.StringType, }, @@ -551,19 +551,19 @@ func (a CreateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of CreateInstallationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateInstallationRequest in the Terraform plugin framework type // system. -func (a CreateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateInstallationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "accepted_consumer_terms": basetypes.ListType{ - ElemType: ConsumerTerms{}.ToAttrType(ctx), + ElemType: ConsumerTerms{}.ToObjectType(ctx), }, "catalog_name": types.StringType, "listing_id": types.StringType, "recipient_type": types.StringType, "repo_detail": basetypes.ListType{ - ElemType: RepoInstallation{}.ToAttrType(ctx), + ElemType: RepoInstallation{}.ToObjectType(ctx), }, "share_name": types.StringType, }, @@ -593,13 +593,13 @@ func (a CreateListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of CreateListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateListingRequest in the Terraform plugin framework type // system. -func (a CreateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, }, } @@ -626,9 +626,9 @@ func (a CreateListingResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateListingResponse in the Terraform plugin framework type // system. -func (a CreateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -676,13 +676,13 @@ func (a CreatePersonalizationRequest) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of CreatePersonalizationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePersonalizationRequest in the Terraform plugin framework type // system. -func (a CreatePersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePersonalizationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "accepted_consumer_terms": basetypes.ListType{ - ElemType: ConsumerTerms{}.ToAttrType(ctx), + ElemType: ConsumerTerms{}.ToObjectType(ctx), }, "comment": types.StringType, "company": types.StringType, @@ -717,9 +717,9 @@ func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreatePersonalizationRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePersonalizationRequestResponse in the Terraform plugin framework type // system. -func (a CreatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePersonalizationRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -750,13 +750,13 @@ func (a CreateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateProviderRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateProviderRequest in the Terraform plugin framework type // system. -func (a CreateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } @@ -783,9 +783,9 @@ func (a CreateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateProviderResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateProviderResponse in the Terraform plugin framework type // system. -func (a CreateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -816,9 +816,9 @@ func (a DataRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of DataRefreshInfo in the Terraform plugin framework type +// ToObjectType returns the representation of DataRefreshInfo in the Terraform plugin framework type // system. -func (a DataRefreshInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a DataRefreshInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "interval": types.Int64Type, @@ -849,9 +849,9 @@ func (a DeleteExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExchangeFilterRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExchangeFilterRequest in the Terraform plugin framework type // system. -func (a DeleteExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExchangeFilterRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -879,9 +879,9 @@ func (a DeleteExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExchangeFilterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExchangeFilterResponse in the Terraform plugin framework type // system. -func (a DeleteExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExchangeFilterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -909,9 +909,9 @@ func (a DeleteExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExchangeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExchangeRequest in the Terraform plugin framework type // system. -func (a DeleteExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -939,9 +939,9 @@ func (a DeleteExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExchangeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExchangeResponse in the Terraform plugin framework type // system. -func (a DeleteExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -969,9 +969,9 @@ func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteFileRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteFileRequest in the Terraform plugin framework type // system. -func (a DeleteFileRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteFileRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_id": types.StringType, @@ -999,9 +999,9 @@ func (a DeleteFileResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteFileResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteFileResponse in the Terraform plugin framework type // system. -func (a DeleteFileResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteFileResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1031,9 +1031,9 @@ func (a DeleteInstallationRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteInstallationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteInstallationRequest in the Terraform plugin framework type // system. -func (a DeleteInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteInstallationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation_id": types.StringType, @@ -1062,9 +1062,9 @@ func (a DeleteInstallationResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteInstallationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteInstallationResponse in the Terraform plugin framework type // system. -func (a DeleteInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteInstallationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1092,9 +1092,9 @@ func (a DeleteListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteListingRequest in the Terraform plugin framework type // system. -func (a DeleteListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1122,9 +1122,9 @@ func (a DeleteListingResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteListingResponse in the Terraform plugin framework type // system. -func (a DeleteListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1152,9 +1152,9 @@ func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteProviderRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteProviderRequest in the Terraform plugin framework type // system. -func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1182,9 +1182,9 @@ func (a DeleteProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteProviderResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteProviderResponse in the Terraform plugin framework type // system. -func (a DeleteProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1230,20 +1230,20 @@ func (a Exchange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of Exchange in the Terraform plugin framework type +// ToObjectType returns the representation of Exchange in the Terraform plugin framework type // system. -func (a Exchange) ToAttrType(ctx context.Context) types.ObjectType { +func (a Exchange) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, "filters": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToAttrType(ctx), + ElemType: ExchangeFilter{}.ToObjectType(ctx), }, "id": types.StringType, "linked_listings": basetypes.ListType{ - ElemType: ExchangeListing{}.ToAttrType(ctx), + ElemType: ExchangeListing{}.ToObjectType(ctx), }, "name": types.StringType, "updated_at": types.Int64Type, @@ -1289,9 +1289,9 @@ func (a ExchangeFilter) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExchangeFilter in the Terraform plugin framework type +// ToObjectType returns the representation of ExchangeFilter in the Terraform plugin framework type // system. -func (a ExchangeFilter) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExchangeFilter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -1340,9 +1340,9 @@ func (a ExchangeListing) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExchangeListing in the Terraform plugin framework type +// ToObjectType returns the representation of ExchangeListing in the Terraform plugin framework type // system. -func (a ExchangeListing) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExchangeListing) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -1398,16 +1398,16 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of FileInfo in the Terraform plugin framework type +// ToObjectType returns the representation of FileInfo in the Terraform plugin framework type // system. -func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a FileInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, "display_name": types.StringType, "download_link": types.StringType, "file_parent": basetypes.ListType{ - ElemType: FileParent{}.ToAttrType(ctx), + ElemType: FileParent{}.ToObjectType(ctx), }, "id": types.StringType, "marketplace_file_type": types.StringType, @@ -1442,9 +1442,9 @@ func (a FileParent) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of FileParent in the Terraform plugin framework type +// ToObjectType returns the representation of FileParent in the Terraform plugin framework type // system. -func (a FileParent) ToAttrType(ctx context.Context) types.ObjectType { +func (a FileParent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_parent_type": types.StringType, @@ -1475,9 +1475,9 @@ func (a GetExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetExchangeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetExchangeRequest in the Terraform plugin framework type // system. -func (a GetExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1508,13 +1508,13 @@ func (a GetExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of GetExchangeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetExchangeResponse in the Terraform plugin framework type // system. -func (a GetExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToAttrType(ctx), + ElemType: Exchange{}.ToObjectType(ctx), }, }, } @@ -1542,9 +1542,9 @@ func (a GetFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetFileRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetFileRequest in the Terraform plugin framework type // system. -func (a GetFileRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetFileRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_id": types.StringType, @@ -1575,13 +1575,13 @@ func (a GetFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of GetFileResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetFileResponse in the Terraform plugin framework type // system. -func (a GetFileResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetFileResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_info": basetypes.ListType{ - ElemType: FileInfo{}.ToAttrType(ctx), + ElemType: FileInfo{}.ToObjectType(ctx), }, }, } @@ -1609,9 +1609,9 @@ func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetLatestVersionProviderAnalyticsDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetLatestVersionProviderAnalyticsDashboardResponse in the Terraform plugin framework type // system. -func (a GetLatestVersionProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetLatestVersionProviderAnalyticsDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "version": types.Int64Type, @@ -1645,9 +1645,9 @@ func (a GetListingContentMetadataRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetListingContentMetadataRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetListingContentMetadataRequest in the Terraform plugin framework type // system. -func (a GetListingContentMetadataRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetListingContentMetadataRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -1682,14 +1682,14 @@ func (a GetListingContentMetadataResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of GetListingContentMetadataResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetListingContentMetadataResponse in the Terraform plugin framework type // system. -func (a GetListingContentMetadataResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetListingContentMetadataResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "shared_data_objects": basetypes.ListType{ - ElemType: SharedDataObject{}.ToAttrType(ctx), + ElemType: SharedDataObject{}.ToObjectType(ctx), }, }, } @@ -1717,9 +1717,9 @@ func (a GetListingRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetListingRequest in the Terraform plugin framework type // system. -func (a GetListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1750,13 +1750,13 @@ func (a GetListingResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of GetListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetListingResponse in the Terraform plugin framework type // system. -func (a GetListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, }, } @@ -1786,9 +1786,9 @@ func (a GetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetListingsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetListingsRequest in the Terraform plugin framework type // system. -func (a GetListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -1822,13 +1822,13 @@ func (a GetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of GetListingsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetListingsResponse in the Terraform plugin framework type // system. -func (a GetListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -1857,9 +1857,9 @@ func (a GetPersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPersonalizationRequestRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPersonalizationRequestRequest in the Terraform plugin framework type // system. -func (a GetPersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPersonalizationRequestRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -1890,13 +1890,13 @@ func (a GetPersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of GetPersonalizationRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetPersonalizationRequestResponse in the Terraform plugin framework type // system. -func (a GetPersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPersonalizationRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "personalization_requests": basetypes.ListType{ - ElemType: PersonalizationRequest{}.ToAttrType(ctx), + ElemType: PersonalizationRequest{}.ToObjectType(ctx), }, }, } @@ -1924,9 +1924,9 @@ func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetProviderRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetProviderRequest in the Terraform plugin framework type // system. -func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1957,13 +1957,13 @@ func (a GetProviderResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of GetProviderResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetProviderResponse in the Terraform plugin framework type // system. -func (a GetProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } @@ -1992,13 +1992,13 @@ func (a Installation) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of Installation in the Terraform plugin framework type +// ToObjectType returns the representation of Installation in the Terraform plugin framework type // system. -func (a Installation) ToAttrType(ctx context.Context) types.ObjectType { +func (a Installation) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.ToAttrType(ctx), + ElemType: InstallationDetail{}.ToObjectType(ctx), }, }, } @@ -2052,9 +2052,9 @@ func (a InstallationDetail) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of InstallationDetail in the Terraform plugin framework type +// ToObjectType returns the representation of InstallationDetail in the Terraform plugin framework type // system. -func (a InstallationDetail) ToAttrType(ctx context.Context) types.ObjectType { +func (a InstallationDetail) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2069,10 +2069,10 @@ func (a InstallationDetail) ToAttrType(ctx context.Context) types.ObjectType { "share_name": types.StringType, "status": types.StringType, "token_detail": basetypes.ListType{ - ElemType: TokenDetail{}.ToAttrType(ctx), + ElemType: TokenDetail{}.ToObjectType(ctx), }, "tokens": basetypes.ListType{ - ElemType: TokenInfo{}.ToAttrType(ctx), + ElemType: TokenInfo{}.ToObjectType(ctx), }, }, } @@ -2102,9 +2102,9 @@ func (a ListAllInstallationsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAllInstallationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAllInstallationsRequest in the Terraform plugin framework type // system. -func (a ListAllInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAllInstallationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -2138,13 +2138,13 @@ func (a ListAllInstallationsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListAllInstallationsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAllInstallationsResponse in the Terraform plugin framework type // system. -func (a ListAllInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAllInstallationsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installations": basetypes.ListType{ - ElemType: InstallationDetail{}.ToAttrType(ctx), + ElemType: InstallationDetail{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2175,9 +2175,9 @@ func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAllPersonalizationRequestsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAllPersonalizationRequestsRequest in the Terraform plugin framework type // system. -func (a ListAllPersonalizationRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAllPersonalizationRequestsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -2211,14 +2211,14 @@ func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes(ctx context } } -// ToAttrType returns the representation of ListAllPersonalizationRequestsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAllPersonalizationRequestsResponse in the Terraform plugin framework type // system. -func (a ListAllPersonalizationRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAllPersonalizationRequestsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "personalization_requests": basetypes.ListType{ - ElemType: PersonalizationRequest{}.ToAttrType(ctx), + ElemType: PersonalizationRequest{}.ToObjectType(ctx), }, }, } @@ -2250,9 +2250,9 @@ func (a ListExchangeFiltersRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListExchangeFiltersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListExchangeFiltersRequest in the Terraform plugin framework type // system. -func (a ListExchangeFiltersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExchangeFiltersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -2287,13 +2287,13 @@ func (a ListExchangeFiltersResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of ListExchangeFiltersResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListExchangeFiltersResponse in the Terraform plugin framework type // system. -func (a ListExchangeFiltersResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExchangeFiltersResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filters": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToAttrType(ctx), + ElemType: ExchangeFilter{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2326,9 +2326,9 @@ func (a ListExchangesForListingRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListExchangesForListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListExchangesForListingRequest in the Terraform plugin framework type // system. -func (a ListExchangesForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExchangesForListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -2363,13 +2363,13 @@ func (a ListExchangesForListingResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of ListExchangesForListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListExchangesForListingResponse in the Terraform plugin framework type // system. -func (a ListExchangesForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExchangesForListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_listing": basetypes.ListType{ - ElemType: ExchangeListing{}.ToAttrType(ctx), + ElemType: ExchangeListing{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2400,9 +2400,9 @@ func (a ListExchangesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListExchangesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListExchangesRequest in the Terraform plugin framework type // system. -func (a ListExchangesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExchangesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -2436,13 +2436,13 @@ func (a ListExchangesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListExchangesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListExchangesResponse in the Terraform plugin framework type // system. -func (a ListExchangesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExchangesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchanges": basetypes.ListType{ - ElemType: Exchange{}.ToAttrType(ctx), + ElemType: Exchange{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2477,13 +2477,13 @@ func (a ListFilesRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ListFilesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListFilesRequest in the Terraform plugin framework type // system. -func (a ListFilesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListFilesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_parent": basetypes.ListType{ - ElemType: FileParent{}.ToAttrType(ctx), + ElemType: FileParent{}.ToObjectType(ctx), }, "page_size": types.Int64Type, "page_token": types.StringType, @@ -2516,13 +2516,13 @@ func (a ListFilesResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ListFilesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListFilesResponse in the Terraform plugin framework type // system. -func (a ListFilesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListFilesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_infos": basetypes.ListType{ - ElemType: FileInfo{}.ToAttrType(ctx), + ElemType: FileInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2555,9 +2555,9 @@ func (a ListFulfillmentsRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListFulfillmentsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListFulfillmentsRequest in the Terraform plugin framework type // system. -func (a ListFulfillmentsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListFulfillmentsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -2592,13 +2592,13 @@ func (a ListFulfillmentsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of ListFulfillmentsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListFulfillmentsResponse in the Terraform plugin framework type // system. -func (a ListFulfillmentsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListFulfillmentsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fulfillments": basetypes.ListType{ - ElemType: ListingFulfillment{}.ToAttrType(ctx), + ElemType: ListingFulfillment{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2631,9 +2631,9 @@ func (a ListInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListInstallationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListInstallationsRequest in the Terraform plugin framework type // system. -func (a ListInstallationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListInstallationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -2668,13 +2668,13 @@ func (a ListInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ListInstallationsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListInstallationsResponse in the Terraform plugin framework type // system. -func (a ListInstallationsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListInstallationsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installations": basetypes.ListType{ - ElemType: InstallationDetail{}.ToAttrType(ctx), + ElemType: InstallationDetail{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2707,9 +2707,9 @@ func (a ListListingsForExchangeRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListListingsForExchangeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListListingsForExchangeRequest in the Terraform plugin framework type // system. -func (a ListListingsForExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListListingsForExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -2744,13 +2744,13 @@ func (a ListListingsForExchangeResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of ListListingsForExchangeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListListingsForExchangeResponse in the Terraform plugin framework type // system. -func (a ListListingsForExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListListingsForExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_listings": basetypes.ListType{ - ElemType: ExchangeListing{}.ToAttrType(ctx), + ElemType: ExchangeListing{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2801,9 +2801,9 @@ func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListListingsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListListingsRequest in the Terraform plugin framework type // system. -func (a ListListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets": basetypes.ListType{ @@ -2821,7 +2821,7 @@ func (a ListListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "tags": basetypes.ListType{ - ElemType: ListingTag{}.ToAttrType(ctx), + ElemType: ListingTag{}.ToObjectType(ctx), }, }, } @@ -2852,13 +2852,13 @@ func (a ListListingsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListListingsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListListingsResponse in the Terraform plugin framework type // system. -func (a ListListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2891,9 +2891,9 @@ func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListProviderAnalyticsDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListProviderAnalyticsDashboardResponse in the Terraform plugin framework type // system. -func (a ListProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListProviderAnalyticsDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -2929,9 +2929,9 @@ func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListProvidersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListProvidersRequest in the Terraform plugin framework type // system. -func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListProvidersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_featured": types.BoolType, @@ -2966,14 +2966,14 @@ func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListProvidersResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListProvidersResponse in the Terraform plugin framework type // system. -func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListProvidersResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } @@ -3007,17 +3007,17 @@ func (a Listing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of Listing in the Terraform plugin framework type +// ToObjectType returns the representation of Listing in the Terraform plugin framework type // system. -func (a Listing) ToAttrType(ctx context.Context) types.ObjectType { +func (a Listing) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "detail": basetypes.ListType{ - ElemType: ListingDetail{}.ToAttrType(ctx), + ElemType: ListingDetail{}.ToObjectType(ctx), }, "id": types.StringType, "summary": basetypes.ListType{ - ElemType: ListingSummary{}.ToAttrType(ctx), + ElemType: ListingSummary{}.ToObjectType(ctx), }, }, } @@ -3098,9 +3098,9 @@ func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of ListingDetail in the Terraform plugin framework type +// ToObjectType returns the representation of ListingDetail in the Terraform plugin framework type // system. -func (a ListingDetail) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListingDetail) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets": basetypes.ListType{ @@ -3109,14 +3109,14 @@ func (a ListingDetail) ToAttrType(ctx context.Context) types.ObjectType { "collection_date_end": types.Int64Type, "collection_date_start": types.Int64Type, "collection_granularity": basetypes.ListType{ - ElemType: DataRefreshInfo{}.ToAttrType(ctx), + ElemType: DataRefreshInfo{}.ToObjectType(ctx), }, "cost": types.StringType, "data_source": types.StringType, "description": types.StringType, "documentation_link": types.StringType, "embedded_notebook_file_infos": basetypes.ListType{ - ElemType: FileInfo{}.ToAttrType(ctx), + ElemType: FileInfo{}.ToObjectType(ctx), }, "file_ids": basetypes.ListType{ ElemType: types.StringType, @@ -3128,11 +3128,11 @@ func (a ListingDetail) ToAttrType(ctx context.Context) types.ObjectType { "size": types.Float64Type, "support_link": types.StringType, "tags": basetypes.ListType{ - ElemType: ListingTag{}.ToAttrType(ctx), + ElemType: ListingTag{}.ToObjectType(ctx), }, "terms_of_service": types.StringType, "update_frequency": basetypes.ListType{ - ElemType: DataRefreshInfo{}.ToAttrType(ctx), + ElemType: DataRefreshInfo{}.ToObjectType(ctx), }, }, } @@ -3170,19 +3170,19 @@ func (a ListingFulfillment) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListingFulfillment in the Terraform plugin framework type +// ToObjectType returns the representation of ListingFulfillment in the Terraform plugin framework type // system. -func (a ListingFulfillment) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListingFulfillment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fulfillment_type": types.StringType, "listing_id": types.StringType, "recipient_type": types.StringType, "repo_info": basetypes.ListType{ - ElemType: RepoInfo{}.ToAttrType(ctx), + ElemType: RepoInfo{}.ToObjectType(ctx), }, "share_info": basetypes.ListType{ - ElemType: ShareInfo{}.ToAttrType(ctx), + ElemType: ShareInfo{}.ToObjectType(ctx), }, }, } @@ -3209,9 +3209,9 @@ func (a ListingSetting) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListingSetting in the Terraform plugin framework type +// ToObjectType returns the representation of ListingSetting in the Terraform plugin framework type // system. -func (a ListingSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListingSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "visibility": types.StringType, @@ -3285,9 +3285,9 @@ func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ListingSummary in the Terraform plugin framework type +// ToObjectType returns the representation of ListingSummary in the Terraform plugin framework type // system. -func (a ListingSummary) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListingSummary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "categories": basetypes.ListType{ @@ -3300,21 +3300,21 @@ func (a ListingSummary) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "git_repo": basetypes.ListType{ - ElemType: RepoInfo{}.ToAttrType(ctx), + ElemType: RepoInfo{}.ToObjectType(ctx), }, "listingType": types.StringType, "name": types.StringType, "provider_id": types.StringType, "provider_region": basetypes.ListType{ - ElemType: RegionInfo{}.ToAttrType(ctx), + ElemType: RegionInfo{}.ToObjectType(ctx), }, "published_at": types.Int64Type, "published_by": types.StringType, "setting": basetypes.ListType{ - ElemType: ListingSetting{}.ToAttrType(ctx), + ElemType: ListingSetting{}.ToObjectType(ctx), }, "share": basetypes.ListType{ - ElemType: ShareInfo{}.ToAttrType(ctx), + ElemType: ShareInfo{}.ToObjectType(ctx), }, "status": types.StringType, "subtitle": types.StringType, @@ -3352,9 +3352,9 @@ func (a ListingTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of ListingTag in the Terraform plugin framework type +// ToObjectType returns the representation of ListingTag in the Terraform plugin framework type // system. -func (a ListingTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListingTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "tag_name": types.StringType, @@ -3421,17 +3421,17 @@ func (a PersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of PersonalizationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PersonalizationRequest in the Terraform plugin framework type // system. -func (a PersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PersonalizationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "consumer_region": basetypes.ListType{ - ElemType: RegionInfo{}.ToAttrType(ctx), + ElemType: RegionInfo{}.ToObjectType(ctx), }, "contact_info": basetypes.ListType{ - ElemType: ContactInfo{}.ToAttrType(ctx), + ElemType: ContactInfo{}.ToObjectType(ctx), }, "created_at": types.Int64Type, "id": types.StringType, @@ -3443,7 +3443,7 @@ func (a PersonalizationRequest) ToAttrType(ctx context.Context) types.ObjectType "provider_id": types.StringType, "recipient_type": types.StringType, "share": basetypes.ListType{ - ElemType: ShareInfo{}.ToAttrType(ctx), + ElemType: ShareInfo{}.ToObjectType(ctx), }, "status": types.StringType, "status_message": types.StringType, @@ -3473,9 +3473,9 @@ func (a ProviderAnalyticsDashboard) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of ProviderAnalyticsDashboard in the Terraform plugin framework type +// ToObjectType returns the representation of ProviderAnalyticsDashboard in the Terraform plugin framework type // system. -func (a ProviderAnalyticsDashboard) ToAttrType(ctx context.Context) types.ObjectType { +func (a ProviderAnalyticsDashboard) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3530,9 +3530,9 @@ func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of ProviderInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ProviderInfo in the Terraform plugin framework type // system. -func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ProviderInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "business_contact_email": types.StringType, @@ -3576,9 +3576,9 @@ func (a RegionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of RegionInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RegionInfo in the Terraform plugin framework type // system. -func (a RegionInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegionInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cloud": types.StringType, @@ -3609,9 +3609,9 @@ func (a RemoveExchangeForListingRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of RemoveExchangeForListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RemoveExchangeForListingRequest in the Terraform plugin framework type // system. -func (a RemoveExchangeForListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RemoveExchangeForListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3639,9 +3639,9 @@ func (a RemoveExchangeForListingResponse) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of RemoveExchangeForListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RemoveExchangeForListingResponse in the Terraform plugin framework type // system. -func (a RemoveExchangeForListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RemoveExchangeForListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3669,9 +3669,9 @@ func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of RepoInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RepoInfo in the Terraform plugin framework type // system. -func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "git_repo_url": types.StringType, @@ -3705,9 +3705,9 @@ func (a RepoInstallation) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of RepoInstallation in the Terraform plugin framework type +// ToObjectType returns the representation of RepoInstallation in the Terraform plugin framework type // system. -func (a RepoInstallation) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoInstallation) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_name": types.StringType, @@ -3757,9 +3757,9 @@ func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of SearchListingsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SearchListingsRequest in the Terraform plugin framework type // system. -func (a SearchListingsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets": basetypes.ListType{ @@ -3805,13 +3805,13 @@ func (a SearchListingsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of SearchListingsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SearchListingsResponse in the Terraform plugin framework type // system. -func (a SearchListingsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -3841,9 +3841,9 @@ func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of ShareInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ShareInfo in the Terraform plugin framework type // system. -func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ShareInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -3877,9 +3877,9 @@ func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of SharedDataObject in the Terraform plugin framework type +// ToObjectType returns the representation of SharedDataObject in the Terraform plugin framework type // system. -func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { +func (a SharedDataObject) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_object_type": types.StringType, @@ -3917,9 +3917,9 @@ func (a TokenDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of TokenDetail in the Terraform plugin framework type +// ToObjectType returns the representation of TokenDetail in the Terraform plugin framework type // system. -func (a TokenDetail) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenDetail) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bearerToken": types.StringType, @@ -3965,9 +3965,9 @@ func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of TokenInfo in the Terraform plugin framework type +// ToObjectType returns the representation of TokenInfo in the Terraform plugin framework type // system. -func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -4006,13 +4006,13 @@ func (a UpdateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of UpdateExchangeFilterRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExchangeFilterRequest in the Terraform plugin framework type // system. -func (a UpdateExchangeFilterRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExchangeFilterRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToAttrType(ctx), + ElemType: ExchangeFilter{}.ToObjectType(ctx), }, "id": types.StringType, }, @@ -4042,13 +4042,13 @@ func (a UpdateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of UpdateExchangeFilterResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExchangeFilterResponse in the Terraform plugin framework type // system. -func (a UpdateExchangeFilterResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExchangeFilterResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToAttrType(ctx), + ElemType: ExchangeFilter{}.ToObjectType(ctx), }, }, } @@ -4079,13 +4079,13 @@ func (a UpdateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateExchangeRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExchangeRequest in the Terraform plugin framework type // system. -func (a UpdateExchangeRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToAttrType(ctx), + ElemType: Exchange{}.ToObjectType(ctx), }, "id": types.StringType, }, @@ -4115,13 +4115,13 @@ func (a UpdateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of UpdateExchangeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExchangeResponse in the Terraform plugin framework type // system. -func (a UpdateExchangeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToAttrType(ctx), + ElemType: Exchange{}.ToObjectType(ctx), }, }, } @@ -4156,13 +4156,13 @@ func (a UpdateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of UpdateInstallationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateInstallationRequest in the Terraform plugin framework type // system. -func (a UpdateInstallationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateInstallationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.ToAttrType(ctx), + ElemType: InstallationDetail{}.ToObjectType(ctx), }, "installation_id": types.StringType, "listing_id": types.StringType, @@ -4194,13 +4194,13 @@ func (a UpdateInstallationResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of UpdateInstallationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateInstallationResponse in the Terraform plugin framework type // system. -func (a UpdateInstallationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateInstallationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.ToAttrType(ctx), + ElemType: InstallationDetail{}.ToObjectType(ctx), }, }, } @@ -4231,14 +4231,14 @@ func (a UpdateListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of UpdateListingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateListingRequest in the Terraform plugin framework type // system. -func (a UpdateListingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateListingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "listing": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, }, } @@ -4267,13 +4267,13 @@ func (a UpdateListingResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateListingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateListingResponse in the Terraform plugin framework type // system. -func (a UpdateListingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateListingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing": basetypes.ListType{ - ElemType: Listing{}.ToAttrType(ctx), + ElemType: Listing{}.ToObjectType(ctx), }, }, } @@ -4310,16 +4310,16 @@ func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Co } } -// ToAttrType returns the representation of UpdatePersonalizationRequestRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePersonalizationRequestRequest in the Terraform plugin framework type // system. -func (a UpdatePersonalizationRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePersonalizationRequestRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, "reason": types.StringType, "request_id": types.StringType, "share": basetypes.ListType{ - ElemType: ShareInfo{}.ToAttrType(ctx), + ElemType: ShareInfo{}.ToObjectType(ctx), }, "status": types.StringType, }, @@ -4349,13 +4349,13 @@ func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of UpdatePersonalizationRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePersonalizationRequestResponse in the Terraform plugin framework type // system. -func (a UpdatePersonalizationRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePersonalizationRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request": basetypes.ListType{ - ElemType: PersonalizationRequest{}.ToAttrType(ctx), + ElemType: PersonalizationRequest{}.ToObjectType(ctx), }, }, } @@ -4387,9 +4387,9 @@ func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateProviderAnalyticsDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateProviderAnalyticsDashboardRequest in the Terraform plugin framework type // system. -func (a UpdateProviderAnalyticsDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateProviderAnalyticsDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -4424,9 +4424,9 @@ func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateProviderAnalyticsDashboardResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateProviderAnalyticsDashboardResponse in the Terraform plugin framework type // system. -func (a UpdateProviderAnalyticsDashboardResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateProviderAnalyticsDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -4461,14 +4461,14 @@ func (a UpdateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateProviderRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateProviderRequest in the Terraform plugin framework type // system. -func (a UpdateProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } @@ -4497,13 +4497,13 @@ func (a UpdateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of UpdateProviderResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateProviderResponse in the Terraform plugin framework type // system. -func (a UpdateProviderResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 488a09766d..e406758873 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -92,9 +92,9 @@ func (a Activity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of Activity in the Terraform plugin framework type +// ToObjectType returns the representation of Activity in the Terraform plugin framework type // system. -func (a Activity) ToAttrType(ctx context.Context) types.ObjectType { +func (a Activity) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activity_type": types.StringType, @@ -149,9 +149,9 @@ func (a ApproveTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ApproveTransitionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ApproveTransitionRequest in the Terraform plugin framework type // system. -func (a ApproveTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ApproveTransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "archive_existing_versions": types.BoolType, @@ -187,13 +187,13 @@ func (a ApproveTransitionRequestResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of ApproveTransitionRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ApproveTransitionRequestResponse in the Terraform plugin framework type // system. -func (a ApproveTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ApproveTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activity": basetypes.ListType{ - ElemType: Activity{}.ToAttrType(ctx), + ElemType: Activity{}.ToObjectType(ctx), }, }, } @@ -234,9 +234,9 @@ func (a CommentObject) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of CommentObject in the Terraform plugin framework type +// ToObjectType returns the representation of CommentObject in the Terraform plugin framework type // system. -func (a CommentObject) ToAttrType(ctx context.Context) types.ObjectType { +func (a CommentObject) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "available_actions": basetypes.ListType{ @@ -277,9 +277,9 @@ func (a CreateComment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateComment in the Terraform plugin framework type +// ToObjectType returns the representation of CreateComment in the Terraform plugin framework type // system. -func (a CreateComment) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateComment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -313,13 +313,13 @@ func (a CreateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateCommentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCommentResponse in the Terraform plugin framework type // system. -func (a CreateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCommentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": basetypes.ListType{ - ElemType: CommentObject{}.ToAttrType(ctx), + ElemType: CommentObject{}.ToObjectType(ctx), }, }, } @@ -358,15 +358,15 @@ func (a CreateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of CreateExperiment in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExperiment in the Terraform plugin framework type // system. -func (a CreateExperiment) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExperiment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ExperimentTag{}.ToAttrType(ctx), + ElemType: ExperimentTag{}.ToObjectType(ctx), }, }, } @@ -394,9 +394,9 @@ func (a CreateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateExperimentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateExperimentResponse in the Terraform plugin framework type // system. -func (a CreateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -432,15 +432,15 @@ func (a CreateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateModelRequest in the Terraform plugin framework type // system. -func (a CreateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelTag{}.ToAttrType(ctx), + ElemType: ModelTag{}.ToObjectType(ctx), }, }, } @@ -469,13 +469,13 @@ func (a CreateModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of CreateModelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateModelResponse in the Terraform plugin framework type // system. -func (a CreateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateModelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model": basetypes.ListType{ - ElemType: Model{}.ToAttrType(ctx), + ElemType: Model{}.ToObjectType(ctx), }, }, } @@ -517,9 +517,9 @@ func (a CreateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of CreateModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateModelVersionRequest in the Terraform plugin framework type // system. -func (a CreateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -528,7 +528,7 @@ func (a CreateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectT "run_link": types.StringType, "source": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.ToAttrType(ctx), + ElemType: ModelVersionTag{}.ToObjectType(ctx), }, }, } @@ -558,13 +558,13 @@ func (a CreateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of CreateModelVersionResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateModelVersionResponse in the Terraform plugin framework type // system. -func (a CreateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_version": basetypes.ListType{ - ElemType: ModelVersion{}.ToAttrType(ctx), + ElemType: ModelVersion{}.ToObjectType(ctx), }, }, } @@ -645,9 +645,9 @@ func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateRegistryWebhook in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRegistryWebhook in the Terraform plugin framework type // system. -func (a CreateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -655,10 +655,10 @@ func (a CreateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpec{}.ToAttrType(ctx), + ElemType: HttpUrlSpec{}.ToObjectType(ctx), }, "job_spec": basetypes.ListType{ - ElemType: JobSpec{}.ToAttrType(ctx), + ElemType: JobSpec{}.ToObjectType(ctx), }, "model_name": types.StringType, "status": types.StringType, @@ -698,15 +698,15 @@ func (a CreateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of CreateRun in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRun in the Terraform plugin framework type // system. -func (a CreateRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, "start_time": types.Int64Type, "tags": basetypes.ListType{ - ElemType: RunTag{}.ToAttrType(ctx), + ElemType: RunTag{}.ToObjectType(ctx), }, "user_id": types.StringType, }, @@ -737,13 +737,13 @@ func (a CreateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of CreateRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRunResponse in the Terraform plugin framework type // system. -func (a CreateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run": basetypes.ListType{ - ElemType: Run{}.ToAttrType(ctx), + ElemType: Run{}.ToObjectType(ctx), }, }, } @@ -785,9 +785,9 @@ func (a CreateTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateTransitionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateTransitionRequest in the Terraform plugin framework type // system. -func (a CreateTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateTransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -822,13 +822,13 @@ func (a CreateTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of CreateTransitionRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateTransitionRequestResponse in the Terraform plugin framework type // system. -func (a CreateTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request": basetypes.ListType{ - ElemType: TransitionRequest{}.ToAttrType(ctx), + ElemType: TransitionRequest{}.ToObjectType(ctx), }, }, } @@ -857,13 +857,13 @@ func (a CreateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateWebhookResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateWebhookResponse in the Terraform plugin framework type // system. -func (a CreateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "webhook": basetypes.ListType{ - ElemType: RegistryWebhook{}.ToAttrType(ctx), + ElemType: RegistryWebhook{}.ToObjectType(ctx), }, }, } @@ -909,9 +909,9 @@ func (a Dataset) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of Dataset in the Terraform plugin framework type +// ToObjectType returns the representation of Dataset in the Terraform plugin framework type // system. -func (a Dataset) ToAttrType(ctx context.Context) types.ObjectType { +func (a Dataset) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "digest": types.StringType, @@ -952,16 +952,16 @@ func (a DatasetInput) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of DatasetInput in the Terraform plugin framework type +// ToObjectType returns the representation of DatasetInput in the Terraform plugin framework type // system. -func (a DatasetInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a DatasetInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset": basetypes.ListType{ - ElemType: Dataset{}.ToAttrType(ctx), + ElemType: Dataset{}.ToObjectType(ctx), }, "tags": basetypes.ListType{ - ElemType: InputTag{}.ToAttrType(ctx), + ElemType: InputTag{}.ToObjectType(ctx), }, }, } @@ -989,9 +989,9 @@ func (a DeleteCommentRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCommentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCommentRequest in the Terraform plugin framework type // system. -func (a DeleteCommentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCommentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1019,9 +1019,9 @@ func (a DeleteCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCommentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCommentResponse in the Terraform plugin framework type // system. -func (a DeleteCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCommentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1049,9 +1049,9 @@ func (a DeleteExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExperiment in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExperiment in the Terraform plugin framework type // system. -func (a DeleteExperiment) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExperiment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -1079,9 +1079,9 @@ func (a DeleteExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteExperimentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteExperimentResponse in the Terraform plugin framework type // system. -func (a DeleteExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1110,9 +1110,9 @@ func (a DeleteModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelRequest in the Terraform plugin framework type // system. -func (a DeleteModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1140,9 +1140,9 @@ func (a DeleteModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelResponse in the Terraform plugin framework type // system. -func (a DeleteModelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1174,9 +1174,9 @@ func (a DeleteModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelTagRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelTagRequest in the Terraform plugin framework type // system. -func (a DeleteModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelTagRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1205,9 +1205,9 @@ func (a DeleteModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelTagResponse in the Terraform plugin framework type // system. -func (a DeleteModelTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1238,9 +1238,9 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type // system. -func (a DeleteModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1269,9 +1269,9 @@ func (a DeleteModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelVersionResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelVersionResponse in the Terraform plugin framework type // system. -func (a DeleteModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1305,9 +1305,9 @@ func (a DeleteModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelVersionTagRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelVersionTagRequest in the Terraform plugin framework type // system. -func (a DeleteModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelVersionTagRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1337,9 +1337,9 @@ func (a DeleteModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteModelVersionTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteModelVersionTagResponse in the Terraform plugin framework type // system. -func (a DeleteModelVersionTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteModelVersionTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1367,9 +1367,9 @@ func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRun in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRun in the Terraform plugin framework type // system. -func (a DeleteRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.StringType, @@ -1397,9 +1397,9 @@ func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRunResponse in the Terraform plugin framework type // system. -func (a DeleteRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1434,9 +1434,9 @@ func (a DeleteRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRuns in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRuns in the Terraform plugin framework type // system. -func (a DeleteRuns) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRuns) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -1468,9 +1468,9 @@ func (a DeleteRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRunsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRunsResponse in the Terraform plugin framework type // system. -func (a DeleteRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "runs_deleted": types.Int64Type, @@ -1502,9 +1502,9 @@ func (a DeleteTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTag in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTag in the Terraform plugin framework type // system. -func (a DeleteTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1533,9 +1533,9 @@ func (a DeleteTagResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTagResponse in the Terraform plugin framework type // system. -func (a DeleteTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1582,9 +1582,9 @@ func (a DeleteTransitionRequestRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTransitionRequestRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTransitionRequestRequest in the Terraform plugin framework type // system. -func (a DeleteTransitionRequestRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTransitionRequestRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1616,9 +1616,9 @@ func (a DeleteTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTransitionRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTransitionRequestResponse in the Terraform plugin framework type // system. -func (a DeleteTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1647,9 +1647,9 @@ func (a DeleteWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWebhookRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWebhookRequest in the Terraform plugin framework type // system. -func (a DeleteWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWebhookRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1677,9 +1677,9 @@ func (a DeleteWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWebhookResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWebhookResponse in the Terraform plugin framework type // system. -func (a DeleteWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1722,9 +1722,9 @@ func (a Experiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of Experiment in the Terraform plugin framework type +// ToObjectType returns the representation of Experiment in the Terraform plugin framework type // system. -func (a Experiment) ToAttrType(ctx context.Context) types.ObjectType { +func (a Experiment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, @@ -1734,7 +1734,7 @@ func (a Experiment) ToAttrType(ctx context.Context) types.ObjectType { "lifecycle_stage": types.StringType, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ExperimentTag{}.ToAttrType(ctx), + ElemType: ExperimentTag{}.ToObjectType(ctx), }, }, } @@ -1768,9 +1768,9 @@ func (a ExperimentAccessControlRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExperimentAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentAccessControlRequest in the Terraform plugin framework type // system. -func (a ExperimentAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1813,13 +1813,13 @@ func (a ExperimentAccessControlResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of ExperimentAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentAccessControlResponse in the Terraform plugin framework type // system. -func (a ExperimentAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ExperimentPermission{}.ToAttrType(ctx), + ElemType: ExperimentPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1856,9 +1856,9 @@ func (a ExperimentPermission) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ExperimentPermission in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentPermission in the Terraform plugin framework type // system. -func (a ExperimentPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1897,13 +1897,13 @@ func (a ExperimentPermissions) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ExperimentPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentPermissions in the Terraform plugin framework type // system. -func (a ExperimentPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ExperimentAccessControlResponse{}.ToAttrType(ctx), + ElemType: ExperimentAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1934,9 +1934,9 @@ func (a ExperimentPermissionsDescription) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExperimentPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentPermissionsDescription in the Terraform plugin framework type // system. -func (a ExperimentPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1970,13 +1970,13 @@ func (a ExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ExperimentPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentPermissionsRequest in the Terraform plugin framework type // system. -func (a ExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ExperimentAccessControlRequest{}.ToAttrType(ctx), + ElemType: ExperimentAccessControlRequest{}.ToObjectType(ctx), }, "experiment_id": types.StringType, }, @@ -2007,9 +2007,9 @@ func (a ExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExperimentTag in the Terraform plugin framework type +// ToObjectType returns the representation of ExperimentTag in the Terraform plugin framework type // system. -func (a ExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExperimentTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2044,9 +2044,9 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of FileInfo in the Terraform plugin framework type +// ToObjectType returns the representation of FileInfo in the Terraform plugin framework type // system. -func (a FileInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a FileInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_size": types.Int64Type, @@ -2079,9 +2079,9 @@ func (a GetByNameRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetByNameRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetByNameRequest in the Terraform plugin framework type // system. -func (a GetByNameRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetByNameRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_name": types.StringType, @@ -2112,9 +2112,9 @@ func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetExperimentPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetExperimentPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetExperimentPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExperimentPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -2146,13 +2146,13 @@ func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes(ctx context. } } -// ToAttrType returns the representation of GetExperimentPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetExperimentPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetExperimentPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExperimentPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ExperimentPermissionsDescription{}.ToAttrType(ctx), + ElemType: ExperimentPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -2181,9 +2181,9 @@ func (a GetExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetExperimentPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetExperimentPermissionsRequest in the Terraform plugin framework type // system. -func (a GetExperimentPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExperimentPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -2214,9 +2214,9 @@ func (a GetExperimentRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetExperimentRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetExperimentRequest in the Terraform plugin framework type // system. -func (a GetExperimentRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExperimentRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -2248,13 +2248,13 @@ func (a GetExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of GetExperimentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetExperimentResponse in the Terraform plugin framework type // system. -func (a GetExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment": basetypes.ListType{ - ElemType: Experiment{}.ToAttrType(ctx), + ElemType: Experiment{}.ToObjectType(ctx), }, }, } @@ -2294,9 +2294,9 @@ func (a GetHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetHistoryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetHistoryRequest in the Terraform plugin framework type // system. -func (a GetHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetHistoryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -2334,9 +2334,9 @@ func (a GetLatestVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of GetLatestVersionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetLatestVersionsRequest in the Terraform plugin framework type // system. -func (a GetLatestVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetLatestVersionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2373,13 +2373,13 @@ func (a GetLatestVersionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of GetLatestVersionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetLatestVersionsResponse in the Terraform plugin framework type // system. -func (a GetLatestVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetLatestVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToAttrType(ctx), + ElemType: ModelVersion{}.ToObjectType(ctx), }, }, } @@ -2412,13 +2412,13 @@ func (a GetMetricHistoryResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of GetMetricHistoryResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetMetricHistoryResponse in the Terraform plugin framework type // system. -func (a GetMetricHistoryResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetMetricHistoryResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metrics": basetypes.ListType{ - ElemType: Metric{}.ToAttrType(ctx), + ElemType: Metric{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -2448,9 +2448,9 @@ func (a GetModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelRequest in the Terraform plugin framework type // system. -func (a GetModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2481,13 +2481,13 @@ func (a GetModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of GetModelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelResponse in the Terraform plugin framework type // system. -func (a GetModelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model_databricks": basetypes.ListType{ - ElemType: ModelDatabricks{}.ToAttrType(ctx), + ElemType: ModelDatabricks{}.ToObjectType(ctx), }, }, } @@ -2518,9 +2518,9 @@ func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetModelVersionDownloadUriRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelVersionDownloadUriRequest in the Terraform plugin framework type // system. -func (a GetModelVersionDownloadUriRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelVersionDownloadUriRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2551,9 +2551,9 @@ func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetModelVersionDownloadUriResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelVersionDownloadUriResponse in the Terraform plugin framework type // system. -func (a GetModelVersionDownloadUriResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelVersionDownloadUriResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_uri": types.StringType, @@ -2586,9 +2586,9 @@ func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelVersionRequest in the Terraform plugin framework type // system. -func (a GetModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2620,13 +2620,13 @@ func (a GetModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of GetModelVersionResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetModelVersionResponse in the Terraform plugin framework type // system. -func (a GetModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_version": basetypes.ListType{ - ElemType: ModelVersion{}.ToAttrType(ctx), + ElemType: ModelVersion{}.ToObjectType(ctx), }, }, } @@ -2655,9 +2655,9 @@ func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRegisteredModelPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRegisteredModelPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetRegisteredModelPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRegisteredModelPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model_id": types.StringType, @@ -2689,13 +2689,13 @@ func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// ToAttrType returns the representation of GetRegisteredModelPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetRegisteredModelPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetRegisteredModelPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRegisteredModelPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: RegisteredModelPermissionsDescription{}.ToAttrType(ctx), + ElemType: RegisteredModelPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -2724,9 +2724,9 @@ func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRegisteredModelPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRegisteredModelPermissionsRequest in the Terraform plugin framework type // system. -func (a GetRegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRegisteredModelPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model_id": types.StringType, @@ -2760,9 +2760,9 @@ func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRunRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRunRequest in the Terraform plugin framework type // system. -func (a GetRunRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRunRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.StringType, @@ -2796,13 +2796,13 @@ func (a GetRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of GetRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetRunResponse in the Terraform plugin framework type // system. -func (a GetRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run": basetypes.ListType{ - ElemType: Run{}.ToAttrType(ctx), + ElemType: Run{}.ToObjectType(ctx), }, }, } @@ -2847,9 +2847,9 @@ func (a HttpUrlSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of HttpUrlSpec in the Terraform plugin framework type +// ToObjectType returns the representation of HttpUrlSpec in the Terraform plugin framework type // system. -func (a HttpUrlSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a HttpUrlSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authorization": types.StringType, @@ -2890,9 +2890,9 @@ func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of HttpUrlSpecWithoutSecret in the Terraform plugin framework type +// ToObjectType returns the representation of HttpUrlSpecWithoutSecret in the Terraform plugin framework type // system. -func (a HttpUrlSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { +func (a HttpUrlSpecWithoutSecret) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enable_ssl_verification": types.BoolType, @@ -2925,9 +2925,9 @@ func (a InputTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of InputTag in the Terraform plugin framework type +// ToObjectType returns the representation of InputTag in the Terraform plugin framework type // system. -func (a InputTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a InputTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2964,9 +2964,9 @@ func (a JobSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobSpec in the Terraform plugin framework type +// ToObjectType returns the representation of JobSpec in the Terraform plugin framework type // system. -func (a JobSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_token": types.StringType, @@ -3002,9 +3002,9 @@ func (a JobSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of JobSpecWithoutSecret in the Terraform plugin framework type +// ToObjectType returns the representation of JobSpecWithoutSecret in the Terraform plugin framework type // system. -func (a JobSpecWithoutSecret) ToAttrType(ctx context.Context) types.ObjectType { +func (a JobSpecWithoutSecret) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.StringType, @@ -3049,9 +3049,9 @@ func (a ListArtifactsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListArtifactsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListArtifactsRequest in the Terraform plugin framework type // system. -func (a ListArtifactsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListArtifactsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -3090,13 +3090,13 @@ func (a ListArtifactsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListArtifactsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListArtifactsResponse in the Terraform plugin framework type // system. -func (a ListArtifactsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListArtifactsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "files": basetypes.ListType{ - ElemType: FileInfo{}.ToAttrType(ctx), + ElemType: FileInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "root_uri": types.StringType, @@ -3136,9 +3136,9 @@ func (a ListExperimentsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListExperimentsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListExperimentsRequest in the Terraform plugin framework type // system. -func (a ListExperimentsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExperimentsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -3176,13 +3176,13 @@ func (a ListExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ListExperimentsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListExperimentsResponse in the Terraform plugin framework type // system. -func (a ListExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListExperimentsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiments": basetypes.ListType{ - ElemType: Experiment{}.ToAttrType(ctx), + ElemType: Experiment{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -3214,9 +3214,9 @@ func (a ListModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListModelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListModelsRequest in the Terraform plugin framework type // system. -func (a ListModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListModelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -3251,14 +3251,14 @@ func (a ListModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListModelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListModelsResponse in the Terraform plugin framework type // system. -func (a ListModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListModelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "registered_models": basetypes.ListType{ - ElemType: Model{}.ToAttrType(ctx), + ElemType: Model{}.ToObjectType(ctx), }, }, } @@ -3290,14 +3290,14 @@ func (a ListRegistryWebhooks) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListRegistryWebhooks in the Terraform plugin framework type +// ToObjectType returns the representation of ListRegistryWebhooks in the Terraform plugin framework type // system. -func (a ListRegistryWebhooks) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRegistryWebhooks) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "webhooks": basetypes.ListType{ - ElemType: RegistryWebhook{}.ToAttrType(ctx), + ElemType: RegistryWebhook{}.ToObjectType(ctx), }, }, } @@ -3328,9 +3328,9 @@ func (a ListTransitionRequestsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListTransitionRequestsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListTransitionRequestsRequest in the Terraform plugin framework type // system. -func (a ListTransitionRequestsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTransitionRequestsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -3363,13 +3363,13 @@ func (a ListTransitionRequestsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of ListTransitionRequestsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListTransitionRequestsResponse in the Terraform plugin framework type // system. -func (a ListTransitionRequestsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTransitionRequestsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "requests": basetypes.ListType{ - ElemType: Activity{}.ToAttrType(ctx), + ElemType: Activity{}.ToObjectType(ctx), }, }, } @@ -3407,9 +3407,9 @@ func (a ListWebhooksRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListWebhooksRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListWebhooksRequest in the Terraform plugin framework type // system. -func (a ListWebhooksRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListWebhooksRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "events": basetypes.ListType{ @@ -3456,20 +3456,20 @@ func (a LogBatch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of LogBatch in the Terraform plugin framework type +// ToObjectType returns the representation of LogBatch in the Terraform plugin framework type // system. -func (a LogBatch) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogBatch) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metrics": basetypes.ListType{ - ElemType: Metric{}.ToAttrType(ctx), + ElemType: Metric{}.ToObjectType(ctx), }, "params": basetypes.ListType{ - ElemType: Param{}.ToAttrType(ctx), + ElemType: Param{}.ToObjectType(ctx), }, "run_id": types.StringType, "tags": basetypes.ListType{ - ElemType: RunTag{}.ToAttrType(ctx), + ElemType: RunTag{}.ToObjectType(ctx), }, }, } @@ -3495,9 +3495,9 @@ func (a LogBatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogBatchResponse in the Terraform plugin framework type +// ToObjectType returns the representation of LogBatchResponse in the Terraform plugin framework type // system. -func (a LogBatchResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogBatchResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3529,13 +3529,13 @@ func (a LogInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of LogInputs in the Terraform plugin framework type +// ToObjectType returns the representation of LogInputs in the Terraform plugin framework type // system. -func (a LogInputs) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogInputs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "datasets": basetypes.ListType{ - ElemType: DatasetInput{}.ToAttrType(ctx), + ElemType: DatasetInput{}.ToObjectType(ctx), }, "run_id": types.StringType, }, @@ -3562,9 +3562,9 @@ func (a LogInputsResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogInputsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of LogInputsResponse in the Terraform plugin framework type // system. -func (a LogInputsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogInputsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3603,9 +3603,9 @@ func (a LogMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogMetric in the Terraform plugin framework type +// ToObjectType returns the representation of LogMetric in the Terraform plugin framework type // system. -func (a LogMetric) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogMetric) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -3638,9 +3638,9 @@ func (a LogMetricResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogMetricResponse in the Terraform plugin framework type +// ToObjectType returns the representation of LogMetricResponse in the Terraform plugin framework type // system. -func (a LogMetricResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogMetricResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3670,9 +3670,9 @@ func (a LogModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogModel in the Terraform plugin framework type +// ToObjectType returns the representation of LogModel in the Terraform plugin framework type // system. -func (a LogModel) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogModel) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_json": types.StringType, @@ -3701,9 +3701,9 @@ func (a LogModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogModelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of LogModelResponse in the Terraform plugin framework type // system. -func (a LogModelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogModelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3738,9 +3738,9 @@ func (a LogParam) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogParam in the Terraform plugin framework type +// ToObjectType returns the representation of LogParam in the Terraform plugin framework type // system. -func (a LogParam) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogParam) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -3771,9 +3771,9 @@ func (a LogParamResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogParamResponse in the Terraform plugin framework type +// ToObjectType returns the representation of LogParamResponse in the Terraform plugin framework type // system. -func (a LogParamResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogParamResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3807,9 +3807,9 @@ func (a Metric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Metric in the Terraform plugin framework type +// ToObjectType returns the representation of Metric in the Terraform plugin framework type // system. -func (a Metric) ToAttrType(ctx context.Context) types.ObjectType { +func (a Metric) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -3859,20 +3859,20 @@ func (a Model) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of Model in the Terraform plugin framework type +// ToObjectType returns the representation of Model in the Terraform plugin framework type // system. -func (a Model) ToAttrType(ctx context.Context) types.ObjectType { +func (a Model) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, "description": types.StringType, "last_updated_timestamp": types.Int64Type, "latest_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToAttrType(ctx), + ElemType: ModelVersion{}.ToObjectType(ctx), }, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelTag{}.ToAttrType(ctx), + ElemType: ModelTag{}.ToObjectType(ctx), }, "user_id": types.StringType, }, @@ -3921,9 +3921,9 @@ func (a ModelDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of ModelDatabricks in the Terraform plugin framework type +// ToObjectType returns the representation of ModelDatabricks in the Terraform plugin framework type // system. -func (a ModelDatabricks) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelDatabricks) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -3931,12 +3931,12 @@ func (a ModelDatabricks) ToAttrType(ctx context.Context) types.ObjectType { "id": types.StringType, "last_updated_timestamp": types.Int64Type, "latest_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToAttrType(ctx), + ElemType: ModelVersion{}.ToObjectType(ctx), }, "name": types.StringType, "permission_level": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelTag{}.ToAttrType(ctx), + ElemType: ModelTag{}.ToObjectType(ctx), }, "user_id": types.StringType, }, @@ -3967,9 +3967,9 @@ func (a ModelTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToAttrType returns the representation of ModelTag in the Terraform plugin framework type +// ToObjectType returns the representation of ModelTag in the Terraform plugin framework type // system. -func (a ModelTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -4029,9 +4029,9 @@ func (a ModelVersion) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ModelVersion in the Terraform plugin framework type +// ToObjectType returns the representation of ModelVersion in the Terraform plugin framework type // system. -func (a ModelVersion) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelVersion) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -4045,7 +4045,7 @@ func (a ModelVersion) ToAttrType(ctx context.Context) types.ObjectType { "status": types.StringType, "status_message": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.ToAttrType(ctx), + ElemType: ModelVersionTag{}.ToObjectType(ctx), }, "user_id": types.StringType, "version": types.StringType, @@ -4123,9 +4123,9 @@ func (a ModelVersionDatabricks) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ModelVersionDatabricks in the Terraform plugin framework type +// ToObjectType returns the representation of ModelVersionDatabricks in the Terraform plugin framework type // system. -func (a ModelVersionDatabricks) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelVersionDatabricks) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -4140,7 +4140,7 @@ func (a ModelVersionDatabricks) ToAttrType(ctx context.Context) types.ObjectType "status": types.StringType, "status_message": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.ToAttrType(ctx), + ElemType: ModelVersionTag{}.ToObjectType(ctx), }, "user_id": types.StringType, "version": types.StringType, @@ -4172,9 +4172,9 @@ func (a ModelVersionTag) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ModelVersionTag in the Terraform plugin framework type +// ToObjectType returns the representation of ModelVersionTag in the Terraform plugin framework type // system. -func (a ModelVersionTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelVersionTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -4207,9 +4207,9 @@ func (a Param) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Param in the Terraform plugin framework type +// ToObjectType returns the representation of Param in the Terraform plugin framework type // system. -func (a Param) ToAttrType(ctx context.Context) types.ObjectType { +func (a Param) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -4246,9 +4246,9 @@ func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of RegisteredModelAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelAccessControlRequest in the Terraform plugin framework type // system. -func (a RegisteredModelAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -4291,13 +4291,13 @@ func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of RegisteredModelAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelAccessControlResponse in the Terraform plugin framework type // system. -func (a RegisteredModelAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: RegisteredModelPermission{}.ToAttrType(ctx), + ElemType: RegisteredModelPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -4334,9 +4334,9 @@ func (a RegisteredModelPermission) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of RegisteredModelPermission in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelPermission in the Terraform plugin framework type // system. -func (a RegisteredModelPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -4375,13 +4375,13 @@ func (a RegisteredModelPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of RegisteredModelPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelPermissions in the Terraform plugin framework type // system. -func (a RegisteredModelPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RegisteredModelAccessControlResponse{}.ToAttrType(ctx), + ElemType: RegisteredModelAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -4412,9 +4412,9 @@ func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of RegisteredModelPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelPermissionsDescription in the Terraform plugin framework type // system. -func (a RegisteredModelPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -4448,13 +4448,13 @@ func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of RegisteredModelPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RegisteredModelPermissionsRequest in the Terraform plugin framework type // system. -func (a RegisteredModelPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegisteredModelPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RegisteredModelAccessControlRequest{}.ToAttrType(ctx), + ElemType: RegisteredModelAccessControlRequest{}.ToObjectType(ctx), }, "registered_model_id": types.StringType, }, @@ -4542,9 +4542,9 @@ func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of RegistryWebhook in the Terraform plugin framework type +// ToObjectType returns the representation of RegistryWebhook in the Terraform plugin framework type // system. -func (a RegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { +func (a RegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -4553,11 +4553,11 @@ func (a RegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpecWithoutSecret{}.ToAttrType(ctx), + ElemType: HttpUrlSpecWithoutSecret{}.ToObjectType(ctx), }, "id": types.StringType, "job_spec": basetypes.ListType{ - ElemType: JobSpecWithoutSecret{}.ToAttrType(ctx), + ElemType: JobSpecWithoutSecret{}.ToObjectType(ctx), }, "last_updated_timestamp": types.Int64Type, "model_name": types.StringType, @@ -4602,9 +4602,9 @@ func (a RejectTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of RejectTransitionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RejectTransitionRequest in the Terraform plugin framework type // system. -func (a RejectTransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RejectTransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4639,13 +4639,13 @@ func (a RejectTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of RejectTransitionRequestResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RejectTransitionRequestResponse in the Terraform plugin framework type // system. -func (a RejectTransitionRequestResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RejectTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activity": basetypes.ListType{ - ElemType: Activity{}.ToAttrType(ctx), + ElemType: Activity{}.ToObjectType(ctx), }, }, } @@ -4675,9 +4675,9 @@ func (a RenameModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of RenameModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RenameModelRequest in the Terraform plugin framework type // system. -func (a RenameModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RenameModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -4709,13 +4709,13 @@ func (a RenameModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of RenameModelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RenameModelResponse in the Terraform plugin framework type // system. -func (a RenameModelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RenameModelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model": basetypes.ListType{ - ElemType: Model{}.ToAttrType(ctx), + ElemType: Model{}.ToObjectType(ctx), }, }, } @@ -4743,9 +4743,9 @@ func (a RestoreExperiment) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreExperiment in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreExperiment in the Terraform plugin framework type // system. -func (a RestoreExperiment) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreExperiment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -4773,9 +4773,9 @@ func (a RestoreExperimentResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreExperimentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreExperimentResponse in the Terraform plugin framework type // system. -func (a RestoreExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4803,9 +4803,9 @@ func (a RestoreRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreRun in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreRun in the Terraform plugin framework type // system. -func (a RestoreRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.StringType, @@ -4833,9 +4833,9 @@ func (a RestoreRunResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreRunResponse in the Terraform plugin framework type // system. -func (a RestoreRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4870,9 +4870,9 @@ func (a RestoreRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreRuns in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreRuns in the Terraform plugin framework type // system. -func (a RestoreRuns) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreRuns) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -4904,9 +4904,9 @@ func (a RestoreRunsResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreRunsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreRunsResponse in the Terraform plugin framework type // system. -func (a RestoreRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "runs_restored": types.Int64Type, @@ -4944,19 +4944,19 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToAttrType returns the representation of Run in the Terraform plugin framework type +// ToObjectType returns the representation of Run in the Terraform plugin framework type // system. -func (a Run) ToAttrType(ctx context.Context) types.ObjectType { +func (a Run) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data": basetypes.ListType{ - ElemType: RunData{}.ToAttrType(ctx), + ElemType: RunData{}.ToObjectType(ctx), }, "info": basetypes.ListType{ - ElemType: RunInfo{}.ToAttrType(ctx), + ElemType: RunInfo{}.ToObjectType(ctx), }, "inputs": basetypes.ListType{ - ElemType: RunInputs{}.ToAttrType(ctx), + ElemType: RunInputs{}.ToObjectType(ctx), }, }, } @@ -4992,19 +4992,19 @@ func (a RunData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of RunData in the Terraform plugin framework type +// ToObjectType returns the representation of RunData in the Terraform plugin framework type // system. -func (a RunData) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunData) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metrics": basetypes.ListType{ - ElemType: Metric{}.ToAttrType(ctx), + ElemType: Metric{}.ToObjectType(ctx), }, "params": basetypes.ListType{ - ElemType: Param{}.ToAttrType(ctx), + ElemType: Param{}.ToObjectType(ctx), }, "tags": basetypes.ListType{ - ElemType: RunTag{}.ToAttrType(ctx), + ElemType: RunTag{}.ToObjectType(ctx), }, }, } @@ -5054,9 +5054,9 @@ func (a RunInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RunInfo in the Terraform plugin framework type // system. -func (a RunInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_uri": types.StringType, @@ -5096,13 +5096,13 @@ func (a RunInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of RunInputs in the Terraform plugin framework type +// ToObjectType returns the representation of RunInputs in the Terraform plugin framework type // system. -func (a RunInputs) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunInputs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset_inputs": basetypes.ListType{ - ElemType: DatasetInput{}.ToAttrType(ctx), + ElemType: DatasetInput{}.ToObjectType(ctx), }, }, } @@ -5132,9 +5132,9 @@ func (a RunTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of RunTag in the Terraform plugin framework type +// ToObjectType returns the representation of RunTag in the Terraform plugin framework type // system. -func (a RunTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a RunTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5180,9 +5180,9 @@ func (a SearchExperiments) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of SearchExperiments in the Terraform plugin framework type +// ToObjectType returns the representation of SearchExperiments in the Terraform plugin framework type // system. -func (a SearchExperiments) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchExperiments) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -5223,13 +5223,13 @@ func (a SearchExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of SearchExperimentsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SearchExperimentsResponse in the Terraform plugin framework type // system. -func (a SearchExperimentsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchExperimentsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiments": basetypes.ListType{ - ElemType: Experiment{}.ToAttrType(ctx), + ElemType: Experiment{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -5271,9 +5271,9 @@ func (a SearchModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of SearchModelVersionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SearchModelVersionsRequest in the Terraform plugin framework type // system. -func (a SearchModelVersionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchModelVersionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -5313,13 +5313,13 @@ func (a SearchModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of SearchModelVersionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SearchModelVersionsResponse in the Terraform plugin framework type // system. -func (a SearchModelVersionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchModelVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToAttrType(ctx), + ElemType: ModelVersion{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -5361,9 +5361,9 @@ func (a SearchModelsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of SearchModelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SearchModelsRequest in the Terraform plugin framework type // system. -func (a SearchModelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchModelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -5402,14 +5402,14 @@ func (a SearchModelsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of SearchModelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SearchModelsResponse in the Terraform plugin framework type // system. -func (a SearchModelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchModelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "registered_models": basetypes.ListType{ - ElemType: Model{}.ToAttrType(ctx), + ElemType: Model{}.ToObjectType(ctx), }, }, } @@ -5467,9 +5467,9 @@ func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of SearchRuns in the Terraform plugin framework type +// ToObjectType returns the representation of SearchRuns in the Terraform plugin framework type // system. -func (a SearchRuns) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchRuns) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_ids": basetypes.ListType{ @@ -5512,14 +5512,14 @@ func (a SearchRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of SearchRunsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SearchRunsResponse in the Terraform plugin framework type // system. -func (a SearchRunsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SearchRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "runs": basetypes.ListType{ - ElemType: Run{}.ToAttrType(ctx), + ElemType: Run{}.ToObjectType(ctx), }, }, } @@ -5554,9 +5554,9 @@ func (a SetExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetExperimentTag in the Terraform plugin framework type +// ToObjectType returns the representation of SetExperimentTag in the Terraform plugin framework type // system. -func (a SetExperimentTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetExperimentTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -5586,9 +5586,9 @@ func (a SetExperimentTagResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetExperimentTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetExperimentTagResponse in the Terraform plugin framework type // system. -func (a SetExperimentTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetExperimentTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5625,9 +5625,9 @@ func (a SetModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetModelTagRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SetModelTagRequest in the Terraform plugin framework type // system. -func (a SetModelTagRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetModelTagRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5657,9 +5657,9 @@ func (a SetModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetModelTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetModelTagResponse in the Terraform plugin framework type // system. -func (a SetModelTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetModelTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5698,9 +5698,9 @@ func (a SetModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetModelVersionTagRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SetModelVersionTagRequest in the Terraform plugin framework type // system. -func (a SetModelVersionTagRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetModelVersionTagRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5731,9 +5731,9 @@ func (a SetModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetModelVersionTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetModelVersionTagResponse in the Terraform plugin framework type // system. -func (a SetModelVersionTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetModelVersionTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5771,9 +5771,9 @@ func (a SetTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetTag in the Terraform plugin framework type +// ToObjectType returns the representation of SetTag in the Terraform plugin framework type // system. -func (a SetTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5804,9 +5804,9 @@ func (a SetTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetTagResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetTagResponse in the Terraform plugin framework type // system. -func (a SetTagResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetTagResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5837,9 +5837,9 @@ func (a TestRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of TestRegistryWebhook in the Terraform plugin framework type +// ToObjectType returns the representation of TestRegistryWebhook in the Terraform plugin framework type // system. -func (a TestRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { +func (a TestRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "body": types.StringType, @@ -5874,9 +5874,9 @@ func (a TestRegistryWebhookRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of TestRegistryWebhookRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TestRegistryWebhookRequest in the Terraform plugin framework type // system. -func (a TestRegistryWebhookRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TestRegistryWebhookRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "event": types.StringType, @@ -5909,13 +5909,13 @@ func (a TestRegistryWebhookResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of TestRegistryWebhookResponse in the Terraform plugin framework type +// ToObjectType returns the representation of TestRegistryWebhookResponse in the Terraform plugin framework type // system. -func (a TestRegistryWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a TestRegistryWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "webhook": basetypes.ListType{ - ElemType: TestRegistryWebhook{}.ToAttrType(ctx), + ElemType: TestRegistryWebhook{}.ToObjectType(ctx), }, }, } @@ -5960,9 +5960,9 @@ func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of TransitionModelVersionStageDatabricks in the Terraform plugin framework type +// ToObjectType returns the representation of TransitionModelVersionStageDatabricks in the Terraform plugin framework type // system. -func (a TransitionModelVersionStageDatabricks) ToAttrType(ctx context.Context) types.ObjectType { +func (a TransitionModelVersionStageDatabricks) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "archive_existing_versions": types.BoolType, @@ -6016,9 +6016,9 @@ func (a TransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of TransitionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TransitionRequest in the Terraform plugin framework type // system. -func (a TransitionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "available_actions": basetypes.ListType{ @@ -6055,13 +6055,13 @@ func (a TransitionStageResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of TransitionStageResponse in the Terraform plugin framework type +// ToObjectType returns the representation of TransitionStageResponse in the Terraform plugin framework type // system. -func (a TransitionStageResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a TransitionStageResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_version": basetypes.ListType{ - ElemType: ModelVersionDatabricks{}.ToAttrType(ctx), + ElemType: ModelVersionDatabricks{}.ToObjectType(ctx), }, }, } @@ -6091,9 +6091,9 @@ func (a UpdateComment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateComment in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateComment in the Terraform plugin framework type // system. -func (a UpdateComment) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateComment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -6126,13 +6126,13 @@ func (a UpdateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateCommentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCommentResponse in the Terraform plugin framework type // system. -func (a UpdateCommentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCommentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": basetypes.ListType{ - ElemType: CommentObject{}.ToAttrType(ctx), + ElemType: CommentObject{}.ToObjectType(ctx), }, }, } @@ -6163,9 +6163,9 @@ func (a UpdateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateExperiment in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExperiment in the Terraform plugin framework type // system. -func (a UpdateExperiment) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExperiment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -6194,9 +6194,9 @@ func (a UpdateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateExperimentResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateExperimentResponse in the Terraform plugin framework type // system. -func (a UpdateExperimentResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6226,9 +6226,9 @@ func (a UpdateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateModelRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateModelRequest in the Terraform plugin framework type // system. -func (a UpdateModelRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateModelRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6257,9 +6257,9 @@ func (a UpdateModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateModelResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateModelResponse in the Terraform plugin framework type // system. -func (a UpdateModelResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateModelResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6291,9 +6291,9 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type // system. -func (a UpdateModelVersionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6323,9 +6323,9 @@ func (a UpdateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateModelVersionResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateModelVersionResponse in the Terraform plugin framework type // system. -func (a UpdateModelVersionResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6406,9 +6406,9 @@ func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of UpdateRegistryWebhook in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRegistryWebhook in the Terraform plugin framework type // system. -func (a UpdateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6416,11 +6416,11 @@ func (a UpdateRegistryWebhook) ToAttrType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpec{}.ToAttrType(ctx), + ElemType: HttpUrlSpec{}.ToObjectType(ctx), }, "id": types.StringType, "job_spec": basetypes.ListType{ - ElemType: JobSpec{}.ToAttrType(ctx), + ElemType: JobSpec{}.ToObjectType(ctx), }, "status": types.StringType, }, @@ -6456,9 +6456,9 @@ func (a UpdateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateRun in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRun in the Terraform plugin framework type // system. -func (a UpdateRun) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRun) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time": types.Int64Type, @@ -6493,13 +6493,13 @@ func (a UpdateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of UpdateRunResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRunResponse in the Terraform plugin framework type // system. -func (a UpdateRunResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRunResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_info": basetypes.ListType{ - ElemType: RunInfo{}.ToAttrType(ctx), + ElemType: RunInfo{}.ToObjectType(ctx), }, }, } @@ -6525,9 +6525,9 @@ func (a UpdateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateWebhookResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateWebhookResponse in the Terraform plugin framework type // system. -func (a UpdateWebhookResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 18c8733754..53448032dd 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -55,9 +55,9 @@ func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of CreateCustomAppIntegration in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCustomAppIntegration in the Terraform plugin framework type // system. -func (a CreateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCustomAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "confidential": types.BoolType, @@ -69,7 +69,7 @@ func (a CreateCustomAppIntegration) ToAttrType(ctx context.Context) types.Object ElemType: types.StringType, }, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + ElemType: TokenAccessPolicy{}.ToObjectType(ctx), }, }, } @@ -102,9 +102,9 @@ func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateCustomAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCustomAppIntegrationOutput in the Terraform plugin framework type // system. -func (a CreateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "client_id": types.StringType, @@ -141,14 +141,14 @@ func (a CreatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of CreatePublishedAppIntegration in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePublishedAppIntegration in the Terraform plugin framework type // system. -func (a CreatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePublishedAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_id": types.StringType, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + ElemType: TokenAccessPolicy{}.ToObjectType(ctx), }, }, } @@ -176,9 +176,9 @@ func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreatePublishedAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePublishedAppIntegrationOutput in the Terraform plugin framework type // system. -func (a CreatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -209,9 +209,9 @@ func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateServicePrincipalSecretRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateServicePrincipalSecretRequest in the Terraform plugin framework type // system. -func (a CreateServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateServicePrincipalSecretRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "service_principal_id": types.Int64Type, @@ -251,9 +251,9 @@ func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateServicePrincipalSecretResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateServicePrincipalSecretResponse in the Terraform plugin framework type // system. -func (a CreateServicePrincipalSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateServicePrincipalSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -290,9 +290,9 @@ func (a DataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of DataPlaneInfo in the Terraform plugin framework type +// ToObjectType returns the representation of DataPlaneInfo in the Terraform plugin framework type // system. -func (a DataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a DataPlaneInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authorization_details": types.StringType, @@ -321,9 +321,9 @@ func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCustomAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCustomAppIntegrationOutput in the Terraform plugin framework type // system. -func (a DeleteCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -351,9 +351,9 @@ func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCustomAppIntegrationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCustomAppIntegrationRequest in the Terraform plugin framework type // system. -func (a DeleteCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCustomAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -381,9 +381,9 @@ func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePublishedAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePublishedAppIntegrationOutput in the Terraform plugin framework type // system. -func (a DeletePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -411,9 +411,9 @@ func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePublishedAppIntegrationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePublishedAppIntegrationRequest in the Terraform plugin framework type // system. -func (a DeletePublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePublishedAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -441,9 +441,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -474,9 +474,9 @@ func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteServicePrincipalSecretRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteServicePrincipalSecretRequest in the Terraform plugin framework type // system. -func (a DeleteServicePrincipalSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteServicePrincipalSecretRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "secret_id": types.StringType, @@ -530,9 +530,9 @@ func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of GetCustomAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of GetCustomAppIntegrationOutput in the Terraform plugin framework type // system. -func (a GetCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "client_id": types.StringType, @@ -549,7 +549,7 @@ func (a GetCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.Obj ElemType: types.StringType, }, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + ElemType: TokenAccessPolicy{}.ToObjectType(ctx), }, }, } @@ -578,9 +578,9 @@ func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCustomAppIntegrationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetCustomAppIntegrationRequest in the Terraform plugin framework type // system. -func (a GetCustomAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCustomAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -614,13 +614,13 @@ func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of GetCustomAppIntegrationsOutput in the Terraform plugin framework type +// ToObjectType returns the representation of GetCustomAppIntegrationsOutput in the Terraform plugin framework type // system. -func (a GetCustomAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCustomAppIntegrationsOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: GetCustomAppIntegrationOutput{}.ToAttrType(ctx), + ElemType: GetCustomAppIntegrationOutput{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -661,9 +661,9 @@ func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of GetPublishedAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of GetPublishedAppIntegrationOutput in the Terraform plugin framework type // system. -func (a GetPublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_id": types.StringType, @@ -672,7 +672,7 @@ func (a GetPublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types. "integration_id": types.StringType, "name": types.StringType, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + ElemType: TokenAccessPolicy{}.ToObjectType(ctx), }, }, } @@ -700,9 +700,9 @@ func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPublishedAppIntegrationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPublishedAppIntegrationRequest in the Terraform plugin framework type // system. -func (a GetPublishedAppIntegrationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPublishedAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -736,13 +736,13 @@ func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of GetPublishedAppIntegrationsOutput in the Terraform plugin framework type +// ToObjectType returns the representation of GetPublishedAppIntegrationsOutput in the Terraform plugin framework type // system. -func (a GetPublishedAppIntegrationsOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPublishedAppIntegrationsOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: GetPublishedAppIntegrationOutput{}.ToAttrType(ctx), + ElemType: GetPublishedAppIntegrationOutput{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -776,13 +776,13 @@ func (a GetPublishedAppsOutput) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of GetPublishedAppsOutput in the Terraform plugin framework type +// ToObjectType returns the representation of GetPublishedAppsOutput in the Terraform plugin framework type // system. -func (a GetPublishedAppsOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPublishedAppsOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: PublishedAppOutput{}.ToAttrType(ctx), + ElemType: PublishedAppOutput{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -815,9 +815,9 @@ func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListCustomAppIntegrationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListCustomAppIntegrationsRequest in the Terraform plugin framework type // system. -func (a ListCustomAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListCustomAppIntegrationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_creator_username": types.BoolType, @@ -852,9 +852,9 @@ func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListOAuthPublishedAppsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListOAuthPublishedAppsRequest in the Terraform plugin framework type // system. -func (a ListOAuthPublishedAppsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListOAuthPublishedAppsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -887,9 +887,9 @@ func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListPublishedAppIntegrationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListPublishedAppIntegrationsRequest in the Terraform plugin framework type // system. -func (a ListPublishedAppIntegrationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPublishedAppIntegrationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -931,9 +931,9 @@ func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListServicePrincipalSecretsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListServicePrincipalSecretsRequest in the Terraform plugin framework type // system. -func (a ListServicePrincipalSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListServicePrincipalSecretsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -968,14 +968,14 @@ func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes(ctx context.Co } } -// ToAttrType returns the representation of ListServicePrincipalSecretsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListServicePrincipalSecretsResponse in the Terraform plugin framework type // system. -func (a ListServicePrincipalSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListServicePrincipalSecretsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "secrets": basetypes.ListType{ - ElemType: SecretInfo{}.ToAttrType(ctx), + ElemType: SecretInfo{}.ToObjectType(ctx), }, }, } @@ -1020,9 +1020,9 @@ func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of PublishedAppOutput in the Terraform plugin framework type +// ToObjectType returns the representation of PublishedAppOutput in the Terraform plugin framework type // system. -func (a PublishedAppOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a PublishedAppOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_id": types.StringType, @@ -1070,9 +1070,9 @@ func (a SecretInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of SecretInfo in the Terraform plugin framework type +// ToObjectType returns the representation of SecretInfo in the Terraform plugin framework type // system. -func (a SecretInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a SecretInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -1108,9 +1108,9 @@ func (a TokenAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of TokenAccessPolicy in the Terraform plugin framework type +// ToObjectType returns the representation of TokenAccessPolicy in the Terraform plugin framework type // system. -func (a TokenAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenAccessPolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_token_ttl_in_minutes": types.Int64Type, @@ -1148,9 +1148,9 @@ func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of UpdateCustomAppIntegration in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCustomAppIntegration in the Terraform plugin framework type // system. -func (a UpdateCustomAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCustomAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -1158,7 +1158,7 @@ func (a UpdateCustomAppIntegration) ToAttrType(ctx context.Context) types.Object ElemType: types.StringType, }, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + ElemType: TokenAccessPolicy{}.ToObjectType(ctx), }, }, } @@ -1184,9 +1184,9 @@ func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateCustomAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCustomAppIntegrationOutput in the Terraform plugin framework type // system. -func (a UpdateCustomAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1217,14 +1217,14 @@ func (a UpdatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of UpdatePublishedAppIntegration in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePublishedAppIntegration in the Terraform plugin framework type // system. -func (a UpdatePublishedAppIntegration) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePublishedAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToAttrType(ctx), + ElemType: TokenAccessPolicy{}.ToObjectType(ctx), }, }, } @@ -1250,9 +1250,9 @@ func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdatePublishedAppIntegrationOutput in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePublishedAppIntegrationOutput in the Terraform plugin framework type // system. -func (a UpdatePublishedAppIntegrationOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index ff264b0bbc..02b1e8273c 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -112,9 +112,9 @@ func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of CreatePipeline in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePipeline in the Terraform plugin framework type // system. -func (a CreatePipeline) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePipeline) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_duplicate_names": types.BoolType, @@ -122,45 +122,45 @@ func (a CreatePipeline) ToAttrType(ctx context.Context) types.ObjectType { "catalog": types.StringType, "channel": types.StringType, "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.ToAttrType(ctx), + ElemType: PipelineCluster{}.ToObjectType(ctx), }, "configuration": basetypes.MapType{ ElemType: types.StringType, }, "continuous": types.BoolType, "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.ToAttrType(ctx), + ElemType: PipelineDeployment{}.ToObjectType(ctx), }, "development": types.BoolType, "dry_run": types.BoolType, "edition": types.StringType, "filters": basetypes.ListType{ - ElemType: Filters{}.ToAttrType(ctx), + ElemType: Filters{}.ToObjectType(ctx), }, "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + ElemType: IngestionGatewayPipelineDefinition{}.ToObjectType(ctx), }, "id": types.StringType, "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.ToAttrType(ctx), + ElemType: IngestionPipelineDefinition{}.ToObjectType(ctx), }, "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.ToAttrType(ctx), + ElemType: PipelineLibrary{}.ToObjectType(ctx), }, "name": types.StringType, "notifications": basetypes.ListType{ - ElemType: Notifications{}.ToAttrType(ctx), + ElemType: Notifications{}.ToObjectType(ctx), }, "photon": types.BoolType, "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.ToAttrType(ctx), + ElemType: RestartWindow{}.ToObjectType(ctx), }, "schema": types.StringType, "serverless": types.BoolType, "storage": types.StringType, "target": types.StringType, "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.ToAttrType(ctx), + ElemType: PipelineTrigger{}.ToObjectType(ctx), }, }, } @@ -193,13 +193,13 @@ func (a CreatePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CreatePipelineResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePipelineResponse in the Terraform plugin framework type // system. -func (a CreatePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "effective_settings": basetypes.ListType{ - ElemType: PipelineSpec{}.ToAttrType(ctx), + ElemType: PipelineSpec{}.ToObjectType(ctx), }, "pipeline_id": types.StringType, }, @@ -229,9 +229,9 @@ func (a CronTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of CronTrigger in the Terraform plugin framework type +// ToObjectType returns the representation of CronTrigger in the Terraform plugin framework type // system. -func (a CronTrigger) ToAttrType(ctx context.Context) types.ObjectType { +func (a CronTrigger) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "quartz_cron_schedule": types.StringType, @@ -264,9 +264,9 @@ func (a DataPlaneId) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of DataPlaneId in the Terraform plugin framework type +// ToObjectType returns the representation of DataPlaneId in the Terraform plugin framework type // system. -func (a DataPlaneId) ToAttrType(ctx context.Context) types.ObjectType { +func (a DataPlaneId) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance": types.StringType, @@ -297,9 +297,9 @@ func (a DeletePipelineRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePipelineRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePipelineRequest in the Terraform plugin framework type // system. -func (a DeletePipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePipelineRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -327,9 +327,9 @@ func (a DeletePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePipelineResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePipelineResponse in the Terraform plugin framework type // system. -func (a DeletePipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -430,9 +430,9 @@ func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of EditPipeline in the Terraform plugin framework type +// ToObjectType returns the representation of EditPipeline in the Terraform plugin framework type // system. -func (a EditPipeline) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditPipeline) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_duplicate_names": types.BoolType, @@ -440,46 +440,46 @@ func (a EditPipeline) ToAttrType(ctx context.Context) types.ObjectType { "catalog": types.StringType, "channel": types.StringType, "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.ToAttrType(ctx), + ElemType: PipelineCluster{}.ToObjectType(ctx), }, "configuration": basetypes.MapType{ ElemType: types.StringType, }, "continuous": types.BoolType, "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.ToAttrType(ctx), + ElemType: PipelineDeployment{}.ToObjectType(ctx), }, "development": types.BoolType, "edition": types.StringType, "expected_last_modified": types.Int64Type, "filters": basetypes.ListType{ - ElemType: Filters{}.ToAttrType(ctx), + ElemType: Filters{}.ToObjectType(ctx), }, "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + ElemType: IngestionGatewayPipelineDefinition{}.ToObjectType(ctx), }, "id": types.StringType, "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.ToAttrType(ctx), + ElemType: IngestionPipelineDefinition{}.ToObjectType(ctx), }, "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.ToAttrType(ctx), + ElemType: PipelineLibrary{}.ToObjectType(ctx), }, "name": types.StringType, "notifications": basetypes.ListType{ - ElemType: Notifications{}.ToAttrType(ctx), + ElemType: Notifications{}.ToObjectType(ctx), }, "photon": types.BoolType, "pipeline_id": types.StringType, "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.ToAttrType(ctx), + ElemType: RestartWindow{}.ToObjectType(ctx), }, "schema": types.StringType, "serverless": types.BoolType, "storage": types.StringType, "target": types.StringType, "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.ToAttrType(ctx), + ElemType: PipelineTrigger{}.ToObjectType(ctx), }, }, } @@ -505,9 +505,9 @@ func (a EditPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of EditPipelineResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EditPipelineResponse in the Terraform plugin framework type // system. -func (a EditPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -539,13 +539,13 @@ func (a ErrorDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of ErrorDetail in the Terraform plugin framework type +// ToObjectType returns the representation of ErrorDetail in the Terraform plugin framework type // system. -func (a ErrorDetail) ToAttrType(ctx context.Context) types.ObjectType { +func (a ErrorDetail) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exceptions": basetypes.ListType{ - ElemType: SerializedException{}.ToAttrType(ctx), + ElemType: SerializedException{}.ToObjectType(ctx), }, "fatal": types.BoolType, }, @@ -574,9 +574,9 @@ func (a FileLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of FileLibrary in the Terraform plugin framework type +// ToObjectType returns the representation of FileLibrary in the Terraform plugin framework type // system. -func (a FileLibrary) ToAttrType(ctx context.Context) types.ObjectType { +func (a FileLibrary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -611,9 +611,9 @@ func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of Filters in the Terraform plugin framework type +// ToObjectType returns the representation of Filters in the Terraform plugin framework type // system. -func (a Filters) ToAttrType(ctx context.Context) types.ObjectType { +func (a Filters) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exclude": basetypes.ListType{ @@ -649,9 +649,9 @@ func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPipelinePermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPipelinePermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetPipelinePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPipelinePermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -683,13 +683,13 @@ func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Co } } -// ToAttrType returns the representation of GetPipelinePermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetPipelinePermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetPipelinePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPipelinePermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: PipelinePermissionsDescription{}.ToAttrType(ctx), + ElemType: PipelinePermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -718,9 +718,9 @@ func (a GetPipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPipelinePermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPipelinePermissionsRequest in the Terraform plugin framework type // system. -func (a GetPipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPipelinePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -750,9 +750,9 @@ func (a GetPipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPipelineRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPipelineRequest in the Terraform plugin framework type // system. -func (a GetPipelineRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPipelineRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -809,9 +809,9 @@ func (a GetPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of GetPipelineResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetPipelineResponse in the Terraform plugin framework type // system. -func (a GetPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, @@ -821,13 +821,13 @@ func (a GetPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { "health": types.StringType, "last_modified": types.Int64Type, "latest_updates": basetypes.ListType{ - ElemType: UpdateStateInfo{}.ToAttrType(ctx), + ElemType: UpdateStateInfo{}.ToObjectType(ctx), }, "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, "spec": basetypes.ListType{ - ElemType: PipelineSpec{}.ToAttrType(ctx), + ElemType: PipelineSpec{}.ToObjectType(ctx), }, "state": types.StringType, }, @@ -859,9 +859,9 @@ func (a GetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetUpdateRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetUpdateRequest in the Terraform plugin framework type // system. -func (a GetUpdateRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetUpdateRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -894,13 +894,13 @@ func (a GetUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of GetUpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetUpdateResponse in the Terraform plugin framework type // system. -func (a GetUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetUpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "update": basetypes.ListType{ - ElemType: UpdateInfo{}.ToAttrType(ctx), + ElemType: UpdateInfo{}.ToObjectType(ctx), }, }, } @@ -936,19 +936,19 @@ func (a IngestionConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of IngestionConfig in the Terraform plugin framework type +// ToObjectType returns the representation of IngestionConfig in the Terraform plugin framework type // system. -func (a IngestionConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a IngestionConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "report": basetypes.ListType{ - ElemType: ReportSpec{}.ToAttrType(ctx), + ElemType: ReportSpec{}.ToObjectType(ctx), }, "schema": basetypes.ListType{ - ElemType: SchemaSpec{}.ToAttrType(ctx), + ElemType: SchemaSpec{}.ToObjectType(ctx), }, "table": basetypes.ListType{ - ElemType: TableSpec{}.ToAttrType(ctx), + ElemType: TableSpec{}.ToObjectType(ctx), }, }, } @@ -992,9 +992,9 @@ func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of IngestionGatewayPipelineDefinition in the Terraform plugin framework type +// ToObjectType returns the representation of IngestionGatewayPipelineDefinition in the Terraform plugin framework type // system. -func (a IngestionGatewayPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { +func (a IngestionGatewayPipelineDefinition) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connection_id": types.StringType, @@ -1043,18 +1043,18 @@ func (a IngestionPipelineDefinition) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of IngestionPipelineDefinition in the Terraform plugin framework type +// ToObjectType returns the representation of IngestionPipelineDefinition in the Terraform plugin framework type // system. -func (a IngestionPipelineDefinition) ToAttrType(ctx context.Context) types.ObjectType { +func (a IngestionPipelineDefinition) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connection_name": types.StringType, "ingestion_gateway_id": types.StringType, "objects": basetypes.ListType{ - ElemType: IngestionConfig{}.ToAttrType(ctx), + ElemType: IngestionConfig{}.ToObjectType(ctx), }, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToAttrType(ctx), + ElemType: TableSpecificConfig{}.ToObjectType(ctx), }, }, } @@ -1106,9 +1106,9 @@ func (a ListPipelineEventsRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ListPipelineEventsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListPipelineEventsRequest in the Terraform plugin framework type // system. -func (a ListPipelineEventsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPipelineEventsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -1150,13 +1150,13 @@ func (a ListPipelineEventsResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListPipelineEventsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListPipelineEventsResponse in the Terraform plugin framework type // system. -func (a ListPipelineEventsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPipelineEventsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "events": basetypes.ListType{ - ElemType: PipelineEvent{}.ToAttrType(ctx), + ElemType: PipelineEvent{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -1208,9 +1208,9 @@ func (a ListPipelinesRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListPipelinesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListPipelinesRequest in the Terraform plugin framework type // system. -func (a ListPipelinesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPipelinesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -1249,14 +1249,14 @@ func (a ListPipelinesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListPipelinesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListPipelinesResponse in the Terraform plugin framework type // system. -func (a ListPipelinesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPipelinesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "statuses": basetypes.ListType{ - ElemType: PipelineStateInfo{}.ToAttrType(ctx), + ElemType: PipelineStateInfo{}.ToObjectType(ctx), }, }, } @@ -1291,9 +1291,9 @@ func (a ListUpdatesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListUpdatesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListUpdatesRequest in the Terraform plugin framework type // system. -func (a ListUpdatesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListUpdatesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -1334,15 +1334,15 @@ func (a ListUpdatesResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListUpdatesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListUpdatesResponse in the Terraform plugin framework type // system. -func (a ListUpdatesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListUpdatesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "prev_page_token": types.StringType, "updates": basetypes.ListType{ - ElemType: UpdateInfo{}.ToAttrType(ctx), + ElemType: UpdateInfo{}.ToObjectType(ctx), }, }, } @@ -1368,9 +1368,9 @@ func (a ManualTrigger) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ManualTrigger in the Terraform plugin framework type +// ToObjectType returns the representation of ManualTrigger in the Terraform plugin framework type // system. -func (a ManualTrigger) ToAttrType(ctx context.Context) types.ObjectType { +func (a ManualTrigger) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1398,9 +1398,9 @@ func (a NotebookLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of NotebookLibrary in the Terraform plugin framework type +// ToObjectType returns the representation of NotebookLibrary in the Terraform plugin framework type // system. -func (a NotebookLibrary) ToAttrType(ctx context.Context) types.ObjectType { +func (a NotebookLibrary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -1441,9 +1441,9 @@ func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of Notifications in the Terraform plugin framework type +// ToObjectType returns the representation of Notifications in the Terraform plugin framework type // system. -func (a Notifications) ToAttrType(ctx context.Context) types.ObjectType { +func (a Notifications) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alerts": basetypes.ListType{ @@ -1511,9 +1511,9 @@ func (a Origin) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Origin in the Terraform plugin framework type +// ToObjectType returns the representation of Origin in the Terraform plugin framework type // system. -func (a Origin) ToAttrType(ctx context.Context) types.ObjectType { +func (a Origin) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "batch_id": types.Int64Type, @@ -1565,9 +1565,9 @@ func (a PipelineAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelineAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineAccessControlRequest in the Terraform plugin framework type // system. -func (a PipelineAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1610,13 +1610,13 @@ func (a PipelineAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of PipelineAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineAccessControlResponse in the Terraform plugin framework type // system. -func (a PipelineAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: PipelinePermission{}.ToAttrType(ctx), + ElemType: PipelinePermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1751,23 +1751,23 @@ func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of PipelineCluster in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineCluster in the Terraform plugin framework type // system. -func (a PipelineCluster) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineCluster) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: PipelineClusterAutoscale{}.ToAttrType(ctx), + ElemType: PipelineClusterAutoscale{}.ToObjectType(ctx), }, "aws_attributes": basetypes.ListType{ - ElemType: compute_tf.AwsAttributes{}.ToAttrType(ctx), + ElemType: compute_tf.AwsAttributes{}.ToObjectType(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: compute_tf.AzureAttributes{}.ToAttrType(ctx), + ElemType: compute_tf.AzureAttributes{}.ToObjectType(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: compute_tf.ClusterLogConf{}.ToAttrType(ctx), + ElemType: compute_tf.ClusterLogConf{}.ToObjectType(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, @@ -1776,10 +1776,10 @@ func (a PipelineCluster) ToAttrType(ctx context.Context) types.ObjectType { "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: compute_tf.GcpAttributes{}.ToAttrType(ctx), + ElemType: compute_tf.GcpAttributes{}.ToObjectType(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: compute_tf.InitScriptInfo{}.ToAttrType(ctx), + ElemType: compute_tf.InitScriptInfo{}.ToObjectType(ctx), }, "instance_pool_id": types.StringType, "label": types.StringType, @@ -1832,9 +1832,9 @@ func (a PipelineClusterAutoscale) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelineClusterAutoscale in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineClusterAutoscale in the Terraform plugin framework type // system. -func (a PipelineClusterAutoscale) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineClusterAutoscale) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_workers": types.Int64Type, @@ -1868,9 +1868,9 @@ func (a PipelineDeployment) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelineDeployment in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineDeployment in the Terraform plugin framework type // system. -func (a PipelineDeployment) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineDeployment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kind": types.StringType, @@ -1921,13 +1921,13 @@ func (a PipelineEvent) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of PipelineEvent in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineEvent in the Terraform plugin framework type // system. -func (a PipelineEvent) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineEvent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": basetypes.ListType{ - ElemType: ErrorDetail{}.ToAttrType(ctx), + ElemType: ErrorDetail{}.ToObjectType(ctx), }, "event_type": types.StringType, "id": types.StringType, @@ -1935,10 +1935,10 @@ func (a PipelineEvent) ToAttrType(ctx context.Context) types.ObjectType { "maturity_level": types.StringType, "message": types.StringType, "origin": basetypes.ListType{ - ElemType: Origin{}.ToAttrType(ctx), + ElemType: Origin{}.ToObjectType(ctx), }, "sequence": basetypes.ListType{ - ElemType: Sequencing{}.ToAttrType(ctx), + ElemType: Sequencing{}.ToObjectType(ctx), }, "timestamp": types.StringType, }, @@ -1981,20 +1981,20 @@ func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of PipelineLibrary in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineLibrary in the Terraform plugin framework type // system. -func (a PipelineLibrary) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineLibrary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file": basetypes.ListType{ - ElemType: FileLibrary{}.ToAttrType(ctx), + ElemType: FileLibrary{}.ToObjectType(ctx), }, "jar": types.StringType, "maven": basetypes.ListType{ - ElemType: compute_tf.MavenLibrary{}.ToAttrType(ctx), + ElemType: compute_tf.MavenLibrary{}.ToObjectType(ctx), }, "notebook": basetypes.ListType{ - ElemType: NotebookLibrary{}.ToAttrType(ctx), + ElemType: NotebookLibrary{}.ToObjectType(ctx), }, "whl": types.StringType, }, @@ -2028,9 +2028,9 @@ func (a PipelinePermission) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of PipelinePermission in the Terraform plugin framework type +// ToObjectType returns the representation of PipelinePermission in the Terraform plugin framework type // system. -func (a PipelinePermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelinePermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2069,13 +2069,13 @@ func (a PipelinePermissions) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of PipelinePermissions in the Terraform plugin framework type +// ToObjectType returns the representation of PipelinePermissions in the Terraform plugin framework type // system. -func (a PipelinePermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelinePermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PipelineAccessControlResponse{}.ToAttrType(ctx), + ElemType: PipelineAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2106,9 +2106,9 @@ func (a PipelinePermissionsDescription) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of PipelinePermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of PipelinePermissionsDescription in the Terraform plugin framework type // system. -func (a PipelinePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelinePermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2142,13 +2142,13 @@ func (a PipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of PipelinePermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PipelinePermissionsRequest in the Terraform plugin framework type // system. -func (a PipelinePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelinePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PipelineAccessControlRequest{}.ToAttrType(ctx), + ElemType: PipelineAccessControlRequest{}.ToObjectType(ctx), }, "pipeline_id": types.StringType, }, @@ -2241,53 +2241,53 @@ func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of PipelineSpec in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineSpec in the Terraform plugin framework type // system. -func (a PipelineSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.ToAttrType(ctx), + ElemType: PipelineCluster{}.ToObjectType(ctx), }, "configuration": basetypes.MapType{ ElemType: types.StringType, }, "continuous": types.BoolType, "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.ToAttrType(ctx), + ElemType: PipelineDeployment{}.ToObjectType(ctx), }, "development": types.BoolType, "edition": types.StringType, "filters": basetypes.ListType{ - ElemType: Filters{}.ToAttrType(ctx), + ElemType: Filters{}.ToObjectType(ctx), }, "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.ToAttrType(ctx), + ElemType: IngestionGatewayPipelineDefinition{}.ToObjectType(ctx), }, "id": types.StringType, "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.ToAttrType(ctx), + ElemType: IngestionPipelineDefinition{}.ToObjectType(ctx), }, "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.ToAttrType(ctx), + ElemType: PipelineLibrary{}.ToObjectType(ctx), }, "name": types.StringType, "notifications": basetypes.ListType{ - ElemType: Notifications{}.ToAttrType(ctx), + ElemType: Notifications{}.ToObjectType(ctx), }, "photon": types.BoolType, "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.ToAttrType(ctx), + ElemType: RestartWindow{}.ToObjectType(ctx), }, "schema": types.StringType, "serverless": types.BoolType, "storage": types.StringType, "target": types.StringType, "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.ToAttrType(ctx), + ElemType: PipelineTrigger{}.ToObjectType(ctx), }, }, } @@ -2333,16 +2333,16 @@ func (a PipelineStateInfo) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of PipelineStateInfo in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineStateInfo in the Terraform plugin framework type // system. -func (a PipelineStateInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineStateInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "creator_user_name": types.StringType, "health": types.StringType, "latest_updates": basetypes.ListType{ - ElemType: UpdateStateInfo{}.ToAttrType(ctx), + ElemType: UpdateStateInfo{}.ToObjectType(ctx), }, "name": types.StringType, "pipeline_id": types.StringType, @@ -2355,7 +2355,7 @@ func (a PipelineStateInfo) ToAttrType(ctx context.Context) types.ObjectType { type PipelineTrigger struct { Cron types.List `tfsdk:"cron" tf:"optional,object"` - Manual []ManualTrigger `tfsdk:"manual" tf:"optional,object"` + Manual types.List `tfsdk:"manual" tf:"optional,object"` } func (newState *PipelineTrigger) SyncEffectiveFieldsDuringCreateOrUpdate(plan PipelineTrigger) { @@ -2378,16 +2378,16 @@ func (a PipelineTrigger) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of PipelineTrigger in the Terraform plugin framework type +// ToObjectType returns the representation of PipelineTrigger in the Terraform plugin framework type // system. -func (a PipelineTrigger) ToAttrType(ctx context.Context) types.ObjectType { +func (a PipelineTrigger) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cron": basetypes.ListType{ - ElemType: CronTrigger{}.ToAttrType(ctx), + ElemType: CronTrigger{}.ToObjectType(ctx), }, "manual": basetypes.ListType{ - ElemType: ManualTrigger{}.ToAttrType(ctx), + ElemType: ManualTrigger{}.ToObjectType(ctx), }, }, } @@ -2428,9 +2428,9 @@ func (a ReportSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of ReportSpec in the Terraform plugin framework type +// ToObjectType returns the representation of ReportSpec in the Terraform plugin framework type // system. -func (a ReportSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReportSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_catalog": types.StringType, @@ -2438,7 +2438,7 @@ func (a ReportSpec) ToAttrType(ctx context.Context) types.ObjectType { "destination_table": types.StringType, "source_url": types.StringType, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToAttrType(ctx), + ElemType: TableSpecificConfig{}.ToObjectType(ctx), }, }, } @@ -2476,9 +2476,9 @@ func (a RestartWindow) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestartWindow in the Terraform plugin framework type +// ToObjectType returns the representation of RestartWindow in the Terraform plugin framework type // system. -func (a RestartWindow) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestartWindow) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "days_of_week": types.StringType, @@ -2525,9 +2525,9 @@ func (a SchemaSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of SchemaSpec in the Terraform plugin framework type +// ToObjectType returns the representation of SchemaSpec in the Terraform plugin framework type // system. -func (a SchemaSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a SchemaSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_catalog": types.StringType, @@ -2535,7 +2535,7 @@ func (a SchemaSpec) ToAttrType(ctx context.Context) types.ObjectType { "source_catalog": types.StringType, "source_schema": types.StringType, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToAttrType(ctx), + ElemType: TableSpecificConfig{}.ToObjectType(ctx), }, }, } @@ -2567,14 +2567,14 @@ func (a Sequencing) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of Sequencing in the Terraform plugin framework type +// ToObjectType returns the representation of Sequencing in the Terraform plugin framework type // system. -func (a Sequencing) ToAttrType(ctx context.Context) types.ObjectType { +func (a Sequencing) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "control_plane_seq_no": types.Int64Type, "data_plane_id": basetypes.ListType{ - ElemType: DataPlaneId{}.ToAttrType(ctx), + ElemType: DataPlaneId{}.ToObjectType(ctx), }, }, } @@ -2608,15 +2608,15 @@ func (a SerializedException) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of SerializedException in the Terraform plugin framework type +// ToObjectType returns the representation of SerializedException in the Terraform plugin framework type // system. -func (a SerializedException) ToAttrType(ctx context.Context) types.ObjectType { +func (a SerializedException) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "class_name": types.StringType, "message": types.StringType, "stack": basetypes.ListType{ - ElemType: StackFrame{}.ToAttrType(ctx), + ElemType: StackFrame{}.ToObjectType(ctx), }, }, } @@ -2650,9 +2650,9 @@ func (a StackFrame) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of StackFrame in the Terraform plugin framework type +// ToObjectType returns the representation of StackFrame in the Terraform plugin framework type // system. -func (a StackFrame) ToAttrType(ctx context.Context) types.ObjectType { +func (a StackFrame) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "declaring_class": types.StringType, @@ -2704,9 +2704,9 @@ func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of StartUpdate in the Terraform plugin framework type +// ToObjectType returns the representation of StartUpdate in the Terraform plugin framework type // system. -func (a StartUpdate) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartUpdate) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, @@ -2744,9 +2744,9 @@ func (a StartUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of StartUpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of StartUpdateResponse in the Terraform plugin framework type // system. -func (a StartUpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartUpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "update_id": types.StringType, @@ -2774,9 +2774,9 @@ func (a StopPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of StopPipelineResponse in the Terraform plugin framework type +// ToObjectType returns the representation of StopPipelineResponse in the Terraform plugin framework type // system. -func (a StopPipelineResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a StopPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2804,9 +2804,9 @@ func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of StopRequest in the Terraform plugin framework type +// ToObjectType returns the representation of StopRequest in the Terraform plugin framework type // system. -func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a StopRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -2854,9 +2854,9 @@ func (a TableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of TableSpec in the Terraform plugin framework type +// ToObjectType returns the representation of TableSpec in the Terraform plugin framework type // system. -func (a TableSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_catalog": types.StringType, @@ -2866,7 +2866,7 @@ func (a TableSpec) ToAttrType(ctx context.Context) types.ObjectType { "source_schema": types.StringType, "source_table": types.StringType, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToAttrType(ctx), + ElemType: TableSpecificConfig{}.ToObjectType(ctx), }, }, } @@ -2906,9 +2906,9 @@ func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of TableSpecificConfig in the Terraform plugin framework type +// ToObjectType returns the representation of TableSpecificConfig in the Terraform plugin framework type // system. -func (a TableSpecificConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a TableSpecificConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "primary_keys": basetypes.ListType{ @@ -2977,15 +2977,15 @@ func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of UpdateInfo in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateInfo in the Terraform plugin framework type // system. -func (a UpdateInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, "cluster_id": types.StringType, "config": basetypes.ListType{ - ElemType: PipelineSpec{}.ToAttrType(ctx), + ElemType: PipelineSpec{}.ToObjectType(ctx), }, "creation_time": types.Int64Type, "full_refresh": types.BoolType, @@ -3028,9 +3028,9 @@ func (a UpdateStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateStateInfo in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateStateInfo in the Terraform plugin framework type // system. -func (a UpdateStateInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateStateInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_time": types.StringType, diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index de53539522..4b8f188b99 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -42,13 +42,13 @@ func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of AwsCredentials in the Terraform plugin framework type +// ToObjectType returns the representation of AwsCredentials in the Terraform plugin framework type // system. -func (a AwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsCredentials) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sts_role": basetypes.ListType{ - ElemType: StsRole{}.ToAttrType(ctx), + ElemType: StsRole{}.ToObjectType(ctx), }, }, } @@ -85,9 +85,9 @@ func (a AwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of AwsKeyInfo in the Terraform plugin framework type +// ToObjectType returns the representation of AwsKeyInfo in the Terraform plugin framework type // system. -func (a AwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a AwsKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key_alias": types.StringType, @@ -122,9 +122,9 @@ func (a AzureWorkspaceInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureWorkspaceInfo in the Terraform plugin framework type +// ToObjectType returns the representation of AzureWorkspaceInfo in the Terraform plugin framework type // system. -func (a AzureWorkspaceInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureWorkspaceInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resource_group": types.StringType, @@ -158,13 +158,13 @@ func (a CloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CloudResourceContainer in the Terraform plugin framework type +// ToObjectType returns the representation of CloudResourceContainer in the Terraform plugin framework type // system. -func (a CloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { +func (a CloudResourceContainer) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gcp": basetypes.ListType{ - ElemType: CustomerFacingGcpCloudResourceContainer{}.ToAttrType(ctx), + ElemType: CustomerFacingGcpCloudResourceContainer{}.ToObjectType(ctx), }, }, } @@ -200,9 +200,9 @@ func (a CreateAwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateAwsKeyInfo in the Terraform plugin framework type +// ToObjectType returns the representation of CreateAwsKeyInfo in the Terraform plugin framework type // system. -func (a CreateAwsKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateAwsKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key_alias": types.StringType, @@ -235,13 +235,13 @@ func (a CreateCredentialAwsCredentials) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of CreateCredentialAwsCredentials in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCredentialAwsCredentials in the Terraform plugin framework type // system. -func (a CreateCredentialAwsCredentials) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCredentialAwsCredentials) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sts_role": basetypes.ListType{ - ElemType: CreateCredentialStsRole{}.ToAttrType(ctx), + ElemType: CreateCredentialStsRole{}.ToObjectType(ctx), }, }, } @@ -272,13 +272,13 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of CreateCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCredentialRequest in the Terraform plugin framework type // system. -func (a CreateCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_credentials": basetypes.ListType{ - ElemType: CreateCredentialAwsCredentials{}.ToAttrType(ctx), + ElemType: CreateCredentialAwsCredentials{}.ToObjectType(ctx), }, "credentials_name": types.StringType, }, @@ -307,9 +307,9 @@ func (a CreateCredentialStsRole) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateCredentialStsRole in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCredentialStsRole in the Terraform plugin framework type // system. -func (a CreateCredentialStsRole) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCredentialStsRole) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "role_arn": types.StringType, @@ -346,16 +346,16 @@ func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of CreateCustomerManagedKeyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCustomerManagedKeyRequest in the Terraform plugin framework type // system. -func (a CreateCustomerManagedKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCustomerManagedKeyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_key_info": basetypes.ListType{ - ElemType: CreateAwsKeyInfo{}.ToAttrType(ctx), + ElemType: CreateAwsKeyInfo{}.ToObjectType(ctx), }, "gcp_key_info": basetypes.ListType{ - ElemType: CreateGcpKeyInfo{}.ToAttrType(ctx), + ElemType: CreateGcpKeyInfo{}.ToObjectType(ctx), }, "use_cases": basetypes.ListType{ ElemType: types.StringType, @@ -386,9 +386,9 @@ func (a CreateGcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateGcpKeyInfo in the Terraform plugin framework type +// ToObjectType returns the representation of CreateGcpKeyInfo in the Terraform plugin framework type // system. -func (a CreateGcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateGcpKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kms_key_id": types.StringType, @@ -440,13 +440,13 @@ func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of CreateNetworkRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateNetworkRequest in the Terraform plugin framework type // system. -func (a CreateNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gcp_network_info": basetypes.ListType{ - ElemType: GcpNetworkInfo{}.ToAttrType(ctx), + ElemType: GcpNetworkInfo{}.ToObjectType(ctx), }, "network_name": types.StringType, "security_group_ids": basetypes.ListType{ @@ -456,7 +456,7 @@ func (a CreateNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "vpc_endpoints": basetypes.ListType{ - ElemType: NetworkVpcEndpoints{}.ToAttrType(ctx), + ElemType: NetworkVpcEndpoints{}.ToObjectType(ctx), }, "vpc_id": types.StringType, }, @@ -489,13 +489,13 @@ func (a CreateStorageConfigurationRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of CreateStorageConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateStorageConfigurationRequest in the Terraform plugin framework type // system. -func (a CreateStorageConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateStorageConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "root_bucket_info": basetypes.ListType{ - ElemType: RootBucketInfo{}.ToAttrType(ctx), + ElemType: RootBucketInfo{}.ToObjectType(ctx), }, "storage_configuration_name": types.StringType, }, @@ -533,14 +533,14 @@ func (a CreateVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of CreateVpcEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateVpcEndpointRequest in the Terraform plugin framework type // system. -func (a CreateVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateVpcEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_vpc_endpoint_id": types.StringType, "gcp_vpc_endpoint_info": basetypes.ListType{ - ElemType: GcpVpcEndpointInfo{}.ToAttrType(ctx), + ElemType: GcpVpcEndpointInfo{}.ToObjectType(ctx), }, "region": types.StringType, "vpc_endpoint_name": types.StringType, @@ -683,15 +683,15 @@ func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CreateWorkspaceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateWorkspaceRequest in the Terraform plugin framework type // system. -func (a CreateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_region": types.StringType, "cloud": types.StringType, "cloud_resource_container": basetypes.ListType{ - ElemType: CloudResourceContainer{}.ToAttrType(ctx), + ElemType: CloudResourceContainer{}.ToObjectType(ctx), }, "credentials_id": types.StringType, "custom_tags": basetypes.MapType{ @@ -699,10 +699,10 @@ func (a CreateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType }, "deployment_name": types.StringType, "gcp_managed_network_config": basetypes.ListType{ - ElemType: GcpManagedNetworkConfig{}.ToAttrType(ctx), + ElemType: GcpManagedNetworkConfig{}.ToObjectType(ctx), }, "gke_config": basetypes.ListType{ - ElemType: GkeConfig{}.ToAttrType(ctx), + ElemType: GkeConfig{}.ToObjectType(ctx), }, "is_no_public_ip_enabled": types.BoolType, "location": types.StringType, @@ -749,14 +749,14 @@ func (a Credential) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of Credential in the Terraform plugin framework type +// ToObjectType returns the representation of Credential in the Terraform plugin framework type // system. -func (a Credential) ToAttrType(ctx context.Context) types.ObjectType { +func (a Credential) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "aws_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.ToAttrType(ctx), + ElemType: AwsCredentials{}.ToObjectType(ctx), }, "creation_time": types.Int64Type, "credentials_id": types.StringType, @@ -789,9 +789,9 @@ func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of CustomerFacingGcpCloudResourceContainer in the Terraform plugin framework type +// ToObjectType returns the representation of CustomerFacingGcpCloudResourceContainer in the Terraform plugin framework type // system. -func (a CustomerFacingGcpCloudResourceContainer) ToAttrType(ctx context.Context) types.ObjectType { +func (a CustomerFacingGcpCloudResourceContainer) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "project_id": types.StringType, @@ -835,19 +835,19 @@ func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CustomerManagedKey in the Terraform plugin framework type +// ToObjectType returns the representation of CustomerManagedKey in the Terraform plugin framework type // system. -func (a CustomerManagedKey) ToAttrType(ctx context.Context) types.ObjectType { +func (a CustomerManagedKey) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "aws_key_info": basetypes.ListType{ - ElemType: AwsKeyInfo{}.ToAttrType(ctx), + ElemType: AwsKeyInfo{}.ToObjectType(ctx), }, "creation_time": types.Int64Type, "customer_managed_key_id": types.StringType, "gcp_key_info": basetypes.ListType{ - ElemType: GcpKeyInfo{}.ToAttrType(ctx), + ElemType: GcpKeyInfo{}.ToObjectType(ctx), }, "use_cases": basetypes.ListType{ ElemType: types.StringType, @@ -879,9 +879,9 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type // system. -func (a DeleteCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials_id": types.StringType, @@ -912,9 +912,9 @@ func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteEncryptionKeyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteEncryptionKeyRequest in the Terraform plugin framework type // system. -func (a DeleteEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteEncryptionKeyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "customer_managed_key_id": types.StringType, @@ -945,9 +945,9 @@ func (a DeleteNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteNetworkRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteNetworkRequest in the Terraform plugin framework type // system. -func (a DeleteNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_id": types.StringType, @@ -978,9 +978,9 @@ func (a DeletePrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePrivateAccesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePrivateAccesRequest in the Terraform plugin framework type // system. -func (a DeletePrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePrivateAccesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "private_access_settings_id": types.StringType, @@ -1008,9 +1008,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1039,9 +1039,9 @@ func (a DeleteStorageRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteStorageRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteStorageRequest in the Terraform plugin framework type // system. -func (a DeleteStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteStorageRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "storage_configuration_id": types.StringType, @@ -1072,9 +1072,9 @@ func (a DeleteVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteVpcEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteVpcEndpointRequest in the Terraform plugin framework type // system. -func (a DeleteVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteVpcEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "vpc_endpoint_id": types.StringType, @@ -1105,9 +1105,9 @@ func (a DeleteWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWorkspaceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWorkspaceRequest in the Terraform plugin framework type // system. -func (a DeleteWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1141,9 +1141,9 @@ func (a ExternalCustomerInfo) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExternalCustomerInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ExternalCustomerInfo in the Terraform plugin framework type // system. -func (a ExternalCustomerInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExternalCustomerInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authoritative_user_email": types.StringType, @@ -1175,9 +1175,9 @@ func (a GcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpKeyInfo in the Terraform plugin framework type +// ToObjectType returns the representation of GcpKeyInfo in the Terraform plugin framework type // system. -func (a GcpKeyInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kms_key_id": types.StringType, @@ -1237,9 +1237,9 @@ func (a GcpManagedNetworkConfig) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpManagedNetworkConfig in the Terraform plugin framework type +// ToObjectType returns the representation of GcpManagedNetworkConfig in the Terraform plugin framework type // system. -func (a GcpManagedNetworkConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpManagedNetworkConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gke_cluster_pod_ip_range": types.StringType, @@ -1289,9 +1289,9 @@ func (a GcpNetworkInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpNetworkInfo in the Terraform plugin framework type +// ToObjectType returns the representation of GcpNetworkInfo in the Terraform plugin framework type // system. -func (a GcpNetworkInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpNetworkInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_project_id": types.StringType, @@ -1337,9 +1337,9 @@ func (a GcpVpcEndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GcpVpcEndpointInfo in the Terraform plugin framework type +// ToObjectType returns the representation of GcpVpcEndpointInfo in the Terraform plugin framework type // system. -func (a GcpVpcEndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a GcpVpcEndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_region": types.StringType, @@ -1374,9 +1374,9 @@ func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCredentialRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetCredentialRequest in the Terraform plugin framework type // system. -func (a GetCredentialRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials_id": types.StringType, @@ -1407,9 +1407,9 @@ func (a GetEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetEncryptionKeyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetEncryptionKeyRequest in the Terraform plugin framework type // system. -func (a GetEncryptionKeyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEncryptionKeyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "customer_managed_key_id": types.StringType, @@ -1440,9 +1440,9 @@ func (a GetNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetNetworkRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetNetworkRequest in the Terraform plugin framework type // system. -func (a GetNetworkRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_id": types.StringType, @@ -1473,9 +1473,9 @@ func (a GetPrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPrivateAccesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPrivateAccesRequest in the Terraform plugin framework type // system. -func (a GetPrivateAccesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPrivateAccesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "private_access_settings_id": types.StringType, @@ -1506,9 +1506,9 @@ func (a GetStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStorageRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStorageRequest in the Terraform plugin framework type // system. -func (a GetStorageRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStorageRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "storage_configuration_id": types.StringType, @@ -1539,9 +1539,9 @@ func (a GetVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetVpcEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetVpcEndpointRequest in the Terraform plugin framework type // system. -func (a GetVpcEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetVpcEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "vpc_endpoint_id": types.StringType, @@ -1572,9 +1572,9 @@ func (a GetWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWorkspaceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceRequest in the Terraform plugin framework type // system. -func (a GetWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1617,9 +1617,9 @@ func (a GkeConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of GkeConfig in the Terraform plugin framework type +// ToObjectType returns the representation of GkeConfig in the Terraform plugin framework type // system. -func (a GkeConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a GkeConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connectivity_type": types.StringType, @@ -1688,18 +1688,18 @@ func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToAttrType returns the representation of Network in the Terraform plugin framework type +// ToObjectType returns the representation of Network in the Terraform plugin framework type // system. -func (a Network) ToAttrType(ctx context.Context) types.ObjectType { +func (a Network) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, "error_messages": basetypes.ListType{ - ElemType: NetworkHealth{}.ToAttrType(ctx), + ElemType: NetworkHealth{}.ToObjectType(ctx), }, "gcp_network_info": basetypes.ListType{ - ElemType: GcpNetworkInfo{}.ToAttrType(ctx), + ElemType: GcpNetworkInfo{}.ToObjectType(ctx), }, "network_id": types.StringType, "network_name": types.StringType, @@ -1710,12 +1710,12 @@ func (a Network) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "vpc_endpoints": basetypes.ListType{ - ElemType: NetworkVpcEndpoints{}.ToAttrType(ctx), + ElemType: NetworkVpcEndpoints{}.ToObjectType(ctx), }, "vpc_id": types.StringType, "vpc_status": types.StringType, "warning_messages": basetypes.ListType{ - ElemType: NetworkWarning{}.ToAttrType(ctx), + ElemType: NetworkWarning{}.ToObjectType(ctx), }, "workspace_id": types.Int64Type, }, @@ -1747,9 +1747,9 @@ func (a NetworkHealth) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of NetworkHealth in the Terraform plugin framework type +// ToObjectType returns the representation of NetworkHealth in the Terraform plugin framework type // system. -func (a NetworkHealth) ToAttrType(ctx context.Context) types.ObjectType { +func (a NetworkHealth) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_message": types.StringType, @@ -1791,9 +1791,9 @@ func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of NetworkVpcEndpoints in the Terraform plugin framework type +// ToObjectType returns the representation of NetworkVpcEndpoints in the Terraform plugin framework type // system. -func (a NetworkVpcEndpoints) ToAttrType(ctx context.Context) types.ObjectType { +func (a NetworkVpcEndpoints) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataplane_relay": basetypes.ListType{ @@ -1831,9 +1831,9 @@ func (a NetworkWarning) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of NetworkWarning in the Terraform plugin framework type +// ToObjectType returns the representation of NetworkWarning in the Terraform plugin framework type // system. -func (a NetworkWarning) ToAttrType(ctx context.Context) types.ObjectType { +func (a NetworkWarning) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warning_message": types.StringType, @@ -1888,9 +1888,9 @@ func (a PrivateAccessSettings) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of PrivateAccessSettings in the Terraform plugin framework type +// ToObjectType returns the representation of PrivateAccessSettings in the Terraform plugin framework type // system. -func (a PrivateAccessSettings) ToAttrType(ctx context.Context) types.ObjectType { +func (a PrivateAccessSettings) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, @@ -1926,9 +1926,9 @@ func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ReplaceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ReplaceResponse in the Terraform plugin framework type // system. -func (a ReplaceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReplaceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1957,9 +1957,9 @@ func (a RootBucketInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of RootBucketInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RootBucketInfo in the Terraform plugin framework type // system. -func (a RootBucketInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RootBucketInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bucket_name": types.StringType, @@ -1999,15 +1999,15 @@ func (a StorageConfiguration) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of StorageConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of StorageConfiguration in the Terraform plugin framework type // system. -func (a StorageConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a StorageConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, "root_bucket_info": basetypes.ListType{ - ElemType: RootBucketInfo{}.ToAttrType(ctx), + ElemType: RootBucketInfo{}.ToObjectType(ctx), }, "storage_configuration_id": types.StringType, "storage_configuration_name": types.StringType, @@ -2040,9 +2040,9 @@ func (a StsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of StsRole in the Terraform plugin framework type +// ToObjectType returns the representation of StsRole in the Terraform plugin framework type // system. -func (a StsRole) ToAttrType(ctx context.Context) types.ObjectType { +func (a StsRole) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_id": types.StringType, @@ -2071,9 +2071,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2133,9 +2133,9 @@ func (a UpdateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of UpdateWorkspaceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateWorkspaceRequest in the Terraform plugin framework type // system. -func (a UpdateWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_region": types.StringType, @@ -2211,9 +2211,9 @@ func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of UpsertPrivateAccessSettingsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpsertPrivateAccessSettingsRequest in the Terraform plugin framework type // system. -func (a UpsertPrivateAccessSettingsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpsertPrivateAccessSettingsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allowed_vpc_endpoint_ids": basetypes.ListType{ @@ -2285,9 +2285,9 @@ func (a VpcEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of VpcEndpoint in the Terraform plugin framework type +// ToObjectType returns the representation of VpcEndpoint in the Terraform plugin framework type // system. -func (a VpcEndpoint) ToAttrType(ctx context.Context) types.ObjectType { +func (a VpcEndpoint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, @@ -2295,7 +2295,7 @@ func (a VpcEndpoint) ToAttrType(ctx context.Context) types.ObjectType { "aws_endpoint_service_id": types.StringType, "aws_vpc_endpoint_id": types.StringType, "gcp_vpc_endpoint_info": basetypes.ListType{ - ElemType: GcpVpcEndpointInfo{}.ToAttrType(ctx), + ElemType: GcpVpcEndpointInfo{}.ToObjectType(ctx), }, "region": types.StringType, "state": types.StringType, @@ -2430,19 +2430,19 @@ func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of Workspace in the Terraform plugin framework type +// ToObjectType returns the representation of Workspace in the Terraform plugin framework type // system. -func (a Workspace) ToAttrType(ctx context.Context) types.ObjectType { +func (a Workspace) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "aws_region": types.StringType, "azure_workspace_info": basetypes.ListType{ - ElemType: AzureWorkspaceInfo{}.ToAttrType(ctx), + ElemType: AzureWorkspaceInfo{}.ToObjectType(ctx), }, "cloud": types.StringType, "cloud_resource_container": basetypes.ListType{ - ElemType: CloudResourceContainer{}.ToAttrType(ctx), + ElemType: CloudResourceContainer{}.ToObjectType(ctx), }, "creation_time": types.Int64Type, "credentials_id": types.StringType, @@ -2451,13 +2451,13 @@ func (a Workspace) ToAttrType(ctx context.Context) types.ObjectType { }, "deployment_name": types.StringType, "external_customer_info": basetypes.ListType{ - ElemType: ExternalCustomerInfo{}.ToAttrType(ctx), + ElemType: ExternalCustomerInfo{}.ToObjectType(ctx), }, "gcp_managed_network_config": basetypes.ListType{ - ElemType: GcpManagedNetworkConfig{}.ToAttrType(ctx), + ElemType: GcpManagedNetworkConfig{}.ToObjectType(ctx), }, "gke_config": basetypes.ListType{ - ElemType: GkeConfig{}.ToAttrType(ctx), + ElemType: GkeConfig{}.ToObjectType(ctx), }, "is_no_public_ip_enabled": types.BoolType, "location": types.StringType, diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 48af16bd51..f0243d949a 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -52,9 +52,9 @@ func (a Ai21LabsConfig) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of Ai21LabsConfig in the Terraform plugin framework type +// ToObjectType returns the representation of Ai21LabsConfig in the Terraform plugin framework type // system. -func (a Ai21LabsConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a Ai21LabsConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai21labs_api_key": types.StringType, @@ -101,22 +101,22 @@ func (a AiGatewayConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of AiGatewayConfig in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayConfig in the Terraform plugin framework type // system. -func (a AiGatewayConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.ToAttrType(ctx), + ElemType: AiGatewayGuardrails{}.ToObjectType(ctx), }, "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + ElemType: AiGatewayInferenceTableConfig{}.ToObjectType(ctx), }, "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), + ElemType: AiGatewayRateLimit{}.ToObjectType(ctx), }, "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + ElemType: AiGatewayUsageTrackingConfig{}.ToObjectType(ctx), }, }, } @@ -156,16 +156,16 @@ func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of AiGatewayGuardrailParameters in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayGuardrailParameters in the Terraform plugin framework type // system. -func (a AiGatewayGuardrailParameters) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayGuardrailParameters) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "invalid_keywords": basetypes.ListType{ ElemType: types.StringType, }, "pii": basetypes.ListType{ - ElemType: AiGatewayGuardrailPiiBehavior{}.ToAttrType(ctx), + ElemType: AiGatewayGuardrailPiiBehavior{}.ToObjectType(ctx), }, "safety": types.BoolType, "valid_topics": basetypes.ListType{ @@ -202,9 +202,9 @@ func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of AiGatewayGuardrailPiiBehavior in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayGuardrailPiiBehavior in the Terraform plugin framework type // system. -func (a AiGatewayGuardrailPiiBehavior) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayGuardrailPiiBehavior) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "behavior": types.StringType, @@ -239,16 +239,16 @@ func (a AiGatewayGuardrails) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of AiGatewayGuardrails in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayGuardrails in the Terraform plugin framework type // system. -func (a AiGatewayGuardrails) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayGuardrails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "input": basetypes.ListType{ - ElemType: AiGatewayGuardrailParameters{}.ToAttrType(ctx), + ElemType: AiGatewayGuardrailParameters{}.ToObjectType(ctx), }, "output": basetypes.ListType{ - ElemType: AiGatewayGuardrailParameters{}.ToAttrType(ctx), + ElemType: AiGatewayGuardrailParameters{}.ToObjectType(ctx), }, }, } @@ -287,9 +287,9 @@ func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of AiGatewayInferenceTableConfig in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayInferenceTableConfig in the Terraform plugin framework type // system. -func (a AiGatewayInferenceTableConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayInferenceTableConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -329,9 +329,9 @@ func (a AiGatewayRateLimit) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of AiGatewayRateLimit in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayRateLimit in the Terraform plugin framework type // system. -func (a AiGatewayRateLimit) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayRateLimit) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "calls": types.Int64Type, @@ -363,9 +363,9 @@ func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of AiGatewayUsageTrackingConfig in the Terraform plugin framework type +// ToObjectType returns the representation of AiGatewayUsageTrackingConfig in the Terraform plugin framework type // system. -func (a AiGatewayUsageTrackingConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a AiGatewayUsageTrackingConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -424,9 +424,9 @@ func (a AmazonBedrockConfig) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of AmazonBedrockConfig in the Terraform plugin framework type +// ToObjectType returns the representation of AmazonBedrockConfig in the Terraform plugin framework type // system. -func (a AmazonBedrockConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a AmazonBedrockConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_access_key_id": types.StringType, @@ -469,9 +469,9 @@ func (a AnthropicConfig) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of AnthropicConfig in the Terraform plugin framework type +// ToObjectType returns the representation of AnthropicConfig in the Terraform plugin framework type // system. -func (a AnthropicConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a AnthropicConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "anthropic_api_key": types.StringType, @@ -511,9 +511,9 @@ func (a AutoCaptureConfigInput) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of AutoCaptureConfigInput in the Terraform plugin framework type +// ToObjectType returns the representation of AutoCaptureConfigInput in the Terraform plugin framework type // system. -func (a AutoCaptureConfigInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a AutoCaptureConfigInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -556,16 +556,16 @@ func (a AutoCaptureConfigOutput) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of AutoCaptureConfigOutput in the Terraform plugin framework type +// ToObjectType returns the representation of AutoCaptureConfigOutput in the Terraform plugin framework type // system. -func (a AutoCaptureConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a AutoCaptureConfigOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, "enabled": types.BoolType, "schema_name": types.StringType, "state": basetypes.ListType{ - ElemType: AutoCaptureState{}.ToAttrType(ctx), + ElemType: AutoCaptureState{}.ToObjectType(ctx), }, "table_name_prefix": types.StringType, }, @@ -595,13 +595,13 @@ func (a AutoCaptureState) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of AutoCaptureState in the Terraform plugin framework type +// ToObjectType returns the representation of AutoCaptureState in the Terraform plugin framework type // system. -func (a AutoCaptureState) ToAttrType(ctx context.Context) types.ObjectType { +func (a AutoCaptureState) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "payload_table": basetypes.ListType{ - ElemType: PayloadTable{}.ToAttrType(ctx), + ElemType: PayloadTable{}.ToObjectType(ctx), }, }, } @@ -634,9 +634,9 @@ func (a BuildLogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of BuildLogsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of BuildLogsRequest in the Terraform plugin framework type // system. -func (a BuildLogsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a BuildLogsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -667,9 +667,9 @@ func (a BuildLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of BuildLogsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of BuildLogsResponse in the Terraform plugin framework type // system. -func (a BuildLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a BuildLogsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "logs": types.StringType, @@ -701,9 +701,9 @@ func (a ChatMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of ChatMessage in the Terraform plugin framework type +// ToObjectType returns the representation of ChatMessage in the Terraform plugin framework type // system. -func (a ChatMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a ChatMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -745,9 +745,9 @@ func (a CohereConfig) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of CohereConfig in the Terraform plugin framework type +// ToObjectType returns the representation of CohereConfig in the Terraform plugin framework type // system. -func (a CohereConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a CohereConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cohere_api_base": types.StringType, @@ -799,24 +799,24 @@ func (a CreateServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of CreateServingEndpoint in the Terraform plugin framework type +// ToObjectType returns the representation of CreateServingEndpoint in the Terraform plugin framework type // system. -func (a CreateServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.ToAttrType(ctx), + ElemType: AiGatewayConfig{}.ToObjectType(ctx), }, "config": basetypes.ListType{ - ElemType: EndpointCoreConfigInput{}.ToAttrType(ctx), + ElemType: EndpointCoreConfigInput{}.ToObjectType(ctx), }, "name": types.StringType, "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.ToAttrType(ctx), + ElemType: RateLimit{}.ToObjectType(ctx), }, "route_optimized": types.BoolType, "tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToAttrType(ctx), + ElemType: EndpointTag{}.ToObjectType(ctx), }, }, } @@ -859,9 +859,9 @@ func (a DatabricksModelServingConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DatabricksModelServingConfig in the Terraform plugin framework type +// ToObjectType returns the representation of DatabricksModelServingConfig in the Terraform plugin framework type // system. -func (a DatabricksModelServingConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a DatabricksModelServingConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "databricks_api_token": types.StringType, @@ -900,9 +900,9 @@ func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of DataframeSplitInput in the Terraform plugin framework type +// ToObjectType returns the representation of DataframeSplitInput in the Terraform plugin framework type // system. -func (a DataframeSplitInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a DataframeSplitInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns": basetypes.ListType{ @@ -938,9 +938,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -969,9 +969,9 @@ func (a DeleteServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteServingEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteServingEndpointRequest in the Terraform plugin framework type // system. -func (a DeleteServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteServingEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1006,9 +1006,9 @@ func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of EmbeddingsV1ResponseEmbeddingElement in the Terraform plugin framework type +// ToObjectType returns the representation of EmbeddingsV1ResponseEmbeddingElement in the Terraform plugin framework type // system. -func (a EmbeddingsV1ResponseEmbeddingElement) ToAttrType(ctx context.Context) types.ObjectType { +func (a EmbeddingsV1ResponseEmbeddingElement) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding": basetypes.ListType{ @@ -1059,23 +1059,23 @@ func (a EndpointCoreConfigInput) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of EndpointCoreConfigInput in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointCoreConfigInput in the Terraform plugin framework type // system. -func (a EndpointCoreConfigInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointCoreConfigInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigInput{}.ToAttrType(ctx), + ElemType: AutoCaptureConfigInput{}.ToObjectType(ctx), }, "name": types.StringType, "served_entities": basetypes.ListType{ - ElemType: ServedEntityInput{}.ToAttrType(ctx), + ElemType: ServedEntityInput{}.ToObjectType(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelInput{}.ToAttrType(ctx), + ElemType: ServedModelInput{}.ToObjectType(ctx), }, "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.ToAttrType(ctx), + ElemType: TrafficConfig{}.ToObjectType(ctx), }, }, } @@ -1118,23 +1118,23 @@ func (a EndpointCoreConfigOutput) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of EndpointCoreConfigOutput in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointCoreConfigOutput in the Terraform plugin framework type // system. -func (a EndpointCoreConfigOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointCoreConfigOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigOutput{}.ToAttrType(ctx), + ElemType: AutoCaptureConfigOutput{}.ToObjectType(ctx), }, "config_version": types.Int64Type, "served_entities": basetypes.ListType{ - ElemType: ServedEntityOutput{}.ToAttrType(ctx), + ElemType: ServedEntityOutput{}.ToObjectType(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelOutput{}.ToAttrType(ctx), + ElemType: ServedModelOutput{}.ToObjectType(ctx), }, "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.ToAttrType(ctx), + ElemType: TrafficConfig{}.ToObjectType(ctx), }, }, } @@ -1168,16 +1168,16 @@ func (a EndpointCoreConfigSummary) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of EndpointCoreConfigSummary in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointCoreConfigSummary in the Terraform plugin framework type // system. -func (a EndpointCoreConfigSummary) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointCoreConfigSummary) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "served_entities": basetypes.ListType{ - ElemType: ServedEntitySpec{}.ToAttrType(ctx), + ElemType: ServedEntitySpec{}.ToObjectType(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelSpec{}.ToAttrType(ctx), + ElemType: ServedModelSpec{}.ToObjectType(ctx), }, }, } @@ -1224,24 +1224,24 @@ func (a EndpointPendingConfig) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of EndpointPendingConfig in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointPendingConfig in the Terraform plugin framework type // system. -func (a EndpointPendingConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointPendingConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigOutput{}.ToAttrType(ctx), + ElemType: AutoCaptureConfigOutput{}.ToObjectType(ctx), }, "config_version": types.Int64Type, "served_entities": basetypes.ListType{ - ElemType: ServedEntityOutput{}.ToAttrType(ctx), + ElemType: ServedEntityOutput{}.ToObjectType(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelOutput{}.ToAttrType(ctx), + ElemType: ServedModelOutput{}.ToObjectType(ctx), }, "start_time": types.Int64Type, "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.ToAttrType(ctx), + ElemType: TrafficConfig{}.ToObjectType(ctx), }, }, } @@ -1278,9 +1278,9 @@ func (a EndpointState) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of EndpointState in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointState in the Terraform plugin framework type // system. -func (a EndpointState) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointState) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config_update": types.StringType, @@ -1313,9 +1313,9 @@ func (a EndpointTag) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of EndpointTag in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointTag in the Terraform plugin framework type // system. -func (a EndpointTag) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointTag) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1348,9 +1348,9 @@ func (a ExportMetricsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExportMetricsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExportMetricsRequest in the Terraform plugin framework type // system. -func (a ExportMetricsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExportMetricsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1379,9 +1379,9 @@ func (a ExportMetricsResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExportMetricsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ExportMetricsResponse in the Terraform plugin framework type // system. -func (a ExportMetricsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExportMetricsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.ObjectType{}, @@ -1445,35 +1445,35 @@ func (a ExternalModel) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of ExternalModel in the Terraform plugin framework type +// ToObjectType returns the representation of ExternalModel in the Terraform plugin framework type // system. -func (a ExternalModel) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExternalModel) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai21labs_config": basetypes.ListType{ - ElemType: Ai21LabsConfig{}.ToAttrType(ctx), + ElemType: Ai21LabsConfig{}.ToObjectType(ctx), }, "amazon_bedrock_config": basetypes.ListType{ - ElemType: AmazonBedrockConfig{}.ToAttrType(ctx), + ElemType: AmazonBedrockConfig{}.ToObjectType(ctx), }, "anthropic_config": basetypes.ListType{ - ElemType: AnthropicConfig{}.ToAttrType(ctx), + ElemType: AnthropicConfig{}.ToObjectType(ctx), }, "cohere_config": basetypes.ListType{ - ElemType: CohereConfig{}.ToAttrType(ctx), + ElemType: CohereConfig{}.ToObjectType(ctx), }, "databricks_model_serving_config": basetypes.ListType{ - ElemType: DatabricksModelServingConfig{}.ToAttrType(ctx), + ElemType: DatabricksModelServingConfig{}.ToObjectType(ctx), }, "google_cloud_vertex_ai_config": basetypes.ListType{ - ElemType: GoogleCloudVertexAiConfig{}.ToAttrType(ctx), + ElemType: GoogleCloudVertexAiConfig{}.ToObjectType(ctx), }, "name": types.StringType, "openai_config": basetypes.ListType{ - ElemType: OpenAiConfig{}.ToAttrType(ctx), + ElemType: OpenAiConfig{}.ToObjectType(ctx), }, "palm_config": basetypes.ListType{ - ElemType: PaLmConfig{}.ToAttrType(ctx), + ElemType: PaLmConfig{}.ToObjectType(ctx), }, "provider": types.StringType, "task": types.StringType, @@ -1507,9 +1507,9 @@ func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExternalModelUsageElement in the Terraform plugin framework type +// ToObjectType returns the representation of ExternalModelUsageElement in the Terraform plugin framework type // system. -func (a ExternalModelUsageElement) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExternalModelUsageElement) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "completion_tokens": types.Int64Type, @@ -1547,9 +1547,9 @@ func (a FoundationModel) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of FoundationModel in the Terraform plugin framework type +// ToObjectType returns the representation of FoundationModel in the Terraform plugin framework type // system. -func (a FoundationModel) ToAttrType(ctx context.Context) types.ObjectType { +func (a FoundationModel) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1584,9 +1584,9 @@ func (a GetOpenApiRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetOpenApiRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetOpenApiRequest in the Terraform plugin framework type // system. -func (a GetOpenApiRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetOpenApiRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1616,9 +1616,9 @@ func (a GetOpenApiResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetOpenApiResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetOpenApiResponse in the Terraform plugin framework type // system. -func (a GetOpenApiResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetOpenApiResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1647,9 +1647,9 @@ func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetServingEndpointPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetServingEndpointPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetServingEndpointPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetServingEndpointPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "serving_endpoint_id": types.StringType, @@ -1681,13 +1681,13 @@ func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// ToAttrType returns the representation of GetServingEndpointPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetServingEndpointPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetServingEndpointPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetServingEndpointPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ServingEndpointPermissionsDescription{}.ToAttrType(ctx), + ElemType: ServingEndpointPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -1716,9 +1716,9 @@ func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetServingEndpointPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetServingEndpointPermissionsRequest in the Terraform plugin framework type // system. -func (a GetServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetServingEndpointPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "serving_endpoint_id": types.StringType, @@ -1749,9 +1749,9 @@ func (a GetServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetServingEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetServingEndpointRequest in the Terraform plugin framework type // system. -func (a GetServingEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetServingEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1806,9 +1806,9 @@ func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of GoogleCloudVertexAiConfig in the Terraform plugin framework type +// ToObjectType returns the representation of GoogleCloudVertexAiConfig in the Terraform plugin framework type // system. -func (a GoogleCloudVertexAiConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a GoogleCloudVertexAiConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "private_key": types.StringType, @@ -1843,13 +1843,13 @@ func (a ListEndpointsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListEndpointsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListEndpointsResponse in the Terraform plugin framework type // system. -func (a ListEndpointsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListEndpointsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoints": basetypes.ListType{ - ElemType: ServingEndpoint{}.ToAttrType(ctx), + ElemType: ServingEndpoint{}.ToObjectType(ctx), }, }, } @@ -1882,9 +1882,9 @@ func (a LogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of LogsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of LogsRequest in the Terraform plugin framework type // system. -func (a LogsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a LogsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1917,13 +1917,13 @@ func (a ModelDataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ModelDataPlaneInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ModelDataPlaneInfo in the Terraform plugin framework type // system. -func (a ModelDataPlaneInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ModelDataPlaneInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_info": basetypes.ListType{ - ElemType: oauth2_tf.DataPlaneInfo{}.ToAttrType(ctx), + ElemType: oauth2_tf.DataPlaneInfo{}.ToObjectType(ctx), }, }, } @@ -2000,9 +2000,9 @@ func (a OpenAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of OpenAiConfig in the Terraform plugin framework type +// ToObjectType returns the representation of OpenAiConfig in the Terraform plugin framework type // system. -func (a OpenAiConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a OpenAiConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "microsoft_entra_client_id": types.StringType, @@ -2050,9 +2050,9 @@ func (a PaLmConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of PaLmConfig in the Terraform plugin framework type +// ToObjectType returns the representation of PaLmConfig in the Terraform plugin framework type // system. -func (a PaLmConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a PaLmConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "palm_api_key": types.StringType, @@ -2091,13 +2091,13 @@ func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of PatchServingEndpointTags in the Terraform plugin framework type +// ToObjectType returns the representation of PatchServingEndpointTags in the Terraform plugin framework type // system. -func (a PatchServingEndpointTags) ToAttrType(ctx context.Context) types.ObjectType { +func (a PatchServingEndpointTags) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "add_tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToAttrType(ctx), + ElemType: EndpointTag{}.ToObjectType(ctx), }, "delete_tags": basetypes.ListType{ ElemType: types.StringType, @@ -2133,9 +2133,9 @@ func (a PayloadTable) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of PayloadTable in the Terraform plugin framework type +// ToObjectType returns the representation of PayloadTable in the Terraform plugin framework type // system. -func (a PayloadTable) ToAttrType(ctx context.Context) types.ObjectType { +func (a PayloadTable) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2187,23 +2187,23 @@ func (a PutAiGatewayRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of PutAiGatewayRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PutAiGatewayRequest in the Terraform plugin framework type // system. -func (a PutAiGatewayRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutAiGatewayRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.ToAttrType(ctx), + ElemType: AiGatewayGuardrails{}.ToObjectType(ctx), }, "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + ElemType: AiGatewayInferenceTableConfig{}.ToObjectType(ctx), }, "name": types.StringType, "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), + ElemType: AiGatewayRateLimit{}.ToObjectType(ctx), }, "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + ElemType: AiGatewayUsageTrackingConfig{}.ToObjectType(ctx), }, }, } @@ -2247,22 +2247,22 @@ func (a PutAiGatewayResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of PutAiGatewayResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PutAiGatewayResponse in the Terraform plugin framework type // system. -func (a PutAiGatewayResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutAiGatewayResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.ToAttrType(ctx), + ElemType: AiGatewayGuardrails{}.ToObjectType(ctx), }, "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.ToAttrType(ctx), + ElemType: AiGatewayInferenceTableConfig{}.ToObjectType(ctx), }, "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.ToAttrType(ctx), + ElemType: AiGatewayRateLimit{}.ToObjectType(ctx), }, "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.ToAttrType(ctx), + ElemType: AiGatewayUsageTrackingConfig{}.ToObjectType(ctx), }, }, } @@ -2296,14 +2296,14 @@ func (a PutRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of PutRequest in the Terraform plugin framework type +// ToObjectType returns the representation of PutRequest in the Terraform plugin framework type // system. -func (a PutRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.ToAttrType(ctx), + ElemType: RateLimit{}.ToObjectType(ctx), }, }, } @@ -2333,13 +2333,13 @@ func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of PutResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PutResponse in the Terraform plugin framework type // system. -func (a PutResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.ToAttrType(ctx), + ElemType: RateLimit{}.ToObjectType(ctx), }, }, } @@ -2421,16 +2421,16 @@ func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of QueryEndpointInput in the Terraform plugin framework type +// ToObjectType returns the representation of QueryEndpointInput in the Terraform plugin framework type // system. -func (a QueryEndpointInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryEndpointInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataframe_records": basetypes.ListType{ ElemType: types.ObjectType{}, }, "dataframe_split": basetypes.ListType{ - ElemType: DataframeSplitInput{}.ToAttrType(ctx), + ElemType: DataframeSplitInput{}.ToObjectType(ctx), }, "extra_params": basetypes.MapType{ ElemType: types.StringType, @@ -2442,7 +2442,7 @@ func (a QueryEndpointInput) ToAttrType(ctx context.Context) types.ObjectType { }, "max_tokens": types.Int64Type, "messages": basetypes.ListType{ - ElemType: ChatMessage{}.ToAttrType(ctx), + ElemType: ChatMessage{}.ToObjectType(ctx), }, "n": types.Int64Type, "name": types.StringType, @@ -2509,17 +2509,17 @@ func (a QueryEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of QueryEndpointResponse in the Terraform plugin framework type +// ToObjectType returns the representation of QueryEndpointResponse in the Terraform plugin framework type // system. -func (a QueryEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryEndpointResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "choices": basetypes.ListType{ - ElemType: V1ResponseChoiceElement{}.ToAttrType(ctx), + ElemType: V1ResponseChoiceElement{}.ToObjectType(ctx), }, "created": types.Int64Type, "data": basetypes.ListType{ - ElemType: EmbeddingsV1ResponseEmbeddingElement{}.ToAttrType(ctx), + ElemType: EmbeddingsV1ResponseEmbeddingElement{}.ToObjectType(ctx), }, "id": types.StringType, "model": types.StringType, @@ -2529,7 +2529,7 @@ func (a QueryEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType }, "served-model-name": types.StringType, "usage": basetypes.ListType{ - ElemType: ExternalModelUsageElement{}.ToAttrType(ctx), + ElemType: ExternalModelUsageElement{}.ToObjectType(ctx), }, }, } @@ -2565,9 +2565,9 @@ func (a RateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of RateLimit in the Terraform plugin framework type +// ToObjectType returns the representation of RateLimit in the Terraform plugin framework type // system. -func (a RateLimit) ToAttrType(ctx context.Context) types.ObjectType { +func (a RateLimit) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "calls": types.Int64Type, @@ -2602,9 +2602,9 @@ func (a Route) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Route in the Terraform plugin framework type +// ToObjectType returns the representation of Route in the Terraform plugin framework type // system. -func (a Route) ToAttrType(ctx context.Context) types.ObjectType { +func (a Route) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "served_model_name": types.StringType, @@ -2694,9 +2694,9 @@ func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ServedEntityInput in the Terraform plugin framework type +// ToObjectType returns the representation of ServedEntityInput in the Terraform plugin framework type // system. -func (a ServedEntityInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedEntityInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "entity_name": types.StringType, @@ -2705,7 +2705,7 @@ func (a ServedEntityInput) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.ToAttrType(ctx), + ElemType: ExternalModel{}.ToObjectType(ctx), }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, @@ -2803,9 +2803,9 @@ func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ServedEntityOutput in the Terraform plugin framework type +// ToObjectType returns the representation of ServedEntityOutput in the Terraform plugin framework type // system. -func (a ServedEntityOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedEntityOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -2816,10 +2816,10 @@ func (a ServedEntityOutput) ToAttrType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.ToAttrType(ctx), + ElemType: ExternalModel{}.ToObjectType(ctx), }, "foundation_model": basetypes.ListType{ - ElemType: FoundationModel{}.ToAttrType(ctx), + ElemType: FoundationModel{}.ToObjectType(ctx), }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, @@ -2827,7 +2827,7 @@ func (a ServedEntityOutput) ToAttrType(ctx context.Context) types.ObjectType { "name": types.StringType, "scale_to_zero_enabled": types.BoolType, "state": basetypes.ListType{ - ElemType: ServedModelState{}.ToAttrType(ctx), + ElemType: ServedModelState{}.ToObjectType(ctx), }, "workload_size": types.StringType, "workload_type": types.StringType, @@ -2877,18 +2877,18 @@ func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ServedEntitySpec in the Terraform plugin framework type +// ToObjectType returns the representation of ServedEntitySpec in the Terraform plugin framework type // system. -func (a ServedEntitySpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedEntitySpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "entity_name": types.StringType, "entity_version": types.StringType, "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.ToAttrType(ctx), + ElemType: ExternalModel{}.ToObjectType(ctx), }, "foundation_model": basetypes.ListType{ - ElemType: FoundationModel{}.ToAttrType(ctx), + ElemType: FoundationModel{}.ToObjectType(ctx), }, "name": types.StringType, }, @@ -2962,9 +2962,9 @@ func (a ServedModelInput) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ServedModelInput in the Terraform plugin framework type +// ToObjectType returns the representation of ServedModelInput in the Terraform plugin framework type // system. -func (a ServedModelInput) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedModelInput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "environment_vars": basetypes.MapType{ @@ -3049,9 +3049,9 @@ func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ServedModelOutput in the Terraform plugin framework type +// ToObjectType returns the representation of ServedModelOutput in the Terraform plugin framework type // system. -func (a ServedModelOutput) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedModelOutput) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -3065,7 +3065,7 @@ func (a ServedModelOutput) ToAttrType(ctx context.Context) types.ObjectType { "name": types.StringType, "scale_to_zero_enabled": types.BoolType, "state": basetypes.ListType{ - ElemType: ServedModelState{}.ToAttrType(ctx), + ElemType: ServedModelState{}.ToObjectType(ctx), }, "workload_size": types.StringType, "workload_type": types.StringType, @@ -3101,9 +3101,9 @@ func (a ServedModelSpec) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ServedModelSpec in the Terraform plugin framework type +// ToObjectType returns the representation of ServedModelSpec in the Terraform plugin framework type // system. -func (a ServedModelSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedModelSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_name": types.StringType, @@ -3148,9 +3148,9 @@ func (a ServedModelState) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of ServedModelState in the Terraform plugin framework type +// ToObjectType returns the representation of ServedModelState in the Terraform plugin framework type // system. -func (a ServedModelState) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServedModelState) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "deployment": types.StringType, @@ -3182,9 +3182,9 @@ func (a ServerLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ServerLogsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ServerLogsResponse in the Terraform plugin framework type // system. -func (a ServerLogsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServerLogsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "logs": types.StringType, @@ -3239,16 +3239,16 @@ func (a ServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of ServingEndpoint in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpoint in the Terraform plugin framework type // system. -func (a ServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.ToAttrType(ctx), + ElemType: AiGatewayConfig{}.ToObjectType(ctx), }, "config": basetypes.ListType{ - ElemType: EndpointCoreConfigSummary{}.ToAttrType(ctx), + ElemType: EndpointCoreConfigSummary{}.ToObjectType(ctx), }, "creation_timestamp": types.Int64Type, "creator": types.StringType, @@ -3256,10 +3256,10 @@ func (a ServingEndpoint) ToAttrType(ctx context.Context) types.ObjectType { "last_updated_timestamp": types.Int64Type, "name": types.StringType, "state": basetypes.ListType{ - ElemType: EndpointState{}.ToAttrType(ctx), + ElemType: EndpointState{}.ToObjectType(ctx), }, "tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToAttrType(ctx), + ElemType: EndpointTag{}.ToObjectType(ctx), }, "task": types.StringType, }, @@ -3294,9 +3294,9 @@ func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of ServingEndpointAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointAccessControlRequest in the Terraform plugin framework type // system. -func (a ServingEndpointAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -3339,13 +3339,13 @@ func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of ServingEndpointAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointAccessControlResponse in the Terraform plugin framework type // system. -func (a ServingEndpointAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ServingEndpointPermission{}.ToAttrType(ctx), + ElemType: ServingEndpointPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -3415,36 +3415,36 @@ func (a ServingEndpointDetailed) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ServingEndpointDetailed in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointDetailed in the Terraform plugin framework type // system. -func (a ServingEndpointDetailed) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointDetailed) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.ToAttrType(ctx), + ElemType: AiGatewayConfig{}.ToObjectType(ctx), }, "config": basetypes.ListType{ - ElemType: EndpointCoreConfigOutput{}.ToAttrType(ctx), + ElemType: EndpointCoreConfigOutput{}.ToObjectType(ctx), }, "creation_timestamp": types.Int64Type, "creator": types.StringType, "data_plane_info": basetypes.ListType{ - ElemType: ModelDataPlaneInfo{}.ToAttrType(ctx), + ElemType: ModelDataPlaneInfo{}.ToObjectType(ctx), }, "endpoint_url": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "name": types.StringType, "pending_config": basetypes.ListType{ - ElemType: EndpointPendingConfig{}.ToAttrType(ctx), + ElemType: EndpointPendingConfig{}.ToObjectType(ctx), }, "permission_level": types.StringType, "route_optimized": types.BoolType, "state": basetypes.ListType{ - ElemType: EndpointState{}.ToAttrType(ctx), + ElemType: EndpointState{}.ToObjectType(ctx), }, "tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToAttrType(ctx), + ElemType: EndpointTag{}.ToObjectType(ctx), }, "task": types.StringType, }, @@ -3478,9 +3478,9 @@ func (a ServingEndpointPermission) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ServingEndpointPermission in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointPermission in the Terraform plugin framework type // system. -func (a ServingEndpointPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -3519,13 +3519,13 @@ func (a ServingEndpointPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ServingEndpointPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointPermissions in the Terraform plugin framework type // system. -func (a ServingEndpointPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ServingEndpointAccessControlResponse{}.ToAttrType(ctx), + ElemType: ServingEndpointAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -3556,9 +3556,9 @@ func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of ServingEndpointPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointPermissionsDescription in the Terraform plugin framework type // system. -func (a ServingEndpointPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -3592,13 +3592,13 @@ func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of ServingEndpointPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ServingEndpointPermissionsRequest in the Terraform plugin framework type // system. -func (a ServingEndpointPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServingEndpointPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ServingEndpointAccessControlRequest{}.ToAttrType(ctx), + ElemType: ServingEndpointAccessControlRequest{}.ToObjectType(ctx), }, "serving_endpoint_id": types.StringType, }, @@ -3629,13 +3629,13 @@ func (a TrafficConfig) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of TrafficConfig in the Terraform plugin framework type +// ToObjectType returns the representation of TrafficConfig in the Terraform plugin framework type // system. -func (a TrafficConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a TrafficConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "routes": basetypes.ListType{ - ElemType: Route{}.ToAttrType(ctx), + ElemType: Route{}.ToObjectType(ctx), }, }, } @@ -3673,16 +3673,16 @@ func (a V1ResponseChoiceElement) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of V1ResponseChoiceElement in the Terraform plugin framework type +// ToObjectType returns the representation of V1ResponseChoiceElement in the Terraform plugin framework type // system. -func (a V1ResponseChoiceElement) ToAttrType(ctx context.Context) types.ObjectType { +func (a V1ResponseChoiceElement) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "finishReason": types.StringType, "index": types.Int64Type, "logprobs": types.Int64Type, "message": basetypes.ListType{ - ElemType: ChatMessage{}.ToAttrType(ctx), + ElemType: ChatMessage{}.ToObjectType(ctx), }, "text": types.StringType, }, diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index a498c70321..6ab16f9f5d 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -40,9 +40,9 @@ func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of AibiDashboardEmbeddingAccessPolicy in the Terraform plugin framework type +// ToObjectType returns the representation of AibiDashboardEmbeddingAccessPolicy in the Terraform plugin framework type // system. -func (a AibiDashboardEmbeddingAccessPolicy) ToAttrType(ctx context.Context) types.ObjectType { +func (a AibiDashboardEmbeddingAccessPolicy) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_policy_type": types.StringType, @@ -87,13 +87,13 @@ func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes(ctx cont } } -// ToAttrType returns the representation of AibiDashboardEmbeddingAccessPolicySetting in the Terraform plugin framework type +// ToObjectType returns the representation of AibiDashboardEmbeddingAccessPolicySetting in the Terraform plugin framework type // system. -func (a AibiDashboardEmbeddingAccessPolicySetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a AibiDashboardEmbeddingAccessPolicySetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aibi_dashboard_embedding_access_policy": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingAccessPolicy{}.ToAttrType(ctx), + ElemType: AibiDashboardEmbeddingAccessPolicy{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -124,9 +124,9 @@ func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes(ctx context. } } -// ToAttrType returns the representation of AibiDashboardEmbeddingApprovedDomains in the Terraform plugin framework type +// ToObjectType returns the representation of AibiDashboardEmbeddingApprovedDomains in the Terraform plugin framework type // system. -func (a AibiDashboardEmbeddingApprovedDomains) ToAttrType(ctx context.Context) types.ObjectType { +func (a AibiDashboardEmbeddingApprovedDomains) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "approved_domains": basetypes.ListType{ @@ -173,13 +173,13 @@ func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes(ctx c } } -// ToAttrType returns the representation of AibiDashboardEmbeddingApprovedDomainsSetting in the Terraform plugin framework type +// ToObjectType returns the representation of AibiDashboardEmbeddingApprovedDomainsSetting in the Terraform plugin framework type // system. -func (a AibiDashboardEmbeddingApprovedDomainsSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingApprovedDomains{}.ToAttrType(ctx), + ElemType: AibiDashboardEmbeddingApprovedDomains{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -224,13 +224,13 @@ func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of AutomaticClusterUpdateSetting in the Terraform plugin framework type +// ToObjectType returns the representation of AutomaticClusterUpdateSetting in the Terraform plugin framework type // system. -func (a AutomaticClusterUpdateSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a AutomaticClusterUpdateSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "automatic_cluster_update_workspace": basetypes.ListType{ - ElemType: ClusterAutoRestartMessage{}.ToAttrType(ctx), + ElemType: ClusterAutoRestartMessage{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -259,9 +259,9 @@ func (a BooleanMessage) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of BooleanMessage in the Terraform plugin framework type +// ToObjectType returns the representation of BooleanMessage in the Terraform plugin framework type // system. -func (a BooleanMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a BooleanMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.BoolType, @@ -306,18 +306,18 @@ func (a ClusterAutoRestartMessage) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ClusterAutoRestartMessage in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAutoRestartMessage in the Terraform plugin framework type // system. -func (a ClusterAutoRestartMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAutoRestartMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "can_toggle": types.BoolType, "enabled": types.BoolType, "enablement_details": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageEnablementDetails{}.ToAttrType(ctx), + ElemType: ClusterAutoRestartMessageEnablementDetails{}.ToObjectType(ctx), }, "maintenance_window": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.ToAttrType(ctx), + ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.ToObjectType(ctx), }, "restart_even_if_no_updates_available": types.BoolType, }, @@ -357,9 +357,9 @@ func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterAutoRestartMessageEnablementDetails in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAutoRestartMessageEnablementDetails in the Terraform plugin framework type // system. -func (a ClusterAutoRestartMessageEnablementDetails) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAutoRestartMessageEnablementDetails) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "forced_for_compliance_mode": types.BoolType, @@ -392,13 +392,13 @@ func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes(ctx con } } -// ToAttrType returns the representation of ClusterAutoRestartMessageMaintenanceWindow in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAutoRestartMessageMaintenanceWindow in the Terraform plugin framework type // system. -func (a ClusterAutoRestartMessageMaintenanceWindow) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAutoRestartMessageMaintenanceWindow) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "week_day_based_schedule": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.ToAttrType(ctx), + ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.ToObjectType(ctx), }, }, } @@ -431,15 +431,15 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetCompl } } -// ToAttrType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule in the Terraform plugin framework type // system. -func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "day_of_week": types.StringType, "frequency": types.StringType, "window_start_time": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.ToAttrType(ctx), + ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.ToObjectType(ctx), }, }, } @@ -468,9 +468,9 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFie return map[string]reflect.Type{} } -// ToAttrType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWindowStartTime in the Terraform plugin framework type +// ToObjectType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWindowStartTime in the Terraform plugin framework type // system. -func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToAttrType(ctx context.Context) types.ObjectType { +func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "hours": types.Int64Type, @@ -506,9 +506,9 @@ func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ComplianceSecurityProfile in the Terraform plugin framework type +// ToObjectType returns the representation of ComplianceSecurityProfile in the Terraform plugin framework type // system. -func (a ComplianceSecurityProfile) ToAttrType(ctx context.Context) types.ObjectType { +func (a ComplianceSecurityProfile) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compliance_standards": basetypes.ListType{ @@ -557,13 +557,13 @@ func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of ComplianceSecurityProfileSetting in the Terraform plugin framework type +// ToObjectType returns the representation of ComplianceSecurityProfileSetting in the Terraform plugin framework type // system. -func (a ComplianceSecurityProfileSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a ComplianceSecurityProfileSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compliance_security_profile_workspace": basetypes.ListType{ - ElemType: ComplianceSecurityProfile{}.ToAttrType(ctx), + ElemType: ComplianceSecurityProfile{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -606,25 +606,25 @@ func (a Config) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToAttrType returns the representation of Config in the Terraform plugin framework type +// ToObjectType returns the representation of Config in the Terraform plugin framework type // system. -func (a Config) ToAttrType(ctx context.Context) types.ObjectType { +func (a Config) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email": basetypes.ListType{ - ElemType: EmailConfig{}.ToAttrType(ctx), + ElemType: EmailConfig{}.ToObjectType(ctx), }, "generic_webhook": basetypes.ListType{ - ElemType: GenericWebhookConfig{}.ToAttrType(ctx), + ElemType: GenericWebhookConfig{}.ToObjectType(ctx), }, "microsoft_teams": basetypes.ListType{ - ElemType: MicrosoftTeamsConfig{}.ToAttrType(ctx), + ElemType: MicrosoftTeamsConfig{}.ToObjectType(ctx), }, "pagerduty": basetypes.ListType{ - ElemType: PagerdutyConfig{}.ToAttrType(ctx), + ElemType: PagerdutyConfig{}.ToObjectType(ctx), }, "slack": basetypes.ListType{ - ElemType: SlackConfig{}.ToAttrType(ctx), + ElemType: SlackConfig{}.ToObjectType(ctx), }, }, } @@ -663,9 +663,9 @@ func (a CreateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateIpAccessList in the Terraform plugin framework type +// ToObjectType returns the representation of CreateIpAccessList in the Terraform plugin framework type // system. -func (a CreateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateIpAccessList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_addresses": basetypes.ListType{ @@ -702,13 +702,13 @@ func (a CreateIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of CreateIpAccessListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateIpAccessListResponse in the Terraform plugin framework type // system. -func (a CreateIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToAttrType(ctx), + ElemType: IpAccessListInfo{}.ToObjectType(ctx), }, }, } @@ -743,9 +743,9 @@ func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateNetworkConnectivityConfigRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateNetworkConnectivityConfigRequest in the Terraform plugin framework type // system. -func (a CreateNetworkConnectivityConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateNetworkConnectivityConfigRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -781,13 +781,13 @@ func (a CreateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of CreateNotificationDestinationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateNotificationDestinationRequest in the Terraform plugin framework type // system. -func (a CreateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config": basetypes.ListType{ - ElemType: Config{}.ToAttrType(ctx), + ElemType: Config{}.ToObjectType(ctx), }, "display_name": types.StringType, }, @@ -821,9 +821,9 @@ func (a CreateOboTokenRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateOboTokenRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateOboTokenRequest in the Terraform plugin framework type // system. -func (a CreateOboTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateOboTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "application_id": types.StringType, @@ -859,13 +859,13 @@ func (a CreateOboTokenResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CreateOboTokenResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateOboTokenResponse in the Terraform plugin framework type // system. -func (a CreateOboTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateOboTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_info": basetypes.ListType{ - ElemType: TokenInfo{}.ToAttrType(ctx), + ElemType: TokenInfo{}.ToObjectType(ctx), }, "token_value": types.StringType, }, @@ -900,9 +900,9 @@ func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreatePrivateEndpointRuleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreatePrivateEndpointRuleRequest in the Terraform plugin framework type // system. -func (a CreatePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreatePrivateEndpointRuleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_id": types.StringType, @@ -938,9 +938,9 @@ func (a CreateTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateTokenRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateTokenRequest in the Terraform plugin framework type // system. -func (a CreateTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -975,13 +975,13 @@ func (a CreateTokenResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of CreateTokenResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateTokenResponse in the Terraform plugin framework type // system. -func (a CreateTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_info": basetypes.ListType{ - ElemType: PublicTokenInfo{}.ToAttrType(ctx), + ElemType: PublicTokenInfo{}.ToObjectType(ctx), }, "token_value": types.StringType, }, @@ -1016,9 +1016,9 @@ func (a CspEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of CspEnablementAccount in the Terraform plugin framework type +// ToObjectType returns the representation of CspEnablementAccount in the Terraform plugin framework type // system. -func (a CspEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { +func (a CspEnablementAccount) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compliance_standards": basetypes.ListType{ @@ -1067,13 +1067,13 @@ func (a CspEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of CspEnablementAccountSetting in the Terraform plugin framework type +// ToObjectType returns the representation of CspEnablementAccountSetting in the Terraform plugin framework type // system. -func (a CspEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a CspEnablementAccountSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "csp_enablement_account": basetypes.ListType{ - ElemType: CspEnablementAccount{}.ToAttrType(ctx), + ElemType: CspEnablementAccount{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -1128,14 +1128,14 @@ func (a DefaultNamespaceSetting) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of DefaultNamespaceSetting in the Terraform plugin framework type +// ToObjectType returns the representation of DefaultNamespaceSetting in the Terraform plugin framework type // system. -func (a DefaultNamespaceSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a DefaultNamespaceSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "namespace": basetypes.ListType{ - ElemType: StringMessage{}.ToAttrType(ctx), + ElemType: StringMessage{}.ToObjectType(ctx), }, "setting_name": types.StringType, }, @@ -1165,9 +1165,9 @@ func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAccountIpAccessListRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAccountIpAccessListRequest in the Terraform plugin framework type // system. -func (a DeleteAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAccountIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -1204,9 +1204,9 @@ func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDefaultNamespaceSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDefaultNamespaceSettingRequest in the Terraform plugin framework type // system. -func (a DeleteDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDefaultNamespaceSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1243,9 +1243,9 @@ func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDefaultNamespaceSettingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDefaultNamespaceSettingResponse in the Terraform plugin framework type // system. -func (a DeleteDefaultNamespaceSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDefaultNamespaceSettingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1282,9 +1282,9 @@ func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDisableLegacyAccessRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDisableLegacyAccessRequest in the Terraform plugin framework type // system. -func (a DeleteDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDisableLegacyAccessRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1321,9 +1321,9 @@ func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDisableLegacyAccessResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDisableLegacyAccessResponse in the Terraform plugin framework type // system. -func (a DeleteDisableLegacyAccessResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDisableLegacyAccessResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1360,9 +1360,9 @@ func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDisableLegacyDbfsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDisableLegacyDbfsRequest in the Terraform plugin framework type // system. -func (a DeleteDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDisableLegacyDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1399,9 +1399,9 @@ func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDisableLegacyDbfsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDisableLegacyDbfsResponse in the Terraform plugin framework type // system. -func (a DeleteDisableLegacyDbfsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDisableLegacyDbfsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1438,9 +1438,9 @@ func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDisableLegacyFeaturesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDisableLegacyFeaturesRequest in the Terraform plugin framework type // system. -func (a DeleteDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDisableLegacyFeaturesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1477,9 +1477,9 @@ func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDisableLegacyFeaturesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDisableLegacyFeaturesResponse in the Terraform plugin framework type // system. -func (a DeleteDisableLegacyFeaturesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDisableLegacyFeaturesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1510,9 +1510,9 @@ func (a DeleteIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteIpAccessListRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteIpAccessListRequest in the Terraform plugin framework type // system. -func (a DeleteIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -1543,9 +1543,9 @@ func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteNetworkConnectivityConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteNetworkConnectivityConfigurationRequest in the Terraform plugin framework type // system. -func (a DeleteNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteNetworkConnectivityConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -1573,9 +1573,9 @@ func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes(ctx return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteNetworkConnectivityConfigurationResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteNetworkConnectivityConfigurationResponse in the Terraform plugin framework type // system. -func (a DeleteNetworkConnectivityConfigurationResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteNetworkConnectivityConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1603,9 +1603,9 @@ func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteNotificationDestinationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteNotificationDestinationRequest in the Terraform plugin framework type // system. -func (a DeleteNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1642,9 +1642,9 @@ func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePersonalComputeSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePersonalComputeSettingRequest in the Terraform plugin framework type // system. -func (a DeletePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePersonalComputeSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1681,9 +1681,9 @@ func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePersonalComputeSettingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePersonalComputeSettingResponse in the Terraform plugin framework type // system. -func (a DeletePersonalComputeSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePersonalComputeSettingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1716,9 +1716,9 @@ func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeletePrivateEndpointRuleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeletePrivateEndpointRuleRequest in the Terraform plugin framework type // system. -func (a DeletePrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeletePrivateEndpointRuleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -1747,9 +1747,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1784,9 +1784,9 @@ func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type // system. -func (a DeleteRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRestrictWorkspaceAdminsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1823,9 +1823,9 @@ func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes(ctx c return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRestrictWorkspaceAdminsSettingResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRestrictWorkspaceAdminsSettingResponse in the Terraform plugin framework type // system. -func (a DeleteRestrictWorkspaceAdminsSettingResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRestrictWorkspaceAdminsSettingResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1856,9 +1856,9 @@ func (a DeleteTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteTokenManagementRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteTokenManagementRequest in the Terraform plugin framework type // system. -func (a DeleteTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteTokenManagementRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_id": types.StringType, @@ -1903,13 +1903,13 @@ func (a DisableLegacyAccess) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of DisableLegacyAccess in the Terraform plugin framework type +// ToObjectType returns the representation of DisableLegacyAccess in the Terraform plugin framework type // system. -func (a DisableLegacyAccess) ToAttrType(ctx context.Context) types.ObjectType { +func (a DisableLegacyAccess) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disable_legacy_access": basetypes.ListType{ - ElemType: BooleanMessage{}.ToAttrType(ctx), + ElemType: BooleanMessage{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -1954,13 +1954,13 @@ func (a DisableLegacyDbfs) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of DisableLegacyDbfs in the Terraform plugin framework type +// ToObjectType returns the representation of DisableLegacyDbfs in the Terraform plugin framework type // system. -func (a DisableLegacyDbfs) ToAttrType(ctx context.Context) types.ObjectType { +func (a DisableLegacyDbfs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disable_legacy_dbfs": basetypes.ListType{ - ElemType: BooleanMessage{}.ToAttrType(ctx), + ElemType: BooleanMessage{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2005,13 +2005,13 @@ func (a DisableLegacyFeatures) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of DisableLegacyFeatures in the Terraform plugin framework type +// ToObjectType returns the representation of DisableLegacyFeatures in the Terraform plugin framework type // system. -func (a DisableLegacyFeatures) ToAttrType(ctx context.Context) types.ObjectType { +func (a DisableLegacyFeatures) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disable_legacy_features": basetypes.ListType{ - ElemType: BooleanMessage{}.ToAttrType(ctx), + ElemType: BooleanMessage{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2043,9 +2043,9 @@ func (a EmailConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of EmailConfig in the Terraform plugin framework type +// ToObjectType returns the representation of EmailConfig in the Terraform plugin framework type // system. -func (a EmailConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a EmailConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "addresses": basetypes.ListType{ @@ -2075,9 +2075,9 @@ func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Empty in the Terraform plugin framework type +// ToObjectType returns the representation of Empty in the Terraform plugin framework type // system. -func (a Empty) ToAttrType(ctx context.Context) types.ObjectType { +func (a Empty) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2105,9 +2105,9 @@ func (a EnhancedSecurityMonitoring) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of EnhancedSecurityMonitoring in the Terraform plugin framework type +// ToObjectType returns the representation of EnhancedSecurityMonitoring in the Terraform plugin framework type // system. -func (a EnhancedSecurityMonitoring) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnhancedSecurityMonitoring) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_enabled": types.BoolType, @@ -2153,13 +2153,13 @@ func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of EnhancedSecurityMonitoringSetting in the Terraform plugin framework type +// ToObjectType returns the representation of EnhancedSecurityMonitoringSetting in the Terraform plugin framework type // system. -func (a EnhancedSecurityMonitoringSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnhancedSecurityMonitoringSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enhanced_security_monitoring_workspace": basetypes.ListType{ - ElemType: EnhancedSecurityMonitoring{}.ToAttrType(ctx), + ElemType: EnhancedSecurityMonitoring{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2189,9 +2189,9 @@ func (a EsmEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of EsmEnablementAccount in the Terraform plugin framework type +// ToObjectType returns the representation of EsmEnablementAccount in the Terraform plugin framework type // system. -func (a EsmEnablementAccount) ToAttrType(ctx context.Context) types.ObjectType { +func (a EsmEnablementAccount) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_enforced": types.BoolType, @@ -2237,13 +2237,13 @@ func (a EsmEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of EsmEnablementAccountSetting in the Terraform plugin framework type +// ToObjectType returns the representation of EsmEnablementAccountSetting in the Terraform plugin framework type // system. -func (a EsmEnablementAccountSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a EsmEnablementAccountSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "esm_enablement_account": basetypes.ListType{ - ElemType: EsmEnablementAccount{}.ToAttrType(ctx), + ElemType: EsmEnablementAccount{}.ToObjectType(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2285,9 +2285,9 @@ func (a ExchangeToken) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of ExchangeToken in the Terraform plugin framework type +// ToObjectType returns the representation of ExchangeToken in the Terraform plugin framework type // system. -func (a ExchangeToken) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExchangeToken) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential": types.StringType, @@ -2332,13 +2332,13 @@ func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ExchangeTokenRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExchangeTokenRequest in the Terraform plugin framework type // system. -func (a ExchangeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExchangeTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "partitionId": basetypes.ListType{ - ElemType: PartitionId{}.ToAttrType(ctx), + ElemType: PartitionId{}.ToObjectType(ctx), }, "scopes": basetypes.ListType{ ElemType: types.StringType, @@ -2374,13 +2374,13 @@ func (a ExchangeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ExchangeTokenResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ExchangeTokenResponse in the Terraform plugin framework type // system. -func (a ExchangeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExchangeTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "values": basetypes.ListType{ - ElemType: ExchangeToken{}.ToAttrType(ctx), + ElemType: ExchangeToken{}.ToObjectType(ctx), }, }, } @@ -2411,13 +2411,13 @@ func (a FetchIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of FetchIpAccessListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of FetchIpAccessListResponse in the Terraform plugin framework type // system. -func (a FetchIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a FetchIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToAttrType(ctx), + ElemType: IpAccessListInfo{}.ToObjectType(ctx), }, }, } @@ -2455,9 +2455,9 @@ func (a GenericWebhookConfig) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of GenericWebhookConfig in the Terraform plugin framework type +// ToObjectType returns the representation of GenericWebhookConfig in the Terraform plugin framework type // system. -func (a GenericWebhookConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a GenericWebhookConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "password": types.StringType, @@ -2493,9 +2493,9 @@ func (a GetAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAccountIpAccessListRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAccountIpAccessListRequest in the Terraform plugin framework type // system. -func (a GetAccountIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAccountIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -2532,9 +2532,9 @@ func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldType return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type // system. -func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2571,9 +2571,9 @@ func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldT return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type // system. -func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2610,9 +2610,9 @@ func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type // system. -func (a GetAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAutomaticClusterUpdateSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2649,9 +2649,9 @@ func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetComplianceSecurityProfileSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetComplianceSecurityProfileSettingRequest in the Terraform plugin framework type // system. -func (a GetComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetComplianceSecurityProfileSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2688,9 +2688,9 @@ func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCspEnablementAccountSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetCspEnablementAccountSettingRequest in the Terraform plugin framework type // system. -func (a GetCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCspEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2727,9 +2727,9 @@ func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDefaultNamespaceSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDefaultNamespaceSettingRequest in the Terraform plugin framework type // system. -func (a GetDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDefaultNamespaceSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2766,9 +2766,9 @@ func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDisableLegacyAccessRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDisableLegacyAccessRequest in the Terraform plugin framework type // system. -func (a GetDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDisableLegacyAccessRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2805,9 +2805,9 @@ func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDisableLegacyDbfsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDisableLegacyDbfsRequest in the Terraform plugin framework type // system. -func (a GetDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDisableLegacyDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2844,9 +2844,9 @@ func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDisableLegacyFeaturesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDisableLegacyFeaturesRequest in the Terraform plugin framework type // system. -func (a GetDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDisableLegacyFeaturesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2883,9 +2883,9 @@ func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type // system. -func (a GetEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEnhancedSecurityMonitoringSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2922,9 +2922,9 @@ func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetEsmEnablementAccountSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetEsmEnablementAccountSettingRequest in the Terraform plugin framework type // system. -func (a GetEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEsmEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2955,9 +2955,9 @@ func (a GetIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetIpAccessListRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetIpAccessListRequest in the Terraform plugin framework type // system. -func (a GetIpAccessListRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -2989,13 +2989,13 @@ func (a GetIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of GetIpAccessListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetIpAccessListResponse in the Terraform plugin framework type // system. -func (a GetIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToAttrType(ctx), + ElemType: IpAccessListInfo{}.ToObjectType(ctx), }, }, } @@ -3025,13 +3025,13 @@ func (a GetIpAccessListsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of GetIpAccessListsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetIpAccessListsResponse in the Terraform plugin framework type // system. -func (a GetIpAccessListsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetIpAccessListsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_lists": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToAttrType(ctx), + ElemType: IpAccessListInfo{}.ToObjectType(ctx), }, }, } @@ -3060,9 +3060,9 @@ func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetNetworkConnectivityConfigurationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetNetworkConnectivityConfigurationRequest in the Terraform plugin framework type // system. -func (a GetNetworkConnectivityConfigurationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetNetworkConnectivityConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -3092,9 +3092,9 @@ func (a GetNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetNotificationDestinationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetNotificationDestinationRequest in the Terraform plugin framework type // system. -func (a GetNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3131,9 +3131,9 @@ func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPersonalComputeSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPersonalComputeSettingRequest in the Terraform plugin framework type // system. -func (a GetPersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPersonalComputeSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -3166,9 +3166,9 @@ func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetPrivateEndpointRuleRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetPrivateEndpointRuleRequest in the Terraform plugin framework type // system. -func (a GetPrivateEndpointRuleRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetPrivateEndpointRuleRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -3206,9 +3206,9 @@ func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type // system. -func (a GetRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRestrictWorkspaceAdminsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -3238,9 +3238,9 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStatusRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStatusRequest in the Terraform plugin framework type // system. -func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "keys": types.StringType, @@ -3271,9 +3271,9 @@ func (a GetTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetTokenManagementRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetTokenManagementRequest in the Terraform plugin framework type // system. -func (a GetTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetTokenManagementRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_id": types.StringType, @@ -3305,13 +3305,13 @@ func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of GetTokenPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetTokenPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetTokenPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetTokenPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: TokenPermissionsDescription{}.ToAttrType(ctx), + ElemType: TokenPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -3341,13 +3341,13 @@ func (a GetTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of GetTokenResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetTokenResponse in the Terraform plugin framework type // system. -func (a GetTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_info": basetypes.ListType{ - ElemType: TokenInfo{}.ToAttrType(ctx), + ElemType: TokenInfo{}.ToObjectType(ctx), }, }, } @@ -3401,9 +3401,9 @@ func (a IpAccessListInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of IpAccessListInfo in the Terraform plugin framework type +// ToObjectType returns the representation of IpAccessListInfo in the Terraform plugin framework type // system. -func (a IpAccessListInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a IpAccessListInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "address_count": types.Int64Type, @@ -3446,13 +3446,13 @@ func (a ListIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of ListIpAccessListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListIpAccessListResponse in the Terraform plugin framework type // system. -func (a ListIpAccessListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_lists": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToAttrType(ctx), + ElemType: IpAccessListInfo{}.ToObjectType(ctx), }, }, } @@ -3484,13 +3484,13 @@ func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes(ctx conte } } -// ToAttrType returns the representation of ListNccAzurePrivateEndpointRulesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListNccAzurePrivateEndpointRulesResponse in the Terraform plugin framework type // system. -func (a ListNccAzurePrivateEndpointRulesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNccAzurePrivateEndpointRulesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "items": basetypes.ListType{ - ElemType: NccAzurePrivateEndpointRule{}.ToAttrType(ctx), + ElemType: NccAzurePrivateEndpointRule{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -3520,9 +3520,9 @@ func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes(ctx c return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListNetworkConnectivityConfigurationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListNetworkConnectivityConfigurationsRequest in the Terraform plugin framework type // system. -func (a ListNetworkConnectivityConfigurationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNetworkConnectivityConfigurationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -3556,13 +3556,13 @@ func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes(ctx } } -// ToAttrType returns the representation of ListNetworkConnectivityConfigurationsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListNetworkConnectivityConfigurationsResponse in the Terraform plugin framework type // system. -func (a ListNetworkConnectivityConfigurationsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNetworkConnectivityConfigurationsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "items": basetypes.ListType{ - ElemType: NetworkConnectivityConfiguration{}.ToAttrType(ctx), + ElemType: NetworkConnectivityConfiguration{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -3593,9 +3593,9 @@ func (a ListNotificationDestinationsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListNotificationDestinationsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListNotificationDestinationsRequest in the Terraform plugin framework type // system. -func (a ListNotificationDestinationsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNotificationDestinationsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -3630,14 +3630,14 @@ func (a ListNotificationDestinationsResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of ListNotificationDestinationsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListNotificationDestinationsResponse in the Terraform plugin framework type // system. -func (a ListNotificationDestinationsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNotificationDestinationsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: ListNotificationDestinationsResult{}.ToAttrType(ctx), + ElemType: ListNotificationDestinationsResult{}.ToObjectType(ctx), }, }, } @@ -3670,9 +3670,9 @@ func (a ListNotificationDestinationsResult) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListNotificationDestinationsResult in the Terraform plugin framework type +// ToObjectType returns the representation of ListNotificationDestinationsResult in the Terraform plugin framework type // system. -func (a ListNotificationDestinationsResult) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListNotificationDestinationsResult) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_type": types.StringType, @@ -3707,9 +3707,9 @@ func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListPrivateEndpointRulesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListPrivateEndpointRulesRequest in the Terraform plugin framework type // system. -func (a ListPrivateEndpointRulesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPrivateEndpointRulesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -3742,13 +3742,13 @@ func (a ListPublicTokensResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of ListPublicTokensResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListPublicTokensResponse in the Terraform plugin framework type // system. -func (a ListPublicTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListPublicTokensResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_infos": basetypes.ListType{ - ElemType: PublicTokenInfo{}.ToAttrType(ctx), + ElemType: PublicTokenInfo{}.ToObjectType(ctx), }, }, } @@ -3779,9 +3779,9 @@ func (a ListTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListTokenManagementRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListTokenManagementRequest in the Terraform plugin framework type // system. -func (a ListTokenManagementRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTokenManagementRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_by_id": types.Int64Type, @@ -3815,13 +3815,13 @@ func (a ListTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListTokensResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListTokensResponse in the Terraform plugin framework type // system. -func (a ListTokensResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListTokensResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_infos": basetypes.ListType{ - ElemType: TokenInfo{}.ToAttrType(ctx), + ElemType: TokenInfo{}.ToObjectType(ctx), }, }, } @@ -3851,9 +3851,9 @@ func (a MicrosoftTeamsConfig) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of MicrosoftTeamsConfig in the Terraform plugin framework type +// ToObjectType returns the representation of MicrosoftTeamsConfig in the Terraform plugin framework type // system. -func (a MicrosoftTeamsConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a MicrosoftTeamsConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "url": types.StringType, @@ -3889,9 +3889,9 @@ func (a NccAwsStableIpRule) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of NccAwsStableIpRule in the Terraform plugin framework type +// ToObjectType returns the representation of NccAwsStableIpRule in the Terraform plugin framework type // system. -func (a NccAwsStableIpRule) ToAttrType(ctx context.Context) types.ObjectType { +func (a NccAwsStableIpRule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cidr_blocks": basetypes.ListType{ @@ -3956,9 +3956,9 @@ func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of NccAzurePrivateEndpointRule in the Terraform plugin framework type +// ToObjectType returns the representation of NccAzurePrivateEndpointRule in the Terraform plugin framework type // system. -func (a NccAzurePrivateEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { +func (a NccAzurePrivateEndpointRule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connection_state": types.StringType, @@ -4008,9 +4008,9 @@ func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of NccAzureServiceEndpointRule in the Terraform plugin framework type +// ToObjectType returns the representation of NccAzureServiceEndpointRule in the Terraform plugin framework type // system. -func (a NccAzureServiceEndpointRule) ToAttrType(ctx context.Context) types.ObjectType { +func (a NccAzureServiceEndpointRule) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "subnets": basetypes.ListType{ @@ -4056,16 +4056,16 @@ func (a NccEgressConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of NccEgressConfig in the Terraform plugin framework type +// ToObjectType returns the representation of NccEgressConfig in the Terraform plugin framework type // system. -func (a NccEgressConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a NccEgressConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_rules": basetypes.ListType{ - ElemType: NccEgressDefaultRules{}.ToAttrType(ctx), + ElemType: NccEgressDefaultRules{}.ToObjectType(ctx), }, "target_rules": basetypes.ListType{ - ElemType: NccEgressTargetRules{}.ToAttrType(ctx), + ElemType: NccEgressTargetRules{}.ToObjectType(ctx), }, }, } @@ -4105,16 +4105,16 @@ func (a NccEgressDefaultRules) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of NccEgressDefaultRules in the Terraform plugin framework type +// ToObjectType returns the representation of NccEgressDefaultRules in the Terraform plugin framework type // system. -func (a NccEgressDefaultRules) ToAttrType(ctx context.Context) types.ObjectType { +func (a NccEgressDefaultRules) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_stable_ip_rule": basetypes.ListType{ - ElemType: NccAwsStableIpRule{}.ToAttrType(ctx), + ElemType: NccAwsStableIpRule{}.ToObjectType(ctx), }, "azure_service_endpoint_rule": basetypes.ListType{ - ElemType: NccAzureServiceEndpointRule{}.ToAttrType(ctx), + ElemType: NccAzureServiceEndpointRule{}.ToObjectType(ctx), }, }, } @@ -4145,13 +4145,13 @@ func (a NccEgressTargetRules) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of NccEgressTargetRules in the Terraform plugin framework type +// ToObjectType returns the representation of NccEgressTargetRules in the Terraform plugin framework type // system. -func (a NccEgressTargetRules) ToAttrType(ctx context.Context) types.ObjectType { +func (a NccEgressTargetRules) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "azure_private_endpoint_rules": basetypes.ListType{ - ElemType: NccAzurePrivateEndpointRule{}.ToAttrType(ctx), + ElemType: NccAzurePrivateEndpointRule{}.ToObjectType(ctx), }, }, } @@ -4199,15 +4199,15 @@ func (a NetworkConnectivityConfiguration) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of NetworkConnectivityConfiguration in the Terraform plugin framework type +// ToObjectType returns the representation of NetworkConnectivityConfiguration in the Terraform plugin framework type // system. -func (a NetworkConnectivityConfiguration) ToAttrType(ctx context.Context) types.ObjectType { +func (a NetworkConnectivityConfiguration) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, "egress_config": basetypes.ListType{ - ElemType: NccEgressConfig{}.ToAttrType(ctx), + ElemType: NccEgressConfig{}.ToObjectType(ctx), }, "name": types.StringType, "network_connectivity_config_id": types.StringType, @@ -4250,13 +4250,13 @@ func (a NotificationDestination) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of NotificationDestination in the Terraform plugin framework type +// ToObjectType returns the representation of NotificationDestination in the Terraform plugin framework type // system. -func (a NotificationDestination) ToAttrType(ctx context.Context) types.ObjectType { +func (a NotificationDestination) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config": basetypes.ListType{ - ElemType: Config{}.ToAttrType(ctx), + ElemType: Config{}.ToObjectType(ctx), }, "destination_type": types.StringType, "display_name": types.StringType, @@ -4289,9 +4289,9 @@ func (a PagerdutyConfig) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of PagerdutyConfig in the Terraform plugin framework type +// ToObjectType returns the representation of PagerdutyConfig in the Terraform plugin framework type // system. -func (a PagerdutyConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a PagerdutyConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_key": types.StringType, @@ -4323,9 +4323,9 @@ func (a PartitionId) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of PartitionId in the Terraform plugin framework type +// ToObjectType returns the representation of PartitionId in the Terraform plugin framework type // system. -func (a PartitionId) ToAttrType(ctx context.Context) types.ObjectType { +func (a PartitionId) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspaceId": types.Int64Type, @@ -4361,9 +4361,9 @@ func (a PersonalComputeMessage) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of PersonalComputeMessage in the Terraform plugin framework type +// ToObjectType returns the representation of PersonalComputeMessage in the Terraform plugin framework type // system. -func (a PersonalComputeMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a PersonalComputeMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.StringType, @@ -4409,14 +4409,14 @@ func (a PersonalComputeSetting) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of PersonalComputeSetting in the Terraform plugin framework type +// ToObjectType returns the representation of PersonalComputeSetting in the Terraform plugin framework type // system. -func (a PersonalComputeSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a PersonalComputeSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "personal_compute": basetypes.ListType{ - ElemType: PersonalComputeMessage{}.ToAttrType(ctx), + ElemType: PersonalComputeMessage{}.ToObjectType(ctx), }, "setting_name": types.StringType, }, @@ -4452,9 +4452,9 @@ func (a PublicTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of PublicTokenInfo in the Terraform plugin framework type +// ToObjectType returns the representation of PublicTokenInfo in the Terraform plugin framework type // system. -func (a PublicTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a PublicTokenInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4503,9 +4503,9 @@ func (a ReplaceIpAccessList) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ReplaceIpAccessList in the Terraform plugin framework type +// ToObjectType returns the representation of ReplaceIpAccessList in the Terraform plugin framework type // system. -func (a ReplaceIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReplaceIpAccessList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -4539,9 +4539,9 @@ func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ReplaceResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ReplaceResponse in the Terraform plugin framework type // system. -func (a ReplaceResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ReplaceResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4568,9 +4568,9 @@ func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestrictWorkspaceAdminsMessage in the Terraform plugin framework type +// ToObjectType returns the representation of RestrictWorkspaceAdminsMessage in the Terraform plugin framework type // system. -func (a RestrictWorkspaceAdminsMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestrictWorkspaceAdminsMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "status": types.StringType, @@ -4616,14 +4616,14 @@ func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of RestrictWorkspaceAdminsSetting in the Terraform plugin framework type +// ToObjectType returns the representation of RestrictWorkspaceAdminsSetting in the Terraform plugin framework type // system. -func (a RestrictWorkspaceAdminsSetting) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestrictWorkspaceAdminsSetting) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "restrict_workspace_admins": basetypes.ListType{ - ElemType: RestrictWorkspaceAdminsMessage{}.ToAttrType(ctx), + ElemType: RestrictWorkspaceAdminsMessage{}.ToObjectType(ctx), }, "setting_name": types.StringType, }, @@ -4652,9 +4652,9 @@ func (a RevokeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of RevokeTokenRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RevokeTokenRequest in the Terraform plugin framework type // system. -func (a RevokeTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RevokeTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_id": types.StringType, @@ -4682,9 +4682,9 @@ func (a RevokeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of RevokeTokenResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RevokeTokenResponse in the Terraform plugin framework type // system. -func (a RevokeTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RevokeTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4710,9 +4710,9 @@ func (a SetStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetStatusResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetStatusResponse in the Terraform plugin framework type // system. -func (a SetStatusResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4742,9 +4742,9 @@ func (a SlackConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of SlackConfig in the Terraform plugin framework type +// ToObjectType returns the representation of SlackConfig in the Terraform plugin framework type // system. -func (a SlackConfig) ToAttrType(ctx context.Context) types.ObjectType { +func (a SlackConfig) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "url": types.StringType, @@ -4775,9 +4775,9 @@ func (a StringMessage) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of StringMessage in the Terraform plugin framework type +// ToObjectType returns the representation of StringMessage in the Terraform plugin framework type // system. -func (a StringMessage) ToAttrType(ctx context.Context) types.ObjectType { +func (a StringMessage) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.StringType, @@ -4813,9 +4813,9 @@ func (a TokenAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of TokenAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TokenAccessControlRequest in the Terraform plugin framework type // system. -func (a TokenAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -4858,13 +4858,13 @@ func (a TokenAccessControlResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of TokenAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of TokenAccessControlResponse in the Terraform plugin framework type // system. -func (a TokenAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: TokenPermission{}.ToAttrType(ctx), + ElemType: TokenPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -4914,9 +4914,9 @@ func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of TokenInfo in the Terraform plugin framework type +// ToObjectType returns the representation of TokenInfo in the Terraform plugin framework type // system. -func (a TokenInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4959,9 +4959,9 @@ func (a TokenPermission) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of TokenPermission in the Terraform plugin framework type +// ToObjectType returns the representation of TokenPermission in the Terraform plugin framework type // system. -func (a TokenPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -5000,13 +5000,13 @@ func (a TokenPermissions) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of TokenPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of TokenPermissions in the Terraform plugin framework type // system. -func (a TokenPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: TokenAccessControlResponse{}.ToAttrType(ctx), + ElemType: TokenAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -5037,9 +5037,9 @@ func (a TokenPermissionsDescription) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of TokenPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of TokenPermissionsDescription in the Terraform plugin framework type // system. -func (a TokenPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -5071,13 +5071,13 @@ func (a TokenPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of TokenPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TokenPermissionsRequest in the Terraform plugin framework type // system. -func (a TokenPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TokenPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: TokenAccessControlRequest{}.ToAttrType(ctx), + ElemType: TokenAccessControlRequest{}.ToObjectType(ctx), }, }, } @@ -5116,15 +5116,15 @@ func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldT } } -// ToAttrType returns the representation of UpdateAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type // system. -func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.ToAttrType(ctx), + ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.ToObjectType(ctx), }, }, } @@ -5163,15 +5163,15 @@ func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFie } } -// ToAttrType returns the representation of UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type // system. -func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.ToAttrType(ctx), + ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.ToObjectType(ctx), }, }, } @@ -5210,15 +5210,15 @@ func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx con } } -// ToAttrType returns the representation of UpdateAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type // system. -func (a UpdateAutomaticClusterUpdateSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAutomaticClusterUpdateSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: AutomaticClusterUpdateSetting{}.ToAttrType(ctx), + ElemType: AutomaticClusterUpdateSetting{}.ToObjectType(ctx), }, }, } @@ -5257,15 +5257,15 @@ func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx } } -// ToAttrType returns the representation of UpdateComplianceSecurityProfileSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateComplianceSecurityProfileSettingRequest in the Terraform plugin framework type // system. -func (a UpdateComplianceSecurityProfileSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateComplianceSecurityProfileSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: ComplianceSecurityProfileSetting{}.ToAttrType(ctx), + ElemType: ComplianceSecurityProfileSetting{}.ToObjectType(ctx), }, }, } @@ -5304,15 +5304,15 @@ func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx conte } } -// ToAttrType returns the representation of UpdateCspEnablementAccountSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCspEnablementAccountSettingRequest in the Terraform plugin framework type // system. -func (a UpdateCspEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCspEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: CspEnablementAccountSetting{}.ToAttrType(ctx), + ElemType: CspEnablementAccountSetting{}.ToObjectType(ctx), }, }, } @@ -5359,15 +5359,15 @@ func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of UpdateDefaultNamespaceSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateDefaultNamespaceSettingRequest in the Terraform plugin framework type // system. -func (a UpdateDefaultNamespaceSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateDefaultNamespaceSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DefaultNamespaceSetting{}.ToAttrType(ctx), + ElemType: DefaultNamespaceSetting{}.ToObjectType(ctx), }, }, } @@ -5406,15 +5406,15 @@ func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of UpdateDisableLegacyAccessRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateDisableLegacyAccessRequest in the Terraform plugin framework type // system. -func (a UpdateDisableLegacyAccessRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateDisableLegacyAccessRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DisableLegacyAccess{}.ToAttrType(ctx), + ElemType: DisableLegacyAccess{}.ToObjectType(ctx), }, }, } @@ -5453,15 +5453,15 @@ func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of UpdateDisableLegacyDbfsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateDisableLegacyDbfsRequest in the Terraform plugin framework type // system. -func (a UpdateDisableLegacyDbfsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateDisableLegacyDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DisableLegacyDbfs{}.ToAttrType(ctx), + ElemType: DisableLegacyDbfs{}.ToObjectType(ctx), }, }, } @@ -5500,15 +5500,15 @@ func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of UpdateDisableLegacyFeaturesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateDisableLegacyFeaturesRequest in the Terraform plugin framework type // system. -func (a UpdateDisableLegacyFeaturesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateDisableLegacyFeaturesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DisableLegacyFeatures{}.ToAttrType(ctx), + ElemType: DisableLegacyFeatures{}.ToObjectType(ctx), }, }, } @@ -5547,15 +5547,15 @@ func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx } } -// ToAttrType returns the representation of UpdateEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type // system. -func (a UpdateEnhancedSecurityMonitoringSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateEnhancedSecurityMonitoringSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: EnhancedSecurityMonitoringSetting{}.ToAttrType(ctx), + ElemType: EnhancedSecurityMonitoringSetting{}.ToObjectType(ctx), }, }, } @@ -5594,15 +5594,15 @@ func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx conte } } -// ToAttrType returns the representation of UpdateEsmEnablementAccountSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateEsmEnablementAccountSettingRequest in the Terraform plugin framework type // system. -func (a UpdateEsmEnablementAccountSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateEsmEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: EsmEnablementAccountSetting{}.ToAttrType(ctx), + ElemType: EsmEnablementAccountSetting{}.ToObjectType(ctx), }, }, } @@ -5646,9 +5646,9 @@ func (a UpdateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of UpdateIpAccessList in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateIpAccessList in the Terraform plugin framework type // system. -func (a UpdateIpAccessList) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateIpAccessList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -5691,13 +5691,13 @@ func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of UpdateNotificationDestinationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateNotificationDestinationRequest in the Terraform plugin framework type // system. -func (a UpdateNotificationDestinationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config": basetypes.ListType{ - ElemType: Config{}.ToAttrType(ctx), + ElemType: Config{}.ToObjectType(ctx), }, "display_name": types.StringType, "id": types.StringType, @@ -5738,15 +5738,15 @@ func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Co } } -// ToAttrType returns the representation of UpdatePersonalComputeSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePersonalComputeSettingRequest in the Terraform plugin framework type // system. -func (a UpdatePersonalComputeSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePersonalComputeSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: PersonalComputeSetting{}.ToAttrType(ctx), + ElemType: PersonalComputeSetting{}.ToObjectType(ctx), }, }, } @@ -5772,9 +5772,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5813,15 +5813,15 @@ func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx co } } -// ToAttrType returns the representation of UpdateRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type // system. -func (a UpdateRestrictWorkspaceAdminsSettingRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRestrictWorkspaceAdminsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: RestrictWorkspaceAdminsSetting{}.ToAttrType(ctx), + ElemType: RestrictWorkspaceAdminsSetting{}.ToObjectType(ctx), }, }, } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index d70988d86d..1507de7c05 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -50,9 +50,9 @@ func (a CreateProvider) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateProvider in the Terraform plugin framework type +// ToObjectType returns the representation of CreateProvider in the Terraform plugin framework type // system. -func (a CreateProvider) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateProvider) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authentication_type": types.StringType, @@ -108,9 +108,9 @@ func (a CreateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of CreateRecipient in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRecipient in the Terraform plugin framework type // system. -func (a CreateRecipient) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRecipient) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authentication_type": types.StringType, @@ -118,12 +118,12 @@ func (a CreateRecipient) ToAttrType(ctx context.Context) types.ObjectType { "data_recipient_global_metastore_id": types.StringType, "expiration_time": types.Int64Type, "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.ToAttrType(ctx), + ElemType: IpAccessList{}.ToObjectType(ctx), }, "name": types.StringType, "owner": types.StringType, "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.ToAttrType(ctx), + ElemType: SecurablePropertiesKvPairs{}.ToObjectType(ctx), }, "sharing_code": types.StringType, }, @@ -156,9 +156,9 @@ func (a CreateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateShare in the Terraform plugin framework type +// ToObjectType returns the representation of CreateShare in the Terraform plugin framework type // system. -func (a CreateShare) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateShare) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -191,9 +191,9 @@ func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteProviderRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteProviderRequest in the Terraform plugin framework type // system. -func (a DeleteProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -224,9 +224,9 @@ func (a DeleteRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRecipientRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRecipientRequest in the Terraform plugin framework type // system. -func (a DeleteRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRecipientRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -254,9 +254,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -285,9 +285,9 @@ func (a DeleteShareRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteShareRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteShareRequest in the Terraform plugin framework type // system. -func (a DeleteShareRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteShareRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -318,9 +318,9 @@ func (a GetActivationUrlInfoRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetActivationUrlInfoRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetActivationUrlInfoRequest in the Terraform plugin framework type // system. -func (a GetActivationUrlInfoRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetActivationUrlInfoRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -348,9 +348,9 @@ func (a GetActivationUrlInfoResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetActivationUrlInfoResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetActivationUrlInfoResponse in the Terraform plugin framework type // system. -func (a GetActivationUrlInfoResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetActivationUrlInfoResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -379,9 +379,9 @@ func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetProviderRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetProviderRequest in the Terraform plugin framework type // system. -func (a GetProviderRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -412,9 +412,9 @@ func (a GetRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRecipientRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRecipientRequest in the Terraform plugin framework type // system. -func (a GetRecipientRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRecipientRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -450,14 +450,14 @@ func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of GetRecipientSharePermissionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetRecipientSharePermissionsResponse in the Terraform plugin framework type // system. -func (a GetRecipientSharePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRecipientSharePermissionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "permissions_out": basetypes.ListType{ - ElemType: ShareToPrivilegeAssignment{}.ToAttrType(ctx), + ElemType: ShareToPrivilegeAssignment{}.ToObjectType(ctx), }, }, } @@ -488,9 +488,9 @@ func (a GetShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetShareRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetShareRequest in the Terraform plugin framework type // system. -func (a GetShareRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetShareRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_shared_data": types.BoolType, @@ -523,9 +523,9 @@ func (a IpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of IpAccessList in the Terraform plugin framework type +// ToObjectType returns the representation of IpAccessList in the Terraform plugin framework type // system. -func (a IpAccessList) ToAttrType(ctx context.Context) types.ObjectType { +func (a IpAccessList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allowed_ip_addresses": basetypes.ListType{ @@ -563,14 +563,14 @@ func (a ListProviderSharesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ListProviderSharesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListProviderSharesResponse in the Terraform plugin framework type // system. -func (a ListProviderSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListProviderSharesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "shares": basetypes.ListType{ - ElemType: ProviderShare{}.ToAttrType(ctx), + ElemType: ProviderShare{}.ToObjectType(ctx), }, }, } @@ -612,9 +612,9 @@ func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListProvidersRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListProvidersRequest in the Terraform plugin framework type // system. -func (a ListProvidersRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListProvidersRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_provider_global_metastore_id": types.StringType, @@ -652,14 +652,14 @@ func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of ListProvidersResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListProvidersResponse in the Terraform plugin framework type // system. -func (a ListProvidersResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListProvidersResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.ToAttrType(ctx), + ElemType: ProviderInfo{}.ToObjectType(ctx), }, }, } @@ -701,9 +701,9 @@ func (a ListRecipientsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListRecipientsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListRecipientsRequest in the Terraform plugin framework type // system. -func (a ListRecipientsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRecipientsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_recipient_global_metastore_id": types.StringType, @@ -741,14 +741,14 @@ func (a ListRecipientsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ListRecipientsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListRecipientsResponse in the Terraform plugin framework type // system. -func (a ListRecipientsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListRecipientsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "recipients": basetypes.ListType{ - ElemType: RecipientInfo{}.ToAttrType(ctx), + ElemType: RecipientInfo{}.ToObjectType(ctx), }, }, } @@ -789,9 +789,9 @@ func (a ListSharesRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSharesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSharesRequest in the Terraform plugin framework type // system. -func (a ListSharesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSharesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -829,14 +829,14 @@ func (a ListSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListSharesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListSharesResponse in the Terraform plugin framework type // system. -func (a ListSharesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSharesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "shares": basetypes.ListType{ - ElemType: ShareInfo{}.ToAttrType(ctx), + ElemType: ShareInfo{}.ToObjectType(ctx), }, }, } @@ -866,13 +866,13 @@ func (a Partition) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of Partition in the Terraform plugin framework type +// ToObjectType returns the representation of Partition in the Terraform plugin framework type // system. -func (a Partition) ToAttrType(ctx context.Context) types.ObjectType { +func (a Partition) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": basetypes.ListType{ - ElemType: PartitionValue{}.ToAttrType(ctx), + ElemType: PartitionValue{}.ToObjectType(ctx), }, }, } @@ -910,9 +910,9 @@ func (a PartitionValue) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of PartitionValue in the Terraform plugin framework type +// ToObjectType returns the representation of PartitionValue in the Terraform plugin framework type // system. -func (a PartitionValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a PartitionValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -949,9 +949,9 @@ func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of PrivilegeAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of PrivilegeAssignment in the Terraform plugin framework type // system. -func (a PrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a PrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -1019,9 +1019,9 @@ func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ProviderInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ProviderInfo in the Terraform plugin framework type // system. -func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ProviderInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authentication_type": types.StringType, @@ -1034,7 +1034,7 @@ func (a ProviderInfo) ToAttrType(ctx context.Context) types.ObjectType { "name": types.StringType, "owner": types.StringType, "recipient_profile": basetypes.ListType{ - ElemType: RecipientProfile{}.ToAttrType(ctx), + ElemType: RecipientProfile{}.ToObjectType(ctx), }, "recipient_profile_str": types.StringType, "region": types.StringType, @@ -1066,9 +1066,9 @@ func (a ProviderShare) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ProviderShare in the Terraform plugin framework type +// ToObjectType returns the representation of ProviderShare in the Terraform plugin framework type // system. -func (a ProviderShare) ToAttrType(ctx context.Context) types.ObjectType { +func (a ProviderShare) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1145,9 +1145,9 @@ func (a RecipientInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of RecipientInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RecipientInfo in the Terraform plugin framework type // system. -func (a RecipientInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RecipientInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activated": types.BoolType, @@ -1159,18 +1159,18 @@ func (a RecipientInfo) ToAttrType(ctx context.Context) types.ObjectType { "created_by": types.StringType, "data_recipient_global_metastore_id": types.StringType, "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.ToAttrType(ctx), + ElemType: IpAccessList{}.ToObjectType(ctx), }, "metastore_id": types.StringType, "name": types.StringType, "owner": types.StringType, "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.ToAttrType(ctx), + ElemType: SecurablePropertiesKvPairs{}.ToObjectType(ctx), }, "region": types.StringType, "sharing_code": types.StringType, "tokens": basetypes.ListType{ - ElemType: RecipientTokenInfo{}.ToAttrType(ctx), + ElemType: RecipientTokenInfo{}.ToObjectType(ctx), }, "updated_at": types.Int64Type, "updated_by": types.StringType, @@ -1204,9 +1204,9 @@ func (a RecipientProfile) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of RecipientProfile in the Terraform plugin framework type +// ToObjectType returns the representation of RecipientProfile in the Terraform plugin framework type // system. -func (a RecipientProfile) ToAttrType(ctx context.Context) types.ObjectType { +func (a RecipientProfile) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bearer_token": types.StringType, @@ -1251,9 +1251,9 @@ func (a RecipientTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of RecipientTokenInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RecipientTokenInfo in the Terraform plugin framework type // system. -func (a RecipientTokenInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RecipientTokenInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -1290,9 +1290,9 @@ func (a RetrieveTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of RetrieveTokenRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RetrieveTokenRequest in the Terraform plugin framework type // system. -func (a RetrieveTokenRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RetrieveTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -1328,9 +1328,9 @@ func (a RetrieveTokenResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of RetrieveTokenResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RetrieveTokenResponse in the Terraform plugin framework type // system. -func (a RetrieveTokenResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RetrieveTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bearerToken": types.StringType, @@ -1368,9 +1368,9 @@ func (a RotateRecipientToken) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of RotateRecipientToken in the Terraform plugin framework type +// ToObjectType returns the representation of RotateRecipientToken in the Terraform plugin framework type // system. -func (a RotateRecipientToken) ToAttrType(ctx context.Context) types.ObjectType { +func (a RotateRecipientToken) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "existing_token_expire_in_seconds": types.Int64Type, @@ -1405,9 +1405,9 @@ func (a SecurablePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of SecurablePropertiesKvPairs in the Terraform plugin framework type +// ToObjectType returns the representation of SecurablePropertiesKvPairs in the Terraform plugin framework type // system. -func (a SecurablePropertiesKvPairs) ToAttrType(ctx context.Context) types.ObjectType { +func (a SecurablePropertiesKvPairs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "properties": basetypes.MapType{ @@ -1459,9 +1459,9 @@ func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of ShareInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ShareInfo in the Terraform plugin framework type // system. -func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ShareInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1469,7 +1469,7 @@ func (a ShareInfo) ToAttrType(ctx context.Context) types.ObjectType { "created_by": types.StringType, "name": types.StringType, "object": basetypes.ListType{ - ElemType: SharedDataObject{}.ToAttrType(ctx), + ElemType: SharedDataObject{}.ToObjectType(ctx), }, "owner": types.StringType, "storage_location": types.StringType, @@ -1515,9 +1515,9 @@ func (a SharePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of SharePermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SharePermissionsRequest in the Terraform plugin framework type // system. -func (a SharePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SharePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -1553,13 +1553,13 @@ func (a ShareToPrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of ShareToPrivilegeAssignment in the Terraform plugin framework type +// ToObjectType returns the representation of ShareToPrivilegeAssignment in the Terraform plugin framework type // system. -func (a ShareToPrivilegeAssignment) ToAttrType(ctx context.Context) types.ObjectType { +func (a ShareToPrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "privilege_assignments": basetypes.ListType{ - ElemType: PrivilegeAssignment{}.ToAttrType(ctx), + ElemType: PrivilegeAssignment{}.ToObjectType(ctx), }, "share_name": types.StringType, }, @@ -1635,9 +1635,9 @@ func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of SharedDataObject in the Terraform plugin framework type +// ToObjectType returns the representation of SharedDataObject in the Terraform plugin framework type // system. -func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { +func (a SharedDataObject) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "added_at": types.Int64Type, @@ -1649,7 +1649,7 @@ func (a SharedDataObject) ToAttrType(ctx context.Context) types.ObjectType { "history_data_sharing_status": types.StringType, "name": types.StringType, "partition": basetypes.ListType{ - ElemType: Partition{}.ToAttrType(ctx), + ElemType: Partition{}.ToObjectType(ctx), }, "shared_as": types.StringType, "start_version": types.Int64Type, @@ -1685,14 +1685,14 @@ func (a SharedDataObjectUpdate) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of SharedDataObjectUpdate in the Terraform plugin framework type +// ToObjectType returns the representation of SharedDataObjectUpdate in the Terraform plugin framework type // system. -func (a SharedDataObjectUpdate) ToAttrType(ctx context.Context) types.ObjectType { +func (a SharedDataObjectUpdate) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action": types.StringType, "data_object": basetypes.ListType{ - ElemType: SharedDataObject{}.ToAttrType(ctx), + ElemType: SharedDataObject{}.ToObjectType(ctx), }, }, } @@ -1718,9 +1718,9 @@ func (a UpdatePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdatePermissionsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdatePermissionsResponse in the Terraform plugin framework type // system. -func (a UpdatePermissionsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdatePermissionsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1757,9 +1757,9 @@ func (a UpdateProvider) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateProvider in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateProvider in the Terraform plugin framework type // system. -func (a UpdateProvider) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateProvider) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1811,21 +1811,21 @@ func (a UpdateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of UpdateRecipient in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRecipient in the Terraform plugin framework type // system. -func (a UpdateRecipient) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRecipient) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "expiration_time": types.Int64Type, "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.ToAttrType(ctx), + ElemType: IpAccessList{}.ToObjectType(ctx), }, "name": types.StringType, "new_name": types.StringType, "owner": types.StringType, "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.ToAttrType(ctx), + ElemType: SecurablePropertiesKvPairs{}.ToObjectType(ctx), }, }, } @@ -1851,9 +1851,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1893,9 +1893,9 @@ func (a UpdateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of UpdateShare in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateShare in the Terraform plugin framework type // system. -func (a UpdateShare) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateShare) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1904,7 +1904,7 @@ func (a UpdateShare) ToAttrType(ctx context.Context) types.ObjectType { "owner": types.StringType, "storage_root": types.StringType, "updates": basetypes.ListType{ - ElemType: SharedDataObjectUpdate{}.ToAttrType(ctx), + ElemType: SharedDataObjectUpdate{}.ToObjectType(ctx), }, }, } @@ -1948,13 +1948,13 @@ func (a UpdateSharePermissions) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of UpdateSharePermissions in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateSharePermissions in the Terraform plugin framework type // system. -func (a UpdateSharePermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateSharePermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "changes": basetypes.ListType{ - ElemType: catalog_tf.PermissionsChange{}.ToAttrType(ctx), + ElemType: catalog_tf.PermissionsChange{}.ToObjectType(ctx), }, "max_results": types.Int64Type, "name": types.StringType, diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 53bee6a24f..e35cc362fd 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -45,9 +45,9 @@ func (a AccessControl) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of AccessControl in the Terraform plugin framework type +// ToObjectType returns the representation of AccessControl in the Terraform plugin framework type // system. -func (a AccessControl) ToAttrType(ctx context.Context) types.ObjectType { +func (a AccessControl) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -122,13 +122,13 @@ func (a Alert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of Alert in the Terraform plugin framework type +// ToObjectType returns the representation of Alert in the Terraform plugin framework type // system. -func (a Alert) ToAttrType(ctx context.Context) types.ObjectType { +func (a Alert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToAttrType(ctx), + ElemType: AlertCondition{}.ToObjectType(ctx), }, "create_time": types.StringType, "custom_body": types.StringType, @@ -180,18 +180,18 @@ func (a AlertCondition) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of AlertCondition in the Terraform plugin framework type +// ToObjectType returns the representation of AlertCondition in the Terraform plugin framework type // system. -func (a AlertCondition) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertCondition) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "empty_result_state": types.StringType, "op": types.StringType, "operand": basetypes.ListType{ - ElemType: AlertConditionOperand{}.ToAttrType(ctx), + ElemType: AlertConditionOperand{}.ToObjectType(ctx), }, "threshold": basetypes.ListType{ - ElemType: AlertConditionThreshold{}.ToAttrType(ctx), + ElemType: AlertConditionThreshold{}.ToObjectType(ctx), }, }, } @@ -220,13 +220,13 @@ func (a AlertConditionOperand) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToAttrType returns the representation of AlertConditionOperand in the Terraform plugin framework type +// ToObjectType returns the representation of AlertConditionOperand in the Terraform plugin framework type // system. -func (a AlertConditionOperand) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertConditionOperand) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column": basetypes.ListType{ - ElemType: AlertOperandColumn{}.ToAttrType(ctx), + ElemType: AlertOperandColumn{}.ToObjectType(ctx), }, }, } @@ -255,13 +255,13 @@ func (a AlertConditionThreshold) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of AlertConditionThreshold in the Terraform plugin framework type +// ToObjectType returns the representation of AlertConditionThreshold in the Terraform plugin framework type // system. -func (a AlertConditionThreshold) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertConditionThreshold) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": basetypes.ListType{ - ElemType: AlertOperandValue{}.ToAttrType(ctx), + ElemType: AlertOperandValue{}.ToObjectType(ctx), }, }, } @@ -288,9 +288,9 @@ func (a AlertOperandColumn) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of AlertOperandColumn in the Terraform plugin framework type +// ToObjectType returns the representation of AlertOperandColumn in the Terraform plugin framework type // system. -func (a AlertOperandColumn) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertOperandColumn) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -323,9 +323,9 @@ func (a AlertOperandValue) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of AlertOperandValue in the Terraform plugin framework type +// ToObjectType returns the representation of AlertOperandValue in the Terraform plugin framework type // system. -func (a AlertOperandValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertOperandValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bool_value": types.BoolType, @@ -380,9 +380,9 @@ func (a AlertOptions) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of AlertOptions in the Terraform plugin framework type +// ToObjectType returns the representation of AlertOptions in the Terraform plugin framework type // system. -func (a AlertOptions) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertOptions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column": types.StringType, @@ -458,9 +458,9 @@ func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of AlertQuery in the Terraform plugin framework type +// ToObjectType returns the representation of AlertQuery in the Terraform plugin framework type // system. -func (a AlertQuery) ToAttrType(ctx context.Context) types.ObjectType { +func (a AlertQuery) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -472,7 +472,7 @@ func (a AlertQuery) ToAttrType(ctx context.Context) types.ObjectType { "is_safe": types.BoolType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: QueryOptions{}.ToAttrType(ctx), + ElemType: QueryOptions{}.ToObjectType(ctx), }, "query": types.StringType, "tags": basetypes.ListType{ @@ -516,9 +516,9 @@ func (a BaseChunkInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of BaseChunkInfo in the Terraform plugin framework type +// ToObjectType returns the representation of BaseChunkInfo in the Terraform plugin framework type // system. -func (a BaseChunkInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a BaseChunkInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_count": types.Int64Type, @@ -553,9 +553,9 @@ func (a CancelExecutionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelExecutionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CancelExecutionRequest in the Terraform plugin framework type // system. -func (a CancelExecutionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelExecutionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statement_id": types.StringType, @@ -583,9 +583,9 @@ func (a CancelExecutionResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of CancelExecutionResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CancelExecutionResponse in the Terraform plugin framework type // system. -func (a CancelExecutionResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CancelExecutionResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -616,9 +616,9 @@ func (a Channel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of Channel in the Terraform plugin framework type +// ToObjectType returns the representation of Channel in the Terraform plugin framework type // system. -func (a Channel) ToAttrType(ctx context.Context) types.ObjectType { +func (a Channel) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbsql_version": types.StringType, @@ -652,9 +652,9 @@ func (a ChannelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of ChannelInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ChannelInfo in the Terraform plugin framework type // system. -func (a ChannelInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ChannelInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbsql_version": types.StringType, @@ -700,9 +700,9 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of ColumnInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ColumnInfo in the Terraform plugin framework type // system. -func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ColumnInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -750,14 +750,14 @@ func (a CreateAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of CreateAlert in the Terraform plugin framework type +// ToObjectType returns the representation of CreateAlert in the Terraform plugin framework type // system. -func (a CreateAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "options": basetypes.ListType{ - ElemType: AlertOptions{}.ToAttrType(ctx), + ElemType: AlertOptions{}.ToObjectType(ctx), }, "parent": types.StringType, "query_id": types.StringType, @@ -789,13 +789,13 @@ func (a CreateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateAlertRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateAlertRequest in the Terraform plugin framework type // system. -func (a CreateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert": basetypes.ListType{ - ElemType: CreateAlertRequestAlert{}.ToAttrType(ctx), + ElemType: CreateAlertRequestAlert{}.ToObjectType(ctx), }, }, } @@ -848,13 +848,13 @@ func (a CreateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of CreateAlertRequestAlert in the Terraform plugin framework type +// ToObjectType returns the representation of CreateAlertRequestAlert in the Terraform plugin framework type // system. -func (a CreateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateAlertRequestAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToAttrType(ctx), + ElemType: AlertCondition{}.ToObjectType(ctx), }, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -890,13 +890,13 @@ func (a CreateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateQueryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateQueryRequest in the Terraform plugin framework type // system. -func (a CreateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query": basetypes.ListType{ - ElemType: CreateQueryRequestQuery{}.ToAttrType(ctx), + ElemType: CreateQueryRequestQuery{}.ToObjectType(ctx), }, }, } @@ -949,9 +949,9 @@ func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of CreateQueryRequestQuery in the Terraform plugin framework type +// ToObjectType returns the representation of CreateQueryRequestQuery in the Terraform plugin framework type // system. -func (a CreateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateQueryRequestQuery) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -959,7 +959,7 @@ func (a CreateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectTyp "description": types.StringType, "display_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToAttrType(ctx), + ElemType: QueryParameter{}.ToObjectType(ctx), }, "parent_path": types.StringType, "query_text": types.StringType, @@ -1008,9 +1008,9 @@ func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateQueryVisualizationsLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateQueryVisualizationsLegacyRequest in the Terraform plugin framework type // system. -func (a CreateQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateQueryVisualizationsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1045,13 +1045,13 @@ func (a CreateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of CreateVisualizationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateVisualizationRequest in the Terraform plugin framework type // system. -func (a CreateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateVisualizationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "visualization": basetypes.ListType{ - ElemType: CreateVisualizationRequestVisualization{}.ToAttrType(ctx), + ElemType: CreateVisualizationRequestVisualization{}.ToObjectType(ctx), }, }, } @@ -1091,9 +1091,9 @@ func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateVisualizationRequestVisualization in the Terraform plugin framework type +// ToObjectType returns the representation of CreateVisualizationRequestVisualization in the Terraform plugin framework type // system. -func (a CreateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateVisualizationRequestVisualization) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -1189,14 +1189,14 @@ func (a CreateWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of CreateWarehouseRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateWarehouseRequest in the Terraform plugin framework type // system. -func (a CreateWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToAttrType(ctx), + ElemType: Channel{}.ToObjectType(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, @@ -1208,7 +1208,7 @@ func (a CreateWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType "name": types.StringType, "spot_instance_policy": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToAttrType(ctx), + ElemType: EndpointTags{}.ToObjectType(ctx), }, "warehouse_type": types.StringType, }, @@ -1237,9 +1237,9 @@ func (a CreateWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateWarehouseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateWarehouseResponse in the Terraform plugin framework type // system. -func (a CreateWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1283,15 +1283,15 @@ func (a CreateWidget) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of CreateWidget in the Terraform plugin framework type +// ToObjectType returns the representation of CreateWidget in the Terraform plugin framework type // system. -func (a CreateWidget) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateWidget) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "id": types.StringType, "options": basetypes.ListType{ - ElemType: WidgetOptions{}.ToAttrType(ctx), + ElemType: WidgetOptions{}.ToObjectType(ctx), }, "text": types.StringType, "visualization_id": types.StringType, @@ -1371,9 +1371,9 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of Dashboard in the Terraform plugin framework type +// ToObjectType returns the representation of Dashboard in the Terraform plugin framework type // system. -func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { +func (a Dashboard) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "can_edit": types.BoolType, @@ -1385,7 +1385,7 @@ func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { "is_favorite": types.BoolType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: DashboardOptions{}.ToAttrType(ctx), + ElemType: DashboardOptions{}.ToObjectType(ctx), }, "parent": types.StringType, "permission_tier": types.StringType, @@ -1395,11 +1395,11 @@ func (a Dashboard) ToAttrType(ctx context.Context) types.ObjectType { }, "updated_at": types.StringType, "user": basetypes.ListType{ - ElemType: User{}.ToAttrType(ctx), + ElemType: User{}.ToObjectType(ctx), }, "user_id": types.Int64Type, "widgets": basetypes.ListType{ - ElemType: Widget{}.ToAttrType(ctx), + ElemType: Widget{}.ToObjectType(ctx), }, }, } @@ -1437,9 +1437,9 @@ func (a DashboardEditContent) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of DashboardEditContent in the Terraform plugin framework type +// ToObjectType returns the representation of DashboardEditContent in the Terraform plugin framework type // system. -func (a DashboardEditContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a DashboardEditContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1476,9 +1476,9 @@ func (a DashboardOptions) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of DashboardOptions in the Terraform plugin framework type +// ToObjectType returns the representation of DashboardOptions in the Terraform plugin framework type // system. -func (a DashboardOptions) ToAttrType(ctx context.Context) types.ObjectType { +func (a DashboardOptions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "moved_to_trash_at": types.StringType, @@ -1524,9 +1524,9 @@ func (a DashboardPostContent) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of DashboardPostContent in the Terraform plugin framework type +// ToObjectType returns the representation of DashboardPostContent in the Terraform plugin framework type // system. -func (a DashboardPostContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a DashboardPostContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_filters_enabled": types.BoolType, @@ -1586,9 +1586,9 @@ func (a DataSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of DataSource in the Terraform plugin framework type +// ToObjectType returns the representation of DataSource in the Terraform plugin framework type // system. -func (a DataSource) ToAttrType(ctx context.Context) types.ObjectType { +func (a DataSource) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1627,9 +1627,9 @@ func (a DateRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DateRange in the Terraform plugin framework type +// ToObjectType returns the representation of DateRange in the Terraform plugin framework type // system. -func (a DateRange) ToAttrType(ctx context.Context) types.ObjectType { +func (a DateRange) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end": types.StringType, @@ -1669,13 +1669,13 @@ func (a DateRangeValue) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of DateRangeValue in the Terraform plugin framework type +// ToObjectType returns the representation of DateRangeValue in the Terraform plugin framework type // system. -func (a DateRangeValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a DateRangeValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "date_range_value": basetypes.ListType{ - ElemType: DateRange{}.ToAttrType(ctx), + ElemType: DateRange{}.ToObjectType(ctx), }, "dynamic_date_range_value": types.StringType, "precision": types.StringType, @@ -1711,9 +1711,9 @@ func (a DateValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DateValue in the Terraform plugin framework type +// ToObjectType returns the representation of DateValue in the Terraform plugin framework type // system. -func (a DateValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a DateValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "date_value": types.StringType, @@ -1745,9 +1745,9 @@ func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAlertsLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAlertsLegacyRequest in the Terraform plugin framework type // system. -func (a DeleteAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAlertsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, @@ -1777,9 +1777,9 @@ func (a DeleteDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDashboardRequest in the Terraform plugin framework type // system. -func (a DeleteDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1810,9 +1810,9 @@ func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteDashboardWidgetRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDashboardWidgetRequest in the Terraform plugin framework type // system. -func (a DeleteDashboardWidgetRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDashboardWidgetRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1842,9 +1842,9 @@ func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteQueriesLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteQueriesLegacyRequest in the Terraform plugin framework type // system. -func (a DeleteQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -1875,9 +1875,9 @@ func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteQueryVisualizationsLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteQueryVisualizationsLegacyRequest in the Terraform plugin framework type // system. -func (a DeleteQueryVisualizationsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteQueryVisualizationsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1905,9 +1905,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1935,9 +1935,9 @@ func (a DeleteVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteVisualizationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteVisualizationRequest in the Terraform plugin framework type // system. -func (a DeleteVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteVisualizationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1968,9 +1968,9 @@ func (a DeleteWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWarehouseRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWarehouseRequest in the Terraform plugin framework type // system. -func (a DeleteWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1998,9 +1998,9 @@ func (a DeleteWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteWarehouseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteWarehouseResponse in the Terraform plugin framework type // system. -func (a DeleteWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2039,15 +2039,15 @@ func (a EditAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of EditAlert in the Terraform plugin framework type +// ToObjectType returns the representation of EditAlert in the Terraform plugin framework type // system. -func (a EditAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: AlertOptions{}.ToAttrType(ctx), + ElemType: AlertOptions{}.ToObjectType(ctx), }, "query_id": types.StringType, "rearm": types.Int64Type, @@ -2139,14 +2139,14 @@ func (a EditWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of EditWarehouseRequest in the Terraform plugin framework type +// ToObjectType returns the representation of EditWarehouseRequest in the Terraform plugin framework type // system. -func (a EditWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToAttrType(ctx), + ElemType: Channel{}.ToObjectType(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, @@ -2159,7 +2159,7 @@ func (a EditWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { "name": types.StringType, "spot_instance_policy": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToAttrType(ctx), + ElemType: EndpointTags{}.ToObjectType(ctx), }, "warehouse_type": types.StringType, }, @@ -2186,9 +2186,9 @@ func (a EditWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of EditWarehouseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of EditWarehouseResponse in the Terraform plugin framework type // system. -func (a EditWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a EditWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2216,9 +2216,9 @@ func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of Empty in the Terraform plugin framework type +// ToObjectType returns the representation of Empty in the Terraform plugin framework type // system. -func (a Empty) ToAttrType(ctx context.Context) types.ObjectType { +func (a Empty) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2247,9 +2247,9 @@ func (a EndpointConfPair) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of EndpointConfPair in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointConfPair in the Terraform plugin framework type // system. -func (a EndpointConfPair) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointConfPair) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2292,14 +2292,14 @@ func (a EndpointHealth) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of EndpointHealth in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointHealth in the Terraform plugin framework type // system. -func (a EndpointHealth) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointHealth) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "details": types.StringType, "failure_reason": basetypes.ListType{ - ElemType: TerminationReason{}.ToAttrType(ctx), + ElemType: TerminationReason{}.ToObjectType(ctx), }, "message": types.StringType, "status": types.StringType, @@ -2407,21 +2407,21 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of EndpointInfo in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointInfo in the Terraform plugin framework type // system. -func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToAttrType(ctx), + ElemType: Channel{}.ToObjectType(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, "health": basetypes.ListType{ - ElemType: EndpointHealth{}.ToAttrType(ctx), + ElemType: EndpointHealth{}.ToObjectType(ctx), }, "id": types.StringType, "instance_profile_arn": types.StringType, @@ -2432,12 +2432,12 @@ func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { "num_active_sessions": types.Int64Type, "num_clusters": types.Int64Type, "odbc_params": basetypes.ListType{ - ElemType: OdbcParams{}.ToAttrType(ctx), + ElemType: OdbcParams{}.ToObjectType(ctx), }, "spot_instance_policy": types.StringType, "state": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToAttrType(ctx), + ElemType: EndpointTags{}.ToObjectType(ctx), }, "warehouse_type": types.StringType, }, @@ -2467,9 +2467,9 @@ func (a EndpointTagPair) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of EndpointTagPair in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointTagPair in the Terraform plugin framework type // system. -func (a EndpointTagPair) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointTagPair) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2501,13 +2501,13 @@ func (a EndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of EndpointTags in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointTags in the Terraform plugin framework type // system. -func (a EndpointTags) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointTags) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "custom_tags": basetypes.ListType{ - ElemType: EndpointTagPair{}.ToAttrType(ctx), + ElemType: EndpointTagPair{}.ToObjectType(ctx), }, }, } @@ -2542,14 +2542,14 @@ func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of EnumValue in the Terraform plugin framework type +// ToObjectType returns the representation of EnumValue in the Terraform plugin framework type // system. -func (a EnumValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a EnumValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enum_options": types.StringType, "multi_values_options": basetypes.ListType{ - ElemType: MultiValuesOptions{}.ToAttrType(ctx), + ElemType: MultiValuesOptions{}.ToObjectType(ctx), }, "values": basetypes.ListType{ ElemType: types.StringType, @@ -2703,9 +2703,9 @@ func (a ExecuteStatementRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ExecuteStatementRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExecuteStatementRequest in the Terraform plugin framework type // system. -func (a ExecuteStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExecuteStatementRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_limit": types.Int64Type, @@ -2714,7 +2714,7 @@ func (a ExecuteStatementRequest) ToAttrType(ctx context.Context) types.ObjectTyp "format": types.StringType, "on_wait_timeout": types.StringType, "parameters": basetypes.ListType{ - ElemType: StatementParameterListItem{}.ToAttrType(ctx), + ElemType: StatementParameterListItem{}.ToObjectType(ctx), }, "row_limit": types.Int64Type, "schema": types.StringType, @@ -2777,9 +2777,9 @@ func (a ExternalLink) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ExternalLink in the Terraform plugin framework type +// ToObjectType returns the representation of ExternalLink in the Terraform plugin framework type // system. -func (a ExternalLink) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExternalLink) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_count": types.Int64Type, @@ -2819,9 +2819,9 @@ func (a GetAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAlertRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAlertRequest in the Terraform plugin framework type // system. -func (a GetAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -2851,9 +2851,9 @@ func (a GetAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAlertsLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAlertsLegacyRequest in the Terraform plugin framework type // system. -func (a GetAlertsLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAlertsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, @@ -2883,9 +2883,9 @@ func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDashboardRequest in the Terraform plugin framework type // system. -func (a GetDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -2918,9 +2918,9 @@ func (a GetDbsqlPermissionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetDbsqlPermissionRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetDbsqlPermissionRequest in the Terraform plugin framework type // system. -func (a GetDbsqlPermissionRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetDbsqlPermissionRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "objectId": types.StringType, @@ -2951,9 +2951,9 @@ func (a GetQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetQueriesLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetQueriesLegacyRequest in the Terraform plugin framework type // system. -func (a GetQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -2983,9 +2983,9 @@ func (a GetQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetQueryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetQueryRequest in the Terraform plugin framework type // system. -func (a GetQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3020,13 +3020,13 @@ func (a GetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of GetResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetResponse in the Terraform plugin framework type // system. -func (a GetResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.ToAttrType(ctx), + ElemType: AccessControl{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -3058,9 +3058,9 @@ func (a GetStatementRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStatementRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStatementRequest in the Terraform plugin framework type // system. -func (a GetStatementRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStatementRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statement_id": types.StringType, @@ -3093,9 +3093,9 @@ func (a GetStatementResultChunkNRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStatementResultChunkNRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStatementResultChunkNRequest in the Terraform plugin framework type // system. -func (a GetStatementResultChunkNRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStatementResultChunkNRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "chunk_index": types.Int64Type, @@ -3127,9 +3127,9 @@ func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWarehousePermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWarehousePermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetWarehousePermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWarehousePermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, @@ -3161,13 +3161,13 @@ func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of GetWarehousePermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetWarehousePermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetWarehousePermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWarehousePermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: WarehousePermissionsDescription{}.ToAttrType(ctx), + ElemType: WarehousePermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -3196,9 +3196,9 @@ func (a GetWarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWarehousePermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWarehousePermissionsRequest in the Terraform plugin framework type // system. -func (a GetWarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWarehousePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, @@ -3229,9 +3229,9 @@ func (a GetWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWarehouseRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWarehouseRequest in the Terraform plugin framework type // system. -func (a GetWarehouseRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3338,21 +3338,21 @@ func (a GetWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of GetWarehouseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetWarehouseResponse in the Terraform plugin framework type // system. -func (a GetWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToAttrType(ctx), + ElemType: Channel{}.ToObjectType(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, "health": basetypes.ListType{ - ElemType: EndpointHealth{}.ToAttrType(ctx), + ElemType: EndpointHealth{}.ToObjectType(ctx), }, "id": types.StringType, "instance_profile_arn": types.StringType, @@ -3363,12 +3363,12 @@ func (a GetWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { "num_active_sessions": types.Int64Type, "num_clusters": types.Int64Type, "odbc_params": basetypes.ListType{ - ElemType: OdbcParams{}.ToAttrType(ctx), + ElemType: OdbcParams{}.ToObjectType(ctx), }, "spot_instance_policy": types.StringType, "state": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToAttrType(ctx), + ElemType: EndpointTags{}.ToObjectType(ctx), }, "warehouse_type": types.StringType, }, @@ -3427,31 +3427,31 @@ func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co } } -// ToAttrType returns the representation of GetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type // system. -func (a GetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceWarehouseConfigResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ - ElemType: Channel{}.ToAttrType(ctx), + ElemType: Channel{}.ToObjectType(ctx), }, "config_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), }, "data_access_config": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToAttrType(ctx), + ElemType: EndpointConfPair{}.ToObjectType(ctx), }, "enabled_warehouse_types": basetypes.ListType{ - ElemType: WarehouseTypePair{}.ToAttrType(ctx), + ElemType: WarehouseTypePair{}.ToObjectType(ctx), }, "global_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), }, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, "security_policy": types.StringType, "sql_configuration_parameters": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), }, }, } @@ -3507,9 +3507,9 @@ func (a LegacyAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of LegacyAlert in the Terraform plugin framework type +// ToObjectType returns the representation of LegacyAlert in the Terraform plugin framework type // system. -func (a LegacyAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a LegacyAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -3517,17 +3517,17 @@ func (a LegacyAlert) ToAttrType(ctx context.Context) types.ObjectType { "last_triggered_at": types.StringType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: AlertOptions{}.ToAttrType(ctx), + ElemType: AlertOptions{}.ToObjectType(ctx), }, "parent": types.StringType, "query": basetypes.ListType{ - ElemType: AlertQuery{}.ToAttrType(ctx), + ElemType: AlertQuery{}.ToObjectType(ctx), }, "rearm": types.Int64Type, "state": types.StringType, "updated_at": types.StringType, "user": basetypes.ListType{ - ElemType: User{}.ToAttrType(ctx), + ElemType: User{}.ToObjectType(ctx), }, }, } @@ -3627,9 +3627,9 @@ func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of LegacyQuery in the Terraform plugin framework type +// ToObjectType returns the representation of LegacyQuery in the Terraform plugin framework type // system. -func (a LegacyQuery) ToAttrType(ctx context.Context) types.ObjectType { +func (a LegacyQuery) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "can_edit": types.BoolType, @@ -3642,13 +3642,13 @@ func (a LegacyQuery) ToAttrType(ctx context.Context) types.ObjectType { "is_favorite": types.BoolType, "is_safe": types.BoolType, "last_modified_by": basetypes.ListType{ - ElemType: User{}.ToAttrType(ctx), + ElemType: User{}.ToObjectType(ctx), }, "last_modified_by_id": types.Int64Type, "latest_query_data_id": types.StringType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: QueryOptions{}.ToAttrType(ctx), + ElemType: QueryOptions{}.ToObjectType(ctx), }, "parent": types.StringType, "permission_tier": types.StringType, @@ -3660,11 +3660,11 @@ func (a LegacyQuery) ToAttrType(ctx context.Context) types.ObjectType { }, "updated_at": types.StringType, "user": basetypes.ListType{ - ElemType: User{}.ToAttrType(ctx), + ElemType: User{}.ToObjectType(ctx), }, "user_id": types.Int64Type, "visualizations": basetypes.ListType{ - ElemType: LegacyVisualization{}.ToAttrType(ctx), + ElemType: LegacyVisualization{}.ToObjectType(ctx), }, }, } @@ -3716,9 +3716,9 @@ func (a LegacyVisualization) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of LegacyVisualization in the Terraform plugin framework type +// ToObjectType returns the representation of LegacyVisualization in the Terraform plugin framework type // system. -func (a LegacyVisualization) ToAttrType(ctx context.Context) types.ObjectType { +func (a LegacyVisualization) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -3727,7 +3727,7 @@ func (a LegacyVisualization) ToAttrType(ctx context.Context) types.ObjectType { "name": types.StringType, "options": types.ObjectType{}, "query": basetypes.ListType{ - ElemType: LegacyQuery{}.ToAttrType(ctx), + ElemType: LegacyQuery{}.ToObjectType(ctx), }, "type": types.StringType, "updated_at": types.StringType, @@ -3759,9 +3759,9 @@ func (a ListAlertsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAlertsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAlertsRequest in the Terraform plugin framework type // system. -func (a ListAlertsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAlertsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -3795,14 +3795,14 @@ func (a ListAlertsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListAlertsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAlertsResponse in the Terraform plugin framework type // system. -func (a ListAlertsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAlertsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: ListAlertsResponseAlert{}.ToAttrType(ctx), + ElemType: ListAlertsResponseAlert{}.ToObjectType(ctx), }, }, } @@ -3871,13 +3871,13 @@ func (a ListAlertsResponseAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ListAlertsResponseAlert in the Terraform plugin framework type +// ToObjectType returns the representation of ListAlertsResponseAlert in the Terraform plugin framework type // system. -func (a ListAlertsResponseAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAlertsResponseAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToAttrType(ctx), + ElemType: AlertCondition{}.ToObjectType(ctx), }, "create_time": types.StringType, "custom_body": types.StringType, @@ -3925,9 +3925,9 @@ func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListDashboardsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListDashboardsRequest in the Terraform plugin framework type // system. -func (a ListDashboardsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListDashboardsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "order": types.StringType, @@ -3980,9 +3980,9 @@ func (a ListQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListQueriesLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListQueriesLegacyRequest in the Terraform plugin framework type // system. -func (a ListQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "order": types.StringType, @@ -4017,9 +4017,9 @@ func (a ListQueriesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListQueriesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListQueriesRequest in the Terraform plugin framework type // system. -func (a ListQueriesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQueriesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -4056,15 +4056,15 @@ func (a ListQueriesResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListQueriesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListQueriesResponse in the Terraform plugin framework type // system. -func (a ListQueriesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQueriesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_next_page": types.BoolType, "next_page_token": types.StringType, "res": basetypes.ListType{ - ElemType: QueryInfo{}.ToAttrType(ctx), + ElemType: QueryInfo{}.ToObjectType(ctx), }, }, } @@ -4106,13 +4106,13 @@ func (a ListQueryHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ListQueryHistoryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListQueryHistoryRequest in the Terraform plugin framework type // system. -func (a ListQueryHistoryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQueryHistoryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter_by": basetypes.ListType{ - ElemType: QueryFilter{}.ToAttrType(ctx), + ElemType: QueryFilter{}.ToObjectType(ctx), }, "include_metrics": types.BoolType, "max_results": types.Int64Type, @@ -4146,14 +4146,14 @@ func (a ListQueryObjectsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of ListQueryObjectsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListQueryObjectsResponse in the Terraform plugin framework type // system. -func (a ListQueryObjectsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQueryObjectsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: ListQueryObjectsResponseQuery{}.ToAttrType(ctx), + ElemType: ListQueryObjectsResponseQuery{}.ToObjectType(ctx), }, }, } @@ -4216,9 +4216,9 @@ func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of ListQueryObjectsResponseQuery in the Terraform plugin framework type +// ToObjectType returns the representation of ListQueryObjectsResponseQuery in the Terraform plugin framework type // system. -func (a ListQueryObjectsResponseQuery) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListQueryObjectsResponseQuery) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -4231,7 +4231,7 @@ func (a ListQueryObjectsResponseQuery) ToAttrType(ctx context.Context) types.Obj "lifecycle_state": types.StringType, "owner_user_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToAttrType(ctx), + ElemType: QueryParameter{}.ToObjectType(ctx), }, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -4275,16 +4275,16 @@ func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListResponse in the Terraform plugin framework type // system. -func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, "results": basetypes.ListType{ - ElemType: Dashboard{}.ToAttrType(ctx), + ElemType: Dashboard{}.ToObjectType(ctx), }, }, } @@ -4316,9 +4316,9 @@ func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListVisualizationsForQueryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListVisualizationsForQueryRequest in the Terraform plugin framework type // system. -func (a ListVisualizationsForQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListVisualizationsForQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -4353,14 +4353,14 @@ func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of ListVisualizationsForQueryResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListVisualizationsForQueryResponse in the Terraform plugin framework type // system. -func (a ListVisualizationsForQueryResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListVisualizationsForQueryResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: Visualization{}.ToAttrType(ctx), + ElemType: Visualization{}.ToObjectType(ctx), }, }, } @@ -4390,9 +4390,9 @@ func (a ListWarehousesRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListWarehousesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListWarehousesRequest in the Terraform plugin framework type // system. -func (a ListWarehousesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListWarehousesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_as_user_id": types.Int64Type, @@ -4424,13 +4424,13 @@ func (a ListWarehousesResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of ListWarehousesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListWarehousesResponse in the Terraform plugin framework type // system. -func (a ListWarehousesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListWarehousesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouses": basetypes.ListType{ - ElemType: EndpointInfo{}.ToAttrType(ctx), + ElemType: EndpointInfo{}.ToObjectType(ctx), }, }, } @@ -4463,9 +4463,9 @@ func (a MultiValuesOptions) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of MultiValuesOptions in the Terraform plugin framework type +// ToObjectType returns the representation of MultiValuesOptions in the Terraform plugin framework type // system. -func (a MultiValuesOptions) ToAttrType(ctx context.Context) types.ObjectType { +func (a MultiValuesOptions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "prefix": types.StringType, @@ -4496,9 +4496,9 @@ func (a NumericValue) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of NumericValue in the Terraform plugin framework type +// ToObjectType returns the representation of NumericValue in the Terraform plugin framework type // system. -func (a NumericValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a NumericValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.Float64Type, @@ -4533,9 +4533,9 @@ func (a OdbcParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of OdbcParams in the Terraform plugin framework type +// ToObjectType returns the representation of OdbcParams in the Terraform plugin framework type // system. -func (a OdbcParams) ToAttrType(ctx context.Context) types.ObjectType { +func (a OdbcParams) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "hostname": types.StringType, @@ -4586,14 +4586,14 @@ func (a Parameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of Parameter in the Terraform plugin framework type +// ToObjectType returns the representation of Parameter in the Terraform plugin framework type // system. -func (a Parameter) ToAttrType(ctx context.Context) types.ObjectType { +func (a Parameter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enumOptions": types.StringType, "multiValuesOptions": basetypes.ListType{ - ElemType: MultiValuesOptions{}.ToAttrType(ctx), + ElemType: MultiValuesOptions{}.ToObjectType(ctx), }, "name": types.StringType, "queryId": types.StringType, @@ -4663,9 +4663,9 @@ func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of Query in the Terraform plugin framework type +// ToObjectType returns the representation of Query in the Terraform plugin framework type // system. -func (a Query) ToAttrType(ctx context.Context) types.ObjectType { +func (a Query) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -4678,7 +4678,7 @@ func (a Query) ToAttrType(ctx context.Context) types.ObjectType { "lifecycle_state": types.StringType, "owner_user_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToAttrType(ctx), + ElemType: QueryParameter{}.ToObjectType(ctx), }, "parent_path": types.StringType, "query_text": types.StringType, @@ -4722,13 +4722,13 @@ func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of QueryBackedValue in the Terraform plugin framework type +// ToObjectType returns the representation of QueryBackedValue in the Terraform plugin framework type // system. -func (a QueryBackedValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryBackedValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "multi_values_options": basetypes.ListType{ - ElemType: MultiValuesOptions{}.ToAttrType(ctx), + ElemType: MultiValuesOptions{}.ToObjectType(ctx), }, "query_id": types.StringType, "values": basetypes.ListType{ @@ -4785,9 +4785,9 @@ func (a QueryEditContent) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of QueryEditContent in the Terraform plugin framework type +// ToObjectType returns the representation of QueryEditContent in the Terraform plugin framework type // system. -func (a QueryEditContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryEditContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_source_id": types.StringType, @@ -4841,13 +4841,13 @@ func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of QueryFilter in the Terraform plugin framework type +// ToObjectType returns the representation of QueryFilter in the Terraform plugin framework type // system. -func (a QueryFilter) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryFilter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_start_time_range": basetypes.ListType{ - ElemType: TimeRange{}.ToAttrType(ctx), + ElemType: TimeRange{}.ToObjectType(ctx), }, "statement_ids": basetypes.ListType{ ElemType: types.StringType, @@ -4937,13 +4937,13 @@ func (a QueryInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of QueryInfo in the Terraform plugin framework type +// ToObjectType returns the representation of QueryInfo in the Terraform plugin framework type // system. -func (a QueryInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "channel_used": basetypes.ListType{ - ElemType: ChannelInfo{}.ToAttrType(ctx), + ElemType: ChannelInfo{}.ToObjectType(ctx), }, "duration": types.Int64Type, "endpoint_id": types.StringType, @@ -4954,7 +4954,7 @@ func (a QueryInfo) ToAttrType(ctx context.Context) types.ObjectType { "is_final": types.BoolType, "lookup_key": types.StringType, "metrics": basetypes.ListType{ - ElemType: QueryMetrics{}.ToAttrType(ctx), + ElemType: QueryMetrics{}.ToObjectType(ctx), }, "plans_state": types.StringType, "query_end_time_ms": types.Int64Type, @@ -5002,16 +5002,16 @@ func (a QueryList) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of QueryList in the Terraform plugin framework type +// ToObjectType returns the representation of QueryList in the Terraform plugin framework type // system. -func (a QueryList) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryList) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, "results": basetypes.ListType{ - ElemType: LegacyQuery{}.ToAttrType(ctx), + ElemType: LegacyQuery{}.ToObjectType(ctx), }, }, } @@ -5095,9 +5095,9 @@ func (a QueryMetrics) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of QueryMetrics in the Terraform plugin framework type +// ToObjectType returns the representation of QueryMetrics in the Terraform plugin framework type // system. -func (a QueryMetrics) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryMetrics) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compilation_time_ms": types.Int64Type, @@ -5158,15 +5158,15 @@ func (a QueryOptions) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of QueryOptions in the Terraform plugin framework type +// ToObjectType returns the representation of QueryOptions in the Terraform plugin framework type // system. -func (a QueryOptions) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryOptions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog": types.StringType, "moved_to_trash_at": types.StringType, "parameters": basetypes.ListType{ - ElemType: Parameter{}.ToAttrType(ctx), + ElemType: Parameter{}.ToObjectType(ctx), }, "schema": types.StringType, }, @@ -5219,29 +5219,29 @@ func (a QueryParameter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of QueryParameter in the Terraform plugin framework type +// ToObjectType returns the representation of QueryParameter in the Terraform plugin framework type // system. -func (a QueryParameter) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryParameter) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "date_range_value": basetypes.ListType{ - ElemType: DateRangeValue{}.ToAttrType(ctx), + ElemType: DateRangeValue{}.ToObjectType(ctx), }, "date_value": basetypes.ListType{ - ElemType: DateValue{}.ToAttrType(ctx), + ElemType: DateValue{}.ToObjectType(ctx), }, "enum_value": basetypes.ListType{ - ElemType: EnumValue{}.ToAttrType(ctx), + ElemType: EnumValue{}.ToObjectType(ctx), }, "name": types.StringType, "numeric_value": basetypes.ListType{ - ElemType: NumericValue{}.ToAttrType(ctx), + ElemType: NumericValue{}.ToObjectType(ctx), }, "query_backed_value": basetypes.ListType{ - ElemType: QueryBackedValue{}.ToAttrType(ctx), + ElemType: QueryBackedValue{}.ToObjectType(ctx), }, "text_value": basetypes.ListType{ - ElemType: TextValue{}.ToAttrType(ctx), + ElemType: TextValue{}.ToObjectType(ctx), }, "title": types.StringType, }, @@ -5295,9 +5295,9 @@ func (a QueryPostContent) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of QueryPostContent in the Terraform plugin framework type +// ToObjectType returns the representation of QueryPostContent in the Terraform plugin framework type // system. -func (a QueryPostContent) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryPostContent) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_source_id": types.StringType, @@ -5341,16 +5341,16 @@ func (a RepeatedEndpointConfPairs) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of RepeatedEndpointConfPairs in the Terraform plugin framework type +// ToObjectType returns the representation of RepeatedEndpointConfPairs in the Terraform plugin framework type // system. -func (a RepeatedEndpointConfPairs) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepeatedEndpointConfPairs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config_pair": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToAttrType(ctx), + ElemType: EndpointConfPair{}.ToObjectType(ctx), }, "configuration_pairs": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToAttrType(ctx), + ElemType: EndpointConfPair{}.ToObjectType(ctx), }, }, } @@ -5378,9 +5378,9 @@ func (a RestoreDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreDashboardRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreDashboardRequest in the Terraform plugin framework type // system. -func (a RestoreDashboardRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -5410,9 +5410,9 @@ func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreQueriesLegacyRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreQueriesLegacyRequest in the Terraform plugin framework type // system. -func (a RestoreQueriesLegacyRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -5440,9 +5440,9 @@ func (a RestoreResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of RestoreResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RestoreResponse in the Terraform plugin framework type // system. -func (a RestoreResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RestoreResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5495,9 +5495,9 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of ResultData in the Terraform plugin framework type +// ToObjectType returns the representation of ResultData in the Terraform plugin framework type // system. -func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResultData) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_count": types.Int64Type, @@ -5508,7 +5508,7 @@ func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { }, }, "external_links": basetypes.ListType{ - ElemType: ExternalLink{}.ToAttrType(ctx), + ElemType: ExternalLink{}.ToObjectType(ctx), }, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, @@ -5558,17 +5558,17 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ResultManifest in the Terraform plugin framework type +// ToObjectType returns the representation of ResultManifest in the Terraform plugin framework type // system. -func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResultManifest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "chunks": basetypes.ListType{ - ElemType: BaseChunkInfo{}.ToAttrType(ctx), + ElemType: BaseChunkInfo{}.ToObjectType(ctx), }, "format": types.StringType, "schema": basetypes.ListType{ - ElemType: ResultSchema{}.ToAttrType(ctx), + ElemType: ResultSchema{}.ToObjectType(ctx), }, "total_byte_count": types.Int64Type, "total_chunk_count": types.Int64Type, @@ -5604,14 +5604,14 @@ func (a ResultSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ResultSchema in the Terraform plugin framework type +// ToObjectType returns the representation of ResultSchema in the Terraform plugin framework type // system. -func (a ResultSchema) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResultSchema) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.ToAttrType(ctx), + ElemType: ColumnInfo{}.ToObjectType(ctx), }, }, } @@ -5640,9 +5640,9 @@ func (a ServiceError) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of ServiceError in the Terraform plugin framework type +// ToObjectType returns the representation of ServiceError in the Terraform plugin framework type // system. -func (a ServiceError) ToAttrType(ctx context.Context) types.ObjectType { +func (a ServiceError) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_code": types.StringType, @@ -5680,13 +5680,13 @@ func (a SetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of SetRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SetRequest in the Terraform plugin framework type // system. -func (a SetRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.ToAttrType(ctx), + ElemType: AccessControl{}.ToObjectType(ctx), }, "objectId": types.StringType, "objectType": types.StringType, @@ -5721,13 +5721,13 @@ func (a SetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of SetResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetResponse in the Terraform plugin framework type // system. -func (a SetResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.ToAttrType(ctx), + ElemType: AccessControl{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -5787,31 +5787,31 @@ func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes(ctx context.Con } } -// ToAttrType returns the representation of SetWorkspaceWarehouseConfigRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SetWorkspaceWarehouseConfigRequest in the Terraform plugin framework type // system. -func (a SetWorkspaceWarehouseConfigRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetWorkspaceWarehouseConfigRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ - ElemType: Channel{}.ToAttrType(ctx), + ElemType: Channel{}.ToObjectType(ctx), }, "config_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), }, "data_access_config": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToAttrType(ctx), + ElemType: EndpointConfPair{}.ToObjectType(ctx), }, "enabled_warehouse_types": basetypes.ListType{ - ElemType: WarehouseTypePair{}.ToAttrType(ctx), + ElemType: WarehouseTypePair{}.ToObjectType(ctx), }, "global_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), }, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, "security_policy": types.StringType, "sql_configuration_parameters": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToAttrType(ctx), + ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), }, }, } @@ -5837,9 +5837,9 @@ func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of SetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type // system. -func (a SetWorkspaceWarehouseConfigResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SetWorkspaceWarehouseConfigResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5868,9 +5868,9 @@ func (a StartRequest) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of StartRequest in the Terraform plugin framework type +// ToObjectType returns the representation of StartRequest in the Terraform plugin framework type // system. -func (a StartRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -5898,9 +5898,9 @@ func (a StartWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of StartWarehouseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of StartWarehouseResponse in the Terraform plugin framework type // system. -func (a StartWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a StartWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5939,9 +5939,9 @@ func (a StatementParameterListItem) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of StatementParameterListItem in the Terraform plugin framework type +// ToObjectType returns the representation of StatementParameterListItem in the Terraform plugin framework type // system. -func (a StatementParameterListItem) ToAttrType(ctx context.Context) types.ObjectType { +func (a StatementParameterListItem) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5985,20 +5985,20 @@ func (a StatementResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of StatementResponse in the Terraform plugin framework type +// ToObjectType returns the representation of StatementResponse in the Terraform plugin framework type // system. -func (a StatementResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a StatementResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "manifest": basetypes.ListType{ - ElemType: ResultManifest{}.ToAttrType(ctx), + ElemType: ResultManifest{}.ToObjectType(ctx), }, "result": basetypes.ListType{ - ElemType: ResultData{}.ToAttrType(ctx), + ElemType: ResultData{}.ToObjectType(ctx), }, "statement_id": types.StringType, "status": basetypes.ListType{ - ElemType: StatementStatus{}.ToAttrType(ctx), + ElemType: StatementStatus{}.ToObjectType(ctx), }, }, } @@ -6037,13 +6037,13 @@ func (a StatementStatus) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of StatementStatus in the Terraform plugin framework type +// ToObjectType returns the representation of StatementStatus in the Terraform plugin framework type // system. -func (a StatementStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a StatementStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": basetypes.ListType{ - ElemType: ServiceError{}.ToAttrType(ctx), + ElemType: ServiceError{}.ToObjectType(ctx), }, "state": types.StringType, }, @@ -6073,9 +6073,9 @@ func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of StopRequest in the Terraform plugin framework type +// ToObjectType returns the representation of StopRequest in the Terraform plugin framework type // system. -func (a StopRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a StopRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -6103,9 +6103,9 @@ func (a StopWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of StopWarehouseResponse in the Terraform plugin framework type +// ToObjectType returns the representation of StopWarehouseResponse in the Terraform plugin framework type // system. -func (a StopWarehouseResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a StopWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6132,9 +6132,9 @@ func (a Success) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of Success in the Terraform plugin framework type +// ToObjectType returns the representation of Success in the Terraform plugin framework type // system. -func (a Success) ToAttrType(ctx context.Context) types.ObjectType { +func (a Success) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -6171,9 +6171,9 @@ func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of TerminationReason in the Terraform plugin framework type +// ToObjectType returns the representation of TerminationReason in the Terraform plugin framework type // system. -func (a TerminationReason) ToAttrType(ctx context.Context) types.ObjectType { +func (a TerminationReason) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -6206,9 +6206,9 @@ func (a TextValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of TextValue in the Terraform plugin framework type +// ToObjectType returns the representation of TextValue in the Terraform plugin framework type // system. -func (a TextValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a TextValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.StringType, @@ -6240,9 +6240,9 @@ func (a TimeRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of TimeRange in the Terraform plugin framework type +// ToObjectType returns the representation of TimeRange in the Terraform plugin framework type // system. -func (a TimeRange) ToAttrType(ctx context.Context) types.ObjectType { +func (a TimeRange) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time_ms": types.Int64Type, @@ -6273,9 +6273,9 @@ func (a TransferOwnershipObjectId) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of TransferOwnershipObjectId in the Terraform plugin framework type +// ToObjectType returns the representation of TransferOwnershipObjectId in the Terraform plugin framework type // system. -func (a TransferOwnershipObjectId) ToAttrType(ctx context.Context) types.ObjectType { +func (a TransferOwnershipObjectId) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "new_owner": types.StringType, @@ -6312,14 +6312,14 @@ func (a TransferOwnershipRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of TransferOwnershipRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TransferOwnershipRequest in the Terraform plugin framework type // system. -func (a TransferOwnershipRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TransferOwnershipRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "new_owner": types.StringType, "objectId": basetypes.ListType{ - ElemType: TransferOwnershipObjectId{}.ToAttrType(ctx), + ElemType: TransferOwnershipObjectId{}.ToObjectType(ctx), }, "objectType": types.StringType, }, @@ -6348,9 +6348,9 @@ func (a TrashAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of TrashAlertRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TrashAlertRequest in the Terraform plugin framework type // system. -func (a TrashAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TrashAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -6380,9 +6380,9 @@ func (a TrashQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of TrashQueryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of TrashQueryRequest in the Terraform plugin framework type // system. -func (a TrashQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a TrashQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -6420,13 +6420,13 @@ func (a UpdateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of UpdateAlertRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAlertRequest in the Terraform plugin framework type // system. -func (a UpdateAlertRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert": basetypes.ListType{ - ElemType: UpdateAlertRequestAlert{}.ToAttrType(ctx), + ElemType: UpdateAlertRequestAlert{}.ToObjectType(ctx), }, "id": types.StringType, "update_mask": types.StringType, @@ -6482,13 +6482,13 @@ func (a UpdateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of UpdateAlertRequestAlert in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateAlertRequestAlert in the Terraform plugin framework type // system. -func (a UpdateAlertRequestAlert) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateAlertRequestAlert) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToAttrType(ctx), + ElemType: AlertCondition{}.ToObjectType(ctx), }, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -6531,14 +6531,14 @@ func (a UpdateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of UpdateQueryRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateQueryRequest in the Terraform plugin framework type // system. -func (a UpdateQueryRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "query": basetypes.ListType{ - ElemType: UpdateQueryRequestQuery{}.ToAttrType(ctx), + ElemType: UpdateQueryRequestQuery{}.ToObjectType(ctx), }, "update_mask": types.StringType, }, @@ -6592,9 +6592,9 @@ func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of UpdateQueryRequestQuery in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateQueryRequestQuery in the Terraform plugin framework type // system. -func (a UpdateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateQueryRequestQuery) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -6603,7 +6603,7 @@ func (a UpdateQueryRequestQuery) ToAttrType(ctx context.Context) types.ObjectTyp "display_name": types.StringType, "owner_user_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToAttrType(ctx), + ElemType: QueryParameter{}.ToObjectType(ctx), }, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -6636,9 +6636,9 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type // system. -func (a UpdateResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6674,15 +6674,15 @@ func (a UpdateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of UpdateVisualizationRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateVisualizationRequest in the Terraform plugin framework type // system. -func (a UpdateVisualizationRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateVisualizationRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "update_mask": types.StringType, "visualization": basetypes.ListType{ - ElemType: UpdateVisualizationRequestVisualization{}.ToAttrType(ctx), + ElemType: UpdateVisualizationRequestVisualization{}.ToObjectType(ctx), }, }, } @@ -6720,9 +6720,9 @@ func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateVisualizationRequestVisualization in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateVisualizationRequestVisualization in the Terraform plugin framework type // system. -func (a UpdateVisualizationRequestVisualization) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateVisualizationRequestVisualization) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -6758,9 +6758,9 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToAttrType returns the representation of User in the Terraform plugin framework type +// ToObjectType returns the representation of User in the Terraform plugin framework type // system. -func (a User) ToAttrType(ctx context.Context) types.ObjectType { +func (a User) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email": types.StringType, @@ -6810,9 +6810,9 @@ func (a Visualization) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of Visualization in the Terraform plugin framework type +// ToObjectType returns the representation of Visualization in the Terraform plugin framework type // system. -func (a Visualization) ToAttrType(ctx context.Context) types.ObjectType { +func (a Visualization) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -6855,9 +6855,9 @@ func (a WarehouseAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of WarehouseAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of WarehouseAccessControlRequest in the Terraform plugin framework type // system. -func (a WarehouseAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehouseAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -6900,13 +6900,13 @@ func (a WarehouseAccessControlResponse) GetComplexFieldTypes(ctx context.Context } } -// ToAttrType returns the representation of WarehouseAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of WarehouseAccessControlResponse in the Terraform plugin framework type // system. -func (a WarehouseAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehouseAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: WarehousePermission{}.ToAttrType(ctx), + ElemType: WarehousePermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -6943,9 +6943,9 @@ func (a WarehousePermission) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of WarehousePermission in the Terraform plugin framework type +// ToObjectType returns the representation of WarehousePermission in the Terraform plugin framework type // system. -func (a WarehousePermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehousePermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -6984,13 +6984,13 @@ func (a WarehousePermissions) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of WarehousePermissions in the Terraform plugin framework type +// ToObjectType returns the representation of WarehousePermissions in the Terraform plugin framework type // system. -func (a WarehousePermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehousePermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WarehouseAccessControlResponse{}.ToAttrType(ctx), + ElemType: WarehouseAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -7021,9 +7021,9 @@ func (a WarehousePermissionsDescription) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of WarehousePermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of WarehousePermissionsDescription in the Terraform plugin framework type // system. -func (a WarehousePermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehousePermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -7057,13 +7057,13 @@ func (a WarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of WarehousePermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of WarehousePermissionsRequest in the Terraform plugin framework type // system. -func (a WarehousePermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehousePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WarehouseAccessControlRequest{}.ToAttrType(ctx), + ElemType: WarehouseAccessControlRequest{}.ToObjectType(ctx), }, "warehouse_id": types.StringType, }, @@ -7095,9 +7095,9 @@ func (a WarehouseTypePair) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of WarehouseTypePair in the Terraform plugin framework type +// ToObjectType returns the representation of WarehouseTypePair in the Terraform plugin framework type // system. -func (a WarehouseTypePair) ToAttrType(ctx context.Context) types.ObjectType { +func (a WarehouseTypePair) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -7141,17 +7141,17 @@ func (a Widget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToAttrType returns the representation of Widget in the Terraform plugin framework type +// ToObjectType returns the representation of Widget in the Terraform plugin framework type // system. -func (a Widget) ToAttrType(ctx context.Context) types.ObjectType { +func (a Widget) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "options": basetypes.ListType{ - ElemType: WidgetOptions{}.ToAttrType(ctx), + ElemType: WidgetOptions{}.ToObjectType(ctx), }, "visualization": basetypes.ListType{ - ElemType: LegacyVisualization{}.ToAttrType(ctx), + ElemType: LegacyVisualization{}.ToObjectType(ctx), }, "width": types.Int64Type, }, @@ -7197,9 +7197,9 @@ func (a WidgetOptions) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToAttrType returns the representation of WidgetOptions in the Terraform plugin framework type +// ToObjectType returns the representation of WidgetOptions in the Terraform plugin framework type // system. -func (a WidgetOptions) ToAttrType(ctx context.Context) types.ObjectType { +func (a WidgetOptions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -7207,7 +7207,7 @@ func (a WidgetOptions) ToAttrType(ctx context.Context) types.ObjectType { "isHidden": types.BoolType, "parameterMappings": types.ObjectType{}, "position": basetypes.ListType{ - ElemType: WidgetPosition{}.ToAttrType(ctx), + ElemType: WidgetPosition{}.ToObjectType(ctx), }, "title": types.StringType, "updated_at": types.StringType, @@ -7247,9 +7247,9 @@ func (a WidgetPosition) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of WidgetPosition in the Terraform plugin framework type +// ToObjectType returns the representation of WidgetPosition in the Terraform plugin framework type // system. -func (a WidgetPosition) ToAttrType(ctx context.Context) types.ObjectType { +func (a WidgetPosition) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoHeight": types.BoolType, diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index b9df9743d4..f530aca0c6 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -41,9 +41,9 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of ColumnInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ColumnInfo in the Terraform plugin framework type // system. -func (a ColumnInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ColumnInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -75,9 +75,9 @@ func (a CreateEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateEndpoint in the Terraform plugin framework type +// ToObjectType returns the representation of CreateEndpoint in the Terraform plugin framework type // system. -func (a CreateEndpoint) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateEndpoint) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_type": types.StringType, @@ -129,16 +129,16 @@ func (a CreateVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of CreateVectorIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateVectorIndexRequest in the Terraform plugin framework type // system. -func (a CreateVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "delta_sync_index_spec": basetypes.ListType{ - ElemType: DeltaSyncVectorIndexSpecRequest{}.ToAttrType(ctx), + ElemType: DeltaSyncVectorIndexSpecRequest{}.ToObjectType(ctx), }, "direct_access_index_spec": basetypes.ListType{ - ElemType: DirectAccessVectorIndexSpec{}.ToAttrType(ctx), + ElemType: DirectAccessVectorIndexSpec{}.ToObjectType(ctx), }, "endpoint_name": types.StringType, "index_type": types.StringType, @@ -171,13 +171,13 @@ func (a CreateVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of CreateVectorIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateVectorIndexResponse in the Terraform plugin framework type // system. -func (a CreateVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "vector_index": basetypes.ListType{ - ElemType: VectorIndex{}.ToAttrType(ctx), + ElemType: VectorIndex{}.ToObjectType(ctx), }, }, } @@ -210,9 +210,9 @@ func (a DeleteDataResult) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of DeleteDataResult in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDataResult in the Terraform plugin framework type // system. -func (a DeleteDataResult) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDataResult) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "failed_primary_keys": basetypes.ListType{ @@ -251,9 +251,9 @@ func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of DeleteDataVectorIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDataVectorIndexRequest in the Terraform plugin framework type // system. -func (a DeleteDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDataVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -291,13 +291,13 @@ func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of DeleteDataVectorIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteDataVectorIndexResponse in the Terraform plugin framework type // system. -func (a DeleteDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteDataVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "result": basetypes.ListType{ - ElemType: DeleteDataResult{}.ToAttrType(ctx), + ElemType: DeleteDataResult{}.ToObjectType(ctx), }, "status": types.StringType, }, @@ -327,9 +327,9 @@ func (a DeleteEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteEndpointRequest in the Terraform plugin framework type // system. -func (a DeleteEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -357,9 +357,9 @@ func (a DeleteEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteEndpointResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteEndpointResponse in the Terraform plugin framework type // system. -func (a DeleteEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteEndpointResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -388,9 +388,9 @@ func (a DeleteIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteIndexRequest in the Terraform plugin framework type // system. -func (a DeleteIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -418,9 +418,9 @@ func (a DeleteIndexResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteIndexResponse in the Terraform plugin framework type // system. -func (a DeleteIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -475,19 +475,19 @@ func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of DeltaSyncVectorIndexSpecRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeltaSyncVectorIndexSpecRequest in the Terraform plugin framework type // system. -func (a DeltaSyncVectorIndexSpecRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeltaSyncVectorIndexSpecRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns_to_sync": basetypes.ListType{ ElemType: types.StringType, }, "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), + ElemType: EmbeddingSourceColumn{}.ToObjectType(ctx), }, "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), + ElemType: EmbeddingVectorColumn{}.ToObjectType(ctx), }, "embedding_writeback_table": types.StringType, "pipeline_type": types.StringType, @@ -539,16 +539,16 @@ func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToAttrType returns the representation of DeltaSyncVectorIndexSpecResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeltaSyncVectorIndexSpecResponse in the Terraform plugin framework type // system. -func (a DeltaSyncVectorIndexSpecResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeltaSyncVectorIndexSpecResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), + ElemType: EmbeddingSourceColumn{}.ToObjectType(ctx), }, "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), + ElemType: EmbeddingVectorColumn{}.ToObjectType(ctx), }, "embedding_writeback_table": types.StringType, "pipeline_id": types.StringType, @@ -592,16 +592,16 @@ func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes(ctx context.Context) m } } -// ToAttrType returns the representation of DirectAccessVectorIndexSpec in the Terraform plugin framework type +// ToObjectType returns the representation of DirectAccessVectorIndexSpec in the Terraform plugin framework type // system. -func (a DirectAccessVectorIndexSpec) ToAttrType(ctx context.Context) types.ObjectType { +func (a DirectAccessVectorIndexSpec) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.ToAttrType(ctx), + ElemType: EmbeddingSourceColumn{}.ToObjectType(ctx), }, "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.ToAttrType(ctx), + ElemType: EmbeddingVectorColumn{}.ToObjectType(ctx), }, "schema_json": types.StringType, }, @@ -632,9 +632,9 @@ func (a EmbeddingSourceColumn) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of EmbeddingSourceColumn in the Terraform plugin framework type +// ToObjectType returns the representation of EmbeddingSourceColumn in the Terraform plugin framework type // system. -func (a EmbeddingSourceColumn) ToAttrType(ctx context.Context) types.ObjectType { +func (a EmbeddingSourceColumn) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_model_endpoint_name": types.StringType, @@ -667,9 +667,9 @@ func (a EmbeddingVectorColumn) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of EmbeddingVectorColumn in the Terraform plugin framework type +// ToObjectType returns the representation of EmbeddingVectorColumn in the Terraform plugin framework type // system. -func (a EmbeddingVectorColumn) ToAttrType(ctx context.Context) types.ObjectType { +func (a EmbeddingVectorColumn) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_dimension": types.Int64Type, @@ -718,15 +718,15 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of EndpointInfo in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointInfo in the Terraform plugin framework type // system. -func (a EndpointInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, "creator": types.StringType, "endpoint_status": basetypes.ListType{ - ElemType: EndpointStatus{}.ToAttrType(ctx), + ElemType: EndpointStatus{}.ToObjectType(ctx), }, "endpoint_type": types.StringType, "id": types.StringType, @@ -763,9 +763,9 @@ func (a EndpointStatus) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of EndpointStatus in the Terraform plugin framework type +// ToObjectType returns the representation of EndpointStatus in the Terraform plugin framework type // system. -func (a EndpointStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a EndpointStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -797,9 +797,9 @@ func (a GetEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetEndpointRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetEndpointRequest in the Terraform plugin framework type // system. -func (a GetEndpointRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -830,9 +830,9 @@ func (a GetIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetIndexRequest in the Terraform plugin framework type // system. -func (a GetIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -867,13 +867,13 @@ func (a ListEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of ListEndpointResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListEndpointResponse in the Terraform plugin framework type // system. -func (a ListEndpointResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListEndpointResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoints": basetypes.ListType{ - ElemType: EndpointInfo{}.ToAttrType(ctx), + ElemType: EndpointInfo{}.ToObjectType(ctx), }, "next_page_token": types.StringType, }, @@ -903,9 +903,9 @@ func (a ListEndpointsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListEndpointsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListEndpointsRequest in the Terraform plugin framework type // system. -func (a ListEndpointsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListEndpointsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -938,9 +938,9 @@ func (a ListIndexesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListIndexesRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListIndexesRequest in the Terraform plugin framework type // system. -func (a ListIndexesRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListIndexesRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -972,13 +972,13 @@ func (a ListValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToAttrType returns the representation of ListValue in the Terraform plugin framework type +// ToObjectType returns the representation of ListValue in the Terraform plugin framework type // system. -func (a ListValue) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListValue) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "values": basetypes.ListType{ - ElemType: Value{}.ToAttrType(ctx), + ElemType: Value{}.ToObjectType(ctx), }, }, } @@ -1011,14 +1011,14 @@ func (a ListVectorIndexesResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of ListVectorIndexesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListVectorIndexesResponse in the Terraform plugin framework type // system. -func (a ListVectorIndexesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListVectorIndexesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "vector_indexes": basetypes.ListType{ - ElemType: MiniVectorIndex{}.ToAttrType(ctx), + ElemType: MiniVectorIndex{}.ToObjectType(ctx), }, }, } @@ -1051,14 +1051,14 @@ func (a MapStringValueEntry) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of MapStringValueEntry in the Terraform plugin framework type +// ToObjectType returns the representation of MapStringValueEntry in the Terraform plugin framework type // system. -func (a MapStringValueEntry) ToAttrType(ctx context.Context) types.ObjectType { +func (a MapStringValueEntry) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, "value": basetypes.ListType{ - ElemType: Value{}.ToAttrType(ctx), + ElemType: Value{}.ToObjectType(ctx), }, }, } @@ -1100,9 +1100,9 @@ func (a MiniVectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of MiniVectorIndex in the Terraform plugin framework type +// ToObjectType returns the representation of MiniVectorIndex in the Terraform plugin framework type // system. -func (a MiniVectorIndex) ToAttrType(ctx context.Context) types.ObjectType { +func (a MiniVectorIndex) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creator": types.StringType, @@ -1142,9 +1142,9 @@ func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToAttrType returns the representation of QueryVectorIndexNextPageRequest in the Terraform plugin framework type +// ToObjectType returns the representation of QueryVectorIndexNextPageRequest in the Terraform plugin framework type // system. -func (a QueryVectorIndexNextPageRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryVectorIndexNextPageRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -1199,9 +1199,9 @@ func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of QueryVectorIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of QueryVectorIndexRequest in the Terraform plugin framework type // system. -func (a QueryVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns": basetypes.ListType{ @@ -1251,17 +1251,17 @@ func (a QueryVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToAttrType returns the representation of QueryVectorIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of QueryVectorIndexResponse in the Terraform plugin framework type // system. -func (a QueryVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a QueryVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "manifest": basetypes.ListType{ - ElemType: ResultManifest{}.ToAttrType(ctx), + ElemType: ResultManifest{}.ToObjectType(ctx), }, "next_page_token": types.StringType, "result": basetypes.ListType{ - ElemType: ResultData{}.ToAttrType(ctx), + ElemType: ResultData{}.ToObjectType(ctx), }, }, } @@ -1294,9 +1294,9 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToAttrType returns the representation of ResultData in the Terraform plugin framework type +// ToObjectType returns the representation of ResultData in the Terraform plugin framework type // system. -func (a ResultData) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResultData) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_array": basetypes.ListType{ @@ -1336,14 +1336,14 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of ResultManifest in the Terraform plugin framework type +// ToObjectType returns the representation of ResultManifest in the Terraform plugin framework type // system. -func (a ResultManifest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ResultManifest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.ToAttrType(ctx), + ElemType: ColumnInfo{}.ToObjectType(ctx), }, }, } @@ -1376,9 +1376,9 @@ func (a ScanVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of ScanVectorIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ScanVectorIndexRequest in the Terraform plugin framework type // system. -func (a ScanVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ScanVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -1415,13 +1415,13 @@ func (a ScanVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ScanVectorIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ScanVectorIndexResponse in the Terraform plugin framework type // system. -func (a ScanVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ScanVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data": basetypes.ListType{ - ElemType: Struct{}.ToAttrType(ctx), + ElemType: Struct{}.ToObjectType(ctx), }, "last_primary_key": types.StringType, }, @@ -1452,13 +1452,13 @@ func (a Struct) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToAttrType returns the representation of Struct in the Terraform plugin framework type +// ToObjectType returns the representation of Struct in the Terraform plugin framework type // system. -func (a Struct) ToAttrType(ctx context.Context) types.ObjectType { +func (a Struct) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fields": basetypes.ListType{ - ElemType: MapStringValueEntry{}.ToAttrType(ctx), + ElemType: MapStringValueEntry{}.ToObjectType(ctx), }, }, } @@ -1487,9 +1487,9 @@ func (a SyncIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of SyncIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of SyncIndexRequest in the Terraform plugin framework type // system. -func (a SyncIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a SyncIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -1517,9 +1517,9 @@ func (a SyncIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of SyncIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of SyncIndexResponse in the Terraform plugin framework type // system. -func (a SyncIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a SyncIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1552,9 +1552,9 @@ func (a UpsertDataResult) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of UpsertDataResult in the Terraform plugin framework type +// ToObjectType returns the representation of UpsertDataResult in the Terraform plugin framework type // system. -func (a UpsertDataResult) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpsertDataResult) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "failed_primary_keys": basetypes.ListType{ @@ -1591,9 +1591,9 @@ func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpsertDataVectorIndexRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpsertDataVectorIndexRequest in the Terraform plugin framework type // system. -func (a UpsertDataVectorIndexRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpsertDataVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -1629,13 +1629,13 @@ func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToAttrType returns the representation of UpsertDataVectorIndexResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpsertDataVectorIndexResponse in the Terraform plugin framework type // system. -func (a UpsertDataVectorIndexResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpsertDataVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "result": basetypes.ListType{ - ElemType: UpsertDataResult{}.ToAttrType(ctx), + ElemType: UpsertDataResult{}.ToObjectType(ctx), }, "status": types.StringType, }, @@ -1676,20 +1676,20 @@ func (a Value) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToAttrType returns the representation of Value in the Terraform plugin framework type +// ToObjectType returns the representation of Value in the Terraform plugin framework type // system. -func (a Value) ToAttrType(ctx context.Context) types.ObjectType { +func (a Value) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bool_value": types.BoolType, "list_value": basetypes.ListType{ - ElemType: ListValue{}.ToAttrType(ctx), + ElemType: ListValue{}.ToObjectType(ctx), }, "null_value": types.StringType, "number_value": types.Float64Type, "string_value": types.StringType, "struct_value": basetypes.ListType{ - ElemType: Struct{}.ToAttrType(ctx), + ElemType: Struct{}.ToObjectType(ctx), }, }, } @@ -1741,24 +1741,24 @@ func (a VectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of VectorIndex in the Terraform plugin framework type +// ToObjectType returns the representation of VectorIndex in the Terraform plugin framework type // system. -func (a VectorIndex) ToAttrType(ctx context.Context) types.ObjectType { +func (a VectorIndex) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creator": types.StringType, "delta_sync_index_spec": basetypes.ListType{ - ElemType: DeltaSyncVectorIndexSpecResponse{}.ToAttrType(ctx), + ElemType: DeltaSyncVectorIndexSpecResponse{}.ToObjectType(ctx), }, "direct_access_index_spec": basetypes.ListType{ - ElemType: DirectAccessVectorIndexSpec{}.ToAttrType(ctx), + ElemType: DirectAccessVectorIndexSpec{}.ToObjectType(ctx), }, "endpoint_name": types.StringType, "index_type": types.StringType, "name": types.StringType, "primary_key": types.StringType, "status": basetypes.ListType{ - ElemType: VectorIndexStatus{}.ToAttrType(ctx), + ElemType: VectorIndexStatus{}.ToObjectType(ctx), }, }, } @@ -1792,9 +1792,9 @@ func (a VectorIndexStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of VectorIndexStatus in the Terraform plugin framework type +// ToObjectType returns the representation of VectorIndexStatus in the Terraform plugin framework type // system. -func (a VectorIndexStatus) ToAttrType(ctx context.Context) types.ObjectType { +func (a VectorIndexStatus) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_url": types.StringType, diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 416961b112..0c676585ea 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -43,9 +43,9 @@ func (a AclItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToAttrType returns the representation of AclItem in the Terraform plugin framework type +// ToObjectType returns the representation of AclItem in the Terraform plugin framework type // system. -func (a AclItem) ToAttrType(ctx context.Context) types.ObjectType { +func (a AclItem) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission": types.StringType, @@ -79,9 +79,9 @@ func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToAttrType returns the representation of AzureKeyVaultSecretScopeMetadata in the Terraform plugin framework type +// ToObjectType returns the representation of AzureKeyVaultSecretScopeMetadata in the Terraform plugin framework type // system. -func (a AzureKeyVaultSecretScopeMetadata) ToAttrType(ctx context.Context) types.ObjectType { +func (a AzureKeyVaultSecretScopeMetadata) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dns_name": types.StringType, @@ -129,9 +129,9 @@ func (a CreateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCredentialsRequest in the Terraform plugin framework type // system. -func (a CreateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "git_provider": types.StringType, @@ -168,9 +168,9 @@ func (a CreateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateCredentialsResponse in the Terraform plugin framework type // system. -func (a CreateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -216,15 +216,15 @@ func (a CreateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of CreateRepoRequest in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRepoRequest in the Terraform plugin framework type // system. -func (a CreateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToAttrType(ctx), + ElemType: SparseCheckout{}.ToObjectType(ctx), }, "url": types.StringType, }, @@ -268,9 +268,9 @@ func (a CreateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of CreateRepoResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateRepoResponse in the Terraform plugin framework type // system. -func (a CreateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, @@ -279,7 +279,7 @@ func (a CreateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToAttrType(ctx), + ElemType: SparseCheckout{}.ToObjectType(ctx), }, "url": types.StringType, }, @@ -318,13 +318,13 @@ func (a CreateScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of CreateScope in the Terraform plugin framework type +// ToObjectType returns the representation of CreateScope in the Terraform plugin framework type // system. -func (a CreateScope) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateScope) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "backend_azure_keyvault": basetypes.ListType{ - ElemType: AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), + ElemType: AzureKeyVaultSecretScopeMetadata{}.ToObjectType(ctx), }, "initial_manage_principal": types.StringType, "scope": types.StringType, @@ -353,9 +353,9 @@ func (a CreateScopeResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of CreateScopeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of CreateScopeResponse in the Terraform plugin framework type // system. -func (a CreateScopeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a CreateScopeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -388,9 +388,9 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of CredentialInfo in the Terraform plugin framework type +// ToObjectType returns the representation of CredentialInfo in the Terraform plugin framework type // system. -func (a CredentialInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a CredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -427,9 +427,9 @@ func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Delete in the Terraform plugin framework type +// ToObjectType returns the representation of Delete in the Terraform plugin framework type // system. -func (a Delete) ToAttrType(ctx context.Context) types.ObjectType { +func (a Delete) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -462,9 +462,9 @@ func (a DeleteAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAcl in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAcl in the Terraform plugin framework type // system. -func (a DeleteAcl) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAcl) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -493,9 +493,9 @@ func (a DeleteAclResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteAclResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteAclResponse in the Terraform plugin framework type // system. -func (a DeleteAclResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteAclResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -524,9 +524,9 @@ func (a DeleteCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCredentialsRequest in the Terraform plugin framework type // system. -func (a DeleteCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -554,9 +554,9 @@ func (a DeleteCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteCredentialsResponse in the Terraform plugin framework type // system. -func (a DeleteCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -585,9 +585,9 @@ func (a DeleteRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRepoRequest in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRepoRequest in the Terraform plugin framework type // system. -func (a DeleteRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.Int64Type, @@ -615,9 +615,9 @@ func (a DeleteRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteRepoResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteRepoResponse in the Terraform plugin framework type // system. -func (a DeleteRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -643,9 +643,9 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type // system. -func (a DeleteResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -673,9 +673,9 @@ func (a DeleteScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteScope in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteScope in the Terraform plugin framework type // system. -func (a DeleteScope) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteScope) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scope": types.StringType, @@ -703,9 +703,9 @@ func (a DeleteScopeResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteScopeResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteScopeResponse in the Terraform plugin framework type // system. -func (a DeleteScopeResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteScopeResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -735,9 +735,9 @@ func (a DeleteSecret) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteSecret in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteSecret in the Terraform plugin framework type // system. -func (a DeleteSecret) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteSecret) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -766,9 +766,9 @@ func (a DeleteSecretResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of DeleteSecretResponse in the Terraform plugin framework type +// ToObjectType returns the representation of DeleteSecretResponse in the Terraform plugin framework type // system. -func (a DeleteSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a DeleteSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -813,9 +813,9 @@ func (a ExportRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExportRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ExportRequest in the Terraform plugin framework type // system. -func (a ExportRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExportRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "format": types.StringType, @@ -849,9 +849,9 @@ func (a ExportResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of ExportResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ExportResponse in the Terraform plugin framework type // system. -func (a ExportResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ExportResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -885,9 +885,9 @@ func (a GetAclRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetAclRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetAclRequest in the Terraform plugin framework type // system. -func (a GetAclRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetAclRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -919,9 +919,9 @@ func (a GetCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetCredentialsRequest in the Terraform plugin framework type // system. -func (a GetCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -956,9 +956,9 @@ func (a GetCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetCredentialsResponse in the Terraform plugin framework type // system. -func (a GetCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -991,9 +991,9 @@ func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRepoPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRepoPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetRepoPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRepoPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.StringType, @@ -1025,13 +1025,13 @@ func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToAttrType returns the representation of GetRepoPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetRepoPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetRepoPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRepoPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: RepoPermissionsDescription{}.ToAttrType(ctx), + ElemType: RepoPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -1060,9 +1060,9 @@ func (a GetRepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRepoPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRepoPermissionsRequest in the Terraform plugin framework type // system. -func (a GetRepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRepoPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.StringType, @@ -1093,9 +1093,9 @@ func (a GetRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetRepoRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetRepoRequest in the Terraform plugin framework type // system. -func (a GetRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.Int64Type, @@ -1139,9 +1139,9 @@ func (a GetRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of GetRepoResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetRepoResponse in the Terraform plugin framework type // system. -func (a GetRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, @@ -1150,7 +1150,7 @@ func (a GetRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToAttrType(ctx), + ElemType: SparseCheckout{}.ToObjectType(ctx), }, "url": types.StringType, }, @@ -1182,9 +1182,9 @@ func (a GetSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetSecretRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetSecretRequest in the Terraform plugin framework type // system. -func (a GetSecretRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetSecretRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1217,9 +1217,9 @@ func (a GetSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetSecretResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetSecretResponse in the Terraform plugin framework type // system. -func (a GetSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1251,9 +1251,9 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetStatusRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetStatusRequest in the Terraform plugin framework type // system. -func (a GetStatusRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -1286,9 +1286,9 @@ func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWorkspaceObjectPermissionLevelsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceObjectPermissionLevelsRequest in the Terraform plugin framework type // system. -func (a GetWorkspaceObjectPermissionLevelsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceObjectPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_object_id": types.StringType, @@ -1321,13 +1321,13 @@ func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// ToAttrType returns the representation of GetWorkspaceObjectPermissionLevelsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceObjectPermissionLevelsResponse in the Terraform plugin framework type // system. -func (a GetWorkspaceObjectPermissionLevelsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceObjectPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: WorkspaceObjectPermissionsDescription{}.ToAttrType(ctx), + ElemType: WorkspaceObjectPermissionsDescription{}.ToObjectType(ctx), }, }, } @@ -1358,9 +1358,9 @@ func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToAttrType returns the representation of GetWorkspaceObjectPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of GetWorkspaceObjectPermissionsRequest in the Terraform plugin framework type // system. -func (a GetWorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a GetWorkspaceObjectPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_object_id": types.StringType, @@ -1419,9 +1419,9 @@ func (a Import) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Import in the Terraform plugin framework type +// ToObjectType returns the representation of Import in the Terraform plugin framework type // system. -func (a Import) ToAttrType(ctx context.Context) types.ObjectType { +func (a Import) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -1453,9 +1453,9 @@ func (a ImportResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of ImportResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ImportResponse in the Terraform plugin framework type // system. -func (a ImportResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ImportResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1484,9 +1484,9 @@ func (a ListAclsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListAclsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListAclsRequest in the Terraform plugin framework type // system. -func (a ListAclsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAclsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scope": types.StringType, @@ -1518,13 +1518,13 @@ func (a ListAclsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToAttrType returns the representation of ListAclsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListAclsResponse in the Terraform plugin framework type // system. -func (a ListAclsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListAclsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "items": basetypes.ListType{ - ElemType: AclItem{}.ToAttrType(ctx), + ElemType: AclItem{}.ToObjectType(ctx), }, }, } @@ -1554,13 +1554,13 @@ func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToAttrType returns the representation of ListCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListCredentialsResponse in the Terraform plugin framework type // system. -func (a ListCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials": basetypes.ListType{ - ElemType: CredentialInfo{}.ToAttrType(ctx), + ElemType: CredentialInfo{}.ToObjectType(ctx), }, }, } @@ -1595,9 +1595,9 @@ func (a ListReposRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListReposRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListReposRequest in the Terraform plugin framework type // system. -func (a ListReposRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListReposRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, @@ -1633,14 +1633,14 @@ func (a ListReposResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of ListReposResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListReposResponse in the Terraform plugin framework type // system. -func (a ListReposResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListReposResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "repos": basetypes.ListType{ - ElemType: RepoInfo{}.ToAttrType(ctx), + ElemType: RepoInfo{}.ToObjectType(ctx), }, }, } @@ -1670,13 +1670,13 @@ func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToAttrType returns the representation of ListResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListResponse in the Terraform plugin framework type // system. -func (a ListResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "objects": basetypes.ListType{ - ElemType: ObjectInfo{}.ToAttrType(ctx), + ElemType: ObjectInfo{}.ToObjectType(ctx), }, }, } @@ -1706,13 +1706,13 @@ func (a ListScopesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToAttrType returns the representation of ListScopesResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListScopesResponse in the Terraform plugin framework type // system. -func (a ListScopesResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListScopesResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scopes": basetypes.ListType{ - ElemType: SecretScope{}.ToAttrType(ctx), + ElemType: SecretScope{}.ToObjectType(ctx), }, }, } @@ -1741,9 +1741,9 @@ func (a ListSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListSecretsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListSecretsRequest in the Terraform plugin framework type // system. -func (a ListSecretsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSecretsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scope": types.StringType, @@ -1775,13 +1775,13 @@ func (a ListSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToAttrType returns the representation of ListSecretsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of ListSecretsResponse in the Terraform plugin framework type // system. -func (a ListSecretsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListSecretsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "secrets": basetypes.ListType{ - ElemType: SecretMetadata{}.ToAttrType(ctx), + ElemType: SecretMetadata{}.ToObjectType(ctx), }, }, } @@ -1812,9 +1812,9 @@ func (a ListWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToAttrType returns the representation of ListWorkspaceRequest in the Terraform plugin framework type +// ToObjectType returns the representation of ListWorkspaceRequest in the Terraform plugin framework type // system. -func (a ListWorkspaceRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a ListWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "notebooks_modified_after": types.Int64Type, @@ -1847,9 +1847,9 @@ func (a Mkdirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of Mkdirs in the Terraform plugin framework type +// ToObjectType returns the representation of Mkdirs in the Terraform plugin framework type // system. -func (a Mkdirs) ToAttrType(ctx context.Context) types.ObjectType { +func (a Mkdirs) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -1877,9 +1877,9 @@ func (a MkdirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of MkdirsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of MkdirsResponse in the Terraform plugin framework type // system. -func (a MkdirsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a MkdirsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1927,9 +1927,9 @@ func (a ObjectInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToAttrType returns the representation of ObjectInfo in the Terraform plugin framework type +// ToObjectType returns the representation of ObjectInfo in the Terraform plugin framework type // system. -func (a ObjectInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a ObjectInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -1970,9 +1970,9 @@ func (a PutAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToAttrType returns the representation of PutAcl in the Terraform plugin framework type +// ToObjectType returns the representation of PutAcl in the Terraform plugin framework type // system. -func (a PutAcl) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutAcl) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission": types.StringType, @@ -2002,9 +2002,9 @@ func (a PutAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of PutAclResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PutAclResponse in the Terraform plugin framework type // system. -func (a PutAclResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutAclResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2038,9 +2038,9 @@ func (a PutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToAttrType returns the representation of PutSecret in the Terraform plugin framework type +// ToObjectType returns the representation of PutSecret in the Terraform plugin framework type // system. -func (a PutSecret) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutSecret) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bytes_value": types.StringType, @@ -2071,9 +2071,9 @@ func (a PutSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToAttrType returns the representation of PutSecretResponse in the Terraform plugin framework type +// ToObjectType returns the representation of PutSecretResponse in the Terraform plugin framework type // system. -func (a PutSecretResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a PutSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2107,9 +2107,9 @@ func (a RepoAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of RepoAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RepoAccessControlRequest in the Terraform plugin framework type // system. -func (a RepoAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -2152,13 +2152,13 @@ func (a RepoAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of RepoAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of RepoAccessControlResponse in the Terraform plugin framework type // system. -func (a RepoAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: RepoPermission{}.ToAttrType(ctx), + ElemType: RepoPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -2205,9 +2205,9 @@ func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToAttrType returns the representation of RepoInfo in the Terraform plugin framework type +// ToObjectType returns the representation of RepoInfo in the Terraform plugin framework type // system. -func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoInfo) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, @@ -2216,7 +2216,7 @@ func (a RepoInfo) ToAttrType(ctx context.Context) types.ObjectType { "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToAttrType(ctx), + ElemType: SparseCheckout{}.ToObjectType(ctx), }, "url": types.StringType, }, @@ -2250,9 +2250,9 @@ func (a RepoPermission) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of RepoPermission in the Terraform plugin framework type +// ToObjectType returns the representation of RepoPermission in the Terraform plugin framework type // system. -func (a RepoPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2291,13 +2291,13 @@ func (a RepoPermissions) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToAttrType returns the representation of RepoPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of RepoPermissions in the Terraform plugin framework type // system. -func (a RepoPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RepoAccessControlResponse{}.ToAttrType(ctx), + ElemType: RepoAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2328,9 +2328,9 @@ func (a RepoPermissionsDescription) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToAttrType returns the representation of RepoPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of RepoPermissionsDescription in the Terraform plugin framework type // system. -func (a RepoPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2364,13 +2364,13 @@ func (a RepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToAttrType returns the representation of RepoPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of RepoPermissionsRequest in the Terraform plugin framework type // system. -func (a RepoPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a RepoPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RepoAccessControlRequest{}.ToAttrType(ctx), + ElemType: RepoAccessControlRequest{}.ToObjectType(ctx), }, "repo_id": types.StringType, }, @@ -2401,9 +2401,9 @@ func (a SecretMetadata) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToAttrType returns the representation of SecretMetadata in the Terraform plugin framework type +// ToObjectType returns the representation of SecretMetadata in the Terraform plugin framework type // system. -func (a SecretMetadata) ToAttrType(ctx context.Context) types.ObjectType { +func (a SecretMetadata) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2440,14 +2440,14 @@ func (a SecretScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToAttrType returns the representation of SecretScope in the Terraform plugin framework type +// ToObjectType returns the representation of SecretScope in the Terraform plugin framework type // system. -func (a SecretScope) ToAttrType(ctx context.Context) types.ObjectType { +func (a SecretScope) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "backend_type": types.StringType, "keyvault_metadata": basetypes.ListType{ - ElemType: AzureKeyVaultSecretScopeMetadata{}.ToAttrType(ctx), + ElemType: AzureKeyVaultSecretScopeMetadata{}.ToObjectType(ctx), }, "name": types.StringType, }, @@ -2482,9 +2482,9 @@ func (a SparseCheckout) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToAttrType returns the representation of SparseCheckout in the Terraform plugin framework type +// ToObjectType returns the representation of SparseCheckout in the Terraform plugin framework type // system. -func (a SparseCheckout) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparseCheckout) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "patterns": basetypes.ListType{ @@ -2522,9 +2522,9 @@ func (a SparseCheckoutUpdate) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToAttrType returns the representation of SparseCheckoutUpdate in the Terraform plugin framework type +// ToObjectType returns the representation of SparseCheckoutUpdate in the Terraform plugin framework type // system. -func (a SparseCheckoutUpdate) ToAttrType(ctx context.Context) types.ObjectType { +func (a SparseCheckoutUpdate) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "patterns": basetypes.ListType{ @@ -2575,9 +2575,9 @@ func (a UpdateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateCredentialsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCredentialsRequest in the Terraform plugin framework type // system. -func (a UpdateCredentialsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -2608,9 +2608,9 @@ func (a UpdateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateCredentialsResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateCredentialsResponse in the Terraform plugin framework type // system. -func (a UpdateCredentialsResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2650,15 +2650,15 @@ func (a UpdateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToAttrType returns the representation of UpdateRepoRequest in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRepoRequest in the Terraform plugin framework type // system. -func (a UpdateRepoRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, "repo_id": types.Int64Type, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckoutUpdate{}.ToAttrType(ctx), + ElemType: SparseCheckoutUpdate{}.ToObjectType(ctx), }, "tag": types.StringType, }, @@ -2685,9 +2685,9 @@ func (a UpdateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToAttrType returns the representation of UpdateRepoResponse in the Terraform plugin framework type +// ToObjectType returns the representation of UpdateRepoResponse in the Terraform plugin framework type // system. -func (a UpdateRepoResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a UpdateRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2721,9 +2721,9 @@ func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToAttrType returns the representation of WorkspaceObjectAccessControlRequest in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceObjectAccessControlRequest in the Terraform plugin framework type // system. -func (a WorkspaceObjectAccessControlRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceObjectAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -2766,13 +2766,13 @@ func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// ToAttrType returns the representation of WorkspaceObjectAccessControlResponse in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceObjectAccessControlResponse in the Terraform plugin framework type // system. -func (a WorkspaceObjectAccessControlResponse) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceObjectAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: WorkspaceObjectPermission{}.ToAttrType(ctx), + ElemType: WorkspaceObjectPermission{}.ToObjectType(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -2809,9 +2809,9 @@ func (a WorkspaceObjectPermission) GetComplexFieldTypes(ctx context.Context) map } } -// ToAttrType returns the representation of WorkspaceObjectPermission in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceObjectPermission in the Terraform plugin framework type // system. -func (a WorkspaceObjectPermission) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceObjectPermission) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2850,13 +2850,13 @@ func (a WorkspaceObjectPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// ToAttrType returns the representation of WorkspaceObjectPermissions in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceObjectPermissions in the Terraform plugin framework type // system. -func (a WorkspaceObjectPermissions) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceObjectPermissions) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WorkspaceObjectAccessControlResponse{}.ToAttrType(ctx), + ElemType: WorkspaceObjectAccessControlResponse{}.ToObjectType(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2887,9 +2887,9 @@ func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToAttrType returns the representation of WorkspaceObjectPermissionsDescription in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceObjectPermissionsDescription in the Terraform plugin framework type // system. -func (a WorkspaceObjectPermissionsDescription) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceObjectPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2925,13 +2925,13 @@ func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToAttrType returns the representation of WorkspaceObjectPermissionsRequest in the Terraform plugin framework type +// ToObjectType returns the representation of WorkspaceObjectPermissionsRequest in the Terraform plugin framework type // system. -func (a WorkspaceObjectPermissionsRequest) ToAttrType(ctx context.Context) types.ObjectType { +func (a WorkspaceObjectPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WorkspaceObjectAccessControlRequest{}.ToAttrType(ctx), + ElemType: WorkspaceObjectAccessControlRequest{}.ToObjectType(ctx), }, "workspace_object_id": types.StringType, "workspace_object_type": types.StringType, From 560ce2726a3ea1ccb6f3058a9c9b592d1031664f Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 6 Dec 2024 10:16:29 +0100 Subject: [PATCH 49/91] work --- .codegen/model.go.tmpl | 99 +- .../common/complex_field_type_provider.go | 1 - .../pluginfw/common/object_typable.go | 21 - .../pluginfw/common/object_valuable.go | 163 + .../providers/pluginfw/converters/go_to_tf.go | 7 +- .../providers/pluginfw/converters/names.go | 20 + .../providers/pluginfw/converters/tf_to_go.go | 2 +- .../products/catalog/data_functions.go | 12 +- .../pluginfw/products/cluster/data_cluster.go | 77 +- .../products/cluster/data_cluster_test.go | 15 +- .../data_notification_destinations.go | 22 +- .../resource_quality_monitor.go | 9 - .../registered_model/data_registered_model.go | 18 +- .../data_registered_model_versions.go | 19 +- .../serving/data_serving_endpoints.go | 18 +- .../products/sharing/resource_share.go | 6 - .../pluginfw/tfschema/struct_to_schema.go | 14 +- .../tfschema/struct_to_schema_test.go | 22 +- internal/service/apps_tf/model.go | 1745 ++- internal/service/billing_tf/model.go | 2049 ++- internal/service/catalog_tf/model.go | 13022 ++++++++++++++-- internal/service/compute_tf/model.go | 9883 +++++++++++- internal/service/dashboards_tf/model.go | 2555 ++- internal/service/files_tf/model.go | 1916 ++- internal/service/iam_tf/model.go | 3706 ++++- internal/service/jobs_tf/model.go | 7503 ++++++++- internal/service/marketplace_tf/model.go | 6129 +++++++- internal/service/ml_tf/model.go | 8744 ++++++++++- internal/service/oauth2_tf/model.go | 1720 +- internal/service/pipelines_tf/model.go | 3292 +++- internal/service/provisioning_tf/model.go | 2859 +++- internal/service/serving_tf/model.go | 4180 ++++- internal/service/settings_tf/model.go | 7719 ++++++++- internal/service/sharing_tf/model.go | 2407 ++- internal/service/sql_tf/model.go | 8157 +++++++++- internal/service/vectorsearch_tf/model.go | 2362 ++- internal/service/workspace_tf/model.go | 4177 ++++- 37 files changed, 88069 insertions(+), 6601 deletions(-) delete mode 100644 internal/providers/pluginfw/common/object_typable.go create mode 100644 internal/providers/pluginfw/common/object_valuable.go create mode 100644 internal/providers/pluginfw/converters/names.go diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index bbfb01cbc6..f4c35839ad 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -16,7 +16,9 @@ import ( "github.com/databricks/databricks-sdk-go/service/{{.Name}}" "io" "github.com/databricks/databricks-sdk-go/marshal" - "github.com/hashicorp/terraform-plugin-framework/types" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" + "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) {{range .Types}} {{- if or .Fields .IsEmpty}} @@ -78,9 +80,56 @@ func (a {{.PascalName}}) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of {{.PascalName}} in the Terraform plugin framework type -// system. -func (a {{.PascalName}}) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = {{.PascalName}}{} + +// Equal implements basetypes.ObjectValuable. +func (o {{.PascalName}}) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o {{.PascalName}}) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o {{.PascalName}}) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o {{.PascalName}}) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o {{.PascalName}}) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o {{.PascalName}}) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o {{.PascalName}}) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ {{ range .Fields -}} @@ -94,6 +143,29 @@ func (a {{.PascalName}}) ToObjectType(ctx context.Context) types.ObjectType { {{end}} {{end}} +{{range .Types}} +{{- if .IsEnum}} +{{.Comment "// " 80}} + +{{end}} +{{end}} + +{{- define "complex-field-value" -}} + {{- if .ArrayValue }}{{ template "complex-field-value" .ArrayValue }} + {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} + {{- else -}} + {{- if .IsExternal -}}{{.Package.Name}}.{{- end -}} + {{- if or .IsString .Enum -}}types.String{} + {{- else if .IsBool -}}types.Bool{} + {{- else if .IsInt64 -}}types.Int64{} + {{- else if .IsFloat64 -}}types.Float64{} + {{- else if .IsInt -}}types.Int64{} + {{- else if .IsAny -}}struct{}{} + {{- else if or .IsEmpty .IsObject -}}{{.PascalName}}{} + {{- end -}} + {{- end -}} +{{- end -}} + {{/* Jobs has a recursive structure: Tasks contain ForEachTasks, which contain Tasks. Because of this, GetComplexFieldTypes and ToObjectType will never terminate. @@ -121,30 +193,15 @@ even when they are called recursively. {{- else if .IsAny -}}types.ObjectType{} {{- else if .IsByteStream}}types.ObjectType{} {{- else if or .IsEmpty .IsObject -}}{{/* Objects are treated as lists from a TFSDK type perspective. */}}basetypes.ListType{ - ElemType: {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}}{{.PascalName}}{}.ToObjectType(ctx), + ElemType: {{- if .IsExternal -}}{{.Package.Name}}_tf.{{- end -}}{{.PascalName}}{}.Type(ctx), } {{- end -}} {{- end -}} {{- end -}} -{{- define "complex-field-value" -}} - {{- if .ArrayValue }}{{ template "complex-field-value" .ArrayValue }} - {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} - {{- else -}} - {{- if .IsExternal -}}{{.Package.Name}}.{{- end -}} - {{- if or .IsString .Enum -}}types.String{} - {{- else if .IsBool -}}types.Bool{} - {{- else if .IsInt64 -}}types.Int64{} - {{- else if .IsFloat64 -}}types.Float64{} - {{- else if .IsInt -}}types.Int64{} - {{- else if .IsAny -}}struct{}{} - {{- else if or .IsEmpty .IsObject -}}{{.PascalName}}{} - {{- end -}} - {{- end -}} -{{- end -}} {{- define "field" -}} -{{if .effective}}Effective{{end}}{{.field.PascalName}} {{template "type" .field.Entity}} `{{template "field-tag" . }}` +{{if .effective}}Effective{{end}}{{.field.PascalName}}{{if eq .field.PascalName "Type"}}_{{end}} {{template "type" .field.Entity}} `{{template "field-tag" . }}` {{- end -}} {{- define "field-tag" -}} diff --git a/internal/providers/pluginfw/common/complex_field_type_provider.go b/internal/providers/pluginfw/common/complex_field_type_provider.go index 2300691dbc..ef074398bd 100644 --- a/internal/providers/pluginfw/common/complex_field_type_provider.go +++ b/internal/providers/pluginfw/common/complex_field_type_provider.go @@ -3,7 +3,6 @@ package common import ( "context" "reflect" - ) // ComplexFieldTypeProvider must be implemented by any TFSDK structure that contains diff --git a/internal/providers/pluginfw/common/object_typable.go b/internal/providers/pluginfw/common/object_typable.go deleted file mode 100644 index 863f2e13c9..0000000000 --- a/internal/providers/pluginfw/common/object_typable.go +++ /dev/null @@ -1,21 +0,0 @@ -package common - -import ( - "context" - - "github.com/hashicorp/terraform-plugin-framework/types" -) - -// ObjectTypable defines the Terraform type to be used for a given object. This allows -// the framework to dynamically instantiate instances of this type, either as an object, -// or as an element in a collection of objects, such as a list or map. -// -// Note that this interface is different from ObjectTypable in the plugin framework itself. -// That interface allows you to do custom serde when interacting with Terraform state. -// The TF SDK in this provider uses types from the plugin framework, and the custom handling -// of serde is mainly done at the boundary between the TFSDK and Databricks Go SDK types. -type ObjectTypable interface { - // ToObjectType returns the types.ObjectType that describes the object's type in the - // Terraform value type system. - ToObjectType(context.Context) types.ObjectType -} diff --git a/internal/providers/pluginfw/common/object_valuable.go b/internal/providers/pluginfw/common/object_valuable.go new file mode 100644 index 0000000000..46c132d1fb --- /dev/null +++ b/internal/providers/pluginfw/common/object_valuable.go @@ -0,0 +1,163 @@ +package common + +import ( + "context" + "fmt" + "reflect" + + "github.com/databricks/terraform-provider-databricks/common" + "github.com/databricks/terraform-provider-databricks/internal/tfreflect" + "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" + "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" +) + +type ObjectValuable struct { + // A TF SDK structure. + // If this contains types.List, types.Map, or types.Object, it must implement the + // ComplexFieldTypesProvider interface. + inner any +} + +// Construct a new ObjectValuable. +// TFSDK structs automatically implement ObjectValuable, so they are returned as-is. +// Hand-written structs do not necessarily implement ObjectValuable, so this is a +// convenience implementation using reflection. +func NewObjectValuable(inner any) ObjectValuable { + if ov, ok := inner.(ObjectValuable); ok { + return ov + } + return ObjectValuable{inner: inner} +} + +// Equal implements basetypes.ObjectValuable. +func (o ObjectValuable) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ObjectValuable) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ObjectValuable) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ObjectValuable) String() string { + return fmt.Sprintf("%v", o.inner) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ObjectValuable) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o.inner, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ObjectValuable) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ObjectValuable) Type(ctx context.Context) attr.Type { + attrs := map[string]attr.Type{} + + // Tolerate pointers. + rv := reflect.Indirect(reflect.ValueOf(o.inner)) + for _, field := range tfreflect.ListAllFields(rv) { + typeField := field.StructField + fieldName := typeField.Tag.Get("tfsdk") + if fieldName == "-" { + continue + } + // If it is a simple type, we can determine the type from the reflect.Type. + if t, ok := getAttrType(field.Value); ok { + attrs[fieldName] = t + continue + } + + // Otherwise, additional metadata is required to determine the type of the list elements. + // This is available via the ComplexFieldTypeProvider interface, implemented on the parent type. + provider, ok := o.inner.(ComplexFieldTypeProvider) + if !ok { + panic(fmt.Errorf("complex field types not provided for type: %T. %s", o.inner, common.TerraformBugErrorMessage)) + } + complexFieldTypes := provider.GetComplexFieldTypes(ctx) + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, o.inner, common.TerraformBugErrorMessage)) + } + + // This is either a "simple" type or a TF SDK structure. + var innerType attr.Type + if t, ok := getAttrType(fieldType); ok { + innerType = t + } else { + // If this is a TF SDK structure, we need to recursively determine the type. + nested := reflect.New(fieldType).Elem().Interface() + ov := ObjectValuable{inner: nested} + innerType = ov.Type(ctx) + } + + switch field.Value.Interface().(type) { + case types.List: + attrs[fieldName] = types.ListType{ElemType: innerType} + case types.Map: + attrs[fieldName] = types.MapType{ElemType: innerType} + case types.Object: + // Objects are only used for nested structures, not primitives, so we must go through + // the else case above. + innerType, ok = innerType.(basetypes.ObjectType) + if !ok { + panic(fmt.Errorf("expected ObjectType, got %T", innerType)) + } + attrs[fieldName] = innerType + } + } + + return basetypes.ObjectType{ + AttrTypes: attrs, + } +} + +var simpleTypeMap = map[reflect.Type]attr.Type{ + reflect.TypeOf(types.Bool{}): types.BoolType, + reflect.TypeOf(types.Int64{}): types.Int64Type, + reflect.TypeOf(types.Float64{}): types.Float64Type, + reflect.TypeOf(types.String{}): types.StringType, +} + +// getAttrType returns the attr.Type for the given value. The value can be a +// reflect.Type instance or a Terraform type instance. +func getAttrType(v any) (attr.Type, bool) { + if r, ok := v.(reflect.Type); ok { + t, ok := simpleTypeMap[r] + return t, ok + } + if rv, ok := v.(reflect.Value); ok { + t, ok := simpleTypeMap[rv.Type()] + return t, ok + } + t, ok := simpleTypeMap[reflect.TypeOf(v)] + return t, ok +} + +var _ basetypes.ObjectValuable = ObjectValuable{} diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index 28832cb44f..a9a1507908 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -63,10 +63,7 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ // objectType is the type of the destination struct. Entries from this are used when constructing // plugin framework attr.Values for fields in the object. - var objectType types.ObjectType - if ot, ok := destVal.Interface().(tfcommon.ObjectTypable); ok { - objectType = ot.ToObjectType(ctx) - } + objectType := tfcommon.NewObjectValuable(tfsdk).Type(ctx).(types.ObjectType) var forceSendFieldVal []string forceSendField := srcVal.FieldByName("ForceSendFields") @@ -85,7 +82,7 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ if srcFieldTag == "-" { continue } - destField := destVal.FieldByName(srcFieldName) + destField := destVal.FieldByName(toTfSdkName(srcFieldName)) destFieldType, ok := destVal.Type().FieldByName(field.StructField.Name) if !ok { d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("destination struct does not have field %s. %s", srcFieldName, common.TerraformBugErrorMessage)) diff --git a/internal/providers/pluginfw/converters/names.go b/internal/providers/pluginfw/converters/names.go new file mode 100644 index 0000000000..5c1847aafc --- /dev/null +++ b/internal/providers/pluginfw/converters/names.go @@ -0,0 +1,20 @@ +package converters + +import ( + "strings" +) + +var reservedNames = map[string]struct{}{ + "Type": {}, +} + +func toGoSdkName(tfSdkName string) string { + return strings.TrimSuffix(tfSdkName, "_") +} + +func toTfSdkName(goSdkName string) string { + if _, ok := reservedNames[goSdkName]; ok { + return goSdkName + "_" + } + return goSdkName +} diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 9d14c05fe7..8d7a5b250a 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -71,7 +71,7 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ continue } - destField := destVal.FieldByName(srcFieldName) + destField := destVal.FieldByName(toGoSdkName(srcFieldName)) innerType := innerTypes[srcFieldTag] d.Append(tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField, innerType)...) diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index f6c1358909..e199cc722a 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -16,7 +16,6 @@ import ( "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -51,7 +50,7 @@ func (FunctionsData) ToObjectType(ctx context.Context) types.ObjectType { "catalog_name": types.StringType, "schema_name": types.StringType, "include_browse": types.BoolType, - "functions": types.ListType{ElemType: catalog_tf.FunctionInfo{}.ToObjectType(ctx)}, + "functions": types.ListType{ElemType: pluginfwcommon.NewObjectValuable(catalog_tf.FunctionInfo{}).Type(ctx)}, }, } } @@ -102,7 +101,7 @@ func (d *FunctionsDataSource) Read(ctx context.Context, req datasource.ReadReque resp.Diagnostics.AddError(fmt.Sprintf("failed to get functions for %s.%s schema", catalogName, schemaName), err.Error()) return } - tfFunctions := []catalog_tf.FunctionInfo{} + tfFunctions := []attr.Value{} for _, functionSdk := range functionsInfosSdk { var function catalog_tf.FunctionInfo resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, functionSdk, &function)...) @@ -111,11 +110,6 @@ func (d *FunctionsDataSource) Read(ctx context.Context, req datasource.ReadReque } tfFunctions = append(tfFunctions, function) } - var dd diag.Diagnostics - functions.Functions, dd = types.ListValueFrom(ctx, catalog_tf.FunctionInfo{}.ToObjectType(ctx), tfFunctions) - resp.Diagnostics.Append(dd...) - if resp.Diagnostics.HasError() { - return - } + functions.Functions = types.ListValueMust(catalog_tf.FunctionInfo{}.Type(ctx), tfFunctions) resp.Diagnostics.Append(resp.State.Set(ctx, functions)...) } diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index 9da5586dd0..20250c7d09 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -45,16 +45,6 @@ func (ClusterInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type } } -func (ClusterInfo) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "cluster_name": types.StringType, - "cluster_info": types.ListType{ElemType: compute_tf.ClusterDetails{}.ToObjectType(ctx)}, - }, - } -} - func (d *ClusterDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = pluginfwcommon.GetDatabricksStagingName(dataSourceName) } @@ -73,20 +63,6 @@ func (d *ClusterDataSource) Configure(_ context.Context, req datasource.Configur } } -func validateClustersList(ctx context.Context, clusters []compute_tf.ClusterDetails, clusterName string) diag.Diagnostics { - if len(clusters) == 0 { - return diag.Diagnostics{diag.NewErrorDiagnostic(fmt.Sprintf("there is no cluster with name '%s'", clusterName), "")} - } - if len(clusters) > 1 { - clusterIDs := []string{} - for _, cluster := range clusters { - clusterIDs = append(clusterIDs, cluster.ClusterId.ValueString()) - } - return diag.Diagnostics{diag.NewErrorDiagnostic(fmt.Sprintf("there is more than one cluster with name '%s'", clusterName), fmt.Sprintf("The IDs of those clusters are: %s. When specifying a cluster name, the name must be unique. Alternatively, specify the cluster by ID using the cluster_id attribute.", strings.Join(clusterIDs, ", ")))} - } - return nil -} - func (d *ClusterDataSource) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse) { ctx = pluginfwcontext.SetUserAgentInDataSourceContext(ctx, dataSourceName) w, diags := d.Client.GetWorkspaceClient() @@ -100,34 +76,56 @@ func (d *ClusterDataSource) Read(ctx context.Context, req datasource.ReadRequest if resp.Diagnostics.HasError() { return } + clusterName := clusterInfo.Name.ValueString() clusterId := clusterInfo.ClusterId.ValueString() - c, diag := d.getClusterDetails(ctx, w, clusterName, clusterId) + cluster, diag := d.getClusterDetails(ctx, w, clusterName, clusterId) resp.Diagnostics.Append(diag...) if resp.Diagnostics.HasError() { return } - cc := []compute_tf.ClusterDetails{} - for _, cluster := range c { - var tfCluster compute_tf.ClusterDetails - resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, cluster, &tfCluster)...) - cc = append(cc, tfCluster) - } - resp.Diagnostics.Append(validateClustersList(ctx, cc, clusterName)...) - clusterInfo.ClusterId = cc[0].ClusterId - clusterInfo.Name = cc[0].ClusterName + + var tfCluster compute_tf.ClusterDetails + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, cluster, &tfCluster)...) + + clusterInfo.ClusterId = tfCluster.ClusterId + clusterInfo.Name = tfCluster.ClusterName + clusterInfo.ClusterInfo = types.ListValueMust(tfCluster.Type(ctx), []attr.Value{tfCluster}) resp.Diagnostics.Append(resp.State.Set(ctx, clusterInfo)...) } -func (d *ClusterDataSource) getClusterDetails(ctx context.Context, w *databricks.WorkspaceClient, clusterName, clusterId string) (c []compute.ClusterDetails, dd diag.Diagnostics) { +func validateClustersList(_ context.Context, clusters []compute.ClusterDetails, clusterName string) diag.Diagnostics { + if len(clusters) == 0 { + return diag.Diagnostics{diag.NewErrorDiagnostic(fmt.Sprintf("there is no cluster with name '%s'", clusterName), "")} + } + if len(clusters) > 1 { + clusterIDs := []string{} + for _, cluster := range clusters { + clusterIDs = append(clusterIDs, cluster.ClusterId) + } + return diag.Diagnostics{diag.NewErrorDiagnostic(fmt.Sprintf("there is more than one cluster with name '%s'", clusterName), fmt.Sprintf("The IDs of those clusters are: %s. When specifying a cluster name, the name must be unique. Alternatively, specify the cluster by ID using the cluster_id attribute.", strings.Join(clusterIDs, ", ")))} + } + return nil +} + +func (d *ClusterDataSource) getClusterDetails(ctx context.Context, w *databricks.WorkspaceClient, clusterName, clusterId string) (c compute.ClusterDetails, dd diag.Diagnostics) { if clusterName != "" { - var err error - c, err = w.Clusters.ListAll(ctx, compute.ListClustersRequest{}) + clusters, err := w.Clusters.ListAll(ctx, compute.ListClustersRequest{}) if err != nil { dd.AddError("failed to list clusters", err.Error()) return } - return + cc := []compute.ClusterDetails{} + for _, cluster := range clusters { + if cluster.ClusterName == clusterName { + cc = append(cc, cluster) + } + } + dd.Append(validateClustersList(ctx, cc, clusterName)...) + if dd.HasError() { + return + } + return cc[0], dd } if clusterId != "" { cluster, err := w.Clusters.GetByClusterId(ctx, clusterId) @@ -135,8 +133,7 @@ func (d *ClusterDataSource) getClusterDetails(ctx context.Context, w *databricks dd.AddError(fmt.Sprintf("failed to get cluster with cluster id: %s", clusterId), err.Error()) return } - c = []compute.ClusterDetails{*cluster} - return + return *cluster, dd } dd.AddError("you need to specify either `cluster_name` or `cluster_id`", "") diff --git a/internal/providers/pluginfw/products/cluster/data_cluster_test.go b/internal/providers/pluginfw/products/cluster/data_cluster_test.go index 83ee608a98..2e36e367d4 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster_test.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster_test.go @@ -5,15 +5,14 @@ import ( "fmt" "testing" - "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" + "github.com/databricks/databricks-sdk-go/service/compute" "github.com/hashicorp/terraform-plugin-framework/diag" - "github.com/hashicorp/terraform-plugin-framework/types" "github.com/stretchr/testify/assert" ) func TestNoClusterError(t *testing.T) { clusterName := "test-cluster-name" - clusters := []compute_tf.ClusterDetails{} + clusters := []compute.ClusterDetails{} actualDiagnostics := validateClustersList(context.Background(), clusters, clusterName) expectedDiagnostics := diag.Diagnostics{diag.NewErrorDiagnostic(fmt.Sprintf("there is no cluster with name '%s'", clusterName), "")} assert.True(t, actualDiagnostics.HasError()) @@ -22,14 +21,14 @@ func TestNoClusterError(t *testing.T) { func TestMultipleClustersError(t *testing.T) { clusterName := "test-cluster-name" - clusters := []compute_tf.ClusterDetails{ + clusters := []compute.ClusterDetails{ { - ClusterName: types.StringValue("test-cluster-name"), - ClusterId: types.StringValue("123"), + ClusterName: "test-cluster-name", + ClusterId: "123", }, { - ClusterName: types.StringValue("test-cluster-name"), - ClusterId: types.StringValue("456"), + ClusterName: "test-cluster-name", + ClusterId: "456", }, } actualDiagnostics := validateClustersList(context.Background(), clusters, clusterName) diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index b9dcf58def..baacf723db 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -45,18 +45,6 @@ func (NotificationDestinationsInfo) GetComplexFieldTypes(context.Context) map[st } } -func (NotificationDestinationsInfo) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "display_name_contains": types.StringType, - "type": types.StringType, - "notification_destinations": types.ListType{ - ElemType: settings_tf.ListNotificationDestinationsResult{}.ToObjectType(ctx), - }, - }, - } -} - func (d *NotificationDestinationsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = pluginfwcommon.GetDatabricksProductionName(dataSourceName) } @@ -120,7 +108,7 @@ func (d *NotificationDestinationsDataSource) Read(ctx context.Context, req datas return } - var notificationsTfSdk []settings_tf.ListNotificationDestinationsResult + var notificationsTfSdk []attr.Value for _, notification := range notificationsGoSdk { if (notificationType != "" && notification.DestinationType.String() != notificationType) || (notificationDisplayName != "" && !strings.Contains(strings.ToLower(notification.DisplayName), notificationDisplayName)) { @@ -134,13 +122,7 @@ func (d *NotificationDestinationsDataSource) Read(ctx context.Context, req datas notificationsTfSdk = append(notificationsTfSdk, notificationDestination) } - var dd diag.Diagnostics - notificationInfo.NotificationDestinations, dd = types.ListValueFrom(ctx, settings_tf.ListNotificationDestinationsResult{}.ToObjectType(ctx), notificationsTfSdk) - resp.Diagnostics.Append(dd...) - if resp.Diagnostics.HasError() { - return - } - + notificationInfo.NotificationDestinations = types.ListValueMust(settings_tf.ListNotificationDestinationsResult{}.Type(ctx), notificationsTfSdk) resp.Diagnostics.Append(resp.State.Set(ctx, notificationInfo)...) } diff --git a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go index 7fc6d788d1..00e04a3bd8 100644 --- a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go +++ b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go @@ -63,20 +63,11 @@ type MonitorInfoExtended struct { } var _ pluginfwcommon.ComplexFieldTypeProvider = MonitorInfoExtended{} -var _ pluginfwcommon.ObjectTypable = MonitorInfoExtended{} func (m MonitorInfoExtended) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return m.MonitorInfo.GetComplexFieldTypes(ctx) } -func (m MonitorInfoExtended) ToObjectType(ctx context.Context) types.ObjectType { - tpe := m.MonitorInfo.ToObjectType(ctx) - tpe.AttrTypes["warehouse_id"] = types.StringType - tpe.AttrTypes["skip_builtin_dashboard"] = types.BoolType - tpe.AttrTypes["id"] = types.StringType - return tpe -} - type QualityMonitorResource struct { Client *common.DatabricksClient } diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index 9d77b72f6a..045413ee05 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -46,17 +46,6 @@ func (RegisteredModelData) GetComplexFieldTypes(context.Context) map[string]refl } } -func (RegisteredModelData) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "full_name": types.StringType, - "include_aliases": types.BoolType, - "include_browse": types.BoolType, - "model_info": types.ListType{ElemType: catalog_tf.RegisteredModelInfo{}.ToObjectType(ctx)}, - }, - } -} - func (d *RegisteredModelDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = pluginfwcommon.GetDatabricksProductionName(dataSourceName) } @@ -112,11 +101,6 @@ func (d *RegisteredModelDataSource) Read(ctx context.Context, req datasource.Rea modelInfo.Aliases, d = basetypes.NewListValueFrom(ctx, modelInfo.Aliases.ElementType(ctx), []catalog_tf.RegisteredModelAlias{}) resp.Diagnostics.Append(d...) } - var dd diag.Diagnostics - registeredModel.ModelInfo, dd = types.ListValueFrom(ctx, catalog_tf.RegisteredModelInfo{}.ToObjectType(ctx), []catalog_tf.RegisteredModelInfo{modelInfo}) - resp.Diagnostics.Append(dd...) - if resp.Diagnostics.HasError() { - return - } + registeredModel.ModelInfo = types.ListValueMust(catalog_tf.RegisteredModelInfo{}.Type(ctx), []attr.Value{modelInfo}) resp.Diagnostics.Append(resp.State.Set(ctx, registeredModel)...) } diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go index 315e5c4d9d..9e7ebff000 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go @@ -13,7 +13,6 @@ import ( "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -38,15 +37,6 @@ func (RegisteredModelVersionsData) GetComplexFieldTypes(context.Context) map[str } } -func (RegisteredModelVersionsData) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "full_name": types.StringType, - "model_versions": types.ListType{ElemType: catalog_tf.ModelVersionInfo{}.ToObjectType(ctx)}, - }, - } -} - func (d *RegisteredModelVersionsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = "databricks_registered_model_versions" } @@ -84,7 +74,7 @@ func (d *RegisteredModelVersionsDataSource) Read(ctx context.Context, req dataso resp.Diagnostics.AddError(fmt.Sprintf("failed to list model versions for registered model %s", modelFullName), err.Error()) return } - var tfModelVersions []catalog_tf.ModelVersionInfo + var tfModelVersions []attr.Value for _, modelVersionSdk := range modelVersions.ModelVersions { var modelVersion catalog_tf.ModelVersionInfo resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, modelVersionSdk, &modelVersion)...) @@ -93,11 +83,6 @@ func (d *RegisteredModelVersionsDataSource) Read(ctx context.Context, req dataso } tfModelVersions = append(tfModelVersions, modelVersion) } - var dd diag.Diagnostics - registeredModelVersions.ModelVersions, dd = types.ListValueFrom(ctx, catalog_tf.ModelVersionInfo{}.ToObjectType(ctx), tfModelVersions) - resp.Diagnostics.Append(dd...) - if resp.Diagnostics.HasError() { - return - } + registeredModelVersions.ModelVersions = types.ListValueMust(catalog_tf.ModelVersionInfo{}.Type(ctx), tfModelVersions) resp.Diagnostics.Append(resp.State.Set(ctx, registeredModelVersions)...) } diff --git a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go index 7dfa792c42..6fe6bc22a0 100644 --- a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go +++ b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go @@ -13,7 +13,6 @@ import ( "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/datasource" "github.com/hashicorp/terraform-plugin-framework/datasource/schema" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" ) @@ -37,14 +36,6 @@ func (ServingEndpointsData) GetComplexFieldTypes(context.Context) map[string]ref } } -func (ServingEndpointsData) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "endpoints": types.ListType{ElemType: serving_tf.ServingEndpoint{}.ToObjectType(ctx)}, - }, - } -} - func (d *ServingEndpointsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = "databricks_serving_endpoints" } @@ -84,7 +75,7 @@ func (d *ServingEndpointsDataSource) Read(ctx context.Context, req datasource.Re resp.Diagnostics.AddError("failed to list endpoints", err.Error()) return } - tfEndpoints := []serving_tf.ServingEndpoint{} + tfEndpoints := []attr.Value{} for _, endpoint := range endpointsInfoSdk { var endpointsInfo serving_tf.ServingEndpoint resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, endpoint, &endpointsInfo)...) @@ -93,11 +84,6 @@ func (d *ServingEndpointsDataSource) Read(ctx context.Context, req datasource.Re } tfEndpoints = append(tfEndpoints, endpointsInfo) } - var dd diag.Diagnostics - endpoints.Endpoints, dd = types.ListValueFrom(ctx, serving_tf.ServingEndpoint{}.ToObjectType(ctx), tfEndpoints) - resp.Diagnostics.Append(dd...) - if resp.Diagnostics.HasError() { - return - } + endpoints.Endpoints = types.ListValueMust(serving_tf.ServingEndpoint{}.Type(ctx), tfEndpoints) resp.Diagnostics.Append(resp.State.Set(ctx, endpoints)...) } diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index 4d83310999..e0cc33cc3a 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -19,7 +19,6 @@ import ( "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/int64planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" - "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) @@ -36,16 +35,11 @@ type ShareInfoExtended struct { } var _ pluginfwcommon.ComplexFieldTypeProvider = ShareInfoExtended{} -var _ pluginfwcommon.ObjectTypable = ShareInfoExtended{} func (s ShareInfoExtended) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return s.ShareInfo.GetComplexFieldTypes(ctx) } -func (s ShareInfoExtended) ToObjectType(ctx context.Context) types.ObjectType { - return s.ShareInfo.ToObjectType(ctx) -} - func matchOrder[T any, K comparable](target, reference []T, keyFunc func(T) K) { // Create a map to store the index positions of each key in the reference slice. orderMap := make(map[K]int) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 5c33043ae9..4073d29598 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -10,6 +10,7 @@ import ( tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" "github.com/hashicorp/terraform-plugin-framework-validators/listvalidator" + "github.com/hashicorp/terraform-plugin-framework/attr" dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/schema/validator" @@ -63,11 +64,7 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { if !ok { panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } - objectTypable, ok := v.Interface().(tfcommon.ObjectTypable) - if !ok { - panic(fmt.Errorf("object type not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) - } - objectType := objectTypable.ToObjectType(ctx) + objectType := tfcommon.NewObjectValuable(v.Interface()).Type(ctx).(types.ObjectType) attrType, ok := objectType.AttrTypes[fieldName] if !ok { panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) @@ -78,13 +75,12 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. // If new types are added there, they must also be added here to work properly. case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): + containerType := attrType.(attr.TypeWithElementType) switch value.(type) { case types.List: - scmAttr[fieldName] = ListAttributeBuilder{ElementType: attrType} + scmAttr[fieldName] = ListAttributeBuilder{ElementType: containerType.ElementType()} case types.Map: - scmAttr[fieldName] = MapAttributeBuilder{ElementType: attrType} - case types.Object: - panic(fmt.Errorf("object fields must correspond to a complex type, got %s. %s", fieldType.Name(), common.TerraformBugErrorMessage)) + scmAttr[fieldName] = MapAttributeBuilder{ElementType: containerType.ElementType()} } default: // The element type is a TFSDK type. Map fields are treated as MapNestedAttributes. For compatibility, diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go index 3faeef118c..6971ec965d 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go @@ -8,6 +8,7 @@ import ( "testing" "github.com/databricks/terraform-provider-databricks/common" + tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/tfsdk" "github.com/hashicorp/terraform-plugin-framework/types" @@ -81,15 +82,6 @@ type DummyNested struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } -func (DummyNested) ToObjectType(context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "enabled": types.BoolType, - }, - } -} - type TestNestedMapTfSdk struct { NestedMap types.Map `tfsdk:"nested_map" tf:"optional"` } @@ -100,7 +92,7 @@ func (TestNestedMapTfSdk) GetComplexFieldTypes(context.Context) map[string]refle } } -var dummyType = DummyNested{}.ToObjectType(context.Background()) +var dummyType = tfcommon.NewObjectValuable(DummyNested{}).Type(context.Background()).(types.ObjectType) var tests = []struct { name string @@ -175,14 +167,20 @@ func StructToSchemaConversionTestCase(t *testing.T, description string, testStru Schema: scm, } // Assert we can properly set the state, this means the schema and the struct are consistent. - assert.True(t, !state.Set(context.Background(), testStruct).HasError(), fmt.Sprintf("ResourceStructToSchema - %s", description)) + d := state.Set(context.Background(), testStruct) + if d.HasError() { + t.Errorf("ResourceStructToSchema - %s: %s", description, tfcommon.DiagToString(d)) + } data_scm := DataSourceStructToSchema(context.Background(), testStruct, nil) data_state := tfsdk.State{ Schema: data_scm, } // Assert we can properly set the state, this means the schema and the struct are consistent. - assert.True(t, !data_state.Set(context.Background(), testStruct).HasError(), fmt.Sprintf("DataSourceStructToSchema - %s", description)) + d = data_state.Set(context.Background(), testStruct) + if d.HasError() { + t.Errorf("DataSourceStructToSchema - %s: %s", description, tfcommon.DiagToString(d)) + } } func TestStructToSchemaConversion(t *testing.T) { diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index b8fec23ad5..cac158c410 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -12,11 +12,15 @@ package apps_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type App struct { @@ -82,19 +86,66 @@ func (a App) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToObjectType returns the representation of App in the Terraform plugin framework type -// system. -func (a App) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = App{} + +// Equal implements basetypes.ObjectValuable. +func (o App) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o App) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o App) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o App) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o App) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o App) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o App) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.ToObjectType(ctx), + ElemType: AppDeployment{}.Type(ctx), }, "app_status": basetypes.ListType{ - ElemType: ApplicationStatus{}.ToObjectType(ctx), + ElemType: ApplicationStatus{}.Type(ctx), }, "compute_status": basetypes.ListType{ - ElemType: ComputeStatus{}.ToObjectType(ctx), + ElemType: ComputeStatus{}.Type(ctx), }, "create_time": types.StringType, "creator": types.StringType, @@ -102,10 +153,10 @@ func (a App) ToObjectType(ctx context.Context) types.ObjectType { "description": types.StringType, "name": types.StringType, "pending_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.ToObjectType(ctx), + ElemType: AppDeployment{}.Type(ctx), }, "resources": basetypes.ListType{ - ElemType: AppResource{}.ToObjectType(ctx), + ElemType: AppResource{}.Type(ctx), }, "service_principal_client_id": types.StringType, "service_principal_id": types.Int64Type, @@ -145,9 +196,56 @@ func (a AppAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppAccessControlRequest in the Terraform plugin framework type -// system. -func (a AppAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -190,13 +288,60 @@ func (a AppAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of AppAccessControlResponse in the Terraform plugin framework type -// system. -func (a AppAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: AppPermission{}.ToObjectType(ctx), + ElemType: AppPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -251,21 +396,68 @@ func (a AppDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of AppDeployment in the Terraform plugin framework type -// system. -func (a AppDeployment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppDeployment{} + +// Equal implements basetypes.ObjectValuable. +func (o AppDeployment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppDeployment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppDeployment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppDeployment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppDeployment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppDeployment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppDeployment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, "creator": types.StringType, "deployment_artifacts": basetypes.ListType{ - ElemType: AppDeploymentArtifacts{}.ToObjectType(ctx), + ElemType: AppDeploymentArtifacts{}.Type(ctx), }, "deployment_id": types.StringType, "mode": types.StringType, "source_code_path": types.StringType, "status": basetypes.ListType{ - ElemType: AppDeploymentStatus{}.ToObjectType(ctx), + ElemType: AppDeploymentStatus{}.Type(ctx), }, "update_time": types.StringType, }, @@ -295,9 +487,56 @@ func (a AppDeploymentArtifacts) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppDeploymentArtifacts in the Terraform plugin framework type -// system. -func (a AppDeploymentArtifacts) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppDeploymentArtifacts{} + +// Equal implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppDeploymentArtifacts) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "source_code_path": types.StringType, @@ -329,9 +568,56 @@ func (a AppDeploymentStatus) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppDeploymentStatus in the Terraform plugin framework type -// system. -func (a AppDeploymentStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppDeploymentStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppDeploymentStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -367,9 +653,56 @@ func (a AppPermission) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of AppPermission in the Terraform plugin framework type -// system. -func (a AppPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o AppPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -408,13 +741,60 @@ func (a AppPermissions) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of AppPermissions in the Terraform plugin framework type -// system. -func (a AppPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o AppPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AppAccessControlResponse{}.ToObjectType(ctx), + ElemType: AppAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -445,9 +825,56 @@ func (a AppPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppPermissionsDescription in the Terraform plugin framework type -// system. -func (a AppPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -481,13 +908,60 @@ func (a AppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of AppPermissionsRequest in the Terraform plugin framework type -// system. -func (a AppPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AppAccessControlRequest{}.ToObjectType(ctx), + ElemType: AppAccessControlRequest{}.Type(ctx), }, "app_name": types.StringType, }, @@ -531,24 +1005,71 @@ func (a AppResource) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of AppResource in the Terraform plugin framework type -// system. -func (a AppResource) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppResource{} + +// Equal implements basetypes.ObjectValuable. +func (o AppResource) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppResource) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppResource) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppResource) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppResource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppResource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppResource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, "job": basetypes.ListType{ - ElemType: AppResourceJob{}.ToObjectType(ctx), + ElemType: AppResourceJob{}.Type(ctx), }, "name": types.StringType, "secret": basetypes.ListType{ - ElemType: AppResourceSecret{}.ToObjectType(ctx), + ElemType: AppResourceSecret{}.Type(ctx), }, "serving_endpoint": basetypes.ListType{ - ElemType: AppResourceServingEndpoint{}.ToObjectType(ctx), + ElemType: AppResourceServingEndpoint{}.Type(ctx), }, "sql_warehouse": basetypes.ListType{ - ElemType: AppResourceSqlWarehouse{}.ToObjectType(ctx), + ElemType: AppResourceSqlWarehouse{}.Type(ctx), }, }, } @@ -579,9 +1100,56 @@ func (a AppResourceJob) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppResourceJob in the Terraform plugin framework type -// system. -func (a AppResourceJob) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppResourceJob{} + +// Equal implements basetypes.ObjectValuable. +func (o AppResourceJob) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppResourceJob) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppResourceJob) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppResourceJob) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppResourceJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppResourceJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppResourceJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -617,9 +1185,56 @@ func (a AppResourceSecret) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppResourceSecret in the Terraform plugin framework type -// system. -func (a AppResourceSecret) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppResourceSecret{} + +// Equal implements basetypes.ObjectValuable. +func (o AppResourceSecret) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppResourceSecret) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppResourceSecret) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppResourceSecret) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppResourceSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppResourceSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppResourceSecret) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -654,9 +1269,56 @@ func (a AppResourceServingEndpoint) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppResourceServingEndpoint in the Terraform plugin framework type -// system. -func (a AppResourceServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppResourceServingEndpoint{} + +// Equal implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppResourceServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -690,9 +1352,56 @@ func (a AppResourceSqlWarehouse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of AppResourceSqlWarehouse in the Terraform plugin framework type -// system. -func (a AppResourceSqlWarehouse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AppResourceSqlWarehouse{} + +// Equal implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AppResourceSqlWarehouse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -725,9 +1434,56 @@ func (a ApplicationStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ApplicationStatus in the Terraform plugin framework type -// system. -func (a ApplicationStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ApplicationStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o ApplicationStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ApplicationStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ApplicationStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ApplicationStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ApplicationStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ApplicationStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ApplicationStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -760,9 +1516,56 @@ func (a ComputeStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ComputeStatus in the Terraform plugin framework type -// system. -func (a ComputeStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ComputeStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o ComputeStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ComputeStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ComputeStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ComputeStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ComputeStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ComputeStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ComputeStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -797,13 +1600,60 @@ func (a CreateAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of CreateAppDeploymentRequest in the Terraform plugin framework type -// system. -func (a CreateAppDeploymentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateAppDeploymentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateAppDeploymentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.ToObjectType(ctx), + ElemType: AppDeployment{}.Type(ctx), }, "app_name": types.StringType, }, @@ -834,13 +1684,60 @@ func (a CreateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of CreateAppRequest in the Terraform plugin framework type -// system. -func (a CreateAppRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateAppRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateAppRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateAppRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateAppRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateAppRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app": basetypes.ListType{ - ElemType: App{}.ToObjectType(ctx), + ElemType: App{}.Type(ctx), }, }, } @@ -869,9 +1766,56 @@ func (a DeleteAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAppRequest in the Terraform plugin framework type -// system. -func (a DeleteAppRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAppRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAppRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAppRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAppRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAppRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -904,9 +1848,56 @@ func (a GetAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAppDeploymentRequest in the Terraform plugin framework type -// system. -func (a GetAppDeploymentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAppDeploymentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAppDeploymentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -938,9 +1929,56 @@ func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAppPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetAppPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAppPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -972,13 +2010,60 @@ func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of GetAppPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetAppPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAppPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAppPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: AppPermissionsDescription{}.ToObjectType(ctx), + ElemType: AppPermissionsDescription{}.Type(ctx), }, }, } @@ -1007,9 +2092,56 @@ func (a GetAppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAppPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetAppPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAppPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAppPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -1040,9 +2172,56 @@ func (a GetAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAppRequest in the Terraform plugin framework type -// system. -func (a GetAppRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAppRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAppRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAppRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAppRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAppRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1078,9 +2257,56 @@ func (a ListAppDeploymentsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAppDeploymentsRequest in the Terraform plugin framework type -// system. -func (a ListAppDeploymentsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAppDeploymentsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAppDeploymentsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_name": types.StringType, @@ -1116,13 +2342,60 @@ func (a ListAppDeploymentsResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListAppDeploymentsResponse in the Terraform plugin framework type -// system. -func (a ListAppDeploymentsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAppDeploymentsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAppDeploymentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_deployments": basetypes.ListType{ - ElemType: AppDeployment{}.ToObjectType(ctx), + ElemType: AppDeployment{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -1155,9 +2428,56 @@ func (a ListAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAppsRequest in the Terraform plugin framework type -// system. -func (a ListAppsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAppsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAppsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAppsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAppsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAppsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAppsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAppsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAppsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -1191,13 +2511,60 @@ func (a ListAppsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ListAppsResponse in the Terraform plugin framework type -// system. -func (a ListAppsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAppsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAppsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAppsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAppsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAppsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAppsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAppsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAppsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: App{}.ToObjectType(ctx), + ElemType: App{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -1226,9 +2593,56 @@ func (a StartAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of StartAppRequest in the Terraform plugin framework type -// system. -func (a StartAppRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartAppRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o StartAppRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartAppRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartAppRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartAppRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1258,9 +2672,56 @@ func (a StopAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of StopAppRequest in the Terraform plugin framework type -// system. -func (a StopAppRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StopAppRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o StopAppRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StopAppRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StopAppRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StopAppRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StopAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StopAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StopAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1295,15 +2756,67 @@ func (a UpdateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of UpdateAppRequest in the Terraform plugin framework type -// system. -func (a UpdateAppRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAppRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAppRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAppRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAppRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAppRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app": basetypes.ListType{ - ElemType: App{}.ToObjectType(ctx), + ElemType: App{}.Type(ctx), }, "name": types.StringType, }, } } + +// Permission level + +// Permission to grant on the secret scope. Supported permissions are: "READ", +// "WRITE", "MANAGE". diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index f67766303a..2d1722662c 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -12,12 +12,16 @@ package billing_tf import ( "context" + "fmt" "io" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type ActionConfiguration struct { @@ -46,9 +50,56 @@ func (a ActionConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of ActionConfiguration in the Terraform plugin framework type -// system. -func (a ActionConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ActionConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o ActionConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ActionConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ActionConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ActionConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ActionConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ActionConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ActionConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_configuration_id": types.StringType, @@ -96,13 +147,60 @@ func (a AlertConfiguration) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of AlertConfiguration in the Terraform plugin framework type -// system. -func (a AlertConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_configurations": basetypes.ListType{ - ElemType: ActionConfiguration{}.ToObjectType(ctx), + ElemType: ActionConfiguration{}.Type(ctx), }, "alert_configuration_id": types.StringType, "quantity_threshold": types.StringType, @@ -154,20 +252,67 @@ func (a BudgetConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of BudgetConfiguration in the Terraform plugin framework type -// system. -func (a BudgetConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BudgetConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o BudgetConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BudgetConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BudgetConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BudgetConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BudgetConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BudgetConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "alert_configurations": basetypes.ListType{ - ElemType: AlertConfiguration{}.ToObjectType(ctx), + ElemType: AlertConfiguration{}.Type(ctx), }, "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.ToObjectType(ctx), + ElemType: BudgetConfigurationFilter{}.Type(ctx), }, "update_time": types.Int64Type, }, @@ -203,16 +348,63 @@ func (a BudgetConfigurationFilter) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of BudgetConfigurationFilter in the Terraform plugin framework type -// system. -func (a BudgetConfigurationFilter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BudgetConfigurationFilter{} + +// Equal implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "tags": basetypes.ListType{ - ElemType: BudgetConfigurationFilterTagClause{}.ToObjectType(ctx), + ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx), }, "workspace_id": basetypes.ListType{ - ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.ToObjectType(ctx), + ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx), }, }, } @@ -243,9 +435,56 @@ func (a BudgetConfigurationFilterClause) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of BudgetConfigurationFilterClause in the Terraform plugin framework type -// system. -func (a BudgetConfigurationFilterClause) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BudgetConfigurationFilterClause{} + +// Equal implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, @@ -281,14 +520,61 @@ func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of BudgetConfigurationFilterTagClause in the Terraform plugin framework type -// system. -func (a BudgetConfigurationFilterTagClause) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BudgetConfigurationFilterTagClause{} + +// Equal implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterTagClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, "value": basetypes.ListType{ - ElemType: BudgetConfigurationFilterClause{}.ToObjectType(ctx), + ElemType: BudgetConfigurationFilterClause{}.Type(ctx), }, }, } @@ -319,9 +605,56 @@ func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes(ctx con } } -// ToObjectType returns the representation of BudgetConfigurationFilterWorkspaceIdClause in the Terraform plugin framework type -// system. -func (a BudgetConfigurationFilterWorkspaceIdClause) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BudgetConfigurationFilterWorkspaceIdClause{} + +// Equal implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BudgetConfigurationFilterWorkspaceIdClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, @@ -359,9 +692,56 @@ func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateBillingUsageDashboardRequest in the Terraform plugin framework type -// system. -func (a CreateBillingUsageDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBillingUsageDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_type": types.StringType, @@ -392,9 +772,56 @@ func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateBillingUsageDashboardResponse in the Terraform plugin framework type -// system. -func (a CreateBillingUsageDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBillingUsageDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBillingUsageDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -437,18 +864,65 @@ func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of CreateBudgetConfigurationBudget in the Terraform plugin framework type -// system. -func (a CreateBudgetConfigurationBudget) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBudgetConfigurationBudget{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "alert_configurations": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.ToObjectType(ctx), + ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx), }, "display_name": types.StringType, "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.ToObjectType(ctx), + ElemType: BudgetConfigurationFilter{}.Type(ctx), }, }, } @@ -478,9 +952,56 @@ func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldType return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateBudgetConfigurationBudgetActionConfigurations in the Terraform plugin framework type -// system. -func (a CreateBudgetConfigurationBudgetActionConfigurations) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBudgetConfigurationBudgetActionConfigurations{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetActionConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_type": types.StringType, @@ -525,13 +1046,60 @@ func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes } } -// ToObjectType returns the representation of CreateBudgetConfigurationBudgetAlertConfigurations in the Terraform plugin framework type -// system. -func (a CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBudgetConfigurationBudgetAlertConfigurations{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationBudgetAlertConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action_configurations": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.ToObjectType(ctx), + ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx), }, "quantity_threshold": types.StringType, "quantity_type": types.StringType, @@ -565,13 +1133,60 @@ func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of CreateBudgetConfigurationRequest in the Terraform plugin framework type -// system. -func (a CreateBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBudgetConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudget{}.ToObjectType(ctx), + ElemType: CreateBudgetConfigurationBudget{}.Type(ctx), }, }, } @@ -601,13 +1216,60 @@ func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of CreateBudgetConfigurationResponse in the Terraform plugin framework type -// system. -func (a CreateBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateBudgetConfigurationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToObjectType(ctx), + ElemType: BudgetConfiguration{}.Type(ctx), }, }, } @@ -704,9 +1366,56 @@ func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of CreateLogDeliveryConfigurationParams in the Terraform plugin framework type -// system. -func (a CreateLogDeliveryConfigurationParams) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateLogDeliveryConfigurationParams{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateLogDeliveryConfigurationParams) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config_name": types.StringType, @@ -747,9 +1456,56 @@ func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteBudgetConfigurationRequest in the Terraform plugin framework type -// system. -func (a DeleteBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteBudgetConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_id": types.StringType, @@ -777,9 +1533,56 @@ func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteBudgetConfigurationResponse in the Terraform plugin framework type -// system. -func (a DeleteBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteBudgetConfigurationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -816,10 +1619,57 @@ func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DownloadRequest in the Terraform plugin framework type -// system. -func (a DownloadRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DownloadRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DownloadRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DownloadRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DownloadRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DownloadRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DownloadRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DownloadRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DownloadRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_month": types.StringType, "personal_data": types.BoolType, @@ -849,9 +1699,56 @@ func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of DownloadResponse in the Terraform plugin framework type -// system. -func (a DownloadResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DownloadResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DownloadResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DownloadResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DownloadResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DownloadResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DownloadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DownloadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DownloadResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.ObjectType{}, @@ -887,9 +1784,56 @@ func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetBillingUsageDashboardRequest in the Terraform plugin framework type -// system. -func (a GetBillingUsageDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetBillingUsageDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_type": types.StringType, @@ -922,9 +1866,56 @@ func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetBillingUsageDashboardResponse in the Terraform plugin framework type -// system. -func (a GetBillingUsageDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetBillingUsageDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetBillingUsageDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -956,9 +1947,56 @@ func (a GetBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetBudgetConfigurationRequest in the Terraform plugin framework type -// system. -func (a GetBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetBudgetConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_id": types.StringType, @@ -989,13 +2027,60 @@ func (a GetBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of GetBudgetConfigurationResponse in the Terraform plugin framework type -// system. -func (a GetBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetBudgetConfigurationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToObjectType(ctx), + ElemType: BudgetConfiguration{}.Type(ctx), }, }, } @@ -1024,9 +2109,56 @@ func (a GetLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetLogDeliveryRequest in the Terraform plugin framework type -// system. -func (a GetLogDeliveryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetLogDeliveryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetLogDeliveryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration_id": types.StringType, @@ -1059,9 +2191,56 @@ func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListBudgetConfigurationsRequest in the Terraform plugin framework type -// system. -func (a ListBudgetConfigurationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListBudgetConfigurationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -1095,13 +2274,60 @@ func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of ListBudgetConfigurationsResponse in the Terraform plugin framework type -// system. -func (a ListBudgetConfigurationsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListBudgetConfigurationsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListBudgetConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budgets": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToObjectType(ctx), + ElemType: BudgetConfiguration{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -1135,9 +2361,56 @@ func (a ListLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListLogDeliveryRequest in the Terraform plugin framework type -// system. -func (a ListLogDeliveryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListLogDeliveryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListLogDeliveryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials_id": types.StringType, @@ -1251,9 +2524,56 @@ func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of LogDeliveryConfiguration in the Terraform plugin framework type -// system. -func (a LogDeliveryConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogDeliveryConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, @@ -1264,7 +2584,7 @@ func (a LogDeliveryConfiguration) ToObjectType(ctx context.Context) types.Object "delivery_path_prefix": types.StringType, "delivery_start_time": types.StringType, "log_delivery_status": basetypes.ListType{ - ElemType: LogDeliveryStatus{}.ToObjectType(ctx), + ElemType: LogDeliveryStatus{}.Type(ctx), }, "log_type": types.StringType, "output_format": types.StringType, @@ -1318,9 +2638,56 @@ func (a LogDeliveryStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogDeliveryStatus in the Terraform plugin framework type -// system. -func (a LogDeliveryStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogDeliveryStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogDeliveryStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_attempt_time": types.StringType, @@ -1351,9 +2718,56 @@ func (a PatchStatusResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of PatchStatusResponse in the Terraform plugin framework type -// system. -func (a PatchStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PatchStatusResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PatchStatusResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PatchStatusResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PatchStatusResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PatchStatusResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PatchStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PatchStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PatchStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1396,19 +2810,66 @@ func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of UpdateBudgetConfigurationBudget in the Terraform plugin framework type -// system. -func (a UpdateBudgetConfigurationBudget) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateBudgetConfigurationBudget{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "alert_configurations": basetypes.ListType{ - ElemType: AlertConfiguration{}.ToObjectType(ctx), + ElemType: AlertConfiguration{}.Type(ctx), }, "budget_configuration_id": types.StringType, "display_name": types.StringType, "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.ToObjectType(ctx), + ElemType: BudgetConfigurationFilter{}.Type(ctx), }, }, } @@ -1441,13 +2902,60 @@ func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of UpdateBudgetConfigurationRequest in the Terraform plugin framework type -// system. -func (a UpdateBudgetConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateBudgetConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: UpdateBudgetConfigurationBudget{}.ToObjectType(ctx), + ElemType: UpdateBudgetConfigurationBudget{}.Type(ctx), }, "budget_id": types.StringType, }, @@ -1478,13 +2986,60 @@ func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of UpdateBudgetConfigurationResponse in the Terraform plugin framework type -// system. -func (a UpdateBudgetConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateBudgetConfigurationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.ToObjectType(ctx), + ElemType: BudgetConfiguration{}.Type(ctx), }, }, } @@ -1518,9 +3073,56 @@ func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateLogDeliveryConfigurationStatusRequest in the Terraform plugin framework type -// system. -func (a UpdateLogDeliveryConfigurationStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateLogDeliveryConfigurationStatusRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateLogDeliveryConfigurationStatusRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration_id": types.StringType, @@ -1552,13 +3154,60 @@ func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes(ctx context. } } -// ToObjectType returns the representation of WrappedCreateLogDeliveryConfiguration in the Terraform plugin framework type -// system. -func (a WrappedCreateLogDeliveryConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WrappedCreateLogDeliveryConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WrappedCreateLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration": basetypes.ListType{ - ElemType: CreateLogDeliveryConfigurationParams{}.ToObjectType(ctx), + ElemType: CreateLogDeliveryConfigurationParams{}.Type(ctx), }, }, } @@ -1587,13 +3236,60 @@ func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of WrappedLogDeliveryConfiguration in the Terraform plugin framework type -// system. -func (a WrappedLogDeliveryConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WrappedLogDeliveryConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configuration": basetypes.ListType{ - ElemType: LogDeliveryConfiguration{}.ToObjectType(ctx), + ElemType: LogDeliveryConfiguration{}.Type(ctx), }, }, } @@ -1622,14 +3318,101 @@ func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of WrappedLogDeliveryConfigurations in the Terraform plugin framework type -// system. -func (a WrappedLogDeliveryConfigurations) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WrappedLogDeliveryConfigurations{} + +// Equal implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WrappedLogDeliveryConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_delivery_configurations": basetypes.ListType{ - ElemType: LogDeliveryConfiguration{}.ToObjectType(ctx), + ElemType: LogDeliveryConfiguration{}.Type(ctx), }, }, } } + +// The status string for log delivery. Possible values are: * `CREATED`: There +// were no log delivery attempts since the config was created. * `SUCCEEDED`: +// The latest attempt of log delivery has succeeded completely. * +// `USER_FAILURE`: The latest attempt of log delivery failed because of +// misconfiguration of customer provided permissions on role or storage. * +// `SYSTEM_FAILURE`: The latest attempt of log delivery failed because of an +// Databricks internal error. Contact support if it doesn't go away soon. * +// `NOT_FOUND`: The log delivery status as the configuration has been disabled +// since the release of this feature or there are no workspaces in the account. + +// Status of log delivery configuration. Set to `ENABLED` (enabled) or +// `DISABLED` (disabled). Defaults to `ENABLED`. You can [enable or disable the +// configuration](#operation/patch-log-delivery-config-status) later. Deletion +// of a configuration is not supported, so disable a log delivery configuration +// that is no longer needed. + +// Log delivery type. Supported values are: +// +// * `BILLABLE_USAGE` — Configure [billable usage log delivery]. For the CSV +// schema, see the [View billable usage]. +// +// * `AUDIT_LOGS` — Configure [audit log delivery]. For the JSON schema, see +// [Configure audit logging] +// +// [Configure audit logging]: https://docs.databricks.com/administration-guide/account-settings/audit-logs.html +// [View billable usage]: https://docs.databricks.com/administration-guide/account-settings/usage.html +// [audit log delivery]: https://docs.databricks.com/administration-guide/account-settings/audit-logs.html +// [billable usage log delivery]: https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html + +// The file type of log delivery. +// +// * If `log_type` is `BILLABLE_USAGE`, this value must be `CSV`. Only the CSV +// (comma-separated values) format is supported. For the schema, see the [View +// billable usage] * If `log_type` is `AUDIT_LOGS`, this value must be `JSON`. +// Only the JSON (JavaScript Object Notation) format is supported. For the +// schema, see the [Configuring audit logs]. +// +// [Configuring audit logs]: https://docs.databricks.com/administration-guide/account-settings/audit-logs.html +// [View billable usage]: https://docs.databricks.com/administration-guide/account-settings/usage.html diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 6d9037c078..c7f33168a4 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -12,11 +12,15 @@ package catalog_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AccountsCreateMetastore struct { @@ -42,13 +46,60 @@ func (a AccountsCreateMetastore) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of AccountsCreateMetastore in the Terraform plugin framework type -// system. -func (a AccountsCreateMetastore) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsCreateMetastore{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsCreateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_info": basetypes.ListType{ - ElemType: CreateMetastore{}.ToObjectType(ctx), + ElemType: CreateMetastore{}.Type(ctx), }, }, } @@ -81,13 +132,60 @@ func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of AccountsCreateMetastoreAssignment in the Terraform plugin framework type -// system. -func (a AccountsCreateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsCreateMetastoreAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsCreateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_assignment": basetypes.ListType{ - ElemType: CreateMetastoreAssignment{}.ToObjectType(ctx), + ElemType: CreateMetastoreAssignment{}.Type(ctx), }, "metastore_id": types.StringType, "workspace_id": types.Int64Type, @@ -120,13 +218,60 @@ func (a AccountsCreateStorageCredential) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of AccountsCreateStorageCredential in the Terraform plugin framework type -// system. -func (a AccountsCreateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsCreateStorageCredential{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsCreateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_info": basetypes.ListType{ - ElemType: CreateStorageCredential{}.ToObjectType(ctx), + ElemType: CreateStorageCredential{}.Type(ctx), }, "metastore_id": types.StringType, }, @@ -156,13 +301,60 @@ func (a AccountsMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of AccountsMetastoreAssignment in the Terraform plugin framework type -// system. -func (a AccountsMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsMetastoreAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_assignment": basetypes.ListType{ - ElemType: MetastoreAssignment{}.ToObjectType(ctx), + ElemType: MetastoreAssignment{}.Type(ctx), }, }, } @@ -191,13 +383,60 @@ func (a AccountsMetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of AccountsMetastoreInfo in the Terraform plugin framework type -// system. -func (a AccountsMetastoreInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsMetastoreInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsMetastoreInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_info": basetypes.ListType{ - ElemType: MetastoreInfo{}.ToObjectType(ctx), + ElemType: MetastoreInfo{}.Type(ctx), }, }, } @@ -226,13 +465,60 @@ func (a AccountsStorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of AccountsStorageCredentialInfo in the Terraform plugin framework type -// system. -func (a AccountsStorageCredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsStorageCredentialInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsStorageCredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_info": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.ToObjectType(ctx), + ElemType: StorageCredentialInfo{}.Type(ctx), }, }, } @@ -264,14 +550,61 @@ func (a AccountsUpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of AccountsUpdateMetastore in the Terraform plugin framework type -// system. -func (a AccountsUpdateMetastore) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsUpdateMetastore{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, "metastore_info": basetypes.ListType{ - ElemType: UpdateMetastore{}.ToObjectType(ctx), + ElemType: UpdateMetastore{}.Type(ctx), }, }, } @@ -304,13 +637,60 @@ func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of AccountsUpdateMetastoreAssignment in the Terraform plugin framework type -// system. -func (a AccountsUpdateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsUpdateMetastoreAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsUpdateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_assignment": basetypes.ListType{ - ElemType: UpdateMetastoreAssignment{}.ToObjectType(ctx), + ElemType: UpdateMetastoreAssignment{}.Type(ctx), }, "metastore_id": types.StringType, "workspace_id": types.Int64Type, @@ -345,13 +725,60 @@ func (a AccountsUpdateStorageCredential) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of AccountsUpdateStorageCredential in the Terraform plugin framework type -// system. -func (a AccountsUpdateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccountsUpdateStorageCredential{} + +// Equal implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccountsUpdateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_info": basetypes.ListType{ - ElemType: UpdateStorageCredential{}.ToObjectType(ctx), + ElemType: UpdateStorageCredential{}.Type(ctx), }, "metastore_id": types.StringType, "storage_credential_name": types.StringType, @@ -389,13 +816,60 @@ func (a ArtifactAllowlistInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ArtifactAllowlistInfo in the Terraform plugin framework type -// system. -func (a ArtifactAllowlistInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ArtifactAllowlistInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ArtifactAllowlistInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_matchers": basetypes.ListType{ - ElemType: ArtifactMatcher{}.ToObjectType(ctx), + ElemType: ArtifactMatcher{}.Type(ctx), }, "created_at": types.Int64Type, "created_by": types.StringType, @@ -428,9 +902,56 @@ func (a ArtifactMatcher) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ArtifactMatcher in the Terraform plugin framework type -// system. -func (a ArtifactMatcher) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ArtifactMatcher{} + +// Equal implements basetypes.ObjectValuable. +func (o ArtifactMatcher) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ArtifactMatcher) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ArtifactMatcher) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ArtifactMatcher) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ArtifactMatcher) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ArtifactMatcher) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ArtifactMatcher) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact": types.StringType, @@ -459,9 +980,56 @@ func (a AssignResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of AssignResponse in the Terraform plugin framework type -// system. -func (a AssignResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AssignResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AssignResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AssignResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AssignResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AssignResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AssignResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AssignResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AssignResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -499,9 +1067,56 @@ func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of AwsCredentials in the Terraform plugin framework type -// system. -func (a AwsCredentials) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsCredentials{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsCredentials) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsCredentials) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsCredentials) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsCredentials) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_key_id": types.StringType, @@ -542,9 +1157,56 @@ func (a AwsIamRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of AwsIamRole in the Terraform plugin framework type -// system. -func (a AwsIamRole) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsIamRole{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsIamRole) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsIamRole) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsIamRole) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsIamRole) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsIamRole) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsIamRole) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsIamRole) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_id": types.StringType, @@ -576,9 +1238,56 @@ func (a AwsIamRoleRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of AwsIamRoleRequest in the Terraform plugin framework type -// system. -func (a AwsIamRoleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsIamRoleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsIamRoleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "role_arn": types.StringType, @@ -614,9 +1323,56 @@ func (a AwsIamRoleResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of AwsIamRoleResponse in the Terraform plugin framework type -// system. -func (a AwsIamRoleResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsIamRoleResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsIamRoleResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_id": types.StringType, @@ -652,9 +1408,56 @@ func (a AzureActiveDirectoryToken) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureActiveDirectoryToken in the Terraform plugin framework type -// system. -func (a AzureActiveDirectoryToken) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureActiveDirectoryToken{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureActiveDirectoryToken) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aad_token": types.StringType, @@ -699,10 +1502,57 @@ func (a AzureManagedIdentity) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureManagedIdentity in the Terraform plugin framework type -// system. -func (a AzureManagedIdentity) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureManagedIdentity{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureManagedIdentity) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_connector_id": types.StringType, "credential_id": types.StringType, @@ -742,9 +1592,56 @@ func (a AzureManagedIdentityRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureManagedIdentityRequest in the Terraform plugin framework type -// system. -func (a AzureManagedIdentityRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureManagedIdentityRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureManagedIdentityRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_connector_id": types.StringType, @@ -786,9 +1683,56 @@ func (a AzureManagedIdentityResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureManagedIdentityResponse in the Terraform plugin framework type -// system. -func (a AzureManagedIdentityResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureManagedIdentityResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureManagedIdentityResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_connector_id": types.StringType, @@ -827,9 +1771,56 @@ func (a AzureServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureServicePrincipal in the Terraform plugin framework type -// system. -func (a AzureServicePrincipal) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureServicePrincipal{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureServicePrincipal) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "application_id": types.StringType, @@ -863,9 +1854,56 @@ func (a AzureUserDelegationSas) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureUserDelegationSas in the Terraform plugin framework type -// system. -func (a AzureUserDelegationSas) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureUserDelegationSas{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureUserDelegationSas) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sas_token": types.StringType, @@ -898,9 +1936,56 @@ func (a CancelRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelRefreshRequest in the Terraform plugin framework type -// system. -func (a CancelRefreshRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelRefreshRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelRefreshRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "refresh_id": types.StringType, @@ -929,9 +2014,56 @@ func (a CancelRefreshResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelRefreshResponse in the Terraform plugin framework type -// system. -func (a CancelRefreshResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelRefreshResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelRefreshResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1017,9 +2149,56 @@ func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of CatalogInfo in the Terraform plugin framework type -// system. -func (a CatalogInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CatalogInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o CatalogInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CatalogInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CatalogInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CatalogInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CatalogInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CatalogInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CatalogInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "browse_only": types.BoolType, @@ -1029,7 +2208,7 @@ func (a CatalogInfo) ToObjectType(ctx context.Context) types.ObjectType { "created_at": types.Int64Type, "created_by": types.StringType, "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.ToObjectType(ctx), + ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), }, "enable_predictive_optimization": types.StringType, "full_name": types.StringType, @@ -1045,7 +2224,7 @@ func (a CatalogInfo) ToObjectType(ctx context.Context) types.ObjectType { }, "provider_name": types.StringType, "provisioning_info": basetypes.ListType{ - ElemType: ProvisioningInfo{}.ToObjectType(ctx), + ElemType: ProvisioningInfo{}.Type(ctx), }, "securable_kind": types.StringType, "securable_type": types.StringType, @@ -1084,9 +2263,56 @@ func (a CloudflareApiToken) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of CloudflareApiToken in the Terraform plugin framework type -// system. -func (a CloudflareApiToken) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CloudflareApiToken{} + +// Equal implements basetypes.ObjectValuable. +func (o CloudflareApiToken) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CloudflareApiToken) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CloudflareApiToken) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CloudflareApiToken) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CloudflareApiToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CloudflareApiToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CloudflareApiToken) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_key_id": types.StringType, @@ -1142,14 +2368,61 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of ColumnInfo in the Terraform plugin framework type -// system. -func (a ColumnInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ColumnInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ColumnInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ColumnInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ColumnInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ColumnInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ColumnInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ColumnInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ColumnInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "mask": basetypes.ListType{ - ElemType: ColumnMask{}.ToObjectType(ctx), + ElemType: ColumnMask{}.Type(ctx), }, "name": types.StringType, "nullable": types.BoolType, @@ -1194,9 +2467,56 @@ func (a ColumnMask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of ColumnMask in the Terraform plugin framework type -// system. -func (a ColumnMask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ColumnMask{} + +// Equal implements basetypes.ObjectValuable. +func (o ColumnMask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ColumnMask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ColumnMask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ColumnMask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ColumnMask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ColumnMask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ColumnMask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_name": types.StringType, @@ -1270,9 +2590,56 @@ func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ConnectionInfo in the Terraform plugin framework type -// system. -func (a ConnectionInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ConnectionInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ConnectionInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ConnectionInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ConnectionInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ConnectionInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ConnectionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ConnectionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ConnectionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1292,7 +2659,7 @@ func (a ConnectionInfo) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "provisioning_info": basetypes.ListType{ - ElemType: ProvisioningInfo{}.ToObjectType(ctx), + ElemType: ProvisioningInfo{}.Type(ctx), }, "read_only": types.BoolType, "securable_kind": types.StringType, @@ -1337,13 +2704,60 @@ func (a ContinuousUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ContinuousUpdateStatus in the Terraform plugin framework type -// system. -func (a ContinuousUpdateStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ContinuousUpdateStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ContinuousUpdateStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "initial_pipeline_sync_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.ToObjectType(ctx), + ElemType: PipelineProgress{}.Type(ctx), }, "last_processed_commit_version": types.Int64Type, "timestamp": types.StringType, @@ -1393,9 +2807,56 @@ func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of CreateCatalog in the Terraform plugin framework type -// system. -func (a CreateCatalog) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCatalog{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCatalog) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCatalog) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCatalog) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCatalog) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCatalog) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCatalog) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCatalog) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1450,9 +2911,56 @@ func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of CreateConnection in the Terraform plugin framework type -// system. -func (a CreateConnection) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateConnection{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateConnection) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateConnection) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateConnection) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateConnection) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateConnection) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateConnection) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateConnection) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1516,23 +3024,70 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of CreateCredentialRequest in the Terraform plugin framework type -// system. -func (a CreateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToObjectType(ctx), + ElemType: AwsIamRole{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToObjectType(ctx), + ElemType: AzureManagedIdentity{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "comment": types.StringType, "gcp_service_account_key": basetypes.ListType{ - ElemType: GcpServiceAccountKey{}.ToObjectType(ctx), + ElemType: GcpServiceAccountKey{}.Type(ctx), }, "name": types.StringType, "purpose": types.StringType, @@ -1585,16 +3140,63 @@ func (a CreateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CreateExternalLocation in the Terraform plugin framework type -// system. -func (a CreateExternalLocation) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExternalLocation{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExternalLocation) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExternalLocation) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExternalLocation) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExternalLocation) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExternalLocation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExternalLocation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExternalLocation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, "comment": types.StringType, "credential_name": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToObjectType(ctx), + ElemType: EncryptionDetails{}.Type(ctx), }, "fallback": types.BoolType, "name": types.StringType, @@ -1675,9 +3277,56 @@ func (a CreateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of CreateFunction in the Terraform plugin framework type -// system. -func (a CreateFunction) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateFunction{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateFunction) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateFunction) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateFunction) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateFunction) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateFunction) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateFunction) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateFunction) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -1687,7 +3336,7 @@ func (a CreateFunction) ToObjectType(ctx context.Context) types.ObjectType { "external_name": types.StringType, "full_data_type": types.StringType, "input_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToObjectType(ctx), + ElemType: FunctionParameterInfos{}.Type(ctx), }, "is_deterministic": types.BoolType, "is_null_call": types.BoolType, @@ -1695,12 +3344,12 @@ func (a CreateFunction) ToObjectType(ctx context.Context) types.ObjectType { "parameter_style": types.StringType, "properties": types.StringType, "return_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToObjectType(ctx), + ElemType: FunctionParameterInfos{}.Type(ctx), }, "routine_body": types.StringType, "routine_definition": types.StringType, "routine_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToObjectType(ctx), + ElemType: DependencyList{}.Type(ctx), }, "schema_name": types.StringType, "security_type": types.StringType, @@ -1735,13 +3384,60 @@ func (a CreateFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateFunctionRequest in the Terraform plugin framework type -// system. -func (a CreateFunctionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateFunctionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateFunctionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_info": basetypes.ListType{ - ElemType: CreateFunction{}.ToObjectType(ctx), + ElemType: CreateFunction{}.Type(ctx), }, }, } @@ -1776,9 +3472,56 @@ func (a CreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateMetastore in the Terraform plugin framework type -// system. -func (a CreateMetastore) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateMetastore{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateMetastore) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateMetastore) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateMetastore) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateMetastore) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1816,9 +3559,56 @@ func (a CreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateMetastoreAssignment in the Terraform plugin framework type -// system. -func (a CreateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateMetastoreAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_catalog_name": types.StringType, @@ -1895,39 +3685,86 @@ func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of CreateMonitor in the Terraform plugin framework type -// system. -func (a CreateMonitor) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateMonitor{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateMonitor) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateMonitor) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateMonitor) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateMonitor) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateMonitor) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateMonitor) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.ToObjectType(ctx), + ElemType: MonitorMetric{}.Type(ctx), }, "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.ToObjectType(ctx), + ElemType: MonitorDataClassificationConfig{}.Type(ctx), }, "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.ToObjectType(ctx), + ElemType: MonitorInferenceLog{}.Type(ctx), }, "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.ToObjectType(ctx), + ElemType: MonitorNotifications{}.Type(ctx), }, "output_schema_name": types.StringType, "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.ToObjectType(ctx), + ElemType: MonitorCronSchedule{}.Type(ctx), }, "skip_builtin_dashboard": types.BoolType, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.ToObjectType(ctx), + ElemType: MonitorSnapshot{}.Type(ctx), }, "table_name": types.StringType, "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.ToObjectType(ctx), + ElemType: MonitorTimeSeries{}.Type(ctx), }, "warehouse_id": types.StringType, }, @@ -1959,13 +3796,60 @@ func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of CreateOnlineTableRequest in the Terraform plugin framework type -// system. -func (a CreateOnlineTableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateOnlineTableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateOnlineTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table": basetypes.ListType{ - ElemType: OnlineTable{}.ToObjectType(ctx), + ElemType: OnlineTable{}.Type(ctx), }, }, } @@ -2002,9 +3886,56 @@ func (a CreateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateRegisteredModelRequest in the Terraform plugin framework type -// system. -func (a CreateRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRegisteredModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRegisteredModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2036,9 +3967,56 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type -// system. -func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2076,9 +4054,56 @@ func (a CreateSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of CreateSchema in the Terraform plugin framework type -// system. -func (a CreateSchema) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateSchema{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateSchema) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateSchema) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateSchema) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateSchema) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateSchema) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateSchema) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2137,26 +4162,73 @@ func (a CreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of CreateStorageCredential in the Terraform plugin framework type -// system. -func (a CreateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateStorageCredential{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateStorageCredential) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateStorageCredential) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateStorageCredential) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateStorageCredential) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.ToObjectType(ctx), + ElemType: AwsIamRoleRequest{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityRequest{}.ToObjectType(ctx), + ElemType: AzureManagedIdentityRequest{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToObjectType(ctx), + ElemType: CloudflareApiToken{}.Type(ctx), }, "comment": types.StringType, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.ToObjectType(ctx), + ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), }, "name": types.StringType, "read_only": types.BoolType, @@ -2193,13 +4265,60 @@ func (a CreateTableConstraint) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateTableConstraint in the Terraform plugin framework type -// system. -func (a CreateTableConstraint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateTableConstraint{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateTableConstraint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateTableConstraint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateTableConstraint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateTableConstraint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateTableConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateTableConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateTableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "constraint": basetypes.ListType{ - ElemType: TableConstraint{}.ToObjectType(ctx), + ElemType: TableConstraint{}.Type(ctx), }, "full_name_arg": types.StringType, }, @@ -2238,9 +4357,56 @@ func (a CreateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateVolumeRequestContent in the Terraform plugin framework type -// system. -func (a CreateVolumeRequestContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateVolumeRequestContent{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateVolumeRequestContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2315,19 +4481,66 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of CredentialInfo in the Terraform plugin framework type -// system. -func (a CredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CredentialInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o CredentialInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CredentialInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CredentialInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CredentialInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToObjectType(ctx), + ElemType: AwsIamRole{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToObjectType(ctx), + ElemType: AzureManagedIdentity{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "comment": types.StringType, "created_at": types.Int64Type, @@ -2371,9 +4584,56 @@ func (a CredentialValidationResult) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of CredentialValidationResult in the Terraform plugin framework type -// system. -func (a CredentialValidationResult) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CredentialValidationResult{} + +// Equal implements basetypes.ObjectValuable. +func (o CredentialValidationResult) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CredentialValidationResult) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CredentialValidationResult) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CredentialValidationResult) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CredentialValidationResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CredentialValidationResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CredentialValidationResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -2407,9 +4667,56 @@ func (a CurrentWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of CurrentWorkspaceBindings in the Terraform plugin framework type -// system. -func (a CurrentWorkspaceBindings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CurrentWorkspaceBindings{} + +// Equal implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CurrentWorkspaceBindings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspaces": basetypes.ListType{ @@ -2439,9 +4746,56 @@ func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of DatabricksGcpServiceAccountRequest in the Terraform plugin framework type -// system. -func (a DatabricksGcpServiceAccountRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DatabricksGcpServiceAccountRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2472,9 +4826,56 @@ func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DatabricksGcpServiceAccountResponse in the Terraform plugin framework type -// system. -func (a DatabricksGcpServiceAccountResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DatabricksGcpServiceAccountResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DatabricksGcpServiceAccountResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.StringType, @@ -2508,10 +4909,57 @@ func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountMetastoreAssignmentRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountMetastoreAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountMetastoreAssignmentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreAssignmentRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, "workspace_id": types.Int64Type, @@ -2544,9 +4992,56 @@ func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountMetastoreRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountMetastoreRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountMetastoreRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2583,9 +5078,56 @@ func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountStorageCredentialRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountStorageCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountStorageCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2620,9 +5162,56 @@ func (a DeleteAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAliasRequest in the Terraform plugin framework type -// system. -func (a DeleteAliasRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAliasRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAliasRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias": types.StringType, @@ -2651,9 +5240,56 @@ func (a DeleteAliasResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAliasResponse in the Terraform plugin framework type -// system. -func (a DeleteAliasResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAliasResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAliasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2684,9 +5320,56 @@ func (a DeleteCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCatalogRequest in the Terraform plugin framework type -// system. -func (a DeleteCatalogRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCatalogRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCatalogRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2718,9 +5401,56 @@ func (a DeleteConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteConnectionRequest in the Terraform plugin framework type -// system. -func (a DeleteConnectionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteConnectionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteConnectionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2755,9 +5485,56 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type -// system. -func (a DeleteCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2786,9 +5563,56 @@ func (a DeleteCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCredentialResponse in the Terraform plugin framework type -// system. -func (a DeleteCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCredentialResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2819,9 +5643,56 @@ func (a DeleteExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExternalLocationRequest in the Terraform plugin framework type -// system. -func (a DeleteExternalLocationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExternalLocationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExternalLocationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2856,9 +5727,56 @@ func (a DeleteFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteFunctionRequest in the Terraform plugin framework type -// system. -func (a DeleteFunctionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteFunctionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteFunctionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2892,9 +5810,56 @@ func (a DeleteMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteMetastoreRequest in the Terraform plugin framework type -// system. -func (a DeleteMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteMetastoreRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteMetastoreRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -2928,9 +5893,56 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type -// system. -func (a DeleteModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -2962,9 +5974,56 @@ func (a DeleteOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteOnlineTableRequest in the Terraform plugin framework type -// system. -func (a DeleteOnlineTableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteOnlineTableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteOnlineTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2995,9 +6054,56 @@ func (a DeleteQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteQualityMonitorRequest in the Terraform plugin framework type -// system. -func (a DeleteQualityMonitorRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteQualityMonitorRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteQualityMonitorRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -3028,9 +6134,56 @@ func (a DeleteRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRegisteredModelRequest in the Terraform plugin framework type -// system. -func (a DeleteRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRegisteredModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRegisteredModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -3058,9 +6211,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3091,9 +6291,56 @@ func (a DeleteSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteSchemaRequest in the Terraform plugin framework type -// system. -func (a DeleteSchemaRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteSchemaRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteSchemaRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -3128,9 +6375,56 @@ func (a DeleteStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteStorageCredentialRequest in the Terraform plugin framework type -// system. -func (a DeleteStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteStorageCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteStorageCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "force": types.BoolType, @@ -3168,9 +6462,56 @@ func (a DeleteTableConstraintRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteTableConstraintRequest in the Terraform plugin framework type -// system. -func (a DeleteTableConstraintRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTableConstraintRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteTableConstraintRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cascade": types.BoolType, @@ -3192,20 +6533,67 @@ func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan func (newState *DeleteTableRequest) SyncEffectiveFieldsDuringRead(existingState DeleteTableRequest) { } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTableRequest. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a DeleteTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetComplexFieldTypes returns a map of the types of elements in complex fields in DeleteTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a DeleteTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of DeleteTableRequest in the Terraform plugin framework type -// system. -func (a DeleteTableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o DeleteTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -3236,9 +6624,56 @@ func (a DeleteVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteVolumeRequest in the Terraform plugin framework type -// system. -func (a DeleteVolumeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteVolumeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteVolumeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -3273,9 +6708,56 @@ func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of DeltaRuntimePropertiesKvPairs in the Terraform plugin framework type -// system. -func (a DeltaRuntimePropertiesKvPairs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeltaRuntimePropertiesKvPairs{} + +// Equal implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeltaRuntimePropertiesKvPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "delta_runtime_properties": basetypes.MapType{ @@ -3314,16 +6796,63 @@ func (a Dependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of Dependency in the Terraform plugin framework type -// system. -func (a Dependency) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Dependency{} + +// Equal implements basetypes.ObjectValuable. +func (o Dependency) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Dependency) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Dependency) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Dependency) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Dependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Dependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Dependency) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function": basetypes.ListType{ - ElemType: FunctionDependency{}.ToObjectType(ctx), + ElemType: FunctionDependency{}.Type(ctx), }, "table": basetypes.ListType{ - ElemType: TableDependency{}.ToObjectType(ctx), + ElemType: TableDependency{}.Type(ctx), }, }, } @@ -3354,13 +6883,60 @@ func (a DependencyList) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of DependencyList in the Terraform plugin framework type -// system. -func (a DependencyList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DependencyList{} + +// Equal implements basetypes.ObjectValuable. +func (o DependencyList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DependencyList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DependencyList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DependencyList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DependencyList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DependencyList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DependencyList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dependencies": basetypes.ListType{ - ElemType: Dependency{}.ToObjectType(ctx), + ElemType: Dependency{}.Type(ctx), }, }, } @@ -3391,9 +6967,56 @@ func (a DisableRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DisableRequest in the Terraform plugin framework type -// system. -func (a DisableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DisableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DisableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DisableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DisableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DisableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DisableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DisableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DisableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -3422,9 +7045,56 @@ func (a DisableResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DisableResponse in the Terraform plugin framework type -// system. -func (a DisableResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DisableResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DisableResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DisableResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DisableResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DisableResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DisableResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DisableResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DisableResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3455,13 +7125,60 @@ func (a EffectivePermissionsList) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of EffectivePermissionsList in the Terraform plugin framework type -// system. -func (a EffectivePermissionsList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EffectivePermissionsList{} + +// Equal implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EffectivePermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "privilege_assignments": basetypes.ListType{ - ElemType: EffectivePrivilegeAssignment{}.ToObjectType(ctx), + ElemType: EffectivePrivilegeAssignment{}.Type(ctx), }, }, } @@ -3496,9 +7213,56 @@ func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of EffectivePredictiveOptimizationFlag in the Terraform plugin framework type -// system. -func (a EffectivePredictiveOptimizationFlag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EffectivePredictiveOptimizationFlag{} + +// Equal implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EffectivePredictiveOptimizationFlag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited_from_name": types.StringType, @@ -3538,9 +7302,56 @@ func (a EffectivePrivilege) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of EffectivePrivilege in the Terraform plugin framework type -// system. -func (a EffectivePrivilege) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EffectivePrivilege{} + +// Equal implements basetypes.ObjectValuable. +func (o EffectivePrivilege) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EffectivePrivilege) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EffectivePrivilege) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EffectivePrivilege) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EffectivePrivilege) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EffectivePrivilege) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EffectivePrivilege) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited_from_name": types.StringType, @@ -3577,14 +7388,61 @@ func (a EffectivePrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of EffectivePrivilegeAssignment in the Terraform plugin framework type -// system. -func (a EffectivePrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EffectivePrivilegeAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EffectivePrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, "privileges": basetypes.ListType{ - ElemType: EffectivePrivilege{}.ToObjectType(ctx), + ElemType: EffectivePrivilege{}.Type(ctx), }, }, } @@ -3615,9 +7473,56 @@ func (a EnableRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of EnableRequest in the Terraform plugin framework type -// system. -func (a EnableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o EnableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -3646,9 +7551,56 @@ func (a EnableResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of EnableResponse in the Terraform plugin framework type -// system. -func (a EnableResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnableResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EnableResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnableResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnableResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnableResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnableResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnableResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnableResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3679,13 +7631,60 @@ func (a EncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of EncryptionDetails in the Terraform plugin framework type -// system. -func (a EncryptionDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EncryptionDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o EncryptionDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EncryptionDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EncryptionDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EncryptionDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EncryptionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EncryptionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EncryptionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sse_encryption_details": basetypes.ListType{ - ElemType: SseEncryptionDetails{}.ToObjectType(ctx), + ElemType: SseEncryptionDetails{}.Type(ctx), }, }, } @@ -3714,9 +7713,56 @@ func (a ExistsRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExistsRequest in the Terraform plugin framework type -// system. -func (a ExistsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExistsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExistsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExistsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExistsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExistsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExistsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExistsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExistsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -3785,9 +7831,56 @@ func (a ExternalLocationInfo) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ExternalLocationInfo in the Terraform plugin framework type -// system. -func (a ExternalLocationInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExternalLocationInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExternalLocationInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, @@ -3798,7 +7891,7 @@ func (a ExternalLocationInfo) ToObjectType(ctx context.Context) types.ObjectType "credential_id": types.StringType, "credential_name": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToObjectType(ctx), + ElemType: EncryptionDetails{}.Type(ctx), }, "fallback": types.BoolType, "isolation_mode": types.StringType, @@ -3844,9 +7937,56 @@ func (a FailedStatus) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of FailedStatus in the Terraform plugin framework type -// system. -func (a FailedStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FailedStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o FailedStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FailedStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FailedStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FailedStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FailedStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FailedStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FailedStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_processed_commit_version": types.Int64Type, @@ -3886,9 +8026,56 @@ func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ForeignKeyConstraint in the Terraform plugin framework type -// system. -func (a ForeignKeyConstraint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ForeignKeyConstraint{} + +// Equal implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ForeignKeyConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "child_columns": basetypes.ListType{ @@ -3927,9 +8114,56 @@ func (a FunctionDependency) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of FunctionDependency in the Terraform plugin framework type -// system. -func (a FunctionDependency) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FunctionDependency{} + +// Equal implements basetypes.ObjectValuable. +func (o FunctionDependency) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FunctionDependency) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FunctionDependency) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FunctionDependency) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FunctionDependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FunctionDependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FunctionDependency) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_full_name": types.StringType, @@ -4028,9 +8262,56 @@ func (a FunctionInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of FunctionInfo in the Terraform plugin framework type -// system. -func (a FunctionInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FunctionInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o FunctionInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FunctionInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FunctionInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FunctionInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FunctionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FunctionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FunctionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "browse_only": types.BoolType, @@ -4045,7 +8326,7 @@ func (a FunctionInfo) ToObjectType(ctx context.Context) types.ObjectType { "full_name": types.StringType, "function_id": types.StringType, "input_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToObjectType(ctx), + ElemType: FunctionParameterInfos{}.Type(ctx), }, "is_deterministic": types.BoolType, "is_null_call": types.BoolType, @@ -4055,12 +8336,12 @@ func (a FunctionInfo) ToObjectType(ctx context.Context) types.ObjectType { "parameter_style": types.StringType, "properties": types.StringType, "return_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.ToObjectType(ctx), + ElemType: FunctionParameterInfos{}.Type(ctx), }, "routine_body": types.StringType, "routine_definition": types.StringType, "routine_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToObjectType(ctx), + ElemType: DependencyList{}.Type(ctx), }, "schema_name": types.StringType, "security_type": types.StringType, @@ -4117,9 +8398,56 @@ func (a FunctionParameterInfo) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of FunctionParameterInfo in the Terraform plugin framework type -// system. -func (a FunctionParameterInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FunctionParameterInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FunctionParameterInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4163,13 +8491,60 @@ func (a FunctionParameterInfos) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of FunctionParameterInfos in the Terraform plugin framework type -// system. -func (a FunctionParameterInfos) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FunctionParameterInfos{} + +// Equal implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FunctionParameterInfos) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ - ElemType: FunctionParameterInfo{}.ToObjectType(ctx), + ElemType: FunctionParameterInfo{}.Type(ctx), }, }, } @@ -4198,9 +8573,56 @@ func (a GcpOauthToken) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpOauthToken in the Terraform plugin framework type -// system. -func (a GcpOauthToken) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpOauthToken{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpOauthToken) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpOauthToken) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpOauthToken) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpOauthToken) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpOauthToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpOauthToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpOauthToken) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "oauth_token": types.StringType, @@ -4235,9 +8657,56 @@ func (a GcpServiceAccountKey) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpServiceAccountKey in the Terraform plugin framework type -// system. -func (a GcpServiceAccountKey) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpServiceAccountKey{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpServiceAccountKey) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email": types.StringType, @@ -4274,9 +8743,56 @@ func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes(ctx } } -// ToObjectType returns the representation of GenerateTemporaryServiceCredentialAzureOptions in the Terraform plugin framework type -// system. -func (a GenerateTemporaryServiceCredentialAzureOptions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenerateTemporaryServiceCredentialAzureOptions{} + +// Equal implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialAzureOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resources": basetypes.ListType{ @@ -4313,13 +8829,60 @@ func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes(ctx cont } } -// ToObjectType returns the representation of GenerateTemporaryServiceCredentialRequest in the Terraform plugin framework type -// system. -func (a GenerateTemporaryServiceCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenerateTemporaryServiceCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenerateTemporaryServiceCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "azure_options": basetypes.ListType{ - ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.ToObjectType(ctx), + ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.Type(ctx), }, "credential_name": types.StringType, }, @@ -4352,9 +8915,56 @@ func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenerateTemporaryTableCredentialRequest in the Terraform plugin framework type -// system. -func (a GenerateTemporaryTableCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenerateTemporaryTableCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operation": types.StringType, @@ -4410,26 +9020,73 @@ func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes(ctx conte } } -// ToObjectType returns the representation of GenerateTemporaryTableCredentialResponse in the Terraform plugin framework type -// system. -func (a GenerateTemporaryTableCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenerateTemporaryTableCredentialResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenerateTemporaryTableCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_temp_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.ToObjectType(ctx), + ElemType: AwsCredentials{}.Type(ctx), }, "azure_aad": basetypes.ListType{ - ElemType: AzureActiveDirectoryToken{}.ToObjectType(ctx), + ElemType: AzureActiveDirectoryToken{}.Type(ctx), }, "azure_user_delegation_sas": basetypes.ListType{ - ElemType: AzureUserDelegationSas{}.ToObjectType(ctx), + ElemType: AzureUserDelegationSas{}.Type(ctx), }, "expiration_time": types.Int64Type, "gcp_oauth_token": basetypes.ListType{ - ElemType: GcpOauthToken{}.ToObjectType(ctx), + ElemType: GcpOauthToken{}.Type(ctx), }, "r2_temp_credentials": basetypes.ListType{ - ElemType: R2Credentials{}.ToObjectType(ctx), + ElemType: R2Credentials{}.Type(ctx), }, "url": types.StringType, }, @@ -4459,9 +9116,56 @@ func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountMetastoreAssignmentRequest in the Terraform plugin framework type -// system. -func (a GetAccountMetastoreAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountMetastoreAssignmentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountMetastoreAssignmentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -4492,9 +9196,56 @@ func (a GetAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountMetastoreRequest in the Terraform plugin framework type -// system. -func (a GetAccountMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountMetastoreRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountMetastoreRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -4527,9 +9278,56 @@ func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountStorageCredentialRequest in the Terraform plugin framework type -// system. -func (a GetAccountStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountStorageCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountStorageCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -4561,9 +9359,56 @@ func (a GetArtifactAllowlistRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetArtifactAllowlistRequest in the Terraform plugin framework type -// system. -func (a GetArtifactAllowlistRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetArtifactAllowlistRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetArtifactAllowlistRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_type": types.StringType, @@ -4605,9 +9450,56 @@ func (a GetBindingsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetBindingsRequest in the Terraform plugin framework type -// system. -func (a GetBindingsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetBindingsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetBindingsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetBindingsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetBindingsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetBindingsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetBindingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetBindingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetBindingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -4646,9 +9538,56 @@ func (a GetByAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetByAliasRequest in the Terraform plugin framework type -// system. -func (a GetByAliasRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetByAliasRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetByAliasRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetByAliasRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetByAliasRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetByAliasRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetByAliasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetByAliasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetByAliasRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias": types.StringType, @@ -4684,9 +9623,56 @@ func (a GetCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCatalogRequest in the Terraform plugin framework type -// system. -func (a GetCatalogRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCatalogRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCatalogRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCatalogRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCatalogRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCatalogRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCatalogRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCatalogRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCatalogRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -4718,9 +9704,56 @@ func (a GetConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetConnectionRequest in the Terraform plugin framework type -// system. -func (a GetConnectionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetConnectionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetConnectionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetConnectionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetConnectionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetConnectionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetConnectionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetConnectionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetConnectionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -4751,9 +9784,56 @@ func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCredentialRequest in the Terraform plugin framework type -// system. -func (a GetCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name_arg": types.StringType, @@ -4789,9 +9869,56 @@ func (a GetEffectiveRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetEffectiveRequest in the Terraform plugin framework type -// system. -func (a GetEffectiveRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEffectiveRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEffectiveRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -4827,9 +9954,56 @@ func (a GetExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetExternalLocationRequest in the Terraform plugin framework type -// system. -func (a GetExternalLocationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExternalLocationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExternalLocationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -4865,9 +10039,56 @@ func (a GetFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetFunctionRequest in the Terraform plugin framework type -// system. -func (a GetFunctionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetFunctionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetFunctionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetFunctionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetFunctionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetFunctionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetFunctionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetFunctionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetFunctionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -4904,9 +10125,56 @@ func (a GetGrantRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetGrantRequest in the Terraform plugin framework type -// system. -func (a GetGrantRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetGrantRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetGrantRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetGrantRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetGrantRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetGrantRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetGrantRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetGrantRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetGrantRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -4939,9 +10207,56 @@ func (a GetMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetMetastoreRequest in the Terraform plugin framework type -// system. -func (a GetMetastoreRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetMetastoreRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetMetastoreRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -5011,9 +10326,56 @@ func (a GetMetastoreSummaryResponse) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetMetastoreSummaryResponse in the Terraform plugin framework type -// system. -func (a GetMetastoreSummaryResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetMetastoreSummaryResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetMetastoreSummaryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cloud": types.StringType, @@ -5070,9 +10432,56 @@ func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetModelVersionRequest in the Terraform plugin framework type -// system. -func (a GetModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5106,9 +10515,56 @@ func (a GetOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetOnlineTableRequest in the Terraform plugin framework type -// system. -func (a GetOnlineTableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetOnlineTableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetOnlineTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5139,9 +10595,56 @@ func (a GetQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetQualityMonitorRequest in the Terraform plugin framework type -// system. -func (a GetQualityMonitorRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetQualityMonitorRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetQualityMonitorRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -5178,9 +10681,56 @@ func (a GetQuotaRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetQuotaRequest in the Terraform plugin framework type -// system. -func (a GetQuotaRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetQuotaRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetQuotaRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetQuotaRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetQuotaRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetQuotaRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetQuotaRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetQuotaRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetQuotaRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parent_full_name": types.StringType, @@ -5214,13 +10764,60 @@ func (a GetQuotaResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of GetQuotaResponse in the Terraform plugin framework type -// system. -func (a GetQuotaResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetQuotaResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetQuotaResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetQuotaResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetQuotaResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetQuotaResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetQuotaResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetQuotaResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetQuotaResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "quota_info": basetypes.ListType{ - ElemType: QuotaInfo{}.ToObjectType(ctx), + ElemType: QuotaInfo{}.Type(ctx), }, }, } @@ -5251,9 +10848,56 @@ func (a GetRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRefreshRequest in the Terraform plugin framework type -// system. -func (a GetRefreshRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRefreshRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRefreshRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRefreshRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRefreshRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRefreshRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRefreshRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRefreshRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRefreshRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "refresh_id": types.StringType, @@ -5290,9 +10934,56 @@ func (a GetRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRegisteredModelRequest in the Terraform plugin framework type -// system. -func (a GetRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRegisteredModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRegisteredModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5317,20 +11008,67 @@ func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan G func (newState *GetSchemaRequest) SyncEffectiveFieldsDuringRead(existingState GetSchemaRequest) { } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSchemaRequest. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a GetSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetComplexFieldTypes returns a map of the types of elements in complex fields in GetSchemaRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a GetSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetSchemaRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetSchemaRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetSchemaRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetSchemaRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetSchemaRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetSchemaRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetSchemaRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of GetSchemaRequest in the Terraform plugin framework type -// system. -func (a GetSchemaRequest) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o GetSchemaRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5362,9 +11100,56 @@ func (a GetStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStorageCredentialRequest in the Terraform plugin framework type -// system. -func (a GetStorageCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStorageCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStorageCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5402,9 +11187,56 @@ func (a GetTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetTableRequest in the Terraform plugin framework type -// system. -func (a GetTableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetTableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetTableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetTableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetTableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetTableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -5438,9 +11270,56 @@ func (a GetWorkspaceBindingRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWorkspaceBindingRequest in the Terraform plugin framework type -// system. -func (a GetWorkspaceBindingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceBindingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceBindingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5471,9 +11350,56 @@ func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAccountMetastoreAssignmentsRequest in the Terraform plugin framework type -// system. -func (a ListAccountMetastoreAssignmentsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountMetastoreAssignmentsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -5505,9 +11431,56 @@ func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes(ctx contex } } -// ToObjectType returns the representation of ListAccountMetastoreAssignmentsResponse in the Terraform plugin framework type -// system. -func (a ListAccountMetastoreAssignmentsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountMetastoreAssignmentsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountMetastoreAssignmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_ids": basetypes.ListType{ @@ -5540,9 +11513,56 @@ func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAccountStorageCredentialsRequest in the Terraform plugin framework type -// system. -func (a ListAccountStorageCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountStorageCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -5574,13 +11594,60 @@ func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes(ctx context. } } -// ToObjectType returns the representation of ListAccountStorageCredentialsResponse in the Terraform plugin framework type -// system. -func (a ListAccountStorageCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountStorageCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "storage_credentials": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.ToObjectType(ctx), + ElemType: StorageCredentialInfo{}.Type(ctx), }, }, } @@ -5622,9 +11689,56 @@ func (a ListCatalogsRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListCatalogsRequest in the Terraform plugin framework type -// system. -func (a ListCatalogsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListCatalogsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListCatalogsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -5662,13 +11776,60 @@ func (a ListCatalogsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListCatalogsResponse in the Terraform plugin framework type -// system. -func (a ListCatalogsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListCatalogsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListCatalogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalogs": basetypes.ListType{ - ElemType: CatalogInfo{}.ToObjectType(ctx), + ElemType: CatalogInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -5705,9 +11866,56 @@ func (a ListConnectionsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListConnectionsRequest in the Terraform plugin framework type -// system. -func (a ListConnectionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListConnectionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListConnectionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -5744,13 +11952,60 @@ func (a ListConnectionsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ListConnectionsResponse in the Terraform plugin framework type -// system. -func (a ListConnectionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListConnectionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListConnectionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connections": basetypes.ListType{ - ElemType: ConnectionInfo{}.ToObjectType(ctx), + ElemType: ConnectionInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -5788,9 +12043,56 @@ func (a ListCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListCredentialsRequest in the Terraform plugin framework type -// system. -func (a ListCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -5827,13 +12129,60 @@ func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ListCredentialsResponse in the Terraform plugin framework type -// system. -func (a ListCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials": basetypes.ListType{ - ElemType: CredentialInfo{}.ToObjectType(ctx), + ElemType: CredentialInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -5873,9 +12222,56 @@ func (a ListExternalLocationsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListExternalLocationsRequest in the Terraform plugin framework type -// system. -func (a ListExternalLocationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExternalLocationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExternalLocationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -5913,13 +12309,60 @@ func (a ListExternalLocationsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListExternalLocationsResponse in the Terraform plugin framework type -// system. -func (a ListExternalLocationsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExternalLocationsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExternalLocationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_locations": basetypes.ListType{ - ElemType: ExternalLocationInfo{}.ToObjectType(ctx), + ElemType: ExternalLocationInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -5963,9 +12406,56 @@ func (a ListFunctionsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListFunctionsRequest in the Terraform plugin framework type -// system. -func (a ListFunctionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListFunctionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListFunctionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6005,13 +12495,60 @@ func (a ListFunctionsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListFunctionsResponse in the Terraform plugin framework type -// system. -func (a ListFunctionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListFunctionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListFunctionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "functions": basetypes.ListType{ - ElemType: FunctionInfo{}.ToObjectType(ctx), + ElemType: FunctionInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -6042,13 +12579,60 @@ func (a ListMetastoresResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ListMetastoresResponse in the Terraform plugin framework type -// system. -func (a ListMetastoresResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListMetastoresResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListMetastoresResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastores": basetypes.ListType{ - ElemType: MetastoreInfo{}.ToObjectType(ctx), + ElemType: MetastoreInfo{}.Type(ctx), }, }, } @@ -6091,9 +12675,56 @@ func (a ListModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListModelVersionsRequest in the Terraform plugin framework type -// system. -func (a ListModelVersionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListModelVersionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListModelVersionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -6131,13 +12762,60 @@ func (a ListModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ListModelVersionsResponse in the Terraform plugin framework type -// system. -func (a ListModelVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListModelVersionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_versions": basetypes.ListType{ - ElemType: ModelVersionInfo{}.ToObjectType(ctx), + ElemType: ModelVersionInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -6169,9 +12847,56 @@ func (a ListQuotasRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListQuotasRequest in the Terraform plugin framework type -// system. -func (a ListQuotasRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQuotasRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQuotasRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQuotasRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQuotasRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQuotasRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQuotasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQuotasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQuotasRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -6208,14 +12933,61 @@ func (a ListQuotasResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListQuotasResponse in the Terraform plugin framework type -// system. -func (a ListQuotasResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQuotasResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQuotasResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQuotasResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQuotasResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQuotasResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQuotasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQuotasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQuotasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "quotas": basetypes.ListType{ - ElemType: QuotaInfo{}.ToObjectType(ctx), + ElemType: QuotaInfo{}.Type(ctx), }, }, } @@ -6244,9 +13016,56 @@ func (a ListRefreshesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListRefreshesRequest in the Terraform plugin framework type -// system. -func (a ListRefreshesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRefreshesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRefreshesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -6304,9 +13123,56 @@ func (a ListRegisteredModelsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListRegisteredModelsRequest in the Terraform plugin framework type -// system. -func (a ListRegisteredModelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRegisteredModelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRegisteredModelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6345,14 +13211,61 @@ func (a ListRegisteredModelsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListRegisteredModelsResponse in the Terraform plugin framework type -// system. -func (a ListRegisteredModelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRegisteredModelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRegisteredModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "registered_models": basetypes.ListType{ - ElemType: RegisteredModelInfo{}.ToObjectType(ctx), + ElemType: RegisteredModelInfo{}.Type(ctx), }, }, } @@ -6393,9 +13306,56 @@ func (a ListSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSchemasRequest in the Terraform plugin framework type -// system. -func (a ListSchemasRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSchemasRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSchemasRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSchemasRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSchemasRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSchemasRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSchemasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSchemasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSchemasRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6434,14 +13394,61 @@ func (a ListSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListSchemasResponse in the Terraform plugin framework type -// system. -func (a ListSchemasResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSchemasResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSchemasResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSchemasResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSchemasResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSchemasResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSchemasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSchemasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "schemas": basetypes.ListType{ - ElemType: SchemaInfo{}.ToObjectType(ctx), + ElemType: SchemaInfo{}.Type(ctx), }, }, } @@ -6477,9 +13484,56 @@ func (a ListStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListStorageCredentialsRequest in the Terraform plugin framework type -// system. -func (a ListStorageCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListStorageCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListStorageCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -6516,14 +13570,61 @@ func (a ListStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of ListStorageCredentialsResponse in the Terraform plugin framework type -// system. -func (a ListStorageCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListStorageCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "storage_credentials": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.ToObjectType(ctx), + ElemType: StorageCredentialInfo{}.Type(ctx), }, }, } @@ -6570,9 +13671,56 @@ func (a ListSummariesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSummariesRequest in the Terraform plugin framework type -// system. -func (a ListSummariesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSummariesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSummariesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSummariesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSummariesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSummariesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSummariesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSummariesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSummariesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6617,9 +13765,56 @@ func (a ListSystemSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSystemSchemasRequest in the Terraform plugin framework type -// system. -func (a ListSystemSchemasRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSystemSchemasRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSystemSchemasRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -6657,14 +13852,61 @@ func (a ListSystemSchemasResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ListSystemSchemasResponse in the Terraform plugin framework type -// system. -func (a ListSystemSchemasResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSystemSchemasResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSystemSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "schemas": basetypes.ListType{ - ElemType: SystemSchemaInfo{}.ToObjectType(ctx), + ElemType: SystemSchemaInfo{}.Type(ctx), }, }, } @@ -6698,14 +13940,61 @@ func (a ListTableSummariesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListTableSummariesResponse in the Terraform plugin framework type -// system. -func (a ListTableSummariesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTableSummariesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTableSummariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "tables": basetypes.ListType{ - ElemType: TableSummary{}.ToObjectType(ctx), + ElemType: TableSummary{}.Type(ctx), }, }, } @@ -6759,9 +14048,56 @@ func (a ListTablesRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListTablesRequest in the Terraform plugin framework type -// system. -func (a ListTablesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTablesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTablesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTablesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTablesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTablesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTablesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTablesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTablesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6806,14 +14142,61 @@ func (a ListTablesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListTablesResponse in the Terraform plugin framework type -// system. -func (a ListTablesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTablesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTablesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTablesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTablesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTablesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTablesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTablesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTablesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "tables": basetypes.ListType{ - ElemType: TableInfo{}.ToObjectType(ctx), + ElemType: TableInfo{}.Type(ctx), }, }, } @@ -6863,9 +14246,56 @@ func (a ListVolumesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListVolumesRequest in the Terraform plugin framework type -// system. -func (a ListVolumesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListVolumesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListVolumesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListVolumesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListVolumesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListVolumesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListVolumesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListVolumesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListVolumesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -6905,14 +14335,61 @@ func (a ListVolumesResponseContent) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListVolumesResponseContent in the Terraform plugin framework type -// system. -func (a ListVolumesResponseContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListVolumesResponseContent{} + +// Equal implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListVolumesResponseContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "volumes": basetypes.ListType{ - ElemType: VolumeInfo{}.ToObjectType(ctx), + ElemType: VolumeInfo{}.Type(ctx), }, }, } @@ -6944,9 +14421,56 @@ func (a MetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of MetastoreAssignment in the Terraform plugin framework type -// system. -func (a MetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MetastoreAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o MetastoreAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MetastoreAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MetastoreAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MetastoreAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_catalog_name": types.StringType, @@ -7018,9 +14542,56 @@ func (a MetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of MetastoreInfo in the Terraform plugin framework type -// system. -func (a MetastoreInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MetastoreInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o MetastoreInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MetastoreInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MetastoreInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MetastoreInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MetastoreInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MetastoreInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MetastoreInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cloud": types.StringType, @@ -7119,13 +14690,60 @@ func (a ModelVersionInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ModelVersionInfo in the Terraform plugin framework type -// system. -func (a ModelVersionInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelVersionInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelVersionInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelVersionInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelVersionInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelVersionInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelVersionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelVersionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aliases": basetypes.ListType{ - ElemType: RegisteredModelAlias{}.ToObjectType(ctx), + ElemType: RegisteredModelAlias{}.Type(ctx), }, "browse_only": types.BoolType, "catalog_name": types.StringType, @@ -7136,7 +14754,7 @@ func (a ModelVersionInfo) ToObjectType(ctx context.Context) types.ObjectType { "metastore_id": types.StringType, "model_name": types.StringType, "model_version_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToObjectType(ctx), + ElemType: DependencyList{}.Type(ctx), }, "run_id": types.StringType, "run_workspace_id": types.Int64Type, @@ -7180,9 +14798,56 @@ func (a MonitorCronSchedule) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of MonitorCronSchedule in the Terraform plugin framework type -// system. -func (a MonitorCronSchedule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorCronSchedule{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorCronSchedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pause_status": types.StringType, @@ -7214,9 +14879,56 @@ func (a MonitorDataClassificationConfig) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of MonitorDataClassificationConfig in the Terraform plugin framework type -// system. -func (a MonitorDataClassificationConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorDataClassificationConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorDataClassificationConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -7249,9 +14961,56 @@ func (a MonitorDestination) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of MonitorDestination in the Terraform plugin framework type -// system. -func (a MonitorDestination) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorDestination{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorDestination) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorDestination) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorDestination) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorDestination) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorDestination) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorDestination) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email_addresses": basetypes.ListType{ @@ -7311,9 +15070,56 @@ func (a MonitorInferenceLog) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of MonitorInferenceLog in the Terraform plugin framework type -// system. -func (a MonitorInferenceLog) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorInferenceLog{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorInferenceLog) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "granularities": basetypes.ListType{ @@ -7407,44 +15213,91 @@ func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of MonitorInfo in the Terraform plugin framework type -// system. -func (a MonitorInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.ToObjectType(ctx), + ElemType: MonitorMetric{}.Type(ctx), }, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.ToObjectType(ctx), + ElemType: MonitorDataClassificationConfig{}.Type(ctx), }, "drift_metrics_table_name": types.StringType, "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.ToObjectType(ctx), + ElemType: MonitorInferenceLog{}.Type(ctx), }, "latest_monitor_failure_msg": types.StringType, "monitor_version": types.StringType, "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.ToObjectType(ctx), + ElemType: MonitorNotifications{}.Type(ctx), }, "output_schema_name": types.StringType, "profile_metrics_table_name": types.StringType, "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.ToObjectType(ctx), + ElemType: MonitorCronSchedule{}.Type(ctx), }, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.ToObjectType(ctx), + ElemType: MonitorSnapshot{}.Type(ctx), }, "status": types.StringType, "table_name": types.StringType, "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.ToObjectType(ctx), + ElemType: MonitorTimeSeries{}.Type(ctx), }, }, } @@ -7474,7 +15327,7 @@ type MonitorMetric struct { // table - CUSTOM_METRIC_TYPE_DERIVED: depend on previously computed // aggregate metrics - CUSTOM_METRIC_TYPE_DRIFT: depend on previously // computed aggregate or derived metrics - Type types.String `tfsdk:"type" tf:""` + Type_ types.String `tfsdk:"type" tf:""` } func (newState *MonitorMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorMetric) { @@ -7496,9 +15349,56 @@ func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of MonitorMetric in the Terraform plugin framework type -// system. -func (a MonitorMetric) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorMetric{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorMetric) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorMetric) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorMetric) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorMetric) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorMetric) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorMetric) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorMetric) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, @@ -7540,16 +15440,63 @@ func (a MonitorNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of MonitorNotifications in the Terraform plugin framework type -// system. -func (a MonitorNotifications) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorNotifications{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorNotifications) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorNotifications) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorNotifications) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorNotifications) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "on_failure": basetypes.ListType{ - ElemType: MonitorDestination{}.ToObjectType(ctx), + ElemType: MonitorDestination{}.Type(ctx), }, "on_new_classification_tag_detected": basetypes.ListType{ - ElemType: MonitorDestination{}.ToObjectType(ctx), + ElemType: MonitorDestination{}.Type(ctx), }, }, } @@ -7590,9 +15537,56 @@ func (a MonitorRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of MonitorRefreshInfo in the Terraform plugin framework type -// system. -func (a MonitorRefreshInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorRefreshInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorRefreshInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time_ms": types.Int64Type, @@ -7629,13 +15623,60 @@ func (a MonitorRefreshListResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of MonitorRefreshListResponse in the Terraform plugin framework type -// system. -func (a MonitorRefreshListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorRefreshListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorRefreshListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "refreshes": basetypes.ListType{ - ElemType: MonitorRefreshInfo{}.ToObjectType(ctx), + ElemType: MonitorRefreshInfo{}.Type(ctx), }, }, } @@ -7650,20 +15691,67 @@ func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringCreateOrUpdate(plan Mo func (newState *MonitorSnapshot) SyncEffectiveFieldsDuringRead(existingState MonitorSnapshot) { } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorSnapshot. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a MonitorSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorSnapshot. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a MonitorSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorSnapshot{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorSnapshot) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorSnapshot) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorSnapshot) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorSnapshot) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorSnapshot) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorSnapshot) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of MonitorSnapshot in the Terraform plugin framework type -// system. -func (a MonitorSnapshot) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o MonitorSnapshot) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7703,9 +15791,56 @@ func (a MonitorTimeSeries) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of MonitorTimeSeries in the Terraform plugin framework type -// system. -func (a MonitorTimeSeries) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MonitorTimeSeries{} + +// Equal implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MonitorTimeSeries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "granularities": basetypes.ListType{ @@ -7738,9 +15873,56 @@ func (a NamedTableConstraint) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of NamedTableConstraint in the Terraform plugin framework type -// system. -func (a NamedTableConstraint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NamedTableConstraint{} + +// Equal implements basetypes.ObjectValuable. +func (o NamedTableConstraint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NamedTableConstraint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NamedTableConstraint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NamedTableConstraint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NamedTableConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NamedTableConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NamedTableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -7785,17 +15967,64 @@ func (a OnlineTable) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of OnlineTable in the Terraform plugin framework type -// system. -func (a OnlineTable) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OnlineTable{} + +// Equal implements basetypes.ObjectValuable. +func (o OnlineTable) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OnlineTable) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OnlineTable) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OnlineTable) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OnlineTable) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OnlineTable) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OnlineTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "spec": basetypes.ListType{ - ElemType: OnlineTableSpec{}.ToObjectType(ctx), + ElemType: OnlineTableSpec{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: OnlineTableStatus{}.ToObjectType(ctx), + ElemType: OnlineTableStatus{}.Type(ctx), }, "table_serving_url": types.StringType, "unity_catalog_provisioning_state": types.StringType, @@ -7851,9 +16080,56 @@ func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of OnlineTableSpec in the Terraform plugin framework type -// system. -func (a OnlineTableSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OnlineTableSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o OnlineTableSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OnlineTableSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OnlineTableSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OnlineTableSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OnlineTableSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OnlineTableSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OnlineTableSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "perform_full_copy": types.BoolType, @@ -7862,10 +16138,10 @@ func (a OnlineTableSpec) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "run_continuously": basetypes.ListType{ - ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.ToObjectType(ctx), + ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.Type(ctx), }, "run_triggered": basetypes.ListType{ - ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.ToObjectType(ctx), + ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.Type(ctx), }, "source_table_full_name": types.StringType, "timeseries_key": types.StringType, @@ -7893,9 +16169,56 @@ func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of OnlineTableSpecContinuousSchedulingPolicy in the Terraform plugin framework type -// system. -func (a OnlineTableSpecContinuousSchedulingPolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OnlineTableSpecContinuousSchedulingPolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OnlineTableSpecContinuousSchedulingPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7921,9 +16244,56 @@ func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of OnlineTableSpecTriggeredSchedulingPolicy in the Terraform plugin framework type -// system. -func (a OnlineTableSpecTriggeredSchedulingPolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OnlineTableSpecTriggeredSchedulingPolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OnlineTableSpecTriggeredSchedulingPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7972,24 +16342,71 @@ func (a OnlineTableStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of OnlineTableStatus in the Terraform plugin framework type -// system. -func (a OnlineTableStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OnlineTableStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o OnlineTableStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OnlineTableStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OnlineTableStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OnlineTableStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OnlineTableStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OnlineTableStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OnlineTableStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "continuous_update_status": basetypes.ListType{ - ElemType: ContinuousUpdateStatus{}.ToObjectType(ctx), + ElemType: ContinuousUpdateStatus{}.Type(ctx), }, "detailed_state": types.StringType, "failed_status": basetypes.ListType{ - ElemType: FailedStatus{}.ToObjectType(ctx), + ElemType: FailedStatus{}.Type(ctx), }, "message": types.StringType, "provisioning_status": basetypes.ListType{ - ElemType: ProvisioningStatus{}.ToObjectType(ctx), + ElemType: ProvisioningStatus{}.Type(ctx), }, "triggered_update_status": basetypes.ListType{ - ElemType: TriggeredUpdateStatus{}.ToObjectType(ctx), + ElemType: TriggeredUpdateStatus{}.Type(ctx), }, }, } @@ -8024,9 +16441,56 @@ func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of PermissionsChange in the Terraform plugin framework type -// system. -func (a PermissionsChange) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionsChange{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionsChange) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionsChange) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionsChange) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionsChange) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionsChange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionsChange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionsChange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "add": basetypes.ListType{ @@ -8064,13 +16528,60 @@ func (a PermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of PermissionsList in the Terraform plugin framework type -// system. -func (a PermissionsList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionsList{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionsList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionsList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionsList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionsList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionsList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionsList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "privilege_assignments": basetypes.ListType{ - ElemType: PrivilegeAssignment{}.ToObjectType(ctx), + ElemType: PrivilegeAssignment{}.Type(ctx), }, }, } @@ -8109,9 +16620,56 @@ func (a PipelineProgress) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelineProgress in the Terraform plugin framework type -// system. -func (a PipelineProgress) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineProgress{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineProgress) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineProgress) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineProgress) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineProgress) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineProgress) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineProgress) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineProgress) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "estimated_completion_time_seconds": types.Float64Type, @@ -8149,9 +16707,56 @@ func (a PrimaryKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of PrimaryKeyConstraint in the Terraform plugin framework type -// system. -func (a PrimaryKeyConstraint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PrimaryKeyConstraint{} + +// Equal implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PrimaryKeyConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "child_columns": basetypes.ListType{ @@ -8188,9 +16793,56 @@ func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of PrivilegeAssignment in the Terraform plugin framework type -// system. -func (a PrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PrivilegeAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -8223,9 +16875,56 @@ func (a ProvisioningInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of ProvisioningInfo in the Terraform plugin framework type -// system. -func (a ProvisioningInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ProvisioningInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ProvisioningInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ProvisioningInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ProvisioningInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ProvisioningInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ProvisioningInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ProvisioningInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ProvisioningInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "state": types.StringType, @@ -8260,13 +16959,60 @@ func (a ProvisioningStatus) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ProvisioningStatus in the Terraform plugin framework type -// system. -func (a ProvisioningStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ProvisioningStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o ProvisioningStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ProvisioningStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ProvisioningStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ProvisioningStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ProvisioningStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ProvisioningStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ProvisioningStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "initial_pipeline_sync_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.ToObjectType(ctx), + ElemType: PipelineProgress{}.Type(ctx), }, }, } @@ -8305,9 +17051,56 @@ func (a QuotaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of QuotaInfo in the Terraform plugin framework type -// system. -func (a QuotaInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QuotaInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o QuotaInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QuotaInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QuotaInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QuotaInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QuotaInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QuotaInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QuotaInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_refreshed_at": types.Int64Type, @@ -8348,9 +17141,56 @@ func (a R2Credentials) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of R2Credentials in the Terraform plugin framework type -// system. -func (a R2Credentials) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = R2Credentials{} + +// Equal implements basetypes.ObjectValuable. +func (o R2Credentials) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o R2Credentials) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o R2Credentials) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o R2Credentials) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o R2Credentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o R2Credentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o R2Credentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_key_id": types.StringType, @@ -8386,9 +17226,56 @@ func (a ReadVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ReadVolumeRequest in the Terraform plugin framework type -// system. -func (a ReadVolumeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReadVolumeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReadVolumeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_browse": types.BoolType, @@ -8422,9 +17309,56 @@ func (a RegenerateDashboardRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of RegenerateDashboardRequest in the Terraform plugin framework type -// system. -func (a RegenerateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegenerateDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegenerateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -8457,9 +17391,56 @@ func (a RegenerateDashboardResponse) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of RegenerateDashboardResponse in the Terraform plugin framework type -// system. -func (a RegenerateDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegenerateDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegenerateDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -8493,9 +17474,56 @@ func (a RegisteredModelAlias) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of RegisteredModelAlias in the Terraform plugin framework type -// system. -func (a RegisteredModelAlias) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelAlias{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelAlias) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias_name": types.StringType, @@ -8559,13 +17587,60 @@ func (a RegisteredModelInfo) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of RegisteredModelInfo in the Terraform plugin framework type -// system. -func (a RegisteredModelInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aliases": basetypes.ListType{ - ElemType: RegisteredModelAlias{}.ToObjectType(ctx), + ElemType: RegisteredModelAlias{}.Type(ctx), }, "browse_only": types.BoolType, "catalog_name": types.StringType, @@ -8607,9 +17682,56 @@ func (a RunRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunRefreshRequest in the Terraform plugin framework type -// system. -func (a RunRefreshRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunRefreshRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RunRefreshRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunRefreshRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunRefreshRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunRefreshRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunRefreshRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunRefreshRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunRefreshRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_name": types.StringType, @@ -8679,9 +17801,56 @@ func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of SchemaInfo in the Terraform plugin framework type -// system. -func (a SchemaInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SchemaInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o SchemaInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SchemaInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SchemaInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SchemaInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SchemaInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SchemaInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SchemaInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "browse_only": types.BoolType, @@ -8691,7 +17860,7 @@ func (a SchemaInfo) ToObjectType(ctx context.Context) types.ObjectType { "created_at": types.Int64Type, "created_by": types.StringType, "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.ToObjectType(ctx), + ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), }, "enable_predictive_optimization": types.StringType, "full_name": types.StringType, @@ -8736,13 +17905,60 @@ func (a SetArtifactAllowlist) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of SetArtifactAllowlist in the Terraform plugin framework type -// system. -func (a SetArtifactAllowlist) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetArtifactAllowlist{} + +// Equal implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetArtifactAllowlist) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_matchers": basetypes.ListType{ - ElemType: ArtifactMatcher{}.ToObjectType(ctx), + ElemType: ArtifactMatcher{}.Type(ctx), }, "artifact_type": types.StringType, }, @@ -8775,9 +17991,56 @@ func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetRegisteredModelAliasRequest in the Terraform plugin framework type -// system. -func (a SetRegisteredModelAliasRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetRegisteredModelAliasRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetRegisteredModelAliasRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alias": types.StringType, @@ -8813,9 +18076,56 @@ func (a SseEncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of SseEncryptionDetails in the Terraform plugin framework type -// system. -func (a SseEncryptionDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SseEncryptionDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SseEncryptionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "algorithm": types.StringType, @@ -8887,28 +18197,75 @@ func (a StorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of StorageCredentialInfo in the Terraform plugin framework type -// system. -func (a StorageCredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StorageCredentialInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StorageCredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleResponse{}.ToObjectType(ctx), + ElemType: AwsIamRoleResponse{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityResponse{}.ToObjectType(ctx), + ElemType: AzureManagedIdentityResponse{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToObjectType(ctx), + ElemType: CloudflareApiToken{}.Type(ctx), }, "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountResponse{}.ToObjectType(ctx), + ElemType: DatabricksGcpServiceAccountResponse{}.Type(ctx), }, "full_name": types.StringType, "id": types.StringType, @@ -8949,9 +18306,56 @@ func (a SystemSchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of SystemSchemaInfo in the Terraform plugin framework type -// system. -func (a SystemSchemaInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SystemSchemaInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SystemSchemaInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "schema": types.StringType, @@ -8992,19 +18396,66 @@ func (a TableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of TableConstraint in the Terraform plugin framework type -// system. -func (a TableConstraint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableConstraint{} + +// Equal implements basetypes.ObjectValuable. +func (o TableConstraint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableConstraint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableConstraint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableConstraint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "foreign_key_constraint": basetypes.ListType{ - ElemType: ForeignKeyConstraint{}.ToObjectType(ctx), + ElemType: ForeignKeyConstraint{}.Type(ctx), }, "named_table_constraint": basetypes.ListType{ - ElemType: NamedTableConstraint{}.ToObjectType(ctx), + ElemType: NamedTableConstraint{}.Type(ctx), }, "primary_key_constraint": basetypes.ListType{ - ElemType: PrimaryKeyConstraint{}.ToObjectType(ctx), + ElemType: PrimaryKeyConstraint{}.Type(ctx), }, }, } @@ -9034,9 +18485,56 @@ func (a TableDependency) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of TableDependency in the Terraform plugin framework type -// system. -func (a TableDependency) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableDependency{} + +// Equal implements basetypes.ObjectValuable. +func (o TableDependency) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableDependency) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableDependency) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableDependency) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableDependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableDependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableDependency) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_full_name": types.StringType, @@ -9066,9 +18564,56 @@ func (a TableExistsResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of TableExistsResponse in the Terraform plugin framework type -// system. -func (a TableExistsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableExistsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o TableExistsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableExistsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableExistsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableExistsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableExistsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableExistsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableExistsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "table_exists": types.BoolType, @@ -9182,16 +18727,63 @@ func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of TableInfo in the Terraform plugin framework type -// system. -func (a TableInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o TableInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, "browse_only": types.BoolType, "catalog_name": types.StringType, "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.ToObjectType(ctx), + ElemType: ColumnInfo{}.Type(ctx), }, "comment": types.StringType, "created_at": types.Int64Type, @@ -9200,14 +18792,14 @@ func (a TableInfo) ToObjectType(ctx context.Context) types.ObjectType { "data_source_format": types.StringType, "deleted_at": types.Int64Type, "delta_runtime_properties_kvpairs": basetypes.ListType{ - ElemType: DeltaRuntimePropertiesKvPairs{}.ToObjectType(ctx), + ElemType: DeltaRuntimePropertiesKvPairs{}.Type(ctx), }, "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.ToObjectType(ctx), + ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), }, "enable_predictive_optimization": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToObjectType(ctx), + ElemType: EncryptionDetails{}.Type(ctx), }, "full_name": types.StringType, "metastore_id": types.StringType, @@ -9218,14 +18810,14 @@ func (a TableInfo) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "row_filter": basetypes.ListType{ - ElemType: TableRowFilter{}.ToObjectType(ctx), + ElemType: TableRowFilter{}.Type(ctx), }, "schema_name": types.StringType, "sql_path": types.StringType, "storage_credential_name": types.StringType, "storage_location": types.StringType, "table_constraints": basetypes.ListType{ - ElemType: TableConstraint{}.ToObjectType(ctx), + ElemType: TableConstraint{}.Type(ctx), }, "table_id": types.StringType, "table_type": types.StringType, @@ -9233,7 +18825,7 @@ func (a TableInfo) ToObjectType(ctx context.Context) types.ObjectType { "updated_by": types.StringType, "view_definition": types.StringType, "view_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.ToObjectType(ctx), + ElemType: DependencyList{}.Type(ctx), }, }, } @@ -9267,9 +18859,56 @@ func (a TableRowFilter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of TableRowFilter in the Terraform plugin framework type -// system. -func (a TableRowFilter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableRowFilter{} + +// Equal implements basetypes.ObjectValuable. +func (o TableRowFilter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableRowFilter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableRowFilter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableRowFilter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableRowFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableRowFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableRowFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "function_name": types.StringType, @@ -9304,9 +18943,56 @@ func (a TableSummary) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of TableSummary in the Terraform plugin framework type -// system. -func (a TableSummary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableSummary{} + +// Equal implements basetypes.ObjectValuable. +func (o TableSummary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableSummary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableSummary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableSummary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableSummary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableSummary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -9348,16 +19034,63 @@ func (a TemporaryCredentials) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of TemporaryCredentials in the Terraform plugin framework type -// system. -func (a TemporaryCredentials) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TemporaryCredentials{} + +// Equal implements basetypes.ObjectValuable. +func (o TemporaryCredentials) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TemporaryCredentials) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TemporaryCredentials) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TemporaryCredentials) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TemporaryCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TemporaryCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TemporaryCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_temp_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.ToObjectType(ctx), + ElemType: AwsCredentials{}.Type(ctx), }, "azure_aad": basetypes.ListType{ - ElemType: AzureActiveDirectoryToken{}.ToObjectType(ctx), + ElemType: AzureActiveDirectoryToken{}.Type(ctx), }, "expiration_time": types.Int64Type, }, @@ -9397,15 +19130,62 @@ func (a TriggeredUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of TriggeredUpdateStatus in the Terraform plugin framework type -// system. -func (a TriggeredUpdateStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TriggeredUpdateStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TriggeredUpdateStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_processed_commit_version": types.Int64Type, "timestamp": types.StringType, "triggered_update_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.ToObjectType(ctx), + ElemType: PipelineProgress{}.Type(ctx), }, }, } @@ -9436,9 +19216,56 @@ func (a UnassignRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of UnassignRequest in the Terraform plugin framework type -// system. -func (a UnassignRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UnassignRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UnassignRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UnassignRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UnassignRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UnassignRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UnassignRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UnassignRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UnassignRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metastore_id": types.StringType, @@ -9467,9 +19294,56 @@ func (a UnassignResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of UnassignResponse in the Terraform plugin framework type -// system. -func (a UnassignResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UnassignResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UnassignResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UnassignResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UnassignResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UnassignResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UnassignResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UnassignResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UnassignResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -9495,9 +19369,56 @@ func (a UpdateAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateAssignmentResponse in the Terraform plugin framework type -// system. -func (a UpdateAssignmentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAssignmentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAssignmentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -9541,9 +19462,56 @@ func (a UpdateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of UpdateCatalog in the Terraform plugin framework type -// system. -func (a UpdateCatalog) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCatalog{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCatalog) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCatalog) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCatalog) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCatalog) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCatalog) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCatalog) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCatalog) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -9589,9 +19557,56 @@ func (a UpdateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of UpdateConnection in the Terraform plugin framework type -// system. -func (a UpdateConnection) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateConnection{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateConnection) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateConnection) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateConnection) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateConnection) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateConnection) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateConnection) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateConnection) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -9655,19 +19670,66 @@ func (a UpdateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of UpdateCredentialRequest in the Terraform plugin framework type -// system. -func (a UpdateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToObjectType(ctx), + ElemType: AwsIamRole{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToObjectType(ctx), + ElemType: AzureManagedIdentity{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "comment": types.StringType, "force": types.BoolType, @@ -9733,16 +19795,63 @@ func (a UpdateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of UpdateExternalLocation in the Terraform plugin framework type -// system. -func (a UpdateExternalLocation) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExternalLocation{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExternalLocation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, "comment": types.StringType, "credential_name": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToObjectType(ctx), + ElemType: EncryptionDetails{}.Type(ctx), }, "fallback": types.BoolType, "force": types.BoolType, @@ -9782,9 +19891,56 @@ func (a UpdateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateFunction in the Terraform plugin framework type -// system. -func (a UpdateFunction) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateFunction{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateFunction) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateFunction) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateFunction) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateFunction) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateFunction) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateFunction) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateFunction) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -9831,9 +19987,56 @@ func (a UpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateMetastore in the Terraform plugin framework type -// system. -func (a UpdateMetastore) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateMetastore{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateMetastore) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateMetastore) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateMetastore) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateMetastore) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "delta_sharing_organization_name": types.StringType, @@ -9876,9 +20079,56 @@ func (a UpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateMetastoreAssignment in the Terraform plugin framework type -// system. -func (a UpdateMetastoreAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateMetastoreAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_catalog_name": types.StringType, @@ -9914,9 +20164,56 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type -// system. -func (a UpdateModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -9988,38 +20285,85 @@ func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of UpdateMonitor in the Terraform plugin framework type -// system. -func (a UpdateMonitor) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateMonitor{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateMonitor) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateMonitor) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateMonitor) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateMonitor) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateMonitor) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateMonitor) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "baseline_table_name": types.StringType, "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.ToObjectType(ctx), + ElemType: MonitorMetric{}.Type(ctx), }, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.ToObjectType(ctx), + ElemType: MonitorDataClassificationConfig{}.Type(ctx), }, "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.ToObjectType(ctx), + ElemType: MonitorInferenceLog{}.Type(ctx), }, "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.ToObjectType(ctx), + ElemType: MonitorNotifications{}.Type(ctx), }, "output_schema_name": types.StringType, "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.ToObjectType(ctx), + ElemType: MonitorCronSchedule{}.Type(ctx), }, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.ToObjectType(ctx), + ElemType: MonitorSnapshot{}.Type(ctx), }, "table_name": types.StringType, "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.ToObjectType(ctx), + ElemType: MonitorTimeSeries{}.Type(ctx), }, }, } @@ -10053,13 +20397,60 @@ func (a UpdatePermissions) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of UpdatePermissions in the Terraform plugin framework type -// system. -func (a UpdatePermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "changes": basetypes.ListType{ - ElemType: PermissionsChange{}.ToObjectType(ctx), + ElemType: PermissionsChange{}.Type(ctx), }, "full_name": types.StringType, "securable_type": types.StringType, @@ -10095,9 +20486,56 @@ func (a UpdateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateRegisteredModelRequest in the Terraform plugin framework type -// system. -func (a UpdateRegisteredModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRegisteredModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRegisteredModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -10128,9 +20566,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -10171,9 +20656,56 @@ func (a UpdateSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of UpdateSchema in the Terraform plugin framework type -// system. -func (a UpdateSchema) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateSchema{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateSchema) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateSchema) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateSchema) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateSchema) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateSchema) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateSchema) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -10242,26 +20774,73 @@ func (a UpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of UpdateStorageCredential in the Terraform plugin framework type -// system. -func (a UpdateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateStorageCredential{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.ToObjectType(ctx), + ElemType: AwsIamRoleRequest{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityResponse{}.ToObjectType(ctx), + ElemType: AzureManagedIdentityResponse{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToObjectType(ctx), + ElemType: CloudflareApiToken{}.Type(ctx), }, "comment": types.StringType, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.ToObjectType(ctx), + ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), }, "force": types.BoolType, "isolation_mode": types.StringType, @@ -10299,9 +20878,56 @@ func (a UpdateTableRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateTableRequest in the Terraform plugin framework type -// system. -func (a UpdateTableRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateTableRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateTableRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateTableRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateTableRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateTableRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_name": types.StringType, @@ -10338,9 +20964,56 @@ func (a UpdateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateVolumeRequestContent in the Terraform plugin framework type -// system. -func (a UpdateVolumeRequestContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateVolumeRequestContent{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateVolumeRequestContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -10380,9 +21053,56 @@ func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of UpdateWorkspaceBindings in the Terraform plugin framework type -// system. -func (a UpdateWorkspaceBindings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateWorkspaceBindings{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assign_workspaces": basetypes.ListType{ @@ -10427,16 +21147,63 @@ func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of UpdateWorkspaceBindingsParameters in the Terraform plugin framework type -// system. -func (a UpdateWorkspaceBindingsParameters) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateWorkspaceBindingsParameters{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateWorkspaceBindingsParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "add": basetypes.ListType{ - ElemType: WorkspaceBinding{}.ToObjectType(ctx), + ElemType: WorkspaceBinding{}.Type(ctx), }, "remove": basetypes.ListType{ - ElemType: WorkspaceBinding{}.ToObjectType(ctx), + ElemType: WorkspaceBinding{}.Type(ctx), }, "securable_name": types.StringType, "securable_type": types.StringType, @@ -10486,16 +21253,63 @@ func (a ValidateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ValidateCredentialRequest in the Terraform plugin framework type -// system. -func (a ValidateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ValidateCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ValidateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.ToObjectType(ctx), + ElemType: AwsIamRole{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.ToObjectType(ctx), + ElemType: AzureManagedIdentity{}.Type(ctx), }, "credential_name": types.StringType, "external_location_name": types.StringType, @@ -10533,14 +21347,61 @@ func (a ValidateCredentialResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ValidateCredentialResponse in the Terraform plugin framework type -// system. -func (a ValidateCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ValidateCredentialResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ValidateCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, "results": basetypes.ListType{ - ElemType: CredentialValidationResult{}.ToObjectType(ctx), + ElemType: CredentialValidationResult{}.Type(ctx), }, }, } @@ -10590,25 +21451,72 @@ func (a ValidateStorageCredential) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ValidateStorageCredential in the Terraform plugin framework type -// system. -func (a ValidateStorageCredential) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ValidateStorageCredential{} + +// Equal implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ValidateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.ToObjectType(ctx), + ElemType: AwsIamRoleRequest{}.Type(ctx), }, "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityRequest{}.ToObjectType(ctx), + ElemType: AzureManagedIdentityRequest{}.Type(ctx), }, "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.ToObjectType(ctx), + ElemType: AzureServicePrincipal{}.Type(ctx), }, "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.ToObjectType(ctx), + ElemType: CloudflareApiToken{}.Type(ctx), }, "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.ToObjectType(ctx), + ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), }, "external_location_name": types.StringType, "read_only": types.BoolType, @@ -10644,14 +21552,61 @@ func (a ValidateStorageCredentialResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of ValidateStorageCredentialResponse in the Terraform plugin framework type -// system. -func (a ValidateStorageCredentialResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ValidateStorageCredentialResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ValidateStorageCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, "results": basetypes.ListType{ - ElemType: ValidationResult{}.ToObjectType(ctx), + ElemType: ValidationResult{}.Type(ctx), }, }, } @@ -10683,9 +21638,56 @@ func (a ValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of ValidationResult in the Terraform plugin framework type -// system. -func (a ValidationResult) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ValidationResult{} + +// Equal implements basetypes.ObjectValuable. +func (o ValidationResult) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ValidationResult) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ValidationResult) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ValidationResult) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ValidationResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ValidationResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ValidationResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -10753,9 +21755,56 @@ func (a VolumeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of VolumeInfo in the Terraform plugin framework type -// system. -func (a VolumeInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = VolumeInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o VolumeInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o VolumeInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o VolumeInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o VolumeInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o VolumeInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o VolumeInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o VolumeInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_point": types.StringType, @@ -10765,7 +21814,7 @@ func (a VolumeInfo) ToObjectType(ctx context.Context) types.ObjectType { "created_at": types.Int64Type, "created_by": types.StringType, "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.ToObjectType(ctx), + ElemType: EncryptionDetails{}.Type(ctx), }, "full_name": types.StringType, "metastore_id": types.StringType, @@ -10804,9 +21853,56 @@ func (a WorkspaceBinding) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of WorkspaceBinding in the Terraform plugin framework type -// system. -func (a WorkspaceBinding) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceBinding{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceBinding) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceBinding) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceBinding) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceBinding) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceBinding) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceBinding) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceBinding) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "binding_type": types.StringType, @@ -10844,15 +21940,163 @@ func (a WorkspaceBindingsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of WorkspaceBindingsResponse in the Terraform plugin framework type -// system. -func (a WorkspaceBindingsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceBindingsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceBindingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bindings": basetypes.ListType{ - ElemType: WorkspaceBinding{}.ToObjectType(ctx), + ElemType: WorkspaceBinding{}.Type(ctx), }, "next_page_token": types.StringType, }, } } + +// The artifact type + +// Kind of catalog securable. + +// Whether the current securable is accessible from all workspaces or a specific +// set of workspaces. + +// The type of the catalog. + +// Name of type (INT, STRUCT, MAP, etc.). + +// Kind of connection securable. + +// The type of connection. + +// Function parameter style. **S** is the value for SQL. + +// Function language. When **EXTERNAL** is used, the language of the routine +// function should be specified in the __external_language__ field, and the +// __return_params__ of the function cannot be used (as **TABLE** return type is +// not supported), and the __sql_data_access__ field must be **NO_SQL**. + +// The security type of the function. + +// Function SQL data access. + +// The type of credential. + +// Data source format + +// The type of the object from which the flag was inherited. If there was no +// inheritance, this field is left blank. + +// Whether predictive optimization should be enabled for this object and objects +// under it. + +// Function parameter style. **S** is the value for SQL. + +// Function language. When **EXTERNAL** is used, the language of the routine +// function should be specified in the __external_language__ field, and the +// __return_params__ of the function cannot be used (as **TABLE** return type is +// not supported), and the __sql_data_access__ field must be **NO_SQL**. + +// The security type of the function. + +// Function SQL data access. + +// The mode of the function parameter. + +// The type of function parameter. + +// The scope of Delta Sharing enabled for the metastore. + +// The artifact pattern matching type + +// The scope of Delta Sharing enabled for the metastore. + +// Current status of the model version. Newly created model versions start in +// PENDING_REGISTRATION status, then move to READY status once the model version +// files are uploaded and the model version is finalized. Only model versions in +// READY status can be loaded for inference or served. + +// Read only field that indicates whether a schedule is paused or not. + +// Problem type the model aims to solve. Determines the type of model-quality +// metrics that will be computed. + +// The status of the monitor. + +// Can only be one of ``"CUSTOM_METRIC_TYPE_AGGREGATE"``, +// ``"CUSTOM_METRIC_TYPE_DERIVED"``, or ``"CUSTOM_METRIC_TYPE_DRIFT"``. The +// ``"CUSTOM_METRIC_TYPE_AGGREGATE"`` and ``"CUSTOM_METRIC_TYPE_DERIVED"`` +// metrics are computed on a single table, whereas the +// ``"CUSTOM_METRIC_TYPE_DRIFT"`` compare metrics across baseline and input +// table, or across the two consecutive time windows. - +// CUSTOM_METRIC_TYPE_AGGREGATE: only depend on the existing columns in your +// table - CUSTOM_METRIC_TYPE_DERIVED: depend on previously computed aggregate +// metrics - CUSTOM_METRIC_TYPE_DRIFT: depend on previously computed aggregate +// or derived metrics + +// The current state of the refresh. + +// The method by which the refresh was triggered. + +// The state of an online table. + +// The type of Unity Catalog securable + +// The type of key encryption to use (affects headers from s3 client). + +// The current state of enablement for the system schema. An empty string means +// the system schema is available and ready for opt-in. + +// The scope of Delta Sharing enabled for the metastore. + +// A enum represents the result of the file operation + +// The operation tested. + +// The results of the tested operation. diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 17f615a5e9..416d83324d 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -12,11 +12,15 @@ package compute_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AddInstanceProfile struct { @@ -65,9 +69,56 @@ func (a AddInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of AddInstanceProfile in the Terraform plugin framework type -// system. -func (a AddInstanceProfile) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AddInstanceProfile{} + +// Equal implements basetypes.ObjectValuable. +func (o AddInstanceProfile) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AddInstanceProfile) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AddInstanceProfile) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AddInstanceProfile) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AddInstanceProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AddInstanceProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AddInstanceProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "iam_role_arn": types.StringType, @@ -98,9 +149,56 @@ func (a AddResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of AddResponse in the Terraform plugin framework type -// system. -func (a AddResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AddResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AddResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AddResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AddResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AddResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AddResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AddResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AddResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -129,9 +227,56 @@ func (a Adlsgen2Info) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of Adlsgen2Info in the Terraform plugin framework type -// system. -func (a Adlsgen2Info) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Adlsgen2Info{} + +// Equal implements basetypes.ObjectValuable. +func (o Adlsgen2Info) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Adlsgen2Info) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Adlsgen2Info) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Adlsgen2Info) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Adlsgen2Info) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Adlsgen2Info) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Adlsgen2Info) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -167,9 +312,56 @@ func (a AutoScale) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of AutoScale in the Terraform plugin framework type -// system. -func (a AutoScale) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AutoScale{} + +// Equal implements basetypes.ObjectValuable. +func (o AutoScale) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AutoScale) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AutoScale) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AutoScale) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AutoScale) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AutoScale) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AutoScale) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_workers": types.Int64Type, @@ -281,9 +473,56 @@ func (a AwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of AwsAttributes in the Terraform plugin framework type -// system. -func (a AwsAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -345,15 +584,62 @@ func (a AzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of AzureAttributes in the Terraform plugin framework type -// system. -func (a AzureAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, "first_on_demand": types.Int64Type, "log_analytics_info": basetypes.ListType{ - ElemType: LogAnalyticsInfo{}.ToObjectType(ctx), + ElemType: LogAnalyticsInfo{}.Type(ctx), }, "spot_bid_max_price": types.Float64Type, }, @@ -385,9 +671,56 @@ func (a CancelCommand) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelCommand in the Terraform plugin framework type -// system. -func (a CancelCommand) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelCommand{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelCommand) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelCommand) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelCommand) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelCommand) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelCommand) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelCommand) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelCommand) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -417,9 +750,56 @@ func (a CancelResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelResponse in the Terraform plugin framework type -// system. -func (a CancelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -449,9 +829,56 @@ func (a ChangeClusterOwner) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ChangeClusterOwner in the Terraform plugin framework type -// system. -func (a ChangeClusterOwner) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ChangeClusterOwner{} + +// Equal implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ChangeClusterOwner) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -480,9 +907,56 @@ func (a ChangeClusterOwnerResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of ChangeClusterOwnerResponse in the Terraform plugin framework type -// system. -func (a ChangeClusterOwnerResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ChangeClusterOwnerResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ChangeClusterOwnerResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -512,9 +986,56 @@ func (a ClientsTypes) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClientsTypes in the Terraform plugin framework type -// system. -func (a ClientsTypes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClientsTypes{} + +// Equal implements basetypes.ObjectValuable. +func (o ClientsTypes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClientsTypes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClientsTypes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClientsTypes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClientsTypes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClientsTypes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClientsTypes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "jobs": types.BoolType, @@ -545,9 +1066,56 @@ func (a CloneCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of CloneCluster in the Terraform plugin framework type -// system. -func (a CloneCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CloneCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o CloneCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CloneCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CloneCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CloneCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CloneCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CloneCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CloneCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "source_cluster_id": types.StringType, @@ -578,9 +1146,56 @@ func (a CloudProviderNodeInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CloudProviderNodeInfo in the Terraform plugin framework type -// system. -func (a CloudProviderNodeInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CloudProviderNodeInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CloudProviderNodeInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "status": basetypes.ListType{ @@ -618,9 +1233,56 @@ func (a ClusterAccessControlRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterAccessControlRequest in the Terraform plugin framework type -// system. -func (a ClusterAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -663,13 +1325,60 @@ func (a ClusterAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ClusterAccessControlResponse in the Terraform plugin framework type -// system. -func (a ClusterAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ClusterPermission{}.ToObjectType(ctx), + ElemType: ClusterPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -841,20 +1550,67 @@ func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ClusterAttributes in the Terraform plugin framework type -// system. -func (a ClusterAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToObjectType(ctx), + ElemType: AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToObjectType(ctx), + ElemType: AzureAttributes{}.Type(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToObjectType(ctx), + ElemType: ClusterLogConf{}.Type(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -862,17 +1618,17 @@ func (a ClusterAttributes) ToObjectType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToObjectType(ctx), + ElemType: GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -890,7 +1646,7 @@ func (a ClusterAttributes) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToObjectType(ctx), + ElemType: WorkloadType{}.Type(ctx), }, }, } @@ -928,9 +1684,56 @@ func (a ClusterCompliance) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ClusterCompliance in the Terraform plugin framework type -// system. -func (a ClusterCompliance) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterCompliance{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterCompliance) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterCompliance) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterCompliance) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterCompliance) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterCompliance) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterCompliance) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterCompliance) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -1194,28 +1997,75 @@ func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ClusterDetails in the Terraform plugin framework type -// system. -func (a ClusterDetails) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterDetails) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToObjectType(ctx), + ElemType: AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToObjectType(ctx), + ElemType: AzureAttributes{}.Type(ctx), }, "cluster_cores": types.Float64Type, "cluster_id": types.StringType, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToObjectType(ctx), + ElemType: ClusterLogConf{}.Type(ctx), }, "cluster_log_status": basetypes.ListType{ - ElemType: LogSyncStatus{}.ToObjectType(ctx), + ElemType: LogSyncStatus{}.Type(ctx), }, "cluster_memory_mb": types.Int64Type, "cluster_name": types.StringType, @@ -1229,23 +2079,23 @@ func (a ClusterDetails) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "driver": basetypes.ListType{ - ElemType: SparkNode{}.ToObjectType(ctx), + ElemType: SparkNode{}.Type(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "executors": basetypes.ListType{ - ElemType: SparkNode{}.ToObjectType(ctx), + ElemType: SparkNode{}.Type(ctx), }, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToObjectType(ctx), + ElemType: GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "jdbc_port": types.Int64Type, @@ -1265,7 +2115,7 @@ func (a ClusterDetails) ToObjectType(ctx context.Context) types.ObjectType { }, "spark_version": types.StringType, "spec": basetypes.ListType{ - ElemType: ClusterSpec{}.ToObjectType(ctx), + ElemType: ClusterSpec{}.Type(ctx), }, "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, @@ -1275,10 +2125,10 @@ func (a ClusterDetails) ToObjectType(ctx context.Context) types.ObjectType { "state_message": types.StringType, "terminated_time": types.Int64Type, "termination_reason": basetypes.ListType{ - ElemType: TerminationReason{}.ToObjectType(ctx), + ElemType: TerminationReason{}.Type(ctx), }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToObjectType(ctx), + ElemType: WorkloadType{}.Type(ctx), }, }, } @@ -1296,7 +2146,7 @@ type ClusterEvent struct { // by the Timeline service. Timestamp types.Int64 `tfsdk:"timestamp" tf:"optional"` - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *ClusterEvent) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterEvent) { @@ -1319,17 +2169,64 @@ func (a ClusterEvent) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ClusterEvent in the Terraform plugin framework type -// system. -func (a ClusterEvent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterEvent{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterEvent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterEvent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterEvent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterEvent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterEvent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterEvent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterEvent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "data_plane_event_details": basetypes.ListType{ - ElemType: DataPlaneEventDetails{}.ToObjectType(ctx), + ElemType: DataPlaneEventDetails{}.Type(ctx), }, "details": basetypes.ListType{ - ElemType: EventDetails{}.ToObjectType(ctx), + ElemType: EventDetails{}.Type(ctx), }, "timestamp": types.Int64Type, "type": types.StringType, @@ -1363,14 +2260,61 @@ func (a ClusterLibraryStatuses) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ClusterLibraryStatuses in the Terraform plugin framework type -// system. -func (a ClusterLibraryStatuses) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterLibraryStatuses{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterLibraryStatuses) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "library_statuses": basetypes.ListType{ - ElemType: LibraryFullStatus{}.ToObjectType(ctx), + ElemType: LibraryFullStatus{}.Type(ctx), }, }, } @@ -1408,16 +2352,63 @@ func (a ClusterLogConf) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ClusterLogConf in the Terraform plugin framework type -// system. -func (a ClusterLogConf) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterLogConf{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterLogConf) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterLogConf) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterLogConf) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterLogConf) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterLogConf) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterLogConf) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterLogConf) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbfs": basetypes.ListType{ - ElemType: DbfsStorageInfo{}.ToObjectType(ctx), + ElemType: DbfsStorageInfo{}.Type(ctx), }, "s3": basetypes.ListType{ - ElemType: S3StorageInfo{}.ToObjectType(ctx), + ElemType: S3StorageInfo{}.Type(ctx), }, }, } @@ -1450,9 +2441,56 @@ func (a ClusterPermission) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ClusterPermission in the Terraform plugin framework type -// system. -func (a ClusterPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1491,13 +2529,60 @@ func (a ClusterPermissions) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ClusterPermissions in the Terraform plugin framework type -// system. -func (a ClusterPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterAccessControlResponse{}.ToObjectType(ctx), + ElemType: ClusterAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1528,9 +2613,56 @@ func (a ClusterPermissionsDescription) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterPermissionsDescription in the Terraform plugin framework type -// system. -func (a ClusterPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1564,13 +2696,60 @@ func (a ClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ClusterPermissionsRequest in the Terraform plugin framework type -// system. -func (a ClusterPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterAccessControlRequest{}.ToObjectType(ctx), + ElemType: ClusterAccessControlRequest{}.Type(ctx), }, "cluster_id": types.StringType, }, @@ -1605,9 +2784,56 @@ func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterPolicyAccessControlRequest in the Terraform plugin framework type -// system. -func (a ClusterPolicyAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPolicyAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1650,13 +2876,60 @@ func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of ClusterPolicyAccessControlResponse in the Terraform plugin framework type -// system. -func (a ClusterPolicyAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPolicyAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPolicyAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ClusterPolicyPermission{}.ToObjectType(ctx), + ElemType: ClusterPolicyPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1693,9 +2966,56 @@ func (a ClusterPolicyPermission) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ClusterPolicyPermission in the Terraform plugin framework type -// system. -func (a ClusterPolicyPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPolicyPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPolicyPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1734,13 +3054,60 @@ func (a ClusterPolicyPermissions) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of ClusterPolicyPermissions in the Terraform plugin framework type -// system. -func (a ClusterPolicyPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPolicyPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterPolicyAccessControlResponse{}.ToObjectType(ctx), + ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1771,9 +3138,56 @@ func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterPolicyPermissionsDescription in the Terraform plugin framework type -// system. -func (a ClusterPolicyPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPolicyPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1807,13 +3221,60 @@ func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of ClusterPolicyPermissionsRequest in the Terraform plugin framework type -// system. -func (a ClusterPolicyPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterPolicyPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ClusterPolicyAccessControlRequest{}.ToObjectType(ctx), + ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx), }, "cluster_policy_id": types.StringType, }, @@ -1854,9 +3315,56 @@ func (a ClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterSettingsChange in the Terraform plugin framework type -// system. -func (a ClusterSettingsChange) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterSettingsChange{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterSettingsChange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "field": types.StringType, @@ -1903,13 +3411,60 @@ func (a ClusterSize) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of ClusterSize in the Terraform plugin framework type -// system. -func (a ClusterSize) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterSize{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterSize) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterSize) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterSize) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterSize) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterSize) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterSize) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterSize) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "num_workers": types.Int64Type, }, @@ -2098,24 +3653,71 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of ClusterSpec in the Terraform plugin framework type -// system. -func (a ClusterSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToObjectType(ctx), + ElemType: AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToObjectType(ctx), + ElemType: AzureAttributes{}.Type(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToObjectType(ctx), + ElemType: ClusterLogConf{}.Type(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -2123,17 +3725,17 @@ func (a ClusterSpec) ToObjectType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToObjectType(ctx), + ElemType: GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -2152,7 +3754,7 @@ func (a ClusterSpec) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToObjectType(ctx), + ElemType: WorkloadType{}.Type(ctx), }, }, } @@ -2181,9 +3783,56 @@ func (a ClusterStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterStatus in the Terraform plugin framework type -// system. -func (a ClusterStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -2219,9 +3868,56 @@ func (a Command) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of Command in the Terraform plugin framework type -// system. -func (a Command) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Command{} + +// Equal implements basetypes.ObjectValuable. +func (o Command) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Command) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Command) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Command) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Command) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Command) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Command) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2258,9 +3954,56 @@ func (a CommandStatusRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of CommandStatusRequest in the Terraform plugin framework type -// system. -func (a CommandStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CommandStatusRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CommandStatusRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CommandStatusRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CommandStatusRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CommandStatusRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CommandStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CommandStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CommandStatusRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2297,14 +4040,61 @@ func (a CommandStatusResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CommandStatusResponse in the Terraform plugin framework type -// system. -func (a CommandStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CommandStatusResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CommandStatusResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CommandStatusResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CommandStatusResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CommandStatusResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CommandStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CommandStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CommandStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "results": basetypes.ListType{ - ElemType: Results{}.ToObjectType(ctx), + ElemType: Results{}.Type(ctx), }, "status": types.StringType, }, @@ -2335,9 +4125,56 @@ func (a ContextStatusRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ContextStatusRequest in the Terraform plugin framework type -// system. -func (a ContextStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ContextStatusRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ContextStatusRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ContextStatusRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ContextStatusRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ContextStatusRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ContextStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ContextStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ContextStatusRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2369,9 +4206,56 @@ func (a ContextStatusResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ContextStatusResponse in the Terraform plugin framework type -// system. -func (a ContextStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ContextStatusResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ContextStatusResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ContextStatusResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ContextStatusResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ContextStatusResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ContextStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ContextStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ContextStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -2566,27 +4450,74 @@ func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of CreateCluster in the Terraform plugin framework type -// system. -func (a CreateCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToObjectType(ctx), + ElemType: AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToObjectType(ctx), + ElemType: AzureAttributes{}.Type(ctx), }, "clone_from": basetypes.ListType{ - ElemType: CloneCluster{}.ToObjectType(ctx), + ElemType: CloneCluster{}.Type(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToObjectType(ctx), + ElemType: ClusterLogConf{}.Type(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -2594,17 +4525,17 @@ func (a CreateCluster) ToObjectType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToObjectType(ctx), + ElemType: GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -2623,7 +4554,7 @@ func (a CreateCluster) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToObjectType(ctx), + ElemType: WorkloadType{}.Type(ctx), }, }, } @@ -2650,9 +4581,56 @@ func (a CreateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateClusterResponse in the Terraform plugin framework type -// system. -func (a CreateClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -2684,9 +4662,56 @@ func (a CreateContext) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateContext in the Terraform plugin framework type -// system. -func (a CreateContext) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateContext{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateContext) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateContext) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateContext) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateContext) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateContext) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateContext) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateContext) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -2777,26 +4802,73 @@ func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateInstancePool in the Terraform plugin framework type -// system. -func (a CreateInstancePool) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateInstancePool{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateInstancePool) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateInstancePool) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateInstancePool) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateInstancePool) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolAwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolAzureAttributes{}.Type(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.ToObjectType(ctx), + ElemType: DiskSpec{}.Type(ctx), }, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolGcpAttributes{}.Type(ctx), }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_name": types.StringType, @@ -2804,7 +4876,7 @@ func (a CreateInstancePool) ToObjectType(ctx context.Context) types.ObjectType { "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, @@ -2835,9 +4907,56 @@ func (a CreateInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateInstancePoolResponse in the Terraform plugin framework type -// system. -func (a CreateInstancePoolResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateInstancePoolResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateInstancePoolResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -2900,15 +5019,62 @@ func (a CreatePolicy) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of CreatePolicy in the Terraform plugin framework type -// system. -func (a CreatePolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToObjectType(ctx), + ElemType: Library{}.Type(ctx), }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, @@ -2940,9 +5106,56 @@ func (a CreatePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreatePolicyResponse in the Terraform plugin framework type -// system. -func (a CreatePolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePolicyResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_id": types.StringType, @@ -2972,9 +5185,56 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type -// system. -func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "script_id": types.StringType, @@ -3003,9 +5263,56 @@ func (a Created) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of Created in the Terraform plugin framework type -// system. -func (a Created) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Created{} + +// Equal implements basetypes.ObjectValuable. +func (o Created) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Created) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Created) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Created) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Created) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Created) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Created) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3041,9 +5348,56 @@ func (a DataPlaneEventDetails) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DataPlaneEventDetails in the Terraform plugin framework type -// system. -func (a DataPlaneEventDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DataPlaneEventDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DataPlaneEventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "event_type": types.StringType, @@ -3076,9 +5430,56 @@ func (a DbfsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DbfsStorageInfo in the Terraform plugin framework type -// system. -func (a DbfsStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DbfsStorageInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DbfsStorageInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -3108,10 +5509,57 @@ func (a DeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCluster in the Terraform plugin framework type -// system. -func (a DeleteCluster) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCluster) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, }, @@ -3138,9 +5586,56 @@ func (a DeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteClusterResponse in the Terraform plugin framework type -// system. -func (a DeleteClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3169,9 +5664,56 @@ func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteGlobalInitScriptRequest in the Terraform plugin framework type -// system. -func (a DeleteGlobalInitScriptRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteGlobalInitScriptRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteGlobalInitScriptRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "script_id": types.StringType, @@ -3201,9 +5743,56 @@ func (a DeleteInstancePool) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteInstancePool in the Terraform plugin framework type -// system. -func (a DeleteInstancePool) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteInstancePool{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteInstancePool) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteInstancePool) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteInstancePool) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteInstancePool) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -3231,9 +5820,56 @@ func (a DeleteInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteInstancePoolResponse in the Terraform plugin framework type -// system. -func (a DeleteInstancePoolResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteInstancePoolResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteInstancePoolResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3261,9 +5897,56 @@ func (a DeletePolicy) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePolicy in the Terraform plugin framework type -// system. -func (a DeletePolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_id": types.StringType, @@ -3291,9 +5974,56 @@ func (a DeletePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePolicyResponse in the Terraform plugin framework type -// system. -func (a DeletePolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePolicyResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3319,9 +6049,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3350,9 +6127,56 @@ func (a DestroyContext) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DestroyContext in the Terraform plugin framework type -// system. -func (a DestroyContext) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DestroyContext{} + +// Equal implements basetypes.ObjectValuable. +func (o DestroyContext) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DestroyContext) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DestroyContext) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DestroyContext) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DestroyContext) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DestroyContext) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DestroyContext) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusterId": types.StringType, @@ -3381,9 +6205,56 @@ func (a DestroyResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DestroyResponse in the Terraform plugin framework type -// system. -func (a DestroyResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DestroyResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DestroyResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DestroyResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DestroyResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DestroyResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DestroyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DestroyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DestroyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3443,9 +6314,56 @@ func (a DiskSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of DiskSpec in the Terraform plugin framework type -// system. -func (a DiskSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DiskSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o DiskSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DiskSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DiskSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DiskSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DiskSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DiskSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DiskSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disk_count": types.Int64Type, @@ -3453,7 +6371,7 @@ func (a DiskSpec) ToObjectType(ctx context.Context) types.ObjectType { "disk_size": types.Int64Type, "disk_throughput": types.Int64Type, "disk_type": basetypes.ListType{ - ElemType: DiskType{}.ToObjectType(ctx), + ElemType: DiskType{}.Type(ctx), }, }, } @@ -3482,9 +6400,56 @@ func (a DiskType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of DiskType in the Terraform plugin framework type -// system. -func (a DiskType) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DiskType{} + +// Equal implements basetypes.ObjectValuable. +func (o DiskType) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DiskType) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DiskType) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DiskType) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DiskType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DiskType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DiskType) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "azure_disk_volume_type": types.StringType, @@ -3517,9 +6482,56 @@ func (a DockerBasicAuth) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DockerBasicAuth in the Terraform plugin framework type -// system. -func (a DockerBasicAuth) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DockerBasicAuth{} + +// Equal implements basetypes.ObjectValuable. +func (o DockerBasicAuth) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DockerBasicAuth) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DockerBasicAuth) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DockerBasicAuth) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DockerBasicAuth) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DockerBasicAuth) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DockerBasicAuth) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "password": types.StringType, @@ -3553,13 +6565,60 @@ func (a DockerImage) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of DockerImage in the Terraform plugin framework type -// system. -func (a DockerImage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DockerImage{} + +// Equal implements basetypes.ObjectValuable. +func (o DockerImage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DockerImage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DockerImage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DockerImage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DockerImage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DockerImage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DockerImage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "basic_auth": basetypes.ListType{ - ElemType: DockerBasicAuth{}.ToObjectType(ctx), + ElemType: DockerBasicAuth{}.Type(ctx), }, "url": types.StringType, }, @@ -3750,25 +6809,72 @@ func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of EditCluster in the Terraform plugin framework type -// system. -func (a EditCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o EditCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToObjectType(ctx), + ElemType: AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToObjectType(ctx), + ElemType: AzureAttributes{}.Type(ctx), }, "cluster_id": types.StringType, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToObjectType(ctx), + ElemType: ClusterLogConf{}.Type(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -3776,17 +6882,17 @@ func (a EditCluster) ToObjectType(ctx context.Context) types.ObjectType { }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToObjectType(ctx), + ElemType: GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -3805,7 +6911,7 @@ func (a EditCluster) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToObjectType(ctx), + ElemType: WorkloadType{}.Type(ctx), }, }, } @@ -3831,9 +6937,56 @@ func (a EditClusterResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of EditClusterResponse in the Terraform plugin framework type -// system. -func (a EditClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EditClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3892,9 +7045,56 @@ func (a EditInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of EditInstancePool in the Terraform plugin framework type -// system. -func (a EditInstancePool) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditInstancePool{} + +// Equal implements basetypes.ObjectValuable. +func (o EditInstancePool) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditInstancePool) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditInstancePool) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditInstancePool) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "custom_tags": basetypes.MapType{ @@ -3930,9 +7130,56 @@ func (a EditInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of EditInstancePoolResponse in the Terraform plugin framework type -// system. -func (a EditInstancePoolResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditInstancePoolResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditInstancePoolResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3995,15 +7242,62 @@ func (a EditPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of EditPolicy in the Terraform plugin framework type -// system. -func (a EditPolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditPolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o EditPolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditPolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditPolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditPolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToObjectType(ctx), + ElemType: Library{}.Type(ctx), }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, @@ -4034,9 +7328,56 @@ func (a EditPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of EditPolicyResponse in the Terraform plugin framework type -// system. -func (a EditPolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditPolicyResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EditPolicyResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditPolicyResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditPolicyResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditPolicyResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditPolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditPolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditPolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4062,9 +7403,56 @@ func (a EditResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of EditResponse in the Terraform plugin framework type -// system. -func (a EditResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EditResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4095,9 +7483,56 @@ func (a EnforceClusterComplianceRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of EnforceClusterComplianceRequest in the Terraform plugin framework type -// system. -func (a EnforceClusterComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnforceClusterComplianceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4134,13 +7569,60 @@ func (a EnforceClusterComplianceResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of EnforceClusterComplianceResponse in the Terraform plugin framework type -// system. -func (a EnforceClusterComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnforceClusterComplianceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnforceClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "changes": basetypes.ListType{ - ElemType: ClusterSettingsChange{}.ToObjectType(ctx), + ElemType: ClusterSettingsChange{}.Type(ctx), }, "has_changes": types.BoolType, }, @@ -4184,9 +7666,56 @@ func (a Environment) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of Environment in the Terraform plugin framework type -// system. -func (a Environment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Environment{} + +// Equal implements basetypes.ObjectValuable. +func (o Environment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Environment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Environment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Environment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Environment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Environment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Environment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "client": types.StringType, @@ -4272,17 +7801,64 @@ func (a EventDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of EventDetails in the Terraform plugin framework type -// system. -func (a EventDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EventDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o EventDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EventDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EventDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EventDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EventDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EventDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": basetypes.ListType{ - ElemType: ClusterAttributes{}.ToObjectType(ctx), + ElemType: ClusterAttributes{}.Type(ctx), }, "cause": types.StringType, "cluster_size": basetypes.ListType{ - ElemType: ClusterSize{}.ToObjectType(ctx), + ElemType: ClusterSize{}.Type(ctx), }, "current_num_vcpus": types.Int64Type, "current_num_workers": types.Int64Type, @@ -4292,19 +7868,19 @@ func (a EventDetails) ToObjectType(ctx context.Context) types.ObjectType { "enable_termination_for_node_blocklisted": types.BoolType, "free_space": types.Int64Type, "init_scripts": basetypes.ListType{ - ElemType: InitScriptEventDetails{}.ToObjectType(ctx), + ElemType: InitScriptEventDetails{}.Type(ctx), }, "instance_id": types.StringType, "job_run_name": types.StringType, "previous_attributes": basetypes.ListType{ - ElemType: ClusterAttributes{}.ToObjectType(ctx), + ElemType: ClusterAttributes{}.Type(ctx), }, "previous_cluster_size": basetypes.ListType{ - ElemType: ClusterSize{}.ToObjectType(ctx), + ElemType: ClusterSize{}.Type(ctx), }, "previous_disk_size": types.Int64Type, "reason": basetypes.ListType{ - ElemType: TerminationReason{}.ToObjectType(ctx), + ElemType: TerminationReason{}.Type(ctx), }, "target_num_vcpus": types.Int64Type, "target_num_workers": types.Int64Type, @@ -4364,9 +7940,56 @@ func (a GcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpAttributes in the Terraform plugin framework type -// system. -func (a GcpAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -4401,9 +8024,56 @@ func (a GcsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcsStorageInfo in the Terraform plugin framework type -// system. -func (a GcsStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcsStorageInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o GcsStorageInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcsStorageInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcsStorageInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcsStorageInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcsStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcsStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcsStorageInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -4434,9 +8104,56 @@ func (a GetClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterComplianceRequest in the Terraform plugin framework type -// system. -func (a GetClusterComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterComplianceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterComplianceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4475,9 +8192,56 @@ func (a GetClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of GetClusterComplianceResponse in the Terraform plugin framework type -// system. -func (a GetClusterComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterComplianceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, @@ -4511,9 +8275,56 @@ func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetClusterPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4545,13 +8356,60 @@ func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of GetClusterPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetClusterPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ClusterPermissionsDescription{}.ToObjectType(ctx), + ElemType: ClusterPermissionsDescription{}.Type(ctx), }, }, } @@ -4580,9 +8438,56 @@ func (a GetClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetClusterPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4613,9 +8518,56 @@ func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterPolicyPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetClusterPolicyPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPolicyPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_policy_id": types.StringType, @@ -4647,13 +8599,60 @@ func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes(ctx conte } } -// ToObjectType returns the representation of GetClusterPolicyPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetClusterPolicyPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPolicyPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ClusterPolicyPermissionsDescription{}.ToObjectType(ctx), + ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx), }, }, } @@ -4682,10 +8681,57 @@ func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterPolicyPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetClusterPolicyPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPolicyPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_policy_id": types.StringType, }, @@ -4715,9 +8761,56 @@ func (a GetClusterPolicyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterPolicyRequest in the Terraform plugin framework type -// system. -func (a GetClusterPolicyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterPolicyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterPolicyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_id": types.StringType, @@ -4748,9 +8841,56 @@ func (a GetClusterRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetClusterRequest in the Terraform plugin framework type -// system. -func (a GetClusterRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetClusterRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetClusterRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetClusterRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetClusterRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetClusterRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetClusterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetClusterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetClusterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4800,9 +8940,56 @@ func (a GetEvents) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of GetEvents in the Terraform plugin framework type -// system. -func (a GetEvents) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEvents{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEvents) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEvents) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEvents) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEvents) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEvents) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEvents) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEvents) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -4849,16 +9036,63 @@ func (a GetEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of GetEventsResponse in the Terraform plugin framework type -// system. -func (a GetEventsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEventsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEventsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEventsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEventsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEventsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEventsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEventsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "events": basetypes.ListType{ - ElemType: ClusterEvent{}.ToObjectType(ctx), + ElemType: ClusterEvent{}.Type(ctx), }, "next_page": basetypes.ListType{ - ElemType: GetEvents{}.ToObjectType(ctx), + ElemType: GetEvents{}.Type(ctx), }, "total_count": types.Int64Type, }, @@ -4888,9 +9122,56 @@ func (a GetGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetGlobalInitScriptRequest in the Terraform plugin framework type -// system. -func (a GetGlobalInitScriptRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetGlobalInitScriptRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetGlobalInitScriptRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "script_id": types.StringType, @@ -5002,16 +9283,63 @@ func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of GetInstancePool in the Terraform plugin framework type -// system. -func (a GetInstancePool) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetInstancePool{} + +// Equal implements basetypes.ObjectValuable. +func (o GetInstancePool) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetInstancePool) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetInstancePool) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetInstancePool) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolAwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolAzureAttributes{}.Type(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, @@ -5020,11 +9348,11 @@ func (a GetInstancePool) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.ToObjectType(ctx), + ElemType: DiskSpec{}.Type(ctx), }, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolGcpAttributes{}.Type(ctx), }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, @@ -5033,17 +9361,17 @@ func (a GetInstancePool) ToObjectType(ctx context.Context) types.ObjectType { "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, "state": types.StringType, "stats": basetypes.ListType{ - ElemType: InstancePoolStats{}.ToObjectType(ctx), + ElemType: InstancePoolStats{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: InstancePoolStatus{}.ToObjectType(ctx), + ElemType: InstancePoolStatus{}.Type(ctx), }, }, } @@ -5072,9 +9400,56 @@ func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetInstancePoolPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetInstancePoolPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetInstancePoolPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -5106,13 +9481,60 @@ func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes(ctx contex } } -// ToObjectType returns the representation of GetInstancePoolPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetInstancePoolPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetInstancePoolPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: InstancePoolPermissionsDescription{}.ToObjectType(ctx), + ElemType: InstancePoolPermissionsDescription{}.Type(ctx), }, }, } @@ -5141,9 +9563,56 @@ func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetInstancePoolPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetInstancePoolPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetInstancePoolPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetInstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -5174,9 +9643,56 @@ func (a GetInstancePoolRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetInstancePoolRequest in the Terraform plugin framework type -// system. -func (a GetInstancePoolRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetInstancePoolRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetInstancePoolRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pool_id": types.StringType, @@ -5210,9 +9726,56 @@ func (a GetPolicyFamilyRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPolicyFamilyRequest in the Terraform plugin framework type -// system. -func (a GetPolicyFamilyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPolicyFamilyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policy_family_id": types.StringType, @@ -5245,13 +9808,60 @@ func (a GetSparkVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of GetSparkVersionsResponse in the Terraform plugin framework type -// system. -func (a GetSparkVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetSparkVersionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetSparkVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "versions": basetypes.ListType{ - ElemType: SparkVersion{}.ToObjectType(ctx), + ElemType: SparkVersion{}.Type(ctx), }, }, } @@ -5295,9 +9905,56 @@ func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GlobalInitScriptCreateRequest in the Terraform plugin framework type -// system. -func (a GlobalInitScriptCreateRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GlobalInitScriptCreateRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GlobalInitScriptCreateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -5347,9 +10004,56 @@ func (a GlobalInitScriptDetails) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of GlobalInitScriptDetails in the Terraform plugin framework type -// system. -func (a GlobalInitScriptDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GlobalInitScriptDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -5405,9 +10109,56 @@ func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GlobalInitScriptDetailsWithContent in the Terraform plugin framework type -// system. -func (a GlobalInitScriptDetailsWithContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GlobalInitScriptDetailsWithContent{} + +// Equal implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GlobalInitScriptDetailsWithContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -5464,9 +10215,56 @@ func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GlobalInitScriptUpdateRequest in the Terraform plugin framework type -// system. -func (a GlobalInitScriptUpdateRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GlobalInitScriptUpdateRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GlobalInitScriptUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -5507,16 +10305,63 @@ func (a InitScriptEventDetails) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of InitScriptEventDetails in the Terraform plugin framework type -// system. -func (a InitScriptEventDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InitScriptEventDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.ToObjectType(ctx), + ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), }, "global": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.ToObjectType(ctx), + ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), }, "reported_for_node": types.StringType, }, @@ -5549,9 +10394,56 @@ func (a InitScriptExecutionDetails) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of InitScriptExecutionDetails in the Terraform plugin framework type -// system. -func (a InitScriptExecutionDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InitScriptExecutionDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InitScriptExecutionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_message": types.StringType, @@ -5614,31 +10506,78 @@ func (a InitScriptInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of InitScriptInfo in the Terraform plugin framework type -// system. -func (a InitScriptInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InitScriptInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o InitScriptInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InitScriptInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InitScriptInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InitScriptInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InitScriptInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InitScriptInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InitScriptInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "abfss": basetypes.ListType{ - ElemType: Adlsgen2Info{}.ToObjectType(ctx), + ElemType: Adlsgen2Info{}.Type(ctx), }, "dbfs": basetypes.ListType{ - ElemType: DbfsStorageInfo{}.ToObjectType(ctx), + ElemType: DbfsStorageInfo{}.Type(ctx), }, "file": basetypes.ListType{ - ElemType: LocalFileInfo{}.ToObjectType(ctx), + ElemType: LocalFileInfo{}.Type(ctx), }, "gcs": basetypes.ListType{ - ElemType: GcsStorageInfo{}.ToObjectType(ctx), + ElemType: GcsStorageInfo{}.Type(ctx), }, "s3": basetypes.ListType{ - ElemType: S3StorageInfo{}.ToObjectType(ctx), + ElemType: S3StorageInfo{}.Type(ctx), }, "volumes": basetypes.ListType{ - ElemType: VolumesStorageInfo{}.ToObjectType(ctx), + ElemType: VolumesStorageInfo{}.Type(ctx), }, "workspace": basetypes.ListType{ - ElemType: WorkspaceStorageInfo{}.ToObjectType(ctx), + ElemType: WorkspaceStorageInfo{}.Type(ctx), }, }, } @@ -5671,16 +10610,63 @@ func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of InitScriptInfoAndExecutionDetails in the Terraform plugin framework type -// system. -func (a InitScriptInfoAndExecutionDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InitScriptInfoAndExecutionDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InitScriptInfoAndExecutionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "execution_details": basetypes.ListType{ - ElemType: InitScriptExecutionDetails{}.ToObjectType(ctx), + ElemType: InitScriptExecutionDetails{}.Type(ctx), }, "script": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, }, } @@ -5712,14 +10698,61 @@ func (a InstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of InstallLibraries in the Terraform plugin framework type -// system. -func (a InstallLibraries) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstallLibraries{} + +// Equal implements basetypes.ObjectValuable. +func (o InstallLibraries) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstallLibraries) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstallLibraries) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstallLibraries) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstallLibraries) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstallLibraries) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToObjectType(ctx), + ElemType: Library{}.Type(ctx), }, }, } @@ -5745,9 +10778,56 @@ func (a InstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstallLibrariesResponse in the Terraform plugin framework type -// system. -func (a InstallLibrariesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstallLibrariesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstallLibrariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5781,9 +10861,56 @@ func (a InstancePoolAccessControlRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstancePoolAccessControlRequest in the Terraform plugin framework type -// system. -func (a InstancePoolAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -5826,13 +10953,60 @@ func (a InstancePoolAccessControlResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of InstancePoolAccessControlResponse in the Terraform plugin framework type -// system. -func (a InstancePoolAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: InstancePoolPermission{}.ToObjectType(ctx), + ElemType: InstancePoolPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -5946,16 +11120,63 @@ func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of InstancePoolAndStats in the Terraform plugin framework type -// system. -func (a InstancePoolAndStats) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolAndStats{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolAwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolAzureAttributes{}.Type(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, @@ -5964,11 +11185,11 @@ func (a InstancePoolAndStats) ToObjectType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.ToObjectType(ctx), + ElemType: DiskSpec{}.Type(ctx), }, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.ToObjectType(ctx), + ElemType: InstancePoolGcpAttributes{}.Type(ctx), }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, @@ -5977,17 +11198,17 @@ func (a InstancePoolAndStats) ToObjectType(ctx context.Context) types.ObjectType "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, "state": types.StringType, "stats": basetypes.ListType{ - ElemType: InstancePoolStats{}.ToObjectType(ctx), + ElemType: InstancePoolStats{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: InstancePoolStatus{}.ToObjectType(ctx), + ElemType: InstancePoolStatus{}.Type(ctx), }, }, } @@ -6042,9 +11263,56 @@ func (a InstancePoolAwsAttributes) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstancePoolAwsAttributes in the Terraform plugin framework type -// system. -func (a InstancePoolAwsAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolAwsAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolAwsAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -6082,9 +11350,56 @@ func (a InstancePoolAzureAttributes) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstancePoolAzureAttributes in the Terraform plugin framework type -// system. -func (a InstancePoolAzureAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolAzureAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolAzureAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "availability": types.StringType, @@ -6141,9 +11456,56 @@ func (a InstancePoolGcpAttributes) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstancePoolGcpAttributes in the Terraform plugin framework type -// system. -func (a InstancePoolGcpAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolGcpAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolGcpAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gcp_availability": types.StringType, @@ -6180,9 +11542,56 @@ func (a InstancePoolPermission) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of InstancePoolPermission in the Terraform plugin framework type -// system. -func (a InstancePoolPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -6221,13 +11630,60 @@ func (a InstancePoolPermissions) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of InstancePoolPermissions in the Terraform plugin framework type -// system. -func (a InstancePoolPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: InstancePoolAccessControlResponse{}.ToObjectType(ctx), + ElemType: InstancePoolAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -6258,9 +11714,56 @@ func (a InstancePoolPermissionsDescription) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstancePoolPermissionsDescription in the Terraform plugin framework type -// system. -func (a InstancePoolPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6294,13 +11797,60 @@ func (a InstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of InstancePoolPermissionsRequest in the Terraform plugin framework type -// system. -func (a InstancePoolPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: InstancePoolAccessControlRequest{}.ToObjectType(ctx), + ElemType: InstancePoolAccessControlRequest{}.Type(ctx), }, "instance_pool_id": types.StringType, }, @@ -6335,9 +11885,56 @@ func (a InstancePoolStats) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstancePoolStats in the Terraform plugin framework type -// system. -func (a InstancePoolStats) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolStats{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolStats) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolStats) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolStats) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolStats) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "idle_count": types.Int64Type, @@ -6375,13 +11972,60 @@ func (a InstancePoolStatus) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of InstancePoolStatus in the Terraform plugin framework type -// system. -func (a InstancePoolStatus) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstancePoolStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o InstancePoolStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstancePoolStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstancePoolStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstancePoolStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstancePoolStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstancePoolStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstancePoolStatus) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pending_instance_errors": basetypes.ListType{ - ElemType: PendingInstanceError{}.ToObjectType(ctx), + ElemType: PendingInstanceError{}.Type(ctx), }, }, } @@ -6425,9 +12069,56 @@ func (a InstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of InstanceProfile in the Terraform plugin framework type -// system. -func (a InstanceProfile) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstanceProfile{} + +// Equal implements basetypes.ObjectValuable. +func (o InstanceProfile) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstanceProfile) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstanceProfile) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstanceProfile) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstanceProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstanceProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstanceProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "iam_role_arn": types.StringType, @@ -6494,21 +12185,68 @@ func (a Library) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of Library in the Terraform plugin framework type -// system. -func (a Library) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Library{} + +// Equal implements basetypes.ObjectValuable. +func (o Library) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Library) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Library) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Library) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Library) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Library) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Library) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cran": basetypes.ListType{ - ElemType: RCranLibrary{}.ToObjectType(ctx), + ElemType: RCranLibrary{}.Type(ctx), }, "egg": types.StringType, "jar": types.StringType, "maven": basetypes.ListType{ - ElemType: MavenLibrary{}.ToObjectType(ctx), + ElemType: MavenLibrary{}.Type(ctx), }, "pypi": basetypes.ListType{ - ElemType: PythonPyPiLibrary{}.ToObjectType(ctx), + ElemType: PythonPyPiLibrary{}.Type(ctx), }, "requirements": types.StringType, "whl": types.StringType, @@ -6550,14 +12288,61 @@ func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of LibraryFullStatus in the Terraform plugin framework type -// system. -func (a LibraryFullStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LibraryFullStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o LibraryFullStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LibraryFullStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LibraryFullStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LibraryFullStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LibraryFullStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LibraryFullStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LibraryFullStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_library_for_all_clusters": types.BoolType, "library": basetypes.ListType{ - ElemType: Library{}.ToObjectType(ctx), + ElemType: Library{}.Type(ctx), }, "messages": basetypes.ListType{ ElemType: types.StringType, @@ -6591,13 +12376,60 @@ func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes(ctx context. } } -// ToObjectType returns the representation of ListAllClusterLibraryStatusesResponse in the Terraform plugin framework type -// system. -func (a ListAllClusterLibraryStatusesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAllClusterLibraryStatusesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAllClusterLibraryStatusesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statuses": basetypes.ListType{ - ElemType: ClusterLibraryStatuses{}.ToObjectType(ctx), + ElemType: ClusterLibraryStatuses{}.Type(ctx), }, }, } @@ -6630,9 +12462,56 @@ func (a ListAvailableZonesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListAvailableZonesResponse in the Terraform plugin framework type -// system. -func (a ListAvailableZonesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAvailableZonesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAvailableZonesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_zone": types.StringType, @@ -6673,9 +12552,56 @@ func (a ListClusterCompliancesRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListClusterCompliancesRequest in the Terraform plugin framework type -// system. -func (a ListClusterCompliancesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClusterCompliancesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClusterCompliancesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -6716,13 +12642,60 @@ func (a ListClusterCompliancesResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of ListClusterCompliancesResponse in the Terraform plugin framework type -// system. -func (a ListClusterCompliancesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClusterCompliancesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClusterCompliancesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusters": basetypes.ListType{ - ElemType: ClusterCompliance{}.ToObjectType(ctx), + ElemType: ClusterCompliance{}.Type(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -6758,9 +12731,56 @@ func (a ListClusterPoliciesRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListClusterPoliciesRequest in the Terraform plugin framework type -// system. -func (a ListClusterPoliciesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClusterPoliciesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClusterPoliciesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sort_column": types.StringType, @@ -6800,9 +12820,56 @@ func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListClustersFilterBy in the Terraform plugin framework type -// system. -func (a ListClustersFilterBy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClustersFilterBy{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClustersFilterBy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_sources": basetypes.ListType{ @@ -6852,18 +12919,65 @@ func (a ListClustersRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListClustersRequest in the Terraform plugin framework type -// system. -func (a ListClustersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClustersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClustersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClustersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClustersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClustersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClustersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClustersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClustersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter_by": basetypes.ListType{ - ElemType: ListClustersFilterBy{}.ToObjectType(ctx), + ElemType: ListClustersFilterBy{}.Type(ctx), }, "page_size": types.Int64Type, "page_token": types.StringType, "sort_by": basetypes.ListType{ - ElemType: ListClustersSortBy{}.ToObjectType(ctx), + ElemType: ListClustersSortBy{}.Type(ctx), }, }, } @@ -6900,13 +13014,60 @@ func (a ListClustersResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListClustersResponse in the Terraform plugin framework type -// system. -func (a ListClustersResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClustersResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClustersResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClustersResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClustersResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClustersResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClustersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClustersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClustersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clusters": basetypes.ListType{ - ElemType: ClusterDetails{}.ToObjectType(ctx), + ElemType: ClusterDetails{}.Type(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -6940,9 +13101,56 @@ func (a ListClustersSortBy) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListClustersSortBy in the Terraform plugin framework type -// system. -func (a ListClustersSortBy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListClustersSortBy{} + +// Equal implements basetypes.ObjectValuable. +func (o ListClustersSortBy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListClustersSortBy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListClustersSortBy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListClustersSortBy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListClustersSortBy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListClustersSortBy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListClustersSortBy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "direction": types.StringType, @@ -6974,13 +13182,60 @@ func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListGlobalInitScriptsResponse in the Terraform plugin framework type -// system. -func (a ListGlobalInitScriptsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListGlobalInitScriptsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListGlobalInitScriptsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scripts": basetypes.ListType{ - ElemType: GlobalInitScriptDetails{}.ToObjectType(ctx), + ElemType: GlobalInitScriptDetails{}.Type(ctx), }, }, } @@ -7009,13 +13264,60 @@ func (a ListInstancePools) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ListInstancePools in the Terraform plugin framework type -// system. -func (a ListInstancePools) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListInstancePools{} + +// Equal implements basetypes.ObjectValuable. +func (o ListInstancePools) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListInstancePools) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListInstancePools) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListInstancePools) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListInstancePools) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListInstancePools) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListInstancePools) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_pools": basetypes.ListType{ - ElemType: InstancePoolAndStats{}.ToObjectType(ctx), + ElemType: InstancePoolAndStats{}.Type(ctx), }, }, } @@ -7045,13 +13347,60 @@ func (a ListInstanceProfilesResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListInstanceProfilesResponse in the Terraform plugin framework type -// system. -func (a ListInstanceProfilesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListInstanceProfilesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListInstanceProfilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_profiles": basetypes.ListType{ - ElemType: InstanceProfile{}.ToObjectType(ctx), + ElemType: InstanceProfile{}.Type(ctx), }, }, } @@ -7081,13 +13430,60 @@ func (a ListNodeTypesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListNodeTypesResponse in the Terraform plugin framework type -// system. -func (a ListNodeTypesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNodeTypesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListNodeTypesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "node_types": basetypes.ListType{ - ElemType: NodeType{}.ToObjectType(ctx), + ElemType: NodeType{}.Type(ctx), }, }, } @@ -7117,13 +13513,60 @@ func (a ListPoliciesResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListPoliciesResponse in the Terraform plugin framework type -// system. -func (a ListPoliciesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPoliciesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPoliciesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "policies": basetypes.ListType{ - ElemType: Policy{}.ToObjectType(ctx), + ElemType: Policy{}.Type(ctx), }, }, } @@ -7154,9 +13597,56 @@ func (a ListPolicyFamiliesRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListPolicyFamiliesRequest in the Terraform plugin framework type -// system. -func (a ListPolicyFamiliesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPolicyFamiliesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -7192,14 +13682,61 @@ func (a ListPolicyFamiliesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListPolicyFamiliesResponse in the Terraform plugin framework type -// system. -func (a ListPolicyFamiliesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPolicyFamiliesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPolicyFamiliesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "policy_families": basetypes.ListType{ - ElemType: PolicyFamily{}.ToObjectType(ctx), + ElemType: PolicyFamily{}.Type(ctx), }, }, } @@ -7227,9 +13764,56 @@ func (a LocalFileInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of LocalFileInfo in the Terraform plugin framework type -// system. -func (a LocalFileInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LocalFileInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o LocalFileInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LocalFileInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LocalFileInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LocalFileInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LocalFileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LocalFileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LocalFileInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -7261,9 +13845,56 @@ func (a LogAnalyticsInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogAnalyticsInfo in the Terraform plugin framework type -// system. -func (a LogAnalyticsInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogAnalyticsInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogAnalyticsInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_analytics_primary_key": types.StringType, @@ -7298,9 +13929,56 @@ func (a LogSyncStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogSyncStatus in the Terraform plugin framework type -// system. -func (a LogSyncStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogSyncStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o LogSyncStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogSyncStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogSyncStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogSyncStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogSyncStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogSyncStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogSyncStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "last_attempted": types.Int64Type, @@ -7342,9 +14020,56 @@ func (a MavenLibrary) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of MavenLibrary in the Terraform plugin framework type -// system. -func (a MavenLibrary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MavenLibrary{} + +// Equal implements basetypes.ObjectValuable. +func (o MavenLibrary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MavenLibrary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MavenLibrary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MavenLibrary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MavenLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MavenLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MavenLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "coordinates": types.StringType, @@ -7385,9 +14110,56 @@ func (a NodeInstanceType) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of NodeInstanceType in the Terraform plugin framework type -// system. -func (a NodeInstanceType) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NodeInstanceType{} + +// Equal implements basetypes.ObjectValuable. +func (o NodeInstanceType) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NodeInstanceType) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NodeInstanceType) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NodeInstanceType) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NodeInstanceType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NodeInstanceType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NodeInstanceType) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_type_id": types.StringType, @@ -7469,9 +14241,56 @@ func (a NodeType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of NodeType in the Terraform plugin framework type -// system. -func (a NodeType) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NodeType{} + +// Equal implements basetypes.ObjectValuable. +func (o NodeType) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NodeType) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NodeType) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NodeType) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NodeType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NodeType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NodeType) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "category": types.StringType, @@ -7485,10 +14304,10 @@ func (a NodeType) ToObjectType(ctx context.Context) types.ObjectType { "is_io_cache_enabled": types.BoolType, "memory_mb": types.Int64Type, "node_info": basetypes.ListType{ - ElemType: CloudProviderNodeInfo{}.ToObjectType(ctx), + ElemType: CloudProviderNodeInfo{}.Type(ctx), }, "node_instance_type": basetypes.ListType{ - ElemType: NodeInstanceType{}.ToObjectType(ctx), + ElemType: NodeInstanceType{}.Type(ctx), }, "node_type_id": types.StringType, "num_cores": types.Float64Type, @@ -7526,9 +14345,56 @@ func (a PendingInstanceError) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of PendingInstanceError in the Terraform plugin framework type -// system. -func (a PendingInstanceError) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PendingInstanceError{} + +// Equal implements basetypes.ObjectValuable. +func (o PendingInstanceError) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PendingInstanceError) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PendingInstanceError) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PendingInstanceError) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PendingInstanceError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PendingInstanceError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PendingInstanceError) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_id": types.StringType, @@ -7559,9 +14425,56 @@ func (a PermanentDeleteCluster) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of PermanentDeleteCluster in the Terraform plugin framework type -// system. -func (a PermanentDeleteCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermanentDeleteCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermanentDeleteCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -7589,9 +14502,56 @@ func (a PermanentDeleteClusterResponse) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of PermanentDeleteClusterResponse in the Terraform plugin framework type -// system. -func (a PermanentDeleteClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermanentDeleteClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermanentDeleteClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7619,9 +14579,56 @@ func (a PinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of PinCluster in the Terraform plugin framework type -// system. -func (a PinCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PinCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o PinCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PinCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PinCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PinCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PinCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PinCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PinCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -7649,9 +14656,56 @@ func (a PinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of PinClusterResponse in the Terraform plugin framework type -// system. -func (a PinClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PinClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PinClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PinClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PinClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PinClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PinClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PinClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PinClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7725,9 +14779,56 @@ func (a Policy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToObjectType returns the representation of Policy in the Terraform plugin framework type -// system. -func (a Policy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Policy{} + +// Equal implements basetypes.ObjectValuable. +func (o Policy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Policy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Policy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Policy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Policy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Policy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Policy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at_timestamp": types.Int64Type, @@ -7736,7 +14837,7 @@ func (a Policy) ToObjectType(ctx context.Context) types.ObjectType { "description": types.StringType, "is_default": types.BoolType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToObjectType(ctx), + ElemType: Library{}.Type(ctx), }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, @@ -7778,9 +14879,56 @@ func (a PolicyFamily) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of PolicyFamily in the Terraform plugin framework type -// system. -func (a PolicyFamily) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PolicyFamily{} + +// Equal implements basetypes.ObjectValuable. +func (o PolicyFamily) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PolicyFamily) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PolicyFamily) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PolicyFamily) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PolicyFamily) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PolicyFamily) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PolicyFamily) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "definition": types.StringType, @@ -7818,9 +14966,56 @@ func (a PythonPyPiLibrary) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of PythonPyPiLibrary in the Terraform plugin framework type -// system. -func (a PythonPyPiLibrary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PythonPyPiLibrary{} + +// Equal implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PythonPyPiLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "package": types.StringType, @@ -7854,10 +15049,57 @@ func (a RCranLibrary) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of RCranLibrary in the Terraform plugin framework type -// system. -func (a RCranLibrary) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RCranLibrary{} + +// Equal implements basetypes.ObjectValuable. +func (o RCranLibrary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RCranLibrary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RCranLibrary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RCranLibrary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RCranLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RCranLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RCranLibrary) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "package": types.StringType, "repo": types.StringType, @@ -7887,9 +15129,56 @@ func (a RemoveInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of RemoveInstanceProfile in the Terraform plugin framework type -// system. -func (a RemoveInstanceProfile) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RemoveInstanceProfile{} + +// Equal implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RemoveInstanceProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance_profile_arn": types.StringType, @@ -7917,9 +15206,56 @@ func (a RemoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of RemoveResponse in the Terraform plugin framework type -// system. -func (a RemoveResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RemoveResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RemoveResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RemoveResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RemoveResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RemoveResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RemoveResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RemoveResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RemoveResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7964,13 +15300,60 @@ func (a ResizeCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of ResizeCluster in the Terraform plugin framework type -// system. -func (a ResizeCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResizeCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o ResizeCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResizeCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResizeCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResizeCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResizeCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResizeCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResizeCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "cluster_id": types.StringType, "num_workers": types.Int64Type, @@ -7998,9 +15381,56 @@ func (a ResizeClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ResizeClusterResponse in the Terraform plugin framework type -// system. -func (a ResizeClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResizeClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResizeClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8030,9 +15460,56 @@ func (a RestartCluster) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestartCluster in the Terraform plugin framework type -// system. -func (a RestartCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestartCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o RestartCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestartCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestartCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestartCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestartCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestartCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestartCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -8061,9 +15538,56 @@ func (a RestartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestartClusterResponse in the Terraform plugin framework type -// system. -func (a RestartClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestartClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RestartClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestartClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestartClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestartClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestartClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestartClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestartClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8113,9 +15637,56 @@ func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of Results in the Terraform plugin framework type -// system. -func (a Results) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Results{} + +// Equal implements basetypes.ObjectValuable. +func (o Results) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Results) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Results) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Results) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Results) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Results) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Results) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, @@ -8188,9 +15759,56 @@ func (a S3StorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of S3StorageInfo in the Terraform plugin framework type -// system. -func (a S3StorageInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = S3StorageInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o S3StorageInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o S3StorageInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o S3StorageInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o S3StorageInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o S3StorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o S3StorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o S3StorageInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "canned_acl": types.StringType, @@ -8251,15 +15869,62 @@ func (a SparkNode) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of SparkNode in the Terraform plugin framework type -// system. -func (a SparkNode) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparkNode{} + +// Equal implements basetypes.ObjectValuable. +func (o SparkNode) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparkNode) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparkNode) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparkNode) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparkNode) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparkNode) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparkNode) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "host_private_ip": types.StringType, "instance_id": types.StringType, "node_aws_attributes": basetypes.ListType{ - ElemType: SparkNodeAwsAttributes{}.ToObjectType(ctx), + ElemType: SparkNodeAwsAttributes{}.Type(ctx), }, "node_id": types.StringType, "private_ip": types.StringType, @@ -8291,9 +15956,56 @@ func (a SparkNodeAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of SparkNodeAwsAttributes in the Terraform plugin framework type -// system. -func (a SparkNodeAwsAttributes) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparkNodeAwsAttributes{} + +// Equal implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparkNodeAwsAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_spot": types.BoolType, @@ -8329,9 +16041,56 @@ func (a SparkVersion) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of SparkVersion in the Terraform plugin framework type -// system. -func (a SparkVersion) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparkVersion{} + +// Equal implements basetypes.ObjectValuable. +func (o SparkVersion) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparkVersion) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparkVersion) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparkVersion) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparkVersion) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparkVersion) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparkVersion) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -8362,9 +16121,56 @@ func (a StartCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of StartCluster in the Terraform plugin framework type -// system. -func (a StartCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o StartCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -8392,9 +16198,56 @@ func (a StartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of StartClusterResponse in the Terraform plugin framework type -// system. -func (a StartClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o StartClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8407,7 +16260,7 @@ type TerminationReason struct { // cluster was terminated Parameters types.Map `tfsdk:"parameters" tf:"optional"` // type of the termination - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan TerminationReason) { @@ -8429,9 +16282,56 @@ func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of TerminationReason in the Terraform plugin framework type -// system. -func (a TerminationReason) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TerminationReason{} + +// Equal implements basetypes.ObjectValuable. +func (o TerminationReason) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TerminationReason) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TerminationReason) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TerminationReason) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TerminationReason) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TerminationReason) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TerminationReason) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -8469,14 +16369,61 @@ func (a UninstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of UninstallLibraries in the Terraform plugin framework type -// system. -func (a UninstallLibraries) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UninstallLibraries{} + +// Equal implements basetypes.ObjectValuable. +func (o UninstallLibraries) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UninstallLibraries) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UninstallLibraries) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UninstallLibraries) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UninstallLibraries) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UninstallLibraries) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UninstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "libraries": basetypes.ListType{ - ElemType: Library{}.ToObjectType(ctx), + ElemType: Library{}.Type(ctx), }, }, } @@ -8502,9 +16449,56 @@ func (a UninstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of UninstallLibrariesResponse in the Terraform plugin framework type -// system. -func (a UninstallLibrariesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UninstallLibrariesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UninstallLibrariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8532,9 +16526,56 @@ func (a UnpinCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of UnpinCluster in the Terraform plugin framework type -// system. -func (a UnpinCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UnpinCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o UnpinCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UnpinCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UnpinCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UnpinCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UnpinCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UnpinCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UnpinCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -8562,9 +16603,56 @@ func (a UnpinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of UnpinClusterResponse in the Terraform plugin framework type -// system. -func (a UnpinClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UnpinClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UnpinClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8602,13 +16690,60 @@ func (a UpdateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of UpdateCluster in the Terraform plugin framework type -// system. -func (a UpdateCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster": basetypes.ListType{ - ElemType: UpdateClusterResource{}.ToObjectType(ctx), + ElemType: UpdateClusterResource{}.Type(ctx), }, "cluster_id": types.StringType, "update_mask": types.StringType, @@ -8794,23 +16929,70 @@ func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateClusterResource in the Terraform plugin framework type -// system. -func (a UpdateClusterResource) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateClusterResource{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateClusterResource) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateClusterResource) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateClusterResource) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateClusterResource) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateClusterResource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateClusterResource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.ToObjectType(ctx), + ElemType: AutoScale{}.Type(ctx), }, "autotermination_minutes": types.Int64Type, "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.ToObjectType(ctx), + ElemType: AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.ToObjectType(ctx), + ElemType: AzureAttributes{}.Type(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.ToObjectType(ctx), + ElemType: ClusterLogConf{}.Type(ctx), }, "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ @@ -8818,17 +17000,17 @@ func (a UpdateClusterResource) ToObjectType(ctx context.Context) types.ObjectTyp }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.ToObjectType(ctx), + ElemType: DockerImage{}.Type(ctx), }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.ToObjectType(ctx), + ElemType: GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.ToObjectType(ctx), + ElemType: InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "node_type_id": types.StringType, @@ -8847,7 +17029,7 @@ func (a UpdateClusterResource) ToObjectType(ctx context.Context) types.ObjectTyp ElemType: types.StringType, }, "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.ToObjectType(ctx), + ElemType: WorkloadType{}.Type(ctx), }, }, } @@ -8873,9 +17055,56 @@ func (a UpdateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateClusterResponse in the Terraform plugin framework type -// system. -func (a UpdateClusterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateClusterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateClusterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8901,9 +17130,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -8931,9 +17207,56 @@ func (a VolumesStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of VolumesStorageInfo in the Terraform plugin framework type -// system. -func (a VolumesStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = VolumesStorageInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o VolumesStorageInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, @@ -8965,13 +17288,60 @@ func (a WorkloadType) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of WorkloadType in the Terraform plugin framework type -// system. -func (a WorkloadType) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkloadType{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkloadType) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkloadType) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkloadType) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkloadType) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkloadType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkloadType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkloadType) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clients": basetypes.ListType{ - ElemType: ClientsTypes{}.ToObjectType(ctx), + ElemType: ClientsTypes{}.Type(ctx), }, }, } @@ -9000,12 +17370,153 @@ func (a WorkspaceStorageInfo) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of WorkspaceStorageInfo in the Terraform plugin framework type -// system. -func (a WorkspaceStorageInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceStorageInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceStorageInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination": types.StringType, }, } } + +// Availability type used for all subsequent nodes past the `first_on_demand` +// ones. +// +// Note: If `first_on_demand` is zero, this availability type will be used for +// the entire cluster. + +// Availability type used for all subsequent nodes past the `first_on_demand` +// ones. Note: If `first_on_demand` is zero (which only happens on pool +// clusters), this availability type will be used for the entire cluster. + +// Permission level + +// Permission level + +// Determines whether the cluster was created by a user through the UI, created +// by the Databricks Jobs Scheduler, or through an API request. This is the same +// as cluster_creator, but read only. + +// + +// Data security mode decides what data governance model to use when accessing +// data from a cluster. +// +// * `NONE`: No security isolation for multiple users sharing the cluster. Data +// governance features are not available in this mode. * `SINGLE_USER`: A secure +// cluster that can only be exclusively used by a single user specified in +// `single_user_name`. Most programming languages, cluster features and data +// governance features are available in this mode. * `USER_ISOLATION`: A secure +// cluster that can be shared by multiple users. Cluster users are fully +// isolated so that they cannot see each other's data and credentials. Most data +// governance features are supported in this mode. But programming languages and +// cluster features might be limited. +// +// The following modes are deprecated starting with Databricks Runtime 15.0 and +// will be removed for future Databricks Runtime versions: +// +// * `LEGACY_TABLE_ACL`: This mode is for users migrating from legacy Table ACL +// clusters. * `LEGACY_PASSTHROUGH`: This mode is for users migrating from +// legacy Passthrough on high concurrency clusters. * `LEGACY_SINGLE_USER`: This +// mode is for users migrating from legacy Passthrough on standard clusters. * +// `LEGACY_SINGLE_USER_STANDARD`: This mode provides a way that doesn’t have +// UC nor passthrough enabled. + +// The type of EBS volumes that will be launched with this cluster. + +// The cause of a change in target size. + +// This field determines whether the instance pool will contain preemptible VMs, +// on-demand VMs, or preemptible VMs with a fallback to on-demand VMs if the +// former is unavailable. + +// The order to list events in; either "ASC" or "DESC". Defaults to "DESC". + +// The current status of the script + +// Availability type used for the spot nodes. +// +// The default value is defined by +// InstancePoolConf.instancePoolDefaultAwsAvailability + +// Shows the Availability type used for the spot nodes. +// +// The default value is defined by +// InstancePoolConf.instancePoolDefaultAzureAvailability + +// Permission level + +// Current state of the instance pool. + +// The status of a library on a specific cluster. + +// The direction to sort by. + +// The sorting criteria. By default, clusters are sorted by 3 columns from +// highest to lowest precedence: cluster state, pinned or unpinned, then cluster +// name. + +// A generic ordering enum for list-based queries. + +// Determines the cluster's runtime engine, either standard or Photon. +// +// This field is not compatible with legacy `spark_version` values that contain +// `-photon-`. Remove `-photon-` from the `spark_version` and set +// `runtime_engine` to `PHOTON`. +// +// If left unspecified, the runtime engine defaults to standard unless the +// spark_version contains -photon-, in which case Photon will be used. + +// Current state of the cluster. + +// status code indicating why the cluster was terminated + +// type of the termination diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 517f0af730..2d080bc11f 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -12,13 +12,17 @@ package dashboards_tf import ( "context" + "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/sql" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/sql_tf" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) // Create dashboard @@ -45,13 +49,60 @@ func (a CreateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CreateDashboardRequest in the Terraform plugin framework type -// system. -func (a CreateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard": basetypes.ListType{ - ElemType: Dashboard{}.ToObjectType(ctx), + ElemType: Dashboard{}.Type(ctx), }, }, } @@ -84,14 +135,61 @@ func (a CreateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateScheduleRequest in the Terraform plugin framework type -// system. -func (a CreateScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateScheduleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule": basetypes.ListType{ - ElemType: Schedule{}.ToObjectType(ctx), + ElemType: Schedule{}.Type(ctx), }, }, } @@ -126,15 +224,62 @@ func (a CreateSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of CreateSubscriptionRequest in the Terraform plugin framework type -// system. -func (a CreateSubscriptionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateSubscriptionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateSubscriptionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule_id": types.StringType, "subscription": basetypes.ListType{ - ElemType: Subscription{}.ToObjectType(ctx), + ElemType: Subscription{}.Type(ctx), }, }, } @@ -170,9 +315,56 @@ func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of CronSchedule in the Terraform plugin framework type -// system. -func (a CronSchedule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CronSchedule{} + +// Equal implements basetypes.ObjectValuable. +func (o CronSchedule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CronSchedule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CronSchedule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CronSchedule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CronSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CronSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CronSchedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "quartz_cron_expression": types.StringType, @@ -234,9 +426,56 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of Dashboard in the Terraform plugin framework type -// system. -func (a Dashboard) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Dashboard{} + +// Equal implements basetypes.ObjectValuable. +func (o Dashboard) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Dashboard) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Dashboard) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Dashboard) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Dashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Dashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Dashboard) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -281,9 +520,56 @@ func (a DeleteScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteScheduleRequest in the Terraform plugin framework type -// system. -func (a DeleteScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteScheduleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -313,9 +599,56 @@ func (a DeleteScheduleResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteScheduleResponse in the Terraform plugin framework type -// system. -func (a DeleteScheduleResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteScheduleResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteScheduleResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -351,9 +684,56 @@ func (a DeleteSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteSubscriptionRequest in the Terraform plugin framework type -// system. -func (a DeleteSubscriptionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteSubscriptionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteSubscriptionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -384,9 +764,56 @@ func (a DeleteSubscriptionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteSubscriptionResponse in the Terraform plugin framework type -// system. -func (a DeleteSubscriptionResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteSubscriptionResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteSubscriptionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -419,16 +846,63 @@ func (a GenieAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of GenieAttachment in the Terraform plugin framework type -// system. -func (a GenieAttachment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieAttachment{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieAttachment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieAttachment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieAttachment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieAttachment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieAttachment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieAttachment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query": basetypes.ListType{ - ElemType: QueryAttachment{}.ToObjectType(ctx), + ElemType: QueryAttachment{}.Type(ctx), }, "text": basetypes.ListType{ - ElemType: TextAttachment{}.ToObjectType(ctx), + ElemType: TextAttachment{}.Type(ctx), }, }, } @@ -466,9 +940,56 @@ func (a GenieConversation) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenieConversation in the Terraform plugin framework type -// system. -func (a GenieConversation) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieConversation{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieConversation) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieConversation) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieConversation) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieConversation) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieConversation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieConversation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieConversation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_timestamp": types.Int64Type, @@ -507,9 +1028,56 @@ func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenieCreateConversationMessageRequest in the Terraform plugin framework type -// system. -func (a GenieCreateConversationMessageRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieCreateConversationMessageRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieCreateConversationMessageRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -546,9 +1114,56 @@ func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenieExecuteMessageQueryRequest in the Terraform plugin framework type -// system. -func (a GenieExecuteMessageQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieExecuteMessageQueryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieExecuteMessageQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation_id": types.StringType, @@ -587,9 +1202,56 @@ func (a GenieGetConversationMessageRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenieGetConversationMessageRequest in the Terraform plugin framework type -// system. -func (a GenieGetConversationMessageRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieGetConversationMessageRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieGetConversationMessageRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation_id": types.StringType, @@ -626,9 +1288,56 @@ func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenieGetMessageQueryResultRequest in the Terraform plugin framework type -// system. -func (a GenieGetMessageQueryResultRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieGetMessageQueryResultRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation_id": types.StringType, @@ -663,13 +1372,60 @@ func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of GenieGetMessageQueryResultResponse in the Terraform plugin framework type -// system. -func (a GenieGetMessageQueryResultResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieGetMessageQueryResultResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieGetMessageQueryResultResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statement_response": basetypes.ListType{ - ElemType: sql_tf.StatementResponse{}.ToObjectType(ctx), + ElemType: sql_tf.StatementResponse{}.Type(ctx), }, }, } @@ -736,24 +1492,71 @@ func (a GenieMessage) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of GenieMessage in the Terraform plugin framework type -// system. -func (a GenieMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attachments": basetypes.ListType{ - ElemType: GenieAttachment{}.ToObjectType(ctx), + ElemType: GenieAttachment{}.Type(ctx), }, "content": types.StringType, "conversation_id": types.StringType, "created_timestamp": types.Int64Type, "error": basetypes.ListType{ - ElemType: MessageError{}.ToObjectType(ctx), + ElemType: MessageError{}.Type(ctx), }, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "query_result": basetypes.ListType{ - ElemType: Result{}.ToObjectType(ctx), + ElemType: Result{}.Type(ctx), }, "space_id": types.StringType, "status": types.StringType, @@ -787,10 +1590,57 @@ func (a GenieStartConversationMessageRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenieStartConversationMessageRequest in the Terraform plugin framework type -// system. -func (a GenieStartConversationMessageRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieStartConversationMessageRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieStartConversationMessageRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, "space_id": types.StringType, @@ -828,17 +1678,64 @@ func (a GenieStartConversationResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of GenieStartConversationResponse in the Terraform plugin framework type -// system. -func (a GenieStartConversationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenieStartConversationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenieStartConversationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "conversation": basetypes.ListType{ - ElemType: GenieConversation{}.ToObjectType(ctx), + ElemType: GenieConversation{}.Type(ctx), }, "conversation_id": types.StringType, "message": basetypes.ListType{ - ElemType: GenieMessage{}.ToObjectType(ctx), + ElemType: GenieMessage{}.Type(ctx), }, "message_id": types.StringType, }, @@ -868,9 +1765,56 @@ func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDashboardRequest in the Terraform plugin framework type -// system. -func (a GetDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -901,9 +1845,56 @@ func (a GetPublishedDashboardRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPublishedDashboardRequest in the Terraform plugin framework type -// system. -func (a GetPublishedDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPublishedDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPublishedDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -936,9 +1927,56 @@ func (a GetScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetScheduleRequest in the Terraform plugin framework type -// system. -func (a GetScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetScheduleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetScheduleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetScheduleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetScheduleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetScheduleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -974,9 +2012,56 @@ func (a GetSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetSubscriptionRequest in the Terraform plugin framework type -// system. -func (a GetSubscriptionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetSubscriptionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetSubscriptionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1017,9 +2102,56 @@ func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListDashboardsRequest in the Terraform plugin framework type -// system. -func (a ListDashboardsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListDashboardsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -1056,13 +2188,60 @@ func (a ListDashboardsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ListDashboardsResponse in the Terraform plugin framework type -// system. -func (a ListDashboardsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListDashboardsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListDashboardsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboards": basetypes.ListType{ - ElemType: Dashboard{}.ToObjectType(ctx), + ElemType: Dashboard{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -1097,9 +2276,56 @@ func (a ListSchedulesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSchedulesRequest in the Terraform plugin framework type -// system. -func (a ListSchedulesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSchedulesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSchedulesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1137,14 +2363,61 @@ func (a ListSchedulesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListSchedulesResponse in the Terraform plugin framework type -// system. -func (a ListSchedulesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSchedulesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSchedulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "schedules": basetypes.ListType{ - ElemType: Schedule{}.ToObjectType(ctx), + ElemType: Schedule{}.Type(ctx), }, }, } @@ -1180,9 +2453,56 @@ func (a ListSubscriptionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSubscriptionsRequest in the Terraform plugin framework type -// system. -func (a ListSubscriptionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSubscriptionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSubscriptionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1221,14 +2541,61 @@ func (a ListSubscriptionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ListSubscriptionsResponse in the Terraform plugin framework type -// system. -func (a ListSubscriptionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSubscriptionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSubscriptionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "subscriptions": basetypes.ListType{ - ElemType: Subscription{}.ToObjectType(ctx), + ElemType: Subscription{}.Type(ctx), }, }, } @@ -1237,7 +2604,7 @@ func (a ListSubscriptionsResponse) ToObjectType(ctx context.Context) types.Objec type MessageError struct { Error types.String `tfsdk:"error" tf:"optional"` - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *MessageError) SyncEffectiveFieldsDuringCreateOrUpdate(plan MessageError) { @@ -1257,9 +2624,56 @@ func (a MessageError) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of MessageError in the Terraform plugin framework type -// system. -func (a MessageError) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MessageError{} + +// Equal implements basetypes.ObjectValuable. +func (o MessageError) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MessageError) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MessageError) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MessageError) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MessageError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MessageError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MessageError) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": types.StringType, @@ -1295,9 +2709,56 @@ func (a MigrateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of MigrateDashboardRequest in the Terraform plugin framework type -// system. -func (a MigrateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MigrateDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MigrateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -1336,9 +2797,56 @@ func (a PublishRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of PublishRequest in the Terraform plugin framework type -// system. -func (a PublishRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PublishRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PublishRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PublishRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PublishRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PublishRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PublishRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PublishRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PublishRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1376,9 +2884,56 @@ func (a PublishedDashboard) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of PublishedDashboard in the Terraform plugin framework type -// system. -func (a PublishedDashboard) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PublishedDashboard{} + +// Equal implements basetypes.ObjectValuable. +func (o PublishedDashboard) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PublishedDashboard) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PublishedDashboard) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PublishedDashboard) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PublishedDashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PublishedDashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PublishedDashboard) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -1425,9 +2980,56 @@ func (a QueryAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of QueryAttachment in the Terraform plugin framework type -// system. -func (a QueryAttachment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryAttachment{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryAttachment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryAttachment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryAttachment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryAttachment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryAttachment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryAttachment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1469,9 +3071,56 @@ func (a Result) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Result in the Terraform plugin framework type -// system. -func (a Result) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Result{} + +// Equal implements basetypes.ObjectValuable. +func (o Result) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Result) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Result) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Result) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Result) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Result) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Result) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_truncated": types.BoolType, @@ -1524,14 +3173,61 @@ func (a Schedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of Schedule in the Terraform plugin framework type -// system. -func (a Schedule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Schedule{} + +// Equal implements basetypes.ObjectValuable. +func (o Schedule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Schedule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Schedule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Schedule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Schedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Schedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Schedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, "cron_schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToObjectType(ctx), + ElemType: CronSchedule{}.Type(ctx), }, "dashboard_id": types.StringType, "display_name": types.StringType, @@ -1573,16 +3269,63 @@ func (a Subscriber) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of Subscriber in the Terraform plugin framework type -// system. -func (a Subscriber) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Subscriber{} + +// Equal implements basetypes.ObjectValuable. +func (o Subscriber) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Subscriber) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Subscriber) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Subscriber) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Subscriber) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Subscriber) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Subscriber) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_subscriber": basetypes.ListType{ - ElemType: SubscriptionSubscriberDestination{}.ToObjectType(ctx), + ElemType: SubscriptionSubscriberDestination{}.Type(ctx), }, "user_subscriber": basetypes.ListType{ - ElemType: SubscriptionSubscriberUser{}.ToObjectType(ctx), + ElemType: SubscriptionSubscriberUser{}.Type(ctx), }, }, } @@ -1630,9 +3373,56 @@ func (a Subscription) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of Subscription in the Terraform plugin framework type -// system. -func (a Subscription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Subscription{} + +// Equal implements basetypes.ObjectValuable. +func (o Subscription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Subscription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Subscription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Subscription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Subscription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Subscription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Subscription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -1641,7 +3431,7 @@ func (a Subscription) ToObjectType(ctx context.Context) types.ObjectType { "etag": types.StringType, "schedule_id": types.StringType, "subscriber": basetypes.ListType{ - ElemType: Subscriber{}.ToObjectType(ctx), + ElemType: Subscriber{}.Type(ctx), }, "subscription_id": types.StringType, "update_time": types.StringType, @@ -1672,9 +3462,56 @@ func (a SubscriptionSubscriberDestination) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of SubscriptionSubscriberDestination in the Terraform plugin framework type -// system. -func (a SubscriptionSubscriberDestination) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SubscriptionSubscriberDestination{} + +// Equal implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_id": types.StringType, @@ -1704,9 +3541,56 @@ func (a SubscriptionSubscriberUser) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of SubscriptionSubscriberUser in the Terraform plugin framework type -// system. -func (a SubscriptionSubscriberUser) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SubscriptionSubscriberUser{} + +// Equal implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SubscriptionSubscriberUser) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "user_id": types.Int64Type, @@ -1738,9 +3622,56 @@ func (a TextAttachment) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of TextAttachment in the Terraform plugin framework type -// system. -func (a TextAttachment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TextAttachment{} + +// Equal implements basetypes.ObjectValuable. +func (o TextAttachment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TextAttachment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TextAttachment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TextAttachment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TextAttachment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TextAttachment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TextAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -1772,9 +3703,56 @@ func (a TrashDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of TrashDashboardRequest in the Terraform plugin framework type -// system. -func (a TrashDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TrashDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TrashDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1802,9 +3780,56 @@ func (a TrashDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of TrashDashboardResponse in the Terraform plugin framework type -// system. -func (a TrashDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TrashDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TrashDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1833,9 +3858,56 @@ func (a UnpublishDashboardRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of UnpublishDashboardRequest in the Terraform plugin framework type -// system. -func (a UnpublishDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UnpublishDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UnpublishDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1863,9 +3935,56 @@ func (a UnpublishDashboardResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of UnpublishDashboardResponse in the Terraform plugin framework type -// system. -func (a UnpublishDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UnpublishDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UnpublishDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1897,13 +4016,60 @@ func (a UpdateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of UpdateDashboardRequest in the Terraform plugin framework type -// system. -func (a UpdateDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard": basetypes.ListType{ - ElemType: Dashboard{}.ToObjectType(ctx), + ElemType: Dashboard{}.Type(ctx), }, "dashboard_id": types.StringType, }, @@ -1939,16 +4105,79 @@ func (a UpdateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateScheduleRequest in the Terraform plugin framework type -// system. -func (a UpdateScheduleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateScheduleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule": basetypes.ListType{ - ElemType: Schedule{}.ToObjectType(ctx), + ElemType: Schedule{}.Type(ctx), }, "schedule_id": types.StringType, }, } } + +// MesssageStatus. The possible values are: * `FETCHING_METADATA`: Fetching +// metadata from the data sources. * `FILTERING_CONTEXT`: Running smart context +// step to determine relevant context. * `ASKING_AI`: Waiting for the LLM to +// respond to the users question. * `EXECUTING_QUERY`: Executing AI provided SQL +// query. Get the SQL query result by calling +// [getMessageQueryResult](:method:genie/getMessageQueryResult) API. +// **Important: The message status will stay in the `EXECUTING_QUERY` until a +// client calls [getMessageQueryResult](:method:genie/getMessageQueryResult)**. +// * `FAILED`: Generating a response or the executing the query failed. Please +// see `error` field. * `COMPLETED`: Message processing is completed. Results +// are in the `attachments` field. Get the SQL query result by calling +// [getMessageQueryResult](:method:genie/getMessageQueryResult) API. * +// `SUBMITTED`: Message has been submitted. * `QUERY_RESULT_EXPIRED`: SQL result +// is not available anymore. The user needs to execute the query again. * +// `CANCELLED`: Message has been cancelled. diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 9c328c1474..35c9e75465 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -12,12 +12,16 @@ package files_tf import ( "context" + "fmt" "io" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AddBlock struct { @@ -45,9 +49,56 @@ func (a AddBlock) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of AddBlock in the Terraform plugin framework type -// system. -func (a AddBlock) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AddBlock{} + +// Equal implements basetypes.ObjectValuable. +func (o AddBlock) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AddBlock) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AddBlock) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AddBlock) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AddBlock) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AddBlock) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AddBlock) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data": types.StringType, @@ -76,9 +127,56 @@ func (a AddBlockResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of AddBlockResponse in the Terraform plugin framework type -// system. -func (a AddBlockResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AddBlockResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AddBlockResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AddBlockResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AddBlockResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AddBlockResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AddBlockResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AddBlockResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AddBlockResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -106,9 +204,56 @@ func (a Close) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Close in the Terraform plugin framework type -// system. -func (a Close) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Close{} + +// Equal implements basetypes.ObjectValuable. +func (o Close) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Close) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Close) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Close) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Close) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Close) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Close) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "handle": types.Int64Type, @@ -136,9 +281,56 @@ func (a CloseResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of CloseResponse in the Terraform plugin framework type -// system. -func (a CloseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CloseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CloseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CloseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CloseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CloseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CloseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CloseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CloseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -168,9 +360,56 @@ func (a Create) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Create in the Terraform plugin framework type -// system. -func (a Create) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Create{} + +// Equal implements basetypes.ObjectValuable. +func (o Create) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Create) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Create) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Create) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Create) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Create) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Create) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "overwrite": types.BoolType, @@ -202,9 +441,56 @@ func (a CreateDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateDirectoryRequest in the Terraform plugin framework type -// system. -func (a CreateDirectoryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateDirectoryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateDirectoryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -232,9 +518,56 @@ func (a CreateDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateDirectoryResponse in the Terraform plugin framework type -// system. -func (a CreateDirectoryResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateDirectoryResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -263,9 +596,56 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type -// system. -func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "handle": types.Int64Type, @@ -299,9 +679,56 @@ func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Delete in the Terraform plugin framework type -// system. -func (a Delete) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Delete{} + +// Equal implements basetypes.ObjectValuable. +func (o Delete) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Delete) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Delete) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Delete) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Delete) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Delete) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Delete) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -333,9 +760,56 @@ func (a DeleteDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDirectoryRequest in the Terraform plugin framework type -// system. -func (a DeleteDirectoryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDirectoryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDirectoryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -363,9 +837,56 @@ func (a DeleteDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDirectoryResponse in the Terraform plugin framework type -// system. -func (a DeleteDirectoryResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDirectoryResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -394,9 +915,56 @@ func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteFileRequest in the Terraform plugin framework type -// system. -func (a DeleteFileRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteFileRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteFileRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteFileRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteFileRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteFileRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteFileRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_path": types.StringType, @@ -424,9 +992,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -463,9 +1078,56 @@ func (a DirectoryEntry) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DirectoryEntry in the Terraform plugin framework type -// system. -func (a DirectoryEntry) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DirectoryEntry{} + +// Equal implements basetypes.ObjectValuable. +func (o DirectoryEntry) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DirectoryEntry) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DirectoryEntry) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DirectoryEntry) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DirectoryEntry) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DirectoryEntry) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DirectoryEntry) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_size": types.Int64Type, @@ -500,9 +1162,56 @@ func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DownloadRequest in the Terraform plugin framework type -// system. -func (a DownloadRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DownloadRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DownloadRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DownloadRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DownloadRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DownloadRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DownloadRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DownloadRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DownloadRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_path": types.StringType, @@ -537,9 +1246,56 @@ func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of DownloadResponse in the Terraform plugin framework type -// system. -func (a DownloadResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DownloadResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DownloadResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DownloadResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DownloadResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DownloadResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DownloadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DownloadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DownloadResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content-length": types.Int64Type, @@ -578,9 +1334,56 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of FileInfo in the Terraform plugin framework type -// system. -func (a FileInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FileInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o FileInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FileInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FileInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FileInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FileInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_size": types.Int64Type, @@ -614,9 +1417,56 @@ func (a GetDirectoryMetadataRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDirectoryMetadataRequest in the Terraform plugin framework type -// system. -func (a GetDirectoryMetadataRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDirectoryMetadataRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -644,9 +1494,56 @@ func (a GetDirectoryMetadataResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDirectoryMetadataResponse in the Terraform plugin framework type -// system. -func (a GetDirectoryMetadataResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDirectoryMetadataResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDirectoryMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -675,9 +1572,56 @@ func (a GetMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetMetadataRequest in the Terraform plugin framework type -// system. -func (a GetMetadataRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetMetadataRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetMetadataRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetMetadataRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetMetadataRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetMetadataRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetMetadataRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetMetadataRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetMetadataRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_path": types.StringType, @@ -710,9 +1654,56 @@ func (a GetMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetMetadataResponse in the Terraform plugin framework type -// system. -func (a GetMetadataResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetMetadataResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetMetadataResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetMetadataResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetMetadataResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetMetadataResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetMetadataResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetMetadataResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content-length": types.Int64Type, @@ -746,9 +1737,56 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStatusRequest in the Terraform plugin framework type -// system. -func (a GetStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStatusRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStatusRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStatusRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStatusRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStatusRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStatusRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -780,9 +1818,56 @@ func (a ListDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListDbfsRequest in the Terraform plugin framework type -// system. -func (a ListDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListDbfsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListDbfsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListDbfsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListDbfsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListDbfsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListDbfsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -833,9 +1918,56 @@ func (a ListDirectoryContentsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListDirectoryContentsRequest in the Terraform plugin framework type -// system. -func (a ListDirectoryContentsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListDirectoryContentsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListDirectoryContentsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "directory_path": types.StringType, @@ -871,13 +2003,60 @@ func (a ListDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListDirectoryResponse in the Terraform plugin framework type -// system. -func (a ListDirectoryResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListDirectoryResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": basetypes.ListType{ - ElemType: DirectoryEntry{}.ToObjectType(ctx), + ElemType: DirectoryEntry{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -909,13 +2088,60 @@ func (a ListStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListStatusResponse in the Terraform plugin framework type -// system. -func (a ListStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListStatusResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListStatusResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListStatusResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListStatusResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListStatusResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "files": basetypes.ListType{ - ElemType: FileInfo{}.ToObjectType(ctx), + ElemType: FileInfo{}.Type(ctx), }, }, } @@ -943,9 +2169,56 @@ func (a MkDirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of MkDirs in the Terraform plugin framework type -// system. -func (a MkDirs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MkDirs{} + +// Equal implements basetypes.ObjectValuable. +func (o MkDirs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MkDirs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MkDirs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MkDirs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MkDirs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MkDirs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MkDirs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -973,9 +2246,56 @@ func (a MkDirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of MkDirsResponse in the Terraform plugin framework type -// system. -func (a MkDirsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MkDirsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o MkDirsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MkDirsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MkDirsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MkDirsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MkDirsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MkDirsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MkDirsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1007,9 +2327,56 @@ func (a Move) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Move in the Terraform plugin framework type -// system. -func (a Move) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Move{} + +// Equal implements basetypes.ObjectValuable. +func (o Move) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Move) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Move) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Move) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Move) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Move) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Move) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_path": types.StringType, @@ -1038,9 +2405,56 @@ func (a MoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of MoveResponse in the Terraform plugin framework type -// system. -func (a MoveResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MoveResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o MoveResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MoveResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MoveResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MoveResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MoveResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MoveResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MoveResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1072,9 +2486,56 @@ func (a Put) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } -// ToObjectType returns the representation of Put in the Terraform plugin framework type -// system. -func (a Put) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Put{} + +// Equal implements basetypes.ObjectValuable. +func (o Put) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Put) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Put) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Put) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Put) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Put) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Put) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.StringType, @@ -1104,9 +2565,56 @@ func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of PutResponse in the Terraform plugin framework type -// system. -func (a PutResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PutResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1140,9 +2648,56 @@ func (a ReadDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ReadDbfsRequest in the Terraform plugin framework type -// system. -func (a ReadDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReadDbfsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReadDbfsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "length": types.Int64Type, @@ -1178,9 +2733,56 @@ func (a ReadResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of ReadResponse in the Terraform plugin framework type -// system. -func (a ReadResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReadResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ReadResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReadResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReadResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReadResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReadResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bytes_read": types.Int64Type, @@ -1215,9 +2817,56 @@ func (a UploadRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of UploadRequest in the Terraform plugin framework type -// system. -func (a UploadRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UploadRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UploadRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UploadRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UploadRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UploadRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UploadRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UploadRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UploadRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.ObjectType{}, @@ -1247,9 +2896,56 @@ func (a UploadResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UploadResponse in the Terraform plugin framework type -// system. -func (a UploadResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UploadResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UploadResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UploadResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UploadResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UploadResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UploadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UploadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UploadResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 273094da12..cfc82023c2 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -12,11 +12,15 @@ package iam_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AccessControlRequest struct { @@ -47,9 +51,56 @@ func (a AccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of AccessControlRequest in the Terraform plugin framework type -// system. -func (a AccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o AccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -92,13 +143,60 @@ func (a AccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of AccessControlResponse in the Terraform plugin framework type -// system. -func (a AccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: Permission{}.ToObjectType(ctx), + ElemType: Permission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -115,7 +213,7 @@ type ComplexValue struct { Ref types.String `tfsdk:"$ref" tf:"optional"` - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` Value types.String `tfsdk:"value" tf:"optional"` } @@ -137,9 +235,56 @@ func (a ComplexValue) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of ComplexValue in the Terraform plugin framework type -// system. -func (a ComplexValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ComplexValue{} + +// Equal implements basetypes.ObjectValuable. +func (o ComplexValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ComplexValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ComplexValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ComplexValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ComplexValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ComplexValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ComplexValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display": types.StringType, @@ -174,9 +319,56 @@ func (a DeleteAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountGroupRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountGroupRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountGroupRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -207,9 +399,56 @@ func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountServicePrincipalRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountServicePrincipalRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountServicePrincipalRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -240,9 +479,56 @@ func (a DeleteAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountUserRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountUserRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountUserRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountUserRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -273,9 +559,56 @@ func (a DeleteGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteGroupRequest in the Terraform plugin framework type -// system. -func (a DeleteGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteGroupRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteGroupRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -303,9 +636,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -334,9 +714,56 @@ func (a DeleteServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteServicePrincipalRequest in the Terraform plugin framework type -// system. -func (a DeleteServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteServicePrincipalRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -367,9 +794,56 @@ func (a DeleteUserRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteUserRequest in the Terraform plugin framework type -// system. -func (a DeleteUserRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteUserRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteUserRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteUserRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteUserRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteUserRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteUserRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -402,9 +876,56 @@ func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWorkspaceAssignmentRequest in the Terraform plugin framework type -// system. -func (a DeleteWorkspaceAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWorkspaceAssignmentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWorkspaceAssignmentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal_id": types.Int64Type, @@ -433,9 +954,56 @@ func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWorkspacePermissionAssignmentResponse in the Terraform plugin framework type -// system. -func (a DeleteWorkspacePermissionAssignmentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWorkspacePermissionAssignmentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWorkspacePermissionAssignmentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -464,9 +1032,56 @@ func (a GetAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountGroupRequest in the Terraform plugin framework type -// system. -func (a GetAccountGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountGroupRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountGroupRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -497,9 +1112,56 @@ func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountServicePrincipalRequest in the Terraform plugin framework type -// system. -func (a GetAccountServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountServicePrincipalRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountServicePrincipalRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -551,9 +1213,56 @@ func (a GetAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountUserRequest in the Terraform plugin framework type -// system. -func (a GetAccountUserRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountUserRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountUserRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -591,9 +1300,56 @@ func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAssignableRolesForResourceRequest in the Terraform plugin framework type -// system. -func (a GetAssignableRolesForResourceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAssignableRolesForResourceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resource": types.StringType, @@ -624,13 +1380,60 @@ func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes(ctx context. } } -// ToObjectType returns the representation of GetAssignableRolesForResourceResponse in the Terraform plugin framework type -// system. -func (a GetAssignableRolesForResourceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAssignableRolesForResourceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAssignableRolesForResourceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "roles": basetypes.ListType{ - ElemType: Role{}.ToObjectType(ctx), + ElemType: Role{}.Type(ctx), }, }, } @@ -659,10 +1462,57 @@ func (a GetGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetGroupRequest in the Terraform plugin framework type -// system. -func (a GetGroupRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetGroupRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetGroupRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetGroupRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetGroupRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetGroupRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetGroupRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, }, @@ -693,13 +1543,60 @@ func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Co } } -// ToObjectType returns the representation of GetPasswordPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetPasswordPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPasswordPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPasswordPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: PasswordPermissionsDescription{}.ToObjectType(ctx), + ElemType: PasswordPermissionsDescription{}.Type(ctx), }, }, } @@ -730,9 +1627,56 @@ func (a GetPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request_object_id": types.StringType, @@ -765,13 +1709,60 @@ func (a GetPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of GetPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: PermissionsDescription{}.ToObjectType(ctx), + ElemType: PermissionsDescription{}.Type(ctx), }, }, } @@ -806,9 +1797,56 @@ func (a GetPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPermissionRequest in the Terraform plugin framework type -// system. -func (a GetPermissionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPermissionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPermissionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPermissionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPermissionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPermissionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPermissionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPermissionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPermissionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request_object_id": types.StringType, @@ -849,9 +1887,56 @@ func (a GetRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRuleSetRequest in the Terraform plugin framework type -// system. -func (a GetRuleSetRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRuleSetRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRuleSetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -883,9 +1968,56 @@ func (a GetServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetServicePrincipalRequest in the Terraform plugin framework type -// system. -func (a GetServicePrincipalRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetServicePrincipalRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetServicePrincipalRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -937,9 +2069,56 @@ func (a GetUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetUserRequest in the Terraform plugin framework type -// system. -func (a GetUserRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetUserRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetUserRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetUserRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetUserRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetUserRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetUserRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -977,9 +2156,56 @@ func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWorkspaceAssignmentRequest in the Terraform plugin framework type -// system. -func (a GetWorkspaceAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceAssignmentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceAssignmentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1013,9 +2239,56 @@ func (a GrantRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of GrantRule in the Terraform plugin framework type -// system. -func (a GrantRule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GrantRule{} + +// Equal implements basetypes.ObjectValuable. +func (o GrantRule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GrantRule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GrantRule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GrantRule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GrantRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GrantRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GrantRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principals": basetypes.ListType{ @@ -1074,28 +2347,75 @@ func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of Group in the Terraform plugin framework type -// system. -func (a Group) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Group{} + +// Equal implements basetypes.ObjectValuable. +func (o Group) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Group) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Group) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Group) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Group) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Group) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Group) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "displayName": types.StringType, "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "externalId": types.StringType, "groups": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "id": types.StringType, "members": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "meta": basetypes.ListType{ - ElemType: ResourceMeta{}.ToObjectType(ctx), + ElemType: ResourceMeta{}.Type(ctx), }, "roles": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1145,9 +2465,56 @@ func (a ListAccountGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAccountGroupsRequest in the Terraform plugin framework type -// system. -func (a ListAccountGroupsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountGroupsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountGroupsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1202,9 +2569,56 @@ func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAccountServicePrincipalsRequest in the Terraform plugin framework type -// system. -func (a ListAccountServicePrincipalsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountServicePrincipalsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountServicePrincipalsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1260,9 +2674,56 @@ func (a ListAccountUsersRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAccountUsersRequest in the Terraform plugin framework type -// system. -func (a ListAccountUsersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAccountUsersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAccountUsersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1317,9 +2778,56 @@ func (a ListGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListGroupsRequest in the Terraform plugin framework type -// system. -func (a ListGroupsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListGroupsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListGroupsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListGroupsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListGroupsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListGroupsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListGroupsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListGroupsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListGroupsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1367,14 +2875,61 @@ func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListGroupsResponse in the Terraform plugin framework type -// system. -func (a ListGroupsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListGroupsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListGroupsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListGroupsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListGroupsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListGroupsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListGroupsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListGroupsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListGroupsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ - ElemType: Group{}.ToObjectType(ctx), + ElemType: Group{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1419,14 +2974,61 @@ func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListServicePrincipalResponse in the Terraform plugin framework type -// system. -func (a ListServicePrincipalResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListServicePrincipalResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListServicePrincipalResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ - ElemType: ServicePrincipal{}.ToObjectType(ctx), + ElemType: ServicePrincipal{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1478,9 +3080,56 @@ func (a ListServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListServicePrincipalsRequest in the Terraform plugin framework type -// system. -func (a ListServicePrincipalsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListServicePrincipalsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListServicePrincipalsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1536,9 +3185,56 @@ func (a ListUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListUsersRequest in the Terraform plugin framework type -// system. -func (a ListUsersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListUsersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListUsersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListUsersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListUsersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListUsersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListUsersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListUsersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListUsersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attributes": types.StringType, @@ -1586,14 +3282,61 @@ func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ListUsersResponse in the Terraform plugin framework type -// system. -func (a ListUsersResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListUsersResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListUsersResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListUsersResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListUsersResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListUsersResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListUsersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListUsersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListUsersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, "Resources": basetypes.ListType{ - ElemType: User{}.ToObjectType(ctx), + ElemType: User{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1627,9 +3370,56 @@ func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListWorkspaceAssignmentRequest in the Terraform plugin framework type -// system. -func (a ListWorkspaceAssignmentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListWorkspaceAssignmentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListWorkspaceAssignmentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1666,9 +3456,56 @@ func (a MigratePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of MigratePermissionsRequest in the Terraform plugin framework type -// system. -func (a MigratePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MigratePermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MigratePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "from_workspace_group_name": types.StringType, @@ -1701,9 +3538,56 @@ func (a MigratePermissionsResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of MigratePermissionsResponse in the Terraform plugin framework type -// system. -func (a MigratePermissionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MigratePermissionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MigratePermissionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permissions_migrated": types.Int64Type, @@ -1735,9 +3619,56 @@ func (a Name) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Name in the Terraform plugin framework type -// system. -func (a Name) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Name{} + +// Equal implements basetypes.ObjectValuable. +func (o Name) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Name) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Name) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Name) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Name) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Name) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Name) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "familyName": types.StringType, @@ -1773,13 +3704,60 @@ func (a ObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ObjectPermissions in the Terraform plugin framework type -// system. -func (a ObjectPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ObjectPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o ObjectPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ObjectPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ObjectPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ObjectPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ObjectPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ObjectPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControlResponse{}.ToObjectType(ctx), + ElemType: AccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1817,14 +3795,61 @@ func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of PartialUpdate in the Terraform plugin framework type -// system. -func (a PartialUpdate) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PartialUpdate{} + +// Equal implements basetypes.ObjectValuable. +func (o PartialUpdate) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PartialUpdate) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PartialUpdate) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PartialUpdate) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PartialUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PartialUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PartialUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "Operations": basetypes.ListType{ - ElemType: Patch{}.ToObjectType(ctx), + ElemType: Patch{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -1861,9 +3886,56 @@ func (a PasswordAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of PasswordAccessControlRequest in the Terraform plugin framework type -// system. -func (a PasswordAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PasswordAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PasswordAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1906,13 +3978,60 @@ func (a PasswordAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of PasswordAccessControlResponse in the Terraform plugin framework type -// system. -func (a PasswordAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PasswordAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PasswordAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: PasswordPermission{}.ToObjectType(ctx), + ElemType: PasswordPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1949,9 +4068,56 @@ func (a PasswordPermission) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of PasswordPermission in the Terraform plugin framework type -// system. -func (a PasswordPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PasswordPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o PasswordPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PasswordPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PasswordPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PasswordPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PasswordPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PasswordPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PasswordPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1990,13 +4156,60 @@ func (a PasswordPermissions) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of PasswordPermissions in the Terraform plugin framework type -// system. -func (a PasswordPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PasswordPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o PasswordPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PasswordPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PasswordPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PasswordPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PasswordPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PasswordPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PasswordPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PasswordAccessControlResponse{}.ToObjectType(ctx), + ElemType: PasswordAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2027,9 +4240,56 @@ func (a PasswordPermissionsDescription) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of PasswordPermissionsDescription in the Terraform plugin framework type -// system. -func (a PasswordPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PasswordPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PasswordPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2061,13 +4321,60 @@ func (a PasswordPermissionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of PasswordPermissionsRequest in the Terraform plugin framework type -// system. -func (a PasswordPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PasswordPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PasswordPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PasswordAccessControlRequest{}.ToObjectType(ctx), + ElemType: PasswordAccessControlRequest{}.Type(ctx), }, }, } @@ -2099,9 +4406,56 @@ func (a Patch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Patch in the Terraform plugin framework type -// system. -func (a Patch) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Patch{} + +// Equal implements basetypes.ObjectValuable. +func (o Patch) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Patch) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Patch) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Patch) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Patch) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Patch) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Patch) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "op": types.StringType, @@ -2131,9 +4485,56 @@ func (a PatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of PatchResponse in the Terraform plugin framework type -// system. -func (a PatchResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PatchResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PatchResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PatchResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PatchResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PatchResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PatchResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PatchResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PatchResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2147,28 +4548,75 @@ type Permission struct { PermissionLevel types.String `tfsdk:"permission_level" tf:"optional"` } -func (newState *Permission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Permission) { +func (newState *Permission) SyncEffectiveFieldsDuringCreateOrUpdate(plan Permission) { +} + +func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permission) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in Permission. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "inherited_from_object": reflect.TypeOf(types.String{}), + } +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Permission{} + +// Equal implements basetypes.ObjectValuable. +func (o Permission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Permission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Permission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Permission) String() string { + return fmt.Sprintf("%#v", o) } -func (newState *Permission) SyncEffectiveFieldsDuringRead(existingState Permission) { +// ToObjectValue implements basetypes.ObjectValuable. +func (o Permission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in Permission. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "inherited_from_object": reflect.TypeOf(types.String{}), +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Permission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of Permission in the Terraform plugin framework type -// system. -func (a Permission) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o Permission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2211,9 +4659,56 @@ func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of PermissionAssignment in the Terraform plugin framework type -// system. -func (a PermissionAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": types.StringType, @@ -2221,7 +4716,7 @@ func (a PermissionAssignment) ToObjectType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "principal": basetypes.ListType{ - ElemType: PrincipalOutput{}.ToObjectType(ctx), + ElemType: PrincipalOutput{}.Type(ctx), }, }, } @@ -2251,13 +4746,60 @@ func (a PermissionAssignments) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of PermissionAssignments in the Terraform plugin framework type -// system. -func (a PermissionAssignments) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionAssignments{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionAssignments) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionAssignments) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionAssignments) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionAssignments) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionAssignments) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionAssignments) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_assignments": basetypes.ListType{ - ElemType: PermissionAssignment{}.ToObjectType(ctx), + ElemType: PermissionAssignment{}.Type(ctx), }, }, } @@ -2287,9 +4829,56 @@ func (a PermissionOutput) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of PermissionOutput in the Terraform plugin framework type -// system. -func (a PermissionOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2321,9 +4910,56 @@ func (a PermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of PermissionsDescription in the Terraform plugin framework type -// system. -func (a PermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2363,13 +4999,60 @@ func (a PermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of PermissionsRequest in the Terraform plugin framework type -// system. -func (a PermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControlRequest{}.ToObjectType(ctx), + ElemType: AccessControlRequest{}.Type(ctx), }, "request_object_id": types.StringType, "request_object_type": types.StringType, @@ -2409,9 +5092,56 @@ func (a PrincipalOutput) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of PrincipalOutput in the Terraform plugin framework type -// system. -func (a PrincipalOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PrincipalOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o PrincipalOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PrincipalOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PrincipalOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PrincipalOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PrincipalOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PrincipalOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PrincipalOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -2446,9 +5176,56 @@ func (a ResourceMeta) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of ResourceMeta in the Terraform plugin framework type -// system. -func (a ResourceMeta) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResourceMeta{} + +// Equal implements basetypes.ObjectValuable. +func (o ResourceMeta) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResourceMeta) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResourceMeta) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResourceMeta) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResourceMeta) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResourceMeta) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResourceMeta) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resourceType": types.StringType, @@ -2478,9 +5255,56 @@ func (a Role) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Role in the Terraform plugin framework type -// system. -func (a Role) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Role{} + +// Equal implements basetypes.ObjectValuable. +func (o Role) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Role) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Role) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Role) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Role) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Role) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Role) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2516,14 +5340,61 @@ func (a RuleSetResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of RuleSetResponse in the Terraform plugin framework type -// system. -func (a RuleSetResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RuleSetResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RuleSetResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RuleSetResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RuleSetResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RuleSetResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RuleSetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RuleSetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RuleSetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "grant_rules": basetypes.ListType{ - ElemType: GrantRule{}.ToObjectType(ctx), + ElemType: GrantRule{}.Type(ctx), }, "name": types.StringType, }, @@ -2560,14 +5431,61 @@ func (a RuleSetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of RuleSetUpdateRequest in the Terraform plugin framework type -// system. -func (a RuleSetUpdateRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RuleSetUpdateRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RuleSetUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "grant_rules": basetypes.ListType{ - ElemType: GrantRule{}.ToObjectType(ctx), + ElemType: GrantRule{}.Type(ctx), }, "name": types.StringType, }, @@ -2620,24 +5538,71 @@ func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ServicePrincipal in the Terraform plugin framework type -// system. -func (a ServicePrincipal) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServicePrincipal{} + +// Equal implements basetypes.ObjectValuable. +func (o ServicePrincipal) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServicePrincipal) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServicePrincipal) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServicePrincipal) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServicePrincipal) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServicePrincipal) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServicePrincipal) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active": types.BoolType, "applicationId": types.StringType, "displayName": types.StringType, "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "externalId": types.StringType, "groups": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "id": types.StringType, "roles": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -2666,9 +5631,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2700,14 +5712,61 @@ func (a UpdateRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of UpdateRuleSetRequest in the Terraform plugin framework type -// system. -func (a UpdateRuleSetRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRuleSetRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRuleSetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "rule_set": basetypes.ListType{ - ElemType: RuleSetUpdateRequest{}.ToObjectType(ctx), + ElemType: RuleSetUpdateRequest{}.Type(ctx), }, }, } @@ -2746,9 +5805,56 @@ func (a UpdateWorkspaceAssignments) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of UpdateWorkspaceAssignments in the Terraform plugin framework type -// system. -func (a UpdateWorkspaceAssignments) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateWorkspaceAssignments{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateWorkspaceAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permissions": basetypes.ListType{ @@ -2818,29 +5924,76 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of User in the Terraform plugin framework type -// system. -func (a User) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = User{} + +// Equal implements basetypes.ObjectValuable. +func (o User) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o User) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o User) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o User) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o User) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o User) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o User) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active": types.BoolType, "displayName": types.StringType, "emails": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "externalId": types.StringType, "groups": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "id": types.StringType, "name": basetypes.ListType{ - ElemType: Name{}.ToObjectType(ctx), + ElemType: Name{}.Type(ctx), }, "roles": basetypes.ListType{ - ElemType: ComplexValue{}.ToObjectType(ctx), + ElemType: ComplexValue{}.Type(ctx), }, "schemas": basetypes.ListType{ ElemType: types.StringType, @@ -2874,14 +6027,67 @@ func (a WorkspacePermissions) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of WorkspacePermissions in the Terraform plugin framework type -// system. -func (a WorkspacePermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspacePermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspacePermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspacePermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspacePermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspacePermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspacePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspacePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspacePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permissions": basetypes.ListType{ - ElemType: PermissionOutput{}.ToObjectType(ctx), + ElemType: PermissionOutput{}.Type(ctx), }, }, } } + +// Permission level + +// Type of patch operation. + +// Permission level diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 8fe91bb525..dca7a02c1d 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -12,13 +12,17 @@ package jobs_tf import ( "context" + "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/compute" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type BaseJob struct { @@ -61,9 +65,56 @@ func (a BaseJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of BaseJob in the Terraform plugin framework type -// system. -func (a BaseJob) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BaseJob{} + +// Equal implements basetypes.ObjectValuable. +func (o BaseJob) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BaseJob) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BaseJob) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BaseJob) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BaseJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BaseJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BaseJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_time": types.Int64Type, @@ -71,7 +122,7 @@ func (a BaseJob) ToObjectType(ctx context.Context) types.ObjectType { "effective_budget_policy_id": types.StringType, "job_id": types.Int64Type, "settings": basetypes.ListType{ - ElemType: JobSettings{}.ToObjectType(ctx), + ElemType: JobSettings{}.Type(ctx), }, }, } @@ -237,42 +288,89 @@ func (a BaseRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of BaseRun in the Terraform plugin framework type -// system. -func (a BaseRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BaseRun{} + +// Equal implements basetypes.ObjectValuable. +func (o BaseRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BaseRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BaseRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BaseRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BaseRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BaseRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BaseRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.ToObjectType(ctx), + ElemType: ClusterInstance{}.Type(ctx), }, "cluster_spec": basetypes.ListType{ - ElemType: ClusterSpec{}.ToObjectType(ctx), + ElemType: ClusterSpec{}.Type(ctx), }, "creator_user_name": types.StringType, "description": types.StringType, "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToObjectType(ctx), + ElemType: GitSource{}.Type(ctx), }, "job_clusters": basetypes.ListType{ - ElemType: JobCluster{}.ToObjectType(ctx), + ElemType: JobCluster{}.Type(ctx), }, "job_id": types.Int64Type, "job_parameters": basetypes.ListType{ - ElemType: JobParameter{}.ToObjectType(ctx), + ElemType: JobParameter{}.Type(ctx), }, "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ - ElemType: RunParameters{}.ToObjectType(ctx), + ElemType: RunParameters{}.Type(ctx), }, "queue_duration": types.Int64Type, "repair_history": basetypes.ListType{ - ElemType: RepairHistoryItem{}.ToObjectType(ctx), + ElemType: RepairHistoryItem{}.Type(ctx), }, "run_duration": types.Int64Type, "run_id": types.Int64Type, @@ -280,22 +378,22 @@ func (a BaseRun) ToObjectType(ctx context.Context) types.ObjectType { "run_page_url": types.StringType, "run_type": types.StringType, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToObjectType(ctx), + ElemType: CronSchedule{}.Type(ctx), }, "setup_duration": types.Int64Type, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToObjectType(ctx), + ElemType: RunState{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToObjectType(ctx), + ElemType: RunStatus{}.Type(ctx), }, "tasks": basetypes.ListType{ - ElemType: RunTask{}.ToObjectType(ctx), + ElemType: RunTask{}.Type(ctx), }, "trigger": types.StringType, "trigger_info": basetypes.ListType{ - ElemType: TriggerInfo{}.ToObjectType(ctx), + ElemType: TriggerInfo{}.Type(ctx), }, }, } @@ -326,9 +424,56 @@ func (a CancelAllRuns) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelAllRuns in the Terraform plugin framework type -// system. -func (a CancelAllRuns) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelAllRuns{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelAllRuns) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelAllRuns) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelAllRuns) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelAllRuns) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelAllRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelAllRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelAllRuns) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_queued_runs": types.BoolType, @@ -357,9 +502,56 @@ func (a CancelAllRunsResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelAllRunsResponse in the Terraform plugin framework type -// system. -func (a CancelAllRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelAllRunsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelAllRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -387,9 +579,56 @@ func (a CancelRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelRun in the Terraform plugin framework type -// system. -func (a CancelRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelRun{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -417,9 +656,56 @@ func (a CancelRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelRunResponse in the Terraform plugin framework type -// system. -func (a CancelRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -463,9 +749,56 @@ func (a ClusterInstance) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterInstance in the Terraform plugin framework type -// system. -func (a ClusterInstance) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterInstance{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterInstance) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterInstance) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterInstance) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterInstance) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterInstance) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterInstance) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterInstance) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, @@ -511,18 +844,65 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of ClusterSpec in the Terraform plugin framework type -// system. -func (a ClusterSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "existing_cluster_id": types.StringType, "job_cluster_key": types.StringType, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToObjectType(ctx), + ElemType: compute_tf.Library{}.Type(ctx), }, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), + ElemType: compute_tf.ClusterSpec{}.Type(ctx), }, }, } @@ -565,9 +945,56 @@ func (a ConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ConditionTask in the Terraform plugin framework type -// system. -func (a ConditionTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ConditionTask{} + +// Equal implements basetypes.ObjectValuable. +func (o ConditionTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ConditionTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ConditionTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ConditionTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ConditionTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ConditionTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ConditionTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "left": types.StringType, @@ -600,9 +1027,56 @@ func (a Continuous) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of Continuous in the Terraform plugin framework type -// system. -func (a Continuous) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Continuous{} + +// Equal implements basetypes.ObjectValuable. +func (o Continuous) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Continuous) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Continuous) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Continuous) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Continuous) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Continuous) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Continuous) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pause_status": types.StringType, @@ -751,68 +1225,115 @@ func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of CreateJob in the Terraform plugin framework type -// system. -func (a CreateJob) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateJob{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateJob) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateJob) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateJob) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateJob) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.ToObjectType(ctx), + ElemType: JobAccessControlRequest{}.Type(ctx), }, "budget_policy_id": types.StringType, "continuous": basetypes.ListType{ - ElemType: Continuous{}.ToObjectType(ctx), + ElemType: Continuous{}.Type(ctx), }, "deployment": basetypes.ListType{ - ElemType: JobDeployment{}.ToObjectType(ctx), + ElemType: JobDeployment{}.Type(ctx), }, "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToObjectType(ctx), + ElemType: JobEmailNotifications{}.Type(ctx), }, "environment": basetypes.ListType{ - ElemType: JobEnvironment{}.ToObjectType(ctx), + ElemType: JobEnvironment{}.Type(ctx), }, "format": types.StringType, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToObjectType(ctx), + ElemType: GitSource{}.Type(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToObjectType(ctx), + ElemType: JobsHealthRules{}.Type(ctx), }, "job_cluster": basetypes.ListType{ - ElemType: JobCluster{}.ToObjectType(ctx), + ElemType: JobCluster{}.Type(ctx), }, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.ToObjectType(ctx), + ElemType: JobNotificationSettings{}.Type(ctx), }, "parameter": basetypes.ListType{ - ElemType: JobParameterDefinition{}.ToObjectType(ctx), + ElemType: JobParameterDefinition{}.Type(ctx), }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToObjectType(ctx), + ElemType: QueueSettings{}.Type(ctx), }, "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.ToObjectType(ctx), + ElemType: JobRunAs{}.Type(ctx), }, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToObjectType(ctx), + ElemType: CronSchedule{}.Type(ctx), }, "tags": basetypes.MapType{ ElemType: types.StringType, }, "task": basetypes.ListType{ - ElemType: Task{}.ToObjectType(ctx), + ElemType: Task{}.Type(ctx), }, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ - ElemType: TriggerSettings{}.ToObjectType(ctx), + ElemType: TriggerSettings{}.Type(ctx), }, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToObjectType(ctx), + ElemType: WebhookNotifications{}.Type(ctx), }, }, } @@ -841,9 +1362,56 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateResponse in the Terraform plugin framework type -// system. -func (a CreateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -883,9 +1451,56 @@ func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of CronSchedule in the Terraform plugin framework type -// system. -func (a CronSchedule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CronSchedule{} + +// Equal implements basetypes.ObjectValuable. +func (o CronSchedule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CronSchedule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CronSchedule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CronSchedule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CronSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CronSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CronSchedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pause_status": types.StringType, @@ -924,9 +1539,56 @@ func (a DbtOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of DbtOutput in the Terraform plugin framework type -// system. -func (a DbtOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DbtOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o DbtOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DbtOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DbtOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DbtOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DbtOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DbtOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DbtOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifacts_headers": basetypes.MapType{ @@ -993,9 +1655,56 @@ func (a DbtTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of DbtTask in the Terraform plugin framework type -// system. -func (a DbtTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DbtTask{} + +// Equal implements basetypes.ObjectValuable. +func (o DbtTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DbtTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DbtTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DbtTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DbtTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DbtTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DbtTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog": types.StringType, @@ -1033,9 +1742,56 @@ func (a DeleteJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteJob in the Terraform plugin framework type -// system. -func (a DeleteJob) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteJob{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteJob) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteJob) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteJob) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteJob) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1063,9 +1819,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1093,10 +1896,57 @@ func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRun in the Terraform plugin framework type -// system. -func (a DeleteRun) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRun{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRun) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, }, @@ -1123,9 +1973,56 @@ func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRunResponse in the Terraform plugin framework type -// system. -func (a DeleteRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1166,9 +2063,56 @@ func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComple return map[string]reflect.Type{} } -// ToObjectType returns the representation of EnforcePolicyComplianceForJobResponseJobClusterSettingsChange in the Terraform plugin framework type -// system. -func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{} + +// Equal implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "field": types.StringType, @@ -1203,9 +2147,56 @@ func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of EnforcePolicyComplianceRequest in the Terraform plugin framework type -// system. -func (a EnforcePolicyComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnforcePolicyComplianceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1251,17 +2242,64 @@ func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of EnforcePolicyComplianceResponse in the Terraform plugin framework type -// system. -func (a EnforcePolicyComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnforcePolicyComplianceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_changes": types.BoolType, "job_cluster_changes": basetypes.ListType{ - ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.ToObjectType(ctx), + ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx), }, "settings": basetypes.ListType{ - ElemType: JobSettings{}.ToObjectType(ctx), + ElemType: JobSettings{}.Type(ctx), }, }, } @@ -1296,13 +2334,60 @@ func (a ExportRunOutput) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of ExportRunOutput in the Terraform plugin framework type -// system. -func (a ExportRunOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExportRunOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o ExportRunOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExportRunOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExportRunOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExportRunOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExportRunOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExportRunOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExportRunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "views": basetypes.ListType{ - ElemType: ViewItem{}.ToObjectType(ctx), + ElemType: ViewItem{}.Type(ctx), }, }, } @@ -1333,9 +2418,56 @@ func (a ExportRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExportRunRequest in the Terraform plugin framework type -// system. -func (a ExportRunRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExportRunRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExportRunRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExportRunRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExportRunRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExportRunRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExportRunRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExportRunRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExportRunRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -1376,9 +2508,56 @@ func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of FileArrivalTriggerConfiguration in the Terraform plugin framework type -// system. -func (a FileArrivalTriggerConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FileArrivalTriggerConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FileArrivalTriggerConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "min_time_between_triggers_seconds": types.Int64Type, @@ -1415,16 +2594,63 @@ func (a ForEachStats) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ForEachStats in the Terraform plugin framework type -// system. -func (a ForEachStats) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ForEachStats{} + +// Equal implements basetypes.ObjectValuable. +func (o ForEachStats) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ForEachStats) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ForEachStats) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ForEachStats) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ForEachStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ForEachStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ForEachStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_message_stats": basetypes.ListType{ - ElemType: ForEachTaskErrorMessageStats{}.ToObjectType(ctx), + ElemType: ForEachTaskErrorMessageStats{}.Type(ctx), }, "task_run_stats": basetypes.ListType{ - ElemType: ForEachTaskTaskRunStats{}.ToObjectType(ctx), + ElemType: ForEachTaskTaskRunStats{}.Type(ctx), }, }, } @@ -1461,15 +2687,62 @@ func (a ForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of ForEachTask in the Terraform plugin framework type -// system. -func (a ForEachTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ForEachTask{} + +// Equal implements basetypes.ObjectValuable. +func (o ForEachTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ForEachTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ForEachTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ForEachTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ForEachTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ForEachTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ForEachTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, "task": basetypes.ListType{ - ElemType: Task{}.ToObjectType(ctx), + ElemType: Task{}.Type(ctx), }, }, } @@ -1502,9 +2775,56 @@ func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ForEachTaskErrorMessageStats in the Terraform plugin framework type -// system. -func (a ForEachTaskErrorMessageStats) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ForEachTaskErrorMessageStats{} + +// Equal implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ForEachTaskErrorMessageStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "count": types.Int64Type, @@ -1547,9 +2867,56 @@ func (a ForEachTaskTaskRunStats) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of ForEachTaskTaskRunStats in the Terraform plugin framework type -// system. -func (a ForEachTaskTaskRunStats) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ForEachTaskTaskRunStats{} + +// Equal implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ForEachTaskTaskRunStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active_iterations": types.Int64Type, @@ -1585,9 +2952,56 @@ func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetJobPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetJobPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetJobPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.StringType, @@ -1619,13 +3033,60 @@ func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of GetJobPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetJobPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetJobPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetJobPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: JobPermissionsDescription{}.ToObjectType(ctx), + ElemType: JobPermissionsDescription{}.Type(ctx), }, }, } @@ -1654,9 +3115,56 @@ func (a GetJobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetJobPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetJobPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetJobPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetJobPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.StringType, @@ -1688,9 +3196,56 @@ func (a GetJobRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetJobRequest in the Terraform plugin framework type -// system. -func (a GetJobRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetJobRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetJobRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetJobRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetJobRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetJobRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetJobRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetJobRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetJobRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1721,9 +3276,56 @@ func (a GetPolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPolicyComplianceRequest in the Terraform plugin framework type -// system. -func (a GetPolicyComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPolicyComplianceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPolicyComplianceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, @@ -1764,9 +3366,56 @@ func (a GetPolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of GetPolicyComplianceResponse in the Terraform plugin framework type -// system. -func (a GetPolicyComplianceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPolicyComplianceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, @@ -1800,9 +3449,56 @@ func (a GetRunOutputRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRunOutputRequest in the Terraform plugin framework type -// system. -func (a GetRunOutputRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRunOutputRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRunOutputRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -1841,9 +3537,56 @@ func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRunRequest in the Terraform plugin framework type -// system. -func (a GetRunRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRunRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRunRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRunRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRunRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRunRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRunRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRunRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRunRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_history": types.BoolType, @@ -1880,9 +3623,56 @@ func (a GitSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of GitSnapshot in the Terraform plugin framework type -// system. -func (a GitSnapshot) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GitSnapshot{} + +// Equal implements basetypes.ObjectValuable. +func (o GitSnapshot) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GitSnapshot) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GitSnapshot) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GitSnapshot) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GitSnapshot) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GitSnapshot) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GitSnapshot) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "used_commit": types.StringType, @@ -1943,21 +3733,68 @@ func (a GitSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of GitSource in the Terraform plugin framework type -// system. -func (a GitSource) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GitSource{} + +// Equal implements basetypes.ObjectValuable. +func (o GitSource) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GitSource) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GitSource) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GitSource) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GitSource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GitSource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GitSource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, "commit": types.StringType, "git_provider": types.StringType, "git_snapshot": basetypes.ListType{ - ElemType: GitSnapshot{}.ToObjectType(ctx), + ElemType: GitSnapshot{}.Type(ctx), }, "tag": types.StringType, "url": types.StringType, "job_source": basetypes.ListType{ - ElemType: JobSource{}.ToObjectType(ctx), + ElemType: JobSource{}.Type(ctx), }, }, } @@ -2012,9 +3849,56 @@ func (a Job) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToObjectType returns the representation of Job in the Terraform plugin framework type -// system. -func (a Job) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Job{} + +// Equal implements basetypes.ObjectValuable. +func (o Job) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Job) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Job) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Job) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Job) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Job) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Job) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_time": types.Int64Type, @@ -2023,7 +3907,7 @@ func (a Job) ToObjectType(ctx context.Context) types.ObjectType { "job_id": types.Int64Type, "run_as_user_name": types.StringType, "settings": basetypes.ListType{ - ElemType: JobSettings{}.ToObjectType(ctx), + ElemType: JobSettings{}.Type(ctx), }, }, } @@ -2057,9 +3941,56 @@ func (a JobAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobAccessControlRequest in the Terraform plugin framework type -// system. -func (a JobAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -2102,13 +4033,60 @@ func (a JobAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of JobAccessControlResponse in the Terraform plugin framework type -// system. -func (a JobAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: JobPermission{}.ToObjectType(ctx), + ElemType: JobPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -2146,14 +4124,61 @@ func (a JobCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of JobCluster in the Terraform plugin framework type -// system. -func (a JobCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o JobCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_cluster_key": types.StringType, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), + ElemType: compute_tf.ClusterSpec{}.Type(ctx), }, }, } @@ -2191,9 +4216,56 @@ func (a JobCompliance) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of JobCompliance in the Terraform plugin framework type -// system. -func (a JobCompliance) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobCompliance{} + +// Equal implements basetypes.ObjectValuable. +func (o JobCompliance) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobCompliance) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobCompliance) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobCompliance) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobCompliance) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobCompliance) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobCompliance) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, @@ -2231,9 +4303,56 @@ func (a JobDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobDeployment in the Terraform plugin framework type -// system. -func (a JobDeployment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobDeployment{} + +// Equal implements basetypes.ObjectValuable. +func (o JobDeployment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobDeployment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobDeployment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobDeployment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobDeployment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobDeployment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobDeployment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kind": types.StringType, @@ -2301,9 +4420,56 @@ func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of JobEmailNotifications in the Terraform plugin framework type -// system. -func (a JobEmailNotifications) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobEmailNotifications{} + +// Equal implements basetypes.ObjectValuable. +func (o JobEmailNotifications) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobEmailNotifications) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobEmailNotifications) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobEmailNotifications) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobEmailNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobEmailNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobEmailNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "no_alert_for_skipped_runs": types.BoolType, @@ -2354,14 +4520,61 @@ func (a JobEnvironment) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of JobEnvironment in the Terraform plugin framework type -// system. -func (a JobEnvironment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobEnvironment{} + +// Equal implements basetypes.ObjectValuable. +func (o JobEnvironment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobEnvironment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobEnvironment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobEnvironment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobEnvironment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobEnvironment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobEnvironment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "environment_key": types.StringType, "spec": basetypes.ListType{ - ElemType: compute_tf.Environment{}.ToObjectType(ctx), + ElemType: compute_tf.Environment{}.Type(ctx), }, }, } @@ -2393,9 +4606,56 @@ func (a JobNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobNotificationSettings in the Terraform plugin framework type -// system. -func (a JobNotificationSettings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobNotificationSettings{} + +// Equal implements basetypes.ObjectValuable. +func (o JobNotificationSettings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobNotificationSettings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobNotificationSettings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobNotificationSettings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobNotificationSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobNotificationSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobNotificationSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "no_alert_for_canceled_runs": types.BoolType, @@ -2430,9 +4690,56 @@ func (a JobParameter) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobParameter in the Terraform plugin framework type -// system. -func (a JobParameter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobParameter{} + +// Equal implements basetypes.ObjectValuable. +func (o JobParameter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobParameter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobParameter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobParameter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobParameter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobParameter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobParameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default": types.StringType, @@ -2467,9 +4774,56 @@ func (a JobParameterDefinition) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobParameterDefinition in the Terraform plugin framework type -// system. -func (a JobParameterDefinition) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobParameterDefinition{} + +// Equal implements basetypes.ObjectValuable. +func (o JobParameterDefinition) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobParameterDefinition) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobParameterDefinition) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobParameterDefinition) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobParameterDefinition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobParameterDefinition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobParameterDefinition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default": types.StringType, @@ -2505,9 +4859,56 @@ func (a JobPermission) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of JobPermission in the Terraform plugin framework type -// system. -func (a JobPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o JobPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2546,13 +4947,60 @@ func (a JobPermissions) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of JobPermissions in the Terraform plugin framework type -// system. -func (a JobPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o JobPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlResponse{}.ToObjectType(ctx), + ElemType: JobAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2583,9 +5031,56 @@ func (a JobPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobPermissionsDescription in the Terraform plugin framework type -// system. -func (a JobPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2619,13 +5114,60 @@ func (a JobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of JobPermissionsRequest in the Terraform plugin framework type -// system. -func (a JobPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.ToObjectType(ctx), + ElemType: JobAccessControlRequest{}.Type(ctx), }, "job_id": types.StringType, }, @@ -2664,9 +5206,56 @@ func (a JobRunAs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobRunAs in the Terraform plugin framework type -// system. -func (a JobRunAs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobRunAs{} + +// Equal implements basetypes.ObjectValuable. +func (o JobRunAs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobRunAs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobRunAs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobRunAs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobRunAs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobRunAs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobRunAs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "service_principal_name": types.StringType, @@ -2813,65 +5402,112 @@ func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of JobSettings in the Terraform plugin framework type -// system. -func (a JobSettings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobSettings{} + +// Equal implements basetypes.ObjectValuable. +func (o JobSettings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobSettings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobSettings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobSettings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_policy_id": types.StringType, "continuous": basetypes.ListType{ - ElemType: Continuous{}.ToObjectType(ctx), + ElemType: Continuous{}.Type(ctx), }, "deployment": basetypes.ListType{ - ElemType: JobDeployment{}.ToObjectType(ctx), + ElemType: JobDeployment{}.Type(ctx), }, "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToObjectType(ctx), + ElemType: JobEmailNotifications{}.Type(ctx), }, "environment": basetypes.ListType{ - ElemType: JobEnvironment{}.ToObjectType(ctx), + ElemType: JobEnvironment{}.Type(ctx), }, "format": types.StringType, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToObjectType(ctx), + ElemType: GitSource{}.Type(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToObjectType(ctx), + ElemType: JobsHealthRules{}.Type(ctx), }, "job_cluster": basetypes.ListType{ - ElemType: JobCluster{}.ToObjectType(ctx), + ElemType: JobCluster{}.Type(ctx), }, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.ToObjectType(ctx), + ElemType: JobNotificationSettings{}.Type(ctx), }, "parameter": basetypes.ListType{ - ElemType: JobParameterDefinition{}.ToObjectType(ctx), + ElemType: JobParameterDefinition{}.Type(ctx), }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToObjectType(ctx), + ElemType: QueueSettings{}.Type(ctx), }, "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.ToObjectType(ctx), + ElemType: JobRunAs{}.Type(ctx), }, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToObjectType(ctx), + ElemType: CronSchedule{}.Type(ctx), }, "tags": basetypes.MapType{ ElemType: types.StringType, }, "task": basetypes.ListType{ - ElemType: Task{}.ToObjectType(ctx), + ElemType: Task{}.Type(ctx), }, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ - ElemType: TriggerSettings{}.ToObjectType(ctx), + ElemType: TriggerSettings{}.Type(ctx), }, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToObjectType(ctx), + ElemType: WebhookNotifications{}.Type(ctx), }, }, } @@ -2913,9 +5549,56 @@ func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobSource in the Terraform plugin framework type -// system. -func (a JobSource) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobSource{} + +// Equal implements basetypes.ObjectValuable. +func (o JobSource) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobSource) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobSource) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobSource) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobSource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobSource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobSource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dirty_state": types.StringType, @@ -2964,9 +5647,56 @@ func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobsHealthRule in the Terraform plugin framework type -// system. -func (a JobsHealthRule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobsHealthRule{} + +// Equal implements basetypes.ObjectValuable. +func (o JobsHealthRule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobsHealthRule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobsHealthRule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobsHealthRule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobsHealthRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobsHealthRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobsHealthRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metric": types.StringType, @@ -3000,13 +5730,60 @@ func (a JobsHealthRules) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of JobsHealthRules in the Terraform plugin framework type -// system. -func (a JobsHealthRules) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobsHealthRules{} + +// Equal implements basetypes.ObjectValuable. +func (o JobsHealthRules) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobsHealthRules) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobsHealthRules) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobsHealthRules) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobsHealthRules) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobsHealthRules) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobsHealthRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "rules": basetypes.ListType{ - ElemType: JobsHealthRule{}.ToObjectType(ctx), + ElemType: JobsHealthRule{}.Type(ctx), }, }, } @@ -3044,13 +5821,60 @@ func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of ListJobComplianceForPolicyResponse in the Terraform plugin framework type -// system. -func (a ListJobComplianceForPolicyResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListJobComplianceForPolicyResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListJobComplianceForPolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "jobs": basetypes.ListType{ - ElemType: JobCompliance{}.ToObjectType(ctx), + ElemType: JobCompliance{}.Type(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -3088,9 +5912,56 @@ func (a ListJobComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListJobComplianceRequest in the Terraform plugin framework type -// system. -func (a ListJobComplianceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListJobComplianceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListJobComplianceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -3135,9 +6006,56 @@ func (a ListJobsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListJobsRequest in the Terraform plugin framework type -// system. -func (a ListJobsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListJobsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListJobsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListJobsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListJobsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListJobsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListJobsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListJobsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListJobsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "expand_tasks": types.BoolType, @@ -3183,14 +6101,61 @@ func (a ListJobsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ListJobsResponse in the Terraform plugin framework type -// system. -func (a ListJobsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListJobsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListJobsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListJobsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListJobsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListJobsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListJobsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListJobsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListJobsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_more": types.BoolType, "jobs": basetypes.ListType{ - ElemType: BaseJob{}.ToObjectType(ctx), + ElemType: BaseJob{}.Type(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -3255,9 +6220,56 @@ func (a ListRunsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListRunsRequest in the Terraform plugin framework type -// system. -func (a ListRunsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRunsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRunsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRunsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRunsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRunsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRunsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRunsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRunsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "active_only": types.BoolType, @@ -3308,16 +6320,63 @@ func (a ListRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ListRunsResponse in the Terraform plugin framework type -// system. -func (a ListRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRunsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRunsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRunsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRunsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRunsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_more": types.BoolType, "next_page_token": types.StringType, "prev_page_token": types.StringType, "runs": basetypes.ListType{ - ElemType: BaseRun{}.ToObjectType(ctx), + ElemType: BaseRun{}.Type(ctx), }, }, } @@ -3352,9 +6411,56 @@ func (a NotebookOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of NotebookOutput in the Terraform plugin framework type -// system. -func (a NotebookOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NotebookOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o NotebookOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NotebookOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NotebookOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NotebookOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NotebookOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NotebookOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NotebookOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "result": types.StringType, @@ -3423,9 +6529,56 @@ func (a NotebookTask) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of NotebookTask in the Terraform plugin framework type -// system. -func (a NotebookTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NotebookTask{} + +// Equal implements basetypes.ObjectValuable. +func (o NotebookTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NotebookTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NotebookTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NotebookTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NotebookTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NotebookTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NotebookTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "base_parameters": basetypes.MapType{ @@ -3462,9 +6615,56 @@ func (a PeriodicTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of PeriodicTriggerConfiguration in the Terraform plugin framework type -// system. -func (a PeriodicTriggerConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PeriodicTriggerConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PeriodicTriggerConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "interval": types.Int64Type, @@ -3495,9 +6695,56 @@ func (a PipelineParams) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelineParams in the Terraform plugin framework type -// system. -func (a PipelineParams) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineParams{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineParams) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineParams) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineParams) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineParams) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineParams) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineParams) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineParams) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_refresh": types.BoolType, @@ -3529,9 +6776,56 @@ func (a PipelineTask) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelineTask in the Terraform plugin framework type -// system. -func (a PipelineTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineTask{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "full_refresh": types.BoolType, @@ -3576,9 +6870,56 @@ func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of PythonWheelTask in the Terraform plugin framework type -// system. -func (a PythonWheelTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PythonWheelTask{} + +// Equal implements basetypes.ObjectValuable. +func (o PythonWheelTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PythonWheelTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PythonWheelTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PythonWheelTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PythonWheelTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PythonWheelTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PythonWheelTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "entry_point": types.StringType, @@ -3623,9 +6964,56 @@ func (a QueueDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of QueueDetails in the Terraform plugin framework type -// system. -func (a QueueDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueueDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o QueueDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueueDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueueDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueueDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueueDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueueDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueueDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -3656,9 +7044,56 @@ func (a QueueSettings) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of QueueSettings in the Terraform plugin framework type -// system. -func (a QueueSettings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueueSettings{} + +// Equal implements basetypes.ObjectValuable. +func (o QueueSettings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueueSettings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueueSettings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueueSettings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueueSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueueSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueueSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -3683,7 +7118,7 @@ type RepairHistoryItem struct { TaskRunIds types.List `tfsdk:"task_run_ids" tf:"optional"` // The repair history item type. Indicates whether a run is the original run // or a repair run. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *RepairHistoryItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepairHistoryItem) { @@ -3707,19 +7142,66 @@ func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of RepairHistoryItem in the Terraform plugin framework type -// system. -func (a RepairHistoryItem) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepairHistoryItem{} + +// Equal implements basetypes.ObjectValuable. +func (o RepairHistoryItem) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepairHistoryItem) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepairHistoryItem) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepairHistoryItem) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepairHistoryItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepairHistoryItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepairHistoryItem) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time": types.Int64Type, "id": types.Int64Type, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToObjectType(ctx), + ElemType: RunState{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToObjectType(ctx), + ElemType: RunStatus{}.Type(ctx), }, "task_run_ids": basetypes.ListType{ ElemType: types.Int64Type, @@ -3860,9 +7342,56 @@ func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of RepairRun in the Terraform plugin framework type -// system. -func (a RepairRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepairRun{} + +// Equal implements basetypes.ObjectValuable. +func (o RepairRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepairRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepairRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepairRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepairRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepairRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepairRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -3879,7 +7408,7 @@ func (a RepairRun) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToObjectType(ctx), + ElemType: PipelineParams{}.Type(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -3927,9 +7456,56 @@ func (a RepairRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of RepairRunResponse in the Terraform plugin framework type -// system. -func (a RepairRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepairRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RepairRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepairRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepairRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepairRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepairRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepairRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepairRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repair_id": types.Int64Type, @@ -3967,14 +7543,61 @@ func (a ResetJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of ResetJob in the Terraform plugin framework type -// system. -func (a ResetJob) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResetJob{} + +// Equal implements basetypes.ObjectValuable. +func (o ResetJob) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResetJob) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResetJob) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResetJob) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResetJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResetJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResetJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.Int64Type, "new_settings": basetypes.ListType{ - ElemType: JobSettings{}.ToObjectType(ctx), + ElemType: JobSettings{}.Type(ctx), }, }, } @@ -4000,9 +7623,56 @@ func (a ResetResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ResetResponse in the Terraform plugin framework type -// system. -func (a ResetResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResetResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ResetResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResetResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResetResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResetResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4031,9 +7701,56 @@ func (a ResolvedConditionTaskValues) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of ResolvedConditionTaskValues in the Terraform plugin framework type -// system. -func (a ResolvedConditionTaskValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedConditionTaskValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedConditionTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "left": types.StringType, @@ -4065,9 +7782,56 @@ func (a ResolvedDbtTaskValues) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ResolvedDbtTaskValues in the Terraform plugin framework type -// system. -func (a ResolvedDbtTaskValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedDbtTaskValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedDbtTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "commands": basetypes.ListType{ @@ -4084,25 +7848,72 @@ type ResolvedNotebookTaskValues struct { func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringCreateOrUpdate(plan ResolvedNotebookTaskValues) { } -func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedNotebookTaskValues) { +func (newState *ResolvedNotebookTaskValues) SyncEffectiveFieldsDuringRead(existingState ResolvedNotebookTaskValues) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedNotebookTaskValues. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "base_parameters": reflect.TypeOf(types.String{}), + } +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedNotebookTaskValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in ResolvedNotebookTaskValues. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "base_parameters": reflect.TypeOf(types.String{}), +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of ResolvedNotebookTaskValues in the Terraform plugin framework type -// system. -func (a ResolvedNotebookTaskValues) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o ResolvedNotebookTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "base_parameters": basetypes.MapType{ @@ -4135,9 +7946,56 @@ func (a ResolvedParamPairValues) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ResolvedParamPairValues in the Terraform plugin framework type -// system. -func (a ResolvedParamPairValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedParamPairValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedParamPairValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.MapType{ @@ -4173,9 +8031,56 @@ func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ResolvedPythonWheelTaskValues in the Terraform plugin framework type -// system. -func (a ResolvedPythonWheelTaskValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedPythonWheelTaskValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedPythonWheelTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "named_parameters": basetypes.MapType{ @@ -4214,9 +8119,56 @@ func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of ResolvedRunJobTaskValues in the Terraform plugin framework type -// system. -func (a ResolvedRunJobTaskValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedRunJobTaskValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedRunJobTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_parameters": basetypes.MapType{ @@ -4252,9 +8204,56 @@ func (a ResolvedStringParamsValues) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ResolvedStringParamsValues in the Terraform plugin framework type -// system. -func (a ResolvedStringParamsValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedStringParamsValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedStringParamsValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ @@ -4314,40 +8313,87 @@ func (a ResolvedValues) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ResolvedValues in the Terraform plugin framework type -// system. -func (a ResolvedValues) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResolvedValues{} + +// Equal implements basetypes.ObjectValuable. +func (o ResolvedValues) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResolvedValues) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResolvedValues) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResolvedValues) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResolvedValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResolvedValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResolvedValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ - ElemType: ResolvedConditionTaskValues{}.ToObjectType(ctx), + ElemType: ResolvedConditionTaskValues{}.Type(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: ResolvedDbtTaskValues{}.ToObjectType(ctx), + ElemType: ResolvedDbtTaskValues{}.Type(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: ResolvedNotebookTaskValues{}.ToObjectType(ctx), + ElemType: ResolvedNotebookTaskValues{}.Type(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: ResolvedPythonWheelTaskValues{}.ToObjectType(ctx), + ElemType: ResolvedPythonWheelTaskValues{}.Type(ctx), }, "run_job_task": basetypes.ListType{ - ElemType: ResolvedRunJobTaskValues{}.ToObjectType(ctx), + ElemType: ResolvedRunJobTaskValues{}.Type(ctx), }, "simulation_task": basetypes.ListType{ - ElemType: ResolvedParamPairValues{}.ToObjectType(ctx), + ElemType: ResolvedParamPairValues{}.Type(ctx), }, "spark_jar_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.ToObjectType(ctx), + ElemType: ResolvedStringParamsValues{}.Type(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.ToObjectType(ctx), + ElemType: ResolvedStringParamsValues{}.Type(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.ToObjectType(ctx), + ElemType: ResolvedStringParamsValues{}.Type(ctx), }, "sql_task": basetypes.ListType{ - ElemType: ResolvedParamPairValues{}.ToObjectType(ctx), + ElemType: ResolvedParamPairValues{}.Type(ctx), }, }, } @@ -4520,46 +8566,93 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToObjectType returns the representation of Run in the Terraform plugin framework type -// system. -func (a Run) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Run{} + +// Equal implements basetypes.ObjectValuable. +func (o Run) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Run) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Run) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Run) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Run) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Run) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.ToObjectType(ctx), + ElemType: ClusterInstance{}.Type(ctx), }, "cluster_spec": basetypes.ListType{ - ElemType: ClusterSpec{}.ToObjectType(ctx), + ElemType: ClusterSpec{}.Type(ctx), }, "creator_user_name": types.StringType, "description": types.StringType, "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToObjectType(ctx), + ElemType: GitSource{}.Type(ctx), }, "iterations": basetypes.ListType{ - ElemType: RunTask{}.ToObjectType(ctx), + ElemType: RunTask{}.Type(ctx), }, "job_clusters": basetypes.ListType{ - ElemType: JobCluster{}.ToObjectType(ctx), + ElemType: JobCluster{}.Type(ctx), }, "job_id": types.Int64Type, "job_parameters": basetypes.ListType{ - ElemType: JobParameter{}.ToObjectType(ctx), + ElemType: JobParameter{}.Type(ctx), }, "job_run_id": types.Int64Type, "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ - ElemType: RunParameters{}.ToObjectType(ctx), + ElemType: RunParameters{}.Type(ctx), }, "queue_duration": types.Int64Type, "repair_history": basetypes.ListType{ - ElemType: RepairHistoryItem{}.ToObjectType(ctx), + ElemType: RepairHistoryItem{}.Type(ctx), }, "run_duration": types.Int64Type, "run_id": types.Int64Type, @@ -4567,22 +8660,22 @@ func (a Run) ToObjectType(ctx context.Context) types.ObjectType { "run_page_url": types.StringType, "run_type": types.StringType, "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.ToObjectType(ctx), + ElemType: CronSchedule{}.Type(ctx), }, "setup_duration": types.Int64Type, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToObjectType(ctx), + ElemType: RunState{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToObjectType(ctx), + ElemType: RunStatus{}.Type(ctx), }, "tasks": basetypes.ListType{ - ElemType: RunTask{}.ToObjectType(ctx), + ElemType: RunTask{}.Type(ctx), }, "trigger": types.StringType, "trigger_info": basetypes.ListType{ - ElemType: TriggerInfo{}.ToObjectType(ctx), + ElemType: TriggerInfo{}.Type(ctx), }, }, } @@ -4628,9 +8721,56 @@ func (a RunConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunConditionTask in the Terraform plugin framework type -// system. -func (a RunConditionTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunConditionTask{} + +// Equal implements basetypes.ObjectValuable. +func (o RunConditionTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunConditionTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunConditionTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunConditionTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunConditionTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunConditionTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunConditionTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "left": types.StringType, @@ -4676,18 +8816,65 @@ func (a RunForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of RunForEachTask in the Terraform plugin framework type -// system. -func (a RunForEachTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunForEachTask{} + +// Equal implements basetypes.ObjectValuable. +func (o RunForEachTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunForEachTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunForEachTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunForEachTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunForEachTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunForEachTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunForEachTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, "stats": basetypes.ListType{ - ElemType: ForEachStats{}.ToObjectType(ctx), + ElemType: ForEachStats{}.Type(ctx), }, "task": basetypes.ListType{ - ElemType: Task{}.ToObjectType(ctx), + ElemType: Task{}.Type(ctx), }, }, } @@ -4715,9 +8902,56 @@ func (a RunJobOutput) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunJobOutput in the Terraform plugin framework type -// system. -func (a RunJobOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunJobOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o RunJobOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunJobOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunJobOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunJobOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunJobOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunJobOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunJobOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -4841,9 +9075,56 @@ func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of RunJobTask in the Terraform plugin framework type -// system. -func (a RunJobTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunJobTask{} + +// Equal implements basetypes.ObjectValuable. +func (o RunJobTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunJobTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunJobTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunJobTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunJobTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunJobTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunJobTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -4860,7 +9141,7 @@ func (a RunJobTask) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToObjectType(ctx), + ElemType: PipelineParams{}.Type(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -5017,9 +9298,56 @@ func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToObjectType returns the representation of RunNow in the Terraform plugin framework type -// system. -func (a RunNow) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunNow{} + +// Equal implements basetypes.ObjectValuable. +func (o RunNow) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunNow) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunNow) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunNow) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunNow) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunNow) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunNow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -5040,7 +9368,7 @@ func (a RunNow) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToObjectType(ctx), + ElemType: PipelineParams{}.Type(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -5049,7 +9377,7 @@ func (a RunNow) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToObjectType(ctx), + ElemType: QueueSettings{}.Type(ctx), }, "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, @@ -5087,9 +9415,56 @@ func (a RunNowResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunNowResponse in the Terraform plugin framework type -// system. -func (a RunNowResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunNowResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RunNowResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunNowResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunNowResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunNowResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunNowResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunNowResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunNowResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "number_in_job": types.Int64Type, @@ -5161,13 +9536,60 @@ func (a RunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of RunOutput in the Terraform plugin framework type -// system. -func (a RunOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o RunOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_output": basetypes.ListType{ - ElemType: DbtOutput{}.ToObjectType(ctx), + ElemType: DbtOutput{}.Type(ctx), }, "error": types.StringType, "error_trace": types.StringType, @@ -5175,16 +9597,16 @@ func (a RunOutput) ToObjectType(ctx context.Context) types.ObjectType { "logs": types.StringType, "logs_truncated": types.BoolType, "metadata": basetypes.ListType{ - ElemType: Run{}.ToObjectType(ctx), + ElemType: Run{}.Type(ctx), }, "notebook_output": basetypes.ListType{ - ElemType: NotebookOutput{}.ToObjectType(ctx), + ElemType: NotebookOutput{}.Type(ctx), }, "run_job_output": basetypes.ListType{ - ElemType: RunJobOutput{}.ToObjectType(ctx), + ElemType: RunJobOutput{}.Type(ctx), }, "sql_output": basetypes.ListType{ - ElemType: SqlOutput{}.ToObjectType(ctx), + ElemType: SqlOutput{}.Type(ctx), }, }, } @@ -5301,9 +9723,56 @@ func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of RunParameters in the Terraform plugin framework type -// system. -func (a RunParameters) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunParameters{} + +// Equal implements basetypes.ObjectValuable. +func (o RunParameters) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunParameters) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunParameters) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunParameters) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunParameters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunParameters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbt_commands": basetypes.ListType{ @@ -5316,7 +9785,7 @@ func (a RunParameters) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.ToObjectType(ctx), + ElemType: PipelineParams{}.Type(ctx), }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, @@ -5369,9 +9838,56 @@ func (a RunState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunState in the Terraform plugin framework type -// system. -func (a RunState) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunState{} + +// Equal implements basetypes.ObjectValuable. +func (o RunState) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunState) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunState) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunState) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunState) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "life_cycle_state": types.StringType, @@ -5414,17 +9930,64 @@ func (a RunStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of RunStatus in the Terraform plugin framework type -// system. -func (a RunStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o RunStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "queue_details": basetypes.ListType{ - ElemType: QueueDetails{}.ToObjectType(ctx), + ElemType: QueueDetails{}.Type(ctx), }, "state": types.StringType, "termination_details": basetypes.ListType{ - ElemType: TerminationDetails{}.ToObjectType(ctx), + ElemType: TerminationDetails{}.Type(ctx), }, }, } @@ -5638,93 +10201,140 @@ func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of RunTask in the Terraform plugin framework type -// system. -func (a RunTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunTask{} + +// Equal implements basetypes.ObjectValuable. +func (o RunTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.ToObjectType(ctx), + ElemType: ClusterInstance{}.Type(ctx), }, "condition_task": basetypes.ListType{ - ElemType: RunConditionTask{}.ToObjectType(ctx), + ElemType: RunConditionTask{}.Type(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.ToObjectType(ctx), + ElemType: DbtTask{}.Type(ctx), }, "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.ToObjectType(ctx), + ElemType: TaskDependency{}.Type(ctx), }, "description": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToObjectType(ctx), + ElemType: JobEmailNotifications{}.Type(ctx), }, "end_time": types.Int64Type, "environment_key": types.StringType, "execution_duration": types.Int64Type, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ - ElemType: RunForEachTask{}.ToObjectType(ctx), + ElemType: RunForEachTask{}.Type(ctx), }, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToObjectType(ctx), + ElemType: GitSource{}.Type(ctx), }, "job_cluster_key": types.StringType, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToObjectType(ctx), + ElemType: compute_tf.Library{}.Type(ctx), }, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), + ElemType: compute_tf.ClusterSpec{}.Type(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.ToObjectType(ctx), + ElemType: NotebookTask{}.Type(ctx), }, "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.ToObjectType(ctx), + ElemType: TaskNotificationSettings{}.Type(ctx), }, "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.ToObjectType(ctx), + ElemType: PipelineTask{}.Type(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.ToObjectType(ctx), + ElemType: PythonWheelTask{}.Type(ctx), }, "queue_duration": types.Int64Type, "resolved_values": basetypes.ListType{ - ElemType: ResolvedValues{}.ToObjectType(ctx), + ElemType: ResolvedValues{}.Type(ctx), }, "run_duration": types.Int64Type, "run_id": types.Int64Type, "run_if": types.StringType, "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.ToObjectType(ctx), + ElemType: RunJobTask{}.Type(ctx), }, "run_page_url": types.StringType, "setup_duration": types.Int64Type, "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.ToObjectType(ctx), + ElemType: SparkJarTask{}.Type(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.ToObjectType(ctx), + ElemType: SparkPythonTask{}.Type(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.ToObjectType(ctx), + ElemType: SparkSubmitTask{}.Type(ctx), }, "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.ToObjectType(ctx), + ElemType: SqlTask{}.Type(ctx), }, "start_time": types.Int64Type, "state": basetypes.ListType{ - ElemType: RunState{}.ToObjectType(ctx), + ElemType: RunState{}.Type(ctx), }, "status": basetypes.ListType{ - ElemType: RunStatus{}.ToObjectType(ctx), + ElemType: RunStatus{}.Type(ctx), }, "task_key": types.StringType, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToObjectType(ctx), + ElemType: WebhookNotifications{}.Type(ctx), }, }, } @@ -5768,9 +10378,56 @@ func (a SparkJarTask) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of SparkJarTask in the Terraform plugin framework type -// system. -func (a SparkJarTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparkJarTask{} + +// Equal implements basetypes.ObjectValuable. +func (o SparkJarTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparkJarTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparkJarTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparkJarTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparkJarTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparkJarTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparkJarTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "jar_uri": types.StringType, @@ -5827,9 +10484,56 @@ func (a SparkPythonTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of SparkPythonTask in the Terraform plugin framework type -// system. -func (a SparkPythonTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparkPythonTask{} + +// Equal implements basetypes.ObjectValuable. +func (o SparkPythonTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparkPythonTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparkPythonTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparkPythonTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparkPythonTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparkPythonTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparkPythonTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ @@ -5870,9 +10574,56 @@ func (a SparkSubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of SparkSubmitTask in the Terraform plugin framework type -// system. -func (a SparkSubmitTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparkSubmitTask{} + +// Equal implements basetypes.ObjectValuable. +func (o SparkSubmitTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparkSubmitTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparkSubmitTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparkSubmitTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparkSubmitTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparkSubmitTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparkSubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "parameters": basetypes.ListType{ @@ -5919,16 +10670,63 @@ func (a SqlAlertOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of SqlAlertOutput in the Terraform plugin framework type -// system. -func (a SqlAlertOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlAlertOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlAlertOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlAlertOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlAlertOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlAlertOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlAlertOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlAlertOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlAlertOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_state": types.StringType, "output_link": types.StringType, "query_text": types.StringType, "sql_statements": basetypes.ListType{ - ElemType: SqlStatementOutput{}.ToObjectType(ctx), + ElemType: SqlStatementOutput{}.Type(ctx), }, "warehouse_id": types.StringType, }, @@ -5961,14 +10759,61 @@ func (a SqlDashboardOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of SqlDashboardOutput in the Terraform plugin framework type -// system. -func (a SqlDashboardOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlDashboardOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlDashboardOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, "widgets": basetypes.ListType{ - ElemType: SqlDashboardWidgetOutput{}.ToObjectType(ctx), + ElemType: SqlDashboardWidgetOutput{}.Type(ctx), }, }, } @@ -6010,14 +10855,61 @@ func (a SqlDashboardWidgetOutput) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of SqlDashboardWidgetOutput in the Terraform plugin framework type -// system. -func (a SqlDashboardWidgetOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlDashboardWidgetOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlDashboardWidgetOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time": types.Int64Type, "error": basetypes.ListType{ - ElemType: SqlOutputError{}.ToObjectType(ctx), + ElemType: SqlOutputError{}.Type(ctx), }, "output_link": types.StringType, "start_time": types.Int64Type, @@ -6058,19 +10950,66 @@ func (a SqlOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of SqlOutput in the Terraform plugin framework type -// system. -func (a SqlOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_output": basetypes.ListType{ - ElemType: SqlAlertOutput{}.ToObjectType(ctx), + ElemType: SqlAlertOutput{}.Type(ctx), }, "dashboard_output": basetypes.ListType{ - ElemType: SqlDashboardOutput{}.ToObjectType(ctx), + ElemType: SqlDashboardOutput{}.Type(ctx), }, "query_output": basetypes.ListType{ - ElemType: SqlQueryOutput{}.ToObjectType(ctx), + ElemType: SqlQueryOutput{}.Type(ctx), }, }, } @@ -6098,9 +11037,56 @@ func (a SqlOutputError) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of SqlOutputError in the Terraform plugin framework type -// system. -func (a SqlOutputError) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlOutputError{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlOutputError) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlOutputError) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlOutputError) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlOutputError) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlOutputError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlOutputError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlOutputError) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -6140,16 +11126,63 @@ func (a SqlQueryOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of SqlQueryOutput in the Terraform plugin framework type -// system. -func (a SqlQueryOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlQueryOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlQueryOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlQueryOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlQueryOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlQueryOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlQueryOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlQueryOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlQueryOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_id": types.StringType, "output_link": types.StringType, "query_text": types.StringType, "sql_statements": basetypes.ListType{ - ElemType: SqlStatementOutput{}.ToObjectType(ctx), + ElemType: SqlStatementOutput{}.Type(ctx), }, "warehouse_id": types.StringType, }, @@ -6178,9 +11211,56 @@ func (a SqlStatementOutput) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of SqlStatementOutput in the Terraform plugin framework type -// system. -func (a SqlStatementOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlStatementOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlStatementOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlStatementOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlStatementOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlStatementOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlStatementOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlStatementOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlStatementOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "lookup_key": types.StringType, @@ -6231,25 +11311,72 @@ func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of SqlTask in the Terraform plugin framework type -// system. -func (a SqlTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlTask{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert": basetypes.ListType{ - ElemType: SqlTaskAlert{}.ToObjectType(ctx), + ElemType: SqlTaskAlert{}.Type(ctx), }, "dashboard": basetypes.ListType{ - ElemType: SqlTaskDashboard{}.ToObjectType(ctx), + ElemType: SqlTaskDashboard{}.Type(ctx), }, "file": basetypes.ListType{ - ElemType: SqlTaskFile{}.ToObjectType(ctx), + ElemType: SqlTaskFile{}.Type(ctx), }, "parameters": basetypes.MapType{ ElemType: types.StringType, }, "query": basetypes.ListType{ - ElemType: SqlTaskQuery{}.ToObjectType(ctx), + ElemType: SqlTaskQuery{}.Type(ctx), }, "warehouse_id": types.StringType, }, @@ -6284,15 +11411,62 @@ func (a SqlTaskAlert) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of SqlTaskAlert in the Terraform plugin framework type -// system. -func (a SqlTaskAlert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlTaskAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlTaskAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlTaskAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlTaskAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlTaskAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlTaskAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlTaskAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlTaskAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "pause_subscriptions": types.BoolType, "subscriptions": basetypes.ListType{ - ElemType: SqlTaskSubscription{}.ToObjectType(ctx), + ElemType: SqlTaskSubscription{}.Type(ctx), }, }, } @@ -6329,16 +11503,63 @@ func (a SqlTaskDashboard) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of SqlTaskDashboard in the Terraform plugin framework type -// system. -func (a SqlTaskDashboard) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlTaskDashboard{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlTaskDashboard) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "custom_subject": types.StringType, "dashboard_id": types.StringType, "pause_subscriptions": types.BoolType, "subscriptions": basetypes.ListType{ - ElemType: SqlTaskSubscription{}.ToObjectType(ctx), + ElemType: SqlTaskSubscription{}.Type(ctx), }, }, } @@ -6376,9 +11597,56 @@ func (a SqlTaskFile) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of SqlTaskFile in the Terraform plugin framework type -// system. -func (a SqlTaskFile) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlTaskFile{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlTaskFile) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlTaskFile) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlTaskFile) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlTaskFile) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlTaskFile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlTaskFile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlTaskFile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -6409,9 +11677,56 @@ func (a SqlTaskQuery) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of SqlTaskQuery in the Terraform plugin framework type -// system. -func (a SqlTaskQuery) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlTaskQuery{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlTaskQuery) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlTaskQuery) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlTaskQuery) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlTaskQuery) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlTaskQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlTaskQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlTaskQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -6448,9 +11763,56 @@ func (a SqlTaskSubscription) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of SqlTaskSubscription in the Terraform plugin framework type -// system. -func (a SqlTaskSubscription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SqlTaskSubscription{} + +// Equal implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SqlTaskSubscription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_id": types.StringType, @@ -6549,44 +11911,91 @@ func (a SubmitRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of SubmitRun in the Terraform plugin framework type -// system. -func (a SubmitRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SubmitRun{} + +// Equal implements basetypes.ObjectValuable. +func (o SubmitRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SubmitRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SubmitRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SubmitRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SubmitRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SubmitRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SubmitRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.ToObjectType(ctx), + ElemType: JobAccessControlRequest{}.Type(ctx), }, "budget_policy_id": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToObjectType(ctx), + ElemType: JobEmailNotifications{}.Type(ctx), }, "environments": basetypes.ListType{ - ElemType: JobEnvironment{}.ToObjectType(ctx), + ElemType: JobEnvironment{}.Type(ctx), }, "git_source": basetypes.ListType{ - ElemType: GitSource{}.ToObjectType(ctx), + ElemType: GitSource{}.Type(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToObjectType(ctx), + ElemType: JobsHealthRules{}.Type(ctx), }, "idempotency_token": types.StringType, "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.ToObjectType(ctx), + ElemType: JobNotificationSettings{}.Type(ctx), }, "queue": basetypes.ListType{ - ElemType: QueueSettings{}.ToObjectType(ctx), + ElemType: QueueSettings{}.Type(ctx), }, "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.ToObjectType(ctx), + ElemType: JobRunAs{}.Type(ctx), }, "run_name": types.StringType, "tasks": basetypes.ListType{ - ElemType: SubmitTask{}.ToObjectType(ctx), + ElemType: SubmitTask{}.Type(ctx), }, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToObjectType(ctx), + ElemType: WebhookNotifications{}.Type(ctx), }, }, } @@ -6615,9 +12024,56 @@ func (a SubmitRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of SubmitRunResponse in the Terraform plugin framework type -// system. -func (a SubmitRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SubmitRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SubmitRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SubmitRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SubmitRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SubmitRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SubmitRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SubmitRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SubmitRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -6761,70 +12217,117 @@ func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of SubmitTask in the Terraform plugin framework type -// system. -func (a SubmitTask) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SubmitTask{} + +// Equal implements basetypes.ObjectValuable. +func (o SubmitTask) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SubmitTask) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SubmitTask) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SubmitTask) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SubmitTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SubmitTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ - ElemType: ConditionTask{}.ToObjectType(ctx), + ElemType: ConditionTask{}.Type(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.ToObjectType(ctx), + ElemType: DbtTask{}.Type(ctx), }, "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.ToObjectType(ctx), + ElemType: TaskDependency{}.Type(ctx), }, "description": types.StringType, "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.ToObjectType(ctx), + ElemType: JobEmailNotifications{}.Type(ctx), }, "environment_key": types.StringType, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ - ElemType: ForEachTask{}.ToObjectType(ctx), + ElemType: ForEachTask{}.Type(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToObjectType(ctx), + ElemType: JobsHealthRules{}.Type(ctx), }, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToObjectType(ctx), + ElemType: compute_tf.Library{}.Type(ctx), }, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), + ElemType: compute_tf.ClusterSpec{}.Type(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.ToObjectType(ctx), + ElemType: NotebookTask{}.Type(ctx), }, "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.ToObjectType(ctx), + ElemType: TaskNotificationSettings{}.Type(ctx), }, "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.ToObjectType(ctx), + ElemType: PipelineTask{}.Type(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.ToObjectType(ctx), + ElemType: PythonWheelTask{}.Type(ctx), }, "run_if": types.StringType, "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.ToObjectType(ctx), + ElemType: RunJobTask{}.Type(ctx), }, "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.ToObjectType(ctx), + ElemType: SparkJarTask{}.Type(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.ToObjectType(ctx), + ElemType: SparkPythonTask{}.Type(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.ToObjectType(ctx), + ElemType: SparkSubmitTask{}.Type(ctx), }, "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.ToObjectType(ctx), + ElemType: SqlTask{}.Type(ctx), }, "task_key": types.StringType, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToObjectType(ctx), + ElemType: WebhookNotifications{}.Type(ctx), }, }, } @@ -6866,9 +12369,56 @@ func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of TableUpdateTriggerConfiguration in the Terraform plugin framework type -// system. -func (a TableUpdateTriggerConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableUpdateTriggerConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableUpdateTriggerConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": types.StringType, @@ -7040,75 +12590,122 @@ func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of Task in the Terraform plugin framework type -// system. -func (a Task) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Task{} + +// Equal implements basetypes.ObjectValuable. +func (o Task) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Task) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Task) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Task) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Task) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Task) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Task) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ - ElemType: ConditionTask{}.ToObjectType(ctx), + ElemType: ConditionTask{}.Type(ctx), }, "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.ToObjectType(ctx), + ElemType: DbtTask{}.Type(ctx), }, "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.ToObjectType(ctx), + ElemType: TaskDependency{}.Type(ctx), }, "description": types.StringType, "disable_auto_optimization": types.BoolType, "email_notifications": basetypes.ListType{ - ElemType: TaskEmailNotifications{}.ToObjectType(ctx), + ElemType: TaskEmailNotifications{}.Type(ctx), }, "environment_key": types.StringType, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ - ElemType: ForEachTask{}.ToObjectType(ctx), + ElemType: ForEachTask{}.Type(ctx), }, "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.ToObjectType(ctx), + ElemType: JobsHealthRules{}.Type(ctx), }, "job_cluster_key": types.StringType, "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.ToObjectType(ctx), + ElemType: compute_tf.Library{}.Type(ctx), }, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.ToObjectType(ctx), + ElemType: compute_tf.ClusterSpec{}.Type(ctx), }, "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.ToObjectType(ctx), + ElemType: NotebookTask{}.Type(ctx), }, "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.ToObjectType(ctx), + ElemType: TaskNotificationSettings{}.Type(ctx), }, "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.ToObjectType(ctx), + ElemType: PipelineTask{}.Type(ctx), }, "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.ToObjectType(ctx), + ElemType: PythonWheelTask{}.Type(ctx), }, "retry_on_timeout": types.BoolType, "run_if": types.StringType, "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.ToObjectType(ctx), + ElemType: RunJobTask{}.Type(ctx), }, "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.ToObjectType(ctx), + ElemType: SparkJarTask{}.Type(ctx), }, "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.ToObjectType(ctx), + ElemType: SparkPythonTask{}.Type(ctx), }, "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.ToObjectType(ctx), + ElemType: SparkSubmitTask{}.Type(ctx), }, "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.ToObjectType(ctx), + ElemType: SqlTask{}.Type(ctx), }, "task_key": types.StringType, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.ToObjectType(ctx), + ElemType: WebhookNotifications{}.Type(ctx), }, }, } @@ -7139,9 +12736,56 @@ func (a TaskDependency) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of TaskDependency in the Terraform plugin framework type -// system. -func (a TaskDependency) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TaskDependency{} + +// Equal implements basetypes.ObjectValuable. +func (o TaskDependency) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TaskDependency) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TaskDependency) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TaskDependency) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TaskDependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TaskDependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TaskDependency) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "outcome": types.StringType, @@ -7209,9 +12853,56 @@ func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of TaskEmailNotifications in the Terraform plugin framework type -// system. -func (a TaskEmailNotifications) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TaskEmailNotifications{} + +// Equal implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TaskEmailNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "no_alert_for_skipped_runs": types.BoolType, @@ -7264,9 +12955,56 @@ func (a TaskNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of TaskNotificationSettings in the Terraform plugin framework type -// system. -func (a TaskNotificationSettings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TaskNotificationSettings{} + +// Equal implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TaskNotificationSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_on_last_attempt": types.BoolType, @@ -7334,7 +13072,7 @@ type TerminationDetails struct { // issue with your cloud provider. // // [status page]: https://status.databricks.com/ - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *TerminationDetails) SyncEffectiveFieldsDuringCreateOrUpdate(plan TerminationDetails) { @@ -7354,9 +13092,56 @@ func (a TerminationDetails) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of TerminationDetails in the Terraform plugin framework type -// system. -func (a TerminationDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TerminationDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o TerminationDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TerminationDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TerminationDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TerminationDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TerminationDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TerminationDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TerminationDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -7389,9 +13174,56 @@ func (a TriggerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of TriggerInfo in the Terraform plugin framework type -// system. -func (a TriggerInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TriggerInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o TriggerInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TriggerInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TriggerInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TriggerInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TriggerInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TriggerInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TriggerInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.Int64Type, @@ -7434,23 +13266,70 @@ func (a TriggerSettings) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of TriggerSettings in the Terraform plugin framework type -// system. -func (a TriggerSettings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TriggerSettings{} + +// Equal implements basetypes.ObjectValuable. +func (o TriggerSettings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TriggerSettings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TriggerSettings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TriggerSettings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TriggerSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TriggerSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TriggerSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_arrival": basetypes.ListType{ - ElemType: FileArrivalTriggerConfiguration{}.ToObjectType(ctx), + ElemType: FileArrivalTriggerConfiguration{}.Type(ctx), }, "pause_status": types.StringType, "periodic": basetypes.ListType{ - ElemType: PeriodicTriggerConfiguration{}.ToObjectType(ctx), + ElemType: PeriodicTriggerConfiguration{}.Type(ctx), }, "table": basetypes.ListType{ - ElemType: TableUpdateTriggerConfiguration{}.ToObjectType(ctx), + ElemType: TableUpdateTriggerConfiguration{}.Type(ctx), }, "table_update": basetypes.ListType{ - ElemType: TableUpdateTriggerConfiguration{}.ToObjectType(ctx), + ElemType: TableUpdateTriggerConfiguration{}.Type(ctx), }, }, } @@ -7497,9 +13376,56 @@ func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of UpdateJob in the Terraform plugin framework type -// system. -func (a UpdateJob) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateJob{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateJob) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateJob) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateJob) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateJob) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fields_to_remove": basetypes.ListType{ @@ -7507,7 +13433,7 @@ func (a UpdateJob) ToObjectType(ctx context.Context) types.ObjectType { }, "job_id": types.Int64Type, "new_settings": basetypes.ListType{ - ElemType: JobSettings{}.ToObjectType(ctx), + ElemType: JobSettings{}.Type(ctx), }, }, } @@ -7533,9 +13459,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -7549,7 +13522,7 @@ type ViewItem struct { // dashboard’s name. Name types.String `tfsdk:"name" tf:"optional"` // Type of the view item. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *ViewItem) SyncEffectiveFieldsDuringCreateOrUpdate(plan ViewItem) { @@ -7569,9 +13542,56 @@ func (a ViewItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of ViewItem in the Terraform plugin framework type -// system. -func (a ViewItem) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ViewItem{} + +// Equal implements basetypes.ObjectValuable. +func (o ViewItem) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ViewItem) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ViewItem) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ViewItem) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ViewItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ViewItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ViewItem) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -7602,9 +13622,56 @@ func (a Webhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of Webhook in the Terraform plugin framework type -// system. -func (a Webhook) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Webhook{} + +// Equal implements basetypes.ObjectValuable. +func (o Webhook) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Webhook) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Webhook) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Webhook) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Webhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Webhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Webhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -7662,26 +13729,260 @@ func (a WebhookNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of WebhookNotifications in the Terraform plugin framework type -// system. -func (a WebhookNotifications) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WebhookNotifications{} + +// Equal implements basetypes.ObjectValuable. +func (o WebhookNotifications) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WebhookNotifications) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WebhookNotifications) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WebhookNotifications) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WebhookNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WebhookNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WebhookNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "on_duration_warning_threshold_exceeded": basetypes.ListType{ - ElemType: Webhook{}.ToObjectType(ctx), + ElemType: Webhook{}.Type(ctx), }, "on_failure": basetypes.ListType{ - ElemType: Webhook{}.ToObjectType(ctx), + ElemType: Webhook{}.Type(ctx), }, "on_start": basetypes.ListType{ - ElemType: Webhook{}.ToObjectType(ctx), + ElemType: Webhook{}.Type(ctx), }, "on_streaming_backlog_exceeded": basetypes.ListType{ - ElemType: Webhook{}.ToObjectType(ctx), + ElemType: Webhook{}.Type(ctx), }, "on_success": basetypes.ListType{ - ElemType: Webhook{}.ToObjectType(ctx), + ElemType: Webhook{}.Type(ctx), }, }, } } + +// * `EQUAL_TO`, `NOT_EQUAL` operators perform string comparison of their +// operands. This means that `“12.0” == “12”` will evaluate to `false`. +// * `GREATER_THAN`, `GREATER_THAN_OR_EQUAL`, `LESS_THAN`, `LESS_THAN_OR_EQUAL` +// operators perform numeric comparison of their operands. `“12.0” >= +// “12”` will evaluate to `true`, `“10.0” >= “12”` will evaluate to +// `false`. +// +// The boolean comparison to task values can be implemented with operators +// `EQUAL_TO`, `NOT_EQUAL`. If a task value was set to a boolean value, it will +// be serialized to `“true”` or `“false”` for the comparison. + +// * `BUNDLE`: The job is managed by Databricks Asset Bundle. + +// Edit mode of the job. +// +// * `UI_LOCKED`: The job is in a locked UI state and cannot be modified. * +// `EDITABLE`: The job is in an editable state and can be modified. + +// Permission level + +// Dirty state indicates the job is not fully synced with the job specification +// in the remote repository. +// +// Possible values are: * `NOT_SYNCED`: The job is not yet synced with the +// remote job specification. Import the remote job specification from UI to make +// the job fully synced. * `DISCONNECTED`: The job is temporary disconnected +// from the remote job specification and is allowed for live edit. Import the +// remote job specification again from UI to make the job fully synced. + +// Specifies the health metric that is being evaluated for a particular health +// rule. +// +// * `RUN_DURATION_SECONDS`: Expected total time for a run in seconds. * +// `STREAMING_BACKLOG_BYTES`: An estimate of the maximum bytes of data waiting +// to be consumed across all streams. This metric is in Private Preview. * +// `STREAMING_BACKLOG_RECORDS`: An estimate of the maximum offset lag across all +// streams. This metric is in Private Preview. * `STREAMING_BACKLOG_SECONDS`: An +// estimate of the maximum consumer delay across all streams. This metric is in +// Private Preview. * `STREAMING_BACKLOG_FILES`: An estimate of the maximum +// number of outstanding files across all streams. This metric is in Private +// Preview. + +// Specifies the operator used to compare the health metric value with the +// specified threshold. + +// The reason for queuing the run. * `ACTIVE_RUNS_LIMIT_REACHED`: The run was +// queued due to reaching the workspace limit of active task runs. * +// `MAX_CONCURRENT_RUNS_REACHED`: The run was queued due to reaching the per-job +// limit of concurrent job runs. * `ACTIVE_RUN_JOB_TASKS_LIMIT_REACHED`: The run +// was queued due to reaching the workspace limit of active run job tasks. + +// The repair history item type. Indicates whether a run is the original run or +// a repair run. + +// An optional value indicating the condition that determines whether the task +// should be run once its dependencies have been completed. When omitted, +// defaults to `ALL_SUCCESS`. +// +// Possible values are: * `ALL_SUCCESS`: All dependencies have executed and +// succeeded * `AT_LEAST_ONE_SUCCESS`: At least one dependency has succeeded * +// `NONE_FAILED`: None of the dependencies have failed and at least one was +// executed * `ALL_DONE`: All dependencies have been completed * +// `AT_LEAST_ONE_FAILED`: At least one dependency failed * `ALL_FAILED`: ALl +// dependencies have failed + +// A value indicating the run's lifecycle state. The possible values are: * +// `QUEUED`: The run is queued. * `PENDING`: The run is waiting to be executed +// while the cluster and execution context are being prepared. * `RUNNING`: The +// task of this run is being executed. * `TERMINATING`: The task of this run has +// completed, and the cluster and execution context are being cleaned up. * +// `TERMINATED`: The task of this run has completed, and the cluster and +// execution context have been cleaned up. This state is terminal. * `SKIPPED`: +// This run was aborted because a previous run of the same job was already +// active. This state is terminal. * `INTERNAL_ERROR`: An exceptional state that +// indicates a failure in the Jobs service, such as network failure over a long +// period. If a run on a new cluster ends in the `INTERNAL_ERROR` state, the +// Jobs service terminates the cluster as soon as possible. This state is +// terminal. * `BLOCKED`: The run is blocked on an upstream dependency. * +// `WAITING_FOR_RETRY`: The run is waiting for a retry. + +// The current state of the run. + +// A value indicating the run's result. The possible values are: * `SUCCESS`: +// The task completed successfully. * `FAILED`: The task completed with an +// error. * `TIMEDOUT`: The run was stopped after reaching the timeout. * +// `CANCELED`: The run was canceled at user request. * +// `MAXIMUM_CONCURRENT_RUNS_REACHED`: The run was skipped because the maximum +// concurrent runs were reached. * `EXCLUDED`: The run was skipped because the +// necessary conditions were not met. * `SUCCESS_WITH_FAILURES`: The job run +// completed successfully with some failures; leaf tasks were successful. * +// `UPSTREAM_FAILED`: The run was skipped because of an upstream failure. * +// `UPSTREAM_CANCELED`: The run was skipped because an upstream task was +// canceled. * `DISABLED`: The run was skipped because it was disabled +// explicitly by the user. + +// The type of a run. * `JOB_RUN`: Normal job run. A run created with +// :method:jobs/runNow. * `WORKFLOW_RUN`: Workflow run. A run created with +// [dbutils.notebook.run]. * `SUBMIT_RUN`: Submit run. A run created with +// :method:jobs/submit. +// +// [dbutils.notebook.run]: https://docs.databricks.com/dev-tools/databricks-utils.html#dbutils-workflow + +// Optional location type of the SQL file. When set to `WORKSPACE`, the SQL file +// will be retrieved\ from the local Databricks workspace. When set to `GIT`, +// the SQL file will be retrieved from a Git repository defined in `git_source`. +// If the value is empty, the task will use `GIT` if `git_source` is defined and +// `WORKSPACE` otherwise. +// +// * `WORKSPACE`: SQL file is located in Databricks workspace. * `GIT`: SQL file +// is located in cloud Git provider. + +// The state of the SQL alert. +// +// * UNKNOWN: alert yet to be evaluated * OK: alert evaluated and did not +// fulfill trigger conditions * TRIGGERED: alert evaluated and fulfilled trigger +// conditions + +// The code indicates why the run was terminated. Additional codes might be +// introduced in future releases. * `SUCCESS`: The run was completed +// successfully. * `USER_CANCELED`: The run was successfully canceled during +// execution by a user. * `CANCELED`: The run was canceled during execution by +// the Databricks platform; for example, if the maximum run duration was +// exceeded. * `SKIPPED`: Run was never executed, for example, if the upstream +// task run failed, the dependency type condition was not met, or there were no +// material tasks to execute. * `INTERNAL_ERROR`: The run encountered an +// unexpected error. Refer to the state message for further details. * +// `DRIVER_ERROR`: The run encountered an error while communicating with the +// Spark Driver. * `CLUSTER_ERROR`: The run failed due to a cluster error. Refer +// to the state message for further details. * `REPOSITORY_CHECKOUT_FAILED`: +// Failed to complete the checkout due to an error when communicating with the +// third party service. * `INVALID_CLUSTER_REQUEST`: The run failed because it +// issued an invalid request to start the cluster. * +// `WORKSPACE_RUN_LIMIT_EXCEEDED`: The workspace has reached the quota for the +// maximum number of concurrent active runs. Consider scheduling the runs over a +// larger time frame. * `FEATURE_DISABLED`: The run failed because it tried to +// access a feature unavailable for the workspace. * +// `CLUSTER_REQUEST_LIMIT_EXCEEDED`: The number of cluster creation, start, and +// upsize requests have exceeded the allotted rate limit. Consider spreading the +// run execution over a larger time frame. * `STORAGE_ACCESS_ERROR`: The run +// failed due to an error when accessing the customer blob storage. Refer to the +// state message for further details. * `RUN_EXECUTION_ERROR`: The run was +// completed with task failures. For more details, refer to the state message or +// run output. * `UNAUTHORIZED_ERROR`: The run failed due to a permission issue +// while accessing a resource. Refer to the state message for further details. * +// `LIBRARY_INSTALLATION_ERROR`: The run failed while installing the +// user-requested library. Refer to the state message for further details. The +// causes might include, but are not limited to: The provided library is +// invalid, there are insufficient permissions to install the library, and so +// forth. * `MAX_CONCURRENT_RUNS_EXCEEDED`: The scheduled run exceeds the limit +// of maximum concurrent runs set for the job. * `MAX_SPARK_CONTEXTS_EXCEEDED`: +// The run is scheduled on a cluster that has already reached the maximum number +// of contexts it is configured to create. See: [Link]. * `RESOURCE_NOT_FOUND`: +// A resource necessary for run execution does not exist. Refer to the state +// message for further details. * `INVALID_RUN_CONFIGURATION`: The run failed +// due to an invalid configuration. Refer to the state message for further +// details. * `CLOUD_FAILURE`: The run failed due to a cloud provider issue. +// Refer to the state message for further details. * +// `MAX_JOB_QUEUE_SIZE_EXCEEDED`: The run was skipped due to reaching the job +// level queue size limit. +// +// [Link]: https://kb.databricks.com/en_US/notebooks/too-many-execution-contexts-are-open-right-now + +// * `SUCCESS`: The run terminated without any issues * `INTERNAL_ERROR`: An +// error occurred in the Databricks platform. Please look at the [status page] +// or contact support if the issue persists. * `CLIENT_ERROR`: The run was +// terminated because of an error caused by user input or the job configuration. +// * `CLOUD_FAILURE`: The run was terminated because of an issue with your cloud +// provider. +// +// [status page]: https://status.databricks.com/ + +// The type of trigger that fired this run. +// +// * `PERIODIC`: Schedules that periodically trigger runs, such as a cron +// scheduler. * `ONE_TIME`: One time triggers that fire a single run. This +// occurs you triggered a single run on demand through the UI or the API. * +// `RETRY`: Indicates a run that is triggered as a retry of a previously failed +// run. This occurs when you request to re-run the job in case of failures. * +// `RUN_JOB_TASK`: Indicates a run that is triggered using a Run Job task. * +// `FILE_ARRIVAL`: Indicates a run that is triggered by a file arrival. * +// `TABLE`: Indicates a run that is triggered by a table update. + +// * `NOTEBOOK`: Notebook view item. * `DASHBOARD`: Dashboard view item. + +// * `CODE`: Code view of the notebook. * `DASHBOARDS`: All dashboard views of +// the notebook. * `ALL`: All views of the notebook. diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 4d284c7b8e..544b007491 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -12,11 +12,15 @@ package marketplace_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AddExchangeForListingRequest struct { @@ -42,9 +46,56 @@ func (a AddExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of AddExchangeForListingRequest in the Terraform plugin framework type -// system. -func (a AddExchangeForListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AddExchangeForListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AddExchangeForListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -76,13 +127,60 @@ func (a AddExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of AddExchangeForListingResponse in the Terraform plugin framework type -// system. -func (a AddExchangeForListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AddExchangeForListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AddExchangeForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_for_listing": basetypes.ListType{ - ElemType: ExchangeListing{}.ToObjectType(ctx), + ElemType: ExchangeListing{}.Type(ctx), }, }, } @@ -112,9 +210,56 @@ func (a BatchGetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of BatchGetListingsRequest in the Terraform plugin framework type -// system. -func (a BatchGetListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BatchGetListingsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BatchGetListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ids": basetypes.ListType{ @@ -147,13 +292,60 @@ func (a BatchGetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of BatchGetListingsResponse in the Terraform plugin framework type -// system. -func (a BatchGetListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BatchGetListingsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BatchGetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, }, } @@ -183,9 +375,56 @@ func (a BatchGetProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of BatchGetProvidersRequest in the Terraform plugin framework type -// system. -func (a BatchGetProvidersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BatchGetProvidersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BatchGetProvidersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ids": basetypes.ListType{ @@ -218,13 +457,60 @@ func (a BatchGetProvidersResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of BatchGetProvidersResponse in the Terraform plugin framework type -// system. -func (a BatchGetProvidersResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BatchGetProvidersResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BatchGetProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } @@ -251,9 +537,56 @@ func (a ConsumerTerms) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ConsumerTerms in the Terraform plugin framework type -// system. -func (a ConsumerTerms) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ConsumerTerms{} + +// Equal implements basetypes.ObjectValuable. +func (o ConsumerTerms) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ConsumerTerms) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ConsumerTerms) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ConsumerTerms) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ConsumerTerms) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ConsumerTerms) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ConsumerTerms) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "version": types.StringType, @@ -290,9 +623,56 @@ func (a ContactInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of ContactInfo in the Terraform plugin framework type -// system. -func (a ContactInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ContactInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ContactInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ContactInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ContactInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ContactInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ContactInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ContactInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ContactInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "company": types.StringType, @@ -326,13 +706,60 @@ func (a CreateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of CreateExchangeFilterRequest in the Terraform plugin framework type -// system. -func (a CreateExchangeFilterRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExchangeFilterRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToObjectType(ctx), + ElemType: ExchangeFilter{}.Type(ctx), }, }, } @@ -359,9 +786,56 @@ func (a CreateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateExchangeFilterResponse in the Terraform plugin framework type -// system. -func (a CreateExchangeFilterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExchangeFilterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExchangeFilterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter_id": types.StringType, @@ -392,13 +866,60 @@ func (a CreateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateExchangeRequest in the Terraform plugin framework type -// system. -func (a CreateExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExchangeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToObjectType(ctx), + ElemType: Exchange{}.Type(ctx), }, }, } @@ -425,9 +946,56 @@ func (a CreateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateExchangeResponse in the Terraform plugin framework type -// system. -func (a CreateExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExchangeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -464,14 +1032,61 @@ func (a CreateFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of CreateFileRequest in the Terraform plugin framework type -// system. -func (a CreateFileRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateFileRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateFileRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateFileRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateFileRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateFileRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateFileRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, "file_parent": basetypes.ListType{ - ElemType: FileParent{}.ToObjectType(ctx), + ElemType: FileParent{}.Type(ctx), }, "marketplace_file_type": types.StringType, "mime_type": types.StringType, @@ -504,13 +1119,60 @@ func (a CreateFileResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateFileResponse in the Terraform plugin framework type -// system. -func (a CreateFileResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateFileResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateFileResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateFileResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateFileResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateFileResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateFileResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateFileResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_info": basetypes.ListType{ - ElemType: FileInfo{}.ToObjectType(ctx), + ElemType: FileInfo{}.Type(ctx), }, "upload_url": types.StringType, }, @@ -551,19 +1213,66 @@ func (a CreateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of CreateInstallationRequest in the Terraform plugin framework type -// system. -func (a CreateInstallationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateInstallationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "accepted_consumer_terms": basetypes.ListType{ - ElemType: ConsumerTerms{}.ToObjectType(ctx), + ElemType: ConsumerTerms{}.Type(ctx), }, "catalog_name": types.StringType, "listing_id": types.StringType, "recipient_type": types.StringType, "repo_detail": basetypes.ListType{ - ElemType: RepoInstallation{}.ToObjectType(ctx), + ElemType: RepoInstallation{}.Type(ctx), }, "share_name": types.StringType, }, @@ -593,13 +1302,60 @@ func (a CreateListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of CreateListingRequest in the Terraform plugin framework type -// system. -func (a CreateListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, }, } @@ -626,9 +1382,56 @@ func (a CreateListingResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateListingResponse in the Terraform plugin framework type -// system. -func (a CreateListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -676,13 +1479,60 @@ func (a CreatePersonalizationRequest) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of CreatePersonalizationRequest in the Terraform plugin framework type -// system. -func (a CreatePersonalizationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePersonalizationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "accepted_consumer_terms": basetypes.ListType{ - ElemType: ConsumerTerms{}.ToObjectType(ctx), + ElemType: ConsumerTerms{}.Type(ctx), }, "comment": types.StringType, "company": types.StringType, @@ -717,9 +1567,56 @@ func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreatePersonalizationRequestResponse in the Terraform plugin framework type -// system. -func (a CreatePersonalizationRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePersonalizationRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -750,13 +1647,60 @@ func (a CreateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateProviderRequest in the Terraform plugin framework type -// system. -func (a CreateProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateProviderRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateProviderRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateProviderRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateProviderRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateProviderRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } @@ -783,9 +1727,56 @@ func (a CreateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateProviderResponse in the Terraform plugin framework type -// system. -func (a CreateProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateProviderResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateProviderResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateProviderResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateProviderResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateProviderResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -816,9 +1807,56 @@ func (a DataRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of DataRefreshInfo in the Terraform plugin framework type -// system. -func (a DataRefreshInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DataRefreshInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o DataRefreshInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DataRefreshInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DataRefreshInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DataRefreshInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DataRefreshInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DataRefreshInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DataRefreshInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "interval": types.Int64Type, @@ -849,9 +1887,56 @@ func (a DeleteExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExchangeFilterRequest in the Terraform plugin framework type -// system. -func (a DeleteExchangeFilterRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExchangeFilterRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -879,9 +1964,56 @@ func (a DeleteExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExchangeFilterResponse in the Terraform plugin framework type -// system. -func (a DeleteExchangeFilterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExchangeFilterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExchangeFilterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -909,9 +2041,56 @@ func (a DeleteExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExchangeRequest in the Terraform plugin framework type -// system. -func (a DeleteExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExchangeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -939,9 +2118,56 @@ func (a DeleteExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExchangeResponse in the Terraform plugin framework type -// system. -func (a DeleteExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExchangeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -969,9 +2195,56 @@ func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteFileRequest in the Terraform plugin framework type -// system. -func (a DeleteFileRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteFileRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteFileRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteFileRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteFileRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteFileRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteFileRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_id": types.StringType, @@ -999,9 +2272,56 @@ func (a DeleteFileResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteFileResponse in the Terraform plugin framework type -// system. -func (a DeleteFileResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteFileResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteFileResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteFileResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteFileResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteFileResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteFileResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteFileResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1031,9 +2351,56 @@ func (a DeleteInstallationRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteInstallationRequest in the Terraform plugin framework type -// system. -func (a DeleteInstallationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteInstallationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation_id": types.StringType, @@ -1062,9 +2429,56 @@ func (a DeleteInstallationResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteInstallationResponse in the Terraform plugin framework type -// system. -func (a DeleteInstallationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteInstallationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteInstallationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1092,9 +2506,56 @@ func (a DeleteListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteListingRequest in the Terraform plugin framework type -// system. -func (a DeleteListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1122,9 +2583,56 @@ func (a DeleteListingResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteListingResponse in the Terraform plugin framework type -// system. -func (a DeleteListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1152,9 +2660,56 @@ func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteProviderRequest in the Terraform plugin framework type -// system. -func (a DeleteProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteProviderRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1182,9 +2737,56 @@ func (a DeleteProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteProviderResponse in the Terraform plugin framework type -// system. -func (a DeleteProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteProviderResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1230,20 +2832,67 @@ func (a Exchange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of Exchange in the Terraform plugin framework type -// system. -func (a Exchange) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Exchange{} + +// Equal implements basetypes.ObjectValuable. +func (o Exchange) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Exchange) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Exchange) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Exchange) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Exchange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Exchange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Exchange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, "filters": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToObjectType(ctx), + ElemType: ExchangeFilter{}.Type(ctx), }, "id": types.StringType, "linked_listings": basetypes.ListType{ - ElemType: ExchangeListing{}.ToObjectType(ctx), + ElemType: ExchangeListing{}.Type(ctx), }, "name": types.StringType, "updated_at": types.Int64Type, @@ -1289,9 +2938,56 @@ func (a ExchangeFilter) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExchangeFilter in the Terraform plugin framework type -// system. -func (a ExchangeFilter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExchangeFilter{} + +// Equal implements basetypes.ObjectValuable. +func (o ExchangeFilter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExchangeFilter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExchangeFilter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExchangeFilter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExchangeFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExchangeFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExchangeFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -1340,9 +3036,56 @@ func (a ExchangeListing) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExchangeListing in the Terraform plugin framework type -// system. -func (a ExchangeListing) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExchangeListing{} + +// Equal implements basetypes.ObjectValuable. +func (o ExchangeListing) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExchangeListing) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExchangeListing) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExchangeListing) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExchangeListing) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExchangeListing) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExchangeListing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -1398,16 +3141,63 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of FileInfo in the Terraform plugin framework type -// system. -func (a FileInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FileInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o FileInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FileInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FileInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FileInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FileInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, "display_name": types.StringType, "download_link": types.StringType, "file_parent": basetypes.ListType{ - ElemType: FileParent{}.ToObjectType(ctx), + ElemType: FileParent{}.Type(ctx), }, "id": types.StringType, "marketplace_file_type": types.StringType, @@ -1442,9 +3232,56 @@ func (a FileParent) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of FileParent in the Terraform plugin framework type -// system. -func (a FileParent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FileParent{} + +// Equal implements basetypes.ObjectValuable. +func (o FileParent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FileParent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FileParent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FileParent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FileParent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FileParent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FileParent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_parent_type": types.StringType, @@ -1475,9 +3312,56 @@ func (a GetExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetExchangeRequest in the Terraform plugin framework type -// system. -func (a GetExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExchangeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExchangeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExchangeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExchangeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExchangeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1508,13 +3392,60 @@ func (a GetExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of GetExchangeResponse in the Terraform plugin framework type -// system. -func (a GetExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExchangeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExchangeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExchangeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExchangeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExchangeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToObjectType(ctx), + ElemType: Exchange{}.Type(ctx), }, }, } @@ -1542,9 +3473,56 @@ func (a GetFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetFileRequest in the Terraform plugin framework type -// system. -func (a GetFileRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetFileRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetFileRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetFileRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetFileRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetFileRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetFileRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_id": types.StringType, @@ -1575,13 +3553,60 @@ func (a GetFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of GetFileResponse in the Terraform plugin framework type -// system. -func (a GetFileResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetFileResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetFileResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetFileResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetFileResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetFileResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetFileResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetFileResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_info": basetypes.ListType{ - ElemType: FileInfo{}.ToObjectType(ctx), + ElemType: FileInfo{}.Type(ctx), }, }, } @@ -1609,9 +3634,56 @@ func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetLatestVersionProviderAnalyticsDashboardResponse in the Terraform plugin framework type -// system. -func (a GetLatestVersionProviderAnalyticsDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetLatestVersionProviderAnalyticsDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetLatestVersionProviderAnalyticsDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "version": types.Int64Type, @@ -1645,9 +3717,56 @@ func (a GetListingContentMetadataRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetListingContentMetadataRequest in the Terraform plugin framework type -// system. -func (a GetListingContentMetadataRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetListingContentMetadataRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetListingContentMetadataRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -1682,14 +3801,61 @@ func (a GetListingContentMetadataResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of GetListingContentMetadataResponse in the Terraform plugin framework type -// system. -func (a GetListingContentMetadataResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetListingContentMetadataResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetListingContentMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "shared_data_objects": basetypes.ListType{ - ElemType: SharedDataObject{}.ToObjectType(ctx), + ElemType: SharedDataObject{}.Type(ctx), }, }, } @@ -1717,9 +3883,56 @@ func (a GetListingRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetListingRequest in the Terraform plugin framework type -// system. -func (a GetListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1750,13 +3963,60 @@ func (a GetListingResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of GetListingResponse in the Terraform plugin framework type -// system. -func (a GetListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, }, } @@ -1786,9 +4046,56 @@ func (a GetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetListingsRequest in the Terraform plugin framework type -// system. -func (a GetListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetListingsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetListingsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetListingsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetListingsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetListingsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -1822,13 +4129,60 @@ func (a GetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of GetListingsResponse in the Terraform plugin framework type -// system. -func (a GetListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetListingsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetListingsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetListingsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetListingsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetListingsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -1857,9 +4211,56 @@ func (a GetPersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPersonalizationRequestRequest in the Terraform plugin framework type -// system. -func (a GetPersonalizationRequestRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPersonalizationRequestRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -1890,13 +4291,60 @@ func (a GetPersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of GetPersonalizationRequestResponse in the Terraform plugin framework type -// system. -func (a GetPersonalizationRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPersonalizationRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "personalization_requests": basetypes.ListType{ - ElemType: PersonalizationRequest{}.ToObjectType(ctx), + ElemType: PersonalizationRequest{}.Type(ctx), }, }, } @@ -1924,9 +4372,56 @@ func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetProviderRequest in the Terraform plugin framework type -// system. -func (a GetProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetProviderRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetProviderRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetProviderRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetProviderRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetProviderRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1957,13 +4452,60 @@ func (a GetProviderResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of GetProviderResponse in the Terraform plugin framework type -// system. -func (a GetProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetProviderResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetProviderResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetProviderResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetProviderResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetProviderResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } @@ -1992,13 +4534,60 @@ func (a Installation) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of Installation in the Terraform plugin framework type -// system. -func (a Installation) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Installation{} + +// Equal implements basetypes.ObjectValuable. +func (o Installation) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Installation) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Installation) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Installation) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Installation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Installation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Installation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.ToObjectType(ctx), + ElemType: InstallationDetail{}.Type(ctx), }, }, } @@ -2052,9 +4641,56 @@ func (a InstallationDetail) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of InstallationDetail in the Terraform plugin framework type -// system. -func (a InstallationDetail) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InstallationDetail{} + +// Equal implements basetypes.ObjectValuable. +func (o InstallationDetail) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InstallationDetail) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InstallationDetail) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InstallationDetail) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InstallationDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InstallationDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InstallationDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -2069,10 +4705,10 @@ func (a InstallationDetail) ToObjectType(ctx context.Context) types.ObjectType { "share_name": types.StringType, "status": types.StringType, "token_detail": basetypes.ListType{ - ElemType: TokenDetail{}.ToObjectType(ctx), + ElemType: TokenDetail{}.Type(ctx), }, "tokens": basetypes.ListType{ - ElemType: TokenInfo{}.ToObjectType(ctx), + ElemType: TokenInfo{}.Type(ctx), }, }, } @@ -2102,9 +4738,56 @@ func (a ListAllInstallationsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAllInstallationsRequest in the Terraform plugin framework type -// system. -func (a ListAllInstallationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAllInstallationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAllInstallationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -2138,13 +4821,60 @@ func (a ListAllInstallationsResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListAllInstallationsResponse in the Terraform plugin framework type -// system. -func (a ListAllInstallationsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAllInstallationsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAllInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installations": basetypes.ListType{ - ElemType: InstallationDetail{}.ToObjectType(ctx), + ElemType: InstallationDetail{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2175,9 +4905,56 @@ func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAllPersonalizationRequestsRequest in the Terraform plugin framework type -// system. -func (a ListAllPersonalizationRequestsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAllPersonalizationRequestsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -2211,14 +4988,61 @@ func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes(ctx context } } -// ToObjectType returns the representation of ListAllPersonalizationRequestsResponse in the Terraform plugin framework type -// system. -func (a ListAllPersonalizationRequestsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAllPersonalizationRequestsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAllPersonalizationRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "personalization_requests": basetypes.ListType{ - ElemType: PersonalizationRequest{}.ToObjectType(ctx), + ElemType: PersonalizationRequest{}.Type(ctx), }, }, } @@ -2250,9 +5074,56 @@ func (a ListExchangeFiltersRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListExchangeFiltersRequest in the Terraform plugin framework type -// system. -func (a ListExchangeFiltersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExchangeFiltersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExchangeFiltersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -2287,13 +5158,60 @@ func (a ListExchangeFiltersResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of ListExchangeFiltersResponse in the Terraform plugin framework type -// system. -func (a ListExchangeFiltersResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExchangeFiltersResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExchangeFiltersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filters": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToObjectType(ctx), + ElemType: ExchangeFilter{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2326,9 +5244,56 @@ func (a ListExchangesForListingRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListExchangesForListingRequest in the Terraform plugin framework type -// system. -func (a ListExchangesForListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExchangesForListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExchangesForListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -2363,13 +5328,60 @@ func (a ListExchangesForListingResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of ListExchangesForListingResponse in the Terraform plugin framework type -// system. -func (a ListExchangesForListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExchangesForListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExchangesForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_listing": basetypes.ListType{ - ElemType: ExchangeListing{}.ToObjectType(ctx), + ElemType: ExchangeListing{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2400,9 +5412,56 @@ func (a ListExchangesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListExchangesRequest in the Terraform plugin framework type -// system. -func (a ListExchangesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExchangesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExchangesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExchangesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExchangesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExchangesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExchangesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExchangesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExchangesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -2436,13 +5495,60 @@ func (a ListExchangesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListExchangesResponse in the Terraform plugin framework type -// system. -func (a ListExchangesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExchangesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExchangesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExchangesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExchangesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExchangesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExchangesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExchangesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExchangesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchanges": basetypes.ListType{ - ElemType: Exchange{}.ToObjectType(ctx), + ElemType: Exchange{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2477,13 +5583,60 @@ func (a ListFilesRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ListFilesRequest in the Terraform plugin framework type -// system. -func (a ListFilesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListFilesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListFilesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListFilesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListFilesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListFilesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListFilesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListFilesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListFilesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_parent": basetypes.ListType{ - ElemType: FileParent{}.ToObjectType(ctx), + ElemType: FileParent{}.Type(ctx), }, "page_size": types.Int64Type, "page_token": types.StringType, @@ -2516,13 +5669,60 @@ func (a ListFilesResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ListFilesResponse in the Terraform plugin framework type -// system. -func (a ListFilesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListFilesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListFilesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListFilesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListFilesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListFilesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListFilesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListFilesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListFilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_infos": basetypes.ListType{ - ElemType: FileInfo{}.ToObjectType(ctx), + ElemType: FileInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2555,9 +5755,56 @@ func (a ListFulfillmentsRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListFulfillmentsRequest in the Terraform plugin framework type -// system. -func (a ListFulfillmentsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListFulfillmentsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListFulfillmentsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -2592,13 +5839,60 @@ func (a ListFulfillmentsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of ListFulfillmentsResponse in the Terraform plugin framework type -// system. -func (a ListFulfillmentsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListFulfillmentsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListFulfillmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fulfillments": basetypes.ListType{ - ElemType: ListingFulfillment{}.ToObjectType(ctx), + ElemType: ListingFulfillment{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2631,9 +5925,56 @@ func (a ListInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListInstallationsRequest in the Terraform plugin framework type -// system. -func (a ListInstallationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListInstallationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListInstallationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, @@ -2668,13 +6009,60 @@ func (a ListInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ListInstallationsResponse in the Terraform plugin framework type -// system. -func (a ListInstallationsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListInstallationsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installations": basetypes.ListType{ - ElemType: InstallationDetail{}.ToObjectType(ctx), + ElemType: InstallationDetail{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2707,9 +6095,56 @@ func (a ListListingsForExchangeRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListListingsForExchangeRequest in the Terraform plugin framework type -// system. -func (a ListListingsForExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListListingsForExchangeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListListingsForExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_id": types.StringType, @@ -2744,13 +6179,60 @@ func (a ListListingsForExchangeResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of ListListingsForExchangeResponse in the Terraform plugin framework type -// system. -func (a ListListingsForExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListListingsForExchangeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListListingsForExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange_listings": basetypes.ListType{ - ElemType: ExchangeListing{}.ToObjectType(ctx), + ElemType: ExchangeListing{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2801,9 +6283,56 @@ func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListListingsRequest in the Terraform plugin framework type -// system. -func (a ListListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListListingsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListListingsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListListingsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListListingsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListListingsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets": basetypes.ListType{ @@ -2821,7 +6350,7 @@ func (a ListListingsRequest) ToObjectType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "tags": basetypes.ListType{ - ElemType: ListingTag{}.ToObjectType(ctx), + ElemType: ListingTag{}.Type(ctx), }, }, } @@ -2852,13 +6381,60 @@ func (a ListListingsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListListingsResponse in the Terraform plugin framework type -// system. -func (a ListListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListListingsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListListingsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListListingsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListListingsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListListingsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2891,9 +6467,56 @@ func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListProviderAnalyticsDashboardResponse in the Terraform plugin framework type -// system. -func (a ListProviderAnalyticsDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListProviderAnalyticsDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListProviderAnalyticsDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -2929,9 +6552,56 @@ func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListProvidersRequest in the Terraform plugin framework type -// system. -func (a ListProvidersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListProvidersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListProvidersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListProvidersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListProvidersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListProvidersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListProvidersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListProvidersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListProvidersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_featured": types.BoolType, @@ -2966,14 +6636,61 @@ func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListProvidersResponse in the Terraform plugin framework type -// system. -func (a ListProvidersResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListProvidersResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListProvidersResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListProvidersResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListProvidersResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListProvidersResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListProvidersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListProvidersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } @@ -3007,17 +6724,64 @@ func (a Listing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of Listing in the Terraform plugin framework type -// system. -func (a Listing) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Listing{} + +// Equal implements basetypes.ObjectValuable. +func (o Listing) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Listing) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Listing) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Listing) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Listing) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Listing) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Listing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "detail": basetypes.ListType{ - ElemType: ListingDetail{}.ToObjectType(ctx), + ElemType: ListingDetail{}.Type(ctx), }, "id": types.StringType, "summary": basetypes.ListType{ - ElemType: ListingSummary{}.ToObjectType(ctx), + ElemType: ListingSummary{}.Type(ctx), }, }, } @@ -3098,9 +6862,56 @@ func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of ListingDetail in the Terraform plugin framework type -// system. -func (a ListingDetail) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListingDetail{} + +// Equal implements basetypes.ObjectValuable. +func (o ListingDetail) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListingDetail) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListingDetail) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListingDetail) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListingDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListingDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListingDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets": basetypes.ListType{ @@ -3109,14 +6920,14 @@ func (a ListingDetail) ToObjectType(ctx context.Context) types.ObjectType { "collection_date_end": types.Int64Type, "collection_date_start": types.Int64Type, "collection_granularity": basetypes.ListType{ - ElemType: DataRefreshInfo{}.ToObjectType(ctx), + ElemType: DataRefreshInfo{}.Type(ctx), }, "cost": types.StringType, "data_source": types.StringType, "description": types.StringType, "documentation_link": types.StringType, "embedded_notebook_file_infos": basetypes.ListType{ - ElemType: FileInfo{}.ToObjectType(ctx), + ElemType: FileInfo{}.Type(ctx), }, "file_ids": basetypes.ListType{ ElemType: types.StringType, @@ -3128,11 +6939,11 @@ func (a ListingDetail) ToObjectType(ctx context.Context) types.ObjectType { "size": types.Float64Type, "support_link": types.StringType, "tags": basetypes.ListType{ - ElemType: ListingTag{}.ToObjectType(ctx), + ElemType: ListingTag{}.Type(ctx), }, "terms_of_service": types.StringType, "update_frequency": basetypes.ListType{ - ElemType: DataRefreshInfo{}.ToObjectType(ctx), + ElemType: DataRefreshInfo{}.Type(ctx), }, }, } @@ -3170,19 +6981,66 @@ func (a ListingFulfillment) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListingFulfillment in the Terraform plugin framework type -// system. -func (a ListingFulfillment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListingFulfillment{} + +// Equal implements basetypes.ObjectValuable. +func (o ListingFulfillment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListingFulfillment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListingFulfillment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListingFulfillment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListingFulfillment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListingFulfillment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListingFulfillment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fulfillment_type": types.StringType, "listing_id": types.StringType, "recipient_type": types.StringType, "repo_info": basetypes.ListType{ - ElemType: RepoInfo{}.ToObjectType(ctx), + ElemType: RepoInfo{}.Type(ctx), }, "share_info": basetypes.ListType{ - ElemType: ShareInfo{}.ToObjectType(ctx), + ElemType: ShareInfo{}.Type(ctx), }, }, } @@ -3209,9 +7067,56 @@ func (a ListingSetting) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListingSetting in the Terraform plugin framework type -// system. -func (a ListingSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListingSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o ListingSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListingSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListingSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListingSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListingSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListingSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListingSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "visibility": types.StringType, @@ -3285,9 +7190,56 @@ func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ListingSummary in the Terraform plugin framework type -// system. -func (a ListingSummary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListingSummary{} + +// Equal implements basetypes.ObjectValuable. +func (o ListingSummary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListingSummary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListingSummary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListingSummary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListingSummary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListingSummary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListingSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "categories": basetypes.ListType{ @@ -3300,21 +7252,21 @@ func (a ListingSummary) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "git_repo": basetypes.ListType{ - ElemType: RepoInfo{}.ToObjectType(ctx), + ElemType: RepoInfo{}.Type(ctx), }, "listingType": types.StringType, "name": types.StringType, "provider_id": types.StringType, "provider_region": basetypes.ListType{ - ElemType: RegionInfo{}.ToObjectType(ctx), + ElemType: RegionInfo{}.Type(ctx), }, "published_at": types.Int64Type, "published_by": types.StringType, "setting": basetypes.ListType{ - ElemType: ListingSetting{}.ToObjectType(ctx), + ElemType: ListingSetting{}.Type(ctx), }, "share": basetypes.ListType{ - ElemType: ShareInfo{}.ToObjectType(ctx), + ElemType: ShareInfo{}.Type(ctx), }, "status": types.StringType, "subtitle": types.StringType, @@ -3352,9 +7304,56 @@ func (a ListingTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of ListingTag in the Terraform plugin framework type -// system. -func (a ListingTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListingTag{} + +// Equal implements basetypes.ObjectValuable. +func (o ListingTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListingTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListingTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListingTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListingTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListingTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListingTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "tag_name": types.StringType, @@ -3421,17 +7420,64 @@ func (a PersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of PersonalizationRequest in the Terraform plugin framework type -// system. -func (a PersonalizationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PersonalizationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PersonalizationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PersonalizationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PersonalizationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PersonalizationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PersonalizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PersonalizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PersonalizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "consumer_region": basetypes.ListType{ - ElemType: RegionInfo{}.ToObjectType(ctx), + ElemType: RegionInfo{}.Type(ctx), }, "contact_info": basetypes.ListType{ - ElemType: ContactInfo{}.ToObjectType(ctx), + ElemType: ContactInfo{}.Type(ctx), }, "created_at": types.Int64Type, "id": types.StringType, @@ -3443,7 +7489,7 @@ func (a PersonalizationRequest) ToObjectType(ctx context.Context) types.ObjectTy "provider_id": types.StringType, "recipient_type": types.StringType, "share": basetypes.ListType{ - ElemType: ShareInfo{}.ToObjectType(ctx), + ElemType: ShareInfo{}.Type(ctx), }, "status": types.StringType, "status_message": types.StringType, @@ -3473,9 +7519,56 @@ func (a ProviderAnalyticsDashboard) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of ProviderAnalyticsDashboard in the Terraform plugin framework type -// system. -func (a ProviderAnalyticsDashboard) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ProviderAnalyticsDashboard{} + +// Equal implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ProviderAnalyticsDashboard) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3530,9 +7623,56 @@ func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of ProviderInfo in the Terraform plugin framework type -// system. -func (a ProviderInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ProviderInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ProviderInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ProviderInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ProviderInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ProviderInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ProviderInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ProviderInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ProviderInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "business_contact_email": types.StringType, @@ -3576,9 +7716,56 @@ func (a RegionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of RegionInfo in the Terraform plugin framework type -// system. -func (a RegionInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegionInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RegionInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegionInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegionInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegionInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cloud": types.StringType, @@ -3609,9 +7796,56 @@ func (a RemoveExchangeForListingRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of RemoveExchangeForListingRequest in the Terraform plugin framework type -// system. -func (a RemoveExchangeForListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RemoveExchangeForListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3639,9 +7873,56 @@ func (a RemoveExchangeForListingResponse) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of RemoveExchangeForListingResponse in the Terraform plugin framework type -// system. -func (a RemoveExchangeForListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RemoveExchangeForListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RemoveExchangeForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3669,9 +7950,56 @@ func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of RepoInfo in the Terraform plugin framework type -// system. -func (a RepoInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "git_repo_url": types.StringType, @@ -3705,9 +8033,56 @@ func (a RepoInstallation) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of RepoInstallation in the Terraform plugin framework type -// system. -func (a RepoInstallation) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoInstallation{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoInstallation) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoInstallation) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoInstallation) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoInstallation) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoInstallation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoInstallation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoInstallation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_name": types.StringType, @@ -3757,9 +8132,56 @@ func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of SearchListingsRequest in the Terraform plugin framework type -// system. -func (a SearchListingsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchListingsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchListingsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchListingsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchListingsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchListingsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "assets": basetypes.ListType{ @@ -3805,13 +8227,60 @@ func (a SearchListingsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of SearchListingsResponse in the Terraform plugin framework type -// system. -func (a SearchListingsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchListingsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchListingsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchListingsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchListingsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchListingsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listings": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -3821,7 +8290,7 @@ func (a SearchListingsResponse) ToObjectType(ctx context.Context) types.ObjectTy type ShareInfo struct { Name types.String `tfsdk:"name" tf:""` - Type types.String `tfsdk:"type" tf:""` + Type_ types.String `tfsdk:"type" tf:""` } func (newState *ShareInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ShareInfo) { @@ -3841,9 +8310,56 @@ func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of ShareInfo in the Terraform plugin framework type -// system. -func (a ShareInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ShareInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ShareInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ShareInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ShareInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ShareInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ShareInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ShareInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ShareInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -3877,9 +8393,56 @@ func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of SharedDataObject in the Terraform plugin framework type -// system. -func (a SharedDataObject) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SharedDataObject{} + +// Equal implements basetypes.ObjectValuable. +func (o SharedDataObject) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SharedDataObject) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SharedDataObject) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SharedDataObject) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SharedDataObject) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SharedDataObject) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SharedDataObject) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_object_type": types.StringType, @@ -3917,9 +8480,56 @@ func (a TokenDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of TokenDetail in the Terraform plugin framework type -// system. -func (a TokenDetail) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenDetail{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenDetail) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenDetail) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenDetail) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenDetail) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bearerToken": types.StringType, @@ -3965,9 +8575,56 @@ func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of TokenInfo in the Terraform plugin framework type -// system. -func (a TokenInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -4006,13 +8663,60 @@ func (a UpdateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of UpdateExchangeFilterRequest in the Terraform plugin framework type -// system. -func (a UpdateExchangeFilterRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExchangeFilterRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToObjectType(ctx), + ElemType: ExchangeFilter{}.Type(ctx), }, "id": types.StringType, }, @@ -4042,13 +8746,60 @@ func (a UpdateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of UpdateExchangeFilterResponse in the Terraform plugin framework type -// system. -func (a UpdateExchangeFilterResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExchangeFilterResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExchangeFilterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.ToObjectType(ctx), + ElemType: ExchangeFilter{}.Type(ctx), }, }, } @@ -4079,13 +8830,60 @@ func (a UpdateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateExchangeRequest in the Terraform plugin framework type -// system. -func (a UpdateExchangeRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExchangeRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToObjectType(ctx), + ElemType: Exchange{}.Type(ctx), }, "id": types.StringType, }, @@ -4115,13 +8913,60 @@ func (a UpdateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of UpdateExchangeResponse in the Terraform plugin framework type -// system. -func (a UpdateExchangeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExchangeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exchange": basetypes.ListType{ - ElemType: Exchange{}.ToObjectType(ctx), + ElemType: Exchange{}.Type(ctx), }, }, } @@ -4156,13 +9001,60 @@ func (a UpdateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of UpdateInstallationRequest in the Terraform plugin framework type -// system. -func (a UpdateInstallationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateInstallationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.ToObjectType(ctx), + ElemType: InstallationDetail{}.Type(ctx), }, "installation_id": types.StringType, "listing_id": types.StringType, @@ -4194,13 +9086,60 @@ func (a UpdateInstallationResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of UpdateInstallationResponse in the Terraform plugin framework type -// system. -func (a UpdateInstallationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateInstallationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateInstallationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.ToObjectType(ctx), + ElemType: InstallationDetail{}.Type(ctx), }, }, } @@ -4231,14 +9170,61 @@ func (a UpdateListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of UpdateListingRequest in the Terraform plugin framework type -// system. -func (a UpdateListingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateListingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateListingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateListingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateListingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateListingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "listing": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, }, } @@ -4267,13 +9253,60 @@ func (a UpdateListingResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateListingResponse in the Terraform plugin framework type -// system. -func (a UpdateListingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateListingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateListingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateListingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateListingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateListingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing": basetypes.ListType{ - ElemType: Listing{}.ToObjectType(ctx), + ElemType: Listing{}.Type(ctx), }, }, } @@ -4310,16 +9343,63 @@ func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Co } } -// ToObjectType returns the representation of UpdatePersonalizationRequestRequest in the Terraform plugin framework type -// system. -func (a UpdatePersonalizationRequestRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePersonalizationRequestRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "listing_id": types.StringType, "reason": types.StringType, "request_id": types.StringType, "share": basetypes.ListType{ - ElemType: ShareInfo{}.ToObjectType(ctx), + ElemType: ShareInfo{}.Type(ctx), }, "status": types.StringType, }, @@ -4349,13 +9429,60 @@ func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of UpdatePersonalizationRequestResponse in the Terraform plugin framework type -// system. -func (a UpdatePersonalizationRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePersonalizationRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request": basetypes.ListType{ - ElemType: PersonalizationRequest{}.ToObjectType(ctx), + ElemType: PersonalizationRequest{}.Type(ctx), }, }, } @@ -4387,9 +9514,56 @@ func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateProviderAnalyticsDashboardRequest in the Terraform plugin framework type -// system. -func (a UpdateProviderAnalyticsDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateProviderAnalyticsDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -4424,9 +9598,56 @@ func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateProviderAnalyticsDashboardResponse in the Terraform plugin framework type -// system. -func (a UpdateProviderAnalyticsDashboardResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateProviderAnalyticsDashboardResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateProviderAnalyticsDashboardResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -4461,14 +9682,61 @@ func (a UpdateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateProviderRequest in the Terraform plugin framework type -// system. -func (a UpdateProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateProviderRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } @@ -4497,14 +9765,63 @@ func (a UpdateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of UpdateProviderResponse in the Terraform plugin framework type -// system. -func (a UpdateProviderResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateProviderResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } } + +// Enums diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index e406758873..976dfbe65d 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -12,11 +12,15 @@ package ml_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) // Activity recorded for the action. @@ -92,9 +96,56 @@ func (a Activity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of Activity in the Terraform plugin framework type -// system. -func (a Activity) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Activity{} + +// Equal implements basetypes.ObjectValuable. +func (o Activity) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Activity) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Activity) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Activity) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Activity) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Activity) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Activity) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activity_type": types.StringType, @@ -149,9 +200,56 @@ func (a ApproveTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ApproveTransitionRequest in the Terraform plugin framework type -// system. -func (a ApproveTransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ApproveTransitionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ApproveTransitionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "archive_existing_versions": types.BoolType, @@ -187,13 +285,60 @@ func (a ApproveTransitionRequestResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of ApproveTransitionRequestResponse in the Terraform plugin framework type -// system. -func (a ApproveTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ApproveTransitionRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ApproveTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activity": basetypes.ListType{ - ElemType: Activity{}.ToObjectType(ctx), + ElemType: Activity{}.Type(ctx), }, }, } @@ -234,9 +379,56 @@ func (a CommentObject) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of CommentObject in the Terraform plugin framework type -// system. -func (a CommentObject) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CommentObject{} + +// Equal implements basetypes.ObjectValuable. +func (o CommentObject) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CommentObject) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CommentObject) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CommentObject) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CommentObject) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CommentObject) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CommentObject) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "available_actions": basetypes.ListType{ @@ -277,9 +469,56 @@ func (a CreateComment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateComment in the Terraform plugin framework type -// system. -func (a CreateComment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateComment{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateComment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateComment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateComment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateComment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateComment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateComment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateComment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -313,13 +552,60 @@ func (a CreateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateCommentResponse in the Terraform plugin framework type -// system. -func (a CreateCommentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCommentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCommentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCommentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCommentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCommentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCommentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCommentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": basetypes.ListType{ - ElemType: CommentObject{}.ToObjectType(ctx), + ElemType: CommentObject{}.Type(ctx), }, }, } @@ -358,15 +644,62 @@ func (a CreateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of CreateExperiment in the Terraform plugin framework type -// system. -func (a CreateExperiment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExperiment{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExperiment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExperiment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExperiment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExperiment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExperiment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ExperimentTag{}.ToObjectType(ctx), + ElemType: ExperimentTag{}.Type(ctx), }, }, } @@ -394,9 +727,56 @@ func (a CreateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateExperimentResponse in the Terraform plugin framework type -// system. -func (a CreateExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateExperimentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -432,15 +812,62 @@ func (a CreateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateModelRequest in the Terraform plugin framework type -// system. -func (a CreateModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelTag{}.ToObjectType(ctx), + ElemType: ModelTag{}.Type(ctx), }, }, } @@ -469,13 +896,60 @@ func (a CreateModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of CreateModelResponse in the Terraform plugin framework type -// system. -func (a CreateModelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateModelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateModelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateModelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateModelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateModelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model": basetypes.ListType{ - ElemType: Model{}.ToObjectType(ctx), + ElemType: Model{}.Type(ctx), }, }, } @@ -517,9 +991,56 @@ func (a CreateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of CreateModelVersionRequest in the Terraform plugin framework type -// system. -func (a CreateModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -528,7 +1049,7 @@ func (a CreateModelVersionRequest) ToObjectType(ctx context.Context) types.Objec "run_link": types.StringType, "source": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.ToObjectType(ctx), + ElemType: ModelVersionTag{}.Type(ctx), }, }, } @@ -558,13 +1079,60 @@ func (a CreateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of CreateModelVersionResponse in the Terraform plugin framework type -// system. -func (a CreateModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateModelVersionResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_version": basetypes.ListType{ - ElemType: ModelVersion{}.ToObjectType(ctx), + ElemType: ModelVersion{}.Type(ctx), }, }, } @@ -645,9 +1213,56 @@ func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateRegistryWebhook in the Terraform plugin framework type -// system. -func (a CreateRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRegistryWebhook{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -655,10 +1270,10 @@ func (a CreateRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectTyp ElemType: types.StringType, }, "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpec{}.ToObjectType(ctx), + ElemType: HttpUrlSpec{}.Type(ctx), }, "job_spec": basetypes.ListType{ - ElemType: JobSpec{}.ToObjectType(ctx), + ElemType: JobSpec{}.Type(ctx), }, "model_name": types.StringType, "status": types.StringType, @@ -698,15 +1313,62 @@ func (a CreateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of CreateRun in the Terraform plugin framework type -// system. -func (a CreateRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRun{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, "start_time": types.Int64Type, "tags": basetypes.ListType{ - ElemType: RunTag{}.ToObjectType(ctx), + ElemType: RunTag{}.Type(ctx), }, "user_id": types.StringType, }, @@ -737,13 +1399,60 @@ func (a CreateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of CreateRunResponse in the Terraform plugin framework type -// system. -func (a CreateRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run": basetypes.ListType{ - ElemType: Run{}.ToObjectType(ctx), + ElemType: Run{}.Type(ctx), }, }, } @@ -785,9 +1494,56 @@ func (a CreateTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateTransitionRequest in the Terraform plugin framework type -// system. -func (a CreateTransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateTransitionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateTransitionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -822,13 +1578,60 @@ func (a CreateTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of CreateTransitionRequestResponse in the Terraform plugin framework type -// system. -func (a CreateTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateTransitionRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "request": basetypes.ListType{ - ElemType: TransitionRequest{}.ToObjectType(ctx), + ElemType: TransitionRequest{}.Type(ctx), }, }, } @@ -857,13 +1660,60 @@ func (a CreateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateWebhookResponse in the Terraform plugin framework type -// system. -func (a CreateWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateWebhookResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateWebhookResponse) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "webhook": basetypes.ListType{ - ElemType: RegistryWebhook{}.ToObjectType(ctx), + ElemType: RegistryWebhook{}.Type(ctx), }, }, } @@ -909,9 +1759,56 @@ func (a Dataset) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of Dataset in the Terraform plugin framework type -// system. -func (a Dataset) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Dataset{} + +// Equal implements basetypes.ObjectValuable. +func (o Dataset) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Dataset) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Dataset) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Dataset) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Dataset) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Dataset) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Dataset) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "digest": types.StringType, @@ -952,16 +1849,63 @@ func (a DatasetInput) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of DatasetInput in the Terraform plugin framework type -// system. -func (a DatasetInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DatasetInput{} + +// Equal implements basetypes.ObjectValuable. +func (o DatasetInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DatasetInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DatasetInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DatasetInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DatasetInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DatasetInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DatasetInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset": basetypes.ListType{ - ElemType: Dataset{}.ToObjectType(ctx), + ElemType: Dataset{}.Type(ctx), }, "tags": basetypes.ListType{ - ElemType: InputTag{}.ToObjectType(ctx), + ElemType: InputTag{}.Type(ctx), }, }, } @@ -989,9 +1933,56 @@ func (a DeleteCommentRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCommentRequest in the Terraform plugin framework type -// system. -func (a DeleteCommentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCommentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCommentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1019,9 +2010,56 @@ func (a DeleteCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCommentResponse in the Terraform plugin framework type -// system. -func (a DeleteCommentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCommentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1049,9 +2087,56 @@ func (a DeleteExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExperiment in the Terraform plugin framework type -// system. -func (a DeleteExperiment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExperiment{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExperiment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExperiment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExperiment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExperiment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExperiment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -1079,9 +2164,56 @@ func (a DeleteExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteExperimentResponse in the Terraform plugin framework type -// system. -func (a DeleteExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteExperimentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1110,9 +2242,56 @@ func (a DeleteModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelRequest in the Terraform plugin framework type -// system. -func (a DeleteModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1140,9 +2319,56 @@ func (a DeleteModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelResponse in the Terraform plugin framework type -// system. -func (a DeleteModelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1174,9 +2400,56 @@ func (a DeleteModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelTagRequest in the Terraform plugin framework type -// system. -func (a DeleteModelTagRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelTagRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelTagRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1205,9 +2478,56 @@ func (a DeleteModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelTagResponse in the Terraform plugin framework type -// system. -func (a DeleteModelTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1238,9 +2558,56 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelVersionRequest in the Terraform plugin framework type -// system. -func (a DeleteModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1269,9 +2636,56 @@ func (a DeleteModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelVersionResponse in the Terraform plugin framework type -// system. -func (a DeleteModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelVersionResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1305,9 +2719,56 @@ func (a DeleteModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelVersionTagRequest in the Terraform plugin framework type -// system. -func (a DeleteModelVersionTagRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelVersionTagRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1337,9 +2798,56 @@ func (a DeleteModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteModelVersionTagResponse in the Terraform plugin framework type -// system. -func (a DeleteModelVersionTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteModelVersionTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteModelVersionTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1367,9 +2875,56 @@ func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRun in the Terraform plugin framework type -// system. -func (a DeleteRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRun{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.StringType, @@ -1397,9 +2952,56 @@ func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRunResponse in the Terraform plugin framework type -// system. -func (a DeleteRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1434,9 +3036,56 @@ func (a DeleteRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRuns in the Terraform plugin framework type -// system. -func (a DeleteRuns) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRuns{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRuns) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRuns) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRuns) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRuns) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRuns) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -1468,9 +3117,56 @@ func (a DeleteRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRunsResponse in the Terraform plugin framework type -// system. -func (a DeleteRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRunsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "runs_deleted": types.Int64Type, @@ -1502,9 +3198,56 @@ func (a DeleteTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteTag in the Terraform plugin framework type -// system. -func (a DeleteTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTag{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1533,9 +3276,56 @@ func (a DeleteTagResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteTagResponse in the Terraform plugin framework type -// system. -func (a DeleteTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1582,9 +3372,56 @@ func (a DeleteTransitionRequestRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteTransitionRequestRequest in the Terraform plugin framework type -// system. -func (a DeleteTransitionRequestRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTransitionRequestRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1616,9 +3453,56 @@ func (a DeleteTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteTransitionRequestResponse in the Terraform plugin framework type -// system. -func (a DeleteTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTransitionRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1647,9 +3531,56 @@ func (a DeleteWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWebhookRequest in the Terraform plugin framework type -// system. -func (a DeleteWebhookRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWebhookRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWebhookRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1677,9 +3608,56 @@ func (a DeleteWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWebhookResponse in the Terraform plugin framework type -// system. -func (a DeleteWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWebhookResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1722,9 +3700,56 @@ func (a Experiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of Experiment in the Terraform plugin framework type -// system. -func (a Experiment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Experiment{} + +// Equal implements basetypes.ObjectValuable. +func (o Experiment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Experiment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Experiment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Experiment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Experiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Experiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Experiment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, @@ -1734,7 +3759,7 @@ func (a Experiment) ToObjectType(ctx context.Context) types.ObjectType { "lifecycle_stage": types.StringType, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ExperimentTag{}.ToObjectType(ctx), + ElemType: ExperimentTag{}.Type(ctx), }, }, } @@ -1768,9 +3793,56 @@ func (a ExperimentAccessControlRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExperimentAccessControlRequest in the Terraform plugin framework type -// system. -func (a ExperimentAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1813,13 +3885,60 @@ func (a ExperimentAccessControlResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of ExperimentAccessControlResponse in the Terraform plugin framework type -// system. -func (a ExperimentAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ExperimentPermission{}.ToObjectType(ctx), + ElemType: ExperimentPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1856,9 +3975,56 @@ func (a ExperimentPermission) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ExperimentPermission in the Terraform plugin framework type -// system. -func (a ExperimentPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -1897,13 +4063,60 @@ func (a ExperimentPermissions) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ExperimentPermissions in the Terraform plugin framework type -// system. -func (a ExperimentPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ExperimentAccessControlResponse{}.ToObjectType(ctx), + ElemType: ExperimentAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -1934,9 +4147,56 @@ func (a ExperimentPermissionsDescription) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExperimentPermissionsDescription in the Terraform plugin framework type -// system. -func (a ExperimentPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1970,13 +4230,60 @@ func (a ExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ExperimentPermissionsRequest in the Terraform plugin framework type -// system. -func (a ExperimentPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ExperimentAccessControlRequest{}.ToObjectType(ctx), + ElemType: ExperimentAccessControlRequest{}.Type(ctx), }, "experiment_id": types.StringType, }, @@ -2007,9 +4314,56 @@ func (a ExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExperimentTag in the Terraform plugin framework type -// system. -func (a ExperimentTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExperimentTag{} + +// Equal implements basetypes.ObjectValuable. +func (o ExperimentTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExperimentTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExperimentTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExperimentTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExperimentTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExperimentTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExperimentTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2044,9 +4398,56 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of FileInfo in the Terraform plugin framework type -// system. -func (a FileInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FileInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o FileInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FileInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FileInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FileInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FileInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file_size": types.Int64Type, @@ -2079,9 +4480,56 @@ func (a GetByNameRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetByNameRequest in the Terraform plugin framework type -// system. -func (a GetByNameRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetByNameRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetByNameRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetByNameRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetByNameRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetByNameRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetByNameRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetByNameRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetByNameRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_name": types.StringType, @@ -2112,9 +4560,56 @@ func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetExperimentPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetExperimentPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExperimentPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -2146,13 +4641,60 @@ func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes(ctx context. } } -// ToObjectType returns the representation of GetExperimentPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetExperimentPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExperimentPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExperimentPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ExperimentPermissionsDescription{}.ToObjectType(ctx), + ElemType: ExperimentPermissionsDescription{}.Type(ctx), }, }, } @@ -2181,9 +4723,56 @@ func (a GetExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetExperimentPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetExperimentPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExperimentPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -2214,9 +4803,56 @@ func (a GetExperimentRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetExperimentRequest in the Terraform plugin framework type -// system. -func (a GetExperimentRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExperimentRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExperimentRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExperimentRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExperimentRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExperimentRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExperimentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExperimentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExperimentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -2248,13 +4884,60 @@ func (a GetExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of GetExperimentResponse in the Terraform plugin framework type -// system. -func (a GetExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetExperimentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetExperimentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetExperimentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetExperimentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetExperimentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment": basetypes.ListType{ - ElemType: Experiment{}.ToObjectType(ctx), + ElemType: Experiment{}.Type(ctx), }, }, } @@ -2294,9 +4977,56 @@ func (a GetHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetHistoryRequest in the Terraform plugin framework type -// system. -func (a GetHistoryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetHistoryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetHistoryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetHistoryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetHistoryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetHistoryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetHistoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetHistoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetHistoryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -2334,9 +5064,56 @@ func (a GetLatestVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of GetLatestVersionsRequest in the Terraform plugin framework type -// system. -func (a GetLatestVersionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetLatestVersionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetLatestVersionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2373,13 +5150,60 @@ func (a GetLatestVersionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of GetLatestVersionsResponse in the Terraform plugin framework type -// system. -func (a GetLatestVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetLatestVersionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetLatestVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToObjectType(ctx), + ElemType: ModelVersion{}.Type(ctx), }, }, } @@ -2412,13 +5236,60 @@ func (a GetMetricHistoryResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of GetMetricHistoryResponse in the Terraform plugin framework type -// system. -func (a GetMetricHistoryResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetMetricHistoryResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetMetricHistoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metrics": basetypes.ListType{ - ElemType: Metric{}.ToObjectType(ctx), + ElemType: Metric{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -2448,9 +5319,56 @@ func (a GetModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetModelRequest in the Terraform plugin framework type -// system. -func (a GetModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2481,13 +5399,60 @@ func (a GetModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of GetModelResponse in the Terraform plugin framework type -// system. -func (a GetModelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model_databricks": basetypes.ListType{ - ElemType: ModelDatabricks{}.ToObjectType(ctx), + ElemType: ModelDatabricks{}.Type(ctx), }, }, } @@ -2518,9 +5483,56 @@ func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetModelVersionDownloadUriRequest in the Terraform plugin framework type -// system. -func (a GetModelVersionDownloadUriRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelVersionDownloadUriRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2551,9 +5563,56 @@ func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetModelVersionDownloadUriResponse in the Terraform plugin framework type -// system. -func (a GetModelVersionDownloadUriResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelVersionDownloadUriResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelVersionDownloadUriResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_uri": types.StringType, @@ -2586,9 +5645,56 @@ func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetModelVersionRequest in the Terraform plugin framework type -// system. -func (a GetModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2620,13 +5726,60 @@ func (a GetModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of GetModelVersionResponse in the Terraform plugin framework type -// system. -func (a GetModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetModelVersionResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_version": basetypes.ListType{ - ElemType: ModelVersion{}.ToObjectType(ctx), + ElemType: ModelVersion{}.Type(ctx), }, }, } @@ -2655,9 +5808,56 @@ func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRegisteredModelPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetRegisteredModelPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRegisteredModelPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model_id": types.StringType, @@ -2689,13 +5889,60 @@ func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// ToObjectType returns the representation of GetRegisteredModelPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetRegisteredModelPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRegisteredModelPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: RegisteredModelPermissionsDescription{}.ToObjectType(ctx), + ElemType: RegisteredModelPermissionsDescription{}.Type(ctx), }, }, } @@ -2724,9 +5971,56 @@ func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRegisteredModelPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetRegisteredModelPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRegisteredModelPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model_id": types.StringType, @@ -2760,9 +6054,56 @@ func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRunRequest in the Terraform plugin framework type -// system. -func (a GetRunRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRunRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRunRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRunRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRunRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRunRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRunRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRunRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRunRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.StringType, @@ -2796,13 +6137,60 @@ func (a GetRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of GetRunResponse in the Terraform plugin framework type -// system. -func (a GetRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run": basetypes.ListType{ - ElemType: Run{}.ToObjectType(ctx), + ElemType: Run{}.Type(ctx), }, }, } @@ -2847,9 +6235,56 @@ func (a HttpUrlSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of HttpUrlSpec in the Terraform plugin framework type -// system. -func (a HttpUrlSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = HttpUrlSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o HttpUrlSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o HttpUrlSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o HttpUrlSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o HttpUrlSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o HttpUrlSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o HttpUrlSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o HttpUrlSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authorization": types.StringType, @@ -2890,9 +6325,56 @@ func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of HttpUrlSpecWithoutSecret in the Terraform plugin framework type -// system. -func (a HttpUrlSpecWithoutSecret) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = HttpUrlSpecWithoutSecret{} + +// Equal implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o HttpUrlSpecWithoutSecret) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enable_ssl_verification": types.BoolType, @@ -2925,9 +6407,56 @@ func (a InputTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of InputTag in the Terraform plugin framework type -// system. -func (a InputTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = InputTag{} + +// Equal implements basetypes.ObjectValuable. +func (o InputTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o InputTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o InputTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o InputTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o InputTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o InputTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o InputTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2964,9 +6493,56 @@ func (a JobSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobSpec in the Terraform plugin framework type -// system. -func (a JobSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o JobSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_token": types.StringType, @@ -3002,9 +6578,56 @@ func (a JobSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of JobSpecWithoutSecret in the Terraform plugin framework type -// system. -func (a JobSpecWithoutSecret) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = JobSpecWithoutSecret{} + +// Equal implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o JobSpecWithoutSecret) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_id": types.StringType, @@ -3049,9 +6672,56 @@ func (a ListArtifactsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListArtifactsRequest in the Terraform plugin framework type -// system. -func (a ListArtifactsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListArtifactsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListArtifactsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -3090,13 +6760,60 @@ func (a ListArtifactsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListArtifactsResponse in the Terraform plugin framework type -// system. -func (a ListArtifactsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListArtifactsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListArtifactsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "files": basetypes.ListType{ - ElemType: FileInfo{}.ToObjectType(ctx), + ElemType: FileInfo{}.Type(ctx), }, "next_page_token": types.StringType, "root_uri": types.StringType, @@ -3136,9 +6853,56 @@ func (a ListExperimentsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListExperimentsRequest in the Terraform plugin framework type -// system. -func (a ListExperimentsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExperimentsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExperimentsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -3176,13 +6940,60 @@ func (a ListExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ListExperimentsResponse in the Terraform plugin framework type -// system. -func (a ListExperimentsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListExperimentsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiments": basetypes.ListType{ - ElemType: Experiment{}.ToObjectType(ctx), + ElemType: Experiment{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -3214,9 +7025,56 @@ func (a ListModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListModelsRequest in the Terraform plugin framework type -// system. -func (a ListModelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListModelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListModelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListModelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListModelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListModelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListModelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListModelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListModelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -3251,14 +7109,61 @@ func (a ListModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListModelsResponse in the Terraform plugin framework type -// system. -func (a ListModelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListModelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListModelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListModelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListModelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListModelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListModelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListModelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "registered_models": basetypes.ListType{ - ElemType: Model{}.ToObjectType(ctx), + ElemType: Model{}.Type(ctx), }, }, } @@ -3290,14 +7195,61 @@ func (a ListRegistryWebhooks) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListRegistryWebhooks in the Terraform plugin framework type -// system. -func (a ListRegistryWebhooks) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRegistryWebhooks{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRegistryWebhooks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "webhooks": basetypes.ListType{ - ElemType: RegistryWebhook{}.ToObjectType(ctx), + ElemType: RegistryWebhook{}.Type(ctx), }, }, } @@ -3328,9 +7280,56 @@ func (a ListTransitionRequestsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListTransitionRequestsRequest in the Terraform plugin framework type -// system. -func (a ListTransitionRequestsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTransitionRequestsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTransitionRequestsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -3363,13 +7362,60 @@ func (a ListTransitionRequestsResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of ListTransitionRequestsResponse in the Terraform plugin framework type -// system. -func (a ListTransitionRequestsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTransitionRequestsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTransitionRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "requests": basetypes.ListType{ - ElemType: Activity{}.ToObjectType(ctx), + ElemType: Activity{}.Type(ctx), }, }, } @@ -3407,9 +7453,56 @@ func (a ListWebhooksRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListWebhooksRequest in the Terraform plugin framework type -// system. -func (a ListWebhooksRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListWebhooksRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListWebhooksRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "events": basetypes.ListType{ @@ -3456,20 +7549,67 @@ func (a LogBatch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of LogBatch in the Terraform plugin framework type -// system. -func (a LogBatch) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogBatch{} + +// Equal implements basetypes.ObjectValuable. +func (o LogBatch) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogBatch) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogBatch) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogBatch) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogBatch) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogBatch) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogBatch) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metrics": basetypes.ListType{ - ElemType: Metric{}.ToObjectType(ctx), + ElemType: Metric{}.Type(ctx), }, "params": basetypes.ListType{ - ElemType: Param{}.ToObjectType(ctx), + ElemType: Param{}.Type(ctx), }, "run_id": types.StringType, "tags": basetypes.ListType{ - ElemType: RunTag{}.ToObjectType(ctx), + ElemType: RunTag{}.Type(ctx), }, }, } @@ -3495,9 +7635,56 @@ func (a LogBatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogBatchResponse in the Terraform plugin framework type -// system. -func (a LogBatchResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogBatchResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o LogBatchResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogBatchResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogBatchResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogBatchResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogBatchResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogBatchResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogBatchResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3529,13 +7716,60 @@ func (a LogInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of LogInputs in the Terraform plugin framework type -// system. -func (a LogInputs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogInputs{} + +// Equal implements basetypes.ObjectValuable. +func (o LogInputs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogInputs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogInputs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogInputs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogInputs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogInputs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "datasets": basetypes.ListType{ - ElemType: DatasetInput{}.ToObjectType(ctx), + ElemType: DatasetInput{}.Type(ctx), }, "run_id": types.StringType, }, @@ -3562,9 +7796,56 @@ func (a LogInputsResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogInputsResponse in the Terraform plugin framework type -// system. -func (a LogInputsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogInputsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o LogInputsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogInputsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogInputsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogInputsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogInputsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogInputsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogInputsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3603,9 +7884,56 @@ func (a LogMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogMetric in the Terraform plugin framework type -// system. -func (a LogMetric) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogMetric{} + +// Equal implements basetypes.ObjectValuable. +func (o LogMetric) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogMetric) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogMetric) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogMetric) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogMetric) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogMetric) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogMetric) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -3638,9 +7966,56 @@ func (a LogMetricResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogMetricResponse in the Terraform plugin framework type -// system. -func (a LogMetricResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogMetricResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o LogMetricResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogMetricResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogMetricResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogMetricResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogMetricResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogMetricResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogMetricResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3670,9 +8045,56 @@ func (a LogModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogModel in the Terraform plugin framework type -// system. -func (a LogModel) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogModel{} + +// Equal implements basetypes.ObjectValuable. +func (o LogModel) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogModel) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogModel) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogModel) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogModel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogModel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogModel) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_json": types.StringType, @@ -3701,9 +8123,56 @@ func (a LogModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogModelResponse in the Terraform plugin framework type -// system. -func (a LogModelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogModelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o LogModelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogModelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogModelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogModelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3738,9 +8207,56 @@ func (a LogParam) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogParam in the Terraform plugin framework type -// system. -func (a LogParam) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogParam{} + +// Equal implements basetypes.ObjectValuable. +func (o LogParam) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogParam) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogParam) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogParam) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogParam) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogParam) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogParam) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -3771,9 +8287,56 @@ func (a LogParamResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogParamResponse in the Terraform plugin framework type -// system. -func (a LogParamResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogParamResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o LogParamResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogParamResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogParamResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogParamResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogParamResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogParamResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogParamResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -3807,9 +8370,56 @@ func (a Metric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Metric in the Terraform plugin framework type -// system. -func (a Metric) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Metric{} + +// Equal implements basetypes.ObjectValuable. +func (o Metric) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Metric) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Metric) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Metric) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Metric) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Metric) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Metric) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -3859,20 +8469,67 @@ func (a Model) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of Model in the Terraform plugin framework type -// system. -func (a Model) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Model{} + +// Equal implements basetypes.ObjectValuable. +func (o Model) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Model) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Model) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Model) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Model) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Model) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Model) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, "description": types.StringType, "last_updated_timestamp": types.Int64Type, "latest_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToObjectType(ctx), + ElemType: ModelVersion{}.Type(ctx), }, "name": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelTag{}.ToObjectType(ctx), + ElemType: ModelTag{}.Type(ctx), }, "user_id": types.StringType, }, @@ -3921,9 +8578,56 @@ func (a ModelDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of ModelDatabricks in the Terraform plugin framework type -// system. -func (a ModelDatabricks) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelDatabricks{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelDatabricks) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelDatabricks) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelDatabricks) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelDatabricks) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelDatabricks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelDatabricks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelDatabricks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -3931,12 +8635,12 @@ func (a ModelDatabricks) ToObjectType(ctx context.Context) types.ObjectType { "id": types.StringType, "last_updated_timestamp": types.Int64Type, "latest_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToObjectType(ctx), + ElemType: ModelVersion{}.Type(ctx), }, "name": types.StringType, "permission_level": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelTag{}.ToObjectType(ctx), + ElemType: ModelTag{}.Type(ctx), }, "user_id": types.StringType, }, @@ -3967,9 +8671,56 @@ func (a ModelTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// ToObjectType returns the representation of ModelTag in the Terraform plugin framework type -// system. -func (a ModelTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelTag{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -4029,9 +8780,56 @@ func (a ModelVersion) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ModelVersion in the Terraform plugin framework type -// system. -func (a ModelVersion) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelVersion{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelVersion) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelVersion) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelVersion) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelVersion) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelVersion) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelVersion) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelVersion) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -4045,7 +8843,7 @@ func (a ModelVersion) ToObjectType(ctx context.Context) types.ObjectType { "status": types.StringType, "status_message": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.ToObjectType(ctx), + ElemType: ModelVersionTag{}.Type(ctx), }, "user_id": types.StringType, "version": types.StringType, @@ -4123,9 +8921,56 @@ func (a ModelVersionDatabricks) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ModelVersionDatabricks in the Terraform plugin framework type -// system. -func (a ModelVersionDatabricks) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelVersionDatabricks{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelVersionDatabricks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -4140,7 +8985,7 @@ func (a ModelVersionDatabricks) ToObjectType(ctx context.Context) types.ObjectTy "status": types.StringType, "status_message": types.StringType, "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.ToObjectType(ctx), + ElemType: ModelVersionTag{}.Type(ctx), }, "user_id": types.StringType, "version": types.StringType, @@ -4172,9 +9017,56 @@ func (a ModelVersionTag) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ModelVersionTag in the Terraform plugin framework type -// system. -func (a ModelVersionTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelVersionTag{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelVersionTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelVersionTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelVersionTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelVersionTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelVersionTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelVersionTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelVersionTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -4207,9 +9099,56 @@ func (a Param) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Param in the Terraform plugin framework type -// system. -func (a Param) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Param{} + +// Equal implements basetypes.ObjectValuable. +func (o Param) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Param) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Param) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Param) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Param) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Param) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Param) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -4246,9 +9185,56 @@ func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of RegisteredModelAccessControlRequest in the Terraform plugin framework type -// system. -func (a RegisteredModelAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -4291,13 +9277,60 @@ func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of RegisteredModelAccessControlResponse in the Terraform plugin framework type -// system. -func (a RegisteredModelAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: RegisteredModelPermission{}.ToObjectType(ctx), + ElemType: RegisteredModelPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -4334,9 +9367,56 @@ func (a RegisteredModelPermission) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of RegisteredModelPermission in the Terraform plugin framework type -// system. -func (a RegisteredModelPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -4375,13 +9455,60 @@ func (a RegisteredModelPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of RegisteredModelPermissions in the Terraform plugin framework type -// system. -func (a RegisteredModelPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RegisteredModelAccessControlResponse{}.ToObjectType(ctx), + ElemType: RegisteredModelAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -4412,9 +9539,56 @@ func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of RegisteredModelPermissionsDescription in the Terraform plugin framework type -// system. -func (a RegisteredModelPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -4448,13 +9622,60 @@ func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of RegisteredModelPermissionsRequest in the Terraform plugin framework type -// system. -func (a RegisteredModelPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegisteredModelPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RegisteredModelAccessControlRequest{}.ToObjectType(ctx), + ElemType: RegisteredModelAccessControlRequest{}.Type(ctx), }, "registered_model_id": types.StringType, }, @@ -4542,9 +9763,56 @@ func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of RegistryWebhook in the Terraform plugin framework type -// system. -func (a RegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RegistryWebhook{} + +// Equal implements basetypes.ObjectValuable. +func (o RegistryWebhook) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RegistryWebhook) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RegistryWebhook) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RegistryWebhook) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -4553,11 +9821,11 @@ func (a RegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpecWithoutSecret{}.ToObjectType(ctx), + ElemType: HttpUrlSpecWithoutSecret{}.Type(ctx), }, "id": types.StringType, "job_spec": basetypes.ListType{ - ElemType: JobSpecWithoutSecret{}.ToObjectType(ctx), + ElemType: JobSpecWithoutSecret{}.Type(ctx), }, "last_updated_timestamp": types.Int64Type, "model_name": types.StringType, @@ -4602,9 +9870,56 @@ func (a RejectTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of RejectTransitionRequest in the Terraform plugin framework type -// system. -func (a RejectTransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RejectTransitionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RejectTransitionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4639,13 +9954,60 @@ func (a RejectTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of RejectTransitionRequestResponse in the Terraform plugin framework type -// system. -func (a RejectTransitionRequestResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RejectTransitionRequestResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RejectTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activity": basetypes.ListType{ - ElemType: Activity{}.ToObjectType(ctx), + ElemType: Activity{}.Type(ctx), }, }, } @@ -4675,9 +10037,56 @@ func (a RenameModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of RenameModelRequest in the Terraform plugin framework type -// system. -func (a RenameModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RenameModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RenameModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RenameModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RenameModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RenameModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RenameModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RenameModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RenameModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -4709,13 +10118,60 @@ func (a RenameModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of RenameModelResponse in the Terraform plugin framework type -// system. -func (a RenameModelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RenameModelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RenameModelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RenameModelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RenameModelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RenameModelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RenameModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RenameModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RenameModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "registered_model": basetypes.ListType{ - ElemType: Model{}.ToObjectType(ctx), + ElemType: Model{}.Type(ctx), }, }, } @@ -4743,9 +10199,56 @@ func (a RestoreExperiment) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreExperiment in the Terraform plugin framework type -// system. -func (a RestoreExperiment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreExperiment{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreExperiment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreExperiment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreExperiment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreExperiment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreExperiment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -4773,9 +10276,56 @@ func (a RestoreExperimentResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreExperimentResponse in the Terraform plugin framework type -// system. -func (a RestoreExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreExperimentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4803,9 +10353,56 @@ func (a RestoreRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreRun in the Terraform plugin framework type -// system. -func (a RestoreRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreRun{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_id": types.StringType, @@ -4833,9 +10430,56 @@ func (a RestoreRunResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreRunResponse in the Terraform plugin framework type -// system. -func (a RestoreRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4870,9 +10514,56 @@ func (a RestoreRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreRuns in the Terraform plugin framework type -// system. -func (a RestoreRuns) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreRuns{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreRuns) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreRuns) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreRuns) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreRuns) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreRuns) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -4904,9 +10595,56 @@ func (a RestoreRunsResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreRunsResponse in the Terraform plugin framework type -// system. -func (a RestoreRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreRunsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "runs_restored": types.Int64Type, @@ -4944,19 +10682,66 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// ToObjectType returns the representation of Run in the Terraform plugin framework type -// system. -func (a Run) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Run{} + +// Equal implements basetypes.ObjectValuable. +func (o Run) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Run) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Run) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Run) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Run) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Run) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data": basetypes.ListType{ - ElemType: RunData{}.ToObjectType(ctx), + ElemType: RunData{}.Type(ctx), }, "info": basetypes.ListType{ - ElemType: RunInfo{}.ToObjectType(ctx), + ElemType: RunInfo{}.Type(ctx), }, "inputs": basetypes.ListType{ - ElemType: RunInputs{}.ToObjectType(ctx), + ElemType: RunInputs{}.Type(ctx), }, }, } @@ -4992,19 +10777,66 @@ func (a RunData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of RunData in the Terraform plugin framework type -// system. -func (a RunData) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunData{} + +// Equal implements basetypes.ObjectValuable. +func (o RunData) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunData) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunData) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunData) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunData) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunData) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "metrics": basetypes.ListType{ - ElemType: Metric{}.ToObjectType(ctx), + ElemType: Metric{}.Type(ctx), }, "params": basetypes.ListType{ - ElemType: Param{}.ToObjectType(ctx), + ElemType: Param{}.Type(ctx), }, "tags": basetypes.ListType{ - ElemType: RunTag{}.ToObjectType(ctx), + ElemType: RunTag{}.Type(ctx), }, }, } @@ -5054,9 +10886,56 @@ func (a RunInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunInfo in the Terraform plugin framework type -// system. -func (a RunInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RunInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "artifact_uri": types.StringType, @@ -5096,13 +10975,60 @@ func (a RunInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of RunInputs in the Terraform plugin framework type -// system. -func (a RunInputs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunInputs{} + +// Equal implements basetypes.ObjectValuable. +func (o RunInputs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunInputs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunInputs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunInputs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunInputs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunInputs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset_inputs": basetypes.ListType{ - ElemType: DatasetInput{}.ToObjectType(ctx), + ElemType: DatasetInput{}.Type(ctx), }, }, } @@ -5132,9 +11058,56 @@ func (a RunTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of RunTag in the Terraform plugin framework type -// system. -func (a RunTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RunTag{} + +// Equal implements basetypes.ObjectValuable. +func (o RunTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RunTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RunTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RunTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RunTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RunTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RunTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5180,9 +11153,56 @@ func (a SearchExperiments) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of SearchExperiments in the Terraform plugin framework type -// system. -func (a SearchExperiments) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchExperiments{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchExperiments) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchExperiments) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchExperiments) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchExperiments) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchExperiments) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchExperiments) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchExperiments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -5223,13 +11243,60 @@ func (a SearchExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of SearchExperimentsResponse in the Terraform plugin framework type -// system. -func (a SearchExperimentsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchExperimentsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiments": basetypes.ListType{ - ElemType: Experiment{}.ToObjectType(ctx), + ElemType: Experiment{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -5271,9 +11338,56 @@ func (a SearchModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of SearchModelVersionsRequest in the Terraform plugin framework type -// system. -func (a SearchModelVersionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchModelVersionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchModelVersionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -5313,13 +11427,60 @@ func (a SearchModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of SearchModelVersionsResponse in the Terraform plugin framework type -// system. -func (a SearchModelVersionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchModelVersionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_versions": basetypes.ListType{ - ElemType: ModelVersion{}.ToObjectType(ctx), + ElemType: ModelVersion{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -5361,9 +11522,56 @@ func (a SearchModelsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of SearchModelsRequest in the Terraform plugin framework type -// system. -func (a SearchModelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchModelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchModelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchModelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchModelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchModelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchModelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchModelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchModelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -5402,14 +11610,61 @@ func (a SearchModelsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of SearchModelsResponse in the Terraform plugin framework type -// system. -func (a SearchModelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchModelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchModelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchModelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchModelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchModelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchModelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchModelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "registered_models": basetypes.ListType{ - ElemType: Model{}.ToObjectType(ctx), + ElemType: Model{}.Type(ctx), }, }, } @@ -5467,9 +11722,56 @@ func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of SearchRuns in the Terraform plugin framework type -// system. -func (a SearchRuns) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchRuns{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchRuns) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchRuns) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchRuns) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchRuns) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchRuns) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_ids": basetypes.ListType{ @@ -5512,14 +11814,61 @@ func (a SearchRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of SearchRunsResponse in the Terraform plugin framework type -// system. -func (a SearchRunsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SearchRunsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SearchRunsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SearchRunsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SearchRunsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SearchRunsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SearchRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SearchRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SearchRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "runs": basetypes.ListType{ - ElemType: Run{}.ToObjectType(ctx), + ElemType: Run{}.Type(ctx), }, }, } @@ -5554,9 +11903,56 @@ func (a SetExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetExperimentTag in the Terraform plugin framework type -// system. -func (a SetExperimentTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetExperimentTag{} + +// Equal implements basetypes.ObjectValuable. +func (o SetExperimentTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetExperimentTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetExperimentTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetExperimentTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetExperimentTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetExperimentTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetExperimentTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -5586,9 +11982,56 @@ func (a SetExperimentTagResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetExperimentTagResponse in the Terraform plugin framework type -// system. -func (a SetExperimentTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetExperimentTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetExperimentTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5625,9 +12068,56 @@ func (a SetModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetModelTagRequest in the Terraform plugin framework type -// system. -func (a SetModelTagRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetModelTagRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SetModelTagRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetModelTagRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetModelTagRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetModelTagRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetModelTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetModelTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetModelTagRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5657,9 +12147,56 @@ func (a SetModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetModelTagResponse in the Terraform plugin framework type -// system. -func (a SetModelTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetModelTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetModelTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetModelTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetModelTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetModelTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetModelTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetModelTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetModelTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5698,9 +12235,56 @@ func (a SetModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetModelVersionTagRequest in the Terraform plugin framework type -// system. -func (a SetModelVersionTagRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetModelVersionTagRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetModelVersionTagRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5731,9 +12315,56 @@ func (a SetModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetModelVersionTagResponse in the Terraform plugin framework type -// system. -func (a SetModelVersionTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetModelVersionTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetModelVersionTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5771,9 +12402,56 @@ func (a SetTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetTag in the Terraform plugin framework type -// system. -func (a SetTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetTag{} + +// Equal implements basetypes.ObjectValuable. +func (o SetTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -5804,9 +12482,56 @@ func (a SetTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetTagResponse in the Terraform plugin framework type -// system. -func (a SetTagResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetTagResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetTagResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetTagResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetTagResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetTagResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetTagResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5837,9 +12562,56 @@ func (a TestRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of TestRegistryWebhook in the Terraform plugin framework type -// system. -func (a TestRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TestRegistryWebhook{} + +// Equal implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TestRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "body": types.StringType, @@ -5874,9 +12646,56 @@ func (a TestRegistryWebhookRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of TestRegistryWebhookRequest in the Terraform plugin framework type -// system. -func (a TestRegistryWebhookRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TestRegistryWebhookRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TestRegistryWebhookRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "event": types.StringType, @@ -5909,13 +12728,60 @@ func (a TestRegistryWebhookResponse) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of TestRegistryWebhookResponse in the Terraform plugin framework type -// system. -func (a TestRegistryWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TestRegistryWebhookResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TestRegistryWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "webhook": basetypes.ListType{ - ElemType: TestRegistryWebhook{}.ToObjectType(ctx), + ElemType: TestRegistryWebhook{}.Type(ctx), }, }, } @@ -5960,9 +12826,56 @@ func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of TransitionModelVersionStageDatabricks in the Terraform plugin framework type -// system. -func (a TransitionModelVersionStageDatabricks) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TransitionModelVersionStageDatabricks{} + +// Equal implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TransitionModelVersionStageDatabricks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "archive_existing_versions": types.BoolType, @@ -6016,9 +12929,56 @@ func (a TransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of TransitionRequest in the Terraform plugin framework type -// system. -func (a TransitionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TransitionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TransitionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TransitionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TransitionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TransitionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TransitionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "available_actions": basetypes.ListType{ @@ -6055,13 +13015,60 @@ func (a TransitionStageResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of TransitionStageResponse in the Terraform plugin framework type -// system. -func (a TransitionStageResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TransitionStageResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o TransitionStageResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TransitionStageResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TransitionStageResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TransitionStageResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TransitionStageResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TransitionStageResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TransitionStageResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_version": basetypes.ListType{ - ElemType: ModelVersionDatabricks{}.ToObjectType(ctx), + ElemType: ModelVersionDatabricks{}.Type(ctx), }, }, } @@ -6091,9 +13098,56 @@ func (a UpdateComment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateComment in the Terraform plugin framework type -// system. -func (a UpdateComment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateComment{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateComment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateComment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateComment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateComment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateComment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateComment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateComment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -6126,13 +13180,60 @@ func (a UpdateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateCommentResponse in the Terraform plugin framework type -// system. -func (a UpdateCommentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCommentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": basetypes.ListType{ - ElemType: CommentObject{}.ToObjectType(ctx), + ElemType: CommentObject{}.Type(ctx), }, }, } @@ -6163,9 +13264,56 @@ func (a UpdateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateExperiment in the Terraform plugin framework type -// system. -func (a UpdateExperiment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExperiment{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExperiment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExperiment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExperiment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExperiment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExperiment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, @@ -6194,9 +13342,56 @@ func (a UpdateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateExperimentResponse in the Terraform plugin framework type -// system. -func (a UpdateExperimentResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateExperimentResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6226,9 +13421,56 @@ func (a UpdateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateModelRequest in the Terraform plugin framework type -// system. -func (a UpdateModelRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateModelRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateModelRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateModelRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateModelRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateModelRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateModelRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6257,9 +13499,56 @@ func (a UpdateModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateModelResponse in the Terraform plugin framework type -// system. -func (a UpdateModelResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateModelResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateModelResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateModelResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateModelResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateModelResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6291,9 +13580,56 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateModelVersionRequest in the Terraform plugin framework type -// system. -func (a UpdateModelVersionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateModelVersionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateModelVersionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6323,9 +13659,56 @@ func (a UpdateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateModelVersionResponse in the Terraform plugin framework type -// system. -func (a UpdateModelVersionResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateModelVersionResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6406,9 +13789,56 @@ func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of UpdateRegistryWebhook in the Terraform plugin framework type -// system. -func (a UpdateRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRegistryWebhook{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -6416,11 +13846,11 @@ func (a UpdateRegistryWebhook) ToObjectType(ctx context.Context) types.ObjectTyp ElemType: types.StringType, }, "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpec{}.ToObjectType(ctx), + ElemType: HttpUrlSpec{}.Type(ctx), }, "id": types.StringType, "job_spec": basetypes.ListType{ - ElemType: JobSpec{}.ToObjectType(ctx), + ElemType: JobSpec{}.Type(ctx), }, "status": types.StringType, }, @@ -6456,9 +13886,56 @@ func (a UpdateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateRun in the Terraform plugin framework type -// system. -func (a UpdateRun) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRun{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRun) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRun) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRun) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRun) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time": types.Int64Type, @@ -6493,13 +13970,60 @@ func (a UpdateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of UpdateRunResponse in the Terraform plugin framework type -// system. -func (a UpdateRunResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRunResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRunResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRunResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRunResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRunResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_info": basetypes.ListType{ - ElemType: RunInfo{}.ToObjectType(ctx), + ElemType: RunInfo{}.Type(ctx), }, }, } @@ -6525,10 +14049,130 @@ func (a UpdateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateWebhookResponse in the Terraform plugin framework type -// system. -func (a UpdateWebhookResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateWebhookResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } } + +// An action that a user (with sufficient permissions) could take on an +// activity. Valid values are: * `APPROVE_TRANSITION_REQUEST`: Approve a +// transition request +// +// * `REJECT_TRANSITION_REQUEST`: Reject a transition request +// +// * `CANCEL_TRANSITION_REQUEST`: Cancel (delete) a transition request + +// Type of activity. Valid values are: * `APPLIED_TRANSITION`: User applied the +// corresponding stage transition. +// +// * `REQUESTED_TRANSITION`: User requested the corresponding stage transition. +// +// * `CANCELLED_REQUEST`: User cancelled an existing transition request. +// +// * `APPROVED_REQUEST`: User approved the corresponding stage transition. +// +// * `REJECTED_REQUEST`: User rejected the coressponding stage transition. +// +// * `SYSTEM_TRANSITION`: For events performed as a side effect, such as +// archiving existing model versions in a stage. + +// An action that a user (with sufficient permissions) could take on a comment. +// Valid values are: * `EDIT_COMMENT`: Edit the comment +// +// * `DELETE_COMMENT`: Delete the comment + +// Permission level + +// Current status of `model_version` + +// Permission level of the requesting user on the object. For what is allowed at +// each level, see [MLflow Model permissions](..). + +// Permission level + +// Enable or disable triggering the webhook, or put the webhook into test mode. +// The default is `ACTIVE`: * `ACTIVE`: Webhook is triggered when an associated +// event happens. +// +// * `DISABLED`: Webhook is not triggered. +// +// * `TEST_MODE`: Webhook can be triggered through the test endpoint, but is not +// triggered on a real event. + +// Current status of the run. + +// Qualifier for type of experiments to be returned. If unspecified, return only +// active experiments. + +// Whether to display only active, only deleted, or all runs. Defaults to only +// active runs. + +// Stage of the model version. Valid values are: +// +// * `None`: The initial stage of a model version. +// +// * `Staging`: Staging or pre-production stage. +// +// * `Production`: Production stage. +// +// * `Archived`: Archived stage. + +// The status of the model version. Valid values are: * `PENDING_REGISTRATION`: +// Request to register a new model version is pending as server performs +// background tasks. +// +// * `FAILED_REGISTRATION`: Request to register a new model version has failed. +// +// * `READY`: Model version is ready for use. + +// Updated status of the run. diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 53448032dd..71d3187bed 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -12,11 +12,15 @@ package oauth2_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type CreateCustomAppIntegration struct { @@ -55,9 +59,56 @@ func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of CreateCustomAppIntegration in the Terraform plugin framework type -// system. -func (a CreateCustomAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCustomAppIntegration{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "confidential": types.BoolType, @@ -69,7 +120,7 @@ func (a CreateCustomAppIntegration) ToObjectType(ctx context.Context) types.Obje ElemType: types.StringType, }, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToObjectType(ctx), + ElemType: TokenAccessPolicy{}.Type(ctx), }, }, } @@ -102,9 +153,56 @@ func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateCustomAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a CreateCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCustomAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "client_id": types.StringType, @@ -141,14 +239,61 @@ func (a CreatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of CreatePublishedAppIntegration in the Terraform plugin framework type -// system. -func (a CreatePublishedAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePublishedAppIntegration{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_id": types.StringType, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToObjectType(ctx), + ElemType: TokenAccessPolicy{}.Type(ctx), }, }, } @@ -176,9 +321,56 @@ func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreatePublishedAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a CreatePublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePublishedAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -209,9 +401,56 @@ func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateServicePrincipalSecretRequest in the Terraform plugin framework type -// system. -func (a CreateServicePrincipalSecretRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateServicePrincipalSecretRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "service_principal_id": types.Int64Type, @@ -251,9 +490,56 @@ func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateServicePrincipalSecretResponse in the Terraform plugin framework type -// system. -func (a CreateServicePrincipalSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateServicePrincipalSecretResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateServicePrincipalSecretResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -290,9 +576,56 @@ func (a DataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of DataPlaneInfo in the Terraform plugin framework type -// system. -func (a DataPlaneInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DataPlaneInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o DataPlaneInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DataPlaneInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DataPlaneInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DataPlaneInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DataPlaneInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DataPlaneInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DataPlaneInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authorization_details": types.StringType, @@ -321,9 +654,56 @@ func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCustomAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a DeleteCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCustomAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -351,9 +731,56 @@ func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCustomAppIntegrationRequest in the Terraform plugin framework type -// system. -func (a DeleteCustomAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCustomAppIntegrationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCustomAppIntegrationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -381,9 +808,56 @@ func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePublishedAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a DeletePublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePublishedAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -411,9 +885,56 @@ func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePublishedAppIntegrationRequest in the Terraform plugin framework type -// system. -func (a DeletePublishedAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePublishedAppIntegrationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePublishedAppIntegrationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -441,9 +962,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -474,9 +1042,56 @@ func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteServicePrincipalSecretRequest in the Terraform plugin framework type -// system. -func (a DeleteServicePrincipalSecretRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteServicePrincipalSecretRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteServicePrincipalSecretRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "secret_id": types.StringType, @@ -530,9 +1145,56 @@ func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of GetCustomAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a GetCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCustomAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "client_id": types.StringType, @@ -549,7 +1211,7 @@ func (a GetCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.O ElemType: types.StringType, }, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToObjectType(ctx), + ElemType: TokenAccessPolicy{}.Type(ctx), }, }, } @@ -578,9 +1240,56 @@ func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCustomAppIntegrationRequest in the Terraform plugin framework type -// system. -func (a GetCustomAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCustomAppIntegrationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -614,13 +1323,60 @@ func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of GetCustomAppIntegrationsOutput in the Terraform plugin framework type -// system. -func (a GetCustomAppIntegrationsOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCustomAppIntegrationsOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCustomAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: GetCustomAppIntegrationOutput{}.ToObjectType(ctx), + ElemType: GetCustomAppIntegrationOutput{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -661,9 +1417,56 @@ func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of GetPublishedAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a GetPublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPublishedAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_id": types.StringType, @@ -672,7 +1475,7 @@ func (a GetPublishedAppIntegrationOutput) ToObjectType(ctx context.Context) type "integration_id": types.StringType, "name": types.StringType, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToObjectType(ctx), + ElemType: TokenAccessPolicy{}.Type(ctx), }, }, } @@ -700,9 +1503,56 @@ func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPublishedAppIntegrationRequest in the Terraform plugin framework type -// system. -func (a GetPublishedAppIntegrationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPublishedAppIntegrationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -736,13 +1586,60 @@ func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of GetPublishedAppIntegrationsOutput in the Terraform plugin framework type -// system. -func (a GetPublishedAppIntegrationsOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPublishedAppIntegrationsOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPublishedAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: GetPublishedAppIntegrationOutput{}.ToObjectType(ctx), + ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -776,13 +1673,60 @@ func (a GetPublishedAppsOutput) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of GetPublishedAppsOutput in the Terraform plugin framework type -// system. -func (a GetPublishedAppsOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPublishedAppsOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPublishedAppsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apps": basetypes.ListType{ - ElemType: PublishedAppOutput{}.ToObjectType(ctx), + ElemType: PublishedAppOutput{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -815,9 +1759,56 @@ func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListCustomAppIntegrationsRequest in the Terraform plugin framework type -// system. -func (a ListCustomAppIntegrationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListCustomAppIntegrationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListCustomAppIntegrationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_creator_username": types.BoolType, @@ -852,9 +1843,56 @@ func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListOAuthPublishedAppsRequest in the Terraform plugin framework type -// system. -func (a ListOAuthPublishedAppsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListOAuthPublishedAppsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListOAuthPublishedAppsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -887,9 +1925,56 @@ func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListPublishedAppIntegrationsRequest in the Terraform plugin framework type -// system. -func (a ListPublishedAppIntegrationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPublishedAppIntegrationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPublishedAppIntegrationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -931,9 +2016,56 @@ func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListServicePrincipalSecretsRequest in the Terraform plugin framework type -// system. -func (a ListServicePrincipalSecretsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListServicePrincipalSecretsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -968,14 +2100,61 @@ func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes(ctx context.Co } } -// ToObjectType returns the representation of ListServicePrincipalSecretsResponse in the Terraform plugin framework type -// system. -func (a ListServicePrincipalSecretsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListServicePrincipalSecretsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListServicePrincipalSecretsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "secrets": basetypes.ListType{ - ElemType: SecretInfo{}.ToObjectType(ctx), + ElemType: SecretInfo{}.Type(ctx), }, }, } @@ -1020,9 +2199,56 @@ func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of PublishedAppOutput in the Terraform plugin framework type -// system. -func (a PublishedAppOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PublishedAppOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o PublishedAppOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PublishedAppOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PublishedAppOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PublishedAppOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PublishedAppOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PublishedAppOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PublishedAppOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "app_id": types.StringType, @@ -1070,9 +2296,56 @@ func (a SecretInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of SecretInfo in the Terraform plugin framework type -// system. -func (a SecretInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SecretInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o SecretInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SecretInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SecretInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SecretInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SecretInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SecretInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SecretInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -1108,9 +2381,56 @@ func (a TokenAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of TokenAccessPolicy in the Terraform plugin framework type -// system. -func (a TokenAccessPolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenAccessPolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenAccessPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_token_ttl_in_minutes": types.Int64Type, @@ -1148,9 +2468,56 @@ func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of UpdateCustomAppIntegration in the Terraform plugin framework type -// system. -func (a UpdateCustomAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCustomAppIntegration{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, @@ -1158,7 +2525,7 @@ func (a UpdateCustomAppIntegration) ToObjectType(ctx context.Context) types.Obje ElemType: types.StringType, }, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToObjectType(ctx), + ElemType: TokenAccessPolicy{}.Type(ctx), }, }, } @@ -1184,9 +2551,56 @@ func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateCustomAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a UpdateCustomAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCustomAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1217,14 +2631,61 @@ func (a UpdatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of UpdatePublishedAppIntegration in the Terraform plugin framework type -// system. -func (a UpdatePublishedAppIntegration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePublishedAppIntegration{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_id": types.StringType, "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.ToObjectType(ctx), + ElemType: TokenAccessPolicy{}.Type(ctx), }, }, } @@ -1250,9 +2711,56 @@ func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdatePublishedAppIntegrationOutput in the Terraform plugin framework type -// system. -func (a UpdatePublishedAppIntegrationOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePublishedAppIntegrationOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 02b1e8273c..4568058ccf 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -12,13 +12,17 @@ package pipelines_tf import ( "context" + "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/compute" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type CreatePipeline struct { @@ -112,9 +116,56 @@ func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of CreatePipeline in the Terraform plugin framework type -// system. -func (a CreatePipeline) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePipeline{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePipeline) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePipeline) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePipeline) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePipeline) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePipeline) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePipeline) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePipeline) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_duplicate_names": types.BoolType, @@ -122,45 +173,45 @@ func (a CreatePipeline) ToObjectType(ctx context.Context) types.ObjectType { "catalog": types.StringType, "channel": types.StringType, "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.ToObjectType(ctx), + ElemType: PipelineCluster{}.Type(ctx), }, "configuration": basetypes.MapType{ ElemType: types.StringType, }, "continuous": types.BoolType, "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.ToObjectType(ctx), + ElemType: PipelineDeployment{}.Type(ctx), }, "development": types.BoolType, "dry_run": types.BoolType, "edition": types.StringType, "filters": basetypes.ListType{ - ElemType: Filters{}.ToObjectType(ctx), + ElemType: Filters{}.Type(ctx), }, "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.ToObjectType(ctx), + ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), }, "id": types.StringType, "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.ToObjectType(ctx), + ElemType: IngestionPipelineDefinition{}.Type(ctx), }, "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.ToObjectType(ctx), + ElemType: PipelineLibrary{}.Type(ctx), }, "name": types.StringType, "notifications": basetypes.ListType{ - ElemType: Notifications{}.ToObjectType(ctx), + ElemType: Notifications{}.Type(ctx), }, "photon": types.BoolType, "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.ToObjectType(ctx), + ElemType: RestartWindow{}.Type(ctx), }, "schema": types.StringType, "serverless": types.BoolType, "storage": types.StringType, "target": types.StringType, "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.ToObjectType(ctx), + ElemType: PipelineTrigger{}.Type(ctx), }, }, } @@ -193,13 +244,60 @@ func (a CreatePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CreatePipelineResponse in the Terraform plugin framework type -// system. -func (a CreatePipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePipelineResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "effective_settings": basetypes.ListType{ - ElemType: PipelineSpec{}.ToObjectType(ctx), + ElemType: PipelineSpec{}.Type(ctx), }, "pipeline_id": types.StringType, }, @@ -229,9 +327,56 @@ func (a CronTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of CronTrigger in the Terraform plugin framework type -// system. -func (a CronTrigger) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CronTrigger{} + +// Equal implements basetypes.ObjectValuable. +func (o CronTrigger) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CronTrigger) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CronTrigger) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CronTrigger) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CronTrigger) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CronTrigger) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CronTrigger) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "quartz_cron_schedule": types.StringType, @@ -264,9 +409,56 @@ func (a DataPlaneId) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of DataPlaneId in the Terraform plugin framework type -// system. -func (a DataPlaneId) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DataPlaneId{} + +// Equal implements basetypes.ObjectValuable. +func (o DataPlaneId) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DataPlaneId) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DataPlaneId) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DataPlaneId) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DataPlaneId) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DataPlaneId) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DataPlaneId) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "instance": types.StringType, @@ -297,9 +489,56 @@ func (a DeletePipelineRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePipelineRequest in the Terraform plugin framework type -// system. -func (a DeletePipelineRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePipelineRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePipelineRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -327,9 +566,56 @@ func (a DeletePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePipelineResponse in the Terraform plugin framework type -// system. -func (a DeletePipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePipelineResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -430,9 +716,56 @@ func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of EditPipeline in the Terraform plugin framework type -// system. -func (a EditPipeline) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditPipeline{} + +// Equal implements basetypes.ObjectValuable. +func (o EditPipeline) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditPipeline) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditPipeline) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditPipeline) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditPipeline) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditPipeline) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditPipeline) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_duplicate_names": types.BoolType, @@ -440,46 +773,46 @@ func (a EditPipeline) ToObjectType(ctx context.Context) types.ObjectType { "catalog": types.StringType, "channel": types.StringType, "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.ToObjectType(ctx), + ElemType: PipelineCluster{}.Type(ctx), }, "configuration": basetypes.MapType{ ElemType: types.StringType, }, "continuous": types.BoolType, "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.ToObjectType(ctx), + ElemType: PipelineDeployment{}.Type(ctx), }, "development": types.BoolType, "edition": types.StringType, "expected_last_modified": types.Int64Type, "filters": basetypes.ListType{ - ElemType: Filters{}.ToObjectType(ctx), + ElemType: Filters{}.Type(ctx), }, "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.ToObjectType(ctx), + ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), }, "id": types.StringType, "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.ToObjectType(ctx), + ElemType: IngestionPipelineDefinition{}.Type(ctx), }, "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.ToObjectType(ctx), + ElemType: PipelineLibrary{}.Type(ctx), }, "name": types.StringType, "notifications": basetypes.ListType{ - ElemType: Notifications{}.ToObjectType(ctx), + ElemType: Notifications{}.Type(ctx), }, "photon": types.BoolType, "pipeline_id": types.StringType, "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.ToObjectType(ctx), + ElemType: RestartWindow{}.Type(ctx), }, "schema": types.StringType, "serverless": types.BoolType, "storage": types.StringType, "target": types.StringType, "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.ToObjectType(ctx), + ElemType: PipelineTrigger{}.Type(ctx), }, }, } @@ -505,9 +838,56 @@ func (a EditPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of EditPipelineResponse in the Terraform plugin framework type -// system. -func (a EditPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditPipelineResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EditPipelineResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditPipelineResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditPipelineResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditPipelineResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditPipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditPipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditPipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -539,13 +919,60 @@ func (a ErrorDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of ErrorDetail in the Terraform plugin framework type -// system. -func (a ErrorDetail) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ErrorDetail{} + +// Equal implements basetypes.ObjectValuable. +func (o ErrorDetail) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ErrorDetail) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ErrorDetail) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ErrorDetail) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ErrorDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ErrorDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ErrorDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exceptions": basetypes.ListType{ - ElemType: SerializedException{}.ToObjectType(ctx), + ElemType: SerializedException{}.Type(ctx), }, "fatal": types.BoolType, }, @@ -574,9 +1001,56 @@ func (a FileLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of FileLibrary in the Terraform plugin framework type -// system. -func (a FileLibrary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FileLibrary{} + +// Equal implements basetypes.ObjectValuable. +func (o FileLibrary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FileLibrary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FileLibrary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FileLibrary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FileLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FileLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FileLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -611,9 +1085,56 @@ func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of Filters in the Terraform plugin framework type -// system. -func (a Filters) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Filters{} + +// Equal implements basetypes.ObjectValuable. +func (o Filters) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Filters) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Filters) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Filters) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Filters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Filters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Filters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "exclude": basetypes.ListType{ @@ -649,9 +1170,56 @@ func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPipelinePermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetPipelinePermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPipelinePermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -683,13 +1251,60 @@ func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Co } } -// ToObjectType returns the representation of GetPipelinePermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetPipelinePermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPipelinePermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPipelinePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: PipelinePermissionsDescription{}.ToObjectType(ctx), + ElemType: PipelinePermissionsDescription{}.Type(ctx), }, }, } @@ -718,9 +1333,56 @@ func (a GetPipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPipelinePermissionsRequest in the Terraform plugin framework type -// system. -func (a GetPipelinePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPipelinePermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPipelinePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -750,9 +1412,56 @@ func (a GetPipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPipelineRequest in the Terraform plugin framework type -// system. -func (a GetPipelineRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPipelineRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPipelineRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPipelineRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPipelineRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPipelineRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPipelineRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPipelineRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPipelineRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -809,9 +1518,56 @@ func (a GetPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of GetPipelineResponse in the Terraform plugin framework type -// system. -func (a GetPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPipelineResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPipelineResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPipelineResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPipelineResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPipelineResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, @@ -821,13 +1577,13 @@ func (a GetPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType "health": types.StringType, "last_modified": types.Int64Type, "latest_updates": basetypes.ListType{ - ElemType: UpdateStateInfo{}.ToObjectType(ctx), + ElemType: UpdateStateInfo{}.Type(ctx), }, "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, "spec": basetypes.ListType{ - ElemType: PipelineSpec{}.ToObjectType(ctx), + ElemType: PipelineSpec{}.Type(ctx), }, "state": types.StringType, }, @@ -859,9 +1615,56 @@ func (a GetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetUpdateRequest in the Terraform plugin framework type -// system. -func (a GetUpdateRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetUpdateRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetUpdateRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetUpdateRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetUpdateRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetUpdateRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetUpdateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetUpdateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -894,13 +1697,60 @@ func (a GetUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of GetUpdateResponse in the Terraform plugin framework type -// system. -func (a GetUpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetUpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetUpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetUpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetUpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetUpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetUpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetUpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetUpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "update": basetypes.ListType{ - ElemType: UpdateInfo{}.ToObjectType(ctx), + ElemType: UpdateInfo{}.Type(ctx), }, }, } @@ -936,19 +1786,66 @@ func (a IngestionConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of IngestionConfig in the Terraform plugin framework type -// system. -func (a IngestionConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = IngestionConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o IngestionConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o IngestionConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o IngestionConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o IngestionConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o IngestionConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o IngestionConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o IngestionConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "report": basetypes.ListType{ - ElemType: ReportSpec{}.ToObjectType(ctx), + ElemType: ReportSpec{}.Type(ctx), }, "schema": basetypes.ListType{ - ElemType: SchemaSpec{}.ToObjectType(ctx), + ElemType: SchemaSpec{}.Type(ctx), }, "table": basetypes.ListType{ - ElemType: TableSpec{}.ToObjectType(ctx), + ElemType: TableSpec{}.Type(ctx), }, }, } @@ -992,9 +1889,56 @@ func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of IngestionGatewayPipelineDefinition in the Terraform plugin framework type -// system. -func (a IngestionGatewayPipelineDefinition) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = IngestionGatewayPipelineDefinition{} + +// Equal implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o IngestionGatewayPipelineDefinition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connection_id": types.StringType, @@ -1043,18 +1987,65 @@ func (a IngestionPipelineDefinition) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of IngestionPipelineDefinition in the Terraform plugin framework type -// system. -func (a IngestionPipelineDefinition) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = IngestionPipelineDefinition{} + +// Equal implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connection_name": types.StringType, "ingestion_gateway_id": types.StringType, "objects": basetypes.ListType{ - ElemType: IngestionConfig{}.ToObjectType(ctx), + ElemType: IngestionConfig{}.Type(ctx), }, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToObjectType(ctx), + ElemType: TableSpecificConfig{}.Type(ctx), }, }, } @@ -1106,9 +2097,56 @@ func (a ListPipelineEventsRequest) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ListPipelineEventsRequest in the Terraform plugin framework type -// system. -func (a ListPipelineEventsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPipelineEventsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPipelineEventsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -1150,13 +2188,60 @@ func (a ListPipelineEventsResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListPipelineEventsResponse in the Terraform plugin framework type -// system. -func (a ListPipelineEventsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPipelineEventsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPipelineEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "events": basetypes.ListType{ - ElemType: PipelineEvent{}.ToObjectType(ctx), + ElemType: PipelineEvent{}.Type(ctx), }, "next_page_token": types.StringType, "prev_page_token": types.StringType, @@ -1208,9 +2293,56 @@ func (a ListPipelinesRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListPipelinesRequest in the Terraform plugin framework type -// system. -func (a ListPipelinesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPipelinesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPipelinesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter": types.StringType, @@ -1249,14 +2381,61 @@ func (a ListPipelinesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListPipelinesResponse in the Terraform plugin framework type -// system. -func (a ListPipelinesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPipelinesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPipelinesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "statuses": basetypes.ListType{ - ElemType: PipelineStateInfo{}.ToObjectType(ctx), + ElemType: PipelineStateInfo{}.Type(ctx), }, }, } @@ -1291,9 +2470,56 @@ func (a ListUpdatesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListUpdatesRequest in the Terraform plugin framework type -// system. -func (a ListUpdatesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListUpdatesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListUpdatesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -1334,15 +2560,62 @@ func (a ListUpdatesResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListUpdatesResponse in the Terraform plugin framework type -// system. -func (a ListUpdatesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListUpdatesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListUpdatesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "prev_page_token": types.StringType, "updates": basetypes.ListType{ - ElemType: UpdateInfo{}.ToObjectType(ctx), + ElemType: UpdateInfo{}.Type(ctx), }, }, } @@ -1368,9 +2641,56 @@ func (a ManualTrigger) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ManualTrigger in the Terraform plugin framework type -// system. -func (a ManualTrigger) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ManualTrigger{} + +// Equal implements basetypes.ObjectValuable. +func (o ManualTrigger) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ManualTrigger) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ManualTrigger) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ManualTrigger) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ManualTrigger) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ManualTrigger) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ManualTrigger) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1398,9 +2718,56 @@ func (a NotebookLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of NotebookLibrary in the Terraform plugin framework type -// system. -func (a NotebookLibrary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NotebookLibrary{} + +// Equal implements basetypes.ObjectValuable. +func (o NotebookLibrary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NotebookLibrary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NotebookLibrary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NotebookLibrary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NotebookLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NotebookLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NotebookLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -1441,9 +2808,56 @@ func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of Notifications in the Terraform plugin framework type -// system. -func (a Notifications) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Notifications{} + +// Equal implements basetypes.ObjectValuable. +func (o Notifications) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Notifications) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Notifications) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Notifications) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Notifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Notifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Notifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alerts": basetypes.ListType{ @@ -1511,9 +2925,56 @@ func (a Origin) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Origin in the Terraform plugin framework type -// system. -func (a Origin) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Origin{} + +// Equal implements basetypes.ObjectValuable. +func (o Origin) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Origin) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Origin) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Origin) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Origin) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Origin) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Origin) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "batch_id": types.Int64Type, @@ -1565,9 +3026,56 @@ func (a PipelineAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelineAccessControlRequest in the Terraform plugin framework type -// system. -func (a PipelineAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -1610,13 +3118,60 @@ func (a PipelineAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of PipelineAccessControlResponse in the Terraform plugin framework type -// system. -func (a PipelineAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: PipelinePermission{}.ToObjectType(ctx), + ElemType: PipelinePermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -1751,23 +3306,70 @@ func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of PipelineCluster in the Terraform plugin framework type -// system. -func (a PipelineCluster) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineCluster{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineCluster) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineCluster) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineCluster) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineCluster) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, "autoscale": basetypes.ListType{ - ElemType: PipelineClusterAutoscale{}.ToObjectType(ctx), + ElemType: PipelineClusterAutoscale{}.Type(ctx), }, "aws_attributes": basetypes.ListType{ - ElemType: compute_tf.AwsAttributes{}.ToObjectType(ctx), + ElemType: compute_tf.AwsAttributes{}.Type(ctx), }, "azure_attributes": basetypes.ListType{ - ElemType: compute_tf.AzureAttributes{}.ToObjectType(ctx), + ElemType: compute_tf.AzureAttributes{}.Type(ctx), }, "cluster_log_conf": basetypes.ListType{ - ElemType: compute_tf.ClusterLogConf{}.ToObjectType(ctx), + ElemType: compute_tf.ClusterLogConf{}.Type(ctx), }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, @@ -1776,10 +3378,10 @@ func (a PipelineCluster) ToObjectType(ctx context.Context) types.ObjectType { "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ - ElemType: compute_tf.GcpAttributes{}.ToObjectType(ctx), + ElemType: compute_tf.GcpAttributes{}.Type(ctx), }, "init_scripts": basetypes.ListType{ - ElemType: compute_tf.InitScriptInfo{}.ToObjectType(ctx), + ElemType: compute_tf.InitScriptInfo{}.Type(ctx), }, "instance_pool_id": types.StringType, "label": types.StringType, @@ -1832,9 +3434,56 @@ func (a PipelineClusterAutoscale) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelineClusterAutoscale in the Terraform plugin framework type -// system. -func (a PipelineClusterAutoscale) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineClusterAutoscale{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineClusterAutoscale) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_workers": types.Int64Type, @@ -1868,9 +3517,56 @@ func (a PipelineDeployment) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelineDeployment in the Terraform plugin framework type -// system. -func (a PipelineDeployment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineDeployment{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineDeployment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineDeployment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineDeployment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineDeployment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineDeployment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineDeployment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineDeployment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kind": types.StringType, @@ -1921,13 +3617,60 @@ func (a PipelineEvent) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of PipelineEvent in the Terraform plugin framework type -// system. -func (a PipelineEvent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineEvent{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineEvent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineEvent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineEvent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineEvent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineEvent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineEvent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineEvent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": basetypes.ListType{ - ElemType: ErrorDetail{}.ToObjectType(ctx), + ElemType: ErrorDetail{}.Type(ctx), }, "event_type": types.StringType, "id": types.StringType, @@ -1935,10 +3678,10 @@ func (a PipelineEvent) ToObjectType(ctx context.Context) types.ObjectType { "maturity_level": types.StringType, "message": types.StringType, "origin": basetypes.ListType{ - ElemType: Origin{}.ToObjectType(ctx), + ElemType: Origin{}.Type(ctx), }, "sequence": basetypes.ListType{ - ElemType: Sequencing{}.ToObjectType(ctx), + ElemType: Sequencing{}.Type(ctx), }, "timestamp": types.StringType, }, @@ -1981,20 +3724,67 @@ func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of PipelineLibrary in the Terraform plugin framework type -// system. -func (a PipelineLibrary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineLibrary{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineLibrary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineLibrary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineLibrary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineLibrary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "file": basetypes.ListType{ - ElemType: FileLibrary{}.ToObjectType(ctx), + ElemType: FileLibrary{}.Type(ctx), }, "jar": types.StringType, "maven": basetypes.ListType{ - ElemType: compute_tf.MavenLibrary{}.ToObjectType(ctx), + ElemType: compute_tf.MavenLibrary{}.Type(ctx), }, "notebook": basetypes.ListType{ - ElemType: NotebookLibrary{}.ToObjectType(ctx), + ElemType: NotebookLibrary{}.Type(ctx), }, "whl": types.StringType, }, @@ -2028,9 +3818,56 @@ func (a PipelinePermission) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of PipelinePermission in the Terraform plugin framework type -// system. -func (a PipelinePermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelinePermission{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelinePermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelinePermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelinePermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelinePermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelinePermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelinePermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelinePermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2069,13 +3906,60 @@ func (a PipelinePermissions) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of PipelinePermissions in the Terraform plugin framework type -// system. -func (a PipelinePermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelinePermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelinePermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelinePermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelinePermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelinePermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelinePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelinePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelinePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PipelineAccessControlResponse{}.ToObjectType(ctx), + ElemType: PipelineAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2106,9 +3990,56 @@ func (a PipelinePermissionsDescription) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of PipelinePermissionsDescription in the Terraform plugin framework type -// system. -func (a PipelinePermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelinePermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelinePermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2142,13 +4073,60 @@ func (a PipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of PipelinePermissionsRequest in the Terraform plugin framework type -// system. -func (a PipelinePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelinePermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelinePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: PipelineAccessControlRequest{}.ToObjectType(ctx), + ElemType: PipelineAccessControlRequest{}.Type(ctx), }, "pipeline_id": types.StringType, }, @@ -2241,53 +4219,100 @@ func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of PipelineSpec in the Terraform plugin framework type -// system. -func (a PipelineSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.ToObjectType(ctx), + ElemType: PipelineCluster{}.Type(ctx), }, "configuration": basetypes.MapType{ ElemType: types.StringType, }, "continuous": types.BoolType, "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.ToObjectType(ctx), + ElemType: PipelineDeployment{}.Type(ctx), }, "development": types.BoolType, "edition": types.StringType, "filters": basetypes.ListType{ - ElemType: Filters{}.ToObjectType(ctx), + ElemType: Filters{}.Type(ctx), }, "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.ToObjectType(ctx), + ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), }, "id": types.StringType, "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.ToObjectType(ctx), + ElemType: IngestionPipelineDefinition{}.Type(ctx), }, "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.ToObjectType(ctx), + ElemType: PipelineLibrary{}.Type(ctx), }, "name": types.StringType, "notifications": basetypes.ListType{ - ElemType: Notifications{}.ToObjectType(ctx), + ElemType: Notifications{}.Type(ctx), }, "photon": types.BoolType, "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.ToObjectType(ctx), + ElemType: RestartWindow{}.Type(ctx), }, "schema": types.StringType, "serverless": types.BoolType, "storage": types.StringType, "target": types.StringType, "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.ToObjectType(ctx), + ElemType: PipelineTrigger{}.Type(ctx), }, }, } @@ -2333,16 +4358,63 @@ func (a PipelineStateInfo) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of PipelineStateInfo in the Terraform plugin framework type -// system. -func (a PipelineStateInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineStateInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineStateInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineStateInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineStateInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineStateInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineStateInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineStateInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineStateInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "creator_user_name": types.StringType, "health": types.StringType, "latest_updates": basetypes.ListType{ - ElemType: UpdateStateInfo{}.ToObjectType(ctx), + ElemType: UpdateStateInfo{}.Type(ctx), }, "name": types.StringType, "pipeline_id": types.StringType, @@ -2378,16 +4450,63 @@ func (a PipelineTrigger) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of PipelineTrigger in the Terraform plugin framework type -// system. -func (a PipelineTrigger) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PipelineTrigger{} + +// Equal implements basetypes.ObjectValuable. +func (o PipelineTrigger) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PipelineTrigger) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PipelineTrigger) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PipelineTrigger) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PipelineTrigger) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PipelineTrigger) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PipelineTrigger) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cron": basetypes.ListType{ - ElemType: CronTrigger{}.ToObjectType(ctx), + ElemType: CronTrigger{}.Type(ctx), }, "manual": basetypes.ListType{ - ElemType: ManualTrigger{}.ToObjectType(ctx), + ElemType: ManualTrigger{}.Type(ctx), }, }, } @@ -2428,9 +4547,56 @@ func (a ReportSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of ReportSpec in the Terraform plugin framework type -// system. -func (a ReportSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReportSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o ReportSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReportSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReportSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReportSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReportSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReportSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReportSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_catalog": types.StringType, @@ -2438,7 +4604,7 @@ func (a ReportSpec) ToObjectType(ctx context.Context) types.ObjectType { "destination_table": types.StringType, "source_url": types.StringType, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToObjectType(ctx), + ElemType: TableSpecificConfig{}.Type(ctx), }, }, } @@ -2476,9 +4642,56 @@ func (a RestartWindow) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestartWindow in the Terraform plugin framework type -// system. -func (a RestartWindow) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestartWindow{} + +// Equal implements basetypes.ObjectValuable. +func (o RestartWindow) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestartWindow) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestartWindow) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestartWindow) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestartWindow) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestartWindow) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestartWindow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "days_of_week": types.StringType, @@ -2525,9 +4738,56 @@ func (a SchemaSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of SchemaSpec in the Terraform plugin framework type -// system. -func (a SchemaSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SchemaSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o SchemaSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SchemaSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SchemaSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SchemaSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SchemaSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SchemaSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SchemaSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_catalog": types.StringType, @@ -2535,7 +4795,7 @@ func (a SchemaSpec) ToObjectType(ctx context.Context) types.ObjectType { "source_catalog": types.StringType, "source_schema": types.StringType, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToObjectType(ctx), + ElemType: TableSpecificConfig{}.Type(ctx), }, }, } @@ -2567,14 +4827,61 @@ func (a Sequencing) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of Sequencing in the Terraform plugin framework type -// system. -func (a Sequencing) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Sequencing{} + +// Equal implements basetypes.ObjectValuable. +func (o Sequencing) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Sequencing) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Sequencing) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Sequencing) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Sequencing) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Sequencing) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Sequencing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "control_plane_seq_no": types.Int64Type, "data_plane_id": basetypes.ListType{ - ElemType: DataPlaneId{}.ToObjectType(ctx), + ElemType: DataPlaneId{}.Type(ctx), }, }, } @@ -2608,15 +4915,62 @@ func (a SerializedException) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of SerializedException in the Terraform plugin framework type -// system. -func (a SerializedException) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SerializedException{} + +// Equal implements basetypes.ObjectValuable. +func (o SerializedException) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SerializedException) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SerializedException) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SerializedException) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SerializedException) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SerializedException) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SerializedException) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "class_name": types.StringType, "message": types.StringType, "stack": basetypes.ListType{ - ElemType: StackFrame{}.ToObjectType(ctx), + ElemType: StackFrame{}.Type(ctx), }, }, } @@ -2650,9 +5004,56 @@ func (a StackFrame) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of StackFrame in the Terraform plugin framework type -// system. -func (a StackFrame) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StackFrame{} + +// Equal implements basetypes.ObjectValuable. +func (o StackFrame) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StackFrame) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StackFrame) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StackFrame) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StackFrame) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StackFrame) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StackFrame) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "declaring_class": types.StringType, @@ -2704,9 +5105,56 @@ func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of StartUpdate in the Terraform plugin framework type -// system. -func (a StartUpdate) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartUpdate{} + +// Equal implements basetypes.ObjectValuable. +func (o StartUpdate) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartUpdate) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartUpdate) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartUpdate) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, @@ -2744,9 +5192,56 @@ func (a StartUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of StartUpdateResponse in the Terraform plugin framework type -// system. -func (a StartUpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartUpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o StartUpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartUpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartUpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartUpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartUpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartUpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartUpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "update_id": types.StringType, @@ -2774,9 +5269,56 @@ func (a StopPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of StopPipelineResponse in the Terraform plugin framework type -// system. -func (a StopPipelineResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StopPipelineResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o StopPipelineResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StopPipelineResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StopPipelineResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StopPipelineResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StopPipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StopPipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StopPipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2804,9 +5346,56 @@ func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of StopRequest in the Terraform plugin framework type -// system. -func (a StopRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StopRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o StopRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StopRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StopRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StopRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StopRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StopRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StopRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "pipeline_id": types.StringType, @@ -2854,9 +5443,56 @@ func (a TableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of TableSpec in the Terraform plugin framework type -// system. -func (a TableSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o TableSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_catalog": types.StringType, @@ -2866,7 +5502,7 @@ func (a TableSpec) ToObjectType(ctx context.Context) types.ObjectType { "source_schema": types.StringType, "source_table": types.StringType, "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.ToObjectType(ctx), + ElemType: TableSpecificConfig{}.Type(ctx), }, }, } @@ -2906,9 +5542,56 @@ func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of TableSpecificConfig in the Terraform plugin framework type -// system. -func (a TableSpecificConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TableSpecificConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o TableSpecificConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TableSpecificConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TableSpecificConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TableSpecificConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TableSpecificConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TableSpecificConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TableSpecificConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "primary_keys": basetypes.ListType{ @@ -2977,15 +5660,62 @@ func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of UpdateInfo in the Terraform plugin framework type -// system. -func (a UpdateInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cause": types.StringType, "cluster_id": types.StringType, "config": basetypes.ListType{ - ElemType: PipelineSpec{}.ToObjectType(ctx), + ElemType: PipelineSpec{}.Type(ctx), }, "creation_time": types.Int64Type, "full_refresh": types.BoolType, @@ -3028,9 +5758,56 @@ func (a UpdateStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateStateInfo in the Terraform plugin framework type -// system. -func (a UpdateStateInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateStateInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateStateInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateStateInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateStateInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateStateInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateStateInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateStateInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateStateInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_time": types.StringType, @@ -3039,3 +5816,34 @@ func (a UpdateStateInfo) ToObjectType(ctx context.Context) types.ObjectType { }, } } + +// The deployment method that manages the pipeline: - BUNDLE: The pipeline is +// managed by a Databricks Asset Bundle. + +// The severity level of the event. + +// The health of a pipeline. + +// Maturity level for EventDetails. + +// Databricks Enhanced Autoscaling optimizes cluster utilization by +// automatically allocating cluster resources based on workload volume, with +// minimal impact to the data processing latency of your pipelines. Enhanced +// Autoscaling is available for `updates` clusters only. The legacy autoscaling +// feature is used for `maintenance` clusters. + +// Permission level + +// The pipeline state. + +// The health of a pipeline. + +// Days of week in which the restart is allowed to happen (within a five-hour +// window starting at start_hour). If not specified all days of the week will be +// used. + +// The SCD type to use to ingest the table. + +// What triggered this update. + +// The update state. diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 4b8f188b99..9e1442d59d 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -12,11 +12,15 @@ package provisioning_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AwsCredentials struct { @@ -42,13 +46,60 @@ func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of AwsCredentials in the Terraform plugin framework type -// system. -func (a AwsCredentials) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsCredentials{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsCredentials) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsCredentials) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsCredentials) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsCredentials) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sts_role": basetypes.ListType{ - ElemType: StsRole{}.ToObjectType(ctx), + ElemType: StsRole{}.Type(ctx), }, }, } @@ -85,9 +136,56 @@ func (a AwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of AwsKeyInfo in the Terraform plugin framework type -// system. -func (a AwsKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AwsKeyInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o AwsKeyInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AwsKeyInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AwsKeyInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AwsKeyInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AwsKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AwsKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AwsKeyInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key_alias": types.StringType, @@ -122,9 +220,56 @@ func (a AzureWorkspaceInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureWorkspaceInfo in the Terraform plugin framework type -// system. -func (a AzureWorkspaceInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureWorkspaceInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureWorkspaceInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "resource_group": types.StringType, @@ -158,13 +303,60 @@ func (a CloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CloudResourceContainer in the Terraform plugin framework type -// system. -func (a CloudResourceContainer) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CloudResourceContainer{} + +// Equal implements basetypes.ObjectValuable. +func (o CloudResourceContainer) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CloudResourceContainer) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CloudResourceContainer) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CloudResourceContainer) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CloudResourceContainer) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CloudResourceContainer) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CloudResourceContainer) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gcp": basetypes.ListType{ - ElemType: CustomerFacingGcpCloudResourceContainer{}.ToObjectType(ctx), + ElemType: CustomerFacingGcpCloudResourceContainer{}.Type(ctx), }, }, } @@ -200,9 +392,56 @@ func (a CreateAwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateAwsKeyInfo in the Terraform plugin framework type -// system. -func (a CreateAwsKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateAwsKeyInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateAwsKeyInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key_alias": types.StringType, @@ -235,13 +474,60 @@ func (a CreateCredentialAwsCredentials) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of CreateCredentialAwsCredentials in the Terraform plugin framework type -// system. -func (a CreateCredentialAwsCredentials) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCredentialAwsCredentials{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCredentialAwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "sts_role": basetypes.ListType{ - ElemType: CreateCredentialStsRole{}.ToObjectType(ctx), + ElemType: CreateCredentialStsRole{}.Type(ctx), }, }, } @@ -272,13 +558,60 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of CreateCredentialRequest in the Terraform plugin framework type -// system. -func (a CreateCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_credentials": basetypes.ListType{ - ElemType: CreateCredentialAwsCredentials{}.ToObjectType(ctx), + ElemType: CreateCredentialAwsCredentials{}.Type(ctx), }, "credentials_name": types.StringType, }, @@ -307,9 +640,56 @@ func (a CreateCredentialStsRole) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateCredentialStsRole in the Terraform plugin framework type -// system. -func (a CreateCredentialStsRole) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCredentialStsRole{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCredentialStsRole) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "role_arn": types.StringType, @@ -346,16 +726,63 @@ func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of CreateCustomerManagedKeyRequest in the Terraform plugin framework type -// system. -func (a CreateCustomerManagedKeyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCustomerManagedKeyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCustomerManagedKeyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_key_info": basetypes.ListType{ - ElemType: CreateAwsKeyInfo{}.ToObjectType(ctx), + ElemType: CreateAwsKeyInfo{}.Type(ctx), }, "gcp_key_info": basetypes.ListType{ - ElemType: CreateGcpKeyInfo{}.ToObjectType(ctx), + ElemType: CreateGcpKeyInfo{}.Type(ctx), }, "use_cases": basetypes.ListType{ ElemType: types.StringType, @@ -386,9 +813,56 @@ func (a CreateGcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateGcpKeyInfo in the Terraform plugin framework type -// system. -func (a CreateGcpKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateGcpKeyInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateGcpKeyInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kms_key_id": types.StringType, @@ -440,13 +914,60 @@ func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of CreateNetworkRequest in the Terraform plugin framework type -// system. -func (a CreateNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateNetworkRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateNetworkRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gcp_network_info": basetypes.ListType{ - ElemType: GcpNetworkInfo{}.ToObjectType(ctx), + ElemType: GcpNetworkInfo{}.Type(ctx), }, "network_name": types.StringType, "security_group_ids": basetypes.ListType{ @@ -456,7 +977,7 @@ func (a CreateNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType ElemType: types.StringType, }, "vpc_endpoints": basetypes.ListType{ - ElemType: NetworkVpcEndpoints{}.ToObjectType(ctx), + ElemType: NetworkVpcEndpoints{}.Type(ctx), }, "vpc_id": types.StringType, }, @@ -489,13 +1010,60 @@ func (a CreateStorageConfigurationRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of CreateStorageConfigurationRequest in the Terraform plugin framework type -// system. -func (a CreateStorageConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateStorageConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateStorageConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "root_bucket_info": basetypes.ListType{ - ElemType: RootBucketInfo{}.ToObjectType(ctx), + ElemType: RootBucketInfo{}.Type(ctx), }, "storage_configuration_name": types.StringType, }, @@ -533,14 +1101,61 @@ func (a CreateVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of CreateVpcEndpointRequest in the Terraform plugin framework type -// system. -func (a CreateVpcEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateVpcEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateVpcEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_vpc_endpoint_id": types.StringType, "gcp_vpc_endpoint_info": basetypes.ListType{ - ElemType: GcpVpcEndpointInfo{}.ToObjectType(ctx), + ElemType: GcpVpcEndpointInfo{}.Type(ctx), }, "region": types.StringType, "vpc_endpoint_name": types.StringType, @@ -683,15 +1298,62 @@ func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CreateWorkspaceRequest in the Terraform plugin framework type -// system. -func (a CreateWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateWorkspaceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_region": types.StringType, "cloud": types.StringType, "cloud_resource_container": basetypes.ListType{ - ElemType: CloudResourceContainer{}.ToObjectType(ctx), + ElemType: CloudResourceContainer{}.Type(ctx), }, "credentials_id": types.StringType, "custom_tags": basetypes.MapType{ @@ -699,10 +1361,10 @@ func (a CreateWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectTy }, "deployment_name": types.StringType, "gcp_managed_network_config": basetypes.ListType{ - ElemType: GcpManagedNetworkConfig{}.ToObjectType(ctx), + ElemType: GcpManagedNetworkConfig{}.Type(ctx), }, "gke_config": basetypes.ListType{ - ElemType: GkeConfig{}.ToObjectType(ctx), + ElemType: GkeConfig{}.Type(ctx), }, "is_no_public_ip_enabled": types.BoolType, "location": types.StringType, @@ -749,14 +1411,61 @@ func (a Credential) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of Credential in the Terraform plugin framework type -// system. -func (a Credential) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Credential{} + +// Equal implements basetypes.ObjectValuable. +func (o Credential) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Credential) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Credential) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Credential) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Credential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Credential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Credential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "aws_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.ToObjectType(ctx), + ElemType: AwsCredentials{}.Type(ctx), }, "creation_time": types.Int64Type, "credentials_id": types.StringType, @@ -789,9 +1498,56 @@ func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of CustomerFacingGcpCloudResourceContainer in the Terraform plugin framework type -// system. -func (a CustomerFacingGcpCloudResourceContainer) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CustomerFacingGcpCloudResourceContainer{} + +// Equal implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CustomerFacingGcpCloudResourceContainer) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "project_id": types.StringType, @@ -835,19 +1591,66 @@ func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CustomerManagedKey in the Terraform plugin framework type -// system. -func (a CustomerManagedKey) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CustomerManagedKey{} + +// Equal implements basetypes.ObjectValuable. +func (o CustomerManagedKey) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CustomerManagedKey) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CustomerManagedKey) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CustomerManagedKey) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CustomerManagedKey) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CustomerManagedKey) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CustomerManagedKey) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "aws_key_info": basetypes.ListType{ - ElemType: AwsKeyInfo{}.ToObjectType(ctx), + ElemType: AwsKeyInfo{}.Type(ctx), }, "creation_time": types.Int64Type, "customer_managed_key_id": types.StringType, "gcp_key_info": basetypes.ListType{ - ElemType: GcpKeyInfo{}.ToObjectType(ctx), + ElemType: GcpKeyInfo{}.Type(ctx), }, "use_cases": basetypes.ListType{ ElemType: types.StringType, @@ -879,10 +1682,57 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCredentialRequest in the Terraform plugin framework type -// system. -func (a DeleteCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials_id": types.StringType, }, @@ -912,9 +1762,56 @@ func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteEncryptionKeyRequest in the Terraform plugin framework type -// system. -func (a DeleteEncryptionKeyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteEncryptionKeyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteEncryptionKeyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "customer_managed_key_id": types.StringType, @@ -945,9 +1842,56 @@ func (a DeleteNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteNetworkRequest in the Terraform plugin framework type -// system. -func (a DeleteNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteNetworkRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteNetworkRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_id": types.StringType, @@ -978,9 +1922,56 @@ func (a DeletePrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePrivateAccesRequest in the Terraform plugin framework type -// system. -func (a DeletePrivateAccesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePrivateAccesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePrivateAccesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "private_access_settings_id": types.StringType, @@ -1008,9 +1999,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1039,9 +2077,56 @@ func (a DeleteStorageRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteStorageRequest in the Terraform plugin framework type -// system. -func (a DeleteStorageRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteStorageRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteStorageRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "storage_configuration_id": types.StringType, @@ -1072,9 +2157,56 @@ func (a DeleteVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteVpcEndpointRequest in the Terraform plugin framework type -// system. -func (a DeleteVpcEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteVpcEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteVpcEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "vpc_endpoint_id": types.StringType, @@ -1105,9 +2237,56 @@ func (a DeleteWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWorkspaceRequest in the Terraform plugin framework type -// system. -func (a DeleteWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWorkspaceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1141,9 +2320,56 @@ func (a ExternalCustomerInfo) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExternalCustomerInfo in the Terraform plugin framework type -// system. -func (a ExternalCustomerInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExternalCustomerInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExternalCustomerInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authoritative_user_email": types.StringType, @@ -1175,9 +2401,56 @@ func (a GcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpKeyInfo in the Terraform plugin framework type -// system. -func (a GcpKeyInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpKeyInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpKeyInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpKeyInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpKeyInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpKeyInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpKeyInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "kms_key_id": types.StringType, @@ -1237,9 +2510,56 @@ func (a GcpManagedNetworkConfig) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpManagedNetworkConfig in the Terraform plugin framework type -// system. -func (a GcpManagedNetworkConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpManagedNetworkConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpManagedNetworkConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "gke_cluster_pod_ip_range": types.StringType, @@ -1289,9 +2609,56 @@ func (a GcpNetworkInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpNetworkInfo in the Terraform plugin framework type -// system. -func (a GcpNetworkInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpNetworkInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpNetworkInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_project_id": types.StringType, @@ -1337,9 +2704,56 @@ func (a GcpVpcEndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GcpVpcEndpointInfo in the Terraform plugin framework type -// system. -func (a GcpVpcEndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GcpVpcEndpointInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GcpVpcEndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_region": types.StringType, @@ -1374,9 +2788,56 @@ func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCredentialRequest in the Terraform plugin framework type -// system. -func (a GetCredentialRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCredentialRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCredentialRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCredentialRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCredentialRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCredentialRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials_id": types.StringType, @@ -1407,9 +2868,56 @@ func (a GetEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetEncryptionKeyRequest in the Terraform plugin framework type -// system. -func (a GetEncryptionKeyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEncryptionKeyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEncryptionKeyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "customer_managed_key_id": types.StringType, @@ -1440,9 +2948,56 @@ func (a GetNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetNetworkRequest in the Terraform plugin framework type -// system. -func (a GetNetworkRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetNetworkRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetNetworkRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetNetworkRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetNetworkRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetNetworkRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetNetworkRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetNetworkRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetNetworkRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_id": types.StringType, @@ -1473,9 +3028,56 @@ func (a GetPrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPrivateAccesRequest in the Terraform plugin framework type -// system. -func (a GetPrivateAccesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPrivateAccesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPrivateAccesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "private_access_settings_id": types.StringType, @@ -1506,9 +3108,56 @@ func (a GetStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStorageRequest in the Terraform plugin framework type -// system. -func (a GetStorageRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStorageRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStorageRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStorageRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStorageRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStorageRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStorageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStorageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStorageRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "storage_configuration_id": types.StringType, @@ -1539,9 +3188,56 @@ func (a GetVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetVpcEndpointRequest in the Terraform plugin framework type -// system. -func (a GetVpcEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetVpcEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetVpcEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "vpc_endpoint_id": types.StringType, @@ -1572,9 +3268,56 @@ func (a GetWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWorkspaceRequest in the Terraform plugin framework type -// system. -func (a GetWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_id": types.Int64Type, @@ -1617,9 +3360,56 @@ func (a GkeConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of GkeConfig in the Terraform plugin framework type -// system. -func (a GkeConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GkeConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o GkeConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GkeConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GkeConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GkeConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GkeConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GkeConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GkeConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connectivity_type": types.StringType, @@ -1688,18 +3478,65 @@ func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// ToObjectType returns the representation of Network in the Terraform plugin framework type -// system. -func (a Network) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Network{} + +// Equal implements basetypes.ObjectValuable. +func (o Network) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Network) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Network) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Network) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Network) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Network) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Network) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, "error_messages": basetypes.ListType{ - ElemType: NetworkHealth{}.ToObjectType(ctx), + ElemType: NetworkHealth{}.Type(ctx), }, "gcp_network_info": basetypes.ListType{ - ElemType: GcpNetworkInfo{}.ToObjectType(ctx), + ElemType: GcpNetworkInfo{}.Type(ctx), }, "network_id": types.StringType, "network_name": types.StringType, @@ -1710,12 +3547,12 @@ func (a Network) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "vpc_endpoints": basetypes.ListType{ - ElemType: NetworkVpcEndpoints{}.ToObjectType(ctx), + ElemType: NetworkVpcEndpoints{}.Type(ctx), }, "vpc_id": types.StringType, "vpc_status": types.StringType, "warning_messages": basetypes.ListType{ - ElemType: NetworkWarning{}.ToObjectType(ctx), + ElemType: NetworkWarning{}.Type(ctx), }, "workspace_id": types.Int64Type, }, @@ -1747,9 +3584,56 @@ func (a NetworkHealth) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of NetworkHealth in the Terraform plugin framework type -// system. -func (a NetworkHealth) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NetworkHealth{} + +// Equal implements basetypes.ObjectValuable. +func (o NetworkHealth) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NetworkHealth) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NetworkHealth) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NetworkHealth) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NetworkHealth) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NetworkHealth) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NetworkHealth) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_message": types.StringType, @@ -1791,9 +3675,56 @@ func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of NetworkVpcEndpoints in the Terraform plugin framework type -// system. -func (a NetworkVpcEndpoints) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NetworkVpcEndpoints{} + +// Equal implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NetworkVpcEndpoints) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataplane_relay": basetypes.ListType{ @@ -1831,9 +3762,56 @@ func (a NetworkWarning) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of NetworkWarning in the Terraform plugin framework type -// system. -func (a NetworkWarning) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NetworkWarning{} + +// Equal implements basetypes.ObjectValuable. +func (o NetworkWarning) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NetworkWarning) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NetworkWarning) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NetworkWarning) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NetworkWarning) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NetworkWarning) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NetworkWarning) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warning_message": types.StringType, @@ -1888,9 +3866,56 @@ func (a PrivateAccessSettings) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of PrivateAccessSettings in the Terraform plugin framework type -// system. -func (a PrivateAccessSettings) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PrivateAccessSettings{} + +// Equal implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PrivateAccessSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, @@ -1926,9 +3951,56 @@ func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ReplaceResponse in the Terraform plugin framework type -// system. -func (a ReplaceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReplaceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ReplaceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReplaceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReplaceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReplaceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReplaceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReplaceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReplaceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1957,9 +4029,56 @@ func (a RootBucketInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of RootBucketInfo in the Terraform plugin framework type -// system. -func (a RootBucketInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RootBucketInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RootBucketInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RootBucketInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RootBucketInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RootBucketInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RootBucketInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RootBucketInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RootBucketInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bucket_name": types.StringType, @@ -1999,15 +4118,62 @@ func (a StorageConfiguration) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of StorageConfiguration in the Terraform plugin framework type -// system. -func (a StorageConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StorageConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o StorageConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StorageConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StorageConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StorageConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StorageConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StorageConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StorageConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, "root_bucket_info": basetypes.ListType{ - ElemType: RootBucketInfo{}.ToObjectType(ctx), + ElemType: RootBucketInfo{}.Type(ctx), }, "storage_configuration_id": types.StringType, "storage_configuration_name": types.StringType, @@ -2040,9 +4206,56 @@ func (a StsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of StsRole in the Terraform plugin framework type -// system. -func (a StsRole) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StsRole{} + +// Equal implements basetypes.ObjectValuable. +func (o StsRole) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StsRole) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StsRole) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StsRole) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StsRole) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StsRole) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StsRole) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "external_id": types.StringType, @@ -2071,9 +4284,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2133,9 +4393,56 @@ func (a UpdateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of UpdateWorkspaceRequest in the Terraform plugin framework type -// system. -func (a UpdateWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateWorkspaceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_region": types.StringType, @@ -2211,9 +4518,56 @@ func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of UpsertPrivateAccessSettingsRequest in the Terraform plugin framework type -// system. -func (a UpsertPrivateAccessSettingsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpsertPrivateAccessSettingsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpsertPrivateAccessSettingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allowed_vpc_endpoint_ids": basetypes.ListType{ @@ -2285,9 +4639,56 @@ func (a VpcEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of VpcEndpoint in the Terraform plugin framework type -// system. -func (a VpcEndpoint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = VpcEndpoint{} + +// Equal implements basetypes.ObjectValuable. +func (o VpcEndpoint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o VpcEndpoint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o VpcEndpoint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o VpcEndpoint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o VpcEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o VpcEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o VpcEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, @@ -2295,7 +4696,7 @@ func (a VpcEndpoint) ToObjectType(ctx context.Context) types.ObjectType { "aws_endpoint_service_id": types.StringType, "aws_vpc_endpoint_id": types.StringType, "gcp_vpc_endpoint_info": basetypes.ListType{ - ElemType: GcpVpcEndpointInfo{}.ToObjectType(ctx), + ElemType: GcpVpcEndpointInfo{}.Type(ctx), }, "region": types.StringType, "state": types.StringType, @@ -2430,19 +4831,66 @@ func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of Workspace in the Terraform plugin framework type -// system. -func (a Workspace) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Workspace{} + +// Equal implements basetypes.ObjectValuable. +func (o Workspace) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Workspace) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Workspace) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Workspace) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Workspace) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Workspace) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Workspace) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "aws_region": types.StringType, "azure_workspace_info": basetypes.ListType{ - ElemType: AzureWorkspaceInfo{}.ToObjectType(ctx), + ElemType: AzureWorkspaceInfo{}.Type(ctx), }, "cloud": types.StringType, "cloud_resource_container": basetypes.ListType{ - ElemType: CloudResourceContainer{}.ToObjectType(ctx), + ElemType: CloudResourceContainer{}.Type(ctx), }, "creation_time": types.Int64Type, "credentials_id": types.StringType, @@ -2451,13 +4899,13 @@ func (a Workspace) ToObjectType(ctx context.Context) types.ObjectType { }, "deployment_name": types.StringType, "external_customer_info": basetypes.ListType{ - ElemType: ExternalCustomerInfo{}.ToObjectType(ctx), + ElemType: ExternalCustomerInfo{}.Type(ctx), }, "gcp_managed_network_config": basetypes.ListType{ - ElemType: GcpManagedNetworkConfig{}.ToObjectType(ctx), + ElemType: GcpManagedNetworkConfig{}.Type(ctx), }, "gke_config": basetypes.ListType{ - ElemType: GkeConfig{}.ToObjectType(ctx), + ElemType: GkeConfig{}.Type(ctx), }, "is_no_public_ip_enabled": types.BoolType, "location": types.StringType, @@ -2474,3 +4922,46 @@ func (a Workspace) ToObjectType(ctx context.Context) types.ObjectType { }, } } + +// This enumeration represents the type of Databricks VPC [endpoint service] +// that was used when creating this VPC endpoint. +// +// [endpoint service]: https://docs.aws.amazon.com/vpc/latest/privatelink/endpoint-service.html + +// The AWS resource associated with this error: credentials, VPC, subnet, +// security group, or network ACL. + +// Specifies the network connectivity types for the GKE nodes and the GKE master +// network. +// +// Set to `PRIVATE_NODE_PUBLIC_MASTER` for a private GKE cluster for the +// workspace. The GKE nodes will not have public IPs. +// +// Set to `PUBLIC_NODE_PUBLIC_MASTER` for a public GKE cluster. The nodes of a +// public GKE cluster have public IP addresses. + +// Possible values are: * `MANAGED_SERVICES`: Encrypts notebook and secret data +// in the control plane * `STORAGE`: Encrypts the workspace's root S3 bucket +// (root DBFS and system data) and, optionally, cluster EBS volumes. + +// The pricing tier of the workspace. For pricing tier information, see [AWS +// Pricing]. +// +// [AWS Pricing]: https://databricks.com/product/aws-pricing + +// The private access level controls which VPC endpoints can connect to the UI +// or API of any workspace that attaches this private access settings object. * +// `ACCOUNT` level access (the default) allows only VPC endpoints that are +// registered in your Databricks account connect to your workspace. * `ENDPOINT` +// level access allows only specified VPC endpoints connect to your workspace. +// For details, see `allowed_vpc_endpoint_ids`. + +// The status of this network configuration object in terms of its use in a +// workspace: * `UNATTACHED`: Unattached. * `VALID`: Valid. * `BROKEN`: Broken. +// * `WARNED`: Warned. + +// The AWS resource associated with this warning: a subnet or a security group. + +// The status of the workspace. For workspace creation, usually it is set to +// `PROVISIONING` initially. Continue to check the status until the status is +// `RUNNING`. diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index f0243d949a..a0642b6151 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -12,14 +12,18 @@ package serving_tf import ( "context" + "fmt" "io" "reflect" "github.com/databricks/databricks-sdk-go/service/oauth2" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/oauth2_tf" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type Ai21LabsConfig struct { @@ -52,9 +56,56 @@ func (a Ai21LabsConfig) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of Ai21LabsConfig in the Terraform plugin framework type -// system. -func (a Ai21LabsConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Ai21LabsConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Ai21LabsConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai21labs_api_key": types.StringType, @@ -101,22 +152,69 @@ func (a AiGatewayConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of AiGatewayConfig in the Terraform plugin framework type -// system. -func (a AiGatewayConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.ToObjectType(ctx), + ElemType: AiGatewayGuardrails{}.Type(ctx), }, "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.ToObjectType(ctx), + ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), }, "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.ToObjectType(ctx), + ElemType: AiGatewayRateLimit{}.Type(ctx), }, "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.ToObjectType(ctx), + ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), }, }, } @@ -156,16 +254,63 @@ func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of AiGatewayGuardrailParameters in the Terraform plugin framework type -// system. -func (a AiGatewayGuardrailParameters) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayGuardrailParameters{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "invalid_keywords": basetypes.ListType{ ElemType: types.StringType, }, "pii": basetypes.ListType{ - ElemType: AiGatewayGuardrailPiiBehavior{}.ToObjectType(ctx), + ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx), }, "safety": types.BoolType, "valid_topics": basetypes.ListType{ @@ -202,9 +347,56 @@ func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of AiGatewayGuardrailPiiBehavior in the Terraform plugin framework type -// system. -func (a AiGatewayGuardrailPiiBehavior) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayGuardrailPiiBehavior{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayGuardrailPiiBehavior) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "behavior": types.StringType, @@ -239,16 +431,63 @@ func (a AiGatewayGuardrails) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of AiGatewayGuardrails in the Terraform plugin framework type -// system. -func (a AiGatewayGuardrails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayGuardrails{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayGuardrails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "input": basetypes.ListType{ - ElemType: AiGatewayGuardrailParameters{}.ToObjectType(ctx), + ElemType: AiGatewayGuardrailParameters{}.Type(ctx), }, "output": basetypes.ListType{ - ElemType: AiGatewayGuardrailParameters{}.ToObjectType(ctx), + ElemType: AiGatewayGuardrailParameters{}.Type(ctx), }, }, } @@ -287,9 +526,56 @@ func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of AiGatewayInferenceTableConfig in the Terraform plugin framework type -// system. -func (a AiGatewayInferenceTableConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayInferenceTableConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayInferenceTableConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -329,9 +615,56 @@ func (a AiGatewayRateLimit) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of AiGatewayRateLimit in the Terraform plugin framework type -// system. -func (a AiGatewayRateLimit) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayRateLimit{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayRateLimit) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "calls": types.Int64Type, @@ -363,9 +696,56 @@ func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of AiGatewayUsageTrackingConfig in the Terraform plugin framework type -// system. -func (a AiGatewayUsageTrackingConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AiGatewayUsageTrackingConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AiGatewayUsageTrackingConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -424,9 +804,56 @@ func (a AmazonBedrockConfig) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of AmazonBedrockConfig in the Terraform plugin framework type -// system. -func (a AmazonBedrockConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AmazonBedrockConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AmazonBedrockConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_access_key_id": types.StringType, @@ -469,9 +896,56 @@ func (a AnthropicConfig) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of AnthropicConfig in the Terraform plugin framework type -// system. -func (a AnthropicConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AnthropicConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o AnthropicConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AnthropicConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AnthropicConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AnthropicConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AnthropicConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AnthropicConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AnthropicConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "anthropic_api_key": types.StringType, @@ -511,9 +985,56 @@ func (a AutoCaptureConfigInput) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of AutoCaptureConfigInput in the Terraform plugin framework type -// system. -func (a AutoCaptureConfigInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AutoCaptureConfigInput{} + +// Equal implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AutoCaptureConfigInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, @@ -556,16 +1077,63 @@ func (a AutoCaptureConfigOutput) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of AutoCaptureConfigOutput in the Terraform plugin framework type -// system. -func (a AutoCaptureConfigOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AutoCaptureConfigOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AutoCaptureConfigOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog_name": types.StringType, "enabled": types.BoolType, "schema_name": types.StringType, "state": basetypes.ListType{ - ElemType: AutoCaptureState{}.ToObjectType(ctx), + ElemType: AutoCaptureState{}.Type(ctx), }, "table_name_prefix": types.StringType, }, @@ -595,13 +1163,60 @@ func (a AutoCaptureState) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of AutoCaptureState in the Terraform plugin framework type -// system. -func (a AutoCaptureState) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AutoCaptureState{} + +// Equal implements basetypes.ObjectValuable. +func (o AutoCaptureState) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AutoCaptureState) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AutoCaptureState) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AutoCaptureState) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AutoCaptureState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AutoCaptureState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AutoCaptureState) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "payload_table": basetypes.ListType{ - ElemType: PayloadTable{}.ToObjectType(ctx), + ElemType: PayloadTable{}.Type(ctx), }, }, } @@ -634,9 +1249,56 @@ func (a BuildLogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of BuildLogsRequest in the Terraform plugin framework type -// system. -func (a BuildLogsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BuildLogsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o BuildLogsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BuildLogsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BuildLogsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BuildLogsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BuildLogsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BuildLogsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BuildLogsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -667,9 +1329,56 @@ func (a BuildLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of BuildLogsResponse in the Terraform plugin framework type -// system. -func (a BuildLogsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BuildLogsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o BuildLogsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BuildLogsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BuildLogsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BuildLogsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BuildLogsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BuildLogsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BuildLogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "logs": types.StringType, @@ -701,9 +1410,56 @@ func (a ChatMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of ChatMessage in the Terraform plugin framework type -// system. -func (a ChatMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ChatMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o ChatMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ChatMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ChatMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ChatMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ChatMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ChatMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ChatMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -745,9 +1501,56 @@ func (a CohereConfig) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of CohereConfig in the Terraform plugin framework type -// system. -func (a CohereConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CohereConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o CohereConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CohereConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CohereConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CohereConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CohereConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CohereConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CohereConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cohere_api_base": types.StringType, @@ -799,24 +1602,71 @@ func (a CreateServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of CreateServingEndpoint in the Terraform plugin framework type -// system. -func (a CreateServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateServingEndpoint{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.ToObjectType(ctx), + ElemType: AiGatewayConfig{}.Type(ctx), }, "config": basetypes.ListType{ - ElemType: EndpointCoreConfigInput{}.ToObjectType(ctx), + ElemType: EndpointCoreConfigInput{}.Type(ctx), }, "name": types.StringType, "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.ToObjectType(ctx), + ElemType: RateLimit{}.Type(ctx), }, "route_optimized": types.BoolType, "tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToObjectType(ctx), + ElemType: EndpointTag{}.Type(ctx), }, }, } @@ -859,9 +1709,56 @@ func (a DatabricksModelServingConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DatabricksModelServingConfig in the Terraform plugin framework type -// system. -func (a DatabricksModelServingConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DatabricksModelServingConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DatabricksModelServingConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "databricks_api_token": types.StringType, @@ -900,9 +1797,56 @@ func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of DataframeSplitInput in the Terraform plugin framework type -// system. -func (a DataframeSplitInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DataframeSplitInput{} + +// Equal implements basetypes.ObjectValuable. +func (o DataframeSplitInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DataframeSplitInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DataframeSplitInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DataframeSplitInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DataframeSplitInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DataframeSplitInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DataframeSplitInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns": basetypes.ListType{ @@ -938,9 +1882,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -969,9 +1960,56 @@ func (a DeleteServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteServingEndpointRequest in the Terraform plugin framework type -// system. -func (a DeleteServingEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteServingEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteServingEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1006,9 +2044,56 @@ func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of EmbeddingsV1ResponseEmbeddingElement in the Terraform plugin framework type -// system. -func (a EmbeddingsV1ResponseEmbeddingElement) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EmbeddingsV1ResponseEmbeddingElement{} + +// Equal implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EmbeddingsV1ResponseEmbeddingElement) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding": basetypes.ListType{ @@ -1059,23 +2144,70 @@ func (a EndpointCoreConfigInput) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of EndpointCoreConfigInput in the Terraform plugin framework type -// system. -func (a EndpointCoreConfigInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointCoreConfigInput{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigInput{}.ToObjectType(ctx), + ElemType: AutoCaptureConfigInput{}.Type(ctx), }, "name": types.StringType, "served_entities": basetypes.ListType{ - ElemType: ServedEntityInput{}.ToObjectType(ctx), + ElemType: ServedEntityInput{}.Type(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelInput{}.ToObjectType(ctx), + ElemType: ServedModelInput{}.Type(ctx), }, "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.ToObjectType(ctx), + ElemType: TrafficConfig{}.Type(ctx), }, }, } @@ -1118,23 +2250,70 @@ func (a EndpointCoreConfigOutput) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of EndpointCoreConfigOutput in the Terraform plugin framework type -// system. -func (a EndpointCoreConfigOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointCoreConfigOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigOutput{}.ToObjectType(ctx), + ElemType: AutoCaptureConfigOutput{}.Type(ctx), }, "config_version": types.Int64Type, "served_entities": basetypes.ListType{ - ElemType: ServedEntityOutput{}.ToObjectType(ctx), + ElemType: ServedEntityOutput{}.Type(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelOutput{}.ToObjectType(ctx), + ElemType: ServedModelOutput{}.Type(ctx), }, "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.ToObjectType(ctx), + ElemType: TrafficConfig{}.Type(ctx), }, }, } @@ -1168,16 +2347,63 @@ func (a EndpointCoreConfigSummary) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of EndpointCoreConfigSummary in the Terraform plugin framework type -// system. -func (a EndpointCoreConfigSummary) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointCoreConfigSummary{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointCoreConfigSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "served_entities": basetypes.ListType{ - ElemType: ServedEntitySpec{}.ToObjectType(ctx), + ElemType: ServedEntitySpec{}.Type(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelSpec{}.ToObjectType(ctx), + ElemType: ServedModelSpec{}.Type(ctx), }, }, } @@ -1224,24 +2450,71 @@ func (a EndpointPendingConfig) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of EndpointPendingConfig in the Terraform plugin framework type -// system. -func (a EndpointPendingConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointPendingConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigOutput{}.ToObjectType(ctx), + ElemType: AutoCaptureConfigOutput{}.Type(ctx), }, "config_version": types.Int64Type, "served_entities": basetypes.ListType{ - ElemType: ServedEntityOutput{}.ToObjectType(ctx), + ElemType: ServedEntityOutput{}.Type(ctx), }, "served_models": basetypes.ListType{ - ElemType: ServedModelOutput{}.ToObjectType(ctx), + ElemType: ServedModelOutput{}.Type(ctx), }, "start_time": types.Int64Type, "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.ToObjectType(ctx), + ElemType: TrafficConfig{}.Type(ctx), }, }, } @@ -1278,9 +2551,56 @@ func (a EndpointState) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of EndpointState in the Terraform plugin framework type -// system. -func (a EndpointState) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointState{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointState) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointState) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointState) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointState) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointState) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config_update": types.StringType, @@ -1313,9 +2633,56 @@ func (a EndpointTag) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of EndpointTag in the Terraform plugin framework type -// system. -func (a EndpointTag) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointTag{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointTag) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointTag) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointTag) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointTag) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1348,9 +2715,56 @@ func (a ExportMetricsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExportMetricsRequest in the Terraform plugin framework type -// system. -func (a ExportMetricsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExportMetricsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExportMetricsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1379,9 +2793,56 @@ func (a ExportMetricsResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExportMetricsResponse in the Terraform plugin framework type -// system. -func (a ExportMetricsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExportMetricsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExportMetricsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "contents": types.ObjectType{}, @@ -1445,35 +2906,82 @@ func (a ExternalModel) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of ExternalModel in the Terraform plugin framework type -// system. -func (a ExternalModel) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExternalModel{} + +// Equal implements basetypes.ObjectValuable. +func (o ExternalModel) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExternalModel) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExternalModel) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExternalModel) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExternalModel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExternalModel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExternalModel) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai21labs_config": basetypes.ListType{ - ElemType: Ai21LabsConfig{}.ToObjectType(ctx), + ElemType: Ai21LabsConfig{}.Type(ctx), }, "amazon_bedrock_config": basetypes.ListType{ - ElemType: AmazonBedrockConfig{}.ToObjectType(ctx), + ElemType: AmazonBedrockConfig{}.Type(ctx), }, "anthropic_config": basetypes.ListType{ - ElemType: AnthropicConfig{}.ToObjectType(ctx), + ElemType: AnthropicConfig{}.Type(ctx), }, "cohere_config": basetypes.ListType{ - ElemType: CohereConfig{}.ToObjectType(ctx), + ElemType: CohereConfig{}.Type(ctx), }, "databricks_model_serving_config": basetypes.ListType{ - ElemType: DatabricksModelServingConfig{}.ToObjectType(ctx), + ElemType: DatabricksModelServingConfig{}.Type(ctx), }, "google_cloud_vertex_ai_config": basetypes.ListType{ - ElemType: GoogleCloudVertexAiConfig{}.ToObjectType(ctx), + ElemType: GoogleCloudVertexAiConfig{}.Type(ctx), }, "name": types.StringType, "openai_config": basetypes.ListType{ - ElemType: OpenAiConfig{}.ToObjectType(ctx), + ElemType: OpenAiConfig{}.Type(ctx), }, "palm_config": basetypes.ListType{ - ElemType: PaLmConfig{}.ToObjectType(ctx), + ElemType: PaLmConfig{}.Type(ctx), }, "provider": types.StringType, "task": types.StringType, @@ -1507,9 +3015,56 @@ func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExternalModelUsageElement in the Terraform plugin framework type -// system. -func (a ExternalModelUsageElement) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExternalModelUsageElement{} + +// Equal implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExternalModelUsageElement) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "completion_tokens": types.Int64Type, @@ -1547,9 +3102,56 @@ func (a FoundationModel) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of FoundationModel in the Terraform plugin framework type -// system. -func (a FoundationModel) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FoundationModel{} + +// Equal implements basetypes.ObjectValuable. +func (o FoundationModel) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FoundationModel) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FoundationModel) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FoundationModel) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FoundationModel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FoundationModel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FoundationModel) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1584,9 +3186,56 @@ func (a GetOpenApiRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetOpenApiRequest in the Terraform plugin framework type -// system. -func (a GetOpenApiRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetOpenApiRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetOpenApiRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1616,9 +3265,56 @@ func (a GetOpenApiResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetOpenApiResponse in the Terraform plugin framework type -// system. -func (a GetOpenApiResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetOpenApiResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetOpenApiResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1647,9 +3343,56 @@ func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetServingEndpointPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetServingEndpointPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetServingEndpointPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "serving_endpoint_id": types.StringType, @@ -1681,13 +3424,60 @@ func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// ToObjectType returns the representation of GetServingEndpointPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetServingEndpointPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetServingEndpointPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: ServingEndpointPermissionsDescription{}.ToObjectType(ctx), + ElemType: ServingEndpointPermissionsDescription{}.Type(ctx), }, }, } @@ -1716,9 +3506,56 @@ func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetServingEndpointPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetServingEndpointPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetServingEndpointPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "serving_endpoint_id": types.StringType, @@ -1749,9 +3586,56 @@ func (a GetServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetServingEndpointRequest in the Terraform plugin framework type -// system. -func (a GetServingEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetServingEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetServingEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1806,9 +3690,56 @@ func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of GoogleCloudVertexAiConfig in the Terraform plugin framework type -// system. -func (a GoogleCloudVertexAiConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GoogleCloudVertexAiConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GoogleCloudVertexAiConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "private_key": types.StringType, @@ -1843,13 +3774,60 @@ func (a ListEndpointsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListEndpointsResponse in the Terraform plugin framework type -// system. -func (a ListEndpointsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListEndpointsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListEndpointsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoints": basetypes.ListType{ - ElemType: ServingEndpoint{}.ToObjectType(ctx), + ElemType: ServingEndpoint{}.Type(ctx), }, }, } @@ -1882,9 +3860,56 @@ func (a LogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of LogsRequest in the Terraform plugin framework type -// system. -func (a LogsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LogsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o LogsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LogsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LogsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LogsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LogsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LogsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LogsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1917,13 +3942,60 @@ func (a ModelDataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ModelDataPlaneInfo in the Terraform plugin framework type -// system. -func (a ModelDataPlaneInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ModelDataPlaneInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ModelDataPlaneInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_info": basetypes.ListType{ - ElemType: oauth2_tf.DataPlaneInfo{}.ToObjectType(ctx), + ElemType: oauth2_tf.DataPlaneInfo{}.Type(ctx), }, }, } @@ -2000,9 +4072,56 @@ func (a OpenAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of OpenAiConfig in the Terraform plugin framework type -// system. -func (a OpenAiConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OpenAiConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o OpenAiConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OpenAiConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OpenAiConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OpenAiConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OpenAiConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OpenAiConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OpenAiConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "microsoft_entra_client_id": types.StringType, @@ -2050,9 +4169,56 @@ func (a PaLmConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of PaLmConfig in the Terraform plugin framework type -// system. -func (a PaLmConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PaLmConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o PaLmConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PaLmConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PaLmConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PaLmConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PaLmConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PaLmConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PaLmConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "palm_api_key": types.StringType, @@ -2091,13 +4257,60 @@ func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of PatchServingEndpointTags in the Terraform plugin framework type -// system. -func (a PatchServingEndpointTags) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PatchServingEndpointTags{} + +// Equal implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PatchServingEndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "add_tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToObjectType(ctx), + ElemType: EndpointTag{}.Type(ctx), }, "delete_tags": basetypes.ListType{ ElemType: types.StringType, @@ -2133,9 +4346,56 @@ func (a PayloadTable) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of PayloadTable in the Terraform plugin framework type -// system. -func (a PayloadTable) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PayloadTable{} + +// Equal implements basetypes.ObjectValuable. +func (o PayloadTable) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PayloadTable) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PayloadTable) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PayloadTable) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PayloadTable) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PayloadTable) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PayloadTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -2187,23 +4447,70 @@ func (a PutAiGatewayRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of PutAiGatewayRequest in the Terraform plugin framework type -// system. -func (a PutAiGatewayRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutAiGatewayRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.ToObjectType(ctx), + ElemType: AiGatewayGuardrails{}.Type(ctx), }, "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.ToObjectType(ctx), + ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), }, "name": types.StringType, "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.ToObjectType(ctx), + ElemType: AiGatewayRateLimit{}.Type(ctx), }, "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.ToObjectType(ctx), + ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), }, }, } @@ -2247,22 +4554,69 @@ func (a PutAiGatewayResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of PutAiGatewayResponse in the Terraform plugin framework type -// system. -func (a PutAiGatewayResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutAiGatewayResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.ToObjectType(ctx), + ElemType: AiGatewayGuardrails{}.Type(ctx), }, "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.ToObjectType(ctx), + ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), }, "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.ToObjectType(ctx), + ElemType: AiGatewayRateLimit{}.Type(ctx), }, "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.ToObjectType(ctx), + ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), }, }, } @@ -2296,14 +4650,61 @@ func (a PutRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of PutRequest in the Terraform plugin framework type -// system. -func (a PutRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o PutRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.ToObjectType(ctx), + ElemType: RateLimit{}.Type(ctx), }, }, } @@ -2333,13 +4734,60 @@ func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of PutResponse in the Terraform plugin framework type -// system. -func (a PutResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PutResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.ToObjectType(ctx), + ElemType: RateLimit{}.Type(ctx), }, }, } @@ -2421,16 +4869,63 @@ func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of QueryEndpointInput in the Terraform plugin framework type -// system. -func (a QueryEndpointInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryEndpointInput{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryEndpointInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryEndpointInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryEndpointInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryEndpointInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryEndpointInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryEndpointInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataframe_records": basetypes.ListType{ ElemType: types.ObjectType{}, }, "dataframe_split": basetypes.ListType{ - ElemType: DataframeSplitInput{}.ToObjectType(ctx), + ElemType: DataframeSplitInput{}.Type(ctx), }, "extra_params": basetypes.MapType{ ElemType: types.StringType, @@ -2442,7 +4937,7 @@ func (a QueryEndpointInput) ToObjectType(ctx context.Context) types.ObjectType { }, "max_tokens": types.Int64Type, "messages": basetypes.ListType{ - ElemType: ChatMessage{}.ToObjectType(ctx), + ElemType: ChatMessage{}.Type(ctx), }, "n": types.Int64Type, "name": types.StringType, @@ -2509,17 +5004,64 @@ func (a QueryEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of QueryEndpointResponse in the Terraform plugin framework type -// system. -func (a QueryEndpointResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryEndpointResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "choices": basetypes.ListType{ - ElemType: V1ResponseChoiceElement{}.ToObjectType(ctx), + ElemType: V1ResponseChoiceElement{}.Type(ctx), }, "created": types.Int64Type, "data": basetypes.ListType{ - ElemType: EmbeddingsV1ResponseEmbeddingElement{}.ToObjectType(ctx), + ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx), }, "id": types.StringType, "model": types.StringType, @@ -2529,7 +5071,7 @@ func (a QueryEndpointResponse) ToObjectType(ctx context.Context) types.ObjectTyp }, "served-model-name": types.StringType, "usage": basetypes.ListType{ - ElemType: ExternalModelUsageElement{}.ToObjectType(ctx), + ElemType: ExternalModelUsageElement{}.Type(ctx), }, }, } @@ -2565,9 +5107,56 @@ func (a RateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of RateLimit in the Terraform plugin framework type -// system. -func (a RateLimit) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RateLimit{} + +// Equal implements basetypes.ObjectValuable. +func (o RateLimit) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RateLimit) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RateLimit) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RateLimit) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RateLimit) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RateLimit) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RateLimit) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "calls": types.Int64Type, @@ -2602,9 +5191,56 @@ func (a Route) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Route in the Terraform plugin framework type -// system. -func (a Route) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Route{} + +// Equal implements basetypes.ObjectValuable. +func (o Route) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Route) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Route) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Route) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Route) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Route) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Route) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "served_model_name": types.StringType, @@ -2694,9 +5330,56 @@ func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ServedEntityInput in the Terraform plugin framework type -// system. -func (a ServedEntityInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedEntityInput{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedEntityInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedEntityInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedEntityInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedEntityInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedEntityInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedEntityInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServedEntityInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "entity_name": types.StringType, @@ -2705,7 +5388,7 @@ func (a ServedEntityInput) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.ToObjectType(ctx), + ElemType: ExternalModel{}.Type(ctx), }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, @@ -2803,9 +5486,56 @@ func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ServedEntityOutput in the Terraform plugin framework type -// system. -func (a ServedEntityOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedEntityOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedEntityOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedEntityOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedEntityOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedEntityOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedEntityOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedEntityOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServedEntityOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -2816,10 +5546,10 @@ func (a ServedEntityOutput) ToObjectType(ctx context.Context) types.ObjectType { ElemType: types.StringType, }, "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.ToObjectType(ctx), + ElemType: ExternalModel{}.Type(ctx), }, "foundation_model": basetypes.ListType{ - ElemType: FoundationModel{}.ToObjectType(ctx), + ElemType: FoundationModel{}.Type(ctx), }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, @@ -2827,7 +5557,7 @@ func (a ServedEntityOutput) ToObjectType(ctx context.Context) types.ObjectType { "name": types.StringType, "scale_to_zero_enabled": types.BoolType, "state": basetypes.ListType{ - ElemType: ServedModelState{}.ToObjectType(ctx), + ElemType: ServedModelState{}.Type(ctx), }, "workload_size": types.StringType, "workload_type": types.StringType, @@ -2857,38 +5587,85 @@ type ServedEntitySpec struct { Name types.String `tfsdk:"name" tf:"optional"` } -func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ServedEntitySpec) { +func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ServedEntitySpec) { +} + +func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringRead(existingState ServedEntitySpec) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedEntitySpec. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "external_model": reflect.TypeOf(ExternalModel{}), + "foundation_model": reflect.TypeOf(FoundationModel{}), + } +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedEntitySpec{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedEntitySpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedEntitySpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedEntitySpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedEntitySpec) String() string { + return fmt.Sprintf("%#v", o) } -func (newState *ServedEntitySpec) SyncEffectiveFieldsDuringRead(existingState ServedEntitySpec) { +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedEntitySpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in ServedEntitySpec. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "external_model": reflect.TypeOf(ExternalModel{}), - "foundation_model": reflect.TypeOf(FoundationModel{}), +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedEntitySpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of ServedEntitySpec in the Terraform plugin framework type -// system. -func (a ServedEntitySpec) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o ServedEntitySpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "entity_name": types.StringType, "entity_version": types.StringType, "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.ToObjectType(ctx), + ElemType: ExternalModel{}.Type(ctx), }, "foundation_model": basetypes.ListType{ - ElemType: FoundationModel{}.ToObjectType(ctx), + ElemType: FoundationModel{}.Type(ctx), }, "name": types.StringType, }, @@ -2962,9 +5739,56 @@ func (a ServedModelInput) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ServedModelInput in the Terraform plugin framework type -// system. -func (a ServedModelInput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedModelInput{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedModelInput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedModelInput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedModelInput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedModelInput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedModelInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedModelInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServedModelInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "environment_vars": basetypes.MapType{ @@ -3049,9 +5873,56 @@ func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ServedModelOutput in the Terraform plugin framework type -// system. -func (a ServedModelOutput) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedModelOutput{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedModelOutput) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedModelOutput) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedModelOutput) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedModelOutput) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedModelOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedModelOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServedModelOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, @@ -3065,7 +5936,7 @@ func (a ServedModelOutput) ToObjectType(ctx context.Context) types.ObjectType { "name": types.StringType, "scale_to_zero_enabled": types.BoolType, "state": basetypes.ListType{ - ElemType: ServedModelState{}.ToObjectType(ctx), + ElemType: ServedModelState{}.Type(ctx), }, "workload_size": types.StringType, "workload_type": types.StringType, @@ -3101,9 +5972,56 @@ func (a ServedModelSpec) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ServedModelSpec in the Terraform plugin framework type -// system. -func (a ServedModelSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedModelSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedModelSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedModelSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedModelSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedModelSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedModelSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedModelSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServedModelSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "model_name": types.StringType, @@ -3148,9 +6066,56 @@ func (a ServedModelState) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of ServedModelState in the Terraform plugin framework type -// system. -func (a ServedModelState) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServedModelState{} + +// Equal implements basetypes.ObjectValuable. +func (o ServedModelState) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServedModelState) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServedModelState) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServedModelState) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServedModelState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServedModelState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServedModelState) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "deployment": types.StringType, @@ -3182,9 +6147,56 @@ func (a ServerLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ServerLogsResponse in the Terraform plugin framework type -// system. -func (a ServerLogsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServerLogsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ServerLogsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServerLogsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServerLogsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServerLogsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServerLogsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServerLogsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServerLogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "logs": types.StringType, @@ -3239,16 +6251,63 @@ func (a ServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of ServingEndpoint in the Terraform plugin framework type -// system. -func (a ServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpoint{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpoint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpoint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpoint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpoint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.ToObjectType(ctx), + ElemType: AiGatewayConfig{}.Type(ctx), }, "config": basetypes.ListType{ - ElemType: EndpointCoreConfigSummary{}.ToObjectType(ctx), + ElemType: EndpointCoreConfigSummary{}.Type(ctx), }, "creation_timestamp": types.Int64Type, "creator": types.StringType, @@ -3256,10 +6315,10 @@ func (a ServingEndpoint) ToObjectType(ctx context.Context) types.ObjectType { "last_updated_timestamp": types.Int64Type, "name": types.StringType, "state": basetypes.ListType{ - ElemType: EndpointState{}.ToObjectType(ctx), + ElemType: EndpointState{}.Type(ctx), }, "tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToObjectType(ctx), + ElemType: EndpointTag{}.Type(ctx), }, "task": types.StringType, }, @@ -3294,9 +6353,56 @@ func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of ServingEndpointAccessControlRequest in the Terraform plugin framework type -// system. -func (a ServingEndpointAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -3339,13 +6445,60 @@ func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of ServingEndpointAccessControlResponse in the Terraform plugin framework type -// system. -func (a ServingEndpointAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: ServingEndpointPermission{}.ToObjectType(ctx), + ElemType: ServingEndpointPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -3415,36 +6568,83 @@ func (a ServingEndpointDetailed) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ServingEndpointDetailed in the Terraform plugin framework type -// system. -func (a ServingEndpointDetailed) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointDetailed{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.ToObjectType(ctx), + ElemType: AiGatewayConfig{}.Type(ctx), }, "config": basetypes.ListType{ - ElemType: EndpointCoreConfigOutput{}.ToObjectType(ctx), + ElemType: EndpointCoreConfigOutput{}.Type(ctx), }, "creation_timestamp": types.Int64Type, "creator": types.StringType, "data_plane_info": basetypes.ListType{ - ElemType: ModelDataPlaneInfo{}.ToObjectType(ctx), + ElemType: ModelDataPlaneInfo{}.Type(ctx), }, "endpoint_url": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "name": types.StringType, "pending_config": basetypes.ListType{ - ElemType: EndpointPendingConfig{}.ToObjectType(ctx), + ElemType: EndpointPendingConfig{}.Type(ctx), }, "permission_level": types.StringType, "route_optimized": types.BoolType, "state": basetypes.ListType{ - ElemType: EndpointState{}.ToObjectType(ctx), + ElemType: EndpointState{}.Type(ctx), }, "tags": basetypes.ListType{ - ElemType: EndpointTag{}.ToObjectType(ctx), + ElemType: EndpointTag{}.Type(ctx), }, "task": types.StringType, }, @@ -3478,9 +6678,56 @@ func (a ServingEndpointPermission) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ServingEndpointPermission in the Terraform plugin framework type -// system. -func (a ServingEndpointPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -3519,13 +6766,60 @@ func (a ServingEndpointPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ServingEndpointPermissions in the Terraform plugin framework type -// system. -func (a ServingEndpointPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ServingEndpointAccessControlResponse{}.ToObjectType(ctx), + ElemType: ServingEndpointAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -3556,9 +6850,56 @@ func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of ServingEndpointPermissionsDescription in the Terraform plugin framework type -// system. -func (a ServingEndpointPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -3592,13 +6933,60 @@ func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of ServingEndpointPermissionsRequest in the Terraform plugin framework type -// system. -func (a ServingEndpointPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServingEndpointPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: ServingEndpointAccessControlRequest{}.ToObjectType(ctx), + ElemType: ServingEndpointAccessControlRequest{}.Type(ctx), }, "serving_endpoint_id": types.StringType, }, @@ -3629,13 +7017,60 @@ func (a TrafficConfig) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of TrafficConfig in the Terraform plugin framework type -// system. -func (a TrafficConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TrafficConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o TrafficConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TrafficConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TrafficConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TrafficConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TrafficConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TrafficConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TrafficConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "routes": basetypes.ListType{ - ElemType: Route{}.ToObjectType(ctx), + ElemType: Route{}.Type(ctx), }, }, } @@ -3673,18 +7108,139 @@ func (a V1ResponseChoiceElement) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of V1ResponseChoiceElement in the Terraform plugin framework type -// system. -func (a V1ResponseChoiceElement) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = V1ResponseChoiceElement{} + +// Equal implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o V1ResponseChoiceElement) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "finishReason": types.StringType, "index": types.Int64Type, "logprobs": types.Int64Type, "message": basetypes.ListType{ - ElemType: ChatMessage{}.ToObjectType(ctx), + ElemType: ChatMessage{}.Type(ctx), }, "text": types.StringType, }, } } + +// Behavior for PII filter. Currently only 'BLOCK' is supported. If 'BLOCK' is +// set for the input guardrail and the request contains PII, the request is not +// sent to the model server and 400 status code is returned; if 'BLOCK' is set +// for the output guardrail and the model response contains PII, the PII info in +// the response is redacted and 400 status code is returned. + +// Key field for a rate limit. Currently, only 'user' and 'endpoint' are +// supported, with 'endpoint' being the default if not specified. + +// Renewal period field for a rate limit. Currently, only 'minute' is supported. + +// The underlying provider in Amazon Bedrock. Supported values (case +// insensitive) include: Anthropic, Cohere, AI21Labs, Amazon. + +// The role of the message. One of [system, user, assistant]. + +// This will always be 'embedding'. + +// The state of an endpoint's config update. This informs the user if the +// pending_config is in progress, if the update failed, or if there is no update +// in progress. Note that if the endpoint's config_update state value is +// IN_PROGRESS, another update can not be made until the update completes or +// fails." + +// The state of an endpoint, indicating whether or not the endpoint is +// queryable. An endpoint is READY if all of the served entities in its active +// configuration are ready. If any of the actively served entities are in a +// non-ready state, the endpoint state will be NOT_READY. + +// The name of the provider for the external model. Currently, the supported +// providers are 'ai21labs', 'anthropic', 'amazon-bedrock', 'cohere', +// 'databricks-model-serving', 'google-cloud-vertex-ai', 'openai', and 'palm'.", + +// The type of object returned by the __external/foundation model__ serving +// endpoint, one of [text_completion, chat.completion, list (of embeddings)]. + +// Key field for a serving endpoint rate limit. Currently, only 'user' and +// 'endpoint' are supported, with 'endpoint' being the default if not specified. + +// Renewal period field for a serving endpoint rate limit. Currently, only +// 'minute' is supported. + +// The workload size of the served model. The workload size corresponds to a +// range of provisioned concurrency that the compute will autoscale between. A +// single unit of provisioned concurrency can process one request at a time. +// Valid workload sizes are "Small" (4 - 4 provisioned concurrency), "Medium" (8 +// - 16 provisioned concurrency), and "Large" (16 - 64 provisioned concurrency). +// If scale-to-zero is enabled, the lower bound of the provisioned concurrency +// for each workload size will be 0. + +// The workload type of the served model. The workload type selects which type +// of compute to use in the endpoint. The default value for this parameter is +// "CPU". For deep learning workloads, GPU acceleration is available by +// selecting workload types like GPU_SMALL and others. See the available [GPU +// types]. +// +// [GPU types]: https://docs.databricks.com/machine-learning/model-serving/create-manage-serving-endpoints.html#gpu-workload-types + +// The state of the served entity deployment. DEPLOYMENT_CREATING indicates that +// the served entity is not ready yet because the deployment is still being +// created (i.e container image is building, model server is deploying for the +// first time, etc.). DEPLOYMENT_RECOVERING indicates that the served entity was +// previously in a ready state but no longer is and is attempting to recover. +// DEPLOYMENT_READY indicates that the served entity is ready to receive +// traffic. DEPLOYMENT_FAILED indicates that there was an error trying to bring +// up the served entity (e.g container image build failed, the model server +// failed to start due to a model loading error, etc.) DEPLOYMENT_ABORTED +// indicates that the deployment was terminated likely due to a failure in +// bringing up another served entity under the same endpoint and config version. + +// The permission level of the principal making the request. + +// Permission level diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 6ab16f9f5d..6a4ed0c2e8 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -12,11 +12,15 @@ package settings_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AibiDashboardEmbeddingAccessPolicy struct { @@ -40,9 +44,56 @@ func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of AibiDashboardEmbeddingAccessPolicy in the Terraform plugin framework type -// system. -func (a AibiDashboardEmbeddingAccessPolicy) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AibiDashboardEmbeddingAccessPolicy{} + +// Equal implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_policy_type": types.StringType, @@ -87,13 +138,60 @@ func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes(ctx cont } } -// ToObjectType returns the representation of AibiDashboardEmbeddingAccessPolicySetting in the Terraform plugin framework type -// system. -func (a AibiDashboardEmbeddingAccessPolicySetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AibiDashboardEmbeddingAccessPolicySetting{} + +// Equal implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingAccessPolicySetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aibi_dashboard_embedding_access_policy": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingAccessPolicy{}.ToObjectType(ctx), + ElemType: AibiDashboardEmbeddingAccessPolicy{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -124,9 +222,56 @@ func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes(ctx context. } } -// ToObjectType returns the representation of AibiDashboardEmbeddingApprovedDomains in the Terraform plugin framework type -// system. -func (a AibiDashboardEmbeddingApprovedDomains) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AibiDashboardEmbeddingApprovedDomains{} + +// Equal implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomains) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "approved_domains": basetypes.ListType{ @@ -173,13 +318,60 @@ func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes(ctx c } } -// ToObjectType returns the representation of AibiDashboardEmbeddingApprovedDomainsSetting in the Terraform plugin framework type -// system. -func (a AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AibiDashboardEmbeddingApprovedDomainsSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AibiDashboardEmbeddingApprovedDomainsSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingApprovedDomains{}.ToObjectType(ctx), + ElemType: AibiDashboardEmbeddingApprovedDomains{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -224,13 +416,60 @@ func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of AutomaticClusterUpdateSetting in the Terraform plugin framework type -// system. -func (a AutomaticClusterUpdateSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AutomaticClusterUpdateSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AutomaticClusterUpdateSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "automatic_cluster_update_workspace": basetypes.ListType{ - ElemType: ClusterAutoRestartMessage{}.ToObjectType(ctx), + ElemType: ClusterAutoRestartMessage{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -259,9 +498,56 @@ func (a BooleanMessage) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of BooleanMessage in the Terraform plugin framework type -// system. -func (a BooleanMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BooleanMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o BooleanMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BooleanMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BooleanMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BooleanMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BooleanMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BooleanMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BooleanMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.BoolType, @@ -306,18 +592,65 @@ func (a ClusterAutoRestartMessage) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ClusterAutoRestartMessage in the Terraform plugin framework type -// system. -func (a ClusterAutoRestartMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAutoRestartMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "can_toggle": types.BoolType, "enabled": types.BoolType, "enablement_details": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageEnablementDetails{}.ToObjectType(ctx), + ElemType: ClusterAutoRestartMessageEnablementDetails{}.Type(ctx), }, "maintenance_window": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.ToObjectType(ctx), + ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.Type(ctx), }, "restart_even_if_no_updates_available": types.BoolType, }, @@ -357,9 +690,56 @@ func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterAutoRestartMessageEnablementDetails in the Terraform plugin framework type -// system. -func (a ClusterAutoRestartMessageEnablementDetails) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAutoRestartMessageEnablementDetails{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageEnablementDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "forced_for_compliance_mode": types.BoolType, @@ -392,13 +772,60 @@ func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes(ctx con } } -// ToObjectType returns the representation of ClusterAutoRestartMessageMaintenanceWindow in the Terraform plugin framework type -// system. -func (a ClusterAutoRestartMessageMaintenanceWindow) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAutoRestartMessageMaintenanceWindow{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "week_day_based_schedule": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.ToObjectType(ctx), + ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.Type(ctx), }, }, } @@ -431,15 +858,62 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetCompl } } -// ToObjectType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule in the Terraform plugin framework type -// system. -func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "day_of_week": types.StringType, "frequency": types.StringType, "window_start_time": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.ToObjectType(ctx), + ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.Type(ctx), }, }, } @@ -468,9 +942,56 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFie return map[string]reflect.Type{} } -// ToObjectType returns the representation of ClusterAutoRestartMessageMaintenanceWindowWindowStartTime in the Terraform plugin framework type -// system. -func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{} + +// Equal implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "hours": types.Int64Type, @@ -506,9 +1027,56 @@ func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ComplianceSecurityProfile in the Terraform plugin framework type -// system. -func (a ComplianceSecurityProfile) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ComplianceSecurityProfile{} + +// Equal implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compliance_standards": basetypes.ListType{ @@ -557,13 +1125,60 @@ func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of ComplianceSecurityProfileSetting in the Terraform plugin framework type -// system. -func (a ComplianceSecurityProfileSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ComplianceSecurityProfileSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ComplianceSecurityProfileSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compliance_security_profile_workspace": basetypes.ListType{ - ElemType: ComplianceSecurityProfile{}.ToObjectType(ctx), + ElemType: ComplianceSecurityProfile{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -606,25 +1221,72 @@ func (a Config) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToObjectType returns the representation of Config in the Terraform plugin framework type -// system. -func (a Config) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Config{} + +// Equal implements basetypes.ObjectValuable. +func (o Config) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Config) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Config) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Config) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Config) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Config) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Config) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email": basetypes.ListType{ - ElemType: EmailConfig{}.ToObjectType(ctx), + ElemType: EmailConfig{}.Type(ctx), }, "generic_webhook": basetypes.ListType{ - ElemType: GenericWebhookConfig{}.ToObjectType(ctx), + ElemType: GenericWebhookConfig{}.Type(ctx), }, "microsoft_teams": basetypes.ListType{ - ElemType: MicrosoftTeamsConfig{}.ToObjectType(ctx), + ElemType: MicrosoftTeamsConfig{}.Type(ctx), }, "pagerduty": basetypes.ListType{ - ElemType: PagerdutyConfig{}.ToObjectType(ctx), + ElemType: PagerdutyConfig{}.Type(ctx), }, "slack": basetypes.ListType{ - ElemType: SlackConfig{}.ToObjectType(ctx), + ElemType: SlackConfig{}.Type(ctx), }, }, } @@ -663,9 +1325,56 @@ func (a CreateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateIpAccessList in the Terraform plugin framework type -// system. -func (a CreateIpAccessList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateIpAccessList{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateIpAccessList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateIpAccessList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateIpAccessList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateIpAccessList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateIpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateIpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateIpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_addresses": basetypes.ListType{ @@ -702,13 +1411,60 @@ func (a CreateIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of CreateIpAccessListResponse in the Terraform plugin framework type -// system. -func (a CreateIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateIpAccessListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToObjectType(ctx), + ElemType: IpAccessListInfo{}.Type(ctx), }, }, } @@ -743,9 +1499,56 @@ func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateNetworkConnectivityConfigRequest in the Terraform plugin framework type -// system. -func (a CreateNetworkConnectivityConfigRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateNetworkConnectivityConfigRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateNetworkConnectivityConfigRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -781,13 +1584,60 @@ func (a CreateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of CreateNotificationDestinationRequest in the Terraform plugin framework type -// system. -func (a CreateNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateNotificationDestinationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateNotificationDestinationRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config": basetypes.ListType{ - ElemType: Config{}.ToObjectType(ctx), + ElemType: Config{}.Type(ctx), }, "display_name": types.StringType, }, @@ -821,9 +1671,56 @@ func (a CreateOboTokenRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateOboTokenRequest in the Terraform plugin framework type -// system. -func (a CreateOboTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateOboTokenRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateOboTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "application_id": types.StringType, @@ -859,13 +1756,60 @@ func (a CreateOboTokenResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CreateOboTokenResponse in the Terraform plugin framework type -// system. -func (a CreateOboTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateOboTokenResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateOboTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_info": basetypes.ListType{ - ElemType: TokenInfo{}.ToObjectType(ctx), + ElemType: TokenInfo{}.Type(ctx), }, "token_value": types.StringType, }, @@ -900,9 +1844,56 @@ func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreatePrivateEndpointRuleRequest in the Terraform plugin framework type -// system. -func (a CreatePrivateEndpointRuleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreatePrivateEndpointRuleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreatePrivateEndpointRuleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_id": types.StringType, @@ -938,9 +1929,56 @@ func (a CreateTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateTokenRequest in the Terraform plugin framework type -// system. -func (a CreateTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateTokenRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateTokenRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateTokenRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateTokenRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateTokenRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -975,13 +2013,60 @@ func (a CreateTokenResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of CreateTokenResponse in the Terraform plugin framework type -// system. -func (a CreateTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateTokenResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateTokenResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateTokenResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateTokenResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateTokenResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_info": basetypes.ListType{ - ElemType: PublicTokenInfo{}.ToObjectType(ctx), + ElemType: PublicTokenInfo{}.Type(ctx), }, "token_value": types.StringType, }, @@ -1016,9 +2101,56 @@ func (a CspEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of CspEnablementAccount in the Terraform plugin framework type -// system. -func (a CspEnablementAccount) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CspEnablementAccount{} + +// Equal implements basetypes.ObjectValuable. +func (o CspEnablementAccount) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CspEnablementAccount) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CspEnablementAccount) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CspEnablementAccount) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CspEnablementAccount) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CspEnablementAccount) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CspEnablementAccount) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compliance_standards": basetypes.ListType{ @@ -1067,13 +2199,60 @@ func (a CspEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of CspEnablementAccountSetting in the Terraform plugin framework type -// system. -func (a CspEnablementAccountSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CspEnablementAccountSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CspEnablementAccountSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "csp_enablement_account": basetypes.ListType{ - ElemType: CspEnablementAccount{}.ToObjectType(ctx), + ElemType: CspEnablementAccount{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -1128,14 +2307,61 @@ func (a DefaultNamespaceSetting) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of DefaultNamespaceSetting in the Terraform plugin framework type -// system. -func (a DefaultNamespaceSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DefaultNamespaceSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DefaultNamespaceSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "namespace": basetypes.ListType{ - ElemType: StringMessage{}.ToObjectType(ctx), + ElemType: StringMessage{}.Type(ctx), }, "setting_name": types.StringType, }, @@ -1165,9 +2391,56 @@ func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAccountIpAccessListRequest in the Terraform plugin framework type -// system. -func (a DeleteAccountIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAccountIpAccessListRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAccountIpAccessListRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -1204,9 +2477,56 @@ func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDefaultNamespaceSettingRequest in the Terraform plugin framework type -// system. -func (a DeleteDefaultNamespaceSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDefaultNamespaceSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1243,9 +2563,56 @@ func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDefaultNamespaceSettingResponse in the Terraform plugin framework type -// system. -func (a DeleteDefaultNamespaceSettingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDefaultNamespaceSettingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDefaultNamespaceSettingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1282,9 +2649,56 @@ func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDisableLegacyAccessRequest in the Terraform plugin framework type -// system. -func (a DeleteDisableLegacyAccessRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDisableLegacyAccessRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1321,9 +2735,56 @@ func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDisableLegacyAccessResponse in the Terraform plugin framework type -// system. -func (a DeleteDisableLegacyAccessResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDisableLegacyAccessResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyAccessResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1360,9 +2821,56 @@ func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDisableLegacyDbfsRequest in the Terraform plugin framework type -// system. -func (a DeleteDisableLegacyDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDisableLegacyDbfsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1399,9 +2907,56 @@ func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDisableLegacyDbfsResponse in the Terraform plugin framework type -// system. -func (a DeleteDisableLegacyDbfsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDisableLegacyDbfsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyDbfsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1438,9 +2993,56 @@ func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDisableLegacyFeaturesRequest in the Terraform plugin framework type -// system. -func (a DeleteDisableLegacyFeaturesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDisableLegacyFeaturesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1477,9 +3079,56 @@ func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDisableLegacyFeaturesResponse in the Terraform plugin framework type -// system. -func (a DeleteDisableLegacyFeaturesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDisableLegacyFeaturesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDisableLegacyFeaturesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1510,9 +3159,56 @@ func (a DeleteIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteIpAccessListRequest in the Terraform plugin framework type -// system. -func (a DeleteIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteIpAccessListRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteIpAccessListRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -1543,9 +3239,56 @@ func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteNetworkConnectivityConfigurationRequest in the Terraform plugin framework type -// system. -func (a DeleteNetworkConnectivityConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteNetworkConnectivityConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -1573,9 +3316,56 @@ func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes(ctx return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteNetworkConnectivityConfigurationResponse in the Terraform plugin framework type -// system. -func (a DeleteNetworkConnectivityConfigurationResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteNetworkConnectivityConfigurationResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteNetworkConnectivityConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1603,9 +3393,56 @@ func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteNotificationDestinationRequest in the Terraform plugin framework type -// system. -func (a DeleteNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteNotificationDestinationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1642,9 +3479,56 @@ func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePersonalComputeSettingRequest in the Terraform plugin framework type -// system. -func (a DeletePersonalComputeSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePersonalComputeSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1681,9 +3565,56 @@ func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePersonalComputeSettingResponse in the Terraform plugin framework type -// system. -func (a DeletePersonalComputeSettingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePersonalComputeSettingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePersonalComputeSettingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1716,9 +3647,56 @@ func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeletePrivateEndpointRuleRequest in the Terraform plugin framework type -// system. -func (a DeletePrivateEndpointRuleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeletePrivateEndpointRuleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeletePrivateEndpointRuleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -1747,9 +3725,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1784,9 +3809,56 @@ func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type -// system. -func (a DeleteRestrictWorkspaceAdminsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRestrictWorkspaceAdminsSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1823,9 +3895,56 @@ func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes(ctx c return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRestrictWorkspaceAdminsSettingResponse in the Terraform plugin framework type -// system. -func (a DeleteRestrictWorkspaceAdminsSettingResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRestrictWorkspaceAdminsSettingResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRestrictWorkspaceAdminsSettingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -1856,9 +3975,56 @@ func (a DeleteTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteTokenManagementRequest in the Terraform plugin framework type -// system. -func (a DeleteTokenManagementRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteTokenManagementRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteTokenManagementRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_id": types.StringType, @@ -1903,13 +4069,60 @@ func (a DisableLegacyAccess) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of DisableLegacyAccess in the Terraform plugin framework type -// system. -func (a DisableLegacyAccess) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DisableLegacyAccess{} + +// Equal implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DisableLegacyAccess) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disable_legacy_access": basetypes.ListType{ - ElemType: BooleanMessage{}.ToObjectType(ctx), + ElemType: BooleanMessage{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -1954,13 +4167,60 @@ func (a DisableLegacyDbfs) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of DisableLegacyDbfs in the Terraform plugin framework type -// system. -func (a DisableLegacyDbfs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DisableLegacyDbfs{} + +// Equal implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DisableLegacyDbfs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disable_legacy_dbfs": basetypes.ListType{ - ElemType: BooleanMessage{}.ToObjectType(ctx), + ElemType: BooleanMessage{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2005,13 +4265,60 @@ func (a DisableLegacyFeatures) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of DisableLegacyFeatures in the Terraform plugin framework type -// system. -func (a DisableLegacyFeatures) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DisableLegacyFeatures{} + +// Equal implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DisableLegacyFeatures) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "disable_legacy_features": basetypes.ListType{ - ElemType: BooleanMessage{}.ToObjectType(ctx), + ElemType: BooleanMessage{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2043,9 +4350,56 @@ func (a EmailConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of EmailConfig in the Terraform plugin framework type -// system. -func (a EmailConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EmailConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o EmailConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EmailConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EmailConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EmailConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EmailConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EmailConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EmailConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "addresses": basetypes.ListType{ @@ -2075,9 +4429,56 @@ func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Empty in the Terraform plugin framework type -// system. -func (a Empty) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Empty{} + +// Equal implements basetypes.ObjectValuable. +func (o Empty) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Empty) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Empty) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Empty) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Empty) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Empty) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Empty) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2105,10 +4506,57 @@ func (a EnhancedSecurityMonitoring) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of EnhancedSecurityMonitoring in the Terraform plugin framework type -// system. -func (a EnhancedSecurityMonitoring) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnhancedSecurityMonitoring{} + +// Equal implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoring) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_enabled": types.BoolType, }, @@ -2153,13 +4601,60 @@ func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of EnhancedSecurityMonitoringSetting in the Terraform plugin framework type -// system. -func (a EnhancedSecurityMonitoringSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnhancedSecurityMonitoringSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnhancedSecurityMonitoringSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enhanced_security_monitoring_workspace": basetypes.ListType{ - ElemType: EnhancedSecurityMonitoring{}.ToObjectType(ctx), + ElemType: EnhancedSecurityMonitoring{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2189,9 +4684,56 @@ func (a EsmEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of EsmEnablementAccount in the Terraform plugin framework type -// system. -func (a EsmEnablementAccount) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EsmEnablementAccount{} + +// Equal implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EsmEnablementAccount) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_enforced": types.BoolType, @@ -2237,13 +4779,60 @@ func (a EsmEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of EsmEnablementAccountSetting in the Terraform plugin framework type -// system. -func (a EsmEnablementAccountSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EsmEnablementAccountSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EsmEnablementAccountSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "esm_enablement_account": basetypes.ListType{ - ElemType: EsmEnablementAccount{}.ToObjectType(ctx), + ElemType: EsmEnablementAccount{}.Type(ctx), }, "etag": types.StringType, "setting_name": types.StringType, @@ -2285,9 +4874,56 @@ func (a ExchangeToken) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of ExchangeToken in the Terraform plugin framework type -// system. -func (a ExchangeToken) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExchangeToken{} + +// Equal implements basetypes.ObjectValuable. +func (o ExchangeToken) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExchangeToken) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExchangeToken) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExchangeToken) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExchangeToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExchangeToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExchangeToken) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential": types.StringType, @@ -2332,13 +4968,60 @@ func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ExchangeTokenRequest in the Terraform plugin framework type -// system. -func (a ExchangeTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExchangeTokenRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExchangeTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "partitionId": basetypes.ListType{ - ElemType: PartitionId{}.ToObjectType(ctx), + ElemType: PartitionId{}.Type(ctx), }, "scopes": basetypes.ListType{ ElemType: types.StringType, @@ -2374,13 +5057,60 @@ func (a ExchangeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ExchangeTokenResponse in the Terraform plugin framework type -// system. -func (a ExchangeTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExchangeTokenResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExchangeTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "values": basetypes.ListType{ - ElemType: ExchangeToken{}.ToObjectType(ctx), + ElemType: ExchangeToken{}.Type(ctx), }, }, } @@ -2411,13 +5141,60 @@ func (a FetchIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of FetchIpAccessListResponse in the Terraform plugin framework type -// system. -func (a FetchIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = FetchIpAccessListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToObjectType(ctx), + ElemType: IpAccessListInfo{}.Type(ctx), }, }, } @@ -2455,9 +5232,56 @@ func (a GenericWebhookConfig) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of GenericWebhookConfig in the Terraform plugin framework type -// system. -func (a GenericWebhookConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GenericWebhookConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GenericWebhookConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "password": types.StringType, @@ -2493,9 +5317,56 @@ func (a GetAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAccountIpAccessListRequest in the Terraform plugin framework type -// system. -func (a GetAccountIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAccountIpAccessListRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAccountIpAccessListRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -2532,9 +5403,56 @@ func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldType return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type -// system. -func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAibiDashboardEmbeddingAccessPolicySettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2571,9 +5489,56 @@ func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldT return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type -// system. -func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAibiDashboardEmbeddingApprovedDomainsSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2610,9 +5575,56 @@ func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type -// system. -func (a GetAutomaticClusterUpdateSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAutomaticClusterUpdateSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAutomaticClusterUpdateSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2649,9 +5661,56 @@ func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetComplianceSecurityProfileSettingRequest in the Terraform plugin framework type -// system. -func (a GetComplianceSecurityProfileSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetComplianceSecurityProfileSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetComplianceSecurityProfileSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2688,9 +5747,56 @@ func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCspEnablementAccountSettingRequest in the Terraform plugin framework type -// system. -func (a GetCspEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCspEnablementAccountSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCspEnablementAccountSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2727,9 +5833,56 @@ func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDefaultNamespaceSettingRequest in the Terraform plugin framework type -// system. -func (a GetDefaultNamespaceSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDefaultNamespaceSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDefaultNamespaceSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2766,9 +5919,56 @@ func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDisableLegacyAccessRequest in the Terraform plugin framework type -// system. -func (a GetDisableLegacyAccessRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDisableLegacyAccessRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDisableLegacyAccessRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2805,9 +6005,56 @@ func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDisableLegacyDbfsRequest in the Terraform plugin framework type -// system. -func (a GetDisableLegacyDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDisableLegacyDbfsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDisableLegacyDbfsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2844,9 +6091,56 @@ func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDisableLegacyFeaturesRequest in the Terraform plugin framework type -// system. -func (a GetDisableLegacyFeaturesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDisableLegacyFeaturesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDisableLegacyFeaturesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2883,9 +6177,56 @@ func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type -// system. -func (a GetEnhancedSecurityMonitoringSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEnhancedSecurityMonitoringSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEnhancedSecurityMonitoringSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2922,9 +6263,56 @@ func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetEsmEnablementAccountSettingRequest in the Terraform plugin framework type -// system. -func (a GetEsmEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEsmEnablementAccountSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEsmEnablementAccountSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -2955,9 +6343,56 @@ func (a GetIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetIpAccessListRequest in the Terraform plugin framework type -// system. -func (a GetIpAccessListRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetIpAccessListRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetIpAccessListRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list_id": types.StringType, @@ -2989,13 +6424,60 @@ func (a GetIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of GetIpAccessListResponse in the Terraform plugin framework type -// system. -func (a GetIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetIpAccessListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToObjectType(ctx), + ElemType: IpAccessListInfo{}.Type(ctx), }, }, } @@ -3025,13 +6507,60 @@ func (a GetIpAccessListsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of GetIpAccessListsResponse in the Terraform plugin framework type -// system. -func (a GetIpAccessListsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetIpAccessListsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetIpAccessListsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_lists": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToObjectType(ctx), + ElemType: IpAccessListInfo{}.Type(ctx), }, }, } @@ -3060,9 +6589,56 @@ func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetNetworkConnectivityConfigurationRequest in the Terraform plugin framework type -// system. -func (a GetNetworkConnectivityConfigurationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetNetworkConnectivityConfigurationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetNetworkConnectivityConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -3092,9 +6668,56 @@ func (a GetNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetNotificationDestinationRequest in the Terraform plugin framework type -// system. -func (a GetNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetNotificationDestinationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3131,9 +6754,56 @@ func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPersonalComputeSettingRequest in the Terraform plugin framework type -// system. -func (a GetPersonalComputeSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPersonalComputeSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPersonalComputeSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -3166,9 +6836,56 @@ func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetPrivateEndpointRuleRequest in the Terraform plugin framework type -// system. -func (a GetPrivateEndpointRuleRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetPrivateEndpointRuleRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetPrivateEndpointRuleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -3206,9 +6923,56 @@ func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type -// system. -func (a GetRestrictWorkspaceAdminsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRestrictWorkspaceAdminsSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRestrictWorkspaceAdminsSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, @@ -3238,9 +7002,56 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStatusRequest in the Terraform plugin framework type -// system. -func (a GetStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStatusRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStatusRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStatusRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStatusRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStatusRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStatusRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "keys": types.StringType, @@ -3271,9 +7082,56 @@ func (a GetTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetTokenManagementRequest in the Terraform plugin framework type -// system. -func (a GetTokenManagementRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetTokenManagementRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetTokenManagementRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_id": types.StringType, @@ -3305,13 +7163,60 @@ func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of GetTokenPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetTokenPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetTokenPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetTokenPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: TokenPermissionsDescription{}.ToObjectType(ctx), + ElemType: TokenPermissionsDescription{}.Type(ctx), }, }, } @@ -3341,13 +7246,60 @@ func (a GetTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of GetTokenResponse in the Terraform plugin framework type -// system. -func (a GetTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetTokenResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetTokenResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetTokenResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetTokenResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetTokenResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_info": basetypes.ListType{ - ElemType: TokenInfo{}.ToObjectType(ctx), + ElemType: TokenInfo{}.Type(ctx), }, }, } @@ -3401,9 +7353,56 @@ func (a IpAccessListInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of IpAccessListInfo in the Terraform plugin framework type -// system. -func (a IpAccessListInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = IpAccessListInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o IpAccessListInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o IpAccessListInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o IpAccessListInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o IpAccessListInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o IpAccessListInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o IpAccessListInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o IpAccessListInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "address_count": types.Int64Type, @@ -3446,13 +7445,60 @@ func (a ListIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of ListIpAccessListResponse in the Terraform plugin framework type -// system. -func (a ListIpAccessListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListIpAccessListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "ip_access_lists": basetypes.ListType{ - ElemType: IpAccessListInfo{}.ToObjectType(ctx), + ElemType: IpAccessListInfo{}.Type(ctx), }, }, } @@ -3484,13 +7530,60 @@ func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes(ctx conte } } -// ToObjectType returns the representation of ListNccAzurePrivateEndpointRulesResponse in the Terraform plugin framework type -// system. -func (a ListNccAzurePrivateEndpointRulesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNccAzurePrivateEndpointRulesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListNccAzurePrivateEndpointRulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "items": basetypes.ListType{ - ElemType: NccAzurePrivateEndpointRule{}.ToObjectType(ctx), + ElemType: NccAzurePrivateEndpointRule{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -3520,9 +7613,56 @@ func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes(ctx c return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListNetworkConnectivityConfigurationsRequest in the Terraform plugin framework type -// system. -func (a ListNetworkConnectivityConfigurationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNetworkConnectivityConfigurationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -3556,13 +7696,60 @@ func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes(ctx } } -// ToObjectType returns the representation of ListNetworkConnectivityConfigurationsResponse in the Terraform plugin framework type -// system. -func (a ListNetworkConnectivityConfigurationsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNetworkConnectivityConfigurationsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListNetworkConnectivityConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "items": basetypes.ListType{ - ElemType: NetworkConnectivityConfiguration{}.ToObjectType(ctx), + ElemType: NetworkConnectivityConfiguration{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -3593,9 +7780,56 @@ func (a ListNotificationDestinationsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListNotificationDestinationsRequest in the Terraform plugin framework type -// system. -func (a ListNotificationDestinationsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNotificationDestinationsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -3630,14 +7864,61 @@ func (a ListNotificationDestinationsResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of ListNotificationDestinationsResponse in the Terraform plugin framework type -// system. -func (a ListNotificationDestinationsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNotificationDestinationsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: ListNotificationDestinationsResult{}.ToObjectType(ctx), + ElemType: ListNotificationDestinationsResult{}.Type(ctx), }, }, } @@ -3659,20 +7940,67 @@ func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringCre func (newState *ListNotificationDestinationsResult) SyncEffectiveFieldsDuringRead(existingState ListNotificationDestinationsResult) { } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNotificationDestinationsResult. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a ListNotificationDestinationsResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ListNotificationDestinationsResult. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a ListNotificationDestinationsResult) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListNotificationDestinationsResult{} + +// Equal implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of ListNotificationDestinationsResult in the Terraform plugin framework type -// system. -func (a ListNotificationDestinationsResult) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o ListNotificationDestinationsResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "destination_type": types.StringType, @@ -3707,9 +8035,56 @@ func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListPrivateEndpointRulesRequest in the Terraform plugin framework type -// system. -func (a ListPrivateEndpointRulesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPrivateEndpointRulesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPrivateEndpointRulesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "network_connectivity_config_id": types.StringType, @@ -3742,13 +8117,60 @@ func (a ListPublicTokensResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of ListPublicTokensResponse in the Terraform plugin framework type -// system. -func (a ListPublicTokensResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListPublicTokensResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListPublicTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_infos": basetypes.ListType{ - ElemType: PublicTokenInfo{}.ToObjectType(ctx), + ElemType: PublicTokenInfo{}.Type(ctx), }, }, } @@ -3779,9 +8201,56 @@ func (a ListTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListTokenManagementRequest in the Terraform plugin framework type -// system. -func (a ListTokenManagementRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTokenManagementRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTokenManagementRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_by_id": types.Int64Type, @@ -3815,13 +8284,60 @@ func (a ListTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListTokensResponse in the Terraform plugin framework type -// system. -func (a ListTokensResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListTokensResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListTokensResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListTokensResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListTokensResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListTokensResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListTokensResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListTokensResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_infos": basetypes.ListType{ - ElemType: TokenInfo{}.ToObjectType(ctx), + ElemType: TokenInfo{}.Type(ctx), }, }, } @@ -3851,9 +8367,56 @@ func (a MicrosoftTeamsConfig) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of MicrosoftTeamsConfig in the Terraform plugin framework type -// system. -func (a MicrosoftTeamsConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MicrosoftTeamsConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MicrosoftTeamsConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "url": types.StringType, @@ -3889,9 +8452,56 @@ func (a NccAwsStableIpRule) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of NccAwsStableIpRule in the Terraform plugin framework type -// system. -func (a NccAwsStableIpRule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NccAwsStableIpRule{} + +// Equal implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NccAwsStableIpRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cidr_blocks": basetypes.ListType{ @@ -3956,9 +8566,56 @@ func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of NccAzurePrivateEndpointRule in the Terraform plugin framework type -// system. -func (a NccAzurePrivateEndpointRule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NccAzurePrivateEndpointRule{} + +// Equal implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NccAzurePrivateEndpointRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "connection_state": types.StringType, @@ -4008,9 +8665,56 @@ func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of NccAzureServiceEndpointRule in the Terraform plugin framework type -// system. -func (a NccAzureServiceEndpointRule) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NccAzureServiceEndpointRule{} + +// Equal implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NccAzureServiceEndpointRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "subnets": basetypes.ListType{ @@ -4056,16 +8760,63 @@ func (a NccEgressConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of NccEgressConfig in the Terraform plugin framework type -// system. -func (a NccEgressConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NccEgressConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o NccEgressConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NccEgressConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NccEgressConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NccEgressConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NccEgressConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NccEgressConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NccEgressConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_rules": basetypes.ListType{ - ElemType: NccEgressDefaultRules{}.ToObjectType(ctx), + ElemType: NccEgressDefaultRules{}.Type(ctx), }, "target_rules": basetypes.ListType{ - ElemType: NccEgressTargetRules{}.ToObjectType(ctx), + ElemType: NccEgressTargetRules{}.Type(ctx), }, }, } @@ -4105,16 +8856,63 @@ func (a NccEgressDefaultRules) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of NccEgressDefaultRules in the Terraform plugin framework type -// system. -func (a NccEgressDefaultRules) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NccEgressDefaultRules{} + +// Equal implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NccEgressDefaultRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "aws_stable_ip_rule": basetypes.ListType{ - ElemType: NccAwsStableIpRule{}.ToObjectType(ctx), + ElemType: NccAwsStableIpRule{}.Type(ctx), }, "azure_service_endpoint_rule": basetypes.ListType{ - ElemType: NccAzureServiceEndpointRule{}.ToObjectType(ctx), + ElemType: NccAzureServiceEndpointRule{}.Type(ctx), }, }, } @@ -4145,13 +8943,60 @@ func (a NccEgressTargetRules) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of NccEgressTargetRules in the Terraform plugin framework type -// system. -func (a NccEgressTargetRules) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NccEgressTargetRules{} + +// Equal implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NccEgressTargetRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "azure_private_endpoint_rules": basetypes.ListType{ - ElemType: NccAzurePrivateEndpointRule{}.ToObjectType(ctx), + ElemType: NccAzurePrivateEndpointRule{}.Type(ctx), }, }, } @@ -4199,15 +9044,62 @@ func (a NetworkConnectivityConfiguration) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of NetworkConnectivityConfiguration in the Terraform plugin framework type -// system. -func (a NetworkConnectivityConfiguration) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NetworkConnectivityConfiguration{} + +// Equal implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NetworkConnectivityConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, "egress_config": basetypes.ListType{ - ElemType: NccEgressConfig{}.ToObjectType(ctx), + ElemType: NccEgressConfig{}.Type(ctx), }, "name": types.StringType, "network_connectivity_config_id": types.StringType, @@ -4250,13 +9142,60 @@ func (a NotificationDestination) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of NotificationDestination in the Terraform plugin framework type -// system. -func (a NotificationDestination) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NotificationDestination{} + +// Equal implements basetypes.ObjectValuable. +func (o NotificationDestination) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NotificationDestination) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NotificationDestination) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NotificationDestination) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NotificationDestination) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NotificationDestination) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NotificationDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config": basetypes.ListType{ - ElemType: Config{}.ToObjectType(ctx), + ElemType: Config{}.Type(ctx), }, "destination_type": types.StringType, "display_name": types.StringType, @@ -4289,9 +9228,56 @@ func (a PagerdutyConfig) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of PagerdutyConfig in the Terraform plugin framework type -// system. -func (a PagerdutyConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PagerdutyConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o PagerdutyConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PagerdutyConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PagerdutyConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PagerdutyConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PagerdutyConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PagerdutyConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PagerdutyConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "integration_key": types.StringType, @@ -4323,9 +9309,56 @@ func (a PartitionId) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of PartitionId in the Terraform plugin framework type -// system. -func (a PartitionId) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PartitionId{} + +// Equal implements basetypes.ObjectValuable. +func (o PartitionId) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PartitionId) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PartitionId) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PartitionId) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PartitionId) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PartitionId) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PartitionId) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspaceId": types.Int64Type, @@ -4361,9 +9394,56 @@ func (a PersonalComputeMessage) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of PersonalComputeMessage in the Terraform plugin framework type -// system. -func (a PersonalComputeMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PersonalComputeMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PersonalComputeMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.StringType, @@ -4409,14 +9489,61 @@ func (a PersonalComputeSetting) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of PersonalComputeSetting in the Terraform plugin framework type -// system. -func (a PersonalComputeSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PersonalComputeSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PersonalComputeSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "personal_compute": basetypes.ListType{ - ElemType: PersonalComputeMessage{}.ToObjectType(ctx), + ElemType: PersonalComputeMessage{}.Type(ctx), }, "setting_name": types.StringType, }, @@ -4452,9 +9579,56 @@ func (a PublicTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of PublicTokenInfo in the Terraform plugin framework type -// system. -func (a PublicTokenInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PublicTokenInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o PublicTokenInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PublicTokenInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PublicTokenInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PublicTokenInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PublicTokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PublicTokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PublicTokenInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4503,9 +9677,56 @@ func (a ReplaceIpAccessList) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ReplaceIpAccessList in the Terraform plugin framework type -// system. -func (a ReplaceIpAccessList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReplaceIpAccessList{} + +// Equal implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReplaceIpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -4539,9 +9760,56 @@ func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ReplaceResponse in the Terraform plugin framework type -// system. -func (a ReplaceResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ReplaceResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ReplaceResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ReplaceResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ReplaceResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ReplaceResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ReplaceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ReplaceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ReplaceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4568,9 +9836,56 @@ func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestrictWorkspaceAdminsMessage in the Terraform plugin framework type -// system. -func (a RestrictWorkspaceAdminsMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestrictWorkspaceAdminsMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "status": types.StringType, @@ -4616,14 +9931,61 @@ func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of RestrictWorkspaceAdminsSetting in the Terraform plugin framework type -// system. -func (a RestrictWorkspaceAdminsSetting) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestrictWorkspaceAdminsSetting{} + +// Equal implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestrictWorkspaceAdminsSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, "restrict_workspace_admins": basetypes.ListType{ - ElemType: RestrictWorkspaceAdminsMessage{}.ToObjectType(ctx), + ElemType: RestrictWorkspaceAdminsMessage{}.Type(ctx), }, "setting_name": types.StringType, }, @@ -4652,9 +10014,56 @@ func (a RevokeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of RevokeTokenRequest in the Terraform plugin framework type -// system. -func (a RevokeTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RevokeTokenRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RevokeTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "token_id": types.StringType, @@ -4682,9 +10091,56 @@ func (a RevokeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of RevokeTokenResponse in the Terraform plugin framework type -// system. -func (a RevokeTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RevokeTokenResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RevokeTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4710,9 +10166,56 @@ func (a SetStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetStatusResponse in the Terraform plugin framework type -// system. -func (a SetStatusResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetStatusResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetStatusResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetStatusResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetStatusResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetStatusResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -4742,9 +10245,56 @@ func (a SlackConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of SlackConfig in the Terraform plugin framework type -// system. -func (a SlackConfig) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SlackConfig{} + +// Equal implements basetypes.ObjectValuable. +func (o SlackConfig) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SlackConfig) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SlackConfig) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SlackConfig) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SlackConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SlackConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SlackConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "url": types.StringType, @@ -4775,9 +10325,56 @@ func (a StringMessage) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of StringMessage in the Terraform plugin framework type -// system. -func (a StringMessage) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StringMessage{} + +// Equal implements basetypes.ObjectValuable. +func (o StringMessage) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StringMessage) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StringMessage) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StringMessage) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StringMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StringMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StringMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.StringType, @@ -4813,9 +10410,56 @@ func (a TokenAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of TokenAccessControlRequest in the Terraform plugin framework type -// system. -func (a TokenAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -4858,13 +10502,60 @@ func (a TokenAccessControlResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of TokenAccessControlResponse in the Terraform plugin framework type -// system. -func (a TokenAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: TokenPermission{}.ToObjectType(ctx), + ElemType: TokenPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -4914,9 +10605,56 @@ func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of TokenInfo in the Terraform plugin framework type -// system. -func (a TokenInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -4959,9 +10697,56 @@ func (a TokenPermission) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of TokenPermission in the Terraform plugin framework type -// system. -func (a TokenPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -5000,13 +10785,60 @@ func (a TokenPermissions) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of TokenPermissions in the Terraform plugin framework type -// system. -func (a TokenPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: TokenAccessControlResponse{}.ToObjectType(ctx), + ElemType: TokenAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -5037,9 +10869,56 @@ func (a TokenPermissionsDescription) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of TokenPermissionsDescription in the Terraform plugin framework type -// system. -func (a TokenPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -5071,13 +10950,60 @@ func (a TokenPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of TokenPermissionsRequest in the Terraform plugin framework type -// system. -func (a TokenPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TokenPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TokenPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: TokenAccessControlRequest{}.ToObjectType(ctx), + ElemType: TokenAccessControlRequest{}.Type(ctx), }, }, } @@ -5116,15 +11042,62 @@ func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldT } } -// ToObjectType returns the representation of UpdateAibiDashboardEmbeddingAccessPolicySettingRequest in the Terraform plugin framework type -// system. -func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAibiDashboardEmbeddingAccessPolicySettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.ToObjectType(ctx), + ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.Type(ctx), }, }, } @@ -5163,15 +11136,62 @@ func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFie } } -// ToObjectType returns the representation of UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.ToObjectType(ctx), + ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.Type(ctx), }, }, } @@ -5210,15 +11230,62 @@ func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx con } } -// ToObjectType returns the representation of UpdateAutomaticClusterUpdateSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateAutomaticClusterUpdateSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAutomaticClusterUpdateSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAutomaticClusterUpdateSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: AutomaticClusterUpdateSetting{}.ToObjectType(ctx), + ElemType: AutomaticClusterUpdateSetting{}.Type(ctx), }, }, } @@ -5257,15 +11324,62 @@ func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx } } -// ToObjectType returns the representation of UpdateComplianceSecurityProfileSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateComplianceSecurityProfileSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateComplianceSecurityProfileSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateComplianceSecurityProfileSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: ComplianceSecurityProfileSetting{}.ToObjectType(ctx), + ElemType: ComplianceSecurityProfileSetting{}.Type(ctx), }, }, } @@ -5304,15 +11418,62 @@ func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx conte } } -// ToObjectType returns the representation of UpdateCspEnablementAccountSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateCspEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCspEnablementAccountSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCspEnablementAccountSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: CspEnablementAccountSetting{}.ToObjectType(ctx), + ElemType: CspEnablementAccountSetting{}.Type(ctx), }, }, } @@ -5359,15 +11520,62 @@ func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of UpdateDefaultNamespaceSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateDefaultNamespaceSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateDefaultNamespaceSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateDefaultNamespaceSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DefaultNamespaceSetting{}.ToObjectType(ctx), + ElemType: DefaultNamespaceSetting{}.Type(ctx), }, }, } @@ -5406,15 +11614,62 @@ func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of UpdateDisableLegacyAccessRequest in the Terraform plugin framework type -// system. -func (a UpdateDisableLegacyAccessRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateDisableLegacyAccessRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyAccessRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DisableLegacyAccess{}.ToObjectType(ctx), + ElemType: DisableLegacyAccess{}.Type(ctx), }, }, } @@ -5453,15 +11708,62 @@ func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of UpdateDisableLegacyDbfsRequest in the Terraform plugin framework type -// system. -func (a UpdateDisableLegacyDbfsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateDisableLegacyDbfsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyDbfsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DisableLegacyDbfs{}.ToObjectType(ctx), + ElemType: DisableLegacyDbfs{}.Type(ctx), }, }, } @@ -5500,15 +11802,62 @@ func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of UpdateDisableLegacyFeaturesRequest in the Terraform plugin framework type -// system. -func (a UpdateDisableLegacyFeaturesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateDisableLegacyFeaturesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateDisableLegacyFeaturesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: DisableLegacyFeatures{}.ToObjectType(ctx), + ElemType: DisableLegacyFeatures{}.Type(ctx), }, }, } @@ -5547,15 +11896,62 @@ func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx } } -// ToObjectType returns the representation of UpdateEnhancedSecurityMonitoringSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateEnhancedSecurityMonitoringSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateEnhancedSecurityMonitoringSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateEnhancedSecurityMonitoringSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: EnhancedSecurityMonitoringSetting{}.ToObjectType(ctx), + ElemType: EnhancedSecurityMonitoringSetting{}.Type(ctx), }, }, } @@ -5594,15 +11990,62 @@ func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx conte } } -// ToObjectType returns the representation of UpdateEsmEnablementAccountSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateEsmEnablementAccountSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateEsmEnablementAccountSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateEsmEnablementAccountSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: EsmEnablementAccountSetting{}.ToObjectType(ctx), + ElemType: EsmEnablementAccountSetting{}.Type(ctx), }, }, } @@ -5646,9 +12089,56 @@ func (a UpdateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of UpdateIpAccessList in the Terraform plugin framework type -// system. -func (a UpdateIpAccessList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateIpAccessList{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateIpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -5691,13 +12181,60 @@ func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of UpdateNotificationDestinationRequest in the Terraform plugin framework type -// system. -func (a UpdateNotificationDestinationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateNotificationDestinationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config": basetypes.ListType{ - ElemType: Config{}.ToObjectType(ctx), + ElemType: Config{}.Type(ctx), }, "display_name": types.StringType, "id": types.StringType, @@ -5738,15 +12275,62 @@ func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Co } } -// ToObjectType returns the representation of UpdatePersonalComputeSettingRequest in the Terraform plugin framework type -// system. -func (a UpdatePersonalComputeSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePersonalComputeSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePersonalComputeSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: PersonalComputeSetting{}.ToObjectType(ctx), + ElemType: PersonalComputeSetting{}.Type(ctx), }, }, } @@ -5772,9 +12356,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5813,16 +12444,104 @@ func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx co } } -// ToObjectType returns the representation of UpdateRestrictWorkspaceAdminsSettingRequest in the Terraform plugin framework type -// system. -func (a UpdateRestrictWorkspaceAdminsSettingRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRestrictWorkspaceAdminsSettingRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRestrictWorkspaceAdminsSettingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, "setting": basetypes.ListType{ - ElemType: RestrictWorkspaceAdminsSetting{}.ToObjectType(ctx), + ElemType: RestrictWorkspaceAdminsSetting{}.Type(ctx), }, }, } } + +// Compliance stardard for SHIELD customers + +// The sub-resource type (group ID) of the target resource. Note that to connect +// to workspace root storage (root DBFS), you need two endpoints, one for `blob` +// and one for `dfs`. + +// Type of IP access list. Valid values are as follows and are case-sensitive: +// +// * `ALLOW`: An allow list. Include this IP or range. * `BLOCK`: A block list. +// Exclude this IP or range. IP addresses in the block list are excluded even if +// they are included in an allow list. + +// The current status of this private endpoint. The private endpoint rules are +// effective only if the connection state is `ESTABLISHED`. Remember that you +// must approve new endpoints on your resources in the Azure portal before they +// take effect. +// +// The possible values are: - INIT: (deprecated) The endpoint has been created +// and pending approval. - PENDING: The endpoint has been created and pending +// approval. - ESTABLISHED: The endpoint has been approved and is ready to use +// in your serverless compute resources. - REJECTED: Connection was rejected by +// the private link resource owner. - DISCONNECTED: Connection was removed by +// the private link resource owner, the private endpoint becomes informative and +// should be deleted for clean-up. + +// The sub-resource type (group ID) of the target resource. Note that to connect +// to workspace root storage (root DBFS), you need two endpoints, one for `blob` +// and one for `dfs`. + +// ON: Grants all users in all workspaces access to the Personal Compute default +// policy, allowing all users to create single-machine compute resources. +// DELEGATE: Moves access control for the Personal Compute default policy to +// individual workspaces and requires a workspace’s users or groups to be +// added to the ACLs of that workspace’s Personal Compute default policy +// before they will be able to create compute resources through that policy. + +// Permission level + +// The type of token request. As of now, only `AZURE_ACTIVE_DIRECTORY_TOKEN` is +// supported. diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 1507de7c05..80b2d52bf4 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -12,13 +12,17 @@ package sharing_tf import ( "context" + "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/catalog" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type CreateProvider struct { @@ -50,9 +54,56 @@ func (a CreateProvider) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateProvider in the Terraform plugin framework type -// system. -func (a CreateProvider) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateProvider{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateProvider) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateProvider) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateProvider) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateProvider) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateProvider) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateProvider) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateProvider) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authentication_type": types.StringType, @@ -108,9 +159,56 @@ func (a CreateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of CreateRecipient in the Terraform plugin framework type -// system. -func (a CreateRecipient) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRecipient{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRecipient) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRecipient) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRecipient) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRecipient) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRecipient) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRecipient) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRecipient) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authentication_type": types.StringType, @@ -118,12 +216,12 @@ func (a CreateRecipient) ToObjectType(ctx context.Context) types.ObjectType { "data_recipient_global_metastore_id": types.StringType, "expiration_time": types.Int64Type, "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.ToObjectType(ctx), + ElemType: IpAccessList{}.Type(ctx), }, "name": types.StringType, "owner": types.StringType, "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.ToObjectType(ctx), + ElemType: SecurablePropertiesKvPairs{}.Type(ctx), }, "sharing_code": types.StringType, }, @@ -156,9 +254,56 @@ func (a CreateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateShare in the Terraform plugin framework type -// system. -func (a CreateShare) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateShare{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateShare) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateShare) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateShare) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateShare) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateShare) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateShare) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateShare) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -191,9 +336,56 @@ func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteProviderRequest in the Terraform plugin framework type -// system. -func (a DeleteProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteProviderRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -224,9 +416,56 @@ func (a DeleteRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRecipientRequest in the Terraform plugin framework type -// system. -func (a DeleteRecipientRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRecipientRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRecipientRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -254,9 +493,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -285,9 +571,56 @@ func (a DeleteShareRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteShareRequest in the Terraform plugin framework type -// system. -func (a DeleteShareRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteShareRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteShareRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteShareRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteShareRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteShareRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteShareRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteShareRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteShareRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -318,9 +651,56 @@ func (a GetActivationUrlInfoRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetActivationUrlInfoRequest in the Terraform plugin framework type -// system. -func (a GetActivationUrlInfoRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetActivationUrlInfoRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -348,9 +728,56 @@ func (a GetActivationUrlInfoResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetActivationUrlInfoResponse in the Terraform plugin framework type -// system. -func (a GetActivationUrlInfoResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetActivationUrlInfoResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetActivationUrlInfoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -379,9 +806,56 @@ func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetProviderRequest in the Terraform plugin framework type -// system. -func (a GetProviderRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetProviderRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetProviderRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetProviderRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetProviderRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetProviderRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -412,9 +886,56 @@ func (a GetRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRecipientRequest in the Terraform plugin framework type -// system. -func (a GetRecipientRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRecipientRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRecipientRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRecipientRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRecipientRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRecipientRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRecipientRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRecipientRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRecipientRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -450,14 +971,61 @@ func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of GetRecipientSharePermissionsResponse in the Terraform plugin framework type -// system. -func (a GetRecipientSharePermissionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRecipientSharePermissionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRecipientSharePermissionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "permissions_out": basetypes.ListType{ - ElemType: ShareToPrivilegeAssignment{}.ToObjectType(ctx), + ElemType: ShareToPrivilegeAssignment{}.Type(ctx), }, }, } @@ -488,9 +1056,56 @@ func (a GetShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetShareRequest in the Terraform plugin framework type -// system. -func (a GetShareRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetShareRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetShareRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetShareRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetShareRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetShareRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetShareRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetShareRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetShareRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "include_shared_data": types.BoolType, @@ -523,9 +1138,56 @@ func (a IpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of IpAccessList in the Terraform plugin framework type -// system. -func (a IpAccessList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = IpAccessList{} + +// Equal implements basetypes.ObjectValuable. +func (o IpAccessList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o IpAccessList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o IpAccessList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o IpAccessList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o IpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o IpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o IpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "allowed_ip_addresses": basetypes.ListType{ @@ -563,14 +1225,61 @@ func (a ListProviderSharesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ListProviderSharesResponse in the Terraform plugin framework type -// system. -func (a ListProviderSharesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListProviderSharesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListProviderSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "shares": basetypes.ListType{ - ElemType: ProviderShare{}.ToObjectType(ctx), + ElemType: ProviderShare{}.Type(ctx), }, }, } @@ -612,9 +1321,56 @@ func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListProvidersRequest in the Terraform plugin framework type -// system. -func (a ListProvidersRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListProvidersRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListProvidersRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListProvidersRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListProvidersRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListProvidersRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListProvidersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListProvidersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListProvidersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_provider_global_metastore_id": types.StringType, @@ -652,14 +1408,61 @@ func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of ListProvidersResponse in the Terraform plugin framework type -// system. -func (a ListProvidersResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListProvidersResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListProvidersResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListProvidersResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListProvidersResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListProvidersResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListProvidersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListProvidersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.ToObjectType(ctx), + ElemType: ProviderInfo{}.Type(ctx), }, }, } @@ -701,9 +1504,56 @@ func (a ListRecipientsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListRecipientsRequest in the Terraform plugin framework type -// system. -func (a ListRecipientsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRecipientsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRecipientsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_recipient_global_metastore_id": types.StringType, @@ -741,14 +1591,61 @@ func (a ListRecipientsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ListRecipientsResponse in the Terraform plugin framework type -// system. -func (a ListRecipientsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListRecipientsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListRecipientsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "recipients": basetypes.ListType{ - ElemType: RecipientInfo{}.ToObjectType(ctx), + ElemType: RecipientInfo{}.Type(ctx), }, }, } @@ -789,9 +1686,56 @@ func (a ListSharesRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSharesRequest in the Terraform plugin framework type -// system. -func (a ListSharesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSharesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSharesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSharesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSharesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSharesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSharesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSharesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSharesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -829,14 +1773,61 @@ func (a ListSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListSharesResponse in the Terraform plugin framework type -// system. -func (a ListSharesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSharesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSharesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSharesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSharesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSharesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSharesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSharesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "shares": basetypes.ListType{ - ElemType: ShareInfo{}.ToObjectType(ctx), + ElemType: ShareInfo{}.Type(ctx), }, }, } @@ -866,13 +1857,60 @@ func (a Partition) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of Partition in the Terraform plugin framework type -// system. -func (a Partition) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Partition{} + +// Equal implements basetypes.ObjectValuable. +func (o Partition) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Partition) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Partition) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Partition) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Partition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Partition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Partition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": basetypes.ListType{ - ElemType: PartitionValue{}.ToObjectType(ctx), + ElemType: PartitionValue{}.Type(ctx), }, }, } @@ -910,9 +1948,56 @@ func (a PartitionValue) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of PartitionValue in the Terraform plugin framework type -// system. -func (a PartitionValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PartitionValue{} + +// Equal implements basetypes.ObjectValuable. +func (o PartitionValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PartitionValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PartitionValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PartitionValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PartitionValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PartitionValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PartitionValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -949,9 +2034,56 @@ func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of PrivilegeAssignment in the Terraform plugin framework type -// system. -func (a PrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PrivilegeAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -1019,9 +2151,56 @@ func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ProviderInfo in the Terraform plugin framework type -// system. -func (a ProviderInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ProviderInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ProviderInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ProviderInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ProviderInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ProviderInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ProviderInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ProviderInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ProviderInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "authentication_type": types.StringType, @@ -1034,7 +2213,7 @@ func (a ProviderInfo) ToObjectType(ctx context.Context) types.ObjectType { "name": types.StringType, "owner": types.StringType, "recipient_profile": basetypes.ListType{ - ElemType: RecipientProfile{}.ToObjectType(ctx), + ElemType: RecipientProfile{}.Type(ctx), }, "recipient_profile_str": types.StringType, "region": types.StringType, @@ -1066,9 +2245,56 @@ func (a ProviderShare) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ProviderShare in the Terraform plugin framework type -// system. -func (a ProviderShare) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ProviderShare{} + +// Equal implements basetypes.ObjectValuable. +func (o ProviderShare) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ProviderShare) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ProviderShare) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ProviderShare) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ProviderShare) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ProviderShare) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ProviderShare) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -1145,9 +2371,56 @@ func (a RecipientInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of RecipientInfo in the Terraform plugin framework type -// system. -func (a RecipientInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RecipientInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RecipientInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RecipientInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RecipientInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RecipientInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RecipientInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RecipientInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RecipientInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activated": types.BoolType, @@ -1159,18 +2432,18 @@ func (a RecipientInfo) ToObjectType(ctx context.Context) types.ObjectType { "created_by": types.StringType, "data_recipient_global_metastore_id": types.StringType, "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.ToObjectType(ctx), + ElemType: IpAccessList{}.Type(ctx), }, "metastore_id": types.StringType, "name": types.StringType, "owner": types.StringType, "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.ToObjectType(ctx), + ElemType: SecurablePropertiesKvPairs{}.Type(ctx), }, "region": types.StringType, "sharing_code": types.StringType, "tokens": basetypes.ListType{ - ElemType: RecipientTokenInfo{}.ToObjectType(ctx), + ElemType: RecipientTokenInfo{}.Type(ctx), }, "updated_at": types.Int64Type, "updated_by": types.StringType, @@ -1193,20 +2466,67 @@ func (newState *RecipientProfile) SyncEffectiveFieldsDuringCreateOrUpdate(plan R func (newState *RecipientProfile) SyncEffectiveFieldsDuringRead(existingState RecipientProfile) { } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in RecipientProfile. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a RecipientProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RecipientProfile. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a RecipientProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RecipientProfile{} + +// Equal implements basetypes.ObjectValuable. +func (o RecipientProfile) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RecipientProfile) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RecipientProfile) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RecipientProfile) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RecipientProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RecipientProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of RecipientProfile in the Terraform plugin framework type -// system. -func (a RecipientProfile) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o RecipientProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bearer_token": types.StringType, @@ -1251,9 +2571,56 @@ func (a RecipientTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of RecipientTokenInfo in the Terraform plugin framework type -// system. -func (a RecipientTokenInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RecipientTokenInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RecipientTokenInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -1290,9 +2657,56 @@ func (a RetrieveTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of RetrieveTokenRequest in the Terraform plugin framework type -// system. -func (a RetrieveTokenRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RetrieveTokenRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RetrieveTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "activation_url": types.StringType, @@ -1328,9 +2742,56 @@ func (a RetrieveTokenResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of RetrieveTokenResponse in the Terraform plugin framework type -// system. -func (a RetrieveTokenResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RetrieveTokenResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RetrieveTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bearerToken": types.StringType, @@ -1368,9 +2829,56 @@ func (a RotateRecipientToken) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of RotateRecipientToken in the Terraform plugin framework type -// system. -func (a RotateRecipientToken) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RotateRecipientToken{} + +// Equal implements basetypes.ObjectValuable. +func (o RotateRecipientToken) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RotateRecipientToken) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RotateRecipientToken) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RotateRecipientToken) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RotateRecipientToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RotateRecipientToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RotateRecipientToken) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "existing_token_expire_in_seconds": types.Int64Type, @@ -1405,9 +2913,56 @@ func (a SecurablePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of SecurablePropertiesKvPairs in the Terraform plugin framework type -// system. -func (a SecurablePropertiesKvPairs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SecurablePropertiesKvPairs{} + +// Equal implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SecurablePropertiesKvPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "properties": basetypes.MapType{ @@ -1459,9 +3014,56 @@ func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of ShareInfo in the Terraform plugin framework type -// system. -func (a ShareInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ShareInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ShareInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ShareInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ShareInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ShareInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ShareInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ShareInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ShareInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1469,7 +3071,7 @@ func (a ShareInfo) ToObjectType(ctx context.Context) types.ObjectType { "created_by": types.StringType, "name": types.StringType, "object": basetypes.ListType{ - ElemType: SharedDataObject{}.ToObjectType(ctx), + ElemType: SharedDataObject{}.Type(ctx), }, "owner": types.StringType, "storage_location": types.StringType, @@ -1515,9 +3117,56 @@ func (a SharePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of SharePermissionsRequest in the Terraform plugin framework type -// system. -func (a SharePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SharePermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SharePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "max_results": types.Int64Type, @@ -1553,13 +3202,60 @@ func (a ShareToPrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of ShareToPrivilegeAssignment in the Terraform plugin framework type -// system. -func (a ShareToPrivilegeAssignment) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ShareToPrivilegeAssignment{} + +// Equal implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ShareToPrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "privilege_assignments": basetypes.ListType{ - ElemType: PrivilegeAssignment{}.ToObjectType(ctx), + ElemType: PrivilegeAssignment{}.Type(ctx), }, "share_name": types.StringType, }, @@ -1635,9 +3331,56 @@ func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of SharedDataObject in the Terraform plugin framework type -// system. -func (a SharedDataObject) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SharedDataObject{} + +// Equal implements basetypes.ObjectValuable. +func (o SharedDataObject) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SharedDataObject) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SharedDataObject) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SharedDataObject) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SharedDataObject) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SharedDataObject) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SharedDataObject) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "added_at": types.Int64Type, @@ -1649,7 +3392,7 @@ func (a SharedDataObject) ToObjectType(ctx context.Context) types.ObjectType { "history_data_sharing_status": types.StringType, "name": types.StringType, "partition": basetypes.ListType{ - ElemType: Partition{}.ToObjectType(ctx), + ElemType: Partition{}.Type(ctx), }, "shared_as": types.StringType, "start_version": types.Int64Type, @@ -1685,14 +3428,61 @@ func (a SharedDataObjectUpdate) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of SharedDataObjectUpdate in the Terraform plugin framework type -// system. -func (a SharedDataObjectUpdate) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SharedDataObjectUpdate{} + +// Equal implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SharedDataObjectUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "action": types.StringType, "data_object": basetypes.ListType{ - ElemType: SharedDataObject{}.ToObjectType(ctx), + ElemType: SharedDataObject{}.Type(ctx), }, }, } @@ -1718,9 +3508,56 @@ func (a UpdatePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdatePermissionsResponse in the Terraform plugin framework type -// system. -func (a UpdatePermissionsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdatePermissionsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdatePermissionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1757,9 +3594,56 @@ func (a UpdateProvider) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateProvider in the Terraform plugin framework type -// system. -func (a UpdateProvider) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateProvider{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateProvider) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateProvider) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateProvider) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateProvider) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateProvider) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateProvider) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateProvider) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1811,21 +3695,68 @@ func (a UpdateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of UpdateRecipient in the Terraform plugin framework type -// system. -func (a UpdateRecipient) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRecipient{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRecipient) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRecipient) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRecipient) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRecipient) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRecipient) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRecipient) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRecipient) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, "expiration_time": types.Int64Type, "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.ToObjectType(ctx), + ElemType: IpAccessList{}.Type(ctx), }, "name": types.StringType, "new_name": types.StringType, "owner": types.StringType, "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.ToObjectType(ctx), + ElemType: SecurablePropertiesKvPairs{}.Type(ctx), }, }, } @@ -1851,9 +3782,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1893,9 +3871,56 @@ func (a UpdateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of UpdateShare in the Terraform plugin framework type -// system. -func (a UpdateShare) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateShare{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateShare) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateShare) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateShare) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateShare) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateShare) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateShare) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateShare) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "comment": types.StringType, @@ -1904,7 +3929,7 @@ func (a UpdateShare) ToObjectType(ctx context.Context) types.ObjectType { "owner": types.StringType, "storage_root": types.StringType, "updates": basetypes.ListType{ - ElemType: SharedDataObjectUpdate{}.ToObjectType(ctx), + ElemType: SharedDataObjectUpdate{}.Type(ctx), }, }, } @@ -1948,13 +3973,60 @@ func (a UpdateSharePermissions) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of UpdateSharePermissions in the Terraform plugin framework type -// system. -func (a UpdateSharePermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateSharePermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateSharePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "changes": basetypes.ListType{ - ElemType: catalog_tf.PermissionsChange{}.ToObjectType(ctx), + ElemType: catalog_tf.PermissionsChange{}.Type(ctx), }, "max_results": types.Int64Type, "name": types.StringType, @@ -1962,3 +4034,16 @@ func (a UpdateSharePermissions) ToObjectType(ctx context.Context) types.ObjectTy }, } } + +// The delta sharing authentication type. + +// The operator to apply for the value. + +// The type of the data object. + +// Whether to enable or disable sharing of data history. If not specified, the +// default is **DISABLED**. + +// One of: **ACTIVE**, **PERMISSION_DENIED**. + +// One of: **ADD**, **REMOVE**, **UPDATE**. diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index e35cc362fd..38e572bc37 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -12,11 +12,15 @@ package sql_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AccessControl struct { @@ -45,9 +49,56 @@ func (a AccessControl) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of AccessControl in the Terraform plugin framework type -// system. -func (a AccessControl) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AccessControl{} + +// Equal implements basetypes.ObjectValuable. +func (o AccessControl) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AccessControl) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AccessControl) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AccessControl) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AccessControl) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AccessControl) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AccessControl) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -122,13 +173,60 @@ func (a Alert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of Alert in the Terraform plugin framework type -// system. -func (a Alert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Alert{} + +// Equal implements basetypes.ObjectValuable. +func (o Alert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Alert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Alert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Alert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Alert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Alert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Alert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToObjectType(ctx), + ElemType: AlertCondition{}.Type(ctx), }, "create_time": types.StringType, "custom_body": types.StringType, @@ -180,18 +278,65 @@ func (a AlertCondition) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of AlertCondition in the Terraform plugin framework type -// system. -func (a AlertCondition) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertCondition{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertCondition) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertCondition) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertCondition) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertCondition) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertCondition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertCondition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertCondition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "empty_result_state": types.StringType, "op": types.StringType, "operand": basetypes.ListType{ - ElemType: AlertConditionOperand{}.ToObjectType(ctx), + ElemType: AlertConditionOperand{}.Type(ctx), }, "threshold": basetypes.ListType{ - ElemType: AlertConditionThreshold{}.ToObjectType(ctx), + ElemType: AlertConditionThreshold{}.Type(ctx), }, }, } @@ -220,13 +365,60 @@ func (a AlertConditionOperand) GetComplexFieldTypes(ctx context.Context) map[str } } -// ToObjectType returns the representation of AlertConditionOperand in the Terraform plugin framework type -// system. -func (a AlertConditionOperand) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertConditionOperand{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertConditionOperand) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertConditionOperand) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertConditionOperand) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertConditionOperand) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertConditionOperand) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertConditionOperand) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertConditionOperand) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column": basetypes.ListType{ - ElemType: AlertOperandColumn{}.ToObjectType(ctx), + ElemType: AlertOperandColumn{}.Type(ctx), }, }, } @@ -255,13 +447,60 @@ func (a AlertConditionThreshold) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of AlertConditionThreshold in the Terraform plugin framework type -// system. -func (a AlertConditionThreshold) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertConditionThreshold{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertConditionThreshold) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": basetypes.ListType{ - ElemType: AlertOperandValue{}.ToObjectType(ctx), + ElemType: AlertOperandValue{}.Type(ctx), }, }, } @@ -288,9 +527,56 @@ func (a AlertOperandColumn) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of AlertOperandColumn in the Terraform plugin framework type -// system. -func (a AlertOperandColumn) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertOperandColumn{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertOperandColumn) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertOperandColumn) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertOperandColumn) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertOperandColumn) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertOperandColumn) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertOperandColumn) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertOperandColumn) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -323,9 +609,56 @@ func (a AlertOperandValue) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of AlertOperandValue in the Terraform plugin framework type -// system. -func (a AlertOperandValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertOperandValue{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertOperandValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertOperandValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertOperandValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertOperandValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertOperandValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertOperandValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertOperandValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bool_value": types.BoolType, @@ -380,9 +713,56 @@ func (a AlertOptions) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of AlertOptions in the Terraform plugin framework type -// system. -func (a AlertOptions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertOptions{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertOptions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertOptions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertOptions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertOptions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column": types.StringType, @@ -458,9 +838,56 @@ func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of AlertQuery in the Terraform plugin framework type -// system. -func (a AlertQuery) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AlertQuery{} + +// Equal implements basetypes.ObjectValuable. +func (o AlertQuery) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AlertQuery) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AlertQuery) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AlertQuery) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AlertQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AlertQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AlertQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -472,7 +899,7 @@ func (a AlertQuery) ToObjectType(ctx context.Context) types.ObjectType { "is_safe": types.BoolType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: QueryOptions{}.ToObjectType(ctx), + ElemType: QueryOptions{}.Type(ctx), }, "query": types.StringType, "tags": basetypes.ListType{ @@ -516,9 +943,56 @@ func (a BaseChunkInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of BaseChunkInfo in the Terraform plugin framework type -// system. -func (a BaseChunkInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = BaseChunkInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o BaseChunkInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o BaseChunkInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o BaseChunkInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o BaseChunkInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o BaseChunkInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o BaseChunkInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o BaseChunkInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_count": types.Int64Type, @@ -553,9 +1027,56 @@ func (a CancelExecutionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelExecutionRequest in the Terraform plugin framework type -// system. -func (a CancelExecutionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelExecutionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelExecutionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statement_id": types.StringType, @@ -583,9 +1104,56 @@ func (a CancelExecutionResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of CancelExecutionResponse in the Terraform plugin framework type -// system. -func (a CancelExecutionResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CancelExecutionResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CancelExecutionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -616,9 +1184,56 @@ func (a Channel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of Channel in the Terraform plugin framework type -// system. -func (a Channel) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Channel{} + +// Equal implements basetypes.ObjectValuable. +func (o Channel) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Channel) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Channel) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Channel) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Channel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Channel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Channel) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbsql_version": types.StringType, @@ -652,9 +1267,56 @@ func (a ChannelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of ChannelInfo in the Terraform plugin framework type -// system. -func (a ChannelInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ChannelInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ChannelInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ChannelInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ChannelInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ChannelInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ChannelInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ChannelInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ChannelInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dbsql_version": types.StringType, @@ -700,9 +1362,56 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of ColumnInfo in the Terraform plugin framework type -// system. -func (a ColumnInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ColumnInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ColumnInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ColumnInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ColumnInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ColumnInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ColumnInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ColumnInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ColumnInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -750,14 +1459,61 @@ func (a CreateAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of CreateAlert in the Terraform plugin framework type -// system. -func (a CreateAlert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, "options": basetypes.ListType{ - ElemType: AlertOptions{}.ToObjectType(ctx), + ElemType: AlertOptions{}.Type(ctx), }, "parent": types.StringType, "query_id": types.StringType, @@ -789,13 +1545,60 @@ func (a CreateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateAlertRequest in the Terraform plugin framework type -// system. -func (a CreateAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateAlertRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateAlertRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateAlertRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateAlertRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateAlertRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert": basetypes.ListType{ - ElemType: CreateAlertRequestAlert{}.ToObjectType(ctx), + ElemType: CreateAlertRequestAlert{}.Type(ctx), }, }, } @@ -848,13 +1651,60 @@ func (a CreateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of CreateAlertRequestAlert in the Terraform plugin framework type -// system. -func (a CreateAlertRequestAlert) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateAlertRequestAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateAlertRequestAlert) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToObjectType(ctx), + ElemType: AlertCondition{}.Type(ctx), }, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -890,13 +1740,60 @@ func (a CreateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateQueryRequest in the Terraform plugin framework type -// system. -func (a CreateQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateQueryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateQueryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateQueryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateQueryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateQueryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query": basetypes.ListType{ - ElemType: CreateQueryRequestQuery{}.ToObjectType(ctx), + ElemType: CreateQueryRequestQuery{}.Type(ctx), }, }, } @@ -949,9 +1846,56 @@ func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of CreateQueryRequestQuery in the Terraform plugin framework type -// system. -func (a CreateQueryRequestQuery) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateQueryRequestQuery{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateQueryRequestQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -959,7 +1903,7 @@ func (a CreateQueryRequestQuery) ToObjectType(ctx context.Context) types.ObjectT "description": types.StringType, "display_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToObjectType(ctx), + ElemType: QueryParameter{}.Type(ctx), }, "parent_path": types.StringType, "query_text": types.StringType, @@ -988,7 +1932,7 @@ type CreateQueryVisualizationsLegacyRequest struct { // The identifier returned by :method:queries/create QueryId types.String `tfsdk:"query_id" tf:""` // The type of visualization: chart, table, pivot table, and so on. - Type types.String `tfsdk:"type" tf:""` + Type_ types.String `tfsdk:"type" tf:""` } func (newState *CreateQueryVisualizationsLegacyRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateQueryVisualizationsLegacyRequest) { @@ -1008,9 +1952,56 @@ func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateQueryVisualizationsLegacyRequest in the Terraform plugin framework type -// system. -func (a CreateQueryVisualizationsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateQueryVisualizationsLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateQueryVisualizationsLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -1045,13 +2036,60 @@ func (a CreateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of CreateVisualizationRequest in the Terraform plugin framework type -// system. -func (a CreateVisualizationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateVisualizationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "visualization": basetypes.ListType{ - ElemType: CreateVisualizationRequestVisualization{}.ToObjectType(ctx), + ElemType: CreateVisualizationRequestVisualization{}.Type(ctx), }, }, } @@ -1071,7 +2109,7 @@ type CreateVisualizationRequestVisualization struct { // visualization query plan directly. SerializedQueryPlan types.String `tfsdk:"serialized_query_plan" tf:"optional"` // The type of visualization: counter, table, funnel, and so on. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *CreateVisualizationRequestVisualization) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateVisualizationRequestVisualization) { @@ -1091,9 +2129,56 @@ func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateVisualizationRequestVisualization in the Terraform plugin framework type -// system. -func (a CreateVisualizationRequestVisualization) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateVisualizationRequestVisualization{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateVisualizationRequestVisualization) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -1189,14 +2274,61 @@ func (a CreateWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of CreateWarehouseRequest in the Terraform plugin framework type -// system. -func (a CreateWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateWarehouseRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToObjectType(ctx), + ElemType: Channel{}.Type(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, @@ -1208,7 +2340,7 @@ func (a CreateWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectTy "name": types.StringType, "spot_instance_policy": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToObjectType(ctx), + ElemType: EndpointTags{}.Type(ctx), }, "warehouse_type": types.StringType, }, @@ -1237,9 +2369,56 @@ func (a CreateWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateWarehouseResponse in the Terraform plugin framework type -// system. -func (a CreateWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateWarehouseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1283,15 +2462,62 @@ func (a CreateWidget) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of CreateWidget in the Terraform plugin framework type -// system. -func (a CreateWidget) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateWidget{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateWidget) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateWidget) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateWidget) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateWidget) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateWidget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateWidget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateWidget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "id": types.StringType, "options": basetypes.ListType{ - ElemType: WidgetOptions{}.ToObjectType(ctx), + ElemType: WidgetOptions{}.Type(ctx), }, "text": types.StringType, "visualization_id": types.StringType, @@ -1371,9 +2597,56 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of Dashboard in the Terraform plugin framework type -// system. -func (a Dashboard) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Dashboard{} + +// Equal implements basetypes.ObjectValuable. +func (o Dashboard) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Dashboard) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Dashboard) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Dashboard) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Dashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Dashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Dashboard) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "can_edit": types.BoolType, @@ -1385,7 +2658,7 @@ func (a Dashboard) ToObjectType(ctx context.Context) types.ObjectType { "is_favorite": types.BoolType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: DashboardOptions{}.ToObjectType(ctx), + ElemType: DashboardOptions{}.Type(ctx), }, "parent": types.StringType, "permission_tier": types.StringType, @@ -1395,11 +2668,11 @@ func (a Dashboard) ToObjectType(ctx context.Context) types.ObjectType { }, "updated_at": types.StringType, "user": basetypes.ListType{ - ElemType: User{}.ToObjectType(ctx), + ElemType: User{}.Type(ctx), }, "user_id": types.Int64Type, "widgets": basetypes.ListType{ - ElemType: Widget{}.ToObjectType(ctx), + ElemType: Widget{}.Type(ctx), }, }, } @@ -1437,9 +2710,56 @@ func (a DashboardEditContent) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of DashboardEditContent in the Terraform plugin framework type -// system. -func (a DashboardEditContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DashboardEditContent{} + +// Equal implements basetypes.ObjectValuable. +func (o DashboardEditContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DashboardEditContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DashboardEditContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DashboardEditContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DashboardEditContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DashboardEditContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DashboardEditContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1476,9 +2796,56 @@ func (a DashboardOptions) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of DashboardOptions in the Terraform plugin framework type -// system. -func (a DashboardOptions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DashboardOptions{} + +// Equal implements basetypes.ObjectValuable. +func (o DashboardOptions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DashboardOptions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DashboardOptions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DashboardOptions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DashboardOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DashboardOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DashboardOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "moved_to_trash_at": types.StringType, @@ -1524,9 +2891,56 @@ func (a DashboardPostContent) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of DashboardPostContent in the Terraform plugin framework type -// system. -func (a DashboardPostContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DashboardPostContent{} + +// Equal implements basetypes.ObjectValuable. +func (o DashboardPostContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DashboardPostContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DashboardPostContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DashboardPostContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DashboardPostContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DashboardPostContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DashboardPostContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_filters_enabled": types.BoolType, @@ -1561,7 +2975,7 @@ type DataSource struct { Syntax types.String `tfsdk:"syntax" tf:"optional"` // The type of data source. For SQL warehouses, this will be // `databricks_internal`. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` // Reserved for internal use. ViewOnly types.Bool `tfsdk:"view_only" tf:"optional"` // The ID of the associated SQL warehouse, if this data source is backed by @@ -1586,9 +3000,56 @@ func (a DataSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of DataSource in the Terraform plugin framework type -// system. -func (a DataSource) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DataSource{} + +// Equal implements basetypes.ObjectValuable. +func (o DataSource) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DataSource) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DataSource) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DataSource) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DataSource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DataSource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DataSource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1627,9 +3088,56 @@ func (a DateRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DateRange in the Terraform plugin framework type -// system. -func (a DateRange) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DateRange{} + +// Equal implements basetypes.ObjectValuable. +func (o DateRange) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DateRange) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DateRange) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DateRange) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DateRange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DateRange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DateRange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end": types.StringType, @@ -1669,13 +3177,60 @@ func (a DateRangeValue) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of DateRangeValue in the Terraform plugin framework type -// system. -func (a DateRangeValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DateRangeValue{} + +// Equal implements basetypes.ObjectValuable. +func (o DateRangeValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DateRangeValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DateRangeValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DateRangeValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DateRangeValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DateRangeValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DateRangeValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "date_range_value": basetypes.ListType{ - ElemType: DateRange{}.ToObjectType(ctx), + ElemType: DateRange{}.Type(ctx), }, "dynamic_date_range_value": types.StringType, "precision": types.StringType, @@ -1711,9 +3266,56 @@ func (a DateValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DateValue in the Terraform plugin framework type -// system. -func (a DateValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DateValue{} + +// Equal implements basetypes.ObjectValuable. +func (o DateValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DateValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DateValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DateValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DateValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DateValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DateValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "date_value": types.StringType, @@ -1745,9 +3347,56 @@ func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAlertsLegacyRequest in the Terraform plugin framework type -// system. -func (a DeleteAlertsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAlertsLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAlertsLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, @@ -1777,9 +3426,56 @@ func (a DeleteDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDashboardRequest in the Terraform plugin framework type -// system. -func (a DeleteDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -1810,9 +3506,56 @@ func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteDashboardWidgetRequest in the Terraform plugin framework type -// system. -func (a DeleteDashboardWidgetRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDashboardWidgetRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDashboardWidgetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1842,9 +3585,56 @@ func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteQueriesLegacyRequest in the Terraform plugin framework type -// system. -func (a DeleteQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteQueriesLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteQueriesLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -1875,9 +3665,56 @@ func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteQueryVisualizationsLegacyRequest in the Terraform plugin framework type -// system. -func (a DeleteQueryVisualizationsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteQueryVisualizationsLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteQueryVisualizationsLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1905,9 +3742,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1935,9 +3819,56 @@ func (a DeleteVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteVisualizationRequest in the Terraform plugin framework type -// system. -func (a DeleteVisualizationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteVisualizationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1968,9 +3899,56 @@ func (a DeleteWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWarehouseRequest in the Terraform plugin framework type -// system. -func (a DeleteWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWarehouseRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -1998,9 +3976,56 @@ func (a DeleteWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteWarehouseResponse in the Terraform plugin framework type -// system. -func (a DeleteWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteWarehouseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2039,15 +4064,62 @@ func (a EditAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of EditAlert in the Terraform plugin framework type -// system. -func (a EditAlert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o EditAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: AlertOptions{}.ToObjectType(ctx), + ElemType: AlertOptions{}.Type(ctx), }, "query_id": types.StringType, "rearm": types.Int64Type, @@ -2139,14 +4211,61 @@ func (a EditWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of EditWarehouseRequest in the Terraform plugin framework type -// system. -func (a EditWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditWarehouseRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToObjectType(ctx), + ElemType: Channel{}.Type(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, @@ -2159,7 +4278,7 @@ func (a EditWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType "name": types.StringType, "spot_instance_policy": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToObjectType(ctx), + ElemType: EndpointTags{}.Type(ctx), }, "warehouse_type": types.StringType, }, @@ -2186,9 +4305,56 @@ func (a EditWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of EditWarehouseResponse in the Terraform plugin framework type -// system. -func (a EditWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EditWarehouseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EditWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2216,9 +4382,56 @@ func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of Empty in the Terraform plugin framework type -// system. -func (a Empty) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Empty{} + +// Equal implements basetypes.ObjectValuable. +func (o Empty) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Empty) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Empty) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Empty) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Empty) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Empty) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Empty) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2247,9 +4460,56 @@ func (a EndpointConfPair) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of EndpointConfPair in the Terraform plugin framework type -// system. -func (a EndpointConfPair) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointConfPair{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointConfPair) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointConfPair) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointConfPair) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointConfPair) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointConfPair) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointConfPair) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointConfPair) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2292,14 +4552,61 @@ func (a EndpointHealth) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of EndpointHealth in the Terraform plugin framework type -// system. -func (a EndpointHealth) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointHealth{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointHealth) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointHealth) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointHealth) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointHealth) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointHealth) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointHealth) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointHealth) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "details": types.StringType, "failure_reason": basetypes.ListType{ - ElemType: TerminationReason{}.ToObjectType(ctx), + ElemType: TerminationReason{}.Type(ctx), }, "message": types.StringType, "status": types.StringType, @@ -2407,21 +4714,68 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of EndpointInfo in the Terraform plugin framework type -// system. -func (a EndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToObjectType(ctx), + ElemType: Channel{}.Type(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, "health": basetypes.ListType{ - ElemType: EndpointHealth{}.ToObjectType(ctx), + ElemType: EndpointHealth{}.Type(ctx), }, "id": types.StringType, "instance_profile_arn": types.StringType, @@ -2432,12 +4786,12 @@ func (a EndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { "num_active_sessions": types.Int64Type, "num_clusters": types.Int64Type, "odbc_params": basetypes.ListType{ - ElemType: OdbcParams{}.ToObjectType(ctx), + ElemType: OdbcParams{}.Type(ctx), }, "spot_instance_policy": types.StringType, "state": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToObjectType(ctx), + ElemType: EndpointTags{}.Type(ctx), }, "warehouse_type": types.StringType, }, @@ -2467,9 +4821,56 @@ func (a EndpointTagPair) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of EndpointTagPair in the Terraform plugin framework type -// system. -func (a EndpointTagPair) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointTagPair{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointTagPair) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointTagPair) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointTagPair) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointTagPair) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointTagPair) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointTagPair) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointTagPair) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2501,13 +4902,60 @@ func (a EndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of EndpointTags in the Terraform plugin framework type -// system. -func (a EndpointTags) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointTags{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointTags) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointTags) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointTags) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointTags) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointTags) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointTags) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointTags) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "custom_tags": basetypes.ListType{ - ElemType: EndpointTagPair{}.ToObjectType(ctx), + ElemType: EndpointTagPair{}.Type(ctx), }, }, } @@ -2542,14 +4990,61 @@ func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of EnumValue in the Terraform plugin framework type -// system. -func (a EnumValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EnumValue{} + +// Equal implements basetypes.ObjectValuable. +func (o EnumValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EnumValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EnumValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EnumValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EnumValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EnumValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EnumValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enum_options": types.StringType, "multi_values_options": basetypes.ListType{ - ElemType: MultiValuesOptions{}.ToObjectType(ctx), + ElemType: MultiValuesOptions{}.Type(ctx), }, "values": basetypes.ListType{ ElemType: types.StringType, @@ -2703,9 +5198,56 @@ func (a ExecuteStatementRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ExecuteStatementRequest in the Terraform plugin framework type -// system. -func (a ExecuteStatementRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExecuteStatementRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExecuteStatementRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_limit": types.Int64Type, @@ -2714,7 +5256,7 @@ func (a ExecuteStatementRequest) ToObjectType(ctx context.Context) types.ObjectT "format": types.StringType, "on_wait_timeout": types.StringType, "parameters": basetypes.ListType{ - ElemType: StatementParameterListItem{}.ToObjectType(ctx), + ElemType: StatementParameterListItem{}.Type(ctx), }, "row_limit": types.Int64Type, "schema": types.StringType, @@ -2777,9 +5319,56 @@ func (a ExternalLink) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ExternalLink in the Terraform plugin framework type -// system. -func (a ExternalLink) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExternalLink{} + +// Equal implements basetypes.ObjectValuable. +func (o ExternalLink) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExternalLink) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExternalLink) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExternalLink) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExternalLink) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExternalLink) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExternalLink) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_count": types.Int64Type, @@ -2819,9 +5408,56 @@ func (a GetAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAlertRequest in the Terraform plugin framework type -// system. -func (a GetAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAlertRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAlertRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAlertRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAlertRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAlertRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -2851,9 +5487,56 @@ func (a GetAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAlertsLegacyRequest in the Terraform plugin framework type -// system. -func (a GetAlertsLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAlertsLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAlertsLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, @@ -2883,9 +5566,56 @@ func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDashboardRequest in the Terraform plugin framework type -// system. -func (a GetDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -2918,9 +5648,56 @@ func (a GetDbsqlPermissionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetDbsqlPermissionRequest in the Terraform plugin framework type -// system. -func (a GetDbsqlPermissionRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetDbsqlPermissionRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "objectId": types.StringType, @@ -2951,9 +5728,56 @@ func (a GetQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetQueriesLegacyRequest in the Terraform plugin framework type -// system. -func (a GetQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetQueriesLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetQueriesLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -2983,9 +5807,56 @@ func (a GetQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetQueryRequest in the Terraform plugin framework type -// system. -func (a GetQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetQueryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetQueryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetQueryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetQueryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetQueryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3020,13 +5891,60 @@ func (a GetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of GetResponse in the Terraform plugin framework type -// system. -func (a GetResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.ToObjectType(ctx), + ElemType: AccessControl{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -3058,9 +5976,56 @@ func (a GetStatementRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStatementRequest in the Terraform plugin framework type -// system. -func (a GetStatementRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStatementRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStatementRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStatementRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStatementRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStatementRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStatementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStatementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStatementRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "statement_id": types.StringType, @@ -3093,9 +6058,56 @@ func (a GetStatementResultChunkNRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStatementResultChunkNRequest in the Terraform plugin framework type -// system. -func (a GetStatementResultChunkNRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStatementResultChunkNRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStatementResultChunkNRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "chunk_index": types.Int64Type, @@ -3127,9 +6139,56 @@ func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWarehousePermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetWarehousePermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWarehousePermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, @@ -3161,13 +6220,60 @@ func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of GetWarehousePermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetWarehousePermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWarehousePermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWarehousePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: WarehousePermissionsDescription{}.ToObjectType(ctx), + ElemType: WarehousePermissionsDescription{}.Type(ctx), }, }, } @@ -3196,9 +6302,56 @@ func (a GetWarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWarehousePermissionsRequest in the Terraform plugin framework type -// system. -func (a GetWarehousePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWarehousePermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWarehousePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, @@ -3229,9 +6382,56 @@ func (a GetWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWarehouseRequest in the Terraform plugin framework type -// system. -func (a GetWarehouseRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWarehouseRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -3338,21 +6538,68 @@ func (a GetWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of GetWarehouseResponse in the Terraform plugin framework type -// system. -func (a GetWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWarehouseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "auto_stop_mins": types.Int64Type, "channel": basetypes.ListType{ - ElemType: Channel{}.ToObjectType(ctx), + ElemType: Channel{}.Type(ctx), }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, "health": basetypes.ListType{ - ElemType: EndpointHealth{}.ToObjectType(ctx), + ElemType: EndpointHealth{}.Type(ctx), }, "id": types.StringType, "instance_profile_arn": types.StringType, @@ -3363,12 +6610,12 @@ func (a GetWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType "num_active_sessions": types.Int64Type, "num_clusters": types.Int64Type, "odbc_params": basetypes.ListType{ - ElemType: OdbcParams{}.ToObjectType(ctx), + ElemType: OdbcParams{}.Type(ctx), }, "spot_instance_policy": types.StringType, "state": types.StringType, "tags": basetypes.ListType{ - ElemType: EndpointTags{}.ToObjectType(ctx), + ElemType: EndpointTags{}.Type(ctx), }, "warehouse_type": types.StringType, }, @@ -3427,31 +6674,78 @@ func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co } } -// ToObjectType returns the representation of GetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type -// system. -func (a GetWorkspaceWarehouseConfigResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceWarehouseConfigResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ - ElemType: Channel{}.ToObjectType(ctx), + ElemType: Channel{}.Type(ctx), }, "config_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), }, "data_access_config": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToObjectType(ctx), + ElemType: EndpointConfPair{}.Type(ctx), }, "enabled_warehouse_types": basetypes.ListType{ - ElemType: WarehouseTypePair{}.ToObjectType(ctx), + ElemType: WarehouseTypePair{}.Type(ctx), }, "global_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), }, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, "security_policy": types.StringType, "sql_configuration_parameters": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), }, }, } @@ -3507,9 +6801,56 @@ func (a LegacyAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of LegacyAlert in the Terraform plugin framework type -// system. -func (a LegacyAlert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LegacyAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o LegacyAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LegacyAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LegacyAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LegacyAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LegacyAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LegacyAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LegacyAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -3517,17 +6858,17 @@ func (a LegacyAlert) ToObjectType(ctx context.Context) types.ObjectType { "last_triggered_at": types.StringType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: AlertOptions{}.ToObjectType(ctx), + ElemType: AlertOptions{}.Type(ctx), }, "parent": types.StringType, "query": basetypes.ListType{ - ElemType: AlertQuery{}.ToObjectType(ctx), + ElemType: AlertQuery{}.Type(ctx), }, "rearm": types.Int64Type, "state": types.StringType, "updated_at": types.StringType, "user": basetypes.ListType{ - ElemType: User{}.ToObjectType(ctx), + ElemType: User{}.Type(ctx), }, }, } @@ -3627,9 +6968,56 @@ func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of LegacyQuery in the Terraform plugin framework type -// system. -func (a LegacyQuery) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LegacyQuery{} + +// Equal implements basetypes.ObjectValuable. +func (o LegacyQuery) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LegacyQuery) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LegacyQuery) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LegacyQuery) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LegacyQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LegacyQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LegacyQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "can_edit": types.BoolType, @@ -3642,13 +7030,13 @@ func (a LegacyQuery) ToObjectType(ctx context.Context) types.ObjectType { "is_favorite": types.BoolType, "is_safe": types.BoolType, "last_modified_by": basetypes.ListType{ - ElemType: User{}.ToObjectType(ctx), + ElemType: User{}.Type(ctx), }, "last_modified_by_id": types.Int64Type, "latest_query_data_id": types.StringType, "name": types.StringType, "options": basetypes.ListType{ - ElemType: QueryOptions{}.ToObjectType(ctx), + ElemType: QueryOptions{}.Type(ctx), }, "parent": types.StringType, "permission_tier": types.StringType, @@ -3660,11 +7048,11 @@ func (a LegacyQuery) ToObjectType(ctx context.Context) types.ObjectType { }, "updated_at": types.StringType, "user": basetypes.ListType{ - ElemType: User{}.ToObjectType(ctx), + ElemType: User{}.Type(ctx), }, "user_id": types.Int64Type, "visualizations": basetypes.ListType{ - ElemType: LegacyVisualization{}.ToObjectType(ctx), + ElemType: LegacyVisualization{}.Type(ctx), }, }, } @@ -3692,7 +7080,7 @@ type LegacyVisualization struct { Query types.List `tfsdk:"query" tf:"optional,object"` // The type of visualization: chart, table, pivot table, and so on. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` UpdatedAt types.String `tfsdk:"updated_at" tf:"optional"` } @@ -3716,9 +7104,56 @@ func (a LegacyVisualization) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of LegacyVisualization in the Terraform plugin framework type -// system. -func (a LegacyVisualization) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = LegacyVisualization{} + +// Equal implements basetypes.ObjectValuable. +func (o LegacyVisualization) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o LegacyVisualization) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o LegacyVisualization) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o LegacyVisualization) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o LegacyVisualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o LegacyVisualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o LegacyVisualization) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -3727,7 +7162,7 @@ func (a LegacyVisualization) ToObjectType(ctx context.Context) types.ObjectType "name": types.StringType, "options": types.ObjectType{}, "query": basetypes.ListType{ - ElemType: LegacyQuery{}.ToObjectType(ctx), + ElemType: LegacyQuery{}.Type(ctx), }, "type": types.StringType, "updated_at": types.StringType, @@ -3759,9 +7194,56 @@ func (a ListAlertsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAlertsRequest in the Terraform plugin framework type -// system. -func (a ListAlertsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAlertsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAlertsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAlertsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAlertsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAlertsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAlertsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAlertsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAlertsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -3795,14 +7277,61 @@ func (a ListAlertsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListAlertsResponse in the Terraform plugin framework type -// system. -func (a ListAlertsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAlertsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAlertsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAlertsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAlertsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAlertsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAlertsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAlertsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAlertsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: ListAlertsResponseAlert{}.ToObjectType(ctx), + ElemType: ListAlertsResponseAlert{}.Type(ctx), }, }, } @@ -3871,13 +7400,60 @@ func (a ListAlertsResponseAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ListAlertsResponseAlert in the Terraform plugin framework type -// system. -func (a ListAlertsResponseAlert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAlertsResponseAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAlertsResponseAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToObjectType(ctx), + ElemType: AlertCondition{}.Type(ctx), }, "create_time": types.StringType, "custom_body": types.StringType, @@ -3925,9 +7501,56 @@ func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListDashboardsRequest in the Terraform plugin framework type -// system. -func (a ListDashboardsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListDashboardsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "order": types.StringType, @@ -3980,9 +7603,56 @@ func (a ListQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListQueriesLegacyRequest in the Terraform plugin framework type -// system. -func (a ListQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQueriesLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQueriesLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "order": types.StringType, @@ -4017,9 +7687,56 @@ func (a ListQueriesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListQueriesRequest in the Terraform plugin framework type -// system. -func (a ListQueriesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQueriesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQueriesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQueriesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQueriesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQueriesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQueriesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQueriesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQueriesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_size": types.Int64Type, @@ -4056,15 +7773,62 @@ func (a ListQueriesResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListQueriesResponse in the Terraform plugin framework type -// system. -func (a ListQueriesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQueriesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQueriesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQueriesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQueriesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQueriesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQueriesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQueriesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQueriesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_next_page": types.BoolType, "next_page_token": types.StringType, "res": basetypes.ListType{ - ElemType: QueryInfo{}.ToObjectType(ctx), + ElemType: QueryInfo{}.Type(ctx), }, }, } @@ -4106,13 +7870,60 @@ func (a ListQueryHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ListQueryHistoryRequest in the Terraform plugin framework type -// system. -func (a ListQueryHistoryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQueryHistoryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQueryHistoryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "filter_by": basetypes.ListType{ - ElemType: QueryFilter{}.ToObjectType(ctx), + ElemType: QueryFilter{}.Type(ctx), }, "include_metrics": types.BoolType, "max_results": types.Int64Type, @@ -4146,14 +7957,61 @@ func (a ListQueryObjectsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of ListQueryObjectsResponse in the Terraform plugin framework type -// system. -func (a ListQueryObjectsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQueryObjectsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: ListQueryObjectsResponseQuery{}.ToObjectType(ctx), + ElemType: ListQueryObjectsResponseQuery{}.Type(ctx), }, }, } @@ -4216,9 +8074,56 @@ func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of ListQueryObjectsResponseQuery in the Terraform plugin framework type -// system. -func (a ListQueryObjectsResponseQuery) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListQueryObjectsResponseQuery{} + +// Equal implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListQueryObjectsResponseQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -4231,7 +8136,7 @@ func (a ListQueryObjectsResponseQuery) ToObjectType(ctx context.Context) types.O "lifecycle_state": types.StringType, "owner_user_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToObjectType(ctx), + ElemType: QueryParameter{}.Type(ctx), }, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -4275,16 +8180,63 @@ func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ListResponse in the Terraform plugin framework type -// system. -func (a ListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, "results": basetypes.ListType{ - ElemType: Dashboard{}.ToObjectType(ctx), + ElemType: Dashboard{}.Type(ctx), }, }, } @@ -4316,9 +8268,56 @@ func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListVisualizationsForQueryRequest in the Terraform plugin framework type -// system. -func (a ListVisualizationsForQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListVisualizationsForQueryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -4353,14 +8352,61 @@ func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of ListVisualizationsForQueryResponse in the Terraform plugin framework type -// system. -func (a ListVisualizationsForQueryResponse) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListVisualizationsForQueryResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListVisualizationsForQueryResponse) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "results": basetypes.ListType{ - ElemType: Visualization{}.ToObjectType(ctx), + ElemType: Visualization{}.Type(ctx), }, }, } @@ -4390,9 +8436,56 @@ func (a ListWarehousesRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListWarehousesRequest in the Terraform plugin framework type -// system. -func (a ListWarehousesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListWarehousesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListWarehousesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "run_as_user_id": types.Int64Type, @@ -4424,13 +8517,60 @@ func (a ListWarehousesResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of ListWarehousesResponse in the Terraform plugin framework type -// system. -func (a ListWarehousesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListWarehousesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListWarehousesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouses": basetypes.ListType{ - ElemType: EndpointInfo{}.ToObjectType(ctx), + ElemType: EndpointInfo{}.Type(ctx), }, }, } @@ -4463,9 +8603,56 @@ func (a MultiValuesOptions) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of MultiValuesOptions in the Terraform plugin framework type -// system. -func (a MultiValuesOptions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MultiValuesOptions{} + +// Equal implements basetypes.ObjectValuable. +func (o MultiValuesOptions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MultiValuesOptions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MultiValuesOptions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MultiValuesOptions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MultiValuesOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MultiValuesOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MultiValuesOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "prefix": types.StringType, @@ -4496,9 +8683,56 @@ func (a NumericValue) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of NumericValue in the Terraform plugin framework type -// system. -func (a NumericValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = NumericValue{} + +// Equal implements basetypes.ObjectValuable. +func (o NumericValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o NumericValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o NumericValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o NumericValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o NumericValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o NumericValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o NumericValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.Float64Type, @@ -4533,9 +8767,56 @@ func (a OdbcParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of OdbcParams in the Terraform plugin framework type -// system. -func (a OdbcParams) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = OdbcParams{} + +// Equal implements basetypes.ObjectValuable. +func (o OdbcParams) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o OdbcParams) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o OdbcParams) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o OdbcParams) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o OdbcParams) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o OdbcParams) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o OdbcParams) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "hostname": types.StringType, @@ -4562,7 +8843,7 @@ type Parameter struct { // The text displayed in a parameter picking widget. Title types.String `tfsdk:"title" tf:"optional"` // Parameters can have several different types. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` // The default value for this parameter. Value any `tfsdk:"value" tf:"optional"` } @@ -4586,14 +8867,61 @@ func (a Parameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of Parameter in the Terraform plugin framework type -// system. -func (a Parameter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Parameter{} + +// Equal implements basetypes.ObjectValuable. +func (o Parameter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Parameter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Parameter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Parameter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Parameter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Parameter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Parameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enumOptions": types.StringType, "multiValuesOptions": basetypes.ListType{ - ElemType: MultiValuesOptions{}.ToObjectType(ctx), + ElemType: MultiValuesOptions{}.Type(ctx), }, "name": types.StringType, "queryId": types.StringType, @@ -4663,9 +8991,56 @@ func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of Query in the Terraform plugin framework type -// system. -func (a Query) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Query{} + +// Equal implements basetypes.ObjectValuable. +func (o Query) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Query) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Query) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Query) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Query) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Query) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Query) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -4678,7 +9053,7 @@ func (a Query) ToObjectType(ctx context.Context) types.ObjectType { "lifecycle_state": types.StringType, "owner_user_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToObjectType(ctx), + ElemType: QueryParameter{}.Type(ctx), }, "parent_path": types.StringType, "query_text": types.StringType, @@ -4722,13 +9097,60 @@ func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of QueryBackedValue in the Terraform plugin framework type -// system. -func (a QueryBackedValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryBackedValue{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryBackedValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryBackedValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryBackedValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryBackedValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryBackedValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryBackedValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryBackedValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "multi_values_options": basetypes.ListType{ - ElemType: MultiValuesOptions{}.ToObjectType(ctx), + ElemType: MultiValuesOptions{}.Type(ctx), }, "query_id": types.StringType, "values": basetypes.ListType{ @@ -4785,9 +9207,56 @@ func (a QueryEditContent) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of QueryEditContent in the Terraform plugin framework type -// system. -func (a QueryEditContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryEditContent{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryEditContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryEditContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryEditContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryEditContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryEditContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryEditContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryEditContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_source_id": types.StringType, @@ -4841,13 +9310,60 @@ func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of QueryFilter in the Terraform plugin framework type -// system. -func (a QueryFilter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryFilter{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryFilter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryFilter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryFilter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryFilter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_start_time_range": basetypes.ListType{ - ElemType: TimeRange{}.ToObjectType(ctx), + ElemType: TimeRange{}.Type(ctx), }, "statement_ids": basetypes.ListType{ ElemType: types.StringType, @@ -4937,13 +9453,60 @@ func (a QueryInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of QueryInfo in the Terraform plugin framework type -// system. -func (a QueryInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "channel_used": basetypes.ListType{ - ElemType: ChannelInfo{}.ToObjectType(ctx), + ElemType: ChannelInfo{}.Type(ctx), }, "duration": types.Int64Type, "endpoint_id": types.StringType, @@ -4954,7 +9517,7 @@ func (a QueryInfo) ToObjectType(ctx context.Context) types.ObjectType { "is_final": types.BoolType, "lookup_key": types.StringType, "metrics": basetypes.ListType{ - ElemType: QueryMetrics{}.ToObjectType(ctx), + ElemType: QueryMetrics{}.Type(ctx), }, "plans_state": types.StringType, "query_end_time_ms": types.Int64Type, @@ -5002,16 +9565,63 @@ func (a QueryList) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of QueryList in the Terraform plugin framework type -// system. -func (a QueryList) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryList{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryList) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryList) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryList) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryList) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, "results": basetypes.ListType{ - ElemType: LegacyQuery{}.ToObjectType(ctx), + ElemType: LegacyQuery{}.Type(ctx), }, }, } @@ -5095,9 +9705,56 @@ func (a QueryMetrics) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of QueryMetrics in the Terraform plugin framework type -// system. -func (a QueryMetrics) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryMetrics{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryMetrics) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryMetrics) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryMetrics) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryMetrics) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryMetrics) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryMetrics) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryMetrics) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "compilation_time_ms": types.Int64Type, @@ -5158,15 +9815,62 @@ func (a QueryOptions) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of QueryOptions in the Terraform plugin framework type -// system. -func (a QueryOptions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryOptions{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryOptions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryOptions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryOptions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryOptions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "catalog": types.StringType, "moved_to_trash_at": types.StringType, "parameters": basetypes.ListType{ - ElemType: Parameter{}.ToObjectType(ctx), + ElemType: Parameter{}.Type(ctx), }, "schema": types.StringType, }, @@ -5219,29 +9923,76 @@ func (a QueryParameter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of QueryParameter in the Terraform plugin framework type -// system. -func (a QueryParameter) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryParameter{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryParameter) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryParameter) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryParameter) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryParameter) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryParameter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryParameter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryParameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "date_range_value": basetypes.ListType{ - ElemType: DateRangeValue{}.ToObjectType(ctx), + ElemType: DateRangeValue{}.Type(ctx), }, "date_value": basetypes.ListType{ - ElemType: DateValue{}.ToObjectType(ctx), + ElemType: DateValue{}.Type(ctx), }, "enum_value": basetypes.ListType{ - ElemType: EnumValue{}.ToObjectType(ctx), + ElemType: EnumValue{}.Type(ctx), }, "name": types.StringType, "numeric_value": basetypes.ListType{ - ElemType: NumericValue{}.ToObjectType(ctx), + ElemType: NumericValue{}.Type(ctx), }, "query_backed_value": basetypes.ListType{ - ElemType: QueryBackedValue{}.ToObjectType(ctx), + ElemType: QueryBackedValue{}.Type(ctx), }, "text_value": basetypes.ListType{ - ElemType: TextValue{}.ToObjectType(ctx), + ElemType: TextValue{}.Type(ctx), }, "title": types.StringType, }, @@ -5295,9 +10046,56 @@ func (a QueryPostContent) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of QueryPostContent in the Terraform plugin framework type -// system. -func (a QueryPostContent) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryPostContent{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryPostContent) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryPostContent) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryPostContent) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryPostContent) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryPostContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryPostContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryPostContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_source_id": types.StringType, @@ -5341,16 +10139,63 @@ func (a RepeatedEndpointConfPairs) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of RepeatedEndpointConfPairs in the Terraform plugin framework type -// system. -func (a RepeatedEndpointConfPairs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepeatedEndpointConfPairs{} + +// Equal implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepeatedEndpointConfPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "config_pair": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToObjectType(ctx), + ElemType: EndpointConfPair{}.Type(ctx), }, "configuration_pairs": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToObjectType(ctx), + ElemType: EndpointConfPair{}.Type(ctx), }, }, } @@ -5378,9 +10223,56 @@ func (a RestoreDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreDashboardRequest in the Terraform plugin framework type -// system. -func (a RestoreDashboardRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreDashboardRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, @@ -5410,9 +10302,56 @@ func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreQueriesLegacyRequest in the Terraform plugin framework type -// system. -func (a RestoreQueriesLegacyRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreQueriesLegacyRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreQueriesLegacyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_id": types.StringType, @@ -5440,9 +10379,56 @@ func (a RestoreResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of RestoreResponse in the Terraform plugin framework type -// system. -func (a RestoreResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RestoreResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RestoreResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RestoreResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RestoreResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RestoreResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RestoreResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RestoreResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RestoreResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5495,9 +10481,56 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of ResultData in the Terraform plugin framework type -// system. -func (a ResultData) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResultData{} + +// Equal implements basetypes.ObjectValuable. +func (o ResultData) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResultData) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResultData) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResultData) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResultData) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResultData) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResultData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "byte_count": types.Int64Type, @@ -5508,7 +10541,7 @@ func (a ResultData) ToObjectType(ctx context.Context) types.ObjectType { }, }, "external_links": basetypes.ListType{ - ElemType: ExternalLink{}.ToObjectType(ctx), + ElemType: ExternalLink{}.Type(ctx), }, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, @@ -5558,17 +10591,64 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ResultManifest in the Terraform plugin framework type -// system. -func (a ResultManifest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResultManifest{} + +// Equal implements basetypes.ObjectValuable. +func (o ResultManifest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResultManifest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResultManifest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResultManifest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResultManifest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResultManifest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "chunks": basetypes.ListType{ - ElemType: BaseChunkInfo{}.ToObjectType(ctx), + ElemType: BaseChunkInfo{}.Type(ctx), }, "format": types.StringType, "schema": basetypes.ListType{ - ElemType: ResultSchema{}.ToObjectType(ctx), + ElemType: ResultSchema{}.Type(ctx), }, "total_byte_count": types.Int64Type, "total_chunk_count": types.Int64Type, @@ -5604,14 +10684,61 @@ func (a ResultSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ResultSchema in the Terraform plugin framework type -// system. -func (a ResultSchema) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResultSchema{} + +// Equal implements basetypes.ObjectValuable. +func (o ResultSchema) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResultSchema) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResultSchema) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResultSchema) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResultSchema) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResultSchema) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResultSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.ToObjectType(ctx), + ElemType: ColumnInfo{}.Type(ctx), }, }, } @@ -5640,9 +10767,56 @@ func (a ServiceError) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of ServiceError in the Terraform plugin framework type -// system. -func (a ServiceError) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ServiceError{} + +// Equal implements basetypes.ObjectValuable. +func (o ServiceError) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ServiceError) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ServiceError) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ServiceError) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ServiceError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ServiceError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ServiceError) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error_code": types.StringType, @@ -5680,13 +10854,60 @@ func (a SetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of SetRequest in the Terraform plugin framework type -// system. -func (a SetRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SetRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.ToObjectType(ctx), + ElemType: AccessControl{}.Type(ctx), }, "objectId": types.StringType, "objectType": types.StringType, @@ -5721,13 +10942,60 @@ func (a SetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of SetResponse in the Terraform plugin framework type -// system. -func (a SetResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.ToObjectType(ctx), + ElemType: AccessControl{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -5787,31 +11055,78 @@ func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes(ctx context.Con } } -// ToObjectType returns the representation of SetWorkspaceWarehouseConfigRequest in the Terraform plugin framework type -// system. -func (a SetWorkspaceWarehouseConfigRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetWorkspaceWarehouseConfigRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ - ElemType: Channel{}.ToObjectType(ctx), + ElemType: Channel{}.Type(ctx), }, "config_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), }, "data_access_config": basetypes.ListType{ - ElemType: EndpointConfPair{}.ToObjectType(ctx), + ElemType: EndpointConfPair{}.Type(ctx), }, "enabled_warehouse_types": basetypes.ListType{ - ElemType: WarehouseTypePair{}.ToObjectType(ctx), + ElemType: WarehouseTypePair{}.Type(ctx), }, "global_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), }, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, "security_policy": types.StringType, "sql_configuration_parameters": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.ToObjectType(ctx), + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), }, }, } @@ -5837,9 +11152,56 @@ func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of SetWorkspaceWarehouseConfigResponse in the Terraform plugin framework type -// system. -func (a SetWorkspaceWarehouseConfigResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SetWorkspaceWarehouseConfigResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5868,9 +11230,56 @@ func (a StartRequest) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of StartRequest in the Terraform plugin framework type -// system. -func (a StartRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o StartRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -5898,9 +11307,56 @@ func (a StartWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of StartWarehouseResponse in the Terraform plugin framework type -// system. -func (a StartWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StartWarehouseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StartWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -5916,7 +11372,7 @@ type StatementParameterListItem struct { // reference. // // [Data types]: https://docs.databricks.com/sql/language-manual/functions/cast.html - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` // The value to substitute, represented as a string. If omitted, the value // is interpreted as NULL. Value types.String `tfsdk:"value" tf:"optional"` @@ -5939,9 +11395,56 @@ func (a StatementParameterListItem) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of StatementParameterListItem in the Terraform plugin framework type -// system. -func (a StatementParameterListItem) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StatementParameterListItem{} + +// Equal implements basetypes.ObjectValuable. +func (o StatementParameterListItem) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StatementParameterListItem) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StatementParameterListItem) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StatementParameterListItem) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StatementParameterListItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StatementParameterListItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StatementParameterListItem) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -5985,20 +11488,67 @@ func (a StatementResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of StatementResponse in the Terraform plugin framework type -// system. -func (a StatementResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StatementResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o StatementResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StatementResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StatementResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StatementResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StatementResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StatementResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StatementResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "manifest": basetypes.ListType{ - ElemType: ResultManifest{}.ToObjectType(ctx), + ElemType: ResultManifest{}.Type(ctx), }, "result": basetypes.ListType{ - ElemType: ResultData{}.ToObjectType(ctx), + ElemType: ResultData{}.Type(ctx), }, "statement_id": types.StringType, "status": basetypes.ListType{ - ElemType: StatementStatus{}.ToObjectType(ctx), + ElemType: StatementStatus{}.Type(ctx), }, }, } @@ -6037,13 +11587,60 @@ func (a StatementStatus) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of StatementStatus in the Terraform plugin framework type -// system. -func (a StatementStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StatementStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o StatementStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StatementStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StatementStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StatementStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StatementStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StatementStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StatementStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "error": basetypes.ListType{ - ElemType: ServiceError{}.ToObjectType(ctx), + ElemType: ServiceError{}.Type(ctx), }, "state": types.StringType, }, @@ -6073,10 +11670,57 @@ func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of StopRequest in the Terraform plugin framework type -// system. -func (a StopRequest) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StopRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o StopRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StopRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StopRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StopRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StopRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StopRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StopRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, }, @@ -6103,9 +11747,56 @@ func (a StopWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of StopWarehouseResponse in the Terraform plugin framework type -// system. -func (a StopWarehouseResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = StopWarehouseResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o StopWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6132,9 +11823,56 @@ func (a Success) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of Success in the Terraform plugin framework type -// system. -func (a Success) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Success{} + +// Equal implements basetypes.ObjectValuable. +func (o Success) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Success) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Success) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Success) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Success) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Success) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Success) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, @@ -6149,7 +11887,7 @@ type TerminationReason struct { // cluster was terminated Parameters types.Map `tfsdk:"parameters" tf:"optional"` // type of the termination - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *TerminationReason) SyncEffectiveFieldsDuringCreateOrUpdate(plan TerminationReason) { @@ -6171,9 +11909,56 @@ func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of TerminationReason in the Terraform plugin framework type -// system. -func (a TerminationReason) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TerminationReason{} + +// Equal implements basetypes.ObjectValuable. +func (o TerminationReason) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TerminationReason) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TerminationReason) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TerminationReason) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TerminationReason) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TerminationReason) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TerminationReason) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "code": types.StringType, @@ -6206,9 +11991,56 @@ func (a TextValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of TextValue in the Terraform plugin framework type -// system. -func (a TextValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TextValue{} + +// Equal implements basetypes.ObjectValuable. +func (o TextValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TextValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TextValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TextValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TextValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TextValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TextValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "value": types.StringType, @@ -6240,9 +12072,56 @@ func (a TimeRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of TimeRange in the Terraform plugin framework type -// system. -func (a TimeRange) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TimeRange{} + +// Equal implements basetypes.ObjectValuable. +func (o TimeRange) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TimeRange) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TimeRange) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TimeRange) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TimeRange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TimeRange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TimeRange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "end_time_ms": types.Int64Type, @@ -6273,9 +12152,56 @@ func (a TransferOwnershipObjectId) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of TransferOwnershipObjectId in the Terraform plugin framework type -// system. -func (a TransferOwnershipObjectId) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TransferOwnershipObjectId{} + +// Equal implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TransferOwnershipObjectId) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "new_owner": types.StringType, @@ -6312,14 +12238,61 @@ func (a TransferOwnershipRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of TransferOwnershipRequest in the Terraform plugin framework type -// system. -func (a TransferOwnershipRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TransferOwnershipRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TransferOwnershipRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "new_owner": types.StringType, "objectId": basetypes.ListType{ - ElemType: TransferOwnershipObjectId{}.ToObjectType(ctx), + ElemType: TransferOwnershipObjectId{}.Type(ctx), }, "objectType": types.StringType, }, @@ -6348,9 +12321,56 @@ func (a TrashAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of TrashAlertRequest in the Terraform plugin framework type -// system. -func (a TrashAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TrashAlertRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TrashAlertRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TrashAlertRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TrashAlertRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TrashAlertRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TrashAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TrashAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TrashAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -6380,9 +12400,56 @@ func (a TrashQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of TrashQueryRequest in the Terraform plugin framework type -// system. -func (a TrashQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = TrashQueryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o TrashQueryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o TrashQueryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o TrashQueryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o TrashQueryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o TrashQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o TrashQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o TrashQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, @@ -6420,13 +12487,60 @@ func (a UpdateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of UpdateAlertRequest in the Terraform plugin framework type -// system. -func (a UpdateAlertRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAlertRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "alert": basetypes.ListType{ - ElemType: UpdateAlertRequestAlert{}.ToObjectType(ctx), + ElemType: UpdateAlertRequestAlert{}.Type(ctx), }, "id": types.StringType, "update_mask": types.StringType, @@ -6482,13 +12596,60 @@ func (a UpdateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of UpdateAlertRequestAlert in the Terraform plugin framework type -// system. -func (a UpdateAlertRequestAlert) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateAlertRequestAlert{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateAlertRequestAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "condition": basetypes.ListType{ - ElemType: AlertCondition{}.ToObjectType(ctx), + ElemType: AlertCondition{}.Type(ctx), }, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -6531,14 +12692,61 @@ func (a UpdateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of UpdateQueryRequest in the Terraform plugin framework type -// system. -func (a UpdateQueryRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateQueryRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "query": basetypes.ListType{ - ElemType: UpdateQueryRequestQuery{}.ToObjectType(ctx), + ElemType: UpdateQueryRequestQuery{}.Type(ctx), }, "update_mask": types.StringType, }, @@ -6592,9 +12800,56 @@ func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of UpdateQueryRequestQuery in the Terraform plugin framework type -// system. -func (a UpdateQueryRequestQuery) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateQueryRequestQuery{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateQueryRequestQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_auto_limit": types.BoolType, @@ -6603,7 +12858,7 @@ func (a UpdateQueryRequestQuery) ToObjectType(ctx context.Context) types.ObjectT "display_name": types.StringType, "owner_user_name": types.StringType, "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.ToObjectType(ctx), + ElemType: QueryParameter{}.Type(ctx), }, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -6636,9 +12891,56 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateResponse in the Terraform plugin framework type -// system. -func (a UpdateResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -6674,15 +12976,62 @@ func (a UpdateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of UpdateVisualizationRequest in the Terraform plugin framework type -// system. -func (a UpdateVisualizationRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateVisualizationRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "update_mask": types.StringType, "visualization": basetypes.ListType{ - ElemType: UpdateVisualizationRequestVisualization{}.ToObjectType(ctx), + ElemType: UpdateVisualizationRequestVisualization{}.Type(ctx), }, }, } @@ -6700,7 +13049,7 @@ type UpdateVisualizationRequestVisualization struct { // visualization query plan directly. SerializedQueryPlan types.String `tfsdk:"serialized_query_plan" tf:"optional"` // The type of visualization: counter, table, funnel, and so on. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` } func (newState *UpdateVisualizationRequestVisualization) SyncEffectiveFieldsDuringCreateOrUpdate(plan UpdateVisualizationRequestVisualization) { @@ -6720,9 +13069,56 @@ func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateVisualizationRequestVisualization in the Terraform plugin framework type -// system. -func (a UpdateVisualizationRequestVisualization) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateVisualizationRequestVisualization{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateVisualizationRequestVisualization) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "display_name": types.StringType, @@ -6758,9 +13154,56 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// ToObjectType returns the representation of User in the Terraform plugin framework type -// system. -func (a User) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = User{} + +// Equal implements basetypes.ObjectValuable. +func (o User) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o User) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o User) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o User) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o User) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o User) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o User) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "email": types.StringType, @@ -6788,7 +13231,7 @@ type Visualization struct { // visualization query plan directly. SerializedQueryPlan types.String `tfsdk:"serialized_query_plan" tf:"optional"` // The type of visualization: counter, table, funnel, and so on. - Type types.String `tfsdk:"type" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:"optional"` // The timestamp indicating when the visualization was updated. UpdateTime types.String `tfsdk:"update_time" tf:"optional"` } @@ -6810,9 +13253,56 @@ func (a Visualization) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of Visualization in the Terraform plugin framework type -// system. -func (a Visualization) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Visualization{} + +// Equal implements basetypes.ObjectValuable. +func (o Visualization) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Visualization) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Visualization) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Visualization) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Visualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Visualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Visualization) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "create_time": types.StringType, @@ -6855,9 +13345,56 @@ func (a WarehouseAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of WarehouseAccessControlRequest in the Terraform plugin framework type -// system. -func (a WarehouseAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehouseAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehouseAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -6900,13 +13437,60 @@ func (a WarehouseAccessControlResponse) GetComplexFieldTypes(ctx context.Context } } -// ToObjectType returns the representation of WarehouseAccessControlResponse in the Terraform plugin framework type -// system. -func (a WarehouseAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehouseAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehouseAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: WarehousePermission{}.ToObjectType(ctx), + ElemType: WarehousePermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -6943,9 +13527,56 @@ func (a WarehousePermission) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of WarehousePermission in the Terraform plugin framework type -// system. -func (a WarehousePermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehousePermission{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehousePermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehousePermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehousePermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehousePermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehousePermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehousePermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehousePermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -6984,13 +13615,60 @@ func (a WarehousePermissions) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of WarehousePermissions in the Terraform plugin framework type -// system. -func (a WarehousePermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehousePermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehousePermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehousePermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehousePermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehousePermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehousePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehousePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehousePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WarehouseAccessControlResponse{}.ToObjectType(ctx), + ElemType: WarehouseAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -7021,9 +13699,56 @@ func (a WarehousePermissionsDescription) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of WarehousePermissionsDescription in the Terraform plugin framework type -// system. -func (a WarehousePermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehousePermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehousePermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -7057,13 +13782,60 @@ func (a WarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of WarehousePermissionsRequest in the Terraform plugin framework type -// system. -func (a WarehousePermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehousePermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehousePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WarehouseAccessControlRequest{}.ToObjectType(ctx), + ElemType: WarehouseAccessControlRequest{}.Type(ctx), }, "warehouse_id": types.StringType, }, @@ -7095,9 +13867,56 @@ func (a WarehouseTypePair) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of WarehouseTypePair in the Terraform plugin framework type -// system. -func (a WarehouseTypePair) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WarehouseTypePair{} + +// Equal implements basetypes.ObjectValuable. +func (o WarehouseTypePair) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WarehouseTypePair) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WarehouseTypePair) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WarehouseTypePair) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WarehouseTypePair) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WarehouseTypePair) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WarehouseTypePair) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, @@ -7141,17 +13960,64 @@ func (a Widget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToObjectType returns the representation of Widget in the Terraform plugin framework type -// system. -func (a Widget) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Widget{} + +// Equal implements basetypes.ObjectValuable. +func (o Widget) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Widget) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Widget) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Widget) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Widget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Widget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Widget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, "options": basetypes.ListType{ - ElemType: WidgetOptions{}.ToObjectType(ctx), + ElemType: WidgetOptions{}.Type(ctx), }, "visualization": basetypes.ListType{ - ElemType: LegacyVisualization{}.ToObjectType(ctx), + ElemType: LegacyVisualization{}.Type(ctx), }, "width": types.Int64Type, }, @@ -7197,9 +14063,56 @@ func (a WidgetOptions) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// ToObjectType returns the representation of WidgetOptions in the Terraform plugin framework type -// system. -func (a WidgetOptions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WidgetOptions{} + +// Equal implements basetypes.ObjectValuable. +func (o WidgetOptions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WidgetOptions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WidgetOptions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WidgetOptions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WidgetOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WidgetOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WidgetOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.StringType, @@ -7207,7 +14120,7 @@ func (a WidgetOptions) ToObjectType(ctx context.Context) types.ObjectType { "isHidden": types.BoolType, "parameterMappings": types.ObjectType{}, "position": basetypes.ListType{ - ElemType: WidgetPosition{}.ToObjectType(ctx), + ElemType: WidgetPosition{}.Type(ctx), }, "title": types.StringType, "updated_at": types.StringType, @@ -7247,9 +14160,56 @@ func (a WidgetPosition) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of WidgetPosition in the Terraform plugin framework type -// system. -func (a WidgetPosition) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WidgetPosition{} + +// Equal implements basetypes.ObjectValuable. +func (o WidgetPosition) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WidgetPosition) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WidgetPosition) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WidgetPosition) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WidgetPosition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WidgetPosition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WidgetPosition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autoHeight": types.BoolType, @@ -7260,3 +14220,80 @@ func (a WidgetPosition) ToObjectType(ctx context.Context) types.ObjectType { }, } } + +// State that alert evaluates to when query result is empty. + +// The name of the base data type. This doesn't include details for complex +// types such as STRUCT, MAP or ARRAY. + +// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, +// you must set to `PRO` and also set the field `enable_serverless_compute` to +// `true`. + +// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, +// you must set to `PRO` and also set the field `enable_serverless_compute` to +// `true`. + +// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, +// you must set to `PRO` and also set the field `enable_serverless_compute` to +// `true`. + +// When `wait_timeout > 0s`, the call will block up to the specified time. If +// the statement execution doesn't finish within this time, `on_wait_timeout` +// determines whether the execution should continue or be canceled. When set to +// `CONTINUE`, the statement execution continues asynchronously and the call +// returns a statement ID which can be used for polling with +// :method:statementexecution/getStatement. When set to `CANCEL`, the statement +// execution is canceled and the call returns with a `CANCELED` state. + +// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, +// you must set to `PRO` and also set the field `enable_serverless_compute` to +// `true`. + +// Security policy for warehouses + +// State of the alert. Possible values are: `unknown` (yet to be evaluated), +// `triggered` (evaluated and fulfilled trigger conditions), or `ok` (evaluated +// and did not fulfill trigger conditions). + +// A singular noun object type. + +// Always a plural of the object type. + +// The singular form of the type of object which can be owned. + +// Parameters can have several different types. + +// * `CAN_VIEW`: Can view the query * `CAN_RUN`: Can run the query * `CAN_EDIT`: +// Can edit the query * `CAN_MANAGE`: Can manage the query + +// Possible Reasons for which we have not saved plans in the database + +// Statuses which are also used by OperationStatus in runtime + +// Sets the **Run as** role for the object. Must be set to one of `"viewer"` +// (signifying "run as viewer" behavior) or `"owner"` (signifying "run as owner" +// behavior) + +// Security policy for warehouses + +// Configurations whether the warehouse should use spot instances. + +// State of the warehouse + +// Statement execution state: - `PENDING`: waiting for warehouse - `RUNNING`: +// running - `SUCCEEDED`: execution was successful, result data available for +// fetch - `FAILED`: execution failed; reason for failure described in +// accomanying error message - `CANCELED`: user canceled; can come from explicit +// cancel call, or timeout with `on_wait_timeout=CANCEL` - `CLOSED`: execution +// successful, and statement closed; result no longer available for fetch + +// Health status of the warehouse. + +// status code indicating why the cluster was terminated + +// type of the termination + +// Permission level + +// Warehouse type: `PRO` or `CLASSIC`. diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index f530aca0c6..27bbb022bf 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -12,11 +12,15 @@ package vectorsearch_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type ColumnInfo struct { @@ -41,9 +45,56 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of ColumnInfo in the Terraform plugin framework type -// system. -func (a ColumnInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ColumnInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ColumnInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ColumnInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ColumnInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ColumnInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ColumnInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ColumnInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ColumnInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, @@ -75,9 +126,56 @@ func (a CreateEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateEndpoint in the Terraform plugin framework type -// system. -func (a CreateEndpoint) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateEndpoint{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateEndpoint) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateEndpoint) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateEndpoint) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateEndpoint) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_type": types.StringType, @@ -129,16 +227,63 @@ func (a CreateVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of CreateVectorIndexRequest in the Terraform plugin framework type -// system. -func (a CreateVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateVectorIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "delta_sync_index_spec": basetypes.ListType{ - ElemType: DeltaSyncVectorIndexSpecRequest{}.ToObjectType(ctx), + ElemType: DeltaSyncVectorIndexSpecRequest{}.Type(ctx), }, "direct_access_index_spec": basetypes.ListType{ - ElemType: DirectAccessVectorIndexSpec{}.ToObjectType(ctx), + ElemType: DirectAccessVectorIndexSpec{}.Type(ctx), }, "endpoint_name": types.StringType, "index_type": types.StringType, @@ -171,13 +316,60 @@ func (a CreateVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of CreateVectorIndexResponse in the Terraform plugin framework type -// system. -func (a CreateVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateVectorIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "vector_index": basetypes.ListType{ - ElemType: VectorIndex{}.ToObjectType(ctx), + ElemType: VectorIndex{}.Type(ctx), }, }, } @@ -210,9 +402,56 @@ func (a DeleteDataResult) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of DeleteDataResult in the Terraform plugin framework type -// system. -func (a DeleteDataResult) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDataResult{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDataResult) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDataResult) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDataResult) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDataResult) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDataResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDataResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDataResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "failed_primary_keys": basetypes.ListType{ @@ -251,9 +490,56 @@ func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of DeleteDataVectorIndexRequest in the Terraform plugin framework type -// system. -func (a DeleteDataVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDataVectorIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -291,13 +577,60 @@ func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of DeleteDataVectorIndexResponse in the Terraform plugin framework type -// system. -func (a DeleteDataVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteDataVectorIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteDataVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "result": basetypes.ListType{ - ElemType: DeleteDataResult{}.ToObjectType(ctx), + ElemType: DeleteDataResult{}.Type(ctx), }, "status": types.StringType, }, @@ -327,9 +660,56 @@ func (a DeleteEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteEndpointRequest in the Terraform plugin framework type -// system. -func (a DeleteEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -357,9 +737,56 @@ func (a DeleteEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteEndpointResponse in the Terraform plugin framework type -// system. -func (a DeleteEndpointResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteEndpointResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -388,9 +815,56 @@ func (a DeleteIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteIndexRequest in the Terraform plugin framework type -// system. -func (a DeleteIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -418,9 +892,56 @@ func (a DeleteIndexResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteIndexResponse in the Terraform plugin framework type -// system. -func (a DeleteIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -475,19 +996,66 @@ func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of DeltaSyncVectorIndexSpecRequest in the Terraform plugin framework type -// system. -func (a DeltaSyncVectorIndexSpecRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeltaSyncVectorIndexSpecRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns_to_sync": basetypes.ListType{ ElemType: types.StringType, }, "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.ToObjectType(ctx), + ElemType: EmbeddingSourceColumn{}.Type(ctx), }, "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.ToObjectType(ctx), + ElemType: EmbeddingVectorColumn{}.Type(ctx), }, "embedding_writeback_table": types.StringType, "pipeline_type": types.StringType, @@ -539,16 +1107,63 @@ func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes(ctx context.Conte } } -// ToObjectType returns the representation of DeltaSyncVectorIndexSpecResponse in the Terraform plugin framework type -// system. -func (a DeltaSyncVectorIndexSpecResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeltaSyncVectorIndexSpecResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeltaSyncVectorIndexSpecResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.ToObjectType(ctx), + ElemType: EmbeddingSourceColumn{}.Type(ctx), }, "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.ToObjectType(ctx), + ElemType: EmbeddingVectorColumn{}.Type(ctx), }, "embedding_writeback_table": types.StringType, "pipeline_id": types.StringType, @@ -592,16 +1207,63 @@ func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes(ctx context.Context) m } } -// ToObjectType returns the representation of DirectAccessVectorIndexSpec in the Terraform plugin framework type -// system. -func (a DirectAccessVectorIndexSpec) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DirectAccessVectorIndexSpec{} + +// Equal implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DirectAccessVectorIndexSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.ToObjectType(ctx), + ElemType: EmbeddingSourceColumn{}.Type(ctx), }, "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.ToObjectType(ctx), + ElemType: EmbeddingVectorColumn{}.Type(ctx), }, "schema_json": types.StringType, }, @@ -632,9 +1294,56 @@ func (a EmbeddingSourceColumn) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of EmbeddingSourceColumn in the Terraform plugin framework type -// system. -func (a EmbeddingSourceColumn) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EmbeddingSourceColumn{} + +// Equal implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EmbeddingSourceColumn) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_model_endpoint_name": types.StringType, @@ -667,9 +1376,56 @@ func (a EmbeddingVectorColumn) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of EmbeddingVectorColumn in the Terraform plugin framework type -// system. -func (a EmbeddingVectorColumn) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EmbeddingVectorColumn{} + +// Equal implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EmbeddingVectorColumn) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "embedding_dimension": types.Int64Type, @@ -718,15 +1474,62 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of EndpointInfo in the Terraform plugin framework type -// system. -func (a EndpointInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creation_timestamp": types.Int64Type, "creator": types.StringType, "endpoint_status": basetypes.ListType{ - ElemType: EndpointStatus{}.ToObjectType(ctx), + ElemType: EndpointStatus{}.Type(ctx), }, "endpoint_type": types.StringType, "id": types.StringType, @@ -763,10 +1566,57 @@ func (a EndpointStatus) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of EndpointStatus in the Terraform plugin framework type -// system. -func (a EndpointStatus) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = EndpointStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o EndpointStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o EndpointStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o EndpointStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o EndpointStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o EndpointStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o EndpointStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o EndpointStatus) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "message": types.StringType, "state": types.StringType, @@ -797,9 +1647,56 @@ func (a GetEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetEndpointRequest in the Terraform plugin framework type -// system. -func (a GetEndpointRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetEndpointRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetEndpointRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetEndpointRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetEndpointRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetEndpointRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -830,9 +1727,56 @@ func (a GetIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetIndexRequest in the Terraform plugin framework type -// system. -func (a GetIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -867,13 +1811,60 @@ func (a ListEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of ListEndpointResponse in the Terraform plugin framework type -// system. -func (a ListEndpointResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListEndpointResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListEndpointResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListEndpointResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListEndpointResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListEndpointResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListEndpointResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListEndpointResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoints": basetypes.ListType{ - ElemType: EndpointInfo{}.ToObjectType(ctx), + ElemType: EndpointInfo{}.Type(ctx), }, "next_page_token": types.StringType, }, @@ -903,9 +1894,56 @@ func (a ListEndpointsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListEndpointsRequest in the Terraform plugin framework type -// system. -func (a ListEndpointsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListEndpointsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListEndpointsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "page_token": types.StringType, @@ -938,9 +1976,56 @@ func (a ListIndexesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListIndexesRequest in the Terraform plugin framework type -// system. -func (a ListIndexesRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListIndexesRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListIndexesRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListIndexesRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListIndexesRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListIndexesRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListIndexesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListIndexesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListIndexesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -972,13 +2057,60 @@ func (a ListValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// ToObjectType returns the representation of ListValue in the Terraform plugin framework type -// system. -func (a ListValue) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListValue{} + +// Equal implements basetypes.ObjectValuable. +func (o ListValue) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListValue) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListValue) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListValue) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "values": basetypes.ListType{ - ElemType: Value{}.ToObjectType(ctx), + ElemType: Value{}.Type(ctx), }, }, } @@ -1011,14 +2143,61 @@ func (a ListVectorIndexesResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of ListVectorIndexesResponse in the Terraform plugin framework type -// system. -func (a ListVectorIndexesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListVectorIndexesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListVectorIndexesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "vector_indexes": basetypes.ListType{ - ElemType: MiniVectorIndex{}.ToObjectType(ctx), + ElemType: MiniVectorIndex{}.Type(ctx), }, }, } @@ -1051,14 +2230,61 @@ func (a MapStringValueEntry) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of MapStringValueEntry in the Terraform plugin framework type -// system. -func (a MapStringValueEntry) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MapStringValueEntry{} + +// Equal implements basetypes.ObjectValuable. +func (o MapStringValueEntry) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MapStringValueEntry) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MapStringValueEntry) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MapStringValueEntry) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MapStringValueEntry) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MapStringValueEntry) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MapStringValueEntry) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, "value": basetypes.ListType{ - ElemType: Value{}.ToObjectType(ctx), + ElemType: Value{}.Type(ctx), }, }, } @@ -1100,9 +2326,56 @@ func (a MiniVectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of MiniVectorIndex in the Terraform plugin framework type -// system. -func (a MiniVectorIndex) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MiniVectorIndex{} + +// Equal implements basetypes.ObjectValuable. +func (o MiniVectorIndex) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MiniVectorIndex) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MiniVectorIndex) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MiniVectorIndex) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MiniVectorIndex) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MiniVectorIndex) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MiniVectorIndex) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creator": types.StringType, @@ -1142,9 +2415,56 @@ func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// ToObjectType returns the representation of QueryVectorIndexNextPageRequest in the Terraform plugin framework type -// system. -func (a QueryVectorIndexNextPageRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryVectorIndexNextPageRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryVectorIndexNextPageRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "endpoint_name": types.StringType, @@ -1199,9 +2519,56 @@ func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of QueryVectorIndexRequest in the Terraform plugin framework type -// system. -func (a QueryVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryVectorIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns": basetypes.ListType{ @@ -1251,17 +2618,64 @@ func (a QueryVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// ToObjectType returns the representation of QueryVectorIndexResponse in the Terraform plugin framework type -// system. -func (a QueryVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = QueryVectorIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o QueryVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "manifest": basetypes.ListType{ - ElemType: ResultManifest{}.ToObjectType(ctx), + ElemType: ResultManifest{}.Type(ctx), }, "next_page_token": types.StringType, "result": basetypes.ListType{ - ElemType: ResultData{}.ToObjectType(ctx), + ElemType: ResultData{}.Type(ctx), }, }, } @@ -1294,9 +2708,56 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// ToObjectType returns the representation of ResultData in the Terraform plugin framework type -// system. -func (a ResultData) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResultData{} + +// Equal implements basetypes.ObjectValuable. +func (o ResultData) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResultData) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResultData) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResultData) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResultData) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResultData) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResultData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data_array": basetypes.ListType{ @@ -1336,14 +2797,61 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of ResultManifest in the Terraform plugin framework type -// system. -func (a ResultManifest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ResultManifest{} + +// Equal implements basetypes.ObjectValuable. +func (o ResultManifest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ResultManifest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ResultManifest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ResultManifest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ResultManifest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ResultManifest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.ToObjectType(ctx), + ElemType: ColumnInfo{}.Type(ctx), }, }, } @@ -1376,9 +2884,56 @@ func (a ScanVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of ScanVectorIndexRequest in the Terraform plugin framework type -// system. -func (a ScanVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ScanVectorIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ScanVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -1415,13 +2970,60 @@ func (a ScanVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ScanVectorIndexResponse in the Terraform plugin framework type -// system. -func (a ScanVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ScanVectorIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ScanVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "data": basetypes.ListType{ - ElemType: Struct{}.ToObjectType(ctx), + ElemType: Struct{}.Type(ctx), }, "last_primary_key": types.StringType, }, @@ -1452,13 +3054,60 @@ func (a Struct) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// ToObjectType returns the representation of Struct in the Terraform plugin framework type -// system. -func (a Struct) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Struct{} + +// Equal implements basetypes.ObjectValuable. +func (o Struct) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Struct) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Struct) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Struct) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Struct) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Struct) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Struct) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "fields": basetypes.ListType{ - ElemType: MapStringValueEntry{}.ToObjectType(ctx), + ElemType: MapStringValueEntry{}.Type(ctx), }, }, } @@ -1487,9 +3136,56 @@ func (a SyncIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of SyncIndexRequest in the Terraform plugin framework type -// system. -func (a SyncIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SyncIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o SyncIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SyncIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SyncIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SyncIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SyncIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SyncIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SyncIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -1517,9 +3213,56 @@ func (a SyncIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of SyncIndexResponse in the Terraform plugin framework type -// system. -func (a SyncIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SyncIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o SyncIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SyncIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SyncIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SyncIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SyncIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SyncIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SyncIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1552,9 +3295,56 @@ func (a UpsertDataResult) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of UpsertDataResult in the Terraform plugin framework type -// system. -func (a UpsertDataResult) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpsertDataResult{} + +// Equal implements basetypes.ObjectValuable. +func (o UpsertDataResult) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpsertDataResult) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpsertDataResult) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpsertDataResult) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpsertDataResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpsertDataResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpsertDataResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "failed_primary_keys": basetypes.ListType{ @@ -1591,9 +3381,56 @@ func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpsertDataVectorIndexRequest in the Terraform plugin framework type -// system. -func (a UpsertDataVectorIndexRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpsertDataVectorIndexRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_name": types.StringType, @@ -1629,13 +3466,60 @@ func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) } } -// ToObjectType returns the representation of UpsertDataVectorIndexResponse in the Terraform plugin framework type -// system. -func (a UpsertDataVectorIndexResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpsertDataVectorIndexResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpsertDataVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "result": basetypes.ListType{ - ElemType: UpsertDataResult{}.ToObjectType(ctx), + ElemType: UpsertDataResult{}.Type(ctx), }, "status": types.StringType, }, @@ -1676,20 +3560,67 @@ func (a Value) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// ToObjectType returns the representation of Value in the Terraform plugin framework type -// system. -func (a Value) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Value{} + +// Equal implements basetypes.ObjectValuable. +func (o Value) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Value) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Value) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Value) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Value) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Value) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Value) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bool_value": types.BoolType, "list_value": basetypes.ListType{ - ElemType: ListValue{}.ToObjectType(ctx), + ElemType: ListValue{}.Type(ctx), }, "null_value": types.StringType, "number_value": types.Float64Type, "string_value": types.StringType, "struct_value": basetypes.ListType{ - ElemType: Struct{}.ToObjectType(ctx), + ElemType: Struct{}.Type(ctx), }, }, } @@ -1741,24 +3672,71 @@ func (a VectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of VectorIndex in the Terraform plugin framework type -// system. -func (a VectorIndex) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = VectorIndex{} + +// Equal implements basetypes.ObjectValuable. +func (o VectorIndex) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o VectorIndex) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o VectorIndex) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o VectorIndex) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o VectorIndex) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o VectorIndex) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o VectorIndex) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "creator": types.StringType, "delta_sync_index_spec": basetypes.ListType{ - ElemType: DeltaSyncVectorIndexSpecResponse{}.ToObjectType(ctx), + ElemType: DeltaSyncVectorIndexSpecResponse{}.Type(ctx), }, "direct_access_index_spec": basetypes.ListType{ - ElemType: DirectAccessVectorIndexSpec{}.ToObjectType(ctx), + ElemType: DirectAccessVectorIndexSpec{}.Type(ctx), }, "endpoint_name": types.StringType, "index_type": types.StringType, "name": types.StringType, "primary_key": types.StringType, "status": basetypes.ListType{ - ElemType: VectorIndexStatus{}.ToObjectType(ctx), + ElemType: VectorIndexStatus{}.Type(ctx), }, }, } @@ -1792,9 +3770,56 @@ func (a VectorIndexStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of VectorIndexStatus in the Terraform plugin framework type -// system. -func (a VectorIndexStatus) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = VectorIndexStatus{} + +// Equal implements basetypes.ObjectValuable. +func (o VectorIndexStatus) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o VectorIndexStatus) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o VectorIndexStatus) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o VectorIndexStatus) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o VectorIndexStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o VectorIndexStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o VectorIndexStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "index_url": types.StringType, @@ -1804,3 +3829,28 @@ func (a VectorIndexStatus) ToObjectType(ctx context.Context) types.ObjectType { }, } } + +// Status of the delete operation. + +// Current state of the endpoint + +// Type of endpoint. + +// Pipeline execution mode. +// +// - `TRIGGERED`: If the pipeline uses the triggered execution mode, the system +// stops processing after successfully refreshing the source table in the +// pipeline once, ensuring the table is updated based on the data available when +// the update started. - `CONTINUOUS`: If the pipeline uses continuous +// execution, the pipeline processes new data as it arrives in the source table +// to keep vector index fresh. + +// Status of the upsert operation. + +// There are 2 types of Vector Search indexes: +// +// - `DELTA_SYNC`: An index that automatically syncs with a source Delta Table, +// automatically and incrementally updating the index as the underlying data in +// the Delta Table changes. - `DIRECT_ACCESS`: An index that supports direct +// read and write of vectors and metadata through our REST and SDK APIs. With +// this model, the user manages index updates. diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 0c676585ea..9ffbb4a846 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -12,11 +12,15 @@ package workspace_tf import ( "context" + "fmt" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" + "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AclItem struct { @@ -43,9 +47,56 @@ func (a AclItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// ToObjectType returns the representation of AclItem in the Terraform plugin framework type -// system. -func (a AclItem) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AclItem{} + +// Equal implements basetypes.ObjectValuable. +func (o AclItem) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AclItem) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AclItem) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AclItem) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AclItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AclItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AclItem) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission": types.StringType, @@ -79,9 +130,56 @@ func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// ToObjectType returns the representation of AzureKeyVaultSecretScopeMetadata in the Terraform plugin framework type -// system. -func (a AzureKeyVaultSecretScopeMetadata) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = AzureKeyVaultSecretScopeMetadata{} + +// Equal implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o AzureKeyVaultSecretScopeMetadata) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dns_name": types.StringType, @@ -129,9 +227,56 @@ func (a CreateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateCredentialsRequest in the Terraform plugin framework type -// system. -func (a CreateCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "git_provider": types.StringType, @@ -168,9 +313,56 @@ func (a CreateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateCredentialsResponse in the Terraform plugin framework type -// system. -func (a CreateCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -216,15 +408,62 @@ func (a CreateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of CreateRepoRequest in the Terraform plugin framework type -// system. -func (a CreateRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRepoRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRepoRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRepoRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRepoRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRepoRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToObjectType(ctx), + ElemType: SparseCheckout{}.Type(ctx), }, "url": types.StringType, }, @@ -268,9 +507,56 @@ func (a CreateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of CreateRepoResponse in the Terraform plugin framework type -// system. -func (a CreateRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateRepoResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateRepoResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateRepoResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateRepoResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateRepoResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, @@ -279,7 +565,7 @@ func (a CreateRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToObjectType(ctx), + ElemType: SparseCheckout{}.Type(ctx), }, "url": types.StringType, }, @@ -318,13 +604,60 @@ func (a CreateScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of CreateScope in the Terraform plugin framework type -// system. -func (a CreateScope) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateScope{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateScope) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateScope) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateScope) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateScope) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateScope) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateScope) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateScope) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "backend_azure_keyvault": basetypes.ListType{ - ElemType: AzureKeyVaultSecretScopeMetadata{}.ToObjectType(ctx), + ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx), }, "initial_manage_principal": types.StringType, "scope": types.StringType, @@ -353,9 +686,56 @@ func (a CreateScopeResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of CreateScopeResponse in the Terraform plugin framework type -// system. -func (a CreateScopeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CreateScopeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o CreateScopeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CreateScopeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CreateScopeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CreateScopeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CreateScopeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CreateScopeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CreateScopeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -388,9 +768,56 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of CredentialInfo in the Terraform plugin framework type -// system. -func (a CredentialInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = CredentialInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o CredentialInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o CredentialInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o CredentialInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o CredentialInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o CredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o CredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o CredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -427,9 +854,56 @@ func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Delete in the Terraform plugin framework type -// system. -func (a Delete) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Delete{} + +// Equal implements basetypes.ObjectValuable. +func (o Delete) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Delete) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Delete) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Delete) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Delete) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Delete) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Delete) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -462,9 +936,56 @@ func (a DeleteAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAcl in the Terraform plugin framework type -// system. -func (a DeleteAcl) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAcl{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAcl) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAcl) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAcl) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAcl) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAcl) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAcl) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAcl) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -493,9 +1014,56 @@ func (a DeleteAclResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteAclResponse in the Terraform plugin framework type -// system. -func (a DeleteAclResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteAclResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteAclResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteAclResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteAclResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteAclResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteAclResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteAclResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteAclResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -524,9 +1092,56 @@ func (a DeleteCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCredentialsRequest in the Terraform plugin framework type -// system. -func (a DeleteCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -554,9 +1169,56 @@ func (a DeleteCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteCredentialsResponse in the Terraform plugin framework type -// system. -func (a DeleteCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -585,9 +1247,56 @@ func (a DeleteRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRepoRequest in the Terraform plugin framework type -// system. -func (a DeleteRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRepoRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.Int64Type, @@ -615,9 +1324,56 @@ func (a DeleteRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteRepoResponse in the Terraform plugin framework type -// system. -func (a DeleteRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteRepoResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -643,9 +1399,56 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteResponse in the Terraform plugin framework type -// system. -func (a DeleteResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -673,10 +1476,57 @@ func (a DeleteScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteScope in the Terraform plugin framework type -// system. -func (a DeleteScope) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteScope{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteScope) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteScope) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteScope) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteScope) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteScope) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteScope) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteScope) Type(ctx context.Context) attr.Type { + return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scope": types.StringType, }, @@ -703,9 +1553,56 @@ func (a DeleteScopeResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteScopeResponse in the Terraform plugin framework type -// system. -func (a DeleteScopeResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteScopeResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteScopeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -735,9 +1632,56 @@ func (a DeleteSecret) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteSecret in the Terraform plugin framework type -// system. -func (a DeleteSecret) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteSecret{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteSecret) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteSecret) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteSecret) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteSecret) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteSecret) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -766,9 +1710,56 @@ func (a DeleteSecretResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of DeleteSecretResponse in the Terraform plugin framework type -// system. -func (a DeleteSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = DeleteSecretResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o DeleteSecretResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -813,9 +1804,56 @@ func (a ExportRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExportRequest in the Terraform plugin framework type -// system. -func (a ExportRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExportRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ExportRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExportRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExportRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExportRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExportRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExportRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExportRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "format": types.StringType, @@ -849,9 +1887,56 @@ func (a ExportResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of ExportResponse in the Terraform plugin framework type -// system. -func (a ExportResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ExportResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ExportResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ExportResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ExportResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ExportResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ExportResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ExportResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ExportResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -885,9 +1970,56 @@ func (a GetAclRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetAclRequest in the Terraform plugin framework type -// system. -func (a GetAclRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetAclRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetAclRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetAclRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetAclRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetAclRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetAclRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetAclRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetAclRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, @@ -919,9 +2051,56 @@ func (a GetCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCredentialsRequest in the Terraform plugin framework type -// system. -func (a GetCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -956,9 +2135,56 @@ func (a GetCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetCredentialsResponse in the Terraform plugin framework type -// system. -func (a GetCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -991,9 +2217,56 @@ func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRepoPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetRepoPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRepoPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.StringType, @@ -1025,13 +2298,60 @@ func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Contex } } -// ToObjectType returns the representation of GetRepoPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetRepoPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRepoPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRepoPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: RepoPermissionsDescription{}.ToObjectType(ctx), + ElemType: RepoPermissionsDescription{}.Type(ctx), }, }, } @@ -1060,9 +2380,56 @@ func (a GetRepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRepoPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetRepoPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRepoPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRepoPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.StringType, @@ -1093,9 +2460,56 @@ func (a GetRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetRepoRequest in the Terraform plugin framework type -// system. -func (a GetRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRepoRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRepoRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRepoRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRepoRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRepoRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "repo_id": types.Int64Type, @@ -1139,9 +2553,56 @@ func (a GetRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// ToObjectType returns the representation of GetRepoResponse in the Terraform plugin framework type -// system. -func (a GetRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetRepoResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetRepoResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetRepoResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetRepoResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetRepoResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, @@ -1150,7 +2611,7 @@ func (a GetRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToObjectType(ctx), + ElemType: SparseCheckout{}.Type(ctx), }, "url": types.StringType, }, @@ -1182,9 +2643,56 @@ func (a GetSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetSecretRequest in the Terraform plugin framework type -// system. -func (a GetSecretRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetSecretRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetSecretRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetSecretRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetSecretRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetSecretRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetSecretRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetSecretRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetSecretRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1217,9 +2725,56 @@ func (a GetSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetSecretResponse in the Terraform plugin framework type -// system. -func (a GetSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetSecretResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetSecretResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetSecretResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetSecretResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetSecretResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetSecretResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -1251,9 +2806,56 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetStatusRequest in the Terraform plugin framework type -// system. -func (a GetStatusRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetStatusRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetStatusRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetStatusRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetStatusRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetStatusRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetStatusRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -1286,9 +2888,56 @@ func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWorkspaceObjectPermissionLevelsRequest in the Terraform plugin framework type -// system. -func (a GetWorkspaceObjectPermissionLevelsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceObjectPermissionLevelsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_object_id": types.StringType, @@ -1321,13 +2970,60 @@ func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// ToObjectType returns the representation of GetWorkspaceObjectPermissionLevelsResponse in the Terraform plugin framework type -// system. -func (a GetWorkspaceObjectPermissionLevelsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceObjectPermissionLevelsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission_levels": basetypes.ListType{ - ElemType: WorkspaceObjectPermissionsDescription{}.ToObjectType(ctx), + ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx), }, }, } @@ -1358,9 +3054,56 @@ func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// ToObjectType returns the representation of GetWorkspaceObjectPermissionsRequest in the Terraform plugin framework type -// system. -func (a GetWorkspaceObjectPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = GetWorkspaceObjectPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o GetWorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "workspace_object_id": types.StringType, @@ -1419,9 +3162,56 @@ func (a Import) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Import in the Terraform plugin framework type -// system. -func (a Import) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Import{} + +// Equal implements basetypes.ObjectValuable. +func (o Import) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Import) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Import) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Import) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Import) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Import) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Import) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "content": types.StringType, @@ -1453,9 +3243,56 @@ func (a ImportResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of ImportResponse in the Terraform plugin framework type -// system. -func (a ImportResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ImportResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ImportResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ImportResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ImportResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ImportResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ImportResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ImportResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ImportResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1484,9 +3321,56 @@ func (a ListAclsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListAclsRequest in the Terraform plugin framework type -// system. -func (a ListAclsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAclsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAclsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAclsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAclsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAclsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAclsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAclsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAclsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scope": types.StringType, @@ -1518,13 +3402,60 @@ func (a ListAclsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// ToObjectType returns the representation of ListAclsResponse in the Terraform plugin framework type -// system. -func (a ListAclsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListAclsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListAclsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListAclsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListAclsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListAclsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListAclsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListAclsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListAclsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "items": basetypes.ListType{ - ElemType: AclItem{}.ToObjectType(ctx), + ElemType: AclItem{}.Type(ctx), }, }, } @@ -1554,13 +3485,60 @@ func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// ToObjectType returns the representation of ListCredentialsResponse in the Terraform plugin framework type -// system. -func (a ListCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credentials": basetypes.ListType{ - ElemType: CredentialInfo{}.ToObjectType(ctx), + ElemType: CredentialInfo{}.Type(ctx), }, }, } @@ -1595,9 +3573,56 @@ func (a ListReposRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListReposRequest in the Terraform plugin framework type -// system. -func (a ListReposRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListReposRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListReposRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListReposRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListReposRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListReposRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListReposRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListReposRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListReposRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, @@ -1633,14 +3658,61 @@ func (a ListReposResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of ListReposResponse in the Terraform plugin framework type -// system. -func (a ListReposResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListReposResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListReposResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListReposResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListReposResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListReposResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListReposResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListReposResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListReposResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "repos": basetypes.ListType{ - ElemType: RepoInfo{}.ToObjectType(ctx), + ElemType: RepoInfo{}.Type(ctx), }, }, } @@ -1670,13 +3742,60 @@ func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// ToObjectType returns the representation of ListResponse in the Terraform plugin framework type -// system. -func (a ListResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "objects": basetypes.ListType{ - ElemType: ObjectInfo{}.ToObjectType(ctx), + ElemType: ObjectInfo{}.Type(ctx), }, }, } @@ -1706,13 +3825,60 @@ func (a ListScopesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// ToObjectType returns the representation of ListScopesResponse in the Terraform plugin framework type -// system. -func (a ListScopesResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListScopesResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListScopesResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListScopesResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListScopesResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListScopesResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListScopesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListScopesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListScopesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scopes": basetypes.ListType{ - ElemType: SecretScope{}.ToObjectType(ctx), + ElemType: SecretScope{}.Type(ctx), }, }, } @@ -1741,9 +3907,56 @@ func (a ListSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListSecretsRequest in the Terraform plugin framework type -// system. -func (a ListSecretsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSecretsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSecretsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSecretsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSecretsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSecretsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSecretsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSecretsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSecretsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "scope": types.StringType, @@ -1775,13 +3988,60 @@ func (a ListSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// ToObjectType returns the representation of ListSecretsResponse in the Terraform plugin framework type -// system. -func (a ListSecretsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListSecretsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o ListSecretsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListSecretsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListSecretsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListSecretsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListSecretsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListSecretsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListSecretsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "secrets": basetypes.ListType{ - ElemType: SecretMetadata{}.ToObjectType(ctx), + ElemType: SecretMetadata{}.Type(ctx), }, }, } @@ -1812,9 +4072,56 @@ func (a ListWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// ToObjectType returns the representation of ListWorkspaceRequest in the Terraform plugin framework type -// system. -func (a ListWorkspaceRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ListWorkspaceRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ListWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "notebooks_modified_after": types.Int64Type, @@ -1847,9 +4154,56 @@ func (a Mkdirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of Mkdirs in the Terraform plugin framework type -// system. -func (a Mkdirs) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = Mkdirs{} + +// Equal implements basetypes.ObjectValuable. +func (o Mkdirs) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o Mkdirs) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o Mkdirs) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o Mkdirs) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o Mkdirs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o Mkdirs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o Mkdirs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "path": types.StringType, @@ -1877,9 +4231,56 @@ func (a MkdirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of MkdirsResponse in the Terraform plugin framework type -// system. -func (a MkdirsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = MkdirsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o MkdirsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o MkdirsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o MkdirsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o MkdirsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o MkdirsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o MkdirsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o MkdirsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -1927,9 +4328,56 @@ func (a ObjectInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// ToObjectType returns the representation of ObjectInfo in the Terraform plugin framework type -// system. -func (a ObjectInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = ObjectInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o ObjectInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o ObjectInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o ObjectInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o ObjectInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o ObjectInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o ObjectInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o ObjectInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "created_at": types.Int64Type, @@ -1970,9 +4418,56 @@ func (a PutAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// ToObjectType returns the representation of PutAcl in the Terraform plugin framework type -// system. -func (a PutAcl) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutAcl{} + +// Equal implements basetypes.ObjectValuable. +func (o PutAcl) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutAcl) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutAcl) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutAcl) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutAcl) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutAcl) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutAcl) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "permission": types.StringType, @@ -2002,9 +4497,56 @@ func (a PutAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of PutAclResponse in the Terraform plugin framework type -// system. -func (a PutAclResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutAclResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PutAclResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutAclResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutAclResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutAclResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutAclResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutAclResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutAclResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2038,9 +4580,56 @@ func (a PutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// ToObjectType returns the representation of PutSecret in the Terraform plugin framework type -// system. -func (a PutSecret) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutSecret{} + +// Equal implements basetypes.ObjectValuable. +func (o PutSecret) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutSecret) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutSecret) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutSecret) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutSecret) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "bytes_value": types.StringType, @@ -2071,9 +4660,56 @@ func (a PutSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// ToObjectType returns the representation of PutSecretResponse in the Terraform plugin framework type -// system. -func (a PutSecretResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = PutSecretResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o PutSecretResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o PutSecretResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o PutSecretResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o PutSecretResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o PutSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o PutSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o PutSecretResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2107,9 +4743,56 @@ func (a RepoAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of RepoAccessControlRequest in the Terraform plugin framework type -// system. -func (a RepoAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -2152,13 +4835,60 @@ func (a RepoAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of RepoAccessControlResponse in the Terraform plugin framework type -// system. -func (a RepoAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: RepoPermission{}.ToObjectType(ctx), + ElemType: RepoPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -2205,9 +4935,56 @@ func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// ToObjectType returns the representation of RepoInfo in the Terraform plugin framework type -// system. -func (a RepoInfo) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoInfo{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoInfo) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoInfo) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoInfo) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoInfo) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, @@ -2216,7 +4993,7 @@ func (a RepoInfo) ToObjectType(ctx context.Context) types.ObjectType { "path": types.StringType, "provider": types.StringType, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.ToObjectType(ctx), + ElemType: SparseCheckout{}.Type(ctx), }, "url": types.StringType, }, @@ -2250,9 +5027,56 @@ func (a RepoPermission) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of RepoPermission in the Terraform plugin framework type -// system. -func (a RepoPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2275,29 +5099,76 @@ type RepoPermissions struct { func (newState *RepoPermissions) SyncEffectiveFieldsDuringCreateOrUpdate(plan RepoPermissions) { } -func (newState *RepoPermissions) SyncEffectiveFieldsDuringRead(existingState RepoPermissions) { +func (newState *RepoPermissions) SyncEffectiveFieldsDuringRead(existingState RepoPermissions) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoPermissions. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a RepoPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "access_control_list": reflect.TypeOf(RepoAccessControlResponse{}), + } +} + +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in RepoPermissions. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a RepoPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "access_control_list": reflect.TypeOf(RepoAccessControlResponse{}), +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) } + return ov.ToTerraformValue(ctx) } -// ToObjectType returns the representation of RepoPermissions in the Terraform plugin framework type -// system. -func (a RepoPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// Type implements basetypes.ObjectValuable. +func (o RepoPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RepoAccessControlResponse{}.ToObjectType(ctx), + ElemType: RepoAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2328,9 +5199,56 @@ func (a RepoPermissionsDescription) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// ToObjectType returns the representation of RepoPermissionsDescription in the Terraform plugin framework type -// system. -func (a RepoPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2364,13 +5282,60 @@ func (a RepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// ToObjectType returns the representation of RepoPermissionsRequest in the Terraform plugin framework type -// system. -func (a RepoPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = RepoPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o RepoPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: RepoAccessControlRequest{}.ToObjectType(ctx), + ElemType: RepoAccessControlRequest{}.Type(ctx), }, "repo_id": types.StringType, }, @@ -2401,9 +5366,56 @@ func (a SecretMetadata) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// ToObjectType returns the representation of SecretMetadata in the Terraform plugin framework type -// system. -func (a SecretMetadata) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SecretMetadata{} + +// Equal implements basetypes.ObjectValuable. +func (o SecretMetadata) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SecretMetadata) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SecretMetadata) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SecretMetadata) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SecretMetadata) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SecretMetadata) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SecretMetadata) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "key": types.StringType, @@ -2440,14 +5452,61 @@ func (a SecretScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// ToObjectType returns the representation of SecretScope in the Terraform plugin framework type -// system. -func (a SecretScope) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SecretScope{} + +// Equal implements basetypes.ObjectValuable. +func (o SecretScope) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SecretScope) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SecretScope) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SecretScope) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SecretScope) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SecretScope) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SecretScope) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "backend_type": types.StringType, "keyvault_metadata": basetypes.ListType{ - ElemType: AzureKeyVaultSecretScopeMetadata{}.ToObjectType(ctx), + ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx), }, "name": types.StringType, }, @@ -2482,9 +5541,56 @@ func (a SparseCheckout) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// ToObjectType returns the representation of SparseCheckout in the Terraform plugin framework type -// system. -func (a SparseCheckout) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparseCheckout{} + +// Equal implements basetypes.ObjectValuable. +func (o SparseCheckout) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparseCheckout) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparseCheckout) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparseCheckout) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparseCheckout) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparseCheckout) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparseCheckout) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "patterns": basetypes.ListType{ @@ -2522,9 +5628,56 @@ func (a SparseCheckoutUpdate) GetComplexFieldTypes(ctx context.Context) map[stri } } -// ToObjectType returns the representation of SparseCheckoutUpdate in the Terraform plugin framework type -// system. -func (a SparseCheckoutUpdate) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = SparseCheckoutUpdate{} + +// Equal implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o SparseCheckoutUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "patterns": basetypes.ListType{ @@ -2575,9 +5728,56 @@ func (a UpdateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateCredentialsRequest in the Terraform plugin framework type -// system. -func (a UpdateCredentialsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCredentialsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCredentialsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "credential_id": types.Int64Type, @@ -2608,9 +5808,56 @@ func (a UpdateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateCredentialsResponse in the Terraform plugin framework type -// system. -func (a UpdateCredentialsResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateCredentialsResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2650,15 +5897,62 @@ func (a UpdateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// ToObjectType returns the representation of UpdateRepoRequest in the Terraform plugin framework type -// system. -func (a UpdateRepoRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRepoRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "branch": types.StringType, "repo_id": types.Int64Type, "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckoutUpdate{}.ToObjectType(ctx), + ElemType: SparseCheckoutUpdate{}.Type(ctx), }, "tag": types.StringType, }, @@ -2685,9 +5979,56 @@ func (a UpdateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// ToObjectType returns the representation of UpdateRepoResponse in the Terraform plugin framework type -// system. -func (a UpdateRepoResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = UpdateRepoResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o UpdateRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{}, } @@ -2721,9 +6062,56 @@ func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// ToObjectType returns the representation of WorkspaceObjectAccessControlRequest in the Terraform plugin framework type -// system. -func (a WorkspaceObjectAccessControlRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceObjectAccessControlRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "group_name": types.StringType, @@ -2766,13 +6154,60 @@ func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// ToObjectType returns the representation of WorkspaceObjectAccessControlResponse in the Terraform plugin framework type -// system. -func (a WorkspaceObjectAccessControlResponse) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceObjectAccessControlResponse{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceObjectAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "all_permissions": basetypes.ListType{ - ElemType: WorkspaceObjectPermission{}.ToObjectType(ctx), + ElemType: WorkspaceObjectPermission{}.Type(ctx), }, "display_name": types.StringType, "group_name": types.StringType, @@ -2809,9 +6244,56 @@ func (a WorkspaceObjectPermission) GetComplexFieldTypes(ctx context.Context) map } } -// ToObjectType returns the representation of WorkspaceObjectPermission in the Terraform plugin framework type -// system. -func (a WorkspaceObjectPermission) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceObjectPermission{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "inherited": types.BoolType, @@ -2850,13 +6332,60 @@ func (a WorkspaceObjectPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// ToObjectType returns the representation of WorkspaceObjectPermissions in the Terraform plugin framework type -// system. -func (a WorkspaceObjectPermissions) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceObjectPermissions{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WorkspaceObjectAccessControlResponse{}.ToObjectType(ctx), + ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx), }, "object_id": types.StringType, "object_type": types.StringType, @@ -2887,9 +6416,56 @@ func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// ToObjectType returns the representation of WorkspaceObjectPermissionsDescription in the Terraform plugin framework type -// system. -func (a WorkspaceObjectPermissionsDescription) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceObjectPermissionsDescription{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsDescription) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "description": types.StringType, @@ -2925,16 +6501,89 @@ func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// ToObjectType returns the representation of WorkspaceObjectPermissionsRequest in the Terraform plugin framework type -// system. -func (a WorkspaceObjectPermissionsRequest) ToObjectType(ctx context.Context) types.ObjectType { +// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects +// and as elements in lists and maps. +var _ basetypes.ObjectValuable = WorkspaceObjectPermissionsRequest{} + +// Equal implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) Equal(v attr.Value) bool { + ov, d := o.ToObjectValue(context.Background()) + if d.HasError() { + return false + } + return ov.Equal(v) +} + +// IsNull implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) IsNull() bool { + // TF SDK structures are never null. + return false +} + +// IsUnknown implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) IsUnknown() bool { + // TF SDK structures are never unknown. + return false +} + +// String implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) String() string { + return fmt.Sprintf("%#v", o) +} + +// ToObjectValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { + return types.ObjectValueFrom( + ctx, + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + o, + ) +} + +// ToTerraformValue implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { + ov, d := o.ToObjectValue(ctx) + if d.HasError() { + return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) + } + return ov.ToTerraformValue(ctx) +} + +// Type implements basetypes.ObjectValuable. +func (o WorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "access_control_list": basetypes.ListType{ - ElemType: WorkspaceObjectAccessControlRequest{}.ToObjectType(ctx), + ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx), }, "workspace_object_id": types.StringType, "workspace_object_type": types.StringType, }, } } + +// This specifies the format of the file to be imported. +// +// The value is case sensitive. +// +// - `AUTO`: The item is imported depending on an analysis of the item's +// extension and the header content provided in the request. If the item is +// imported as a notebook, then the item's extension is automatically removed. - +// `SOURCE`: The notebook or directory is imported as source code. - `HTML`: The +// notebook is imported as an HTML file. - `JUPYTER`: The notebook is imported +// as a Jupyter/IPython Notebook file. - `DBC`: The notebook is imported in +// Databricks archive format. Required for directories. - `R_MARKDOWN`: The +// notebook is imported from R Markdown format. + +// The language of the object. This value is set only if the object type is +// `NOTEBOOK`. + +// The type of the object in workspace. +// +// - `NOTEBOOK`: document that contains runnable code, visualizations, and +// explanatory text. - `DIRECTORY`: directory - `LIBRARY`: library - `FILE`: +// file - `REPO`: repository - `DASHBOARD`: Lakeview dashboard + +// Permission level + +// Permission level From 5779ecec4de2df32b1739f453c2523f484af0665 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 6 Dec 2024 11:00:26 +0100 Subject: [PATCH 50/91] works again --- .codegen/model.go.tmpl | 77 +- .../products/catalog/data_functions.go | 2 +- .../pluginfw/products/cluster/data_cluster.go | 2 +- .../data_notification_destinations.go | 2 +- .../registered_model/data_registered_model.go | 2 +- .../data_registered_model_versions.go | 2 +- .../serving/data_serving_endpoints.go | 2 +- internal/service/apps_tf/model.go | 1756 +- internal/service/billing_tf/model.go | 2027 +-- internal/service/catalog_tf/model.go | 13346 +++------------- internal/service/compute_tf/model.go | 10052 +++--------- internal/service/dashboards_tf/model.go | 2601 +-- internal/service/files_tf/model.go | 1923 +-- internal/service/iam_tf/model.go | 3751 +---- internal/service/jobs_tf/model.go | 7409 ++------- internal/service/marketplace_tf/model.go | 6203 ++----- internal/service/ml_tf/model.go | 8802 ++-------- internal/service/oauth2_tf/model.go | 1741 +- internal/service/pipelines_tf/model.go | 3358 +--- internal/service/provisioning_tf/model.go | 2895 +--- internal/service/serving_tf/model.go | 4174 +---- internal/service/settings_tf/model.go | 7712 ++------- internal/service/sharing_tf/model.go | 2442 +-- internal/service/sql_tf/model.go | 8427 ++-------- internal/service/vectorsearch_tf/model.go | 2351 +-- internal/service/workspace_tf/model.go | 4162 +---- 26 files changed, 17822 insertions(+), 77399 deletions(-) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index f4c35839ad..dd8d0943f3 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -80,52 +80,22 @@ func (a {{.PascalName}}) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = {{.PascalName}}{} - -// Equal implements basetypes.ObjectValuable. -func (o {{.PascalName}}) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o {{.PascalName}}) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o {{.PascalName}}) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o {{.PascalName}}) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o {{.PascalName}}) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, {{.PascalName}} +// only implements ToObjectValue() and Type(). +func (o {{.PascalName}}) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o {{.PascalName}}) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + {{ range .Fields -}} + {{- $data := dict "field" . -}} + "{{template "tfsdk-name" $data}}": o.{{template "field-name" $data}}, + {{if and .Entity.Terraform .Entity.Terraform.IsServiceProposedIfEmpty -}} + {{- $data := dict "field" . "effective" true }} + "{{template "tfsdk-name" $data}}": o.{{template "field-name" $data}}, + {{- end -}} + {{- end}} + }) } // Type implements basetypes.ObjectValuable. @@ -154,14 +124,13 @@ func (o {{.PascalName}}) Type(ctx context.Context) attr.Type { {{- if .ArrayValue }}{{ template "complex-field-value" .ArrayValue }} {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} {{- else -}} - {{- if .IsExternal -}}{{.Package.Name}}.{{- end -}} {{- if or .IsString .Enum -}}types.String{} {{- else if .IsBool -}}types.Bool{} {{- else if .IsInt64 -}}types.Int64{} {{- else if .IsFloat64 -}}types.Float64{} {{- else if .IsInt -}}types.Int64{} - {{- else if .IsAny -}}struct{}{} - {{- else if or .IsEmpty .IsObject -}}{{.PascalName}}{} + {{- else if .IsAny -}}types.Object{} + {{- else if or .IsEmpty .IsObject -}}{{if .IsExternal}}{{.Package.Name}}.{{end}}{{.PascalName}}{} {{- end -}} {{- end -}} {{- end -}} @@ -201,7 +170,11 @@ even when they are called recursively. {{- define "field" -}} -{{if .effective}}Effective{{end}}{{.field.PascalName}}{{if eq .field.PascalName "Type"}}_{{end}} {{template "type" .field.Entity}} `{{template "field-tag" . }}` +{{template "field-name" .}} {{template "type" .field.Entity}} `{{template "field-tag" . }}` +{{- end -}} + +{{- define "field-name" -}} +{{if .effective}}Effective{{end}}{{.field.PascalName}}{{if eq .field.PascalName "Type"}}_{{end}} {{- end -}} {{- define "field-tag" -}} @@ -232,15 +205,15 @@ even when they are called recursively. {{- define "type" -}} {{- if not . }}any /* ERROR */ - {{- else if .IsExternal }}{{.Package.Name}}.{{.PascalName}} - {{- else if .IsAny}}any + {{- else if .IsExternal }}types.List{{/* Note: we use types.List for objects for now. TODO: change this to types.Object. */}} + {{- else if .IsAny}}types.Object {{- else if .IsEmpty}}types.List {{- else if .IsString}}types.String {{- else if .IsBool}}types.Bool {{- else if .IsInt64}}types.Int64 {{- else if .IsFloat64}}types.Float64 {{- else if .IsInt}}types.Int64 - {{- else if .IsByteStream}}io.ReadCloser + {{- else if .IsByteStream}}types.Object {{- else if .ArrayValue }}types.List {{- else if .MapValue }}types.Map {{- else if .IsObject }}types.List{{/* Note: we use types.List for objects for now. TODO: change this to types.Object. */}} diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index e199cc722a..9048e7a3b0 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -108,7 +108,7 @@ func (d *FunctionsDataSource) Read(ctx context.Context, req datasource.ReadReque if resp.Diagnostics.HasError() { return } - tfFunctions = append(tfFunctions, function) + tfFunctions = append(tfFunctions, function.ToObjectValue(ctx)) } functions.Functions = types.ListValueMust(catalog_tf.FunctionInfo{}.Type(ctx), tfFunctions) resp.Diagnostics.Append(resp.State.Set(ctx, functions)...) diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index 20250c7d09..6db44eaee1 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -90,7 +90,7 @@ func (d *ClusterDataSource) Read(ctx context.Context, req datasource.ReadRequest clusterInfo.ClusterId = tfCluster.ClusterId clusterInfo.Name = tfCluster.ClusterName - clusterInfo.ClusterInfo = types.ListValueMust(tfCluster.Type(ctx), []attr.Value{tfCluster}) + clusterInfo.ClusterInfo = types.ListValueMust(tfCluster.Type(ctx), []attr.Value{tfCluster.ToObjectValue(ctx)}) resp.Diagnostics.Append(resp.State.Set(ctx, clusterInfo)...) } diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index baacf723db..5e6688bb79 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -119,7 +119,7 @@ func (d *NotificationDestinationsDataSource) Read(ctx context.Context, req datas if AppendDiagAndCheckErrors(resp, converters.GoSdkToTfSdkStruct(ctx, notification, ¬ificationDestination)) { return } - notificationsTfSdk = append(notificationsTfSdk, notificationDestination) + notificationsTfSdk = append(notificationsTfSdk, notificationDestination.ToObjectValue(ctx)) } notificationInfo.NotificationDestinations = types.ListValueMust(settings_tf.ListNotificationDestinationsResult{}.Type(ctx), notificationsTfSdk) diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index 045413ee05..912f5b6060 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -101,6 +101,6 @@ func (d *RegisteredModelDataSource) Read(ctx context.Context, req datasource.Rea modelInfo.Aliases, d = basetypes.NewListValueFrom(ctx, modelInfo.Aliases.ElementType(ctx), []catalog_tf.RegisteredModelAlias{}) resp.Diagnostics.Append(d...) } - registeredModel.ModelInfo = types.ListValueMust(catalog_tf.RegisteredModelInfo{}.Type(ctx), []attr.Value{modelInfo}) + registeredModel.ModelInfo = types.ListValueMust(catalog_tf.RegisteredModelInfo{}.Type(ctx), []attr.Value{modelInfo.ToObjectValue(ctx)}) resp.Diagnostics.Append(resp.State.Set(ctx, registeredModel)...) } diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go index 9e7ebff000..5e3ab0c556 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model_versions.go @@ -81,7 +81,7 @@ func (d *RegisteredModelVersionsDataSource) Read(ctx context.Context, req dataso if resp.Diagnostics.HasError() { return } - tfModelVersions = append(tfModelVersions, modelVersion) + tfModelVersions = append(tfModelVersions, modelVersion.ToObjectValue(ctx)) } registeredModelVersions.ModelVersions = types.ListValueMust(catalog_tf.ModelVersionInfo{}.Type(ctx), tfModelVersions) resp.Diagnostics.Append(resp.State.Set(ctx, registeredModelVersions)...) diff --git a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go index 6fe6bc22a0..51c5e2c64b 100644 --- a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go +++ b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go @@ -82,7 +82,7 @@ func (d *ServingEndpointsDataSource) Read(ctx context.Context, req datasource.Re if resp.Diagnostics.HasError() { return } - tfEndpoints = append(tfEndpoints, endpointsInfo) + tfEndpoints = append(tfEndpoints, endpointsInfo.ToObjectValue(ctx)) } endpoints.Endpoints = types.ListValueMust(serving_tf.ServingEndpoint{}.Type(ctx), tfEndpoints) resp.Diagnostics.Append(resp.State.Set(ctx, endpoints)...) diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index cac158c410..9457b01d70 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -12,15 +12,11 @@ package apps_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type App struct { @@ -86,52 +82,30 @@ func (a App) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = App{} - -// Equal implements basetypes.ObjectValuable. -func (o App) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o App) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o App) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o App) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o App) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, App +// only implements ToObjectValue() and Type(). +func (o App) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o App) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "active_deployment": o.ActiveDeployment, + "app_status": o.AppStatus, + "compute_status": o.ComputeStatus, + "create_time": o.CreateTime, + "creator": o.Creator, + "default_source_code_path": o.DefaultSourceCodePath, + "description": o.Description, + "name": o.Name, + "pending_deployment": o.PendingDeployment, + "resources": o.Resources, + "service_principal_client_id": o.ServicePrincipalClientId, + "service_principal_id": o.ServicePrincipalId, + "service_principal_name": o.ServicePrincipalName, + "update_time": o.UpdateTime, + "updater": o.Updater, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -196,52 +170,18 @@ func (a AppAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o AppAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o AppAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -288,52 +228,19 @@ func (a AppAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AppAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o AppAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -396,52 +303,22 @@ func (a AppDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppDeployment{} - -// Equal implements basetypes.ObjectValuable. -func (o AppDeployment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppDeployment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppDeployment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppDeployment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppDeployment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppDeployment +// only implements ToObjectValue() and Type(). +func (o AppDeployment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppDeployment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "creator": o.Creator, + "deployment_artifacts": o.DeploymentArtifacts, + "deployment_id": o.DeploymentId, + "mode": o.Mode, + "source_code_path": o.SourceCodePath, + "status": o.Status, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -487,52 +364,15 @@ func (a AppDeploymentArtifacts) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppDeploymentArtifacts{} - -// Equal implements basetypes.ObjectValuable. -func (o AppDeploymentArtifacts) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppDeploymentArtifacts) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppDeploymentArtifacts) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppDeploymentArtifacts) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppDeploymentArtifacts) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppDeploymentArtifacts +// only implements ToObjectValue() and Type(). +func (o AppDeploymentArtifacts) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppDeploymentArtifacts) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "source_code_path": o.SourceCodePath, + }) } // Type implements basetypes.ObjectValuable. @@ -568,52 +408,16 @@ func (a AppDeploymentStatus) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppDeploymentStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o AppDeploymentStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppDeploymentStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppDeploymentStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppDeploymentStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppDeploymentStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppDeploymentStatus +// only implements ToObjectValue() and Type(). +func (o AppDeploymentStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppDeploymentStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -653,52 +457,17 @@ func (a AppPermission) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o AppPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppPermission +// only implements ToObjectValue() and Type(). +func (o AppPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -741,52 +510,17 @@ func (a AppPermissions) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o AppPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppPermissions +// only implements ToObjectValue() and Type(). +func (o AppPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -825,52 +559,16 @@ func (a AppPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o AppPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o AppPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -908,52 +606,16 @@ func (a AppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o AppPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o AppPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "app_name": o.AppName, + }) } // Type implements basetypes.ObjectValuable. @@ -1005,52 +667,20 @@ func (a AppResource) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppResource{} - -// Equal implements basetypes.ObjectValuable. -func (o AppResource) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppResource) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppResource) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppResource) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppResource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppResource +// only implements ToObjectValue() and Type(). +func (o AppResource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppResource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "job": o.Job, + "name": o.Name, + "secret": o.Secret, + "serving_endpoint": o.ServingEndpoint, + "sql_warehouse": o.SqlWarehouse, + }) } // Type implements basetypes.ObjectValuable. @@ -1100,52 +730,16 @@ func (a AppResourceJob) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppResourceJob{} - -// Equal implements basetypes.ObjectValuable. -func (o AppResourceJob) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppResourceJob) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppResourceJob) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppResourceJob) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppResourceJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppResourceJob +// only implements ToObjectValue() and Type(). +func (o AppResourceJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppResourceJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "permission": o.Permission, + }) } // Type implements basetypes.ObjectValuable. @@ -1185,52 +779,17 @@ func (a AppResourceSecret) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppResourceSecret{} - -// Equal implements basetypes.ObjectValuable. -func (o AppResourceSecret) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppResourceSecret) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppResourceSecret) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppResourceSecret) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppResourceSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppResourceSecret +// only implements ToObjectValue() and Type(). +func (o AppResourceSecret) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppResourceSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "permission": o.Permission, + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -1269,52 +828,16 @@ func (a AppResourceServingEndpoint) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppResourceServingEndpoint{} - -// Equal implements basetypes.ObjectValuable. -func (o AppResourceServingEndpoint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppResourceServingEndpoint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppResourceServingEndpoint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppResourceServingEndpoint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppResourceServingEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppResourceServingEndpoint +// only implements ToObjectValue() and Type(). +func (o AppResourceServingEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppResourceServingEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "permission": o.Permission, + }) } // Type implements basetypes.ObjectValuable. @@ -1352,52 +875,16 @@ func (a AppResourceSqlWarehouse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AppResourceSqlWarehouse{} - -// Equal implements basetypes.ObjectValuable. -func (o AppResourceSqlWarehouse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AppResourceSqlWarehouse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AppResourceSqlWarehouse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AppResourceSqlWarehouse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AppResourceSqlWarehouse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AppResourceSqlWarehouse +// only implements ToObjectValue() and Type(). +func (o AppResourceSqlWarehouse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AppResourceSqlWarehouse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "permission": o.Permission, + }) } // Type implements basetypes.ObjectValuable. @@ -1434,52 +921,16 @@ func (a ApplicationStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ApplicationStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o ApplicationStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ApplicationStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ApplicationStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ApplicationStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ApplicationStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ApplicationStatus +// only implements ToObjectValue() and Type(). +func (o ApplicationStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ApplicationStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -1516,52 +967,16 @@ func (a ComputeStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ComputeStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o ComputeStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ComputeStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ComputeStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ComputeStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ComputeStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ComputeStatus +// only implements ToObjectValue() and Type(). +func (o ComputeStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ComputeStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -1600,52 +1015,16 @@ func (a CreateAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateAppDeploymentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateAppDeploymentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateAppDeploymentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateAppDeploymentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateAppDeploymentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateAppDeploymentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateAppDeploymentRequest +// only implements ToObjectValue() and Type(). +func (o CreateAppDeploymentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateAppDeploymentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_deployment": o.AppDeployment, + "app_name": o.AppName, + }) } // Type implements basetypes.ObjectValuable. @@ -1684,52 +1063,15 @@ func (a CreateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateAppRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateAppRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateAppRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateAppRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateAppRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateAppRequest +// only implements ToObjectValue() and Type(). +func (o CreateAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app": o.App, + }) } // Type implements basetypes.ObjectValuable. @@ -1766,52 +1108,15 @@ func (a DeleteAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAppRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAppRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAppRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAppRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAppRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAppRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1848,52 +1153,16 @@ func (a GetAppDeploymentRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAppDeploymentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAppDeploymentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAppDeploymentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAppDeploymentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAppDeploymentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAppDeploymentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAppDeploymentRequest +// only implements ToObjectValue() and Type(). +func (o GetAppDeploymentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAppDeploymentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_name": o.AppName, + "deployment_id": o.DeploymentId, + }) } // Type implements basetypes.ObjectValuable. @@ -1929,52 +1198,15 @@ func (a GetAppPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAppPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAppPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetAppPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_name": o.AppName, + }) } // Type implements basetypes.ObjectValuable. @@ -2010,52 +1242,15 @@ func (a GetAppPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAppPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAppPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetAppPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAppPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -2092,52 +1287,15 @@ func (a GetAppPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAppPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAppPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAppPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAppPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAppPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAppPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAppPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetAppPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAppPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_name": o.AppName, + }) } // Type implements basetypes.ObjectValuable. @@ -2172,52 +1330,15 @@ func (a GetAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAppRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAppRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAppRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAppRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAppRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAppRequest +// only implements ToObjectValue() and Type(). +func (o GetAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2257,52 +1378,17 @@ func (a ListAppDeploymentsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAppDeploymentsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAppDeploymentsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAppDeploymentsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAppDeploymentsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAppDeploymentsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAppDeploymentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAppDeploymentsRequest +// only implements ToObjectValue() and Type(). +func (o ListAppDeploymentsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAppDeploymentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_name": o.AppName, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2342,52 +1428,16 @@ func (a ListAppDeploymentsResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAppDeploymentsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAppDeploymentsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAppDeploymentsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAppDeploymentsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAppDeploymentsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAppDeploymentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAppDeploymentsResponse +// only implements ToObjectValue() and Type(). +func (o ListAppDeploymentsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAppDeploymentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_deployments": o.AppDeployments, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2428,52 +1478,16 @@ func (a ListAppsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAppsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAppsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAppsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAppsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAppsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAppsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAppsRequest +// only implements ToObjectValue() and Type(). +func (o ListAppsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAppsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2511,52 +1525,16 @@ func (a ListAppsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAppsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAppsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAppsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAppsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAppsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAppsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAppsResponse +// only implements ToObjectValue() and Type(). +func (o ListAppsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAppsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apps": o.Apps, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2593,52 +1571,15 @@ func (a StartAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartAppRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o StartAppRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartAppRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartAppRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartAppRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartAppRequest +// only implements ToObjectValue() and Type(). +func (o StartAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2672,52 +1613,15 @@ func (a StopAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StopAppRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o StopAppRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StopAppRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StopAppRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StopAppRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StopAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StopAppRequest +// only implements ToObjectValue() and Type(). +func (o StopAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StopAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2756,52 +1660,16 @@ func (a UpdateAppRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAppRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAppRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAppRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAppRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAppRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAppRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAppRequest +// only implements ToObjectValue() and Type(). +func (o UpdateAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAppRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app": o.App, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 2d1722662c..66e3e57344 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -12,16 +12,11 @@ package billing_tf import ( "context" - "fmt" - "io" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type ActionConfiguration struct { @@ -50,52 +45,17 @@ func (a ActionConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ActionConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o ActionConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ActionConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ActionConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ActionConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ActionConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ActionConfiguration +// only implements ToObjectValue() and Type(). +func (o ActionConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ActionConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "action_configuration_id": o.ActionConfigurationId, + "action_type": o.ActionType, + "target": o.Target, + }) } // Type implements basetypes.ObjectValuable. @@ -147,52 +107,20 @@ func (a AlertConfiguration) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertConfiguration +// only implements ToObjectValue() and Type(). +func (o AlertConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "action_configurations": o.ActionConfigurations, + "alert_configuration_id": o.AlertConfigurationId, + "quantity_threshold": o.QuantityThreshold, + "quantity_type": o.QuantityType, + "time_period": o.TimePeriod, + "trigger_type": o.TriggerType, + }) } // Type implements basetypes.ObjectValuable. @@ -252,52 +180,21 @@ func (a BudgetConfiguration) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BudgetConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o BudgetConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BudgetConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BudgetConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BudgetConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BudgetConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BudgetConfiguration +// only implements ToObjectValue() and Type(). +func (o BudgetConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BudgetConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "alert_configurations": o.AlertConfigurations, + "budget_configuration_id": o.BudgetConfigurationId, + "create_time": o.CreateTime, + "display_name": o.DisplayName, + "filter": o.Filter, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -348,52 +245,16 @@ func (a BudgetConfigurationFilter) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BudgetConfigurationFilter{} - -// Equal implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BudgetConfigurationFilter +// only implements ToObjectValue() and Type(). +func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "tags": o.Tags, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -435,52 +296,16 @@ func (a BudgetConfigurationFilterClause) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BudgetConfigurationFilterClause{} - -// Equal implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterClause) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterClause) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterClause) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterClause) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterClause) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BudgetConfigurationFilterClause +// only implements ToObjectValue() and Type(). +func (o BudgetConfigurationFilterClause) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterClause) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "operator": o.Operator, + "values": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -520,52 +345,16 @@ func (a BudgetConfigurationFilterTagClause) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BudgetConfigurationFilterTagClause{} - -// Equal implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterTagClause) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterTagClause) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterTagClause) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterTagClause) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterTagClause) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BudgetConfigurationFilterTagClause +// only implements ToObjectValue() and Type(). +func (o BudgetConfigurationFilterTagClause) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterTagClause) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -605,52 +394,16 @@ func (a BudgetConfigurationFilterWorkspaceIdClause) GetComplexFieldTypes(ctx con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BudgetConfigurationFilterWorkspaceIdClause{} - -// Equal implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterWorkspaceIdClause) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterWorkspaceIdClause) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterWorkspaceIdClause) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterWorkspaceIdClause) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterWorkspaceIdClause) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BudgetConfigurationFilterWorkspaceIdClause +// only implements ToObjectValue() and Type(). +func (o BudgetConfigurationFilterWorkspaceIdClause) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BudgetConfigurationFilterWorkspaceIdClause) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "operator": o.Operator, + "values": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -692,52 +445,16 @@ func (a CreateBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBillingUsageDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBillingUsageDashboardRequest +// only implements ToObjectValue() and Type(). +func (o CreateBillingUsageDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_type": o.DashboardType, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -772,52 +489,15 @@ func (a CreateBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBillingUsageDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBillingUsageDashboardResponse +// only implements ToObjectValue() and Type(). +func (o CreateBillingUsageDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBillingUsageDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -864,52 +544,18 @@ func (a CreateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBudgetConfigurationBudget{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudget) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudget) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudget) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudget) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBudgetConfigurationBudget +// only implements ToObjectValue() and Type(). +func (o CreateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "alert_configurations": o.AlertConfigurations, + "display_name": o.DisplayName, + "filter": o.Filter, + }) } // Type implements basetypes.ObjectValuable. @@ -952,52 +598,16 @@ func (a CreateBudgetConfigurationBudgetActionConfigurations) GetComplexFieldType return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBudgetConfigurationBudgetActionConfigurations{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetActionConfigurations) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetActionConfigurations) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetActionConfigurations) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetActionConfigurations) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetActionConfigurations) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBudgetConfigurationBudgetActionConfigurations +// only implements ToObjectValue() and Type(). +func (o CreateBudgetConfigurationBudgetActionConfigurations) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetActionConfigurations) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "action_type": o.ActionType, + "target": o.Target, + }) } // Type implements basetypes.ObjectValuable. @@ -1046,52 +656,19 @@ func (a CreateBudgetConfigurationBudgetAlertConfigurations) GetComplexFieldTypes } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBudgetConfigurationBudgetAlertConfigurations{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetAlertConfigurations) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetAlertConfigurations) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetAlertConfigurations) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetAlertConfigurations) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBudgetConfigurationBudgetAlertConfigurations +// only implements ToObjectValue() and Type(). +func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "action_configurations": o.ActionConfigurations, + "quantity_threshold": o.QuantityThreshold, + "quantity_type": o.QuantityType, + "time_period": o.TimePeriod, + "trigger_type": o.TriggerType, + }) } // Type implements basetypes.ObjectValuable. @@ -1133,52 +710,15 @@ func (a CreateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBudgetConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBudgetConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o CreateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget": o.Budget, + }) } // Type implements basetypes.ObjectValuable. @@ -1216,52 +756,15 @@ func (a CreateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateBudgetConfigurationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateBudgetConfigurationResponse +// only implements ToObjectValue() and Type(). +func (o CreateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget": o.Budget, + }) } // Type implements basetypes.ObjectValuable. @@ -1366,52 +869,23 @@ func (a CreateLogDeliveryConfigurationParams) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateLogDeliveryConfigurationParams{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateLogDeliveryConfigurationParams) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateLogDeliveryConfigurationParams) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateLogDeliveryConfigurationParams) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateLogDeliveryConfigurationParams) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateLogDeliveryConfigurationParams) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateLogDeliveryConfigurationParams +// only implements ToObjectValue() and Type(). +func (o CreateLogDeliveryConfigurationParams) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateLogDeliveryConfigurationParams) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "config_name": o.ConfigName, + "credentials_id": o.CredentialsId, + "delivery_path_prefix": o.DeliveryPathPrefix, + "delivery_start_time": o.DeliveryStartTime, + "log_type": o.LogType, + "output_format": o.OutputFormat, + "status": o.Status, + "storage_configuration_id": o.StorageConfigurationId, + "workspace_ids_filter": o.WorkspaceIdsFilter, + }) } // Type implements basetypes.ObjectValuable. @@ -1456,52 +930,15 @@ func (a DeleteBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteBudgetConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteBudgetConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteBudgetConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget_id": o.BudgetId, + }) } // Type implements basetypes.ObjectValuable. @@ -1533,52 +970,13 @@ func (a DeleteBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteBudgetConfigurationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteBudgetConfigurationResponse +// only implements ToObjectValue() and Type(). +func (o DeleteBudgetConfigurationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1619,52 +1017,17 @@ func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DownloadRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DownloadRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DownloadRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DownloadRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DownloadRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DownloadRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DownloadRequest +// only implements ToObjectValue() and Type(). +func (o DownloadRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DownloadRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end_month": o.EndMonth, + "personal_data": o.PersonalData, + "start_month": o.StartMonth, + }) } // Type implements basetypes.ObjectValuable. @@ -1679,7 +1042,7 @@ func (o DownloadRequest) Type(ctx context.Context) attr.Type { } type DownloadResponse struct { - Contents io.ReadCloser `tfsdk:"-"` + Contents types.Object `tfsdk:"-"` } func (newState *DownloadResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan DownloadResponse) { @@ -1699,52 +1062,15 @@ func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DownloadResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DownloadResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DownloadResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DownloadResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DownloadResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DownloadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DownloadResponse +// only implements ToObjectValue() and Type(). +func (o DownloadResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DownloadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "contents": o.Contents, + }) } // Type implements basetypes.ObjectValuable. @@ -1784,52 +1110,16 @@ func (a GetBillingUsageDashboardRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetBillingUsageDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetBillingUsageDashboardRequest +// only implements ToObjectValue() and Type(). +func (o GetBillingUsageDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_type": o.DashboardType, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1866,52 +1156,16 @@ func (a GetBillingUsageDashboardResponse) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetBillingUsageDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetBillingUsageDashboardResponse +// only implements ToObjectValue() and Type(). +func (o GetBillingUsageDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetBillingUsageDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "dashboard_url": o.DashboardUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -1947,52 +1201,15 @@ func (a GetBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetBudgetConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetBudgetConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o GetBudgetConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget_id": o.BudgetId, + }) } // Type implements basetypes.ObjectValuable. @@ -2027,52 +1244,15 @@ func (a GetBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetBudgetConfigurationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetBudgetConfigurationResponse +// only implements ToObjectValue() and Type(). +func (o GetBudgetConfigurationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget": o.Budget, + }) } // Type implements basetypes.ObjectValuable. @@ -2109,52 +1289,15 @@ func (a GetLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetLogDeliveryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetLogDeliveryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetLogDeliveryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetLogDeliveryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetLogDeliveryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetLogDeliveryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetLogDeliveryRequest +// only implements ToObjectValue() and Type(). +func (o GetLogDeliveryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetLogDeliveryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "log_delivery_configuration_id": o.LogDeliveryConfigurationId, + }) } // Type implements basetypes.ObjectValuable. @@ -2191,52 +1334,15 @@ func (a ListBudgetConfigurationsRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListBudgetConfigurationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListBudgetConfigurationsRequest +// only implements ToObjectValue() and Type(). +func (o ListBudgetConfigurationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2274,52 +1380,16 @@ func (a ListBudgetConfigurationsResponse) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListBudgetConfigurationsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListBudgetConfigurationsResponse +// only implements ToObjectValue() and Type(). +func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListBudgetConfigurationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budgets": o.Budgets, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2361,52 +1431,17 @@ func (a ListLogDeliveryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListLogDeliveryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListLogDeliveryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListLogDeliveryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListLogDeliveryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListLogDeliveryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListLogDeliveryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListLogDeliveryRequest +// only implements ToObjectValue() and Type(). +func (o ListLogDeliveryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListLogDeliveryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credentials_id": o.CredentialsId, + "status": o.Status, + "storage_configuration_id": o.StorageConfigurationId, + }) } // Type implements basetypes.ObjectValuable. @@ -2524,52 +1559,28 @@ func (a LogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogDeliveryConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o LogDeliveryConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogDeliveryConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogDeliveryConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogDeliveryConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogDeliveryConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogDeliveryConfiguration +// only implements ToObjectValue() and Type(). +func (o LogDeliveryConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogDeliveryConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "config_id": o.ConfigId, + "config_name": o.ConfigName, + "creation_time": o.CreationTime, + "credentials_id": o.CredentialsId, + "delivery_path_prefix": o.DeliveryPathPrefix, + "delivery_start_time": o.DeliveryStartTime, + "log_delivery_status": o.LogDeliveryStatus, + "log_type": o.LogType, + "output_format": o.OutputFormat, + "status": o.Status, + "storage_configuration_id": o.StorageConfigurationId, + "update_time": o.UpdateTime, + "workspace_ids_filter": o.WorkspaceIdsFilter, + }) } // Type implements basetypes.ObjectValuable. @@ -2638,52 +1649,18 @@ func (a LogDeliveryStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogDeliveryStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o LogDeliveryStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogDeliveryStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogDeliveryStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogDeliveryStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogDeliveryStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogDeliveryStatus +// only implements ToObjectValue() and Type(). +func (o LogDeliveryStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogDeliveryStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "last_attempt_time": o.LastAttemptTime, + "last_successful_attempt_time": o.LastSuccessfulAttemptTime, + "message": o.Message, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -2718,52 +1695,13 @@ func (a PatchStatusResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PatchStatusResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PatchStatusResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PatchStatusResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PatchStatusResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PatchStatusResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PatchStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PatchStatusResponse +// only implements ToObjectValue() and Type(). +func (o PatchStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PatchStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2810,52 +1748,19 @@ func (a UpdateBudgetConfigurationBudget) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateBudgetConfigurationBudget{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationBudget) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationBudget) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationBudget) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationBudget) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateBudgetConfigurationBudget +// only implements ToObjectValue() and Type(). +func (o UpdateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationBudget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "alert_configurations": o.AlertConfigurations, + "budget_configuration_id": o.BudgetConfigurationId, + "display_name": o.DisplayName, + "filter": o.Filter, + }) } // Type implements basetypes.ObjectValuable. @@ -2902,52 +1807,16 @@ func (a UpdateBudgetConfigurationRequest) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateBudgetConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateBudgetConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o UpdateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget": o.Budget, + "budget_id": o.BudgetId, + }) } // Type implements basetypes.ObjectValuable. @@ -2986,52 +1855,15 @@ func (a UpdateBudgetConfigurationResponse) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateBudgetConfigurationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateBudgetConfigurationResponse +// only implements ToObjectValue() and Type(). +func (o UpdateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateBudgetConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget": o.Budget, + }) } // Type implements basetypes.ObjectValuable. @@ -3073,52 +1905,16 @@ func (a UpdateLogDeliveryConfigurationStatusRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateLogDeliveryConfigurationStatusRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateLogDeliveryConfigurationStatusRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateLogDeliveryConfigurationStatusRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateLogDeliveryConfigurationStatusRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateLogDeliveryConfigurationStatusRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateLogDeliveryConfigurationStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateLogDeliveryConfigurationStatusRequest +// only implements ToObjectValue() and Type(). +func (o UpdateLogDeliveryConfigurationStatusRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateLogDeliveryConfigurationStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "log_delivery_configuration_id": o.LogDeliveryConfigurationId, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -3154,52 +1950,15 @@ func (a WrappedCreateLogDeliveryConfiguration) GetComplexFieldTypes(ctx context. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WrappedCreateLogDeliveryConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o WrappedCreateLogDeliveryConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WrappedCreateLogDeliveryConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WrappedCreateLogDeliveryConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WrappedCreateLogDeliveryConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WrappedCreateLogDeliveryConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WrappedCreateLogDeliveryConfiguration +// only implements ToObjectValue() and Type(). +func (o WrappedCreateLogDeliveryConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WrappedCreateLogDeliveryConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "log_delivery_configuration": o.LogDeliveryConfiguration, + }) } // Type implements basetypes.ObjectValuable. @@ -3236,52 +1995,15 @@ func (a WrappedLogDeliveryConfiguration) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WrappedLogDeliveryConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WrappedLogDeliveryConfiguration +// only implements ToObjectValue() and Type(). +func (o WrappedLogDeliveryConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "log_delivery_configuration": o.LogDeliveryConfiguration, + }) } // Type implements basetypes.ObjectValuable. @@ -3318,52 +2040,15 @@ func (a WrappedLogDeliveryConfigurations) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WrappedLogDeliveryConfigurations{} - -// Equal implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfigurations) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfigurations) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfigurations) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfigurations) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WrappedLogDeliveryConfigurations +// only implements ToObjectValue() and Type(). +func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WrappedLogDeliveryConfigurations) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "log_delivery_configurations": o.LogDeliveryConfigurations, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index c7f33168a4..fce3e2ef05 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -12,15 +12,11 @@ package catalog_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AccountsCreateMetastore struct { @@ -46,52 +42,15 @@ func (a AccountsCreateMetastore) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsCreateMetastore{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsCreateMetastore) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsCreateMetastore) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsCreateMetastore) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsCreateMetastore) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsCreateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsCreateMetastore +// only implements ToObjectValue() and Type(). +func (o AccountsCreateMetastore) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsCreateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_info": o.MetastoreInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -132,52 +91,17 @@ func (a AccountsCreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsCreateMetastoreAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsCreateMetastoreAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsCreateMetastoreAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsCreateMetastoreAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsCreateMetastoreAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsCreateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsCreateMetastoreAssignment +// only implements ToObjectValue() and Type(). +func (o AccountsCreateMetastoreAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsCreateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_assignment": o.MetastoreAssignment, + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -218,52 +142,16 @@ func (a AccountsCreateStorageCredential) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsCreateStorageCredential{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsCreateStorageCredential) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsCreateStorageCredential) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsCreateStorageCredential) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsCreateStorageCredential) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsCreateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsCreateStorageCredential +// only implements ToObjectValue() and Type(). +func (o AccountsCreateStorageCredential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsCreateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_info": o.CredentialInfo, + "metastore_id": o.MetastoreId, + }) } // Type implements basetypes.ObjectValuable. @@ -301,52 +189,15 @@ func (a AccountsMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsMetastoreAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsMetastoreAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsMetastoreAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsMetastoreAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsMetastoreAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsMetastoreAssignment +// only implements ToObjectValue() and Type(). +func (o AccountsMetastoreAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_assignment": o.MetastoreAssignment, + }) } // Type implements basetypes.ObjectValuable. @@ -383,52 +234,15 @@ func (a AccountsMetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsMetastoreInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsMetastoreInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsMetastoreInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsMetastoreInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsMetastoreInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsMetastoreInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsMetastoreInfo +// only implements ToObjectValue() and Type(). +func (o AccountsMetastoreInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsMetastoreInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_info": o.MetastoreInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -465,52 +279,15 @@ func (a AccountsStorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsStorageCredentialInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsStorageCredentialInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsStorageCredentialInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsStorageCredentialInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsStorageCredentialInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsStorageCredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsStorageCredentialInfo +// only implements ToObjectValue() and Type(). +func (o AccountsStorageCredentialInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsStorageCredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_info": o.CredentialInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -550,52 +327,16 @@ func (a AccountsUpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsUpdateMetastore{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastore) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastore) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastore) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastore) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsUpdateMetastore +// only implements ToObjectValue() and Type(). +func (o AccountsUpdateMetastore) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + "metastore_info": o.MetastoreInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -637,52 +378,17 @@ func (a AccountsUpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsUpdateMetastoreAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastoreAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastoreAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastoreAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastoreAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsUpdateMetastoreAssignment +// only implements ToObjectValue() and Type(). +func (o AccountsUpdateMetastoreAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsUpdateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_assignment": o.MetastoreAssignment, + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -725,52 +431,17 @@ func (a AccountsUpdateStorageCredential) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccountsUpdateStorageCredential{} - -// Equal implements basetypes.ObjectValuable. -func (o AccountsUpdateStorageCredential) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccountsUpdateStorageCredential) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccountsUpdateStorageCredential) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccountsUpdateStorageCredential) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccountsUpdateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccountsUpdateStorageCredential +// only implements ToObjectValue() and Type(). +func (o AccountsUpdateStorageCredential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccountsUpdateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_info": o.CredentialInfo, + "metastore_id": o.MetastoreId, + "storage_credential_name": o.StorageCredentialName, + }) } // Type implements basetypes.ObjectValuable. @@ -816,52 +487,18 @@ func (a ArtifactAllowlistInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ArtifactAllowlistInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ArtifactAllowlistInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ArtifactAllowlistInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ArtifactAllowlistInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ArtifactAllowlistInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ArtifactAllowlistInfo +// only implements ToObjectValue() and Type(). +func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ArtifactAllowlistInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_matchers": o.ArtifactMatchers, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "metastore_id": o.MetastoreId, + }) } // Type implements basetypes.ObjectValuable. @@ -902,52 +539,16 @@ func (a ArtifactMatcher) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ArtifactMatcher{} - -// Equal implements basetypes.ObjectValuable. -func (o ArtifactMatcher) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ArtifactMatcher) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ArtifactMatcher) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ArtifactMatcher) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ArtifactMatcher) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ArtifactMatcher +// only implements ToObjectValue() and Type(). +func (o ArtifactMatcher) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ArtifactMatcher) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact": o.Artifact, + "match_type": o.MatchType, + }) } // Type implements basetypes.ObjectValuable. @@ -980,52 +581,13 @@ func (a AssignResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AssignResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AssignResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AssignResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AssignResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AssignResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AssignResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AssignResponse +// only implements ToObjectValue() and Type(). +func (o AssignResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AssignResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1067,52 +629,18 @@ func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsCredentials{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsCredentials) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsCredentials) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsCredentials) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsCredentials) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsCredentials +// only implements ToObjectValue() and Type(). +func (o AwsCredentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_key_id": o.AccessKeyId, + "access_point": o.AccessPoint, + "secret_access_key": o.SecretAccessKey, + "session_token": o.SessionToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1157,52 +685,17 @@ func (a AwsIamRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsIamRole{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsIamRole) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsIamRole) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsIamRole) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsIamRole) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsIamRole) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsIamRole +// only implements ToObjectValue() and Type(). +func (o AwsIamRole) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsIamRole) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "external_id": o.ExternalId, + "role_arn": o.RoleArn, + "unity_catalog_iam_arn": o.UnityCatalogIamArn, + }) } // Type implements basetypes.ObjectValuable. @@ -1238,52 +731,15 @@ func (a AwsIamRoleRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsIamRoleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsIamRoleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsIamRoleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsIamRoleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsIamRoleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsIamRoleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsIamRoleRequest +// only implements ToObjectValue() and Type(). +func (o AwsIamRoleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsIamRoleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "role_arn": o.RoleArn, + }) } // Type implements basetypes.ObjectValuable. @@ -1323,52 +779,17 @@ func (a AwsIamRoleResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsIamRoleResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsIamRoleResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsIamRoleResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsIamRoleResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsIamRoleResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsIamRoleResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsIamRoleResponse +// only implements ToObjectValue() and Type(). +func (o AwsIamRoleResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsIamRoleResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "external_id": o.ExternalId, + "role_arn": o.RoleArn, + "unity_catalog_iam_arn": o.UnityCatalogIamArn, + }) } // Type implements basetypes.ObjectValuable. @@ -1408,52 +829,15 @@ func (a AzureActiveDirectoryToken) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureActiveDirectoryToken{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureActiveDirectoryToken) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureActiveDirectoryToken) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureActiveDirectoryToken) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureActiveDirectoryToken) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureActiveDirectoryToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureActiveDirectoryToken +// only implements ToObjectValue() and Type(). +func (o AzureActiveDirectoryToken) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureActiveDirectoryToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aad_token": o.AadToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1502,52 +886,17 @@ func (a AzureManagedIdentity) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureManagedIdentity{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureManagedIdentity) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureManagedIdentity) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureManagedIdentity) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureManagedIdentity) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureManagedIdentity) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureManagedIdentity +// only implements ToObjectValue() and Type(). +func (o AzureManagedIdentity) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureManagedIdentity) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_connector_id": o.AccessConnectorId, + "credential_id": o.CredentialId, + "managed_identity_id": o.ManagedIdentityId, + }) } // Type implements basetypes.ObjectValuable. @@ -1592,52 +941,16 @@ func (a AzureManagedIdentityRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureManagedIdentityRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureManagedIdentityRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureManagedIdentityRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureManagedIdentityRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureManagedIdentityRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureManagedIdentityRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureManagedIdentityRequest +// only implements ToObjectValue() and Type(). +func (o AzureManagedIdentityRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureManagedIdentityRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_connector_id": o.AccessConnectorId, + "managed_identity_id": o.ManagedIdentityId, + }) } // Type implements basetypes.ObjectValuable. @@ -1683,52 +996,17 @@ func (a AzureManagedIdentityResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureManagedIdentityResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureManagedIdentityResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureManagedIdentityResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureManagedIdentityResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureManagedIdentityResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureManagedIdentityResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureManagedIdentityResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureManagedIdentityResponse +// only implements ToObjectValue() and Type(). +func (o AzureManagedIdentityResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "access_connector_id": o.AccessConnectorId, + "credential_id": o.CredentialId, + "managed_identity_id": o.ManagedIdentityId, + }) } // Type implements basetypes.ObjectValuable. @@ -1771,52 +1049,17 @@ func (a AzureServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureServicePrincipal{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureServicePrincipal) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureServicePrincipal) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureServicePrincipal) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureServicePrincipal) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureServicePrincipal) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureServicePrincipal +// only implements ToObjectValue() and Type(). +func (o AzureServicePrincipal) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureServicePrincipal) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "application_id": o.ApplicationId, + "client_secret": o.ClientSecret, + "directory_id": o.DirectoryId, + }) } // Type implements basetypes.ObjectValuable. @@ -1854,52 +1097,15 @@ func (a AzureUserDelegationSas) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureUserDelegationSas{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureUserDelegationSas) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureUserDelegationSas) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureUserDelegationSas) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureUserDelegationSas) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureUserDelegationSas) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureUserDelegationSas +// only implements ToObjectValue() and Type(). +func (o AzureUserDelegationSas) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureUserDelegationSas) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "sas_token": o.SasToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1936,52 +1142,16 @@ func (a CancelRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelRefreshRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelRefreshRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelRefreshRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelRefreshRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelRefreshRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelRefreshRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelRefreshRequest +// only implements ToObjectValue() and Type(). +func (o CancelRefreshRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelRefreshRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "refresh_id": o.RefreshId, + "table_name": o.TableName, + }) } // Type implements basetypes.ObjectValuable. @@ -2014,52 +1184,13 @@ func (a CancelRefreshResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelRefreshResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelRefreshResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelRefreshResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelRefreshResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelRefreshResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelRefreshResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelRefreshResponse +// only implements ToObjectValue() and Type(). +func (o CancelRefreshResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelRefreshResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2149,52 +1280,38 @@ func (a CatalogInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CatalogInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o CatalogInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CatalogInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CatalogInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CatalogInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CatalogInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CatalogInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CatalogInfo +// only implements ToObjectValue() and Type(). +func (o CatalogInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "browse_only": o.BrowseOnly, + "catalog_type": o.CatalogType, + "comment": o.Comment, + "connection_name": o.ConnectionName, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "effective_predictive_optimization_flag": o.EffectivePredictiveOptimizationFlag, + "enable_predictive_optimization": o.EnablePredictiveOptimization, + "full_name": o.FullName, + "isolation_mode": o.IsolationMode, + "metastore_id": o.MetastoreId, + "name": o.Name, + "options": o.Options, + "owner": o.Owner, + "properties": o.Properties, + "provider_name": o.ProviderName, + "provisioning_info": o.ProvisioningInfo, + "securable_kind": o.SecurableKind, + "securable_type": o.SecurableType, + "share_name": o.ShareName, + "storage_location": o.StorageLocation, + "storage_root": o.StorageRoot, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -2263,52 +1380,17 @@ func (a CloudflareApiToken) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CloudflareApiToken{} - -// Equal implements basetypes.ObjectValuable. -func (o CloudflareApiToken) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CloudflareApiToken) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CloudflareApiToken) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CloudflareApiToken) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CloudflareApiToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CloudflareApiToken +// only implements ToObjectValue() and Type(). +func (o CloudflareApiToken) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CloudflareApiToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_key_id": o.AccessKeyId, + "account_id": o.AccountId, + "secret_access_key": o.SecretAccessKey, + }) } // Type implements basetypes.ObjectValuable. @@ -2368,52 +1450,26 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ColumnInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ColumnInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ColumnInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ColumnInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ColumnInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ColumnInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ColumnInfo +// only implements ToObjectValue() and Type(). +func (o ColumnInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ColumnInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "mask": o.Mask, + "name": o.Name, + "nullable": o.Nullable, + "partition_index": o.PartitionIndex, + "position": o.Position, + "type_interval_type": o.TypeIntervalType, + "type_json": o.TypeJson, + "type_name": o.TypeName, + "type_precision": o.TypePrecision, + "type_scale": o.TypeScale, + "type_text": o.TypeText, + }) } // Type implements basetypes.ObjectValuable. @@ -2467,52 +1523,16 @@ func (a ColumnMask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ColumnMask{} - -// Equal implements basetypes.ObjectValuable. -func (o ColumnMask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ColumnMask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ColumnMask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ColumnMask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ColumnMask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ColumnMask +// only implements ToObjectValue() and Type(). +func (o ColumnMask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ColumnMask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "function_name": o.FunctionName, + "using_column_names": o.UsingColumnNames, + }) } // Type implements basetypes.ObjectValuable. @@ -2590,52 +1610,33 @@ func (a ConnectionInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ConnectionInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ConnectionInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ConnectionInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ConnectionInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ConnectionInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ConnectionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ConnectionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ConnectionInfo +// only implements ToObjectValue() and Type(). +func (o ConnectionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "comment": o.Comment, + "connection_id": o.ConnectionId, + "connection_type": o.ConnectionType, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "credential_type": o.CredentialType, + "full_name": o.FullName, + "metastore_id": o.MetastoreId, + "name": o.Name, + "options": o.Options, + "owner": o.Owner, + "properties": o.Properties, + "provisioning_info": o.ProvisioningInfo, + "read_only": o.ReadOnly, + "securable_kind": o.SecurableKind, + "securable_type": o.SecurableType, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -2704,52 +1705,17 @@ func (a ContinuousUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ContinuousUpdateStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o ContinuousUpdateStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ContinuousUpdateStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ContinuousUpdateStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ContinuousUpdateStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ContinuousUpdateStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ContinuousUpdateStatus +// only implements ToObjectValue() and Type(). +func (o ContinuousUpdateStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ContinuousUpdateStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "initial_pipeline_sync_progress": o.InitialPipelineSyncProgress, + "last_processed_commit_version": o.LastProcessedCommitVersion, + "timestamp": o.Timestamp, + }) } // Type implements basetypes.ObjectValuable. @@ -2807,52 +1773,22 @@ func (a CreateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCatalog{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCatalog) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCatalog) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCatalog) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCatalog) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCatalog) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCatalog +// only implements ToObjectValue() and Type(). +func (o CreateCatalog) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCatalog) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "connection_name": o.ConnectionName, + "name": o.Name, + "options": o.Options, + "properties": o.Properties, + "provider_name": o.ProviderName, + "share_name": o.ShareName, + "storage_root": o.StorageRoot, + }) } // Type implements basetypes.ObjectValuable. @@ -2911,52 +1847,20 @@ func (a CreateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateConnection{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateConnection) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateConnection) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateConnection) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateConnection) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateConnection) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateConnection +// only implements ToObjectValue() and Type(). +func (o CreateConnection) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateConnection) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "connection_type": o.ConnectionType, + "name": o.Name, + "options": o.Options, + "properties": o.Properties, + "read_only": o.ReadOnly, + }) } // Type implements basetypes.ObjectValuable. @@ -3024,52 +1928,23 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCredentialRequest +// only implements ToObjectValue() and Type(). +func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "comment": o.Comment, + "gcp_service_account_key": o.GcpServiceAccountKey, + "name": o.Name, + "purpose": o.Purpose, + "read_only": o.ReadOnly, + "skip_validation": o.SkipValidation, + }) } // Type implements basetypes.ObjectValuable. @@ -3140,52 +2015,23 @@ func (a CreateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExternalLocation{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExternalLocation) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExternalLocation) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExternalLocation) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExternalLocation) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExternalLocation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExternalLocation +// only implements ToObjectValue() and Type(). +func (o CreateExternalLocation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExternalLocation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_point": o.AccessPoint, + "comment": o.Comment, + "credential_name": o.CredentialName, + "encryption_details": o.EncryptionDetails, + "fallback": o.Fallback, + "name": o.Name, + "read_only": o.ReadOnly, + "skip_validation": o.SkipValidation, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -3277,52 +2123,35 @@ func (a CreateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateFunction{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateFunction) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateFunction) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateFunction) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateFunction) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateFunction) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateFunction) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateFunction +// only implements ToObjectValue() and Type(). +func (o CreateFunction) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "comment": o.Comment, + "data_type": o.DataType, + "external_language": o.ExternalLanguage, + "external_name": o.ExternalName, + "full_data_type": o.FullDataType, + "input_params": o.InputParams, + "is_deterministic": o.IsDeterministic, + "is_null_call": o.IsNullCall, + "name": o.Name, + "parameter_style": o.ParameterStyle, + "properties": o.Properties, + "return_params": o.ReturnParams, + "routine_body": o.RoutineBody, + "routine_definition": o.RoutineDefinition, + "routine_dependencies": o.RoutineDependencies, + "schema_name": o.SchemaName, + "security_type": o.SecurityType, + "specific_name": o.SpecificName, + "sql_data_access": o.SqlDataAccess, + "sql_path": o.SqlPath, + }) } // Type implements basetypes.ObjectValuable. @@ -3384,52 +2213,15 @@ func (a CreateFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateFunctionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateFunctionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateFunctionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateFunctionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateFunctionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateFunctionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateFunctionRequest +// only implements ToObjectValue() and Type(). +func (o CreateFunctionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateFunctionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "function_info": o.FunctionInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -3472,52 +2264,17 @@ func (a CreateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateMetastore{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateMetastore) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateMetastore) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateMetastore) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateMetastore) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateMetastore +// only implements ToObjectValue() and Type(). +func (o CreateMetastore) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "region": o.Region, + "storage_root": o.StorageRoot, + }) } // Type implements basetypes.ObjectValuable. @@ -3559,52 +2316,17 @@ func (a CreateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateMetastoreAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateMetastoreAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateMetastoreAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateMetastoreAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateMetastoreAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateMetastoreAssignment +// only implements ToObjectValue() and Type(). +func (o CreateMetastoreAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default_catalog_name": o.DefaultCatalogName, + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -3685,52 +2407,28 @@ func (a CreateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateMonitor{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateMonitor) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateMonitor) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateMonitor) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateMonitor) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateMonitor) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateMonitor +// only implements ToObjectValue() and Type(). +func (o CreateMonitor) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateMonitor) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "assets_dir": o.AssetsDir, + "baseline_table_name": o.BaselineTableName, + "custom_metrics": o.CustomMetrics, + "data_classification_config": o.DataClassificationConfig, + "inference_log": o.InferenceLog, + "notifications": o.Notifications, + "output_schema_name": o.OutputSchemaName, + "schedule": o.Schedule, + "skip_builtin_dashboard": o.SkipBuiltinDashboard, + "slicing_exprs": o.SlicingExprs, + "snapshot": o.Snapshot, + "table_name": o.TableName, + "time_series": o.TimeSeries, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -3796,52 +2494,15 @@ func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateOnlineTableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateOnlineTableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateOnlineTableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateOnlineTableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateOnlineTableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateOnlineTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateOnlineTableRequest +// only implements ToObjectValue() and Type(). +func (o CreateOnlineTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateOnlineTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table": o.Table, + }) } // Type implements basetypes.ObjectValuable. @@ -3886,52 +2547,19 @@ func (a CreateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRegisteredModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRegisteredModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRegisteredModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRegisteredModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRegisteredModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRegisteredModelRequest +// only implements ToObjectValue() and Type(). +func (o CreateRegisteredModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "comment": o.Comment, + "name": o.Name, + "schema_name": o.SchemaName, + "storage_location": o.StorageLocation, + }) } // Type implements basetypes.ObjectValuable. @@ -3967,52 +2595,13 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateResponse +// only implements ToObjectValue() and Type(). +func (o CreateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4054,52 +2643,19 @@ func (a CreateSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateSchema{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateSchema) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateSchema) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateSchema) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateSchema) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateSchema) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateSchema +// only implements ToObjectValue() and Type(). +func (o CreateSchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateSchema) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "comment": o.Comment, + "name": o.Name, + "properties": o.Properties, + "storage_root": o.StorageRoot, + }) } // Type implements basetypes.ObjectValuable. @@ -4162,52 +2718,23 @@ func (a CreateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateStorageCredential{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateStorageCredential) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateStorageCredential) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateStorageCredential) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateStorageCredential) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateStorageCredential +// only implements ToObjectValue() and Type(). +func (o CreateStorageCredential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "cloudflare_api_token": o.CloudflareApiToken, + "comment": o.Comment, + "databricks_gcp_service_account": o.DatabricksGcpServiceAccount, + "name": o.Name, + "read_only": o.ReadOnly, + "skip_validation": o.SkipValidation, + }) } // Type implements basetypes.ObjectValuable. @@ -4265,52 +2792,16 @@ func (a CreateTableConstraint) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateTableConstraint{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateTableConstraint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateTableConstraint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateTableConstraint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateTableConstraint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateTableConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateTableConstraint +// only implements ToObjectValue() and Type(). +func (o CreateTableConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateTableConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "constraint": o.Constraint, + "full_name_arg": o.FullNameArg, + }) } // Type implements basetypes.ObjectValuable. @@ -4357,52 +2848,20 @@ func (a CreateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateVolumeRequestContent{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateVolumeRequestContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateVolumeRequestContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateVolumeRequestContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateVolumeRequestContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateVolumeRequestContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateVolumeRequestContent +// only implements ToObjectValue() and Type(). +func (o CreateVolumeRequestContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateVolumeRequestContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "comment": o.Comment, + "name": o.Name, + "schema_name": o.SchemaName, + "storage_location": o.StorageLocation, + "volume_type": o.VolumeType, + }) } // Type implements basetypes.ObjectValuable. @@ -4481,52 +2940,31 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CredentialInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o CredentialInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CredentialInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CredentialInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CredentialInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CredentialInfo +// only implements ToObjectValue() and Type(). +func (o CredentialInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "full_name": o.FullName, + "id": o.Id, + "isolation_mode": o.IsolationMode, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "purpose": o.Purpose, + "read_only": o.ReadOnly, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "used_for_managed_storage": o.UsedForManagedStorage, + }) } // Type implements basetypes.ObjectValuable. @@ -4584,52 +3022,16 @@ func (a CredentialValidationResult) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CredentialValidationResult{} - -// Equal implements basetypes.ObjectValuable. -func (o CredentialValidationResult) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CredentialValidationResult) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CredentialValidationResult) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CredentialValidationResult) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CredentialValidationResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CredentialValidationResult +// only implements ToObjectValue() and Type(). +func (o CredentialValidationResult) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CredentialValidationResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + "result": o.Result, + }) } // Type implements basetypes.ObjectValuable. @@ -4667,52 +3069,15 @@ func (a CurrentWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CurrentWorkspaceBindings{} - -// Equal implements basetypes.ObjectValuable. -func (o CurrentWorkspaceBindings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CurrentWorkspaceBindings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CurrentWorkspaceBindings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CurrentWorkspaceBindings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CurrentWorkspaceBindings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CurrentWorkspaceBindings +// only implements ToObjectValue() and Type(). +func (o CurrentWorkspaceBindings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CurrentWorkspaceBindings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspaces": o.Workspaces, + }) } // Type implements basetypes.ObjectValuable. @@ -4746,52 +3111,13 @@ func (a DatabricksGcpServiceAccountRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DatabricksGcpServiceAccountRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DatabricksGcpServiceAccountRequest +// only implements ToObjectValue() and Type(). +func (o DatabricksGcpServiceAccountRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4826,52 +3152,16 @@ func (a DatabricksGcpServiceAccountResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DatabricksGcpServiceAccountResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DatabricksGcpServiceAccountResponse +// only implements ToObjectValue() and Type(). +func (o DatabricksGcpServiceAccountResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DatabricksGcpServiceAccountResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + "email": o.Email, + }) } // Type implements basetypes.ObjectValuable. @@ -4909,52 +3199,16 @@ func (a DeleteAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountMetastoreAssignmentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreAssignmentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreAssignmentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreAssignmentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreAssignmentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountMetastoreAssignmentRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountMetastoreAssignmentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -4992,52 +3246,16 @@ func (a DeleteAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountMetastoreRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountMetastoreRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountMetastoreRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "metastore_id": o.MetastoreId, + }) } // Type implements basetypes.ObjectValuable. @@ -5078,52 +3296,17 @@ func (a DeleteAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountStorageCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountStorageCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountStorageCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountStorageCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountStorageCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountStorageCredentialRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountStorageCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "metastore_id": o.MetastoreId, + "storage_credential_name": o.StorageCredentialName, + }) } // Type implements basetypes.ObjectValuable. @@ -5162,52 +3345,16 @@ func (a DeleteAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAliasRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAliasRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAliasRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAliasRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAliasRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAliasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAliasRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAliasRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAliasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alias": o.Alias, + "full_name": o.FullName, + }) } // Type implements basetypes.ObjectValuable. @@ -5240,52 +3387,13 @@ func (a DeleteAliasResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAliasResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAliasResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAliasResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAliasResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAliasResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAliasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAliasResponse +// only implements ToObjectValue() and Type(). +func (o DeleteAliasResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAliasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5320,52 +3428,16 @@ func (a DeleteCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCatalogRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCatalogRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCatalogRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCatalogRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCatalogRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCatalogRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCatalogRequest +// only implements ToObjectValue() and Type(). +func (o DeleteCatalogRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCatalogRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5401,52 +3473,15 @@ func (a DeleteConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteConnectionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteConnectionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteConnectionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteConnectionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteConnectionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteConnectionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteConnectionRequest +// only implements ToObjectValue() and Type(). +func (o DeleteConnectionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteConnectionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5485,61 +3520,25 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCredentialRequest{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCredentialRequest +// only implements ToObjectValue() and Type(). +func (o DeleteCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "force": o.Force, + "name_arg": o.NameArg, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "force": types.BoolType, - "name_arg": types.StringType, - }, +// Type implements basetypes.ObjectValuable. +func (o DeleteCredentialRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "force": types.BoolType, + "name_arg": types.StringType, + }, } } @@ -5563,52 +3562,13 @@ func (a DeleteCredentialResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCredentialResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCredentialResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCredentialResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCredentialResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCredentialResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCredentialResponse +// only implements ToObjectValue() and Type(). +func (o DeleteCredentialResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5643,52 +3603,16 @@ func (a DeleteExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExternalLocationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExternalLocationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExternalLocationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExternalLocationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExternalLocationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExternalLocationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExternalLocationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteExternalLocationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExternalLocationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5727,52 +3651,16 @@ func (a DeleteFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteFunctionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteFunctionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteFunctionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteFunctionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteFunctionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteFunctionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteFunctionRequest +// only implements ToObjectValue() and Type(). +func (o DeleteFunctionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteFunctionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5810,52 +3698,16 @@ func (a DeleteMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteMetastoreRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteMetastoreRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteMetastoreRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteMetastoreRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteMetastoreRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteMetastoreRequest +// only implements ToObjectValue() and Type(). +func (o DeleteMetastoreRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -5893,52 +3745,16 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o DeleteModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -5974,52 +3790,15 @@ func (a DeleteOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteOnlineTableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteOnlineTableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteOnlineTableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteOnlineTableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteOnlineTableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteOnlineTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteOnlineTableRequest +// only implements ToObjectValue() and Type(). +func (o DeleteOnlineTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteOnlineTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -6054,52 +3833,15 @@ func (a DeleteQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteQualityMonitorRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteQualityMonitorRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteQualityMonitorRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteQualityMonitorRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteQualityMonitorRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteQualityMonitorRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteQualityMonitorRequest +// only implements ToObjectValue() and Type(). +func (o DeleteQualityMonitorRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteQualityMonitorRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_name": o.TableName, + }) } // Type implements basetypes.ObjectValuable. @@ -6134,52 +3876,15 @@ func (a DeleteRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRegisteredModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRegisteredModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRegisteredModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRegisteredModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRegisteredModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRegisteredModelRequest +// only implements ToObjectValue() and Type(). +func (o DeleteRegisteredModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + }) } // Type implements basetypes.ObjectValuable. @@ -6211,52 +3916,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -6291,52 +3957,16 @@ func (a DeleteSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteSchemaRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteSchemaRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteSchemaRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteSchemaRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteSchemaRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteSchemaRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteSchemaRequest +// only implements ToObjectValue() and Type(). +func (o DeleteSchemaRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteSchemaRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "full_name": o.FullName, + }) } // Type implements basetypes.ObjectValuable. @@ -6375,52 +4005,16 @@ func (a DeleteStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteStorageCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteStorageCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteStorageCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteStorageCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteStorageCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteStorageCredentialRequest +// only implements ToObjectValue() and Type(). +func (o DeleteStorageCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "force": o.Force, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -6462,52 +4056,17 @@ func (a DeleteTableConstraintRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTableConstraintRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTableConstraintRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTableConstraintRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTableConstraintRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTableConstraintRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTableConstraintRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTableConstraintRequest +// only implements ToObjectValue() and Type(). +func (o DeleteTableConstraintRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTableConstraintRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cascade": o.Cascade, + "constraint_name": o.ConstraintName, + "full_name": o.FullName, + }) } // Type implements basetypes.ObjectValuable. @@ -6544,52 +4103,15 @@ func (a DeleteTableRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTableRequest +// only implements ToObjectValue() and Type(). +func (o DeleteTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + }) } // Type implements basetypes.ObjectValuable. @@ -6624,52 +4146,15 @@ func (a DeleteVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteVolumeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteVolumeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteVolumeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteVolumeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteVolumeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteVolumeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteVolumeRequest +// only implements ToObjectValue() and Type(). +func (o DeleteVolumeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteVolumeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -6708,52 +4193,15 @@ func (a DeltaRuntimePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeltaRuntimePropertiesKvPairs{} - -// Equal implements basetypes.ObjectValuable. -func (o DeltaRuntimePropertiesKvPairs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeltaRuntimePropertiesKvPairs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeltaRuntimePropertiesKvPairs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeltaRuntimePropertiesKvPairs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeltaRuntimePropertiesKvPairs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeltaRuntimePropertiesKvPairs +// only implements ToObjectValue() and Type(). +func (o DeltaRuntimePropertiesKvPairs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeltaRuntimePropertiesKvPairs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "delta_runtime_properties": o.DeltaRuntimeProperties, + }) } // Type implements basetypes.ObjectValuable. @@ -6796,52 +4244,16 @@ func (a Dependency) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Dependency{} - -// Equal implements basetypes.ObjectValuable. -func (o Dependency) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Dependency) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Dependency) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Dependency) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Dependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Dependency +// only implements ToObjectValue() and Type(). +func (o Dependency) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Dependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "function": o.Function, + "table": o.Table, + }) } // Type implements basetypes.ObjectValuable. @@ -6883,52 +4295,15 @@ func (a DependencyList) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DependencyList{} - -// Equal implements basetypes.ObjectValuable. -func (o DependencyList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DependencyList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DependencyList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DependencyList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DependencyList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DependencyList +// only implements ToObjectValue() and Type(). +func (o DependencyList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DependencyList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dependencies": o.Dependencies, + }) } // Type implements basetypes.ObjectValuable. @@ -6967,52 +4342,16 @@ func (a DisableRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DisableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DisableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DisableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DisableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DisableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DisableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DisableRequest +// only implements ToObjectValue() and Type(). +func (o DisableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DisableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + "schema_name": o.SchemaName, + }) } // Type implements basetypes.ObjectValuable. @@ -7045,52 +4384,13 @@ func (a DisableResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DisableResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DisableResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DisableResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DisableResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DisableResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DisableResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DisableResponse +// only implements ToObjectValue() and Type(). +func (o DisableResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DisableResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7125,52 +4425,15 @@ func (a EffectivePermissionsList) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EffectivePermissionsList{} - -// Equal implements basetypes.ObjectValuable. -func (o EffectivePermissionsList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EffectivePermissionsList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EffectivePermissionsList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EffectivePermissionsList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EffectivePermissionsList +// only implements ToObjectValue() and Type(). +func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EffectivePermissionsList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "privilege_assignments": o.PrivilegeAssignments, + }) } // Type implements basetypes.ObjectValuable. @@ -7213,52 +4476,17 @@ func (a EffectivePredictiveOptimizationFlag) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EffectivePredictiveOptimizationFlag{} - -// Equal implements basetypes.ObjectValuable. -func (o EffectivePredictiveOptimizationFlag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EffectivePredictiveOptimizationFlag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EffectivePredictiveOptimizationFlag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EffectivePredictiveOptimizationFlag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EffectivePredictiveOptimizationFlag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EffectivePredictiveOptimizationFlag +// only implements ToObjectValue() and Type(). +func (o EffectivePredictiveOptimizationFlag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EffectivePredictiveOptimizationFlag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited_from_name": o.InheritedFromName, + "inherited_from_type": o.InheritedFromType, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -7302,52 +4530,17 @@ func (a EffectivePrivilege) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EffectivePrivilege{} - -// Equal implements basetypes.ObjectValuable. -func (o EffectivePrivilege) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EffectivePrivilege) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EffectivePrivilege) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EffectivePrivilege) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EffectivePrivilege) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EffectivePrivilege +// only implements ToObjectValue() and Type(). +func (o EffectivePrivilege) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EffectivePrivilege) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited_from_name": o.InheritedFromName, + "inherited_from_type": o.InheritedFromType, + "privilege": o.Privilege, + }) } // Type implements basetypes.ObjectValuable. @@ -7388,52 +4581,16 @@ func (a EffectivePrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EffectivePrivilegeAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o EffectivePrivilegeAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EffectivePrivilegeAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EffectivePrivilegeAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EffectivePrivilegeAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EffectivePrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EffectivePrivilegeAssignment +// only implements ToObjectValue() and Type(). +func (o EffectivePrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EffectivePrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principal": o.Principal, + "privileges": o.Privileges, + }) } // Type implements basetypes.ObjectValuable. @@ -7473,52 +4630,16 @@ func (a EnableRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o EnableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnableRequest +// only implements ToObjectValue() and Type(). +func (o EnableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + "schema_name": o.SchemaName, + }) } // Type implements basetypes.ObjectValuable. @@ -7551,52 +4672,13 @@ func (a EnableResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnableResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EnableResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnableResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnableResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnableResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnableResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnableResponse +// only implements ToObjectValue() and Type(). +func (o EnableResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnableResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7624,59 +4706,22 @@ func (newState *EncryptionDetails) SyncEffectiveFieldsDuringRead(existingState E // retrieve the type information of the elements in complex fields at runtime. The values of the map // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a EncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "sse_encryption_details": reflect.TypeOf(SseEncryptionDetails{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EncryptionDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o EncryptionDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EncryptionDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EncryptionDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EncryptionDetails) String() string { - return fmt.Sprintf("%#v", o) +// SDK values. +func (a EncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "sse_encryption_details": reflect.TypeOf(SseEncryptionDetails{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o EncryptionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EncryptionDetails +// only implements ToObjectValue() and Type(). +func (o EncryptionDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EncryptionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "sse_encryption_details": o.SseEncryptionDetails, + }) } // Type implements basetypes.ObjectValuable. @@ -7713,52 +4758,15 @@ func (a ExistsRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExistsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExistsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExistsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExistsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExistsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExistsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExistsRequest +// only implements ToObjectValue() and Type(). +func (o ExistsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExistsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + }) } // Type implements basetypes.ObjectValuable. @@ -7831,52 +4839,31 @@ func (a ExternalLocationInfo) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExternalLocationInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ExternalLocationInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExternalLocationInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExternalLocationInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExternalLocationInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExternalLocationInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExternalLocationInfo +// only implements ToObjectValue() and Type(). +func (o ExternalLocationInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExternalLocationInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_point": o.AccessPoint, + "browse_only": o.BrowseOnly, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "credential_id": o.CredentialId, + "credential_name": o.CredentialName, + "encryption_details": o.EncryptionDetails, + "fallback": o.Fallback, + "isolation_mode": o.IsolationMode, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "read_only": o.ReadOnly, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -7937,52 +4924,16 @@ func (a FailedStatus) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FailedStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o FailedStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FailedStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FailedStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FailedStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FailedStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FailedStatus +// only implements ToObjectValue() and Type(). +func (o FailedStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FailedStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "last_processed_commit_version": o.LastProcessedCommitVersion, + "timestamp": o.Timestamp, + }) } // Type implements basetypes.ObjectValuable. @@ -8026,52 +4977,18 @@ func (a ForeignKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ForeignKeyConstraint{} - -// Equal implements basetypes.ObjectValuable. -func (o ForeignKeyConstraint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ForeignKeyConstraint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ForeignKeyConstraint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ForeignKeyConstraint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ForeignKeyConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ForeignKeyConstraint +// only implements ToObjectValue() and Type(). +func (o ForeignKeyConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ForeignKeyConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "child_columns": o.ChildColumns, + "name": o.Name, + "parent_columns": o.ParentColumns, + "parent_table": o.ParentTable, + }) } // Type implements basetypes.ObjectValuable. @@ -8114,52 +5031,15 @@ func (a FunctionDependency) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FunctionDependency{} - -// Equal implements basetypes.ObjectValuable. -func (o FunctionDependency) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FunctionDependency) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FunctionDependency) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FunctionDependency) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FunctionDependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FunctionDependency +// only implements ToObjectValue() and Type(). +func (o FunctionDependency) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FunctionDependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "function_full_name": o.FunctionFullName, + }) } // Type implements basetypes.ObjectValuable. @@ -8262,52 +5142,44 @@ func (a FunctionInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FunctionInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o FunctionInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FunctionInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FunctionInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FunctionInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FunctionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FunctionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FunctionInfo +// only implements ToObjectValue() and Type(). +func (o FunctionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "browse_only": o.BrowseOnly, + "catalog_name": o.CatalogName, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "data_type": o.DataType, + "external_language": o.ExternalLanguage, + "external_name": o.ExternalName, + "full_data_type": o.FullDataType, + "full_name": o.FullName, + "function_id": o.FunctionId, + "input_params": o.InputParams, + "is_deterministic": o.IsDeterministic, + "is_null_call": o.IsNullCall, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "parameter_style": o.ParameterStyle, + "properties": o.Properties, + "return_params": o.ReturnParams, + "routine_body": o.RoutineBody, + "routine_definition": o.RoutineDefinition, + "routine_dependencies": o.RoutineDependencies, + "schema_name": o.SchemaName, + "security_type": o.SecurityType, + "specific_name": o.SpecificName, + "sql_data_access": o.SqlDataAccess, + "sql_path": o.SqlPath, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -8398,52 +5270,26 @@ func (a FunctionParameterInfo) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FunctionParameterInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o FunctionParameterInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FunctionParameterInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FunctionParameterInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FunctionParameterInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FunctionParameterInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FunctionParameterInfo +// only implements ToObjectValue() and Type(). +func (o FunctionParameterInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FunctionParameterInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "parameter_default": o.ParameterDefault, + "parameter_mode": o.ParameterMode, + "parameter_type": o.ParameterType, + "position": o.Position, + "type_interval_type": o.TypeIntervalType, + "type_json": o.TypeJson, + "type_name": o.TypeName, + "type_precision": o.TypePrecision, + "type_scale": o.TypeScale, + "type_text": o.TypeText, + }) } // Type implements basetypes.ObjectValuable. @@ -8491,52 +5337,15 @@ func (a FunctionParameterInfos) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FunctionParameterInfos{} - -// Equal implements basetypes.ObjectValuable. -func (o FunctionParameterInfos) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FunctionParameterInfos) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FunctionParameterInfos) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FunctionParameterInfos) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FunctionParameterInfos +// only implements ToObjectValue() and Type(). +func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FunctionParameterInfos) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -8573,52 +5382,15 @@ func (a GcpOauthToken) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpOauthToken{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpOauthToken) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpOauthToken) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpOauthToken) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpOauthToken) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpOauthToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpOauthToken +// only implements ToObjectValue() and Type(). +func (o GcpOauthToken) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpOauthToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "oauth_token": o.OauthToken, + }) } // Type implements basetypes.ObjectValuable. @@ -8657,52 +5429,17 @@ func (a GcpServiceAccountKey) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpServiceAccountKey{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpServiceAccountKey) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpServiceAccountKey) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpServiceAccountKey) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpServiceAccountKey) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpServiceAccountKey) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpServiceAccountKey +// only implements ToObjectValue() and Type(). +func (o GcpServiceAccountKey) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpServiceAccountKey) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "email": o.Email, + "private_key": o.PrivateKey, + "private_key_id": o.PrivateKeyId, + }) } // Type implements basetypes.ObjectValuable. @@ -8743,52 +5480,15 @@ func (a GenerateTemporaryServiceCredentialAzureOptions) GetComplexFieldTypes(ctx } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenerateTemporaryServiceCredentialAzureOptions{} - -// Equal implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialAzureOptions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialAzureOptions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialAzureOptions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialAzureOptions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialAzureOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenerateTemporaryServiceCredentialAzureOptions +// only implements ToObjectValue() and Type(). +func (o GenerateTemporaryServiceCredentialAzureOptions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialAzureOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "resources": o.Resources, + }) } // Type implements basetypes.ObjectValuable. @@ -8829,52 +5529,16 @@ func (a GenerateTemporaryServiceCredentialRequest) GetComplexFieldTypes(ctx cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenerateTemporaryServiceCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenerateTemporaryServiceCredentialRequest +// only implements ToObjectValue() and Type(). +func (o GenerateTemporaryServiceCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryServiceCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "azure_options": o.AzureOptions, + "credential_name": o.CredentialName, + }) } // Type implements basetypes.ObjectValuable. @@ -8915,52 +5579,16 @@ func (a GenerateTemporaryTableCredentialRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenerateTemporaryTableCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenerateTemporaryTableCredentialRequest +// only implements ToObjectValue() and Type(). +func (o GenerateTemporaryTableCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "operation": o.Operation, + "table_id": o.TableId, + }) } // Type implements basetypes.ObjectValuable. @@ -9020,52 +5648,21 @@ func (a GenerateTemporaryTableCredentialResponse) GetComplexFieldTypes(ctx conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenerateTemporaryTableCredentialResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenerateTemporaryTableCredentialResponse +// only implements ToObjectValue() and Type(). +func (o GenerateTemporaryTableCredentialResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenerateTemporaryTableCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_temp_credentials": o.AwsTempCredentials, + "azure_aad": o.AzureAad, + "azure_user_delegation_sas": o.AzureUserDelegationSas, + "expiration_time": o.ExpirationTime, + "gcp_oauth_token": o.GcpOauthToken, + "r2_temp_credentials": o.R2TempCredentials, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -9116,52 +5713,15 @@ func (a GetAccountMetastoreAssignmentRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountMetastoreAssignmentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountMetastoreAssignmentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountMetastoreAssignmentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountMetastoreAssignmentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountMetastoreAssignmentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountMetastoreAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountMetastoreAssignmentRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountMetastoreAssignmentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountMetastoreAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -9196,52 +5756,15 @@ func (a GetAccountMetastoreRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountMetastoreRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountMetastoreRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountMetastoreRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountMetastoreRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountMetastoreRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountMetastoreRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountMetastoreRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + }) } // Type implements basetypes.ObjectValuable. @@ -9278,52 +5801,16 @@ func (a GetAccountStorageCredentialRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountStorageCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountStorageCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountStorageCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountStorageCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountStorageCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountStorageCredentialRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountStorageCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + "storage_credential_name": o.StorageCredentialName, + }) } // Type implements basetypes.ObjectValuable. @@ -9359,52 +5846,15 @@ func (a GetArtifactAllowlistRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetArtifactAllowlistRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetArtifactAllowlistRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetArtifactAllowlistRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetArtifactAllowlistRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetArtifactAllowlistRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetArtifactAllowlistRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetArtifactAllowlistRequest +// only implements ToObjectValue() and Type(). +func (o GetArtifactAllowlistRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetArtifactAllowlistRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_type": o.ArtifactType, + }) } // Type implements basetypes.ObjectValuable. @@ -9445,57 +5895,23 @@ func (newState *GetBindingsRequest) SyncEffectiveFieldsDuringRead(existingState // retrieve the type information of the elements in complex fields at runtime. The values of the map // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a GetBindingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetBindingsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetBindingsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetBindingsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetBindingsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetBindingsRequest) String() string { - return fmt.Sprintf("%#v", o) +// SDK values. +func (a GetBindingsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetBindingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetBindingsRequest +// only implements ToObjectValue() and Type(). +func (o GetBindingsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetBindingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + "securable_name": o.SecurableName, + "securable_type": o.SecurableType, + }) } // Type implements basetypes.ObjectValuable. @@ -9538,52 +5954,17 @@ func (a GetByAliasRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetByAliasRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetByAliasRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetByAliasRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetByAliasRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetByAliasRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetByAliasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetByAliasRequest +// only implements ToObjectValue() and Type(). +func (o GetByAliasRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetByAliasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alias": o.Alias, + "full_name": o.FullName, + "include_aliases": o.IncludeAliases, + }) } // Type implements basetypes.ObjectValuable. @@ -9623,52 +6004,16 @@ func (a GetCatalogRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCatalogRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCatalogRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCatalogRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCatalogRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCatalogRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCatalogRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCatalogRequest +// only implements ToObjectValue() and Type(). +func (o GetCatalogRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCatalogRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_browse": o.IncludeBrowse, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -9704,52 +6049,15 @@ func (a GetConnectionRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetConnectionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetConnectionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetConnectionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetConnectionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetConnectionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetConnectionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetConnectionRequest +// only implements ToObjectValue() and Type(). +func (o GetConnectionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetConnectionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -9784,52 +6092,15 @@ func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCredentialRequest +// only implements ToObjectValue() and Type(). +func (o GetCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name_arg": o.NameArg, + }) } // Type implements basetypes.ObjectValuable. @@ -9869,52 +6140,17 @@ func (a GetEffectiveRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEffectiveRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEffectiveRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEffectiveRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEffectiveRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEffectiveRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEffectiveRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEffectiveRequest +// only implements ToObjectValue() and Type(). +func (o GetEffectiveRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEffectiveRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "principal": o.Principal, + "securable_type": o.SecurableType, + }) } // Type implements basetypes.ObjectValuable. @@ -9954,52 +6190,16 @@ func (a GetExternalLocationRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExternalLocationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExternalLocationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExternalLocationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExternalLocationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExternalLocationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExternalLocationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExternalLocationRequest +// only implements ToObjectValue() and Type(). +func (o GetExternalLocationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExternalLocationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_browse": o.IncludeBrowse, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -10039,52 +6239,16 @@ func (a GetFunctionRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetFunctionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetFunctionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetFunctionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetFunctionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetFunctionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetFunctionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetFunctionRequest +// only implements ToObjectValue() and Type(). +func (o GetFunctionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetFunctionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_browse": o.IncludeBrowse, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -10125,52 +6289,17 @@ func (a GetGrantRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetGrantRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetGrantRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetGrantRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetGrantRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetGrantRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetGrantRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetGrantRequest +// only implements ToObjectValue() and Type(). +func (o GetGrantRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetGrantRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "principal": o.Principal, + "securable_type": o.SecurableType, + }) } // Type implements basetypes.ObjectValuable. @@ -10207,52 +6336,15 @@ func (a GetMetastoreRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetMetastoreRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetMetastoreRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetMetastoreRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetMetastoreRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetMetastoreRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetMetastoreRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetMetastoreRequest +// only implements ToObjectValue() and Type(). +func (o GetMetastoreRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetMetastoreRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -10326,52 +6418,33 @@ func (a GetMetastoreSummaryResponse) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetMetastoreSummaryResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetMetastoreSummaryResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetMetastoreSummaryResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetMetastoreSummaryResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetMetastoreSummaryResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetMetastoreSummaryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetMetastoreSummaryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetMetastoreSummaryResponse +// only implements ToObjectValue() and Type(). +func (o GetMetastoreSummaryResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "cloud": o.Cloud, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "default_data_access_config_id": o.DefaultDataAccessConfigId, + "delta_sharing_organization_name": o.DeltaSharingOrganizationName, + "delta_sharing_recipient_token_lifetime_in_seconds": o.DeltaSharingRecipientTokenLifetimeInSeconds, + "delta_sharing_scope": o.DeltaSharingScope, + "external_access_enabled": o.ExternalAccessEnabled, + "global_metastore_id": o.GlobalMetastoreId, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "privilege_model_version": o.PrivilegeModelVersion, + "region": o.Region, + "storage_root": o.StorageRoot, + "storage_root_credential_id": o.StorageRootCredentialId, + "storage_root_credential_name": o.StorageRootCredentialName, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -10432,52 +6505,18 @@ func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o GetModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "include_aliases": o.IncludeAliases, + "include_browse": o.IncludeBrowse, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -10515,52 +6554,15 @@ func (a GetOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetOnlineTableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetOnlineTableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetOnlineTableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetOnlineTableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetOnlineTableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetOnlineTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetOnlineTableRequest +// only implements ToObjectValue() and Type(). +func (o GetOnlineTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetOnlineTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -10595,52 +6597,15 @@ func (a GetQualityMonitorRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetQualityMonitorRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetQualityMonitorRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetQualityMonitorRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetQualityMonitorRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetQualityMonitorRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetQualityMonitorRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetQualityMonitorRequest +// only implements ToObjectValue() and Type(). +func (o GetQualityMonitorRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetQualityMonitorRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_name": o.TableName, + }) } // Type implements basetypes.ObjectValuable. @@ -10681,52 +6646,17 @@ func (a GetQuotaRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetQuotaRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetQuotaRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetQuotaRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetQuotaRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetQuotaRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetQuotaRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetQuotaRequest +// only implements ToObjectValue() and Type(). +func (o GetQuotaRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetQuotaRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "parent_full_name": o.ParentFullName, + "parent_securable_type": o.ParentSecurableType, + "quota_name": o.QuotaName, + }) } // Type implements basetypes.ObjectValuable. @@ -10764,52 +6694,15 @@ func (a GetQuotaResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetQuotaResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetQuotaResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetQuotaResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetQuotaResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetQuotaResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetQuotaResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetQuotaResponse +// only implements ToObjectValue() and Type(). +func (o GetQuotaResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetQuotaResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "quota_info": o.QuotaInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -10848,52 +6741,16 @@ func (a GetRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRefreshRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRefreshRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRefreshRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRefreshRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRefreshRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRefreshRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRefreshRequest +// only implements ToObjectValue() and Type(). +func (o GetRefreshRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRefreshRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "refresh_id": o.RefreshId, + "table_name": o.TableName, + }) } // Type implements basetypes.ObjectValuable. @@ -10934,52 +6791,17 @@ func (a GetRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRegisteredModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRegisteredModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRegisteredModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRegisteredModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRegisteredModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRegisteredModelRequest +// only implements ToObjectValue() and Type(). +func (o GetRegisteredModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "include_aliases": o.IncludeAliases, + "include_browse": o.IncludeBrowse, + }) } // Type implements basetypes.ObjectValuable. @@ -11019,52 +6841,16 @@ func (a GetSchemaRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetSchemaRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetSchemaRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetSchemaRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetSchemaRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetSchemaRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetSchemaRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetSchemaRequest +// only implements ToObjectValue() and Type(). +func (o GetSchemaRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetSchemaRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "include_browse": o.IncludeBrowse, + }) } // Type implements basetypes.ObjectValuable. @@ -11093,59 +6879,22 @@ func (newState *GetStorageCredentialRequest) SyncEffectiveFieldsDuringRead(exist // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to // retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a GetStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStorageCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStorageCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStorageCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStorageCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStorageCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a GetStorageCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStorageCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStorageCredentialRequest +// only implements ToObjectValue() and Type(). +func (o GetStorageCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStorageCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -11187,52 +6936,18 @@ func (a GetTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetTableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetTableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetTableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetTableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetTableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetTableRequest +// only implements ToObjectValue() and Type(). +func (o GetTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "include_browse": o.IncludeBrowse, + "include_delta_metadata": o.IncludeDeltaMetadata, + "include_manifest_capabilities": o.IncludeManifestCapabilities, + }) } // Type implements basetypes.ObjectValuable. @@ -11270,52 +6985,15 @@ func (a GetWorkspaceBindingRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceBindingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceBindingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceBindingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceBindingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceBindingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceBindingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceBindingRequest +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceBindingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceBindingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -11350,52 +7028,15 @@ func (a ListAccountMetastoreAssignmentsRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountMetastoreAssignmentsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountMetastoreAssignmentsRequest +// only implements ToObjectValue() and Type(). +func (o ListAccountMetastoreAssignmentsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + }) } // Type implements basetypes.ObjectValuable. @@ -11431,52 +7072,15 @@ func (a ListAccountMetastoreAssignmentsResponse) GetComplexFieldTypes(ctx contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountMetastoreAssignmentsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountMetastoreAssignmentsResponse +// only implements ToObjectValue() and Type(). +func (o ListAccountMetastoreAssignmentsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountMetastoreAssignmentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_ids": o.WorkspaceIds, + }) } // Type implements basetypes.ObjectValuable. @@ -11513,52 +7117,15 @@ func (a ListAccountStorageCredentialsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountStorageCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountStorageCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o ListAccountStorageCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + }) } // Type implements basetypes.ObjectValuable. @@ -11594,52 +7161,15 @@ func (a ListAccountStorageCredentialsResponse) GetComplexFieldTypes(ctx context. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountStorageCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountStorageCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountStorageCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "storage_credentials": o.StorageCredentials, + }) } // Type implements basetypes.ObjectValuable. @@ -11689,52 +7219,17 @@ func (a ListCatalogsRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListCatalogsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListCatalogsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListCatalogsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListCatalogsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListCatalogsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListCatalogsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListCatalogsRequest +// only implements ToObjectValue() and Type(). +func (o ListCatalogsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListCatalogsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11776,52 +7271,16 @@ func (a ListCatalogsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListCatalogsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListCatalogsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListCatalogsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListCatalogsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListCatalogsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListCatalogsResponse +// only implements ToObjectValue() and Type(). +func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListCatalogsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalogs": o.Catalogs, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11866,52 +7325,16 @@ func (a ListConnectionsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListConnectionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListConnectionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListConnectionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListConnectionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListConnectionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListConnectionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListConnectionsRequest +// only implements ToObjectValue() and Type(). +func (o ListConnectionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListConnectionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11952,52 +7375,16 @@ func (a ListConnectionsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListConnectionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListConnectionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListConnectionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListConnectionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListConnectionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListConnectionsResponse +// only implements ToObjectValue() and Type(). +func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListConnectionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "connections": o.Connections, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12043,52 +7430,17 @@ func (a ListCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o ListCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + "purpose": o.Purpose, + }) } // Type implements basetypes.ObjectValuable. @@ -12129,52 +7481,16 @@ func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credentials": o.Credentials, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12222,52 +7538,17 @@ func (a ListExternalLocationsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExternalLocationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExternalLocationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExternalLocationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExternalLocationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExternalLocationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExternalLocationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExternalLocationsRequest +// only implements ToObjectValue() and Type(). +func (o ListExternalLocationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExternalLocationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12309,52 +7590,16 @@ func (a ListExternalLocationsResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExternalLocationsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExternalLocationsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExternalLocationsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExternalLocationsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExternalLocationsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExternalLocationsResponse +// only implements ToObjectValue() and Type(). +func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExternalLocationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "external_locations": o.ExternalLocations, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12406,52 +7651,19 @@ func (a ListFunctionsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListFunctionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListFunctionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListFunctionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListFunctionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListFunctionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListFunctionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListFunctionsRequest +// only implements ToObjectValue() and Type(). +func (o ListFunctionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListFunctionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + "schema_name": o.SchemaName, + }) } // Type implements basetypes.ObjectValuable. @@ -12495,52 +7707,16 @@ func (a ListFunctionsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListFunctionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListFunctionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListFunctionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListFunctionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListFunctionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListFunctionsResponse +// only implements ToObjectValue() and Type(). +func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListFunctionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "functions": o.Functions, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12579,52 +7755,15 @@ func (a ListMetastoresResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListMetastoresResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListMetastoresResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListMetastoresResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListMetastoresResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListMetastoresResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListMetastoresResponse +// only implements ToObjectValue() and Type(). +func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListMetastoresResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastores": o.Metastores, + }) } // Type implements basetypes.ObjectValuable. @@ -12675,52 +7814,18 @@ func (a ListModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListModelVersionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListModelVersionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListModelVersionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListModelVersionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListModelVersionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListModelVersionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListModelVersionsRequest +// only implements ToObjectValue() and Type(). +func (o ListModelVersionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListModelVersionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12762,52 +7867,16 @@ func (a ListModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListModelVersionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListModelVersionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListModelVersionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListModelVersionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListModelVersionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListModelVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListModelVersionsResponse +// only implements ToObjectValue() and Type(). +func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "model_versions": o.ModelVersions, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12847,52 +7916,16 @@ func (a ListQuotasRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQuotasRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQuotasRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQuotasRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQuotasRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQuotasRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQuotasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQuotasRequest +// only implements ToObjectValue() and Type(). +func (o ListQuotasRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQuotasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12933,52 +7966,16 @@ func (a ListQuotasResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQuotasResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQuotasResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQuotasResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQuotasResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQuotasResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQuotasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQuotasResponse +// only implements ToObjectValue() and Type(). +func (o ListQuotasResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQuotasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "quotas": o.Quotas, + }) } // Type implements basetypes.ObjectValuable. @@ -13016,52 +8013,15 @@ func (a ListRefreshesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRefreshesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRefreshesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRefreshesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRefreshesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRefreshesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRefreshesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRefreshesRequest +// only implements ToObjectValue() and Type(). +func (o ListRefreshesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRefreshesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_name": o.TableName, + }) } // Type implements basetypes.ObjectValuable. @@ -13123,52 +8083,19 @@ func (a ListRegisteredModelsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRegisteredModelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRegisteredModelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRegisteredModelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRegisteredModelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRegisteredModelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRegisteredModelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRegisteredModelsRequest +// only implements ToObjectValue() and Type(). +func (o ListRegisteredModelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRegisteredModelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + "schema_name": o.SchemaName, + }) } // Type implements basetypes.ObjectValuable. @@ -13211,52 +8138,16 @@ func (a ListRegisteredModelsResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRegisteredModelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRegisteredModelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRegisteredModelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRegisteredModelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRegisteredModelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRegisteredModelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRegisteredModelsResponse +// only implements ToObjectValue() and Type(). +func (o ListRegisteredModelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRegisteredModelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "registered_models": o.RegisteredModels, + }) } // Type implements basetypes.ObjectValuable. @@ -13306,52 +8197,18 @@ func (a ListSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSchemasRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSchemasRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSchemasRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSchemasRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSchemasRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSchemasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSchemasRequest +// only implements ToObjectValue() and Type(). +func (o ListSchemasRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSchemasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -13394,52 +8251,16 @@ func (a ListSchemasResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSchemasResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSchemasResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSchemasResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSchemasResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSchemasResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSchemasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSchemasResponse +// only implements ToObjectValue() and Type(). +func (o ListSchemasResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSchemasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "schemas": o.Schemas, + }) } // Type implements basetypes.ObjectValuable. @@ -13484,52 +8305,16 @@ func (a ListStorageCredentialsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListStorageCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListStorageCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListStorageCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListStorageCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListStorageCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListStorageCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListStorageCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o ListStorageCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListStorageCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -13570,52 +8355,16 @@ func (a ListStorageCredentialsResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListStorageCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListStorageCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListStorageCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListStorageCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListStorageCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListStorageCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListStorageCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o ListStorageCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListStorageCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "storage_credentials": o.StorageCredentials, + }) } // Type implements basetypes.ObjectValuable. @@ -13671,52 +8420,20 @@ func (a ListSummariesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSummariesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSummariesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSummariesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSummariesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSummariesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSummariesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSummariesRequest +// only implements ToObjectValue() and Type(). +func (o ListSummariesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSummariesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "include_manifest_capabilities": o.IncludeManifestCapabilities, + "max_results": o.MaxResults, + "page_token": o.PageToken, + "schema_name_pattern": o.SchemaNamePattern, + "table_name_pattern": o.TableNamePattern, + }) } // Type implements basetypes.ObjectValuable. @@ -13765,52 +8482,17 @@ func (a ListSystemSchemasRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSystemSchemasRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSystemSchemasRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSystemSchemasRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSystemSchemasRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSystemSchemasRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSystemSchemasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSystemSchemasRequest +// only implements ToObjectValue() and Type(). +func (o ListSystemSchemasRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSystemSchemasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "metastore_id": o.MetastoreId, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -13852,52 +8534,16 @@ func (a ListSystemSchemasResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSystemSchemasResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSystemSchemasResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSystemSchemasResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSystemSchemasResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSystemSchemasResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSystemSchemasResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSystemSchemasResponse +// only implements ToObjectValue() and Type(). +func (o ListSystemSchemasResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSystemSchemasResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "schemas": o.Schemas, + }) } // Type implements basetypes.ObjectValuable. @@ -13940,52 +8586,16 @@ func (a ListTableSummariesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTableSummariesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTableSummariesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTableSummariesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTableSummariesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTableSummariesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTableSummariesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTableSummariesResponse +// only implements ToObjectValue() and Type(). +func (o ListTableSummariesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTableSummariesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "tables": o.Tables, + }) } // Type implements basetypes.ObjectValuable. @@ -14048,52 +8658,24 @@ func (a ListTablesRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTablesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTablesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTablesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTablesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTablesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTablesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTablesRequest +// only implements ToObjectValue() and Type(). +func (o ListTablesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTablesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "include_browse": o.IncludeBrowse, + "include_delta_metadata": o.IncludeDeltaMetadata, + "include_manifest_capabilities": o.IncludeManifestCapabilities, + "max_results": o.MaxResults, + "omit_columns": o.OmitColumns, + "omit_properties": o.OmitProperties, + "omit_username": o.OmitUsername, + "page_token": o.PageToken, + "schema_name": o.SchemaName, + }) } // Type implements basetypes.ObjectValuable. @@ -14142,52 +8724,16 @@ func (a ListTablesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTablesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTablesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTablesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTablesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTablesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTablesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTablesResponse +// only implements ToObjectValue() and Type(). +func (o ListTablesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTablesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "tables": o.Tables, + }) } // Type implements basetypes.ObjectValuable. @@ -14246,52 +8792,19 @@ func (a ListVolumesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListVolumesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListVolumesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListVolumesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListVolumesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListVolumesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListVolumesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListVolumesRequest +// only implements ToObjectValue() and Type(). +func (o ListVolumesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListVolumesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "include_browse": o.IncludeBrowse, + "max_results": o.MaxResults, + "page_token": o.PageToken, + "schema_name": o.SchemaName, + }) } // Type implements basetypes.ObjectValuable. @@ -14335,52 +8848,16 @@ func (a ListVolumesResponseContent) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListVolumesResponseContent{} - -// Equal implements basetypes.ObjectValuable. -func (o ListVolumesResponseContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListVolumesResponseContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListVolumesResponseContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListVolumesResponseContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListVolumesResponseContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListVolumesResponseContent +// only implements ToObjectValue() and Type(). +func (o ListVolumesResponseContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListVolumesResponseContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "volumes": o.Volumes, + }) } // Type implements basetypes.ObjectValuable. @@ -14421,52 +8898,17 @@ func (a MetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MetastoreAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o MetastoreAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MetastoreAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MetastoreAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MetastoreAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MetastoreAssignment +// only implements ToObjectValue() and Type(). +func (o MetastoreAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default_catalog_name": o.DefaultCatalogName, + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -14532,62 +8974,43 @@ func (newState *MetastoreInfo) SyncEffectiveFieldsDuringRead(existingState Metas } // GetComplexFieldTypes returns a map of the types of elements in complex fields in MetastoreInfo. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a MetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MetastoreInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o MetastoreInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MetastoreInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MetastoreInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MetastoreInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MetastoreInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a MetastoreInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MetastoreInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MetastoreInfo +// only implements ToObjectValue() and Type(). +func (o MetastoreInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "cloud": o.Cloud, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "default_data_access_config_id": o.DefaultDataAccessConfigId, + "delta_sharing_organization_name": o.DeltaSharingOrganizationName, + "delta_sharing_recipient_token_lifetime_in_seconds": o.DeltaSharingRecipientTokenLifetimeInSeconds, + "delta_sharing_scope": o.DeltaSharingScope, + "external_access_enabled": o.ExternalAccessEnabled, + "global_metastore_id": o.GlobalMetastoreId, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "privilege_model_version": o.PrivilegeModelVersion, + "region": o.Region, + "storage_root": o.StorageRoot, + "storage_root_credential_id": o.StorageRootCredentialId, + "storage_root_credential_name": o.StorageRootCredentialName, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -14690,52 +9113,33 @@ func (a ModelVersionInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelVersionInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelVersionInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelVersionInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelVersionInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelVersionInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelVersionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelVersionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelVersionInfo +// only implements ToObjectValue() and Type(). +func (o ModelVersionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "aliases": o.Aliases, + "browse_only": o.BrowseOnly, + "catalog_name": o.CatalogName, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "id": o.Id, + "metastore_id": o.MetastoreId, + "model_name": o.ModelName, + "model_version_dependencies": o.ModelVersionDependencies, + "run_id": o.RunId, + "run_workspace_id": o.RunWorkspaceId, + "schema_name": o.SchemaName, + "source": o.Source, + "status": o.Status, + "storage_location": o.StorageLocation, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -14798,52 +9202,17 @@ func (a MonitorCronSchedule) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorCronSchedule{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorCronSchedule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorCronSchedule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorCronSchedule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorCronSchedule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorCronSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorCronSchedule +// only implements ToObjectValue() and Type(). +func (o MonitorCronSchedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorCronSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pause_status": o.PauseStatus, + "quartz_cron_expression": o.QuartzCronExpression, + "timezone_id": o.TimezoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -14879,52 +9248,15 @@ func (a MonitorDataClassificationConfig) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorDataClassificationConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorDataClassificationConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorDataClassificationConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorDataClassificationConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorDataClassificationConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorDataClassificationConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorDataClassificationConfig +// only implements ToObjectValue() and Type(). +func (o MonitorDataClassificationConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorDataClassificationConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + }) } // Type implements basetypes.ObjectValuable. @@ -14961,52 +9293,15 @@ func (a MonitorDestination) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorDestination{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorDestination) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorDestination) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorDestination) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorDestination) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorDestination) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorDestination +// only implements ToObjectValue() and Type(). +func (o MonitorDestination) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorDestination) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "email_addresses": o.EmailAddresses, + }) } // Type implements basetypes.ObjectValuable. @@ -15070,52 +9365,21 @@ func (a MonitorInferenceLog) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorInferenceLog{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorInferenceLog) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorInferenceLog) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorInferenceLog) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorInferenceLog) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorInferenceLog) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorInferenceLog +// only implements ToObjectValue() and Type(). +func (o MonitorInferenceLog) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorInferenceLog) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "granularities": o.Granularities, + "label_col": o.LabelCol, + "model_id_col": o.ModelIdCol, + "prediction_col": o.PredictionCol, + "prediction_proba_col": o.PredictionProbaCol, + "problem_type": o.ProblemType, + "timestamp_col": o.TimestampCol, + }) } // Type implements basetypes.ObjectValuable. @@ -15213,52 +9477,32 @@ func (a MonitorInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorInfo +// only implements ToObjectValue() and Type(). +func (o MonitorInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "assets_dir": o.AssetsDir, + "baseline_table_name": o.BaselineTableName, + "custom_metrics": o.CustomMetrics, + "dashboard_id": o.DashboardId, + "data_classification_config": o.DataClassificationConfig, + "drift_metrics_table_name": o.DriftMetricsTableName, + "inference_log": o.InferenceLog, + "latest_monitor_failure_msg": o.LatestMonitorFailureMsg, + "monitor_version": o.MonitorVersion, + "notifications": o.Notifications, + "output_schema_name": o.OutputSchemaName, + "profile_metrics_table_name": o.ProfileMetricsTableName, + "schedule": o.Schedule, + "slicing_exprs": o.SlicingExprs, + "snapshot": o.Snapshot, + "status": o.Status, + "table_name": o.TableName, + "time_series": o.TimeSeries, + }) } // Type implements basetypes.ObjectValuable. @@ -15349,52 +9593,19 @@ func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorMetric{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorMetric) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorMetric) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorMetric) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorMetric) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorMetric) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorMetric +// only implements ToObjectValue() and Type(). +func (o MonitorMetric) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorMetric) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "definition": o.Definition, + "input_columns": o.InputColumns, + "name": o.Name, + "output_data_type": o.OutputDataType, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -15440,52 +9651,16 @@ func (a MonitorNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorNotifications{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorNotifications) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorNotifications) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorNotifications) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorNotifications) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorNotifications +// only implements ToObjectValue() and Type(). +func (o MonitorNotifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "on_failure": o.OnFailure, + "on_new_classification_tag_detected": o.OnNewClassificationTagDetected, + }) } // Type implements basetypes.ObjectValuable. @@ -15537,52 +9712,20 @@ func (a MonitorRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorRefreshInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorRefreshInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorRefreshInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorRefreshInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorRefreshInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorRefreshInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorRefreshInfo +// only implements ToObjectValue() and Type(). +func (o MonitorRefreshInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorRefreshInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end_time_ms": o.EndTimeMs, + "message": o.Message, + "refresh_id": o.RefreshId, + "start_time_ms": o.StartTimeMs, + "state": o.State, + "trigger": o.Trigger, + }) } // Type implements basetypes.ObjectValuable. @@ -15623,52 +9766,15 @@ func (a MonitorRefreshListResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorRefreshListResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorRefreshListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorRefreshListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorRefreshListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorRefreshListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorRefreshListResponse +// only implements ToObjectValue() and Type(). +func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorRefreshListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "refreshes": o.Refreshes, + }) } // Type implements basetypes.ObjectValuable. @@ -15702,52 +9808,13 @@ func (a MonitorSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorSnapshot{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorSnapshot) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorSnapshot) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorSnapshot) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorSnapshot) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorSnapshot) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorSnapshot +// only implements ToObjectValue() and Type(). +func (o MonitorSnapshot) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorSnapshot) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -15791,52 +9858,16 @@ func (a MonitorTimeSeries) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MonitorTimeSeries{} - -// Equal implements basetypes.ObjectValuable. -func (o MonitorTimeSeries) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MonitorTimeSeries) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MonitorTimeSeries) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MonitorTimeSeries) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MonitorTimeSeries) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorTimeSeries +// only implements ToObjectValue() and Type(). +func (o MonitorTimeSeries) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MonitorTimeSeries) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "granularities": o.Granularities, + "timestamp_col": o.TimestampCol, + }) } // Type implements basetypes.ObjectValuable. @@ -15873,52 +9904,15 @@ func (a NamedTableConstraint) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NamedTableConstraint{} - -// Equal implements basetypes.ObjectValuable. -func (o NamedTableConstraint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NamedTableConstraint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NamedTableConstraint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NamedTableConstraint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NamedTableConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NamedTableConstraint +// only implements ToObjectValue() and Type(). +func (o NamedTableConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NamedTableConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -15967,52 +9961,19 @@ func (a OnlineTable) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OnlineTable{} - -// Equal implements basetypes.ObjectValuable. -func (o OnlineTable) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OnlineTable) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OnlineTable) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OnlineTable) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OnlineTable) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OnlineTable +// only implements ToObjectValue() and Type(). +func (o OnlineTable) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OnlineTable) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "spec": o.Spec, + "status": o.Status, + "table_serving_url": o.TableServingUrl, + "unity_catalog_provisioning_state": o.UnityCatalogProvisioningState, + }) } // Type implements basetypes.ObjectValuable. @@ -16080,52 +10041,21 @@ func (a OnlineTableSpec) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OnlineTableSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o OnlineTableSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OnlineTableSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OnlineTableSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OnlineTableSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OnlineTableSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OnlineTableSpec +// only implements ToObjectValue() and Type(). +func (o OnlineTableSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OnlineTableSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "perform_full_copy": o.PerformFullCopy, + "pipeline_id": o.PipelineId, + "primary_key_columns": o.PrimaryKeyColumns, + "run_continuously": o.RunContinuously, + "run_triggered": o.RunTriggered, + "source_table_full_name": o.SourceTableFullName, + "timeseries_key": o.TimeseriesKey, + }) } // Type implements basetypes.ObjectValuable. @@ -16169,52 +10099,13 @@ func (a OnlineTableSpecContinuousSchedulingPolicy) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OnlineTableSpecContinuousSchedulingPolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o OnlineTableSpecContinuousSchedulingPolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OnlineTableSpecContinuousSchedulingPolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OnlineTableSpecContinuousSchedulingPolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OnlineTableSpecContinuousSchedulingPolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OnlineTableSpecContinuousSchedulingPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OnlineTableSpecContinuousSchedulingPolicy +// only implements ToObjectValue() and Type(). +func (o OnlineTableSpecContinuousSchedulingPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OnlineTableSpecContinuousSchedulingPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -16244,52 +10135,13 @@ func (a OnlineTableSpecTriggeredSchedulingPolicy) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OnlineTableSpecTriggeredSchedulingPolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o OnlineTableSpecTriggeredSchedulingPolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OnlineTableSpecTriggeredSchedulingPolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OnlineTableSpecTriggeredSchedulingPolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OnlineTableSpecTriggeredSchedulingPolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OnlineTableSpecTriggeredSchedulingPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OnlineTableSpecTriggeredSchedulingPolicy +// only implements ToObjectValue() and Type(). +func (o OnlineTableSpecTriggeredSchedulingPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OnlineTableSpecTriggeredSchedulingPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -16342,52 +10194,20 @@ func (a OnlineTableStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OnlineTableStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o OnlineTableStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OnlineTableStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OnlineTableStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OnlineTableStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OnlineTableStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OnlineTableStatus +// only implements ToObjectValue() and Type(). +func (o OnlineTableStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OnlineTableStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "continuous_update_status": o.ContinuousUpdateStatus, + "detailed_state": o.DetailedState, + "failed_status": o.FailedStatus, + "message": o.Message, + "provisioning_status": o.ProvisioningStatus, + "triggered_update_status": o.TriggeredUpdateStatus, + }) } // Type implements basetypes.ObjectValuable. @@ -16438,55 +10258,20 @@ func (a PermissionsChange) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{ "add": reflect.TypeOf(types.String{}), "remove": reflect.TypeOf(types.String{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionsChange{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionsChange) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionsChange) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionsChange) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionsChange) String() string { - return fmt.Sprintf("%#v", o) + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionsChange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionsChange +// only implements ToObjectValue() and Type(). +func (o PermissionsChange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionsChange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "add": o.Add, + "principal": o.Principal, + "remove": o.Remove, + }) } // Type implements basetypes.ObjectValuable. @@ -16528,52 +10313,15 @@ func (a PermissionsList) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionsList{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionsList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionsList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionsList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionsList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionsList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionsList +// only implements ToObjectValue() and Type(). +func (o PermissionsList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionsList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "privilege_assignments": o.PrivilegeAssignments, + }) } // Type implements basetypes.ObjectValuable. @@ -16620,52 +10368,19 @@ func (a PipelineProgress) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineProgress{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineProgress) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineProgress) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineProgress) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineProgress) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineProgress) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineProgress +// only implements ToObjectValue() and Type(). +func (o PipelineProgress) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineProgress) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "estimated_completion_time_seconds": o.EstimatedCompletionTimeSeconds, + "latest_version_currently_processing": o.LatestVersionCurrentlyProcessing, + "sync_progress_completion": o.SyncProgressCompletion, + "synced_row_count": o.SyncedRowCount, + "total_row_count": o.TotalRowCount, + }) } // Type implements basetypes.ObjectValuable. @@ -16707,52 +10422,16 @@ func (a PrimaryKeyConstraint) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PrimaryKeyConstraint{} - -// Equal implements basetypes.ObjectValuable. -func (o PrimaryKeyConstraint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PrimaryKeyConstraint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PrimaryKeyConstraint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PrimaryKeyConstraint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PrimaryKeyConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PrimaryKeyConstraint +// only implements ToObjectValue() and Type(). +func (o PrimaryKeyConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PrimaryKeyConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "child_columns": o.ChildColumns, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -16793,52 +10472,16 @@ func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PrivilegeAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PrivilegeAssignment +// only implements ToObjectValue() and Type(). +func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principal": o.Principal, + "privileges": o.Privileges, + }) } // Type implements basetypes.ObjectValuable. @@ -16875,52 +10518,15 @@ func (a ProvisioningInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ProvisioningInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ProvisioningInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ProvisioningInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ProvisioningInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ProvisioningInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ProvisioningInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ProvisioningInfo +// only implements ToObjectValue() and Type(). +func (o ProvisioningInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ProvisioningInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -16959,52 +10565,15 @@ func (a ProvisioningStatus) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ProvisioningStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o ProvisioningStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ProvisioningStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ProvisioningStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ProvisioningStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ProvisioningStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ProvisioningStatus +// only implements ToObjectValue() and Type(). +func (o ProvisioningStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ProvisioningStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "initial_pipeline_sync_progress": o.InitialPipelineSyncProgress, + }) } // Type implements basetypes.ObjectValuable. @@ -17051,52 +10620,20 @@ func (a QuotaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QuotaInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o QuotaInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QuotaInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QuotaInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QuotaInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QuotaInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QuotaInfo +// only implements ToObjectValue() and Type(). +func (o QuotaInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QuotaInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "last_refreshed_at": o.LastRefreshedAt, + "parent_full_name": o.ParentFullName, + "parent_securable_type": o.ParentSecurableType, + "quota_count": o.QuotaCount, + "quota_limit": o.QuotaLimit, + "quota_name": o.QuotaName, + }) } // Type implements basetypes.ObjectValuable. @@ -17141,52 +10678,17 @@ func (a R2Credentials) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = R2Credentials{} - -// Equal implements basetypes.ObjectValuable. -func (o R2Credentials) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o R2Credentials) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o R2Credentials) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o R2Credentials) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o R2Credentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, R2Credentials +// only implements ToObjectValue() and Type(). +func (o R2Credentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o R2Credentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_key_id": o.AccessKeyId, + "secret_access_key": o.SecretAccessKey, + "session_token": o.SessionToken, + }) } // Type implements basetypes.ObjectValuable. @@ -17226,52 +10728,16 @@ func (a ReadVolumeRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReadVolumeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ReadVolumeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReadVolumeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReadVolumeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReadVolumeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReadVolumeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReadVolumeRequest +// only implements ToObjectValue() and Type(). +func (o ReadVolumeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReadVolumeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_browse": o.IncludeBrowse, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -17309,52 +10775,16 @@ func (a RegenerateDashboardRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegenerateDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RegenerateDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegenerateDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegenerateDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegenerateDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegenerateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegenerateDashboardRequest +// only implements ToObjectValue() and Type(). +func (o RegenerateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegenerateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_name": o.TableName, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -17391,52 +10821,16 @@ func (a RegenerateDashboardResponse) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegenerateDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RegenerateDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegenerateDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegenerateDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegenerateDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegenerateDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegenerateDashboardResponse +// only implements ToObjectValue() and Type(). +func (o RegenerateDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegenerateDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "parent_folder": o.ParentFolder, + }) } // Type implements basetypes.ObjectValuable. @@ -17474,52 +10868,16 @@ func (a RegisteredModelAlias) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelAlias{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelAlias) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelAlias) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelAlias) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelAlias) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelAlias) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelAlias +// only implements ToObjectValue() and Type(). +func (o RegisteredModelAlias) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelAlias) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alias_name": o.AliasName, + "version_num": o.VersionNum, + }) } // Type implements basetypes.ObjectValuable. @@ -17587,52 +10945,28 @@ func (a RegisteredModelInfo) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelInfo +// only implements ToObjectValue() and Type(). +func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aliases": o.Aliases, + "browse_only": o.BrowseOnly, + "catalog_name": o.CatalogName, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "full_name": o.FullName, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "schema_name": o.SchemaName, + "storage_location": o.StorageLocation, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -17682,52 +11016,15 @@ func (a RunRefreshRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunRefreshRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RunRefreshRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunRefreshRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunRefreshRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunRefreshRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunRefreshRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunRefreshRequest +// only implements ToObjectValue() and Type(). +func (o RunRefreshRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunRefreshRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_name": o.TableName, + }) } // Type implements basetypes.ObjectValuable. @@ -17801,52 +11098,32 @@ func (a SchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SchemaInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o SchemaInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SchemaInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SchemaInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SchemaInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SchemaInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SchemaInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SchemaInfo +// only implements ToObjectValue() and Type(). +func (o SchemaInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "browse_only": o.BrowseOnly, + "catalog_name": o.CatalogName, + "catalog_type": o.CatalogType, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "effective_predictive_optimization_flag": o.EffectivePredictiveOptimizationFlag, + "enable_predictive_optimization": o.EnablePredictiveOptimization, + "full_name": o.FullName, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "properties": o.Properties, + "schema_id": o.SchemaId, + "storage_location": o.StorageLocation, + "storage_root": o.StorageRoot, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -17905,52 +11182,16 @@ func (a SetArtifactAllowlist) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetArtifactAllowlist{} - -// Equal implements basetypes.ObjectValuable. -func (o SetArtifactAllowlist) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetArtifactAllowlist) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetArtifactAllowlist) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetArtifactAllowlist) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetArtifactAllowlist +// only implements ToObjectValue() and Type(). +func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetArtifactAllowlist) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_matchers": o.ArtifactMatchers, + "artifact_type": o.ArtifactType, + }) } // Type implements basetypes.ObjectValuable. @@ -17991,52 +11232,17 @@ func (a SetRegisteredModelAliasRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetRegisteredModelAliasRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SetRegisteredModelAliasRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetRegisteredModelAliasRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetRegisteredModelAliasRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetRegisteredModelAliasRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetRegisteredModelAliasRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetRegisteredModelAliasRequest +// only implements ToObjectValue() and Type(). +func (o SetRegisteredModelAliasRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetRegisteredModelAliasRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alias": o.Alias, + "full_name": o.FullName, + "version_num": o.VersionNum, + }) } // Type implements basetypes.ObjectValuable. @@ -18076,52 +11282,16 @@ func (a SseEncryptionDetails) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SseEncryptionDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o SseEncryptionDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SseEncryptionDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SseEncryptionDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SseEncryptionDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SseEncryptionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SseEncryptionDetails +// only implements ToObjectValue() and Type(). +func (o SseEncryptionDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SseEncryptionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "algorithm": o.Algorithm, + "aws_kms_key_arn": o.AwsKmsKeyArn, + }) } // Type implements basetypes.ObjectValuable. @@ -18191,58 +11361,38 @@ func (a StorageCredentialInfo) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{ "aws_iam_role": reflect.TypeOf(AwsIamRoleResponse{}), "azure_managed_identity": reflect.TypeOf(AzureManagedIdentityResponse{}), - "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), - "cloudflare_api_token": reflect.TypeOf(CloudflareApiToken{}), - "databricks_gcp_service_account": reflect.TypeOf(DatabricksGcpServiceAccountResponse{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StorageCredentialInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o StorageCredentialInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StorageCredentialInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StorageCredentialInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StorageCredentialInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StorageCredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) + "azure_service_principal": reflect.TypeOf(AzureServicePrincipal{}), + "cloudflare_api_token": reflect.TypeOf(CloudflareApiToken{}), + "databricks_gcp_service_account": reflect.TypeOf(DatabricksGcpServiceAccountResponse{}), + } } -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StorageCredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StorageCredentialInfo +// only implements ToObjectValue() and Type(). +func (o StorageCredentialInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "cloudflare_api_token": o.CloudflareApiToken, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "databricks_gcp_service_account": o.DatabricksGcpServiceAccount, + "full_name": o.FullName, + "id": o.Id, + "isolation_mode": o.IsolationMode, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "read_only": o.ReadOnly, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "used_for_managed_storage": o.UsedForManagedStorage, + }) } // Type implements basetypes.ObjectValuable. @@ -18306,52 +11456,16 @@ func (a SystemSchemaInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SystemSchemaInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o SystemSchemaInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SystemSchemaInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SystemSchemaInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SystemSchemaInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SystemSchemaInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SystemSchemaInfo +// only implements ToObjectValue() and Type(). +func (o SystemSchemaInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SystemSchemaInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "schema": o.Schema, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -18396,52 +11510,17 @@ func (a TableConstraint) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableConstraint{} - -// Equal implements basetypes.ObjectValuable. -func (o TableConstraint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableConstraint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableConstraint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableConstraint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableConstraint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableConstraint +// only implements ToObjectValue() and Type(). +func (o TableConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableConstraint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "foreign_key_constraint": o.ForeignKeyConstraint, + "named_table_constraint": o.NamedTableConstraint, + "primary_key_constraint": o.PrimaryKeyConstraint, + }) } // Type implements basetypes.ObjectValuable. @@ -18485,52 +11564,15 @@ func (a TableDependency) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableDependency{} - -// Equal implements basetypes.ObjectValuable. -func (o TableDependency) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableDependency) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableDependency) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableDependency) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableDependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableDependency +// only implements ToObjectValue() and Type(). +func (o TableDependency) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableDependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_full_name": o.TableFullName, + }) } // Type implements basetypes.ObjectValuable. @@ -18564,52 +11606,15 @@ func (a TableExistsResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableExistsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o TableExistsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableExistsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableExistsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableExistsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableExistsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableExistsResponse +// only implements ToObjectValue() and Type(). +func (o TableExistsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableExistsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "table_exists": o.TableExists, + }) } // Type implements basetypes.ObjectValuable. @@ -18727,52 +11732,46 @@ func (a TableInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o TableInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableInfo +// only implements ToObjectValue() and Type(). +func (o TableInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "access_point": o.AccessPoint, + "browse_only": o.BrowseOnly, + "catalog_name": o.CatalogName, + "columns": o.Columns, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "data_access_configuration_id": o.DataAccessConfigurationId, + "data_source_format": o.DataSourceFormat, + "deleted_at": o.DeletedAt, + "delta_runtime_properties_kvpairs": o.DeltaRuntimePropertiesKvpairs, + "effective_predictive_optimization_flag": o.EffectivePredictiveOptimizationFlag, + "enable_predictive_optimization": o.EnablePredictiveOptimization, + "encryption_details": o.EncryptionDetails, + "full_name": o.FullName, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "pipeline_id": o.PipelineId, + "properties": o.Properties, + "row_filter": o.RowFilter, + "schema_name": o.SchemaName, + "sql_path": o.SqlPath, + "storage_credential_name": o.StorageCredentialName, + "storage_location": o.StorageLocation, + "table_constraints": o.TableConstraints, + "table_id": o.TableId, + "table_type": o.TableType, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "view_definition": o.ViewDefinition, + "view_dependencies": o.ViewDependencies, + }) } // Type implements basetypes.ObjectValuable. @@ -18859,52 +11858,16 @@ func (a TableRowFilter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableRowFilter{} - -// Equal implements basetypes.ObjectValuable. -func (o TableRowFilter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableRowFilter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableRowFilter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableRowFilter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableRowFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableRowFilter +// only implements ToObjectValue() and Type(). +func (o TableRowFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableRowFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "function_name": o.FunctionName, + "input_column_names": o.InputColumnNames, + }) } // Type implements basetypes.ObjectValuable. @@ -18943,52 +11906,16 @@ func (a TableSummary) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableSummary{} - -// Equal implements basetypes.ObjectValuable. -func (o TableSummary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableSummary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableSummary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableSummary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableSummary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableSummary +// only implements ToObjectValue() and Type(). +func (o TableSummary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableSummary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "table_type": o.TableType, + }) } // Type implements basetypes.ObjectValuable. @@ -19034,52 +11961,17 @@ func (a TemporaryCredentials) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TemporaryCredentials{} - -// Equal implements basetypes.ObjectValuable. -func (o TemporaryCredentials) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TemporaryCredentials) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TemporaryCredentials) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TemporaryCredentials) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TemporaryCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TemporaryCredentials +// only implements ToObjectValue() and Type(). +func (o TemporaryCredentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TemporaryCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_temp_credentials": o.AwsTempCredentials, + "azure_aad": o.AzureAad, + "expiration_time": o.ExpirationTime, + }) } // Type implements basetypes.ObjectValuable. @@ -19130,52 +12022,17 @@ func (a TriggeredUpdateStatus) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TriggeredUpdateStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o TriggeredUpdateStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TriggeredUpdateStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TriggeredUpdateStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TriggeredUpdateStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TriggeredUpdateStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TriggeredUpdateStatus +// only implements ToObjectValue() and Type(). +func (o TriggeredUpdateStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TriggeredUpdateStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "last_processed_commit_version": o.LastProcessedCommitVersion, + "timestamp": o.Timestamp, + "triggered_update_progress": o.TriggeredUpdateProgress, + }) } // Type implements basetypes.ObjectValuable. @@ -19216,52 +12073,16 @@ func (a UnassignRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UnassignRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UnassignRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UnassignRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UnassignRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UnassignRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UnassignRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UnassignRequest +// only implements ToObjectValue() and Type(). +func (o UnassignRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UnassignRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -19294,52 +12115,13 @@ func (a UnassignResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UnassignResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UnassignResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UnassignResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UnassignResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UnassignResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UnassignResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UnassignResponse +// only implements ToObjectValue() and Type(). +func (o UnassignResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UnassignResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -19369,52 +12151,13 @@ func (a UpdateAssignmentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAssignmentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAssignmentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAssignmentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAssignmentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAssignmentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAssignmentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAssignmentResponse +// only implements ToObjectValue() and Type(). +func (o UpdateAssignmentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAssignmentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -19462,52 +12205,21 @@ func (a UpdateCatalog) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCatalog{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCatalog) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCatalog) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCatalog) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCatalog) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCatalog) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCatalog +// only implements ToObjectValue() and Type(). +func (o UpdateCatalog) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCatalog) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "enable_predictive_optimization": o.EnablePredictiveOptimization, + "isolation_mode": o.IsolationMode, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + "properties": o.Properties, + }) } // Type implements basetypes.ObjectValuable. @@ -19557,52 +12269,18 @@ func (a UpdateConnection) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateConnection{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateConnection) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateConnection) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateConnection) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateConnection) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateConnection) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateConnection +// only implements ToObjectValue() and Type(). +func (o UpdateConnection) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateConnection) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "new_name": o.NewName, + "options": o.Options, + "owner": o.Owner, + }) } // Type implements basetypes.ObjectValuable. @@ -19670,52 +12348,25 @@ func (a UpdateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCredentialRequest +// only implements ToObjectValue() and Type(). +func (o UpdateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "comment": o.Comment, + "force": o.Force, + "isolation_mode": o.IsolationMode, + "name_arg": o.NameArg, + "new_name": o.NewName, + "owner": o.Owner, + "read_only": o.ReadOnly, + "skip_validation": o.SkipValidation, + }) } // Type implements basetypes.ObjectValuable. @@ -19795,52 +12446,27 @@ func (a UpdateExternalLocation) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExternalLocation{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExternalLocation) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExternalLocation) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExternalLocation) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExternalLocation) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExternalLocation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExternalLocation +// only implements ToObjectValue() and Type(). +func (o UpdateExternalLocation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExternalLocation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_point": o.AccessPoint, + "comment": o.Comment, + "credential_name": o.CredentialName, + "encryption_details": o.EncryptionDetails, + "fallback": o.Fallback, + "force": o.Force, + "isolation_mode": o.IsolationMode, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + "read_only": o.ReadOnly, + "skip_validation": o.SkipValidation, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -19891,52 +12517,16 @@ func (a UpdateFunction) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateFunction{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateFunction) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateFunction) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateFunction) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateFunction) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateFunction) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateFunction +// only implements ToObjectValue() and Type(). +func (o UpdateFunction) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateFunction) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "owner": o.Owner, + }) } // Type implements basetypes.ObjectValuable. @@ -19987,52 +12577,22 @@ func (a UpdateMetastore) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateMetastore{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateMetastore) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateMetastore) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateMetastore) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateMetastore) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateMetastore) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateMetastore +// only implements ToObjectValue() and Type(). +func (o UpdateMetastore) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateMetastore) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "delta_sharing_organization_name": o.DeltaSharingOrganizationName, + "delta_sharing_recipient_token_lifetime_in_seconds": o.DeltaSharingRecipientTokenLifetimeInSeconds, + "delta_sharing_scope": o.DeltaSharingScope, + "id": o.Id, + "new_name": o.NewName, + "owner": o.Owner, + "privilege_model_version": o.PrivilegeModelVersion, + "storage_root_credential_id": o.StorageRootCredentialId, + }) } // Type implements basetypes.ObjectValuable. @@ -20071,60 +12631,25 @@ func (newState *UpdateMetastoreAssignment) SyncEffectiveFieldsDuringRead(existin // GetComplexFieldTypes returns a map of the types of elements in complex fields in UpdateMetastoreAssignment. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a UpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateMetastoreAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateMetastoreAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateMetastoreAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateMetastoreAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateMetastoreAssignment) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a UpdateMetastoreAssignment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateMetastoreAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateMetastoreAssignment +// only implements ToObjectValue() and Type(). +func (o UpdateMetastoreAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateMetastoreAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default_catalog_name": o.DefaultCatalogName, + "metastore_id": o.MetastoreId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -20164,52 +12689,17 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o UpdateModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "full_name": o.FullName, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -20285,52 +12775,26 @@ func (a UpdateMonitor) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateMonitor{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateMonitor) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateMonitor) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateMonitor) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateMonitor) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateMonitor) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateMonitor +// only implements ToObjectValue() and Type(). +func (o UpdateMonitor) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateMonitor) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "baseline_table_name": o.BaselineTableName, + "custom_metrics": o.CustomMetrics, + "dashboard_id": o.DashboardId, + "data_classification_config": o.DataClassificationConfig, + "inference_log": o.InferenceLog, + "notifications": o.Notifications, + "output_schema_name": o.OutputSchemaName, + "schedule": o.Schedule, + "slicing_exprs": o.SlicingExprs, + "snapshot": o.Snapshot, + "table_name": o.TableName, + "time_series": o.TimeSeries, + }) } // Type implements basetypes.ObjectValuable. @@ -20397,52 +12861,17 @@ func (a UpdatePermissions) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePermissions +// only implements ToObjectValue() and Type(). +func (o UpdatePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "changes": o.Changes, + "full_name": o.FullName, + "securable_type": o.SecurableType, + }) } // Type implements basetypes.ObjectValuable. @@ -20486,52 +12915,18 @@ func (a UpdateRegisteredModelRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRegisteredModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRegisteredModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRegisteredModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRegisteredModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRegisteredModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRegisteredModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRegisteredModelRequest +// only implements ToObjectValue() and Type(). +func (o UpdateRegisteredModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRegisteredModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "full_name": o.FullName, + "new_name": o.NewName, + "owner": o.Owner, + }) } // Type implements basetypes.ObjectValuable. @@ -20566,52 +12961,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -20656,52 +13012,20 @@ func (a UpdateSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateSchema{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateSchema) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateSchema) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateSchema) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateSchema) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateSchema) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateSchema +// only implements ToObjectValue() and Type(). +func (o UpdateSchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateSchema) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "enable_predictive_optimization": o.EnablePredictiveOptimization, + "full_name": o.FullName, + "new_name": o.NewName, + "owner": o.Owner, + "properties": o.Properties, + }) } // Type implements basetypes.ObjectValuable. @@ -20774,52 +13098,27 @@ func (a UpdateStorageCredential) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateStorageCredential{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateStorageCredential) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateStorageCredential) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateStorageCredential) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateStorageCredential) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateStorageCredential +// only implements ToObjectValue() and Type(). +func (o UpdateStorageCredential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "cloudflare_api_token": o.CloudflareApiToken, + "comment": o.Comment, + "databricks_gcp_service_account": o.DatabricksGcpServiceAccount, + "force": o.Force, + "isolation_mode": o.IsolationMode, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + "read_only": o.ReadOnly, + "skip_validation": o.SkipValidation, + }) } // Type implements basetypes.ObjectValuable. @@ -20878,52 +13177,16 @@ func (a UpdateTableRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateTableRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateTableRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateTableRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateTableRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateTableRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateTableRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateTableRequest +// only implements ToObjectValue() and Type(). +func (o UpdateTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateTableRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_name": o.FullName, + "owner": o.Owner, + }) } // Type implements basetypes.ObjectValuable. @@ -20964,52 +13227,18 @@ func (a UpdateVolumeRequestContent) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateVolumeRequestContent{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateVolumeRequestContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateVolumeRequestContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateVolumeRequestContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateVolumeRequestContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateVolumeRequestContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateVolumeRequestContent +// only implements ToObjectValue() and Type(). +func (o UpdateVolumeRequestContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateVolumeRequestContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + }) } // Type implements basetypes.ObjectValuable. @@ -21053,52 +13282,17 @@ func (a UpdateWorkspaceBindings) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateWorkspaceBindings{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateWorkspaceBindings +// only implements ToObjectValue() and Type(). +func (o UpdateWorkspaceBindings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "assign_workspaces": o.AssignWorkspaces, + "name": o.Name, + "unassign_workspaces": o.UnassignWorkspaces, + }) } // Type implements basetypes.ObjectValuable. @@ -21147,52 +13341,18 @@ func (a UpdateWorkspaceBindingsParameters) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateWorkspaceBindingsParameters{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindingsParameters) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindingsParameters) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindingsParameters) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindingsParameters) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateWorkspaceBindingsParameters +// only implements ToObjectValue() and Type(). +func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceBindingsParameters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "add": o.Add, + "remove": o.Remove, + "securable_name": o.SecurableName, + "securable_type": o.SecurableType, + }) } // Type implements basetypes.ObjectValuable. @@ -21253,52 +13413,21 @@ func (a ValidateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ValidateCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ValidateCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ValidateCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ValidateCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ValidateCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ValidateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ValidateCredentialRequest +// only implements ToObjectValue() and Type(). +func (o ValidateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ValidateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "credential_name": o.CredentialName, + "external_location_name": o.ExternalLocationName, + "purpose": o.Purpose, + "read_only": o.ReadOnly, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -21347,52 +13476,16 @@ func (a ValidateCredentialResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ValidateCredentialResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ValidateCredentialResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ValidateCredentialResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ValidateCredentialResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ValidateCredentialResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ValidateCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ValidateCredentialResponse +// only implements ToObjectValue() and Type(). +func (o ValidateCredentialResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ValidateCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "isDir": o.IsDir, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -21451,52 +13544,23 @@ func (a ValidateStorageCredential) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ValidateStorageCredential{} - -// Equal implements basetypes.ObjectValuable. -func (o ValidateStorageCredential) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ValidateStorageCredential) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ValidateStorageCredential) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ValidateStorageCredential) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ValidateStorageCredential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ValidateStorageCredential +// only implements ToObjectValue() and Type(). +func (o ValidateStorageCredential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ValidateStorageCredential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_iam_role": o.AwsIamRole, + "azure_managed_identity": o.AzureManagedIdentity, + "azure_service_principal": o.AzureServicePrincipal, + "cloudflare_api_token": o.CloudflareApiToken, + "databricks_gcp_service_account": o.DatabricksGcpServiceAccount, + "external_location_name": o.ExternalLocationName, + "read_only": o.ReadOnly, + "storage_credential_name": o.StorageCredentialName, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -21552,52 +13616,16 @@ func (a ValidateStorageCredentialResponse) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ValidateStorageCredentialResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ValidateStorageCredentialResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ValidateStorageCredentialResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ValidateStorageCredentialResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ValidateStorageCredentialResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ValidateStorageCredentialResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ValidateStorageCredentialResponse +// only implements ToObjectValue() and Type(). +func (o ValidateStorageCredentialResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ValidateStorageCredentialResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "isDir": o.IsDir, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -21638,52 +13666,17 @@ func (a ValidationResult) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ValidationResult{} - -// Equal implements basetypes.ObjectValuable. -func (o ValidationResult) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ValidationResult) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ValidationResult) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ValidationResult) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ValidationResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ValidationResult +// only implements ToObjectValue() and Type(). +func (o ValidationResult) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ValidationResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + "operation": o.Operation, + "result": o.Result, + }) } // Type implements basetypes.ObjectValuable. @@ -21755,52 +13748,31 @@ func (a VolumeInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = VolumeInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o VolumeInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o VolumeInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o VolumeInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o VolumeInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o VolumeInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, VolumeInfo +// only implements ToObjectValue() and Type(). +func (o VolumeInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o VolumeInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_point": o.AccessPoint, + "browse_only": o.BrowseOnly, + "catalog_name": o.CatalogName, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "encryption_details": o.EncryptionDetails, + "full_name": o.FullName, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "schema_name": o.SchemaName, + "storage_location": o.StorageLocation, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "volume_id": o.VolumeId, + "volume_type": o.VolumeType, + }) } // Type implements basetypes.ObjectValuable. @@ -21853,52 +13825,16 @@ func (a WorkspaceBinding) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceBinding{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceBinding) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceBinding) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceBinding) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceBinding) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceBinding) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceBinding +// only implements ToObjectValue() and Type(). +func (o WorkspaceBinding) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceBinding) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "binding_type": o.BindingType, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -21940,52 +13876,16 @@ func (a WorkspaceBindingsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceBindingsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceBindingsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceBindingsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceBindingsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceBindingsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceBindingsResponse +// only implements ToObjectValue() and Type(). +func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceBindingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bindings": o.Bindings, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 416d83324d..08e275f9ea 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -12,15 +12,11 @@ package compute_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AddInstanceProfile struct { @@ -69,52 +65,18 @@ func (a AddInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AddInstanceProfile{} - -// Equal implements basetypes.ObjectValuable. -func (o AddInstanceProfile) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AddInstanceProfile) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AddInstanceProfile) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AddInstanceProfile) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AddInstanceProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AddInstanceProfile +// only implements ToObjectValue() and Type(). +func (o AddInstanceProfile) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AddInstanceProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "iam_role_arn": o.IamRoleArn, + "instance_profile_arn": o.InstanceProfileArn, + "is_meta_instance_profile": o.IsMetaInstanceProfile, + "skip_validation": o.SkipValidation, + }) } // Type implements basetypes.ObjectValuable. @@ -149,52 +111,13 @@ func (a AddResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AddResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AddResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AddResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AddResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AddResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AddResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AddResponse +// only implements ToObjectValue() and Type(). +func (o AddResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AddResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -227,52 +150,15 @@ func (a Adlsgen2Info) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Adlsgen2Info{} - -// Equal implements basetypes.ObjectValuable. -func (o Adlsgen2Info) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Adlsgen2Info) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Adlsgen2Info) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Adlsgen2Info) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Adlsgen2Info) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Adlsgen2Info +// only implements ToObjectValue() and Type(). +func (o Adlsgen2Info) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Adlsgen2Info) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination": o.Destination, + }) } // Type implements basetypes.ObjectValuable. @@ -312,52 +198,16 @@ func (a AutoScale) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AutoScale{} - -// Equal implements basetypes.ObjectValuable. -func (o AutoScale) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AutoScale) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AutoScale) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AutoScale) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AutoScale) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AutoScale +// only implements ToObjectValue() and Type(). +func (o AutoScale) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AutoScale) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_workers": o.MaxWorkers, + "min_workers": o.MinWorkers, + }) } // Type implements basetypes.ObjectValuable. @@ -473,52 +323,24 @@ func (a AwsAttributes) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsAttributes +// only implements ToObjectValue() and Type(). +func (o AwsAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "availability": o.Availability, + "ebs_volume_count": o.EbsVolumeCount, + "ebs_volume_iops": o.EbsVolumeIops, + "ebs_volume_size": o.EbsVolumeSize, + "ebs_volume_throughput": o.EbsVolumeThroughput, + "ebs_volume_type": o.EbsVolumeType, + "first_on_demand": o.FirstOnDemand, + "instance_profile_arn": o.InstanceProfileArn, + "spot_bid_price_percent": o.SpotBidPricePercent, + "zone_id": o.ZoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -584,52 +406,18 @@ func (a AzureAttributes) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureAttributes +// only implements ToObjectValue() and Type(). +func (o AzureAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "availability": o.Availability, + "first_on_demand": o.FirstOnDemand, + "log_analytics_info": o.LogAnalyticsInfo, + "spot_bid_max_price": o.SpotBidMaxPrice, + }) } // Type implements basetypes.ObjectValuable. @@ -671,52 +459,17 @@ func (a CancelCommand) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelCommand{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelCommand) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelCommand) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelCommand) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelCommand) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelCommand) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelCommand +// only implements ToObjectValue() and Type(). +func (o CancelCommand) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelCommand) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusterId": o.ClusterId, + "commandId": o.CommandId, + "contextId": o.ContextId, + }) } // Type implements basetypes.ObjectValuable. @@ -750,52 +503,13 @@ func (a CancelResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelResponse +// only implements ToObjectValue() and Type(). +func (o CancelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -829,52 +543,16 @@ func (a ChangeClusterOwner) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ChangeClusterOwner{} - -// Equal implements basetypes.ObjectValuable. -func (o ChangeClusterOwner) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ChangeClusterOwner) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ChangeClusterOwner) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ChangeClusterOwner) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ChangeClusterOwner) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ChangeClusterOwner +// only implements ToObjectValue() and Type(). +func (o ChangeClusterOwner) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ChangeClusterOwner) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "owner_username": o.OwnerUsername, + }) } // Type implements basetypes.ObjectValuable. @@ -907,52 +585,13 @@ func (a ChangeClusterOwnerResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ChangeClusterOwnerResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ChangeClusterOwnerResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ChangeClusterOwnerResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ChangeClusterOwnerResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ChangeClusterOwnerResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ChangeClusterOwnerResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ChangeClusterOwnerResponse +// only implements ToObjectValue() and Type(). +func (o ChangeClusterOwnerResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ChangeClusterOwnerResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -986,52 +625,16 @@ func (a ClientsTypes) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClientsTypes{} - -// Equal implements basetypes.ObjectValuable. -func (o ClientsTypes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClientsTypes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClientsTypes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClientsTypes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClientsTypes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClientsTypes +// only implements ToObjectValue() and Type(). +func (o ClientsTypes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClientsTypes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "jobs": o.Jobs, + "notebooks": o.Notebooks, + }) } // Type implements basetypes.ObjectValuable. @@ -1066,52 +669,15 @@ func (a CloneCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CloneCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o CloneCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CloneCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CloneCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CloneCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CloneCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CloneCluster +// only implements ToObjectValue() and Type(). +func (o CloneCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CloneCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "source_cluster_id": o.SourceClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -1146,52 +712,15 @@ func (a CloudProviderNodeInfo) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CloudProviderNodeInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o CloudProviderNodeInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CloudProviderNodeInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CloudProviderNodeInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CloudProviderNodeInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CloudProviderNodeInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CloudProviderNodeInfo +// only implements ToObjectValue() and Type(). +func (o CloudProviderNodeInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CloudProviderNodeInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -1233,52 +762,18 @@ func (a ClusterAccessControlRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o ClusterAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -1325,52 +820,19 @@ func (a ClusterAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -1550,52 +1012,38 @@ func (a ClusterAttributes) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAttributes +// only implements ToObjectValue() and Type(). +func (o ClusterAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "autotermination_minutes": o.AutoterminationMinutes, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "cluster_log_conf": o.ClusterLogConf, + "cluster_name": o.ClusterName, + "custom_tags": o.CustomTags, + "data_security_mode": o.DataSecurityMode, + "docker_image": o.DockerImage, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_elastic_disk": o.EnableElasticDisk, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "node_type_id": o.NodeTypeId, + "policy_id": o.PolicyId, + "runtime_engine": o.RuntimeEngine, + "single_user_name": o.SingleUserName, + "spark_conf": o.SparkConf, + "spark_env_vars": o.SparkEnvVars, + "spark_version": o.SparkVersion, + "ssh_public_keys": o.SshPublicKeys, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -1684,52 +1132,17 @@ func (a ClusterCompliance) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterCompliance{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterCompliance) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterCompliance) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterCompliance) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterCompliance) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterCompliance) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterCompliance +// only implements ToObjectValue() and Type(). +func (o ClusterCompliance) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterCompliance) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "is_compliant": o.IsCompliant, + "violations": o.Violations, + }) } // Type implements basetypes.ObjectValuable. @@ -1997,52 +1410,59 @@ func (a ClusterDetails) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterDetails +// only implements ToObjectValue() and Type(). +func (o ClusterDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "autoscale": o.Autoscale, + "autotermination_minutes": o.AutoterminationMinutes, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "cluster_cores": o.ClusterCores, + "cluster_id": o.ClusterId, + "cluster_log_conf": o.ClusterLogConf, + "cluster_log_status": o.ClusterLogStatus, + "cluster_memory_mb": o.ClusterMemoryMb, + "cluster_name": o.ClusterName, + "cluster_source": o.ClusterSource, + "creator_user_name": o.CreatorUserName, + "custom_tags": o.CustomTags, + "data_security_mode": o.DataSecurityMode, + "default_tags": o.DefaultTags, + "docker_image": o.DockerImage, + "driver": o.Driver, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_elastic_disk": o.EnableElasticDisk, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "executors": o.Executors, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "jdbc_port": o.JdbcPort, + "last_restarted_time": o.LastRestartedTime, + "last_state_loss_time": o.LastStateLossTime, + "node_type_id": o.NodeTypeId, + "num_workers": o.NumWorkers, + "policy_id": o.PolicyId, + "runtime_engine": o.RuntimeEngine, + "single_user_name": o.SingleUserName, + "spark_conf": o.SparkConf, + "spark_context_id": o.SparkContextId, + "spark_env_vars": o.SparkEnvVars, + "spark_version": o.SparkVersion, + "spec": o.Spec, + "ssh_public_keys": o.SshPublicKeys, + "start_time": o.StartTime, + "state": o.State, + "state_message": o.StateMessage, + "terminated_time": o.TerminatedTime, + "termination_reason": o.TerminationReason, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -2169,52 +1589,19 @@ func (a ClusterEvent) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterEvent{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterEvent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterEvent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterEvent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterEvent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterEvent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterEvent +// only implements ToObjectValue() and Type(). +func (o ClusterEvent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterEvent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "data_plane_event_details": o.DataPlaneEventDetails, + "details": o.Details, + "timestamp": o.Timestamp, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -2260,52 +1647,16 @@ func (a ClusterLibraryStatuses) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterLibraryStatuses{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterLibraryStatuses) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterLibraryStatuses) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterLibraryStatuses) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterLibraryStatuses) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterLibraryStatuses) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterLibraryStatuses) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterLibraryStatuses +// only implements ToObjectValue() and Type(). +func (o ClusterLibraryStatuses) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "library_statuses": o.LibraryStatuses, + }) } // Type implements basetypes.ObjectValuable. @@ -2352,52 +1703,16 @@ func (a ClusterLogConf) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterLogConf{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterLogConf) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterLogConf) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterLogConf) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterLogConf) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterLogConf) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterLogConf +// only implements ToObjectValue() and Type(). +func (o ClusterLogConf) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterLogConf) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbfs": o.Dbfs, + "s3": o.S3, + }) } // Type implements basetypes.ObjectValuable. @@ -2441,52 +1756,17 @@ func (a ClusterPermission) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPermission +// only implements ToObjectValue() and Type(). +func (o ClusterPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -2529,52 +1809,17 @@ func (a ClusterPermissions) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPermissions +// only implements ToObjectValue() and Type(). +func (o ClusterPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -2613,52 +1858,16 @@ func (a ClusterPermissionsDescription) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o ClusterPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -2696,52 +1905,16 @@ func (a ClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -2784,52 +1957,18 @@ func (a ClusterPolicyAccessControlRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPolicyAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPolicyAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o ClusterPolicyAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -2876,52 +2015,19 @@ func (a ClusterPolicyAccessControlResponse) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPolicyAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPolicyAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPolicyAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -2966,52 +2072,17 @@ func (a ClusterPolicyPermission) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPolicyPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPolicyPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPolicyPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPolicyPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPolicyPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPolicyPermission +// only implements ToObjectValue() and Type(). +func (o ClusterPolicyPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -3054,52 +2125,17 @@ func (a ClusterPolicyPermissions) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPolicyPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPolicyPermissions +// only implements ToObjectValue() and Type(). +func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -3138,52 +2174,16 @@ func (a ClusterPolicyPermissionsDescription) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPolicyPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPolicyPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o ClusterPolicyPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -3221,52 +2221,16 @@ func (a ClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterPolicyPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterPolicyPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterPolicyPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "cluster_policy_id": o.ClusterPolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -3315,52 +2279,17 @@ func (a ClusterSettingsChange) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterSettingsChange{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterSettingsChange) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterSettingsChange) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterSettingsChange) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterSettingsChange) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterSettingsChange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterSettingsChange +// only implements ToObjectValue() and Type(). +func (o ClusterSettingsChange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterSettingsChange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "field": o.Field, + "new_value": o.NewValue, + "previous_value": o.PreviousValue, + }) } // Type implements basetypes.ObjectValuable. @@ -3411,52 +2340,16 @@ func (a ClusterSize) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterSize{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterSize) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterSize) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterSize) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterSize) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterSize) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterSize +// only implements ToObjectValue() and Type(). +func (o ClusterSize) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterSize) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "autoscale": o.Autoscale, + "num_workers": o.NumWorkers, + }) } // Type implements basetypes.ObjectValuable. @@ -3653,52 +2546,41 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterSpec +// only implements ToObjectValue() and Type(). +func (o ClusterSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "apply_policy_default_values": o.ApplyPolicyDefaultValues, + "autoscale": o.Autoscale, + "autotermination_minutes": o.AutoterminationMinutes, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "cluster_log_conf": o.ClusterLogConf, + "cluster_name": o.ClusterName, + "custom_tags": o.CustomTags, + "data_security_mode": o.DataSecurityMode, + "docker_image": o.DockerImage, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_elastic_disk": o.EnableElasticDisk, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "node_type_id": o.NodeTypeId, + "num_workers": o.NumWorkers, + "policy_id": o.PolicyId, + "runtime_engine": o.RuntimeEngine, + "single_user_name": o.SingleUserName, + "spark_conf": o.SparkConf, + "spark_env_vars": o.SparkEnvVars, + "spark_version": o.SparkVersion, + "ssh_public_keys": o.SshPublicKeys, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -3783,52 +2665,15 @@ func (a ClusterStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterStatus +// only implements ToObjectValue() and Type(). +func (o ClusterStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -3868,52 +2713,18 @@ func (a Command) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Command{} - -// Equal implements basetypes.ObjectValuable. -func (o Command) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Command) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Command) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Command) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Command) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Command +// only implements ToObjectValue() and Type(). +func (o Command) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Command) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusterId": o.ClusterId, + "command": o.Command, + "contextId": o.ContextId, + "language": o.Language, + }) } // Type implements basetypes.ObjectValuable. @@ -3954,52 +2765,17 @@ func (a CommandStatusRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CommandStatusRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CommandStatusRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CommandStatusRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CommandStatusRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CommandStatusRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CommandStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CommandStatusRequest +// only implements ToObjectValue() and Type(). +func (o CommandStatusRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CommandStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusterId": o.ClusterId, + "commandId": o.CommandId, + "contextId": o.ContextId, + }) } // Type implements basetypes.ObjectValuable. @@ -4040,52 +2816,17 @@ func (a CommandStatusResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CommandStatusResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CommandStatusResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CommandStatusResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CommandStatusResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CommandStatusResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CommandStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CommandStatusResponse +// only implements ToObjectValue() and Type(). +func (o CommandStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CommandStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "results": o.Results, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -4125,52 +2866,16 @@ func (a ContextStatusRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ContextStatusRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ContextStatusRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ContextStatusRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ContextStatusRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ContextStatusRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ContextStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ContextStatusRequest +// only implements ToObjectValue() and Type(). +func (o ContextStatusRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ContextStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusterId": o.ClusterId, + "contextId": o.ContextId, + }) } // Type implements basetypes.ObjectValuable. @@ -4206,52 +2911,16 @@ func (a ContextStatusResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ContextStatusResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ContextStatusResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ContextStatusResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ContextStatusResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ContextStatusResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ContextStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ContextStatusResponse +// only implements ToObjectValue() and Type(). +func (o ContextStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ContextStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -4450,52 +3119,42 @@ func (a CreateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCluster +// only implements ToObjectValue() and Type(). +func (o CreateCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "apply_policy_default_values": o.ApplyPolicyDefaultValues, + "autoscale": o.Autoscale, + "autotermination_minutes": o.AutoterminationMinutes, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "clone_from": o.CloneFrom, + "cluster_log_conf": o.ClusterLogConf, + "cluster_name": o.ClusterName, + "custom_tags": o.CustomTags, + "data_security_mode": o.DataSecurityMode, + "docker_image": o.DockerImage, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_elastic_disk": o.EnableElasticDisk, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "node_type_id": o.NodeTypeId, + "num_workers": o.NumWorkers, + "policy_id": o.PolicyId, + "runtime_engine": o.RuntimeEngine, + "single_user_name": o.SingleUserName, + "spark_conf": o.SparkConf, + "spark_env_vars": o.SparkEnvVars, + "spark_version": o.SparkVersion, + "ssh_public_keys": o.SshPublicKeys, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -4581,52 +3240,15 @@ func (a CreateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateClusterResponse +// only implements ToObjectValue() and Type(). +func (o CreateClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -4662,52 +3284,16 @@ func (a CreateContext) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateContext{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateContext) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateContext) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateContext) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateContext) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateContext) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateContext +// only implements ToObjectValue() and Type(). +func (o CreateContext) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateContext) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusterId": o.ClusterId, + "language": o.Language, + }) } // Type implements basetypes.ObjectValuable. @@ -4802,52 +3388,27 @@ func (a CreateInstancePool) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateInstancePool{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateInstancePool) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateInstancePool) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateInstancePool) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateInstancePool) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateInstancePool +// only implements ToObjectValue() and Type(). +func (o CreateInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "custom_tags": o.CustomTags, + "disk_spec": o.DiskSpec, + "enable_elastic_disk": o.EnableElasticDisk, + "gcp_attributes": o.GcpAttributes, + "idle_instance_autotermination_minutes": o.IdleInstanceAutoterminationMinutes, + "instance_pool_name": o.InstancePoolName, + "max_capacity": o.MaxCapacity, + "min_idle_instances": o.MinIdleInstances, + "node_type_id": o.NodeTypeId, + "preloaded_docker_images": o.PreloadedDockerImages, + "preloaded_spark_versions": o.PreloadedSparkVersions, + }) } // Type implements basetypes.ObjectValuable. @@ -4907,52 +3468,15 @@ func (a CreateInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateInstancePoolResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateInstancePoolResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateInstancePoolResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateInstancePoolResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateInstancePoolResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateInstancePoolResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateInstancePoolResponse +// only implements ToObjectValue() and Type(). +func (o CreateInstancePoolResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateInstancePoolResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_pool_id": o.InstancePoolId, + }) } // Type implements basetypes.ObjectValuable. @@ -5019,52 +3543,21 @@ func (a CreatePolicy) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePolicy +// only implements ToObjectValue() and Type(). +func (o CreatePolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "definition": o.Definition, + "description": o.Description, + "libraries": o.Libraries, + "max_clusters_per_user": o.MaxClustersPerUser, + "name": o.Name, + "policy_family_definition_overrides": o.PolicyFamilyDefinitionOverrides, + "policy_family_id": o.PolicyFamilyId, + }) } // Type implements basetypes.ObjectValuable. @@ -5106,52 +3599,15 @@ func (a CreatePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePolicyResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePolicyResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePolicyResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePolicyResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePolicyResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePolicyResponse +// only implements ToObjectValue() and Type(). +func (o CreatePolicyResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -5185,52 +3641,15 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateResponse +// only implements ToObjectValue() and Type(). +func (o CreateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "script_id": o.ScriptId, + }) } // Type implements basetypes.ObjectValuable. @@ -5263,52 +3682,15 @@ func (a Created) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Created{} - -// Equal implements basetypes.ObjectValuable. -func (o Created) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Created) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Created) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Created) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Created) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Created +// only implements ToObjectValue() and Type(). +func (o Created) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Created) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -5348,52 +3730,18 @@ func (a DataPlaneEventDetails) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DataPlaneEventDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o DataPlaneEventDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DataPlaneEventDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DataPlaneEventDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DataPlaneEventDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DataPlaneEventDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DataPlaneEventDetails +// only implements ToObjectValue() and Type(). +func (o DataPlaneEventDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DataPlaneEventDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "event_type": o.EventType, + "executor_failures": o.ExecutorFailures, + "host_id": o.HostId, + "timestamp": o.Timestamp, + }) } // Type implements basetypes.ObjectValuable. @@ -5430,52 +3778,15 @@ func (a DbfsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DbfsStorageInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o DbfsStorageInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DbfsStorageInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DbfsStorageInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DbfsStorageInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DbfsStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DbfsStorageInfo +// only implements ToObjectValue() and Type(). +func (o DbfsStorageInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DbfsStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination": o.Destination, + }) } // Type implements basetypes.ObjectValuable. @@ -5509,52 +3820,15 @@ func (a DeleteCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCluster +// only implements ToObjectValue() and Type(). +func (o DeleteCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -5586,52 +3860,13 @@ func (a DeleteClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteClusterResponse +// only implements ToObjectValue() and Type(). +func (o DeleteClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5664,52 +3899,15 @@ func (a DeleteGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteGlobalInitScriptRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteGlobalInitScriptRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteGlobalInitScriptRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteGlobalInitScriptRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteGlobalInitScriptRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteGlobalInitScriptRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteGlobalInitScriptRequest +// only implements ToObjectValue() and Type(). +func (o DeleteGlobalInitScriptRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteGlobalInitScriptRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "script_id": o.ScriptId, + }) } // Type implements basetypes.ObjectValuable. @@ -5743,52 +3941,15 @@ func (a DeleteInstancePool) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteInstancePool{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteInstancePool) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteInstancePool) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteInstancePool) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteInstancePool) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteInstancePool +// only implements ToObjectValue() and Type(). +func (o DeleteInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_pool_id": o.InstancePoolId, + }) } // Type implements basetypes.ObjectValuable. @@ -5820,52 +3981,13 @@ func (a DeleteInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteInstancePoolResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteInstancePoolResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteInstancePoolResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteInstancePoolResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteInstancePoolResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteInstancePoolResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteInstancePoolResponse +// only implements ToObjectValue() and Type(). +func (o DeleteInstancePoolResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteInstancePoolResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5897,52 +4019,15 @@ func (a DeletePolicy) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePolicy +// only implements ToObjectValue() and Type(). +func (o DeletePolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -5974,52 +4059,13 @@ func (a DeletePolicyResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePolicyResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePolicyResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePolicyResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePolicyResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePolicyResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePolicyResponse +// only implements ToObjectValue() and Type(). +func (o DeletePolicyResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -6049,59 +4095,20 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{}) } -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o DeleteResponse) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{}, - } +// Type implements basetypes.ObjectValuable. +func (o DeleteResponse) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{}, + } } type DestroyContext struct { @@ -6127,52 +4134,16 @@ func (a DestroyContext) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DestroyContext{} - -// Equal implements basetypes.ObjectValuable. -func (o DestroyContext) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DestroyContext) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DestroyContext) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DestroyContext) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DestroyContext) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DestroyContext +// only implements ToObjectValue() and Type(). +func (o DestroyContext) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DestroyContext) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusterId": o.ClusterId, + "contextId": o.ContextId, + }) } // Type implements basetypes.ObjectValuable. @@ -6205,52 +4176,13 @@ func (a DestroyResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DestroyResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DestroyResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DestroyResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DestroyResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DestroyResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DestroyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DestroyResponse +// only implements ToObjectValue() and Type(). +func (o DestroyResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DestroyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -6314,52 +4246,19 @@ func (a DiskSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DiskSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o DiskSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DiskSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DiskSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DiskSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DiskSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DiskSpec +// only implements ToObjectValue() and Type(). +func (o DiskSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DiskSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "disk_count": o.DiskCount, + "disk_iops": o.DiskIops, + "disk_size": o.DiskSize, + "disk_throughput": o.DiskThroughput, + "disk_type": o.DiskType, + }) } // Type implements basetypes.ObjectValuable. @@ -6400,52 +4299,16 @@ func (a DiskType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DiskType{} - -// Equal implements basetypes.ObjectValuable. -func (o DiskType) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DiskType) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DiskType) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DiskType) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DiskType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DiskType +// only implements ToObjectValue() and Type(). +func (o DiskType) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DiskType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "azure_disk_volume_type": o.AzureDiskVolumeType, + "ebs_volume_type": o.EbsVolumeType, + }) } // Type implements basetypes.ObjectValuable. @@ -6482,52 +4345,16 @@ func (a DockerBasicAuth) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DockerBasicAuth{} - -// Equal implements basetypes.ObjectValuable. -func (o DockerBasicAuth) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DockerBasicAuth) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DockerBasicAuth) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DockerBasicAuth) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DockerBasicAuth) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DockerBasicAuth +// only implements ToObjectValue() and Type(). +func (o DockerBasicAuth) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DockerBasicAuth) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "password": o.Password, + "username": o.Username, + }) } // Type implements basetypes.ObjectValuable. @@ -6565,52 +4392,16 @@ func (a DockerImage) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DockerImage{} - -// Equal implements basetypes.ObjectValuable. -func (o DockerImage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DockerImage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DockerImage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DockerImage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DockerImage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DockerImage +// only implements ToObjectValue() and Type(). +func (o DockerImage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DockerImage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "basic_auth": o.BasicAuth, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -6809,52 +4600,42 @@ func (a EditCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o EditCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditCluster +// only implements ToObjectValue() and Type(). +func (o EditCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "apply_policy_default_values": o.ApplyPolicyDefaultValues, + "autoscale": o.Autoscale, + "autotermination_minutes": o.AutoterminationMinutes, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "cluster_id": o.ClusterId, + "cluster_log_conf": o.ClusterLogConf, + "cluster_name": o.ClusterName, + "custom_tags": o.CustomTags, + "data_security_mode": o.DataSecurityMode, + "docker_image": o.DockerImage, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_elastic_disk": o.EnableElasticDisk, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "node_type_id": o.NodeTypeId, + "num_workers": o.NumWorkers, + "policy_id": o.PolicyId, + "runtime_engine": o.RuntimeEngine, + "single_user_name": o.SingleUserName, + "spark_conf": o.SparkConf, + "spark_env_vars": o.SparkEnvVars, + "spark_version": o.SparkVersion, + "ssh_public_keys": o.SshPublicKeys, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -6937,52 +4718,13 @@ func (a EditClusterResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EditClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditClusterResponse +// only implements ToObjectValue() and Type(). +func (o EditClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7045,52 +4787,21 @@ func (a EditInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditInstancePool{} - -// Equal implements basetypes.ObjectValuable. -func (o EditInstancePool) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditInstancePool) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditInstancePool) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditInstancePool) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditInstancePool +// only implements ToObjectValue() and Type(). +func (o EditInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "custom_tags": o.CustomTags, + "idle_instance_autotermination_minutes": o.IdleInstanceAutoterminationMinutes, + "instance_pool_id": o.InstancePoolId, + "instance_pool_name": o.InstancePoolName, + "max_capacity": o.MaxCapacity, + "min_idle_instances": o.MinIdleInstances, + "node_type_id": o.NodeTypeId, + }) } // Type implements basetypes.ObjectValuable. @@ -7130,52 +4841,13 @@ func (a EditInstancePoolResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditInstancePoolResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EditInstancePoolResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditInstancePoolResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditInstancePoolResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditInstancePoolResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditInstancePoolResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditInstancePoolResponse +// only implements ToObjectValue() and Type(). +func (o EditInstancePoolResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditInstancePoolResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7242,52 +4914,22 @@ func (a EditPolicy) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditPolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o EditPolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditPolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditPolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditPolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditPolicy +// only implements ToObjectValue() and Type(). +func (o EditPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "definition": o.Definition, + "description": o.Description, + "libraries": o.Libraries, + "max_clusters_per_user": o.MaxClustersPerUser, + "name": o.Name, + "policy_family_definition_overrides": o.PolicyFamilyDefinitionOverrides, + "policy_family_id": o.PolicyFamilyId, + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -7328,52 +4970,13 @@ func (a EditPolicyResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditPolicyResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EditPolicyResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditPolicyResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditPolicyResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditPolicyResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditPolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditPolicyResponse +// only implements ToObjectValue() and Type(). +func (o EditPolicyResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditPolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7403,52 +5006,13 @@ func (a EditResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EditResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditResponse +// only implements ToObjectValue() and Type(). +func (o EditResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7483,52 +5047,16 @@ func (a EnforceClusterComplianceRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnforceClusterComplianceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnforceClusterComplianceRequest +// only implements ToObjectValue() and Type(). +func (o EnforceClusterComplianceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "validate_only": o.ValidateOnly, + }) } // Type implements basetypes.ObjectValuable. @@ -7569,52 +5097,16 @@ func (a EnforceClusterComplianceResponse) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnforceClusterComplianceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnforceClusterComplianceResponse +// only implements ToObjectValue() and Type(). +func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnforceClusterComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "changes": o.Changes, + "has_changes": o.HasChanges, + }) } // Type implements basetypes.ObjectValuable. @@ -7666,52 +5158,16 @@ func (a Environment) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Environment{} - -// Equal implements basetypes.ObjectValuable. -func (o Environment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Environment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Environment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Environment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Environment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Environment +// only implements ToObjectValue() and Type(). +func (o Environment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Environment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "client": o.Client, + "dependencies": o.Dependencies, + }) } // Type implements basetypes.ObjectValuable. @@ -7801,52 +5257,34 @@ func (a EventDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EventDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o EventDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EventDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EventDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EventDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EventDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EventDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EventDetails +// only implements ToObjectValue() and Type(). +func (o EventDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "attributes": o.Attributes, + "cause": o.Cause, + "cluster_size": o.ClusterSize, + "current_num_vcpus": o.CurrentNumVcpus, + "current_num_workers": o.CurrentNumWorkers, + "did_not_expand_reason": o.DidNotExpandReason, + "disk_size": o.DiskSize, + "driver_state_message": o.DriverStateMessage, + "enable_termination_for_node_blocklisted": o.EnableTerminationForNodeBlocklisted, + "free_space": o.FreeSpace, + "init_scripts": o.InitScripts, + "instance_id": o.InstanceId, + "job_run_name": o.JobRunName, + "previous_attributes": o.PreviousAttributes, + "previous_cluster_size": o.PreviousClusterSize, + "previous_disk_size": o.PreviousDiskSize, + "reason": o.Reason, + "target_num_vcpus": o.TargetNumVcpus, + "target_num_workers": o.TargetNumWorkers, + "user": o.User, + }) } // Type implements basetypes.ObjectValuable. @@ -7940,52 +5378,20 @@ func (a GcpAttributes) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpAttributes +// only implements ToObjectValue() and Type(). +func (o GcpAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "availability": o.Availability, + "boot_disk_size": o.BootDiskSize, + "google_service_account": o.GoogleServiceAccount, + "local_ssd_count": o.LocalSsdCount, + "use_preemptible_executors": o.UsePreemptibleExecutors, + "zone_id": o.ZoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -8024,52 +5430,15 @@ func (a GcsStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcsStorageInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o GcsStorageInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcsStorageInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcsStorageInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcsStorageInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcsStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcsStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcsStorageInfo +// only implements ToObjectValue() and Type(). +func (o GcsStorageInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "destination": o.Destination, + }) } // Type implements basetypes.ObjectValuable. @@ -8104,52 +5473,15 @@ func (a GetClusterComplianceRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterComplianceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterComplianceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterComplianceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterComplianceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterComplianceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterComplianceRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterComplianceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -8192,52 +5524,16 @@ func (a GetClusterComplianceResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterComplianceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterComplianceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterComplianceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterComplianceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterComplianceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterComplianceResponse +// only implements ToObjectValue() and Type(). +func (o GetClusterComplianceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_compliant": o.IsCompliant, + "violations": o.Violations, + }) } // Type implements basetypes.ObjectValuable. @@ -8275,52 +5571,15 @@ func (a GetClusterPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -8356,52 +5615,15 @@ func (a GetClusterPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -8438,52 +5660,15 @@ func (a GetClusterPermissionsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -8518,52 +5703,15 @@ func (a GetClusterPolicyPermissionLevelsRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPolicyPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPolicyPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterPolicyPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_policy_id": o.ClusterPolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -8599,52 +5747,15 @@ func (a GetClusterPolicyPermissionLevelsResponse) GetComplexFieldTypes(ctx conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPolicyPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPolicyPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -8681,52 +5792,15 @@ func (a GetClusterPolicyPermissionsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPolicyPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPolicyPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_policy_id": o.ClusterPolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -8761,52 +5835,15 @@ func (a GetClusterPolicyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterPolicyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterPolicyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterPolicyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterPolicyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterPolicyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterPolicyRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterPolicyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterPolicyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -8841,52 +5878,15 @@ func (a GetClusterRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetClusterRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetClusterRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetClusterRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetClusterRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetClusterRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetClusterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetClusterRequest +// only implements ToObjectValue() and Type(). +func (o GetClusterRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetClusterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -8940,52 +5940,21 @@ func (a GetEvents) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEvents{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEvents) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEvents) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEvents) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEvents) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEvents) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEvents +// only implements ToObjectValue() and Type(). +func (o GetEvents) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEvents) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "end_time": o.EndTime, + "event_types": o.EventTypes, + "limit": o.Limit, + "offset": o.Offset, + "order": o.Order, + "start_time": o.StartTime, + }) } // Type implements basetypes.ObjectValuable. @@ -9036,52 +6005,17 @@ func (a GetEventsResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEventsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEventsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEventsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEventsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEventsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEventsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEventsResponse +// only implements ToObjectValue() and Type(). +func (o GetEventsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEventsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "events": o.Events, + "next_page": o.NextPage, + "total_count": o.TotalCount, + }) } // Type implements basetypes.ObjectValuable. @@ -9122,52 +6056,15 @@ func (a GetGlobalInitScriptRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetGlobalInitScriptRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetGlobalInitScriptRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetGlobalInitScriptRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetGlobalInitScriptRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetGlobalInitScriptRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetGlobalInitScriptRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetGlobalInitScriptRequest +// only implements ToObjectValue() and Type(). +func (o GetGlobalInitScriptRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetGlobalInitScriptRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "script_id": o.ScriptId, + }) } // Type implements basetypes.ObjectValuable. @@ -9283,52 +6180,32 @@ func (a GetInstancePool) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetInstancePool{} - -// Equal implements basetypes.ObjectValuable. -func (o GetInstancePool) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetInstancePool) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetInstancePool) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetInstancePool) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetInstancePool) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetInstancePool) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetInstancePool +// only implements ToObjectValue() and Type(). +func (o GetInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "custom_tags": o.CustomTags, + "default_tags": o.DefaultTags, + "disk_spec": o.DiskSpec, + "enable_elastic_disk": o.EnableElasticDisk, + "gcp_attributes": o.GcpAttributes, + "idle_instance_autotermination_minutes": o.IdleInstanceAutoterminationMinutes, + "instance_pool_id": o.InstancePoolId, + "instance_pool_name": o.InstancePoolName, + "max_capacity": o.MaxCapacity, + "min_idle_instances": o.MinIdleInstances, + "node_type_id": o.NodeTypeId, + "preloaded_docker_images": o.PreloadedDockerImages, + "preloaded_spark_versions": o.PreloadedSparkVersions, + "state": o.State, + "stats": o.Stats, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -9400,52 +6277,15 @@ func (a GetInstancePoolPermissionLevelsRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetInstancePoolPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetInstancePoolPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetInstancePoolPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_pool_id": o.InstancePoolId, + }) } // Type implements basetypes.ObjectValuable. @@ -9481,52 +6321,15 @@ func (a GetInstancePoolPermissionLevelsResponse) GetComplexFieldTypes(ctx contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetInstancePoolPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetInstancePoolPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -9563,52 +6366,15 @@ func (a GetInstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetInstancePoolPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetInstancePoolPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetInstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetInstancePoolPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_pool_id": o.InstancePoolId, + }) } // Type implements basetypes.ObjectValuable. @@ -9643,52 +6409,15 @@ func (a GetInstancePoolRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetInstancePoolRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetInstancePoolRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetInstancePoolRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetInstancePoolRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetInstancePoolRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetInstancePoolRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetInstancePoolRequest +// only implements ToObjectValue() and Type(). +func (o GetInstancePoolRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetInstancePoolRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_pool_id": o.InstancePoolId, + }) } // Type implements basetypes.ObjectValuable. @@ -9726,61 +6455,25 @@ func (a GetPolicyFamilyRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPolicyFamilyRequest{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPolicyFamilyRequest +// only implements ToObjectValue() and Type(). +func (o GetPolicyFamilyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "policy_family_id": o.PolicyFamilyId, + "version": o.Version, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o GetPolicyFamilyRequest) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "policy_family_id": types.StringType, - "version": types.Int64Type, - }, +// Type implements basetypes.ObjectValuable. +func (o GetPolicyFamilyRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "policy_family_id": types.StringType, + "version": types.Int64Type, + }, } } @@ -9808,52 +6501,15 @@ func (a GetSparkVersionsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetSparkVersionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetSparkVersionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetSparkVersionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetSparkVersionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetSparkVersionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetSparkVersionsResponse +// only implements ToObjectValue() and Type(). +func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetSparkVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "versions": o.Versions, + }) } // Type implements basetypes.ObjectValuable. @@ -9905,52 +6561,18 @@ func (a GlobalInitScriptCreateRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GlobalInitScriptCreateRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GlobalInitScriptCreateRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GlobalInitScriptCreateRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GlobalInitScriptCreateRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GlobalInitScriptCreateRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptCreateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GlobalInitScriptCreateRequest +// only implements ToObjectValue() and Type(). +func (o GlobalInitScriptCreateRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptCreateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + "name": o.Name, + "position": o.Position, + "script": o.Script, + }) } // Type implements basetypes.ObjectValuable. @@ -10004,52 +6626,22 @@ func (a GlobalInitScriptDetails) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GlobalInitScriptDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GlobalInitScriptDetails +// only implements ToObjectValue() and Type(). +func (o GlobalInitScriptDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "enabled": o.Enabled, + "name": o.Name, + "position": o.Position, + "script_id": o.ScriptId, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -10109,52 +6701,23 @@ func (a GlobalInitScriptDetailsWithContent) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GlobalInitScriptDetailsWithContent{} - -// Equal implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetailsWithContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetailsWithContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetailsWithContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetailsWithContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetailsWithContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GlobalInitScriptDetailsWithContent +// only implements ToObjectValue() and Type(). +func (o GlobalInitScriptDetailsWithContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptDetailsWithContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "enabled": o.Enabled, + "name": o.Name, + "position": o.Position, + "script": o.Script, + "script_id": o.ScriptId, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -10215,52 +6778,19 @@ func (a GlobalInitScriptUpdateRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GlobalInitScriptUpdateRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GlobalInitScriptUpdateRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GlobalInitScriptUpdateRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GlobalInitScriptUpdateRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GlobalInitScriptUpdateRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptUpdateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GlobalInitScriptUpdateRequest +// only implements ToObjectValue() and Type(). +func (o GlobalInitScriptUpdateRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GlobalInitScriptUpdateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + "name": o.Name, + "position": o.Position, + "script": o.Script, + "script_id": o.ScriptId, + }) } // Type implements basetypes.ObjectValuable. @@ -10305,52 +6835,17 @@ func (a InitScriptEventDetails) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InitScriptEventDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InitScriptEventDetails +// only implements ToObjectValue() and Type(). +func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster": o.Cluster, + "global": o.Global, + "reported_for_node": o.ReportedForNode, + }) } // Type implements basetypes.ObjectValuable. @@ -10394,52 +6889,17 @@ func (a InitScriptExecutionDetails) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InitScriptExecutionDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o InitScriptExecutionDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InitScriptExecutionDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InitScriptExecutionDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InitScriptExecutionDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InitScriptExecutionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InitScriptExecutionDetails +// only implements ToObjectValue() and Type(). +func (o InitScriptExecutionDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InitScriptExecutionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error_message": o.ErrorMessage, + "execution_duration_seconds": o.ExecutionDurationSeconds, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -10506,52 +6966,21 @@ func (a InitScriptInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InitScriptInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o InitScriptInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InitScriptInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InitScriptInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InitScriptInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InitScriptInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InitScriptInfo +// only implements ToObjectValue() and Type(). +func (o InitScriptInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InitScriptInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "abfss": o.Abfss, + "dbfs": o.Dbfs, + "file": o.File, + "gcs": o.Gcs, + "s3": o.S3, + "volumes": o.Volumes, + "workspace": o.Workspace, + }) } // Type implements basetypes.ObjectValuable. @@ -10610,52 +7039,16 @@ func (a InitScriptInfoAndExecutionDetails) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InitScriptInfoAndExecutionDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o InitScriptInfoAndExecutionDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InitScriptInfoAndExecutionDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InitScriptInfoAndExecutionDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InitScriptInfoAndExecutionDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InitScriptInfoAndExecutionDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InitScriptInfoAndExecutionDetails +// only implements ToObjectValue() and Type(). +func (o InitScriptInfoAndExecutionDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InitScriptInfoAndExecutionDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "execution_details": o.ExecutionDetails, + "script": o.Script, + }) } // Type implements basetypes.ObjectValuable. @@ -10698,52 +7091,16 @@ func (a InstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstallLibraries{} - -// Equal implements basetypes.ObjectValuable. -func (o InstallLibraries) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstallLibraries) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstallLibraries) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstallLibraries) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstallLibraries) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstallLibraries +// only implements ToObjectValue() and Type(). +func (o InstallLibraries) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstallLibraries) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "libraries": o.Libraries, + }) } // Type implements basetypes.ObjectValuable. @@ -10778,52 +7135,13 @@ func (a InstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstallLibrariesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o InstallLibrariesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstallLibrariesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstallLibrariesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstallLibrariesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstallLibrariesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstallLibrariesResponse +// only implements ToObjectValue() and Type(). +func (o InstallLibrariesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstallLibrariesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -10861,52 +7179,18 @@ func (a InstancePoolAccessControlRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o InstancePoolAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -10953,52 +7237,19 @@ func (a InstancePoolAccessControlResponse) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -11120,52 +7371,32 @@ func (a InstancePoolAndStats) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolAndStats{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolAndStats) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolAndStats) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolAndStats) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolAndStats) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolAndStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolAndStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolAndStats +// only implements ToObjectValue() and Type(). +func (o InstancePoolAndStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "custom_tags": o.CustomTags, + "default_tags": o.DefaultTags, + "disk_spec": o.DiskSpec, + "enable_elastic_disk": o.EnableElasticDisk, + "gcp_attributes": o.GcpAttributes, + "idle_instance_autotermination_minutes": o.IdleInstanceAutoterminationMinutes, + "instance_pool_id": o.InstancePoolId, + "instance_pool_name": o.InstancePoolName, + "max_capacity": o.MaxCapacity, + "min_idle_instances": o.MinIdleInstances, + "node_type_id": o.NodeTypeId, + "preloaded_docker_images": o.PreloadedDockerImages, + "preloaded_spark_versions": o.PreloadedSparkVersions, + "state": o.State, + "stats": o.Stats, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -11263,52 +7494,17 @@ func (a InstancePoolAwsAttributes) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolAwsAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolAwsAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolAwsAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolAwsAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolAwsAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolAwsAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolAwsAttributes +// only implements ToObjectValue() and Type(). +func (o InstancePoolAwsAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolAwsAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "availability": o.Availability, + "spot_bid_price_percent": o.SpotBidPricePercent, + "zone_id": o.ZoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -11350,52 +7546,16 @@ func (a InstancePoolAzureAttributes) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolAzureAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolAzureAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolAzureAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolAzureAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolAzureAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolAzureAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolAzureAttributes +// only implements ToObjectValue() and Type(). +func (o InstancePoolAzureAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolAzureAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "availability": o.Availability, + "spot_bid_max_price": o.SpotBidMaxPrice, + }) } // Type implements basetypes.ObjectValuable. @@ -11456,52 +7616,17 @@ func (a InstancePoolGcpAttributes) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolGcpAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolGcpAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolGcpAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolGcpAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolGcpAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolGcpAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolGcpAttributes +// only implements ToObjectValue() and Type(). +func (o InstancePoolGcpAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolGcpAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "gcp_availability": o.GcpAvailability, + "local_ssd_count": o.LocalSsdCount, + "zone_id": o.ZoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -11542,64 +7667,29 @@ func (a InstancePoolPermission) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolPermission{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolPermission +// only implements ToObjectValue() and Type(). +func (o InstancePoolPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o InstancePoolPermission) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, - }, +// Type implements basetypes.ObjectValuable. +func (o InstancePoolPermission) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, + }, } } @@ -11630,52 +7720,17 @@ func (a InstancePoolPermissions) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolPermissions +// only implements ToObjectValue() and Type(). +func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -11714,52 +7769,16 @@ func (a InstancePoolPermissionsDescription) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o InstancePoolPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -11797,52 +7816,16 @@ func (a InstancePoolPermissionsRequest) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "instance_pool_id": o.InstancePoolId, + }) } // Type implements basetypes.ObjectValuable. @@ -11885,52 +7868,18 @@ func (a InstancePoolStats) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolStats{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolStats) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolStats) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolStats) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolStats) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolStats +// only implements ToObjectValue() and Type(). +func (o InstancePoolStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "idle_count": o.IdleCount, + "pending_idle_count": o.PendingIdleCount, + "pending_used_count": o.PendingUsedCount, + "used_count": o.UsedCount, + }) } // Type implements basetypes.ObjectValuable. @@ -11972,52 +7921,15 @@ func (a InstancePoolStatus) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstancePoolStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o InstancePoolStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstancePoolStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstancePoolStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstancePoolStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstancePoolStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstancePoolStatus +// only implements ToObjectValue() and Type(). +func (o InstancePoolStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstancePoolStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pending_instance_errors": o.PendingInstanceErrors, + }) } // Type implements basetypes.ObjectValuable. @@ -12069,52 +7981,17 @@ func (a InstanceProfile) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstanceProfile{} - -// Equal implements basetypes.ObjectValuable. -func (o InstanceProfile) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstanceProfile) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstanceProfile) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstanceProfile) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstanceProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstanceProfile +// only implements ToObjectValue() and Type(). +func (o InstanceProfile) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstanceProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "iam_role_arn": o.IamRoleArn, + "instance_profile_arn": o.InstanceProfileArn, + "is_meta_instance_profile": o.IsMetaInstanceProfile, + }) } // Type implements basetypes.ObjectValuable. @@ -12185,52 +8062,21 @@ func (a Library) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Library{} - -// Equal implements basetypes.ObjectValuable. -func (o Library) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Library) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Library) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Library) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Library) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Library +// only implements ToObjectValue() and Type(). +func (o Library) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Library) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cran": o.Cran, + "egg": o.Egg, + "jar": o.Jar, + "maven": o.Maven, + "pypi": o.Pypi, + "requirements": o.Requirements, + "whl": o.Whl, + }) } // Type implements basetypes.ObjectValuable. @@ -12288,52 +8134,18 @@ func (a LibraryFullStatus) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LibraryFullStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o LibraryFullStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LibraryFullStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LibraryFullStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LibraryFullStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LibraryFullStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LibraryFullStatus +// only implements ToObjectValue() and Type(). +func (o LibraryFullStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LibraryFullStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_library_for_all_clusters": o.IsLibraryForAllClusters, + "library": o.Library, + "messages": o.Messages, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -12376,52 +8188,15 @@ func (a ListAllClusterLibraryStatusesResponse) GetComplexFieldTypes(ctx context. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAllClusterLibraryStatusesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAllClusterLibraryStatusesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAllClusterLibraryStatusesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAllClusterLibraryStatusesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAllClusterLibraryStatusesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAllClusterLibraryStatusesResponse +// only implements ToObjectValue() and Type(). +func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAllClusterLibraryStatusesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "statuses": o.Statuses, + }) } // Type implements basetypes.ObjectValuable. @@ -12462,52 +8237,16 @@ func (a ListAvailableZonesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAvailableZonesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAvailableZonesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAvailableZonesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAvailableZonesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAvailableZonesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAvailableZonesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAvailableZonesResponse +// only implements ToObjectValue() and Type(). +func (o ListAvailableZonesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAvailableZonesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default_zone": o.DefaultZone, + "zones": o.Zones, + }) } // Type implements basetypes.ObjectValuable. @@ -12552,52 +8291,17 @@ func (a ListClusterCompliancesRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClusterCompliancesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClusterCompliancesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClusterCompliancesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClusterCompliancesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClusterCompliancesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClusterCompliancesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClusterCompliancesRequest +// only implements ToObjectValue() and Type(). +func (o ListClusterCompliancesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClusterCompliancesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -12642,52 +8346,17 @@ func (a ListClusterCompliancesResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClusterCompliancesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClusterCompliancesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClusterCompliancesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClusterCompliancesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClusterCompliancesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClusterCompliancesResponse +// only implements ToObjectValue() and Type(). +func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClusterCompliancesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusters": o.Clusters, + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -12731,52 +8400,16 @@ func (a ListClusterPoliciesRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClusterPoliciesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClusterPoliciesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClusterPoliciesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClusterPoliciesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClusterPoliciesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClusterPoliciesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClusterPoliciesRequest +// only implements ToObjectValue() and Type(). +func (o ListClusterPoliciesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClusterPoliciesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "sort_column": o.SortColumn, + "sort_order": o.SortOrder, + }) } // Type implements basetypes.ObjectValuable. @@ -12820,52 +8453,18 @@ func (a ListClustersFilterBy) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClustersFilterBy{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClustersFilterBy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClustersFilterBy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClustersFilterBy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClustersFilterBy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClustersFilterBy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClustersFilterBy +// only implements ToObjectValue() and Type(). +func (o ListClustersFilterBy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClustersFilterBy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_sources": o.ClusterSources, + "cluster_states": o.ClusterStates, + "is_pinned": o.IsPinned, + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -12919,52 +8518,18 @@ func (a ListClustersRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClustersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClustersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClustersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClustersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClustersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClustersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClustersRequest +// only implements ToObjectValue() and Type(). +func (o ListClustersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClustersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter_by": o.FilterBy, + "page_size": o.PageSize, + "page_token": o.PageToken, + "sort_by": o.SortBy, + }) } // Type implements basetypes.ObjectValuable. @@ -13014,52 +8579,17 @@ func (a ListClustersResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClustersResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClustersResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClustersResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClustersResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClustersResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClustersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClustersResponse +// only implements ToObjectValue() and Type(). +func (o ListClustersResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClustersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clusters": o.Clusters, + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -13101,52 +8631,16 @@ func (a ListClustersSortBy) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListClustersSortBy{} - -// Equal implements basetypes.ObjectValuable. -func (o ListClustersSortBy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListClustersSortBy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListClustersSortBy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListClustersSortBy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListClustersSortBy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListClustersSortBy +// only implements ToObjectValue() and Type(). +func (o ListClustersSortBy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListClustersSortBy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "direction": o.Direction, + "field": o.Field, + }) } // Type implements basetypes.ObjectValuable. @@ -13182,52 +8676,15 @@ func (a ListGlobalInitScriptsResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListGlobalInitScriptsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListGlobalInitScriptsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListGlobalInitScriptsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListGlobalInitScriptsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListGlobalInitScriptsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListGlobalInitScriptsResponse +// only implements ToObjectValue() and Type(). +func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListGlobalInitScriptsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "scripts": o.Scripts, + }) } // Type implements basetypes.ObjectValuable. @@ -13264,52 +8721,15 @@ func (a ListInstancePools) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListInstancePools{} - -// Equal implements basetypes.ObjectValuable. -func (o ListInstancePools) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListInstancePools) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListInstancePools) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListInstancePools) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListInstancePools) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListInstancePools +// only implements ToObjectValue() and Type(). +func (o ListInstancePools) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListInstancePools) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_pools": o.InstancePools, + }) } // Type implements basetypes.ObjectValuable. @@ -13347,52 +8767,15 @@ func (a ListInstanceProfilesResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListInstanceProfilesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListInstanceProfilesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListInstanceProfilesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListInstanceProfilesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListInstanceProfilesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListInstanceProfilesResponse +// only implements ToObjectValue() and Type(). +func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListInstanceProfilesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_profiles": o.InstanceProfiles, + }) } // Type implements basetypes.ObjectValuable. @@ -13430,52 +8813,15 @@ func (a ListNodeTypesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNodeTypesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNodeTypesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNodeTypesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNodeTypesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNodeTypesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNodeTypesResponse +// only implements ToObjectValue() and Type(). +func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNodeTypesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "node_types": o.NodeTypes, + }) } // Type implements basetypes.ObjectValuable. @@ -13513,52 +8859,15 @@ func (a ListPoliciesResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPoliciesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPoliciesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPoliciesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPoliciesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPoliciesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPoliciesResponse +// only implements ToObjectValue() and Type(). +func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPoliciesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "policies": o.Policies, + }) } // Type implements basetypes.ObjectValuable. @@ -13597,52 +8906,16 @@ func (a ListPolicyFamiliesRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPolicyFamiliesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPolicyFamiliesRequest +// only implements ToObjectValue() and Type(). +func (o ListPolicyFamiliesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -13682,52 +8955,16 @@ func (a ListPolicyFamiliesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPolicyFamiliesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPolicyFamiliesResponse +// only implements ToObjectValue() and Type(). +func (o ListPolicyFamiliesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPolicyFamiliesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "policy_families": o.PolicyFamilies, + }) } // Type implements basetypes.ObjectValuable. @@ -13764,52 +9001,15 @@ func (a LocalFileInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LocalFileInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o LocalFileInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LocalFileInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LocalFileInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LocalFileInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LocalFileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LocalFileInfo +// only implements ToObjectValue() and Type(). +func (o LocalFileInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LocalFileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination": o.Destination, + }) } // Type implements basetypes.ObjectValuable. @@ -13840,57 +9040,21 @@ func (newState *LogAnalyticsInfo) SyncEffectiveFieldsDuringRead(existingState Lo // retrieve the type information of the elements in complex fields at runtime. The values of the map // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a LogAnalyticsInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogAnalyticsInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o LogAnalyticsInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogAnalyticsInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogAnalyticsInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogAnalyticsInfo) String() string { - return fmt.Sprintf("%#v", o) +// SDK values. +func (a LogAnalyticsInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogAnalyticsInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogAnalyticsInfo +// only implements ToObjectValue() and Type(). +func (o LogAnalyticsInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogAnalyticsInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "log_analytics_primary_key": o.LogAnalyticsPrimaryKey, + "log_analytics_workspace_id": o.LogAnalyticsWorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -13929,52 +9093,16 @@ func (a LogSyncStatus) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogSyncStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o LogSyncStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogSyncStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogSyncStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogSyncStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogSyncStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogSyncStatus +// only implements ToObjectValue() and Type(). +func (o LogSyncStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogSyncStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "last_attempted": o.LastAttempted, + "last_exception": o.LastException, + }) } // Type implements basetypes.ObjectValuable. @@ -14020,52 +9148,17 @@ func (a MavenLibrary) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MavenLibrary{} - -// Equal implements basetypes.ObjectValuable. -func (o MavenLibrary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MavenLibrary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MavenLibrary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MavenLibrary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MavenLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MavenLibrary +// only implements ToObjectValue() and Type(). +func (o MavenLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MavenLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "coordinates": o.Coordinates, + "exclusions": o.Exclusions, + "repo": o.Repo, + }) } // Type implements basetypes.ObjectValuable. @@ -14110,52 +9203,19 @@ func (a NodeInstanceType) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NodeInstanceType{} - -// Equal implements basetypes.ObjectValuable. -func (o NodeInstanceType) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NodeInstanceType) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NodeInstanceType) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NodeInstanceType) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NodeInstanceType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NodeInstanceType +// only implements ToObjectValue() and Type(). +func (o NodeInstanceType) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NodeInstanceType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_type_id": o.InstanceTypeId, + "local_disk_size_gb": o.LocalDiskSizeGb, + "local_disks": o.LocalDisks, + "local_nvme_disk_size_gb": o.LocalNvmeDiskSizeGb, + "local_nvme_disks": o.LocalNvmeDisks, + }) } // Type implements basetypes.ObjectValuable. @@ -14241,52 +9301,35 @@ func (a NodeType) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NodeType{} - -// Equal implements basetypes.ObjectValuable. -func (o NodeType) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NodeType) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NodeType) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NodeType) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NodeType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NodeType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NodeType +// only implements ToObjectValue() and Type(). +func (o NodeType) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "category": o.Category, + "description": o.Description, + "display_order": o.DisplayOrder, + "instance_type_id": o.InstanceTypeId, + "is_deprecated": o.IsDeprecated, + "is_encrypted_in_transit": o.IsEncryptedInTransit, + "is_graviton": o.IsGraviton, + "is_hidden": o.IsHidden, + "is_io_cache_enabled": o.IsIoCacheEnabled, + "memory_mb": o.MemoryMb, + "node_info": o.NodeInfo, + "node_instance_type": o.NodeInstanceType, + "node_type_id": o.NodeTypeId, + "num_cores": o.NumCores, + "num_gpus": o.NumGpus, + "photon_driver_capable": o.PhotonDriverCapable, + "photon_worker_capable": o.PhotonWorkerCapable, + "support_cluster_tags": o.SupportClusterTags, + "support_ebs_volumes": o.SupportEbsVolumes, + "support_port_forwarding": o.SupportPortForwarding, + "supports_elastic_disk": o.SupportsElasticDisk, + }) } // Type implements basetypes.ObjectValuable. @@ -14345,52 +9388,16 @@ func (a PendingInstanceError) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PendingInstanceError{} - -// Equal implements basetypes.ObjectValuable. -func (o PendingInstanceError) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PendingInstanceError) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PendingInstanceError) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PendingInstanceError) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PendingInstanceError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PendingInstanceError +// only implements ToObjectValue() and Type(). +func (o PendingInstanceError) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PendingInstanceError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_id": o.InstanceId, + "message": o.Message, + }) } // Type implements basetypes.ObjectValuable. @@ -14425,52 +9432,15 @@ func (a PermanentDeleteCluster) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermanentDeleteCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o PermanentDeleteCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermanentDeleteCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermanentDeleteCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermanentDeleteCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermanentDeleteCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermanentDeleteCluster +// only implements ToObjectValue() and Type(). +func (o PermanentDeleteCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermanentDeleteCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -14502,52 +9472,13 @@ func (a PermanentDeleteClusterResponse) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermanentDeleteClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PermanentDeleteClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermanentDeleteClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermanentDeleteClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermanentDeleteClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermanentDeleteClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermanentDeleteClusterResponse +// only implements ToObjectValue() and Type(). +func (o PermanentDeleteClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermanentDeleteClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -14579,52 +9510,15 @@ func (a PinCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PinCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o PinCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PinCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PinCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PinCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PinCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PinCluster +// only implements ToObjectValue() and Type(). +func (o PinCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PinCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -14656,52 +9550,13 @@ func (a PinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PinClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PinClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PinClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PinClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PinClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PinClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PinClusterResponse +// only implements ToObjectValue() and Type(). +func (o PinClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PinClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -14779,52 +9634,25 @@ func (a Policy) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Policy{} - -// Equal implements basetypes.ObjectValuable. -func (o Policy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Policy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Policy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Policy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Policy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Policy +// only implements ToObjectValue() and Type(). +func (o Policy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Policy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at_timestamp": o.CreatedAtTimestamp, + "creator_user_name": o.CreatorUserName, + "definition": o.Definition, + "description": o.Description, + "is_default": o.IsDefault, + "libraries": o.Libraries, + "max_clusters_per_user": o.MaxClustersPerUser, + "name": o.Name, + "policy_family_definition_overrides": o.PolicyFamilyDefinitionOverrides, + "policy_family_id": o.PolicyFamilyId, + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -14879,52 +9707,18 @@ func (a PolicyFamily) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PolicyFamily{} - -// Equal implements basetypes.ObjectValuable. -func (o PolicyFamily) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PolicyFamily) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PolicyFamily) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PolicyFamily) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PolicyFamily) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PolicyFamily +// only implements ToObjectValue() and Type(). +func (o PolicyFamily) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PolicyFamily) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "definition": o.Definition, + "description": o.Description, + "name": o.Name, + "policy_family_id": o.PolicyFamilyId, + }) } // Type implements basetypes.ObjectValuable. @@ -14966,52 +9760,16 @@ func (a PythonPyPiLibrary) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PythonPyPiLibrary{} - -// Equal implements basetypes.ObjectValuable. -func (o PythonPyPiLibrary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PythonPyPiLibrary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PythonPyPiLibrary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PythonPyPiLibrary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PythonPyPiLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PythonPyPiLibrary +// only implements ToObjectValue() and Type(). +func (o PythonPyPiLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PythonPyPiLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "package": o.Package, + "repo": o.Repo, + }) } // Type implements basetypes.ObjectValuable. @@ -15049,52 +9807,16 @@ func (a RCranLibrary) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RCranLibrary{} - -// Equal implements basetypes.ObjectValuable. -func (o RCranLibrary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RCranLibrary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RCranLibrary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RCranLibrary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RCranLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RCranLibrary +// only implements ToObjectValue() and Type(). +func (o RCranLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RCranLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "package": o.Package, + "repo": o.Repo, + }) } // Type implements basetypes.ObjectValuable. @@ -15129,52 +9851,15 @@ func (a RemoveInstanceProfile) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RemoveInstanceProfile{} - -// Equal implements basetypes.ObjectValuable. -func (o RemoveInstanceProfile) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RemoveInstanceProfile) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RemoveInstanceProfile) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RemoveInstanceProfile) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RemoveInstanceProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RemoveInstanceProfile +// only implements ToObjectValue() and Type(). +func (o RemoveInstanceProfile) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RemoveInstanceProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance_profile_arn": o.InstanceProfileArn, + }) } // Type implements basetypes.ObjectValuable. @@ -15206,52 +9891,13 @@ func (a RemoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RemoveResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RemoveResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RemoveResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RemoveResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RemoveResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RemoveResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RemoveResponse +// only implements ToObjectValue() and Type(). +func (o RemoveResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RemoveResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -15300,52 +9946,17 @@ func (a ResizeCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResizeCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o ResizeCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResizeCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResizeCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResizeCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResizeCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResizeCluster +// only implements ToObjectValue() and Type(). +func (o ResizeCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResizeCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "autoscale": o.Autoscale, + "cluster_id": o.ClusterId, + "num_workers": o.NumWorkers, + }) } // Type implements basetypes.ObjectValuable. @@ -15381,52 +9992,13 @@ func (a ResizeClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResizeClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ResizeClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResizeClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResizeClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResizeClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResizeClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResizeClusterResponse +// only implements ToObjectValue() and Type(). +func (o ResizeClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResizeClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -15460,52 +10032,16 @@ func (a RestartCluster) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestartCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o RestartCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestartCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestartCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestartCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestartCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestartCluster +// only implements ToObjectValue() and Type(). +func (o RestartCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestartCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "restart_user": o.RestartUser, + }) } // Type implements basetypes.ObjectValuable. @@ -15531,59 +10067,20 @@ func (newState *RestartClusterResponse) SyncEffectiveFieldsDuringRead(existingSt // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to // retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a RestartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestartClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RestartClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestartClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestartClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestartClusterResponse) String() string { - return fmt.Sprintf("%#v", o) +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a RestartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestartClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestartClusterResponse +// only implements ToObjectValue() and Type(). +func (o RestartClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestartClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -15597,7 +10094,7 @@ type Results struct { // The cause of the error Cause types.String `tfsdk:"cause" tf:"optional"` - Data any `tfsdk:"data" tf:"optional"` + Data types.Object `tfsdk:"data" tf:"optional"` // The image filename FileName types.String `tfsdk:"fileName" tf:"optional"` @@ -15633,56 +10130,28 @@ func (newState *Results) SyncEffectiveFieldsDuringRead(existingState Results) { func (a Results) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "fileNames": reflect.TypeOf(types.String{}), - "schema": reflect.TypeOf(struct{}{}), + "schema": reflect.TypeOf(types.Object{}), } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Results{} - -// Equal implements basetypes.ObjectValuable. -func (o Results) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Results) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Results) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Results) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Results) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Results +// only implements ToObjectValue() and Type(). +func (o Results) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Results) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cause": o.Cause, + "data": o.Data, + "fileName": o.FileName, + "fileNames": o.FileNames, + "isJsonSchema": o.IsJsonSchema, + "pos": o.Pos, + "resultType": o.ResultType, + "schema": o.Schema, + "summary": o.Summary, + "truncated": o.Truncated, + }) } // Type implements basetypes.ObjectValuable. @@ -15759,52 +10228,21 @@ func (a S3StorageInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = S3StorageInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o S3StorageInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o S3StorageInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o S3StorageInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o S3StorageInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o S3StorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, S3StorageInfo +// only implements ToObjectValue() and Type(). +func (o S3StorageInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o S3StorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "canned_acl": o.CannedAcl, + "destination": o.Destination, + "enable_encryption": o.EnableEncryption, + "encryption_type": o.EncryptionType, + "endpoint": o.Endpoint, + "kms_key": o.KmsKey, + "region": o.Region, + }) } // Type implements basetypes.ObjectValuable. @@ -15869,52 +10307,21 @@ func (a SparkNode) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparkNode{} - -// Equal implements basetypes.ObjectValuable. -func (o SparkNode) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparkNode) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparkNode) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparkNode) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparkNode) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparkNode +// only implements ToObjectValue() and Type(). +func (o SparkNode) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparkNode) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "host_private_ip": o.HostPrivateIp, + "instance_id": o.InstanceId, + "node_aws_attributes": o.NodeAwsAttributes, + "node_id": o.NodeId, + "private_ip": o.PrivateIp, + "public_dns": o.PublicDns, + "start_timestamp": o.StartTimestamp, + }) } // Type implements basetypes.ObjectValuable. @@ -15956,52 +10363,15 @@ func (a SparkNodeAwsAttributes) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparkNodeAwsAttributes{} - -// Equal implements basetypes.ObjectValuable. -func (o SparkNodeAwsAttributes) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparkNodeAwsAttributes) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparkNodeAwsAttributes) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparkNodeAwsAttributes) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparkNodeAwsAttributes) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparkNodeAwsAttributes +// only implements ToObjectValue() and Type(). +func (o SparkNodeAwsAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparkNodeAwsAttributes) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_spot": o.IsSpot, + }) } // Type implements basetypes.ObjectValuable. @@ -16041,52 +10411,16 @@ func (a SparkVersion) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparkVersion{} - -// Equal implements basetypes.ObjectValuable. -func (o SparkVersion) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparkVersion) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparkVersion) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparkVersion) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparkVersion) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparkVersion +// only implements ToObjectValue() and Type(). +func (o SparkVersion) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparkVersion) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -16121,52 +10455,15 @@ func (a StartCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o StartCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartCluster +// only implements ToObjectValue() and Type(). +func (o StartCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -16198,52 +10495,13 @@ func (a StartClusterResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o StartClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartClusterResponse +// only implements ToObjectValue() and Type(). +func (o StartClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -16282,52 +10540,17 @@ func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TerminationReason{} - -// Equal implements basetypes.ObjectValuable. -func (o TerminationReason) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TerminationReason) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TerminationReason) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TerminationReason) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TerminationReason) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TerminationReason +// only implements ToObjectValue() and Type(). +func (o TerminationReason) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TerminationReason) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "code": o.Code, + "parameters": o.Parameters, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -16369,52 +10592,16 @@ func (a UninstallLibraries) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UninstallLibraries{} - -// Equal implements basetypes.ObjectValuable. -func (o UninstallLibraries) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UninstallLibraries) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UninstallLibraries) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UninstallLibraries) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UninstallLibraries) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UninstallLibraries +// only implements ToObjectValue() and Type(). +func (o UninstallLibraries) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UninstallLibraries) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "libraries": o.Libraries, + }) } // Type implements basetypes.ObjectValuable. @@ -16449,52 +10636,13 @@ func (a UninstallLibrariesResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UninstallLibrariesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UninstallLibrariesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UninstallLibrariesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UninstallLibrariesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UninstallLibrariesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UninstallLibrariesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UninstallLibrariesResponse +// only implements ToObjectValue() and Type(). +func (o UninstallLibrariesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UninstallLibrariesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -16526,52 +10674,15 @@ func (a UnpinCluster) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UnpinCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o UnpinCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UnpinCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UnpinCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UnpinCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UnpinCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UnpinCluster +// only implements ToObjectValue() and Type(). +func (o UnpinCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UnpinCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + }) } // Type implements basetypes.ObjectValuable. @@ -16603,52 +10714,13 @@ func (a UnpinClusterResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UnpinClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UnpinClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UnpinClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UnpinClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UnpinClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UnpinClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UnpinClusterResponse +// only implements ToObjectValue() and Type(). +func (o UnpinClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UnpinClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -16690,52 +10762,17 @@ func (a UpdateCluster) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCluster +// only implements ToObjectValue() and Type(). +func (o UpdateCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster": o.Cluster, + "cluster_id": o.ClusterId, + "update_mask": o.UpdateMask, + }) } // Type implements basetypes.ObjectValuable. @@ -16929,52 +10966,40 @@ func (a UpdateClusterResource) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateClusterResource{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateClusterResource) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateClusterResource) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateClusterResource) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateClusterResource) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateClusterResource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateClusterResource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateClusterResource +// only implements ToObjectValue() and Type(). +func (o UpdateClusterResource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "autoscale": o.Autoscale, + "autotermination_minutes": o.AutoterminationMinutes, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "cluster_log_conf": o.ClusterLogConf, + "cluster_name": o.ClusterName, + "custom_tags": o.CustomTags, + "data_security_mode": o.DataSecurityMode, + "docker_image": o.DockerImage, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_elastic_disk": o.EnableElasticDisk, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "node_type_id": o.NodeTypeId, + "num_workers": o.NumWorkers, + "policy_id": o.PolicyId, + "runtime_engine": o.RuntimeEngine, + "single_user_name": o.SingleUserName, + "spark_conf": o.SparkConf, + "spark_env_vars": o.SparkEnvVars, + "spark_version": o.SparkVersion, + "ssh_public_keys": o.SshPublicKeys, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -17055,52 +11080,13 @@ func (a UpdateClusterResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateClusterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateClusterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateClusterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateClusterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateClusterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateClusterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateClusterResponse +// only implements ToObjectValue() and Type(). +func (o UpdateClusterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateClusterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -17130,52 +11116,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -17207,52 +11154,15 @@ func (a VolumesStorageInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = VolumesStorageInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o VolumesStorageInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o VolumesStorageInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o VolumesStorageInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o VolumesStorageInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o VolumesStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, VolumesStorageInfo +// only implements ToObjectValue() and Type(). +func (o VolumesStorageInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o VolumesStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination": o.Destination, + }) } // Type implements basetypes.ObjectValuable. @@ -17288,52 +11198,15 @@ func (a WorkloadType) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkloadType{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkloadType) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkloadType) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkloadType) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkloadType) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkloadType) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkloadType +// only implements ToObjectValue() and Type(). +func (o WorkloadType) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkloadType) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "clients": o.Clients, + }) } // Type implements basetypes.ObjectValuable. @@ -17370,52 +11243,15 @@ func (a WorkspaceStorageInfo) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceStorageInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceStorageInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceStorageInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceStorageInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceStorageInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceStorageInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceStorageInfo +// only implements ToObjectValue() and Type(). +func (o WorkspaceStorageInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceStorageInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination": o.Destination, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 2d080bc11f..c5be2f3c56 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -12,17 +12,13 @@ package dashboards_tf import ( "context" - "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/sql" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/sql_tf" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) // Create dashboard @@ -49,52 +45,15 @@ func (a CreateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateDashboardRequest +// only implements ToObjectValue() and Type(). +func (o CreateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard": o.Dashboard, + }) } // Type implements basetypes.ObjectValuable. @@ -135,52 +94,16 @@ func (a CreateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateScheduleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateScheduleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateScheduleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateScheduleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateScheduleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateScheduleRequest +// only implements ToObjectValue() and Type(). +func (o CreateScheduleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "schedule": o.Schedule, + }) } // Type implements basetypes.ObjectValuable. @@ -224,52 +147,17 @@ func (a CreateSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateSubscriptionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateSubscriptionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateSubscriptionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateSubscriptionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateSubscriptionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateSubscriptionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateSubscriptionRequest +// only implements ToObjectValue() and Type(). +func (o CreateSubscriptionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateSubscriptionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "schedule_id": o.ScheduleId, + "subscription": o.Subscription, + }) } // Type implements basetypes.ObjectValuable. @@ -315,52 +203,16 @@ func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CronSchedule{} - -// Equal implements basetypes.ObjectValuable. -func (o CronSchedule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CronSchedule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CronSchedule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CronSchedule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CronSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CronSchedule +// only implements ToObjectValue() and Type(). +func (o CronSchedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CronSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "quartz_cron_expression": o.QuartzCronExpression, + "timezone_id": o.TimezoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -426,52 +278,24 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Dashboard{} - -// Equal implements basetypes.ObjectValuable. -func (o Dashboard) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Dashboard) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Dashboard) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Dashboard) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Dashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Dashboard +// only implements ToObjectValue() and Type(). +func (o Dashboard) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Dashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "dashboard_id": o.DashboardId, + "display_name": o.DisplayName, + "etag": o.Etag, + "lifecycle_state": o.LifecycleState, + "parent_path": o.ParentPath, + "path": o.Path, + "serialized_dashboard": o.SerializedDashboard, + "update_time": o.UpdateTime, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -520,52 +344,17 @@ func (a DeleteScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteScheduleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteScheduleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteScheduleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteScheduleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteScheduleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteScheduleRequest +// only implements ToObjectValue() and Type(). +func (o DeleteScheduleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "etag": o.Etag, + "schedule_id": o.ScheduleId, + }) } // Type implements basetypes.ObjectValuable. @@ -599,52 +388,13 @@ func (a DeleteScheduleResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteScheduleResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteScheduleResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteScheduleResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteScheduleResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteScheduleResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteScheduleResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteScheduleResponse +// only implements ToObjectValue() and Type(). +func (o DeleteScheduleResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteScheduleResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -684,52 +434,18 @@ func (a DeleteSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteSubscriptionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteSubscriptionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteSubscriptionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteSubscriptionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteSubscriptionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteSubscriptionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteSubscriptionRequest +// only implements ToObjectValue() and Type(). +func (o DeleteSubscriptionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteSubscriptionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "etag": o.Etag, + "schedule_id": o.ScheduleId, + "subscription_id": o.SubscriptionId, + }) } // Type implements basetypes.ObjectValuable. @@ -764,52 +480,13 @@ func (a DeleteSubscriptionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteSubscriptionResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteSubscriptionResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteSubscriptionResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteSubscriptionResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteSubscriptionResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteSubscriptionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteSubscriptionResponse +// only implements ToObjectValue() and Type(). +func (o DeleteSubscriptionResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteSubscriptionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -846,52 +523,16 @@ func (a GenieAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieAttachment{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieAttachment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieAttachment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieAttachment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieAttachment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieAttachment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieAttachment +// only implements ToObjectValue() and Type(). +func (o GenieAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieAttachment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query": o.Query, + "text": o.Text, + }) } // Type implements basetypes.ObjectValuable. @@ -940,52 +581,20 @@ func (a GenieConversation) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieConversation{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieConversation) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieConversation) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieConversation) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieConversation) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieConversation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieConversation +// only implements ToObjectValue() and Type(). +func (o GenieConversation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieConversation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_timestamp": o.CreatedTimestamp, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "space_id": o.SpaceId, + "title": o.Title, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -1028,52 +637,17 @@ func (a GenieCreateConversationMessageRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieCreateConversationMessageRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieCreateConversationMessageRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieCreateConversationMessageRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieCreateConversationMessageRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieCreateConversationMessageRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieCreateConversationMessageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieCreateConversationMessageRequest +// only implements ToObjectValue() and Type(). +func (o GenieCreateConversationMessageRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieCreateConversationMessageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "conversation_id": o.ConversationId, + "space_id": o.SpaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1114,52 +688,17 @@ func (a GenieExecuteMessageQueryRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieExecuteMessageQueryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieExecuteMessageQueryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieExecuteMessageQueryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieExecuteMessageQueryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieExecuteMessageQueryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieExecuteMessageQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieExecuteMessageQueryRequest +// only implements ToObjectValue() and Type(). +func (o GenieExecuteMessageQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieExecuteMessageQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "conversation_id": o.ConversationId, + "message_id": o.MessageId, + "space_id": o.SpaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1202,52 +741,17 @@ func (a GenieGetConversationMessageRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieGetConversationMessageRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieGetConversationMessageRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieGetConversationMessageRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieGetConversationMessageRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieGetConversationMessageRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieGetConversationMessageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieGetConversationMessageRequest +// only implements ToObjectValue() and Type(). +func (o GenieGetConversationMessageRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieGetConversationMessageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "conversation_id": o.ConversationId, + "message_id": o.MessageId, + "space_id": o.SpaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1288,52 +792,17 @@ func (a GenieGetMessageQueryResultRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieGetMessageQueryResultRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieGetMessageQueryResultRequest +// only implements ToObjectValue() and Type(). +func (o GenieGetMessageQueryResultRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "conversation_id": o.ConversationId, + "message_id": o.MessageId, + "space_id": o.SpaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1350,7 +819,7 @@ func (o GenieGetMessageQueryResultRequest) Type(ctx context.Context) attr.Type { type GenieGetMessageQueryResultResponse struct { // SQL Statement Execution response. See [Get status, manifest, and result // first chunk](:method:statementexecution/getstatement) for more details. - StatementResponse sql.StatementResponse `tfsdk:"statement_response" tf:"optional,object"` + StatementResponse types.List `tfsdk:"statement_response" tf:"optional,object"` } func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan GenieGetMessageQueryResultResponse) { @@ -1372,52 +841,15 @@ func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieGetMessageQueryResultResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieGetMessageQueryResultResponse +// only implements ToObjectValue() and Type(). +func (o GenieGetMessageQueryResultResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieGetMessageQueryResultResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "statement_response": o.StatementResponse, + }) } // Type implements basetypes.ObjectValuable. @@ -1492,52 +924,25 @@ func (a GenieMessage) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieMessage +// only implements ToObjectValue() and Type(). +func (o GenieMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attachments": o.Attachments, + "content": o.Content, + "conversation_id": o.ConversationId, + "created_timestamp": o.CreatedTimestamp, + "error": o.Error, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "query_result": o.QueryResult, + "space_id": o.SpaceId, + "status": o.Status, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -1590,52 +995,16 @@ func (a GenieStartConversationMessageRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieStartConversationMessageRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieStartConversationMessageRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieStartConversationMessageRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieStartConversationMessageRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieStartConversationMessageRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieStartConversationMessageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieStartConversationMessageRequest +// only implements ToObjectValue() and Type(). +func (o GenieStartConversationMessageRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieStartConversationMessageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "space_id": o.SpaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1678,52 +1047,18 @@ func (a GenieStartConversationResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenieStartConversationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GenieStartConversationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenieStartConversationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenieStartConversationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenieStartConversationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenieStartConversationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenieStartConversationResponse +// only implements ToObjectValue() and Type(). +func (o GenieStartConversationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenieStartConversationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "conversation": o.Conversation, + "conversation_id": o.ConversationId, + "message": o.Message, + "message_id": o.MessageId, + }) } // Type implements basetypes.ObjectValuable. @@ -1765,60 +1100,23 @@ func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDashboardRequest{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDashboardRequest +// only implements ToObjectValue() and Type(). +func (o GetDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o GetDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o GetDashboardRequest) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "dashboard_id": types.StringType, - }, +// Type implements basetypes.ObjectValuable. +func (o GetDashboardRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "dashboard_id": types.StringType, + }, } } @@ -1845,52 +1143,15 @@ func (a GetPublishedDashboardRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPublishedDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPublishedDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPublishedDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPublishedDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPublishedDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPublishedDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPublishedDashboardRequest +// only implements ToObjectValue() and Type(). +func (o GetPublishedDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPublishedDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -1927,52 +1188,16 @@ func (a GetScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetScheduleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetScheduleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetScheduleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetScheduleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetScheduleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetScheduleRequest +// only implements ToObjectValue() and Type(). +func (o GetScheduleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "schedule_id": o.ScheduleId, + }) } // Type implements basetypes.ObjectValuable. @@ -2012,52 +1237,17 @@ func (a GetSubscriptionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetSubscriptionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetSubscriptionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetSubscriptionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetSubscriptionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetSubscriptionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetSubscriptionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetSubscriptionRequest +// only implements ToObjectValue() and Type(). +func (o GetSubscriptionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetSubscriptionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "schedule_id": o.ScheduleId, + "subscription_id": o.SubscriptionId, + }) } // Type implements basetypes.ObjectValuable. @@ -2102,52 +1292,18 @@ func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListDashboardsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListDashboardsRequest +// only implements ToObjectValue() and Type(). +func (o ListDashboardsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + "show_trashed": o.ShowTrashed, + "view": o.View, + }) } // Type implements basetypes.ObjectValuable. @@ -2188,52 +1344,16 @@ func (a ListDashboardsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListDashboardsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListDashboardsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListDashboardsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListDashboardsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListDashboardsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListDashboardsResponse +// only implements ToObjectValue() and Type(). +func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListDashboardsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboards": o.Dashboards, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2276,52 +1396,17 @@ func (a ListSchedulesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSchedulesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSchedulesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSchedulesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSchedulesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSchedulesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSchedulesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSchedulesRequest +// only implements ToObjectValue() and Type(). +func (o ListSchedulesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSchedulesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2363,52 +1448,16 @@ func (a ListSchedulesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSchedulesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSchedulesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSchedulesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSchedulesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSchedulesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSchedulesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSchedulesResponse +// only implements ToObjectValue() and Type(). +func (o ListSchedulesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSchedulesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "schedules": o.Schedules, + }) } // Type implements basetypes.ObjectValuable. @@ -2453,52 +1502,18 @@ func (a ListSubscriptionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSubscriptionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSubscriptionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSubscriptionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSubscriptionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSubscriptionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSubscriptionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSubscriptionsRequest +// only implements ToObjectValue() and Type(). +func (o ListSubscriptionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSubscriptionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "page_size": o.PageSize, + "page_token": o.PageToken, + "schedule_id": o.ScheduleId, + }) } // Type implements basetypes.ObjectValuable. @@ -2541,52 +1556,16 @@ func (a ListSubscriptionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSubscriptionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSubscriptionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSubscriptionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSubscriptionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSubscriptionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSubscriptionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSubscriptionsResponse +// only implements ToObjectValue() and Type(). +func (o ListSubscriptionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSubscriptionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "subscriptions": o.Subscriptions, + }) } // Type implements basetypes.ObjectValuable. @@ -2624,52 +1603,16 @@ func (a MessageError) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MessageError{} - -// Equal implements basetypes.ObjectValuable. -func (o MessageError) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MessageError) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MessageError) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MessageError) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MessageError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MessageError +// only implements ToObjectValue() and Type(). +func (o MessageError) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MessageError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error": o.Error, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -2709,52 +1652,17 @@ func (a MigrateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MigrateDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o MigrateDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MigrateDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MigrateDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MigrateDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MigrateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MigrateDashboardRequest +// only implements ToObjectValue() and Type(). +func (o MigrateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MigrateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display_name": o.DisplayName, + "parent_path": o.ParentPath, + "source_dashboard_id": o.SourceDashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -2797,52 +1705,17 @@ func (a PublishRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PublishRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PublishRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PublishRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PublishRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PublishRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PublishRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PublishRequest +// only implements ToObjectValue() and Type(). +func (o PublishRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PublishRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "embed_credentials": o.EmbedCredentials, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -2884,52 +1757,18 @@ func (a PublishedDashboard) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PublishedDashboard{} - -// Equal implements basetypes.ObjectValuable. -func (o PublishedDashboard) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PublishedDashboard) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PublishedDashboard) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PublishedDashboard) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PublishedDashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PublishedDashboard +// only implements ToObjectValue() and Type(). +func (o PublishedDashboard) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PublishedDashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display_name": o.DisplayName, + "embed_credentials": o.EmbedCredentials, + "revision_create_time": o.RevisionCreateTime, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -2980,52 +1819,21 @@ func (a QueryAttachment) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryAttachment{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryAttachment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryAttachment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryAttachment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryAttachment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryAttachment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryAttachment +// only implements ToObjectValue() and Type(). +func (o QueryAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryAttachment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "id": o.Id, + "instruction_id": o.InstructionId, + "instruction_title": o.InstructionTitle, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "query": o.Query, + "title": o.Title, + }) } // Type implements basetypes.ObjectValuable. @@ -3071,52 +1879,17 @@ func (a Result) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Result{} - -// Equal implements basetypes.ObjectValuable. -func (o Result) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Result) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Result) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Result) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Result) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Result +// only implements ToObjectValue() and Type(). +func (o Result) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Result) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_truncated": o.IsTruncated, + "row_count": o.RowCount, + "statement_id": o.StatementId, + }) } // Type implements basetypes.ObjectValuable. @@ -3173,52 +1946,23 @@ func (a Schedule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Schedule{} - -// Equal implements basetypes.ObjectValuable. -func (o Schedule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Schedule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Schedule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Schedule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Schedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Schedule +// only implements ToObjectValue() and Type(). +func (o Schedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Schedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "cron_schedule": o.CronSchedule, + "dashboard_id": o.DashboardId, + "display_name": o.DisplayName, + "etag": o.Etag, + "pause_status": o.PauseStatus, + "schedule_id": o.ScheduleId, + "update_time": o.UpdateTime, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -3269,52 +2013,16 @@ func (a Subscriber) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Subscriber{} - -// Equal implements basetypes.ObjectValuable. -func (o Subscriber) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Subscriber) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Subscriber) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Subscriber) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Subscriber) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Subscriber +// only implements ToObjectValue() and Type(). +func (o Subscriber) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Subscriber) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_subscriber": o.DestinationSubscriber, + "user_subscriber": o.UserSubscriber, + }) } // Type implements basetypes.ObjectValuable. @@ -3373,52 +2081,22 @@ func (a Subscription) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Subscription{} - -// Equal implements basetypes.ObjectValuable. -func (o Subscription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Subscription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Subscription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Subscription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Subscription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Subscription +// only implements ToObjectValue() and Type(). +func (o Subscription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Subscription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "created_by_user_id": o.CreatedByUserId, + "dashboard_id": o.DashboardId, + "etag": o.Etag, + "schedule_id": o.ScheduleId, + "subscriber": o.Subscriber, + "subscription_id": o.SubscriptionId, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -3462,52 +2140,15 @@ func (a SubscriptionSubscriberDestination) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SubscriptionSubscriberDestination{} - -// Equal implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberDestination) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberDestination) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberDestination) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberDestination) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberDestination) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SubscriptionSubscriberDestination +// only implements ToObjectValue() and Type(). +func (o SubscriptionSubscriberDestination) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberDestination) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_id": o.DestinationId, + }) } // Type implements basetypes.ObjectValuable. @@ -3541,52 +2182,15 @@ func (a SubscriptionSubscriberUser) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SubscriptionSubscriberUser{} - -// Equal implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberUser) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberUser) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberUser) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberUser) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberUser) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SubscriptionSubscriberUser +// only implements ToObjectValue() and Type(). +func (o SubscriptionSubscriberUser) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SubscriptionSubscriberUser) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -3622,52 +2226,16 @@ func (a TextAttachment) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TextAttachment{} - -// Equal implements basetypes.ObjectValuable. -func (o TextAttachment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TextAttachment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TextAttachment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TextAttachment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TextAttachment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TextAttachment +// only implements ToObjectValue() and Type(). +func (o TextAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TextAttachment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3703,52 +2271,15 @@ func (a TrashDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TrashDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TrashDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TrashDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TrashDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TrashDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TrashDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TrashDashboardRequest +// only implements ToObjectValue() and Type(). +func (o TrashDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TrashDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -3780,52 +2311,13 @@ func (a TrashDashboardResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TrashDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o TrashDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TrashDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TrashDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TrashDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TrashDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TrashDashboardResponse +// only implements ToObjectValue() and Type(). +func (o TrashDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TrashDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3858,52 +2350,15 @@ func (a UnpublishDashboardRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UnpublishDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UnpublishDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UnpublishDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UnpublishDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UnpublishDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UnpublishDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UnpublishDashboardRequest +// only implements ToObjectValue() and Type(). +func (o UnpublishDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UnpublishDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -3935,52 +2390,13 @@ func (a UnpublishDashboardResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UnpublishDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UnpublishDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UnpublishDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UnpublishDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UnpublishDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UnpublishDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UnpublishDashboardResponse +// only implements ToObjectValue() and Type(). +func (o UnpublishDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UnpublishDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4016,52 +2432,16 @@ func (a UpdateDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateDashboardRequest +// only implements ToObjectValue() and Type(). +func (o UpdateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard": o.Dashboard, + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -4105,52 +2485,17 @@ func (a UpdateScheduleRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateScheduleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateScheduleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateScheduleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateScheduleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateScheduleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateScheduleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateScheduleRequest +// only implements ToObjectValue() and Type(). +func (o UpdateScheduleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateScheduleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "schedule": o.Schedule, + "schedule_id": o.ScheduleId, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 35c9e75465..37fe8b3854 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -12,16 +12,11 @@ package files_tf import ( "context" - "fmt" - "io" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AddBlock struct { @@ -49,52 +44,16 @@ func (a AddBlock) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AddBlock{} - -// Equal implements basetypes.ObjectValuable. -func (o AddBlock) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AddBlock) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AddBlock) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AddBlock) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AddBlock) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AddBlock +// only implements ToObjectValue() and Type(). +func (o AddBlock) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AddBlock) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data": o.Data, + "handle": o.Handle, + }) } // Type implements basetypes.ObjectValuable. @@ -127,52 +86,13 @@ func (a AddBlockResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AddBlockResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AddBlockResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AddBlockResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AddBlockResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AddBlockResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AddBlockResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AddBlockResponse +// only implements ToObjectValue() and Type(). +func (o AddBlockResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AddBlockResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -204,52 +124,15 @@ func (a Close) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Close{} - -// Equal implements basetypes.ObjectValuable. -func (o Close) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Close) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Close) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Close) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Close) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Close +// only implements ToObjectValue() and Type(). +func (o Close) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Close) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "handle": o.Handle, + }) } // Type implements basetypes.ObjectValuable. @@ -281,52 +164,13 @@ func (a CloseResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CloseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CloseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CloseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CloseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CloseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CloseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CloseResponse +// only implements ToObjectValue() and Type(). +func (o CloseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CloseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -360,52 +204,16 @@ func (a Create) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Create{} - -// Equal implements basetypes.ObjectValuable. -func (o Create) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Create) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Create) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Create) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Create) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Create +// only implements ToObjectValue() and Type(). +func (o Create) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Create) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "overwrite": o.Overwrite, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -441,52 +249,15 @@ func (a CreateDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateDirectoryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateDirectoryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateDirectoryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateDirectoryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateDirectoryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateDirectoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateDirectoryRequest +// only implements ToObjectValue() and Type(). +func (o CreateDirectoryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateDirectoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "directory_path": o.DirectoryPath, + }) } // Type implements basetypes.ObjectValuable. @@ -518,52 +289,13 @@ func (a CreateDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateDirectoryResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateDirectoryResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateDirectoryResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateDirectoryResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateDirectoryResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateDirectoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateDirectoryResponse +// only implements ToObjectValue() and Type(). +func (o CreateDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateDirectoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -596,52 +328,15 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateResponse +// only implements ToObjectValue() and Type(). +func (o CreateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "handle": o.Handle, + }) } // Type implements basetypes.ObjectValuable. @@ -679,52 +374,16 @@ func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Delete{} - -// Equal implements basetypes.ObjectValuable. -func (o Delete) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Delete) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Delete) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Delete) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Delete) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Delete +// only implements ToObjectValue() and Type(). +func (o Delete) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Delete) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + "recursive": o.Recursive, + }) } // Type implements basetypes.ObjectValuable. @@ -760,52 +419,15 @@ func (a DeleteDirectoryRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDirectoryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDirectoryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDirectoryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDirectoryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDirectoryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDirectoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDirectoryRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDirectoryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDirectoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "directory_path": o.DirectoryPath, + }) } // Type implements basetypes.ObjectValuable. @@ -837,52 +459,13 @@ func (a DeleteDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDirectoryResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDirectoryResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDirectoryResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDirectoryResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDirectoryResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDirectoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDirectoryResponse +// only implements ToObjectValue() and Type(). +func (o DeleteDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDirectoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -915,52 +498,15 @@ func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteFileRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteFileRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteFileRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteFileRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteFileRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteFileRequest +// only implements ToObjectValue() and Type(). +func (o DeleteFileRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_path": o.FilePath, + }) } // Type implements basetypes.ObjectValuable. @@ -992,52 +538,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1078,52 +585,19 @@ func (a DirectoryEntry) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DirectoryEntry{} - -// Equal implements basetypes.ObjectValuable. -func (o DirectoryEntry) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DirectoryEntry) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DirectoryEntry) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DirectoryEntry) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DirectoryEntry) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DirectoryEntry +// only implements ToObjectValue() and Type(). +func (o DirectoryEntry) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DirectoryEntry) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_size": o.FileSize, + "is_directory": o.IsDirectory, + "last_modified": o.LastModified, + "name": o.Name, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -1162,52 +636,15 @@ func (a DownloadRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DownloadRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DownloadRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DownloadRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DownloadRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DownloadRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DownloadRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DownloadRequest +// only implements ToObjectValue() and Type(). +func (o DownloadRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DownloadRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_path": o.FilePath, + }) } // Type implements basetypes.ObjectValuable. @@ -1224,7 +661,7 @@ type DownloadResponse struct { ContentType types.String `tfsdk:"-"` - Contents io.ReadCloser `tfsdk:"-"` + Contents types.Object `tfsdk:"-"` LastModified types.String `tfsdk:"-"` } @@ -1246,52 +683,18 @@ func (a DownloadResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DownloadResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DownloadResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DownloadResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DownloadResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DownloadResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DownloadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DownloadResponse +// only implements ToObjectValue() and Type(). +func (o DownloadResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DownloadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content-length": o.ContentLength, + "content-type": o.ContentType, + "contents": o.Contents, + "last-modified": o.LastModified, + }) } // Type implements basetypes.ObjectValuable. @@ -1334,52 +737,18 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FileInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o FileInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FileInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FileInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FileInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FileInfo +// only implements ToObjectValue() and Type(). +func (o FileInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_size": o.FileSize, + "is_dir": o.IsDir, + "modification_time": o.ModificationTime, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -1417,52 +786,15 @@ func (a GetDirectoryMetadataRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDirectoryMetadataRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDirectoryMetadataRequest +// only implements ToObjectValue() and Type(). +func (o GetDirectoryMetadataRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "directory_path": o.DirectoryPath, + }) } // Type implements basetypes.ObjectValuable. @@ -1494,52 +826,13 @@ func (a GetDirectoryMetadataResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDirectoryMetadataResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDirectoryMetadataResponse +// only implements ToObjectValue() and Type(). +func (o GetDirectoryMetadataResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDirectoryMetadataResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1572,52 +865,15 @@ func (a GetMetadataRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetMetadataRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetMetadataRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetMetadataRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetMetadataRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetMetadataRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetMetadataRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetMetadataRequest +// only implements ToObjectValue() and Type(). +func (o GetMetadataRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetMetadataRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_path": o.FilePath, + }) } // Type implements basetypes.ObjectValuable. @@ -1654,52 +910,17 @@ func (a GetMetadataResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetMetadataResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetMetadataResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetMetadataResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetMetadataResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetMetadataResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetMetadataResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetMetadataResponse +// only implements ToObjectValue() and Type(). +func (o GetMetadataResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetMetadataResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content-length": o.ContentLength, + "content-type": o.ContentType, + "last-modified": o.LastModified, + }) } // Type implements basetypes.ObjectValuable. @@ -1737,52 +958,15 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStatusRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStatusRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStatusRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStatusRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStatusRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStatusRequest +// only implements ToObjectValue() and Type(). +func (o GetStatusRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -1818,52 +1002,15 @@ func (a ListDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListDbfsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListDbfsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListDbfsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListDbfsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListDbfsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListDbfsRequest +// only implements ToObjectValue() and Type(). +func (o ListDbfsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -1918,52 +1065,17 @@ func (a ListDirectoryContentsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListDirectoryContentsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListDirectoryContentsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListDirectoryContentsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListDirectoryContentsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListDirectoryContentsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListDirectoryContentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListDirectoryContentsRequest +// only implements ToObjectValue() and Type(). +func (o ListDirectoryContentsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListDirectoryContentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "directory_path": o.DirectoryPath, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2003,52 +1115,16 @@ func (a ListDirectoryResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListDirectoryResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListDirectoryResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListDirectoryResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListDirectoryResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListDirectoryResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListDirectoryResponse +// only implements ToObjectValue() and Type(). +func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListDirectoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "contents": o.Contents, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2088,52 +1164,15 @@ func (a ListStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListStatusResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListStatusResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListStatusResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListStatusResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListStatusResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListStatusResponse +// only implements ToObjectValue() and Type(). +func (o ListStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "files": o.Files, + }) } // Type implements basetypes.ObjectValuable. @@ -2169,52 +1208,15 @@ func (a MkDirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MkDirs{} - -// Equal implements basetypes.ObjectValuable. -func (o MkDirs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MkDirs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MkDirs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MkDirs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MkDirs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MkDirs +// only implements ToObjectValue() and Type(). +func (o MkDirs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MkDirs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -2246,52 +1248,13 @@ func (a MkDirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MkDirsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o MkDirsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MkDirsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MkDirsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MkDirsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MkDirsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MkDirsResponse +// only implements ToObjectValue() and Type(). +func (o MkDirsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MkDirsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2327,52 +1290,16 @@ func (a Move) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Move{} - -// Equal implements basetypes.ObjectValuable. -func (o Move) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Move) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Move) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Move) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Move) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Move +// only implements ToObjectValue() and Type(). +func (o Move) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Move) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_path": o.DestinationPath, + "source_path": o.SourcePath, + }) } // Type implements basetypes.ObjectValuable. @@ -2405,52 +1332,13 @@ func (a MoveResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MoveResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o MoveResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MoveResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MoveResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MoveResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MoveResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MoveResponse +// only implements ToObjectValue() and Type(). +func (o MoveResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MoveResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2486,52 +1374,17 @@ func (a Put) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Put{} - -// Equal implements basetypes.ObjectValuable. -func (o Put) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Put) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Put) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Put) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Put) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Put +// only implements ToObjectValue() and Type(). +func (o Put) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Put) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "contents": o.Contents, + "overwrite": o.Overwrite, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -2565,52 +1418,13 @@ func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PutResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutResponse +// only implements ToObjectValue() and Type(). +func (o PutResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2648,52 +1462,17 @@ func (a ReadDbfsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReadDbfsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ReadDbfsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReadDbfsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReadDbfsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReadDbfsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReadDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReadDbfsRequest +// only implements ToObjectValue() and Type(). +func (o ReadDbfsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReadDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "length": o.Length, + "offset": o.Offset, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -2733,52 +1512,16 @@ func (a ReadResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReadResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ReadResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReadResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReadResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReadResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReadResponse +// only implements ToObjectValue() and Type(). +func (o ReadResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bytes_read": o.BytesRead, + "data": o.Data, + }) } // Type implements basetypes.ObjectValuable. @@ -2793,7 +1536,7 @@ func (o ReadResponse) Type(ctx context.Context) attr.Type { // Upload a file type UploadRequest struct { - Contents io.ReadCloser `tfsdk:"-"` + Contents types.Object `tfsdk:"-"` // The absolute path of the file. FilePath types.String `tfsdk:"-"` // If true, an existing file will be overwritten. @@ -2817,52 +1560,17 @@ func (a UploadRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UploadRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UploadRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UploadRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UploadRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UploadRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UploadRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UploadRequest +// only implements ToObjectValue() and Type(). +func (o UploadRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UploadRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "contents": o.Contents, + "file_path": o.FilePath, + "overwrite": o.Overwrite, + }) } // Type implements basetypes.ObjectValuable. @@ -2896,52 +1604,13 @@ func (a UploadResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UploadResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UploadResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UploadResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UploadResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UploadResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UploadResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UploadResponse +// only implements ToObjectValue() and Type(). +func (o UploadResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UploadResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index cfc82023c2..6c9095fa2f 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -12,15 +12,11 @@ package iam_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AccessControlRequest struct { @@ -51,52 +47,18 @@ func (a AccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o AccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccessControlRequest +// only implements ToObjectValue() and Type(). +func (o AccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -143,52 +105,19 @@ func (a AccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccessControlResponse +// only implements ToObjectValue() and Type(). +func (o AccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -235,52 +164,19 @@ func (a ComplexValue) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ComplexValue{} - -// Equal implements basetypes.ObjectValuable. -func (o ComplexValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ComplexValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ComplexValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ComplexValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ComplexValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ComplexValue +// only implements ToObjectValue() and Type(). +func (o ComplexValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ComplexValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display": o.Display, + "primary": o.Primary, + "$ref": o.Ref, + "type": o.Type_, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -319,52 +215,15 @@ func (a DeleteAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountGroupRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountGroupRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountGroupRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountGroupRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountGroupRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountGroupRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountGroupRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -399,52 +258,15 @@ func (a DeleteAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountServicePrincipalRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountServicePrincipalRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountServicePrincipalRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountServicePrincipalRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountServicePrincipalRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountServicePrincipalRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountServicePrincipalRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -479,52 +301,15 @@ func (a DeleteAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountUserRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountUserRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountUserRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountUserRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountUserRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountUserRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountUserRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -559,52 +344,15 @@ func (a DeleteGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteGroupRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteGroupRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteGroupRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteGroupRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteGroupRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteGroupRequest +// only implements ToObjectValue() and Type(). +func (o DeleteGroupRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -636,52 +384,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -714,52 +423,15 @@ func (a DeleteServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteServicePrincipalRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteServicePrincipalRequest +// only implements ToObjectValue() and Type(). +func (o DeleteServicePrincipalRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -794,52 +466,15 @@ func (a DeleteUserRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteUserRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteUserRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteUserRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteUserRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteUserRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteUserRequest +// only implements ToObjectValue() and Type(). +func (o DeleteUserRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -876,52 +511,16 @@ func (a DeleteWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWorkspaceAssignmentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWorkspaceAssignmentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWorkspaceAssignmentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWorkspaceAssignmentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWorkspaceAssignmentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWorkspaceAssignmentRequest +// only implements ToObjectValue() and Type(). +func (o DeleteWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWorkspaceAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principal_id": o.PrincipalId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -954,52 +553,13 @@ func (a DeleteWorkspacePermissionAssignmentResponse) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWorkspacePermissionAssignmentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWorkspacePermissionAssignmentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWorkspacePermissionAssignmentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWorkspacePermissionAssignmentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWorkspacePermissionAssignmentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWorkspacePermissionAssignmentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWorkspacePermissionAssignmentResponse +// only implements ToObjectValue() and Type(). +func (o DeleteWorkspacePermissionAssignmentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWorkspacePermissionAssignmentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1032,52 +592,15 @@ func (a GetAccountGroupRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountGroupRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountGroupRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountGroupRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountGroupRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountGroupRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountGroupRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountGroupRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -1112,52 +635,15 @@ func (a GetAccountServicePrincipalRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountServicePrincipalRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountServicePrincipalRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountServicePrincipalRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountServicePrincipalRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountServicePrincipalRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountServicePrincipalRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountServicePrincipalRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -1213,52 +699,22 @@ func (a GetAccountUserRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountUserRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountUserRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountUserRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountUserRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountUserRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountUserRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountUserRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "id": o.Id, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -1300,52 +756,15 @@ func (a GetAssignableRolesForResourceRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAssignableRolesForResourceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAssignableRolesForResourceRequest +// only implements ToObjectValue() and Type(). +func (o GetAssignableRolesForResourceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "resource": o.Resource, + }) } // Type implements basetypes.ObjectValuable. @@ -1380,52 +799,15 @@ func (a GetAssignableRolesForResourceResponse) GetComplexFieldTypes(ctx context. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAssignableRolesForResourceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAssignableRolesForResourceResponse +// only implements ToObjectValue() and Type(). +func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAssignableRolesForResourceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "roles": o.Roles, + }) } // Type implements basetypes.ObjectValuable. @@ -1462,52 +844,15 @@ func (a GetGroupRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetGroupRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetGroupRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetGroupRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetGroupRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetGroupRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetGroupRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetGroupRequest +// only implements ToObjectValue() and Type(). +func (o GetGroupRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetGroupRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -1543,52 +888,15 @@ func (a GetPasswordPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPasswordPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPasswordPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPasswordPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPasswordPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPasswordPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPasswordPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPasswordPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -1627,52 +935,16 @@ func (a GetPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "request_object_id": o.RequestObjectId, + "request_object_type": o.RequestObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -1709,52 +981,15 @@ func (a GetPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -1797,52 +1032,16 @@ func (a GetPermissionRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPermissionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPermissionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPermissionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPermissionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPermissionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPermissionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPermissionRequest +// only implements ToObjectValue() and Type(). +func (o GetPermissionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPermissionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "request_object_id": o.RequestObjectId, + "request_object_type": o.RequestObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -1887,52 +1086,16 @@ func (a GetRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRuleSetRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRuleSetRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRuleSetRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRuleSetRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRuleSetRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRuleSetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRuleSetRequest +// only implements ToObjectValue() and Type(). +func (o GetRuleSetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRuleSetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1968,52 +1131,15 @@ func (a GetServicePrincipalRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetServicePrincipalRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetServicePrincipalRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetServicePrincipalRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetServicePrincipalRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetServicePrincipalRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetServicePrincipalRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetServicePrincipalRequest +// only implements ToObjectValue() and Type(). +func (o GetServicePrincipalRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetServicePrincipalRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -2069,52 +1195,22 @@ func (a GetUserRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetUserRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetUserRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetUserRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetUserRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetUserRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetUserRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetUserRequest +// only implements ToObjectValue() and Type(). +func (o GetUserRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetUserRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "id": o.Id, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -2156,52 +1252,15 @@ func (a GetWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceAssignmentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceAssignmentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceAssignmentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceAssignmentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceAssignmentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceAssignmentRequest +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -2239,52 +1298,16 @@ func (a GrantRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GrantRule{} - -// Equal implements basetypes.ObjectValuable. -func (o GrantRule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GrantRule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GrantRule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GrantRule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GrantRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GrantRule +// only implements ToObjectValue() and Type(). +func (o GrantRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GrantRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principals": o.Principals, + "role": o.Role, + }) } // Type implements basetypes.ObjectValuable. @@ -2347,52 +1370,23 @@ func (a Group) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Group{} - -// Equal implements basetypes.ObjectValuable. -func (o Group) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Group) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Group) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Group) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Group) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Group +// only implements ToObjectValue() and Type(). +func (o Group) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Group) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "displayName": o.DisplayName, + "entitlements": o.Entitlements, + "externalId": o.ExternalId, + "groups": o.Groups, + "id": o.Id, + "members": o.Members, + "meta": o.Meta, + "roles": o.Roles, + "schemas": o.Schemas, + }) } // Type implements basetypes.ObjectValuable. @@ -2461,56 +1455,25 @@ func (newState *ListAccountGroupsRequest) SyncEffectiveFieldsDuringRead(existing // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF // SDK values. -func (a ListAccountGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountGroupsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountGroupsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountGroupsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountGroupsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountGroupsRequest) String() string { - return fmt.Sprintf("%#v", o) +func (a ListAccountGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountGroupsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountGroupsRequest +// only implements ToObjectValue() and Type(). +func (o ListAccountGroupsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountGroupsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -2569,52 +1532,21 @@ func (a ListAccountServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountServicePrincipalsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountServicePrincipalsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountServicePrincipalsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountServicePrincipalsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountServicePrincipalsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountServicePrincipalsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountServicePrincipalsRequest +// only implements ToObjectValue() and Type(). +func (o ListAccountServicePrincipalsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountServicePrincipalsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -2674,52 +1606,21 @@ func (a ListAccountUsersRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAccountUsersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAccountUsersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAccountUsersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAccountUsersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAccountUsersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAccountUsersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAccountUsersRequest +// only implements ToObjectValue() and Type(). +func (o ListAccountUsersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAccountUsersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -2778,52 +1679,21 @@ func (a ListGroupsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListGroupsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListGroupsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListGroupsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListGroupsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListGroupsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListGroupsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListGroupsRequest +// only implements ToObjectValue() and Type(). +func (o ListGroupsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListGroupsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -2875,52 +1745,19 @@ func (a ListGroupsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListGroupsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListGroupsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListGroupsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListGroupsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListGroupsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListGroupsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListGroupsResponse +// only implements ToObjectValue() and Type(). +func (o ListGroupsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListGroupsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "itemsPerPage": o.ItemsPerPage, + "Resources": o.Resources, + "schemas": o.Schemas, + "startIndex": o.StartIndex, + "totalResults": o.TotalResults, + }) } // Type implements basetypes.ObjectValuable. @@ -2974,52 +1811,19 @@ func (a ListServicePrincipalResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListServicePrincipalResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListServicePrincipalResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListServicePrincipalResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListServicePrincipalResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListServicePrincipalResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListServicePrincipalResponse +// only implements ToObjectValue() and Type(). +func (o ListServicePrincipalResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "itemsPerPage": o.ItemsPerPage, + "Resources": o.Resources, + "schemas": o.Schemas, + "startIndex": o.StartIndex, + "totalResults": o.TotalResults, + }) } // Type implements basetypes.ObjectValuable. @@ -3080,52 +1884,21 @@ func (a ListServicePrincipalsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListServicePrincipalsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListServicePrincipalsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListServicePrincipalsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListServicePrincipalsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListServicePrincipalsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListServicePrincipalsRequest +// only implements ToObjectValue() and Type(). +func (o ListServicePrincipalsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -3185,52 +1958,21 @@ func (a ListUsersRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListUsersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListUsersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListUsersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListUsersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListUsersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListUsersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListUsersRequest +// only implements ToObjectValue() and Type(). +func (o ListUsersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListUsersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "attributes": o.Attributes, + "count": o.Count, + "excludedAttributes": o.ExcludedAttributes, + "filter": o.Filter, + "sortBy": o.SortBy, + "sortOrder": o.SortOrder, + "startIndex": o.StartIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -3282,52 +2024,19 @@ func (a ListUsersResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListUsersResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListUsersResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListUsersResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListUsersResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListUsersResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListUsersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListUsersResponse +// only implements ToObjectValue() and Type(). +func (o ListUsersResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListUsersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "itemsPerPage": o.ItemsPerPage, + "Resources": o.Resources, + "schemas": o.Schemas, + "startIndex": o.StartIndex, + "totalResults": o.TotalResults, + }) } // Type implements basetypes.ObjectValuable. @@ -3370,52 +2079,15 @@ func (a ListWorkspaceAssignmentRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListWorkspaceAssignmentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListWorkspaceAssignmentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListWorkspaceAssignmentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListWorkspaceAssignmentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListWorkspaceAssignmentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListWorkspaceAssignmentRequest +// only implements ToObjectValue() and Type(). +func (o ListWorkspaceAssignmentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListWorkspaceAssignmentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -3456,52 +2128,18 @@ func (a MigratePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MigratePermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o MigratePermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MigratePermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MigratePermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MigratePermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MigratePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MigratePermissionsRequest +// only implements ToObjectValue() and Type(). +func (o MigratePermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MigratePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "from_workspace_group_name": o.FromWorkspaceGroupName, + "size": o.Size, + "to_account_group_name": o.ToAccountGroupName, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -3538,52 +2176,15 @@ func (a MigratePermissionsResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MigratePermissionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o MigratePermissionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MigratePermissionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MigratePermissionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MigratePermissionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MigratePermissionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MigratePermissionsResponse +// only implements ToObjectValue() and Type(). +func (o MigratePermissionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MigratePermissionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permissions_migrated": o.PermissionsMigrated, + }) } // Type implements basetypes.ObjectValuable. @@ -3619,52 +2220,16 @@ func (a Name) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Name{} - -// Equal implements basetypes.ObjectValuable. -func (o Name) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Name) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Name) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Name) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Name) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Name +// only implements ToObjectValue() and Type(). +func (o Name) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Name) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "familyName": o.FamilyName, + "givenName": o.GivenName, + }) } // Type implements basetypes.ObjectValuable. @@ -3704,52 +2269,17 @@ func (a ObjectPermissions) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ObjectPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o ObjectPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ObjectPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ObjectPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ObjectPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ObjectPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ObjectPermissions +// only implements ToObjectValue() and Type(). +func (o ObjectPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ObjectPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -3795,52 +2325,17 @@ func (a PartialUpdate) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PartialUpdate{} - -// Equal implements basetypes.ObjectValuable. -func (o PartialUpdate) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PartialUpdate) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PartialUpdate) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PartialUpdate) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PartialUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PartialUpdate +// only implements ToObjectValue() and Type(). +func (o PartialUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PartialUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "Operations": o.Operations, + "schemas": o.Schemas, + }) } // Type implements basetypes.ObjectValuable. @@ -3886,52 +2381,18 @@ func (a PasswordAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PasswordAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PasswordAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PasswordAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PasswordAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PasswordAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PasswordAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PasswordAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o PasswordAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PasswordAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -3978,52 +2439,19 @@ func (a PasswordAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PasswordAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PasswordAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PasswordAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PasswordAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PasswordAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PasswordAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PasswordAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -4068,52 +2496,17 @@ func (a PasswordPermission) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PasswordPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o PasswordPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PasswordPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PasswordPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PasswordPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PasswordPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PasswordPermission +// only implements ToObjectValue() and Type(). +func (o PasswordPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PasswordPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4156,52 +2549,17 @@ func (a PasswordPermissions) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PasswordPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o PasswordPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PasswordPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PasswordPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PasswordPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PasswordPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PasswordPermissions +// only implements ToObjectValue() and Type(). +func (o PasswordPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PasswordPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -4240,52 +2598,16 @@ func (a PasswordPermissionsDescription) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PasswordPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o PasswordPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PasswordPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PasswordPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PasswordPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PasswordPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PasswordPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o PasswordPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PasswordPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4321,52 +2643,15 @@ func (a PasswordPermissionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PasswordPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PasswordPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PasswordPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PasswordPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PasswordPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PasswordPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PasswordPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + }) } // Type implements basetypes.ObjectValuable. @@ -4386,7 +2671,7 @@ type Patch struct { // Selection of patch operation Path types.String `tfsdk:"path" tf:"optional"` // Value to modify - Value any `tfsdk:"value" tf:"optional"` + Value types.Object `tfsdk:"value" tf:"optional"` } func (newState *Patch) SyncEffectiveFieldsDuringCreateOrUpdate(plan Patch) { @@ -4406,52 +2691,17 @@ func (a Patch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Patch{} - -// Equal implements basetypes.ObjectValuable. -func (o Patch) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Patch) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Patch) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Patch) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Patch) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Patch +// only implements ToObjectValue() and Type(). +func (o Patch) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Patch) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "op": o.Op, + "path": o.Path, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -4485,52 +2735,13 @@ func (a PatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PatchResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PatchResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PatchResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PatchResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PatchResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PatchResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PatchResponse +// only implements ToObjectValue() and Type(). +func (o PatchResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PatchResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4567,52 +2778,17 @@ func (a Permission) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Permission{} - -// Equal implements basetypes.ObjectValuable. -func (o Permission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Permission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Permission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Permission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Permission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Permission +// only implements ToObjectValue() and Type(). +func (o Permission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Permission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4659,52 +2835,17 @@ func (a PermissionAssignment) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionAssignment +// only implements ToObjectValue() and Type(). +func (o PermissionAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error": o.Error, + "permissions": o.Permissions, + "principal": o.Principal, + }) } // Type implements basetypes.ObjectValuable. @@ -4746,52 +2887,15 @@ func (a PermissionAssignments) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionAssignments{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionAssignments) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionAssignments) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionAssignments) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionAssignments) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionAssignments) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionAssignments +// only implements ToObjectValue() and Type(). +func (o PermissionAssignments) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionAssignments) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_assignments": o.PermissionAssignments, + }) } // Type implements basetypes.ObjectValuable. @@ -4829,52 +2933,16 @@ func (a PermissionOutput) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionOutput +// only implements ToObjectValue() and Type(). +func (o PermissionOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4910,52 +2978,16 @@ func (a PermissionsDescription) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionsDescription +// only implements ToObjectValue() and Type(). +func (o PermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4999,52 +3031,17 @@ func (a PermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PermissionsRequest +// only implements ToObjectValue() and Type(). +func (o PermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "request_object_id": o.RequestObjectId, + "request_object_type": o.RequestObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -5092,52 +3089,19 @@ func (a PrincipalOutput) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PrincipalOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o PrincipalOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PrincipalOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PrincipalOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PrincipalOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PrincipalOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PrincipalOutput +// only implements ToObjectValue() and Type(). +func (o PrincipalOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PrincipalOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display_name": o.DisplayName, + "group_name": o.GroupName, + "principal_id": o.PrincipalId, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -5176,52 +3140,15 @@ func (a ResourceMeta) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResourceMeta{} - -// Equal implements basetypes.ObjectValuable. -func (o ResourceMeta) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResourceMeta) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResourceMeta) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResourceMeta) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResourceMeta) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResourceMeta +// only implements ToObjectValue() and Type(). +func (o ResourceMeta) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResourceMeta) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "resourceType": o.ResourceType, + }) } // Type implements basetypes.ObjectValuable. @@ -5255,52 +3182,15 @@ func (a Role) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Role{} - -// Equal implements basetypes.ObjectValuable. -func (o Role) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Role) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Role) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Role) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Role) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Role +// only implements ToObjectValue() and Type(). +func (o Role) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Role) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5340,52 +3230,17 @@ func (a RuleSetResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RuleSetResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RuleSetResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RuleSetResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RuleSetResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RuleSetResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RuleSetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RuleSetResponse +// only implements ToObjectValue() and Type(). +func (o RuleSetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RuleSetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + "grant_rules": o.GrantRules, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5431,52 +3286,17 @@ func (a RuleSetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RuleSetUpdateRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RuleSetUpdateRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RuleSetUpdateRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RuleSetUpdateRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RuleSetUpdateRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RuleSetUpdateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RuleSetUpdateRequest +// only implements ToObjectValue() and Type(). +func (o RuleSetUpdateRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RuleSetUpdateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + "grant_rules": o.GrantRules, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5538,52 +3358,23 @@ func (a ServicePrincipal) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServicePrincipal{} - -// Equal implements basetypes.ObjectValuable. -func (o ServicePrincipal) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServicePrincipal) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServicePrincipal) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServicePrincipal) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServicePrincipal) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServicePrincipal +// only implements ToObjectValue() and Type(). +func (o ServicePrincipal) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServicePrincipal) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "active": o.Active, + "applicationId": o.ApplicationId, + "displayName": o.DisplayName, + "entitlements": o.Entitlements, + "externalId": o.ExternalId, + "groups": o.Groups, + "id": o.Id, + "roles": o.Roles, + "schemas": o.Schemas, + }) } // Type implements basetypes.ObjectValuable. @@ -5631,52 +3422,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5712,52 +3464,16 @@ func (a UpdateRuleSetRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRuleSetRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRuleSetRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRuleSetRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRuleSetRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRuleSetRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRuleSetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRuleSetRequest +// only implements ToObjectValue() and Type(). +func (o UpdateRuleSetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRuleSetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "rule_set": o.RuleSet, + }) } // Type implements basetypes.ObjectValuable. @@ -5805,52 +3521,17 @@ func (a UpdateWorkspaceAssignments) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateWorkspaceAssignments{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateWorkspaceAssignments) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateWorkspaceAssignments) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateWorkspaceAssignments) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateWorkspaceAssignments) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceAssignments) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateWorkspaceAssignments +// only implements ToObjectValue() and Type(). +func (o UpdateWorkspaceAssignments) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceAssignments) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permissions": o.Permissions, + "principal_id": o.PrincipalId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -5924,52 +3605,25 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = User{} - -// Equal implements basetypes.ObjectValuable. -func (o User) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o User) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o User) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o User) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o User) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, User +// only implements ToObjectValue() and Type(). +func (o User) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o User) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "active": o.Active, + "displayName": o.DisplayName, + "emails": o.Emails, + "entitlements": o.Entitlements, + "externalId": o.ExternalId, + "groups": o.Groups, + "id": o.Id, + "name": o.Name, + "roles": o.Roles, + "schemas": o.Schemas, + "userName": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -6027,52 +3681,15 @@ func (a WorkspacePermissions) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspacePermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspacePermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspacePermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspacePermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspacePermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspacePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspacePermissions +// only implements ToObjectValue() and Type(). +func (o WorkspacePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspacePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permissions": o.Permissions, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index dca7a02c1d..138c755101 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -12,17 +12,13 @@ package jobs_tf import ( "context" - "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/compute" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type BaseJob struct { @@ -65,52 +61,19 @@ func (a BaseJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BaseJob{} - -// Equal implements basetypes.ObjectValuable. -func (o BaseJob) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BaseJob) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BaseJob) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BaseJob) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BaseJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BaseJob +// only implements ToObjectValue() and Type(). +func (o BaseJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BaseJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_time": o.CreatedTime, + "creator_user_name": o.CreatorUserName, + "effective_budget_policy_id": o.EffectiveBudgetPolicyId, + "job_id": o.JobId, + "settings": o.Settings, + }) } // Type implements basetypes.ObjectValuable. @@ -288,52 +251,45 @@ func (a BaseRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BaseRun{} - -// Equal implements basetypes.ObjectValuable. -func (o BaseRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BaseRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BaseRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BaseRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BaseRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BaseRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BaseRun +// only implements ToObjectValue() and Type(). +func (o BaseRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "attempt_number": o.AttemptNumber, + "cleanup_duration": o.CleanupDuration, + "cluster_instance": o.ClusterInstance, + "cluster_spec": o.ClusterSpec, + "creator_user_name": o.CreatorUserName, + "description": o.Description, + "end_time": o.EndTime, + "execution_duration": o.ExecutionDuration, + "git_source": o.GitSource, + "job_clusters": o.JobClusters, + "job_id": o.JobId, + "job_parameters": o.JobParameters, + "job_run_id": o.JobRunId, + "number_in_job": o.NumberInJob, + "original_attempt_run_id": o.OriginalAttemptRunId, + "overriding_parameters": o.OverridingParameters, + "queue_duration": o.QueueDuration, + "repair_history": o.RepairHistory, + "run_duration": o.RunDuration, + "run_id": o.RunId, + "run_name": o.RunName, + "run_page_url": o.RunPageUrl, + "run_type": o.RunType, + "schedule": o.Schedule, + "setup_duration": o.SetupDuration, + "start_time": o.StartTime, + "state": o.State, + "status": o.Status, + "tasks": o.Tasks, + "trigger": o.Trigger, + "trigger_info": o.TriggerInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -424,52 +380,16 @@ func (a CancelAllRuns) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelAllRuns{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelAllRuns) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelAllRuns) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelAllRuns) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelAllRuns) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelAllRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelAllRuns +// only implements ToObjectValue() and Type(). +func (o CancelAllRuns) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelAllRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_queued_runs": o.AllQueuedRuns, + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -502,52 +422,13 @@ func (a CancelAllRunsResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelAllRunsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelAllRunsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelAllRunsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelAllRunsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelAllRunsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelAllRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelAllRunsResponse +// only implements ToObjectValue() and Type(). +func (o CancelAllRunsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelAllRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -579,52 +460,15 @@ func (a CancelRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelRun{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelRun +// only implements ToObjectValue() and Type(). +func (o CancelRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -656,52 +500,13 @@ func (a CancelRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelRunResponse +// only implements ToObjectValue() and Type(). +func (o CancelRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -749,52 +554,16 @@ func (a ClusterInstance) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterInstance{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterInstance) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterInstance) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterInstance) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterInstance) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterInstance) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterInstance +// only implements ToObjectValue() and Type(). +func (o ClusterInstance) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterInstance) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "spark_context_id": o.SparkContextId, + }) } // Type implements basetypes.ObjectValuable. @@ -821,7 +590,7 @@ type ClusterSpec struct { Libraries types.List `tfsdk:"library" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. - NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` + NewCluster types.List `tfsdk:"new_cluster" tf:"optional,object"` } func (newState *ClusterSpec) SyncEffectiveFieldsDuringCreateOrUpdate(plan ClusterSpec) { @@ -844,52 +613,18 @@ func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterSpec +// only implements ToObjectValue() and Type(). +func (o ClusterSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "existing_cluster_id": o.ExistingClusterId, + "job_cluster_key": o.JobClusterKey, + "library": o.Libraries, + "new_cluster": o.NewCluster, + }) } // Type implements basetypes.ObjectValuable. @@ -945,52 +680,17 @@ func (a ConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ConditionTask{} - -// Equal implements basetypes.ObjectValuable. -func (o ConditionTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ConditionTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ConditionTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ConditionTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ConditionTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ConditionTask +// only implements ToObjectValue() and Type(). +func (o ConditionTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ConditionTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "left": o.Left, + "op": o.Op, + "right": o.Right, + }) } // Type implements basetypes.ObjectValuable. @@ -1027,52 +727,15 @@ func (a Continuous) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Continuous{} - -// Equal implements basetypes.ObjectValuable. -func (o Continuous) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Continuous) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Continuous) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Continuous) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Continuous) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Continuous +// only implements ToObjectValue() and Type(). +func (o Continuous) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Continuous) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pause_status": o.PauseStatus, + }) } // Type implements basetypes.ObjectValuable. @@ -1225,52 +888,38 @@ func (a CreateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateJob{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateJob) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateJob) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateJob) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateJob) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateJob +// only implements ToObjectValue() and Type(). +func (o CreateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "budget_policy_id": o.BudgetPolicyId, + "continuous": o.Continuous, + "deployment": o.Deployment, + "description": o.Description, + "edit_mode": o.EditMode, + "email_notifications": o.EmailNotifications, + "environment": o.Environments, + "format": o.Format, + "git_source": o.GitSource, + "health": o.Health, + "job_cluster": o.JobClusters, + "max_concurrent_runs": o.MaxConcurrentRuns, + "name": o.Name, + "notification_settings": o.NotificationSettings, + "parameter": o.Parameters, + "queue": o.Queue, + "run_as": o.RunAs, + "schedule": o.Schedule, + "tags": o.Tags, + "task": o.Tasks, + "timeout_seconds": o.TimeoutSeconds, + "trigger": o.Trigger, + "webhook_notifications": o.WebhookNotifications, + }) } // Type implements basetypes.ObjectValuable. @@ -1362,52 +1011,15 @@ func (a CreateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateResponse +// only implements ToObjectValue() and Type(). +func (o CreateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -1451,52 +1063,17 @@ func (a CronSchedule) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CronSchedule{} - -// Equal implements basetypes.ObjectValuable. -func (o CronSchedule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CronSchedule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CronSchedule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CronSchedule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CronSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CronSchedule +// only implements ToObjectValue() and Type(). +func (o CronSchedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CronSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pause_status": o.PauseStatus, + "quartz_cron_expression": o.QuartzCronExpression, + "timezone_id": o.TimezoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -1539,52 +1116,16 @@ func (a DbtOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DbtOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o DbtOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DbtOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DbtOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DbtOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DbtOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DbtOutput +// only implements ToObjectValue() and Type(). +func (o DbtOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DbtOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifacts_headers": o.ArtifactsHeaders, + "artifacts_link": o.ArtifactsLink, + }) } // Type implements basetypes.ObjectValuable. @@ -1655,52 +1196,21 @@ func (a DbtTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DbtTask{} - -// Equal implements basetypes.ObjectValuable. -func (o DbtTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DbtTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DbtTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DbtTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DbtTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DbtTask +// only implements ToObjectValue() and Type(). +func (o DbtTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DbtTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog": o.Catalog, + "commands": o.Commands, + "profiles_directory": o.ProfilesDirectory, + "project_directory": o.ProjectDirectory, + "schema": o.Schema, + "source": o.Source, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -1742,52 +1252,15 @@ func (a DeleteJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteJob{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteJob) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteJob) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteJob) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteJob) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteJob +// only implements ToObjectValue() and Type(). +func (o DeleteJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -1819,52 +1292,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1896,52 +1330,15 @@ func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRun{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRun +// only implements ToObjectValue() and Type(). +func (o DeleteRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -1973,52 +1370,13 @@ func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRunResponse +// only implements ToObjectValue() and Type(). +func (o DeleteRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2063,52 +1421,17 @@ func (a EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) GetComple return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{} - -// Equal implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnforcePolicyComplianceForJobResponseJobClusterSettingsChange +// only implements ToObjectValue() and Type(). +func (o EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "field": o.Field, + "new_value": o.NewValue, + "previous_value": o.PreviousValue, + }) } // Type implements basetypes.ObjectValuable. @@ -2147,52 +1470,16 @@ func (a EnforcePolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnforcePolicyComplianceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnforcePolicyComplianceRequest +// only implements ToObjectValue() and Type(). +func (o EnforcePolicyComplianceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + "validate_only": o.ValidateOnly, + }) } // Type implements basetypes.ObjectValuable. @@ -2242,52 +1529,17 @@ func (a EnforcePolicyComplianceResponse) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnforcePolicyComplianceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnforcePolicyComplianceResponse +// only implements ToObjectValue() and Type(). +func (o EnforcePolicyComplianceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnforcePolicyComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "has_changes": o.HasChanges, + "job_cluster_changes": o.JobClusterChanges, + "settings": o.Settings, + }) } // Type implements basetypes.ObjectValuable. @@ -2334,52 +1586,15 @@ func (a ExportRunOutput) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExportRunOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o ExportRunOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExportRunOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExportRunOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExportRunOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExportRunOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExportRunOutput +// only implements ToObjectValue() and Type(). +func (o ExportRunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExportRunOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "views": o.Views, + }) } // Type implements basetypes.ObjectValuable. @@ -2418,52 +1633,16 @@ func (a ExportRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExportRunRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExportRunRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExportRunRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExportRunRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExportRunRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExportRunRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExportRunRequest +// only implements ToObjectValue() and Type(). +func (o ExportRunRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExportRunRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + "views_to_export": o.ViewsToExport, + }) } // Type implements basetypes.ObjectValuable. @@ -2508,52 +1687,17 @@ func (a FileArrivalTriggerConfiguration) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FileArrivalTriggerConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o FileArrivalTriggerConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FileArrivalTriggerConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FileArrivalTriggerConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FileArrivalTriggerConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FileArrivalTriggerConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FileArrivalTriggerConfiguration +// only implements ToObjectValue() and Type(). +func (o FileArrivalTriggerConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FileArrivalTriggerConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "min_time_between_triggers_seconds": o.MinTimeBetweenTriggersSeconds, + "url": o.Url, + "wait_after_last_change_seconds": o.WaitAfterLastChangeSeconds, + }) } // Type implements basetypes.ObjectValuable. @@ -2594,52 +1738,16 @@ func (a ForEachStats) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ForEachStats{} - -// Equal implements basetypes.ObjectValuable. -func (o ForEachStats) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ForEachStats) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ForEachStats) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ForEachStats) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ForEachStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ForEachStats +// only implements ToObjectValue() and Type(). +func (o ForEachStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ForEachStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error_message_stats": o.ErrorMessageStats, + "task_run_stats": o.TaskRunStats, + }) } // Type implements basetypes.ObjectValuable. @@ -2687,52 +1795,17 @@ func (a ForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ForEachTask{} - -// Equal implements basetypes.ObjectValuable. -func (o ForEachTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ForEachTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ForEachTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ForEachTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ForEachTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ForEachTask +// only implements ToObjectValue() and Type(). +func (o ForEachTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ForEachTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "concurrency": o.Concurrency, + "inputs": o.Inputs, + "task": o.Task, + }) } // Type implements basetypes.ObjectValuable. @@ -2775,52 +1848,17 @@ func (a ForEachTaskErrorMessageStats) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ForEachTaskErrorMessageStats{} - -// Equal implements basetypes.ObjectValuable. -func (o ForEachTaskErrorMessageStats) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ForEachTaskErrorMessageStats) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ForEachTaskErrorMessageStats) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ForEachTaskErrorMessageStats) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ForEachTaskErrorMessageStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ForEachTaskErrorMessageStats +// only implements ToObjectValue() and Type(). +func (o ForEachTaskErrorMessageStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ForEachTaskErrorMessageStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "count": o.Count, + "error_message": o.ErrorMessage, + "termination_category": o.TerminationCategory, + }) } // Type implements basetypes.ObjectValuable. @@ -2867,52 +1905,20 @@ func (a ForEachTaskTaskRunStats) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ForEachTaskTaskRunStats{} - -// Equal implements basetypes.ObjectValuable. -func (o ForEachTaskTaskRunStats) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ForEachTaskTaskRunStats) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ForEachTaskTaskRunStats) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ForEachTaskTaskRunStats) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ForEachTaskTaskRunStats) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ForEachTaskTaskRunStats +// only implements ToObjectValue() and Type(). +func (o ForEachTaskTaskRunStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ForEachTaskTaskRunStats) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "active_iterations": o.ActiveIterations, + "completed_iterations": o.CompletedIterations, + "failed_iterations": o.FailedIterations, + "scheduled_iterations": o.ScheduledIterations, + "succeeded_iterations": o.SucceededIterations, + "total_iterations": o.TotalIterations, + }) } // Type implements basetypes.ObjectValuable. @@ -2952,52 +1958,15 @@ func (a GetJobPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetJobPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetJobPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetJobPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -3033,52 +2002,15 @@ func (a GetJobPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetJobPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetJobPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetJobPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -3115,52 +2047,15 @@ func (a GetJobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetJobPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetJobPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetJobPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetJobPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetJobPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetJobPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetJobPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetJobPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetJobPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -3196,52 +2091,15 @@ func (a GetJobRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetJobRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetJobRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetJobRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetJobRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetJobRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetJobRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetJobRequest +// only implements ToObjectValue() and Type(). +func (o GetJobRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetJobRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -3276,52 +2134,15 @@ func (a GetPolicyComplianceRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPolicyComplianceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPolicyComplianceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPolicyComplianceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPolicyComplianceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPolicyComplianceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPolicyComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPolicyComplianceRequest +// only implements ToObjectValue() and Type(). +func (o GetPolicyComplianceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPolicyComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -3366,52 +2187,16 @@ func (a GetPolicyComplianceResponse) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPolicyComplianceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPolicyComplianceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPolicyComplianceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPolicyComplianceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPolicyComplianceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPolicyComplianceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPolicyComplianceResponse +// only implements ToObjectValue() and Type(). +func (o GetPolicyComplianceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPolicyComplianceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_compliant": o.IsCompliant, + "violations": o.Violations, + }) } // Type implements basetypes.ObjectValuable. @@ -3449,52 +2234,15 @@ func (a GetRunOutputRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRunOutputRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRunOutputRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRunOutputRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRunOutputRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRunOutputRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRunOutputRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRunOutputRequest +// only implements ToObjectValue() and Type(). +func (o GetRunOutputRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRunOutputRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -3537,52 +2285,18 @@ func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRunRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRunRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRunRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRunRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRunRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRunRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRunRequest +// only implements ToObjectValue() and Type(). +func (o GetRunRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRunRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_history": o.IncludeHistory, + "include_resolved_values": o.IncludeResolvedValues, + "page_token": o.PageToken, + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -3623,52 +2337,15 @@ func (a GitSnapshot) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GitSnapshot{} - -// Equal implements basetypes.ObjectValuable. -func (o GitSnapshot) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GitSnapshot) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GitSnapshot) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GitSnapshot) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GitSnapshot) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GitSnapshot +// only implements ToObjectValue() and Type(). +func (o GitSnapshot) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GitSnapshot) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "used_commit": o.UsedCommit, + }) } // Type implements basetypes.ObjectValuable. @@ -3733,52 +2410,21 @@ func (a GitSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GitSource{} - -// Equal implements basetypes.ObjectValuable. -func (o GitSource) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GitSource) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GitSource) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GitSource) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GitSource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GitSource +// only implements ToObjectValue() and Type(). +func (o GitSource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GitSource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "branch": o.GitBranch, + "commit": o.GitCommit, + "git_provider": o.GitProvider, + "git_snapshot": o.GitSnapshot, + "tag": o.GitTag, + "url": o.GitUrl, + "job_source": o.JobSource, + }) } // Type implements basetypes.ObjectValuable. @@ -3849,52 +2495,20 @@ func (a Job) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Job{} - -// Equal implements basetypes.ObjectValuable. -func (o Job) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Job) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Job) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Job) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Job) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Job +// only implements ToObjectValue() and Type(). +func (o Job) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Job) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_time": o.CreatedTime, + "creator_user_name": o.CreatorUserName, + "effective_budget_policy_id": o.EffectiveBudgetPolicyId, + "job_id": o.JobId, + "run_as_user_name": o.RunAsUserName, + "settings": o.Settings, + }) } // Type implements basetypes.ObjectValuable. @@ -3941,52 +2555,18 @@ func (a JobAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o JobAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o JobAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -4033,52 +2613,19 @@ func (a JobAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o JobAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -4102,7 +2649,7 @@ type JobCluster struct { // determine which cluster to launch for the task execution. JobClusterKey types.String `tfsdk:"job_cluster_key" tf:""` // If new_cluster, a description of a cluster that is created for each task. - NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"object"` + NewCluster types.List `tfsdk:"new_cluster" tf:"object"` } func (newState *JobCluster) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobCluster) { @@ -4124,52 +2671,16 @@ func (a JobCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o JobCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobCluster +// only implements ToObjectValue() and Type(). +func (o JobCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_cluster_key": o.JobClusterKey, + "new_cluster": o.NewCluster, + }) } // Type implements basetypes.ObjectValuable. @@ -4216,52 +2727,17 @@ func (a JobCompliance) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobCompliance{} - -// Equal implements basetypes.ObjectValuable. -func (o JobCompliance) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobCompliance) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobCompliance) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobCompliance) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobCompliance) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobCompliance +// only implements ToObjectValue() and Type(). +func (o JobCompliance) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobCompliance) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_compliant": o.IsCompliant, + "job_id": o.JobId, + "violations": o.Violations, + }) } // Type implements basetypes.ObjectValuable. @@ -4303,52 +2779,16 @@ func (a JobDeployment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobDeployment{} - -// Equal implements basetypes.ObjectValuable. -func (o JobDeployment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobDeployment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobDeployment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobDeployment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobDeployment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobDeployment +// only implements ToObjectValue() and Type(). +func (o JobDeployment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobDeployment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "kind": o.Kind, + "metadata_file_path": o.MetadataFilePath, + }) } // Type implements basetypes.ObjectValuable. @@ -4420,52 +2860,20 @@ func (a JobEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobEmailNotifications{} - -// Equal implements basetypes.ObjectValuable. -func (o JobEmailNotifications) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobEmailNotifications) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobEmailNotifications) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobEmailNotifications) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobEmailNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobEmailNotifications +// only implements ToObjectValue() and Type(). +func (o JobEmailNotifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobEmailNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "no_alert_for_skipped_runs": o.NoAlertForSkippedRuns, + "on_duration_warning_threshold_exceeded": o.OnDurationWarningThresholdExceeded, + "on_failure": o.OnFailure, + "on_start": o.OnStart, + "on_streaming_backlog_exceeded": o.OnStreamingBacklogExceeded, + "on_success": o.OnSuccess, + }) } // Type implements basetypes.ObjectValuable. @@ -4498,7 +2906,7 @@ type JobEnvironment struct { // The environment entity used to preserve serverless environment side panel // and jobs' environment for non-notebook task. In this minimal environment // spec, only pip dependencies are supported. - Spec compute.Environment `tfsdk:"spec" tf:"optional,object"` + Spec types.List `tfsdk:"spec" tf:"optional,object"` } func (newState *JobEnvironment) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobEnvironment) { @@ -4520,52 +2928,16 @@ func (a JobEnvironment) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobEnvironment{} - -// Equal implements basetypes.ObjectValuable. -func (o JobEnvironment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobEnvironment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobEnvironment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobEnvironment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobEnvironment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobEnvironment +// only implements ToObjectValue() and Type(). +func (o JobEnvironment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobEnvironment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "environment_key": o.EnvironmentKey, + "spec": o.Spec, + }) } // Type implements basetypes.ObjectValuable. @@ -4606,52 +2978,16 @@ func (a JobNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobNotificationSettings{} - -// Equal implements basetypes.ObjectValuable. -func (o JobNotificationSettings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobNotificationSettings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobNotificationSettings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobNotificationSettings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobNotificationSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobNotificationSettings +// only implements ToObjectValue() and Type(). +func (o JobNotificationSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobNotificationSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "no_alert_for_canceled_runs": o.NoAlertForCanceledRuns, + "no_alert_for_skipped_runs": o.NoAlertForSkippedRuns, + }) } // Type implements basetypes.ObjectValuable. @@ -4690,52 +3026,17 @@ func (a JobParameter) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobParameter{} - -// Equal implements basetypes.ObjectValuable. -func (o JobParameter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobParameter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobParameter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobParameter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobParameter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobParameter +// only implements ToObjectValue() and Type(). +func (o JobParameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobParameter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default": o.Default, + "name": o.Name, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -4774,52 +3075,16 @@ func (a JobParameterDefinition) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobParameterDefinition{} - -// Equal implements basetypes.ObjectValuable. -func (o JobParameterDefinition) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobParameterDefinition) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobParameterDefinition) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobParameterDefinition) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobParameterDefinition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobParameterDefinition +// only implements ToObjectValue() and Type(). +func (o JobParameterDefinition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobParameterDefinition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default": o.Default, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -4859,52 +3124,17 @@ func (a JobPermission) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o JobPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobPermission +// only implements ToObjectValue() and Type(). +func (o JobPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4947,52 +3177,17 @@ func (a JobPermissions) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o JobPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobPermissions +// only implements ToObjectValue() and Type(). +func (o JobPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -5031,52 +3226,16 @@ func (a JobPermissionsDescription) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o JobPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o JobPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -5108,58 +3267,22 @@ func (newState *JobPermissionsRequest) SyncEffectiveFieldsDuringRead(existingSta // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF // SDK values. -func (a JobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o JobPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) +func (a JobPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "access_control_list": reflect.TypeOf(JobAccessControlRequest{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "job_id": o.JobId, + }) } // Type implements basetypes.ObjectValuable. @@ -5206,52 +3329,16 @@ func (a JobRunAs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobRunAs{} - -// Equal implements basetypes.ObjectValuable. -func (o JobRunAs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobRunAs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobRunAs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobRunAs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobRunAs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobRunAs +// only implements ToObjectValue() and Type(). +func (o JobRunAs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobRunAs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -5402,52 +3489,37 @@ func (a JobSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobSettings{} - -// Equal implements basetypes.ObjectValuable. -func (o JobSettings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobSettings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobSettings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobSettings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobSettings +// only implements ToObjectValue() and Type(). +func (o JobSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "budget_policy_id": o.BudgetPolicyId, + "continuous": o.Continuous, + "deployment": o.Deployment, + "description": o.Description, + "edit_mode": o.EditMode, + "email_notifications": o.EmailNotifications, + "environment": o.Environments, + "format": o.Format, + "git_source": o.GitSource, + "health": o.Health, + "job_cluster": o.JobClusters, + "max_concurrent_runs": o.MaxConcurrentRuns, + "name": o.Name, + "notification_settings": o.NotificationSettings, + "parameter": o.Parameters, + "queue": o.Queue, + "run_as": o.RunAs, + "schedule": o.Schedule, + "tags": o.Tags, + "task": o.Tasks, + "timeout_seconds": o.TimeoutSeconds, + "trigger": o.Trigger, + "webhook_notifications": o.WebhookNotifications, + }) } // Type implements basetypes.ObjectValuable. @@ -5549,52 +3621,17 @@ func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobSource{} - -// Equal implements basetypes.ObjectValuable. -func (o JobSource) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobSource) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobSource) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobSource) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobSource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobSource +// only implements ToObjectValue() and Type(). +func (o JobSource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobSource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dirty_state": o.DirtyState, + "import_from_git_branch": o.ImportFromGitBranch, + "job_config_path": o.JobConfigPath, + }) } // Type implements basetypes.ObjectValuable. @@ -5647,52 +3684,17 @@ func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobsHealthRule{} - -// Equal implements basetypes.ObjectValuable. -func (o JobsHealthRule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobsHealthRule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobsHealthRule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobsHealthRule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobsHealthRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobsHealthRule +// only implements ToObjectValue() and Type(). +func (o JobsHealthRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobsHealthRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metric": o.Metric, + "op": o.Op, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -5730,52 +3732,15 @@ func (a JobsHealthRules) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobsHealthRules{} - -// Equal implements basetypes.ObjectValuable. -func (o JobsHealthRules) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobsHealthRules) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobsHealthRules) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobsHealthRules) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobsHealthRules) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobsHealthRules +// only implements ToObjectValue() and Type(). +func (o JobsHealthRules) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobsHealthRules) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "rules": o.Rules, + }) } // Type implements basetypes.ObjectValuable. @@ -5821,52 +3786,17 @@ func (a ListJobComplianceForPolicyResponse) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListJobComplianceForPolicyResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListJobComplianceForPolicyResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListJobComplianceForPolicyResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListJobComplianceForPolicyResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListJobComplianceForPolicyResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListJobComplianceForPolicyResponse +// only implements ToObjectValue() and Type(). +func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListJobComplianceForPolicyResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "jobs": o.Jobs, + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5912,52 +3842,17 @@ func (a ListJobComplianceRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListJobComplianceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListJobComplianceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListJobComplianceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListJobComplianceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListJobComplianceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListJobComplianceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListJobComplianceRequest +// only implements ToObjectValue() and Type(). +func (o ListJobComplianceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListJobComplianceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + "policy_id": o.PolicyId, + }) } // Type implements basetypes.ObjectValuable. @@ -6006,52 +3901,19 @@ func (a ListJobsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListJobsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListJobsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListJobsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListJobsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListJobsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListJobsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListJobsRequest +// only implements ToObjectValue() and Type(). +func (o ListJobsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListJobsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "expand_tasks": o.ExpandTasks, + "limit": o.Limit, + "name": o.Name, + "offset": o.Offset, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6101,52 +3963,18 @@ func (a ListJobsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListJobsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListJobsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListJobsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListJobsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListJobsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListJobsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListJobsResponse +// only implements ToObjectValue() and Type(). +func (o ListJobsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListJobsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "has_more": o.HasMore, + "jobs": o.Jobs, + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6220,52 +4048,24 @@ func (a ListRunsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRunsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRunsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRunsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRunsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRunsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRunsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRunsRequest +// only implements ToObjectValue() and Type(). +func (o ListRunsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRunsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "active_only": o.ActiveOnly, + "completed_only": o.CompletedOnly, + "expand_tasks": o.ExpandTasks, + "job_id": o.JobId, + "limit": o.Limit, + "offset": o.Offset, + "page_token": o.PageToken, + "run_type": o.RunType, + "start_time_from": o.StartTimeFrom, + "start_time_to": o.StartTimeTo, + }) } // Type implements basetypes.ObjectValuable. @@ -6320,52 +4120,18 @@ func (a ListRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRunsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRunsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRunsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRunsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRunsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRunsResponse +// only implements ToObjectValue() and Type(). +func (o ListRunsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "has_more": o.HasMore, + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + "runs": o.Runs, + }) } // Type implements basetypes.ObjectValuable. @@ -6411,52 +4177,16 @@ func (a NotebookOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NotebookOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o NotebookOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NotebookOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NotebookOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NotebookOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NotebookOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NotebookOutput +// only implements ToObjectValue() and Type(). +func (o NotebookOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NotebookOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "result": o.Result, + "truncated": o.Truncated, + }) } // Type implements basetypes.ObjectValuable. @@ -6529,52 +4259,18 @@ func (a NotebookTask) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NotebookTask{} - -// Equal implements basetypes.ObjectValuable. -func (o NotebookTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NotebookTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NotebookTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NotebookTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NotebookTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NotebookTask +// only implements ToObjectValue() and Type(). +func (o NotebookTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NotebookTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "base_parameters": o.BaseParameters, + "notebook_path": o.NotebookPath, + "source": o.Source, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -6615,52 +4311,16 @@ func (a PeriodicTriggerConfiguration) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PeriodicTriggerConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o PeriodicTriggerConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PeriodicTriggerConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PeriodicTriggerConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PeriodicTriggerConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PeriodicTriggerConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PeriodicTriggerConfiguration +// only implements ToObjectValue() and Type(). +func (o PeriodicTriggerConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PeriodicTriggerConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "interval": o.Interval, + "unit": o.Unit, + }) } // Type implements basetypes.ObjectValuable. @@ -6695,52 +4355,15 @@ func (a PipelineParams) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineParams{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineParams) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineParams) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineParams) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineParams) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineParams) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineParams +// only implements ToObjectValue() and Type(). +func (o PipelineParams) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineParams) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_refresh": o.FullRefresh, + }) } // Type implements basetypes.ObjectValuable. @@ -6776,52 +4399,16 @@ func (a PipelineTask) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineTask{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineTask +// only implements ToObjectValue() and Type(). +func (o PipelineTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "full_refresh": o.FullRefresh, + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -6870,52 +4457,18 @@ func (a PythonWheelTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PythonWheelTask{} - -// Equal implements basetypes.ObjectValuable. -func (o PythonWheelTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PythonWheelTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PythonWheelTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PythonWheelTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PythonWheelTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PythonWheelTask +// only implements ToObjectValue() and Type(). +func (o PythonWheelTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PythonWheelTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "entry_point": o.EntryPoint, + "named_parameters": o.NamedParameters, + "package_name": o.PackageName, + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -6964,52 +4517,16 @@ func (a QueueDetails) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueueDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o QueueDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueueDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueueDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueueDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueueDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueueDetails +// only implements ToObjectValue() and Type(). +func (o QueueDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueueDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "code": o.Code, + "message": o.Message, + }) } // Type implements basetypes.ObjectValuable. @@ -7038,58 +4555,21 @@ func (newState *QueueSettings) SyncEffectiveFieldsDuringRead(existingState Queue // the type information of their elements in the Go type system. This function provides a way to // retrieve the type information of the elements in complex fields at runtime. The values of the map // are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a QueueSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueueSettings{} - -// Equal implements basetypes.ObjectValuable. -func (o QueueSettings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueueSettings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueueSettings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueueSettings) String() string { - return fmt.Sprintf("%#v", o) +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a QueueSettings) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueueSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueueSettings +// only implements ToObjectValue() and Type(). +func (o QueueSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueueSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + }) } // Type implements basetypes.ObjectValuable. @@ -7142,52 +4622,21 @@ func (a RepairHistoryItem) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepairHistoryItem{} - -// Equal implements basetypes.ObjectValuable. -func (o RepairHistoryItem) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepairHistoryItem) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepairHistoryItem) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepairHistoryItem) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepairHistoryItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepairHistoryItem +// only implements ToObjectValue() and Type(). +func (o RepairHistoryItem) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepairHistoryItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end_time": o.EndTime, + "id": o.Id, + "start_time": o.StartTime, + "state": o.State, + "status": o.Status, + "task_run_ids": o.TaskRunIds, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -7342,52 +4791,28 @@ func (a RepairRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepairRun{} - -// Equal implements basetypes.ObjectValuable. -func (o RepairRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepairRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepairRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepairRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepairRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepairRun +// only implements ToObjectValue() and Type(). +func (o RepairRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepairRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbt_commands": o.DbtCommands, + "jar_params": o.JarParams, + "job_parameters": o.JobParameters, + "latest_repair_id": o.LatestRepairId, + "notebook_params": o.NotebookParams, + "pipeline_params": o.PipelineParams, + "python_named_params": o.PythonNamedParams, + "python_params": o.PythonParams, + "rerun_all_failed_tasks": o.RerunAllFailedTasks, + "rerun_dependent_tasks": o.RerunDependentTasks, + "rerun_tasks": o.RerunTasks, + "run_id": o.RunId, + "spark_submit_params": o.SparkSubmitParams, + "sql_params": o.SqlParams, + }) } // Type implements basetypes.ObjectValuable. @@ -7456,52 +4881,15 @@ func (a RepairRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepairRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RepairRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepairRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepairRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepairRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepairRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepairRunResponse +// only implements ToObjectValue() and Type(). +func (o RepairRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepairRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "repair_id": o.RepairId, + }) } // Type implements basetypes.ObjectValuable. @@ -7543,52 +4931,16 @@ func (a ResetJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResetJob{} - -// Equal implements basetypes.ObjectValuable. -func (o ResetJob) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResetJob) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResetJob) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResetJob) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResetJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResetJob +// only implements ToObjectValue() and Type(). +func (o ResetJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResetJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + "new_settings": o.NewSettings, + }) } // Type implements basetypes.ObjectValuable. @@ -7623,52 +4975,13 @@ func (a ResetResponse) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResetResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ResetResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResetResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResetResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResetResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResetResponse +// only implements ToObjectValue() and Type(). +func (o ResetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7701,52 +5014,16 @@ func (a ResolvedConditionTaskValues) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedConditionTaskValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedConditionTaskValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedConditionTaskValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedConditionTaskValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedConditionTaskValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedConditionTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedConditionTaskValues +// only implements ToObjectValue() and Type(). +func (o ResolvedConditionTaskValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedConditionTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "left": o.Left, + "right": o.Right, + }) } // Type implements basetypes.ObjectValuable. @@ -7782,52 +5059,15 @@ func (a ResolvedDbtTaskValues) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedDbtTaskValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedDbtTaskValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedDbtTaskValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedDbtTaskValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedDbtTaskValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedDbtTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedDbtTaskValues +// only implements ToObjectValue() and Type(). +func (o ResolvedDbtTaskValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedDbtTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "commands": o.Commands, + }) } // Type implements basetypes.ObjectValuable. @@ -7864,52 +5104,15 @@ func (a ResolvedNotebookTaskValues) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedNotebookTaskValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedNotebookTaskValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedNotebookTaskValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedNotebookTaskValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedNotebookTaskValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedNotebookTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedNotebookTaskValues +// only implements ToObjectValue() and Type(). +func (o ResolvedNotebookTaskValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedNotebookTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "base_parameters": o.BaseParameters, + }) } // Type implements basetypes.ObjectValuable. @@ -7946,52 +5149,15 @@ func (a ResolvedParamPairValues) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedParamPairValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedParamPairValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedParamPairValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedParamPairValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedParamPairValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedParamPairValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedParamPairValues +// only implements ToObjectValue() and Type(). +func (o ResolvedParamPairValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedParamPairValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -8031,52 +5197,16 @@ func (a ResolvedPythonWheelTaskValues) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedPythonWheelTaskValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedPythonWheelTaskValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedPythonWheelTaskValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedPythonWheelTaskValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedPythonWheelTaskValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedPythonWheelTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedPythonWheelTaskValues +// only implements ToObjectValue() and Type(). +func (o ResolvedPythonWheelTaskValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedPythonWheelTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "named_parameters": o.NamedParameters, + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -8119,52 +5249,16 @@ func (a ResolvedRunJobTaskValues) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedRunJobTaskValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedRunJobTaskValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedRunJobTaskValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedRunJobTaskValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedRunJobTaskValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedRunJobTaskValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedRunJobTaskValues +// only implements ToObjectValue() and Type(). +func (o ResolvedRunJobTaskValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedRunJobTaskValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_parameters": o.JobParameters, + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -8204,52 +5298,15 @@ func (a ResolvedStringParamsValues) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedStringParamsValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedStringParamsValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedStringParamsValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedStringParamsValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedStringParamsValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedStringParamsValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedStringParamsValues +// only implements ToObjectValue() and Type(). +func (o ResolvedStringParamsValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedStringParamsValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -8313,52 +5370,24 @@ func (a ResolvedValues) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResolvedValues{} - -// Equal implements basetypes.ObjectValuable. -func (o ResolvedValues) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResolvedValues) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResolvedValues) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResolvedValues) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResolvedValues) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResolvedValues +// only implements ToObjectValue() and Type(). +func (o ResolvedValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResolvedValues) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "condition_task": o.ConditionTask, + "dbt_task": o.DbtTask, + "notebook_task": o.NotebookTask, + "python_wheel_task": o.PythonWheelTask, + "run_job_task": o.RunJobTask, + "simulation_task": o.SimulationTask, + "spark_jar_task": o.SparkJarTask, + "spark_python_task": o.SparkPythonTask, + "spark_submit_task": o.SparkSubmitTask, + "sql_task": o.SqlTask, + }) } // Type implements basetypes.ObjectValuable. @@ -8566,52 +5595,47 @@ func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Run{} - -// Equal implements basetypes.ObjectValuable. -func (o Run) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Run) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Run) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Run) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Run) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Run) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Run +// only implements ToObjectValue() and Type(). +func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "attempt_number": o.AttemptNumber, + "cleanup_duration": o.CleanupDuration, + "cluster_instance": o.ClusterInstance, + "cluster_spec": o.ClusterSpec, + "creator_user_name": o.CreatorUserName, + "description": o.Description, + "end_time": o.EndTime, + "execution_duration": o.ExecutionDuration, + "git_source": o.GitSource, + "iterations": o.Iterations, + "job_clusters": o.JobClusters, + "job_id": o.JobId, + "job_parameters": o.JobParameters, + "job_run_id": o.JobRunId, + "next_page_token": o.NextPageToken, + "number_in_job": o.NumberInJob, + "original_attempt_run_id": o.OriginalAttemptRunId, + "overriding_parameters": o.OverridingParameters, + "queue_duration": o.QueueDuration, + "repair_history": o.RepairHistory, + "run_duration": o.RunDuration, + "run_id": o.RunId, + "run_name": o.RunName, + "run_page_url": o.RunPageUrl, + "run_type": o.RunType, + "schedule": o.Schedule, + "setup_duration": o.SetupDuration, + "start_time": o.StartTime, + "state": o.State, + "status": o.Status, + "tasks": o.Tasks, + "trigger": o.Trigger, + "trigger_info": o.TriggerInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -8721,52 +5745,18 @@ func (a RunConditionTask) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunConditionTask{} - -// Equal implements basetypes.ObjectValuable. -func (o RunConditionTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunConditionTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunConditionTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunConditionTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunConditionTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunConditionTask +// only implements ToObjectValue() and Type(). +func (o RunConditionTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunConditionTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "left": o.Left, + "op": o.Op, + "outcome": o.Outcome, + "right": o.Right, + }) } // Type implements basetypes.ObjectValuable. @@ -8816,52 +5806,18 @@ func (a RunForEachTask) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunForEachTask{} - -// Equal implements basetypes.ObjectValuable. -func (o RunForEachTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunForEachTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunForEachTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunForEachTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunForEachTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunForEachTask +// only implements ToObjectValue() and Type(). +func (o RunForEachTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunForEachTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "concurrency": o.Concurrency, + "inputs": o.Inputs, + "stats": o.Stats, + "task": o.Task, + }) } // Type implements basetypes.ObjectValuable. @@ -8902,52 +5858,15 @@ func (a RunJobOutput) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunJobOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o RunJobOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunJobOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunJobOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunJobOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunJobOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunJobOutput +// only implements ToObjectValue() and Type(). +func (o RunJobOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunJobOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -9075,52 +5994,24 @@ func (a RunJobTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunJobTask{} - -// Equal implements basetypes.ObjectValuable. -func (o RunJobTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunJobTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunJobTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunJobTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunJobTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunJobTask +// only implements ToObjectValue() and Type(). +func (o RunJobTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunJobTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbt_commands": o.DbtCommands, + "jar_params": o.JarParams, + "job_id": o.JobId, + "job_parameters": o.JobParameters, + "notebook_params": o.NotebookParams, + "pipeline_params": o.PipelineParams, + "python_named_params": o.PythonNamedParams, + "python_params": o.PythonParams, + "spark_submit_params": o.SparkSubmitParams, + "sql_params": o.SqlParams, + }) } // Type implements basetypes.ObjectValuable. @@ -9292,58 +6183,33 @@ func (a RunNow) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ "pipeline_params": reflect.TypeOf(PipelineParams{}), "python_named_params": reflect.TypeOf(types.String{}), "python_params": reflect.TypeOf(types.String{}), - "queue": reflect.TypeOf(QueueSettings{}), - "spark_submit_params": reflect.TypeOf(types.String{}), - "sql_params": reflect.TypeOf(types.String{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunNow{} - -// Equal implements basetypes.ObjectValuable. -func (o RunNow) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunNow) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunNow) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunNow) String() string { - return fmt.Sprintf("%#v", o) + "queue": reflect.TypeOf(QueueSettings{}), + "spark_submit_params": reflect.TypeOf(types.String{}), + "sql_params": reflect.TypeOf(types.String{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunNow) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunNow +// only implements ToObjectValue() and Type(). +func (o RunNow) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunNow) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbt_commands": o.DbtCommands, + "idempotency_token": o.IdempotencyToken, + "jar_params": o.JarParams, + "job_id": o.JobId, + "job_parameters": o.JobParameters, + "notebook_params": o.NotebookParams, + "only": o.Only, + "pipeline_params": o.PipelineParams, + "python_named_params": o.PythonNamedParams, + "python_params": o.PythonParams, + "queue": o.Queue, + "spark_submit_params": o.SparkSubmitParams, + "sql_params": o.SqlParams, + }) } // Type implements basetypes.ObjectValuable. @@ -9415,52 +6281,16 @@ func (a RunNowResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunNowResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RunNowResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunNowResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunNowResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunNowResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunNowResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunNowResponse +// only implements ToObjectValue() and Type(). +func (o RunNowResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunNowResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "number_in_job": o.NumberInJob, + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -9536,52 +6366,24 @@ func (a RunOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o RunOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunOutput +// only implements ToObjectValue() and Type(). +func (o RunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbt_output": o.DbtOutput, + "error": o.Error, + "error_trace": o.ErrorTrace, + "info": o.Info, + "logs": o.Logs, + "logs_truncated": o.LogsTruncated, + "metadata": o.Metadata, + "notebook_output": o.NotebookOutput, + "run_job_output": o.RunJobOutput, + "sql_output": o.SqlOutput, + }) } // Type implements basetypes.ObjectValuable. @@ -9723,52 +6525,22 @@ func (a RunParameters) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunParameters{} - -// Equal implements basetypes.ObjectValuable. -func (o RunParameters) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunParameters) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunParameters) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunParameters) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunParameters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunParameters +// only implements ToObjectValue() and Type(). +func (o RunParameters) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunParameters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbt_commands": o.DbtCommands, + "jar_params": o.JarParams, + "notebook_params": o.NotebookParams, + "pipeline_params": o.PipelineParams, + "python_named_params": o.PythonNamedParams, + "python_params": o.PythonParams, + "spark_submit_params": o.SparkSubmitParams, + "sql_params": o.SqlParams, + }) } // Type implements basetypes.ObjectValuable. @@ -9838,52 +6610,19 @@ func (a RunState) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunState{} - -// Equal implements basetypes.ObjectValuable. -func (o RunState) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunState) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunState) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunState) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunState +// only implements ToObjectValue() and Type(). +func (o RunState) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "life_cycle_state": o.LifeCycleState, + "queue_reason": o.QueueReason, + "result_state": o.ResultState, + "state_message": o.StateMessage, + "user_cancelled_or_timedout": o.UserCancelledOrTimedout, + }) } // Type implements basetypes.ObjectValuable. @@ -9930,52 +6669,17 @@ func (a RunStatus) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o RunStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunStatus +// only implements ToObjectValue() and Type(). +func (o RunStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "queue_details": o.QueueDetails, + "state": o.State, + "termination_details": o.TerminationDetails, + }) } // Type implements basetypes.ObjectValuable. @@ -10072,7 +6776,7 @@ type RunTask struct { Libraries types.List `tfsdk:"library" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. - NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` + NewCluster types.List `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications @@ -10201,52 +6905,53 @@ func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunTask{} - -// Equal implements basetypes.ObjectValuable. -func (o RunTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunTask +// only implements ToObjectValue() and Type(). +func (o RunTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "attempt_number": o.AttemptNumber, + "cleanup_duration": o.CleanupDuration, + "cluster_instance": o.ClusterInstance, + "condition_task": o.ConditionTask, + "dbt_task": o.DbtTask, + "depends_on": o.DependsOn, + "description": o.Description, + "email_notifications": o.EmailNotifications, + "end_time": o.EndTime, + "environment_key": o.EnvironmentKey, + "execution_duration": o.ExecutionDuration, + "existing_cluster_id": o.ExistingClusterId, + "for_each_task": o.ForEachTask, + "git_source": o.GitSource, + "job_cluster_key": o.JobClusterKey, + "library": o.Libraries, + "new_cluster": o.NewCluster, + "notebook_task": o.NotebookTask, + "notification_settings": o.NotificationSettings, + "pipeline_task": o.PipelineTask, + "python_wheel_task": o.PythonWheelTask, + "queue_duration": o.QueueDuration, + "resolved_values": o.ResolvedValues, + "run_duration": o.RunDuration, + "run_id": o.RunId, + "run_if": o.RunIf, + "run_job_task": o.RunJobTask, + "run_page_url": o.RunPageUrl, + "setup_duration": o.SetupDuration, + "spark_jar_task": o.SparkJarTask, + "spark_python_task": o.SparkPythonTask, + "spark_submit_task": o.SparkSubmitTask, + "sql_task": o.SqlTask, + "start_time": o.StartTime, + "state": o.State, + "status": o.Status, + "task_key": o.TaskKey, + "timeout_seconds": o.TimeoutSeconds, + "webhook_notifications": o.WebhookNotifications, + }) } // Type implements basetypes.ObjectValuable. @@ -10378,52 +7083,17 @@ func (a SparkJarTask) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparkJarTask{} - -// Equal implements basetypes.ObjectValuable. -func (o SparkJarTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparkJarTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparkJarTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparkJarTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparkJarTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparkJarTask +// only implements ToObjectValue() and Type(). +func (o SparkJarTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparkJarTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "jar_uri": o.JarUri, + "main_class_name": o.MainClassName, + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -10484,52 +7154,17 @@ func (a SparkPythonTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparkPythonTask{} - -// Equal implements basetypes.ObjectValuable. -func (o SparkPythonTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparkPythonTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparkPythonTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparkPythonTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparkPythonTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparkPythonTask +// only implements ToObjectValue() and Type(). +func (o SparkPythonTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparkPythonTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "parameters": o.Parameters, + "python_file": o.PythonFile, + "source": o.Source, + }) } // Type implements basetypes.ObjectValuable. @@ -10574,52 +7209,15 @@ func (a SparkSubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparkSubmitTask{} - -// Equal implements basetypes.ObjectValuable. -func (o SparkSubmitTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparkSubmitTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparkSubmitTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparkSubmitTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparkSubmitTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparkSubmitTask +// only implements ToObjectValue() and Type(). +func (o SparkSubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparkSubmitTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "parameters": o.Parameters, + }) } // Type implements basetypes.ObjectValuable. @@ -10670,52 +7268,19 @@ func (a SqlAlertOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlAlertOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlAlertOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlAlertOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlAlertOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlAlertOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlAlertOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlAlertOutput +// only implements ToObjectValue() and Type(). +func (o SqlAlertOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlAlertOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_state": o.AlertState, + "output_link": o.OutputLink, + "query_text": o.QueryText, + "sql_statements": o.SqlStatements, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -10759,52 +7324,16 @@ func (a SqlDashboardOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlDashboardOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlDashboardOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlDashboardOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlDashboardOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlDashboardOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlDashboardOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlDashboardOutput +// only implements ToObjectValue() and Type(). +func (o SqlDashboardOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlDashboardOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "warehouse_id": o.WarehouseId, + "widgets": o.Widgets, + }) } // Type implements basetypes.ObjectValuable. @@ -10855,52 +7384,21 @@ func (a SqlDashboardWidgetOutput) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlDashboardWidgetOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlDashboardWidgetOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlDashboardWidgetOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlDashboardWidgetOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlDashboardWidgetOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlDashboardWidgetOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlDashboardWidgetOutput +// only implements ToObjectValue() and Type(). +func (o SqlDashboardWidgetOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlDashboardWidgetOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end_time": o.EndTime, + "error": o.Error, + "output_link": o.OutputLink, + "start_time": o.StartTime, + "status": o.Status, + "widget_id": o.WidgetId, + "widget_title": o.WidgetTitle, + }) } // Type implements basetypes.ObjectValuable. @@ -10950,52 +7448,17 @@ func (a SqlOutput) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlOutput +// only implements ToObjectValue() and Type(). +func (o SqlOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_output": o.AlertOutput, + "dashboard_output": o.DashboardOutput, + "query_output": o.QueryOutput, + }) } // Type implements basetypes.ObjectValuable. @@ -11037,52 +7500,15 @@ func (a SqlOutputError) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlOutputError{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlOutputError) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlOutputError) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlOutputError) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlOutputError) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlOutputError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlOutputError +// only implements ToObjectValue() and Type(). +func (o SqlOutputError) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlOutputError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + }) } // Type implements basetypes.ObjectValuable. @@ -11126,52 +7552,19 @@ func (a SqlQueryOutput) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlQueryOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlQueryOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlQueryOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlQueryOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlQueryOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlQueryOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlQueryOutput +// only implements ToObjectValue() and Type(). +func (o SqlQueryOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlQueryOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_id": o.EndpointId, + "output_link": o.OutputLink, + "query_text": o.QueryText, + "sql_statements": o.SqlStatements, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -11211,52 +7604,15 @@ func (a SqlStatementOutput) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlStatementOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlStatementOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlStatementOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlStatementOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlStatementOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlStatementOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlStatementOutput +// only implements ToObjectValue() and Type(). +func (o SqlStatementOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlStatementOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "lookup_key": o.LookupKey, + }) } // Type implements basetypes.ObjectValuable. @@ -11311,52 +7667,20 @@ func (a SqlTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlTask{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlTask +// only implements ToObjectValue() and Type(). +func (o SqlTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert": o.Alert, + "dashboard": o.Dashboard, + "file": o.File, + "parameters": o.Parameters, + "query": o.Query, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -11411,52 +7735,17 @@ func (a SqlTaskAlert) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlTaskAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlTaskAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlTaskAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlTaskAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlTaskAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlTaskAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlTaskAlert +// only implements ToObjectValue() and Type(). +func (o SqlTaskAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlTaskAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_id": o.AlertId, + "pause_subscriptions": o.PauseSubscriptions, + "subscriptions": o.Subscriptions, + }) } // Type implements basetypes.ObjectValuable. @@ -11497,58 +7786,24 @@ func (newState *SqlTaskDashboard) SyncEffectiveFieldsDuringRead(existingState Sq // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF // SDK values. -func (a SqlTaskDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlTaskDashboard{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlTaskDashboard) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlTaskDashboard) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlTaskDashboard) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlTaskDashboard) String() string { - return fmt.Sprintf("%#v", o) +func (a SqlTaskDashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "subscriptions": reflect.TypeOf(SqlTaskSubscription{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlTaskDashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlTaskDashboard +// only implements ToObjectValue() and Type(). +func (o SqlTaskDashboard) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlTaskDashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "custom_subject": o.CustomSubject, + "dashboard_id": o.DashboardId, + "pause_subscriptions": o.PauseSubscriptions, + "subscriptions": o.Subscriptions, + }) } // Type implements basetypes.ObjectValuable. @@ -11597,52 +7852,16 @@ func (a SqlTaskFile) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlTaskFile{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlTaskFile) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlTaskFile) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlTaskFile) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlTaskFile) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlTaskFile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlTaskFile +// only implements ToObjectValue() and Type(). +func (o SqlTaskFile) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlTaskFile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + "source": o.Source, + }) } // Type implements basetypes.ObjectValuable. @@ -11677,52 +7896,15 @@ func (a SqlTaskQuery) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlTaskQuery{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlTaskQuery) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlTaskQuery) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlTaskQuery) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlTaskQuery) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlTaskQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlTaskQuery +// only implements ToObjectValue() and Type(). +func (o SqlTaskQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlTaskQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query_id": o.QueryId, + }) } // Type implements basetypes.ObjectValuable. @@ -11763,52 +7945,16 @@ func (a SqlTaskSubscription) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SqlTaskSubscription{} - -// Equal implements basetypes.ObjectValuable. -func (o SqlTaskSubscription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SqlTaskSubscription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SqlTaskSubscription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SqlTaskSubscription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SqlTaskSubscription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SqlTaskSubscription +// only implements ToObjectValue() and Type(). +func (o SqlTaskSubscription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SqlTaskSubscription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_id": o.DestinationId, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -11911,52 +8057,28 @@ func (a SubmitRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SubmitRun{} - -// Equal implements basetypes.ObjectValuable. -func (o SubmitRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SubmitRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SubmitRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SubmitRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SubmitRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SubmitRun +// only implements ToObjectValue() and Type(). +func (o SubmitRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SubmitRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "budget_policy_id": o.BudgetPolicyId, + "email_notifications": o.EmailNotifications, + "environments": o.Environments, + "git_source": o.GitSource, + "health": o.Health, + "idempotency_token": o.IdempotencyToken, + "notification_settings": o.NotificationSettings, + "queue": o.Queue, + "run_as": o.RunAs, + "run_name": o.RunName, + "tasks": o.Tasks, + "timeout_seconds": o.TimeoutSeconds, + "webhook_notifications": o.WebhookNotifications, + }) } // Type implements basetypes.ObjectValuable. @@ -12024,52 +8146,15 @@ func (a SubmitRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SubmitRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SubmitRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SubmitRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SubmitRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SubmitRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SubmitRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SubmitRunResponse +// only implements ToObjectValue() and Type(). +func (o SubmitRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SubmitRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -12120,7 +8205,7 @@ type SubmitTask struct { Libraries types.List `tfsdk:"library" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. - NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` + NewCluster types.List `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications @@ -12217,52 +8302,38 @@ func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SubmitTask{} - -// Equal implements basetypes.ObjectValuable. -func (o SubmitTask) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SubmitTask) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SubmitTask) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SubmitTask) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SubmitTask) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SubmitTask) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SubmitTask +// only implements ToObjectValue() and Type(). +func (o SubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "condition_task": o.ConditionTask, + "dbt_task": o.DbtTask, + "depends_on": o.DependsOn, + "description": o.Description, + "email_notifications": o.EmailNotifications, + "environment_key": o.EnvironmentKey, + "existing_cluster_id": o.ExistingClusterId, + "for_each_task": o.ForEachTask, + "health": o.Health, + "library": o.Libraries, + "new_cluster": o.NewCluster, + "notebook_task": o.NotebookTask, + "notification_settings": o.NotificationSettings, + "pipeline_task": o.PipelineTask, + "python_wheel_task": o.PythonWheelTask, + "run_if": o.RunIf, + "run_job_task": o.RunJobTask, + "spark_jar_task": o.SparkJarTask, + "spark_python_task": o.SparkPythonTask, + "spark_submit_task": o.SparkSubmitTask, + "sql_task": o.SqlTask, + "task_key": o.TaskKey, + "timeout_seconds": o.TimeoutSeconds, + "webhook_notifications": o.WebhookNotifications, + }) } // Type implements basetypes.ObjectValuable. @@ -12369,52 +8440,18 @@ func (a TableUpdateTriggerConfiguration) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableUpdateTriggerConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o TableUpdateTriggerConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableUpdateTriggerConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableUpdateTriggerConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableUpdateTriggerConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableUpdateTriggerConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableUpdateTriggerConfiguration +// only implements ToObjectValue() and Type(). +func (o TableUpdateTriggerConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableUpdateTriggerConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "condition": o.Condition, + "min_time_between_triggers_seconds": o.MinTimeBetweenTriggersSeconds, + "table_names": o.TableNames, + "wait_after_last_change_seconds": o.WaitAfterLastChangeSeconds, + }) } // Type implements basetypes.ObjectValuable. @@ -12485,7 +8522,7 @@ type Task struct { MinRetryIntervalMillis types.Int64 `tfsdk:"min_retry_interval_millis" tf:"optional"` // If new_cluster, a description of a new cluster that is created for each // run. - NewCluster compute.ClusterSpec `tfsdk:"new_cluster" tf:"optional,object"` + NewCluster types.List `tfsdk:"new_cluster" tf:"optional,object"` // The task runs a notebook when the `notebook_task` field is present. NotebookTask types.List `tfsdk:"notebook_task" tf:"optional,object"` // Optional notification settings that are used when sending notifications @@ -12590,52 +8627,43 @@ func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Task{} - -// Equal implements basetypes.ObjectValuable. -func (o Task) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Task) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Task) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Task) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Task) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Task) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Task +// only implements ToObjectValue() and Type(). +func (o Task) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "condition_task": o.ConditionTask, + "dbt_task": o.DbtTask, + "depends_on": o.DependsOn, + "description": o.Description, + "disable_auto_optimization": o.DisableAutoOptimization, + "email_notifications": o.EmailNotifications, + "environment_key": o.EnvironmentKey, + "existing_cluster_id": o.ExistingClusterId, + "for_each_task": o.ForEachTask, + "health": o.Health, + "job_cluster_key": o.JobClusterKey, + "library": o.Libraries, + "max_retries": o.MaxRetries, + "min_retry_interval_millis": o.MinRetryIntervalMillis, + "new_cluster": o.NewCluster, + "notebook_task": o.NotebookTask, + "notification_settings": o.NotificationSettings, + "pipeline_task": o.PipelineTask, + "python_wheel_task": o.PythonWheelTask, + "retry_on_timeout": o.RetryOnTimeout, + "run_if": o.RunIf, + "run_job_task": o.RunJobTask, + "spark_jar_task": o.SparkJarTask, + "spark_python_task": o.SparkPythonTask, + "spark_submit_task": o.SparkSubmitTask, + "sql_task": o.SqlTask, + "task_key": o.TaskKey, + "timeout_seconds": o.TimeoutSeconds, + "webhook_notifications": o.WebhookNotifications, + }) } // Type implements basetypes.ObjectValuable. @@ -12736,52 +8764,16 @@ func (a TaskDependency) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TaskDependency{} - -// Equal implements basetypes.ObjectValuable. -func (o TaskDependency) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TaskDependency) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TaskDependency) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TaskDependency) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TaskDependency) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TaskDependency +// only implements ToObjectValue() and Type(). +func (o TaskDependency) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TaskDependency) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "outcome": o.Outcome, + "task_key": o.TaskKey, + }) } // Type implements basetypes.ObjectValuable. @@ -12853,52 +8845,20 @@ func (a TaskEmailNotifications) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TaskEmailNotifications{} - -// Equal implements basetypes.ObjectValuable. -func (o TaskEmailNotifications) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TaskEmailNotifications) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TaskEmailNotifications) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TaskEmailNotifications) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TaskEmailNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TaskEmailNotifications +// only implements ToObjectValue() and Type(). +func (o TaskEmailNotifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TaskEmailNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "no_alert_for_skipped_runs": o.NoAlertForSkippedRuns, + "on_duration_warning_threshold_exceeded": o.OnDurationWarningThresholdExceeded, + "on_failure": o.OnFailure, + "on_start": o.OnStart, + "on_streaming_backlog_exceeded": o.OnStreamingBacklogExceeded, + "on_success": o.OnSuccess, + }) } // Type implements basetypes.ObjectValuable. @@ -12955,52 +8915,17 @@ func (a TaskNotificationSettings) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TaskNotificationSettings{} - -// Equal implements basetypes.ObjectValuable. -func (o TaskNotificationSettings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TaskNotificationSettings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TaskNotificationSettings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TaskNotificationSettings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TaskNotificationSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TaskNotificationSettings +// only implements ToObjectValue() and Type(). +func (o TaskNotificationSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TaskNotificationSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_on_last_attempt": o.AlertOnLastAttempt, + "no_alert_for_canceled_runs": o.NoAlertForCanceledRuns, + "no_alert_for_skipped_runs": o.NoAlertForSkippedRuns, + }) } // Type implements basetypes.ObjectValuable. @@ -13092,52 +9017,17 @@ func (a TerminationDetails) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TerminationDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o TerminationDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TerminationDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TerminationDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TerminationDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TerminationDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TerminationDetails +// only implements ToObjectValue() and Type(). +func (o TerminationDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TerminationDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "code": o.Code, + "message": o.Message, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -13174,52 +9064,15 @@ func (a TriggerInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TriggerInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o TriggerInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TriggerInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TriggerInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TriggerInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TriggerInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TriggerInfo +// only implements ToObjectValue() and Type(). +func (o TriggerInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TriggerInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -13266,52 +9119,19 @@ func (a TriggerSettings) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TriggerSettings{} - -// Equal implements basetypes.ObjectValuable. -func (o TriggerSettings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TriggerSettings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TriggerSettings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TriggerSettings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TriggerSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TriggerSettings +// only implements ToObjectValue() and Type(). +func (o TriggerSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TriggerSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_arrival": o.FileArrival, + "pause_status": o.PauseStatus, + "periodic": o.Periodic, + "table": o.Table, + "table_update": o.TableUpdate, + }) } // Type implements basetypes.ObjectValuable. @@ -13376,52 +9196,17 @@ func (a UpdateJob) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateJob{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateJob) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateJob) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateJob) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateJob) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateJob) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateJob +// only implements ToObjectValue() and Type(). +func (o UpdateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateJob) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "fields_to_remove": o.FieldsToRemove, + "job_id": o.JobId, + "new_settings": o.NewSettings, + }) } // Type implements basetypes.ObjectValuable. @@ -13459,52 +9244,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -13542,52 +9288,17 @@ func (a ViewItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ViewItem{} - -// Equal implements basetypes.ObjectValuable. -func (o ViewItem) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ViewItem) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ViewItem) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ViewItem) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ViewItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ViewItem +// only implements ToObjectValue() and Type(). +func (o ViewItem) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ViewItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "name": o.Name, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -13622,52 +9333,15 @@ func (a Webhook) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Webhook{} - -// Equal implements basetypes.ObjectValuable. -func (o Webhook) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Webhook) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Webhook) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Webhook) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Webhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Webhook +// only implements ToObjectValue() and Type(). +func (o Webhook) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Webhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -13729,52 +9403,19 @@ func (a WebhookNotifications) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WebhookNotifications{} - -// Equal implements basetypes.ObjectValuable. -func (o WebhookNotifications) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WebhookNotifications) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WebhookNotifications) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WebhookNotifications) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WebhookNotifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WebhookNotifications +// only implements ToObjectValue() and Type(). +func (o WebhookNotifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WebhookNotifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "on_duration_warning_threshold_exceeded": o.OnDurationWarningThresholdExceeded, + "on_failure": o.OnFailure, + "on_start": o.OnStart, + "on_streaming_backlog_exceeded": o.OnStreamingBacklogExceeded, + "on_success": o.OnSuccess, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 544b007491..8d05f64f8d 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -12,15 +12,11 @@ package marketplace_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AddExchangeForListingRequest struct { @@ -46,52 +42,16 @@ func (a AddExchangeForListingRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AddExchangeForListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o AddExchangeForListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AddExchangeForListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AddExchangeForListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AddExchangeForListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AddExchangeForListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AddExchangeForListingRequest +// only implements ToObjectValue() and Type(). +func (o AddExchangeForListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AddExchangeForListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_id": o.ExchangeId, + "listing_id": o.ListingId, + }) } // Type implements basetypes.ObjectValuable. @@ -127,52 +87,15 @@ func (a AddExchangeForListingResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AddExchangeForListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o AddExchangeForListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AddExchangeForListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AddExchangeForListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AddExchangeForListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AddExchangeForListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AddExchangeForListingResponse +// only implements ToObjectValue() and Type(). +func (o AddExchangeForListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AddExchangeForListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_for_listing": o.ExchangeForListing, + }) } // Type implements basetypes.ObjectValuable. @@ -210,52 +133,15 @@ func (a BatchGetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BatchGetListingsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o BatchGetListingsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BatchGetListingsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BatchGetListingsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BatchGetListingsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BatchGetListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BatchGetListingsRequest +// only implements ToObjectValue() and Type(). +func (o BatchGetListingsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BatchGetListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ids": o.Ids, + }) } // Type implements basetypes.ObjectValuable. @@ -292,52 +178,15 @@ func (a BatchGetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BatchGetListingsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o BatchGetListingsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BatchGetListingsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BatchGetListingsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BatchGetListingsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BatchGetListingsResponse +// only implements ToObjectValue() and Type(). +func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BatchGetListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listings": o.Listings, + }) } // Type implements basetypes.ObjectValuable. @@ -375,52 +224,15 @@ func (a BatchGetProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BatchGetProvidersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o BatchGetProvidersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BatchGetProvidersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BatchGetProvidersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BatchGetProvidersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BatchGetProvidersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BatchGetProvidersRequest +// only implements ToObjectValue() and Type(). +func (o BatchGetProvidersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BatchGetProvidersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ids": o.Ids, + }) } // Type implements basetypes.ObjectValuable. @@ -457,52 +269,15 @@ func (a BatchGetProvidersResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BatchGetProvidersResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o BatchGetProvidersResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BatchGetProvidersResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BatchGetProvidersResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BatchGetProvidersResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BatchGetProvidersResponse +// only implements ToObjectValue() and Type(). +func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BatchGetProvidersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "providers": o.Providers, + }) } // Type implements basetypes.ObjectValuable. @@ -537,52 +312,15 @@ func (a ConsumerTerms) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ConsumerTerms{} - -// Equal implements basetypes.ObjectValuable. -func (o ConsumerTerms) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ConsumerTerms) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ConsumerTerms) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ConsumerTerms) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ConsumerTerms) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ConsumerTerms +// only implements ToObjectValue() and Type(). +func (o ConsumerTerms) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ConsumerTerms) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -623,52 +361,18 @@ func (a ContactInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ContactInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ContactInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ContactInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ContactInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ContactInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ContactInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ContactInfo +// only implements ToObjectValue() and Type(). +func (o ContactInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ContactInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "company": o.Company, + "email": o.Email, + "first_name": o.FirstName, + "last_name": o.LastName, + }) } // Type implements basetypes.ObjectValuable. @@ -706,52 +410,15 @@ func (a CreateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExchangeFilterRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExchangeFilterRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExchangeFilterRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExchangeFilterRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExchangeFilterRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExchangeFilterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExchangeFilterRequest +// only implements ToObjectValue() and Type(). +func (o CreateExchangeFilterRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExchangeFilterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + }) } // Type implements basetypes.ObjectValuable. @@ -786,52 +453,15 @@ func (a CreateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExchangeFilterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExchangeFilterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExchangeFilterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExchangeFilterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExchangeFilterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExchangeFilterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExchangeFilterResponse +// only implements ToObjectValue() and Type(). +func (o CreateExchangeFilterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExchangeFilterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter_id": o.FilterId, + }) } // Type implements basetypes.ObjectValuable. @@ -866,52 +496,15 @@ func (a CreateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExchangeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExchangeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExchangeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExchangeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExchangeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExchangeRequest +// only implements ToObjectValue() and Type(). +func (o CreateExchangeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange": o.Exchange, + }) } // Type implements basetypes.ObjectValuable. @@ -946,52 +539,15 @@ func (a CreateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExchangeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExchangeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExchangeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExchangeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExchangeResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExchangeResponse +// only implements ToObjectValue() and Type(). +func (o CreateExchangeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_id": o.ExchangeId, + }) } // Type implements basetypes.ObjectValuable. @@ -1032,52 +588,18 @@ func (a CreateFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateFileRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateFileRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateFileRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateFileRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateFileRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateFileRequest +// only implements ToObjectValue() and Type(). +func (o CreateFileRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display_name": o.DisplayName, + "file_parent": o.FileParent, + "marketplace_file_type": o.MarketplaceFileType, + "mime_type": o.MimeType, + }) } // Type implements basetypes.ObjectValuable. @@ -1119,52 +641,16 @@ func (a CreateFileResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateFileResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateFileResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateFileResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateFileResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateFileResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateFileResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateFileResponse +// only implements ToObjectValue() and Type(). +func (o CreateFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateFileResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_info": o.FileInfo, + "upload_url": o.UploadUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -1213,52 +699,20 @@ func (a CreateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateInstallationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateInstallationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateInstallationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateInstallationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateInstallationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateInstallationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateInstallationRequest +// only implements ToObjectValue() and Type(). +func (o CreateInstallationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateInstallationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "accepted_consumer_terms": o.AcceptedConsumerTerms, + "catalog_name": o.CatalogName, + "listing_id": o.ListingId, + "recipient_type": o.RecipientType, + "repo_detail": o.RepoDetail, + "share_name": o.ShareName, + }) } // Type implements basetypes.ObjectValuable. @@ -1302,52 +756,15 @@ func (a CreateListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateListingRequest +// only implements ToObjectValue() and Type(). +func (o CreateListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing": o.Listing, + }) } // Type implements basetypes.ObjectValuable. @@ -1382,52 +799,15 @@ func (a CreateListingResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateListingResponse +// only implements ToObjectValue() and Type(). +func (o CreateListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + }) } // Type implements basetypes.ObjectValuable. @@ -1479,52 +859,23 @@ func (a CreatePersonalizationRequest) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePersonalizationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePersonalizationRequest +// only implements ToObjectValue() and Type(). +func (o CreatePersonalizationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "accepted_consumer_terms": o.AcceptedConsumerTerms, + "comment": o.Comment, + "company": o.Company, + "first_name": o.FirstName, + "intended_use": o.IntendedUse, + "is_from_lighthouse": o.IsFromLighthouse, + "last_name": o.LastName, + "listing_id": o.ListingId, + "recipient_type": o.RecipientType, + }) } // Type implements basetypes.ObjectValuable. @@ -1567,52 +918,15 @@ func (a CreatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePersonalizationRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePersonalizationRequestResponse +// only implements ToObjectValue() and Type(). +func (o CreatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePersonalizationRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -1647,52 +961,15 @@ func (a CreateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateProviderRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateProviderRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateProviderRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateProviderRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateProviderRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateProviderRequest +// only implements ToObjectValue() and Type(). +func (o CreateProviderRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "provider": o.Provider, + }) } // Type implements basetypes.ObjectValuable. @@ -1727,52 +1004,15 @@ func (a CreateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateProviderResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateProviderResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateProviderResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateProviderResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateProviderResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateProviderResponse +// only implements ToObjectValue() and Type(). +func (o CreateProviderResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -1807,52 +1047,16 @@ func (a DataRefreshInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DataRefreshInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o DataRefreshInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DataRefreshInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DataRefreshInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DataRefreshInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DataRefreshInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DataRefreshInfo +// only implements ToObjectValue() and Type(). +func (o DataRefreshInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DataRefreshInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "interval": o.Interval, + "unit": o.Unit, + }) } // Type implements basetypes.ObjectValuable. @@ -1887,52 +1091,15 @@ func (a DeleteExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExchangeFilterRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExchangeFilterRequest +// only implements ToObjectValue() and Type(). +func (o DeleteExchangeFilterRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -1964,52 +1131,13 @@ func (a DeleteExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExchangeFilterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExchangeFilterResponse +// only implements ToObjectValue() and Type(). +func (o DeleteExchangeFilterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExchangeFilterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2041,52 +1169,15 @@ func (a DeleteExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExchangeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExchangeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExchangeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExchangeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExchangeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExchangeRequest +// only implements ToObjectValue() and Type(). +func (o DeleteExchangeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -2118,52 +1209,13 @@ func (a DeleteExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExchangeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExchangeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExchangeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExchangeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExchangeResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExchangeResponse +// only implements ToObjectValue() and Type(). +func (o DeleteExchangeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2195,52 +1247,15 @@ func (a DeleteFileRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteFileRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteFileRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteFileRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteFileRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteFileRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteFileRequest +// only implements ToObjectValue() and Type(). +func (o DeleteFileRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_id": o.FileId, + }) } // Type implements basetypes.ObjectValuable. @@ -2272,52 +1287,13 @@ func (a DeleteFileResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteFileResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteFileResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteFileResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteFileResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteFileResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteFileResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteFileResponse +// only implements ToObjectValue() and Type(). +func (o DeleteFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteFileResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2351,52 +1327,16 @@ func (a DeleteInstallationRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteInstallationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteInstallationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteInstallationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteInstallationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteInstallationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteInstallationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteInstallationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteInstallationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteInstallationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "installation_id": o.InstallationId, + "listing_id": o.ListingId, + }) } // Type implements basetypes.ObjectValuable. @@ -2429,52 +1369,13 @@ func (a DeleteInstallationResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteInstallationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteInstallationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteInstallationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteInstallationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteInstallationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteInstallationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteInstallationResponse +// only implements ToObjectValue() and Type(). +func (o DeleteInstallationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteInstallationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2506,52 +1407,15 @@ func (a DeleteListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteListingRequest +// only implements ToObjectValue() and Type(). +func (o DeleteListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -2583,52 +1447,13 @@ func (a DeleteListingResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteListingResponse +// only implements ToObjectValue() and Type(). +func (o DeleteListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2660,52 +1485,15 @@ func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteProviderRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteProviderRequest +// only implements ToObjectValue() and Type(). +func (o DeleteProviderRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -2737,52 +1525,13 @@ func (a DeleteProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteProviderResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteProviderResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteProviderResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteProviderResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteProviderResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteProviderResponse +// only implements ToObjectValue() and Type(). +func (o DeleteProviderResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2829,55 +1578,26 @@ func (a Exchange) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{ "filters": reflect.TypeOf(ExchangeFilter{}), "linked_listings": reflect.TypeOf(ExchangeListing{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Exchange{} - -// Equal implements basetypes.ObjectValuable. -func (o Exchange) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Exchange) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Exchange) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Exchange) String() string { - return fmt.Sprintf("%#v", o) + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o Exchange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Exchange +// only implements ToObjectValue() and Type(). +func (o Exchange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Exchange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "filters": o.Filters, + "id": o.Id, + "linked_listings": o.LinkedListings, + "name": o.Name, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -2938,52 +1658,23 @@ func (a ExchangeFilter) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExchangeFilter{} - -// Equal implements basetypes.ObjectValuable. -func (o ExchangeFilter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExchangeFilter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExchangeFilter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExchangeFilter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExchangeFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExchangeFilter +// only implements ToObjectValue() and Type(). +func (o ExchangeFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExchangeFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "exchange_id": o.ExchangeId, + "filter_type": o.FilterType, + "filter_value": o.FilterValue, + "id": o.Id, + "name": o.Name, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -3036,52 +1727,21 @@ func (a ExchangeListing) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExchangeListing{} - -// Equal implements basetypes.ObjectValuable. -func (o ExchangeListing) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExchangeListing) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExchangeListing) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExchangeListing) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExchangeListing) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExchangeListing +// only implements ToObjectValue() and Type(). +func (o ExchangeListing) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExchangeListing) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "exchange_id": o.ExchangeId, + "exchange_name": o.ExchangeName, + "id": o.Id, + "listing_id": o.ListingId, + "listing_name": o.ListingName, + }) } // Type implements basetypes.ObjectValuable. @@ -3141,52 +1801,24 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FileInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o FileInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FileInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FileInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FileInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FileInfo +// only implements ToObjectValue() and Type(). +func (o FileInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "display_name": o.DisplayName, + "download_link": o.DownloadLink, + "file_parent": o.FileParent, + "id": o.Id, + "marketplace_file_type": o.MarketplaceFileType, + "mime_type": o.MimeType, + "status": o.Status, + "status_message": o.StatusMessage, + "updated_at": o.UpdatedAt, + }) } // Type implements basetypes.ObjectValuable. @@ -3232,52 +1864,16 @@ func (a FileParent) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FileParent{} - -// Equal implements basetypes.ObjectValuable. -func (o FileParent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FileParent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FileParent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FileParent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FileParent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FileParent +// only implements ToObjectValue() and Type(). +func (o FileParent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FileParent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_parent_type": o.FileParentType, + "parent_id": o.ParentId, + }) } // Type implements basetypes.ObjectValuable. @@ -3312,52 +1908,15 @@ func (a GetExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExchangeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExchangeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExchangeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExchangeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExchangeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExchangeRequest +// only implements ToObjectValue() and Type(). +func (o GetExchangeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3392,52 +1951,15 @@ func (a GetExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExchangeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExchangeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExchangeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExchangeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExchangeResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExchangeResponse +// only implements ToObjectValue() and Type(). +func (o GetExchangeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange": o.Exchange, + }) } // Type implements basetypes.ObjectValuable. @@ -3473,52 +1995,15 @@ func (a GetFileRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetFileRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetFileRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetFileRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetFileRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetFileRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetFileRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetFileRequest +// only implements ToObjectValue() and Type(). +func (o GetFileRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetFileRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_id": o.FileId, + }) } // Type implements basetypes.ObjectValuable. @@ -3553,52 +2038,15 @@ func (a GetFileResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetFileResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetFileResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetFileResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetFileResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetFileResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetFileResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetFileResponse +// only implements ToObjectValue() and Type(). +func (o GetFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetFileResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_info": o.FileInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -3634,52 +2082,15 @@ func (a GetLatestVersionProviderAnalyticsDashboardResponse) GetComplexFieldTypes return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetLatestVersionProviderAnalyticsDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetLatestVersionProviderAnalyticsDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetLatestVersionProviderAnalyticsDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetLatestVersionProviderAnalyticsDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetLatestVersionProviderAnalyticsDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetLatestVersionProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetLatestVersionProviderAnalyticsDashboardResponse +// only implements ToObjectValue() and Type(). +func (o GetLatestVersionProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetLatestVersionProviderAnalyticsDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -3717,52 +2128,17 @@ func (a GetListingContentMetadataRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetListingContentMetadataRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetListingContentMetadataRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetListingContentMetadataRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetListingContentMetadataRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetListingContentMetadataRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetListingContentMetadataRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetListingContentMetadataRequest +// only implements ToObjectValue() and Type(). +func (o GetListingContentMetadataRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetListingContentMetadataRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -3801,52 +2177,16 @@ func (a GetListingContentMetadataResponse) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetListingContentMetadataResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetListingContentMetadataResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetListingContentMetadataResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetListingContentMetadataResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetListingContentMetadataResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetListingContentMetadataResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetListingContentMetadataResponse +// only implements ToObjectValue() and Type(). +func (o GetListingContentMetadataResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetListingContentMetadataResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "shared_data_objects": o.SharedDataObjects, + }) } // Type implements basetypes.ObjectValuable. @@ -3883,52 +2223,15 @@ func (a GetListingRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetListingRequest +// only implements ToObjectValue() and Type(). +func (o GetListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3963,52 +2266,15 @@ func (a GetListingResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetListingResponse +// only implements ToObjectValue() and Type(). +func (o GetListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing": o.Listing, + }) } // Type implements basetypes.ObjectValuable. @@ -4046,52 +2312,16 @@ func (a GetListingsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetListingsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetListingsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetListingsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetListingsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetListingsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetListingsRequest +// only implements ToObjectValue() and Type(). +func (o GetListingsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -4129,52 +2359,16 @@ func (a GetListingsResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetListingsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetListingsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetListingsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetListingsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetListingsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetListingsResponse +// only implements ToObjectValue() and Type(). +func (o GetListingsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listings": o.Listings, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -4211,52 +2405,15 @@ func (a GetPersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPersonalizationRequestRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPersonalizationRequestRequest +// only implements ToObjectValue() and Type(). +func (o GetPersonalizationRequestRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + }) } // Type implements basetypes.ObjectValuable. @@ -4291,52 +2448,15 @@ func (a GetPersonalizationRequestResponse) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPersonalizationRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPersonalizationRequestResponse +// only implements ToObjectValue() and Type(). +func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPersonalizationRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "personalization_requests": o.PersonalizationRequests, + }) } // Type implements basetypes.ObjectValuable. @@ -4372,52 +2492,15 @@ func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetProviderRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetProviderRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetProviderRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetProviderRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetProviderRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetProviderRequest +// only implements ToObjectValue() and Type(). +func (o GetProviderRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -4452,52 +2535,15 @@ func (a GetProviderResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetProviderResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetProviderResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetProviderResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetProviderResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetProviderResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetProviderResponse +// only implements ToObjectValue() and Type(). +func (o GetProviderResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "provider": o.Provider, + }) } // Type implements basetypes.ObjectValuable. @@ -4530,56 +2576,19 @@ func (newState *Installation) SyncEffectiveFieldsDuringRead(existingState Instal // SDK values. func (a Installation) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "installation": reflect.TypeOf(InstallationDetail{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Installation{} - -// Equal implements basetypes.ObjectValuable. -func (o Installation) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false + "installation": reflect.TypeOf(InstallationDetail{}), } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Installation) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Installation) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Installation) String() string { - return fmt.Sprintf("%#v", o) } -// ToObjectValue implements basetypes.ObjectValuable. -func (o Installation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Installation +// only implements ToObjectValue() and Type(). +func (o Installation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Installation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "installation": o.Installation, + }) } // Type implements basetypes.ObjectValuable. @@ -4641,52 +2650,27 @@ func (a InstallationDetail) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InstallationDetail{} - -// Equal implements basetypes.ObjectValuable. -func (o InstallationDetail) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InstallationDetail) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InstallationDetail) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InstallationDetail) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InstallationDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InstallationDetail +// only implements ToObjectValue() and Type(). +func (o InstallationDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InstallationDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "error_message": o.ErrorMessage, + "id": o.Id, + "installed_on": o.InstalledOn, + "listing_id": o.ListingId, + "listing_name": o.ListingName, + "recipient_type": o.RecipientType, + "repo_name": o.RepoName, + "repo_path": o.RepoPath, + "share_name": o.ShareName, + "status": o.Status, + "token_detail": o.TokenDetail, + "tokens": o.Tokens, + }) } // Type implements basetypes.ObjectValuable. @@ -4738,52 +2722,16 @@ func (a ListAllInstallationsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAllInstallationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAllInstallationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAllInstallationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAllInstallationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAllInstallationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAllInstallationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAllInstallationsRequest +// only implements ToObjectValue() and Type(). +func (o ListAllInstallationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAllInstallationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -4821,52 +2769,16 @@ func (a ListAllInstallationsResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAllInstallationsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAllInstallationsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAllInstallationsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAllInstallationsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAllInstallationsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAllInstallationsResponse +// only implements ToObjectValue() and Type(). +func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAllInstallationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "installations": o.Installations, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -4905,52 +2817,16 @@ func (a ListAllPersonalizationRequestsRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAllPersonalizationRequestsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAllPersonalizationRequestsRequest +// only implements ToObjectValue() and Type(). +func (o ListAllPersonalizationRequestsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -4988,52 +2864,16 @@ func (a ListAllPersonalizationRequestsResponse) GetComplexFieldTypes(ctx context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAllPersonalizationRequestsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAllPersonalizationRequestsResponse +// only implements ToObjectValue() and Type(). +func (o ListAllPersonalizationRequestsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAllPersonalizationRequestsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "personalization_requests": o.PersonalizationRequests, + }) } // Type implements basetypes.ObjectValuable. @@ -5074,52 +2914,17 @@ func (a ListExchangeFiltersRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExchangeFiltersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExchangeFiltersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExchangeFiltersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExchangeFiltersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExchangeFiltersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExchangeFiltersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExchangeFiltersRequest +// only implements ToObjectValue() and Type(). +func (o ListExchangeFiltersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExchangeFiltersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_id": o.ExchangeId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5158,52 +2963,16 @@ func (a ListExchangeFiltersResponse) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExchangeFiltersResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExchangeFiltersResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExchangeFiltersResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExchangeFiltersResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExchangeFiltersResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExchangeFiltersResponse +// only implements ToObjectValue() and Type(). +func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExchangeFiltersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filters": o.Filters, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5244,52 +3013,17 @@ func (a ListExchangesForListingRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExchangesForListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExchangesForListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExchangesForListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExchangesForListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExchangesForListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExchangesForListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExchangesForListingRequest +// only implements ToObjectValue() and Type(). +func (o ListExchangesForListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExchangesForListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5328,52 +3062,16 @@ func (a ListExchangesForListingResponse) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExchangesForListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExchangesForListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExchangesForListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExchangesForListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExchangesForListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExchangesForListingResponse +// only implements ToObjectValue() and Type(). +func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExchangesForListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_listing": o.ExchangeListing, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5412,52 +3110,16 @@ func (a ListExchangesRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExchangesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExchangesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExchangesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExchangesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExchangesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExchangesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExchangesRequest +// only implements ToObjectValue() and Type(). +func (o ListExchangesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExchangesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5495,52 +3157,16 @@ func (a ListExchangesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExchangesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExchangesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExchangesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExchangesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExchangesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExchangesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExchangesResponse +// only implements ToObjectValue() and Type(). +func (o ListExchangesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExchangesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchanges": o.Exchanges, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5583,52 +3209,17 @@ func (a ListFilesRequest) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListFilesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListFilesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListFilesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListFilesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListFilesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListFilesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListFilesRequest +// only implements ToObjectValue() and Type(). +func (o ListFilesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListFilesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_parent": o.FileParent, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5669,52 +3260,16 @@ func (a ListFilesResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListFilesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListFilesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListFilesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListFilesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListFilesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListFilesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListFilesResponse +// only implements ToObjectValue() and Type(). +func (o ListFilesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListFilesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_infos": o.FileInfos, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5755,52 +3310,17 @@ func (a ListFulfillmentsRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListFulfillmentsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListFulfillmentsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListFulfillmentsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListFulfillmentsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListFulfillmentsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListFulfillmentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListFulfillmentsRequest +// only implements ToObjectValue() and Type(). +func (o ListFulfillmentsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListFulfillmentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5839,52 +3359,16 @@ func (a ListFulfillmentsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListFulfillmentsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListFulfillmentsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListFulfillmentsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListFulfillmentsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListFulfillmentsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListFulfillmentsResponse +// only implements ToObjectValue() and Type(). +func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListFulfillmentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "fulfillments": o.Fulfillments, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5925,52 +3409,17 @@ func (a ListInstallationsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListInstallationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListInstallationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListInstallationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListInstallationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListInstallationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListInstallationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListInstallationsRequest +// only implements ToObjectValue() and Type(). +func (o ListInstallationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListInstallationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6009,52 +3458,16 @@ func (a ListInstallationsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListInstallationsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListInstallationsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListInstallationsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListInstallationsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListInstallationsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListInstallationsResponse +// only implements ToObjectValue() and Type(). +func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListInstallationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "installations": o.Installations, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6095,52 +3508,17 @@ func (a ListListingsForExchangeRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListListingsForExchangeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListListingsForExchangeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListListingsForExchangeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListListingsForExchangeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListListingsForExchangeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListListingsForExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListListingsForExchangeRequest +// only implements ToObjectValue() and Type(). +func (o ListListingsForExchangeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListListingsForExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_id": o.ExchangeId, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6175,56 +3553,20 @@ func (newState *ListListingsForExchangeResponse) SyncEffectiveFieldsDuringRead(e // SDK values. func (a ListListingsForExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "exchange_listings": reflect.TypeOf(ExchangeListing{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListListingsForExchangeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListListingsForExchangeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListListingsForExchangeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListListingsForExchangeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListListingsForExchangeResponse) String() string { - return fmt.Sprintf("%#v", o) + "exchange_listings": reflect.TypeOf(ExchangeListing{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListListingsForExchangeResponse +// only implements ToObjectValue() and Type(). +func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListListingsForExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange_listings": o.ExchangeListings, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6283,52 +3625,23 @@ func (a ListListingsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListListingsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListListingsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListListingsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListListingsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListListingsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListListingsRequest +// only implements ToObjectValue() and Type(). +func (o ListListingsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "assets": o.Assets, + "categories": o.Categories, + "is_free": o.IsFree, + "is_private_exchange": o.IsPrivateExchange, + "is_staff_pick": o.IsStaffPick, + "page_size": o.PageSize, + "page_token": o.PageToken, + "provider_ids": o.ProviderIds, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -6381,52 +3694,16 @@ func (a ListListingsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListListingsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListListingsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListListingsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListListingsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListListingsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListListingsResponse +// only implements ToObjectValue() and Type(). +func (o ListListingsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listings": o.Listings, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6467,52 +3744,17 @@ func (a ListProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListProviderAnalyticsDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListProviderAnalyticsDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListProviderAnalyticsDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListProviderAnalyticsDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListProviderAnalyticsDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListProviderAnalyticsDashboardResponse +// only implements ToObjectValue() and Type(). +func (o ListProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListProviderAnalyticsDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "id": o.Id, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -6552,52 +3794,17 @@ func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListProvidersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListProvidersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListProvidersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListProvidersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListProvidersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListProvidersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListProvidersRequest +// only implements ToObjectValue() and Type(). +func (o ListProvidersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListProvidersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_featured": o.IsFeatured, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -6636,52 +3843,16 @@ func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListProvidersResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListProvidersResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListProvidersResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListProvidersResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListProvidersResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListProvidersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListProvidersResponse +// only implements ToObjectValue() and Type(). +func (o ListProvidersResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListProvidersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "providers": o.Providers, + }) } // Type implements basetypes.ObjectValuable. @@ -6724,52 +3895,17 @@ func (a Listing) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Listing{} - -// Equal implements basetypes.ObjectValuable. -func (o Listing) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Listing) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Listing) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Listing) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Listing) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Listing +// only implements ToObjectValue() and Type(). +func (o Listing) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Listing) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "detail": o.Detail, + "id": o.Id, + "summary": o.Summary, + }) } // Type implements basetypes.ObjectValuable. @@ -6862,52 +3998,33 @@ func (a ListingDetail) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListingDetail{} - -// Equal implements basetypes.ObjectValuable. -func (o ListingDetail) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListingDetail) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListingDetail) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListingDetail) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListingDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListingDetail +// only implements ToObjectValue() and Type(). +func (o ListingDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListingDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "assets": o.Assets, + "collection_date_end": o.CollectionDateEnd, + "collection_date_start": o.CollectionDateStart, + "collection_granularity": o.CollectionGranularity, + "cost": o.Cost, + "data_source": o.DataSource, + "description": o.Description, + "documentation_link": o.DocumentationLink, + "embedded_notebook_file_infos": o.EmbeddedNotebookFileInfos, + "file_ids": o.FileIds, + "geographical_coverage": o.GeographicalCoverage, + "license": o.License, + "pricing_model": o.PricingModel, + "privacy_policy_link": o.PrivacyPolicyLink, + "size": o.Size, + "support_link": o.SupportLink, + "tags": o.Tags, + "terms_of_service": o.TermsOfService, + "update_frequency": o.UpdateFrequency, + }) } // Type implements basetypes.ObjectValuable. @@ -6981,52 +4098,19 @@ func (a ListingFulfillment) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListingFulfillment{} - -// Equal implements basetypes.ObjectValuable. -func (o ListingFulfillment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListingFulfillment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListingFulfillment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListingFulfillment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListingFulfillment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListingFulfillment +// only implements ToObjectValue() and Type(). +func (o ListingFulfillment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListingFulfillment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "fulfillment_type": o.FulfillmentType, + "listing_id": o.ListingId, + "recipient_type": o.RecipientType, + "repo_info": o.RepoInfo, + "share_info": o.ShareInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -7067,52 +4151,15 @@ func (a ListingSetting) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListingSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o ListingSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListingSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListingSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListingSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListingSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListingSetting +// only implements ToObjectValue() and Type(). +func (o ListingSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListingSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "visibility": o.Visibility, + }) } // Type implements basetypes.ObjectValuable. @@ -7190,52 +4237,33 @@ func (a ListingSummary) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListingSummary{} - -// Equal implements basetypes.ObjectValuable. -func (o ListingSummary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListingSummary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListingSummary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListingSummary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListingSummary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListingSummary +// only implements ToObjectValue() and Type(). +func (o ListingSummary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListingSummary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "categories": o.Categories, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "created_by_id": o.CreatedById, + "exchange_ids": o.ExchangeIds, + "git_repo": o.GitRepo, + "listingType": o.ListingType, + "name": o.Name, + "provider_id": o.ProviderId, + "provider_region": o.ProviderRegion, + "published_at": o.PublishedAt, + "published_by": o.PublishedBy, + "setting": o.Setting, + "share": o.Share, + "status": o.Status, + "subtitle": o.Subtitle, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + "updated_by_id": o.UpdatedById, + }) } // Type implements basetypes.ObjectValuable. @@ -7304,52 +4332,16 @@ func (a ListingTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListingTag{} - -// Equal implements basetypes.ObjectValuable. -func (o ListingTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListingTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListingTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListingTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListingTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListingTag +// only implements ToObjectValue() and Type(). +func (o ListingTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListingTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "tag_name": o.TagName, + "tag_values": o.TagValues, + }) } // Type implements basetypes.ObjectValuable. @@ -7420,52 +4412,30 @@ func (a PersonalizationRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PersonalizationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PersonalizationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PersonalizationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PersonalizationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PersonalizationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PersonalizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PersonalizationRequest +// only implements ToObjectValue() and Type(). +func (o PersonalizationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PersonalizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "consumer_region": o.ConsumerRegion, + "contact_info": o.ContactInfo, + "created_at": o.CreatedAt, + "id": o.Id, + "intended_use": o.IntendedUse, + "is_from_lighthouse": o.IsFromLighthouse, + "listing_id": o.ListingId, + "listing_name": o.ListingName, + "metastore_id": o.MetastoreId, + "provider_id": o.ProviderId, + "recipient_type": o.RecipientType, + "share": o.Share, + "status": o.Status, + "status_message": o.StatusMessage, + "updated_at": o.UpdatedAt, + }) } // Type implements basetypes.ObjectValuable. @@ -7519,52 +4489,15 @@ func (a ProviderAnalyticsDashboard) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ProviderAnalyticsDashboard{} - -// Equal implements basetypes.ObjectValuable. -func (o ProviderAnalyticsDashboard) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ProviderAnalyticsDashboard) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ProviderAnalyticsDashboard) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ProviderAnalyticsDashboard) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ProviderAnalyticsDashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ProviderAnalyticsDashboard +// only implements ToObjectValue() and Type(). +func (o ProviderAnalyticsDashboard) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ProviderAnalyticsDashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -7623,52 +4556,28 @@ func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ProviderInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ProviderInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ProviderInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ProviderInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ProviderInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ProviderInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ProviderInfo +// only implements ToObjectValue() and Type(). +func (o ProviderInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ProviderInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "business_contact_email": o.BusinessContactEmail, + "company_website_link": o.CompanyWebsiteLink, + "dark_mode_icon_file_id": o.DarkModeIconFileId, + "dark_mode_icon_file_path": o.DarkModeIconFilePath, + "description": o.Description, + "icon_file_id": o.IconFileId, + "icon_file_path": o.IconFilePath, + "id": o.Id, + "is_featured": o.IsFeatured, + "name": o.Name, + "privacy_policy_link": o.PrivacyPolicyLink, + "published_by": o.PublishedBy, + "support_contact_email": o.SupportContactEmail, + "term_of_service_link": o.TermOfServiceLink, + }) } // Type implements basetypes.ObjectValuable. @@ -7716,52 +4625,16 @@ func (a RegionInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegionInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RegionInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegionInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegionInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegionInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegionInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegionInfo +// only implements ToObjectValue() and Type(). +func (o RegionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegionInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cloud": o.Cloud, + "region": o.Region, + }) } // Type implements basetypes.ObjectValuable. @@ -7796,52 +4669,15 @@ func (a RemoveExchangeForListingRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RemoveExchangeForListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RemoveExchangeForListingRequest +// only implements ToObjectValue() and Type(). +func (o RemoveExchangeForListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -7873,52 +4709,13 @@ func (a RemoveExchangeForListingResponse) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RemoveExchangeForListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RemoveExchangeForListingResponse +// only implements ToObjectValue() and Type(). +func (o RemoveExchangeForListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RemoveExchangeForListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7950,52 +4747,15 @@ func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoInfo +// only implements ToObjectValue() and Type(). +func (o RepoInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "git_repo_url": o.GitRepoUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -8033,52 +4793,16 @@ func (a RepoInstallation) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoInstallation{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoInstallation) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoInstallation) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoInstallation) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoInstallation) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoInstallation) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoInstallation +// only implements ToObjectValue() and Type(). +func (o RepoInstallation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoInstallation) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "repo_name": o.RepoName, + "repo_path": o.RepoPath, + }) } // Type implements basetypes.ObjectValuable. @@ -8132,52 +4856,22 @@ func (a SearchListingsRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchListingsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchListingsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchListingsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchListingsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchListingsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchListingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchListingsRequest +// only implements ToObjectValue() and Type(). +func (o SearchListingsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchListingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "assets": o.Assets, + "categories": o.Categories, + "is_free": o.IsFree, + "is_private_exchange": o.IsPrivateExchange, + "page_size": o.PageSize, + "page_token": o.PageToken, + "provider_ids": o.ProviderIds, + "query": o.Query, + }) } // Type implements basetypes.ObjectValuable. @@ -8227,52 +4921,16 @@ func (a SearchListingsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchListingsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchListingsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchListingsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchListingsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchListingsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchListingsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchListingsResponse +// only implements ToObjectValue() and Type(). +func (o SearchListingsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchListingsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listings": o.Listings, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -8310,52 +4968,16 @@ func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ShareInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ShareInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ShareInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ShareInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ShareInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ShareInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ShareInfo +// only implements ToObjectValue() and Type(). +func (o ShareInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ShareInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -8393,52 +5015,16 @@ func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SharedDataObject{} - -// Equal implements basetypes.ObjectValuable. -func (o SharedDataObject) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SharedDataObject) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SharedDataObject) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SharedDataObject) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SharedDataObject) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SharedDataObject +// only implements ToObjectValue() and Type(). +func (o SharedDataObject) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SharedDataObject) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data_object_type": o.DataObjectType, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -8480,52 +5066,18 @@ func (a TokenDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenDetail{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenDetail) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenDetail) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenDetail) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenDetail) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenDetail +// only implements ToObjectValue() and Type(). +func (o TokenDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bearerToken": o.BearerToken, + "endpoint": o.Endpoint, + "expirationTime": o.ExpirationTime, + "shareCredentialsVersion": o.ShareCredentialsVersion, + }) } // Type implements basetypes.ObjectValuable. @@ -8575,52 +5127,21 @@ func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenInfo +// only implements ToObjectValue() and Type(). +func (o TokenInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activation_url": o.ActivationUrl, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "expiration_time": o.ExpirationTime, + "id": o.Id, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -8663,52 +5184,16 @@ func (a UpdateExchangeFilterRequest) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExchangeFilterRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExchangeFilterRequest +// only implements ToObjectValue() and Type(). +func (o UpdateExchangeFilterRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -8746,52 +5231,15 @@ func (a UpdateExchangeFilterResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExchangeFilterResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExchangeFilterResponse +// only implements ToObjectValue() and Type(). +func (o UpdateExchangeFilterResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExchangeFilterResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + }) } // Type implements basetypes.ObjectValuable. @@ -8830,52 +5278,16 @@ func (a UpdateExchangeRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExchangeRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExchangeRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExchangeRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExchangeRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExchangeRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExchangeRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExchangeRequest +// only implements ToObjectValue() and Type(). +func (o UpdateExchangeRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExchangeRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange": o.Exchange, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -8913,52 +5325,15 @@ func (a UpdateExchangeResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExchangeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExchangeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExchangeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExchangeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExchangeResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExchangeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExchangeResponse +// only implements ToObjectValue() and Type(). +func (o UpdateExchangeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExchangeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exchange": o.Exchange, + }) } // Type implements basetypes.ObjectValuable. @@ -9001,52 +5376,18 @@ func (a UpdateInstallationRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateInstallationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateInstallationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateInstallationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateInstallationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateInstallationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateInstallationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateInstallationRequest +// only implements ToObjectValue() and Type(). +func (o UpdateInstallationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateInstallationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "installation": o.Installation, + "installation_id": o.InstallationId, + "listing_id": o.ListingId, + "rotate_token": o.RotateToken, + }) } // Type implements basetypes.ObjectValuable. @@ -9086,52 +5427,15 @@ func (a UpdateInstallationResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateInstallationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateInstallationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateInstallationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateInstallationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateInstallationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateInstallationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateInstallationResponse +// only implements ToObjectValue() and Type(). +func (o UpdateInstallationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateInstallationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "installation": o.Installation, + }) } // Type implements basetypes.ObjectValuable. @@ -9170,52 +5474,16 @@ func (a UpdateListingRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateListingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateListingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateListingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateListingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateListingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateListingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateListingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateListingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateListingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "listing": o.Listing, + }) } // Type implements basetypes.ObjectValuable. @@ -9253,52 +5521,15 @@ func (a UpdateListingResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateListingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateListingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateListingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateListingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateListingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateListingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateListingResponse +// only implements ToObjectValue() and Type(). +func (o UpdateListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateListingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing": o.Listing, + }) } // Type implements basetypes.ObjectValuable. @@ -9343,52 +5574,19 @@ func (a UpdatePersonalizationRequestRequest) GetComplexFieldTypes(ctx context.Co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePersonalizationRequestRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePersonalizationRequestRequest +// only implements ToObjectValue() and Type(). +func (o UpdatePersonalizationRequestRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "listing_id": o.ListingId, + "reason": o.Reason, + "request_id": o.RequestId, + "share": o.Share, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -9429,52 +5627,15 @@ func (a UpdatePersonalizationRequestResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePersonalizationRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePersonalizationRequestResponse +// only implements ToObjectValue() and Type(). +func (o UpdatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePersonalizationRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "request": o.Request, + }) } // Type implements basetypes.ObjectValuable. @@ -9514,52 +5675,16 @@ func (a UpdateProviderAnalyticsDashboardRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateProviderAnalyticsDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateProviderAnalyticsDashboardRequest +// only implements ToObjectValue() and Type(). +func (o UpdateProviderAnalyticsDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -9598,52 +5723,17 @@ func (a UpdateProviderAnalyticsDashboardResponse) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateProviderAnalyticsDashboardResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateProviderAnalyticsDashboardResponse +// only implements ToObjectValue() and Type(). +func (o UpdateProviderAnalyticsDashboardResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateProviderAnalyticsDashboardResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "id": o.Id, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -9682,52 +5772,16 @@ func (a UpdateProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateProviderRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateProviderRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateProviderRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateProviderRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateProviderRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateProviderRequest +// only implements ToObjectValue() and Type(). +func (o UpdateProviderRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "provider": o.Provider, + }) } // Type implements basetypes.ObjectValuable. @@ -9765,52 +5819,15 @@ func (a UpdateProviderResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateProviderResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateProviderResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateProviderResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateProviderResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateProviderResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateProviderResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateProviderResponse +// only implements ToObjectValue() and Type(). +func (o UpdateProviderResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateProviderResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "provider": o.Provider, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 976dfbe65d..65207e13ac 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -12,15 +12,11 @@ package ml_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) // Activity recorded for the action. @@ -96,52 +92,23 @@ func (a Activity) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Activity{} - -// Equal implements basetypes.ObjectValuable. -func (o Activity) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Activity) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Activity) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Activity) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Activity) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Activity +// only implements ToObjectValue() and Type(). +func (o Activity) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Activity) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activity_type": o.ActivityType, + "comment": o.Comment, + "creation_timestamp": o.CreationTimestamp, + "from_stage": o.FromStage, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "system_comment": o.SystemComment, + "to_stage": o.ToStage, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -200,52 +167,19 @@ func (a ApproveTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ApproveTransitionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ApproveTransitionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ApproveTransitionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ApproveTransitionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ApproveTransitionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ApproveTransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ApproveTransitionRequest +// only implements ToObjectValue() and Type(). +func (o ApproveTransitionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ApproveTransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "archive_existing_versions": o.ArchiveExistingVersions, + "comment": o.Comment, + "name": o.Name, + "stage": o.Stage, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -285,52 +219,15 @@ func (a ApproveTransitionRequestResponse) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ApproveTransitionRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ApproveTransitionRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ApproveTransitionRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ApproveTransitionRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ApproveTransitionRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ApproveTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ApproveTransitionRequestResponse +// only implements ToObjectValue() and Type(). +func (o ApproveTransitionRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ApproveTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activity": o.Activity, + }) } // Type implements basetypes.ObjectValuable. @@ -379,52 +276,20 @@ func (a CommentObject) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CommentObject{} - -// Equal implements basetypes.ObjectValuable. -func (o CommentObject) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CommentObject) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CommentObject) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CommentObject) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CommentObject) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CommentObject +// only implements ToObjectValue() and Type(). +func (o CommentObject) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CommentObject) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "available_actions": o.AvailableActions, + "comment": o.Comment, + "creation_timestamp": o.CreationTimestamp, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -469,52 +334,17 @@ func (a CreateComment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateComment{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateComment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateComment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateComment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateComment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateComment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateComment +// only implements ToObjectValue() and Type(). +func (o CreateComment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateComment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -552,52 +382,15 @@ func (a CreateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCommentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCommentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCommentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCommentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCommentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCommentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCommentResponse +// only implements ToObjectValue() and Type(). +func (o CreateCommentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCommentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + }) } // Type implements basetypes.ObjectValuable. @@ -644,52 +437,17 @@ func (a CreateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExperiment{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExperiment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExperiment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExperiment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExperiment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExperiment +// only implements ToObjectValue() and Type(). +func (o CreateExperiment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_location": o.ArtifactLocation, + "name": o.Name, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -727,52 +485,15 @@ func (a CreateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateExperimentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateExperimentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateExperimentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateExperimentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateExperimentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateExperimentResponse +// only implements ToObjectValue() and Type(). +func (o CreateExperimentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -812,52 +533,17 @@ func (a CreateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateModelRequest +// only implements ToObjectValue() and Type(). +func (o CreateModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "name": o.Name, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -896,52 +582,15 @@ func (a CreateModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateModelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateModelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateModelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateModelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateModelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateModelResponse +// only implements ToObjectValue() and Type(). +func (o CreateModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "registered_model": o.RegisteredModel, + }) } // Type implements basetypes.ObjectValuable. @@ -991,52 +640,20 @@ func (a CreateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o CreateModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "name": o.Name, + "run_id": o.RunId, + "run_link": o.RunLink, + "source": o.Source, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -1079,52 +696,15 @@ func (a CreateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateModelVersionResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateModelVersionResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateModelVersionResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateModelVersionResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateModelVersionResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateModelVersionResponse +// only implements ToObjectValue() and Type(). +func (o CreateModelVersionResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_version": o.ModelVersion, + }) } // Type implements basetypes.ObjectValuable. @@ -1213,52 +793,20 @@ func (a CreateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRegistryWebhook{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRegistryWebhook) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRegistryWebhook) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRegistryWebhook) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRegistryWebhook) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRegistryWebhook +// only implements ToObjectValue() and Type(). +func (o CreateRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "events": o.Events, + "http_url_spec": o.HttpUrlSpec, + "job_spec": o.JobSpec, + "model_name": o.ModelName, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -1313,52 +861,18 @@ func (a CreateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRun{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRun +// only implements ToObjectValue() and Type(). +func (o CreateRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + "start_time": o.StartTime, + "tags": o.Tags, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -1399,52 +913,15 @@ func (a CreateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRunResponse +// only implements ToObjectValue() and Type(). +func (o CreateRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run": o.Run, + }) } // Type implements basetypes.ObjectValuable. @@ -1494,52 +971,18 @@ func (a CreateTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateTransitionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateTransitionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateTransitionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateTransitionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateTransitionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateTransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateTransitionRequest +// only implements ToObjectValue() and Type(). +func (o CreateTransitionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateTransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "stage": o.Stage, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -1578,52 +1021,15 @@ func (a CreateTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateTransitionRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateTransitionRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateTransitionRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateTransitionRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateTransitionRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateTransitionRequestResponse +// only implements ToObjectValue() and Type(). +func (o CreateTransitionRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "request": o.Request, + }) } // Type implements basetypes.ObjectValuable. @@ -1660,52 +1066,15 @@ func (a CreateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateWebhookResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateWebhookResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateWebhookResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateWebhookResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateWebhookResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateWebhookResponse +// only implements ToObjectValue() and Type(). +func (o CreateWebhookResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "webhook": o.Webhook, + }) } // Type implements basetypes.ObjectValuable. @@ -1759,52 +1128,20 @@ func (a Dataset) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Dataset{} - -// Equal implements basetypes.ObjectValuable. -func (o Dataset) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Dataset) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Dataset) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Dataset) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Dataset) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Dataset +// only implements ToObjectValue() and Type(). +func (o Dataset) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Dataset) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "digest": o.Digest, + "name": o.Name, + "profile": o.Profile, + "schema": o.Schema, + "source": o.Source, + "source_type": o.SourceType, + }) } // Type implements basetypes.ObjectValuable. @@ -1849,52 +1186,16 @@ func (a DatasetInput) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DatasetInput{} - -// Equal implements basetypes.ObjectValuable. -func (o DatasetInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DatasetInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DatasetInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DatasetInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DatasetInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DatasetInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DatasetInput +// only implements ToObjectValue() and Type(). +func (o DatasetInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "dataset": o.Dataset, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -1933,52 +1234,15 @@ func (a DeleteCommentRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCommentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCommentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCommentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCommentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCommentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCommentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCommentRequest +// only implements ToObjectValue() and Type(). +func (o DeleteCommentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCommentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -2010,52 +1274,13 @@ func (a DeleteCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCommentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCommentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCommentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCommentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCommentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCommentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCommentResponse +// only implements ToObjectValue() and Type(). +func (o DeleteCommentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCommentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2087,52 +1312,15 @@ func (a DeleteExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExperiment{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExperiment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExperiment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExperiment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExperiment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExperiment +// only implements ToObjectValue() and Type(). +func (o DeleteExperiment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -2164,52 +1352,13 @@ func (a DeleteExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteExperimentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteExperimentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteExperimentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteExperimentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteExperimentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteExperimentResponse +// only implements ToObjectValue() and Type(). +func (o DeleteExperimentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2242,52 +1391,15 @@ func (a DeleteModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelRequest +// only implements ToObjectValue() and Type(). +func (o DeleteModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2319,52 +1431,13 @@ func (a DeleteModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelResponse +// only implements ToObjectValue() and Type(). +func (o DeleteModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2400,52 +1473,16 @@ func (a DeleteModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelTagRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelTagRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelTagRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelTagRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelTagRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelTagRequest +// only implements ToObjectValue() and Type(). +func (o DeleteModelTagRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2478,52 +1515,13 @@ func (a DeleteModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelTagResponse +// only implements ToObjectValue() and Type(). +func (o DeleteModelTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2558,52 +1556,16 @@ func (a DeleteModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o DeleteModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -2636,52 +1598,13 @@ func (a DeleteModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelVersionResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelVersionResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelVersionResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelVersionResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelVersionResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelVersionResponse +// only implements ToObjectValue() and Type(). +func (o DeleteModelVersionResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2719,52 +1642,17 @@ func (a DeleteModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelVersionTagRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelVersionTagRequest +// only implements ToObjectValue() and Type(). +func (o DeleteModelVersionTagRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -2798,52 +1686,13 @@ func (a DeleteModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteModelVersionTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteModelVersionTagResponse +// only implements ToObjectValue() and Type(). +func (o DeleteModelVersionTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteModelVersionTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2875,52 +1724,15 @@ func (a DeleteRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRun{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRun +// only implements ToObjectValue() and Type(). +func (o DeleteRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -2952,52 +1764,13 @@ func (a DeleteRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRunResponse +// only implements ToObjectValue() and Type(). +func (o DeleteRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3036,52 +1809,17 @@ func (a DeleteRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRuns{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRuns) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRuns) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRuns) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRuns) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRuns +// only implements ToObjectValue() and Type(). +func (o DeleteRuns) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + "max_runs": o.MaxRuns, + "max_timestamp_millis": o.MaxTimestampMillis, + }) } // Type implements basetypes.ObjectValuable. @@ -3117,52 +1855,15 @@ func (a DeleteRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRunsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRunsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRunsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRunsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRunsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRunsResponse +// only implements ToObjectValue() and Type(). +func (o DeleteRunsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "runs_deleted": o.RunsDeleted, + }) } // Type implements basetypes.ObjectValuable. @@ -3198,52 +1899,16 @@ func (a DeleteTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTag{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTag +// only implements ToObjectValue() and Type(). +func (o DeleteTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -3276,52 +1941,13 @@ func (a DeleteTagResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTagResponse +// only implements ToObjectValue() and Type(). +func (o DeleteTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3372,52 +1998,19 @@ func (a DeleteTransitionRequestRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTransitionRequestRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTransitionRequestRequest +// only implements ToObjectValue() and Type(). +func (o DeleteTransitionRequestRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "creator": o.Creator, + "name": o.Name, + "stage": o.Stage, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -3453,52 +2046,13 @@ func (a DeleteTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTransitionRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTransitionRequestResponse +// only implements ToObjectValue() and Type(). +func (o DeleteTransitionRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3531,52 +2085,15 @@ func (a DeleteWebhookRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWebhookRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWebhookRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWebhookRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWebhookRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWebhookRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWebhookRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWebhookRequest +// only implements ToObjectValue() and Type(). +func (o DeleteWebhookRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWebhookRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3608,52 +2125,13 @@ func (a DeleteWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWebhookResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWebhookResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWebhookResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWebhookResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWebhookResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWebhookResponse +// only implements ToObjectValue() and Type(). +func (o DeleteWebhookResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3700,52 +2178,21 @@ func (a Experiment) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Experiment{} - -// Equal implements basetypes.ObjectValuable. -func (o Experiment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Experiment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Experiment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Experiment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Experiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Experiment +// only implements ToObjectValue() and Type(). +func (o Experiment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Experiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_location": o.ArtifactLocation, + "creation_time": o.CreationTime, + "experiment_id": o.ExperimentId, + "last_update_time": o.LastUpdateTime, + "lifecycle_stage": o.LifecycleStage, + "name": o.Name, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -3793,52 +2240,18 @@ func (a ExperimentAccessControlRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o ExperimentAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -3885,52 +2298,19 @@ func (a ExperimentAccessControlResponse) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -3975,52 +2355,17 @@ func (a ExperimentPermission) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentPermission +// only implements ToObjectValue() and Type(). +func (o ExperimentPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4058,57 +2403,22 @@ func (newState *ExperimentPermissions) SyncEffectiveFieldsDuringRead(existingSta // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF // SDK values. func (a ExperimentPermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "access_control_list": reflect.TypeOf(ExperimentAccessControlResponse{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentPermissions) String() string { - return fmt.Sprintf("%#v", o) + return map[string]reflect.Type{ + "access_control_list": reflect.TypeOf(ExperimentAccessControlResponse{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentPermissions +// only implements ToObjectValue() and Type(). +func (o ExperimentPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -4147,52 +2457,16 @@ func (a ExperimentPermissionsDescription) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o ExperimentPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4230,52 +2504,16 @@ func (a ExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -4314,52 +2552,16 @@ func (a ExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExperimentTag{} - -// Equal implements basetypes.ObjectValuable. -func (o ExperimentTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExperimentTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExperimentTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExperimentTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExperimentTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExperimentTag +// only implements ToObjectValue() and Type(). +func (o ExperimentTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExperimentTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -4398,52 +2600,17 @@ func (a FileInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FileInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o FileInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FileInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FileInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FileInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FileInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FileInfo +// only implements ToObjectValue() and Type(). +func (o FileInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FileInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file_size": o.FileSize, + "is_dir": o.IsDir, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -4480,52 +2647,15 @@ func (a GetByNameRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetByNameRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetByNameRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetByNameRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetByNameRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetByNameRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetByNameRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetByNameRequest +// only implements ToObjectValue() and Type(). +func (o GetByNameRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetByNameRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_name": o.ExperimentName, + }) } // Type implements basetypes.ObjectValuable. @@ -4560,52 +2690,15 @@ func (a GetExperimentPermissionLevelsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExperimentPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExperimentPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetExperimentPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -4641,52 +2734,15 @@ func (a GetExperimentPermissionLevelsResponse) GetComplexFieldTypes(ctx context. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExperimentPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExperimentPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExperimentPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -4723,52 +2779,15 @@ func (a GetExperimentPermissionsRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExperimentPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExperimentPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExperimentPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExperimentPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExperimentPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExperimentPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExperimentPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetExperimentPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExperimentPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -4803,52 +2822,15 @@ func (a GetExperimentRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExperimentRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExperimentRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExperimentRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExperimentRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExperimentRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExperimentRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExperimentRequest +// only implements ToObjectValue() and Type(). +func (o GetExperimentRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExperimentRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -4884,52 +2866,15 @@ func (a GetExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetExperimentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetExperimentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetExperimentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetExperimentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetExperimentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetExperimentResponse +// only implements ToObjectValue() and Type(). +func (o GetExperimentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment": o.Experiment, + }) } // Type implements basetypes.ObjectValuable. @@ -4977,52 +2922,19 @@ func (a GetHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetHistoryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetHistoryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetHistoryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetHistoryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetHistoryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetHistoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetHistoryRequest +// only implements ToObjectValue() and Type(). +func (o GetHistoryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetHistoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "metric_key": o.MetricKey, + "page_token": o.PageToken, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + }) } // Type implements basetypes.ObjectValuable. @@ -5064,52 +2976,16 @@ func (a GetLatestVersionsRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetLatestVersionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetLatestVersionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetLatestVersionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetLatestVersionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetLatestVersionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetLatestVersionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetLatestVersionsRequest +// only implements ToObjectValue() and Type(). +func (o GetLatestVersionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetLatestVersionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "stages": o.Stages, + }) } // Type implements basetypes.ObjectValuable. @@ -5150,52 +3026,15 @@ func (a GetLatestVersionsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetLatestVersionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetLatestVersionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetLatestVersionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetLatestVersionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetLatestVersionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetLatestVersionsResponse +// only implements ToObjectValue() and Type(). +func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetLatestVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_versions": o.ModelVersions, + }) } // Type implements basetypes.ObjectValuable. @@ -5236,52 +3075,16 @@ func (a GetMetricHistoryResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetMetricHistoryResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetMetricHistoryResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetMetricHistoryResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetMetricHistoryResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetMetricHistoryResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetMetricHistoryResponse +// only implements ToObjectValue() and Type(). +func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetMetricHistoryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metrics": o.Metrics, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5319,52 +3122,15 @@ func (a GetModelRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelRequest +// only implements ToObjectValue() and Type(). +func (o GetModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5399,52 +3165,15 @@ func (a GetModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelResponse +// only implements ToObjectValue() and Type(). +func (o GetModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "registered_model_databricks": o.RegisteredModelDatabricks, + }) } // Type implements basetypes.ObjectValuable. @@ -5483,52 +3212,16 @@ func (a GetModelVersionDownloadUriRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelVersionDownloadUriRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelVersionDownloadUriRequest +// only implements ToObjectValue() and Type(). +func (o GetModelVersionDownloadUriRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -5563,52 +3256,15 @@ func (a GetModelVersionDownloadUriResponse) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelVersionDownloadUriResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelVersionDownloadUriResponse +// only implements ToObjectValue() and Type(). +func (o GetModelVersionDownloadUriResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelVersionDownloadUriResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_uri": o.ArtifactUri, + }) } // Type implements basetypes.ObjectValuable. @@ -5637,60 +3293,24 @@ func (newState *GetModelVersionRequest) SyncEffectiveFieldsDuringRead(existingSt // GetComplexFieldTypes returns a map of the types of elements in complex fields in GetModelVersionRequest. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a GetModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o GetModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -5726,52 +3346,15 @@ func (a GetModelVersionResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetModelVersionResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetModelVersionResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetModelVersionResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetModelVersionResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetModelVersionResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetModelVersionResponse +// only implements ToObjectValue() and Type(). +func (o GetModelVersionResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_version": o.ModelVersion, + }) } // Type implements basetypes.ObjectValuable. @@ -5808,52 +3391,15 @@ func (a GetRegisteredModelPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRegisteredModelPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRegisteredModelPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetRegisteredModelPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "registered_model_id": o.RegisteredModelId, + }) } // Type implements basetypes.ObjectValuable. @@ -5889,52 +3435,15 @@ func (a GetRegisteredModelPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRegisteredModelPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRegisteredModelPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -5971,52 +3480,15 @@ func (a GetRegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRegisteredModelPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRegisteredModelPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetRegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRegisteredModelPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "registered_model_id": o.RegisteredModelId, + }) } // Type implements basetypes.ObjectValuable. @@ -6054,52 +3526,16 @@ func (a GetRunRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRunRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRunRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRunRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRunRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRunRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRunRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRunRequest +// only implements ToObjectValue() and Type(). +func (o GetRunRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRunRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + "run_uuid": o.RunUuid, + }) } // Type implements basetypes.ObjectValuable. @@ -6137,52 +3573,15 @@ func (a GetRunResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRunResponse +// only implements ToObjectValue() and Type(). +func (o GetRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run": o.Run, + }) } // Type implements basetypes.ObjectValuable. @@ -6235,52 +3634,18 @@ func (a HttpUrlSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = HttpUrlSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o HttpUrlSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o HttpUrlSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o HttpUrlSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o HttpUrlSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o HttpUrlSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, HttpUrlSpec +// only implements ToObjectValue() and Type(). +func (o HttpUrlSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o HttpUrlSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "authorization": o.Authorization, + "enable_ssl_verification": o.EnableSslVerification, + "secret": o.Secret, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -6325,52 +3690,16 @@ func (a HttpUrlSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = HttpUrlSpecWithoutSecret{} - -// Equal implements basetypes.ObjectValuable. -func (o HttpUrlSpecWithoutSecret) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o HttpUrlSpecWithoutSecret) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o HttpUrlSpecWithoutSecret) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o HttpUrlSpecWithoutSecret) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o HttpUrlSpecWithoutSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, HttpUrlSpecWithoutSecret +// only implements ToObjectValue() and Type(). +func (o HttpUrlSpecWithoutSecret) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o HttpUrlSpecWithoutSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enable_ssl_verification": o.EnableSslVerification, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -6407,52 +3736,16 @@ func (a InputTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = InputTag{} - -// Equal implements basetypes.ObjectValuable. -func (o InputTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o InputTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o InputTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o InputTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o InputTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, InputTag +// only implements ToObjectValue() and Type(). +func (o InputTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o InputTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -6493,52 +3786,17 @@ func (a JobSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o JobSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobSpec +// only implements ToObjectValue() and Type(). +func (o JobSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_token": o.AccessToken, + "job_id": o.JobId, + "workspace_url": o.WorkspaceUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -6578,52 +3836,16 @@ func (a JobSpecWithoutSecret) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = JobSpecWithoutSecret{} - -// Equal implements basetypes.ObjectValuable. -func (o JobSpecWithoutSecret) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o JobSpecWithoutSecret) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o JobSpecWithoutSecret) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o JobSpecWithoutSecret) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o JobSpecWithoutSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobSpecWithoutSecret +// only implements ToObjectValue() and Type(). +func (o JobSpecWithoutSecret) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o JobSpecWithoutSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "job_id": o.JobId, + "workspace_url": o.WorkspaceUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -6672,52 +3894,18 @@ func (a ListArtifactsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListArtifactsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListArtifactsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListArtifactsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListArtifactsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListArtifactsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListArtifactsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListArtifactsRequest +// only implements ToObjectValue() and Type(). +func (o ListArtifactsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListArtifactsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_token": o.PageToken, + "path": o.Path, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + }) } // Type implements basetypes.ObjectValuable. @@ -6760,52 +3948,17 @@ func (a ListArtifactsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListArtifactsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListArtifactsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListArtifactsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListArtifactsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListArtifactsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListArtifactsResponse +// only implements ToObjectValue() and Type(). +func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListArtifactsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "files": o.Files, + "next_page_token": o.NextPageToken, + "root_uri": o.RootUri, + }) } // Type implements basetypes.ObjectValuable. @@ -6853,52 +4006,17 @@ func (a ListExperimentsRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExperimentsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExperimentsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExperimentsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExperimentsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExperimentsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExperimentsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExperimentsRequest +// only implements ToObjectValue() and Type(). +func (o ListExperimentsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExperimentsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + "view_type": o.ViewType, + }) } // Type implements basetypes.ObjectValuable. @@ -6940,52 +4058,16 @@ func (a ListExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListExperimentsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListExperimentsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListExperimentsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListExperimentsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListExperimentsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListExperimentsResponse +// only implements ToObjectValue() and Type(). +func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListExperimentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiments": o.Experiments, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7025,52 +4107,16 @@ func (a ListModelsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListModelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListModelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListModelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListModelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListModelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListModelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListModelsRequest +// only implements ToObjectValue() and Type(). +func (o ListModelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListModelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7109,52 +4155,16 @@ func (a ListModelsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListModelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListModelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListModelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListModelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListModelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListModelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListModelsResponse +// only implements ToObjectValue() and Type(). +func (o ListModelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListModelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "registered_models": o.RegisteredModels, + }) } // Type implements basetypes.ObjectValuable. @@ -7195,52 +4205,16 @@ func (a ListRegistryWebhooks) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRegistryWebhooks{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRegistryWebhooks) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRegistryWebhooks) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRegistryWebhooks) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRegistryWebhooks) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRegistryWebhooks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRegistryWebhooks +// only implements ToObjectValue() and Type(). +func (o ListRegistryWebhooks) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRegistryWebhooks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "webhooks": o.Webhooks, + }) } // Type implements basetypes.ObjectValuable. @@ -7275,57 +4249,21 @@ func (newState *ListTransitionRequestsRequest) SyncEffectiveFieldsDuringRead(exi // retrieve the type information of the elements in complex fields at runtime. The values of the map // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a ListTransitionRequestsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTransitionRequestsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTransitionRequestsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTransitionRequestsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTransitionRequestsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTransitionRequestsRequest) String() string { - return fmt.Sprintf("%#v", o) +// SDK values. +func (a ListTransitionRequestsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTransitionRequestsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTransitionRequestsRequest +// only implements ToObjectValue() and Type(). +func (o ListTransitionRequestsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTransitionRequestsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -7362,52 +4300,15 @@ func (a ListTransitionRequestsResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTransitionRequestsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTransitionRequestsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTransitionRequestsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTransitionRequestsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTransitionRequestsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTransitionRequestsResponse +// only implements ToObjectValue() and Type(). +func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTransitionRequestsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "requests": o.Requests, + }) } // Type implements basetypes.ObjectValuable. @@ -7453,52 +4354,17 @@ func (a ListWebhooksRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListWebhooksRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListWebhooksRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListWebhooksRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListWebhooksRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListWebhooksRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListWebhooksRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListWebhooksRequest +// only implements ToObjectValue() and Type(). +func (o ListWebhooksRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListWebhooksRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "events": o.Events, + "model_name": o.ModelName, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7549,52 +4415,18 @@ func (a LogBatch) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogBatch{} - -// Equal implements basetypes.ObjectValuable. -func (o LogBatch) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogBatch) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogBatch) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogBatch) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogBatch) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogBatch +// only implements ToObjectValue() and Type(). +func (o LogBatch) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogBatch) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metrics": o.Metrics, + "params": o.Params, + "run_id": o.RunId, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -7635,52 +4467,13 @@ func (a LogBatchResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogBatchResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o LogBatchResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogBatchResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogBatchResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogBatchResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogBatchResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogBatchResponse +// only implements ToObjectValue() and Type(). +func (o LogBatchResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogBatchResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7716,52 +4509,16 @@ func (a LogInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogInputs{} - -// Equal implements basetypes.ObjectValuable. -func (o LogInputs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogInputs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogInputs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogInputs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogInputs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogInputs +// only implements ToObjectValue() and Type(). +func (o LogInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogInputs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "datasets": o.Datasets, + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -7796,52 +4553,13 @@ func (a LogInputsResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogInputsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o LogInputsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogInputsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogInputsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogInputsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogInputsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogInputsResponse +// only implements ToObjectValue() and Type(). +func (o LogInputsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogInputsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -7884,52 +4602,20 @@ func (a LogMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogMetric{} - -// Equal implements basetypes.ObjectValuable. -func (o LogMetric) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogMetric) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogMetric) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogMetric) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogMetric) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogMetric +// only implements ToObjectValue() and Type(). +func (o LogMetric) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogMetric) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + "step": o.Step, + "timestamp": o.Timestamp, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -7966,52 +4652,13 @@ func (a LogMetricResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogMetricResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o LogMetricResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogMetricResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogMetricResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogMetricResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogMetricResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogMetricResponse +// only implements ToObjectValue() and Type(). +func (o LogMetricResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogMetricResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -8045,52 +4692,16 @@ func (a LogModel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogModel{} - -// Equal implements basetypes.ObjectValuable. -func (o LogModel) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogModel) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogModel) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogModel) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogModel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogModel +// only implements ToObjectValue() and Type(). +func (o LogModel) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogModel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_json": o.ModelJson, + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -8123,52 +4734,13 @@ func (a LogModelResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogModelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o LogModelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogModelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogModelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogModelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogModelResponse +// only implements ToObjectValue() and Type(). +func (o LogModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -8207,52 +4779,18 @@ func (a LogParam) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogParam{} - -// Equal implements basetypes.ObjectValuable. -func (o LogParam) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogParam) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogParam) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogParam) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogParam) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogParam +// only implements ToObjectValue() and Type(). +func (o LogParam) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogParam) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -8287,52 +4825,13 @@ func (a LogParamResponse) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogParamResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o LogParamResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogParamResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogParamResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogParamResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogParamResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogParamResponse +// only implements ToObjectValue() and Type(). +func (o LogParamResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogParamResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -8370,52 +4869,18 @@ func (a Metric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Metric{} - -// Equal implements basetypes.ObjectValuable. -func (o Metric) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Metric) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Metric) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Metric) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Metric) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Metric +// only implements ToObjectValue() and Type(). +func (o Metric) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Metric) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "step": o.Step, + "timestamp": o.Timestamp, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -8469,52 +4934,21 @@ func (a Model) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Model{} - -// Equal implements basetypes.ObjectValuable. -func (o Model) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Model) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Model) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Model) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Model) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Model +// only implements ToObjectValue() and Type(). +func (o Model) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Model) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "description": o.Description, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "latest_versions": o.LatestVersions, + "name": o.Name, + "tags": o.Tags, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -8578,52 +5012,23 @@ func (a ModelDatabricks) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelDatabricks{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelDatabricks) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelDatabricks) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelDatabricks) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelDatabricks) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelDatabricks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelDatabricks +// only implements ToObjectValue() and Type(). +func (o ModelDatabricks) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelDatabricks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "description": o.Description, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "latest_versions": o.LatestVersions, + "name": o.Name, + "permission_level": o.PermissionLevel, + "tags": o.Tags, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -8671,52 +5076,16 @@ func (a ModelTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelTag{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelTag +// only implements ToObjectValue() and Type(). +func (o ModelTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -8780,52 +5149,27 @@ func (a ModelVersion) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelVersion{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelVersion) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelVersion) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelVersion) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelVersion) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelVersion) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelVersion +// only implements ToObjectValue() and Type(). +func (o ModelVersion) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelVersion) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "current_stage": o.CurrentStage, + "description": o.Description, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "name": o.Name, + "run_id": o.RunId, + "run_link": o.RunLink, + "source": o.Source, + "status": o.Status, + "status_message": o.StatusMessage, + "tags": o.Tags, + "user_id": o.UserId, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -8921,52 +5265,28 @@ func (a ModelVersionDatabricks) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelVersionDatabricks{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelVersionDatabricks) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelVersionDatabricks) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelVersionDatabricks) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelVersionDatabricks) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelVersionDatabricks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelVersionDatabricks +// only implements ToObjectValue() and Type(). +func (o ModelVersionDatabricks) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelVersionDatabricks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "current_stage": o.CurrentStage, + "description": o.Description, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "name": o.Name, + "permission_level": o.PermissionLevel, + "run_id": o.RunId, + "run_link": o.RunLink, + "source": o.Source, + "status": o.Status, + "status_message": o.StatusMessage, + "tags": o.Tags, + "user_id": o.UserId, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -9009,60 +5329,24 @@ func (newState *ModelVersionTag) SyncEffectiveFieldsDuringRead(existingState Mod // GetComplexFieldTypes returns a map of the types of elements in complex fields in ModelVersionTag. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a ModelVersionTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelVersionTag{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelVersionTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelVersionTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelVersionTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelVersionTag) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a ModelVersionTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelVersionTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelVersionTag +// only implements ToObjectValue() and Type(). +func (o ModelVersionTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelVersionTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -9099,52 +5383,16 @@ func (a Param) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Param{} - -// Equal implements basetypes.ObjectValuable. -func (o Param) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Param) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Param) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Param) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Param) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Param +// only implements ToObjectValue() and Type(). +func (o Param) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Param) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -9185,52 +5433,18 @@ func (a RegisteredModelAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o RegisteredModelAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -9277,52 +5491,19 @@ func (a RegisteredModelAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -9367,52 +5548,17 @@ func (a RegisteredModelPermission) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelPermission +// only implements ToObjectValue() and Type(). +func (o RegisteredModelPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -9455,52 +5601,17 @@ func (a RegisteredModelPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelPermissions +// only implements ToObjectValue() and Type(). +func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -9539,52 +5650,16 @@ func (a RegisteredModelPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o RegisteredModelPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -9622,52 +5697,16 @@ func (a RegisteredModelPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegisteredModelPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegisteredModelPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegisteredModelPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "registered_model_id": o.RegisteredModelId, + }) } // Type implements basetypes.ObjectValuable. @@ -9763,52 +5802,23 @@ func (a RegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RegistryWebhook{} - -// Equal implements basetypes.ObjectValuable. -func (o RegistryWebhook) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RegistryWebhook) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RegistryWebhook) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RegistryWebhook) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RegistryWebhook +// only implements ToObjectValue() and Type(). +func (o RegistryWebhook) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "description": o.Description, + "events": o.Events, + "http_url_spec": o.HttpUrlSpec, + "id": o.Id, + "job_spec": o.JobSpec, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "model_name": o.ModelName, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -9870,52 +5880,18 @@ func (a RejectTransitionRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RejectTransitionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RejectTransitionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RejectTransitionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RejectTransitionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RejectTransitionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RejectTransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RejectTransitionRequest +// only implements ToObjectValue() and Type(). +func (o RejectTransitionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RejectTransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "stage": o.Stage, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -9954,52 +5930,15 @@ func (a RejectTransitionRequestResponse) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RejectTransitionRequestResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RejectTransitionRequestResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RejectTransitionRequestResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RejectTransitionRequestResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RejectTransitionRequestResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RejectTransitionRequestResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RejectTransitionRequestResponse +// only implements ToObjectValue() and Type(). +func (o RejectTransitionRequestResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RejectTransitionRequestResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activity": o.Activity, + }) } // Type implements basetypes.ObjectValuable. @@ -10037,52 +5976,16 @@ func (a RenameModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RenameModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RenameModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RenameModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RenameModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RenameModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RenameModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RenameModelRequest +// only implements ToObjectValue() and Type(). +func (o RenameModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RenameModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "new_name": o.NewName, + }) } // Type implements basetypes.ObjectValuable. @@ -10118,52 +6021,15 @@ func (a RenameModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RenameModelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RenameModelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RenameModelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RenameModelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RenameModelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RenameModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RenameModelResponse +// only implements ToObjectValue() and Type(). +func (o RenameModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RenameModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "registered_model": o.RegisteredModel, + }) } // Type implements basetypes.ObjectValuable. @@ -10199,52 +6065,15 @@ func (a RestoreExperiment) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreExperiment{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreExperiment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreExperiment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreExperiment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreExperiment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreExperiment +// only implements ToObjectValue() and Type(). +func (o RestoreExperiment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + }) } // Type implements basetypes.ObjectValuable. @@ -10276,52 +6105,13 @@ func (a RestoreExperimentResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreExperimentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreExperimentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreExperimentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreExperimentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreExperimentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreExperimentResponse +// only implements ToObjectValue() and Type(). +func (o RestoreExperimentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -10353,52 +6143,15 @@ func (a RestoreRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreRun{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreRun +// only implements ToObjectValue() and Type(). +func (o RestoreRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_id": o.RunId, + }) } // Type implements basetypes.ObjectValuable. @@ -10430,52 +6183,13 @@ func (a RestoreRunResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreRunResponse +// only implements ToObjectValue() and Type(). +func (o RestoreRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -10514,52 +6228,17 @@ func (a RestoreRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreRuns{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreRuns) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreRuns) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreRuns) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreRuns) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreRuns +// only implements ToObjectValue() and Type(). +func (o RestoreRuns) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + "max_runs": o.MaxRuns, + "min_timestamp_millis": o.MinTimestampMillis, + }) } // Type implements basetypes.ObjectValuable. @@ -10595,52 +6274,15 @@ func (a RestoreRunsResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreRunsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreRunsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreRunsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreRunsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreRunsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreRunsResponse +// only implements ToObjectValue() and Type(). +func (o RestoreRunsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "runs_restored": o.RunsRestored, + }) } // Type implements basetypes.ObjectValuable. @@ -10677,57 +6319,22 @@ func (newState *Run) SyncEffectiveFieldsDuringRead(existingState Run) { func (a Run) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "data": reflect.TypeOf(RunData{}), - "info": reflect.TypeOf(RunInfo{}), - "inputs": reflect.TypeOf(RunInputs{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Run{} - -// Equal implements basetypes.ObjectValuable. -func (o Run) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Run) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Run) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Run) String() string { - return fmt.Sprintf("%#v", o) + "info": reflect.TypeOf(RunInfo{}), + "inputs": reflect.TypeOf(RunInputs{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o Run) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Run +// only implements ToObjectValue() and Type(). +func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Run) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data": o.Data, + "info": o.Info, + "inputs": o.Inputs, + }) } // Type implements basetypes.ObjectValuable. @@ -10777,52 +6384,17 @@ func (a RunData) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunData{} - -// Equal implements basetypes.ObjectValuable. -func (o RunData) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunData) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunData) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunData) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunData) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunData +// only implements ToObjectValue() and Type(). +func (o RunData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunData) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "metrics": o.Metrics, + "params": o.Params, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -10886,52 +6458,23 @@ func (a RunInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RunInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunInfo +// only implements ToObjectValue() and Type(). +func (o RunInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "artifact_uri": o.ArtifactUri, + "end_time": o.EndTime, + "experiment_id": o.ExperimentId, + "lifecycle_stage": o.LifecycleStage, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + "start_time": o.StartTime, + "status": o.Status, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -10975,52 +6518,15 @@ func (a RunInputs) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunInputs{} - -// Equal implements basetypes.ObjectValuable. -func (o RunInputs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunInputs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunInputs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunInputs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunInputs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunInputs +// only implements ToObjectValue() and Type(). +func (o RunInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunInputs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dataset_inputs": o.DatasetInputs, + }) } // Type implements basetypes.ObjectValuable. @@ -11058,52 +6564,16 @@ func (a RunTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RunTag{} - -// Equal implements basetypes.ObjectValuable. -func (o RunTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RunTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RunTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RunTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RunTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RunTag +// only implements ToObjectValue() and Type(). +func (o RunTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RunTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -11153,52 +6623,19 @@ func (a SearchExperiments) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchExperiments{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchExperiments) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchExperiments) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchExperiments) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchExperiments) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchExperiments) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchExperiments +// only implements ToObjectValue() and Type(). +func (o SearchExperiments) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchExperiments) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + "max_results": o.MaxResults, + "order_by": o.OrderBy, + "page_token": o.PageToken, + "view_type": o.ViewType, + }) } // Type implements basetypes.ObjectValuable. @@ -11243,52 +6680,16 @@ func (a SearchExperimentsResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchExperimentsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchExperimentsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchExperimentsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchExperimentsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchExperimentsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchExperimentsResponse +// only implements ToObjectValue() and Type(). +func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchExperimentsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiments": o.Experiments, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11338,52 +6739,18 @@ func (a SearchModelVersionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchModelVersionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchModelVersionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchModelVersionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchModelVersionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchModelVersionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchModelVersionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchModelVersionsRequest +// only implements ToObjectValue() and Type(). +func (o SearchModelVersionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchModelVersionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + "max_results": o.MaxResults, + "order_by": o.OrderBy, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11427,52 +6794,16 @@ func (a SearchModelVersionsResponse) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchModelVersionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchModelVersionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchModelVersionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchModelVersionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchModelVersionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchModelVersionsResponse +// only implements ToObjectValue() and Type(). +func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchModelVersionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_versions": o.ModelVersions, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11522,52 +6853,18 @@ func (a SearchModelsRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchModelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchModelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchModelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchModelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchModelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchModelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchModelsRequest +// only implements ToObjectValue() and Type(). +func (o SearchModelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchModelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + "max_results": o.MaxResults, + "order_by": o.OrderBy, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -11610,52 +6907,16 @@ func (a SearchModelsResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchModelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchModelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchModelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchModelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchModelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchModelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchModelsResponse +// only implements ToObjectValue() and Type(). +func (o SearchModelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchModelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "registered_models": o.RegisteredModels, + }) } // Type implements basetypes.ObjectValuable. @@ -11722,52 +6983,20 @@ func (a SearchRuns) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchRuns{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchRuns) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchRuns) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchRuns) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchRuns) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchRuns) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchRuns +// only implements ToObjectValue() and Type(). +func (o SearchRuns) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchRuns) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_ids": o.ExperimentIds, + "filter": o.Filter, + "max_results": o.MaxResults, + "order_by": o.OrderBy, + "page_token": o.PageToken, + "run_view_type": o.RunViewType, + }) } // Type implements basetypes.ObjectValuable. @@ -11814,52 +7043,16 @@ func (a SearchRunsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SearchRunsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SearchRunsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SearchRunsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SearchRunsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SearchRunsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SearchRunsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SearchRunsResponse +// only implements ToObjectValue() and Type(). +func (o SearchRunsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SearchRunsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "runs": o.Runs, + }) } // Type implements basetypes.ObjectValuable. @@ -11903,52 +7096,17 @@ func (a SetExperimentTag) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetExperimentTag{} - -// Equal implements basetypes.ObjectValuable. -func (o SetExperimentTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetExperimentTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetExperimentTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetExperimentTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetExperimentTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetExperimentTag +// only implements ToObjectValue() and Type(). +func (o SetExperimentTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetExperimentTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -11982,52 +7140,13 @@ func (a SetExperimentTagResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetExperimentTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetExperimentTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetExperimentTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetExperimentTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetExperimentTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetExperimentTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetExperimentTagResponse +// only implements ToObjectValue() and Type(). +func (o SetExperimentTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetExperimentTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -12068,52 +7187,17 @@ func (a SetModelTagRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetModelTagRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SetModelTagRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetModelTagRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetModelTagRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetModelTagRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetModelTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetModelTagRequest +// only implements ToObjectValue() and Type(). +func (o SetModelTagRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetModelTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "name": o.Name, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -12147,52 +7231,13 @@ func (a SetModelTagResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetModelTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetModelTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetModelTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetModelTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetModelTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetModelTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetModelTagResponse +// only implements ToObjectValue() and Type(). +func (o SetModelTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetModelTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -12235,52 +7280,18 @@ func (a SetModelVersionTagRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetModelVersionTagRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SetModelVersionTagRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetModelVersionTagRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetModelVersionTagRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetModelVersionTagRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetModelVersionTagRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetModelVersionTagRequest +// only implements ToObjectValue() and Type(). +func (o SetModelVersionTagRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetModelVersionTagRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "name": o.Name, + "value": o.Value, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -12315,52 +7326,13 @@ func (a SetModelVersionTagResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetModelVersionTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetModelVersionTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetModelVersionTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetModelVersionTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetModelVersionTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetModelVersionTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetModelVersionTagResponse +// only implements ToObjectValue() and Type(). +func (o SetModelVersionTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetModelVersionTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -12394,60 +7366,26 @@ func (newState *SetTag) SyncEffectiveFieldsDuringRead(existingState SetTag) { // GetComplexFieldTypes returns a map of the types of elements in complex fields in SetTag. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a SetTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetTag{} - -// Equal implements basetypes.ObjectValuable. -func (o SetTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetTag) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a SetTag) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetTag +// only implements ToObjectValue() and Type(). +func (o SetTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -12482,52 +7420,13 @@ func (a SetTagResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetTagResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetTagResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetTagResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetTagResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetTagResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetTagResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetTagResponse +// only implements ToObjectValue() and Type(). +func (o SetTagResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetTagResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -12562,52 +7461,16 @@ func (a TestRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TestRegistryWebhook{} - -// Equal implements basetypes.ObjectValuable. -func (o TestRegistryWebhook) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TestRegistryWebhook) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TestRegistryWebhook) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TestRegistryWebhook) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TestRegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TestRegistryWebhook +// only implements ToObjectValue() and Type(). +func (o TestRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TestRegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "body": o.Body, + "status_code": o.StatusCode, + }) } // Type implements basetypes.ObjectValuable. @@ -12646,52 +7509,16 @@ func (a TestRegistryWebhookRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TestRegistryWebhookRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TestRegistryWebhookRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TestRegistryWebhookRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TestRegistryWebhookRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TestRegistryWebhookRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TestRegistryWebhookRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TestRegistryWebhookRequest +// only implements ToObjectValue() and Type(). +func (o TestRegistryWebhookRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TestRegistryWebhookRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "event": o.Event, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -12728,52 +7555,15 @@ func (a TestRegistryWebhookResponse) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TestRegistryWebhookResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o TestRegistryWebhookResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TestRegistryWebhookResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TestRegistryWebhookResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TestRegistryWebhookResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TestRegistryWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TestRegistryWebhookResponse +// only implements ToObjectValue() and Type(). +func (o TestRegistryWebhookResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TestRegistryWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "webhook": o.Webhook, + }) } // Type implements basetypes.ObjectValuable. @@ -12826,52 +7616,19 @@ func (a TransitionModelVersionStageDatabricks) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TransitionModelVersionStageDatabricks{} - -// Equal implements basetypes.ObjectValuable. -func (o TransitionModelVersionStageDatabricks) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TransitionModelVersionStageDatabricks) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TransitionModelVersionStageDatabricks) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TransitionModelVersionStageDatabricks) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TransitionModelVersionStageDatabricks) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TransitionModelVersionStageDatabricks +// only implements ToObjectValue() and Type(). +func (o TransitionModelVersionStageDatabricks) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TransitionModelVersionStageDatabricks) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "archive_existing_versions": o.ArchiveExistingVersions, + "comment": o.Comment, + "name": o.Name, + "stage": o.Stage, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -12929,52 +7686,19 @@ func (a TransitionRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TransitionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TransitionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TransitionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TransitionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TransitionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TransitionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TransitionRequest +// only implements ToObjectValue() and Type(). +func (o TransitionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TransitionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "available_actions": o.AvailableActions, + "comment": o.Comment, + "creation_timestamp": o.CreationTimestamp, + "to_stage": o.ToStage, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -13015,52 +7739,15 @@ func (a TransitionStageResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TransitionStageResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o TransitionStageResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TransitionStageResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TransitionStageResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TransitionStageResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TransitionStageResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TransitionStageResponse +// only implements ToObjectValue() and Type(). +func (o TransitionStageResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TransitionStageResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_version": o.ModelVersion, + }) } // Type implements basetypes.ObjectValuable. @@ -13098,52 +7785,16 @@ func (a UpdateComment) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateComment{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateComment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateComment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateComment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateComment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateComment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateComment +// only implements ToObjectValue() and Type(). +func (o UpdateComment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateComment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -13180,52 +7831,15 @@ func (a UpdateCommentResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCommentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCommentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCommentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCommentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCommentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCommentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCommentResponse +// only implements ToObjectValue() and Type(). +func (o UpdateCommentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCommentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + }) } // Type implements basetypes.ObjectValuable. @@ -13264,52 +7878,16 @@ func (a UpdateExperiment) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExperiment{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExperiment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExperiment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExperiment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExperiment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExperiment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExperiment +// only implements ToObjectValue() and Type(). +func (o UpdateExperiment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExperiment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "experiment_id": o.ExperimentId, + "new_name": o.NewName, + }) } // Type implements basetypes.ObjectValuable. @@ -13342,52 +7920,13 @@ func (a UpdateExperimentResponse) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateExperimentResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateExperimentResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateExperimentResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateExperimentResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateExperimentResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateExperimentResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateExperimentResponse +// only implements ToObjectValue() and Type(). +func (o UpdateExperimentResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateExperimentResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -13421,52 +7960,16 @@ func (a UpdateModelRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateModelRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateModelRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateModelRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateModelRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateModelRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateModelRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateModelRequest +// only implements ToObjectValue() and Type(). +func (o UpdateModelRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateModelRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -13499,52 +8002,13 @@ func (a UpdateModelResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateModelResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateModelResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateModelResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateModelResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateModelResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateModelResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateModelResponse +// only implements ToObjectValue() and Type(). +func (o UpdateModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateModelResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -13580,52 +8044,17 @@ func (a UpdateModelVersionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateModelVersionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateModelVersionRequest +// only implements ToObjectValue() and Type(). +func (o UpdateModelVersionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateModelVersionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "name": o.Name, + "version": o.Version, + }) } // Type implements basetypes.ObjectValuable. @@ -13659,52 +8088,13 @@ func (a UpdateModelVersionResponse) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateModelVersionResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateModelVersionResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateModelVersionResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateModelVersionResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateModelVersionResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateModelVersionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateModelVersionResponse +// only implements ToObjectValue() and Type(). +func (o UpdateModelVersionResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateModelVersionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -13789,52 +8179,20 @@ func (a UpdateRegistryWebhook) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRegistryWebhook{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRegistryWebhook) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRegistryWebhook) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRegistryWebhook) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRegistryWebhook) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRegistryWebhook) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRegistryWebhook +// only implements ToObjectValue() and Type(). +func (o UpdateRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRegistryWebhook) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "events": o.Events, + "http_url_spec": o.HttpUrlSpec, + "id": o.Id, + "job_spec": o.JobSpec, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -13886,52 +8244,18 @@ func (a UpdateRun) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRun{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRun) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRun) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRun) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRun) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRun) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRun +// only implements ToObjectValue() and Type(). +func (o UpdateRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRun) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end_time": o.EndTime, + "run_id": o.RunId, + "run_uuid": o.RunUuid, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -13970,52 +8294,15 @@ func (a UpdateRunResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRunResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRunResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRunResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRunResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRunResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRunResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRunResponse +// only implements ToObjectValue() and Type(). +func (o UpdateRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRunResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_info": o.RunInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -14049,52 +8336,13 @@ func (a UpdateWebhookResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateWebhookResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateWebhookResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateWebhookResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateWebhookResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateWebhookResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateWebhookResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateWebhookResponse +// only implements ToObjectValue() and Type(). +func (o UpdateWebhookResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateWebhookResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 71d3187bed..975ac569c4 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -12,15 +12,11 @@ package oauth2_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type CreateCustomAppIntegration struct { @@ -59,52 +55,19 @@ func (a CreateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCustomAppIntegration{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCustomAppIntegration +// only implements ToObjectValue() and Type(). +func (o CreateCustomAppIntegration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "confidential": o.Confidential, + "name": o.Name, + "redirect_urls": o.RedirectUrls, + "scopes": o.Scopes, + "token_access_policy": o.TokenAccessPolicy, + }) } // Type implements basetypes.ObjectValuable. @@ -153,52 +116,17 @@ func (a CreateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCustomAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCustomAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o CreateCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "client_id": o.ClientId, + "client_secret": o.ClientSecret, + "integration_id": o.IntegrationId, + }) } // Type implements basetypes.ObjectValuable. @@ -239,52 +167,16 @@ func (a CreatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePublishedAppIntegration{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePublishedAppIntegration +// only implements ToObjectValue() and Type(). +func (o CreatePublishedAppIntegration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_id": o.AppId, + "token_access_policy": o.TokenAccessPolicy, + }) } // Type implements basetypes.ObjectValuable. @@ -321,52 +213,15 @@ func (a CreatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePublishedAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePublishedAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o CreatePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + }) } // Type implements basetypes.ObjectValuable. @@ -401,52 +256,15 @@ func (a CreateServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateServicePrincipalSecretRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateServicePrincipalSecretRequest +// only implements ToObjectValue() and Type(). +func (o CreateServicePrincipalSecretRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "service_principal_id": o.ServicePrincipalId, + }) } // Type implements basetypes.ObjectValuable. @@ -490,52 +308,20 @@ func (a CreateServicePrincipalSecretResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateServicePrincipalSecretResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateServicePrincipalSecretResponse +// only implements ToObjectValue() and Type(). +func (o CreateServicePrincipalSecretResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateServicePrincipalSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "id": o.Id, + "secret": o.Secret, + "secret_hash": o.SecretHash, + "status": o.Status, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -576,52 +362,16 @@ func (a DataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DataPlaneInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o DataPlaneInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DataPlaneInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DataPlaneInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DataPlaneInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DataPlaneInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DataPlaneInfo +// only implements ToObjectValue() and Type(). +func (o DataPlaneInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DataPlaneInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "authorization_details": o.AuthorizationDetails, + "endpoint_url": o.EndpointUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -654,52 +404,13 @@ func (a DeleteCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCustomAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCustomAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o DeleteCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -731,52 +442,15 @@ func (a DeleteCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCustomAppIntegrationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCustomAppIntegrationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteCustomAppIntegrationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCustomAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + }) } // Type implements basetypes.ObjectValuable. @@ -808,52 +482,13 @@ func (a DeletePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePublishedAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePublishedAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o DeletePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -885,52 +520,15 @@ func (a DeletePublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePublishedAppIntegrationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePublishedAppIntegrationRequest +// only implements ToObjectValue() and Type(). +func (o DeletePublishedAppIntegrationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePublishedAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + }) } // Type implements basetypes.ObjectValuable. @@ -962,52 +560,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1042,52 +601,16 @@ func (a DeleteServicePrincipalSecretRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteServicePrincipalSecretRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalSecretRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalSecretRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalSecretRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalSecretRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalSecretRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteServicePrincipalSecretRequest +// only implements ToObjectValue() and Type(). +func (o DeleteServicePrincipalSecretRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteServicePrincipalSecretRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "secret_id": o.SecretId, + "service_principal_id": o.ServicePrincipalId, + }) } // Type implements basetypes.ObjectValuable. @@ -1145,52 +668,24 @@ func (a GetCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCustomAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCustomAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o GetCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "client_id": o.ClientId, + "confidential": o.Confidential, + "create_time": o.CreateTime, + "created_by": o.CreatedBy, + "creator_username": o.CreatorUsername, + "integration_id": o.IntegrationId, + "name": o.Name, + "redirect_urls": o.RedirectUrls, + "scopes": o.Scopes, + "token_access_policy": o.TokenAccessPolicy, + }) } // Type implements basetypes.ObjectValuable. @@ -1240,52 +735,15 @@ func (a GetCustomAppIntegrationRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCustomAppIntegrationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCustomAppIntegrationRequest +// only implements ToObjectValue() and Type(). +func (o GetCustomAppIntegrationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + }) } // Type implements basetypes.ObjectValuable. @@ -1323,52 +781,16 @@ func (a GetCustomAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCustomAppIntegrationsOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationsOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationsOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationsOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationsOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCustomAppIntegrationsOutput +// only implements ToObjectValue() and Type(). +func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCustomAppIntegrationsOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apps": o.Apps, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1417,52 +839,20 @@ func (a GetPublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPublishedAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPublishedAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o GetPublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_id": o.AppId, + "create_time": o.CreateTime, + "created_by": o.CreatedBy, + "integration_id": o.IntegrationId, + "name": o.Name, + "token_access_policy": o.TokenAccessPolicy, + }) } // Type implements basetypes.ObjectValuable. @@ -1503,52 +893,15 @@ func (a GetPublishedAppIntegrationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPublishedAppIntegrationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPublishedAppIntegrationRequest +// only implements ToObjectValue() and Type(). +func (o GetPublishedAppIntegrationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + }) } // Type implements basetypes.ObjectValuable. @@ -1586,52 +939,16 @@ func (a GetPublishedAppIntegrationsOutput) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPublishedAppIntegrationsOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationsOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationsOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationsOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationsOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPublishedAppIntegrationsOutput +// only implements ToObjectValue() and Type(). +func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPublishedAppIntegrationsOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apps": o.Apps, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1673,52 +990,16 @@ func (a GetPublishedAppsOutput) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPublishedAppsOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPublishedAppsOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPublishedAppsOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPublishedAppsOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPublishedAppsOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPublishedAppsOutput +// only implements ToObjectValue() and Type(). +func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPublishedAppsOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apps": o.Apps, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1759,52 +1040,17 @@ func (a ListCustomAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListCustomAppIntegrationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListCustomAppIntegrationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListCustomAppIntegrationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListCustomAppIntegrationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListCustomAppIntegrationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListCustomAppIntegrationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListCustomAppIntegrationsRequest +// only implements ToObjectValue() and Type(). +func (o ListCustomAppIntegrationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListCustomAppIntegrationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_creator_username": o.IncludeCreatorUsername, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1843,52 +1089,16 @@ func (a ListOAuthPublishedAppsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListOAuthPublishedAppsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListOAuthPublishedAppsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListOAuthPublishedAppsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListOAuthPublishedAppsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListOAuthPublishedAppsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListOAuthPublishedAppsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListOAuthPublishedAppsRequest +// only implements ToObjectValue() and Type(). +func (o ListOAuthPublishedAppsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListOAuthPublishedAppsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1925,52 +1135,16 @@ func (a ListPublishedAppIntegrationsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPublishedAppIntegrationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPublishedAppIntegrationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPublishedAppIntegrationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPublishedAppIntegrationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPublishedAppIntegrationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPublishedAppIntegrationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPublishedAppIntegrationsRequest +// only implements ToObjectValue() and Type(). +func (o ListPublishedAppIntegrationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPublishedAppIntegrationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2016,52 +1190,16 @@ func (a ListServicePrincipalSecretsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListServicePrincipalSecretsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListServicePrincipalSecretsRequest +// only implements ToObjectValue() and Type(). +func (o ListServicePrincipalSecretsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_token": o.PageToken, + "service_principal_id": o.ServicePrincipalId, + }) } // Type implements basetypes.ObjectValuable. @@ -2100,52 +1238,16 @@ func (a ListServicePrincipalSecretsResponse) GetComplexFieldTypes(ctx context.Co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListServicePrincipalSecretsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListServicePrincipalSecretsResponse +// only implements ToObjectValue() and Type(). +func (o ListServicePrincipalSecretsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListServicePrincipalSecretsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "secrets": o.Secrets, + }) } // Type implements basetypes.ObjectValuable. @@ -2199,52 +1301,21 @@ func (a PublishedAppOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PublishedAppOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o PublishedAppOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PublishedAppOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PublishedAppOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PublishedAppOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PublishedAppOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PublishedAppOutput +// only implements ToObjectValue() and Type(). +func (o PublishedAppOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PublishedAppOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "app_id": o.AppId, + "client_id": o.ClientId, + "description": o.Description, + "is_confidential_client": o.IsConfidentialClient, + "name": o.Name, + "redirect_urls": o.RedirectUrls, + "scopes": o.Scopes, + }) } // Type implements basetypes.ObjectValuable. @@ -2296,52 +1367,19 @@ func (a SecretInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SecretInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o SecretInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SecretInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SecretInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SecretInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SecretInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SecretInfo +// only implements ToObjectValue() and Type(). +func (o SecretInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SecretInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "id": o.Id, + "secret_hash": o.SecretHash, + "status": o.Status, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -2381,52 +1419,16 @@ func (a TokenAccessPolicy) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenAccessPolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenAccessPolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenAccessPolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenAccessPolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenAccessPolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenAccessPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenAccessPolicy +// only implements ToObjectValue() and Type(). +func (o TokenAccessPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenAccessPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_token_ttl_in_minutes": o.AccessTokenTtlInMinutes, + "refresh_token_ttl_in_minutes": o.RefreshTokenTtlInMinutes, + }) } // Type implements basetypes.ObjectValuable. @@ -2468,52 +1470,17 @@ func (a UpdateCustomAppIntegration) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCustomAppIntegration{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCustomAppIntegration +// only implements ToObjectValue() and Type(). +func (o UpdateCustomAppIntegration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + "redirect_urls": o.RedirectUrls, + "token_access_policy": o.TokenAccessPolicy, + }) } // Type implements basetypes.ObjectValuable. @@ -2551,52 +1518,13 @@ func (a UpdateCustomAppIntegrationOutput) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCustomAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCustomAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o UpdateCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCustomAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2631,52 +1559,16 @@ func (a UpdatePublishedAppIntegration) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePublishedAppIntegration{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePublishedAppIntegration +// only implements ToObjectValue() and Type(). +func (o UpdatePublishedAppIntegration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_id": o.IntegrationId, + "token_access_policy": o.TokenAccessPolicy, + }) } // Type implements basetypes.ObjectValuable. @@ -2711,52 +1603,13 @@ func (a UpdatePublishedAppIntegrationOutput) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePublishedAppIntegrationOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegrationOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegrationOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegrationOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegrationOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePublishedAppIntegrationOutput +// only implements ToObjectValue() and Type(). +func (o UpdatePublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePublishedAppIntegrationOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 4568058ccf..e3a8228837 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -12,17 +12,13 @@ package pipelines_tf import ( "context" - "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/compute" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type CreatePipeline struct { @@ -116,52 +112,39 @@ func (a CreatePipeline) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePipeline{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePipeline) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePipeline) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePipeline) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePipeline) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePipeline) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePipeline +// only implements ToObjectValue() and Type(). +func (o CreatePipeline) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePipeline) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_duplicate_names": o.AllowDuplicateNames, + "budget_policy_id": o.BudgetPolicyId, + "catalog": o.Catalog, + "channel": o.Channel, + "clusters": o.Clusters, + "configuration": o.Configuration, + "continuous": o.Continuous, + "deployment": o.Deployment, + "development": o.Development, + "dry_run": o.DryRun, + "edition": o.Edition, + "filters": o.Filters, + "gateway_definition": o.GatewayDefinition, + "id": o.Id, + "ingestion_definition": o.IngestionDefinition, + "libraries": o.Libraries, + "name": o.Name, + "notifications": o.Notifications, + "photon": o.Photon, + "restart_window": o.RestartWindow, + "schema": o.Schema, + "serverless": o.Serverless, + "storage": o.Storage, + "target": o.Target, + "trigger": o.Trigger, + }) } // Type implements basetypes.ObjectValuable. @@ -244,52 +227,16 @@ func (a CreatePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePipelineResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePipelineResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePipelineResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePipelineResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePipelineResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePipelineResponse +// only implements ToObjectValue() and Type(). +func (o CreatePipelineResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "effective_settings": o.EffectiveSettings, + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -327,52 +274,16 @@ func (a CronTrigger) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CronTrigger{} - -// Equal implements basetypes.ObjectValuable. -func (o CronTrigger) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CronTrigger) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CronTrigger) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CronTrigger) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CronTrigger) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CronTrigger +// only implements ToObjectValue() and Type(). +func (o CronTrigger) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CronTrigger) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "quartz_cron_schedule": o.QuartzCronSchedule, + "timezone_id": o.TimezoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -409,52 +320,16 @@ func (a DataPlaneId) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DataPlaneId{} - -// Equal implements basetypes.ObjectValuable. -func (o DataPlaneId) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DataPlaneId) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DataPlaneId) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DataPlaneId) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DataPlaneId) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DataPlaneId +// only implements ToObjectValue() and Type(). +func (o DataPlaneId) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DataPlaneId) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "instance": o.Instance, + "seq_no": o.SeqNo, + }) } // Type implements basetypes.ObjectValuable. @@ -489,52 +364,15 @@ func (a DeletePipelineRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePipelineRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePipelineRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePipelineRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePipelineRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePipelineRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePipelineRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePipelineRequest +// only implements ToObjectValue() and Type(). +func (o DeletePipelineRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePipelineRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -566,52 +404,13 @@ func (a DeletePipelineResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePipelineResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePipelineResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePipelineResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePipelineResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePipelineResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePipelineResponse +// only implements ToObjectValue() and Type(). +func (o DeletePipelineResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -716,52 +515,40 @@ func (a EditPipeline) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditPipeline{} - -// Equal implements basetypes.ObjectValuable. -func (o EditPipeline) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditPipeline) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditPipeline) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditPipeline) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditPipeline) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditPipeline +// only implements ToObjectValue() and Type(). +func (o EditPipeline) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditPipeline) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_duplicate_names": o.AllowDuplicateNames, + "budget_policy_id": o.BudgetPolicyId, + "catalog": o.Catalog, + "channel": o.Channel, + "clusters": o.Clusters, + "configuration": o.Configuration, + "continuous": o.Continuous, + "deployment": o.Deployment, + "development": o.Development, + "edition": o.Edition, + "expected_last_modified": o.ExpectedLastModified, + "filters": o.Filters, + "gateway_definition": o.GatewayDefinition, + "id": o.Id, + "ingestion_definition": o.IngestionDefinition, + "libraries": o.Libraries, + "name": o.Name, + "notifications": o.Notifications, + "photon": o.Photon, + "pipeline_id": o.PipelineId, + "restart_window": o.RestartWindow, + "schema": o.Schema, + "serverless": o.Serverless, + "storage": o.Storage, + "target": o.Target, + "trigger": o.Trigger, + }) } // Type implements basetypes.ObjectValuable. @@ -838,52 +625,13 @@ func (a EditPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditPipelineResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EditPipelineResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditPipelineResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditPipelineResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditPipelineResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditPipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditPipelineResponse +// only implements ToObjectValue() and Type(). +func (o EditPipelineResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditPipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -919,52 +667,16 @@ func (a ErrorDetail) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ErrorDetail{} - -// Equal implements basetypes.ObjectValuable. -func (o ErrorDetail) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ErrorDetail) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ErrorDetail) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ErrorDetail) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ErrorDetail) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ErrorDetail +// only implements ToObjectValue() and Type(). +func (o ErrorDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ErrorDetail) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exceptions": o.Exceptions, + "fatal": o.Fatal, + }) } // Type implements basetypes.ObjectValuable. @@ -1001,52 +713,15 @@ func (a FileLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FileLibrary{} - -// Equal implements basetypes.ObjectValuable. -func (o FileLibrary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FileLibrary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FileLibrary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FileLibrary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FileLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FileLibrary +// only implements ToObjectValue() and Type(). +func (o FileLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FileLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -1085,52 +760,16 @@ func (a Filters) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Filters{} - -// Equal implements basetypes.ObjectValuable. -func (o Filters) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Filters) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Filters) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Filters) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Filters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Filters +// only implements ToObjectValue() and Type(). +func (o Filters) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Filters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "exclude": o.Exclude, + "include": o.Include, + }) } // Type implements basetypes.ObjectValuable. @@ -1170,52 +809,15 @@ func (a GetPipelinePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPipelinePermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPipelinePermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetPipelinePermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -1251,52 +853,15 @@ func (a GetPipelinePermissionLevelsResponse) GetComplexFieldTypes(ctx context.Co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPipelinePermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPipelinePermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPipelinePermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -1333,52 +898,15 @@ func (a GetPipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPipelinePermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPipelinePermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPipelinePermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPipelinePermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPipelinePermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPipelinePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPipelinePermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetPipelinePermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPipelinePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -1412,52 +940,15 @@ func (a GetPipelineRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPipelineRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPipelineRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPipelineRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPipelineRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPipelineRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPipelineRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPipelineRequest +// only implements ToObjectValue() and Type(). +func (o GetPipelineRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPipelineRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -1518,52 +1009,26 @@ func (a GetPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPipelineResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPipelineResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPipelineResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPipelineResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPipelineResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPipelineResponse +// only implements ToObjectValue() and Type(). +func (o GetPipelineResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cause": o.Cause, + "cluster_id": o.ClusterId, + "creator_user_name": o.CreatorUserName, + "effective_budget_policy_id": o.EffectiveBudgetPolicyId, + "health": o.Health, + "last_modified": o.LastModified, + "latest_updates": o.LatestUpdates, + "name": o.Name, + "pipeline_id": o.PipelineId, + "run_as_user_name": o.RunAsUserName, + "spec": o.Spec, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -1615,52 +1080,16 @@ func (a GetUpdateRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetUpdateRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetUpdateRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetUpdateRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetUpdateRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetUpdateRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetUpdateRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetUpdateRequest +// only implements ToObjectValue() and Type(). +func (o GetUpdateRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetUpdateRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pipeline_id": o.PipelineId, + "update_id": o.UpdateId, + }) } // Type implements basetypes.ObjectValuable. @@ -1697,52 +1126,15 @@ func (a GetUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetUpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetUpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetUpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetUpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetUpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetUpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetUpdateResponse +// only implements ToObjectValue() and Type(). +func (o GetUpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetUpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "update": o.Update, + }) } // Type implements basetypes.ObjectValuable. @@ -1786,52 +1178,17 @@ func (a IngestionConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = IngestionConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o IngestionConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o IngestionConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o IngestionConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o IngestionConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o IngestionConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, IngestionConfig +// only implements ToObjectValue() and Type(). +func (o IngestionConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o IngestionConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "report": o.Report, + "schema": o.Schema, + "table": o.Table, + }) } // Type implements basetypes.ObjectValuable. @@ -1889,52 +1246,19 @@ func (a IngestionGatewayPipelineDefinition) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = IngestionGatewayPipelineDefinition{} - -// Equal implements basetypes.ObjectValuable. -func (o IngestionGatewayPipelineDefinition) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o IngestionGatewayPipelineDefinition) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o IngestionGatewayPipelineDefinition) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o IngestionGatewayPipelineDefinition) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o IngestionGatewayPipelineDefinition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, IngestionGatewayPipelineDefinition +// only implements ToObjectValue() and Type(). +func (o IngestionGatewayPipelineDefinition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o IngestionGatewayPipelineDefinition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "connection_id": o.ConnectionId, + "connection_name": o.ConnectionName, + "gateway_storage_catalog": o.GatewayStorageCatalog, + "gateway_storage_name": o.GatewayStorageName, + "gateway_storage_schema": o.GatewayStorageSchema, + }) } // Type implements basetypes.ObjectValuable. @@ -1987,52 +1311,18 @@ func (a IngestionPipelineDefinition) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = IngestionPipelineDefinition{} - -// Equal implements basetypes.ObjectValuable. -func (o IngestionPipelineDefinition) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o IngestionPipelineDefinition) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o IngestionPipelineDefinition) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o IngestionPipelineDefinition) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o IngestionPipelineDefinition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, IngestionPipelineDefinition +// only implements ToObjectValue() and Type(). +func (o IngestionPipelineDefinition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o IngestionPipelineDefinition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "connection_name": o.ConnectionName, + "ingestion_gateway_id": o.IngestionGatewayId, + "objects": o.Objects, + "table_configuration": o.TableConfiguration, + }) } // Type implements basetypes.ObjectValuable. @@ -2097,52 +1387,19 @@ func (a ListPipelineEventsRequest) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPipelineEventsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPipelineEventsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPipelineEventsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPipelineEventsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPipelineEventsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPipelineEventsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPipelineEventsRequest +// only implements ToObjectValue() and Type(). +func (o ListPipelineEventsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPipelineEventsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + "max_results": o.MaxResults, + "order_by": o.OrderBy, + "page_token": o.PageToken, + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -2188,52 +1445,17 @@ func (a ListPipelineEventsResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPipelineEventsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPipelineEventsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPipelineEventsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPipelineEventsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPipelineEventsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPipelineEventsResponse +// only implements ToObjectValue() and Type(). +func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPipelineEventsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "events": o.Events, + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2293,52 +1515,18 @@ func (a ListPipelinesRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPipelinesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPipelinesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPipelinesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPipelinesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPipelinesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPipelinesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPipelinesRequest +// only implements ToObjectValue() and Type(). +func (o ListPipelinesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPipelinesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter": o.Filter, + "max_results": o.MaxResults, + "order_by": o.OrderBy, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2381,52 +1569,16 @@ func (a ListPipelinesResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPipelinesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPipelinesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPipelinesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPipelinesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPipelinesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPipelinesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPipelinesResponse +// only implements ToObjectValue() and Type(). +func (o ListPipelinesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPipelinesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "statuses": o.Statuses, + }) } // Type implements basetypes.ObjectValuable. @@ -2470,52 +1622,18 @@ func (a ListUpdatesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListUpdatesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListUpdatesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListUpdatesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListUpdatesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListUpdatesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListUpdatesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListUpdatesRequest +// only implements ToObjectValue() and Type(). +func (o ListUpdatesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListUpdatesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "page_token": o.PageToken, + "pipeline_id": o.PipelineId, + "until_update_id": o.UntilUpdateId, + }) } // Type implements basetypes.ObjectValuable. @@ -2560,52 +1678,17 @@ func (a ListUpdatesResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListUpdatesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListUpdatesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListUpdatesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListUpdatesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListUpdatesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListUpdatesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListUpdatesResponse +// only implements ToObjectValue() and Type(). +func (o ListUpdatesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListUpdatesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "prev_page_token": o.PrevPageToken, + "updates": o.Updates, + }) } // Type implements basetypes.ObjectValuable. @@ -2641,52 +1724,13 @@ func (a ManualTrigger) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ManualTrigger{} - -// Equal implements basetypes.ObjectValuable. -func (o ManualTrigger) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ManualTrigger) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ManualTrigger) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ManualTrigger) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ManualTrigger) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ManualTrigger +// only implements ToObjectValue() and Type(). +func (o ManualTrigger) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ManualTrigger) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2718,52 +1762,15 @@ func (a NotebookLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NotebookLibrary{} - -// Equal implements basetypes.ObjectValuable. -func (o NotebookLibrary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NotebookLibrary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NotebookLibrary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NotebookLibrary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NotebookLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NotebookLibrary +// only implements ToObjectValue() and Type(). +func (o NotebookLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NotebookLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -2808,52 +1815,16 @@ func (a Notifications) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Notifications{} - -// Equal implements basetypes.ObjectValuable. -func (o Notifications) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Notifications) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Notifications) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Notifications) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Notifications) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Notifications +// only implements ToObjectValue() and Type(). +func (o Notifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Notifications) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alerts": o.Alerts, + "email_recipients": o.EmailRecipients, + }) } // Type implements basetypes.ObjectValuable. @@ -2925,52 +1896,31 @@ func (a Origin) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Origin{} - -// Equal implements basetypes.ObjectValuable. -func (o Origin) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Origin) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Origin) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Origin) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Origin) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Origin +// only implements ToObjectValue() and Type(). +func (o Origin) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Origin) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "batch_id": o.BatchId, + "cloud": o.Cloud, + "cluster_id": o.ClusterId, + "dataset_name": o.DatasetName, + "flow_id": o.FlowId, + "flow_name": o.FlowName, + "host": o.Host, + "maintenance_id": o.MaintenanceId, + "materialization_name": o.MaterializationName, + "org_id": o.OrgId, + "pipeline_id": o.PipelineId, + "pipeline_name": o.PipelineName, + "region": o.Region, + "request_id": o.RequestId, + "table_id": o.TableId, + "uc_resource_id": o.UcResourceId, + "update_id": o.UpdateId, + }) } // Type implements basetypes.ObjectValuable. @@ -3026,52 +1976,18 @@ func (a PipelineAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o PipelineAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -3118,52 +2034,19 @@ func (a PipelineAccessControlResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -3191,17 +2074,17 @@ type PipelineCluster struct { Autoscale types.List `tfsdk:"autoscale" tf:"optional,object"` // Attributes related to clusters running on Amazon Web Services. If not // specified at cluster creation, a set of default values will be used. - AwsAttributes compute.AwsAttributes `tfsdk:"aws_attributes" tf:"optional,object"` + AwsAttributes types.List `tfsdk:"aws_attributes" tf:"optional,object"` // Attributes related to clusters running on Microsoft Azure. If not // specified at cluster creation, a set of default values will be used. - AzureAttributes compute.AzureAttributes `tfsdk:"azure_attributes" tf:"optional,object"` + AzureAttributes types.List `tfsdk:"azure_attributes" tf:"optional,object"` // The configuration for delivering spark logs to a long-term storage // destination. Only dbfs destinations are supported. Only one destination // can be specified for one cluster. If the conf is given, the logs will be // delivered to the destination every `5 mins`. The destination of driver // logs is `$destination/$clusterId/driver`, while the destination of // executor logs is `$destination/$clusterId/executor`. - ClusterLogConf compute.ClusterLogConf `tfsdk:"cluster_log_conf" tf:"optional,object"` + ClusterLogConf types.List `tfsdk:"cluster_log_conf" tf:"optional,object"` // Additional tags for cluster resources. Databricks will tag all cluster // resources (e.g., AWS instances and EBS volumes) with these tags in // addition to `default_tags`. Notes: @@ -3223,7 +2106,7 @@ type PipelineCluster struct { EnableLocalDiskEncryption types.Bool `tfsdk:"enable_local_disk_encryption" tf:"optional"` // Attributes related to clusters running on Google Cloud Platform. If not // specified at cluster creation, a set of default values will be used. - GcpAttributes compute.GcpAttributes `tfsdk:"gcp_attributes" tf:"optional,object"` + GcpAttributes types.List `tfsdk:"gcp_attributes" tf:"optional,object"` // The configuration for storing init scripts. Any number of destinations // can be specified. The scripts are executed sequentially in the order // provided. If `cluster_log_conf` is specified, init script logs are sent @@ -3306,52 +2189,33 @@ func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineCluster{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineCluster) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineCluster) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineCluster) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineCluster) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineCluster) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineCluster +// only implements ToObjectValue() and Type(). +func (o PipelineCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineCluster) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apply_policy_default_values": o.ApplyPolicyDefaultValues, + "autoscale": o.Autoscale, + "aws_attributes": o.AwsAttributes, + "azure_attributes": o.AzureAttributes, + "cluster_log_conf": o.ClusterLogConf, + "custom_tags": o.CustomTags, + "driver_instance_pool_id": o.DriverInstancePoolId, + "driver_node_type_id": o.DriverNodeTypeId, + "enable_local_disk_encryption": o.EnableLocalDiskEncryption, + "gcp_attributes": o.GcpAttributes, + "init_scripts": o.InitScripts, + "instance_pool_id": o.InstancePoolId, + "label": o.Label, + "node_type_id": o.NodeTypeId, + "num_workers": o.NumWorkers, + "policy_id": o.PolicyId, + "spark_conf": o.SparkConf, + "spark_env_vars": o.SparkEnvVars, + "ssh_public_keys": o.SshPublicKeys, + }) } // Type implements basetypes.ObjectValuable. @@ -3434,52 +2298,17 @@ func (a PipelineClusterAutoscale) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineClusterAutoscale{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineClusterAutoscale) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineClusterAutoscale) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineClusterAutoscale) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineClusterAutoscale) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineClusterAutoscale) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineClusterAutoscale +// only implements ToObjectValue() and Type(). +func (o PipelineClusterAutoscale) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineClusterAutoscale) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_workers": o.MaxWorkers, + "min_workers": o.MinWorkers, + "mode": o.Mode, + }) } // Type implements basetypes.ObjectValuable. @@ -3517,52 +2346,16 @@ func (a PipelineDeployment) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineDeployment{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineDeployment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineDeployment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineDeployment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineDeployment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineDeployment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineDeployment +// only implements ToObjectValue() and Type(). +func (o PipelineDeployment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineDeployment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "kind": o.Kind, + "metadata_file_path": o.MetadataFilePath, + }) } // Type implements basetypes.ObjectValuable. @@ -3617,52 +2410,23 @@ func (a PipelineEvent) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineEvent{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineEvent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineEvent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineEvent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineEvent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineEvent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineEvent +// only implements ToObjectValue() and Type(). +func (o PipelineEvent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineEvent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error": o.Error, + "event_type": o.EventType, + "id": o.Id, + "level": o.Level, + "maturity_level": o.MaturityLevel, + "message": o.Message, + "origin": o.Origin, + "sequence": o.Sequence, + "timestamp": o.Timestamp, + }) } // Type implements basetypes.ObjectValuable. @@ -3695,7 +2459,7 @@ type PipelineLibrary struct { // URI of the jar to be installed. Currently only DBFS is supported. Jar types.String `tfsdk:"jar" tf:"optional"` // Specification of a maven library to be installed. - Maven compute.MavenLibrary `tfsdk:"maven" tf:"optional,object"` + Maven types.List `tfsdk:"maven" tf:"optional,object"` // The path to a notebook that defines a pipeline and is stored in the // Databricks workspace. Notebook types.List `tfsdk:"notebook" tf:"optional,object"` @@ -3724,52 +2488,19 @@ func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineLibrary{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineLibrary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineLibrary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineLibrary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineLibrary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineLibrary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineLibrary +// only implements ToObjectValue() and Type(). +func (o PipelineLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineLibrary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "file": o.File, + "jar": o.Jar, + "maven": o.Maven, + "notebook": o.Notebook, + "whl": o.Whl, + }) } // Type implements basetypes.ObjectValuable. @@ -3818,52 +2549,17 @@ func (a PipelinePermission) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelinePermission{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelinePermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelinePermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelinePermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelinePermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelinePermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelinePermission +// only implements ToObjectValue() and Type(). +func (o PipelinePermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelinePermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -3906,52 +2602,17 @@ func (a PipelinePermissions) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelinePermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelinePermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelinePermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelinePermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelinePermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelinePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelinePermissions +// only implements ToObjectValue() and Type(). +func (o PipelinePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelinePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -3990,52 +2651,16 @@ func (a PipelinePermissionsDescription) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelinePermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelinePermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelinePermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelinePermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelinePermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelinePermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelinePermissionsDescription +// only implements ToObjectValue() and Type(). +func (o PipelinePermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelinePermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -4073,52 +2698,16 @@ func (a PipelinePermissionsRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelinePermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelinePermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelinePermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelinePermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelinePermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelinePermissionsRequest +// only implements ToObjectValue() and Type(). +func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelinePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -4219,52 +2808,37 @@ func (a PipelineSpec) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineSpec +// only implements ToObjectValue() and Type(). +func (o PipelineSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "budget_policy_id": o.BudgetPolicyId, + "catalog": o.Catalog, + "channel": o.Channel, + "clusters": o.Clusters, + "configuration": o.Configuration, + "continuous": o.Continuous, + "deployment": o.Deployment, + "development": o.Development, + "edition": o.Edition, + "filters": o.Filters, + "gateway_definition": o.GatewayDefinition, + "id": o.Id, + "ingestion_definition": o.IngestionDefinition, + "libraries": o.Libraries, + "name": o.Name, + "notifications": o.Notifications, + "photon": o.Photon, + "restart_window": o.RestartWindow, + "schema": o.Schema, + "serverless": o.Serverless, + "storage": o.Storage, + "target": o.Target, + "trigger": o.Trigger, + }) } // Type implements basetypes.ObjectValuable. @@ -4358,52 +2932,22 @@ func (a PipelineStateInfo) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineStateInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineStateInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineStateInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineStateInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineStateInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineStateInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineStateInfo +// only implements ToObjectValue() and Type(). +func (o PipelineStateInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineStateInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cluster_id": o.ClusterId, + "creator_user_name": o.CreatorUserName, + "health": o.Health, + "latest_updates": o.LatestUpdates, + "name": o.Name, + "pipeline_id": o.PipelineId, + "run_as_user_name": o.RunAsUserName, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -4450,52 +2994,16 @@ func (a PipelineTrigger) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PipelineTrigger{} - -// Equal implements basetypes.ObjectValuable. -func (o PipelineTrigger) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PipelineTrigger) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PipelineTrigger) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PipelineTrigger) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PipelineTrigger) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PipelineTrigger +// only implements ToObjectValue() and Type(). +func (o PipelineTrigger) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PipelineTrigger) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cron": o.Cron, + "manual": o.Manual, + }) } // Type implements basetypes.ObjectValuable. @@ -4547,52 +3055,19 @@ func (a ReportSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReportSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o ReportSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReportSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReportSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReportSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReportSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReportSpec +// only implements ToObjectValue() and Type(). +func (o ReportSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReportSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_catalog": o.DestinationCatalog, + "destination_schema": o.DestinationSchema, + "destination_table": o.DestinationTable, + "source_url": o.SourceUrl, + "table_configuration": o.TableConfiguration, + }) } // Type implements basetypes.ObjectValuable. @@ -4642,52 +3117,17 @@ func (a RestartWindow) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestartWindow{} - -// Equal implements basetypes.ObjectValuable. -func (o RestartWindow) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestartWindow) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestartWindow) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestartWindow) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestartWindow) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestartWindow +// only implements ToObjectValue() and Type(). +func (o RestartWindow) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestartWindow) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "days_of_week": o.DaysOfWeek, + "start_hour": o.StartHour, + "time_zone_id": o.TimeZoneId, + }) } // Type implements basetypes.ObjectValuable. @@ -4738,52 +3178,19 @@ func (a SchemaSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SchemaSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o SchemaSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SchemaSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SchemaSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SchemaSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SchemaSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SchemaSpec +// only implements ToObjectValue() and Type(). +func (o SchemaSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SchemaSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_catalog": o.DestinationCatalog, + "destination_schema": o.DestinationSchema, + "source_catalog": o.SourceCatalog, + "source_schema": o.SourceSchema, + "table_configuration": o.TableConfiguration, + }) } // Type implements basetypes.ObjectValuable. @@ -4827,52 +3234,16 @@ func (a Sequencing) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Sequencing{} - -// Equal implements basetypes.ObjectValuable. -func (o Sequencing) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Sequencing) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Sequencing) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Sequencing) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Sequencing) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Sequencing +// only implements ToObjectValue() and Type(). +func (o Sequencing) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Sequencing) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "control_plane_seq_no": o.ControlPlaneSeqNo, + "data_plane_id": o.DataPlaneId, + }) } // Type implements basetypes.ObjectValuable. @@ -4915,52 +3286,17 @@ func (a SerializedException) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SerializedException{} - -// Equal implements basetypes.ObjectValuable. -func (o SerializedException) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SerializedException) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SerializedException) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SerializedException) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SerializedException) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SerializedException +// only implements ToObjectValue() and Type(). +func (o SerializedException) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SerializedException) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "class_name": o.ClassName, + "message": o.Message, + "stack": o.Stack, + }) } // Type implements basetypes.ObjectValuable. @@ -5004,52 +3340,18 @@ func (a StackFrame) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StackFrame{} - -// Equal implements basetypes.ObjectValuable. -func (o StackFrame) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StackFrame) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StackFrame) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StackFrame) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StackFrame) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StackFrame +// only implements ToObjectValue() and Type(). +func (o StackFrame) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StackFrame) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "declaring_class": o.DeclaringClass, + "file_name": o.FileName, + "line_number": o.LineNumber, + "method_name": o.MethodName, + }) } // Type implements basetypes.ObjectValuable. @@ -5105,52 +3407,20 @@ func (a StartUpdate) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartUpdate{} - -// Equal implements basetypes.ObjectValuable. -func (o StartUpdate) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartUpdate) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartUpdate) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartUpdate) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartUpdate +// only implements ToObjectValue() and Type(). +func (o StartUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cause": o.Cause, + "full_refresh": o.FullRefresh, + "full_refresh_selection": o.FullRefreshSelection, + "pipeline_id": o.PipelineId, + "refresh_selection": o.RefreshSelection, + "validate_only": o.ValidateOnly, + }) } // Type implements basetypes.ObjectValuable. @@ -5192,52 +3462,15 @@ func (a StartUpdateResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartUpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o StartUpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartUpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartUpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartUpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartUpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartUpdateResponse +// only implements ToObjectValue() and Type(). +func (o StartUpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartUpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "update_id": o.UpdateId, + }) } // Type implements basetypes.ObjectValuable. @@ -5269,52 +3502,13 @@ func (a StopPipelineResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StopPipelineResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o StopPipelineResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StopPipelineResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StopPipelineResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StopPipelineResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StopPipelineResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StopPipelineResponse +// only implements ToObjectValue() and Type(). +func (o StopPipelineResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StopPipelineResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5346,52 +3540,15 @@ func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StopRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o StopRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StopRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StopRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StopRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StopRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StopRequest +// only implements ToObjectValue() and Type(). +func (o StopRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StopRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "pipeline_id": o.PipelineId, + }) } // Type implements basetypes.ObjectValuable. @@ -5443,52 +3600,21 @@ func (a TableSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o TableSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableSpec +// only implements ToObjectValue() and Type(). +func (o TableSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_catalog": o.DestinationCatalog, + "destination_schema": o.DestinationSchema, + "destination_table": o.DestinationTable, + "source_catalog": o.SourceCatalog, + "source_schema": o.SourceSchema, + "source_table": o.SourceTable, + "table_configuration": o.TableConfiguration, + }) } // Type implements basetypes.ObjectValuable. @@ -5542,52 +3668,18 @@ func (a TableSpecificConfig) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TableSpecificConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o TableSpecificConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TableSpecificConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TableSpecificConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TableSpecificConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TableSpecificConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TableSpecificConfig +// only implements ToObjectValue() and Type(). +func (o TableSpecificConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TableSpecificConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "primary_keys": o.PrimaryKeys, + "salesforce_include_formula_fields": o.SalesforceIncludeFormulaFields, + "scd_type": o.ScdType, + "sequence_by": o.SequenceBy, + }) } // Type implements basetypes.ObjectValuable. @@ -5660,52 +3752,25 @@ func (a UpdateInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateInfo +// only implements ToObjectValue() and Type(). +func (o UpdateInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cause": o.Cause, + "cluster_id": o.ClusterId, + "config": o.Config, + "creation_time": o.CreationTime, + "full_refresh": o.FullRefresh, + "full_refresh_selection": o.FullRefreshSelection, + "pipeline_id": o.PipelineId, + "refresh_selection": o.RefreshSelection, + "state": o.State, + "update_id": o.UpdateId, + "validate_only": o.ValidateOnly, + }) } // Type implements basetypes.ObjectValuable. @@ -5758,52 +3823,17 @@ func (a UpdateStateInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateStateInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateStateInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateStateInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateStateInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateStateInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateStateInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateStateInfo +// only implements ToObjectValue() and Type(). +func (o UpdateStateInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateStateInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_time": o.CreationTime, + "state": o.State, + "update_id": o.UpdateId, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 9e1442d59d..2b91c6f3ed 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -12,15 +12,11 @@ package provisioning_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AwsCredentials struct { @@ -46,52 +42,15 @@ func (a AwsCredentials) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsCredentials{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsCredentials) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsCredentials) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsCredentials) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsCredentials) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsCredentials +// only implements ToObjectValue() and Type(). +func (o AwsCredentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "sts_role": o.StsRole, + }) } // Type implements basetypes.ObjectValuable. @@ -136,52 +95,18 @@ func (a AwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AwsKeyInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o AwsKeyInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AwsKeyInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AwsKeyInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AwsKeyInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AwsKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AwsKeyInfo +// only implements ToObjectValue() and Type(). +func (o AwsKeyInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AwsKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key_alias": o.KeyAlias, + "key_arn": o.KeyArn, + "key_region": o.KeyRegion, + "reuse_key_for_cluster_volumes": o.ReuseKeyForClusterVolumes, + }) } // Type implements basetypes.ObjectValuable. @@ -220,52 +145,16 @@ func (a AzureWorkspaceInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureWorkspaceInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureWorkspaceInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureWorkspaceInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureWorkspaceInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureWorkspaceInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureWorkspaceInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureWorkspaceInfo +// only implements ToObjectValue() and Type(). +func (o AzureWorkspaceInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureWorkspaceInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "resource_group": o.ResourceGroup, + "subscription_id": o.SubscriptionId, + }) } // Type implements basetypes.ObjectValuable. @@ -303,52 +192,15 @@ func (a CloudResourceContainer) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CloudResourceContainer{} - -// Equal implements basetypes.ObjectValuable. -func (o CloudResourceContainer) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CloudResourceContainer) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CloudResourceContainer) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CloudResourceContainer) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CloudResourceContainer) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CloudResourceContainer +// only implements ToObjectValue() and Type(). +func (o CloudResourceContainer) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CloudResourceContainer) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "gcp": o.Gcp, + }) } // Type implements basetypes.ObjectValuable. @@ -392,52 +244,17 @@ func (a CreateAwsKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateAwsKeyInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateAwsKeyInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateAwsKeyInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateAwsKeyInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateAwsKeyInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateAwsKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateAwsKeyInfo +// only implements ToObjectValue() and Type(). +func (o CreateAwsKeyInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateAwsKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key_alias": o.KeyAlias, + "key_arn": o.KeyArn, + "reuse_key_for_cluster_volumes": o.ReuseKeyForClusterVolumes, + }) } // Type implements basetypes.ObjectValuable. @@ -474,52 +291,15 @@ func (a CreateCredentialAwsCredentials) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCredentialAwsCredentials{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCredentialAwsCredentials) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCredentialAwsCredentials) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCredentialAwsCredentials) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCredentialAwsCredentials) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCredentialAwsCredentials) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCredentialAwsCredentials +// only implements ToObjectValue() and Type(). +func (o CreateCredentialAwsCredentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCredentialAwsCredentials) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "sts_role": o.StsRole, + }) } // Type implements basetypes.ObjectValuable. @@ -558,52 +338,16 @@ func (a CreateCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCredentialRequest +// only implements ToObjectValue() and Type(). +func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_credentials": o.AwsCredentials, + "credentials_name": o.CredentialsName, + }) } // Type implements basetypes.ObjectValuable. @@ -640,52 +384,15 @@ func (a CreateCredentialStsRole) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCredentialStsRole{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCredentialStsRole) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCredentialStsRole) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCredentialStsRole) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCredentialStsRole) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCredentialStsRole) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCredentialStsRole +// only implements ToObjectValue() and Type(). +func (o CreateCredentialStsRole) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCredentialStsRole) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "role_arn": o.RoleArn, + }) } // Type implements basetypes.ObjectValuable. @@ -726,52 +433,17 @@ func (a CreateCustomerManagedKeyRequest) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCustomerManagedKeyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCustomerManagedKeyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCustomerManagedKeyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCustomerManagedKeyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCustomerManagedKeyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCustomerManagedKeyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCustomerManagedKeyRequest +// only implements ToObjectValue() and Type(). +func (o CreateCustomerManagedKeyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCustomerManagedKeyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_key_info": o.AwsKeyInfo, + "gcp_key_info": o.GcpKeyInfo, + "use_cases": o.UseCases, + }) } // Type implements basetypes.ObjectValuable. @@ -813,52 +485,15 @@ func (a CreateGcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateGcpKeyInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateGcpKeyInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateGcpKeyInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateGcpKeyInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateGcpKeyInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateGcpKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateGcpKeyInfo +// only implements ToObjectValue() and Type(). +func (o CreateGcpKeyInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateGcpKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "kms_key_id": o.KmsKeyId, + }) } // Type implements basetypes.ObjectValuable. @@ -914,52 +549,20 @@ func (a CreateNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateNetworkRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateNetworkRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateNetworkRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateNetworkRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateNetworkRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateNetworkRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateNetworkRequest +// only implements ToObjectValue() and Type(). +func (o CreateNetworkRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateNetworkRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "gcp_network_info": o.GcpNetworkInfo, + "network_name": o.NetworkName, + "security_group_ids": o.SecurityGroupIds, + "subnet_ids": o.SubnetIds, + "vpc_endpoints": o.VpcEndpoints, + "vpc_id": o.VpcId, + }) } // Type implements basetypes.ObjectValuable. @@ -1010,52 +613,16 @@ func (a CreateStorageConfigurationRequest) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateStorageConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateStorageConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateStorageConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateStorageConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateStorageConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateStorageConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateStorageConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o CreateStorageConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateStorageConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "root_bucket_info": o.RootBucketInfo, + "storage_configuration_name": o.StorageConfigurationName, + }) } // Type implements basetypes.ObjectValuable. @@ -1101,52 +668,18 @@ func (a CreateVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateVpcEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateVpcEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateVpcEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateVpcEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateVpcEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateVpcEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateVpcEndpointRequest +// only implements ToObjectValue() and Type(). +func (o CreateVpcEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateVpcEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_vpc_endpoint_id": o.AwsVpcEndpointId, + "gcp_vpc_endpoint_info": o.GcpVpcEndpointInfo, + "region": o.Region, + "vpc_endpoint_name": o.VpcEndpointName, + }) } // Type implements basetypes.ObjectValuable. @@ -1298,52 +831,31 @@ func (a CreateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateWorkspaceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateWorkspaceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateWorkspaceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateWorkspaceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateWorkspaceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateWorkspaceRequest +// only implements ToObjectValue() and Type(). +func (o CreateWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_region": o.AwsRegion, + "cloud": o.Cloud, + "cloud_resource_container": o.CloudResourceContainer, + "credentials_id": o.CredentialsId, + "custom_tags": o.CustomTags, + "deployment_name": o.DeploymentName, + "gcp_managed_network_config": o.GcpManagedNetworkConfig, + "gke_config": o.GkeConfig, + "is_no_public_ip_enabled": o.IsNoPublicIpEnabled, + "location": o.Location, + "managed_services_customer_managed_key_id": o.ManagedServicesCustomerManagedKeyId, + "network_id": o.NetworkId, + "pricing_tier": o.PricingTier, + "private_access_settings_id": o.PrivateAccessSettingsId, + "storage_configuration_id": o.StorageConfigurationId, + "storage_customer_managed_key_id": o.StorageCustomerManagedKeyId, + "workspace_name": o.WorkspaceName, + }) } // Type implements basetypes.ObjectValuable. @@ -1411,52 +923,19 @@ func (a Credential) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Credential{} - -// Equal implements basetypes.ObjectValuable. -func (o Credential) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Credential) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Credential) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Credential) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Credential) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Credential +// only implements ToObjectValue() and Type(). +func (o Credential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Credential) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "aws_credentials": o.AwsCredentials, + "creation_time": o.CreationTime, + "credentials_id": o.CredentialsId, + "credentials_name": o.CredentialsName, + }) } // Type implements basetypes.ObjectValuable. @@ -1498,52 +977,15 @@ func (a CustomerFacingGcpCloudResourceContainer) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CustomerFacingGcpCloudResourceContainer{} - -// Equal implements basetypes.ObjectValuable. -func (o CustomerFacingGcpCloudResourceContainer) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CustomerFacingGcpCloudResourceContainer) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CustomerFacingGcpCloudResourceContainer) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CustomerFacingGcpCloudResourceContainer) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CustomerFacingGcpCloudResourceContainer) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CustomerFacingGcpCloudResourceContainer +// only implements ToObjectValue() and Type(). +func (o CustomerFacingGcpCloudResourceContainer) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CustomerFacingGcpCloudResourceContainer) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "project_id": o.ProjectId, + }) } // Type implements basetypes.ObjectValuable. @@ -1591,52 +1033,20 @@ func (a CustomerManagedKey) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CustomerManagedKey{} - -// Equal implements basetypes.ObjectValuable. -func (o CustomerManagedKey) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CustomerManagedKey) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CustomerManagedKey) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CustomerManagedKey) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CustomerManagedKey) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CustomerManagedKey +// only implements ToObjectValue() and Type(). +func (o CustomerManagedKey) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CustomerManagedKey) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "aws_key_info": o.AwsKeyInfo, + "creation_time": o.CreationTime, + "customer_managed_key_id": o.CustomerManagedKeyId, + "gcp_key_info": o.GcpKeyInfo, + "use_cases": o.UseCases, + }) } // Type implements basetypes.ObjectValuable. @@ -1682,52 +1092,15 @@ func (a DeleteCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCredentialRequest +// only implements ToObjectValue() and Type(). +func (o DeleteCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credentials_id": o.CredentialsId, + }) } // Type implements basetypes.ObjectValuable. @@ -1762,52 +1135,15 @@ func (a DeleteEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteEncryptionKeyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteEncryptionKeyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteEncryptionKeyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteEncryptionKeyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteEncryptionKeyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteEncryptionKeyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteEncryptionKeyRequest +// only implements ToObjectValue() and Type(). +func (o DeleteEncryptionKeyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteEncryptionKeyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "customer_managed_key_id": o.CustomerManagedKeyId, + }) } // Type implements basetypes.ObjectValuable. @@ -1842,52 +1178,15 @@ func (a DeleteNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteNetworkRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteNetworkRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteNetworkRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteNetworkRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteNetworkRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteNetworkRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteNetworkRequest +// only implements ToObjectValue() and Type(). +func (o DeleteNetworkRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteNetworkRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_id": o.NetworkId, + }) } // Type implements basetypes.ObjectValuable. @@ -1922,52 +1221,15 @@ func (a DeletePrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePrivateAccesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePrivateAccesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePrivateAccesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePrivateAccesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePrivateAccesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePrivateAccesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePrivateAccesRequest +// only implements ToObjectValue() and Type(). +func (o DeletePrivateAccesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePrivateAccesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "private_access_settings_id": o.PrivateAccessSettingsId, + }) } // Type implements basetypes.ObjectValuable. @@ -1999,52 +1261,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -2077,52 +1300,15 @@ func (a DeleteStorageRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteStorageRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteStorageRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteStorageRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteStorageRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteStorageRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteStorageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteStorageRequest +// only implements ToObjectValue() and Type(). +func (o DeleteStorageRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteStorageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "storage_configuration_id": o.StorageConfigurationId, + }) } // Type implements basetypes.ObjectValuable. @@ -2157,52 +1343,15 @@ func (a DeleteVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteVpcEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteVpcEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteVpcEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteVpcEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteVpcEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteVpcEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteVpcEndpointRequest +// only implements ToObjectValue() and Type(). +func (o DeleteVpcEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteVpcEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "vpc_endpoint_id": o.VpcEndpointId, + }) } // Type implements basetypes.ObjectValuable. @@ -2237,52 +1386,15 @@ func (a DeleteWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWorkspaceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWorkspaceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWorkspaceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWorkspaceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWorkspaceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWorkspaceRequest +// only implements ToObjectValue() and Type(). +func (o DeleteWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -2320,52 +1432,17 @@ func (a ExternalCustomerInfo) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExternalCustomerInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ExternalCustomerInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExternalCustomerInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExternalCustomerInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExternalCustomerInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExternalCustomerInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExternalCustomerInfo +// only implements ToObjectValue() and Type(). +func (o ExternalCustomerInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExternalCustomerInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "authoritative_user_email": o.AuthoritativeUserEmail, + "authoritative_user_full_name": o.AuthoritativeUserFullName, + "customer_name": o.CustomerName, + }) } // Type implements basetypes.ObjectValuable. @@ -2401,52 +1478,15 @@ func (a GcpKeyInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpKeyInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpKeyInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpKeyInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpKeyInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpKeyInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpKeyInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpKeyInfo +// only implements ToObjectValue() and Type(). +func (o GcpKeyInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpKeyInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "kms_key_id": o.KmsKeyId, + }) } // Type implements basetypes.ObjectValuable. @@ -2510,52 +1550,17 @@ func (a GcpManagedNetworkConfig) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpManagedNetworkConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpManagedNetworkConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpManagedNetworkConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpManagedNetworkConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpManagedNetworkConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpManagedNetworkConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpManagedNetworkConfig +// only implements ToObjectValue() and Type(). +func (o GcpManagedNetworkConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpManagedNetworkConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "gke_cluster_pod_ip_range": o.GkeClusterPodIpRange, + "gke_cluster_service_ip_range": o.GkeClusterServiceIpRange, + "subnet_cidr": o.SubnetCidr, + }) } // Type implements basetypes.ObjectValuable. @@ -2609,52 +1614,20 @@ func (a GcpNetworkInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpNetworkInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpNetworkInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpNetworkInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpNetworkInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpNetworkInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpNetworkInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpNetworkInfo +// only implements ToObjectValue() and Type(). +func (o GcpNetworkInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpNetworkInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_project_id": o.NetworkProjectId, + "pod_ip_range_name": o.PodIpRangeName, + "service_ip_range_name": o.ServiceIpRangeName, + "subnet_id": o.SubnetId, + "subnet_region": o.SubnetRegion, + "vpc_id": o.VpcId, + }) } // Type implements basetypes.ObjectValuable. @@ -2704,52 +1677,19 @@ func (a GcpVpcEndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GcpVpcEndpointInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o GcpVpcEndpointInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GcpVpcEndpointInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GcpVpcEndpointInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GcpVpcEndpointInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GcpVpcEndpointInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GcpVpcEndpointInfo +// only implements ToObjectValue() and Type(). +func (o GcpVpcEndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GcpVpcEndpointInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_region": o.EndpointRegion, + "project_id": o.ProjectId, + "psc_connection_id": o.PscConnectionId, + "psc_endpoint_name": o.PscEndpointName, + "service_attachment_id": o.ServiceAttachmentId, + }) } // Type implements basetypes.ObjectValuable. @@ -2788,52 +1728,15 @@ func (a GetCredentialRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCredentialRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCredentialRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCredentialRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCredentialRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCredentialRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCredentialRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCredentialRequest +// only implements ToObjectValue() and Type(). +func (o GetCredentialRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCredentialRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credentials_id": o.CredentialsId, + }) } // Type implements basetypes.ObjectValuable. @@ -2868,52 +1771,15 @@ func (a GetEncryptionKeyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEncryptionKeyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEncryptionKeyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEncryptionKeyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEncryptionKeyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEncryptionKeyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEncryptionKeyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEncryptionKeyRequest +// only implements ToObjectValue() and Type(). +func (o GetEncryptionKeyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEncryptionKeyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "customer_managed_key_id": o.CustomerManagedKeyId, + }) } // Type implements basetypes.ObjectValuable. @@ -2940,60 +1806,23 @@ func (newState *GetNetworkRequest) SyncEffectiveFieldsDuringRead(existingState G // GetComplexFieldTypes returns a map of the types of elements in complex fields in GetNetworkRequest. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a GetNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetNetworkRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetNetworkRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetNetworkRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetNetworkRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetNetworkRequest) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a GetNetworkRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetNetworkRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetNetworkRequest +// only implements ToObjectValue() and Type(). +func (o GetNetworkRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetNetworkRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_id": o.NetworkId, + }) } // Type implements basetypes.ObjectValuable. @@ -3028,52 +1857,15 @@ func (a GetPrivateAccesRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPrivateAccesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPrivateAccesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPrivateAccesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPrivateAccesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPrivateAccesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPrivateAccesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPrivateAccesRequest +// only implements ToObjectValue() and Type(). +func (o GetPrivateAccesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPrivateAccesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "private_access_settings_id": o.PrivateAccessSettingsId, + }) } // Type implements basetypes.ObjectValuable. @@ -3108,52 +1900,15 @@ func (a GetStorageRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStorageRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStorageRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStorageRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStorageRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStorageRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStorageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStorageRequest +// only implements ToObjectValue() and Type(). +func (o GetStorageRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStorageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "storage_configuration_id": o.StorageConfigurationId, + }) } // Type implements basetypes.ObjectValuable. @@ -3188,52 +1943,15 @@ func (a GetVpcEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetVpcEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetVpcEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetVpcEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetVpcEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetVpcEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetVpcEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetVpcEndpointRequest +// only implements ToObjectValue() and Type(). +func (o GetVpcEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetVpcEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "vpc_endpoint_id": o.VpcEndpointId, + }) } // Type implements basetypes.ObjectValuable. @@ -3268,52 +1986,15 @@ func (a GetWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceRequest +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -3360,52 +2041,16 @@ func (a GkeConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GkeConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o GkeConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GkeConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GkeConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GkeConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GkeConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GkeConfig +// only implements ToObjectValue() and Type(). +func (o GkeConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GkeConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "connectivity_type": o.ConnectivityType, + "master_ip_range": o.MasterIpRange, + }) } // Type implements basetypes.ObjectValuable. @@ -3478,52 +2123,27 @@ func (a Network) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Network{} - -// Equal implements basetypes.ObjectValuable. -func (o Network) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Network) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Network) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Network) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Network) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Network +// only implements ToObjectValue() and Type(). +func (o Network) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Network) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "creation_time": o.CreationTime, + "error_messages": o.ErrorMessages, + "gcp_network_info": o.GcpNetworkInfo, + "network_id": o.NetworkId, + "network_name": o.NetworkName, + "security_group_ids": o.SecurityGroupIds, + "subnet_ids": o.SubnetIds, + "vpc_endpoints": o.VpcEndpoints, + "vpc_id": o.VpcId, + "vpc_status": o.VpcStatus, + "warning_messages": o.WarningMessages, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -3584,52 +2204,16 @@ func (a NetworkHealth) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NetworkHealth{} - -// Equal implements basetypes.ObjectValuable. -func (o NetworkHealth) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NetworkHealth) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NetworkHealth) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NetworkHealth) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NetworkHealth) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NetworkHealth +// only implements ToObjectValue() and Type(). +func (o NetworkHealth) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NetworkHealth) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error_message": o.ErrorMessage, + "error_type": o.ErrorType, + }) } // Type implements basetypes.ObjectValuable. @@ -3675,52 +2259,16 @@ func (a NetworkVpcEndpoints) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NetworkVpcEndpoints{} - -// Equal implements basetypes.ObjectValuable. -func (o NetworkVpcEndpoints) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NetworkVpcEndpoints) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NetworkVpcEndpoints) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NetworkVpcEndpoints) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NetworkVpcEndpoints) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NetworkVpcEndpoints +// only implements ToObjectValue() and Type(). +func (o NetworkVpcEndpoints) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NetworkVpcEndpoints) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dataplane_relay": o.DataplaneRelay, + "rest_api": o.RestApi, + }) } // Type implements basetypes.ObjectValuable. @@ -3762,52 +2310,16 @@ func (a NetworkWarning) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NetworkWarning{} - -// Equal implements basetypes.ObjectValuable. -func (o NetworkWarning) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NetworkWarning) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NetworkWarning) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NetworkWarning) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NetworkWarning) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NetworkWarning +// only implements ToObjectValue() and Type(). +func (o NetworkWarning) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NetworkWarning) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "warning_message": o.WarningMessage, + "warning_type": o.WarningType, + }) } // Type implements basetypes.ObjectValuable. @@ -3866,52 +2378,21 @@ func (a PrivateAccessSettings) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PrivateAccessSettings{} - -// Equal implements basetypes.ObjectValuable. -func (o PrivateAccessSettings) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PrivateAccessSettings) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PrivateAccessSettings) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PrivateAccessSettings) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PrivateAccessSettings) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PrivateAccessSettings +// only implements ToObjectValue() and Type(). +func (o PrivateAccessSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PrivateAccessSettings) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "allowed_vpc_endpoint_ids": o.AllowedVpcEndpointIds, + "private_access_level": o.PrivateAccessLevel, + "private_access_settings_id": o.PrivateAccessSettingsId, + "private_access_settings_name": o.PrivateAccessSettingsName, + "public_access_enabled": o.PublicAccessEnabled, + "region": o.Region, + }) } // Type implements basetypes.ObjectValuable. @@ -3951,52 +2432,13 @@ func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReplaceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ReplaceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReplaceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReplaceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReplaceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReplaceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReplaceResponse +// only implements ToObjectValue() and Type(). +func (o ReplaceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReplaceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4029,52 +2471,15 @@ func (a RootBucketInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RootBucketInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RootBucketInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RootBucketInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RootBucketInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RootBucketInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RootBucketInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RootBucketInfo +// only implements ToObjectValue() and Type(). +func (o RootBucketInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RootBucketInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bucket_name": o.BucketName, + }) } // Type implements basetypes.ObjectValuable. @@ -4118,52 +2523,19 @@ func (a StorageConfiguration) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StorageConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o StorageConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StorageConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StorageConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StorageConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StorageConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StorageConfiguration +// only implements ToObjectValue() and Type(). +func (o StorageConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StorageConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "creation_time": o.CreationTime, + "root_bucket_info": o.RootBucketInfo, + "storage_configuration_id": o.StorageConfigurationId, + "storage_configuration_name": o.StorageConfigurationName, + }) } // Type implements basetypes.ObjectValuable. @@ -4206,52 +2578,16 @@ func (a StsRole) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StsRole{} - -// Equal implements basetypes.ObjectValuable. -func (o StsRole) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StsRole) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StsRole) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StsRole) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StsRole) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StsRole +// only implements ToObjectValue() and Type(). +func (o StsRole) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StsRole) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "external_id": o.ExternalId, + "role_arn": o.RoleArn, + }) } // Type implements basetypes.ObjectValuable. @@ -4284,52 +2620,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4393,52 +2690,24 @@ func (a UpdateWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateWorkspaceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateWorkspaceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateWorkspaceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateWorkspaceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateWorkspaceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateWorkspaceRequest +// only implements ToObjectValue() and Type(). +func (o UpdateWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_region": o.AwsRegion, + "credentials_id": o.CredentialsId, + "custom_tags": o.CustomTags, + "managed_services_customer_managed_key_id": o.ManagedServicesCustomerManagedKeyId, + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "network_id": o.NetworkId, + "private_access_settings_id": o.PrivateAccessSettingsId, + "storage_configuration_id": o.StorageConfigurationId, + "storage_customer_managed_key_id": o.StorageCustomerManagedKeyId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -4518,52 +2787,20 @@ func (a UpsertPrivateAccessSettingsRequest) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpsertPrivateAccessSettingsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpsertPrivateAccessSettingsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpsertPrivateAccessSettingsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpsertPrivateAccessSettingsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpsertPrivateAccessSettingsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpsertPrivateAccessSettingsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpsertPrivateAccessSettingsRequest +// only implements ToObjectValue() and Type(). +func (o UpsertPrivateAccessSettingsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpsertPrivateAccessSettingsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allowed_vpc_endpoint_ids": o.AllowedVpcEndpointIds, + "private_access_level": o.PrivateAccessLevel, + "private_access_settings_id": o.PrivateAccessSettingsId, + "private_access_settings_name": o.PrivateAccessSettingsName, + "public_access_enabled": o.PublicAccessEnabled, + "region": o.Region, + }) } // Type implements basetypes.ObjectValuable. @@ -4639,52 +2876,24 @@ func (a VpcEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = VpcEndpoint{} - -// Equal implements basetypes.ObjectValuable. -func (o VpcEndpoint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o VpcEndpoint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o VpcEndpoint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o VpcEndpoint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o VpcEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, VpcEndpoint +// only implements ToObjectValue() and Type(). +func (o VpcEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o VpcEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "aws_account_id": o.AwsAccountId, + "aws_endpoint_service_id": o.AwsEndpointServiceId, + "aws_vpc_endpoint_id": o.AwsVpcEndpointId, + "gcp_vpc_endpoint_info": o.GcpVpcEndpointInfo, + "region": o.Region, + "state": o.State, + "use_case": o.UseCase, + "vpc_endpoint_id": o.VpcEndpointId, + "vpc_endpoint_name": o.VpcEndpointName, + }) } // Type implements basetypes.ObjectValuable. @@ -4831,52 +3040,38 @@ func (a Workspace) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Workspace{} - -// Equal implements basetypes.ObjectValuable. -func (o Workspace) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Workspace) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Workspace) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Workspace) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Workspace) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Workspace +// only implements ToObjectValue() and Type(). +func (o Workspace) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Workspace) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "aws_region": o.AwsRegion, + "azure_workspace_info": o.AzureWorkspaceInfo, + "cloud": o.Cloud, + "cloud_resource_container": o.CloudResourceContainer, + "creation_time": o.CreationTime, + "credentials_id": o.CredentialsId, + "custom_tags": o.CustomTags, + "deployment_name": o.DeploymentName, + "external_customer_info": o.ExternalCustomerInfo, + "gcp_managed_network_config": o.GcpManagedNetworkConfig, + "gke_config": o.GkeConfig, + "is_no_public_ip_enabled": o.IsNoPublicIpEnabled, + "location": o.Location, + "managed_services_customer_managed_key_id": o.ManagedServicesCustomerManagedKeyId, + "network_id": o.NetworkId, + "pricing_tier": o.PricingTier, + "private_access_settings_id": o.PrivateAccessSettingsId, + "storage_configuration_id": o.StorageConfigurationId, + "storage_customer_managed_key_id": o.StorageCustomerManagedKeyId, + "workspace_id": o.WorkspaceId, + "workspace_name": o.WorkspaceName, + "workspace_status": o.WorkspaceStatus, + "workspace_status_message": o.WorkspaceStatusMessage, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index a0642b6151..7c5fde1d35 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -12,18 +12,13 @@ package serving_tf import ( "context" - "fmt" - "io" "reflect" "github.com/databricks/databricks-sdk-go/service/oauth2" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/oauth2_tf" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type Ai21LabsConfig struct { @@ -56,52 +51,16 @@ func (a Ai21LabsConfig) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Ai21LabsConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o Ai21LabsConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Ai21LabsConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Ai21LabsConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Ai21LabsConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Ai21LabsConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Ai21LabsConfig +// only implements ToObjectValue() and Type(). +func (o Ai21LabsConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Ai21LabsConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ai21labs_api_key": o.Ai21labsApiKey, + "ai21labs_api_key_plaintext": o.Ai21labsApiKeyPlaintext, + }) } // Type implements basetypes.ObjectValuable. @@ -152,52 +111,18 @@ func (a AiGatewayConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayConfig +// only implements ToObjectValue() and Type(). +func (o AiGatewayConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "guardrails": o.Guardrails, + "inference_table_config": o.InferenceTableConfig, + "rate_limits": o.RateLimits, + "usage_tracking_config": o.UsageTrackingConfig, + }) } // Type implements basetypes.ObjectValuable. @@ -254,52 +179,18 @@ func (a AiGatewayGuardrailParameters) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayGuardrailParameters{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailParameters) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailParameters) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailParameters) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailParameters) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailParameters) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayGuardrailParameters +// only implements ToObjectValue() and Type(). +func (o AiGatewayGuardrailParameters) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailParameters) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "invalid_keywords": o.InvalidKeywords, + "pii": o.Pii, + "safety": o.Safety, + "valid_topics": o.ValidTopics, + }) } // Type implements basetypes.ObjectValuable. @@ -347,52 +238,15 @@ func (a AiGatewayGuardrailPiiBehavior) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayGuardrailPiiBehavior{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailPiiBehavior) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailPiiBehavior) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailPiiBehavior) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailPiiBehavior) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailPiiBehavior) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayGuardrailPiiBehavior +// only implements ToObjectValue() and Type(). +func (o AiGatewayGuardrailPiiBehavior) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayGuardrailPiiBehavior) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "behavior": o.Behavior, + }) } // Type implements basetypes.ObjectValuable. @@ -431,52 +285,16 @@ func (a AiGatewayGuardrails) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayGuardrails{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayGuardrails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayGuardrails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayGuardrails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayGuardrails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayGuardrails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayGuardrails +// only implements ToObjectValue() and Type(). +func (o AiGatewayGuardrails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayGuardrails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "input": o.Input, + "output": o.Output, + }) } // Type implements basetypes.ObjectValuable. @@ -526,52 +344,18 @@ func (a AiGatewayInferenceTableConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayInferenceTableConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayInferenceTableConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayInferenceTableConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayInferenceTableConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayInferenceTableConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayInferenceTableConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayInferenceTableConfig +// only implements ToObjectValue() and Type(). +func (o AiGatewayInferenceTableConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayInferenceTableConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "enabled": o.Enabled, + "schema_name": o.SchemaName, + "table_name_prefix": o.TableNamePrefix, + }) } // Type implements basetypes.ObjectValuable. @@ -615,52 +399,17 @@ func (a AiGatewayRateLimit) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayRateLimit{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayRateLimit) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayRateLimit) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayRateLimit) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayRateLimit) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayRateLimit) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayRateLimit +// only implements ToObjectValue() and Type(). +func (o AiGatewayRateLimit) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayRateLimit) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "calls": o.Calls, + "key": o.Key, + "renewal_period": o.RenewalPeriod, + }) } // Type implements basetypes.ObjectValuable. @@ -696,52 +445,15 @@ func (a AiGatewayUsageTrackingConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AiGatewayUsageTrackingConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o AiGatewayUsageTrackingConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AiGatewayUsageTrackingConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AiGatewayUsageTrackingConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AiGatewayUsageTrackingConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AiGatewayUsageTrackingConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AiGatewayUsageTrackingConfig +// only implements ToObjectValue() and Type(). +func (o AiGatewayUsageTrackingConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AiGatewayUsageTrackingConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + }) } // Type implements basetypes.ObjectValuable. @@ -804,52 +516,20 @@ func (a AmazonBedrockConfig) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AmazonBedrockConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o AmazonBedrockConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AmazonBedrockConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AmazonBedrockConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AmazonBedrockConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AmazonBedrockConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AmazonBedrockConfig +// only implements ToObjectValue() and Type(). +func (o AmazonBedrockConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AmazonBedrockConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_access_key_id": o.AwsAccessKeyId, + "aws_access_key_id_plaintext": o.AwsAccessKeyIdPlaintext, + "aws_region": o.AwsRegion, + "aws_secret_access_key": o.AwsSecretAccessKey, + "aws_secret_access_key_plaintext": o.AwsSecretAccessKeyPlaintext, + "bedrock_provider": o.BedrockProvider, + }) } // Type implements basetypes.ObjectValuable. @@ -896,52 +576,16 @@ func (a AnthropicConfig) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AnthropicConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o AnthropicConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AnthropicConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AnthropicConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AnthropicConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AnthropicConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AnthropicConfig +// only implements ToObjectValue() and Type(). +func (o AnthropicConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AnthropicConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "anthropic_api_key": o.AnthropicApiKey, + "anthropic_api_key_plaintext": o.AnthropicApiKeyPlaintext, + }) } // Type implements basetypes.ObjectValuable. @@ -985,52 +629,18 @@ func (a AutoCaptureConfigInput) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AutoCaptureConfigInput{} - -// Equal implements basetypes.ObjectValuable. -func (o AutoCaptureConfigInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AutoCaptureConfigInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AutoCaptureConfigInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AutoCaptureConfigInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AutoCaptureConfigInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AutoCaptureConfigInput +// only implements ToObjectValue() and Type(). +func (o AutoCaptureConfigInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AutoCaptureConfigInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "enabled": o.Enabled, + "schema_name": o.SchemaName, + "table_name_prefix": o.TableNamePrefix, + }) } // Type implements basetypes.ObjectValuable. @@ -1077,52 +687,19 @@ func (a AutoCaptureConfigOutput) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AutoCaptureConfigOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o AutoCaptureConfigOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AutoCaptureConfigOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AutoCaptureConfigOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AutoCaptureConfigOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AutoCaptureConfigOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AutoCaptureConfigOutput +// only implements ToObjectValue() and Type(). +func (o AutoCaptureConfigOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AutoCaptureConfigOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog_name": o.CatalogName, + "enabled": o.Enabled, + "schema_name": o.SchemaName, + "state": o.State, + "table_name_prefix": o.TableNamePrefix, + }) } // Type implements basetypes.ObjectValuable. @@ -1163,52 +740,15 @@ func (a AutoCaptureState) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AutoCaptureState{} - -// Equal implements basetypes.ObjectValuable. -func (o AutoCaptureState) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AutoCaptureState) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AutoCaptureState) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AutoCaptureState) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AutoCaptureState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AutoCaptureState +// only implements ToObjectValue() and Type(). +func (o AutoCaptureState) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AutoCaptureState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "payload_table": o.PayloadTable, + }) } // Type implements basetypes.ObjectValuable. @@ -1249,52 +789,16 @@ func (a BuildLogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BuildLogsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o BuildLogsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BuildLogsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BuildLogsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BuildLogsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BuildLogsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BuildLogsRequest +// only implements ToObjectValue() and Type(). +func (o BuildLogsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BuildLogsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "served_model_name": o.ServedModelName, + }) } // Type implements basetypes.ObjectValuable. @@ -1329,52 +833,15 @@ func (a BuildLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BuildLogsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o BuildLogsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BuildLogsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BuildLogsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BuildLogsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BuildLogsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BuildLogsResponse +// only implements ToObjectValue() and Type(). +func (o BuildLogsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BuildLogsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "logs": o.Logs, + }) } // Type implements basetypes.ObjectValuable. @@ -1410,52 +877,16 @@ func (a ChatMessage) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ChatMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o ChatMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ChatMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ChatMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ChatMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ChatMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ChatMessage +// only implements ToObjectValue() and Type(). +func (o ChatMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ChatMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "role": o.Role, + }) } // Type implements basetypes.ObjectValuable. @@ -1501,52 +932,17 @@ func (a CohereConfig) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CohereConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o CohereConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CohereConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CohereConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CohereConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CohereConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CohereConfig +// only implements ToObjectValue() and Type(). +func (o CohereConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CohereConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cohere_api_base": o.CohereApiBase, + "cohere_api_key": o.CohereApiKey, + "cohere_api_key_plaintext": o.CohereApiKeyPlaintext, + }) } // Type implements basetypes.ObjectValuable. @@ -1602,52 +998,20 @@ func (a CreateServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateServingEndpoint{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateServingEndpoint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateServingEndpoint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateServingEndpoint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateServingEndpoint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateServingEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateServingEndpoint +// only implements ToObjectValue() and Type(). +func (o CreateServingEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateServingEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ai_gateway": o.AiGateway, + "config": o.Config, + "name": o.Name, + "rate_limits": o.RateLimits, + "route_optimized": o.RouteOptimized, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -1709,52 +1073,17 @@ func (a DatabricksModelServingConfig) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DatabricksModelServingConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o DatabricksModelServingConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DatabricksModelServingConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DatabricksModelServingConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DatabricksModelServingConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DatabricksModelServingConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DatabricksModelServingConfig +// only implements ToObjectValue() and Type(). +func (o DatabricksModelServingConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DatabricksModelServingConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "databricks_api_token": o.DatabricksApiToken, + "databricks_api_token_plaintext": o.DatabricksApiTokenPlaintext, + "databricks_workspace_url": o.DatabricksWorkspaceUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -1791,58 +1120,23 @@ func (newState *DataframeSplitInput) SyncEffectiveFieldsDuringRead(existingState // SDK values. func (a DataframeSplitInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "columns": reflect.TypeOf(struct{}{}), - "data": reflect.TypeOf(struct{}{}), + "columns": reflect.TypeOf(types.Object{}), + "data": reflect.TypeOf(types.Object{}), "index": reflect.TypeOf(types.Int64{}), } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DataframeSplitInput{} - -// Equal implements basetypes.ObjectValuable. -func (o DataframeSplitInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DataframeSplitInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DataframeSplitInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DataframeSplitInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DataframeSplitInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DataframeSplitInput +// only implements ToObjectValue() and Type(). +func (o DataframeSplitInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DataframeSplitInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "columns": o.Columns, + "data": o.Data, + "index": o.Index, + }) } // Type implements basetypes.ObjectValuable. @@ -1882,52 +1176,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1960,52 +1215,15 @@ func (a DeleteServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteServingEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteServingEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteServingEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteServingEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteServingEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteServingEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteServingEndpointRequest +// only implements ToObjectValue() and Type(). +func (o DeleteServingEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteServingEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2044,52 +1262,17 @@ func (a EmbeddingsV1ResponseEmbeddingElement) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EmbeddingsV1ResponseEmbeddingElement{} - -// Equal implements basetypes.ObjectValuable. -func (o EmbeddingsV1ResponseEmbeddingElement) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EmbeddingsV1ResponseEmbeddingElement) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EmbeddingsV1ResponseEmbeddingElement) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EmbeddingsV1ResponseEmbeddingElement) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EmbeddingsV1ResponseEmbeddingElement) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EmbeddingsV1ResponseEmbeddingElement +// only implements ToObjectValue() and Type(). +func (o EmbeddingsV1ResponseEmbeddingElement) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EmbeddingsV1ResponseEmbeddingElement) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "embedding": o.Embedding, + "index": o.Index, + "object": o.Object, + }) } // Type implements basetypes.ObjectValuable. @@ -2144,52 +1327,19 @@ func (a EndpointCoreConfigInput) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointCoreConfigInput{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointCoreConfigInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointCoreConfigInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointCoreConfigInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointCoreConfigInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointCoreConfigInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointCoreConfigInput +// only implements ToObjectValue() and Type(). +func (o EndpointCoreConfigInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointCoreConfigInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "auto_capture_config": o.AutoCaptureConfig, + "name": o.Name, + "served_entities": o.ServedEntities, + "served_models": o.ServedModels, + "traffic_config": o.TrafficConfig, + }) } // Type implements basetypes.ObjectValuable. @@ -2250,52 +1400,19 @@ func (a EndpointCoreConfigOutput) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointCoreConfigOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointCoreConfigOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointCoreConfigOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointCoreConfigOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointCoreConfigOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointCoreConfigOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointCoreConfigOutput +// only implements ToObjectValue() and Type(). +func (o EndpointCoreConfigOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointCoreConfigOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "auto_capture_config": o.AutoCaptureConfig, + "config_version": o.ConfigVersion, + "served_entities": o.ServedEntities, + "served_models": o.ServedModels, + "traffic_config": o.TrafficConfig, + }) } // Type implements basetypes.ObjectValuable. @@ -2347,52 +1464,16 @@ func (a EndpointCoreConfigSummary) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointCoreConfigSummary{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointCoreConfigSummary) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointCoreConfigSummary) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointCoreConfigSummary) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointCoreConfigSummary) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointCoreConfigSummary +// only implements ToObjectValue() and Type(). +func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointCoreConfigSummary) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "served_entities": o.ServedEntities, + "served_models": o.ServedModels, + }) } // Type implements basetypes.ObjectValuable. @@ -2450,52 +1531,20 @@ func (a EndpointPendingConfig) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointPendingConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointPendingConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointPendingConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointPendingConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointPendingConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointPendingConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointPendingConfig +// only implements ToObjectValue() and Type(). +func (o EndpointPendingConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointPendingConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "auto_capture_config": o.AutoCaptureConfig, + "config_version": o.ConfigVersion, + "served_entities": o.ServedEntities, + "served_models": o.ServedModels, + "start_time": o.StartTime, + "traffic_config": o.TrafficConfig, + }) } // Type implements basetypes.ObjectValuable. @@ -2551,52 +1600,16 @@ func (a EndpointState) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointState{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointState) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointState) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointState) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointState) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointState +// only implements ToObjectValue() and Type(). +func (o EndpointState) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "config_update": o.ConfigUpdate, + "ready": o.Ready, + }) } // Type implements basetypes.ObjectValuable. @@ -2633,52 +1646,16 @@ func (a EndpointTag) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointTag{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointTag) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointTag) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointTag) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointTag) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointTag) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointTag +// only implements ToObjectValue() and Type(). +func (o EndpointTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointTag) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -2715,52 +1692,15 @@ func (a ExportMetricsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExportMetricsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExportMetricsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExportMetricsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExportMetricsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExportMetricsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExportMetricsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExportMetricsRequest +// only implements ToObjectValue() and Type(). +func (o ExportMetricsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExportMetricsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2773,7 +1713,7 @@ func (o ExportMetricsRequest) Type(ctx context.Context) attr.Type { } type ExportMetricsResponse struct { - Contents io.ReadCloser `tfsdk:"-"` + Contents types.Object `tfsdk:"-"` } func (newState *ExportMetricsResponse) SyncEffectiveFieldsDuringCreateOrUpdate(plan ExportMetricsResponse) { @@ -2793,52 +1733,15 @@ func (a ExportMetricsResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExportMetricsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ExportMetricsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExportMetricsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExportMetricsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExportMetricsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExportMetricsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExportMetricsResponse +// only implements ToObjectValue() and Type(). +func (o ExportMetricsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExportMetricsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "contents": o.Contents, + }) } // Type implements basetypes.ObjectValuable. @@ -2906,52 +1809,25 @@ func (a ExternalModel) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExternalModel{} - -// Equal implements basetypes.ObjectValuable. -func (o ExternalModel) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExternalModel) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExternalModel) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExternalModel) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExternalModel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExternalModel +// only implements ToObjectValue() and Type(). +func (o ExternalModel) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExternalModel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ai21labs_config": o.Ai21labsConfig, + "amazon_bedrock_config": o.AmazonBedrockConfig, + "anthropic_config": o.AnthropicConfig, + "cohere_config": o.CohereConfig, + "databricks_model_serving_config": o.DatabricksModelServingConfig, + "google_cloud_vertex_ai_config": o.GoogleCloudVertexAiConfig, + "name": o.Name, + "openai_config": o.OpenaiConfig, + "palm_config": o.PalmConfig, + "provider": o.Provider, + "task": o.Task, + }) } // Type implements basetypes.ObjectValuable. @@ -3015,52 +1891,17 @@ func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExternalModelUsageElement{} - -// Equal implements basetypes.ObjectValuable. -func (o ExternalModelUsageElement) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExternalModelUsageElement) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExternalModelUsageElement) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExternalModelUsageElement) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExternalModelUsageElement) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExternalModelUsageElement +// only implements ToObjectValue() and Type(). +func (o ExternalModelUsageElement) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExternalModelUsageElement) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "completion_tokens": o.CompletionTokens, + "prompt_tokens": o.PromptTokens, + "total_tokens": o.TotalTokens, + }) } // Type implements basetypes.ObjectValuable. @@ -3102,52 +1943,18 @@ func (a FoundationModel) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FoundationModel{} - -// Equal implements basetypes.ObjectValuable. -func (o FoundationModel) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FoundationModel) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FoundationModel) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FoundationModel) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FoundationModel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FoundationModel +// only implements ToObjectValue() and Type(). +func (o FoundationModel) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FoundationModel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "display_name": o.DisplayName, + "docs": o.Docs, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -3186,52 +1993,15 @@ func (a GetOpenApiRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetOpenApiRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetOpenApiRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetOpenApiRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetOpenApiRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetOpenApiRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetOpenApiRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetOpenApiRequest +// only implements ToObjectValue() and Type(). +func (o GetOpenApiRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetOpenApiRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -3260,57 +2030,18 @@ func (newState *GetOpenApiResponse) SyncEffectiveFieldsDuringRead(existingState // retrieve the type information of the elements in complex fields at runtime. The values of the map // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a GetOpenApiResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetOpenApiResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetOpenApiResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetOpenApiResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetOpenApiResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetOpenApiResponse) String() string { - return fmt.Sprintf("%#v", o) +// SDK values. +func (a GetOpenApiResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetOpenApiResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetOpenApiResponse +// only implements ToObjectValue() and Type(). +func (o GetOpenApiResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetOpenApiResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3343,52 +2074,15 @@ func (a GetServingEndpointPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetServingEndpointPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetServingEndpointPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetServingEndpointPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "serving_endpoint_id": o.ServingEndpointId, + }) } // Type implements basetypes.ObjectValuable. @@ -3424,52 +2118,15 @@ func (a GetServingEndpointPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetServingEndpointPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetServingEndpointPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -3506,52 +2163,15 @@ func (a GetServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetServingEndpointPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetServingEndpointPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetServingEndpointPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "serving_endpoint_id": o.ServingEndpointId, + }) } // Type implements basetypes.ObjectValuable. @@ -3586,52 +2206,15 @@ func (a GetServingEndpointRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetServingEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetServingEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetServingEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetServingEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetServingEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetServingEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetServingEndpointRequest +// only implements ToObjectValue() and Type(). +func (o GetServingEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetServingEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -3690,52 +2273,18 @@ func (a GoogleCloudVertexAiConfig) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GoogleCloudVertexAiConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o GoogleCloudVertexAiConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GoogleCloudVertexAiConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GoogleCloudVertexAiConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GoogleCloudVertexAiConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GoogleCloudVertexAiConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GoogleCloudVertexAiConfig +// only implements ToObjectValue() and Type(). +func (o GoogleCloudVertexAiConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GoogleCloudVertexAiConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "private_key": o.PrivateKey, + "private_key_plaintext": o.PrivateKeyPlaintext, + "project_id": o.ProjectId, + "region": o.Region, + }) } // Type implements basetypes.ObjectValuable. @@ -3774,52 +2323,15 @@ func (a ListEndpointsResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListEndpointsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListEndpointsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListEndpointsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListEndpointsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListEndpointsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListEndpointsResponse +// only implements ToObjectValue() and Type(). +func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListEndpointsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoints": o.Endpoints, + }) } // Type implements basetypes.ObjectValuable. @@ -3860,52 +2372,16 @@ func (a LogsRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LogsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o LogsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LogsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LogsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LogsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LogsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LogsRequest +// only implements ToObjectValue() and Type(). +func (o LogsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LogsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "served_model_name": o.ServedModelName, + }) } // Type implements basetypes.ObjectValuable. @@ -3920,7 +2396,7 @@ func (o LogsRequest) Type(ctx context.Context) attr.Type { type ModelDataPlaneInfo struct { // Information required to query DataPlane API 'query' endpoint. - QueryInfo oauth2.DataPlaneInfo `tfsdk:"query_info" tf:"optional,object"` + QueryInfo types.List `tfsdk:"query_info" tf:"optional,object"` } func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringCreateOrUpdate(plan ModelDataPlaneInfo) { @@ -3942,52 +2418,15 @@ func (a ModelDataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ModelDataPlaneInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ModelDataPlaneInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ModelDataPlaneInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ModelDataPlaneInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ModelDataPlaneInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ModelDataPlaneInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ModelDataPlaneInfo +// only implements ToObjectValue() and Type(). +func (o ModelDataPlaneInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ModelDataPlaneInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query_info": o.QueryInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -4072,52 +2511,25 @@ func (a OpenAiConfig) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OpenAiConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o OpenAiConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OpenAiConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OpenAiConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OpenAiConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OpenAiConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OpenAiConfig +// only implements ToObjectValue() and Type(). +func (o OpenAiConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OpenAiConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "microsoft_entra_client_id": o.MicrosoftEntraClientId, + "microsoft_entra_client_secret": o.MicrosoftEntraClientSecret, + "microsoft_entra_client_secret_plaintext": o.MicrosoftEntraClientSecretPlaintext, + "microsoft_entra_tenant_id": o.MicrosoftEntraTenantId, + "openai_api_base": o.OpenaiApiBase, + "openai_api_key": o.OpenaiApiKey, + "openai_api_key_plaintext": o.OpenaiApiKeyPlaintext, + "openai_api_type": o.OpenaiApiType, + "openai_api_version": o.OpenaiApiVersion, + "openai_deployment_name": o.OpenaiDeploymentName, + "openai_organization": o.OpenaiOrganization, + }) } // Type implements basetypes.ObjectValuable. @@ -4169,52 +2581,16 @@ func (a PaLmConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PaLmConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o PaLmConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PaLmConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PaLmConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PaLmConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PaLmConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PaLmConfig +// only implements ToObjectValue() and Type(). +func (o PaLmConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PaLmConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "palm_api_key": o.PalmApiKey, + "palm_api_key_plaintext": o.PalmApiKeyPlaintext, + }) } // Type implements basetypes.ObjectValuable. @@ -4257,52 +2633,17 @@ func (a PatchServingEndpointTags) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PatchServingEndpointTags{} - -// Equal implements basetypes.ObjectValuable. -func (o PatchServingEndpointTags) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PatchServingEndpointTags) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PatchServingEndpointTags) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PatchServingEndpointTags) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PatchServingEndpointTags +// only implements ToObjectValue() and Type(). +func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PatchServingEndpointTags) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "add_tags": o.AddTags, + "delete_tags": o.DeleteTags, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -4346,52 +2687,17 @@ func (a PayloadTable) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PayloadTable{} - -// Equal implements basetypes.ObjectValuable. -func (o PayloadTable) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PayloadTable) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PayloadTable) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PayloadTable) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PayloadTable) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PayloadTable +// only implements ToObjectValue() and Type(). +func (o PayloadTable) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PayloadTable) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "status": o.Status, + "status_message": o.StatusMessage, + }) } // Type implements basetypes.ObjectValuable. @@ -4447,52 +2753,19 @@ func (a PutAiGatewayRequest) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutAiGatewayRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PutAiGatewayRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutAiGatewayRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutAiGatewayRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutAiGatewayRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutAiGatewayRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutAiGatewayRequest +// only implements ToObjectValue() and Type(). +func (o PutAiGatewayRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutAiGatewayRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "guardrails": o.Guardrails, + "inference_table_config": o.InferenceTableConfig, + "name": o.Name, + "rate_limits": o.RateLimits, + "usage_tracking_config": o.UsageTrackingConfig, + }) } // Type implements basetypes.ObjectValuable. @@ -4554,52 +2827,18 @@ func (a PutAiGatewayResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutAiGatewayResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PutAiGatewayResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutAiGatewayResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutAiGatewayResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutAiGatewayResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutAiGatewayResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutAiGatewayResponse +// only implements ToObjectValue() and Type(). +func (o PutAiGatewayResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutAiGatewayResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "guardrails": o.Guardrails, + "inference_table_config": o.InferenceTableConfig, + "rate_limits": o.RateLimits, + "usage_tracking_config": o.UsageTrackingConfig, + }) } // Type implements basetypes.ObjectValuable. @@ -4650,52 +2889,16 @@ func (a PutRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o PutRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutRequest +// only implements ToObjectValue() and Type(). +func (o PutRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "rate_limits": o.RateLimits, + }) } // Type implements basetypes.ObjectValuable. @@ -4734,52 +2937,15 @@ func (a PutResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PutResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutResponse +// only implements ToObjectValue() and Type(). +func (o PutResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "rate_limits": o.RateLimits, + }) } // Type implements basetypes.ObjectValuable. @@ -4806,9 +2972,9 @@ type QueryEndpointInput struct { // The input string (or array of strings) field used ONLY for __embeddings // external & foundation model__ serving endpoints and is the only field // (along with extra_params if needed) used by embeddings queries. - Input any `tfsdk:"input" tf:"optional"` + Input types.Object `tfsdk:"input" tf:"optional"` // Tensor-based input in columnar format. - Inputs any `tfsdk:"inputs" tf:"optional"` + Inputs types.Object `tfsdk:"inputs" tf:"optional"` // Tensor-based input in row format. Instances types.List `tfsdk:"instances" tf:"optional"` // The max tokens field used ONLY for __completions__ and __chat external & @@ -4829,7 +2995,7 @@ type QueryEndpointInput struct { // The prompt string (or array of strings) field used ONLY for __completions // external & foundation model__ serving endpoints and should only be used // with other completions query fields. - Prompt any `tfsdk:"prompt" tf:"optional"` + Prompt types.Object `tfsdk:"prompt" tf:"optional"` // The stop sequences field used ONLY for __completions__ and __chat // external & foundation model__ serving endpoints. This is a list of // strings and should only be used with other chat/completions query fields. @@ -4860,61 +3026,37 @@ func (newState *QueryEndpointInput) SyncEffectiveFieldsDuringRead(existingState // SDK values. func (a QueryEndpointInput) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "dataframe_records": reflect.TypeOf(struct{}{}), + "dataframe_records": reflect.TypeOf(types.Object{}), "dataframe_split": reflect.TypeOf(DataframeSplitInput{}), "extra_params": reflect.TypeOf(types.String{}), - "instances": reflect.TypeOf(struct{}{}), + "instances": reflect.TypeOf(types.Object{}), "messages": reflect.TypeOf(ChatMessage{}), "stop": reflect.TypeOf(types.String{}), } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryEndpointInput{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryEndpointInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryEndpointInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryEndpointInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryEndpointInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryEndpointInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryEndpointInput +// only implements ToObjectValue() and Type(). +func (o QueryEndpointInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryEndpointInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dataframe_records": o.DataframeRecords, + "dataframe_split": o.DataframeSplit, + "extra_params": o.ExtraParams, + "input": o.Input, + "inputs": o.Inputs, + "instances": o.Instances, + "max_tokens": o.MaxTokens, + "messages": o.Messages, + "n": o.N, + "name": o.Name, + "prompt": o.Prompt, + "stop": o.Stop, + "stream": o.Stream, + "temperature": o.Temperature, + }) } // Type implements basetypes.ObjectValuable. @@ -4999,57 +3141,28 @@ func (a QueryEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{ "choices": reflect.TypeOf(V1ResponseChoiceElement{}), "data": reflect.TypeOf(EmbeddingsV1ResponseEmbeddingElement{}), - "predictions": reflect.TypeOf(struct{}{}), + "predictions": reflect.TypeOf(types.Object{}), "usage": reflect.TypeOf(ExternalModelUsageElement{}), } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryEndpointResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryEndpointResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryEndpointResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryEndpointResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryEndpointResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryEndpointResponse +// only implements ToObjectValue() and Type(). +func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryEndpointResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "choices": o.Choices, + "created": o.Created, + "data": o.Data, + "id": o.Id, + "model": o.Model, + "object": o.Object, + "predictions": o.Predictions, + "served-model-name": o.ServedModelName, + "usage": o.Usage, + }) } // Type implements basetypes.ObjectValuable. @@ -5099,60 +3212,25 @@ func (newState *RateLimit) SyncEffectiveFieldsDuringRead(existingState RateLimit // GetComplexFieldTypes returns a map of the types of elements in complex fields in RateLimit. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a RateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RateLimit{} - -// Equal implements basetypes.ObjectValuable. -func (o RateLimit) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RateLimit) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RateLimit) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RateLimit) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a RateLimit) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o RateLimit) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RateLimit +// only implements ToObjectValue() and Type(). +func (o RateLimit) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RateLimit) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "calls": o.Calls, + "key": o.Key, + "renewal_period": o.RenewalPeriod, + }) } // Type implements basetypes.ObjectValuable. @@ -5191,52 +3269,16 @@ func (a Route) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Route{} - -// Equal implements basetypes.ObjectValuable. -func (o Route) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Route) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Route) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Route) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Route) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Route +// only implements ToObjectValue() and Type(). +func (o Route) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Route) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "served_model_name": o.ServedModelName, + "traffic_percentage": o.TrafficPercentage, + }) } // Type implements basetypes.ObjectValuable. @@ -5330,52 +3372,25 @@ func (a ServedEntityInput) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedEntityInput{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedEntityInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedEntityInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedEntityInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedEntityInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedEntityInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedEntityInput +// only implements ToObjectValue() and Type(). +func (o ServedEntityInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedEntityInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "entity_name": o.EntityName, + "entity_version": o.EntityVersion, + "environment_vars": o.EnvironmentVars, + "external_model": o.ExternalModel, + "instance_profile_arn": o.InstanceProfileArn, + "max_provisioned_throughput": o.MaxProvisionedThroughput, + "min_provisioned_throughput": o.MinProvisionedThroughput, + "name": o.Name, + "scale_to_zero_enabled": o.ScaleToZeroEnabled, + "workload_size": o.WorkloadSize, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -5486,52 +3501,29 @@ func (a ServedEntityOutput) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedEntityOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedEntityOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedEntityOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedEntityOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedEntityOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedEntityOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedEntityOutput +// only implements ToObjectValue() and Type(). +func (o ServedEntityOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedEntityOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "creator": o.Creator, + "entity_name": o.EntityName, + "entity_version": o.EntityVersion, + "environment_vars": o.EnvironmentVars, + "external_model": o.ExternalModel, + "foundation_model": o.FoundationModel, + "instance_profile_arn": o.InstanceProfileArn, + "max_provisioned_throughput": o.MaxProvisionedThroughput, + "min_provisioned_throughput": o.MinProvisionedThroughput, + "name": o.Name, + "scale_to_zero_enabled": o.ScaleToZeroEnabled, + "state": o.State, + "workload_size": o.WorkloadSize, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -5607,52 +3599,19 @@ func (a ServedEntitySpec) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedEntitySpec{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedEntitySpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedEntitySpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedEntitySpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedEntitySpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedEntitySpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedEntitySpec +// only implements ToObjectValue() and Type(). +func (o ServedEntitySpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedEntitySpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "entity_name": o.EntityName, + "entity_version": o.EntityVersion, + "external_model": o.ExternalModel, + "foundation_model": o.FoundationModel, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5739,52 +3698,24 @@ func (a ServedModelInput) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedModelInput{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedModelInput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedModelInput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedModelInput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedModelInput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedModelInput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedModelInput +// only implements ToObjectValue() and Type(). +func (o ServedModelInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedModelInput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "environment_vars": o.EnvironmentVars, + "instance_profile_arn": o.InstanceProfileArn, + "max_provisioned_throughput": o.MaxProvisionedThroughput, + "min_provisioned_throughput": o.MinProvisionedThroughput, + "model_name": o.ModelName, + "model_version": o.ModelVersion, + "name": o.Name, + "scale_to_zero_enabled": o.ScaleToZeroEnabled, + "workload_size": o.WorkloadSize, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -5873,52 +3804,25 @@ func (a ServedModelOutput) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedModelOutput{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedModelOutput) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedModelOutput) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedModelOutput) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedModelOutput) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedModelOutput) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedModelOutput +// only implements ToObjectValue() and Type(). +func (o ServedModelOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedModelOutput) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "creator": o.Creator, + "environment_vars": o.EnvironmentVars, + "instance_profile_arn": o.InstanceProfileArn, + "model_name": o.ModelName, + "model_version": o.ModelVersion, + "name": o.Name, + "scale_to_zero_enabled": o.ScaleToZeroEnabled, + "state": o.State, + "workload_size": o.WorkloadSize, + "workload_type": o.WorkloadType, + }) } // Type implements basetypes.ObjectValuable. @@ -5972,52 +3876,17 @@ func (a ServedModelSpec) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedModelSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedModelSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedModelSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedModelSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedModelSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedModelSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedModelSpec +// only implements ToObjectValue() and Type(). +func (o ServedModelSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedModelSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "model_name": o.ModelName, + "model_version": o.ModelVersion, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -6066,52 +3935,16 @@ func (a ServedModelState) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServedModelState{} - -// Equal implements basetypes.ObjectValuable. -func (o ServedModelState) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServedModelState) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServedModelState) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServedModelState) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServedModelState) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServedModelState +// only implements ToObjectValue() and Type(). +func (o ServedModelState) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServedModelState) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "deployment": o.Deployment, + "deployment_state_message": o.DeploymentStateMessage, + }) } // Type implements basetypes.ObjectValuable. @@ -6147,52 +3980,15 @@ func (a ServerLogsResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServerLogsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ServerLogsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServerLogsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServerLogsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServerLogsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServerLogsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServerLogsResponse +// only implements ToObjectValue() and Type(). +func (o ServerLogsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServerLogsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "logs": o.Logs, + }) } // Type implements basetypes.ObjectValuable. @@ -6251,52 +4047,24 @@ func (a ServingEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpoint{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpoint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpoint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpoint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpoint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpoint +// only implements ToObjectValue() and Type(). +func (o ServingEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ai_gateway": o.AiGateway, + "config": o.Config, + "creation_timestamp": o.CreationTimestamp, + "creator": o.Creator, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "name": o.Name, + "state": o.State, + "tags": o.Tags, + "task": o.Task, + }) } // Type implements basetypes.ObjectValuable. @@ -6353,52 +4121,18 @@ func (a ServingEndpointAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o ServingEndpointAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -6445,52 +4179,19 @@ func (a ServingEndpointAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -6568,52 +4269,29 @@ func (a ServingEndpointDetailed) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointDetailed{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointDetailed) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointDetailed) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointDetailed) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointDetailed) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointDetailed) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointDetailed +// only implements ToObjectValue() and Type(). +func (o ServingEndpointDetailed) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointDetailed) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ai_gateway": o.AiGateway, + "config": o.Config, + "creation_timestamp": o.CreationTimestamp, + "creator": o.Creator, + "data_plane_info": o.DataPlaneInfo, + "endpoint_url": o.EndpointUrl, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "name": o.Name, + "pending_config": o.PendingConfig, + "permission_level": o.PermissionLevel, + "route_optimized": o.RouteOptimized, + "state": o.State, + "tags": o.Tags, + "task": o.Task, + }) } // Type implements basetypes.ObjectValuable. @@ -6678,52 +4356,17 @@ func (a ServingEndpointPermission) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointPermission +// only implements ToObjectValue() and Type(). +func (o ServingEndpointPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -6766,52 +4409,17 @@ func (a ServingEndpointPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointPermissions +// only implements ToObjectValue() and Type(). +func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -6850,52 +4458,16 @@ func (a ServingEndpointPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o ServingEndpointPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -6933,52 +4505,16 @@ func (a ServingEndpointPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServingEndpointPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServingEndpointPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServingEndpointPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "serving_endpoint_id": o.ServingEndpointId, + }) } // Type implements basetypes.ObjectValuable. @@ -7017,52 +4553,15 @@ func (a TrafficConfig) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TrafficConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o TrafficConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TrafficConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TrafficConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TrafficConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TrafficConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TrafficConfig +// only implements ToObjectValue() and Type(). +func (o TrafficConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TrafficConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "routes": o.Routes, + }) } // Type implements basetypes.ObjectValuable. @@ -7108,52 +4607,19 @@ func (a V1ResponseChoiceElement) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = V1ResponseChoiceElement{} - -// Equal implements basetypes.ObjectValuable. -func (o V1ResponseChoiceElement) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o V1ResponseChoiceElement) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o V1ResponseChoiceElement) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o V1ResponseChoiceElement) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o V1ResponseChoiceElement) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, V1ResponseChoiceElement +// only implements ToObjectValue() and Type(). +func (o V1ResponseChoiceElement) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o V1ResponseChoiceElement) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "finishReason": o.FinishReason, + "index": o.Index, + "logprobs": o.Logprobs, + "message": o.Message, + "text": o.Text, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 6a4ed0c2e8..4bed86c778 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -12,15 +12,11 @@ package settings_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AibiDashboardEmbeddingAccessPolicy struct { @@ -44,52 +40,15 @@ func (a AibiDashboardEmbeddingAccessPolicy) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AibiDashboardEmbeddingAccessPolicy{} - -// Equal implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicy) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicy) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicy) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicy) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicy) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AibiDashboardEmbeddingAccessPolicy +// only implements ToObjectValue() and Type(). +func (o AibiDashboardEmbeddingAccessPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicy) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_policy_type": o.AccessPolicyType, + }) } // Type implements basetypes.ObjectValuable. @@ -138,52 +97,17 @@ func (a AibiDashboardEmbeddingAccessPolicySetting) GetComplexFieldTypes(ctx cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AibiDashboardEmbeddingAccessPolicySetting{} - -// Equal implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicySetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicySetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicySetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicySetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicySetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AibiDashboardEmbeddingAccessPolicySetting +// only implements ToObjectValue() and Type(). +func (o AibiDashboardEmbeddingAccessPolicySetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingAccessPolicySetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aibi_dashboard_embedding_access_policy": o.AibiDashboardEmbeddingAccessPolicy, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -222,52 +146,15 @@ func (a AibiDashboardEmbeddingApprovedDomains) GetComplexFieldTypes(ctx context. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AibiDashboardEmbeddingApprovedDomains{} - -// Equal implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomains) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomains) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomains) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomains) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomains) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AibiDashboardEmbeddingApprovedDomains +// only implements ToObjectValue() and Type(). +func (o AibiDashboardEmbeddingApprovedDomains) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomains) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "approved_domains": o.ApprovedDomains, + }) } // Type implements basetypes.ObjectValuable. @@ -318,52 +205,17 @@ func (a AibiDashboardEmbeddingApprovedDomainsSetting) GetComplexFieldTypes(ctx c } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AibiDashboardEmbeddingApprovedDomainsSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomainsSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomainsSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomainsSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomainsSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AibiDashboardEmbeddingApprovedDomainsSetting +// only implements ToObjectValue() and Type(). +func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aibi_dashboard_embedding_approved_domains": o.AibiDashboardEmbeddingApprovedDomains, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -416,52 +268,17 @@ func (a AutomaticClusterUpdateSetting) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AutomaticClusterUpdateSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o AutomaticClusterUpdateSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AutomaticClusterUpdateSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AutomaticClusterUpdateSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AutomaticClusterUpdateSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AutomaticClusterUpdateSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AutomaticClusterUpdateSetting +// only implements ToObjectValue() and Type(). +func (o AutomaticClusterUpdateSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AutomaticClusterUpdateSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "automatic_cluster_update_workspace": o.AutomaticClusterUpdateWorkspace, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -498,52 +315,15 @@ func (a BooleanMessage) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BooleanMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o BooleanMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BooleanMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BooleanMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BooleanMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BooleanMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BooleanMessage +// only implements ToObjectValue() and Type(). +func (o BooleanMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BooleanMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -592,52 +372,19 @@ func (a ClusterAutoRestartMessage) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAutoRestartMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAutoRestartMessage +// only implements ToObjectValue() and Type(). +func (o ClusterAutoRestartMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "can_toggle": o.CanToggle, + "enabled": o.Enabled, + "enablement_details": o.EnablementDetails, + "maintenance_window": o.MaintenanceWindow, + "restart_even_if_no_updates_available": o.RestartEvenIfNoUpdatesAvailable, + }) } // Type implements basetypes.ObjectValuable. @@ -690,52 +437,17 @@ func (a ClusterAutoRestartMessageEnablementDetails) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAutoRestartMessageEnablementDetails{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageEnablementDetails) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageEnablementDetails) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageEnablementDetails) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageEnablementDetails) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageEnablementDetails) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAutoRestartMessageEnablementDetails +// only implements ToObjectValue() and Type(). +func (o ClusterAutoRestartMessageEnablementDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageEnablementDetails) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "forced_for_compliance_mode": o.ForcedForComplianceMode, + "unavailable_for_disabled_entitlement": o.UnavailableForDisabledEntitlement, + "unavailable_for_non_enterprise_tier": o.UnavailableForNonEnterpriseTier, + }) } // Type implements basetypes.ObjectValuable. @@ -772,52 +484,15 @@ func (a ClusterAutoRestartMessageMaintenanceWindow) GetComplexFieldTypes(ctx con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAutoRestartMessageMaintenanceWindow{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindow) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindow) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindow) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindow) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindow) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAutoRestartMessageMaintenanceWindow +// only implements ToObjectValue() and Type(). +func (o ClusterAutoRestartMessageMaintenanceWindow) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindow) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "week_day_based_schedule": o.WeekDayBasedSchedule, + }) } // Type implements basetypes.ObjectValuable. @@ -858,52 +533,17 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetCompl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule +// only implements ToObjectValue() and Type(). +func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "day_of_week": o.DayOfWeek, + "frequency": o.Frequency, + "window_start_time": o.WindowStartTime, + }) } // Type implements basetypes.ObjectValuable. @@ -942,52 +582,16 @@ func (a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) GetComplexFie return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{} - -// Equal implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ClusterAutoRestartMessageMaintenanceWindowWindowStartTime +// only implements ToObjectValue() and Type(). +func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "hours": o.Hours, + "minutes": o.Minutes, + }) } // Type implements basetypes.ObjectValuable. @@ -1027,52 +631,16 @@ func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ComplianceSecurityProfile{} - -// Equal implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfile) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfile) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfile) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfile) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ComplianceSecurityProfile +// only implements ToObjectValue() and Type(). +func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "compliance_standards": o.ComplianceStandards, + "is_enabled": o.IsEnabled, + }) } // Type implements basetypes.ObjectValuable. @@ -1125,52 +693,17 @@ func (a ComplianceSecurityProfileSetting) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ComplianceSecurityProfileSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfileSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfileSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfileSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfileSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfileSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ComplianceSecurityProfileSetting +// only implements ToObjectValue() and Type(). +func (o ComplianceSecurityProfileSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ComplianceSecurityProfileSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "compliance_security_profile_workspace": o.ComplianceSecurityProfileWorkspace, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -1221,52 +754,19 @@ func (a Config) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Config{} - -// Equal implements basetypes.ObjectValuable. -func (o Config) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Config) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Config) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Config) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Config) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Config +// only implements ToObjectValue() and Type(). +func (o Config) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Config) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "email": o.Email, + "generic_webhook": o.GenericWebhook, + "microsoft_teams": o.MicrosoftTeams, + "pagerduty": o.Pagerduty, + "slack": o.Slack, + }) } // Type implements basetypes.ObjectValuable. @@ -1325,52 +825,17 @@ func (a CreateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateIpAccessList{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateIpAccessList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateIpAccessList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateIpAccessList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateIpAccessList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateIpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateIpAccessList +// only implements ToObjectValue() and Type(). +func (o CreateIpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateIpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_addresses": o.IpAddresses, + "label": o.Label, + "list_type": o.ListType, + }) } // Type implements basetypes.ObjectValuable. @@ -1411,52 +876,15 @@ func (a CreateIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateIpAccessListResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateIpAccessListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateIpAccessListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateIpAccessListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateIpAccessListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateIpAccessListResponse +// only implements ToObjectValue() and Type(). +func (o CreateIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_list": o.IpAccessList, + }) } // Type implements basetypes.ObjectValuable. @@ -1499,52 +927,16 @@ func (a CreateNetworkConnectivityConfigRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateNetworkConnectivityConfigRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateNetworkConnectivityConfigRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateNetworkConnectivityConfigRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateNetworkConnectivityConfigRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateNetworkConnectivityConfigRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateNetworkConnectivityConfigRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateNetworkConnectivityConfigRequest +// only implements ToObjectValue() and Type(). +func (o CreateNetworkConnectivityConfigRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateNetworkConnectivityConfigRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "region": o.Region, + }) } // Type implements basetypes.ObjectValuable. @@ -1584,52 +976,16 @@ func (a CreateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateNotificationDestinationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateNotificationDestinationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateNotificationDestinationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateNotificationDestinationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateNotificationDestinationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateNotificationDestinationRequest +// only implements ToObjectValue() and Type(). +func (o CreateNotificationDestinationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "config": o.Config, + "display_name": o.DisplayName, + }) } // Type implements basetypes.ObjectValuable. @@ -1671,52 +1027,17 @@ func (a CreateOboTokenRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateOboTokenRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateOboTokenRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateOboTokenRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateOboTokenRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateOboTokenRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateOboTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateOboTokenRequest +// only implements ToObjectValue() and Type(). +func (o CreateOboTokenRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateOboTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "application_id": o.ApplicationId, + "comment": o.Comment, + "lifetime_seconds": o.LifetimeSeconds, + }) } // Type implements basetypes.ObjectValuable. @@ -1756,52 +1077,16 @@ func (a CreateOboTokenResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateOboTokenResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateOboTokenResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateOboTokenResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateOboTokenResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateOboTokenResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateOboTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateOboTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateOboTokenResponse +// only implements ToObjectValue() and Type(). +func (o CreateOboTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "token_info": o.TokenInfo, + "token_value": o.TokenValue, + }) } // Type implements basetypes.ObjectValuable. @@ -1844,52 +1129,17 @@ func (a CreatePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreatePrivateEndpointRuleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreatePrivateEndpointRuleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreatePrivateEndpointRuleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreatePrivateEndpointRuleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreatePrivateEndpointRuleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreatePrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreatePrivateEndpointRuleRequest +// only implements ToObjectValue() and Type(). +func (o CreatePrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreatePrivateEndpointRuleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_id": o.GroupId, + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "resource_id": o.ResourceId, + }) } // Type implements basetypes.ObjectValuable. @@ -1929,52 +1179,16 @@ func (a CreateTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateTokenRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateTokenRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateTokenRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateTokenRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateTokenRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateTokenRequest +// only implements ToObjectValue() and Type(). +func (o CreateTokenRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "lifetime_seconds": o.LifetimeSeconds, + }) } // Type implements basetypes.ObjectValuable. @@ -2013,52 +1227,16 @@ func (a CreateTokenResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateTokenResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateTokenResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateTokenResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateTokenResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateTokenResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateTokenResponse +// only implements ToObjectValue() and Type(). +func (o CreateTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_info": o.TokenInfo, + "token_value": o.TokenValue, + }) } // Type implements basetypes.ObjectValuable. @@ -2101,52 +1279,16 @@ func (a CspEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CspEnablementAccount{} - -// Equal implements basetypes.ObjectValuable. -func (o CspEnablementAccount) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CspEnablementAccount) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CspEnablementAccount) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CspEnablementAccount) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CspEnablementAccount) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CspEnablementAccount +// only implements ToObjectValue() and Type(). +func (o CspEnablementAccount) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CspEnablementAccount) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "compliance_standards": o.ComplianceStandards, + "is_enforced": o.IsEnforced, + }) } // Type implements basetypes.ObjectValuable. @@ -2199,52 +1341,17 @@ func (a CspEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CspEnablementAccountSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o CspEnablementAccountSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CspEnablementAccountSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CspEnablementAccountSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CspEnablementAccountSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CspEnablementAccountSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CspEnablementAccountSetting +// only implements ToObjectValue() and Type(). +func (o CspEnablementAccountSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CspEnablementAccountSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "csp_enablement_account": o.CspEnablementAccount, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -2307,52 +1414,17 @@ func (a DefaultNamespaceSetting) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DefaultNamespaceSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o DefaultNamespaceSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DefaultNamespaceSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DefaultNamespaceSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DefaultNamespaceSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DefaultNamespaceSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DefaultNamespaceSetting +// only implements ToObjectValue() and Type(). +func (o DefaultNamespaceSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DefaultNamespaceSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + "namespace": o.Namespace, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -2391,52 +1463,15 @@ func (a DeleteAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAccountIpAccessListRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAccountIpAccessListRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAccountIpAccessListRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAccountIpAccessListRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAccountIpAccessListRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAccountIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAccountIpAccessListRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAccountIpAccessListRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAccountIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_list_id": o.IpAccessListId, + }) } // Type implements basetypes.ObjectValuable. @@ -2477,52 +1512,15 @@ func (a DeleteDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDefaultNamespaceSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDefaultNamespaceSettingRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -2563,52 +1561,15 @@ func (a DeleteDefaultNamespaceSettingResponse) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDefaultNamespaceSettingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDefaultNamespaceSettingResponse +// only implements ToObjectValue() and Type(). +func (o DeleteDefaultNamespaceSettingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDefaultNamespaceSettingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -2649,52 +1610,15 @@ func (a DeleteDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDisableLegacyAccessRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDisableLegacyAccessRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -2735,52 +1659,15 @@ func (a DeleteDisableLegacyAccessResponse) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDisableLegacyAccessResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDisableLegacyAccessResponse +// only implements ToObjectValue() and Type(). +func (o DeleteDisableLegacyAccessResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyAccessResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -2821,52 +1708,15 @@ func (a DeleteDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDisableLegacyDbfsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDisableLegacyDbfsRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -2907,52 +1757,15 @@ func (a DeleteDisableLegacyDbfsResponse) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDisableLegacyDbfsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDisableLegacyDbfsResponse +// only implements ToObjectValue() and Type(). +func (o DeleteDisableLegacyDbfsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyDbfsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -2993,52 +1806,15 @@ func (a DeleteDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDisableLegacyFeaturesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDisableLegacyFeaturesRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -3079,52 +1855,15 @@ func (a DeleteDisableLegacyFeaturesResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDisableLegacyFeaturesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDisableLegacyFeaturesResponse +// only implements ToObjectValue() and Type(). +func (o DeleteDisableLegacyFeaturesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDisableLegacyFeaturesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -3159,52 +1898,15 @@ func (a DeleteIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteIpAccessListRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteIpAccessListRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteIpAccessListRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteIpAccessListRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteIpAccessListRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteIpAccessListRequest +// only implements ToObjectValue() and Type(). +func (o DeleteIpAccessListRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_list_id": o.IpAccessListId, + }) } // Type implements basetypes.ObjectValuable. @@ -3239,52 +1941,15 @@ func (a DeleteNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteNetworkConnectivityConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteNetworkConnectivityConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteNetworkConnectivityConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + }) } // Type implements basetypes.ObjectValuable. @@ -3316,52 +1981,13 @@ func (a DeleteNetworkConnectivityConfigurationResponse) GetComplexFieldTypes(ctx return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteNetworkConnectivityConfigurationResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteNetworkConnectivityConfigurationResponse +// only implements ToObjectValue() and Type(). +func (o DeleteNetworkConnectivityConfigurationResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteNetworkConnectivityConfigurationResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3393,52 +2019,15 @@ func (a DeleteNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteNotificationDestinationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteNotificationDestinationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteNotificationDestinationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteNotificationDestinationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteNotificationDestinationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteNotificationDestinationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteNotificationDestinationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3479,52 +2068,15 @@ func (a DeletePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePersonalComputeSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePersonalComputeSettingRequest +// only implements ToObjectValue() and Type(). +func (o DeletePersonalComputeSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -3565,52 +2117,15 @@ func (a DeletePersonalComputeSettingResponse) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePersonalComputeSettingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePersonalComputeSettingResponse +// only implements ToObjectValue() and Type(). +func (o DeletePersonalComputeSettingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePersonalComputeSettingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -3647,52 +2162,16 @@ func (a DeletePrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeletePrivateEndpointRuleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeletePrivateEndpointRuleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeletePrivateEndpointRuleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeletePrivateEndpointRuleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeletePrivateEndpointRuleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeletePrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeletePrivateEndpointRuleRequest +// only implements ToObjectValue() and Type(). +func (o DeletePrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeletePrivateEndpointRuleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "private_endpoint_rule_id": o.PrivateEndpointRuleId, + }) } // Type implements basetypes.ObjectValuable. @@ -3725,52 +2204,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3809,52 +2249,15 @@ func (a DeleteRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRestrictWorkspaceAdminsSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRestrictWorkspaceAdminsSettingRequest +// only implements ToObjectValue() and Type(). +func (o DeleteRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -3895,52 +2298,15 @@ func (a DeleteRestrictWorkspaceAdminsSettingResponse) GetComplexFieldTypes(ctx c return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRestrictWorkspaceAdminsSettingResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRestrictWorkspaceAdminsSettingResponse +// only implements ToObjectValue() and Type(). +func (o DeleteRestrictWorkspaceAdminsSettingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRestrictWorkspaceAdminsSettingResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -3975,52 +2341,15 @@ func (a DeleteTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteTokenManagementRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteTokenManagementRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteTokenManagementRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteTokenManagementRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteTokenManagementRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteTokenManagementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteTokenManagementRequest +// only implements ToObjectValue() and Type(). +func (o DeleteTokenManagementRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteTokenManagementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_id": o.TokenId, + }) } // Type implements basetypes.ObjectValuable. @@ -4069,52 +2398,17 @@ func (a DisableLegacyAccess) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DisableLegacyAccess{} - -// Equal implements basetypes.ObjectValuable. -func (o DisableLegacyAccess) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DisableLegacyAccess) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DisableLegacyAccess) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DisableLegacyAccess) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DisableLegacyAccess) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DisableLegacyAccess +// only implements ToObjectValue() and Type(). +func (o DisableLegacyAccess) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DisableLegacyAccess) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "disable_legacy_access": o.DisableLegacyAccess, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -4167,52 +2461,17 @@ func (a DisableLegacyDbfs) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DisableLegacyDbfs{} - -// Equal implements basetypes.ObjectValuable. -func (o DisableLegacyDbfs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DisableLegacyDbfs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DisableLegacyDbfs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DisableLegacyDbfs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DisableLegacyDbfs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DisableLegacyDbfs +// only implements ToObjectValue() and Type(). +func (o DisableLegacyDbfs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DisableLegacyDbfs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "disable_legacy_dbfs": o.DisableLegacyDbfs, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -4265,52 +2524,17 @@ func (a DisableLegacyFeatures) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DisableLegacyFeatures{} - -// Equal implements basetypes.ObjectValuable. -func (o DisableLegacyFeatures) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DisableLegacyFeatures) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DisableLegacyFeatures) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DisableLegacyFeatures) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DisableLegacyFeatures) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DisableLegacyFeatures +// only implements ToObjectValue() and Type(). +func (o DisableLegacyFeatures) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DisableLegacyFeatures) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "disable_legacy_features": o.DisableLegacyFeatures, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -4350,52 +2574,15 @@ func (a EmailConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EmailConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o EmailConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EmailConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EmailConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EmailConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EmailConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EmailConfig +// only implements ToObjectValue() and Type(). +func (o EmailConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EmailConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "addresses": o.Addresses, + }) } // Type implements basetypes.ObjectValuable. @@ -4429,52 +2616,13 @@ func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Empty{} - -// Equal implements basetypes.ObjectValuable. -func (o Empty) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Empty) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Empty) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Empty) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Empty) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Empty +// only implements ToObjectValue() and Type(). +func (o Empty) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Empty) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4506,52 +2654,15 @@ func (a EnhancedSecurityMonitoring) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnhancedSecurityMonitoring{} - -// Equal implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoring) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoring) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoring) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoring) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoring) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnhancedSecurityMonitoring +// only implements ToObjectValue() and Type(). +func (o EnhancedSecurityMonitoring) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoring) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_enabled": o.IsEnabled, + }) } // Type implements basetypes.ObjectValuable. @@ -4601,52 +2712,17 @@ func (a EnhancedSecurityMonitoringSetting) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnhancedSecurityMonitoringSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoringSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoringSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoringSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoringSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoringSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnhancedSecurityMonitoringSetting +// only implements ToObjectValue() and Type(). +func (o EnhancedSecurityMonitoringSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnhancedSecurityMonitoringSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enhanced_security_monitoring_workspace": o.EnhancedSecurityMonitoringWorkspace, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -4684,52 +2760,15 @@ func (a EsmEnablementAccount) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EsmEnablementAccount{} - -// Equal implements basetypes.ObjectValuable. -func (o EsmEnablementAccount) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EsmEnablementAccount) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EsmEnablementAccount) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EsmEnablementAccount) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EsmEnablementAccount) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EsmEnablementAccount +// only implements ToObjectValue() and Type(). +func (o EsmEnablementAccount) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EsmEnablementAccount) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "is_enforced": o.IsEnforced, + }) } // Type implements basetypes.ObjectValuable. @@ -4779,52 +2818,17 @@ func (a EsmEnablementAccountSetting) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EsmEnablementAccountSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o EsmEnablementAccountSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EsmEnablementAccountSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EsmEnablementAccountSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EsmEnablementAccountSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EsmEnablementAccountSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EsmEnablementAccountSetting +// only implements ToObjectValue() and Type(). +func (o EsmEnablementAccountSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EsmEnablementAccountSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "esm_enablement_account": o.EsmEnablementAccount, + "etag": o.Etag, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -4874,52 +2878,19 @@ func (a ExchangeToken) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExchangeToken{} - -// Equal implements basetypes.ObjectValuable. -func (o ExchangeToken) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExchangeToken) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExchangeToken) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExchangeToken) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExchangeToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExchangeToken +// only implements ToObjectValue() and Type(). +func (o ExchangeToken) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExchangeToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential": o.Credential, + "credentialEolTime": o.CredentialEolTime, + "ownerId": o.OwnerId, + "scopes": o.Scopes, + "tokenType": o.TokenType, + }) } // Type implements basetypes.ObjectValuable. @@ -4968,52 +2939,17 @@ func (a ExchangeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExchangeTokenRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExchangeTokenRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExchangeTokenRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExchangeTokenRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExchangeTokenRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExchangeTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExchangeTokenRequest +// only implements ToObjectValue() and Type(). +func (o ExchangeTokenRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExchangeTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "partitionId": o.PartitionId, + "scopes": o.Scopes, + "tokenType": o.TokenType, + }) } // Type implements basetypes.ObjectValuable. @@ -5057,52 +2993,15 @@ func (a ExchangeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExchangeTokenResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ExchangeTokenResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExchangeTokenResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExchangeTokenResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExchangeTokenResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExchangeTokenResponse +// only implements ToObjectValue() and Type(). +func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExchangeTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "values": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -5141,62 +3040,25 @@ func (a FetchIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = FetchIpAccessListResponse{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, FetchIpAccessListResponse +// only implements ToObjectValue() and Type(). +func (o FetchIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "ip_access_list": o.IpAccessList, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o FetchIpAccessListResponse) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.Type(ctx), - }, - }, +// Type implements basetypes.ObjectValuable. +func (o FetchIpAccessListResponse) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.Type(ctx), + }, + }, } } @@ -5232,52 +3094,20 @@ func (a GenericWebhookConfig) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GenericWebhookConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o GenericWebhookConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GenericWebhookConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GenericWebhookConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GenericWebhookConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GenericWebhookConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GenericWebhookConfig +// only implements ToObjectValue() and Type(). +func (o GenericWebhookConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GenericWebhookConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "password": o.Password, + "password_set": o.PasswordSet, + "url": o.Url, + "url_set": o.UrlSet, + "username": o.Username, + "username_set": o.UsernameSet, + }) } // Type implements basetypes.ObjectValuable. @@ -5317,52 +3147,15 @@ func (a GetAccountIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAccountIpAccessListRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAccountIpAccessListRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAccountIpAccessListRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAccountIpAccessListRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAccountIpAccessListRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAccountIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAccountIpAccessListRequest +// only implements ToObjectValue() and Type(). +func (o GetAccountIpAccessListRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAccountIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_list_id": o.IpAccessListId, + }) } // Type implements basetypes.ObjectValuable. @@ -5403,52 +3196,15 @@ func (a GetAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldType return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAibiDashboardEmbeddingAccessPolicySettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAibiDashboardEmbeddingAccessPolicySettingRequest +// only implements ToObjectValue() and Type(). +func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingAccessPolicySettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -5489,52 +3245,15 @@ func (a GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFieldT return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAibiDashboardEmbeddingApprovedDomainsSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAibiDashboardEmbeddingApprovedDomainsSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -5575,52 +3294,15 @@ func (a GetAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAutomaticClusterUpdateSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAutomaticClusterUpdateSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAutomaticClusterUpdateSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAutomaticClusterUpdateSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAutomaticClusterUpdateSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAutomaticClusterUpdateSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAutomaticClusterUpdateSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetAutomaticClusterUpdateSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAutomaticClusterUpdateSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -5661,52 +3343,15 @@ func (a GetComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetComplianceSecurityProfileSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetComplianceSecurityProfileSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetComplianceSecurityProfileSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetComplianceSecurityProfileSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetComplianceSecurityProfileSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetComplianceSecurityProfileSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetComplianceSecurityProfileSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetComplianceSecurityProfileSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetComplianceSecurityProfileSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -5747,52 +3392,15 @@ func (a GetCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCspEnablementAccountSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCspEnablementAccountSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCspEnablementAccountSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCspEnablementAccountSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCspEnablementAccountSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCspEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCspEnablementAccountSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetCspEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCspEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -5833,52 +3441,15 @@ func (a GetDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDefaultNamespaceSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDefaultNamespaceSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDefaultNamespaceSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDefaultNamespaceSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDefaultNamespaceSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDefaultNamespaceSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDefaultNamespaceSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -5919,52 +3490,15 @@ func (a GetDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDisableLegacyAccessRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDisableLegacyAccessRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDisableLegacyAccessRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDisableLegacyAccessRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDisableLegacyAccessRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDisableLegacyAccessRequest +// only implements ToObjectValue() and Type(). +func (o GetDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDisableLegacyAccessRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -6005,52 +3539,15 @@ func (a GetDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDisableLegacyDbfsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDisableLegacyDbfsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDisableLegacyDbfsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDisableLegacyDbfsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDisableLegacyDbfsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDisableLegacyDbfsRequest +// only implements ToObjectValue() and Type(). +func (o GetDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDisableLegacyDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -6091,52 +3588,15 @@ func (a GetDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDisableLegacyFeaturesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDisableLegacyFeaturesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDisableLegacyFeaturesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDisableLegacyFeaturesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDisableLegacyFeaturesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDisableLegacyFeaturesRequest +// only implements ToObjectValue() and Type(). +func (o GetDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDisableLegacyFeaturesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -6177,52 +3637,15 @@ func (a GetEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEnhancedSecurityMonitoringSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEnhancedSecurityMonitoringSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEnhancedSecurityMonitoringSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEnhancedSecurityMonitoringSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEnhancedSecurityMonitoringSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEnhancedSecurityMonitoringSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEnhancedSecurityMonitoringSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetEnhancedSecurityMonitoringSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEnhancedSecurityMonitoringSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -6263,52 +3686,15 @@ func (a GetEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEsmEnablementAccountSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEsmEnablementAccountSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEsmEnablementAccountSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEsmEnablementAccountSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEsmEnablementAccountSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEsmEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEsmEnablementAccountSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetEsmEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEsmEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -6343,52 +3729,15 @@ func (a GetIpAccessListRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetIpAccessListRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetIpAccessListRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetIpAccessListRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetIpAccessListRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetIpAccessListRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetIpAccessListRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetIpAccessListRequest +// only implements ToObjectValue() and Type(). +func (o GetIpAccessListRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetIpAccessListRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_list_id": o.IpAccessListId, + }) } // Type implements basetypes.ObjectValuable. @@ -6424,52 +3773,15 @@ func (a GetIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetIpAccessListResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetIpAccessListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetIpAccessListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetIpAccessListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetIpAccessListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetIpAccessListResponse +// only implements ToObjectValue() and Type(). +func (o GetIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_list": o.IpAccessList, + }) } // Type implements basetypes.ObjectValuable. @@ -6507,52 +3819,15 @@ func (a GetIpAccessListsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetIpAccessListsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetIpAccessListsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetIpAccessListsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetIpAccessListsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetIpAccessListsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetIpAccessListsResponse +// only implements ToObjectValue() and Type(). +func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetIpAccessListsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_lists": o.IpAccessLists, + }) } // Type implements basetypes.ObjectValuable. @@ -6589,52 +3864,15 @@ func (a GetNetworkConnectivityConfigurationRequest) GetComplexFieldTypes(ctx con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetNetworkConnectivityConfigurationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetNetworkConnectivityConfigurationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetNetworkConnectivityConfigurationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetNetworkConnectivityConfigurationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetNetworkConnectivityConfigurationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetNetworkConnectivityConfigurationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetNetworkConnectivityConfigurationRequest +// only implements ToObjectValue() and Type(). +func (o GetNetworkConnectivityConfigurationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetNetworkConnectivityConfigurationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + }) } // Type implements basetypes.ObjectValuable. @@ -6668,52 +3906,15 @@ func (a GetNotificationDestinationRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetNotificationDestinationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetNotificationDestinationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetNotificationDestinationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetNotificationDestinationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetNotificationDestinationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetNotificationDestinationRequest +// only implements ToObjectValue() and Type(). +func (o GetNotificationDestinationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -6754,52 +3955,15 @@ func (a GetPersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPersonalComputeSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPersonalComputeSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPersonalComputeSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPersonalComputeSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPersonalComputeSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPersonalComputeSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPersonalComputeSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetPersonalComputeSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPersonalComputeSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -6836,52 +4000,16 @@ func (a GetPrivateEndpointRuleRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetPrivateEndpointRuleRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetPrivateEndpointRuleRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetPrivateEndpointRuleRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetPrivateEndpointRuleRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetPrivateEndpointRuleRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetPrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetPrivateEndpointRuleRequest +// only implements ToObjectValue() and Type(). +func (o GetPrivateEndpointRuleRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetPrivateEndpointRuleRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "private_endpoint_rule_id": o.PrivateEndpointRuleId, + }) } // Type implements basetypes.ObjectValuable. @@ -6923,52 +4051,15 @@ func (a GetRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRestrictWorkspaceAdminsSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRestrictWorkspaceAdminsSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRestrictWorkspaceAdminsSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRestrictWorkspaceAdminsSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRestrictWorkspaceAdminsSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRestrictWorkspaceAdminsSettingRequest +// only implements ToObjectValue() and Type(). +func (o GetRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRestrictWorkspaceAdminsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + }) } // Type implements basetypes.ObjectValuable. @@ -7002,52 +4093,15 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStatusRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStatusRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStatusRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStatusRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStatusRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStatusRequest +// only implements ToObjectValue() and Type(). +func (o GetStatusRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "keys": o.Keys, + }) } // Type implements basetypes.ObjectValuable. @@ -7082,52 +4136,15 @@ func (a GetTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetTokenManagementRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetTokenManagementRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetTokenManagementRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetTokenManagementRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetTokenManagementRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetTokenManagementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetTokenManagementRequest +// only implements ToObjectValue() and Type(). +func (o GetTokenManagementRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetTokenManagementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_id": o.TokenId, + }) } // Type implements basetypes.ObjectValuable. @@ -7163,52 +4180,15 @@ func (a GetTokenPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetTokenPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetTokenPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetTokenPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetTokenPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetTokenPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetTokenPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetTokenPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -7242,56 +4222,19 @@ func (newState *GetTokenResponse) SyncEffectiveFieldsDuringRead(existingState Ge // SDK values. func (a GetTokenResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "token_info": reflect.TypeOf(TokenInfo{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetTokenResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetTokenResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false + "token_info": reflect.TypeOf(TokenInfo{}), } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetTokenResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetTokenResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetTokenResponse) String() string { - return fmt.Sprintf("%#v", o) } -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetTokenResponse +// only implements ToObjectValue() and Type(). +func (o GetTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_info": o.TokenInfo, + }) } // Type implements basetypes.ObjectValuable. @@ -7353,52 +4296,24 @@ func (a IpAccessListInfo) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = IpAccessListInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o IpAccessListInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o IpAccessListInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o IpAccessListInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o IpAccessListInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o IpAccessListInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, IpAccessListInfo +// only implements ToObjectValue() and Type(). +func (o IpAccessListInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o IpAccessListInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "address_count": o.AddressCount, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "enabled": o.Enabled, + "ip_addresses": o.IpAddresses, + "label": o.Label, + "list_id": o.ListId, + "list_type": o.ListType, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -7445,52 +4360,15 @@ func (a ListIpAccessListResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListIpAccessListResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListIpAccessListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListIpAccessListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListIpAccessListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListIpAccessListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListIpAccessListResponse +// only implements ToObjectValue() and Type(). +func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListIpAccessListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "ip_access_lists": o.IpAccessLists, + }) } // Type implements basetypes.ObjectValuable. @@ -7530,52 +4408,16 @@ func (a ListNccAzurePrivateEndpointRulesResponse) GetComplexFieldTypes(ctx conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNccAzurePrivateEndpointRulesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNccAzurePrivateEndpointRulesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNccAzurePrivateEndpointRulesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNccAzurePrivateEndpointRulesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNccAzurePrivateEndpointRulesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNccAzurePrivateEndpointRulesResponse +// only implements ToObjectValue() and Type(). +func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNccAzurePrivateEndpointRulesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "items": o.Items, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7613,52 +4455,15 @@ func (a ListNetworkConnectivityConfigurationsRequest) GetComplexFieldTypes(ctx c return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNetworkConnectivityConfigurationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNetworkConnectivityConfigurationsRequest +// only implements ToObjectValue() and Type(). +func (o ListNetworkConnectivityConfigurationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7696,52 +4501,16 @@ func (a ListNetworkConnectivityConfigurationsResponse) GetComplexFieldTypes(ctx } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNetworkConnectivityConfigurationsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNetworkConnectivityConfigurationsResponse +// only implements ToObjectValue() and Type(). +func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNetworkConnectivityConfigurationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "items": o.Items, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7780,52 +4549,16 @@ func (a ListNotificationDestinationsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNotificationDestinationsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNotificationDestinationsRequest +// only implements ToObjectValue() and Type(). +func (o ListNotificationDestinationsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7864,52 +4597,16 @@ func (a ListNotificationDestinationsResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNotificationDestinationsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNotificationDestinationsResponse +// only implements ToObjectValue() and Type(). +func (o ListNotificationDestinationsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -7951,52 +4648,17 @@ func (a ListNotificationDestinationsResult) GetComplexFieldTypes(ctx context.Con return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListNotificationDestinationsResult{} - -// Equal implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResult) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResult) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResult) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResult) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListNotificationDestinationsResult +// only implements ToObjectValue() and Type(). +func (o ListNotificationDestinationsResult) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListNotificationDestinationsResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "destination_type": o.DestinationType, + "display_name": o.DisplayName, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -8035,52 +4697,16 @@ func (a ListPrivateEndpointRulesRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPrivateEndpointRulesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPrivateEndpointRulesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPrivateEndpointRulesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPrivateEndpointRulesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPrivateEndpointRulesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPrivateEndpointRulesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPrivateEndpointRulesRequest +// only implements ToObjectValue() and Type(). +func (o ListPrivateEndpointRulesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPrivateEndpointRulesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -8117,52 +4743,15 @@ func (a ListPublicTokensResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListPublicTokensResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListPublicTokensResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListPublicTokensResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListPublicTokensResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListPublicTokensResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListPublicTokensResponse +// only implements ToObjectValue() and Type(). +func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListPublicTokensResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_infos": o.TokenInfos, + }) } // Type implements basetypes.ObjectValuable. @@ -8201,52 +4790,16 @@ func (a ListTokenManagementRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTokenManagementRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTokenManagementRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTokenManagementRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTokenManagementRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTokenManagementRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTokenManagementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTokenManagementRequest +// only implements ToObjectValue() and Type(). +func (o ListTokenManagementRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTokenManagementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_by_id": o.CreatedById, + "created_by_username": o.CreatedByUsername, + }) } // Type implements basetypes.ObjectValuable. @@ -8284,52 +4837,15 @@ func (a ListTokensResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListTokensResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListTokensResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListTokensResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListTokensResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListTokensResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListTokensResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListTokensResponse +// only implements ToObjectValue() and Type(). +func (o ListTokensResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListTokensResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_infos": o.TokenInfos, + }) } // Type implements basetypes.ObjectValuable. @@ -8367,52 +4883,16 @@ func (a MicrosoftTeamsConfig) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MicrosoftTeamsConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o MicrosoftTeamsConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MicrosoftTeamsConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MicrosoftTeamsConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MicrosoftTeamsConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MicrosoftTeamsConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MicrosoftTeamsConfig +// only implements ToObjectValue() and Type(). +func (o MicrosoftTeamsConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MicrosoftTeamsConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "url": o.Url, + "url_set": o.UrlSet, + }) } // Type implements basetypes.ObjectValuable. @@ -8452,52 +4932,15 @@ func (a NccAwsStableIpRule) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NccAwsStableIpRule{} - -// Equal implements basetypes.ObjectValuable. -func (o NccAwsStableIpRule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NccAwsStableIpRule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NccAwsStableIpRule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NccAwsStableIpRule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NccAwsStableIpRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NccAwsStableIpRule +// only implements ToObjectValue() and Type(). +func (o NccAwsStableIpRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NccAwsStableIpRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "cidr_blocks": o.CidrBlocks, + }) } // Type implements basetypes.ObjectValuable. @@ -8566,52 +5009,24 @@ func (a NccAzurePrivateEndpointRule) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NccAzurePrivateEndpointRule{} - -// Equal implements basetypes.ObjectValuable. -func (o NccAzurePrivateEndpointRule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NccAzurePrivateEndpointRule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NccAzurePrivateEndpointRule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NccAzurePrivateEndpointRule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NccAzurePrivateEndpointRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NccAzurePrivateEndpointRule +// only implements ToObjectValue() and Type(). +func (o NccAzurePrivateEndpointRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NccAzurePrivateEndpointRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "connection_state": o.ConnectionState, + "creation_time": o.CreationTime, + "deactivated": o.Deactivated, + "deactivated_at": o.DeactivatedAt, + "endpoint_name": o.EndpointName, + "group_id": o.GroupId, + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "resource_id": o.ResourceId, + "rule_id": o.RuleId, + "updated_time": o.UpdatedTime, + }) } // Type implements basetypes.ObjectValuable. @@ -8665,52 +5080,17 @@ func (a NccAzureServiceEndpointRule) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NccAzureServiceEndpointRule{} - -// Equal implements basetypes.ObjectValuable. -func (o NccAzureServiceEndpointRule) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NccAzureServiceEndpointRule) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NccAzureServiceEndpointRule) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NccAzureServiceEndpointRule) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NccAzureServiceEndpointRule) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NccAzureServiceEndpointRule +// only implements ToObjectValue() and Type(). +func (o NccAzureServiceEndpointRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NccAzureServiceEndpointRule) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "subnets": o.Subnets, + "target_region": o.TargetRegion, + "target_services": o.TargetServices, + }) } // Type implements basetypes.ObjectValuable. @@ -8760,52 +5140,16 @@ func (a NccEgressConfig) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NccEgressConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o NccEgressConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NccEgressConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NccEgressConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NccEgressConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NccEgressConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NccEgressConfig +// only implements ToObjectValue() and Type(). +func (o NccEgressConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NccEgressConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "default_rules": o.DefaultRules, + "target_rules": o.TargetRules, + }) } // Type implements basetypes.ObjectValuable. @@ -8856,52 +5200,16 @@ func (a NccEgressDefaultRules) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NccEgressDefaultRules{} - -// Equal implements basetypes.ObjectValuable. -func (o NccEgressDefaultRules) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NccEgressDefaultRules) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NccEgressDefaultRules) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NccEgressDefaultRules) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NccEgressDefaultRules) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NccEgressDefaultRules +// only implements ToObjectValue() and Type(). +func (o NccEgressDefaultRules) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NccEgressDefaultRules) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "aws_stable_ip_rule": o.AwsStableIpRule, + "azure_service_endpoint_rule": o.AzureServiceEndpointRule, + }) } // Type implements basetypes.ObjectValuable. @@ -8939,56 +5247,19 @@ func (newState *NccEgressTargetRules) SyncEffectiveFieldsDuringRead(existingStat // SDK values. func (a NccEgressTargetRules) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "azure_private_endpoint_rules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), - } -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NccEgressTargetRules{} - -// Equal implements basetypes.ObjectValuable. -func (o NccEgressTargetRules) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NccEgressTargetRules) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NccEgressTargetRules) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NccEgressTargetRules) String() string { - return fmt.Sprintf("%#v", o) + "azure_private_endpoint_rules": reflect.TypeOf(NccAzurePrivateEndpointRule{}), + } } -// ToObjectValue implements basetypes.ObjectValuable. -func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NccEgressTargetRules +// only implements ToObjectValue() and Type(). +func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NccEgressTargetRules) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "azure_private_endpoint_rules": o.AzurePrivateEndpointRules, + }) } // Type implements basetypes.ObjectValuable. @@ -9044,52 +5315,21 @@ func (a NetworkConnectivityConfiguration) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NetworkConnectivityConfiguration{} - -// Equal implements basetypes.ObjectValuable. -func (o NetworkConnectivityConfiguration) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NetworkConnectivityConfiguration) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NetworkConnectivityConfiguration) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NetworkConnectivityConfiguration) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NetworkConnectivityConfiguration) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NetworkConnectivityConfiguration +// only implements ToObjectValue() and Type(). +func (o NetworkConnectivityConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NetworkConnectivityConfiguration) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "account_id": o.AccountId, + "creation_time": o.CreationTime, + "egress_config": o.EgressConfig, + "name": o.Name, + "network_connectivity_config_id": o.NetworkConnectivityConfigId, + "region": o.Region, + "updated_time": o.UpdatedTime, + }) } // Type implements basetypes.ObjectValuable. @@ -9142,52 +5382,18 @@ func (a NotificationDestination) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NotificationDestination{} - -// Equal implements basetypes.ObjectValuable. -func (o NotificationDestination) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NotificationDestination) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NotificationDestination) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NotificationDestination) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NotificationDestination) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NotificationDestination +// only implements ToObjectValue() and Type(). +func (o NotificationDestination) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NotificationDestination) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "config": o.Config, + "destination_type": o.DestinationType, + "display_name": o.DisplayName, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -9228,52 +5434,16 @@ func (a PagerdutyConfig) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PagerdutyConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o PagerdutyConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PagerdutyConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PagerdutyConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PagerdutyConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PagerdutyConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PagerdutyConfig +// only implements ToObjectValue() and Type(). +func (o PagerdutyConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PagerdutyConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "integration_key": o.IntegrationKey, + "integration_key_set": o.IntegrationKeySet, + }) } // Type implements basetypes.ObjectValuable. @@ -9309,52 +5479,15 @@ func (a PartitionId) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PartitionId{} - -// Equal implements basetypes.ObjectValuable. -func (o PartitionId) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PartitionId) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PartitionId) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PartitionId) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PartitionId) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PartitionId +// only implements ToObjectValue() and Type(). +func (o PartitionId) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PartitionId) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspaceId": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -9394,52 +5527,15 @@ func (a PersonalComputeMessage) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PersonalComputeMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o PersonalComputeMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PersonalComputeMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PersonalComputeMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PersonalComputeMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PersonalComputeMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PersonalComputeMessage +// only implements ToObjectValue() and Type(). +func (o PersonalComputeMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PersonalComputeMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -9489,52 +5585,17 @@ func (a PersonalComputeSetting) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PersonalComputeSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o PersonalComputeSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PersonalComputeSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PersonalComputeSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PersonalComputeSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PersonalComputeSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PersonalComputeSetting +// only implements ToObjectValue() and Type(). +func (o PersonalComputeSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PersonalComputeSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + "personal_compute": o.PersonalCompute, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -9579,52 +5640,18 @@ func (a PublicTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PublicTokenInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o PublicTokenInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PublicTokenInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PublicTokenInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PublicTokenInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PublicTokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PublicTokenInfo +// only implements ToObjectValue() and Type(). +func (o PublicTokenInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PublicTokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "creation_time": o.CreationTime, + "expiry_time": o.ExpiryTime, + "token_id": o.TokenId, + }) } // Type implements basetypes.ObjectValuable. @@ -9677,52 +5704,19 @@ func (a ReplaceIpAccessList) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReplaceIpAccessList{} - -// Equal implements basetypes.ObjectValuable. -func (o ReplaceIpAccessList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReplaceIpAccessList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReplaceIpAccessList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReplaceIpAccessList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReplaceIpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReplaceIpAccessList +// only implements ToObjectValue() and Type(). +func (o ReplaceIpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReplaceIpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + "ip_access_list_id": o.IpAccessListId, + "ip_addresses": o.IpAddresses, + "label": o.Label, + "list_type": o.ListType, + }) } // Type implements basetypes.ObjectValuable. @@ -9760,52 +5754,13 @@ func (a ReplaceResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ReplaceResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ReplaceResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ReplaceResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ReplaceResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ReplaceResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ReplaceResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ReplaceResponse +// only implements ToObjectValue() and Type(). +func (o ReplaceResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ReplaceResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -9836,52 +5791,15 @@ func (a RestrictWorkspaceAdminsMessage) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestrictWorkspaceAdminsMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestrictWorkspaceAdminsMessage +// only implements ToObjectValue() and Type(). +func (o RestrictWorkspaceAdminsMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -9931,52 +5849,17 @@ func (a RestrictWorkspaceAdminsSetting) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestrictWorkspaceAdminsSetting{} - -// Equal implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsSetting) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsSetting) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsSetting) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsSetting) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsSetting) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestrictWorkspaceAdminsSetting +// only implements ToObjectValue() and Type(). +func (o RestrictWorkspaceAdminsSetting) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestrictWorkspaceAdminsSetting) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "etag": o.Etag, + "restrict_workspace_admins": o.RestrictWorkspaceAdmins, + "setting_name": o.SettingName, + }) } // Type implements basetypes.ObjectValuable. @@ -10014,52 +5897,15 @@ func (a RevokeTokenRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RevokeTokenRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RevokeTokenRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RevokeTokenRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RevokeTokenRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RevokeTokenRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RevokeTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RevokeTokenRequest +// only implements ToObjectValue() and Type(). +func (o RevokeTokenRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RevokeTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "token_id": o.TokenId, + }) } // Type implements basetypes.ObjectValuable. @@ -10091,52 +5937,13 @@ func (a RevokeTokenResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RevokeTokenResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RevokeTokenResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RevokeTokenResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RevokeTokenResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RevokeTokenResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RevokeTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RevokeTokenResponse +// only implements ToObjectValue() and Type(). +func (o RevokeTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RevokeTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -10166,52 +5973,13 @@ func (a SetStatusResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetStatusResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetStatusResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetStatusResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetStatusResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetStatusResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetStatusResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetStatusResponse +// only implements ToObjectValue() and Type(). +func (o SetStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetStatusResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -10245,52 +6013,16 @@ func (a SlackConfig) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SlackConfig{} - -// Equal implements basetypes.ObjectValuable. -func (o SlackConfig) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SlackConfig) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SlackConfig) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SlackConfig) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SlackConfig) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SlackConfig +// only implements ToObjectValue() and Type(). +func (o SlackConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SlackConfig) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "url": o.Url, + "url_set": o.UrlSet, + }) } // Type implements basetypes.ObjectValuable. @@ -10325,52 +6057,15 @@ func (a StringMessage) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StringMessage{} - -// Equal implements basetypes.ObjectValuable. -func (o StringMessage) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StringMessage) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StringMessage) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StringMessage) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StringMessage) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StringMessage +// only implements ToObjectValue() and Type(). +func (o StringMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StringMessage) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -10410,52 +6105,18 @@ func (a TokenAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o TokenAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -10502,52 +6163,19 @@ func (a TokenAccessControlResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -10605,52 +6233,23 @@ func (a TokenInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenInfo +// only implements ToObjectValue() and Type(). +func (o TokenInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "created_by_id": o.CreatedById, + "created_by_username": o.CreatedByUsername, + "creation_time": o.CreationTime, + "expiry_time": o.ExpiryTime, + "last_used_day": o.LastUsedDay, + "owner_id": o.OwnerId, + "token_id": o.TokenId, + "workspace_id": o.WorkspaceId, + }) } // Type implements basetypes.ObjectValuable. @@ -10697,52 +6296,17 @@ func (a TokenPermission) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenPermission +// only implements ToObjectValue() and Type(). +func (o TokenPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -10785,52 +6349,17 @@ func (a TokenPermissions) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenPermissions +// only implements ToObjectValue() and Type(). +func (o TokenPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -10869,52 +6398,16 @@ func (a TokenPermissionsDescription) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o TokenPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -10950,52 +6443,15 @@ func (a TokenPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TokenPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TokenPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TokenPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TokenPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TokenPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TokenPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TokenPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + }) } // Type implements basetypes.ObjectValuable. @@ -11042,52 +6498,17 @@ func (a UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetComplexFieldT } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAibiDashboardEmbeddingAccessPolicySettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAibiDashboardEmbeddingAccessPolicySettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11136,52 +6557,17 @@ func (a UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetComplexFie } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11230,52 +6616,17 @@ func (a UpdateAutomaticClusterUpdateSettingRequest) GetComplexFieldTypes(ctx con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAutomaticClusterUpdateSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAutomaticClusterUpdateSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAutomaticClusterUpdateSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAutomaticClusterUpdateSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAutomaticClusterUpdateSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAutomaticClusterUpdateSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAutomaticClusterUpdateSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateAutomaticClusterUpdateSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAutomaticClusterUpdateSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11324,52 +6675,17 @@ func (a UpdateComplianceSecurityProfileSettingRequest) GetComplexFieldTypes(ctx } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateComplianceSecurityProfileSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateComplianceSecurityProfileSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateComplianceSecurityProfileSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateComplianceSecurityProfileSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateComplianceSecurityProfileSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateComplianceSecurityProfileSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateComplianceSecurityProfileSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateComplianceSecurityProfileSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateComplianceSecurityProfileSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11418,52 +6734,17 @@ func (a UpdateCspEnablementAccountSettingRequest) GetComplexFieldTypes(ctx conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCspEnablementAccountSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCspEnablementAccountSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCspEnablementAccountSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCspEnablementAccountSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCspEnablementAccountSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCspEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCspEnablementAccountSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateCspEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCspEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11520,52 +6801,17 @@ func (a UpdateDefaultNamespaceSettingRequest) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateDefaultNamespaceSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateDefaultNamespaceSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateDefaultNamespaceSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateDefaultNamespaceSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateDefaultNamespaceSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateDefaultNamespaceSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateDefaultNamespaceSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateDefaultNamespaceSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11614,52 +6860,17 @@ func (a UpdateDisableLegacyAccessRequest) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateDisableLegacyAccessRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyAccessRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyAccessRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyAccessRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyAccessRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateDisableLegacyAccessRequest +// only implements ToObjectValue() and Type(). +func (o UpdateDisableLegacyAccessRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyAccessRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11708,52 +6919,17 @@ func (a UpdateDisableLegacyDbfsRequest) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateDisableLegacyDbfsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyDbfsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyDbfsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyDbfsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyDbfsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateDisableLegacyDbfsRequest +// only implements ToObjectValue() and Type(). +func (o UpdateDisableLegacyDbfsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyDbfsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11802,52 +6978,17 @@ func (a UpdateDisableLegacyFeaturesRequest) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateDisableLegacyFeaturesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyFeaturesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyFeaturesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyFeaturesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyFeaturesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateDisableLegacyFeaturesRequest +// only implements ToObjectValue() and Type(). +func (o UpdateDisableLegacyFeaturesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateDisableLegacyFeaturesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11896,52 +7037,17 @@ func (a UpdateEnhancedSecurityMonitoringSettingRequest) GetComplexFieldTypes(ctx } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateEnhancedSecurityMonitoringSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateEnhancedSecurityMonitoringSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateEnhancedSecurityMonitoringSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateEnhancedSecurityMonitoringSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateEnhancedSecurityMonitoringSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateEnhancedSecurityMonitoringSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateEnhancedSecurityMonitoringSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateEnhancedSecurityMonitoringSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateEnhancedSecurityMonitoringSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -11990,52 +7096,17 @@ func (a UpdateEsmEnablementAccountSettingRequest) GetComplexFieldTypes(ctx conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateEsmEnablementAccountSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateEsmEnablementAccountSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateEsmEnablementAccountSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateEsmEnablementAccountSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateEsmEnablementAccountSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateEsmEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateEsmEnablementAccountSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateEsmEnablementAccountSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateEsmEnablementAccountSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -12089,52 +7160,19 @@ func (a UpdateIpAccessList) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateIpAccessList{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateIpAccessList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateIpAccessList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateIpAccessList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateIpAccessList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateIpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateIpAccessList +// only implements ToObjectValue() and Type(). +func (o UpdateIpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateIpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + "ip_access_list_id": o.IpAccessListId, + "ip_addresses": o.IpAddresses, + "label": o.Label, + "list_type": o.ListType, + }) } // Type implements basetypes.ObjectValuable. @@ -12181,52 +7219,17 @@ func (a UpdateNotificationDestinationRequest) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateNotificationDestinationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateNotificationDestinationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateNotificationDestinationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateNotificationDestinationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateNotificationDestinationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateNotificationDestinationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateNotificationDestinationRequest +// only implements ToObjectValue() and Type(). +func (o UpdateNotificationDestinationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateNotificationDestinationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "config": o.Config, + "display_name": o.DisplayName, + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -12275,52 +7278,17 @@ func (a UpdatePersonalComputeSettingRequest) GetComplexFieldTypes(ctx context.Co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePersonalComputeSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePersonalComputeSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePersonalComputeSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePersonalComputeSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePersonalComputeSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePersonalComputeSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePersonalComputeSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdatePersonalComputeSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePersonalComputeSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. @@ -12356,52 +7324,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -12444,52 +7373,17 @@ func (a UpdateRestrictWorkspaceAdminsSettingRequest) GetComplexFieldTypes(ctx co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRestrictWorkspaceAdminsSettingRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRestrictWorkspaceAdminsSettingRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRestrictWorkspaceAdminsSettingRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRestrictWorkspaceAdminsSettingRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRestrictWorkspaceAdminsSettingRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRestrictWorkspaceAdminsSettingRequest +// only implements ToObjectValue() and Type(). +func (o UpdateRestrictWorkspaceAdminsSettingRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRestrictWorkspaceAdminsSettingRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allow_missing": o.AllowMissing, + "field_mask": o.FieldMask, + "setting": o.Setting, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 80b2d52bf4..f06778b763 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -12,17 +12,13 @@ package sharing_tf import ( "context" - "fmt" "reflect" "github.com/databricks/databricks-sdk-go/service/catalog" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type CreateProvider struct { @@ -54,52 +50,18 @@ func (a CreateProvider) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateProvider{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateProvider) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateProvider) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateProvider) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateProvider) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateProvider) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateProvider +// only implements ToObjectValue() and Type(). +func (o CreateProvider) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateProvider) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "authentication_type": o.AuthenticationType, + "comment": o.Comment, + "name": o.Name, + "recipient_profile_str": o.RecipientProfileStr, + }) } // Type implements basetypes.ObjectValuable. @@ -159,52 +121,23 @@ func (a CreateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRecipient{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRecipient) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRecipient) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRecipient) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRecipient) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRecipient) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRecipient +// only implements ToObjectValue() and Type(). +func (o CreateRecipient) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRecipient) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "authentication_type": o.AuthenticationType, + "comment": o.Comment, + "data_recipient_global_metastore_id": o.DataRecipientGlobalMetastoreId, + "expiration_time": o.ExpirationTime, + "ip_access_list": o.IpAccessList, + "name": o.Name, + "owner": o.Owner, + "properties_kvpairs": o.PropertiesKvpairs, + "sharing_code": o.SharingCode, + }) } // Type implements basetypes.ObjectValuable. @@ -254,52 +187,17 @@ func (a CreateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateShare{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateShare) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateShare) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateShare) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateShare) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateShare) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateShare +// only implements ToObjectValue() and Type(). +func (o CreateShare) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateShare) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "storage_root": o.StorageRoot, + }) } // Type implements basetypes.ObjectValuable. @@ -336,52 +234,15 @@ func (a DeleteProviderRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteProviderRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteProviderRequest +// only implements ToObjectValue() and Type(). +func (o DeleteProviderRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -416,52 +277,15 @@ func (a DeleteRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRecipientRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRecipientRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRecipientRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRecipientRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRecipientRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRecipientRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRecipientRequest +// only implements ToObjectValue() and Type(). +func (o DeleteRecipientRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRecipientRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -493,52 +317,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -571,52 +356,15 @@ func (a DeleteShareRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteShareRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteShareRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteShareRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteShareRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteShareRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteShareRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteShareRequest +// only implements ToObjectValue() and Type(). +func (o DeleteShareRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteShareRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -651,52 +399,15 @@ func (a GetActivationUrlInfoRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetActivationUrlInfoRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetActivationUrlInfoRequest +// only implements ToObjectValue() and Type(). +func (o GetActivationUrlInfoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activation_url": o.ActivationUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -728,52 +439,13 @@ func (a GetActivationUrlInfoResponse) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetActivationUrlInfoResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetActivationUrlInfoResponse +// only implements ToObjectValue() and Type(). +func (o GetActivationUrlInfoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetActivationUrlInfoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -806,52 +478,15 @@ func (a GetProviderRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetProviderRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetProviderRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetProviderRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetProviderRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetProviderRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetProviderRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetProviderRequest +// only implements ToObjectValue() and Type(). +func (o GetProviderRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetProviderRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -886,52 +521,15 @@ func (a GetRecipientRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRecipientRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRecipientRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRecipientRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRecipientRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRecipientRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRecipientRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRecipientRequest +// only implements ToObjectValue() and Type(). +func (o GetRecipientRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRecipientRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -971,52 +569,16 @@ func (a GetRecipientSharePermissionsResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRecipientSharePermissionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRecipientSharePermissionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRecipientSharePermissionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRecipientSharePermissionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRecipientSharePermissionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRecipientSharePermissionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRecipientSharePermissionsResponse +// only implements ToObjectValue() and Type(). +func (o GetRecipientSharePermissionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRecipientSharePermissionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "permissions_out": o.PermissionsOut, + }) } // Type implements basetypes.ObjectValuable. @@ -1056,52 +618,16 @@ func (a GetShareRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetShareRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetShareRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetShareRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetShareRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetShareRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetShareRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetShareRequest +// only implements ToObjectValue() and Type(). +func (o GetShareRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetShareRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "include_shared_data": o.IncludeSharedData, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1138,52 +664,15 @@ func (a IpAccessList) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = IpAccessList{} - -// Equal implements basetypes.ObjectValuable. -func (o IpAccessList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o IpAccessList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o IpAccessList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o IpAccessList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o IpAccessList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, IpAccessList +// only implements ToObjectValue() and Type(). +func (o IpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o IpAccessList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "allowed_ip_addresses": o.AllowedIpAddresses, + }) } // Type implements basetypes.ObjectValuable. @@ -1225,52 +714,16 @@ func (a ListProviderSharesResponse) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListProviderSharesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListProviderSharesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListProviderSharesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListProviderSharesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListProviderSharesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListProviderSharesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListProviderSharesResponse +// only implements ToObjectValue() and Type(). +func (o ListProviderSharesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListProviderSharesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "shares": o.Shares, + }) } // Type implements basetypes.ObjectValuable. @@ -1321,52 +774,17 @@ func (a ListProvidersRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListProvidersRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListProvidersRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListProvidersRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListProvidersRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListProvidersRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListProvidersRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListProvidersRequest +// only implements ToObjectValue() and Type(). +func (o ListProvidersRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListProvidersRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data_provider_global_metastore_id": o.DataProviderGlobalMetastoreId, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1408,52 +826,16 @@ func (a ListProvidersResponse) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListProvidersResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListProvidersResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListProvidersResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListProvidersResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListProvidersResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListProvidersResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListProvidersResponse +// only implements ToObjectValue() and Type(). +func (o ListProvidersResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListProvidersResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "providers": o.Providers, + }) } // Type implements basetypes.ObjectValuable. @@ -1504,52 +886,17 @@ func (a ListRecipientsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRecipientsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRecipientsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRecipientsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRecipientsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRecipientsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRecipientsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRecipientsRequest +// only implements ToObjectValue() and Type(). +func (o ListRecipientsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRecipientsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data_recipient_global_metastore_id": o.DataRecipientGlobalMetastoreId, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1591,52 +938,16 @@ func (a ListRecipientsResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListRecipientsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListRecipientsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListRecipientsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListRecipientsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListRecipientsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListRecipientsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListRecipientsResponse +// only implements ToObjectValue() and Type(). +func (o ListRecipientsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListRecipientsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "recipients": o.Recipients, + }) } // Type implements basetypes.ObjectValuable. @@ -1686,52 +997,17 @@ func (a ListSharesRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSharesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSharesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSharesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSharesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSharesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSharesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSharesRequest +// only implements ToObjectValue() and Type(). +func (o ListSharesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSharesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "name": o.Name, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1773,52 +1049,16 @@ func (a ListSharesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSharesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSharesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSharesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSharesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSharesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSharesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSharesResponse +// only implements ToObjectValue() and Type(). +func (o ListSharesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSharesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "shares": o.Shares, + }) } // Type implements basetypes.ObjectValuable. @@ -1857,52 +1097,15 @@ func (a Partition) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Partition{} - -// Equal implements basetypes.ObjectValuable. -func (o Partition) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Partition) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Partition) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Partition) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Partition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Partition +// only implements ToObjectValue() and Type(). +func (o Partition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Partition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -1948,52 +1151,18 @@ func (a PartitionValue) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PartitionValue{} - -// Equal implements basetypes.ObjectValuable. -func (o PartitionValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PartitionValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PartitionValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PartitionValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PartitionValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PartitionValue +// only implements ToObjectValue() and Type(). +func (o PartitionValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PartitionValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "op": o.Op, + "recipient_property_key": o.RecipientPropertyKey, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -2034,52 +1203,16 @@ func (a PrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PrivilegeAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PrivilegeAssignment +// only implements ToObjectValue() and Type(). +func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principal": o.Principal, + "privileges": o.Privileges, + }) } // Type implements basetypes.ObjectValuable. @@ -2151,52 +1284,28 @@ func (a ProviderInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ProviderInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ProviderInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ProviderInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ProviderInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ProviderInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ProviderInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ProviderInfo +// only implements ToObjectValue() and Type(). +func (o ProviderInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ProviderInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "authentication_type": o.AuthenticationType, + "cloud": o.Cloud, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "data_provider_global_metastore_id": o.DataProviderGlobalMetastoreId, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "recipient_profile": o.RecipientProfile, + "recipient_profile_str": o.RecipientProfileStr, + "region": o.Region, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -2245,52 +1354,15 @@ func (a ProviderShare) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ProviderShare{} - -// Equal implements basetypes.ObjectValuable. -func (o ProviderShare) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ProviderShare) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ProviderShare) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ProviderShare) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ProviderShare) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ProviderShare +// only implements ToObjectValue() and Type(). +func (o ProviderShare) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ProviderShare) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2371,52 +1443,32 @@ func (a RecipientInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RecipientInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RecipientInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RecipientInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RecipientInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RecipientInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RecipientInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RecipientInfo +// only implements ToObjectValue() and Type(). +func (o RecipientInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RecipientInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activated": o.Activated, + "activation_url": o.ActivationUrl, + "authentication_type": o.AuthenticationType, + "cloud": o.Cloud, + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "data_recipient_global_metastore_id": o.DataRecipientGlobalMetastoreId, + "ip_access_list": o.IpAccessList, + "metastore_id": o.MetastoreId, + "name": o.Name, + "owner": o.Owner, + "properties_kvpairs": o.PropertiesKvpairs, + "region": o.Region, + "sharing_code": o.SharingCode, + "tokens": o.Tokens, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -2477,52 +1529,17 @@ func (a RecipientProfile) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RecipientProfile{} - -// Equal implements basetypes.ObjectValuable. -func (o RecipientProfile) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RecipientProfile) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RecipientProfile) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RecipientProfile) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RecipientProfile) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RecipientProfile +// only implements ToObjectValue() and Type(). +func (o RecipientProfile) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RecipientProfile) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bearer_token": o.BearerToken, + "endpoint": o.Endpoint, + "share_credentials_version": o.ShareCredentialsVersion, + }) } // Type implements basetypes.ObjectValuable. @@ -2571,52 +1588,21 @@ func (a RecipientTokenInfo) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RecipientTokenInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RecipientTokenInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RecipientTokenInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RecipientTokenInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RecipientTokenInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RecipientTokenInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RecipientTokenInfo +// only implements ToObjectValue() and Type(). +func (o RecipientTokenInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RecipientTokenInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activation_url": o.ActivationUrl, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "expiration_time": o.ExpirationTime, + "id": o.Id, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -2657,52 +1643,15 @@ func (a RetrieveTokenRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RetrieveTokenRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RetrieveTokenRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RetrieveTokenRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RetrieveTokenRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RetrieveTokenRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RetrieveTokenRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RetrieveTokenRequest +// only implements ToObjectValue() and Type(). +func (o RetrieveTokenRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RetrieveTokenRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "activation_url": o.ActivationUrl, + }) } // Type implements basetypes.ObjectValuable. @@ -2742,52 +1691,18 @@ func (a RetrieveTokenResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RetrieveTokenResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RetrieveTokenResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RetrieveTokenResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RetrieveTokenResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RetrieveTokenResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RetrieveTokenResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RetrieveTokenResponse +// only implements ToObjectValue() and Type(). +func (o RetrieveTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RetrieveTokenResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bearerToken": o.BearerToken, + "endpoint": o.Endpoint, + "expirationTime": o.ExpirationTime, + "shareCredentialsVersion": o.ShareCredentialsVersion, + }) } // Type implements basetypes.ObjectValuable. @@ -2829,52 +1744,16 @@ func (a RotateRecipientToken) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RotateRecipientToken{} - -// Equal implements basetypes.ObjectValuable. -func (o RotateRecipientToken) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RotateRecipientToken) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RotateRecipientToken) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RotateRecipientToken) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RotateRecipientToken) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RotateRecipientToken +// only implements ToObjectValue() and Type(). +func (o RotateRecipientToken) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RotateRecipientToken) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "existing_token_expire_in_seconds": o.ExistingTokenExpireInSeconds, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -2913,52 +1792,15 @@ func (a SecurablePropertiesKvPairs) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SecurablePropertiesKvPairs{} - -// Equal implements basetypes.ObjectValuable. -func (o SecurablePropertiesKvPairs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SecurablePropertiesKvPairs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SecurablePropertiesKvPairs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SecurablePropertiesKvPairs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SecurablePropertiesKvPairs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SecurablePropertiesKvPairs +// only implements ToObjectValue() and Type(). +func (o SecurablePropertiesKvPairs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SecurablePropertiesKvPairs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "properties": o.Properties, + }) } // Type implements basetypes.ObjectValuable. @@ -3014,52 +1856,24 @@ func (a ShareInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ShareInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ShareInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ShareInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ShareInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ShareInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ShareInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ShareInfo +// only implements ToObjectValue() and Type(). +func (o ShareInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ShareInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "created_at": o.CreatedAt, + "created_by": o.CreatedBy, + "name": o.Name, + "object": o.Objects, + "owner": o.Owner, + "storage_location": o.StorageLocation, + "storage_root": o.StorageRoot, + "updated_at": o.UpdatedAt, + "updated_by": o.UpdatedBy, + }) } // Type implements basetypes.ObjectValuable. @@ -3117,52 +1931,17 @@ func (a SharePermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SharePermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SharePermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SharePermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SharePermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SharePermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SharePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SharePermissionsRequest +// only implements ToObjectValue() and Type(). +func (o SharePermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SharePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "max_results": o.MaxResults, + "name": o.Name, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -3202,52 +1981,16 @@ func (a ShareToPrivilegeAssignment) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ShareToPrivilegeAssignment{} - -// Equal implements basetypes.ObjectValuable. -func (o ShareToPrivilegeAssignment) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ShareToPrivilegeAssignment) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ShareToPrivilegeAssignment) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ShareToPrivilegeAssignment) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ShareToPrivilegeAssignment +// only implements ToObjectValue() and Type(). +func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ShareToPrivilegeAssignment) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "privilege_assignments": o.PrivilegeAssignments, + "share_name": o.ShareName, + }) } // Type implements basetypes.ObjectValuable. @@ -3331,52 +2074,27 @@ func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SharedDataObject{} - -// Equal implements basetypes.ObjectValuable. -func (o SharedDataObject) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SharedDataObject) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SharedDataObject) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SharedDataObject) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SharedDataObject) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SharedDataObject +// only implements ToObjectValue() and Type(). +func (o SharedDataObject) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SharedDataObject) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "added_at": o.AddedAt, + "added_by": o.AddedBy, + "cdf_enabled": o.CdfEnabled, + "comment": o.Comment, + "content": o.Content, + "data_object_type": o.DataObjectType, + "history_data_sharing_status": o.HistoryDataSharingStatus, + "name": o.Name, + "partition": o.Partitions, + "shared_as": o.SharedAs, + "start_version": o.StartVersion, + "status": o.Status, + "string_shared_as": o.StringSharedAs, + }) } // Type implements basetypes.ObjectValuable. @@ -3428,52 +2146,16 @@ func (a SharedDataObjectUpdate) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SharedDataObjectUpdate{} - -// Equal implements basetypes.ObjectValuable. -func (o SharedDataObjectUpdate) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SharedDataObjectUpdate) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SharedDataObjectUpdate) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SharedDataObjectUpdate) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SharedDataObjectUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SharedDataObjectUpdate +// only implements ToObjectValue() and Type(). +func (o SharedDataObjectUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SharedDataObjectUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "action": o.Action, + "data_object": o.DataObject, + }) } // Type implements basetypes.ObjectValuable. @@ -3508,52 +2190,13 @@ func (a UpdatePermissionsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdatePermissionsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdatePermissionsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdatePermissionsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdatePermissionsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdatePermissionsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdatePermissionsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdatePermissionsResponse +// only implements ToObjectValue() and Type(). +func (o UpdatePermissionsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdatePermissionsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3594,52 +2237,19 @@ func (a UpdateProvider) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateProvider{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateProvider) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateProvider) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateProvider) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateProvider) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateProvider) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateProvider +// only implements ToObjectValue() and Type(). +func (o UpdateProvider) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateProvider) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + "recipient_profile_str": o.RecipientProfileStr, + }) } // Type implements basetypes.ObjectValuable. @@ -3695,52 +2305,21 @@ func (a UpdateRecipient) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRecipient{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRecipient) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRecipient) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRecipient) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRecipient) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRecipient) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRecipient +// only implements ToObjectValue() and Type(). +func (o UpdateRecipient) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRecipient) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "expiration_time": o.ExpirationTime, + "ip_access_list": o.IpAccessList, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + "properties_kvpairs": o.PropertiesKvpairs, + }) } // Type implements basetypes.ObjectValuable. @@ -3782,52 +2361,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3871,52 +2411,20 @@ func (a UpdateShare) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateShare{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateShare) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateShare) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateShare) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateShare) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateShare) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateShare +// only implements ToObjectValue() and Type(). +func (o UpdateShare) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateShare) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "comment": o.Comment, + "name": o.Name, + "new_name": o.NewName, + "owner": o.Owner, + "storage_root": o.StorageRoot, + "updates": o.Updates, + }) } // Type implements basetypes.ObjectValuable. @@ -3973,52 +2481,18 @@ func (a UpdateSharePermissions) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateSharePermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateSharePermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateSharePermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateSharePermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateSharePermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateSharePermissions +// only implements ToObjectValue() and Type(). +func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateSharePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "changes": o.Changes, + "max_results": o.MaxResults, + "name": o.Name, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 38e572bc37..1688aec95d 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -12,15 +12,11 @@ package sql_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AccessControl struct { @@ -49,52 +45,17 @@ func (a AccessControl) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AccessControl{} - -// Equal implements basetypes.ObjectValuable. -func (o AccessControl) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AccessControl) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AccessControl) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AccessControl) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AccessControl) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AccessControl +// only implements ToObjectValue() and Type(). +func (o AccessControl) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AccessControl) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -173,52 +134,29 @@ func (a Alert) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Alert{} - -// Equal implements basetypes.ObjectValuable. -func (o Alert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Alert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Alert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Alert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Alert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Alert +// only implements ToObjectValue() and Type(). +func (o Alert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Alert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "condition": o.Condition, + "create_time": o.CreateTime, + "custom_body": o.CustomBody, + "custom_subject": o.CustomSubject, + "display_name": o.DisplayName, + "id": o.Id, + "lifecycle_state": o.LifecycleState, + "notify_on_ok": o.NotifyOnOk, + "owner_user_name": o.OwnerUserName, + "parent_path": o.ParentPath, + "query_id": o.QueryId, + "seconds_to_retrigger": o.SecondsToRetrigger, + "state": o.State, + "trigger_time": o.TriggerTime, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -278,52 +216,18 @@ func (a AlertCondition) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertCondition{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertCondition) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertCondition) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertCondition) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertCondition) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertCondition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertCondition +// only implements ToObjectValue() and Type(). +func (o AlertCondition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertCondition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "empty_result_state": o.EmptyResultState, + "op": o.Op, + "operand": o.Operand, + "threshold": o.Threshold, + }) } // Type implements basetypes.ObjectValuable. @@ -365,52 +269,15 @@ func (a AlertConditionOperand) GetComplexFieldTypes(ctx context.Context) map[str } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertConditionOperand{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertConditionOperand) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertConditionOperand) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertConditionOperand) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertConditionOperand) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertConditionOperand) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertConditionOperand +// only implements ToObjectValue() and Type(). +func (o AlertConditionOperand) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertConditionOperand) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "column": o.Column, + }) } // Type implements basetypes.ObjectValuable. @@ -447,52 +314,15 @@ func (a AlertConditionThreshold) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertConditionThreshold{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertConditionThreshold) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertConditionThreshold) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertConditionThreshold) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertConditionThreshold) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertConditionThreshold) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertConditionThreshold +// only implements ToObjectValue() and Type(). +func (o AlertConditionThreshold) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertConditionThreshold) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -527,52 +357,15 @@ func (a AlertOperandColumn) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertOperandColumn{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertOperandColumn) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertOperandColumn) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertOperandColumn) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertOperandColumn) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertOperandColumn) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertOperandColumn +// only implements ToObjectValue() and Type(). +func (o AlertOperandColumn) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertOperandColumn) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -609,52 +402,17 @@ func (a AlertOperandValue) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertOperandValue{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertOperandValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertOperandValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertOperandValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertOperandValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertOperandValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertOperandValue +// only implements ToObjectValue() and Type(). +func (o AlertOperandValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertOperandValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bool_value": o.BoolValue, + "double_value": o.DoubleValue, + "string_value": o.StringValue, + }) } // Type implements basetypes.ObjectValuable. @@ -693,7 +451,7 @@ type AlertOptions struct { Op types.String `tfsdk:"op" tf:""` // Value used to compare in alert evaluation. Supported types include // strings (eg. 'foobar'), floats (eg. 123.4), and booleans (true). - Value any `tfsdk:"value" tf:""` + Value types.Object `tfsdk:"value" tf:""` } func (newState *AlertOptions) SyncEffectiveFieldsDuringCreateOrUpdate(plan AlertOptions) { @@ -713,52 +471,21 @@ func (a AlertOptions) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertOptions{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertOptions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertOptions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertOptions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertOptions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertOptions +// only implements ToObjectValue() and Type(). +func (o AlertOptions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "column": o.Column, + "custom_body": o.CustomBody, + "custom_subject": o.CustomSubject, + "empty_result_state": o.EmptyResultState, + "muted": o.Muted, + "op": o.Op, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -838,52 +565,27 @@ func (a AlertQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AlertQuery{} - -// Equal implements basetypes.ObjectValuable. -func (o AlertQuery) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AlertQuery) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AlertQuery) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AlertQuery) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AlertQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AlertQuery +// only implements ToObjectValue() and Type(). +func (o AlertQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AlertQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "data_source_id": o.DataSourceId, + "description": o.Description, + "id": o.Id, + "is_archived": o.IsArchived, + "is_draft": o.IsDraft, + "is_safe": o.IsSafe, + "name": o.Name, + "options": o.Options, + "query": o.Query, + "tags": o.Tags, + "updated_at": o.UpdatedAt, + "user_id": o.UserId, + }) } // Type implements basetypes.ObjectValuable. @@ -943,52 +645,18 @@ func (a BaseChunkInfo) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = BaseChunkInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o BaseChunkInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o BaseChunkInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o BaseChunkInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o BaseChunkInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o BaseChunkInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, BaseChunkInfo +// only implements ToObjectValue() and Type(). +func (o BaseChunkInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o BaseChunkInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "byte_count": o.ByteCount, + "chunk_index": o.ChunkIndex, + "row_count": o.RowCount, + "row_offset": o.RowOffset, + }) } // Type implements basetypes.ObjectValuable. @@ -1027,52 +695,15 @@ func (a CancelExecutionRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelExecutionRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelExecutionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelExecutionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelExecutionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelExecutionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelExecutionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelExecutionRequest +// only implements ToObjectValue() and Type(). +func (o CancelExecutionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelExecutionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "statement_id": o.StatementId, + }) } // Type implements basetypes.ObjectValuable. @@ -1104,52 +735,13 @@ func (a CancelExecutionResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CancelExecutionResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CancelExecutionResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CancelExecutionResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CancelExecutionResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CancelExecutionResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CancelExecutionResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CancelExecutionResponse +// only implements ToObjectValue() and Type(). +func (o CancelExecutionResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CancelExecutionResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1184,52 +776,16 @@ func (a Channel) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Channel{} - -// Equal implements basetypes.ObjectValuable. -func (o Channel) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Channel) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Channel) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Channel) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Channel) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Channel +// only implements ToObjectValue() and Type(). +func (o Channel) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Channel) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbsql_version": o.DbsqlVersion, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1267,52 +823,16 @@ func (a ChannelInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ChannelInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ChannelInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ChannelInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ChannelInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ChannelInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ChannelInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ChannelInfo +// only implements ToObjectValue() and Type(). +func (o ChannelInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ChannelInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dbsql_version": o.DbsqlVersion, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1362,52 +882,21 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ColumnInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ColumnInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ColumnInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ColumnInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ColumnInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ColumnInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ColumnInfo +// only implements ToObjectValue() and Type(). +func (o ColumnInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ColumnInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "position": o.Position, + "type_interval_type": o.TypeIntervalType, + "type_name": o.TypeName, + "type_precision": o.TypePrecision, + "type_scale": o.TypeScale, + "type_text": o.TypeText, + }) } // Type implements basetypes.ObjectValuable. @@ -1459,52 +948,19 @@ func (a CreateAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateAlert +// only implements ToObjectValue() and Type(). +func (o CreateAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "options": o.Options, + "parent": o.Parent, + "query_id": o.QueryId, + "rearm": o.Rearm, + }) } // Type implements basetypes.ObjectValuable. @@ -1545,52 +1001,15 @@ func (a CreateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateAlertRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateAlertRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateAlertRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateAlertRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateAlertRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateAlertRequest +// only implements ToObjectValue() and Type(). +func (o CreateAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert": o.Alert, + }) } // Type implements basetypes.ObjectValuable. @@ -1651,52 +1070,22 @@ func (a CreateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateAlertRequestAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateAlertRequestAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateAlertRequestAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateAlertRequestAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateAlertRequestAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateAlertRequestAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateAlertRequestAlert +// only implements ToObjectValue() and Type(). +func (o CreateAlertRequestAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateAlertRequestAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "condition": o.Condition, + "custom_body": o.CustomBody, + "custom_subject": o.CustomSubject, + "display_name": o.DisplayName, + "notify_on_ok": o.NotifyOnOk, + "parent_path": o.ParentPath, + "query_id": o.QueryId, + "seconds_to_retrigger": o.SecondsToRetrigger, + }) } // Type implements basetypes.ObjectValuable. @@ -1740,52 +1129,15 @@ func (a CreateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateQueryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateQueryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateQueryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateQueryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateQueryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateQueryRequest +// only implements ToObjectValue() and Type(). +func (o CreateQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query": o.Query, + }) } // Type implements basetypes.ObjectValuable. @@ -1846,52 +1198,25 @@ func (a CreateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateQueryRequestQuery{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateQueryRequestQuery) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateQueryRequestQuery) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateQueryRequestQuery) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateQueryRequestQuery) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateQueryRequestQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateQueryRequestQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateQueryRequestQuery +// only implements ToObjectValue() and Type(). +func (o CreateQueryRequestQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "apply_auto_limit": o.ApplyAutoLimit, + "catalog": o.Catalog, + "description": o.Description, + "display_name": o.DisplayName, + "parameters": o.Parameters, + "parent_path": o.ParentPath, + "query_text": o.QueryText, + "run_as_mode": o.RunAsMode, + "schema": o.Schema, + "tags": o.Tags, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -1928,7 +1253,7 @@ type CreateQueryVisualizationsLegacyRequest struct { // The options object varies widely from one visualization type to the next // and is unsupported. Databricks does not recommend modifying visualization // settings in JSON. - Options any `tfsdk:"options" tf:""` + Options types.Object `tfsdk:"options" tf:""` // The identifier returned by :method:queries/create QueryId types.String `tfsdk:"query_id" tf:""` // The type of visualization: chart, table, pivot table, and so on. @@ -1952,52 +1277,19 @@ func (a CreateQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateQueryVisualizationsLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateQueryVisualizationsLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateQueryVisualizationsLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateQueryVisualizationsLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateQueryVisualizationsLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateQueryVisualizationsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateQueryVisualizationsLegacyRequest +// only implements ToObjectValue() and Type(). +func (o CreateQueryVisualizationsLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateQueryVisualizationsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "name": o.Name, + "options": o.Options, + "query_id": o.QueryId, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -2036,52 +1328,15 @@ func (a CreateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateVisualizationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateVisualizationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateVisualizationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateVisualizationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateVisualizationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateVisualizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateVisualizationRequest +// only implements ToObjectValue() and Type(). +func (o CreateVisualizationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateVisualizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "visualization": o.Visualization, + }) } // Type implements basetypes.ObjectValuable. @@ -2129,52 +1384,19 @@ func (a CreateVisualizationRequestVisualization) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateVisualizationRequestVisualization{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateVisualizationRequestVisualization) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateVisualizationRequestVisualization) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateVisualizationRequestVisualization) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateVisualizationRequestVisualization) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateVisualizationRequestVisualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateVisualizationRequestVisualization +// only implements ToObjectValue() and Type(). +func (o CreateVisualizationRequestVisualization) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateVisualizationRequestVisualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display_name": o.DisplayName, + "query_id": o.QueryId, + "serialized_options": o.SerializedOptions, + "serialized_query_plan": o.SerializedQueryPlan, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -2274,52 +1496,27 @@ func (a CreateWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateWarehouseRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateWarehouseRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateWarehouseRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateWarehouseRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateWarehouseRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateWarehouseRequest +// only implements ToObjectValue() and Type(). +func (o CreateWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "auto_stop_mins": o.AutoStopMins, + "channel": o.Channel, + "cluster_size": o.ClusterSize, + "creator_name": o.CreatorName, + "enable_photon": o.EnablePhoton, + "enable_serverless_compute": o.EnableServerlessCompute, + "instance_profile_arn": o.InstanceProfileArn, + "max_num_clusters": o.MaxNumClusters, + "min_num_clusters": o.MinNumClusters, + "name": o.Name, + "spot_instance_policy": o.SpotInstancePolicy, + "tags": o.Tags, + "warehouse_type": o.WarehouseType, + }) } // Type implements basetypes.ObjectValuable. @@ -2369,52 +1566,15 @@ func (a CreateWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateWarehouseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateWarehouseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateWarehouseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateWarehouseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateWarehouseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateWarehouseResponse +// only implements ToObjectValue() and Type(). +func (o CreateWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -2462,52 +1622,20 @@ func (a CreateWidget) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateWidget{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateWidget) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateWidget) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateWidget) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateWidget) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateWidget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateWidget +// only implements ToObjectValue() and Type(). +func (o CreateWidget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateWidget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "id": o.Id, + "options": o.Options, + "text": o.Text, + "visualization_id": o.VisualizationId, + "width": o.Width, + }) } // Type implements basetypes.ObjectValuable. @@ -2597,52 +1725,31 @@ func (a Dashboard) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Dashboard{} - -// Equal implements basetypes.ObjectValuable. -func (o Dashboard) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Dashboard) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Dashboard) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Dashboard) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Dashboard) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Dashboard +// only implements ToObjectValue() and Type(). +func (o Dashboard) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Dashboard) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "can_edit": o.CanEdit, + "created_at": o.CreatedAt, + "dashboard_filters_enabled": o.DashboardFiltersEnabled, + "id": o.Id, + "is_archived": o.IsArchived, + "is_draft": o.IsDraft, + "is_favorite": o.IsFavorite, + "name": o.Name, + "options": o.Options, + "parent": o.Parent, + "permission_tier": o.PermissionTier, + "slug": o.Slug, + "tags": o.Tags, + "updated_at": o.UpdatedAt, + "user": o.User, + "user_id": o.UserId, + "widgets": o.Widgets, + }) } // Type implements basetypes.ObjectValuable. @@ -2710,52 +1817,18 @@ func (a DashboardEditContent) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DashboardEditContent{} - -// Equal implements basetypes.ObjectValuable. -func (o DashboardEditContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DashboardEditContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DashboardEditContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DashboardEditContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DashboardEditContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DashboardEditContent +// only implements ToObjectValue() and Type(). +func (o DashboardEditContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DashboardEditContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + "name": o.Name, + "run_as_role": o.RunAsRole, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -2796,52 +1869,15 @@ func (a DashboardOptions) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DashboardOptions{} - -// Equal implements basetypes.ObjectValuable. -func (o DashboardOptions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DashboardOptions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DashboardOptions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DashboardOptions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DashboardOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DashboardOptions +// only implements ToObjectValue() and Type(). +func (o DashboardOptions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DashboardOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "moved_to_trash_at": o.MovedToTrashAt, + }) } // Type implements basetypes.ObjectValuable. @@ -2891,52 +1927,20 @@ func (a DashboardPostContent) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DashboardPostContent{} - -// Equal implements basetypes.ObjectValuable. -func (o DashboardPostContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DashboardPostContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DashboardPostContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DashboardPostContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DashboardPostContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DashboardPostContent +// only implements ToObjectValue() and Type(). +func (o DashboardPostContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DashboardPostContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_filters_enabled": o.DashboardFiltersEnabled, + "is_favorite": o.IsFavorite, + "name": o.Name, + "parent": o.Parent, + "run_as_role": o.RunAsRole, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -3000,52 +2004,23 @@ func (a DataSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DataSource{} - -// Equal implements basetypes.ObjectValuable. -func (o DataSource) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DataSource) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DataSource) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DataSource) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DataSource) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DataSource +// only implements ToObjectValue() and Type(). +func (o DataSource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DataSource) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "name": o.Name, + "pause_reason": o.PauseReason, + "paused": o.Paused, + "supports_auto_limit": o.SupportsAutoLimit, + "syntax": o.Syntax, + "type": o.Type_, + "view_only": o.ViewOnly, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -3088,52 +2063,16 @@ func (a DateRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DateRange{} - -// Equal implements basetypes.ObjectValuable. -func (o DateRange) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DateRange) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DateRange) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DateRange) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DateRange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DateRange +// only implements ToObjectValue() and Type(). +func (o DateRange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DateRange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end": o.End, + "start": o.Start, + }) } // Type implements basetypes.ObjectValuable. @@ -3177,52 +2116,18 @@ func (a DateRangeValue) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DateRangeValue{} - -// Equal implements basetypes.ObjectValuable. -func (o DateRangeValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DateRangeValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DateRangeValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DateRangeValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DateRangeValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DateRangeValue +// only implements ToObjectValue() and Type(). +func (o DateRangeValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DateRangeValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "date_range_value": o.DateRangeValue, + "dynamic_date_range_value": o.DynamicDateRangeValue, + "precision": o.Precision, + "start_day_of_week": o.StartDayOfWeek, + }) } // Type implements basetypes.ObjectValuable. @@ -3266,52 +2171,17 @@ func (a DateValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DateValue{} - -// Equal implements basetypes.ObjectValuable. -func (o DateValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DateValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DateValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DateValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DateValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DateValue +// only implements ToObjectValue() and Type(). +func (o DateValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DateValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "date_value": o.DateValue, + "dynamic_date_value": o.DynamicDateValue, + "precision": o.Precision, + }) } // Type implements basetypes.ObjectValuable. @@ -3347,52 +2217,15 @@ func (a DeleteAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAlertsLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAlertsLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAlertsLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAlertsLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAlertsLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAlertsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAlertsLegacyRequest +// only implements ToObjectValue() and Type(). +func (o DeleteAlertsLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAlertsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_id": o.AlertId, + }) } // Type implements basetypes.ObjectValuable. @@ -3426,52 +2259,15 @@ func (a DeleteDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDashboardRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -3506,52 +2302,15 @@ func (a DeleteDashboardWidgetRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDashboardWidgetRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDashboardWidgetRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDashboardWidgetRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDashboardWidgetRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDashboardWidgetRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDashboardWidgetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDashboardWidgetRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDashboardWidgetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDashboardWidgetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3585,52 +2344,15 @@ func (a DeleteQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteQueriesLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteQueriesLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteQueriesLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteQueriesLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteQueriesLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteQueriesLegacyRequest +// only implements ToObjectValue() and Type(). +func (o DeleteQueriesLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query_id": o.QueryId, + }) } // Type implements basetypes.ObjectValuable. @@ -3665,52 +2387,15 @@ func (a DeleteQueryVisualizationsLegacyRequest) GetComplexFieldTypes(ctx context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteQueryVisualizationsLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteQueryVisualizationsLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteQueryVisualizationsLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteQueryVisualizationsLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteQueryVisualizationsLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteQueryVisualizationsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteQueryVisualizationsLegacyRequest +// only implements ToObjectValue() and Type(). +func (o DeleteQueryVisualizationsLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteQueryVisualizationsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3742,52 +2427,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3819,52 +2465,15 @@ func (a DeleteVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteVisualizationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteVisualizationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteVisualizationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteVisualizationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteVisualizationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteVisualizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteVisualizationRequest +// only implements ToObjectValue() and Type(). +func (o DeleteVisualizationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteVisualizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3899,52 +2508,15 @@ func (a DeleteWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWarehouseRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWarehouseRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWarehouseRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWarehouseRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWarehouseRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWarehouseRequest +// only implements ToObjectValue() and Type(). +func (o DeleteWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -3976,52 +2548,13 @@ func (a DeleteWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteWarehouseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteWarehouseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteWarehouseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteWarehouseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteWarehouseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteWarehouseResponse +// only implements ToObjectValue() and Type(). +func (o DeleteWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4064,52 +2597,19 @@ func (a EditAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o EditAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditAlert +// only implements ToObjectValue() and Type(). +func (o EditAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_id": o.AlertId, + "name": o.Name, + "options": o.Options, + "query_id": o.QueryId, + "rearm": o.Rearm, + }) } // Type implements basetypes.ObjectValuable. @@ -4211,52 +2711,28 @@ func (a EditWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditWarehouseRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o EditWarehouseRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditWarehouseRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditWarehouseRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditWarehouseRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditWarehouseRequest +// only implements ToObjectValue() and Type(). +func (o EditWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "auto_stop_mins": o.AutoStopMins, + "channel": o.Channel, + "cluster_size": o.ClusterSize, + "creator_name": o.CreatorName, + "enable_photon": o.EnablePhoton, + "enable_serverless_compute": o.EnableServerlessCompute, + "id": o.Id, + "instance_profile_arn": o.InstanceProfileArn, + "max_num_clusters": o.MaxNumClusters, + "min_num_clusters": o.MinNumClusters, + "name": o.Name, + "spot_instance_policy": o.SpotInstancePolicy, + "tags": o.Tags, + "warehouse_type": o.WarehouseType, + }) } // Type implements basetypes.ObjectValuable. @@ -4305,52 +2781,13 @@ func (a EditWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EditWarehouseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o EditWarehouseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EditWarehouseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EditWarehouseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EditWarehouseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EditWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EditWarehouseResponse +// only implements ToObjectValue() and Type(). +func (o EditWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EditWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4382,52 +2819,13 @@ func (a Empty) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Empty{} - -// Equal implements basetypes.ObjectValuable. -func (o Empty) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Empty) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Empty) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Empty) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Empty) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Empty +// only implements ToObjectValue() and Type(). +func (o Empty) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Empty) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4460,52 +2858,16 @@ func (a EndpointConfPair) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointConfPair{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointConfPair) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointConfPair) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointConfPair) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointConfPair) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointConfPair) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointConfPair +// only implements ToObjectValue() and Type(). +func (o EndpointConfPair) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointConfPair) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -4552,52 +2914,19 @@ func (a EndpointHealth) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointHealth{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointHealth) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointHealth) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointHealth) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointHealth) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointHealth) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointHealth +// only implements ToObjectValue() and Type(). +func (o EndpointHealth) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointHealth) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "details": o.Details, + "failure_reason": o.FailureReason, + "message": o.Message, + "status": o.Status, + "summary": o.Summary, + }) } // Type implements basetypes.ObjectValuable. @@ -4714,52 +3043,34 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointInfo +// only implements ToObjectValue() and Type(). +func (o EndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "auto_stop_mins": o.AutoStopMins, + "channel": o.Channel, + "cluster_size": o.ClusterSize, + "creator_name": o.CreatorName, + "enable_photon": o.EnablePhoton, + "enable_serverless_compute": o.EnableServerlessCompute, + "health": o.Health, + "id": o.Id, + "instance_profile_arn": o.InstanceProfileArn, + "jdbc_url": o.JdbcUrl, + "max_num_clusters": o.MaxNumClusters, + "min_num_clusters": o.MinNumClusters, + "name": o.Name, + "num_active_sessions": o.NumActiveSessions, + "num_clusters": o.NumClusters, + "odbc_params": o.OdbcParams, + "spot_instance_policy": o.SpotInstancePolicy, + "state": o.State, + "tags": o.Tags, + "warehouse_type": o.WarehouseType, + }) } // Type implements basetypes.ObjectValuable. @@ -4821,52 +3132,16 @@ func (a EndpointTagPair) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointTagPair{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointTagPair) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointTagPair) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointTagPair) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointTagPair) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointTagPair) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointTagPair +// only implements ToObjectValue() and Type(). +func (o EndpointTagPair) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointTagPair) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -4902,52 +3177,15 @@ func (a EndpointTags) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointTags{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointTags) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointTags) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointTags) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointTags) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointTags) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointTags +// only implements ToObjectValue() and Type(). +func (o EndpointTags) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointTags) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "custom_tags": o.CustomTags, + }) } // Type implements basetypes.ObjectValuable. @@ -4990,52 +3228,17 @@ func (a EnumValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EnumValue{} - -// Equal implements basetypes.ObjectValuable. -func (o EnumValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EnumValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EnumValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EnumValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EnumValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EnumValue +// only implements ToObjectValue() and Type(). +func (o EnumValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EnumValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enum_options": o.EnumOptions, + "multi_values_options": o.MultiValuesOptions, + "values": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -5198,52 +3401,25 @@ func (a ExecuteStatementRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExecuteStatementRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExecuteStatementRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExecuteStatementRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExecuteStatementRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExecuteStatementRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExecuteStatementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExecuteStatementRequest +// only implements ToObjectValue() and Type(). +func (o ExecuteStatementRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExecuteStatementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "byte_limit": o.ByteLimit, + "catalog": o.Catalog, + "disposition": o.Disposition, + "format": o.Format, + "on_wait_timeout": o.OnWaitTimeout, + "parameters": o.Parameters, + "row_limit": o.RowLimit, + "schema": o.Schema, + "statement": o.Statement, + "wait_timeout": o.WaitTimeout, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -5319,52 +3495,23 @@ func (a ExternalLink) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExternalLink{} - -// Equal implements basetypes.ObjectValuable. -func (o ExternalLink) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExternalLink) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExternalLink) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExternalLink) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExternalLink) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExternalLink +// only implements ToObjectValue() and Type(). +func (o ExternalLink) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExternalLink) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "byte_count": o.ByteCount, + "chunk_index": o.ChunkIndex, + "expiration": o.Expiration, + "external_link": o.ExternalLink, + "http_headers": o.HttpHeaders, + "next_chunk_index": o.NextChunkIndex, + "next_chunk_internal_link": o.NextChunkInternalLink, + "row_count": o.RowCount, + "row_offset": o.RowOffset, + }) } // Type implements basetypes.ObjectValuable. @@ -5408,52 +3555,15 @@ func (a GetAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAlertRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAlertRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAlertRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAlertRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAlertRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAlertRequest +// only implements ToObjectValue() and Type(). +func (o GetAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -5487,52 +3597,15 @@ func (a GetAlertsLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAlertsLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAlertsLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAlertsLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAlertsLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAlertsLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAlertsLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAlertsLegacyRequest +// only implements ToObjectValue() and Type(). +func (o GetAlertsLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAlertsLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert_id": o.AlertId, + }) } // Type implements basetypes.ObjectValuable. @@ -5566,52 +3639,15 @@ func (a GetDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDashboardRequest +// only implements ToObjectValue() and Type(). +func (o GetDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -5648,61 +3684,25 @@ func (a GetDbsqlPermissionRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetDbsqlPermissionRequest{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetDbsqlPermissionRequest +// only implements ToObjectValue() and Type(). +func (o GetDbsqlPermissionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "objectId": o.ObjectId, + "objectType": o.ObjectType, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o GetDbsqlPermissionRequest) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "objectId": types.StringType, - "objectType": types.StringType, - }, +// Type implements basetypes.ObjectValuable. +func (o GetDbsqlPermissionRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "objectId": types.StringType, + "objectType": types.StringType, + }, } } @@ -5728,52 +3728,15 @@ func (a GetQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetQueriesLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetQueriesLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetQueriesLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetQueriesLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetQueriesLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetQueriesLegacyRequest +// only implements ToObjectValue() and Type(). +func (o GetQueriesLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query_id": o.QueryId, + }) } // Type implements basetypes.ObjectValuable. @@ -5807,52 +3770,15 @@ func (a GetQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetQueryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetQueryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetQueryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetQueryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetQueryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetQueryRequest +// only implements ToObjectValue() and Type(). +func (o GetQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -5891,52 +3817,17 @@ func (a GetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetResponse +// only implements ToObjectValue() and Type(). +func (o GetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -5976,52 +3867,15 @@ func (a GetStatementRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStatementRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStatementRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStatementRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStatementRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStatementRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStatementRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStatementRequest +// only implements ToObjectValue() and Type(). +func (o GetStatementRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStatementRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "statement_id": o.StatementId, + }) } // Type implements basetypes.ObjectValuable. @@ -6058,52 +3912,16 @@ func (a GetStatementResultChunkNRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStatementResultChunkNRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStatementResultChunkNRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStatementResultChunkNRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStatementResultChunkNRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStatementResultChunkNRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStatementResultChunkNRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStatementResultChunkNRequest +// only implements ToObjectValue() and Type(). +func (o GetStatementResultChunkNRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStatementResultChunkNRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "chunk_index": o.ChunkIndex, + "statement_id": o.StatementId, + }) } // Type implements basetypes.ObjectValuable. @@ -6139,52 +3957,15 @@ func (a GetWarehousePermissionLevelsRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWarehousePermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWarehousePermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetWarehousePermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -6220,52 +4001,15 @@ func (a GetWarehousePermissionLevelsResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWarehousePermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWarehousePermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWarehousePermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -6302,52 +4046,15 @@ func (a GetWarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWarehousePermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWarehousePermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWarehousePermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWarehousePermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWarehousePermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWarehousePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWarehousePermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetWarehousePermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWarehousePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -6382,52 +4089,15 @@ func (a GetWarehouseRequest) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWarehouseRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWarehouseRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWarehouseRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWarehouseRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWarehouseRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWarehouseRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWarehouseRequest +// only implements ToObjectValue() and Type(). +func (o GetWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWarehouseRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -6538,52 +4208,34 @@ func (a GetWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWarehouseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWarehouseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWarehouseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWarehouseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWarehouseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWarehouseResponse +// only implements ToObjectValue() and Type(). +func (o GetWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "auto_stop_mins": o.AutoStopMins, + "channel": o.Channel, + "cluster_size": o.ClusterSize, + "creator_name": o.CreatorName, + "enable_photon": o.EnablePhoton, + "enable_serverless_compute": o.EnableServerlessCompute, + "health": o.Health, + "id": o.Id, + "instance_profile_arn": o.InstanceProfileArn, + "jdbc_url": o.JdbcUrl, + "max_num_clusters": o.MaxNumClusters, + "min_num_clusters": o.MinNumClusters, + "name": o.Name, + "num_active_sessions": o.NumActiveSessions, + "num_clusters": o.NumClusters, + "odbc_params": o.OdbcParams, + "spot_instance_policy": o.SpotInstancePolicy, + "state": o.State, + "tags": o.Tags, + "warehouse_type": o.WarehouseType, + }) } // Type implements basetypes.ObjectValuable. @@ -6674,52 +4326,23 @@ func (a GetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceWarehouseConfigResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceWarehouseConfigResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceWarehouseConfigResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceWarehouseConfigResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceWarehouseConfigResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceWarehouseConfigResponse +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceWarehouseConfigResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "channel": o.Channel, + "config_param": o.ConfigParam, + "data_access_config": o.DataAccessConfig, + "enabled_warehouse_types": o.EnabledWarehouseTypes, + "global_param": o.GlobalParam, + "google_service_account": o.GoogleServiceAccount, + "instance_profile_arn": o.InstanceProfileArn, + "security_policy": o.SecurityPolicy, + "sql_configuration_parameters": o.SqlConfigurationParameters, + }) } // Type implements basetypes.ObjectValuable. @@ -6801,52 +4424,25 @@ func (a LegacyAlert) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LegacyAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o LegacyAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LegacyAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LegacyAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LegacyAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LegacyAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LegacyAlert +// only implements ToObjectValue() and Type(). +func (o LegacyAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LegacyAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "id": o.Id, + "last_triggered_at": o.LastTriggeredAt, + "name": o.Name, + "options": o.Options, + "parent": o.Parent, + "query": o.Query, + "rearm": o.Rearm, + "state": o.State, + "updated_at": o.UpdatedAt, + "user": o.User, + }) } // Type implements basetypes.ObjectValuable. @@ -6968,52 +4564,38 @@ func (a LegacyQuery) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LegacyQuery{} - -// Equal implements basetypes.ObjectValuable. -func (o LegacyQuery) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LegacyQuery) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LegacyQuery) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LegacyQuery) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LegacyQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LegacyQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LegacyQuery +// only implements ToObjectValue() and Type(). +func (o LegacyQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "can_edit": o.CanEdit, + "created_at": o.CreatedAt, + "data_source_id": o.DataSourceId, + "description": o.Description, + "id": o.Id, + "is_archived": o.IsArchived, + "is_draft": o.IsDraft, + "is_favorite": o.IsFavorite, + "is_safe": o.IsSafe, + "last_modified_by": o.LastModifiedBy, + "last_modified_by_id": o.LastModifiedById, + "latest_query_data_id": o.LatestQueryDataId, + "name": o.Name, + "options": o.Options, + "parent": o.Parent, + "permission_tier": o.PermissionTier, + "query": o.Query, + "query_hash": o.QueryHash, + "run_as_role": o.RunAsRole, + "tags": o.Tags, + "updated_at": o.UpdatedAt, + "user": o.User, + "user_id": o.UserId, + "visualizations": o.Visualizations, + }) } // Type implements basetypes.ObjectValuable. @@ -7076,7 +4658,7 @@ type LegacyVisualization struct { // The options object varies widely from one visualization type to the next // and is unsupported. Databricks does not recommend modifying visualization // settings in JSON. - Options any `tfsdk:"options" tf:"optional"` + Options types.Object `tfsdk:"options" tf:"optional"` Query types.List `tfsdk:"query" tf:"optional,object"` // The type of visualization: chart, table, pivot table, and so on. @@ -7104,52 +4686,22 @@ func (a LegacyVisualization) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = LegacyVisualization{} - -// Equal implements basetypes.ObjectValuable. -func (o LegacyVisualization) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o LegacyVisualization) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o LegacyVisualization) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o LegacyVisualization) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o LegacyVisualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, LegacyVisualization +// only implements ToObjectValue() and Type(). +func (o LegacyVisualization) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o LegacyVisualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "description": o.Description, + "id": o.Id, + "name": o.Name, + "options": o.Options, + "query": o.Query, + "type": o.Type_, + "updated_at": o.UpdatedAt, + }) } // Type implements basetypes.ObjectValuable. @@ -7194,52 +4746,16 @@ func (a ListAlertsRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAlertsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAlertsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAlertsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAlertsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAlertsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAlertsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAlertsRequest +// only implements ToObjectValue() and Type(). +func (o ListAlertsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAlertsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7277,52 +4793,16 @@ func (a ListAlertsResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAlertsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAlertsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAlertsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAlertsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAlertsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAlertsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAlertsResponse +// only implements ToObjectValue() and Type(). +func (o ListAlertsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAlertsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -7400,52 +4880,28 @@ func (a ListAlertsResponseAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAlertsResponseAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAlertsResponseAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAlertsResponseAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAlertsResponseAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAlertsResponseAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAlertsResponseAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAlertsResponseAlert +// only implements ToObjectValue() and Type(). +func (o ListAlertsResponseAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAlertsResponseAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "condition": o.Condition, + "create_time": o.CreateTime, + "custom_body": o.CustomBody, + "custom_subject": o.CustomSubject, + "display_name": o.DisplayName, + "id": o.Id, + "lifecycle_state": o.LifecycleState, + "notify_on_ok": o.NotifyOnOk, + "owner_user_name": o.OwnerUserName, + "query_id": o.QueryId, + "seconds_to_retrigger": o.SecondsToRetrigger, + "state": o.State, + "trigger_time": o.TriggerTime, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -7501,63 +4957,29 @@ func (a ListDashboardsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListDashboardsRequest{} +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListDashboardsRequest +// only implements ToObjectValue() and Type(). +func (o ListDashboardsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "order": o.Order, + "page": o.Page, + "page_size": o.PageSize, + "q": o.Q, + }) +} -// Equal implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) -} - -// Type implements basetypes.ObjectValuable. -func (o ListDashboardsRequest) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "order": types.StringType, - "page": types.Int64Type, - "page_size": types.Int64Type, - "q": types.StringType, - }, +// Type implements basetypes.ObjectValuable. +func (o ListDashboardsRequest) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "order": types.StringType, + "page": types.Int64Type, + "page_size": types.Int64Type, + "q": types.StringType, + }, } } @@ -7603,52 +5025,18 @@ func (a ListQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQueriesLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQueriesLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQueriesLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQueriesLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQueriesLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQueriesLegacyRequest +// only implements ToObjectValue() and Type(). +func (o ListQueriesLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "order": o.Order, + "page": o.Page, + "page_size": o.PageSize, + "q": o.Q, + }) } // Type implements basetypes.ObjectValuable. @@ -7687,52 +5075,16 @@ func (a ListQueriesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQueriesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQueriesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQueriesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQueriesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQueriesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQueriesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQueriesRequest +// only implements ToObjectValue() and Type(). +func (o ListQueriesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQueriesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7773,52 +5125,17 @@ func (a ListQueriesResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQueriesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQueriesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQueriesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQueriesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQueriesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQueriesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQueriesResponse +// only implements ToObjectValue() and Type(). +func (o ListQueriesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQueriesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "has_next_page": o.HasNextPage, + "next_page_token": o.NextPageToken, + "res": o.Res, + }) } // Type implements basetypes.ObjectValuable. @@ -7870,52 +5187,18 @@ func (a ListQueryHistoryRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQueryHistoryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQueryHistoryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQueryHistoryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQueryHistoryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQueryHistoryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQueryHistoryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQueryHistoryRequest +// only implements ToObjectValue() and Type(). +func (o ListQueryHistoryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQueryHistoryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "filter_by": o.FilterBy, + "include_metrics": o.IncludeMetrics, + "max_results": o.MaxResults, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -7957,52 +5240,16 @@ func (a ListQueryObjectsResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQueryObjectsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQueryObjectsResponse +// only implements ToObjectValue() and Type(). +func (o ListQueryObjectsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -8074,52 +5321,30 @@ func (a ListQueryObjectsResponseQuery) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListQueryObjectsResponseQuery{} - -// Equal implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponseQuery) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponseQuery) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponseQuery) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponseQuery) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponseQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListQueryObjectsResponseQuery +// only implements ToObjectValue() and Type(). +func (o ListQueryObjectsResponseQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListQueryObjectsResponseQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apply_auto_limit": o.ApplyAutoLimit, + "catalog": o.Catalog, + "create_time": o.CreateTime, + "description": o.Description, + "display_name": o.DisplayName, + "id": o.Id, + "last_modifier_user_name": o.LastModifierUserName, + "lifecycle_state": o.LifecycleState, + "owner_user_name": o.OwnerUserName, + "parameters": o.Parameters, + "query_text": o.QueryText, + "run_as_mode": o.RunAsMode, + "schema": o.Schema, + "tags": o.Tags, + "update_time": o.UpdateTime, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -8180,52 +5405,18 @@ func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListResponse +// only implements ToObjectValue() and Type(). +func (o ListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "count": o.Count, + "page": o.Page, + "page_size": o.PageSize, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -8268,52 +5459,17 @@ func (a ListVisualizationsForQueryRequest) GetComplexFieldTypes(ctx context.Cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListVisualizationsForQueryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListVisualizationsForQueryRequest +// only implements ToObjectValue() and Type(). +func (o ListVisualizationsForQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "page_size": o.PageSize, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -8352,52 +5508,16 @@ func (a ListVisualizationsForQueryResponse) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListVisualizationsForQueryResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListVisualizationsForQueryResponse +// only implements ToObjectValue() and Type(). +func (o ListVisualizationsForQueryResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListVisualizationsForQueryResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -8436,52 +5556,15 @@ func (a ListWarehousesRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListWarehousesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListWarehousesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListWarehousesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListWarehousesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListWarehousesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListWarehousesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListWarehousesRequest +// only implements ToObjectValue() and Type(). +func (o ListWarehousesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListWarehousesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "run_as_user_id": o.RunAsUserId, + }) } // Type implements basetypes.ObjectValuable. @@ -8517,52 +5600,15 @@ func (a ListWarehousesResponse) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListWarehousesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListWarehousesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListWarehousesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListWarehousesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListWarehousesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListWarehousesResponse +// only implements ToObjectValue() and Type(). +func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListWarehousesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "warehouses": o.Warehouses, + }) } // Type implements basetypes.ObjectValuable. @@ -8603,52 +5649,17 @@ func (a MultiValuesOptions) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MultiValuesOptions{} - -// Equal implements basetypes.ObjectValuable. -func (o MultiValuesOptions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MultiValuesOptions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MultiValuesOptions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MultiValuesOptions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MultiValuesOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MultiValuesOptions +// only implements ToObjectValue() and Type(). +func (o MultiValuesOptions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MultiValuesOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "prefix": o.Prefix, + "separator": o.Separator, + "suffix": o.Suffix, + }) } // Type implements basetypes.ObjectValuable. @@ -8683,52 +5694,15 @@ func (a NumericValue) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = NumericValue{} - -// Equal implements basetypes.ObjectValuable. -func (o NumericValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o NumericValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o NumericValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o NumericValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o NumericValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, NumericValue +// only implements ToObjectValue() and Type(). +func (o NumericValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o NumericValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -8767,52 +5741,18 @@ func (a OdbcParams) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = OdbcParams{} - -// Equal implements basetypes.ObjectValuable. -func (o OdbcParams) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o OdbcParams) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o OdbcParams) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o OdbcParams) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o OdbcParams) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, OdbcParams +// only implements ToObjectValue() and Type(). +func (o OdbcParams) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o OdbcParams) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "hostname": o.Hostname, + "path": o.Path, + "port": o.Port, + "protocol": o.Protocol, + }) } // Type implements basetypes.ObjectValuable. @@ -8845,7 +5785,7 @@ type Parameter struct { // Parameters can have several different types. Type_ types.String `tfsdk:"type" tf:"optional"` // The default value for this parameter. - Value any `tfsdk:"value" tf:"optional"` + Value types.Object `tfsdk:"value" tf:"optional"` } func (newState *Parameter) SyncEffectiveFieldsDuringCreateOrUpdate(plan Parameter) { @@ -8867,52 +5807,21 @@ func (a Parameter) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Parameter{} - -// Equal implements basetypes.ObjectValuable. -func (o Parameter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Parameter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Parameter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Parameter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Parameter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Parameter +// only implements ToObjectValue() and Type(). +func (o Parameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Parameter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enumOptions": o.EnumOptions, + "multiValuesOptions": o.MultiValuesOptions, + "name": o.Name, + "queryId": o.QueryId, + "title": o.Title, + "type": o.Type_, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -8991,52 +5900,31 @@ func (a Query) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Query{} - -// Equal implements basetypes.ObjectValuable. -func (o Query) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Query) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Query) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Query) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Query) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Query +// only implements ToObjectValue() and Type(). +func (o Query) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Query) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apply_auto_limit": o.ApplyAutoLimit, + "catalog": o.Catalog, + "create_time": o.CreateTime, + "description": o.Description, + "display_name": o.DisplayName, + "id": o.Id, + "last_modifier_user_name": o.LastModifierUserName, + "lifecycle_state": o.LifecycleState, + "owner_user_name": o.OwnerUserName, + "parameters": o.Parameters, + "parent_path": o.ParentPath, + "query_text": o.QueryText, + "run_as_mode": o.RunAsMode, + "schema": o.Schema, + "tags": o.Tags, + "update_time": o.UpdateTime, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -9097,52 +5985,17 @@ func (a QueryBackedValue) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryBackedValue{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryBackedValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryBackedValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryBackedValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryBackedValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryBackedValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryBackedValue +// only implements ToObjectValue() and Type(). +func (o QueryBackedValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryBackedValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "multi_values_options": o.MultiValuesOptions, + "query_id": o.QueryId, + "values": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -9175,7 +6028,7 @@ type QueryEditContent struct { // Exclusively used for storing a list parameter definitions. A parameter is // an object with `title`, `name`, `type`, and `value` properties. The // `value` field here is the default value. It can be overridden at runtime. - Options any `tfsdk:"options" tf:"optional"` + Options types.Object `tfsdk:"options" tf:"optional"` // The text of the query to be run. Query types.String `tfsdk:"query" tf:"optional"` @@ -9207,52 +6060,22 @@ func (a QueryEditContent) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryEditContent{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryEditContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryEditContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryEditContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryEditContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryEditContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryEditContent +// only implements ToObjectValue() and Type(). +func (o QueryEditContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryEditContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data_source_id": o.DataSourceId, + "description": o.Description, + "name": o.Name, + "options": o.Options, + "query": o.Query, + "query_id": o.QueryId, + "run_as_role": o.RunAsRole, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -9310,52 +6133,19 @@ func (a QueryFilter) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryFilter{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryFilter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryFilter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryFilter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryFilter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryFilter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryFilter +// only implements ToObjectValue() and Type(). +func (o QueryFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryFilter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query_start_time_range": o.QueryStartTimeRange, + "statement_ids": o.StatementIds, + "statuses": o.Statuses, + "user_ids": o.UserIds, + "warehouse_ids": o.WarehouseIds, + }) } // Type implements basetypes.ObjectValuable. @@ -9453,52 +6243,36 @@ func (a QueryInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryInfo +// only implements ToObjectValue() and Type(). +func (o QueryInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "channel_used": o.ChannelUsed, + "duration": o.Duration, + "endpoint_id": o.EndpointId, + "error_message": o.ErrorMessage, + "executed_as_user_id": o.ExecutedAsUserId, + "executed_as_user_name": o.ExecutedAsUserName, + "execution_end_time_ms": o.ExecutionEndTimeMs, + "is_final": o.IsFinal, + "lookup_key": o.LookupKey, + "metrics": o.Metrics, + "plans_state": o.PlansState, + "query_end_time_ms": o.QueryEndTimeMs, + "query_id": o.QueryId, + "query_start_time_ms": o.QueryStartTimeMs, + "query_text": o.QueryText, + "rows_produced": o.RowsProduced, + "spark_ui_url": o.SparkUiUrl, + "statement_type": o.StatementType, + "status": o.Status, + "user_id": o.UserId, + "user_name": o.UserName, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -9565,52 +6339,18 @@ func (a QueryList) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryList{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryList) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryList) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryList) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryList) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryList) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryList +// only implements ToObjectValue() and Type(). +func (o QueryList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryList) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "count": o.Count, + "page": o.Page, + "page_size": o.PageSize, + "results": o.Results, + }) } // Type implements basetypes.ObjectValuable. @@ -9705,52 +6445,36 @@ func (a QueryMetrics) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryMetrics{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryMetrics) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryMetrics) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryMetrics) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryMetrics) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryMetrics) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryMetrics) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryMetrics +// only implements ToObjectValue() and Type(). +func (o QueryMetrics) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "compilation_time_ms": o.CompilationTimeMs, + "execution_time_ms": o.ExecutionTimeMs, + "network_sent_bytes": o.NetworkSentBytes, + "overloading_queue_start_timestamp": o.OverloadingQueueStartTimestamp, + "photon_total_time_ms": o.PhotonTotalTimeMs, + "provisioning_queue_start_timestamp": o.ProvisioningQueueStartTimestamp, + "pruned_bytes": o.PrunedBytes, + "pruned_files_count": o.PrunedFilesCount, + "query_compilation_start_timestamp": o.QueryCompilationStartTimestamp, + "read_bytes": o.ReadBytes, + "read_cache_bytes": o.ReadCacheBytes, + "read_files_count": o.ReadFilesCount, + "read_partitions_count": o.ReadPartitionsCount, + "read_remote_bytes": o.ReadRemoteBytes, + "result_fetch_time_ms": o.ResultFetchTimeMs, + "result_from_cache": o.ResultFromCache, + "rows_produced_count": o.RowsProducedCount, + "rows_read_count": o.RowsReadCount, + "spill_to_disk_bytes": o.SpillToDiskBytes, + "task_total_time_ms": o.TaskTotalTimeMs, + "total_time_ms": o.TotalTimeMs, + "write_remote_bytes": o.WriteRemoteBytes, + }) } // Type implements basetypes.ObjectValuable. @@ -9815,52 +6539,18 @@ func (a QueryOptions) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryOptions{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryOptions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryOptions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryOptions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryOptions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryOptions +// only implements ToObjectValue() and Type(). +func (o QueryOptions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "catalog": o.Catalog, + "moved_to_trash_at": o.MovedToTrashAt, + "parameters": o.Parameters, + "schema": o.Schema, + }) } // Type implements basetypes.ObjectValuable. @@ -9923,52 +6613,22 @@ func (a QueryParameter) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryParameter{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryParameter) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryParameter) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryParameter) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryParameter) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryParameter) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryParameter +// only implements ToObjectValue() and Type(). +func (o QueryParameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryParameter) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "date_range_value": o.DateRangeValue, + "date_value": o.DateValue, + "enum_value": o.EnumValue, + "name": o.Name, + "numeric_value": o.NumericValue, + "query_backed_value": o.QueryBackedValue, + "text_value": o.TextValue, + "title": o.Title, + }) } // Type implements basetypes.ObjectValuable. @@ -10014,7 +6674,7 @@ type QueryPostContent struct { // Exclusively used for storing a list parameter definitions. A parameter is // an object with `title`, `name`, `type`, and `value` properties. The // `value` field here is the default value. It can be overridden at runtime. - Options any `tfsdk:"options" tf:"optional"` + Options types.Object `tfsdk:"options" tf:"optional"` // The identifier of the workspace folder containing the object. Parent types.String `tfsdk:"parent" tf:"optional"` // The text of the query to be run. @@ -10046,52 +6706,22 @@ func (a QueryPostContent) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryPostContent{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryPostContent) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryPostContent) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryPostContent) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryPostContent) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryPostContent) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryPostContent +// only implements ToObjectValue() and Type(). +func (o QueryPostContent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryPostContent) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data_source_id": o.DataSourceId, + "description": o.Description, + "name": o.Name, + "options": o.Options, + "parent": o.Parent, + "query": o.Query, + "run_as_role": o.RunAsRole, + "tags": o.Tags, + }) } // Type implements basetypes.ObjectValuable. @@ -10139,52 +6769,16 @@ func (a RepeatedEndpointConfPairs) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepeatedEndpointConfPairs{} - -// Equal implements basetypes.ObjectValuable. -func (o RepeatedEndpointConfPairs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepeatedEndpointConfPairs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepeatedEndpointConfPairs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepeatedEndpointConfPairs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepeatedEndpointConfPairs +// only implements ToObjectValue() and Type(). +func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepeatedEndpointConfPairs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "config_pair": o.ConfigPair, + "configuration_pairs": o.ConfigurationPairs, + }) } // Type implements basetypes.ObjectValuable. @@ -10223,52 +6817,15 @@ func (a RestoreDashboardRequest) GetComplexFieldTypes(ctx context.Context) map[s return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreDashboardRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreDashboardRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreDashboardRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreDashboardRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreDashboardRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreDashboardRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreDashboardRequest +// only implements ToObjectValue() and Type(). +func (o RestoreDashboardRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreDashboardRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dashboard_id": o.DashboardId, + }) } // Type implements basetypes.ObjectValuable. @@ -10302,52 +6859,15 @@ func (a RestoreQueriesLegacyRequest) GetComplexFieldTypes(ctx context.Context) m return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreQueriesLegacyRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreQueriesLegacyRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreQueriesLegacyRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreQueriesLegacyRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreQueriesLegacyRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreQueriesLegacyRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreQueriesLegacyRequest +// only implements ToObjectValue() and Type(). +func (o RestoreQueriesLegacyRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreQueriesLegacyRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "query_id": o.QueryId, + }) } // Type implements basetypes.ObjectValuable. @@ -10379,52 +6899,13 @@ func (a RestoreResponse) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RestoreResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RestoreResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RestoreResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RestoreResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RestoreResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RestoreResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RestoreResponse +// only implements ToObjectValue() and Type(). +func (o RestoreResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RestoreResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -10481,52 +6962,22 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResultData{} - -// Equal implements basetypes.ObjectValuable. -func (o ResultData) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResultData) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResultData) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResultData) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResultData) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResultData +// only implements ToObjectValue() and Type(). +func (o ResultData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResultData) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "byte_count": o.ByteCount, + "chunk_index": o.ChunkIndex, + "data_array": o.DataArray, + "external_links": o.ExternalLinks, + "next_chunk_index": o.NextChunkIndex, + "next_chunk_internal_link": o.NextChunkInternalLink, + "row_count": o.RowCount, + "row_offset": o.RowOffset, + }) } // Type implements basetypes.ObjectValuable. @@ -10591,52 +7042,21 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResultManifest{} - -// Equal implements basetypes.ObjectValuable. -func (o ResultManifest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResultManifest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResultManifest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResultManifest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResultManifest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResultManifest +// only implements ToObjectValue() and Type(). +func (o ResultManifest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResultManifest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "chunks": o.Chunks, + "format": o.Format, + "schema": o.Schema, + "total_byte_count": o.TotalByteCount, + "total_chunk_count": o.TotalChunkCount, + "total_row_count": o.TotalRowCount, + "truncated": o.Truncated, + }) } // Type implements basetypes.ObjectValuable. @@ -10684,52 +7104,16 @@ func (a ResultSchema) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResultSchema{} - -// Equal implements basetypes.ObjectValuable. -func (o ResultSchema) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResultSchema) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResultSchema) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResultSchema) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResultSchema) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResultSchema +// only implements ToObjectValue() and Type(). +func (o ResultSchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResultSchema) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "column_count": o.ColumnCount, + "columns": o.Columns, + }) } // Type implements basetypes.ObjectValuable. @@ -10767,52 +7151,16 @@ func (a ServiceError) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ServiceError{} - -// Equal implements basetypes.ObjectValuable. -func (o ServiceError) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ServiceError) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ServiceError) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ServiceError) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ServiceError) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ServiceError +// only implements ToObjectValue() and Type(). +func (o ServiceError) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ServiceError) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error_code": o.ErrorCode, + "message": o.Message, + }) } // Type implements basetypes.ObjectValuable. @@ -10854,52 +7202,17 @@ func (a SetRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SetRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetRequest +// only implements ToObjectValue() and Type(). +func (o SetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "objectId": o.ObjectId, + "objectType": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -10942,52 +7255,17 @@ func (a SetResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetResponse +// only implements ToObjectValue() and Type(). +func (o SetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -11055,52 +7333,23 @@ func (a SetWorkspaceWarehouseConfigRequest) GetComplexFieldTypes(ctx context.Con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetWorkspaceWarehouseConfigRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetWorkspaceWarehouseConfigRequest +// only implements ToObjectValue() and Type(). +func (o SetWorkspaceWarehouseConfigRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "channel": o.Channel, + "config_param": o.ConfigParam, + "data_access_config": o.DataAccessConfig, + "enabled_warehouse_types": o.EnabledWarehouseTypes, + "global_param": o.GlobalParam, + "google_service_account": o.GoogleServiceAccount, + "instance_profile_arn": o.InstanceProfileArn, + "security_policy": o.SecurityPolicy, + "sql_configuration_parameters": o.SqlConfigurationParameters, + }) } // Type implements basetypes.ObjectValuable. @@ -11152,52 +7401,13 @@ func (a SetWorkspaceWarehouseConfigResponse) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SetWorkspaceWarehouseConfigResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SetWorkspaceWarehouseConfigResponse +// only implements ToObjectValue() and Type(). +func (o SetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SetWorkspaceWarehouseConfigResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -11230,52 +7440,15 @@ func (a StartRequest) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o StartRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartRequest +// only implements ToObjectValue() and Type(). +func (o StartRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -11307,52 +7480,13 @@ func (a StartWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StartWarehouseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o StartWarehouseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StartWarehouseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StartWarehouseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StartWarehouseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StartWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StartWarehouseResponse +// only implements ToObjectValue() and Type(). +func (o StartWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StartWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -11395,52 +7529,17 @@ func (a StatementParameterListItem) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StatementParameterListItem{} - -// Equal implements basetypes.ObjectValuable. -func (o StatementParameterListItem) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StatementParameterListItem) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StatementParameterListItem) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StatementParameterListItem) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StatementParameterListItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StatementParameterListItem +// only implements ToObjectValue() and Type(). +func (o StatementParameterListItem) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StatementParameterListItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + "type": o.Type_, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -11488,52 +7587,18 @@ func (a StatementResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StatementResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o StatementResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StatementResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StatementResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StatementResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StatementResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StatementResponse +// only implements ToObjectValue() and Type(). +func (o StatementResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StatementResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "manifest": o.Manifest, + "result": o.Result, + "statement_id": o.StatementId, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -11587,52 +7652,16 @@ func (a StatementStatus) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StatementStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o StatementStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StatementStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StatementStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StatementStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StatementStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StatementStatus +// only implements ToObjectValue() and Type(). +func (o StatementStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StatementStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "error": o.Error, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -11670,52 +7699,15 @@ func (a StopRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StopRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o StopRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StopRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StopRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StopRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StopRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StopRequest +// only implements ToObjectValue() and Type(). +func (o StopRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StopRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -11747,52 +7739,13 @@ func (a StopWarehouseResponse) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = StopWarehouseResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o StopWarehouseResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o StopWarehouseResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o StopWarehouseResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o StopWarehouseResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o StopWarehouseResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, StopWarehouseResponse +// only implements ToObjectValue() and Type(). +func (o StopWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o StopWarehouseResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -11823,52 +7776,15 @@ func (a Success) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Success{} - -// Equal implements basetypes.ObjectValuable. -func (o Success) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Success) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Success) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Success) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Success) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Success +// only implements ToObjectValue() and Type(). +func (o Success) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Success) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + }) } // Type implements basetypes.ObjectValuable. @@ -11909,52 +7825,17 @@ func (a TerminationReason) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TerminationReason{} - -// Equal implements basetypes.ObjectValuable. -func (o TerminationReason) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TerminationReason) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TerminationReason) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TerminationReason) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TerminationReason) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TerminationReason +// only implements ToObjectValue() and Type(). +func (o TerminationReason) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TerminationReason) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "code": o.Code, + "parameters": o.Parameters, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -11991,52 +7872,15 @@ func (a TextValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TextValue{} - -// Equal implements basetypes.ObjectValuable. -func (o TextValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TextValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TextValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TextValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TextValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TextValue +// only implements ToObjectValue() and Type(). +func (o TextValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TextValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -12072,52 +7916,16 @@ func (a TimeRange) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TimeRange{} - -// Equal implements basetypes.ObjectValuable. -func (o TimeRange) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TimeRange) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TimeRange) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TimeRange) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TimeRange) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TimeRange +// only implements ToObjectValue() and Type(). +func (o TimeRange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TimeRange) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "end_time_ms": o.EndTimeMs, + "start_time_ms": o.StartTimeMs, + }) } // Type implements basetypes.ObjectValuable. @@ -12152,52 +7960,15 @@ func (a TransferOwnershipObjectId) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TransferOwnershipObjectId{} - -// Equal implements basetypes.ObjectValuable. -func (o TransferOwnershipObjectId) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TransferOwnershipObjectId) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TransferOwnershipObjectId) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TransferOwnershipObjectId) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TransferOwnershipObjectId) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TransferOwnershipObjectId +// only implements ToObjectValue() and Type(). +func (o TransferOwnershipObjectId) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TransferOwnershipObjectId) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "new_owner": o.NewOwner, + }) } // Type implements basetypes.ObjectValuable. @@ -12238,52 +8009,17 @@ func (a TransferOwnershipRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TransferOwnershipRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TransferOwnershipRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TransferOwnershipRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TransferOwnershipRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TransferOwnershipRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TransferOwnershipRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TransferOwnershipRequest +// only implements ToObjectValue() and Type(). +func (o TransferOwnershipRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TransferOwnershipRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "new_owner": o.NewOwner, + "objectId": o.ObjectId, + "objectType": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -12321,52 +8057,15 @@ func (a TrashAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TrashAlertRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TrashAlertRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TrashAlertRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TrashAlertRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TrashAlertRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o TrashAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TrashAlertRequest +// only implements ToObjectValue() and Type(). +func (o TrashAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TrashAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -12392,60 +8091,23 @@ func (newState *TrashQueryRequest) SyncEffectiveFieldsDuringRead(existingState T // GetComplexFieldTypes returns a map of the types of elements in complex fields in TrashQueryRequest. // Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry // the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a TrashQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = TrashQueryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o TrashQueryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o TrashQueryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o TrashQueryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o TrashQueryRequest) String() string { - return fmt.Sprintf("%#v", o) +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a TrashQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o TrashQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, TrashQueryRequest +// only implements ToObjectValue() and Type(). +func (o TrashQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o TrashQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + }) } // Type implements basetypes.ObjectValuable. @@ -12487,52 +8149,17 @@ func (a UpdateAlertRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAlertRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAlertRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAlertRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAlertRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAlertRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAlertRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAlertRequest +// only implements ToObjectValue() and Type(). +func (o UpdateAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAlertRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "alert": o.Alert, + "id": o.Id, + "update_mask": o.UpdateMask, + }) } // Type implements basetypes.ObjectValuable. @@ -12596,52 +8223,22 @@ func (a UpdateAlertRequestAlert) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateAlertRequestAlert{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateAlertRequestAlert) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateAlertRequestAlert) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateAlertRequestAlert) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateAlertRequestAlert) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateAlertRequestAlert) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateAlertRequestAlert +// only implements ToObjectValue() and Type(). +func (o UpdateAlertRequestAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateAlertRequestAlert) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "condition": o.Condition, + "custom_body": o.CustomBody, + "custom_subject": o.CustomSubject, + "display_name": o.DisplayName, + "notify_on_ok": o.NotifyOnOk, + "owner_user_name": o.OwnerUserName, + "query_id": o.QueryId, + "seconds_to_retrigger": o.SecondsToRetrigger, + }) } // Type implements basetypes.ObjectValuable. @@ -12692,52 +8289,17 @@ func (a UpdateQueryRequest) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateQueryRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateQueryRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateQueryRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateQueryRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateQueryRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateQueryRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateQueryRequest +// only implements ToObjectValue() and Type(). +func (o UpdateQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateQueryRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "query": o.Query, + "update_mask": o.UpdateMask, + }) } // Type implements basetypes.ObjectValuable. @@ -12800,52 +8362,25 @@ func (a UpdateQueryRequestQuery) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateQueryRequestQuery{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateQueryRequestQuery) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateQueryRequestQuery) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateQueryRequestQuery) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateQueryRequestQuery) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateQueryRequestQuery) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateQueryRequestQuery +// only implements ToObjectValue() and Type(). +func (o UpdateQueryRequestQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateQueryRequestQuery) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "apply_auto_limit": o.ApplyAutoLimit, + "catalog": o.Catalog, + "description": o.Description, + "display_name": o.DisplayName, + "owner_user_name": o.OwnerUserName, + "parameters": o.Parameters, + "query_text": o.QueryText, + "run_as_mode": o.RunAsMode, + "schema": o.Schema, + "tags": o.Tags, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -12891,52 +8426,13 @@ func (a UpdateResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateResponse +// only implements ToObjectValue() and Type(). +func (o UpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -12976,52 +8472,17 @@ func (a UpdateVisualizationRequest) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateVisualizationRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateVisualizationRequest +// only implements ToObjectValue() and Type(). +func (o UpdateVisualizationRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "update_mask": o.UpdateMask, + "visualization": o.Visualization, + }) } // Type implements basetypes.ObjectValuable. @@ -13069,52 +8530,18 @@ func (a UpdateVisualizationRequestVisualization) GetComplexFieldTypes(ctx contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateVisualizationRequestVisualization{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequestVisualization) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequestVisualization) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequestVisualization) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequestVisualization) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequestVisualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateVisualizationRequestVisualization +// only implements ToObjectValue() and Type(). +func (o UpdateVisualizationRequestVisualization) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateVisualizationRequestVisualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "display_name": o.DisplayName, + "serialized_options": o.SerializedOptions, + "serialized_query_plan": o.SerializedQueryPlan, + "type": o.Type_, + }) } // Type implements basetypes.ObjectValuable. @@ -13154,52 +8581,17 @@ func (a User) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = User{} - -// Equal implements basetypes.ObjectValuable. -func (o User) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o User) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o User) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o User) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o User) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, User +// only implements ToObjectValue() and Type(). +func (o User) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o User) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "email": o.Email, + "id": o.Id, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -13253,52 +8645,22 @@ func (a Visualization) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Visualization{} - -// Equal implements basetypes.ObjectValuable. -func (o Visualization) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Visualization) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Visualization) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Visualization) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Visualization) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Visualization +// only implements ToObjectValue() and Type(). +func (o Visualization) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Visualization) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "create_time": o.CreateTime, + "display_name": o.DisplayName, + "id": o.Id, + "query_id": o.QueryId, + "serialized_options": o.SerializedOptions, + "serialized_query_plan": o.SerializedQueryPlan, + "type": o.Type_, + "update_time": o.UpdateTime, + }) } // Type implements basetypes.ObjectValuable. @@ -13345,52 +8707,18 @@ func (a WarehouseAccessControlRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehouseAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehouseAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehouseAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehouseAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehouseAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehouseAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehouseAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o WarehouseAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehouseAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -13437,52 +8765,19 @@ func (a WarehouseAccessControlResponse) GetComplexFieldTypes(ctx context.Context } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehouseAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehouseAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehouseAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehouseAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehouseAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehouseAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehouseAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -13527,52 +8822,17 @@ func (a WarehousePermission) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehousePermission{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehousePermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehousePermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehousePermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehousePermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehousePermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehousePermission +// only implements ToObjectValue() and Type(). +func (o WarehousePermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehousePermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -13615,52 +8875,17 @@ func (a WarehousePermissions) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehousePermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehousePermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehousePermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehousePermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehousePermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehousePermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehousePermissions +// only implements ToObjectValue() and Type(). +func (o WarehousePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehousePermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -13699,52 +8924,16 @@ func (a WarehousePermissionsDescription) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehousePermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehousePermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehousePermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehousePermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehousePermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehousePermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehousePermissionsDescription +// only implements ToObjectValue() and Type(). +func (o WarehousePermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehousePermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -13782,52 +8971,16 @@ func (a WarehousePermissionsRequest) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehousePermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehousePermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehousePermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehousePermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehousePermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehousePermissionsRequest +// only implements ToObjectValue() and Type(). +func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehousePermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "warehouse_id": o.WarehouseId, + }) } // Type implements basetypes.ObjectValuable. @@ -13867,52 +9020,16 @@ func (a WarehouseTypePair) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WarehouseTypePair{} - -// Equal implements basetypes.ObjectValuable. -func (o WarehouseTypePair) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WarehouseTypePair) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WarehouseTypePair) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WarehouseTypePair) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WarehouseTypePair) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WarehouseTypePair +// only implements ToObjectValue() and Type(). +func (o WarehouseTypePair) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WarehouseTypePair) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "enabled": o.Enabled, + "warehouse_type": o.WarehouseType, + }) } // Type implements basetypes.ObjectValuable. @@ -13960,52 +9077,18 @@ func (a Widget) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Widget{} - -// Equal implements basetypes.ObjectValuable. -func (o Widget) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Widget) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Widget) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Widget) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Widget) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Widget +// only implements ToObjectValue() and Type(). +func (o Widget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Widget) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "id": o.Id, + "options": o.Options, + "visualization": o.Visualization, + "width": o.Width, + }) } // Type implements basetypes.ObjectValuable. @@ -14034,7 +9117,7 @@ type WidgetOptions struct { // How parameters used by the visualization in this widget relate to other // widgets on the dashboard. Databricks does not recommend modifying this // definition in JSON. - ParameterMappings any `tfsdk:"parameterMappings" tf:"optional"` + ParameterMappings types.Object `tfsdk:"parameterMappings" tf:"optional"` // Coordinates of this widget on a dashboard. This portion of the API // changes frequently and is unsupported. Position types.List `tfsdk:"position" tf:"optional,object"` @@ -14063,52 +9146,21 @@ func (a WidgetOptions) GetComplexFieldTypes(ctx context.Context) map[string]refl } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WidgetOptions{} - -// Equal implements basetypes.ObjectValuable. -func (o WidgetOptions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WidgetOptions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WidgetOptions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WidgetOptions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WidgetOptions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WidgetOptions +// only implements ToObjectValue() and Type(). +func (o WidgetOptions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WidgetOptions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "description": o.Description, + "isHidden": o.IsHidden, + "parameterMappings": o.ParameterMappings, + "position": o.Position, + "title": o.Title, + "updated_at": o.UpdatedAt, + }) } // Type implements basetypes.ObjectValuable. @@ -14160,52 +9212,19 @@ func (a WidgetPosition) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WidgetPosition{} - -// Equal implements basetypes.ObjectValuable. -func (o WidgetPosition) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WidgetPosition) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WidgetPosition) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WidgetPosition) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WidgetPosition) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WidgetPosition +// only implements ToObjectValue() and Type(). +func (o WidgetPosition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WidgetPosition) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "autoHeight": o.AutoHeight, + "col": o.Col, + "row": o.Row, + "sizeX": o.SizeX, + "sizeY": o.SizeY, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 27bbb022bf..20b03299a8 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -12,15 +12,11 @@ package vectorsearch_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type ColumnInfo struct { @@ -45,52 +41,15 @@ func (a ColumnInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ColumnInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ColumnInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ColumnInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ColumnInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ColumnInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ColumnInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ColumnInfo +// only implements ToObjectValue() and Type(). +func (o ColumnInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ColumnInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -126,52 +85,16 @@ func (a CreateEndpoint) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateEndpoint{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateEndpoint) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateEndpoint) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateEndpoint) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateEndpoint) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateEndpoint) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateEndpoint +// only implements ToObjectValue() and Type(). +func (o CreateEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateEndpoint) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_type": o.EndpointType, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -227,52 +150,20 @@ func (a CreateVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateVectorIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateVectorIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateVectorIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateVectorIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateVectorIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateVectorIndexRequest +// only implements ToObjectValue() and Type(). +func (o CreateVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "delta_sync_index_spec": o.DeltaSyncIndexSpec, + "direct_access_index_spec": o.DirectAccessIndexSpec, + "endpoint_name": o.EndpointName, + "index_type": o.IndexType, + "name": o.Name, + "primary_key": o.PrimaryKey, + }) } // Type implements basetypes.ObjectValuable. @@ -316,52 +207,15 @@ func (a CreateVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateVectorIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateVectorIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateVectorIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateVectorIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateVectorIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateVectorIndexResponse +// only implements ToObjectValue() and Type(). +func (o CreateVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "vector_index": o.VectorIndex, + }) } // Type implements basetypes.ObjectValuable. @@ -402,52 +256,16 @@ func (a DeleteDataResult) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDataResult{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDataResult) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDataResult) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDataResult) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDataResult) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDataResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDataResult +// only implements ToObjectValue() and Type(). +func (o DeleteDataResult) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDataResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "failed_primary_keys": o.FailedPrimaryKeys, + "success_row_count": o.SuccessRowCount, + }) } // Type implements basetypes.ObjectValuable. @@ -490,52 +308,16 @@ func (a DeleteDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDataVectorIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDataVectorIndexRequest +// only implements ToObjectValue() and Type(). +func (o DeleteDataVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_name": o.IndexName, + "primary_keys": o.PrimaryKeys, + }) } // Type implements basetypes.ObjectValuable. @@ -577,52 +359,16 @@ func (a DeleteDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteDataVectorIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteDataVectorIndexResponse +// only implements ToObjectValue() and Type(). +func (o DeleteDataVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteDataVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "result": o.Result, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -660,52 +406,15 @@ func (a DeleteEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteEndpointRequest +// only implements ToObjectValue() and Type(). +func (o DeleteEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_name": o.EndpointName, + }) } // Type implements basetypes.ObjectValuable. @@ -737,52 +446,13 @@ func (a DeleteEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteEndpointResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteEndpointResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteEndpointResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteEndpointResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteEndpointResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteEndpointResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteEndpointResponse +// only implements ToObjectValue() and Type(). +func (o DeleteEndpointResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteEndpointResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -815,52 +485,15 @@ func (a DeleteIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteIndexRequest +// only implements ToObjectValue() and Type(). +func (o DeleteIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_name": o.IndexName, + }) } // Type implements basetypes.ObjectValuable. @@ -892,52 +525,13 @@ func (a DeleteIndexResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteIndexResponse +// only implements ToObjectValue() and Type(). +func (o DeleteIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -996,52 +590,20 @@ func (a DeltaSyncVectorIndexSpecRequest) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeltaSyncVectorIndexSpecRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeltaSyncVectorIndexSpecRequest +// only implements ToObjectValue() and Type(). +func (o DeltaSyncVectorIndexSpecRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "columns_to_sync": o.ColumnsToSync, + "embedding_source_columns": o.EmbeddingSourceColumns, + "embedding_vector_columns": o.EmbeddingVectorColumns, + "embedding_writeback_table": o.EmbeddingWritebackTable, + "pipeline_type": o.PipelineType, + "source_table": o.SourceTable, + }) } // Type implements basetypes.ObjectValuable. @@ -1107,52 +669,20 @@ func (a DeltaSyncVectorIndexSpecResponse) GetComplexFieldTypes(ctx context.Conte } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeltaSyncVectorIndexSpecResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeltaSyncVectorIndexSpecResponse +// only implements ToObjectValue() and Type(). +func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeltaSyncVectorIndexSpecResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "embedding_source_columns": o.EmbeddingSourceColumns, + "embedding_vector_columns": o.EmbeddingVectorColumns, + "embedding_writeback_table": o.EmbeddingWritebackTable, + "pipeline_id": o.PipelineId, + "pipeline_type": o.PipelineType, + "source_table": o.SourceTable, + }) } // Type implements basetypes.ObjectValuable. @@ -1207,52 +737,17 @@ func (a DirectAccessVectorIndexSpec) GetComplexFieldTypes(ctx context.Context) m } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DirectAccessVectorIndexSpec{} - -// Equal implements basetypes.ObjectValuable. -func (o DirectAccessVectorIndexSpec) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DirectAccessVectorIndexSpec) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DirectAccessVectorIndexSpec) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DirectAccessVectorIndexSpec) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DirectAccessVectorIndexSpec +// only implements ToObjectValue() and Type(). +func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DirectAccessVectorIndexSpec) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "embedding_source_columns": o.EmbeddingSourceColumns, + "embedding_vector_columns": o.EmbeddingVectorColumns, + "schema_json": o.SchemaJson, + }) } // Type implements basetypes.ObjectValuable. @@ -1294,52 +789,16 @@ func (a EmbeddingSourceColumn) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EmbeddingSourceColumn{} - -// Equal implements basetypes.ObjectValuable. -func (o EmbeddingSourceColumn) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EmbeddingSourceColumn) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EmbeddingSourceColumn) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EmbeddingSourceColumn) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EmbeddingSourceColumn) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EmbeddingSourceColumn +// only implements ToObjectValue() and Type(). +func (o EmbeddingSourceColumn) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EmbeddingSourceColumn) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "embedding_model_endpoint_name": o.EmbeddingModelEndpointName, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1376,52 +835,16 @@ func (a EmbeddingVectorColumn) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EmbeddingVectorColumn{} - -// Equal implements basetypes.ObjectValuable. -func (o EmbeddingVectorColumn) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EmbeddingVectorColumn) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EmbeddingVectorColumn) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EmbeddingVectorColumn) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EmbeddingVectorColumn) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EmbeddingVectorColumn +// only implements ToObjectValue() and Type(). +func (o EmbeddingVectorColumn) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EmbeddingVectorColumn) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "embedding_dimension": o.EmbeddingDimension, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -1474,52 +897,23 @@ func (a EndpointInfo) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointInfo +// only implements ToObjectValue() and Type(). +func (o EndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creation_timestamp": o.CreationTimestamp, + "creator": o.Creator, + "endpoint_status": o.EndpointStatus, + "endpoint_type": o.EndpointType, + "id": o.Id, + "last_updated_timestamp": o.LastUpdatedTimestamp, + "last_updated_user": o.LastUpdatedUser, + "name": o.Name, + "num_indexes": o.NumIndexes, + }) } // Type implements basetypes.ObjectValuable. @@ -1566,52 +960,16 @@ func (a EndpointStatus) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = EndpointStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o EndpointStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o EndpointStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o EndpointStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o EndpointStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o EndpointStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, EndpointStatus +// only implements ToObjectValue() and Type(). +func (o EndpointStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o EndpointStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "message": o.Message, + "state": o.State, + }) } // Type implements basetypes.ObjectValuable. @@ -1647,52 +1005,15 @@ func (a GetEndpointRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetEndpointRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetEndpointRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetEndpointRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetEndpointRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetEndpointRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetEndpointRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetEndpointRequest +// only implements ToObjectValue() and Type(). +func (o GetEndpointRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetEndpointRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_name": o.EndpointName, + }) } // Type implements basetypes.ObjectValuable. @@ -1727,52 +1048,15 @@ func (a GetIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetIndexRequest +// only implements ToObjectValue() and Type(). +func (o GetIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_name": o.IndexName, + }) } // Type implements basetypes.ObjectValuable. @@ -1811,52 +1095,16 @@ func (a ListEndpointResponse) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListEndpointResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListEndpointResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListEndpointResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListEndpointResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListEndpointResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListEndpointResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListEndpointResponse +// only implements ToObjectValue() and Type(). +func (o ListEndpointResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListEndpointResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoints": o.Endpoints, + "next_page_token": o.NextPageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1894,52 +1142,15 @@ func (a ListEndpointsRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListEndpointsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListEndpointsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListEndpointsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListEndpointsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListEndpointsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListEndpointsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListEndpointsRequest +// only implements ToObjectValue() and Type(). +func (o ListEndpointsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListEndpointsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -1976,52 +1187,16 @@ func (a ListIndexesRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListIndexesRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListIndexesRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListIndexesRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListIndexesRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListIndexesRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListIndexesRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListIndexesRequest +// only implements ToObjectValue() and Type(). +func (o ListIndexesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListIndexesRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_name": o.EndpointName, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2057,52 +1232,15 @@ func (a ListValue) GetComplexFieldTypes(ctx context.Context) map[string]reflect. } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListValue{} - -// Equal implements basetypes.ObjectValuable. -func (o ListValue) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListValue) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListValue) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListValue) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListValue) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListValue +// only implements ToObjectValue() and Type(). +func (o ListValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListValue) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "values": o.Values, + }) } // Type implements basetypes.ObjectValuable. @@ -2143,52 +1281,16 @@ func (a ListVectorIndexesResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListVectorIndexesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListVectorIndexesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListVectorIndexesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListVectorIndexesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListVectorIndexesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListVectorIndexesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListVectorIndexesResponse +// only implements ToObjectValue() and Type(). +func (o ListVectorIndexesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListVectorIndexesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "vector_indexes": o.VectorIndexes, + }) } // Type implements basetypes.ObjectValuable. @@ -2230,52 +1332,16 @@ func (a MapStringValueEntry) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MapStringValueEntry{} - -// Equal implements basetypes.ObjectValuable. -func (o MapStringValueEntry) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MapStringValueEntry) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MapStringValueEntry) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MapStringValueEntry) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MapStringValueEntry) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MapStringValueEntry +// only implements ToObjectValue() and Type(). +func (o MapStringValueEntry) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MapStringValueEntry) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -2326,52 +1392,19 @@ func (a MiniVectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MiniVectorIndex{} - -// Equal implements basetypes.ObjectValuable. -func (o MiniVectorIndex) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MiniVectorIndex) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MiniVectorIndex) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MiniVectorIndex) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MiniVectorIndex) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MiniVectorIndex +// only implements ToObjectValue() and Type(). +func (o MiniVectorIndex) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MiniVectorIndex) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creator": o.Creator, + "endpoint_name": o.EndpointName, + "index_type": o.IndexType, + "name": o.Name, + "primary_key": o.PrimaryKey, + }) } // Type implements basetypes.ObjectValuable. @@ -2415,52 +1448,17 @@ func (a QueryVectorIndexNextPageRequest) GetComplexFieldTypes(ctx context.Contex return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryVectorIndexNextPageRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryVectorIndexNextPageRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryVectorIndexNextPageRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryVectorIndexNextPageRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryVectorIndexNextPageRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryVectorIndexNextPageRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryVectorIndexNextPageRequest +// only implements ToObjectValue() and Type(). +func (o QueryVectorIndexNextPageRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryVectorIndexNextPageRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "endpoint_name": o.EndpointName, + "index_name": o.IndexName, + "page_token": o.PageToken, + }) } // Type implements basetypes.ObjectValuable. @@ -2519,52 +1517,22 @@ func (a QueryVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryVectorIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryVectorIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryVectorIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryVectorIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryVectorIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryVectorIndexRequest +// only implements ToObjectValue() and Type(). +func (o QueryVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "columns": o.Columns, + "filters_json": o.FiltersJson, + "index_name": o.IndexName, + "num_results": o.NumResults, + "query_text": o.QueryText, + "query_type": o.QueryType, + "query_vector": o.QueryVector, + "score_threshold": o.ScoreThreshold, + }) } // Type implements basetypes.ObjectValuable. @@ -2618,52 +1586,17 @@ func (a QueryVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = QueryVectorIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o QueryVectorIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o QueryVectorIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o QueryVectorIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o QueryVectorIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o QueryVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, QueryVectorIndexResponse +// only implements ToObjectValue() and Type(). +func (o QueryVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o QueryVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "manifest": o.Manifest, + "next_page_token": o.NextPageToken, + "result": o.Result, + }) } // Type implements basetypes.ObjectValuable. @@ -2708,52 +1641,16 @@ func (a ResultData) GetComplexFieldTypes(ctx context.Context) map[string]reflect } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResultData{} - -// Equal implements basetypes.ObjectValuable. -func (o ResultData) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResultData) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResultData) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResultData) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResultData) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResultData +// only implements ToObjectValue() and Type(). +func (o ResultData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResultData) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data_array": o.DataArray, + "row_count": o.RowCount, + }) } // Type implements basetypes.ObjectValuable. @@ -2797,52 +1694,16 @@ func (a ResultManifest) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ResultManifest{} - -// Equal implements basetypes.ObjectValuable. -func (o ResultManifest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ResultManifest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ResultManifest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ResultManifest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ResultManifest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ResultManifest +// only implements ToObjectValue() and Type(). +func (o ResultManifest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ResultManifest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "column_count": o.ColumnCount, + "columns": o.Columns, + }) } // Type implements basetypes.ObjectValuable. @@ -2884,52 +1745,17 @@ func (a ScanVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ScanVectorIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ScanVectorIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ScanVectorIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ScanVectorIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ScanVectorIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ScanVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ScanVectorIndexRequest +// only implements ToObjectValue() and Type(). +func (o ScanVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ScanVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_name": o.IndexName, + "last_primary_key": o.LastPrimaryKey, + "num_results": o.NumResults, + }) } // Type implements basetypes.ObjectValuable. @@ -2970,52 +1796,16 @@ func (a ScanVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ScanVectorIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ScanVectorIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ScanVectorIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ScanVectorIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ScanVectorIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ScanVectorIndexResponse +// only implements ToObjectValue() and Type(). +func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ScanVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "data": o.Data, + "last_primary_key": o.LastPrimaryKey, + }) } // Type implements basetypes.ObjectValuable. @@ -3054,52 +1844,15 @@ func (a Struct) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Struct{} - -// Equal implements basetypes.ObjectValuable. -func (o Struct) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Struct) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Struct) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Struct) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Struct) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Struct +// only implements ToObjectValue() and Type(). +func (o Struct) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Struct) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "fields": o.Fields, + }) } // Type implements basetypes.ObjectValuable. @@ -3136,52 +1889,15 @@ func (a SyncIndexRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SyncIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o SyncIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SyncIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SyncIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SyncIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SyncIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SyncIndexRequest +// only implements ToObjectValue() and Type(). +func (o SyncIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SyncIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_name": o.IndexName, + }) } // Type implements basetypes.ObjectValuable. @@ -3213,52 +1929,13 @@ func (a SyncIndexResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SyncIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o SyncIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SyncIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SyncIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SyncIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SyncIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SyncIndexResponse +// only implements ToObjectValue() and Type(). +func (o SyncIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SyncIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3295,52 +1972,16 @@ func (a UpsertDataResult) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpsertDataResult{} - -// Equal implements basetypes.ObjectValuable. -func (o UpsertDataResult) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpsertDataResult) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpsertDataResult) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpsertDataResult) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpsertDataResult) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpsertDataResult +// only implements ToObjectValue() and Type(). +func (o UpsertDataResult) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpsertDataResult) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "failed_primary_keys": o.FailedPrimaryKeys, + "success_row_count": o.SuccessRowCount, + }) } // Type implements basetypes.ObjectValuable. @@ -3381,52 +2022,16 @@ func (a UpsertDataVectorIndexRequest) GetComplexFieldTypes(ctx context.Context) return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpsertDataVectorIndexRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpsertDataVectorIndexRequest +// only implements ToObjectValue() and Type(). +func (o UpsertDataVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_name": o.IndexName, + "inputs_json": o.InputsJson, + }) } // Type implements basetypes.ObjectValuable. @@ -3466,52 +2071,16 @@ func (a UpsertDataVectorIndexResponse) GetComplexFieldTypes(ctx context.Context) } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpsertDataVectorIndexResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpsertDataVectorIndexResponse +// only implements ToObjectValue() and Type(). +func (o UpsertDataVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpsertDataVectorIndexResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "result": o.Result, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -3560,52 +2129,20 @@ func (a Value) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Value{} - -// Equal implements basetypes.ObjectValuable. -func (o Value) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Value) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Value) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Value) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Value) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Value +// only implements ToObjectValue() and Type(). +func (o Value) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Value) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bool_value": o.BoolValue, + "list_value": o.ListValue, + "null_value": o.NullValue, + "number_value": o.NumberValue, + "string_value": o.StringValue, + "struct_value": o.StructValue, + }) } // Type implements basetypes.ObjectValuable. @@ -3672,52 +2209,22 @@ func (a VectorIndex) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = VectorIndex{} - -// Equal implements basetypes.ObjectValuable. -func (o VectorIndex) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o VectorIndex) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o VectorIndex) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o VectorIndex) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o VectorIndex) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, VectorIndex +// only implements ToObjectValue() and Type(). +func (o VectorIndex) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o VectorIndex) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "creator": o.Creator, + "delta_sync_index_spec": o.DeltaSyncIndexSpec, + "direct_access_index_spec": o.DirectAccessIndexSpec, + "endpoint_name": o.EndpointName, + "index_type": o.IndexType, + "name": o.Name, + "primary_key": o.PrimaryKey, + "status": o.Status, + }) } // Type implements basetypes.ObjectValuable. @@ -3770,52 +2277,18 @@ func (a VectorIndexStatus) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = VectorIndexStatus{} - -// Equal implements basetypes.ObjectValuable. -func (o VectorIndexStatus) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o VectorIndexStatus) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o VectorIndexStatus) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o VectorIndexStatus) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o VectorIndexStatus) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, VectorIndexStatus +// only implements ToObjectValue() and Type(). +func (o VectorIndexStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o VectorIndexStatus) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "index_url": o.IndexUrl, + "indexed_row_count": o.IndexedRowCount, + "message": o.Message, + "ready": o.Ready, + }) } // Type implements basetypes.ObjectValuable. diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 9ffbb4a846..e510b6ac47 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -12,15 +12,11 @@ package workspace_tf import ( "context" - "fmt" "reflect" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) type AclItem struct { @@ -47,52 +43,16 @@ func (a AclItem) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AclItem{} - -// Equal implements basetypes.ObjectValuable. -func (o AclItem) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AclItem) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AclItem) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AclItem) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AclItem) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AclItem +// only implements ToObjectValue() and Type(). +func (o AclItem) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AclItem) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission": o.Permission, + "principal": o.Principal, + }) } // Type implements basetypes.ObjectValuable. @@ -130,52 +90,16 @@ func (a AzureKeyVaultSecretScopeMetadata) GetComplexFieldTypes(ctx context.Conte return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = AzureKeyVaultSecretScopeMetadata{} - -// Equal implements basetypes.ObjectValuable. -func (o AzureKeyVaultSecretScopeMetadata) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o AzureKeyVaultSecretScopeMetadata) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o AzureKeyVaultSecretScopeMetadata) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o AzureKeyVaultSecretScopeMetadata) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o AzureKeyVaultSecretScopeMetadata) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, AzureKeyVaultSecretScopeMetadata +// only implements ToObjectValue() and Type(). +func (o AzureKeyVaultSecretScopeMetadata) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o AzureKeyVaultSecretScopeMetadata) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "dns_name": o.DnsName, + "resource_id": o.ResourceId, + }) } // Type implements basetypes.ObjectValuable. @@ -227,52 +151,17 @@ func (a CreateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o CreateCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "git_provider": o.GitProvider, + "git_username": o.GitUsername, + "personal_access_token": o.PersonalAccessToken, + }) } // Type implements basetypes.ObjectValuable. @@ -313,52 +202,17 @@ func (a CreateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o CreateCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + "git_provider": o.GitProvider, + "git_username": o.GitUsername, + }) } // Type implements basetypes.ObjectValuable. @@ -408,52 +262,18 @@ func (a CreateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRepoRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRepoRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRepoRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRepoRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRepoRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRepoRequest +// only implements ToObjectValue() and Type(). +func (o CreateRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + "provider": o.Provider, + "sparse_checkout": o.SparseCheckout, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -507,52 +327,21 @@ func (a CreateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateRepoResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateRepoResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateRepoResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateRepoResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateRepoResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateRepoResponse +// only implements ToObjectValue() and Type(). +func (o CreateRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "branch": o.Branch, + "head_commit_id": o.HeadCommitId, + "id": o.Id, + "path": o.Path, + "provider": o.Provider, + "sparse_checkout": o.SparseCheckout, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -604,52 +393,18 @@ func (a CreateScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateScope{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateScope) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateScope) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateScope) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateScope) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateScope) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateScope +// only implements ToObjectValue() and Type(). +func (o CreateScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateScope) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "backend_azure_keyvault": o.BackendAzureKeyvault, + "initial_manage_principal": o.InitialManagePrincipal, + "scope": o.Scope, + "scope_backend_type": o.ScopeBackendType, + }) } // Type implements basetypes.ObjectValuable. @@ -686,52 +441,13 @@ func (a CreateScopeResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CreateScopeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o CreateScopeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CreateScopeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CreateScopeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CreateScopeResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CreateScopeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateScopeResponse +// only implements ToObjectValue() and Type(). +func (o CreateScopeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CreateScopeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -768,52 +484,17 @@ func (a CredentialInfo) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = CredentialInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o CredentialInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o CredentialInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o CredentialInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o CredentialInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o CredentialInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CredentialInfo +// only implements ToObjectValue() and Type(). +func (o CredentialInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o CredentialInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + "git_provider": o.GitProvider, + "git_username": o.GitUsername, + }) } // Type implements basetypes.ObjectValuable. @@ -854,52 +535,16 @@ func (a Delete) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Delete{} - -// Equal implements basetypes.ObjectValuable. -func (o Delete) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Delete) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Delete) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Delete) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Delete) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Delete +// only implements ToObjectValue() and Type(). +func (o Delete) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Delete) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + "recursive": o.Recursive, + }) } // Type implements basetypes.ObjectValuable. @@ -936,52 +581,16 @@ func (a DeleteAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAcl{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAcl) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAcl) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAcl) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAcl) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAcl) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAcl +// only implements ToObjectValue() and Type(). +func (o DeleteAcl) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAcl) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principal": o.Principal, + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -1014,52 +623,13 @@ func (a DeleteAclResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteAclResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteAclResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteAclResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteAclResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteAclResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteAclResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteAclResponse +// only implements ToObjectValue() and Type(). +func (o DeleteAclResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteAclResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1092,52 +662,15 @@ func (a DeleteCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o DeleteCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + }) } // Type implements basetypes.ObjectValuable. @@ -1169,52 +702,13 @@ func (a DeleteCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o DeleteCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1247,52 +741,15 @@ func (a DeleteRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRepoRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRepoRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRepoRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRepoRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRepoRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRepoRequest +// only implements ToObjectValue() and Type(). +func (o DeleteRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "repo_id": o.RepoId, + }) } // Type implements basetypes.ObjectValuable. @@ -1324,52 +781,13 @@ func (a DeleteRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteRepoResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteRepoResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteRepoResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteRepoResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteRepoResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteRepoResponse +// only implements ToObjectValue() and Type(). +func (o DeleteRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1399,52 +817,13 @@ func (a DeleteResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteResponse +// only implements ToObjectValue() and Type(). +func (o DeleteResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1476,52 +855,15 @@ func (a DeleteScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteScope{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteScope) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteScope) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteScope) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteScope) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteScope) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteScope +// only implements ToObjectValue() and Type(). +func (o DeleteScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteScope) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -1553,52 +895,13 @@ func (a DeleteScopeResponse) GetComplexFieldTypes(ctx context.Context) map[strin return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteScopeResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteScopeResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteScopeResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteScopeResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteScopeResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteScopeResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteScopeResponse +// only implements ToObjectValue() and Type(). +func (o DeleteScopeResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteScopeResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1632,52 +935,16 @@ func (a DeleteSecret) GetComplexFieldTypes(ctx context.Context) map[string]refle return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteSecret{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteSecret) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteSecret) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteSecret) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteSecret) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteSecret +// only implements ToObjectValue() and Type(). +func (o DeleteSecret) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -1710,52 +977,13 @@ func (a DeleteSecretResponse) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = DeleteSecretResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o DeleteSecretResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o DeleteSecretResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o DeleteSecretResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o DeleteSecretResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o DeleteSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, DeleteSecretResponse +// only implements ToObjectValue() and Type(). +func (o DeleteSecretResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o DeleteSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -1804,52 +1032,16 @@ func (a ExportRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExportRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ExportRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExportRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExportRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExportRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExportRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExportRequest +// only implements ToObjectValue() and Type(). +func (o ExportRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExportRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "format": o.Format, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -1887,52 +1079,16 @@ func (a ExportResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ExportResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ExportResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ExportResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ExportResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ExportResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ExportResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ExportResponse +// only implements ToObjectValue() and Type(). +func (o ExportResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ExportResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "file_type": o.FileType, + }) } // Type implements basetypes.ObjectValuable. @@ -1970,52 +1126,16 @@ func (a GetAclRequest) GetComplexFieldTypes(ctx context.Context) map[string]refl return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetAclRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetAclRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetAclRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetAclRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetAclRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetAclRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetAclRequest +// only implements ToObjectValue() and Type(). +func (o GetAclRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetAclRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "principal": o.Principal, + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -2051,52 +1171,15 @@ func (a GetCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[str return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o GetCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + }) } // Type implements basetypes.ObjectValuable. @@ -2135,52 +1218,17 @@ func (a GetCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[st return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o GetCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + "git_provider": o.GitProvider, + "git_username": o.GitUsername, + }) } // Type implements basetypes.ObjectValuable. @@ -2217,52 +1265,15 @@ func (a GetRepoPermissionLevelsRequest) GetComplexFieldTypes(ctx context.Context return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRepoPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRepoPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetRepoPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "repo_id": o.RepoId, + }) } // Type implements basetypes.ObjectValuable. @@ -2298,52 +1309,15 @@ func (a GetRepoPermissionLevelsResponse) GetComplexFieldTypes(ctx context.Contex } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRepoPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRepoPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRepoPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -2380,52 +1354,15 @@ func (a GetRepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRepoPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRepoPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRepoPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRepoPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRepoPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRepoPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRepoPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetRepoPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRepoPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "repo_id": o.RepoId, + }) } // Type implements basetypes.ObjectValuable. @@ -2460,52 +1397,15 @@ func (a GetRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRepoRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRepoRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRepoRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRepoRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRepoRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRepoRequest +// only implements ToObjectValue() and Type(). +func (o GetRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "repo_id": o.RepoId, + }) } // Type implements basetypes.ObjectValuable. @@ -2553,52 +1453,21 @@ func (a GetRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetRepoResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetRepoResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetRepoResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetRepoResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetRepoResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetRepoResponse +// only implements ToObjectValue() and Type(). +func (o GetRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "branch": o.Branch, + "head_commit_id": o.HeadCommitId, + "id": o.Id, + "path": o.Path, + "provider": o.Provider, + "sparse_checkout": o.SparseCheckout, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -2643,52 +1512,16 @@ func (a GetSecretRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetSecretRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetSecretRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetSecretRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetSecretRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetSecretRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetSecretRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetSecretRequest +// only implements ToObjectValue() and Type(). +func (o GetSecretRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetSecretRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -2725,52 +1558,16 @@ func (a GetSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetSecretResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetSecretResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetSecretResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetSecretResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetSecretResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetSecretResponse +// only implements ToObjectValue() and Type(). +func (o GetSecretResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -2806,52 +1603,15 @@ func (a GetStatusRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetStatusRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetStatusRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetStatusRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetStatusRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetStatusRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetStatusRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetStatusRequest +// only implements ToObjectValue() and Type(). +func (o GetStatusRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetStatusRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -2888,52 +1648,16 @@ func (a GetWorkspaceObjectPermissionLevelsRequest) GetComplexFieldTypes(ctx cont return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceObjectPermissionLevelsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceObjectPermissionLevelsRequest +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceObjectPermissionLevelsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_object_id": o.WorkspaceObjectId, + "workspace_object_type": o.WorkspaceObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -2970,52 +1694,15 @@ func (a GetWorkspaceObjectPermissionLevelsResponse) GetComplexFieldTypes(ctx con } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceObjectPermissionLevelsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceObjectPermissionLevelsResponse +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionLevelsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission_levels": o.PermissionLevels, + }) } // Type implements basetypes.ObjectValuable. @@ -3054,52 +1741,16 @@ func (a GetWorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.C return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = GetWorkspaceObjectPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, GetWorkspaceObjectPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o GetWorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o GetWorkspaceObjectPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "workspace_object_id": o.WorkspaceObjectId, + "workspace_object_type": o.WorkspaceObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -3158,56 +1809,23 @@ func (newState *Import) SyncEffectiveFieldsDuringRead(existingState Import) { // are the reflected types of the contained elements. They must be either primitive values from the // plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF // SDK values. -func (a Import) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Import{} - -// Equal implements basetypes.ObjectValuable. -func (o Import) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Import) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Import) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Import) String() string { - return fmt.Sprintf("%#v", o) +func (a Import) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} } -// ToObjectValue implements basetypes.ObjectValuable. -func (o Import) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Import +// only implements ToObjectValue() and Type(). +func (o Import) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Import) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "content": o.Content, + "format": o.Format, + "language": o.Language, + "overwrite": o.Overwrite, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -3243,52 +1861,13 @@ func (a ImportResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ImportResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ImportResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ImportResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ImportResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ImportResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ImportResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ImportResponse +// only implements ToObjectValue() and Type(). +func (o ImportResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ImportResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -3321,52 +1900,15 @@ func (a ListAclsRequest) GetComplexFieldTypes(ctx context.Context) map[string]re return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAclsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAclsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAclsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAclsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAclsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAclsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAclsRequest +// only implements ToObjectValue() and Type(). +func (o ListAclsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAclsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -3402,52 +1944,15 @@ func (a ListAclsResponse) GetComplexFieldTypes(ctx context.Context) map[string]r } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListAclsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListAclsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListAclsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListAclsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListAclsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListAclsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListAclsResponse +// only implements ToObjectValue() and Type(). +func (o ListAclsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListAclsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "items": o.Items, + }) } // Type implements basetypes.ObjectValuable. @@ -3485,52 +1990,15 @@ func (a ListCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map[s } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credentials": o.Credentials, + }) } // Type implements basetypes.ObjectValuable. @@ -3573,52 +2041,16 @@ func (a ListReposRequest) GetComplexFieldTypes(ctx context.Context) map[string]r return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListReposRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListReposRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListReposRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListReposRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListReposRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListReposRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListReposRequest +// only implements ToObjectValue() and Type(). +func (o ListReposRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListReposRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "path_prefix": o.PathPrefix, + }) } // Type implements basetypes.ObjectValuable. @@ -3658,52 +2090,16 @@ func (a ListReposResponse) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListReposResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListReposResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListReposResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListReposResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListReposResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListReposResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListReposResponse +// only implements ToObjectValue() and Type(). +func (o ListReposResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListReposResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "next_page_token": o.NextPageToken, + "repos": o.Repos, + }) } // Type implements basetypes.ObjectValuable. @@ -3742,52 +2138,15 @@ func (a ListResponse) GetComplexFieldTypes(ctx context.Context) map[string]refle } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListResponse +// only implements ToObjectValue() and Type(). +func (o ListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "objects": o.Objects, + }) } // Type implements basetypes.ObjectValuable. @@ -3825,52 +2184,15 @@ func (a ListScopesResponse) GetComplexFieldTypes(ctx context.Context) map[string } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListScopesResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListScopesResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListScopesResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListScopesResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListScopesResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListScopesResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListScopesResponse +// only implements ToObjectValue() and Type(). +func (o ListScopesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListScopesResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "scopes": o.Scopes, + }) } // Type implements basetypes.ObjectValuable. @@ -3907,52 +2229,15 @@ func (a ListSecretsRequest) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSecretsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSecretsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSecretsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSecretsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSecretsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSecretsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSecretsRequest +// only implements ToObjectValue() and Type(). +func (o ListSecretsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSecretsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -3988,52 +2273,15 @@ func (a ListSecretsResponse) GetComplexFieldTypes(ctx context.Context) map[strin } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListSecretsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o ListSecretsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListSecretsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListSecretsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListSecretsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListSecretsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListSecretsResponse +// only implements ToObjectValue() and Type(). +func (o ListSecretsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListSecretsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "secrets": o.Secrets, + }) } // Type implements basetypes.ObjectValuable. @@ -4072,52 +2320,16 @@ func (a ListWorkspaceRequest) GetComplexFieldTypes(ctx context.Context) map[stri return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ListWorkspaceRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o ListWorkspaceRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ListWorkspaceRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ListWorkspaceRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ListWorkspaceRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ListWorkspaceRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ListWorkspaceRequest +// only implements ToObjectValue() and Type(). +func (o ListWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ListWorkspaceRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "notebooks_modified_after": o.NotebooksModifiedAfter, + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -4154,52 +2366,15 @@ func (a Mkdirs) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = Mkdirs{} - -// Equal implements basetypes.ObjectValuable. -func (o Mkdirs) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o Mkdirs) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o Mkdirs) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o Mkdirs) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o Mkdirs) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, Mkdirs +// only implements ToObjectValue() and Type(). +func (o Mkdirs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o Mkdirs) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "path": o.Path, + }) } // Type implements basetypes.ObjectValuable. @@ -4231,52 +2406,13 @@ func (a MkdirsResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = MkdirsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o MkdirsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o MkdirsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o MkdirsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o MkdirsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o MkdirsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, MkdirsResponse +// only implements ToObjectValue() and Type(). +func (o MkdirsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o MkdirsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4328,52 +2464,22 @@ func (a ObjectInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = ObjectInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o ObjectInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ObjectInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ObjectInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ObjectInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ObjectInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, ObjectInfo +// only implements ToObjectValue() and Type(). +func (o ObjectInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ObjectInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "created_at": o.CreatedAt, + "language": o.Language, + "modified_at": o.ModifiedAt, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + "path": o.Path, + "resource_id": o.ResourceId, + "size": o.Size, + }) } // Type implements basetypes.ObjectValuable. @@ -4418,52 +2524,17 @@ func (a PutAcl) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Typ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutAcl{} - -// Equal implements basetypes.ObjectValuable. -func (o PutAcl) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutAcl) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutAcl) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutAcl) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutAcl) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutAcl +// only implements ToObjectValue() and Type(). +func (o PutAcl) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutAcl) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "permission": o.Permission, + "principal": o.Principal, + "scope": o.Scope, + }) } // Type implements basetypes.ObjectValuable. @@ -4497,52 +2568,13 @@ func (a PutAclResponse) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutAclResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PutAclResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutAclResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutAclResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutAclResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutAclResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutAclResponse +// only implements ToObjectValue() and Type(). +func (o PutAclResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutAclResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4580,52 +2612,18 @@ func (a PutSecret) GetComplexFieldTypes(ctx context.Context) map[string]reflect. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutSecret{} - -// Equal implements basetypes.ObjectValuable. -func (o PutSecret) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutSecret) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutSecret) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutSecret) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutSecret) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutSecret +// only implements ToObjectValue() and Type(). +func (o PutSecret) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutSecret) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "bytes_value": o.BytesValue, + "key": o.Key, + "scope": o.Scope, + "string_value": o.StringValue, + }) } // Type implements basetypes.ObjectValuable. @@ -4660,52 +2658,13 @@ func (a PutSecretResponse) GetComplexFieldTypes(ctx context.Context) map[string] return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = PutSecretResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o PutSecretResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o PutSecretResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o PutSecretResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o PutSecretResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o PutSecretResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, PutSecretResponse +// only implements ToObjectValue() and Type(). +func (o PutSecretResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o PutSecretResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -4743,52 +2702,18 @@ func (a RepoAccessControlRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o RepoAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -4835,52 +2760,19 @@ func (a RepoAccessControlResponse) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -4935,52 +2827,21 @@ func (a RepoInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoInfo{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoInfo) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoInfo) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoInfo) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoInfo) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoInfo) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoInfo +// only implements ToObjectValue() and Type(). +func (o RepoInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoInfo) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "branch": o.Branch, + "head_commit_id": o.HeadCommitId, + "id": o.Id, + "path": o.Path, + "provider": o.Provider, + "sparse_checkout": o.SparseCheckout, + "url": o.Url, + }) } // Type implements basetypes.ObjectValuable. @@ -5027,52 +2888,17 @@ func (a RepoPermission) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoPermission +// only implements ToObjectValue() and Type(). +func (o RepoPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -5115,52 +2941,17 @@ func (a RepoPermissions) GetComplexFieldTypes(ctx context.Context) map[string]re } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoPermissions +// only implements ToObjectValue() and Type(). +func (o RepoPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -5199,52 +2990,16 @@ func (a RepoPermissionsDescription) GetComplexFieldTypes(ctx context.Context) ma return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o RepoPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -5282,52 +3037,16 @@ func (a RepoPermissionsRequest) GetComplexFieldTypes(ctx context.Context) map[st } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = RepoPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o RepoPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o RepoPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o RepoPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o RepoPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, RepoPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o RepoPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "repo_id": o.RepoId, + }) } // Type implements basetypes.ObjectValuable. @@ -5366,52 +3085,16 @@ func (a SecretMetadata) GetComplexFieldTypes(ctx context.Context) map[string]ref return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SecretMetadata{} - -// Equal implements basetypes.ObjectValuable. -func (o SecretMetadata) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SecretMetadata) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SecretMetadata) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SecretMetadata) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SecretMetadata) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SecretMetadata +// only implements ToObjectValue() and Type(). +func (o SecretMetadata) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SecretMetadata) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "key": o.Key, + "last_updated_timestamp": o.LastUpdatedTimestamp, + }) } // Type implements basetypes.ObjectValuable. @@ -5452,52 +3135,17 @@ func (a SecretScope) GetComplexFieldTypes(ctx context.Context) map[string]reflec } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SecretScope{} - -// Equal implements basetypes.ObjectValuable. -func (o SecretScope) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SecretScope) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SecretScope) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SecretScope) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SecretScope) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SecretScope +// only implements ToObjectValue() and Type(). +func (o SecretScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SecretScope) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "backend_type": o.BackendType, + "keyvault_metadata": o.KeyvaultMetadata, + "name": o.Name, + }) } // Type implements basetypes.ObjectValuable. @@ -5541,52 +3189,15 @@ func (a SparseCheckout) GetComplexFieldTypes(ctx context.Context) map[string]ref } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparseCheckout{} - -// Equal implements basetypes.ObjectValuable. -func (o SparseCheckout) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparseCheckout) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparseCheckout) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparseCheckout) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparseCheckout) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparseCheckout +// only implements ToObjectValue() and Type(). +func (o SparseCheckout) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparseCheckout) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "patterns": o.Patterns, + }) } // Type implements basetypes.ObjectValuable. @@ -5628,52 +3239,15 @@ func (a SparseCheckoutUpdate) GetComplexFieldTypes(ctx context.Context) map[stri } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = SparseCheckoutUpdate{} - -// Equal implements basetypes.ObjectValuable. -func (o SparseCheckoutUpdate) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o SparseCheckoutUpdate) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o SparseCheckoutUpdate) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o SparseCheckoutUpdate) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o SparseCheckoutUpdate) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, SparseCheckoutUpdate +// only implements ToObjectValue() and Type(). +func (o SparseCheckoutUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o SparseCheckoutUpdate) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "patterns": o.Patterns, + }) } // Type implements basetypes.ObjectValuable. @@ -5728,52 +3302,18 @@ func (a UpdateCredentialsRequest) GetComplexFieldTypes(ctx context.Context) map[ return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCredentialsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCredentialsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCredentialsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCredentialsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCredentialsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCredentialsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCredentialsRequest +// only implements ToObjectValue() and Type(). +func (o UpdateCredentialsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCredentialsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "credential_id": o.CredentialId, + "git_provider": o.GitProvider, + "git_username": o.GitUsername, + "personal_access_token": o.PersonalAccessToken, + }) } // Type implements basetypes.ObjectValuable. @@ -5808,52 +3348,13 @@ func (a UpdateCredentialsResponse) GetComplexFieldTypes(ctx context.Context) map return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateCredentialsResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateCredentialsResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateCredentialsResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateCredentialsResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateCredentialsResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateCredentialsResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateCredentialsResponse +// only implements ToObjectValue() and Type(). +func (o UpdateCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateCredentialsResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -5897,52 +3398,18 @@ func (a UpdateRepoRequest) GetComplexFieldTypes(ctx context.Context) map[string] } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRepoRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRepoRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRepoRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRepoRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRepoRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRepoRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRepoRequest +// only implements ToObjectValue() and Type(). +func (o UpdateRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRepoRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "branch": o.Branch, + "repo_id": o.RepoId, + "sparse_checkout": o.SparseCheckout, + "tag": o.Tag, + }) } // Type implements basetypes.ObjectValuable. @@ -5979,52 +3446,13 @@ func (a UpdateRepoResponse) GetComplexFieldTypes(ctx context.Context) map[string return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = UpdateRepoResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o UpdateRepoResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o UpdateRepoResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o UpdateRepoResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o UpdateRepoResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o UpdateRepoResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, UpdateRepoResponse +// only implements ToObjectValue() and Type(). +func (o UpdateRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o UpdateRepoResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{}) } // Type implements basetypes.ObjectValuable. @@ -6062,52 +3490,18 @@ func (a WorkspaceObjectAccessControlRequest) GetComplexFieldTypes(ctx context.Co return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceObjectAccessControlRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceObjectAccessControlRequest +// only implements ToObjectValue() and Type(). +func (o WorkspaceObjectAccessControlRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "group_name": o.GroupName, + "permission_level": o.PermissionLevel, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -6154,52 +3548,19 @@ func (a WorkspaceObjectAccessControlResponse) GetComplexFieldTypes(ctx context.C } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceObjectAccessControlResponse{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlResponse) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlResponse) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlResponse) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlResponse) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceObjectAccessControlResponse +// only implements ToObjectValue() and Type(). +func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectAccessControlResponse) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "all_permissions": o.AllPermissions, + "display_name": o.DisplayName, + "group_name": o.GroupName, + "service_principal_name": o.ServicePrincipalName, + "user_name": o.UserName, + }) } // Type implements basetypes.ObjectValuable. @@ -6244,52 +3605,17 @@ func (a WorkspaceObjectPermission) GetComplexFieldTypes(ctx context.Context) map } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceObjectPermission{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermission) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermission) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermission) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermission) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermission) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceObjectPermission +// only implements ToObjectValue() and Type(). +func (o WorkspaceObjectPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermission) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "inherited": o.Inherited, + "inherited_from_object": o.InheritedFromObject, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -6332,52 +3658,17 @@ func (a WorkspaceObjectPermissions) GetComplexFieldTypes(ctx context.Context) ma } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceObjectPermissions{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissions) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissions) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissions) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissions) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceObjectPermissions +// only implements ToObjectValue() and Type(). +func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissions) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "object_id": o.ObjectId, + "object_type": o.ObjectType, + }) } // Type implements basetypes.ObjectValuable. @@ -6416,52 +3707,16 @@ func (a WorkspaceObjectPermissionsDescription) GetComplexFieldTypes(ctx context. return map[string]reflect.Type{} } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceObjectPermissionsDescription{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsDescription) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsDescription) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsDescription) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsDescription) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsDescription) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceObjectPermissionsDescription +// only implements ToObjectValue() and Type(). +func (o WorkspaceObjectPermissionsDescription) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsDescription) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "description": o.Description, + "permission_level": o.PermissionLevel, + }) } // Type implements basetypes.ObjectValuable. @@ -6501,52 +3756,17 @@ func (a WorkspaceObjectPermissionsRequest) GetComplexFieldTypes(ctx context.Cont } } -// TFSDK types also implement the ObjectValuable interface, so they can be used directly as objects -// and as elements in lists and maps. -var _ basetypes.ObjectValuable = WorkspaceObjectPermissionsRequest{} - -// Equal implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsRequest) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsRequest) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsRequest) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsRequest) String() string { - return fmt.Sprintf("%#v", o) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, WorkspaceObjectPermissionsRequest +// only implements ToObjectValue() and Type(). +func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o WorkspaceObjectPermissionsRequest) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", pluginfwcommon.DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + map[string]attr.Value{ + "access_control_list": o.AccessControlList, + "workspace_object_id": o.WorkspaceObjectId, + "workspace_object_type": o.WorkspaceObjectType, + }) } // Type implements basetypes.ObjectValuable. From b3634bdab3ee92a74a3aeaca627a18aaff869e7a Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 6 Dec 2024 11:13:47 +0100 Subject: [PATCH 51/91] work --- .../pluginfw/converters/converters_test.go | 73 +++++++------------ 1 file changed, 25 insertions(+), 48 deletions(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index aca2ac1874..245f4f68f0 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -7,6 +7,7 @@ import ( "testing" pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" + tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" @@ -49,32 +50,6 @@ func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T } } -func (DummyTfSdk) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "enabled": types.BoolType, - "workers": types.Int64Type, - "floats": types.Float64Type, - "description": types.StringType, - "task": types.StringType, - "no_pointer_nested": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, - "nested_list": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, - "nested_pointer_list": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, - "map": types.MapType{ElemType: types.StringType}, - "nested_map": types.MapType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, - "repeated": types.ListType{ElemType: types.Int64Type}, - "attributes": types.MapType{ElemType: types.StringType}, - "enum_field": types.StringType, - "additional_field": types.StringType, - "distinct_field": types.StringType, - "slice_struct_ptr": types.ListType{ElemType: DummyNestedTfSdk{}.ToObjectType(ctx)}, - "object": types.ObjectType{ - AttrTypes: DummyNestedTfSdk{}.ToObjectType(ctx).AttrTypes, - }, - }, - } -} - type TestEnum string const TestEnumA TestEnum = `TEST_ENUM_A` @@ -107,15 +82,6 @@ type DummyNestedTfSdk struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } -func (DummyNestedTfSdk) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "enabled": types.BoolType, - }, - } -} - type DummyGoSdk struct { Enabled bool `json:"enabled"` Workers int64 `json:"workers"` @@ -150,24 +116,35 @@ func populateEmptyFields(c DummyTfSdk) DummyTfSdk { complexFields := c.GetComplexFieldTypes(context.Background()) v := reflect.ValueOf(&c).Elem() for i := 0; i < v.NumField(); i++ { - name := v.Type().Field(i).Name - tfsdkName := v.Type().Field(i).Tag.Get("tfsdk") - complexType, ok := complexFields[tfsdkName] - if !ok { + field := v.Field(i) + // If the field is a simple type, the zero value is OK. + switch field.Type() { + case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): continue } - field := v.FieldByName(name) if !field.IsZero() { continue } - innerVal := reflect.New(complexType).Elem().Interface() + + tfsdkName := v.Type().Field(i).Tag.Get("tfsdk") + complexType, ok := complexFields[tfsdkName] + if !ok { + continue + } + var typ attr.Type - if ot, ok := innerVal.(interface { - ToObjectType(context.Context) types.ObjectType - }); ok { - typ = ot.ToObjectType(context.Background()) - } else { - typ = innerVal.(attr.Value).Type(context.Background()) + switch complexType { + case reflect.TypeOf(types.Bool{}): + typ = types.BoolType + case reflect.TypeOf(types.Int64{}): + typ = types.Int64Type + case reflect.TypeOf(types.Float64{}): + typ = types.Float64Type + case reflect.TypeOf(types.String{}): + typ = types.StringType + default: + innerVal := reflect.New(complexType).Elem().Interface() + typ = tfcommon.NewObjectValuable(innerVal).Type(context.Background()) } switch field.Type() { case reflect.TypeOf(types.List{}): @@ -221,7 +198,7 @@ func TestGoSdkToTfSdkStructConversionFailure(t *testing.T) { assert.True(t, actualDiagnostics.Equal(expectedDiagnostics)) } -var dummyType = DummyNestedTfSdk{}.ToObjectType(context.Background()) +var dummyType = tfcommon.NewObjectValuable(DummyNestedTfSdk{}).Type(context.Background()).(types.ObjectType) var tests = []struct { name string From 32cba977bdf6db3cc0a58ad1fe8a0499a1bad1d5 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 6 Dec 2024 11:14:42 +0100 Subject: [PATCH 52/91] fix --- internal/providers/pluginfw/converters/converters_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index 245f4f68f0..f7f926bc04 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -6,7 +6,6 @@ import ( "reflect" "testing" - pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" tfcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" @@ -168,14 +167,14 @@ func RunConverterTest(t *testing.T, description string, tfSdkStruct DummyTfSdk, convertedGoSdkStruct := DummyGoSdk{} d := TfSdkToGoSdkStruct(context.Background(), tfSdkStruct, &convertedGoSdkStruct) if d.HasError() { - t.Errorf("tfsdk to gosdk conversion: %s", pluginfwcommon.DiagToString(d)) + t.Errorf("tfsdk to gosdk conversion: %s", tfcommon.DiagToString(d)) } assert.Equal(t, goSdkStruct, convertedGoSdkStruct, fmt.Sprintf("tfsdk to gosdk conversion - %s", description)) convertedTfSdkStruct := DummyTfSdk{} d = GoSdkToTfSdkStruct(context.Background(), goSdkStruct, &convertedTfSdkStruct) if d.HasError() { - t.Errorf("gosdk to tfsdk conversion: %s", pluginfwcommon.DiagToString(d)) + t.Errorf("gosdk to tfsdk conversion: %s", tfcommon.DiagToString(d)) } assert.Equal(t, populateEmptyFields(tfSdkStruct), convertedTfSdkStruct, fmt.Sprintf("gosdk to tfsdk conversion - %s", description)) } From 4fdd72b63817446f6586ee51c7ed5d9dc88eda2f Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Fri, 6 Dec 2024 17:15:22 +0100 Subject: [PATCH 53/91] work --- .codegen/model.go.tmpl | 95 +- .../{object_valuable.go => object_typable.go} | 76 +- .../pluginfw/converters/converters_test.go | 4 +- .../providers/pluginfw/converters/go_to_tf.go | 34 +- .../providers/pluginfw/converters/tf_to_go.go | 33 +- .../products/catalog/data_functions.go | 11 - .../products/sharing/resource_share.go | 19 +- .../pluginfw/products/volume/data_volumes.go | 10 - .../tfschema/customizable_schema_test.go | 29 - .../pluginfw/tfschema/struct_to_schema.go | 20 +- .../tfschema/struct_to_schema_test.go | 4 +- internal/service/apps_tf/model.go | 540 +- internal/service/billing_tf/model.go | 677 +- internal/service/catalog_tf/model.go | 4941 ++++++++++- internal/service/compute_tf/model.go | 5018 +++++++++++- internal/service/dashboards_tf/model.go | 534 +- internal/service/files_tf/model.go | 51 + internal/service/iam_tf/model.go | 1107 ++- internal/service/jobs_tf/model.go | 7248 ++++++++++++++++- internal/service/marketplace_tf/model.go | 2027 ++++- internal/service/ml_tf/model.go | 2109 ++++- internal/service/oauth2_tf/model.go | 432 + internal/service/pipelines_tf/model.go | 2213 ++++- internal/service/provisioning_tf/model.go | 1051 ++- internal/service/serving_tf/model.go | 2486 +++++- internal/service/settings_tf/model.go | 2046 ++++- internal/service/sharing_tf/model.go | 596 +- internal/service/sql_tf/model.go | 3271 +++++++- internal/service/vectorsearch_tf/model.go | 865 +- internal/service/workspace_tf/model.go | 655 +- 30 files changed, 36906 insertions(+), 1296 deletions(-) rename internal/providers/pluginfw/common/{object_valuable.go => object_typable.go} (64%) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index dd8d0943f3..54f7b5cf10 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -110,27 +110,92 @@ func (o {{.PascalName}}) Type(ctx context.Context) attr.Type { } } -{{end}} -{{end}} +{{/* Getters and setters for types.List and types.Map fields. */}} +{{ $parent := . }} +{{ range .Fields }} +{{ if or .Entity.IsObject .Entity.ArrayValue .Entity.MapValue }} +// Get{{.PascalName}} returns the value of the {{.PascalName}} field in {{ $parent.PascalName}} as +// {{ if .Entity.IsObject }}a {{template "complex-field-type" .Entity}} value{{ else if .Entity.ArrayValue }}a slice of {{template "complex-field-type" .Entity}} values{{ else }}a map of string to {{template "complex-field-type" .Entity}} values{{ end }}. +// If the field is unknown or null, the boolean return value is false. +func (o *{{ $parent.PascalName}}) Get{{.PascalName}}(ctx context.Context) {{template "getter-type" .Entity}} { + {{if .Entity.IsObject -}} + var e {{template "complex-field-type" .Entity}} + {{ end -}} + if o.{{.PascalName}}.IsNull() || o.{{.PascalName}}.IsUnknown() { + {{if .Entity.IsObject -}} + return e, false + {{- else -}} + return nil, false + {{- end}} + } + var v {{if .Entity.IsObject}}[]{{end}}{{template "getter-setter-type" .Entity}} + d := o.{{.PascalName}}.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + {{if .Entity.IsObject -}} + if len(v) == 0 { + return e, false + } + return v[0], true + {{- else -}} + return v, true + {{- end}} +} -{{range .Types}} -{{- if .IsEnum}} -{{.Comment "// " 80}} +// Set{{.PascalName}} sets the value of the {{.PascalName}} field in {{ $parent.PascalName}}. +func (o *{{ $parent.PascalName}}) Set{{.PascalName}}(ctx context.Context, v {{template "getter-setter-type" .Entity}}) { + {{ if .Entity.IsObject -}} + vs := []attr.Value{v.ToObjectValue(ctx)} + {{- else if .Entity.ArrayValue -}} + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e{{if or (and .Entity.ArrayValue .Entity.ArrayValue.IsObject) (and .Entity.MapValue .Entity.MapValue.IsObject)}}.ToObjectValue(ctx){{end}}) + } + {{- else -}} + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e{{if or (and .Entity.ArrayValue .Entity.ArrayValue.IsObject) (and .Entity.MapValue .Entity.MapValue.IsObject)}}.ToObjectValue(ctx){{end}} + } + {{- end}} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["{{template "tfsdk-name" (dict "field" .)}}"] + o.{{.PascalName}}{{if eq .PascalName "Type"}}_{{end}} = types.{{if .Entity.MapValue}}Map{{else}}List{{end}}ValueMust(t, vs) +} +{{end}} {{end}} {{end}} +{{end}} + +{{- define "getter-type" -}} +({{ template "getter-setter-type" . }}, bool) +{{- end -}} + +{{- define "getter-setter-type" -}} +{{- if .ArrayValue -}} + []{{ template "complex-field-type" . }} +{{- else if .IsObject -}} + {{ template "complex-field-type" . }} +{{- else -}} + map[string]{{ template "complex-field-type" . }} +{{- end -}} +{{- end -}} {{- define "complex-field-value" -}} - {{- if .ArrayValue }}{{ template "complex-field-value" .ArrayValue }} - {{- else if .MapValue }}{{ template "complex-field-value" .MapValue }} +{{ template "complex-field-type" . }}{} +{{- end -}} + +{{- define "complex-field-type" -}} + {{- if .ArrayValue }}{{ template "complex-field-type" .ArrayValue }} + {{- else if .MapValue }}{{ template "complex-field-type" .MapValue }} {{- else -}} - {{- if or .IsString .Enum -}}types.String{} - {{- else if .IsBool -}}types.Bool{} - {{- else if .IsInt64 -}}types.Int64{} - {{- else if .IsFloat64 -}}types.Float64{} - {{- else if .IsInt -}}types.Int64{} - {{- else if .IsAny -}}types.Object{} - {{- else if or .IsEmpty .IsObject -}}{{if .IsExternal}}{{.Package.Name}}.{{end}}{{.PascalName}}{} + {{- if or .IsString .Enum -}}types.String + {{- else if .IsBool -}}types.Bool + {{- else if .IsInt64 -}}types.Int64 + {{- else if .IsFloat64 -}}types.Float64 + {{- else if .IsInt -}}types.Int64 + {{- else if .IsAny -}}types.Object + {{- else if or .IsEmpty .IsObject -}}{{if .IsExternal}}{{.Package.Name}}_tf.{{end}}{{.PascalName}} {{- end -}} {{- end -}} {{- end -}} @@ -220,4 +285,4 @@ even when they are called recursively. {{- else if .Enum }}types.String {{- else}}any /* MISSING TYPE */ {{- end -}} -{{- end -}} +{{- end -}} \ No newline at end of file diff --git a/internal/providers/pluginfw/common/object_valuable.go b/internal/providers/pluginfw/common/object_typable.go similarity index 64% rename from internal/providers/pluginfw/common/object_valuable.go rename to internal/providers/pluginfw/common/object_typable.go index 46c132d1fb..49e2d0d703 100644 --- a/internal/providers/pluginfw/common/object_valuable.go +++ b/internal/providers/pluginfw/common/object_typable.go @@ -8,76 +8,40 @@ import ( "github.com/databricks/terraform-provider-databricks/common" "github.com/databricks/terraform-provider-databricks/internal/tfreflect" "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" - "github.com/hashicorp/terraform-plugin-go/tftypes" ) -type ObjectValuable struct { +// An ObjectTypable is an object that has a corresponding attr.Type. +// Note that this is different from the plugin framework's ObjectTypable interface, +// which is used to implement custom types in the plugin framework. Today, the +// serialization to plugin framework types is done in the converters package. +type ObjectTypable interface { + // Type returns the corresponding attr.Type for the object. For TF SDK types, + // this must always return an instance of basetypes.ObjectType. + Type(context.Context) attr.Type +} + +type ObjectTyper struct { // A TF SDK structure. // If this contains types.List, types.Map, or types.Object, it must implement the // ComplexFieldTypesProvider interface. inner any } -// Construct a new ObjectValuable. -// TFSDK structs automatically implement ObjectValuable, so they are returned as-is. -// Hand-written structs do not necessarily implement ObjectValuable, so this is a +// Construct a new ObjectTyper. +// TFSDK structs automatically implement ObjectTypable, so they are returned as-is. +// Hand-written structs do not necessarily implement ObjectTypable, so this is a // convenience implementation using reflection. -func NewObjectValuable(inner any) ObjectValuable { - if ov, ok := inner.(ObjectValuable); ok { +func NewObjectTyper(inner any) ObjectTypable { + if ov, ok := inner.(ObjectTypable); ok { return ov } - return ObjectValuable{inner: inner} -} - -// Equal implements basetypes.ObjectValuable. -func (o ObjectValuable) Equal(v attr.Value) bool { - ov, d := o.ToObjectValue(context.Background()) - if d.HasError() { - return false - } - return ov.Equal(v) -} - -// IsNull implements basetypes.ObjectValuable. -func (o ObjectValuable) IsNull() bool { - // TF SDK structures are never null. - return false -} - -// IsUnknown implements basetypes.ObjectValuable. -func (o ObjectValuable) IsUnknown() bool { - // TF SDK structures are never unknown. - return false -} - -// String implements basetypes.ObjectValuable. -func (o ObjectValuable) String() string { - return fmt.Sprintf("%v", o.inner) -} - -// ToObjectValue implements basetypes.ObjectValuable. -func (o ObjectValuable) ToObjectValue(ctx context.Context) (basetypes.ObjectValue, diag.Diagnostics) { - return types.ObjectValueFrom( - ctx, - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - o.inner, - ) -} - -// ToTerraformValue implements basetypes.ObjectValuable. -func (o ObjectValuable) ToTerraformValue(ctx context.Context) (tftypes.Value, error) { - ov, d := o.ToObjectValue(ctx) - if d.HasError() { - return tftypes.Value{}, fmt.Errorf("error converting to object value: %s", DiagToString(d)) - } - return ov.ToTerraformValue(ctx) + return ObjectTyper{inner: inner} } // Type implements basetypes.ObjectValuable. -func (o ObjectValuable) Type(ctx context.Context) attr.Type { +func (o ObjectTyper) Type(ctx context.Context) attr.Type { attrs := map[string]attr.Type{} // Tolerate pointers. @@ -113,7 +77,7 @@ func (o ObjectValuable) Type(ctx context.Context) attr.Type { } else { // If this is a TF SDK structure, we need to recursively determine the type. nested := reflect.New(fieldType).Elem().Interface() - ov := ObjectValuable{inner: nested} + ov := NewObjectTyper(nested) innerType = ov.Type(ctx) } @@ -159,5 +123,3 @@ func getAttrType(v any) (attr.Type, bool) { t, ok := simpleTypeMap[reflect.TypeOf(v)] return t, ok } - -var _ basetypes.ObjectValuable = ObjectValuable{} diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index f7f926bc04..0de36f9bef 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -143,7 +143,7 @@ func populateEmptyFields(c DummyTfSdk) DummyTfSdk { typ = types.StringType default: innerVal := reflect.New(complexType).Elem().Interface() - typ = tfcommon.NewObjectValuable(innerVal).Type(context.Background()) + typ = tfcommon.NewObjectTyper(innerVal).Type(context.Background()) } switch field.Type() { case reflect.TypeOf(types.List{}): @@ -197,7 +197,7 @@ func TestGoSdkToTfSdkStructConversionFailure(t *testing.T) { assert.True(t, actualDiagnostics.Equal(expectedDiagnostics)) } -var dummyType = tfcommon.NewObjectValuable(DummyNestedTfSdk{}).Type(context.Background()).(types.ObjectType) +var dummyType = tfcommon.NewObjectTyper(DummyNestedTfSdk{}).Type(context.Background()).(types.ObjectType) var tests = []struct { name string diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index a9a1507908..70e6653a5f 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -63,7 +63,7 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ // objectType is the type of the destination struct. Entries from this are used when constructing // plugin framework attr.Values for fields in the object. - objectType := tfcommon.NewObjectValuable(tfsdk).Type(ctx).(types.ObjectType) + objectType := tfcommon.NewObjectTyper(tfsdk).Type(ctx).(types.ObjectType) var forceSendFieldVal []string forceSendField := srcVal.FieldByName("ForceSendFields") @@ -124,7 +124,7 @@ func goSdkToTfSdkSingleField( innerType reflect.Type) (d diag.Diagnostics) { if !destField.CanSet() { d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("destination field can not be set: %s. %s", destField.Type().Name(), common.TerraformBugErrorMessage)) - return d + return } switch srcField.Kind() { @@ -133,7 +133,7 @@ func goSdkToTfSdkSingleField( // If nil, set the destination field to the null value of the appropriate type. if srcField.IsNil() { setFieldToNull(destField, tfType) - return nil + return } // Otherwise, dereference the pointer and continue. @@ -197,7 +197,8 @@ func goSdkToTfSdkSingleField( if destField.Type() == reflect.TypeOf(types.List{}) { listSrc := reflect.MakeSlice(reflect.SliceOf(srcField.Type()), 1, 1) listSrc.Index(0).Set(srcField) - return goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, tfType, innerType) + d.Append(goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, tfType, innerType)...) + return } // Otherwise, the destination field is a types.Object. Convert the nested struct to the corresponding @@ -225,9 +226,15 @@ func goSdkToTfSdkSingleField( d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a list type: %s. %s", tfType, common.TerraformBugErrorMessage)) return } + if srcField.IsNil() { + // Treat the source field as an empty slice. + nullList := types.ListNull(listType.ElemType) + destField.Set(reflect.ValueOf(nullList)) + return + } if srcField.Len() == 0 { - // If the destination field is a types.List, treat the source field as an empty slice. - emptyList := types.ListNull(listType.ElemType) + // Treat the source field as an empty slice. + emptyList := types.ListValueMust(listType.ElemType, []attr.Value{}) destField.Set(reflect.ValueOf(emptyList)) return } @@ -264,9 +271,15 @@ func goSdkToTfSdkSingleField( d.AddError(goSdkToTfSdkFieldConversionFailureMessage, fmt.Sprintf("inner type is not a map type: %s. %s", tfType, common.TerraformBugErrorMessage)) return } + if srcField.IsNil() { + // If the source field is nil, treat the destination field as an empty map. + nullMap := types.MapNull(mapType.ElemType) + destField.Set(reflect.ValueOf(nullMap)) + return + } if srcField.Len() == 0 { // If the destination field is a types.Map, treat the source field as an empty map. - emptyMap := types.MapNull(mapType.ElemType) + emptyMap := types.MapValueMust(mapType.ElemType, map[string]attr.Value{}) destField.Set(reflect.ValueOf(emptyMap)) return } @@ -309,12 +322,13 @@ func setFieldToNull(destField reflect.Value, innerType attr.Type) { case reflect.TypeOf(types.List{}): // If the destination field is a types.List, treat the source field as an empty slice. listType := innerType.(types.ListType) - emptyList := types.ListNull(listType.ElemType) - destField.Set(reflect.ValueOf(emptyList)) + nullList := types.ListNull(listType.ElemType) + destField.Set(reflect.ValueOf(nullList)) case reflect.TypeOf(types.Object{}): // If the destination field is a types.Object, treat the source field as an empty object. innerType := innerType.(types.ObjectType) - destField.Set(reflect.ValueOf(types.ObjectNull(innerType.AttrTypes))) + nullObject := types.ObjectNull(innerType.AttrTypes) + destField.Set(reflect.ValueOf(nullObject)) } } diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 8d7a5b250a..d5e4f828ed 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -64,17 +64,17 @@ func TfSdkToGoSdkStruct(ctx context.Context, tfsdk interface{}, gosdk interface{ allFields := tfreflect.ListAllFields(srcVal) for _, field := range allFields { srcField := field.Value - srcFieldName := field.StructField.Name + destFieldName := toGoSdkName(field.StructField.Name) srcFieldTag := field.StructField.Tag.Get("tfsdk") if srcFieldTag == "-" { continue } - destField := destVal.FieldByName(toGoSdkName(srcFieldName)) + destField := destVal.FieldByName(destFieldName) innerType := innerTypes[srcFieldTag] - d.Append(tfSdkToGoSdkSingleField(ctx, srcField, destField, srcFieldName, &forceSendFieldsField, innerType)...) + d.Append(tfSdkToGoSdkSingleField(ctx, srcField, destField, destFieldName, &forceSendFieldsField, innerType)...) if d.HasError() { return } @@ -87,13 +87,13 @@ func tfSdkToGoSdkSingleField( ctx context.Context, srcField reflect.Value, destField reflect.Value, - srcFieldName string, + destFieldName string, forceSendFieldsField *reflect.Value, innerType reflect.Type) (d diag.Diagnostics) { if !destField.IsValid() { // Skip field that destination struct does not have. - tflog.Trace(ctx, fmt.Sprintf("field skipped in tfsdk to gosdk conversion: destination struct does not have field %s", srcFieldName)) + tflog.Trace(ctx, fmt.Sprintf("field skipped in tfsdk to gosdk conversion: destination struct does not have field %s", destFieldName)) return } @@ -102,11 +102,6 @@ func tfSdkToGoSdkSingleField( return } - if srcField.Kind() != reflect.Struct { - d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", srcField.Interface(), common.TerraformBugErrorMessage)) - return - } - // The field being processed must be an attr.Value (a field of the TF SDK struct). v, ok := srcField.Interface().(attr.Value) if !ok { @@ -117,11 +112,12 @@ func tfSdkToGoSdkSingleField( if v.IsUnknown() { return } + if shouldSetForceSendFields(v, destField) { - addToForceSendFields(ctx, srcFieldName, forceSendFieldsField) + addToForceSendFields(ctx, destFieldName, forceSendFieldsField) } - d.Append(tfsdkToGoSdkStructField(ctx, v, destField, srcFieldName, forceSendFieldsField, innerType)...) + d.Append(tfsdkToGoSdkStructField(ctx, v, destField, destFieldName, forceSendFieldsField, innerType)...) return } @@ -129,7 +125,7 @@ func tfsdkToGoSdkStructField( ctx context.Context, srcFieldValue attr.Value, destField reflect.Value, - srcFieldName string, + destFieldName string, forceSendFieldsField *reflect.Value, innerType reflect.Type) (d diag.Diagnostics) { switch v := srcFieldValue.(type) { @@ -195,7 +191,7 @@ func tfsdkToGoSdkStructField( // Otherwise, it is a TF SDK struct, and we need to call TfSdkToGoSdkStruct to convert it. switch typedVv := vv.(type) { case types.Bool, types.String, types.Int64, types.Float64: - d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), srcFieldName, forceSendFieldsField, innerType)...) + d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), destFieldName, forceSendFieldsField, innerType)...) default: d.Append(TfSdkToGoSdkStruct(ctx, vv, nextDest.Interface())...) } @@ -236,7 +232,7 @@ func tfsdkToGoSdkStructField( // Otherwise, it is a TF SDK struct, and we need to call TfSdkToGoSdkStruct to convert it. switch typedVv := vv.(type) { case types.Bool, types.String, types.Int64, types.Float64: - d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), srcFieldName, forceSendFieldsField, innerType)...) + d.Append(tfsdkToGoSdkStructField(ctx, typedVv.(attr.Value), nextDest.Elem(), destFieldName, forceSendFieldsField, innerType)...) default: d.Append(TfSdkToGoSdkStruct(ctx, vv, nextDest.Interface())...) } @@ -259,11 +255,8 @@ func tfsdkToGoSdkStructField( } d.Append(TfSdkToGoSdkStruct(ctx, innerValue.Interface(), destField.Addr().Interface())...) - case types.Set, types.Tuple: - d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("%T is not currently supported as a source field. %s", v, common.TerraformBugErrorMessage)) - return default: - d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", v, common.TerraformBugErrorMessage)) + d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("%T is not currently supported as a source field. %s", v, common.TerraformBugErrorMessage)) return } return @@ -288,7 +281,7 @@ func shouldSetForceSendFields(srcFieldValue attr.Value, destField reflect.Value) func addToForceSendFields(ctx context.Context, fieldName string, forceSendFieldsField *reflect.Value) { if forceSendFieldsField == nil || !forceSendFieldsField.IsValid() || !forceSendFieldsField.CanSet() { - tflog.Debug(ctx, fmt.Sprintf("[Debug] forceSendFieldsField is nil, invalid or not settable. %s", fieldName)) + tflog.Debug(ctx, fmt.Sprintf("forceSendFieldsField is nil, invalid or not settable. %s", fieldName)) return } // Initialize forceSendFields if it is a zero Value diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index 9048e7a3b0..5c0ca3bead 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -44,17 +44,6 @@ func (FunctionsData) GetComplexFieldTypes(context.Context) map[string]reflect.Ty } } -func (FunctionsData) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "catalog_name": types.StringType, - "schema_name": types.StringType, - "include_browse": types.BoolType, - "functions": types.ListType{ElemType: pluginfwcommon.NewObjectValuable(catalog_tf.FunctionInfo{}).Type(ctx)}, - }, - } -} - func (d *FunctionsDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = pluginfwcommon.GetDatabricksProductionName(dataSourceName) } diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index e0cc33cc3a..39d1cf2cb4 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -19,7 +19,6 @@ import ( "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/int64planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" - "github.com/hashicorp/terraform-plugin-framework/types/basetypes" ) const resourceName = "share" @@ -435,21 +434,13 @@ func (effectiveFieldsActionRead) objectLevel(state *sharing_tf.SharedDataObject, func (r *ShareResource) syncEffectiveFields(ctx context.Context, plan, state ShareInfoExtended, mode effectiveFieldsAction) (ShareInfoExtended, diag.Diagnostics) { var d diag.Diagnostics mode.resourceLevel(&state, plan.ShareInfo) - planObjects := []sharing_tf.SharedDataObject{} - d.Append(plan.Objects.ElementsAs(ctx, &planObjects, true)...) - if d.HasError() { - return state, d - } - stateObjects := []sharing_tf.SharedDataObject{} - d.Append(state.Objects.ElementsAs(ctx, &stateObjects, true)...) - if d.HasError() { - return state, d - } + planObjects, _ := plan.GetObjects(ctx) + stateObjects, _ := state.GetObjects(ctx) + finalObjects := []sharing_tf.SharedDataObject{} for i := range stateObjects { mode.objectLevel(&stateObjects[i], planObjects[i]) + finalObjects = append(finalObjects, stateObjects[i]) } - var dd diag.Diagnostics - state.Objects, dd = basetypes.NewListValueFrom(ctx, state.Objects.ElementType(ctx), stateObjects) - d.Append(dd...) + state.SetObjects(ctx, finalObjects) return state, d } diff --git a/internal/providers/pluginfw/products/volume/data_volumes.go b/internal/providers/pluginfw/products/volume/data_volumes.go index 7a2611762b..6727dc20cb 100644 --- a/internal/providers/pluginfw/products/volume/data_volumes.go +++ b/internal/providers/pluginfw/products/volume/data_volumes.go @@ -42,16 +42,6 @@ func (VolumesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type } } -func (VolumesList) ToObjectType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "catalog_name": types.StringType, - "schema_name": types.StringType, - "ids": types.ListType{ElemType: types.StringType}, - }, - } -} - func (d *VolumesDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { resp.TypeName = pluginfwcommon.GetDatabricksProductionName(dataSourceName) } diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index c33c234c32..6de3c00021 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -6,7 +6,6 @@ import ( "reflect" "testing" - "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier" @@ -30,39 +29,11 @@ func (TestTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { } } -func (TestTfSdk) ToAttrType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "description": types.StringType, - "nested": types.ListType{ - ElemType: NestedTfSdk{}.ToAttrType(ctx), - }, - "nested_slice_object": types.ListType{ - ElemType: NestedTfSdk{}.ToAttrType(ctx), - }, - "map": types.StringType, - }, - } -} - type NestedTfSdk struct { Name types.String `tfsdk:"name" tf:"optional"` Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } -func (NestedTfSdk) GetComplexFieldTypes(context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} -} - -func (NestedTfSdk) ToAttrType(ctx context.Context) types.ObjectType { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "enabled": types.BoolType, - }, - } -} - type stringLengthBetweenValidator struct { Max int Min int diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 4073d29598..4c940cced9 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -43,6 +43,9 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { } structTag := getStructTag(typeField) value := field.Value.Interface() + if _, ok := value.(attr.Value); !ok { + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) + } switch value.(type) { case types.Bool: scmAttr[fieldName] = BoolAttributeBuilder{} @@ -64,17 +67,19 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { if !ok { panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } - objectType := tfcommon.NewObjectValuable(v.Interface()).Type(ctx).(types.ObjectType) - attrType, ok := objectType.AttrTypes[fieldName] - if !ok { - panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) - } // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. // Otherwise, use ListNestedBlockBuilder. switch fieldType { // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. // If new types are added there, they must also be added here to work properly. case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): + // Look up the element type from the Type() methods for TF SDK structs. + // This is always a attr.TypeWithElementType because the field is a list or map. + objectType := tfcommon.NewObjectTyper(v.Interface()).Type(ctx).(types.ObjectType) + attrType, ok := objectType.AttrTypes[fieldName] + if !ok { + panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + } containerType := attrType.(attr.TypeWithElementType) switch value.(type) { case types.List: @@ -96,6 +101,7 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { if structTag.singleObject { validators = append(validators, listvalidator.SizeAtMost(1)) } + // Note that this is being added to the block map, not the attribute map. scmBlock[fieldName] = ListNestedBlockBuilder{ NestedObject: nestedSchema, Validators: validators, @@ -110,10 +116,8 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { } } } - case types.Set, types.Tuple: - panic(fmt.Errorf("%T is not currently supported in tfsdk structs. %s", value, common.TerraformBugErrorMessage)) default: - panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework type. %s", value, common.TerraformBugErrorMessage)) + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } // types.List fields of complex types correspond to ListNestedBlock, which don't have optional/required/computed flags. // When these fields are later changed to use ListNestedAttribute, we can inline the if statement below, as all fields diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go index 6971ec965d..6a410ffced 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go @@ -92,7 +92,7 @@ func (TestNestedMapTfSdk) GetComplexFieldTypes(context.Context) map[string]refle } } -var dummyType = tfcommon.NewObjectValuable(DummyNested{}).Type(context.Background()).(types.ObjectType) +var dummyType = tfcommon.NewObjectTyper(DummyNested{}).Type(context.Background()).(types.ObjectType) var tests = []struct { name string @@ -254,7 +254,7 @@ var error_tests = []struct { { "slice of slice conversion", TestSliceOfSlice{}, - fmt.Sprintf("unexpected type [][]string in tfsdk structs, expected a plugin framework type. %s", common.TerraformBugErrorMessage), + fmt.Sprintf("unexpected type [][]string in tfsdk structs, expected a plugin framework value type. %s", common.TerraformBugErrorMessage), }, } diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 9457b01d70..c1777ed1d5 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -142,6 +143,135 @@ func (o App) Type(ctx context.Context) attr.Type { } } +// GetActiveDeployment returns the value of the ActiveDeployment field in App as +// a AppDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *App) GetActiveDeployment(ctx context.Context) (AppDeployment, bool) { + var e AppDeployment + if o.ActiveDeployment.IsNull() || o.ActiveDeployment.IsUnknown() { + return e, false + } + var v []AppDeployment + d := o.ActiveDeployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetActiveDeployment sets the value of the ActiveDeployment field in App. +func (o *App) SetActiveDeployment(ctx context.Context, v AppDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["active_deployment"] + o.ActiveDeployment = types.ListValueMust(t, vs) +} + +// GetAppStatus returns the value of the AppStatus field in App as +// a ApplicationStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *App) GetAppStatus(ctx context.Context) (ApplicationStatus, bool) { + var e ApplicationStatus + if o.AppStatus.IsNull() || o.AppStatus.IsUnknown() { + return e, false + } + var v []ApplicationStatus + d := o.AppStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAppStatus sets the value of the AppStatus field in App. +func (o *App) SetAppStatus(ctx context.Context, v ApplicationStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app_status"] + o.AppStatus = types.ListValueMust(t, vs) +} + +// GetComputeStatus returns the value of the ComputeStatus field in App as +// a ComputeStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *App) GetComputeStatus(ctx context.Context) (ComputeStatus, bool) { + var e ComputeStatus + if o.ComputeStatus.IsNull() || o.ComputeStatus.IsUnknown() { + return e, false + } + var v []ComputeStatus + d := o.ComputeStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetComputeStatus sets the value of the ComputeStatus field in App. +func (o *App) SetComputeStatus(ctx context.Context, v ComputeStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compute_status"] + o.ComputeStatus = types.ListValueMust(t, vs) +} + +// GetPendingDeployment returns the value of the PendingDeployment field in App as +// a AppDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *App) GetPendingDeployment(ctx context.Context) (AppDeployment, bool) { + var e AppDeployment + if o.PendingDeployment.IsNull() || o.PendingDeployment.IsUnknown() { + return e, false + } + var v []AppDeployment + d := o.PendingDeployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPendingDeployment sets the value of the PendingDeployment field in App. +func (o *App) SetPendingDeployment(ctx context.Context, v AppDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pending_deployment"] + o.PendingDeployment = types.ListValueMust(t, vs) +} + +// GetResources returns the value of the Resources field in App as +// a slice of AppResource values. +// If the field is unknown or null, the boolean return value is false. +func (o *App) GetResources(ctx context.Context) ([]AppResource, bool) { + if o.Resources.IsNull() || o.Resources.IsUnknown() { + return nil, false + } + var v []AppResource + d := o.Resources.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResources sets the value of the Resources field in App. +func (o *App) SetResources(ctx context.Context, v []AppResource) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["resources"] + o.Resources = types.ListValueMust(t, vs) +} + type AppAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -258,6 +388,31 @@ func (o AppAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in AppAccessControlResponse as +// a slice of AppPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *AppAccessControlResponse) GetAllPermissions(ctx context.Context) ([]AppPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []AppPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in AppAccessControlResponse. +func (o *AppAccessControlResponse) SetAllPermissions(ctx context.Context, v []AppPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type AppDeployment struct { // The creation time of the deployment. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -341,6 +496,58 @@ func (o AppDeployment) Type(ctx context.Context) attr.Type { } } +// GetDeploymentArtifacts returns the value of the DeploymentArtifacts field in AppDeployment as +// a AppDeploymentArtifacts value. +// If the field is unknown or null, the boolean return value is false. +func (o *AppDeployment) GetDeploymentArtifacts(ctx context.Context) (AppDeploymentArtifacts, bool) { + var e AppDeploymentArtifacts + if o.DeploymentArtifacts.IsNull() || o.DeploymentArtifacts.IsUnknown() { + return e, false + } + var v []AppDeploymentArtifacts + d := o.DeploymentArtifacts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeploymentArtifacts sets the value of the DeploymentArtifacts field in AppDeployment. +func (o *AppDeployment) SetDeploymentArtifacts(ctx context.Context, v AppDeploymentArtifacts) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment_artifacts"] + o.DeploymentArtifacts = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in AppDeployment as +// a AppDeploymentStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *AppDeployment) GetStatus(ctx context.Context) (AppDeploymentStatus, bool) { + var e AppDeploymentStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []AppDeploymentStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in AppDeployment. +func (o *AppDeployment) SetStatus(ctx context.Context, v AppDeploymentStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + type AppDeploymentArtifacts struct { // The snapshotted workspace file system path of the source code loaded by // the deployed app. @@ -483,6 +690,31 @@ func (o AppPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in AppPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *AppPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in AppPermission. +func (o *AppPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type AppPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -536,6 +768,31 @@ func (o AppPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in AppPermissions as +// a slice of AppAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *AppPermissions) GetAccessControlList(ctx context.Context) ([]AppAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AppAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in AppPermissions. +func (o *AppPermissions) SetAccessControlList(ctx context.Context, v []AppAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type AppPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -630,6 +887,31 @@ func (o AppPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in AppPermissionsRequest as +// a slice of AppAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *AppPermissionsRequest) GetAccessControlList(ctx context.Context) ([]AppAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AppAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in AppPermissionsRequest. +func (o *AppPermissionsRequest) SetAccessControlList(ctx context.Context, v []AppAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type AppResource struct { // Description of the App Resource. Description types.String `tfsdk:"description" tf:"optional"` @@ -705,6 +987,110 @@ func (o AppResource) Type(ctx context.Context) attr.Type { } } +// GetJob returns the value of the Job field in AppResource as +// a AppResourceJob value. +// If the field is unknown or null, the boolean return value is false. +func (o *AppResource) GetJob(ctx context.Context) (AppResourceJob, bool) { + var e AppResourceJob + if o.Job.IsNull() || o.Job.IsUnknown() { + return e, false + } + var v []AppResourceJob + d := o.Job.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetJob sets the value of the Job field in AppResource. +func (o *AppResource) SetJob(ctx context.Context, v AppResourceJob) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job"] + o.Job = types.ListValueMust(t, vs) +} + +// GetSecret returns the value of the Secret field in AppResource as +// a AppResourceSecret value. +// If the field is unknown or null, the boolean return value is false. +func (o *AppResource) GetSecret(ctx context.Context) (AppResourceSecret, bool) { + var e AppResourceSecret + if o.Secret.IsNull() || o.Secret.IsUnknown() { + return e, false + } + var v []AppResourceSecret + d := o.Secret.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSecret sets the value of the Secret field in AppResource. +func (o *AppResource) SetSecret(ctx context.Context, v AppResourceSecret) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["secret"] + o.Secret = types.ListValueMust(t, vs) +} + +// GetServingEndpoint returns the value of the ServingEndpoint field in AppResource as +// a AppResourceServingEndpoint value. +// If the field is unknown or null, the boolean return value is false. +func (o *AppResource) GetServingEndpoint(ctx context.Context) (AppResourceServingEndpoint, bool) { + var e AppResourceServingEndpoint + if o.ServingEndpoint.IsNull() || o.ServingEndpoint.IsUnknown() { + return e, false + } + var v []AppResourceServingEndpoint + d := o.ServingEndpoint.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetServingEndpoint sets the value of the ServingEndpoint field in AppResource. +func (o *AppResource) SetServingEndpoint(ctx context.Context, v AppResourceServingEndpoint) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["serving_endpoint"] + o.ServingEndpoint = types.ListValueMust(t, vs) +} + +// GetSqlWarehouse returns the value of the SqlWarehouse field in AppResource as +// a AppResourceSqlWarehouse value. +// If the field is unknown or null, the boolean return value is false. +func (o *AppResource) GetSqlWarehouse(ctx context.Context) (AppResourceSqlWarehouse, bool) { + var e AppResourceSqlWarehouse + if o.SqlWarehouse.IsNull() || o.SqlWarehouse.IsUnknown() { + return e, false + } + var v []AppResourceSqlWarehouse + d := o.SqlWarehouse.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlWarehouse sets the value of the SqlWarehouse field in AppResource. +func (o *AppResource) SetSqlWarehouse(ctx context.Context, v AppResourceSqlWarehouse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_warehouse"] + o.SqlWarehouse = types.ListValueMust(t, vs) +} + type AppResourceJob struct { // Id of the job to grant permission on. Id types.String `tfsdk:"id" tf:""` @@ -1039,6 +1425,32 @@ func (o CreateAppDeploymentRequest) Type(ctx context.Context) attr.Type { } } +// GetAppDeployment returns the value of the AppDeployment field in CreateAppDeploymentRequest as +// a AppDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateAppDeploymentRequest) GetAppDeployment(ctx context.Context) (AppDeployment, bool) { + var e AppDeployment + if o.AppDeployment.IsNull() || o.AppDeployment.IsUnknown() { + return e, false + } + var v []AppDeployment + d := o.AppDeployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAppDeployment sets the value of the AppDeployment field in CreateAppDeploymentRequest. +func (o *CreateAppDeploymentRequest) SetAppDeployment(ctx context.Context, v AppDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app_deployment"] + o.AppDeployment = types.ListValueMust(t, vs) +} + // Create an app type CreateAppRequest struct { App types.List `tfsdk:"app" tf:"optional,object"` @@ -1085,6 +1497,32 @@ func (o CreateAppRequest) Type(ctx context.Context) attr.Type { } } +// GetApp returns the value of the App field in CreateAppRequest as +// a App value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateAppRequest) GetApp(ctx context.Context) (App, bool) { + var e App + if o.App.IsNull() || o.App.IsUnknown() { + return e, false + } + var v []App + d := o.App.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetApp sets the value of the App field in CreateAppRequest. +func (o *CreateAppRequest) SetApp(ctx context.Context, v App) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app"] + o.App = types.ListValueMust(t, vs) +} + // Delete an app type DeleteAppRequest struct { // The name of the app. @@ -1264,6 +1702,31 @@ func (o GetAppPermissionLevelsResponse) Type(ctx context.Context) attr.Type { } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetAppPermissionLevelsResponse as +// a slice of AppPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetAppPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]AppPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []AppPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetAppPermissionLevelsResponse. +func (o *GetAppPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []AppPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get app permissions type GetAppPermissionsRequest struct { // The app for which to get or manage permissions. @@ -1452,6 +1915,31 @@ func (o ListAppDeploymentsResponse) Type(ctx context.Context) attr.Type { } } +// GetAppDeployments returns the value of the AppDeployments field in ListAppDeploymentsResponse as +// a slice of AppDeployment values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAppDeploymentsResponse) GetAppDeployments(ctx context.Context) ([]AppDeployment, bool) { + if o.AppDeployments.IsNull() || o.AppDeployments.IsUnknown() { + return nil, false + } + var v []AppDeployment + d := o.AppDeployments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAppDeployments sets the value of the AppDeployments field in ListAppDeploymentsResponse. +func (o *ListAppDeploymentsResponse) SetAppDeployments(ctx context.Context, v []AppDeployment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app_deployments"] + o.AppDeployments = types.ListValueMust(t, vs) +} + // List apps type ListAppsRequest struct { // Upper bound for items returned. @@ -1549,6 +2037,31 @@ func (o ListAppsResponse) Type(ctx context.Context) attr.Type { } } +// GetApps returns the value of the Apps field in ListAppsResponse as +// a slice of App values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAppsResponse) GetApps(ctx context.Context) ([]App, bool) { + if o.Apps.IsNull() || o.Apps.IsUnknown() { + return nil, false + } + var v []App + d := o.Apps.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetApps sets the value of the Apps field in ListAppsResponse. +func (o *ListAppsResponse) SetApps(ctx context.Context, v []App) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + o.Apps = types.ListValueMust(t, vs) +} + type StartAppRequest struct { // The name of the app. Name types.String `tfsdk:"-"` @@ -1684,7 +2197,28 @@ func (o UpdateAppRequest) Type(ctx context.Context) attr.Type { } } -// Permission level +// GetApp returns the value of the App field in UpdateAppRequest as +// a App value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateAppRequest) GetApp(ctx context.Context) (App, bool) { + var e App + if o.App.IsNull() || o.App.IsUnknown() { + return e, false + } + var v []App + d := o.App.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// Permission to grant on the secret scope. Supported permissions are: "READ", -// "WRITE", "MANAGE". +// SetApp sets the value of the App field in UpdateAppRequest. +func (o *UpdateAppRequest) SetApp(ctx context.Context, v App) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app"] + o.App = types.ListValueMust(t, vs) +} diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 66e3e57344..6c5decf04b 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -139,6 +140,31 @@ func (o AlertConfiguration) Type(ctx context.Context) attr.Type { } } +// GetActionConfigurations returns the value of the ActionConfigurations field in AlertConfiguration as +// a slice of ActionConfiguration values. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertConfiguration) GetActionConfigurations(ctx context.Context) ([]ActionConfiguration, bool) { + if o.ActionConfigurations.IsNull() || o.ActionConfigurations.IsUnknown() { + return nil, false + } + var v []ActionConfiguration + d := o.ActionConfigurations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetActionConfigurations sets the value of the ActionConfigurations field in AlertConfiguration. +func (o *AlertConfiguration) SetActionConfigurations(ctx context.Context, v []ActionConfiguration) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["action_configurations"] + o.ActionConfigurations = types.ListValueMust(t, vs) +} + type BudgetConfiguration struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -216,6 +242,57 @@ func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { } } +// GetAlertConfigurations returns the value of the AlertConfigurations field in BudgetConfiguration as +// a slice of AlertConfiguration values. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfiguration) GetAlertConfigurations(ctx context.Context) ([]AlertConfiguration, bool) { + if o.AlertConfigurations.IsNull() || o.AlertConfigurations.IsUnknown() { + return nil, false + } + var v []AlertConfiguration + d := o.AlertConfigurations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAlertConfigurations sets the value of the AlertConfigurations field in BudgetConfiguration. +func (o *BudgetConfiguration) SetAlertConfigurations(ctx context.Context, v []AlertConfiguration) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_configurations"] + o.AlertConfigurations = types.ListValueMust(t, vs) +} + +// GetFilter returns the value of the Filter field in BudgetConfiguration as +// a BudgetConfigurationFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfiguration) GetFilter(ctx context.Context) (BudgetConfigurationFilter, bool) { + var e BudgetConfigurationFilter + if o.Filter.IsNull() || o.Filter.IsUnknown() { + return e, false + } + var v []BudgetConfigurationFilter + d := o.Filter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilter sets the value of the Filter field in BudgetConfiguration. +func (o *BudgetConfiguration) SetFilter(ctx context.Context, v BudgetConfigurationFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter"] + o.Filter = types.ListValueMust(t, vs) +} + type BudgetConfigurationFilter struct { // A list of tag keys and values that will limit the budget to usage that // includes those specific custom tags. Tags are case-sensitive and should @@ -271,6 +348,57 @@ func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in BudgetConfigurationFilter as +// a slice of BudgetConfigurationFilterTagClause values. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfigurationFilter) GetTags(ctx context.Context) ([]BudgetConfigurationFilterTagClause, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []BudgetConfigurationFilterTagClause + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in BudgetConfigurationFilter. +func (o *BudgetConfigurationFilter) SetTags(ctx context.Context, v []BudgetConfigurationFilterTagClause) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + +// GetWorkspaceId returns the value of the WorkspaceId field in BudgetConfigurationFilter as +// a BudgetConfigurationFilterWorkspaceIdClause value. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfigurationFilter) GetWorkspaceId(ctx context.Context) (BudgetConfigurationFilterWorkspaceIdClause, bool) { + var e BudgetConfigurationFilterWorkspaceIdClause + if o.WorkspaceId.IsNull() || o.WorkspaceId.IsUnknown() { + return e, false + } + var v []BudgetConfigurationFilterWorkspaceIdClause + d := o.WorkspaceId.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkspaceId sets the value of the WorkspaceId field in BudgetConfigurationFilter. +func (o *BudgetConfigurationFilter) SetWorkspaceId(ctx context.Context, v BudgetConfigurationFilterWorkspaceIdClause) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_id"] + o.WorkspaceId = types.ListValueMust(t, vs) +} + type BudgetConfigurationFilterClause struct { Operator types.String `tfsdk:"operator" tf:"optional"` @@ -320,6 +448,31 @@ func (o BudgetConfigurationFilterClause) Type(ctx context.Context) attr.Type { } } +// GetValues returns the value of the Values field in BudgetConfigurationFilterClause as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfigurationFilterClause) GetValues(ctx context.Context) ([]types.String, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in BudgetConfigurationFilterClause. +func (o *BudgetConfigurationFilterClause) SetValues(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + o.Values = types.ListValueMust(t, vs) +} + type BudgetConfigurationFilterTagClause struct { Key types.String `tfsdk:"key" tf:"optional"` @@ -369,6 +522,32 @@ func (o BudgetConfigurationFilterTagClause) Type(ctx context.Context) attr.Type } } +// GetValue returns the value of the Value field in BudgetConfigurationFilterTagClause as +// a BudgetConfigurationFilterClause value. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfigurationFilterTagClause) GetValue(ctx context.Context) (BudgetConfigurationFilterClause, bool) { + var e BudgetConfigurationFilterClause + if o.Value.IsNull() || o.Value.IsUnknown() { + return e, false + } + var v []BudgetConfigurationFilterClause + d := o.Value.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetValue sets the value of the Value field in BudgetConfigurationFilterTagClause. +func (o *BudgetConfigurationFilterTagClause) SetValue(ctx context.Context, v BudgetConfigurationFilterClause) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["value"] + o.Value = types.ListValueMust(t, vs) +} + type BudgetConfigurationFilterWorkspaceIdClause struct { Operator types.String `tfsdk:"operator" tf:"optional"` @@ -418,6 +597,31 @@ func (o BudgetConfigurationFilterWorkspaceIdClause) Type(ctx context.Context) at } } +// GetValues returns the value of the Values field in BudgetConfigurationFilterWorkspaceIdClause as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *BudgetConfigurationFilterWorkspaceIdClause) GetValues(ctx context.Context) ([]types.Int64, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in BudgetConfigurationFilterWorkspaceIdClause. +func (o *BudgetConfigurationFilterWorkspaceIdClause) SetValues(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + o.Values = types.ListValueMust(t, vs) +} + type CreateBillingUsageDashboardRequest struct { // Workspace level usage dashboard shows usage data for the specified // workspace ID. Global level usage dashboard shows usage data for all @@ -574,6 +778,57 @@ func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { } } +// GetAlertConfigurations returns the value of the AlertConfigurations field in CreateBudgetConfigurationBudget as +// a slice of CreateBudgetConfigurationBudgetAlertConfigurations values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateBudgetConfigurationBudget) GetAlertConfigurations(ctx context.Context) ([]CreateBudgetConfigurationBudgetAlertConfigurations, bool) { + if o.AlertConfigurations.IsNull() || o.AlertConfigurations.IsUnknown() { + return nil, false + } + var v []CreateBudgetConfigurationBudgetAlertConfigurations + d := o.AlertConfigurations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAlertConfigurations sets the value of the AlertConfigurations field in CreateBudgetConfigurationBudget. +func (o *CreateBudgetConfigurationBudget) SetAlertConfigurations(ctx context.Context, v []CreateBudgetConfigurationBudgetAlertConfigurations) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_configurations"] + o.AlertConfigurations = types.ListValueMust(t, vs) +} + +// GetFilter returns the value of the Filter field in CreateBudgetConfigurationBudget as +// a BudgetConfigurationFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateBudgetConfigurationBudget) GetFilter(ctx context.Context) (BudgetConfigurationFilter, bool) { + var e BudgetConfigurationFilter + if o.Filter.IsNull() || o.Filter.IsUnknown() { + return e, false + } + var v []BudgetConfigurationFilter + d := o.Filter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilter sets the value of the Filter field in CreateBudgetConfigurationBudget. +func (o *CreateBudgetConfigurationBudget) SetFilter(ctx context.Context, v BudgetConfigurationFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter"] + o.Filter = types.ListValueMust(t, vs) +} + type CreateBudgetConfigurationBudgetActionConfigurations struct { // The type of the action. ActionType types.String `tfsdk:"action_type" tf:"optional"` @@ -686,6 +941,31 @@ func (o CreateBudgetConfigurationBudgetAlertConfigurations) Type(ctx context.Con } } +// GetActionConfigurations returns the value of the ActionConfigurations field in CreateBudgetConfigurationBudgetAlertConfigurations as +// a slice of CreateBudgetConfigurationBudgetActionConfigurations values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateBudgetConfigurationBudgetAlertConfigurations) GetActionConfigurations(ctx context.Context) ([]CreateBudgetConfigurationBudgetActionConfigurations, bool) { + if o.ActionConfigurations.IsNull() || o.ActionConfigurations.IsUnknown() { + return nil, false + } + var v []CreateBudgetConfigurationBudgetActionConfigurations + d := o.ActionConfigurations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetActionConfigurations sets the value of the ActionConfigurations field in CreateBudgetConfigurationBudgetAlertConfigurations. +func (o *CreateBudgetConfigurationBudgetAlertConfigurations) SetActionConfigurations(ctx context.Context, v []CreateBudgetConfigurationBudgetActionConfigurations) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["action_configurations"] + o.ActionConfigurations = types.ListValueMust(t, vs) +} + type CreateBudgetConfigurationRequest struct { // Properties of the new budget configuration. Budget types.List `tfsdk:"budget" tf:"object"` @@ -732,6 +1012,32 @@ func (o CreateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { } } +// GetBudget returns the value of the Budget field in CreateBudgetConfigurationRequest as +// a CreateBudgetConfigurationBudget value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateBudgetConfigurationRequest) GetBudget(ctx context.Context) (CreateBudgetConfigurationBudget, bool) { + var e CreateBudgetConfigurationBudget + if o.Budget.IsNull() || o.Budget.IsUnknown() { + return e, false + } + var v []CreateBudgetConfigurationBudget + d := o.Budget.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBudget sets the value of the Budget field in CreateBudgetConfigurationRequest. +func (o *CreateBudgetConfigurationRequest) SetBudget(ctx context.Context, v CreateBudgetConfigurationBudget) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budget"] + o.Budget = types.ListValueMust(t, vs) +} + type CreateBudgetConfigurationResponse struct { // The created budget configuration. Budget types.List `tfsdk:"budget" tf:"optional,object"` @@ -778,6 +1084,32 @@ func (o CreateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { } } +// GetBudget returns the value of the Budget field in CreateBudgetConfigurationResponse as +// a BudgetConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateBudgetConfigurationResponse) GetBudget(ctx context.Context) (BudgetConfiguration, bool) { + var e BudgetConfiguration + if o.Budget.IsNull() || o.Budget.IsUnknown() { + return e, false + } + var v []BudgetConfiguration + d := o.Budget.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBudget sets the value of the Budget field in CreateBudgetConfigurationResponse. +func (o *CreateBudgetConfigurationResponse) SetBudget(ctx context.Context, v BudgetConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budget"] + o.Budget = types.ListValueMust(t, vs) +} + type CreateLogDeliveryConfigurationParams struct { // The optional human-readable name of the log delivery configuration. // Defaults to empty. @@ -907,6 +1239,31 @@ func (o CreateLogDeliveryConfigurationParams) Type(ctx context.Context) attr.Typ } } +// GetWorkspaceIdsFilter returns the value of the WorkspaceIdsFilter field in CreateLogDeliveryConfigurationParams as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateLogDeliveryConfigurationParams) GetWorkspaceIdsFilter(ctx context.Context) ([]types.Int64, bool) { + if o.WorkspaceIdsFilter.IsNull() || o.WorkspaceIdsFilter.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.WorkspaceIdsFilter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWorkspaceIdsFilter sets the value of the WorkspaceIdsFilter field in CreateLogDeliveryConfigurationParams. +func (o *CreateLogDeliveryConfigurationParams) SetWorkspaceIdsFilter(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_ids_filter"] + o.WorkspaceIdsFilter = types.ListValueMust(t, vs) +} + // Delete budget type DeleteBudgetConfigurationRequest struct { // The Databricks budget configuration ID. @@ -1266,6 +1623,32 @@ func (o GetBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { } } +// GetBudget returns the value of the Budget field in GetBudgetConfigurationResponse as +// a BudgetConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetBudgetConfigurationResponse) GetBudget(ctx context.Context) (BudgetConfiguration, bool) { + var e BudgetConfiguration + if o.Budget.IsNull() || o.Budget.IsUnknown() { + return e, false + } + var v []BudgetConfiguration + d := o.Budget.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBudget sets the value of the Budget field in GetBudgetConfigurationResponse. +func (o *GetBudgetConfigurationResponse) SetBudget(ctx context.Context, v BudgetConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budget"] + o.Budget = types.ListValueMust(t, vs) +} + // Get log delivery configuration type GetLogDeliveryRequest struct { // Databricks log delivery configuration ID @@ -1404,6 +1787,31 @@ func (o ListBudgetConfigurationsResponse) Type(ctx context.Context) attr.Type { } } +// GetBudgets returns the value of the Budgets field in ListBudgetConfigurationsResponse as +// a slice of BudgetConfiguration values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListBudgetConfigurationsResponse) GetBudgets(ctx context.Context) ([]BudgetConfiguration, bool) { + if o.Budgets.IsNull() || o.Budgets.IsUnknown() { + return nil, false + } + var v []BudgetConfiguration + d := o.Budgets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetBudgets sets the value of the Budgets field in ListBudgetConfigurationsResponse. +func (o *ListBudgetConfigurationsResponse) SetBudgets(ctx context.Context, v []BudgetConfiguration) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budgets"] + o.Budgets = types.ListValueMust(t, vs) +} + // Get all log delivery configurations type ListLogDeliveryRequest struct { // Filter by credential configuration ID. @@ -1609,6 +2017,57 @@ func (o LogDeliveryConfiguration) Type(ctx context.Context) attr.Type { } } +// GetLogDeliveryStatus returns the value of the LogDeliveryStatus field in LogDeliveryConfiguration as +// a LogDeliveryStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *LogDeliveryConfiguration) GetLogDeliveryStatus(ctx context.Context) (LogDeliveryStatus, bool) { + var e LogDeliveryStatus + if o.LogDeliveryStatus.IsNull() || o.LogDeliveryStatus.IsUnknown() { + return e, false + } + var v []LogDeliveryStatus + d := o.LogDeliveryStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetLogDeliveryStatus sets the value of the LogDeliveryStatus field in LogDeliveryConfiguration. +func (o *LogDeliveryConfiguration) SetLogDeliveryStatus(ctx context.Context, v LogDeliveryStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["log_delivery_status"] + o.LogDeliveryStatus = types.ListValueMust(t, vs) +} + +// GetWorkspaceIdsFilter returns the value of the WorkspaceIdsFilter field in LogDeliveryConfiguration as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *LogDeliveryConfiguration) GetWorkspaceIdsFilter(ctx context.Context) ([]types.Int64, bool) { + if o.WorkspaceIdsFilter.IsNull() || o.WorkspaceIdsFilter.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.WorkspaceIdsFilter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWorkspaceIdsFilter sets the value of the WorkspaceIdsFilter field in LogDeliveryConfiguration. +func (o *LogDeliveryConfiguration) SetWorkspaceIdsFilter(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_ids_filter"] + o.WorkspaceIdsFilter = types.ListValueMust(t, vs) +} + // Databricks log delivery status. type LogDeliveryStatus struct { // The UTC time for the latest log delivery attempt. @@ -1780,6 +2239,57 @@ func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { } } +// GetAlertConfigurations returns the value of the AlertConfigurations field in UpdateBudgetConfigurationBudget as +// a slice of AlertConfiguration values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateBudgetConfigurationBudget) GetAlertConfigurations(ctx context.Context) ([]AlertConfiguration, bool) { + if o.AlertConfigurations.IsNull() || o.AlertConfigurations.IsUnknown() { + return nil, false + } + var v []AlertConfiguration + d := o.AlertConfigurations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAlertConfigurations sets the value of the AlertConfigurations field in UpdateBudgetConfigurationBudget. +func (o *UpdateBudgetConfigurationBudget) SetAlertConfigurations(ctx context.Context, v []AlertConfiguration) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_configurations"] + o.AlertConfigurations = types.ListValueMust(t, vs) +} + +// GetFilter returns the value of the Filter field in UpdateBudgetConfigurationBudget as +// a BudgetConfigurationFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateBudgetConfigurationBudget) GetFilter(ctx context.Context) (BudgetConfigurationFilter, bool) { + var e BudgetConfigurationFilter + if o.Filter.IsNull() || o.Filter.IsUnknown() { + return e, false + } + var v []BudgetConfigurationFilter + d := o.Filter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilter sets the value of the Filter field in UpdateBudgetConfigurationBudget. +func (o *UpdateBudgetConfigurationBudget) SetFilter(ctx context.Context, v BudgetConfigurationFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter"] + o.Filter = types.ListValueMust(t, vs) +} + type UpdateBudgetConfigurationRequest struct { // The updated budget. This will overwrite the budget specified by the // budget ID. @@ -1831,6 +2341,32 @@ func (o UpdateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { } } +// GetBudget returns the value of the Budget field in UpdateBudgetConfigurationRequest as +// a UpdateBudgetConfigurationBudget value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateBudgetConfigurationRequest) GetBudget(ctx context.Context) (UpdateBudgetConfigurationBudget, bool) { + var e UpdateBudgetConfigurationBudget + if o.Budget.IsNull() || o.Budget.IsUnknown() { + return e, false + } + var v []UpdateBudgetConfigurationBudget + d := o.Budget.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBudget sets the value of the Budget field in UpdateBudgetConfigurationRequest. +func (o *UpdateBudgetConfigurationRequest) SetBudget(ctx context.Context, v UpdateBudgetConfigurationBudget) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budget"] + o.Budget = types.ListValueMust(t, vs) +} + type UpdateBudgetConfigurationResponse struct { // The updated budget. Budget types.List `tfsdk:"budget" tf:"optional,object"` @@ -1877,6 +2413,32 @@ func (o UpdateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { } } +// GetBudget returns the value of the Budget field in UpdateBudgetConfigurationResponse as +// a BudgetConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateBudgetConfigurationResponse) GetBudget(ctx context.Context) (BudgetConfiguration, bool) { + var e BudgetConfiguration + if o.Budget.IsNull() || o.Budget.IsUnknown() { + return e, false + } + var v []BudgetConfiguration + d := o.Budget.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBudget sets the value of the Budget field in UpdateBudgetConfigurationResponse. +func (o *UpdateBudgetConfigurationResponse) SetBudget(ctx context.Context, v BudgetConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budget"] + o.Budget = types.ListValueMust(t, vs) +} + type UpdateLogDeliveryConfigurationStatusRequest struct { // Databricks log delivery configuration ID LogDeliveryConfigurationId types.String `tfsdk:"-"` @@ -1972,6 +2534,32 @@ func (o WrappedCreateLogDeliveryConfiguration) Type(ctx context.Context) attr.Ty } } +// GetLogDeliveryConfiguration returns the value of the LogDeliveryConfiguration field in WrappedCreateLogDeliveryConfiguration as +// a CreateLogDeliveryConfigurationParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *WrappedCreateLogDeliveryConfiguration) GetLogDeliveryConfiguration(ctx context.Context) (CreateLogDeliveryConfigurationParams, bool) { + var e CreateLogDeliveryConfigurationParams + if o.LogDeliveryConfiguration.IsNull() || o.LogDeliveryConfiguration.IsUnknown() { + return e, false + } + var v []CreateLogDeliveryConfigurationParams + d := o.LogDeliveryConfiguration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetLogDeliveryConfiguration sets the value of the LogDeliveryConfiguration field in WrappedCreateLogDeliveryConfiguration. +func (o *WrappedCreateLogDeliveryConfiguration) SetLogDeliveryConfiguration(ctx context.Context, v CreateLogDeliveryConfigurationParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["log_delivery_configuration"] + o.LogDeliveryConfiguration = types.ListValueMust(t, vs) +} + type WrappedLogDeliveryConfiguration struct { LogDeliveryConfiguration types.List `tfsdk:"log_delivery_configuration" tf:"optional,object"` } @@ -2017,6 +2605,32 @@ func (o WrappedLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { } } +// GetLogDeliveryConfiguration returns the value of the LogDeliveryConfiguration field in WrappedLogDeliveryConfiguration as +// a LogDeliveryConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *WrappedLogDeliveryConfiguration) GetLogDeliveryConfiguration(ctx context.Context) (LogDeliveryConfiguration, bool) { + var e LogDeliveryConfiguration + if o.LogDeliveryConfiguration.IsNull() || o.LogDeliveryConfiguration.IsUnknown() { + return e, false + } + var v []LogDeliveryConfiguration + d := o.LogDeliveryConfiguration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetLogDeliveryConfiguration sets the value of the LogDeliveryConfiguration field in WrappedLogDeliveryConfiguration. +func (o *WrappedLogDeliveryConfiguration) SetLogDeliveryConfiguration(ctx context.Context, v LogDeliveryConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["log_delivery_configuration"] + o.LogDeliveryConfiguration = types.ListValueMust(t, vs) +} + type WrappedLogDeliveryConfigurations struct { LogDeliveryConfigurations types.List `tfsdk:"log_delivery_configurations" tf:"optional"` } @@ -2062,42 +2676,27 @@ func (o WrappedLogDeliveryConfigurations) Type(ctx context.Context) attr.Type { } } -// The status string for log delivery. Possible values are: * `CREATED`: There -// were no log delivery attempts since the config was created. * `SUCCEEDED`: -// The latest attempt of log delivery has succeeded completely. * -// `USER_FAILURE`: The latest attempt of log delivery failed because of -// misconfiguration of customer provided permissions on role or storage. * -// `SYSTEM_FAILURE`: The latest attempt of log delivery failed because of an -// Databricks internal error. Contact support if it doesn't go away soon. * -// `NOT_FOUND`: The log delivery status as the configuration has been disabled -// since the release of this feature or there are no workspaces in the account. - -// Status of log delivery configuration. Set to `ENABLED` (enabled) or -// `DISABLED` (disabled). Defaults to `ENABLED`. You can [enable or disable the -// configuration](#operation/patch-log-delivery-config-status) later. Deletion -// of a configuration is not supported, so disable a log delivery configuration -// that is no longer needed. - -// Log delivery type. Supported values are: -// -// * `BILLABLE_USAGE` — Configure [billable usage log delivery]. For the CSV -// schema, see the [View billable usage]. -// -// * `AUDIT_LOGS` — Configure [audit log delivery]. For the JSON schema, see -// [Configure audit logging] -// -// [Configure audit logging]: https://docs.databricks.com/administration-guide/account-settings/audit-logs.html -// [View billable usage]: https://docs.databricks.com/administration-guide/account-settings/usage.html -// [audit log delivery]: https://docs.databricks.com/administration-guide/account-settings/audit-logs.html -// [billable usage log delivery]: https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html - -// The file type of log delivery. -// -// * If `log_type` is `BILLABLE_USAGE`, this value must be `CSV`. Only the CSV -// (comma-separated values) format is supported. For the schema, see the [View -// billable usage] * If `log_type` is `AUDIT_LOGS`, this value must be `JSON`. -// Only the JSON (JavaScript Object Notation) format is supported. For the -// schema, see the [Configuring audit logs]. -// -// [Configuring audit logs]: https://docs.databricks.com/administration-guide/account-settings/audit-logs.html -// [View billable usage]: https://docs.databricks.com/administration-guide/account-settings/usage.html +// GetLogDeliveryConfigurations returns the value of the LogDeliveryConfigurations field in WrappedLogDeliveryConfigurations as +// a slice of LogDeliveryConfiguration values. +// If the field is unknown or null, the boolean return value is false. +func (o *WrappedLogDeliveryConfigurations) GetLogDeliveryConfigurations(ctx context.Context) ([]LogDeliveryConfiguration, bool) { + if o.LogDeliveryConfigurations.IsNull() || o.LogDeliveryConfigurations.IsUnknown() { + return nil, false + } + var v []LogDeliveryConfiguration + d := o.LogDeliveryConfigurations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLogDeliveryConfigurations sets the value of the LogDeliveryConfigurations field in WrappedLogDeliveryConfigurations. +func (o *WrappedLogDeliveryConfigurations) SetLogDeliveryConfigurations(ctx context.Context, v []LogDeliveryConfiguration) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["log_delivery_configurations"] + o.LogDeliveryConfigurations = types.ListValueMust(t, vs) +} diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index fce3e2ef05..4b36a1f2da 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -64,6 +65,32 @@ func (o AccountsCreateMetastore) Type(ctx context.Context) attr.Type { } } +// GetMetastoreInfo returns the value of the MetastoreInfo field in AccountsCreateMetastore as +// a CreateMetastore value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsCreateMetastore) GetMetastoreInfo(ctx context.Context) (CreateMetastore, bool) { + var e CreateMetastore + if o.MetastoreInfo.IsNull() || o.MetastoreInfo.IsUnknown() { + return e, false + } + var v []CreateMetastore + d := o.MetastoreInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetastoreInfo sets the value of the MetastoreInfo field in AccountsCreateMetastore. +func (o *AccountsCreateMetastore) SetMetastoreInfo(ctx context.Context, v CreateMetastore) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastore_info"] + o.MetastoreInfo = types.ListValueMust(t, vs) +} + type AccountsCreateMetastoreAssignment struct { MetastoreAssignment types.List `tfsdk:"metastore_assignment" tf:"optional,object"` // Unity Catalog metastore ID @@ -117,6 +144,32 @@ func (o AccountsCreateMetastoreAssignment) Type(ctx context.Context) attr.Type { } } +// GetMetastoreAssignment returns the value of the MetastoreAssignment field in AccountsCreateMetastoreAssignment as +// a CreateMetastoreAssignment value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsCreateMetastoreAssignment) GetMetastoreAssignment(ctx context.Context) (CreateMetastoreAssignment, bool) { + var e CreateMetastoreAssignment + if o.MetastoreAssignment.IsNull() || o.MetastoreAssignment.IsUnknown() { + return e, false + } + var v []CreateMetastoreAssignment + d := o.MetastoreAssignment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetastoreAssignment sets the value of the MetastoreAssignment field in AccountsCreateMetastoreAssignment. +func (o *AccountsCreateMetastoreAssignment) SetMetastoreAssignment(ctx context.Context, v CreateMetastoreAssignment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastore_assignment"] + o.MetastoreAssignment = types.ListValueMust(t, vs) +} + type AccountsCreateStorageCredential struct { CredentialInfo types.List `tfsdk:"credential_info" tf:"optional,object"` // Unity Catalog metastore ID @@ -166,6 +219,32 @@ func (o AccountsCreateStorageCredential) Type(ctx context.Context) attr.Type { } } +// GetCredentialInfo returns the value of the CredentialInfo field in AccountsCreateStorageCredential as +// a CreateStorageCredential value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsCreateStorageCredential) GetCredentialInfo(ctx context.Context) (CreateStorageCredential, bool) { + var e CreateStorageCredential + if o.CredentialInfo.IsNull() || o.CredentialInfo.IsUnknown() { + return e, false + } + var v []CreateStorageCredential + d := o.CredentialInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCredentialInfo sets the value of the CredentialInfo field in AccountsCreateStorageCredential. +func (o *AccountsCreateStorageCredential) SetCredentialInfo(ctx context.Context, v CreateStorageCredential) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credential_info"] + o.CredentialInfo = types.ListValueMust(t, vs) +} + type AccountsMetastoreAssignment struct { MetastoreAssignment types.List `tfsdk:"metastore_assignment" tf:"optional,object"` } @@ -211,6 +290,32 @@ func (o AccountsMetastoreAssignment) Type(ctx context.Context) attr.Type { } } +// GetMetastoreAssignment returns the value of the MetastoreAssignment field in AccountsMetastoreAssignment as +// a MetastoreAssignment value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsMetastoreAssignment) GetMetastoreAssignment(ctx context.Context) (MetastoreAssignment, bool) { + var e MetastoreAssignment + if o.MetastoreAssignment.IsNull() || o.MetastoreAssignment.IsUnknown() { + return e, false + } + var v []MetastoreAssignment + d := o.MetastoreAssignment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetastoreAssignment sets the value of the MetastoreAssignment field in AccountsMetastoreAssignment. +func (o *AccountsMetastoreAssignment) SetMetastoreAssignment(ctx context.Context, v MetastoreAssignment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastore_assignment"] + o.MetastoreAssignment = types.ListValueMust(t, vs) +} + type AccountsMetastoreInfo struct { MetastoreInfo types.List `tfsdk:"metastore_info" tf:"optional,object"` } @@ -256,6 +361,32 @@ func (o AccountsMetastoreInfo) Type(ctx context.Context) attr.Type { } } +// GetMetastoreInfo returns the value of the MetastoreInfo field in AccountsMetastoreInfo as +// a MetastoreInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsMetastoreInfo) GetMetastoreInfo(ctx context.Context) (MetastoreInfo, bool) { + var e MetastoreInfo + if o.MetastoreInfo.IsNull() || o.MetastoreInfo.IsUnknown() { + return e, false + } + var v []MetastoreInfo + d := o.MetastoreInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetastoreInfo sets the value of the MetastoreInfo field in AccountsMetastoreInfo. +func (o *AccountsMetastoreInfo) SetMetastoreInfo(ctx context.Context, v MetastoreInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastore_info"] + o.MetastoreInfo = types.ListValueMust(t, vs) +} + type AccountsStorageCredentialInfo struct { CredentialInfo types.List `tfsdk:"credential_info" tf:"optional,object"` } @@ -301,6 +432,32 @@ func (o AccountsStorageCredentialInfo) Type(ctx context.Context) attr.Type { } } +// GetCredentialInfo returns the value of the CredentialInfo field in AccountsStorageCredentialInfo as +// a StorageCredentialInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsStorageCredentialInfo) GetCredentialInfo(ctx context.Context) (StorageCredentialInfo, bool) { + var e StorageCredentialInfo + if o.CredentialInfo.IsNull() || o.CredentialInfo.IsUnknown() { + return e, false + } + var v []StorageCredentialInfo + d := o.CredentialInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCredentialInfo sets the value of the CredentialInfo field in AccountsStorageCredentialInfo. +func (o *AccountsStorageCredentialInfo) SetCredentialInfo(ctx context.Context, v StorageCredentialInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credential_info"] + o.CredentialInfo = types.ListValueMust(t, vs) +} + type AccountsUpdateMetastore struct { // Unity Catalog metastore ID MetastoreId types.String `tfsdk:"-"` @@ -351,6 +508,32 @@ func (o AccountsUpdateMetastore) Type(ctx context.Context) attr.Type { } } +// GetMetastoreInfo returns the value of the MetastoreInfo field in AccountsUpdateMetastore as +// a UpdateMetastore value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsUpdateMetastore) GetMetastoreInfo(ctx context.Context) (UpdateMetastore, bool) { + var e UpdateMetastore + if o.MetastoreInfo.IsNull() || o.MetastoreInfo.IsUnknown() { + return e, false + } + var v []UpdateMetastore + d := o.MetastoreInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetastoreInfo sets the value of the MetastoreInfo field in AccountsUpdateMetastore. +func (o *AccountsUpdateMetastore) SetMetastoreInfo(ctx context.Context, v UpdateMetastore) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastore_info"] + o.MetastoreInfo = types.ListValueMust(t, vs) +} + type AccountsUpdateMetastoreAssignment struct { MetastoreAssignment types.List `tfsdk:"metastore_assignment" tf:"optional,object"` // Unity Catalog metastore ID @@ -404,6 +587,32 @@ func (o AccountsUpdateMetastoreAssignment) Type(ctx context.Context) attr.Type { } } +// GetMetastoreAssignment returns the value of the MetastoreAssignment field in AccountsUpdateMetastoreAssignment as +// a UpdateMetastoreAssignment value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsUpdateMetastoreAssignment) GetMetastoreAssignment(ctx context.Context) (UpdateMetastoreAssignment, bool) { + var e UpdateMetastoreAssignment + if o.MetastoreAssignment.IsNull() || o.MetastoreAssignment.IsUnknown() { + return e, false + } + var v []UpdateMetastoreAssignment + d := o.MetastoreAssignment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetastoreAssignment sets the value of the MetastoreAssignment field in AccountsUpdateMetastoreAssignment. +func (o *AccountsUpdateMetastoreAssignment) SetMetastoreAssignment(ctx context.Context, v UpdateMetastoreAssignment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastore_assignment"] + o.MetastoreAssignment = types.ListValueMust(t, vs) +} + type AccountsUpdateStorageCredential struct { CredentialInfo types.List `tfsdk:"credential_info" tf:"optional,object"` // Unity Catalog metastore ID @@ -457,6 +666,32 @@ func (o AccountsUpdateStorageCredential) Type(ctx context.Context) attr.Type { } } +// GetCredentialInfo returns the value of the CredentialInfo field in AccountsUpdateStorageCredential as +// a UpdateStorageCredential value. +// If the field is unknown or null, the boolean return value is false. +func (o *AccountsUpdateStorageCredential) GetCredentialInfo(ctx context.Context) (UpdateStorageCredential, bool) { + var e UpdateStorageCredential + if o.CredentialInfo.IsNull() || o.CredentialInfo.IsUnknown() { + return e, false + } + var v []UpdateStorageCredential + d := o.CredentialInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCredentialInfo sets the value of the CredentialInfo field in AccountsUpdateStorageCredential. +func (o *AccountsUpdateStorageCredential) SetCredentialInfo(ctx context.Context, v UpdateStorageCredential) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credential_info"] + o.CredentialInfo = types.ListValueMust(t, vs) +} + type ArtifactAllowlistInfo struct { // A list of allowed artifact match patterns. ArtifactMatchers types.List `tfsdk:"artifact_matchers" tf:"optional"` @@ -515,6 +750,31 @@ func (o ArtifactAllowlistInfo) Type(ctx context.Context) attr.Type { } } +// GetArtifactMatchers returns the value of the ArtifactMatchers field in ArtifactAllowlistInfo as +// a slice of ArtifactMatcher values. +// If the field is unknown or null, the boolean return value is false. +func (o *ArtifactAllowlistInfo) GetArtifactMatchers(ctx context.Context) ([]ArtifactMatcher, bool) { + if o.ArtifactMatchers.IsNull() || o.ArtifactMatchers.IsUnknown() { + return nil, false + } + var v []ArtifactMatcher + d := o.ArtifactMatchers.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetArtifactMatchers sets the value of the ArtifactMatchers field in ArtifactAllowlistInfo. +func (o *ArtifactAllowlistInfo) SetArtifactMatchers(ctx context.Context, v []ArtifactMatcher) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["artifact_matchers"] + o.ArtifactMatchers = types.ListValueMust(t, vs) +} + type ArtifactMatcher struct { // The artifact path or maven coordinate Artifact types.String `tfsdk:"artifact" tf:""` @@ -1354,6 +1614,108 @@ func (o CatalogInfo) Type(ctx context.Context) attr.Type { } } +// GetEffectivePredictiveOptimizationFlag returns the value of the EffectivePredictiveOptimizationFlag field in CatalogInfo as +// a EffectivePredictiveOptimizationFlag value. +// If the field is unknown or null, the boolean return value is false. +func (o *CatalogInfo) GetEffectivePredictiveOptimizationFlag(ctx context.Context) (EffectivePredictiveOptimizationFlag, bool) { + var e EffectivePredictiveOptimizationFlag + if o.EffectivePredictiveOptimizationFlag.IsNull() || o.EffectivePredictiveOptimizationFlag.IsUnknown() { + return e, false + } + var v []EffectivePredictiveOptimizationFlag + d := o.EffectivePredictiveOptimizationFlag.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEffectivePredictiveOptimizationFlag sets the value of the EffectivePredictiveOptimizationFlag field in CatalogInfo. +func (o *CatalogInfo) SetEffectivePredictiveOptimizationFlag(ctx context.Context, v EffectivePredictiveOptimizationFlag) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["effective_predictive_optimization_flag"] + o.EffectivePredictiveOptimizationFlag = types.ListValueMust(t, vs) +} + +// GetOptions returns the value of the Options field in CatalogInfo as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CatalogInfo) GetOptions(ctx context.Context) (map[string]types.String, bool) { + if o.Options.IsNull() || o.Options.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOptions sets the value of the Options field in CatalogInfo. +func (o *CatalogInfo) SetOptions(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.MapValueMust(t, vs) +} + +// GetProperties returns the value of the Properties field in CatalogInfo as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CatalogInfo) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in CatalogInfo. +func (o *CatalogInfo) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + +// GetProvisioningInfo returns the value of the ProvisioningInfo field in CatalogInfo as +// a ProvisioningInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CatalogInfo) GetProvisioningInfo(ctx context.Context) (ProvisioningInfo, bool) { + var e ProvisioningInfo + if o.ProvisioningInfo.IsNull() || o.ProvisioningInfo.IsUnknown() { + return e, false + } + var v []ProvisioningInfo + d := o.ProvisioningInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvisioningInfo sets the value of the ProvisioningInfo field in CatalogInfo. +func (o *CatalogInfo) SetProvisioningInfo(ctx context.Context, v ProvisioningInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provisioning_info"] + o.ProvisioningInfo = types.ListValueMust(t, vs) +} + type CloudflareApiToken struct { // The Cloudflare access key id of the token. AccessKeyId types.String `tfsdk:"access_key_id" tf:""` @@ -1494,6 +1856,32 @@ func (o ColumnInfo) Type(ctx context.Context) attr.Type { } } +// GetMask returns the value of the Mask field in ColumnInfo as +// a ColumnMask value. +// If the field is unknown or null, the boolean return value is false. +func (o *ColumnInfo) GetMask(ctx context.Context) (ColumnMask, bool) { + var e ColumnMask + if o.Mask.IsNull() || o.Mask.IsUnknown() { + return e, false + } + var v []ColumnMask + d := o.Mask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMask sets the value of the Mask field in ColumnInfo. +func (o *ColumnInfo) SetMask(ctx context.Context, v ColumnMask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["mask"] + o.Mask = types.ListValueMust(t, vs) +} + type ColumnMask struct { // The full name of the column mask SQL UDF. FunctionName types.String `tfsdk:"function_name" tf:"optional"` @@ -1547,6 +1935,31 @@ func (o ColumnMask) Type(ctx context.Context) attr.Type { } } +// GetUsingColumnNames returns the value of the UsingColumnNames field in ColumnMask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ColumnMask) GetUsingColumnNames(ctx context.Context) ([]types.String, bool) { + if o.UsingColumnNames.IsNull() || o.UsingColumnNames.IsUnknown() { + return nil, false + } + var v []types.String + d := o.UsingColumnNames.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUsingColumnNames sets the value of the UsingColumnNames field in ColumnMask. +func (o *ColumnMask) SetUsingColumnNames(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["using_column_names"] + o.UsingColumnNames = types.ListValueMust(t, vs) +} + type ConnectionInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1672,6 +2085,82 @@ func (o ConnectionInfo) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in ConnectionInfo as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ConnectionInfo) GetOptions(ctx context.Context) (map[string]types.String, bool) { + if o.Options.IsNull() || o.Options.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOptions sets the value of the Options field in ConnectionInfo. +func (o *ConnectionInfo) SetOptions(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.MapValueMust(t, vs) +} + +// GetProperties returns the value of the Properties field in ConnectionInfo as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ConnectionInfo) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in ConnectionInfo. +func (o *ConnectionInfo) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + +// GetProvisioningInfo returns the value of the ProvisioningInfo field in ConnectionInfo as +// a ProvisioningInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ConnectionInfo) GetProvisioningInfo(ctx context.Context) (ProvisioningInfo, bool) { + var e ProvisioningInfo + if o.ProvisioningInfo.IsNull() || o.ProvisioningInfo.IsUnknown() { + return e, false + } + var v []ProvisioningInfo + d := o.ProvisioningInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvisioningInfo sets the value of the ProvisioningInfo field in ConnectionInfo. +func (o *ConnectionInfo) SetProvisioningInfo(ctx context.Context, v ProvisioningInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provisioning_info"] + o.ProvisioningInfo = types.ListValueMust(t, vs) +} + // Detailed status of an online table. Shown if the online table is in the // ONLINE_CONTINUOUS_UPDATE or the ONLINE_UPDATING_PIPELINE_RESOURCES state. type ContinuousUpdateStatus struct { @@ -1731,6 +2220,32 @@ func (o ContinuousUpdateStatus) Type(ctx context.Context) attr.Type { } } +// GetInitialPipelineSyncProgress returns the value of the InitialPipelineSyncProgress field in ContinuousUpdateStatus as +// a PipelineProgress value. +// If the field is unknown or null, the boolean return value is false. +func (o *ContinuousUpdateStatus) GetInitialPipelineSyncProgress(ctx context.Context) (PipelineProgress, bool) { + var e PipelineProgress + if o.InitialPipelineSyncProgress.IsNull() || o.InitialPipelineSyncProgress.IsUnknown() { + return e, false + } + var v []PipelineProgress + d := o.InitialPipelineSyncProgress.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInitialPipelineSyncProgress sets the value of the InitialPipelineSyncProgress field in ContinuousUpdateStatus. +func (o *ContinuousUpdateStatus) SetInitialPipelineSyncProgress(ctx context.Context, v PipelineProgress) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["initial_pipeline_sync_progress"] + o.InitialPipelineSyncProgress = types.ListValueMust(t, vs) +} + type CreateCatalog struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1811,6 +2326,56 @@ func (o CreateCatalog) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in CreateCatalog as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCatalog) GetOptions(ctx context.Context) (map[string]types.String, bool) { + if o.Options.IsNull() || o.Options.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOptions sets the value of the Options field in CreateCatalog. +func (o *CreateCatalog) SetOptions(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.MapValueMust(t, vs) +} + +// GetProperties returns the value of the Properties field in CreateCatalog as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCatalog) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in CreateCatalog. +func (o *CreateCatalog) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type CreateConnection struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1881,6 +2446,56 @@ func (o CreateConnection) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in CreateConnection as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateConnection) GetOptions(ctx context.Context) (map[string]types.String, bool) { + if o.Options.IsNull() || o.Options.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOptions sets the value of the Options field in CreateConnection. +func (o *CreateConnection) SetOptions(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.MapValueMust(t, vs) +} + +// GetProperties returns the value of the Properties field in CreateConnection as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateConnection) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in CreateConnection. +func (o *CreateConnection) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type CreateCredentialRequest struct { // The AWS IAM role configuration AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` @@ -1972,6 +2587,110 @@ func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in CreateCredentialRequest as +// a AwsIamRole value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCredentialRequest) GetAwsIamRole(ctx context.Context) (AwsIamRole, bool) { + var e AwsIamRole + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRole + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in CreateCredentialRequest. +func (o *CreateCredentialRequest) SetAwsIamRole(ctx context.Context, v AwsIamRole) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in CreateCredentialRequest as +// a AzureManagedIdentity value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCredentialRequest) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentity, bool) { + var e AzureManagedIdentity + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentity + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in CreateCredentialRequest. +func (o *CreateCredentialRequest) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentity) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in CreateCredentialRequest as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCredentialRequest) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in CreateCredentialRequest. +func (o *CreateCredentialRequest) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + +// GetGcpServiceAccountKey returns the value of the GcpServiceAccountKey field in CreateCredentialRequest as +// a GcpServiceAccountKey value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCredentialRequest) GetGcpServiceAccountKey(ctx context.Context) (GcpServiceAccountKey, bool) { + var e GcpServiceAccountKey + if o.GcpServiceAccountKey.IsNull() || o.GcpServiceAccountKey.IsUnknown() { + return e, false + } + var v []GcpServiceAccountKey + d := o.GcpServiceAccountKey.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpServiceAccountKey sets the value of the GcpServiceAccountKey field in CreateCredentialRequest. +func (o *CreateCredentialRequest) SetGcpServiceAccountKey(ctx context.Context, v GcpServiceAccountKey) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_service_account_key"] + o.GcpServiceAccountKey = types.ListValueMust(t, vs) +} + type CreateExternalLocation struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -2053,6 +2772,32 @@ func (o CreateExternalLocation) Type(ctx context.Context) attr.Type { } } +// GetEncryptionDetails returns the value of the EncryptionDetails field in CreateExternalLocation as +// a EncryptionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateExternalLocation) GetEncryptionDetails(ctx context.Context) (EncryptionDetails, bool) { + var e EncryptionDetails + if o.EncryptionDetails.IsNull() || o.EncryptionDetails.IsUnknown() { + return e, false + } + var v []EncryptionDetails + d := o.EncryptionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEncryptionDetails sets the value of the EncryptionDetails field in CreateExternalLocation. +func (o *CreateExternalLocation) SetEncryptionDetails(ctx context.Context, v EncryptionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["encryption_details"] + o.EncryptionDetails = types.ListValueMust(t, vs) +} + type CreateFunction struct { // Name of parent catalog. CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -2189,6 +2934,84 @@ func (o CreateFunction) Type(ctx context.Context) attr.Type { } } +// GetInputParams returns the value of the InputParams field in CreateFunction as +// a FunctionParameterInfos value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateFunction) GetInputParams(ctx context.Context) (FunctionParameterInfos, bool) { + var e FunctionParameterInfos + if o.InputParams.IsNull() || o.InputParams.IsUnknown() { + return e, false + } + var v []FunctionParameterInfos + d := o.InputParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInputParams sets the value of the InputParams field in CreateFunction. +func (o *CreateFunction) SetInputParams(ctx context.Context, v FunctionParameterInfos) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input_params"] + o.InputParams = types.ListValueMust(t, vs) +} + +// GetReturnParams returns the value of the ReturnParams field in CreateFunction as +// a FunctionParameterInfos value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateFunction) GetReturnParams(ctx context.Context) (FunctionParameterInfos, bool) { + var e FunctionParameterInfos + if o.ReturnParams.IsNull() || o.ReturnParams.IsUnknown() { + return e, false + } + var v []FunctionParameterInfos + d := o.ReturnParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetReturnParams sets the value of the ReturnParams field in CreateFunction. +func (o *CreateFunction) SetReturnParams(ctx context.Context, v FunctionParameterInfos) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["return_params"] + o.ReturnParams = types.ListValueMust(t, vs) +} + +// GetRoutineDependencies returns the value of the RoutineDependencies field in CreateFunction as +// a DependencyList value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateFunction) GetRoutineDependencies(ctx context.Context) (DependencyList, bool) { + var e DependencyList + if o.RoutineDependencies.IsNull() || o.RoutineDependencies.IsUnknown() { + return e, false + } + var v []DependencyList + d := o.RoutineDependencies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRoutineDependencies sets the value of the RoutineDependencies field in CreateFunction. +func (o *CreateFunction) SetRoutineDependencies(ctx context.Context, v DependencyList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["routine_dependencies"] + o.RoutineDependencies = types.ListValueMust(t, vs) +} + type CreateFunctionRequest struct { // Partial __FunctionInfo__ specifying the function to be created. FunctionInfo types.List `tfsdk:"function_info" tf:"object"` @@ -2235,6 +3058,32 @@ func (o CreateFunctionRequest) Type(ctx context.Context) attr.Type { } } +// GetFunctionInfo returns the value of the FunctionInfo field in CreateFunctionRequest as +// a CreateFunction value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateFunctionRequest) GetFunctionInfo(ctx context.Context) (CreateFunction, bool) { + var e CreateFunction + if o.FunctionInfo.IsNull() || o.FunctionInfo.IsUnknown() { + return e, false + } + var v []CreateFunction + d := o.FunctionInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFunctionInfo sets the value of the FunctionInfo field in CreateFunctionRequest. +func (o *CreateFunctionRequest) SetFunctionInfo(ctx context.Context, v CreateFunction) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["function_info"] + o.FunctionInfo = types.ListValueMust(t, vs) +} + type CreateMetastore struct { // The user-specified name of the metastore. Name types.String `tfsdk:"name" tf:""` @@ -2469,33 +3318,239 @@ func (o CreateMonitor) Type(ctx context.Context) attr.Type { } } -// Create an Online Table -type CreateOnlineTableRequest struct { - // Online Table information. - Table types.List `tfsdk:"table" tf:"optional,object"` +// GetCustomMetrics returns the value of the CustomMetrics field in CreateMonitor as +// a slice of MonitorMetric values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetCustomMetrics(ctx context.Context) ([]MonitorMetric, bool) { + if o.CustomMetrics.IsNull() || o.CustomMetrics.IsUnknown() { + return nil, false + } + var v []MonitorMetric + d := o.CustomMetrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true } -func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateOnlineTableRequest) { +// SetCustomMetrics sets the value of the CustomMetrics field in CreateMonitor. +func (o *CreateMonitor) SetCustomMetrics(ctx context.Context, v []MonitorMetric) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_metrics"] + o.CustomMetrics = types.ListValueMust(t, vs) } -func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState CreateOnlineTableRequest) { +// GetDataClassificationConfig returns the value of the DataClassificationConfig field in CreateMonitor as +// a MonitorDataClassificationConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetDataClassificationConfig(ctx context.Context) (MonitorDataClassificationConfig, bool) { + var e MonitorDataClassificationConfig + if o.DataClassificationConfig.IsNull() || o.DataClassificationConfig.IsUnknown() { + return e, false + } + var v []MonitorDataClassificationConfig + d := o.DataClassificationConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateOnlineTableRequest. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "table": reflect.TypeOf(OnlineTable{}), - } +// SetDataClassificationConfig sets the value of the DataClassificationConfig field in CreateMonitor. +func (o *CreateMonitor) SetDataClassificationConfig(ctx context.Context, v MonitorDataClassificationConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_classification_config"] + o.DataClassificationConfig = types.ListValueMust(t, vs) } -// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise -// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateOnlineTableRequest +// GetInferenceLog returns the value of the InferenceLog field in CreateMonitor as +// a MonitorInferenceLog value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetInferenceLog(ctx context.Context) (MonitorInferenceLog, bool) { + var e MonitorInferenceLog + if o.InferenceLog.IsNull() || o.InferenceLog.IsUnknown() { + return e, false + } + var v []MonitorInferenceLog + d := o.InferenceLog.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInferenceLog sets the value of the InferenceLog field in CreateMonitor. +func (o *CreateMonitor) SetInferenceLog(ctx context.Context, v MonitorInferenceLog) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inference_log"] + o.InferenceLog = types.ListValueMust(t, vs) +} + +// GetNotifications returns the value of the Notifications field in CreateMonitor as +// a MonitorNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetNotifications(ctx context.Context) (MonitorNotifications, bool) { + var e MonitorNotifications + if o.Notifications.IsNull() || o.Notifications.IsUnknown() { + return e, false + } + var v []MonitorNotifications + d := o.Notifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotifications sets the value of the Notifications field in CreateMonitor. +func (o *CreateMonitor) SetNotifications(ctx context.Context, v MonitorNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + o.Notifications = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in CreateMonitor as +// a MonitorCronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetSchedule(ctx context.Context) (MonitorCronSchedule, bool) { + var e MonitorCronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []MonitorCronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in CreateMonitor. +func (o *CreateMonitor) SetSchedule(ctx context.Context, v MonitorCronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetSlicingExprs returns the value of the SlicingExprs field in CreateMonitor as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetSlicingExprs(ctx context.Context) ([]types.String, bool) { + if o.SlicingExprs.IsNull() || o.SlicingExprs.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SlicingExprs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSlicingExprs sets the value of the SlicingExprs field in CreateMonitor. +func (o *CreateMonitor) SetSlicingExprs(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slicing_exprs"] + o.SlicingExprs = types.ListValueMust(t, vs) +} + +// GetSnapshot returns the value of the Snapshot field in CreateMonitor as +// a MonitorSnapshot value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetSnapshot(ctx context.Context) (MonitorSnapshot, bool) { + var e MonitorSnapshot + if o.Snapshot.IsNull() || o.Snapshot.IsUnknown() { + return e, false + } + var v []MonitorSnapshot + d := o.Snapshot.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSnapshot sets the value of the Snapshot field in CreateMonitor. +func (o *CreateMonitor) SetSnapshot(ctx context.Context, v MonitorSnapshot) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["snapshot"] + o.Snapshot = types.ListValueMust(t, vs) +} + +// GetTimeSeries returns the value of the TimeSeries field in CreateMonitor as +// a MonitorTimeSeries value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateMonitor) GetTimeSeries(ctx context.Context) (MonitorTimeSeries, bool) { + var e MonitorTimeSeries + if o.TimeSeries.IsNull() || o.TimeSeries.IsUnknown() { + return e, false + } + var v []MonitorTimeSeries + d := o.TimeSeries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTimeSeries sets the value of the TimeSeries field in CreateMonitor. +func (o *CreateMonitor) SetTimeSeries(ctx context.Context, v MonitorTimeSeries) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["time_series"] + o.TimeSeries = types.ListValueMust(t, vs) +} + +// Create an Online Table +type CreateOnlineTableRequest struct { + // Online Table information. + Table types.List `tfsdk:"table" tf:"optional,object"` +} + +func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateOnlineTableRequest) { +} + +func (newState *CreateOnlineTableRequest) SyncEffectiveFieldsDuringRead(existingState CreateOnlineTableRequest) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in CreateOnlineTableRequest. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a CreateOnlineTableRequest) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "table": reflect.TypeOf(OnlineTable{}), + } +} + +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, CreateOnlineTableRequest // only implements ToObjectValue() and Type(). func (o CreateOnlineTableRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { return types.ObjectValueMust( @@ -2516,6 +3571,32 @@ func (o CreateOnlineTableRequest) Type(ctx context.Context) attr.Type { } } +// GetTable returns the value of the Table field in CreateOnlineTableRequest as +// a OnlineTable value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateOnlineTableRequest) GetTable(ctx context.Context) (OnlineTable, bool) { + var e OnlineTable + if o.Table.IsNull() || o.Table.IsUnknown() { + return e, false + } + var v []OnlineTable + d := o.Table.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTable sets the value of the Table field in CreateOnlineTableRequest. +func (o *CreateOnlineTableRequest) SetTable(ctx context.Context, v OnlineTable) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table"] + o.Table = types.ListValueMust(t, vs) +} + type CreateRegisteredModelRequest struct { // The name of the catalog where the schema and the registered model reside CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -2673,6 +3754,31 @@ func (o CreateSchema) Type(ctx context.Context) attr.Type { } } +// GetProperties returns the value of the Properties field in CreateSchema as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateSchema) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in CreateSchema. +func (o *CreateSchema) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type CreateStorageCredential struct { // The AWS IAM role configuration. AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` @@ -2764,6 +3870,136 @@ func (o CreateStorageCredential) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in CreateStorageCredential as +// a AwsIamRoleRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateStorageCredential) GetAwsIamRole(ctx context.Context) (AwsIamRoleRequest, bool) { + var e AwsIamRoleRequest + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRoleRequest + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in CreateStorageCredential. +func (o *CreateStorageCredential) SetAwsIamRole(ctx context.Context, v AwsIamRoleRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in CreateStorageCredential as +// a AzureManagedIdentityRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateStorageCredential) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentityRequest, bool) { + var e AzureManagedIdentityRequest + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentityRequest + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in CreateStorageCredential. +func (o *CreateStorageCredential) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentityRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in CreateStorageCredential as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateStorageCredential) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in CreateStorageCredential. +func (o *CreateStorageCredential) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + +// GetCloudflareApiToken returns the value of the CloudflareApiToken field in CreateStorageCredential as +// a CloudflareApiToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateStorageCredential) GetCloudflareApiToken(ctx context.Context) (CloudflareApiToken, bool) { + var e CloudflareApiToken + if o.CloudflareApiToken.IsNull() || o.CloudflareApiToken.IsUnknown() { + return e, false + } + var v []CloudflareApiToken + d := o.CloudflareApiToken.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCloudflareApiToken sets the value of the CloudflareApiToken field in CreateStorageCredential. +func (o *CreateStorageCredential) SetCloudflareApiToken(ctx context.Context, v CloudflareApiToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cloudflare_api_token"] + o.CloudflareApiToken = types.ListValueMust(t, vs) +} + +// GetDatabricksGcpServiceAccount returns the value of the DatabricksGcpServiceAccount field in CreateStorageCredential as +// a DatabricksGcpServiceAccountRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateStorageCredential) GetDatabricksGcpServiceAccount(ctx context.Context) (DatabricksGcpServiceAccountRequest, bool) { + var e DatabricksGcpServiceAccountRequest + if o.DatabricksGcpServiceAccount.IsNull() || o.DatabricksGcpServiceAccount.IsUnknown() { + return e, false + } + var v []DatabricksGcpServiceAccountRequest + d := o.DatabricksGcpServiceAccount.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDatabricksGcpServiceAccount sets the value of the DatabricksGcpServiceAccount field in CreateStorageCredential. +func (o *CreateStorageCredential) SetDatabricksGcpServiceAccount(ctx context.Context, v DatabricksGcpServiceAccountRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["databricks_gcp_service_account"] + o.DatabricksGcpServiceAccount = types.ListValueMust(t, vs) +} + type CreateTableConstraint struct { // A table constraint, as defined by *one* of the following fields being // set: __primary_key_constraint__, __foreign_key_constraint__, @@ -2816,6 +4052,32 @@ func (o CreateTableConstraint) Type(ctx context.Context) attr.Type { } } +// GetConstraint returns the value of the Constraint field in CreateTableConstraint as +// a TableConstraint value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateTableConstraint) GetConstraint(ctx context.Context) (TableConstraint, bool) { + var e TableConstraint + if o.Constraint.IsNull() || o.Constraint.IsUnknown() { + return e, false + } + var v []TableConstraint + d := o.Constraint.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConstraint sets the value of the Constraint field in CreateTableConstraint. +func (o *CreateTableConstraint) SetConstraint(ctx context.Context, v TableConstraint) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["constraint"] + o.Constraint = types.ListValueMust(t, vs) +} + type CreateVolumeRequestContent struct { // The name of the catalog where the schema and the volume are CatalogName types.String `tfsdk:"catalog_name" tf:""` @@ -2998,6 +4260,84 @@ func (o CredentialInfo) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in CredentialInfo as +// a AwsIamRole value. +// If the field is unknown or null, the boolean return value is false. +func (o *CredentialInfo) GetAwsIamRole(ctx context.Context) (AwsIamRole, bool) { + var e AwsIamRole + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRole + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in CredentialInfo. +func (o *CredentialInfo) SetAwsIamRole(ctx context.Context, v AwsIamRole) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in CredentialInfo as +// a AzureManagedIdentity value. +// If the field is unknown or null, the boolean return value is false. +func (o *CredentialInfo) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentity, bool) { + var e AzureManagedIdentity + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentity + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in CredentialInfo. +func (o *CredentialInfo) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentity) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in CredentialInfo as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *CredentialInfo) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in CredentialInfo. +func (o *CredentialInfo) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + type CredentialValidationResult struct { // Error message would exist when the result does not equal to **PASS**. Message types.String `tfsdk:"message" tf:"optional"` @@ -3091,6 +4431,31 @@ func (o CurrentWorkspaceBindings) Type(ctx context.Context) attr.Type { } } +// GetWorkspaces returns the value of the Workspaces field in CurrentWorkspaceBindings as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *CurrentWorkspaceBindings) GetWorkspaces(ctx context.Context) ([]types.Int64, bool) { + if o.Workspaces.IsNull() || o.Workspaces.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.Workspaces.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWorkspaces sets the value of the Workspaces field in CurrentWorkspaceBindings. +func (o *CurrentWorkspaceBindings) SetWorkspaces(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspaces"] + o.Workspaces = types.ListValueMust(t, vs) +} + type DatabricksGcpServiceAccountRequest struct { } @@ -4215,6 +5580,31 @@ func (o DeltaRuntimePropertiesKvPairs) Type(ctx context.Context) attr.Type { } } +// GetDeltaRuntimeProperties returns the value of the DeltaRuntimeProperties field in DeltaRuntimePropertiesKvPairs as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeltaRuntimePropertiesKvPairs) GetDeltaRuntimeProperties(ctx context.Context) (map[string]types.String, bool) { + if o.DeltaRuntimeProperties.IsNull() || o.DeltaRuntimeProperties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.DeltaRuntimeProperties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDeltaRuntimeProperties sets the value of the DeltaRuntimeProperties field in DeltaRuntimePropertiesKvPairs. +func (o *DeltaRuntimePropertiesKvPairs) SetDeltaRuntimeProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delta_runtime_properties"] + o.DeltaRuntimeProperties = types.MapValueMust(t, vs) +} + // A dependency of a SQL object. Either the __table__ field or the __function__ // field must be defined. type Dependency struct { @@ -4270,6 +5660,58 @@ func (o Dependency) Type(ctx context.Context) attr.Type { } } +// GetFunction returns the value of the Function field in Dependency as +// a FunctionDependency value. +// If the field is unknown or null, the boolean return value is false. +func (o *Dependency) GetFunction(ctx context.Context) (FunctionDependency, bool) { + var e FunctionDependency + if o.Function.IsNull() || o.Function.IsUnknown() { + return e, false + } + var v []FunctionDependency + d := o.Function.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFunction sets the value of the Function field in Dependency. +func (o *Dependency) SetFunction(ctx context.Context, v FunctionDependency) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["function"] + o.Function = types.ListValueMust(t, vs) +} + +// GetTable returns the value of the Table field in Dependency as +// a TableDependency value. +// If the field is unknown or null, the boolean return value is false. +func (o *Dependency) GetTable(ctx context.Context) (TableDependency, bool) { + var e TableDependency + if o.Table.IsNull() || o.Table.IsUnknown() { + return e, false + } + var v []TableDependency + d := o.Table.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTable sets the value of the Table field in Dependency. +func (o *Dependency) SetTable(ctx context.Context, v TableDependency) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table"] + o.Table = types.ListValueMust(t, vs) +} + // A list of dependencies. type DependencyList struct { // Array of dependencies. @@ -4317,6 +5759,31 @@ func (o DependencyList) Type(ctx context.Context) attr.Type { } } +// GetDependencies returns the value of the Dependencies field in DependencyList as +// a slice of Dependency values. +// If the field is unknown or null, the boolean return value is false. +func (o *DependencyList) GetDependencies(ctx context.Context) ([]Dependency, bool) { + if o.Dependencies.IsNull() || o.Dependencies.IsUnknown() { + return nil, false + } + var v []Dependency + d := o.Dependencies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDependencies sets the value of the Dependencies field in DependencyList. +func (o *DependencyList) SetDependencies(ctx context.Context, v []Dependency) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dependencies"] + o.Dependencies = types.ListValueMust(t, vs) +} + // Disable a system schema type DisableRequest struct { // The metastore ID under which the system schema lives. @@ -4447,6 +5914,31 @@ func (o EffectivePermissionsList) Type(ctx context.Context) attr.Type { } } +// GetPrivilegeAssignments returns the value of the PrivilegeAssignments field in EffectivePermissionsList as +// a slice of EffectivePrivilegeAssignment values. +// If the field is unknown or null, the boolean return value is false. +func (o *EffectivePermissionsList) GetPrivilegeAssignments(ctx context.Context) ([]EffectivePrivilegeAssignment, bool) { + if o.PrivilegeAssignments.IsNull() || o.PrivilegeAssignments.IsUnknown() { + return nil, false + } + var v []EffectivePrivilegeAssignment + d := o.PrivilegeAssignments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrivilegeAssignments sets the value of the PrivilegeAssignments field in EffectivePermissionsList. +func (o *EffectivePermissionsList) SetPrivilegeAssignments(ctx context.Context, v []EffectivePrivilegeAssignment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privilege_assignments"] + o.PrivilegeAssignments = types.ListValueMust(t, vs) +} + type EffectivePredictiveOptimizationFlag struct { // The name of the object from which the flag was inherited. If there was no // inheritance, this field is left blank. @@ -4605,6 +6097,31 @@ func (o EffectivePrivilegeAssignment) Type(ctx context.Context) attr.Type { } } +// GetPrivileges returns the value of the Privileges field in EffectivePrivilegeAssignment as +// a slice of EffectivePrivilege values. +// If the field is unknown or null, the boolean return value is false. +func (o *EffectivePrivilegeAssignment) GetPrivileges(ctx context.Context) ([]EffectivePrivilege, bool) { + if o.Privileges.IsNull() || o.Privileges.IsUnknown() { + return nil, false + } + var v []EffectivePrivilege + d := o.Privileges.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrivileges sets the value of the Privileges field in EffectivePrivilegeAssignment. +func (o *EffectivePrivilegeAssignment) SetPrivileges(ctx context.Context, v []EffectivePrivilege) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privileges"] + o.Privileges = types.ListValueMust(t, vs) +} + // Enable a system schema type EnableRequest struct { // The metastore ID under which the system schema lives. @@ -4735,6 +6252,32 @@ func (o EncryptionDetails) Type(ctx context.Context) attr.Type { } } +// GetSseEncryptionDetails returns the value of the SseEncryptionDetails field in EncryptionDetails as +// a SseEncryptionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *EncryptionDetails) GetSseEncryptionDetails(ctx context.Context) (SseEncryptionDetails, bool) { + var e SseEncryptionDetails + if o.SseEncryptionDetails.IsNull() || o.SseEncryptionDetails.IsUnknown() { + return e, false + } + var v []SseEncryptionDetails + d := o.SseEncryptionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSseEncryptionDetails sets the value of the SseEncryptionDetails field in EncryptionDetails. +func (o *EncryptionDetails) SetSseEncryptionDetails(ctx context.Context, v SseEncryptionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sse_encryption_details"] + o.SseEncryptionDetails = types.ListValueMust(t, vs) +} + // Get boolean reflecting if table exists type ExistsRequest struct { // Full name of the table. @@ -4893,6 +6436,32 @@ func (o ExternalLocationInfo) Type(ctx context.Context) attr.Type { } } +// GetEncryptionDetails returns the value of the EncryptionDetails field in ExternalLocationInfo as +// a EncryptionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalLocationInfo) GetEncryptionDetails(ctx context.Context) (EncryptionDetails, bool) { + var e EncryptionDetails + if o.EncryptionDetails.IsNull() || o.EncryptionDetails.IsUnknown() { + return e, false + } + var v []EncryptionDetails + d := o.EncryptionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEncryptionDetails sets the value of the EncryptionDetails field in ExternalLocationInfo. +func (o *ExternalLocationInfo) SetEncryptionDetails(ctx context.Context, v EncryptionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["encryption_details"] + o.EncryptionDetails = types.ListValueMust(t, vs) +} + // Detailed status of an online table. Shown if the online table is in the // OFFLINE_FAILED or the ONLINE_PIPELINE_FAILED state. type FailedStatus struct { @@ -5007,6 +6576,56 @@ func (o ForeignKeyConstraint) Type(ctx context.Context) attr.Type { } } +// GetChildColumns returns the value of the ChildColumns field in ForeignKeyConstraint as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ForeignKeyConstraint) GetChildColumns(ctx context.Context) ([]types.String, bool) { + if o.ChildColumns.IsNull() || o.ChildColumns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ChildColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetChildColumns sets the value of the ChildColumns field in ForeignKeyConstraint. +func (o *ForeignKeyConstraint) SetChildColumns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["child_columns"] + o.ChildColumns = types.ListValueMust(t, vs) +} + +// GetParentColumns returns the value of the ParentColumns field in ForeignKeyConstraint as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ForeignKeyConstraint) GetParentColumns(ctx context.Context) ([]types.String, bool) { + if o.ParentColumns.IsNull() || o.ParentColumns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ParentColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParentColumns sets the value of the ParentColumns field in ForeignKeyConstraint. +func (o *ForeignKeyConstraint) SetParentColumns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parent_columns"] + o.ParentColumns = types.ListValueMust(t, vs) +} + // A function that is dependent on a SQL object. type FunctionDependency struct { // Full name of the dependent function, in the form of @@ -5226,6 +6845,84 @@ func (o FunctionInfo) Type(ctx context.Context) attr.Type { } } +// GetInputParams returns the value of the InputParams field in FunctionInfo as +// a FunctionParameterInfos value. +// If the field is unknown or null, the boolean return value is false. +func (o *FunctionInfo) GetInputParams(ctx context.Context) (FunctionParameterInfos, bool) { + var e FunctionParameterInfos + if o.InputParams.IsNull() || o.InputParams.IsUnknown() { + return e, false + } + var v []FunctionParameterInfos + d := o.InputParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInputParams sets the value of the InputParams field in FunctionInfo. +func (o *FunctionInfo) SetInputParams(ctx context.Context, v FunctionParameterInfos) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input_params"] + o.InputParams = types.ListValueMust(t, vs) +} + +// GetReturnParams returns the value of the ReturnParams field in FunctionInfo as +// a FunctionParameterInfos value. +// If the field is unknown or null, the boolean return value is false. +func (o *FunctionInfo) GetReturnParams(ctx context.Context) (FunctionParameterInfos, bool) { + var e FunctionParameterInfos + if o.ReturnParams.IsNull() || o.ReturnParams.IsUnknown() { + return e, false + } + var v []FunctionParameterInfos + d := o.ReturnParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetReturnParams sets the value of the ReturnParams field in FunctionInfo. +func (o *FunctionInfo) SetReturnParams(ctx context.Context, v FunctionParameterInfos) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["return_params"] + o.ReturnParams = types.ListValueMust(t, vs) +} + +// GetRoutineDependencies returns the value of the RoutineDependencies field in FunctionInfo as +// a DependencyList value. +// If the field is unknown or null, the boolean return value is false. +func (o *FunctionInfo) GetRoutineDependencies(ctx context.Context) (DependencyList, bool) { + var e DependencyList + if o.RoutineDependencies.IsNull() || o.RoutineDependencies.IsUnknown() { + return e, false + } + var v []DependencyList + d := o.RoutineDependencies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRoutineDependencies sets the value of the RoutineDependencies field in FunctionInfo. +func (o *FunctionInfo) SetRoutineDependencies(ctx context.Context, v DependencyList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["routine_dependencies"] + o.RoutineDependencies = types.ListValueMust(t, vs) +} + type FunctionParameterInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5359,6 +7056,31 @@ func (o FunctionParameterInfos) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in FunctionParameterInfos as +// a slice of FunctionParameterInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *FunctionParameterInfos) GetParameters(ctx context.Context) ([]FunctionParameterInfo, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []FunctionParameterInfo + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in FunctionParameterInfos. +func (o *FunctionParameterInfos) SetParameters(ctx context.Context, v []FunctionParameterInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + // GCP temporary credentials for API authentication. Read more at // https://developers.google.com/identity/protocols/oauth2/service-account type GcpOauthToken struct { @@ -5502,11 +7224,36 @@ func (o GenerateTemporaryServiceCredentialAzureOptions) Type(ctx context.Context } } -type GenerateTemporaryServiceCredentialRequest struct { - // Options to customize the requested temporary credential - AzureOptions types.List `tfsdk:"azure_options" tf:"optional,object"` - // The name of the service credential used to generate a temporary - // credential +// GetResources returns the value of the Resources field in GenerateTemporaryServiceCredentialAzureOptions as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryServiceCredentialAzureOptions) GetResources(ctx context.Context) ([]types.String, bool) { + if o.Resources.IsNull() || o.Resources.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Resources.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResources sets the value of the Resources field in GenerateTemporaryServiceCredentialAzureOptions. +func (o *GenerateTemporaryServiceCredentialAzureOptions) SetResources(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["resources"] + o.Resources = types.ListValueMust(t, vs) +} + +type GenerateTemporaryServiceCredentialRequest struct { + // Options to customize the requested temporary credential + AzureOptions types.List `tfsdk:"azure_options" tf:"optional,object"` + // The name of the service credential used to generate a temporary + // credential CredentialName types.String `tfsdk:"credential_name" tf:""` } @@ -5553,6 +7300,32 @@ func (o GenerateTemporaryServiceCredentialRequest) Type(ctx context.Context) att } } +// GetAzureOptions returns the value of the AzureOptions field in GenerateTemporaryServiceCredentialRequest as +// a GenerateTemporaryServiceCredentialAzureOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryServiceCredentialRequest) GetAzureOptions(ctx context.Context) (GenerateTemporaryServiceCredentialAzureOptions, bool) { + var e GenerateTemporaryServiceCredentialAzureOptions + if o.AzureOptions.IsNull() || o.AzureOptions.IsUnknown() { + return e, false + } + var v []GenerateTemporaryServiceCredentialAzureOptions + d := o.AzureOptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureOptions sets the value of the AzureOptions field in GenerateTemporaryServiceCredentialRequest. +func (o *GenerateTemporaryServiceCredentialRequest) SetAzureOptions(ctx context.Context, v GenerateTemporaryServiceCredentialAzureOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_options"] + o.AzureOptions = types.ListValueMust(t, vs) +} + type GenerateTemporaryTableCredentialRequest struct { // The operation performed against the table data, either READ or // READ_WRITE. If READ_WRITE is specified, the credentials returned will @@ -5690,6 +7463,136 @@ func (o GenerateTemporaryTableCredentialResponse) Type(ctx context.Context) attr } } +// GetAwsTempCredentials returns the value of the AwsTempCredentials field in GenerateTemporaryTableCredentialResponse as +// a AwsCredentials value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryTableCredentialResponse) GetAwsTempCredentials(ctx context.Context) (AwsCredentials, bool) { + var e AwsCredentials + if o.AwsTempCredentials.IsNull() || o.AwsTempCredentials.IsUnknown() { + return e, false + } + var v []AwsCredentials + d := o.AwsTempCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsTempCredentials sets the value of the AwsTempCredentials field in GenerateTemporaryTableCredentialResponse. +func (o *GenerateTemporaryTableCredentialResponse) SetAwsTempCredentials(ctx context.Context, v AwsCredentials) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_temp_credentials"] + o.AwsTempCredentials = types.ListValueMust(t, vs) +} + +// GetAzureAad returns the value of the AzureAad field in GenerateTemporaryTableCredentialResponse as +// a AzureActiveDirectoryToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryTableCredentialResponse) GetAzureAad(ctx context.Context) (AzureActiveDirectoryToken, bool) { + var e AzureActiveDirectoryToken + if o.AzureAad.IsNull() || o.AzureAad.IsUnknown() { + return e, false + } + var v []AzureActiveDirectoryToken + d := o.AzureAad.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAad sets the value of the AzureAad field in GenerateTemporaryTableCredentialResponse. +func (o *GenerateTemporaryTableCredentialResponse) SetAzureAad(ctx context.Context, v AzureActiveDirectoryToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_aad"] + o.AzureAad = types.ListValueMust(t, vs) +} + +// GetAzureUserDelegationSas returns the value of the AzureUserDelegationSas field in GenerateTemporaryTableCredentialResponse as +// a AzureUserDelegationSas value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryTableCredentialResponse) GetAzureUserDelegationSas(ctx context.Context) (AzureUserDelegationSas, bool) { + var e AzureUserDelegationSas + if o.AzureUserDelegationSas.IsNull() || o.AzureUserDelegationSas.IsUnknown() { + return e, false + } + var v []AzureUserDelegationSas + d := o.AzureUserDelegationSas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureUserDelegationSas sets the value of the AzureUserDelegationSas field in GenerateTemporaryTableCredentialResponse. +func (o *GenerateTemporaryTableCredentialResponse) SetAzureUserDelegationSas(ctx context.Context, v AzureUserDelegationSas) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_user_delegation_sas"] + o.AzureUserDelegationSas = types.ListValueMust(t, vs) +} + +// GetGcpOauthToken returns the value of the GcpOauthToken field in GenerateTemporaryTableCredentialResponse as +// a GcpOauthToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryTableCredentialResponse) GetGcpOauthToken(ctx context.Context) (GcpOauthToken, bool) { + var e GcpOauthToken + if o.GcpOauthToken.IsNull() || o.GcpOauthToken.IsUnknown() { + return e, false + } + var v []GcpOauthToken + d := o.GcpOauthToken.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpOauthToken sets the value of the GcpOauthToken field in GenerateTemporaryTableCredentialResponse. +func (o *GenerateTemporaryTableCredentialResponse) SetGcpOauthToken(ctx context.Context, v GcpOauthToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_oauth_token"] + o.GcpOauthToken = types.ListValueMust(t, vs) +} + +// GetR2TempCredentials returns the value of the R2TempCredentials field in GenerateTemporaryTableCredentialResponse as +// a R2Credentials value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenerateTemporaryTableCredentialResponse) GetR2TempCredentials(ctx context.Context) (R2Credentials, bool) { + var e R2Credentials + if o.R2TempCredentials.IsNull() || o.R2TempCredentials.IsUnknown() { + return e, false + } + var v []R2Credentials + d := o.R2TempCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetR2TempCredentials sets the value of the R2TempCredentials field in GenerateTemporaryTableCredentialResponse. +func (o *GenerateTemporaryTableCredentialResponse) SetR2TempCredentials(ctx context.Context, v R2Credentials) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["r2_temp_credentials"] + o.R2TempCredentials = types.ListValueMust(t, vs) +} + // Gets the metastore assignment for a workspace type GetAccountMetastoreAssignmentRequest struct { // Workspace ID. @@ -6716,6 +8619,32 @@ func (o GetQuotaResponse) Type(ctx context.Context) attr.Type { } } +// GetQuotaInfo returns the value of the QuotaInfo field in GetQuotaResponse as +// a QuotaInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetQuotaResponse) GetQuotaInfo(ctx context.Context) (QuotaInfo, bool) { + var e QuotaInfo + if o.QuotaInfo.IsNull() || o.QuotaInfo.IsUnknown() { + return e, false + } + var v []QuotaInfo + d := o.QuotaInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuotaInfo sets the value of the QuotaInfo field in GetQuotaResponse. +func (o *GetQuotaResponse) SetQuotaInfo(ctx context.Context, v QuotaInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["quota_info"] + o.QuotaInfo = types.ListValueMust(t, vs) +} + // Get refresh type GetRefreshRequest struct { // ID of the refresh. @@ -7094,6 +9023,31 @@ func (o ListAccountMetastoreAssignmentsResponse) Type(ctx context.Context) attr. } } +// GetWorkspaceIds returns the value of the WorkspaceIds field in ListAccountMetastoreAssignmentsResponse as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAccountMetastoreAssignmentsResponse) GetWorkspaceIds(ctx context.Context) ([]types.Int64, bool) { + if o.WorkspaceIds.IsNull() || o.WorkspaceIds.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.WorkspaceIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWorkspaceIds sets the value of the WorkspaceIds field in ListAccountMetastoreAssignmentsResponse. +func (o *ListAccountMetastoreAssignmentsResponse) SetWorkspaceIds(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_ids"] + o.WorkspaceIds = types.ListValueMust(t, vs) +} + // Get all storage credentials assigned to a metastore type ListAccountStorageCredentialsRequest struct { // Unity Catalog metastore ID @@ -7183,6 +9137,31 @@ func (o ListAccountStorageCredentialsResponse) Type(ctx context.Context) attr.Ty } } +// GetStorageCredentials returns the value of the StorageCredentials field in ListAccountStorageCredentialsResponse as +// a slice of StorageCredentialInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAccountStorageCredentialsResponse) GetStorageCredentials(ctx context.Context) ([]StorageCredentialInfo, bool) { + if o.StorageCredentials.IsNull() || o.StorageCredentials.IsUnknown() { + return nil, false + } + var v []StorageCredentialInfo + d := o.StorageCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStorageCredentials sets the value of the StorageCredentials field in ListAccountStorageCredentialsResponse. +func (o *ListAccountStorageCredentialsResponse) SetStorageCredentials(ctx context.Context, v []StorageCredentialInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["storage_credentials"] + o.StorageCredentials = types.ListValueMust(t, vs) +} + // List catalogs type ListCatalogsRequest struct { // Whether to include catalogs in the response for which the principal can @@ -7295,6 +9274,31 @@ func (o ListCatalogsResponse) Type(ctx context.Context) attr.Type { } } +// GetCatalogs returns the value of the Catalogs field in ListCatalogsResponse as +// a slice of CatalogInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListCatalogsResponse) GetCatalogs(ctx context.Context) ([]CatalogInfo, bool) { + if o.Catalogs.IsNull() || o.Catalogs.IsUnknown() { + return nil, false + } + var v []CatalogInfo + d := o.Catalogs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCatalogs sets the value of the Catalogs field in ListCatalogsResponse. +func (o *ListCatalogsResponse) SetCatalogs(ctx context.Context, v []CatalogInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["catalogs"] + o.Catalogs = types.ListValueMust(t, vs) +} + // List connections type ListConnectionsRequest struct { // Maximum number of connections to return. - If not set, all connections @@ -7399,6 +9403,31 @@ func (o ListConnectionsResponse) Type(ctx context.Context) attr.Type { } } +// GetConnections returns the value of the Connections field in ListConnectionsResponse as +// a slice of ConnectionInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListConnectionsResponse) GetConnections(ctx context.Context) ([]ConnectionInfo, bool) { + if o.Connections.IsNull() || o.Connections.IsUnknown() { + return nil, false + } + var v []ConnectionInfo + d := o.Connections.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetConnections sets the value of the Connections field in ListConnectionsResponse. +func (o *ListConnectionsResponse) SetConnections(ctx context.Context, v []ConnectionInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["connections"] + o.Connections = types.ListValueMust(t, vs) +} + // List credentials type ListCredentialsRequest struct { // Maximum number of credentials to return. - If not set, the default max @@ -7505,6 +9534,31 @@ func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { } } +// GetCredentials returns the value of the Credentials field in ListCredentialsResponse as +// a slice of CredentialInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListCredentialsResponse) GetCredentials(ctx context.Context) ([]CredentialInfo, bool) { + if o.Credentials.IsNull() || o.Credentials.IsUnknown() { + return nil, false + } + var v []CredentialInfo + d := o.Credentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCredentials sets the value of the Credentials field in ListCredentialsResponse. +func (o *ListCredentialsResponse) SetCredentials(ctx context.Context, v []CredentialInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credentials"] + o.Credentials = types.ListValueMust(t, vs) +} + // List external locations type ListExternalLocationsRequest struct { // Whether to include external locations in the response for which the @@ -7614,6 +9668,31 @@ func (o ListExternalLocationsResponse) Type(ctx context.Context) attr.Type { } } +// GetExternalLocations returns the value of the ExternalLocations field in ListExternalLocationsResponse as +// a slice of ExternalLocationInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListExternalLocationsResponse) GetExternalLocations(ctx context.Context) ([]ExternalLocationInfo, bool) { + if o.ExternalLocations.IsNull() || o.ExternalLocations.IsUnknown() { + return nil, false + } + var v []ExternalLocationInfo + d := o.ExternalLocations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExternalLocations sets the value of the ExternalLocations field in ListExternalLocationsResponse. +func (o *ListExternalLocationsResponse) SetExternalLocations(ctx context.Context, v []ExternalLocationInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_locations"] + o.ExternalLocations = types.ListValueMust(t, vs) +} + // List functions type ListFunctionsRequest struct { // Name of parent catalog for functions of interest. @@ -7731,6 +9810,31 @@ func (o ListFunctionsResponse) Type(ctx context.Context) attr.Type { } } +// GetFunctions returns the value of the Functions field in ListFunctionsResponse as +// a slice of FunctionInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListFunctionsResponse) GetFunctions(ctx context.Context) ([]FunctionInfo, bool) { + if o.Functions.IsNull() || o.Functions.IsUnknown() { + return nil, false + } + var v []FunctionInfo + d := o.Functions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFunctions sets the value of the Functions field in ListFunctionsResponse. +func (o *ListFunctionsResponse) SetFunctions(ctx context.Context, v []FunctionInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["functions"] + o.Functions = types.ListValueMust(t, vs) +} + type ListMetastoresResponse struct { // An array of metastore information objects. Metastores types.List `tfsdk:"metastores" tf:"optional"` @@ -7777,6 +9881,31 @@ func (o ListMetastoresResponse) Type(ctx context.Context) attr.Type { } } +// GetMetastores returns the value of the Metastores field in ListMetastoresResponse as +// a slice of MetastoreInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListMetastoresResponse) GetMetastores(ctx context.Context) ([]MetastoreInfo, bool) { + if o.Metastores.IsNull() || o.Metastores.IsUnknown() { + return nil, false + } + var v []MetastoreInfo + d := o.Metastores.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMetastores sets the value of the Metastores field in ListMetastoresResponse. +func (o *ListMetastoresResponse) SetMetastores(ctx context.Context, v []MetastoreInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastores"] + o.Metastores = types.ListValueMust(t, vs) +} + // List Model Versions type ListModelVersionsRequest struct { // The full three-level name of the registered model under which to list @@ -7891,6 +10020,31 @@ func (o ListModelVersionsResponse) Type(ctx context.Context) attr.Type { } } +// GetModelVersions returns the value of the ModelVersions field in ListModelVersionsResponse as +// a slice of ModelVersionInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListModelVersionsResponse) GetModelVersions(ctx context.Context) ([]ModelVersionInfo, bool) { + if o.ModelVersions.IsNull() || o.ModelVersions.IsUnknown() { + return nil, false + } + var v []ModelVersionInfo + d := o.ModelVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetModelVersions sets the value of the ModelVersions field in ListModelVersionsResponse. +func (o *ListModelVersionsResponse) SetModelVersions(ctx context.Context, v []ModelVersionInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_versions"] + o.ModelVersions = types.ListValueMust(t, vs) +} + // List all resource quotas under a metastore. type ListQuotasRequest struct { // The number of quotas to return. @@ -7990,6 +10144,31 @@ func (o ListQuotasResponse) Type(ctx context.Context) attr.Type { } } +// GetQuotas returns the value of the Quotas field in ListQuotasResponse as +// a slice of QuotaInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListQuotasResponse) GetQuotas(ctx context.Context) ([]QuotaInfo, bool) { + if o.Quotas.IsNull() || o.Quotas.IsUnknown() { + return nil, false + } + var v []QuotaInfo + d := o.Quotas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetQuotas sets the value of the Quotas field in ListQuotasResponse. +func (o *ListQuotasResponse) SetQuotas(ctx context.Context, v []QuotaInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["quotas"] + o.Quotas = types.ListValueMust(t, vs) +} + // List refreshes type ListRefreshesRequest struct { // Full name of the table. @@ -8162,6 +10341,31 @@ func (o ListRegisteredModelsResponse) Type(ctx context.Context) attr.Type { } } +// GetRegisteredModels returns the value of the RegisteredModels field in ListRegisteredModelsResponse as +// a slice of RegisteredModelInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListRegisteredModelsResponse) GetRegisteredModels(ctx context.Context) ([]RegisteredModelInfo, bool) { + if o.RegisteredModels.IsNull() || o.RegisteredModels.IsUnknown() { + return nil, false + } + var v []RegisteredModelInfo + d := o.RegisteredModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRegisteredModels sets the value of the RegisteredModels field in ListRegisteredModelsResponse. +func (o *ListRegisteredModelsResponse) SetRegisteredModels(ctx context.Context, v []RegisteredModelInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_models"] + o.RegisteredModels = types.ListValueMust(t, vs) +} + // List schemas type ListSchemasRequest struct { // Parent catalog for schemas of interest. @@ -8275,6 +10479,31 @@ func (o ListSchemasResponse) Type(ctx context.Context) attr.Type { } } +// GetSchemas returns the value of the Schemas field in ListSchemasResponse as +// a slice of SchemaInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListSchemasResponse) GetSchemas(ctx context.Context) ([]SchemaInfo, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []SchemaInfo + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in ListSchemasResponse. +func (o *ListSchemasResponse) SetSchemas(ctx context.Context, v []SchemaInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + // List credentials type ListStorageCredentialsRequest struct { // Maximum number of storage credentials to return. If not set, all the @@ -8379,6 +10608,31 @@ func (o ListStorageCredentialsResponse) Type(ctx context.Context) attr.Type { } } +// GetStorageCredentials returns the value of the StorageCredentials field in ListStorageCredentialsResponse as +// a slice of StorageCredentialInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListStorageCredentialsResponse) GetStorageCredentials(ctx context.Context) ([]StorageCredentialInfo, bool) { + if o.StorageCredentials.IsNull() || o.StorageCredentials.IsUnknown() { + return nil, false + } + var v []StorageCredentialInfo + d := o.StorageCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStorageCredentials sets the value of the StorageCredentials field in ListStorageCredentialsResponse. +func (o *ListStorageCredentialsResponse) SetStorageCredentials(ctx context.Context, v []StorageCredentialInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["storage_credentials"] + o.StorageCredentials = types.ListValueMust(t, vs) +} + // List table summaries type ListSummariesRequest struct { // Name of parent catalog for tables of interest. @@ -8558,6 +10812,31 @@ func (o ListSystemSchemasResponse) Type(ctx context.Context) attr.Type { } } +// GetSchemas returns the value of the Schemas field in ListSystemSchemasResponse as +// a slice of SystemSchemaInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListSystemSchemasResponse) GetSchemas(ctx context.Context) ([]SystemSchemaInfo, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []SystemSchemaInfo + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in ListSystemSchemasResponse. +func (o *ListSystemSchemasResponse) SetSchemas(ctx context.Context, v []SystemSchemaInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + type ListTableSummariesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -8610,6 +10889,31 @@ func (o ListTableSummariesResponse) Type(ctx context.Context) attr.Type { } } +// GetTables returns the value of the Tables field in ListTableSummariesResponse as +// a slice of TableSummary values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListTableSummariesResponse) GetTables(ctx context.Context) ([]TableSummary, bool) { + if o.Tables.IsNull() || o.Tables.IsUnknown() { + return nil, false + } + var v []TableSummary + d := o.Tables.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTables sets the value of the Tables field in ListTableSummariesResponse. +func (o *ListTableSummariesResponse) SetTables(ctx context.Context, v []TableSummary) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tables"] + o.Tables = types.ListValueMust(t, vs) +} + // List tables type ListTablesRequest struct { // Name of parent catalog for tables of interest. @@ -8748,6 +11052,31 @@ func (o ListTablesResponse) Type(ctx context.Context) attr.Type { } } +// GetTables returns the value of the Tables field in ListTablesResponse as +// a slice of TableInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListTablesResponse) GetTables(ctx context.Context) ([]TableInfo, bool) { + if o.Tables.IsNull() || o.Tables.IsUnknown() { + return nil, false + } + var v []TableInfo + d := o.Tables.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTables sets the value of the Tables field in ListTablesResponse. +func (o *ListTablesResponse) SetTables(ctx context.Context, v []TableInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tables"] + o.Tables = types.ListValueMust(t, vs) +} + // List Volumes type ListVolumesRequest struct { // The identifier of the catalog @@ -8872,6 +11201,31 @@ func (o ListVolumesResponseContent) Type(ctx context.Context) attr.Type { } } +// GetVolumes returns the value of the Volumes field in ListVolumesResponseContent as +// a slice of VolumeInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListVolumesResponseContent) GetVolumes(ctx context.Context) ([]VolumeInfo, bool) { + if o.Volumes.IsNull() || o.Volumes.IsUnknown() { + return nil, false + } + var v []VolumeInfo + d := o.Volumes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetVolumes sets the value of the Volumes field in ListVolumesResponseContent. +func (o *ListVolumesResponseContent) SetVolumes(ctx context.Context, v []VolumeInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["volumes"] + o.Volumes = types.ListValueMust(t, vs) +} + type MetastoreAssignment struct { // The name of the default catalog in the metastore. DefaultCatalogName types.String `tfsdk:"default_catalog_name" tf:"optional"` @@ -9173,6 +11527,57 @@ func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { } } +// GetAliases returns the value of the Aliases field in ModelVersionInfo as +// a slice of RegisteredModelAlias values. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelVersionInfo) GetAliases(ctx context.Context) ([]RegisteredModelAlias, bool) { + if o.Aliases.IsNull() || o.Aliases.IsUnknown() { + return nil, false + } + var v []RegisteredModelAlias + d := o.Aliases.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAliases sets the value of the Aliases field in ModelVersionInfo. +func (o *ModelVersionInfo) SetAliases(ctx context.Context, v []RegisteredModelAlias) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aliases"] + o.Aliases = types.ListValueMust(t, vs) +} + +// GetModelVersionDependencies returns the value of the ModelVersionDependencies field in ModelVersionInfo as +// a DependencyList value. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelVersionInfo) GetModelVersionDependencies(ctx context.Context) (DependencyList, bool) { + var e DependencyList + if o.ModelVersionDependencies.IsNull() || o.ModelVersionDependencies.IsUnknown() { + return e, false + } + var v []DependencyList + d := o.ModelVersionDependencies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetModelVersionDependencies sets the value of the ModelVersionDependencies field in ModelVersionInfo. +func (o *ModelVersionInfo) SetModelVersionDependencies(ctx context.Context, v DependencyList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_version_dependencies"] + o.ModelVersionDependencies = types.ListValueMust(t, vs) +} + type MonitorCronSchedule struct { // Read only field that indicates whether a schedule is paused or not. PauseStatus types.String `tfsdk:"pause_status" tf:"optional"` @@ -9315,6 +11720,31 @@ func (o MonitorDestination) Type(ctx context.Context) attr.Type { } } +// GetEmailAddresses returns the value of the EmailAddresses field in MonitorDestination as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorDestination) GetEmailAddresses(ctx context.Context) ([]types.String, bool) { + if o.EmailAddresses.IsNull() || o.EmailAddresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.EmailAddresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmailAddresses sets the value of the EmailAddresses field in MonitorDestination. +func (o *MonitorDestination) SetEmailAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_addresses"] + o.EmailAddresses = types.ListValueMust(t, vs) +} + type MonitorInferenceLog struct { // Granularities for aggregating data into time windows based on their // timestamp. Currently the following static granularities are supported: @@ -9399,6 +11829,31 @@ func (o MonitorInferenceLog) Type(ctx context.Context) attr.Type { } } +// GetGranularities returns the value of the Granularities field in MonitorInferenceLog as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInferenceLog) GetGranularities(ctx context.Context) ([]types.String, bool) { + if o.Granularities.IsNull() || o.Granularities.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Granularities.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGranularities sets the value of the Granularities field in MonitorInferenceLog. +func (o *MonitorInferenceLog) SetGranularities(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["granularities"] + o.Granularities = types.ListValueMust(t, vs) +} + type MonitorInfo struct { // The directory to store monitoring assets (e.g. dashboard, metric tables). AssetsDir types.String `tfsdk:"assets_dir" tf:"optional"` @@ -9547,53 +12002,259 @@ func (o MonitorInfo) Type(ctx context.Context) attr.Type { } } -type MonitorMetric struct { - // Jinja template for a SQL expression that specifies how to compute the - // metric. See [create metric definition]. - // - // [create metric definition]: https://docs.databricks.com/en/lakehouse-monitoring/custom-metrics.html#create-definition - Definition types.String `tfsdk:"definition" tf:""` - // A list of column names in the input table the metric should be computed - // for. Can use ``":table"`` to indicate that the metric needs information - // from multiple columns. - InputColumns types.List `tfsdk:"input_columns" tf:""` - // Name of the metric in the output tables. - Name types.String `tfsdk:"name" tf:""` - // The output type of the custom metric. - OutputDataType types.String `tfsdk:"output_data_type" tf:""` - // Can only be one of ``"CUSTOM_METRIC_TYPE_AGGREGATE"``, - // ``"CUSTOM_METRIC_TYPE_DERIVED"``, or ``"CUSTOM_METRIC_TYPE_DRIFT"``. The - // ``"CUSTOM_METRIC_TYPE_AGGREGATE"`` and ``"CUSTOM_METRIC_TYPE_DERIVED"`` - // metrics are computed on a single table, whereas the - // ``"CUSTOM_METRIC_TYPE_DRIFT"`` compare metrics across baseline and input - // table, or across the two consecutive time windows. - - // CUSTOM_METRIC_TYPE_AGGREGATE: only depend on the existing columns in your - // table - CUSTOM_METRIC_TYPE_DERIVED: depend on previously computed - // aggregate metrics - CUSTOM_METRIC_TYPE_DRIFT: depend on previously - // computed aggregate or derived metrics - Type_ types.String `tfsdk:"type" tf:""` +// GetCustomMetrics returns the value of the CustomMetrics field in MonitorInfo as +// a slice of MonitorMetric values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetCustomMetrics(ctx context.Context) ([]MonitorMetric, bool) { + if o.CustomMetrics.IsNull() || o.CustomMetrics.IsUnknown() { + return nil, false + } + var v []MonitorMetric + d := o.CustomMetrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true } -func (newState *MonitorMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorMetric) { +// SetCustomMetrics sets the value of the CustomMetrics field in MonitorInfo. +func (o *MonitorInfo) SetCustomMetrics(ctx context.Context, v []MonitorMetric) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_metrics"] + o.CustomMetrics = types.ListValueMust(t, vs) } -func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState MonitorMetric) { +// GetDataClassificationConfig returns the value of the DataClassificationConfig field in MonitorInfo as +// a MonitorDataClassificationConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetDataClassificationConfig(ctx context.Context) (MonitorDataClassificationConfig, bool) { + var e MonitorDataClassificationConfig + if o.DataClassificationConfig.IsNull() || o.DataClassificationConfig.IsUnknown() { + return e, false + } + var v []MonitorDataClassificationConfig + d := o.DataClassificationConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorMetric. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "input_columns": reflect.TypeOf(types.String{}), +// SetDataClassificationConfig sets the value of the DataClassificationConfig field in MonitorInfo. +func (o *MonitorInfo) SetDataClassificationConfig(ctx context.Context, v MonitorDataClassificationConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_classification_config"] + o.DataClassificationConfig = types.ListValueMust(t, vs) +} + +// GetInferenceLog returns the value of the InferenceLog field in MonitorInfo as +// a MonitorInferenceLog value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetInferenceLog(ctx context.Context) (MonitorInferenceLog, bool) { + var e MonitorInferenceLog + if o.InferenceLog.IsNull() || o.InferenceLog.IsUnknown() { + return e, false + } + var v []MonitorInferenceLog + d := o.InferenceLog.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) } + if len(v) == 0 { + return e, false + } + return v[0], true } -// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// SetInferenceLog sets the value of the InferenceLog field in MonitorInfo. +func (o *MonitorInfo) SetInferenceLog(ctx context.Context, v MonitorInferenceLog) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inference_log"] + o.InferenceLog = types.ListValueMust(t, vs) +} + +// GetNotifications returns the value of the Notifications field in MonitorInfo as +// a MonitorNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetNotifications(ctx context.Context) (MonitorNotifications, bool) { + var e MonitorNotifications + if o.Notifications.IsNull() || o.Notifications.IsUnknown() { + return e, false + } + var v []MonitorNotifications + d := o.Notifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotifications sets the value of the Notifications field in MonitorInfo. +func (o *MonitorInfo) SetNotifications(ctx context.Context, v MonitorNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + o.Notifications = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in MonitorInfo as +// a MonitorCronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetSchedule(ctx context.Context) (MonitorCronSchedule, bool) { + var e MonitorCronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []MonitorCronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in MonitorInfo. +func (o *MonitorInfo) SetSchedule(ctx context.Context, v MonitorCronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetSlicingExprs returns the value of the SlicingExprs field in MonitorInfo as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetSlicingExprs(ctx context.Context) ([]types.String, bool) { + if o.SlicingExprs.IsNull() || o.SlicingExprs.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SlicingExprs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSlicingExprs sets the value of the SlicingExprs field in MonitorInfo. +func (o *MonitorInfo) SetSlicingExprs(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slicing_exprs"] + o.SlicingExprs = types.ListValueMust(t, vs) +} + +// GetSnapshot returns the value of the Snapshot field in MonitorInfo as +// a MonitorSnapshot value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetSnapshot(ctx context.Context) (MonitorSnapshot, bool) { + var e MonitorSnapshot + if o.Snapshot.IsNull() || o.Snapshot.IsUnknown() { + return e, false + } + var v []MonitorSnapshot + d := o.Snapshot.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSnapshot sets the value of the Snapshot field in MonitorInfo. +func (o *MonitorInfo) SetSnapshot(ctx context.Context, v MonitorSnapshot) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["snapshot"] + o.Snapshot = types.ListValueMust(t, vs) +} + +// GetTimeSeries returns the value of the TimeSeries field in MonitorInfo as +// a MonitorTimeSeries value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorInfo) GetTimeSeries(ctx context.Context) (MonitorTimeSeries, bool) { + var e MonitorTimeSeries + if o.TimeSeries.IsNull() || o.TimeSeries.IsUnknown() { + return e, false + } + var v []MonitorTimeSeries + d := o.TimeSeries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTimeSeries sets the value of the TimeSeries field in MonitorInfo. +func (o *MonitorInfo) SetTimeSeries(ctx context.Context, v MonitorTimeSeries) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["time_series"] + o.TimeSeries = types.ListValueMust(t, vs) +} + +type MonitorMetric struct { + // Jinja template for a SQL expression that specifies how to compute the + // metric. See [create metric definition]. + // + // [create metric definition]: https://docs.databricks.com/en/lakehouse-monitoring/custom-metrics.html#create-definition + Definition types.String `tfsdk:"definition" tf:""` + // A list of column names in the input table the metric should be computed + // for. Can use ``":table"`` to indicate that the metric needs information + // from multiple columns. + InputColumns types.List `tfsdk:"input_columns" tf:""` + // Name of the metric in the output tables. + Name types.String `tfsdk:"name" tf:""` + // The output type of the custom metric. + OutputDataType types.String `tfsdk:"output_data_type" tf:""` + // Can only be one of ``"CUSTOM_METRIC_TYPE_AGGREGATE"``, + // ``"CUSTOM_METRIC_TYPE_DERIVED"``, or ``"CUSTOM_METRIC_TYPE_DRIFT"``. The + // ``"CUSTOM_METRIC_TYPE_AGGREGATE"`` and ``"CUSTOM_METRIC_TYPE_DERIVED"`` + // metrics are computed on a single table, whereas the + // ``"CUSTOM_METRIC_TYPE_DRIFT"`` compare metrics across baseline and input + // table, or across the two consecutive time windows. - + // CUSTOM_METRIC_TYPE_AGGREGATE: only depend on the existing columns in your + // table - CUSTOM_METRIC_TYPE_DERIVED: depend on previously computed + // aggregate metrics - CUSTOM_METRIC_TYPE_DRIFT: depend on previously + // computed aggregate or derived metrics + Type_ types.String `tfsdk:"type" tf:""` +} + +func (newState *MonitorMetric) SyncEffectiveFieldsDuringCreateOrUpdate(plan MonitorMetric) { +} + +func (newState *MonitorMetric) SyncEffectiveFieldsDuringRead(existingState MonitorMetric) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in MonitorMetric. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a MonitorMetric) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "input_columns": reflect.TypeOf(types.String{}), + } +} + +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise // interfere with how the plugin framework retrieves and sets values in state. Thus, MonitorMetric // only implements ToObjectValue() and Type(). func (o MonitorMetric) ToObjectValue(ctx context.Context) basetypes.ObjectValue { @@ -9623,6 +12284,31 @@ func (o MonitorMetric) Type(ctx context.Context) attr.Type { } } +// GetInputColumns returns the value of the InputColumns field in MonitorMetric as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorMetric) GetInputColumns(ctx context.Context) ([]types.String, bool) { + if o.InputColumns.IsNull() || o.InputColumns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InputColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInputColumns sets the value of the InputColumns field in MonitorMetric. +func (o *MonitorMetric) SetInputColumns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input_columns"] + o.InputColumns = types.ListValueMust(t, vs) +} + type MonitorNotifications struct { // Who to send notifications to on monitor failure. OnFailure types.List `tfsdk:"on_failure" tf:"optional,object"` @@ -9677,6 +12363,58 @@ func (o MonitorNotifications) Type(ctx context.Context) attr.Type { } } +// GetOnFailure returns the value of the OnFailure field in MonitorNotifications as +// a MonitorDestination value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorNotifications) GetOnFailure(ctx context.Context) (MonitorDestination, bool) { + var e MonitorDestination + if o.OnFailure.IsNull() || o.OnFailure.IsUnknown() { + return e, false + } + var v []MonitorDestination + d := o.OnFailure.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOnFailure sets the value of the OnFailure field in MonitorNotifications. +func (o *MonitorNotifications) SetOnFailure(ctx context.Context, v MonitorDestination) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + o.OnFailure = types.ListValueMust(t, vs) +} + +// GetOnNewClassificationTagDetected returns the value of the OnNewClassificationTagDetected field in MonitorNotifications as +// a MonitorDestination value. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorNotifications) GetOnNewClassificationTagDetected(ctx context.Context) (MonitorDestination, bool) { + var e MonitorDestination + if o.OnNewClassificationTagDetected.IsNull() || o.OnNewClassificationTagDetected.IsUnknown() { + return e, false + } + var v []MonitorDestination + d := o.OnNewClassificationTagDetected.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOnNewClassificationTagDetected sets the value of the OnNewClassificationTagDetected field in MonitorNotifications. +func (o *MonitorNotifications) SetOnNewClassificationTagDetected(ctx context.Context, v MonitorDestination) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_new_classification_tag_detected"] + o.OnNewClassificationTagDetected = types.ListValueMust(t, vs) +} + type MonitorRefreshInfo struct { // Time at which refresh operation completed (milliseconds since 1/1/1970 // UTC). @@ -9788,6 +12526,31 @@ func (o MonitorRefreshListResponse) Type(ctx context.Context) attr.Type { } } +// GetRefreshes returns the value of the Refreshes field in MonitorRefreshListResponse as +// a slice of MonitorRefreshInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorRefreshListResponse) GetRefreshes(ctx context.Context) ([]MonitorRefreshInfo, bool) { + if o.Refreshes.IsNull() || o.Refreshes.IsUnknown() { + return nil, false + } + var v []MonitorRefreshInfo + d := o.Refreshes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRefreshes sets the value of the Refreshes field in MonitorRefreshListResponse. +func (o *MonitorRefreshListResponse) SetRefreshes(ctx context.Context, v []MonitorRefreshInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["refreshes"] + o.Refreshes = types.ListValueMust(t, vs) +} + type MonitorSnapshot struct { } @@ -9882,6 +12645,31 @@ func (o MonitorTimeSeries) Type(ctx context.Context) attr.Type { } } +// GetGranularities returns the value of the Granularities field in MonitorTimeSeries as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *MonitorTimeSeries) GetGranularities(ctx context.Context) ([]types.String, bool) { + if o.Granularities.IsNull() || o.Granularities.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Granularities.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGranularities sets the value of the Granularities field in MonitorTimeSeries. +func (o *MonitorTimeSeries) SetGranularities(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["granularities"] + o.Granularities = types.ListValueMust(t, vs) +} + type NamedTableConstraint struct { // The name of the constraint. Name types.String `tfsdk:"name" tf:""` @@ -9993,6 +12781,58 @@ func (o OnlineTable) Type(ctx context.Context) attr.Type { } } +// GetSpec returns the value of the Spec field in OnlineTable as +// a OnlineTableSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTable) GetSpec(ctx context.Context) (OnlineTableSpec, bool) { + var e OnlineTableSpec + if o.Spec.IsNull() || o.Spec.IsUnknown() { + return e, false + } + var v []OnlineTableSpec + d := o.Spec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSpec sets the value of the Spec field in OnlineTable. +func (o *OnlineTable) SetSpec(ctx context.Context, v OnlineTableSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spec"] + o.Spec = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in OnlineTable as +// a OnlineTableStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTable) GetStatus(ctx context.Context) (OnlineTableStatus, bool) { + var e OnlineTableStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []OnlineTableStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in OnlineTable. +func (o *OnlineTable) SetStatus(ctx context.Context, v OnlineTableStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + // Specification of an online table. type OnlineTableSpec struct { // Whether to create a full-copy pipeline -- a pipeline that stops after @@ -10079,6 +12919,83 @@ func (o OnlineTableSpec) Type(ctx context.Context) attr.Type { } } +// GetPrimaryKeyColumns returns the value of the PrimaryKeyColumns field in OnlineTableSpec as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableSpec) GetPrimaryKeyColumns(ctx context.Context) ([]types.String, bool) { + if o.PrimaryKeyColumns.IsNull() || o.PrimaryKeyColumns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PrimaryKeyColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrimaryKeyColumns sets the value of the PrimaryKeyColumns field in OnlineTableSpec. +func (o *OnlineTableSpec) SetPrimaryKeyColumns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_key_columns"] + o.PrimaryKeyColumns = types.ListValueMust(t, vs) +} + +// GetRunContinuously returns the value of the RunContinuously field in OnlineTableSpec as +// a OnlineTableSpecContinuousSchedulingPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableSpec) GetRunContinuously(ctx context.Context) (OnlineTableSpecContinuousSchedulingPolicy, bool) { + var e OnlineTableSpecContinuousSchedulingPolicy + if o.RunContinuously.IsNull() || o.RunContinuously.IsUnknown() { + return e, false + } + var v []OnlineTableSpecContinuousSchedulingPolicy + d := o.RunContinuously.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunContinuously sets the value of the RunContinuously field in OnlineTableSpec. +func (o *OnlineTableSpec) SetRunContinuously(ctx context.Context, v OnlineTableSpecContinuousSchedulingPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_continuously"] + o.RunContinuously = types.ListValueMust(t, vs) +} + +// GetRunTriggered returns the value of the RunTriggered field in OnlineTableSpec as +// a OnlineTableSpecTriggeredSchedulingPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableSpec) GetRunTriggered(ctx context.Context) (OnlineTableSpecTriggeredSchedulingPolicy, bool) { + var e OnlineTableSpecTriggeredSchedulingPolicy + if o.RunTriggered.IsNull() || o.RunTriggered.IsUnknown() { + return e, false + } + var v []OnlineTableSpecTriggeredSchedulingPolicy + d := o.RunTriggered.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunTriggered sets the value of the RunTriggered field in OnlineTableSpec. +func (o *OnlineTableSpec) SetRunTriggered(ctx context.Context, v OnlineTableSpecTriggeredSchedulingPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_triggered"] + o.RunTriggered = types.ListValueMust(t, vs) +} + type OnlineTableSpecContinuousSchedulingPolicy struct { } @@ -10232,6 +13149,110 @@ func (o OnlineTableStatus) Type(ctx context.Context) attr.Type { } } +// GetContinuousUpdateStatus returns the value of the ContinuousUpdateStatus field in OnlineTableStatus as +// a ContinuousUpdateStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableStatus) GetContinuousUpdateStatus(ctx context.Context) (ContinuousUpdateStatus, bool) { + var e ContinuousUpdateStatus + if o.ContinuousUpdateStatus.IsNull() || o.ContinuousUpdateStatus.IsUnknown() { + return e, false + } + var v []ContinuousUpdateStatus + d := o.ContinuousUpdateStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetContinuousUpdateStatus sets the value of the ContinuousUpdateStatus field in OnlineTableStatus. +func (o *OnlineTableStatus) SetContinuousUpdateStatus(ctx context.Context, v ContinuousUpdateStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["continuous_update_status"] + o.ContinuousUpdateStatus = types.ListValueMust(t, vs) +} + +// GetFailedStatus returns the value of the FailedStatus field in OnlineTableStatus as +// a FailedStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableStatus) GetFailedStatus(ctx context.Context) (FailedStatus, bool) { + var e FailedStatus + if o.FailedStatus.IsNull() || o.FailedStatus.IsUnknown() { + return e, false + } + var v []FailedStatus + d := o.FailedStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFailedStatus sets the value of the FailedStatus field in OnlineTableStatus. +func (o *OnlineTableStatus) SetFailedStatus(ctx context.Context, v FailedStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["failed_status"] + o.FailedStatus = types.ListValueMust(t, vs) +} + +// GetProvisioningStatus returns the value of the ProvisioningStatus field in OnlineTableStatus as +// a ProvisioningStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableStatus) GetProvisioningStatus(ctx context.Context) (ProvisioningStatus, bool) { + var e ProvisioningStatus + if o.ProvisioningStatus.IsNull() || o.ProvisioningStatus.IsUnknown() { + return e, false + } + var v []ProvisioningStatus + d := o.ProvisioningStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvisioningStatus sets the value of the ProvisioningStatus field in OnlineTableStatus. +func (o *OnlineTableStatus) SetProvisioningStatus(ctx context.Context, v ProvisioningStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provisioning_status"] + o.ProvisioningStatus = types.ListValueMust(t, vs) +} + +// GetTriggeredUpdateStatus returns the value of the TriggeredUpdateStatus field in OnlineTableStatus as +// a TriggeredUpdateStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *OnlineTableStatus) GetTriggeredUpdateStatus(ctx context.Context) (TriggeredUpdateStatus, bool) { + var e TriggeredUpdateStatus + if o.TriggeredUpdateStatus.IsNull() || o.TriggeredUpdateStatus.IsUnknown() { + return e, false + } + var v []TriggeredUpdateStatus + d := o.TriggeredUpdateStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTriggeredUpdateStatus sets the value of the TriggeredUpdateStatus field in OnlineTableStatus. +func (o *OnlineTableStatus) SetTriggeredUpdateStatus(ctx context.Context, v TriggeredUpdateStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["triggered_update_status"] + o.TriggeredUpdateStatus = types.ListValueMust(t, vs) +} + type PermissionsChange struct { // The set of privileges to add. Add types.List `tfsdk:"add" tf:"optional"` @@ -10289,6 +13310,56 @@ func (o PermissionsChange) Type(ctx context.Context) attr.Type { } } +// GetAdd returns the value of the Add field in PermissionsChange as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionsChange) GetAdd(ctx context.Context) ([]types.String, bool) { + if o.Add.IsNull() || o.Add.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Add.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAdd sets the value of the Add field in PermissionsChange. +func (o *PermissionsChange) SetAdd(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["add"] + o.Add = types.ListValueMust(t, vs) +} + +// GetRemove returns the value of the Remove field in PermissionsChange as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionsChange) GetRemove(ctx context.Context) ([]types.String, bool) { + if o.Remove.IsNull() || o.Remove.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Remove.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRemove sets the value of the Remove field in PermissionsChange. +func (o *PermissionsChange) SetRemove(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["remove"] + o.Remove = types.ListValueMust(t, vs) +} + type PermissionsList struct { // The privileges assigned to each principal PrivilegeAssignments types.List `tfsdk:"privilege_assignments" tf:"optional"` @@ -10335,6 +13406,31 @@ func (o PermissionsList) Type(ctx context.Context) attr.Type { } } +// GetPrivilegeAssignments returns the value of the PrivilegeAssignments field in PermissionsList as +// a slice of PrivilegeAssignment values. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionsList) GetPrivilegeAssignments(ctx context.Context) ([]PrivilegeAssignment, bool) { + if o.PrivilegeAssignments.IsNull() || o.PrivilegeAssignments.IsUnknown() { + return nil, false + } + var v []PrivilegeAssignment + d := o.PrivilegeAssignments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrivilegeAssignments sets the value of the PrivilegeAssignments field in PermissionsList. +func (o *PermissionsList) SetPrivilegeAssignments(ctx context.Context, v []PrivilegeAssignment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privilege_assignments"] + o.PrivilegeAssignments = types.ListValueMust(t, vs) +} + // Progress information of the Online Table data synchronization pipeline. type PipelineProgress struct { // The estimated time remaining to complete this update in seconds. @@ -10446,6 +13542,31 @@ func (o PrimaryKeyConstraint) Type(ctx context.Context) attr.Type { } } +// GetChildColumns returns the value of the ChildColumns field in PrimaryKeyConstraint as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PrimaryKeyConstraint) GetChildColumns(ctx context.Context) ([]types.String, bool) { + if o.ChildColumns.IsNull() || o.ChildColumns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ChildColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetChildColumns sets the value of the ChildColumns field in PrimaryKeyConstraint. +func (o *PrimaryKeyConstraint) SetChildColumns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["child_columns"] + o.ChildColumns = types.ListValueMust(t, vs) +} + type PrivilegeAssignment struct { // The principal (user email address or group name). Principal types.String `tfsdk:"principal" tf:"optional"` @@ -10496,6 +13617,31 @@ func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { } } +// GetPrivileges returns the value of the Privileges field in PrivilegeAssignment as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PrivilegeAssignment) GetPrivileges(ctx context.Context) ([]types.String, bool) { + if o.Privileges.IsNull() || o.Privileges.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Privileges.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrivileges sets the value of the Privileges field in PrivilegeAssignment. +func (o *PrivilegeAssignment) SetPrivileges(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privileges"] + o.Privileges = types.ListValueMust(t, vs) +} + // Status of an asynchronously provisioned resource. type ProvisioningInfo struct { State types.String `tfsdk:"state" tf:"optional"` @@ -10587,6 +13733,32 @@ func (o ProvisioningStatus) Type(ctx context.Context) attr.Type { } } +// GetInitialPipelineSyncProgress returns the value of the InitialPipelineSyncProgress field in ProvisioningStatus as +// a PipelineProgress value. +// If the field is unknown or null, the boolean return value is false. +func (o *ProvisioningStatus) GetInitialPipelineSyncProgress(ctx context.Context) (PipelineProgress, bool) { + var e PipelineProgress + if o.InitialPipelineSyncProgress.IsNull() || o.InitialPipelineSyncProgress.IsUnknown() { + return e, false + } + var v []PipelineProgress + d := o.InitialPipelineSyncProgress.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInitialPipelineSyncProgress sets the value of the InitialPipelineSyncProgress field in ProvisioningStatus. +func (o *ProvisioningStatus) SetInitialPipelineSyncProgress(ctx context.Context, v PipelineProgress) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["initial_pipeline_sync_progress"] + o.InitialPipelineSyncProgress = types.ListValueMust(t, vs) +} + type QuotaInfo struct { // The timestamp that indicates when the quota count was last updated. LastRefreshedAt types.Int64 `tfsdk:"last_refreshed_at" tf:"optional"` @@ -10993,6 +14165,31 @@ func (o RegisteredModelInfo) Type(ctx context.Context) attr.Type { } } +// GetAliases returns the value of the Aliases field in RegisteredModelInfo as +// a slice of RegisteredModelAlias values. +// If the field is unknown or null, the boolean return value is false. +func (o *RegisteredModelInfo) GetAliases(ctx context.Context) ([]RegisteredModelAlias, bool) { + if o.Aliases.IsNull() || o.Aliases.IsUnknown() { + return nil, false + } + var v []RegisteredModelAlias + d := o.Aliases.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAliases sets the value of the Aliases field in RegisteredModelInfo. +func (o *RegisteredModelInfo) SetAliases(ctx context.Context, v []RegisteredModelAlias) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aliases"] + o.Aliases = types.ListValueMust(t, vs) +} + // Queue a metric refresh for a monitor type RunRefreshRequest struct { // Full name of the table. @@ -11156,6 +14353,57 @@ func (o SchemaInfo) Type(ctx context.Context) attr.Type { } } +// GetEffectivePredictiveOptimizationFlag returns the value of the EffectivePredictiveOptimizationFlag field in SchemaInfo as +// a EffectivePredictiveOptimizationFlag value. +// If the field is unknown or null, the boolean return value is false. +func (o *SchemaInfo) GetEffectivePredictiveOptimizationFlag(ctx context.Context) (EffectivePredictiveOptimizationFlag, bool) { + var e EffectivePredictiveOptimizationFlag + if o.EffectivePredictiveOptimizationFlag.IsNull() || o.EffectivePredictiveOptimizationFlag.IsUnknown() { + return e, false + } + var v []EffectivePredictiveOptimizationFlag + d := o.EffectivePredictiveOptimizationFlag.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEffectivePredictiveOptimizationFlag sets the value of the EffectivePredictiveOptimizationFlag field in SchemaInfo. +func (o *SchemaInfo) SetEffectivePredictiveOptimizationFlag(ctx context.Context, v EffectivePredictiveOptimizationFlag) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["effective_predictive_optimization_flag"] + o.EffectivePredictiveOptimizationFlag = types.ListValueMust(t, vs) +} + +// GetProperties returns the value of the Properties field in SchemaInfo as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SchemaInfo) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in SchemaInfo. +func (o *SchemaInfo) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type SetArtifactAllowlist struct { // A list of allowed artifact match patterns. ArtifactMatchers types.List `tfsdk:"artifact_matchers" tf:""` @@ -11206,6 +14454,31 @@ func (o SetArtifactAllowlist) Type(ctx context.Context) attr.Type { } } +// GetArtifactMatchers returns the value of the ArtifactMatchers field in SetArtifactAllowlist as +// a slice of ArtifactMatcher values. +// If the field is unknown or null, the boolean return value is false. +func (o *SetArtifactAllowlist) GetArtifactMatchers(ctx context.Context) ([]ArtifactMatcher, bool) { + if o.ArtifactMatchers.IsNull() || o.ArtifactMatchers.IsUnknown() { + return nil, false + } + var v []ArtifactMatcher + d := o.ArtifactMatchers.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetArtifactMatchers sets the value of the ArtifactMatchers field in SetArtifactAllowlist. +func (o *SetArtifactAllowlist) SetArtifactMatchers(ctx context.Context, v []ArtifactMatcher) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["artifact_matchers"] + o.ArtifactMatchers = types.ListValueMust(t, vs) +} + type SetRegisteredModelAliasRequest struct { // The name of the alias Alias types.String `tfsdk:"alias" tf:""` @@ -11431,10 +14704,140 @@ func (o StorageCredentialInfo) Type(ctx context.Context) attr.Type { } } -type SystemSchemaInfo struct { - // Name of the system schema. - Schema types.String `tfsdk:"schema" tf:"optional"` - // The current state of enablement for the system schema. An empty string +// GetAwsIamRole returns the value of the AwsIamRole field in StorageCredentialInfo as +// a AwsIamRoleResponse value. +// If the field is unknown or null, the boolean return value is false. +func (o *StorageCredentialInfo) GetAwsIamRole(ctx context.Context) (AwsIamRoleResponse, bool) { + var e AwsIamRoleResponse + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRoleResponse + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in StorageCredentialInfo. +func (o *StorageCredentialInfo) SetAwsIamRole(ctx context.Context, v AwsIamRoleResponse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in StorageCredentialInfo as +// a AzureManagedIdentityResponse value. +// If the field is unknown or null, the boolean return value is false. +func (o *StorageCredentialInfo) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentityResponse, bool) { + var e AzureManagedIdentityResponse + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentityResponse + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in StorageCredentialInfo. +func (o *StorageCredentialInfo) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentityResponse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in StorageCredentialInfo as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *StorageCredentialInfo) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in StorageCredentialInfo. +func (o *StorageCredentialInfo) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + +// GetCloudflareApiToken returns the value of the CloudflareApiToken field in StorageCredentialInfo as +// a CloudflareApiToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *StorageCredentialInfo) GetCloudflareApiToken(ctx context.Context) (CloudflareApiToken, bool) { + var e CloudflareApiToken + if o.CloudflareApiToken.IsNull() || o.CloudflareApiToken.IsUnknown() { + return e, false + } + var v []CloudflareApiToken + d := o.CloudflareApiToken.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCloudflareApiToken sets the value of the CloudflareApiToken field in StorageCredentialInfo. +func (o *StorageCredentialInfo) SetCloudflareApiToken(ctx context.Context, v CloudflareApiToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cloudflare_api_token"] + o.CloudflareApiToken = types.ListValueMust(t, vs) +} + +// GetDatabricksGcpServiceAccount returns the value of the DatabricksGcpServiceAccount field in StorageCredentialInfo as +// a DatabricksGcpServiceAccountResponse value. +// If the field is unknown or null, the boolean return value is false. +func (o *StorageCredentialInfo) GetDatabricksGcpServiceAccount(ctx context.Context) (DatabricksGcpServiceAccountResponse, bool) { + var e DatabricksGcpServiceAccountResponse + if o.DatabricksGcpServiceAccount.IsNull() || o.DatabricksGcpServiceAccount.IsUnknown() { + return e, false + } + var v []DatabricksGcpServiceAccountResponse + d := o.DatabricksGcpServiceAccount.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDatabricksGcpServiceAccount sets the value of the DatabricksGcpServiceAccount field in StorageCredentialInfo. +func (o *StorageCredentialInfo) SetDatabricksGcpServiceAccount(ctx context.Context, v DatabricksGcpServiceAccountResponse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["databricks_gcp_service_account"] + o.DatabricksGcpServiceAccount = types.ListValueMust(t, vs) +} + +type SystemSchemaInfo struct { + // Name of the system schema. + Schema types.String `tfsdk:"schema" tf:"optional"` + // The current state of enablement for the system schema. An empty string // means the system schema is available and ready for opt-in. State types.String `tfsdk:"state" tf:"optional"` } @@ -11540,6 +14943,84 @@ func (o TableConstraint) Type(ctx context.Context) attr.Type { } } +// GetForeignKeyConstraint returns the value of the ForeignKeyConstraint field in TableConstraint as +// a ForeignKeyConstraint value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableConstraint) GetForeignKeyConstraint(ctx context.Context) (ForeignKeyConstraint, bool) { + var e ForeignKeyConstraint + if o.ForeignKeyConstraint.IsNull() || o.ForeignKeyConstraint.IsUnknown() { + return e, false + } + var v []ForeignKeyConstraint + d := o.ForeignKeyConstraint.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetForeignKeyConstraint sets the value of the ForeignKeyConstraint field in TableConstraint. +func (o *TableConstraint) SetForeignKeyConstraint(ctx context.Context, v ForeignKeyConstraint) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["foreign_key_constraint"] + o.ForeignKeyConstraint = types.ListValueMust(t, vs) +} + +// GetNamedTableConstraint returns the value of the NamedTableConstraint field in TableConstraint as +// a NamedTableConstraint value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableConstraint) GetNamedTableConstraint(ctx context.Context) (NamedTableConstraint, bool) { + var e NamedTableConstraint + if o.NamedTableConstraint.IsNull() || o.NamedTableConstraint.IsUnknown() { + return e, false + } + var v []NamedTableConstraint + d := o.NamedTableConstraint.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNamedTableConstraint sets the value of the NamedTableConstraint field in TableConstraint. +func (o *TableConstraint) SetNamedTableConstraint(ctx context.Context, v NamedTableConstraint) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["named_table_constraint"] + o.NamedTableConstraint = types.ListValueMust(t, vs) +} + +// GetPrimaryKeyConstraint returns the value of the PrimaryKeyConstraint field in TableConstraint as +// a PrimaryKeyConstraint value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableConstraint) GetPrimaryKeyConstraint(ctx context.Context) (PrimaryKeyConstraint, bool) { + var e PrimaryKeyConstraint + if o.PrimaryKeyConstraint.IsNull() || o.PrimaryKeyConstraint.IsUnknown() { + return e, false + } + var v []PrimaryKeyConstraint + d := o.PrimaryKeyConstraint.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPrimaryKeyConstraint sets the value of the PrimaryKeyConstraint field in TableConstraint. +func (o *TableConstraint) SetPrimaryKeyConstraint(ctx context.Context, v PrimaryKeyConstraint) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_key_constraint"] + o.PrimaryKeyConstraint = types.ListValueMust(t, vs) +} + // A table that is dependent on a SQL object. type TableDependency struct { // Full name of the dependent table, in the form of @@ -11830,6 +15311,211 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { } } +// GetColumns returns the value of the Columns field in TableInfo as +// a slice of ColumnInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetColumns(ctx context.Context) ([]ColumnInfo, bool) { + if o.Columns.IsNull() || o.Columns.IsUnknown() { + return nil, false + } + var v []ColumnInfo + d := o.Columns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetColumns sets the value of the Columns field in TableInfo. +func (o *TableInfo) SetColumns(ctx context.Context, v []ColumnInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + o.Columns = types.ListValueMust(t, vs) +} + +// GetDeltaRuntimePropertiesKvpairs returns the value of the DeltaRuntimePropertiesKvpairs field in TableInfo as +// a DeltaRuntimePropertiesKvPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetDeltaRuntimePropertiesKvpairs(ctx context.Context) (DeltaRuntimePropertiesKvPairs, bool) { + var e DeltaRuntimePropertiesKvPairs + if o.DeltaRuntimePropertiesKvpairs.IsNull() || o.DeltaRuntimePropertiesKvpairs.IsUnknown() { + return e, false + } + var v []DeltaRuntimePropertiesKvPairs + d := o.DeltaRuntimePropertiesKvpairs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeltaRuntimePropertiesKvpairs sets the value of the DeltaRuntimePropertiesKvpairs field in TableInfo. +func (o *TableInfo) SetDeltaRuntimePropertiesKvpairs(ctx context.Context, v DeltaRuntimePropertiesKvPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delta_runtime_properties_kvpairs"] + o.DeltaRuntimePropertiesKvpairs = types.ListValueMust(t, vs) +} + +// GetEffectivePredictiveOptimizationFlag returns the value of the EffectivePredictiveOptimizationFlag field in TableInfo as +// a EffectivePredictiveOptimizationFlag value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetEffectivePredictiveOptimizationFlag(ctx context.Context) (EffectivePredictiveOptimizationFlag, bool) { + var e EffectivePredictiveOptimizationFlag + if o.EffectivePredictiveOptimizationFlag.IsNull() || o.EffectivePredictiveOptimizationFlag.IsUnknown() { + return e, false + } + var v []EffectivePredictiveOptimizationFlag + d := o.EffectivePredictiveOptimizationFlag.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEffectivePredictiveOptimizationFlag sets the value of the EffectivePredictiveOptimizationFlag field in TableInfo. +func (o *TableInfo) SetEffectivePredictiveOptimizationFlag(ctx context.Context, v EffectivePredictiveOptimizationFlag) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["effective_predictive_optimization_flag"] + o.EffectivePredictiveOptimizationFlag = types.ListValueMust(t, vs) +} + +// GetEncryptionDetails returns the value of the EncryptionDetails field in TableInfo as +// a EncryptionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetEncryptionDetails(ctx context.Context) (EncryptionDetails, bool) { + var e EncryptionDetails + if o.EncryptionDetails.IsNull() || o.EncryptionDetails.IsUnknown() { + return e, false + } + var v []EncryptionDetails + d := o.EncryptionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEncryptionDetails sets the value of the EncryptionDetails field in TableInfo. +func (o *TableInfo) SetEncryptionDetails(ctx context.Context, v EncryptionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["encryption_details"] + o.EncryptionDetails = types.ListValueMust(t, vs) +} + +// GetProperties returns the value of the Properties field in TableInfo as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in TableInfo. +func (o *TableInfo) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + +// GetRowFilter returns the value of the RowFilter field in TableInfo as +// a TableRowFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetRowFilter(ctx context.Context) (TableRowFilter, bool) { + var e TableRowFilter + if o.RowFilter.IsNull() || o.RowFilter.IsUnknown() { + return e, false + } + var v []TableRowFilter + d := o.RowFilter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRowFilter sets the value of the RowFilter field in TableInfo. +func (o *TableInfo) SetRowFilter(ctx context.Context, v TableRowFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["row_filter"] + o.RowFilter = types.ListValueMust(t, vs) +} + +// GetTableConstraints returns the value of the TableConstraints field in TableInfo as +// a slice of TableConstraint values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetTableConstraints(ctx context.Context) ([]TableConstraint, bool) { + if o.TableConstraints.IsNull() || o.TableConstraints.IsUnknown() { + return nil, false + } + var v []TableConstraint + d := o.TableConstraints.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTableConstraints sets the value of the TableConstraints field in TableInfo. +func (o *TableInfo) SetTableConstraints(ctx context.Context, v []TableConstraint) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_constraints"] + o.TableConstraints = types.ListValueMust(t, vs) +} + +// GetViewDependencies returns the value of the ViewDependencies field in TableInfo as +// a DependencyList value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableInfo) GetViewDependencies(ctx context.Context) (DependencyList, bool) { + var e DependencyList + if o.ViewDependencies.IsNull() || o.ViewDependencies.IsUnknown() { + return e, false + } + var v []DependencyList + d := o.ViewDependencies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetViewDependencies sets the value of the ViewDependencies field in TableInfo. +func (o *TableInfo) SetViewDependencies(ctx context.Context, v DependencyList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["view_dependencies"] + o.ViewDependencies = types.ListValueMust(t, vs) +} + type TableRowFilter struct { // The full name of the row filter SQL UDF. FunctionName types.String `tfsdk:"function_name" tf:""` @@ -11882,6 +15568,31 @@ func (o TableRowFilter) Type(ctx context.Context) attr.Type { } } +// GetInputColumnNames returns the value of the InputColumnNames field in TableRowFilter as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableRowFilter) GetInputColumnNames(ctx context.Context) ([]types.String, bool) { + if o.InputColumnNames.IsNull() || o.InputColumnNames.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InputColumnNames.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInputColumnNames sets the value of the InputColumnNames field in TableRowFilter. +func (o *TableRowFilter) SetInputColumnNames(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input_column_names"] + o.InputColumnNames = types.ListValueMust(t, vs) +} + type TableSummary struct { // The full name of the table. FullName types.String `tfsdk:"full_name" tf:"optional"` @@ -11989,6 +15700,58 @@ func (o TemporaryCredentials) Type(ctx context.Context) attr.Type { } } +// GetAwsTempCredentials returns the value of the AwsTempCredentials field in TemporaryCredentials as +// a AwsCredentials value. +// If the field is unknown or null, the boolean return value is false. +func (o *TemporaryCredentials) GetAwsTempCredentials(ctx context.Context) (AwsCredentials, bool) { + var e AwsCredentials + if o.AwsTempCredentials.IsNull() || o.AwsTempCredentials.IsUnknown() { + return e, false + } + var v []AwsCredentials + d := o.AwsTempCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsTempCredentials sets the value of the AwsTempCredentials field in TemporaryCredentials. +func (o *TemporaryCredentials) SetAwsTempCredentials(ctx context.Context, v AwsCredentials) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_temp_credentials"] + o.AwsTempCredentials = types.ListValueMust(t, vs) +} + +// GetAzureAad returns the value of the AzureAad field in TemporaryCredentials as +// a AzureActiveDirectoryToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *TemporaryCredentials) GetAzureAad(ctx context.Context) (AzureActiveDirectoryToken, bool) { + var e AzureActiveDirectoryToken + if o.AzureAad.IsNull() || o.AzureAad.IsUnknown() { + return e, false + } + var v []AzureActiveDirectoryToken + d := o.AzureAad.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAad sets the value of the AzureAad field in TemporaryCredentials. +func (o *TemporaryCredentials) SetAzureAad(ctx context.Context, v AzureActiveDirectoryToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_aad"] + o.AzureAad = types.ListValueMust(t, vs) +} + // Detailed status of an online table. Shown if the online table is in the // ONLINE_TRIGGERED_UPDATE or the ONLINE_NO_PENDING_UPDATE state. type TriggeredUpdateStatus struct { @@ -12048,6 +15811,32 @@ func (o TriggeredUpdateStatus) Type(ctx context.Context) attr.Type { } } +// GetTriggeredUpdateProgress returns the value of the TriggeredUpdateProgress field in TriggeredUpdateStatus as +// a PipelineProgress value. +// If the field is unknown or null, the boolean return value is false. +func (o *TriggeredUpdateStatus) GetTriggeredUpdateProgress(ctx context.Context) (PipelineProgress, bool) { + var e PipelineProgress + if o.TriggeredUpdateProgress.IsNull() || o.TriggeredUpdateProgress.IsUnknown() { + return e, false + } + var v []PipelineProgress + d := o.TriggeredUpdateProgress.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTriggeredUpdateProgress sets the value of the TriggeredUpdateProgress field in TriggeredUpdateStatus. +func (o *TriggeredUpdateStatus) SetTriggeredUpdateProgress(ctx context.Context, v PipelineProgress) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["triggered_update_progress"] + o.TriggeredUpdateProgress = types.ListValueMust(t, vs) +} + // Delete an assignment type UnassignRequest struct { // Query for the ID of the metastore to delete. @@ -12239,6 +16028,31 @@ func (o UpdateCatalog) Type(ctx context.Context) attr.Type { } } +// GetProperties returns the value of the Properties field in UpdateCatalog as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCatalog) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in UpdateCatalog. +func (o *UpdateCatalog) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type UpdateConnection struct { // Name of the connection. Name types.String `tfsdk:"-"` @@ -12297,6 +16111,31 @@ func (o UpdateConnection) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in UpdateConnection as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateConnection) GetOptions(ctx context.Context) (map[string]types.String, bool) { + if o.Options.IsNull() || o.Options.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOptions sets the value of the Options field in UpdateConnection. +func (o *UpdateConnection) SetOptions(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.MapValueMust(t, vs) +} + type UpdateCredentialRequest struct { // The AWS IAM role configuration AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` @@ -12394,6 +16233,84 @@ func (o UpdateCredentialRequest) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in UpdateCredentialRequest as +// a AwsIamRole value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCredentialRequest) GetAwsIamRole(ctx context.Context) (AwsIamRole, bool) { + var e AwsIamRole + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRole + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in UpdateCredentialRequest. +func (o *UpdateCredentialRequest) SetAwsIamRole(ctx context.Context, v AwsIamRole) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in UpdateCredentialRequest as +// a AzureManagedIdentity value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCredentialRequest) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentity, bool) { + var e AzureManagedIdentity + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentity + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in UpdateCredentialRequest. +func (o *UpdateCredentialRequest) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentity) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in UpdateCredentialRequest as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCredentialRequest) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in UpdateCredentialRequest. +func (o *UpdateCredentialRequest) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + type UpdateExternalLocation struct { // The AWS access point to use when accesing s3 for this external location. AccessPoint types.String `tfsdk:"access_point" tf:"optional"` @@ -12492,6 +16409,32 @@ func (o UpdateExternalLocation) Type(ctx context.Context) attr.Type { } } +// GetEncryptionDetails returns the value of the EncryptionDetails field in UpdateExternalLocation as +// a EncryptionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateExternalLocation) GetEncryptionDetails(ctx context.Context) (EncryptionDetails, bool) { + var e EncryptionDetails + if o.EncryptionDetails.IsNull() || o.EncryptionDetails.IsUnknown() { + return e, false + } + var v []EncryptionDetails + d := o.EncryptionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEncryptionDetails sets the value of the EncryptionDetails field in UpdateExternalLocation. +func (o *UpdateExternalLocation) SetEncryptionDetails(ctx context.Context, v EncryptionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["encryption_details"] + o.EncryptionDetails = types.ListValueMust(t, vs) +} + type UpdateFunction struct { // The fully-qualified name of the function (of the form // __catalog_name__.__schema_name__.__function__name__). @@ -12833,6 +16776,212 @@ func (o UpdateMonitor) Type(ctx context.Context) attr.Type { } } +// GetCustomMetrics returns the value of the CustomMetrics field in UpdateMonitor as +// a slice of MonitorMetric values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetCustomMetrics(ctx context.Context) ([]MonitorMetric, bool) { + if o.CustomMetrics.IsNull() || o.CustomMetrics.IsUnknown() { + return nil, false + } + var v []MonitorMetric + d := o.CustomMetrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomMetrics sets the value of the CustomMetrics field in UpdateMonitor. +func (o *UpdateMonitor) SetCustomMetrics(ctx context.Context, v []MonitorMetric) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_metrics"] + o.CustomMetrics = types.ListValueMust(t, vs) +} + +// GetDataClassificationConfig returns the value of the DataClassificationConfig field in UpdateMonitor as +// a MonitorDataClassificationConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetDataClassificationConfig(ctx context.Context) (MonitorDataClassificationConfig, bool) { + var e MonitorDataClassificationConfig + if o.DataClassificationConfig.IsNull() || o.DataClassificationConfig.IsUnknown() { + return e, false + } + var v []MonitorDataClassificationConfig + d := o.DataClassificationConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataClassificationConfig sets the value of the DataClassificationConfig field in UpdateMonitor. +func (o *UpdateMonitor) SetDataClassificationConfig(ctx context.Context, v MonitorDataClassificationConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_classification_config"] + o.DataClassificationConfig = types.ListValueMust(t, vs) +} + +// GetInferenceLog returns the value of the InferenceLog field in UpdateMonitor as +// a MonitorInferenceLog value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetInferenceLog(ctx context.Context) (MonitorInferenceLog, bool) { + var e MonitorInferenceLog + if o.InferenceLog.IsNull() || o.InferenceLog.IsUnknown() { + return e, false + } + var v []MonitorInferenceLog + d := o.InferenceLog.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInferenceLog sets the value of the InferenceLog field in UpdateMonitor. +func (o *UpdateMonitor) SetInferenceLog(ctx context.Context, v MonitorInferenceLog) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inference_log"] + o.InferenceLog = types.ListValueMust(t, vs) +} + +// GetNotifications returns the value of the Notifications field in UpdateMonitor as +// a MonitorNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetNotifications(ctx context.Context) (MonitorNotifications, bool) { + var e MonitorNotifications + if o.Notifications.IsNull() || o.Notifications.IsUnknown() { + return e, false + } + var v []MonitorNotifications + d := o.Notifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotifications sets the value of the Notifications field in UpdateMonitor. +func (o *UpdateMonitor) SetNotifications(ctx context.Context, v MonitorNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + o.Notifications = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in UpdateMonitor as +// a MonitorCronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetSchedule(ctx context.Context) (MonitorCronSchedule, bool) { + var e MonitorCronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []MonitorCronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in UpdateMonitor. +func (o *UpdateMonitor) SetSchedule(ctx context.Context, v MonitorCronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetSlicingExprs returns the value of the SlicingExprs field in UpdateMonitor as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetSlicingExprs(ctx context.Context) ([]types.String, bool) { + if o.SlicingExprs.IsNull() || o.SlicingExprs.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SlicingExprs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSlicingExprs sets the value of the SlicingExprs field in UpdateMonitor. +func (o *UpdateMonitor) SetSlicingExprs(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slicing_exprs"] + o.SlicingExprs = types.ListValueMust(t, vs) +} + +// GetSnapshot returns the value of the Snapshot field in UpdateMonitor as +// a MonitorSnapshot value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetSnapshot(ctx context.Context) (MonitorSnapshot, bool) { + var e MonitorSnapshot + if o.Snapshot.IsNull() || o.Snapshot.IsUnknown() { + return e, false + } + var v []MonitorSnapshot + d := o.Snapshot.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSnapshot sets the value of the Snapshot field in UpdateMonitor. +func (o *UpdateMonitor) SetSnapshot(ctx context.Context, v MonitorSnapshot) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["snapshot"] + o.Snapshot = types.ListValueMust(t, vs) +} + +// GetTimeSeries returns the value of the TimeSeries field in UpdateMonitor as +// a MonitorTimeSeries value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateMonitor) GetTimeSeries(ctx context.Context) (MonitorTimeSeries, bool) { + var e MonitorTimeSeries + if o.TimeSeries.IsNull() || o.TimeSeries.IsUnknown() { + return e, false + } + var v []MonitorTimeSeries + d := o.TimeSeries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTimeSeries sets the value of the TimeSeries field in UpdateMonitor. +func (o *UpdateMonitor) SetTimeSeries(ctx context.Context, v MonitorTimeSeries) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["time_series"] + o.TimeSeries = types.ListValueMust(t, vs) +} + type UpdatePermissions struct { // Array of permissions change objects. Changes types.List `tfsdk:"changes" tf:"optional"` @@ -12887,6 +17036,31 @@ func (o UpdatePermissions) Type(ctx context.Context) attr.Type { } } +// GetChanges returns the value of the Changes field in UpdatePermissions as +// a slice of PermissionsChange values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdatePermissions) GetChanges(ctx context.Context) ([]PermissionsChange, bool) { + if o.Changes.IsNull() || o.Changes.IsUnknown() { + return nil, false + } + var v []PermissionsChange + d := o.Changes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetChanges sets the value of the Changes field in UpdatePermissions. +func (o *UpdatePermissions) SetChanges(ctx context.Context, v []PermissionsChange) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["changes"] + o.Changes = types.ListValueMust(t, vs) +} + type UpdateRegisteredModelRequest struct { // The comment attached to the registered model Comment types.String `tfsdk:"comment" tf:"optional"` @@ -13044,6 +17218,31 @@ func (o UpdateSchema) Type(ctx context.Context) attr.Type { } } +// GetProperties returns the value of the Properties field in UpdateSchema as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateSchema) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in UpdateSchema. +func (o *UpdateSchema) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type UpdateStorageCredential struct { // The AWS IAM role configuration. AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` @@ -13152,6 +17351,136 @@ func (o UpdateStorageCredential) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in UpdateStorageCredential as +// a AwsIamRoleRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateStorageCredential) GetAwsIamRole(ctx context.Context) (AwsIamRoleRequest, bool) { + var e AwsIamRoleRequest + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRoleRequest + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in UpdateStorageCredential. +func (o *UpdateStorageCredential) SetAwsIamRole(ctx context.Context, v AwsIamRoleRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in UpdateStorageCredential as +// a AzureManagedIdentityResponse value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateStorageCredential) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentityResponse, bool) { + var e AzureManagedIdentityResponse + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentityResponse + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in UpdateStorageCredential. +func (o *UpdateStorageCredential) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentityResponse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in UpdateStorageCredential as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateStorageCredential) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in UpdateStorageCredential. +func (o *UpdateStorageCredential) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + +// GetCloudflareApiToken returns the value of the CloudflareApiToken field in UpdateStorageCredential as +// a CloudflareApiToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateStorageCredential) GetCloudflareApiToken(ctx context.Context) (CloudflareApiToken, bool) { + var e CloudflareApiToken + if o.CloudflareApiToken.IsNull() || o.CloudflareApiToken.IsUnknown() { + return e, false + } + var v []CloudflareApiToken + d := o.CloudflareApiToken.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCloudflareApiToken sets the value of the CloudflareApiToken field in UpdateStorageCredential. +func (o *UpdateStorageCredential) SetCloudflareApiToken(ctx context.Context, v CloudflareApiToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cloudflare_api_token"] + o.CloudflareApiToken = types.ListValueMust(t, vs) +} + +// GetDatabricksGcpServiceAccount returns the value of the DatabricksGcpServiceAccount field in UpdateStorageCredential as +// a DatabricksGcpServiceAccountRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateStorageCredential) GetDatabricksGcpServiceAccount(ctx context.Context) (DatabricksGcpServiceAccountRequest, bool) { + var e DatabricksGcpServiceAccountRequest + if o.DatabricksGcpServiceAccount.IsNull() || o.DatabricksGcpServiceAccount.IsUnknown() { + return e, false + } + var v []DatabricksGcpServiceAccountRequest + d := o.DatabricksGcpServiceAccount.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDatabricksGcpServiceAccount sets the value of the DatabricksGcpServiceAccount field in UpdateStorageCredential. +func (o *UpdateStorageCredential) SetDatabricksGcpServiceAccount(ctx context.Context, v DatabricksGcpServiceAccountRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["databricks_gcp_service_account"] + o.DatabricksGcpServiceAccount = types.ListValueMust(t, vs) +} + // Update a table owner. type UpdateTableRequest struct { // Full name of the table. @@ -13310,6 +17639,56 @@ func (o UpdateWorkspaceBindings) Type(ctx context.Context) attr.Type { } } +// GetAssignWorkspaces returns the value of the AssignWorkspaces field in UpdateWorkspaceBindings as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateWorkspaceBindings) GetAssignWorkspaces(ctx context.Context) ([]types.Int64, bool) { + if o.AssignWorkspaces.IsNull() || o.AssignWorkspaces.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.AssignWorkspaces.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAssignWorkspaces sets the value of the AssignWorkspaces field in UpdateWorkspaceBindings. +func (o *UpdateWorkspaceBindings) SetAssignWorkspaces(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assign_workspaces"] + o.AssignWorkspaces = types.ListValueMust(t, vs) +} + +// GetUnassignWorkspaces returns the value of the UnassignWorkspaces field in UpdateWorkspaceBindings as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateWorkspaceBindings) GetUnassignWorkspaces(ctx context.Context) ([]types.Int64, bool) { + if o.UnassignWorkspaces.IsNull() || o.UnassignWorkspaces.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.UnassignWorkspaces.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUnassignWorkspaces sets the value of the UnassignWorkspaces field in UpdateWorkspaceBindings. +func (o *UpdateWorkspaceBindings) SetUnassignWorkspaces(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["unassign_workspaces"] + o.UnassignWorkspaces = types.ListValueMust(t, vs) +} + type UpdateWorkspaceBindingsParameters struct { // List of workspace bindings Add types.List `tfsdk:"add" tf:"optional"` @@ -13371,6 +17750,56 @@ func (o UpdateWorkspaceBindingsParameters) Type(ctx context.Context) attr.Type { } } +// GetAdd returns the value of the Add field in UpdateWorkspaceBindingsParameters as +// a slice of WorkspaceBinding values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateWorkspaceBindingsParameters) GetAdd(ctx context.Context) ([]WorkspaceBinding, bool) { + if o.Add.IsNull() || o.Add.IsUnknown() { + return nil, false + } + var v []WorkspaceBinding + d := o.Add.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAdd sets the value of the Add field in UpdateWorkspaceBindingsParameters. +func (o *UpdateWorkspaceBindingsParameters) SetAdd(ctx context.Context, v []WorkspaceBinding) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["add"] + o.Add = types.ListValueMust(t, vs) +} + +// GetRemove returns the value of the Remove field in UpdateWorkspaceBindingsParameters as +// a slice of WorkspaceBinding values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateWorkspaceBindingsParameters) GetRemove(ctx context.Context) ([]WorkspaceBinding, bool) { + if o.Remove.IsNull() || o.Remove.IsUnknown() { + return nil, false + } + var v []WorkspaceBinding + d := o.Remove.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRemove sets the value of the Remove field in UpdateWorkspaceBindingsParameters. +func (o *UpdateWorkspaceBindingsParameters) SetRemove(ctx context.Context, v []WorkspaceBinding) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["remove"] + o.Remove = types.ListValueMust(t, vs) +} + type ValidateCredentialRequest struct { // The AWS IAM role configuration AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` @@ -13449,6 +17878,58 @@ func (o ValidateCredentialRequest) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in ValidateCredentialRequest as +// a AwsIamRole value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateCredentialRequest) GetAwsIamRole(ctx context.Context) (AwsIamRole, bool) { + var e AwsIamRole + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRole + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in ValidateCredentialRequest. +func (o *ValidateCredentialRequest) SetAwsIamRole(ctx context.Context, v AwsIamRole) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in ValidateCredentialRequest as +// a AzureManagedIdentity value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateCredentialRequest) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentity, bool) { + var e AzureManagedIdentity + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentity + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in ValidateCredentialRequest. +func (o *ValidateCredentialRequest) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentity) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + type ValidateCredentialResponse struct { // Whether the tested location is a directory in cloud storage. Only // applicable for when purpose is **STORAGE**. @@ -13500,6 +17981,31 @@ func (o ValidateCredentialResponse) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in ValidateCredentialResponse as +// a slice of CredentialValidationResult values. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateCredentialResponse) GetResults(ctx context.Context) ([]CredentialValidationResult, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []CredentialValidationResult + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ValidateCredentialResponse. +func (o *ValidateCredentialResponse) SetResults(ctx context.Context, v []CredentialValidationResult) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + type ValidateStorageCredential struct { // The AWS IAM role configuration. AwsIamRole types.List `tfsdk:"aws_iam_role" tf:"optional,object"` @@ -13590,6 +18096,136 @@ func (o ValidateStorageCredential) Type(ctx context.Context) attr.Type { } } +// GetAwsIamRole returns the value of the AwsIamRole field in ValidateStorageCredential as +// a AwsIamRoleRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateStorageCredential) GetAwsIamRole(ctx context.Context) (AwsIamRoleRequest, bool) { + var e AwsIamRoleRequest + if o.AwsIamRole.IsNull() || o.AwsIamRole.IsUnknown() { + return e, false + } + var v []AwsIamRoleRequest + d := o.AwsIamRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsIamRole sets the value of the AwsIamRole field in ValidateStorageCredential. +func (o *ValidateStorageCredential) SetAwsIamRole(ctx context.Context, v AwsIamRoleRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_iam_role"] + o.AwsIamRole = types.ListValueMust(t, vs) +} + +// GetAzureManagedIdentity returns the value of the AzureManagedIdentity field in ValidateStorageCredential as +// a AzureManagedIdentityRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateStorageCredential) GetAzureManagedIdentity(ctx context.Context) (AzureManagedIdentityRequest, bool) { + var e AzureManagedIdentityRequest + if o.AzureManagedIdentity.IsNull() || o.AzureManagedIdentity.IsUnknown() { + return e, false + } + var v []AzureManagedIdentityRequest + d := o.AzureManagedIdentity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureManagedIdentity sets the value of the AzureManagedIdentity field in ValidateStorageCredential. +func (o *ValidateStorageCredential) SetAzureManagedIdentity(ctx context.Context, v AzureManagedIdentityRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_managed_identity"] + o.AzureManagedIdentity = types.ListValueMust(t, vs) +} + +// GetAzureServicePrincipal returns the value of the AzureServicePrincipal field in ValidateStorageCredential as +// a AzureServicePrincipal value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateStorageCredential) GetAzureServicePrincipal(ctx context.Context) (AzureServicePrincipal, bool) { + var e AzureServicePrincipal + if o.AzureServicePrincipal.IsNull() || o.AzureServicePrincipal.IsUnknown() { + return e, false + } + var v []AzureServicePrincipal + d := o.AzureServicePrincipal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServicePrincipal sets the value of the AzureServicePrincipal field in ValidateStorageCredential. +func (o *ValidateStorageCredential) SetAzureServicePrincipal(ctx context.Context, v AzureServicePrincipal) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_principal"] + o.AzureServicePrincipal = types.ListValueMust(t, vs) +} + +// GetCloudflareApiToken returns the value of the CloudflareApiToken field in ValidateStorageCredential as +// a CloudflareApiToken value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateStorageCredential) GetCloudflareApiToken(ctx context.Context) (CloudflareApiToken, bool) { + var e CloudflareApiToken + if o.CloudflareApiToken.IsNull() || o.CloudflareApiToken.IsUnknown() { + return e, false + } + var v []CloudflareApiToken + d := o.CloudflareApiToken.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCloudflareApiToken sets the value of the CloudflareApiToken field in ValidateStorageCredential. +func (o *ValidateStorageCredential) SetCloudflareApiToken(ctx context.Context, v CloudflareApiToken) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cloudflare_api_token"] + o.CloudflareApiToken = types.ListValueMust(t, vs) +} + +// GetDatabricksGcpServiceAccount returns the value of the DatabricksGcpServiceAccount field in ValidateStorageCredential as +// a DatabricksGcpServiceAccountRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateStorageCredential) GetDatabricksGcpServiceAccount(ctx context.Context) (DatabricksGcpServiceAccountRequest, bool) { + var e DatabricksGcpServiceAccountRequest + if o.DatabricksGcpServiceAccount.IsNull() || o.DatabricksGcpServiceAccount.IsUnknown() { + return e, false + } + var v []DatabricksGcpServiceAccountRequest + d := o.DatabricksGcpServiceAccount.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDatabricksGcpServiceAccount sets the value of the DatabricksGcpServiceAccount field in ValidateStorageCredential. +func (o *ValidateStorageCredential) SetDatabricksGcpServiceAccount(ctx context.Context, v DatabricksGcpServiceAccountRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["databricks_gcp_service_account"] + o.DatabricksGcpServiceAccount = types.ListValueMust(t, vs) +} + type ValidateStorageCredentialResponse struct { // Whether the tested location is a directory in cloud storage. IsDir types.Bool `tfsdk:"isDir" tf:"optional"` @@ -13640,6 +18276,31 @@ func (o ValidateStorageCredentialResponse) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in ValidateStorageCredentialResponse as +// a slice of ValidationResult values. +// If the field is unknown or null, the boolean return value is false. +func (o *ValidateStorageCredentialResponse) GetResults(ctx context.Context) ([]ValidationResult, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []ValidationResult + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ValidateStorageCredentialResponse. +func (o *ValidateStorageCredentialResponse) SetResults(ctx context.Context, v []ValidationResult) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + type ValidationResult struct { // Error message would exist when the result does not equal to **PASS**. Message types.String `tfsdk:"message" tf:"optional"` @@ -13802,6 +18463,32 @@ func (o VolumeInfo) Type(ctx context.Context) attr.Type { } } +// GetEncryptionDetails returns the value of the EncryptionDetails field in VolumeInfo as +// a EncryptionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *VolumeInfo) GetEncryptionDetails(ctx context.Context) (EncryptionDetails, bool) { + var e EncryptionDetails + if o.EncryptionDetails.IsNull() || o.EncryptionDetails.IsUnknown() { + return e, false + } + var v []EncryptionDetails + d := o.EncryptionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEncryptionDetails sets the value of the EncryptionDetails field in VolumeInfo. +func (o *VolumeInfo) SetEncryptionDetails(ctx context.Context, v EncryptionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["encryption_details"] + o.EncryptionDetails = types.ListValueMust(t, vs) +} + type WorkspaceBinding struct { BindingType types.String `tfsdk:"binding_type" tf:"optional"` @@ -13900,103 +18587,27 @@ func (o WorkspaceBindingsResponse) Type(ctx context.Context) attr.Type { } } -// The artifact type - -// Kind of catalog securable. - -// Whether the current securable is accessible from all workspaces or a specific -// set of workspaces. - -// The type of the catalog. - -// Name of type (INT, STRUCT, MAP, etc.). - -// Kind of connection securable. - -// The type of connection. - -// Function parameter style. **S** is the value for SQL. - -// Function language. When **EXTERNAL** is used, the language of the routine -// function should be specified in the __external_language__ field, and the -// __return_params__ of the function cannot be used (as **TABLE** return type is -// not supported), and the __sql_data_access__ field must be **NO_SQL**. - -// The security type of the function. - -// Function SQL data access. - -// The type of credential. - -// Data source format - -// The type of the object from which the flag was inherited. If there was no -// inheritance, this field is left blank. - -// Whether predictive optimization should be enabled for this object and objects -// under it. - -// Function parameter style. **S** is the value for SQL. - -// Function language. When **EXTERNAL** is used, the language of the routine -// function should be specified in the __external_language__ field, and the -// __return_params__ of the function cannot be used (as **TABLE** return type is -// not supported), and the __sql_data_access__ field must be **NO_SQL**. - -// The security type of the function. - -// Function SQL data access. - -// The mode of the function parameter. - -// The type of function parameter. - -// The scope of Delta Sharing enabled for the metastore. - -// The artifact pattern matching type - -// The scope of Delta Sharing enabled for the metastore. - -// Current status of the model version. Newly created model versions start in -// PENDING_REGISTRATION status, then move to READY status once the model version -// files are uploaded and the model version is finalized. Only model versions in -// READY status can be loaded for inference or served. - -// Read only field that indicates whether a schedule is paused or not. - -// Problem type the model aims to solve. Determines the type of model-quality -// metrics that will be computed. - -// The status of the monitor. - -// Can only be one of ``"CUSTOM_METRIC_TYPE_AGGREGATE"``, -// ``"CUSTOM_METRIC_TYPE_DERIVED"``, or ``"CUSTOM_METRIC_TYPE_DRIFT"``. The -// ``"CUSTOM_METRIC_TYPE_AGGREGATE"`` and ``"CUSTOM_METRIC_TYPE_DERIVED"`` -// metrics are computed on a single table, whereas the -// ``"CUSTOM_METRIC_TYPE_DRIFT"`` compare metrics across baseline and input -// table, or across the two consecutive time windows. - -// CUSTOM_METRIC_TYPE_AGGREGATE: only depend on the existing columns in your -// table - CUSTOM_METRIC_TYPE_DERIVED: depend on previously computed aggregate -// metrics - CUSTOM_METRIC_TYPE_DRIFT: depend on previously computed aggregate -// or derived metrics - -// The current state of the refresh. - -// The method by which the refresh was triggered. - -// The state of an online table. - -// The type of Unity Catalog securable - -// The type of key encryption to use (affects headers from s3 client). - -// The current state of enablement for the system schema. An empty string means -// the system schema is available and ready for opt-in. - -// The scope of Delta Sharing enabled for the metastore. - -// A enum represents the result of the file operation - -// The operation tested. +// GetBindings returns the value of the Bindings field in WorkspaceBindingsResponse as +// a slice of WorkspaceBinding values. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkspaceBindingsResponse) GetBindings(ctx context.Context) ([]WorkspaceBinding, bool) { + if o.Bindings.IsNull() || o.Bindings.IsUnknown() { + return nil, false + } + var v []WorkspaceBinding + d := o.Bindings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// The results of the tested operation. +// SetBindings sets the value of the Bindings field in WorkspaceBindingsResponse. +func (o *WorkspaceBindingsResponse) SetBindings(ctx context.Context, v []WorkspaceBinding) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["bindings"] + o.Bindings = types.ListValueMust(t, vs) +} diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 08e275f9ea..6f5c23288e 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -434,6 +435,32 @@ func (o AzureAttributes) Type(ctx context.Context) attr.Type { } } +// GetLogAnalyticsInfo returns the value of the LogAnalyticsInfo field in AzureAttributes as +// a LogAnalyticsInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *AzureAttributes) GetLogAnalyticsInfo(ctx context.Context) (LogAnalyticsInfo, bool) { + var e LogAnalyticsInfo + if o.LogAnalyticsInfo.IsNull() || o.LogAnalyticsInfo.IsUnknown() { + return e, false + } + var v []LogAnalyticsInfo + d := o.LogAnalyticsInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetLogAnalyticsInfo sets the value of the LogAnalyticsInfo field in AzureAttributes. +func (o *AzureAttributes) SetLogAnalyticsInfo(ctx context.Context, v LogAnalyticsInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["log_analytics_info"] + o.LogAnalyticsInfo = types.ListValueMust(t, vs) +} + type CancelCommand struct { ClusterId types.String `tfsdk:"clusterId" tf:"optional"` @@ -734,6 +761,31 @@ func (o CloudProviderNodeInfo) Type(ctx context.Context) attr.Type { } } +// GetStatus returns the value of the Status field in CloudProviderNodeInfo as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CloudProviderNodeInfo) GetStatus(ctx context.Context) ([]types.String, bool) { + if o.Status.IsNull() || o.Status.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStatus sets the value of the Status field in CloudProviderNodeInfo. +func (o *CloudProviderNodeInfo) SetStatus(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + type ClusterAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -850,6 +902,31 @@ func (o ClusterAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in ClusterAccessControlResponse as +// a slice of ClusterPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAccessControlResponse) GetAllPermissions(ctx context.Context) ([]ClusterPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []ClusterPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in ClusterAccessControlResponse. +func (o *ClusterAccessControlResponse) SetAllPermissions(ctx context.Context, v []ClusterPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type ClusterAttributes struct { // Automatically terminates the cluster after it is inactive for this time // in minutes. If not set, this cluster will not be automatically @@ -1100,6 +1177,287 @@ func (o ClusterAttributes) Type(ctx context.Context) attr.Type { } } +// GetAwsAttributes returns the value of the AwsAttributes field in ClusterAttributes as +// a AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetAwsAttributes(ctx context.Context) (AwsAttributes, bool) { + var e AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in ClusterAttributes. +func (o *ClusterAttributes) SetAwsAttributes(ctx context.Context, v AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in ClusterAttributes as +// a AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetAzureAttributes(ctx context.Context) (AzureAttributes, bool) { + var e AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in ClusterAttributes. +func (o *ClusterAttributes) SetAzureAttributes(ctx context.Context, v AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in ClusterAttributes as +// a ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetClusterLogConf(ctx context.Context) (ClusterLogConf, bool) { + var e ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in ClusterAttributes. +func (o *ClusterAttributes) SetClusterLogConf(ctx context.Context, v ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in ClusterAttributes as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in ClusterAttributes. +func (o *ClusterAttributes) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDockerImage returns the value of the DockerImage field in ClusterAttributes as +// a DockerImage value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetDockerImage(ctx context.Context) (DockerImage, bool) { + var e DockerImage + if o.DockerImage.IsNull() || o.DockerImage.IsUnknown() { + return e, false + } + var v []DockerImage + d := o.DockerImage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDockerImage sets the value of the DockerImage field in ClusterAttributes. +func (o *ClusterAttributes) SetDockerImage(ctx context.Context, v DockerImage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["docker_image"] + o.DockerImage = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in ClusterAttributes as +// a GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetGcpAttributes(ctx context.Context) (GcpAttributes, bool) { + var e GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in ClusterAttributes. +func (o *ClusterAttributes) SetGcpAttributes(ctx context.Context, v GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in ClusterAttributes as +// a slice of InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetInitScripts(ctx context.Context) ([]InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in ClusterAttributes. +func (o *ClusterAttributes) SetInitScripts(ctx context.Context, v []InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in ClusterAttributes as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in ClusterAttributes. +func (o *ClusterAttributes) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in ClusterAttributes as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in ClusterAttributes. +func (o *ClusterAttributes) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in ClusterAttributes as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in ClusterAttributes. +func (o *ClusterAttributes) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + +// GetWorkloadType returns the value of the WorkloadType field in ClusterAttributes as +// a WorkloadType value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAttributes) GetWorkloadType(ctx context.Context) (WorkloadType, bool) { + var e WorkloadType + if o.WorkloadType.IsNull() || o.WorkloadType.IsUnknown() { + return e, false + } + var v []WorkloadType + d := o.WorkloadType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkloadType sets the value of the WorkloadType field in ClusterAttributes. +func (o *ClusterAttributes) SetWorkloadType(ctx context.Context, v WorkloadType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workload_type"] + o.WorkloadType = types.ListValueMust(t, vs) +} + type ClusterCompliance struct { // Canonical unique identifier for a cluster. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -1158,6 +1516,31 @@ func (o ClusterCompliance) Type(ctx context.Context) attr.Type { } } +// GetViolations returns the value of the Violations field in ClusterCompliance as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterCompliance) GetViolations(ctx context.Context) (map[string]types.String, bool) { + if o.Violations.IsNull() || o.Violations.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Violations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetViolations sets the value of the Violations field in ClusterCompliance. +func (o *ClusterCompliance) SetViolations(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + o.Violations = types.MapValueMust(t, vs) +} + type ClusterDetails struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 @@ -1554,6 +1937,467 @@ func (o ClusterDetails) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in ClusterDetails as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in ClusterDetails. +func (o *ClusterDetails) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + +// GetAwsAttributes returns the value of the AwsAttributes field in ClusterDetails as +// a AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetAwsAttributes(ctx context.Context) (AwsAttributes, bool) { + var e AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in ClusterDetails. +func (o *ClusterDetails) SetAwsAttributes(ctx context.Context, v AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in ClusterDetails as +// a AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetAzureAttributes(ctx context.Context) (AzureAttributes, bool) { + var e AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in ClusterDetails. +func (o *ClusterDetails) SetAzureAttributes(ctx context.Context, v AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in ClusterDetails as +// a ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetClusterLogConf(ctx context.Context) (ClusterLogConf, bool) { + var e ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in ClusterDetails. +func (o *ClusterDetails) SetClusterLogConf(ctx context.Context, v ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetClusterLogStatus returns the value of the ClusterLogStatus field in ClusterDetails as +// a LogSyncStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetClusterLogStatus(ctx context.Context) (LogSyncStatus, bool) { + var e LogSyncStatus + if o.ClusterLogStatus.IsNull() || o.ClusterLogStatus.IsUnknown() { + return e, false + } + var v []LogSyncStatus + d := o.ClusterLogStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogStatus sets the value of the ClusterLogStatus field in ClusterDetails. +func (o *ClusterDetails) SetClusterLogStatus(ctx context.Context, v LogSyncStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_status"] + o.ClusterLogStatus = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in ClusterDetails as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in ClusterDetails. +func (o *ClusterDetails) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDefaultTags returns the value of the DefaultTags field in ClusterDetails as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetDefaultTags(ctx context.Context) (map[string]types.String, bool) { + if o.DefaultTags.IsNull() || o.DefaultTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.DefaultTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDefaultTags sets the value of the DefaultTags field in ClusterDetails. +func (o *ClusterDetails) SetDefaultTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_tags"] + o.DefaultTags = types.MapValueMust(t, vs) +} + +// GetDockerImage returns the value of the DockerImage field in ClusterDetails as +// a DockerImage value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetDockerImage(ctx context.Context) (DockerImage, bool) { + var e DockerImage + if o.DockerImage.IsNull() || o.DockerImage.IsUnknown() { + return e, false + } + var v []DockerImage + d := o.DockerImage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDockerImage sets the value of the DockerImage field in ClusterDetails. +func (o *ClusterDetails) SetDockerImage(ctx context.Context, v DockerImage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["docker_image"] + o.DockerImage = types.ListValueMust(t, vs) +} + +// GetDriver returns the value of the Driver field in ClusterDetails as +// a SparkNode value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetDriver(ctx context.Context) (SparkNode, bool) { + var e SparkNode + if o.Driver.IsNull() || o.Driver.IsUnknown() { + return e, false + } + var v []SparkNode + d := o.Driver.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDriver sets the value of the Driver field in ClusterDetails. +func (o *ClusterDetails) SetDriver(ctx context.Context, v SparkNode) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["driver"] + o.Driver = types.ListValueMust(t, vs) +} + +// GetExecutors returns the value of the Executors field in ClusterDetails as +// a slice of SparkNode values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetExecutors(ctx context.Context) ([]SparkNode, bool) { + if o.Executors.IsNull() || o.Executors.IsUnknown() { + return nil, false + } + var v []SparkNode + d := o.Executors.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExecutors sets the value of the Executors field in ClusterDetails. +func (o *ClusterDetails) SetExecutors(ctx context.Context, v []SparkNode) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["executors"] + o.Executors = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in ClusterDetails as +// a GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetGcpAttributes(ctx context.Context) (GcpAttributes, bool) { + var e GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in ClusterDetails. +func (o *ClusterDetails) SetGcpAttributes(ctx context.Context, v GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in ClusterDetails as +// a slice of InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetInitScripts(ctx context.Context) ([]InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in ClusterDetails. +func (o *ClusterDetails) SetInitScripts(ctx context.Context, v []InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in ClusterDetails as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in ClusterDetails. +func (o *ClusterDetails) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in ClusterDetails as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in ClusterDetails. +func (o *ClusterDetails) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSpec returns the value of the Spec field in ClusterDetails as +// a ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetSpec(ctx context.Context) (ClusterSpec, bool) { + var e ClusterSpec + if o.Spec.IsNull() || o.Spec.IsUnknown() { + return e, false + } + var v []ClusterSpec + d := o.Spec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSpec sets the value of the Spec field in ClusterDetails. +func (o *ClusterDetails) SetSpec(ctx context.Context, v ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spec"] + o.Spec = types.ListValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in ClusterDetails as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in ClusterDetails. +func (o *ClusterDetails) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + +// GetTerminationReason returns the value of the TerminationReason field in ClusterDetails as +// a TerminationReason value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetTerminationReason(ctx context.Context) (TerminationReason, bool) { + var e TerminationReason + if o.TerminationReason.IsNull() || o.TerminationReason.IsUnknown() { + return e, false + } + var v []TerminationReason + d := o.TerminationReason.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTerminationReason sets the value of the TerminationReason field in ClusterDetails. +func (o *ClusterDetails) SetTerminationReason(ctx context.Context, v TerminationReason) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["termination_reason"] + o.TerminationReason = types.ListValueMust(t, vs) +} + +// GetWorkloadType returns the value of the WorkloadType field in ClusterDetails as +// a WorkloadType value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterDetails) GetWorkloadType(ctx context.Context) (WorkloadType, bool) { + var e WorkloadType + if o.WorkloadType.IsNull() || o.WorkloadType.IsUnknown() { + return e, false + } + var v []WorkloadType + d := o.WorkloadType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkloadType sets the value of the WorkloadType field in ClusterDetails. +func (o *ClusterDetails) SetWorkloadType(ctx context.Context, v WorkloadType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workload_type"] + o.WorkloadType = types.ListValueMust(t, vs) +} + type ClusterEvent struct { // ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -1621,6 +2465,58 @@ func (o ClusterEvent) Type(ctx context.Context) attr.Type { } } +// GetDataPlaneEventDetails returns the value of the DataPlaneEventDetails field in ClusterEvent as +// a DataPlaneEventDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterEvent) GetDataPlaneEventDetails(ctx context.Context) (DataPlaneEventDetails, bool) { + var e DataPlaneEventDetails + if o.DataPlaneEventDetails.IsNull() || o.DataPlaneEventDetails.IsUnknown() { + return e, false + } + var v []DataPlaneEventDetails + d := o.DataPlaneEventDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataPlaneEventDetails sets the value of the DataPlaneEventDetails field in ClusterEvent. +func (o *ClusterEvent) SetDataPlaneEventDetails(ctx context.Context, v DataPlaneEventDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_plane_event_details"] + o.DataPlaneEventDetails = types.ListValueMust(t, vs) +} + +// GetDetails returns the value of the Details field in ClusterEvent as +// a EventDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterEvent) GetDetails(ctx context.Context) (EventDetails, bool) { + var e EventDetails + if o.Details.IsNull() || o.Details.IsUnknown() { + return e, false + } + var v []EventDetails + d := o.Details.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDetails sets the value of the Details field in ClusterEvent. +func (o *ClusterEvent) SetDetails(ctx context.Context, v EventDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["details"] + o.Details = types.ListValueMust(t, vs) +} + type ClusterLibraryStatuses struct { // Unique identifier for the cluster. ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` @@ -1671,6 +2567,31 @@ func (o ClusterLibraryStatuses) Type(ctx context.Context) attr.Type { } } +// GetLibraryStatuses returns the value of the LibraryStatuses field in ClusterLibraryStatuses as +// a slice of LibraryFullStatus values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterLibraryStatuses) GetLibraryStatuses(ctx context.Context) ([]LibraryFullStatus, bool) { + if o.LibraryStatuses.IsNull() || o.LibraryStatuses.IsUnknown() { + return nil, false + } + var v []LibraryFullStatus + d := o.LibraryStatuses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraryStatuses sets the value of the LibraryStatuses field in ClusterLibraryStatuses. +func (o *ClusterLibraryStatuses) SetLibraryStatuses(ctx context.Context, v []LibraryFullStatus) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library_statuses"] + o.LibraryStatuses = types.ListValueMust(t, vs) +} + type ClusterLogConf struct { // destination needs to be provided. e.g. `{ "dbfs" : { "destination" : // "dbfs:/home/cluster_log" } }` @@ -1729,6 +2650,58 @@ func (o ClusterLogConf) Type(ctx context.Context) attr.Type { } } +// GetDbfs returns the value of the Dbfs field in ClusterLogConf as +// a DbfsStorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterLogConf) GetDbfs(ctx context.Context) (DbfsStorageInfo, bool) { + var e DbfsStorageInfo + if o.Dbfs.IsNull() || o.Dbfs.IsUnknown() { + return e, false + } + var v []DbfsStorageInfo + d := o.Dbfs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbfs sets the value of the Dbfs field in ClusterLogConf. +func (o *ClusterLogConf) SetDbfs(ctx context.Context, v DbfsStorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbfs"] + o.Dbfs = types.ListValueMust(t, vs) +} + +// GetS3 returns the value of the S3 field in ClusterLogConf as +// a S3StorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterLogConf) GetS3(ctx context.Context) (S3StorageInfo, bool) { + var e S3StorageInfo + if o.S3.IsNull() || o.S3.IsUnknown() { + return e, false + } + var v []S3StorageInfo + d := o.S3.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetS3 sets the value of the S3 field in ClusterLogConf. +func (o *ClusterLogConf) SetS3(ctx context.Context, v S3StorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["s3"] + o.S3 = types.ListValueMust(t, vs) +} + type ClusterPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -1782,6 +2755,31 @@ func (o ClusterPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in ClusterPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in ClusterPermission. +func (o *ClusterPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type ClusterPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -1835,6 +2833,31 @@ func (o ClusterPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ClusterPermissions as +// a slice of ClusterAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPermissions) GetAccessControlList(ctx context.Context) ([]ClusterAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ClusterAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ClusterPermissions. +func (o *ClusterPermissions) SetAccessControlList(ctx context.Context, v []ClusterAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type ClusterPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -1929,6 +2952,31 @@ func (o ClusterPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ClusterPermissionsRequest as +// a slice of ClusterAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPermissionsRequest) GetAccessControlList(ctx context.Context) ([]ClusterAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ClusterAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ClusterPermissionsRequest. +func (o *ClusterPermissionsRequest) SetAccessControlList(ctx context.Context, v []ClusterAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type ClusterPolicyAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2045,6 +3093,31 @@ func (o ClusterPolicyAccessControlResponse) Type(ctx context.Context) attr.Type } } +// GetAllPermissions returns the value of the AllPermissions field in ClusterPolicyAccessControlResponse as +// a slice of ClusterPolicyPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPolicyAccessControlResponse) GetAllPermissions(ctx context.Context) ([]ClusterPolicyPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []ClusterPolicyPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in ClusterPolicyAccessControlResponse. +func (o *ClusterPolicyAccessControlResponse) SetAllPermissions(ctx context.Context, v []ClusterPolicyPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type ClusterPolicyPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2098,6 +3171,31 @@ func (o ClusterPolicyPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in ClusterPolicyPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPolicyPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in ClusterPolicyPermission. +func (o *ClusterPolicyPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type ClusterPolicyPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -2151,6 +3249,31 @@ func (o ClusterPolicyPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ClusterPolicyPermissions as +// a slice of ClusterPolicyAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPolicyPermissions) GetAccessControlList(ctx context.Context) ([]ClusterPolicyAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ClusterPolicyAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ClusterPolicyPermissions. +func (o *ClusterPolicyPermissions) SetAccessControlList(ctx context.Context, v []ClusterPolicyAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type ClusterPolicyPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2245,6 +3368,31 @@ func (o ClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ClusterPolicyPermissionsRequest as +// a slice of ClusterPolicyAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterPolicyPermissionsRequest) GetAccessControlList(ctx context.Context) ([]ClusterPolicyAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ClusterPolicyAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ClusterPolicyPermissionsRequest. +func (o *ClusterPolicyPermissionsRequest) SetAccessControlList(ctx context.Context, v []ClusterPolicyAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + // Represents a change to the cluster settings required for the cluster to // become compliant with its policy. type ClusterSettingsChange struct { @@ -2364,6 +3512,32 @@ func (o ClusterSize) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in ClusterSize as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSize) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in ClusterSize. +func (o *ClusterSize) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + type ClusterSpec struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -2642,6 +3816,313 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in ClusterSpec as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in ClusterSpec. +func (o *ClusterSpec) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + +// GetAwsAttributes returns the value of the AwsAttributes field in ClusterSpec as +// a AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetAwsAttributes(ctx context.Context) (AwsAttributes, bool) { + var e AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in ClusterSpec. +func (o *ClusterSpec) SetAwsAttributes(ctx context.Context, v AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in ClusterSpec as +// a AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetAzureAttributes(ctx context.Context) (AzureAttributes, bool) { + var e AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in ClusterSpec. +func (o *ClusterSpec) SetAzureAttributes(ctx context.Context, v AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in ClusterSpec as +// a ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetClusterLogConf(ctx context.Context) (ClusterLogConf, bool) { + var e ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in ClusterSpec. +func (o *ClusterSpec) SetClusterLogConf(ctx context.Context, v ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in ClusterSpec as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in ClusterSpec. +func (o *ClusterSpec) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDockerImage returns the value of the DockerImage field in ClusterSpec as +// a DockerImage value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetDockerImage(ctx context.Context) (DockerImage, bool) { + var e DockerImage + if o.DockerImage.IsNull() || o.DockerImage.IsUnknown() { + return e, false + } + var v []DockerImage + d := o.DockerImage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDockerImage sets the value of the DockerImage field in ClusterSpec. +func (o *ClusterSpec) SetDockerImage(ctx context.Context, v DockerImage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["docker_image"] + o.DockerImage = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in ClusterSpec as +// a GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetGcpAttributes(ctx context.Context) (GcpAttributes, bool) { + var e GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in ClusterSpec. +func (o *ClusterSpec) SetGcpAttributes(ctx context.Context, v GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in ClusterSpec as +// a slice of InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetInitScripts(ctx context.Context) ([]InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in ClusterSpec. +func (o *ClusterSpec) SetInitScripts(ctx context.Context, v []InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in ClusterSpec as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in ClusterSpec. +func (o *ClusterSpec) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in ClusterSpec as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in ClusterSpec. +func (o *ClusterSpec) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in ClusterSpec as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in ClusterSpec. +func (o *ClusterSpec) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + +// GetWorkloadType returns the value of the WorkloadType field in ClusterSpec as +// a WorkloadType value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetWorkloadType(ctx context.Context) (WorkloadType, bool) { + var e WorkloadType + if o.WorkloadType.IsNull() || o.WorkloadType.IsUnknown() { + return e, false + } + var v []WorkloadType + d := o.WorkloadType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkloadType sets the value of the WorkloadType field in ClusterSpec. +func (o *ClusterSpec) SetWorkloadType(ctx context.Context, v WorkloadType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workload_type"] + o.WorkloadType = types.ListValueMust(t, vs) +} + // Get status type ClusterStatus struct { // Unique identifier of the cluster whose status should be retrieved. @@ -2842,6 +4323,32 @@ func (o CommandStatusResponse) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in CommandStatusResponse as +// a Results value. +// If the field is unknown or null, the boolean return value is false. +func (o *CommandStatusResponse) GetResults(ctx context.Context) (Results, bool) { + var e Results + if o.Results.IsNull() || o.Results.IsUnknown() { + return e, false + } + var v []Results + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetResults sets the value of the Results field in CommandStatusResponse. +func (o *CommandStatusResponse) SetResults(ctx context.Context, v Results) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + // Get status type ContextStatusRequest struct { ClusterId types.String `tfsdk:"-"` @@ -3219,6 +4726,339 @@ func (o CreateCluster) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in CreateCluster as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in CreateCluster. +func (o *CreateCluster) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + +// GetAwsAttributes returns the value of the AwsAttributes field in CreateCluster as +// a AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetAwsAttributes(ctx context.Context) (AwsAttributes, bool) { + var e AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in CreateCluster. +func (o *CreateCluster) SetAwsAttributes(ctx context.Context, v AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in CreateCluster as +// a AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetAzureAttributes(ctx context.Context) (AzureAttributes, bool) { + var e AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in CreateCluster. +func (o *CreateCluster) SetAzureAttributes(ctx context.Context, v AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetCloneFrom returns the value of the CloneFrom field in CreateCluster as +// a CloneCluster value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetCloneFrom(ctx context.Context) (CloneCluster, bool) { + var e CloneCluster + if o.CloneFrom.IsNull() || o.CloneFrom.IsUnknown() { + return e, false + } + var v []CloneCluster + d := o.CloneFrom.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCloneFrom sets the value of the CloneFrom field in CreateCluster. +func (o *CreateCluster) SetCloneFrom(ctx context.Context, v CloneCluster) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clone_from"] + o.CloneFrom = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in CreateCluster as +// a ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetClusterLogConf(ctx context.Context) (ClusterLogConf, bool) { + var e ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in CreateCluster. +func (o *CreateCluster) SetClusterLogConf(ctx context.Context, v ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in CreateCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in CreateCluster. +func (o *CreateCluster) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDockerImage returns the value of the DockerImage field in CreateCluster as +// a DockerImage value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetDockerImage(ctx context.Context) (DockerImage, bool) { + var e DockerImage + if o.DockerImage.IsNull() || o.DockerImage.IsUnknown() { + return e, false + } + var v []DockerImage + d := o.DockerImage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDockerImage sets the value of the DockerImage field in CreateCluster. +func (o *CreateCluster) SetDockerImage(ctx context.Context, v DockerImage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["docker_image"] + o.DockerImage = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in CreateCluster as +// a GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetGcpAttributes(ctx context.Context) (GcpAttributes, bool) { + var e GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in CreateCluster. +func (o *CreateCluster) SetGcpAttributes(ctx context.Context, v GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in CreateCluster as +// a slice of InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetInitScripts(ctx context.Context) ([]InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in CreateCluster. +func (o *CreateCluster) SetInitScripts(ctx context.Context, v []InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in CreateCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in CreateCluster. +func (o *CreateCluster) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in CreateCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in CreateCluster. +func (o *CreateCluster) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in CreateCluster as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in CreateCluster. +func (o *CreateCluster) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + +// GetWorkloadType returns the value of the WorkloadType field in CreateCluster as +// a WorkloadType value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCluster) GetWorkloadType(ctx context.Context) (WorkloadType, bool) { + var e WorkloadType + if o.WorkloadType.IsNull() || o.WorkloadType.IsUnknown() { + return e, false + } + var v []WorkloadType + d := o.WorkloadType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkloadType sets the value of the WorkloadType field in CreateCluster. +func (o *CreateCluster) SetWorkloadType(ctx context.Context, v WorkloadType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workload_type"] + o.WorkloadType = types.ListValueMust(t, vs) +} + type CreateClusterResponse struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` } @@ -3446,6 +5286,185 @@ func (o CreateInstancePool) Type(ctx context.Context) attr.Type { } } +// GetAwsAttributes returns the value of the AwsAttributes field in CreateInstancePool as +// a InstancePoolAwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetAwsAttributes(ctx context.Context) (InstancePoolAwsAttributes, bool) { + var e InstancePoolAwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolAwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in CreateInstancePool. +func (o *CreateInstancePool) SetAwsAttributes(ctx context.Context, v InstancePoolAwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in CreateInstancePool as +// a InstancePoolAzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetAzureAttributes(ctx context.Context) (InstancePoolAzureAttributes, bool) { + var e InstancePoolAzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolAzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in CreateInstancePool. +func (o *CreateInstancePool) SetAzureAttributes(ctx context.Context, v InstancePoolAzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in CreateInstancePool as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in CreateInstancePool. +func (o *CreateInstancePool) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDiskSpec returns the value of the DiskSpec field in CreateInstancePool as +// a DiskSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetDiskSpec(ctx context.Context) (DiskSpec, bool) { + var e DiskSpec + if o.DiskSpec.IsNull() || o.DiskSpec.IsUnknown() { + return e, false + } + var v []DiskSpec + d := o.DiskSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDiskSpec sets the value of the DiskSpec field in CreateInstancePool. +func (o *CreateInstancePool) SetDiskSpec(ctx context.Context, v DiskSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disk_spec"] + o.DiskSpec = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in CreateInstancePool as +// a InstancePoolGcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetGcpAttributes(ctx context.Context) (InstancePoolGcpAttributes, bool) { + var e InstancePoolGcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolGcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in CreateInstancePool. +func (o *CreateInstancePool) SetGcpAttributes(ctx context.Context, v InstancePoolGcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetPreloadedDockerImages returns the value of the PreloadedDockerImages field in CreateInstancePool as +// a slice of DockerImage values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetPreloadedDockerImages(ctx context.Context) ([]DockerImage, bool) { + if o.PreloadedDockerImages.IsNull() || o.PreloadedDockerImages.IsUnknown() { + return nil, false + } + var v []DockerImage + d := o.PreloadedDockerImages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPreloadedDockerImages sets the value of the PreloadedDockerImages field in CreateInstancePool. +func (o *CreateInstancePool) SetPreloadedDockerImages(ctx context.Context, v []DockerImage) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_docker_images"] + o.PreloadedDockerImages = types.ListValueMust(t, vs) +} + +// GetPreloadedSparkVersions returns the value of the PreloadedSparkVersions field in CreateInstancePool as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstancePool) GetPreloadedSparkVersions(ctx context.Context) ([]types.String, bool) { + if o.PreloadedSparkVersions.IsNull() || o.PreloadedSparkVersions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PreloadedSparkVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPreloadedSparkVersions sets the value of the PreloadedSparkVersions field in CreateInstancePool. +func (o *CreateInstancePool) SetPreloadedSparkVersions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_spark_versions"] + o.PreloadedSparkVersions = types.ListValueMust(t, vs) +} + type CreateInstancePoolResponse struct { // The ID of the created instance pool. InstancePoolId types.String `tfsdk:"instance_pool_id" tf:"optional"` @@ -3577,6 +5596,31 @@ func (o CreatePolicy) Type(ctx context.Context) attr.Type { } } +// GetLibraries returns the value of the Libraries field in CreatePolicy as +// a slice of Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePolicy) GetLibraries(ctx context.Context) ([]Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in CreatePolicy. +func (o *CreatePolicy) SetLibraries(ctx context.Context, v []Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + type CreatePolicyResponse struct { // Canonical unique identifier for the cluster policy. PolicyId types.String `tfsdk:"policy_id" tf:"optional"` @@ -4276,6 +6320,32 @@ func (o DiskSpec) Type(ctx context.Context) attr.Type { } } +// GetDiskType returns the value of the DiskType field in DiskSpec as +// a DiskType value. +// If the field is unknown or null, the boolean return value is false. +func (o *DiskSpec) GetDiskType(ctx context.Context) (DiskType, bool) { + var e DiskType + if o.DiskType.IsNull() || o.DiskType.IsUnknown() { + return e, false + } + var v []DiskType + d := o.DiskType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDiskType sets the value of the DiskType field in DiskSpec. +func (o *DiskSpec) SetDiskType(ctx context.Context, v DiskType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disk_type"] + o.DiskType = types.ListValueMust(t, vs) +} + type DiskType struct { AzureDiskVolumeType types.String `tfsdk:"azure_disk_volume_type" tf:"optional"` @@ -4416,6 +6486,32 @@ func (o DockerImage) Type(ctx context.Context) attr.Type { } } +// GetBasicAuth returns the value of the BasicAuth field in DockerImage as +// a DockerBasicAuth value. +// If the field is unknown or null, the boolean return value is false. +func (o *DockerImage) GetBasicAuth(ctx context.Context) (DockerBasicAuth, bool) { + var e DockerBasicAuth + if o.BasicAuth.IsNull() || o.BasicAuth.IsUnknown() { + return e, false + } + var v []DockerBasicAuth + d := o.BasicAuth.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBasicAuth sets the value of the BasicAuth field in DockerImage. +func (o *DockerImage) SetBasicAuth(ctx context.Context, v DockerBasicAuth) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["basic_auth"] + o.BasicAuth = types.ListValueMust(t, vs) +} + type EditCluster struct { // When set to true, fixed and default values from the policy will be used // for fields that are omitted. When set to false, only fixed values from @@ -4698,6 +6794,313 @@ func (o EditCluster) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in EditCluster as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in EditCluster. +func (o *EditCluster) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + +// GetAwsAttributes returns the value of the AwsAttributes field in EditCluster as +// a AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetAwsAttributes(ctx context.Context) (AwsAttributes, bool) { + var e AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in EditCluster. +func (o *EditCluster) SetAwsAttributes(ctx context.Context, v AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in EditCluster as +// a AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetAzureAttributes(ctx context.Context) (AzureAttributes, bool) { + var e AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in EditCluster. +func (o *EditCluster) SetAzureAttributes(ctx context.Context, v AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in EditCluster as +// a ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetClusterLogConf(ctx context.Context) (ClusterLogConf, bool) { + var e ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in EditCluster. +func (o *EditCluster) SetClusterLogConf(ctx context.Context, v ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in EditCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in EditCluster. +func (o *EditCluster) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDockerImage returns the value of the DockerImage field in EditCluster as +// a DockerImage value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetDockerImage(ctx context.Context) (DockerImage, bool) { + var e DockerImage + if o.DockerImage.IsNull() || o.DockerImage.IsUnknown() { + return e, false + } + var v []DockerImage + d := o.DockerImage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDockerImage sets the value of the DockerImage field in EditCluster. +func (o *EditCluster) SetDockerImage(ctx context.Context, v DockerImage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["docker_image"] + o.DockerImage = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in EditCluster as +// a GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetGcpAttributes(ctx context.Context) (GcpAttributes, bool) { + var e GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in EditCluster. +func (o *EditCluster) SetGcpAttributes(ctx context.Context, v GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in EditCluster as +// a slice of InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetInitScripts(ctx context.Context) ([]InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in EditCluster. +func (o *EditCluster) SetInitScripts(ctx context.Context, v []InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in EditCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in EditCluster. +func (o *EditCluster) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in EditCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in EditCluster. +func (o *EditCluster) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in EditCluster as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in EditCluster. +func (o *EditCluster) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + +// GetWorkloadType returns the value of the WorkloadType field in EditCluster as +// a WorkloadType value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditCluster) GetWorkloadType(ctx context.Context) (WorkloadType, bool) { + var e WorkloadType + if o.WorkloadType.IsNull() || o.WorkloadType.IsUnknown() { + return e, false + } + var v []WorkloadType + d := o.WorkloadType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkloadType sets the value of the WorkloadType field in EditCluster. +func (o *EditCluster) SetWorkloadType(ctx context.Context, v WorkloadType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workload_type"] + o.WorkloadType = types.ListValueMust(t, vs) +} + type EditClusterResponse struct { } @@ -4821,6 +7224,31 @@ func (o EditInstancePool) Type(ctx context.Context) attr.Type { } } +// GetCustomTags returns the value of the CustomTags field in EditInstancePool as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditInstancePool) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in EditInstancePool. +func (o *EditInstancePool) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + type EditInstancePoolResponse struct { } @@ -4950,6 +7378,31 @@ func (o EditPolicy) Type(ctx context.Context) attr.Type { } } +// GetLibraries returns the value of the Libraries field in EditPolicy as +// a slice of Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPolicy) GetLibraries(ctx context.Context) ([]Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in EditPolicy. +func (o *EditPolicy) SetLibraries(ctx context.Context, v []Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + type EditPolicyResponse struct { } @@ -5121,6 +7574,31 @@ func (o EnforceClusterComplianceResponse) Type(ctx context.Context) attr.Type { } } +// GetChanges returns the value of the Changes field in EnforceClusterComplianceResponse as +// a slice of ClusterSettingsChange values. +// If the field is unknown or null, the boolean return value is false. +func (o *EnforceClusterComplianceResponse) GetChanges(ctx context.Context) ([]ClusterSettingsChange, bool) { + if o.Changes.IsNull() || o.Changes.IsUnknown() { + return nil, false + } + var v []ClusterSettingsChange + d := o.Changes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetChanges sets the value of the Changes field in EnforceClusterComplianceResponse. +func (o *EnforceClusterComplianceResponse) SetChanges(ctx context.Context, v []ClusterSettingsChange) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["changes"] + o.Changes = types.ListValueMust(t, vs) +} + // The environment entity used to preserve serverless environment side panel and // jobs' environment for non-notebook task. In this minimal environment spec, // only pip dependencies are supported. @@ -5182,6 +7660,31 @@ func (o Environment) Type(ctx context.Context) attr.Type { } } +// GetDependencies returns the value of the Dependencies field in Environment as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Environment) GetDependencies(ctx context.Context) ([]types.String, bool) { + if o.Dependencies.IsNull() || o.Dependencies.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Dependencies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDependencies sets the value of the Dependencies field in Environment. +func (o *Environment) SetDependencies(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dependencies"] + o.Dependencies = types.ListValueMust(t, vs) +} + type EventDetails struct { // * For created clusters, the attributes of the cluster. * For edited // clusters, the new attributes of the cluster. @@ -5327,6 +7830,162 @@ func (o EventDetails) Type(ctx context.Context) attr.Type { } } +// GetAttributes returns the value of the Attributes field in EventDetails as +// a ClusterAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *EventDetails) GetAttributes(ctx context.Context) (ClusterAttributes, bool) { + var e ClusterAttributes + if o.Attributes.IsNull() || o.Attributes.IsUnknown() { + return e, false + } + var v []ClusterAttributes + d := o.Attributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAttributes sets the value of the Attributes field in EventDetails. +func (o *EventDetails) SetAttributes(ctx context.Context, v ClusterAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["attributes"] + o.Attributes = types.ListValueMust(t, vs) +} + +// GetClusterSize returns the value of the ClusterSize field in EventDetails as +// a ClusterSize value. +// If the field is unknown or null, the boolean return value is false. +func (o *EventDetails) GetClusterSize(ctx context.Context) (ClusterSize, bool) { + var e ClusterSize + if o.ClusterSize.IsNull() || o.ClusterSize.IsUnknown() { + return e, false + } + var v []ClusterSize + d := o.ClusterSize.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterSize sets the value of the ClusterSize field in EventDetails. +func (o *EventDetails) SetClusterSize(ctx context.Context, v ClusterSize) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_size"] + o.ClusterSize = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in EventDetails as +// a InitScriptEventDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *EventDetails) GetInitScripts(ctx context.Context) (InitScriptEventDetails, bool) { + var e InitScriptEventDetails + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return e, false + } + var v []InitScriptEventDetails + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInitScripts sets the value of the InitScripts field in EventDetails. +func (o *EventDetails) SetInitScripts(ctx context.Context, v InitScriptEventDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetPreviousAttributes returns the value of the PreviousAttributes field in EventDetails as +// a ClusterAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *EventDetails) GetPreviousAttributes(ctx context.Context) (ClusterAttributes, bool) { + var e ClusterAttributes + if o.PreviousAttributes.IsNull() || o.PreviousAttributes.IsUnknown() { + return e, false + } + var v []ClusterAttributes + d := o.PreviousAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPreviousAttributes sets the value of the PreviousAttributes field in EventDetails. +func (o *EventDetails) SetPreviousAttributes(ctx context.Context, v ClusterAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["previous_attributes"] + o.PreviousAttributes = types.ListValueMust(t, vs) +} + +// GetPreviousClusterSize returns the value of the PreviousClusterSize field in EventDetails as +// a ClusterSize value. +// If the field is unknown or null, the boolean return value is false. +func (o *EventDetails) GetPreviousClusterSize(ctx context.Context) (ClusterSize, bool) { + var e ClusterSize + if o.PreviousClusterSize.IsNull() || o.PreviousClusterSize.IsUnknown() { + return e, false + } + var v []ClusterSize + d := o.PreviousClusterSize.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPreviousClusterSize sets the value of the PreviousClusterSize field in EventDetails. +func (o *EventDetails) SetPreviousClusterSize(ctx context.Context, v ClusterSize) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["previous_cluster_size"] + o.PreviousClusterSize = types.ListValueMust(t, vs) +} + +// GetReason returns the value of the Reason field in EventDetails as +// a TerminationReason value. +// If the field is unknown or null, the boolean return value is false. +func (o *EventDetails) GetReason(ctx context.Context) (TerminationReason, bool) { + var e TerminationReason + if o.Reason.IsNull() || o.Reason.IsUnknown() { + return e, false + } + var v []TerminationReason + d := o.Reason.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetReason sets the value of the Reason field in EventDetails. +func (o *EventDetails) SetReason(ctx context.Context, v TerminationReason) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["reason"] + o.Reason = types.ListValueMust(t, vs) +} + type GcpAttributes struct { // This field determines whether the instance pool will contain preemptible // VMs, on-demand VMs, or preemptible VMs with a fallback to on-demand VMs @@ -5548,6 +8207,31 @@ func (o GetClusterComplianceResponse) Type(ctx context.Context) attr.Type { } } +// GetViolations returns the value of the Violations field in GetClusterComplianceResponse as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetClusterComplianceResponse) GetViolations(ctx context.Context) (map[string]types.String, bool) { + if o.Violations.IsNull() || o.Violations.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Violations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetViolations sets the value of the Violations field in GetClusterComplianceResponse. +func (o *GetClusterComplianceResponse) SetViolations(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + o.Violations = types.MapValueMust(t, vs) +} + // Get cluster permission levels type GetClusterPermissionLevelsRequest struct { // The cluster for which to get or manage permissions. @@ -5637,6 +8321,31 @@ func (o GetClusterPermissionLevelsResponse) Type(ctx context.Context) attr.Type } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetClusterPermissionLevelsResponse as +// a slice of ClusterPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetClusterPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]ClusterPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []ClusterPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetClusterPermissionLevelsResponse. +func (o *GetClusterPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []ClusterPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get cluster permissions type GetClusterPermissionsRequest struct { // The cluster for which to get or manage permissions. @@ -5769,6 +8478,31 @@ func (o GetClusterPolicyPermissionLevelsResponse) Type(ctx context.Context) attr } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetClusterPolicyPermissionLevelsResponse as +// a slice of ClusterPolicyPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetClusterPolicyPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]ClusterPolicyPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []ClusterPolicyPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetClusterPolicyPermissionLevelsResponse. +func (o *GetClusterPolicyPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []ClusterPolicyPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get cluster policy permissions type GetClusterPolicyPermissionsRequest struct { // The cluster policy for which to get or manage permissions. @@ -5974,6 +8708,31 @@ func (o GetEvents) Type(ctx context.Context) attr.Type { } } +// GetEventTypes returns the value of the EventTypes field in GetEvents as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetEvents) GetEventTypes(ctx context.Context) ([]types.String, bool) { + if o.EventTypes.IsNull() || o.EventTypes.IsUnknown() { + return nil, false + } + var v []types.String + d := o.EventTypes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEventTypes sets the value of the EventTypes field in GetEvents. +func (o *GetEvents) SetEventTypes(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["event_types"] + o.EventTypes = types.ListValueMust(t, vs) +} + type GetEventsResponse struct { // Events types.List `tfsdk:"events" tf:"optional"` @@ -6033,6 +8792,57 @@ func (o GetEventsResponse) Type(ctx context.Context) attr.Type { } } +// GetEvents returns the value of the Events field in GetEventsResponse as +// a slice of ClusterEvent values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetEventsResponse) GetEvents(ctx context.Context) ([]ClusterEvent, bool) { + if o.Events.IsNull() || o.Events.IsUnknown() { + return nil, false + } + var v []ClusterEvent + d := o.Events.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEvents sets the value of the Events field in GetEventsResponse. +func (o *GetEventsResponse) SetEvents(ctx context.Context, v []ClusterEvent) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + o.Events = types.ListValueMust(t, vs) +} + +// GetNextPage returns the value of the NextPage field in GetEventsResponse as +// a GetEvents value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetEventsResponse) GetNextPage(ctx context.Context) (GetEvents, bool) { + var e GetEvents + if o.NextPage.IsNull() || o.NextPage.IsUnknown() { + return e, false + } + var v []GetEvents + d := o.NextPage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNextPage sets the value of the NextPage field in GetEventsResponse. +func (o *GetEventsResponse) SetNextPage(ctx context.Context, v GetEvents) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["next_page"] + o.NextPage = types.ListValueMust(t, vs) +} + // Get an init script type GetGlobalInitScriptRequest struct { // The ID of the global init script. @@ -6254,6 +9064,262 @@ func (o GetInstancePool) Type(ctx context.Context) attr.Type { } } +// GetAwsAttributes returns the value of the AwsAttributes field in GetInstancePool as +// a InstancePoolAwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetAwsAttributes(ctx context.Context) (InstancePoolAwsAttributes, bool) { + var e InstancePoolAwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolAwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in GetInstancePool. +func (o *GetInstancePool) SetAwsAttributes(ctx context.Context, v InstancePoolAwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in GetInstancePool as +// a InstancePoolAzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetAzureAttributes(ctx context.Context) (InstancePoolAzureAttributes, bool) { + var e InstancePoolAzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolAzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in GetInstancePool. +func (o *GetInstancePool) SetAzureAttributes(ctx context.Context, v InstancePoolAzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in GetInstancePool as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in GetInstancePool. +func (o *GetInstancePool) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDefaultTags returns the value of the DefaultTags field in GetInstancePool as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetDefaultTags(ctx context.Context) (map[string]types.String, bool) { + if o.DefaultTags.IsNull() || o.DefaultTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.DefaultTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDefaultTags sets the value of the DefaultTags field in GetInstancePool. +func (o *GetInstancePool) SetDefaultTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_tags"] + o.DefaultTags = types.MapValueMust(t, vs) +} + +// GetDiskSpec returns the value of the DiskSpec field in GetInstancePool as +// a DiskSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetDiskSpec(ctx context.Context) (DiskSpec, bool) { + var e DiskSpec + if o.DiskSpec.IsNull() || o.DiskSpec.IsUnknown() { + return e, false + } + var v []DiskSpec + d := o.DiskSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDiskSpec sets the value of the DiskSpec field in GetInstancePool. +func (o *GetInstancePool) SetDiskSpec(ctx context.Context, v DiskSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disk_spec"] + o.DiskSpec = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in GetInstancePool as +// a InstancePoolGcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetGcpAttributes(ctx context.Context) (InstancePoolGcpAttributes, bool) { + var e InstancePoolGcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolGcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in GetInstancePool. +func (o *GetInstancePool) SetGcpAttributes(ctx context.Context, v InstancePoolGcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetPreloadedDockerImages returns the value of the PreloadedDockerImages field in GetInstancePool as +// a slice of DockerImage values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetPreloadedDockerImages(ctx context.Context) ([]DockerImage, bool) { + if o.PreloadedDockerImages.IsNull() || o.PreloadedDockerImages.IsUnknown() { + return nil, false + } + var v []DockerImage + d := o.PreloadedDockerImages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPreloadedDockerImages sets the value of the PreloadedDockerImages field in GetInstancePool. +func (o *GetInstancePool) SetPreloadedDockerImages(ctx context.Context, v []DockerImage) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_docker_images"] + o.PreloadedDockerImages = types.ListValueMust(t, vs) +} + +// GetPreloadedSparkVersions returns the value of the PreloadedSparkVersions field in GetInstancePool as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetPreloadedSparkVersions(ctx context.Context) ([]types.String, bool) { + if o.PreloadedSparkVersions.IsNull() || o.PreloadedSparkVersions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PreloadedSparkVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPreloadedSparkVersions sets the value of the PreloadedSparkVersions field in GetInstancePool. +func (o *GetInstancePool) SetPreloadedSparkVersions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_spark_versions"] + o.PreloadedSparkVersions = types.ListValueMust(t, vs) +} + +// GetStats returns the value of the Stats field in GetInstancePool as +// a InstancePoolStats value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetStats(ctx context.Context) (InstancePoolStats, bool) { + var e InstancePoolStats + if o.Stats.IsNull() || o.Stats.IsUnknown() { + return e, false + } + var v []InstancePoolStats + d := o.Stats.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStats sets the value of the Stats field in GetInstancePool. +func (o *GetInstancePool) SetStats(ctx context.Context, v InstancePoolStats) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stats"] + o.Stats = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in GetInstancePool as +// a InstancePoolStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePool) GetStatus(ctx context.Context) (InstancePoolStatus, bool) { + var e InstancePoolStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []InstancePoolStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in GetInstancePool. +func (o *GetInstancePool) SetStatus(ctx context.Context, v InstancePoolStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + // Get instance pool permission levels type GetInstancePoolPermissionLevelsRequest struct { // The instance pool for which to get or manage permissions. @@ -6343,6 +9409,31 @@ func (o GetInstancePoolPermissionLevelsResponse) Type(ctx context.Context) attr. } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetInstancePoolPermissionLevelsResponse as +// a slice of InstancePoolPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetInstancePoolPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]InstancePoolPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []InstancePoolPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetInstancePoolPermissionLevelsResponse. +func (o *GetInstancePoolPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []InstancePoolPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get instance pool permissions type GetInstancePoolPermissionsRequest struct { // The instance pool for which to get or manage permissions. @@ -6523,6 +9614,31 @@ func (o GetSparkVersionsResponse) Type(ctx context.Context) attr.Type { } } +// GetVersions returns the value of the Versions field in GetSparkVersionsResponse as +// a slice of SparkVersion values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetSparkVersionsResponse) GetVersions(ctx context.Context) ([]SparkVersion, bool) { + if o.Versions.IsNull() || o.Versions.IsUnknown() { + return nil, false + } + var v []SparkVersion + d := o.Versions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetVersions sets the value of the Versions field in GetSparkVersionsResponse. +func (o *GetSparkVersionsResponse) SetVersions(ctx context.Context, v []SparkVersion) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["versions"] + o.Versions = types.ListValueMust(t, vs) +} + type GlobalInitScriptCreateRequest struct { // Specifies whether the script is enabled. The script runs only if enabled. Enabled types.Bool `tfsdk:"enabled" tf:"optional"` @@ -6848,19 +9964,69 @@ func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) basetypes.Obj }) } -// Type implements basetypes.ObjectValuable. -func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), - }, - "global": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), - }, - "reported_for_node": types.StringType, - }, +// Type implements basetypes.ObjectValuable. +func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "cluster": basetypes.ListType{ + ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), + }, + "global": basetypes.ListType{ + ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), + }, + "reported_for_node": types.StringType, + }, + } +} + +// GetCluster returns the value of the Cluster field in InitScriptEventDetails as +// a slice of InitScriptInfoAndExecutionDetails values. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptEventDetails) GetCluster(ctx context.Context) ([]InitScriptInfoAndExecutionDetails, bool) { + if o.Cluster.IsNull() || o.Cluster.IsUnknown() { + return nil, false + } + var v []InitScriptInfoAndExecutionDetails + d := o.Cluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCluster sets the value of the Cluster field in InitScriptEventDetails. +func (o *InitScriptEventDetails) SetCluster(ctx context.Context, v []InitScriptInfoAndExecutionDetails) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster"] + o.Cluster = types.ListValueMust(t, vs) +} + +// GetGlobal returns the value of the Global field in InitScriptEventDetails as +// a slice of InitScriptInfoAndExecutionDetails values. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptEventDetails) GetGlobal(ctx context.Context) ([]InitScriptInfoAndExecutionDetails, bool) { + if o.Global.IsNull() || o.Global.IsUnknown() { + return nil, false + } + var v []InitScriptInfoAndExecutionDetails + d := o.Global.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGlobal sets the value of the Global field in InitScriptEventDetails. +func (o *InitScriptEventDetails) SetGlobal(ctx context.Context, v []InitScriptInfoAndExecutionDetails) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["global"] + o.Global = types.ListValueMust(t, vs) } type InitScriptExecutionDetails struct { @@ -7012,6 +10178,188 @@ func (o InitScriptInfo) Type(ctx context.Context) attr.Type { } } +// GetAbfss returns the value of the Abfss field in InitScriptInfo as +// a Adlsgen2Info value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetAbfss(ctx context.Context) (Adlsgen2Info, bool) { + var e Adlsgen2Info + if o.Abfss.IsNull() || o.Abfss.IsUnknown() { + return e, false + } + var v []Adlsgen2Info + d := o.Abfss.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAbfss sets the value of the Abfss field in InitScriptInfo. +func (o *InitScriptInfo) SetAbfss(ctx context.Context, v Adlsgen2Info) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["abfss"] + o.Abfss = types.ListValueMust(t, vs) +} + +// GetDbfs returns the value of the Dbfs field in InitScriptInfo as +// a DbfsStorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetDbfs(ctx context.Context) (DbfsStorageInfo, bool) { + var e DbfsStorageInfo + if o.Dbfs.IsNull() || o.Dbfs.IsUnknown() { + return e, false + } + var v []DbfsStorageInfo + d := o.Dbfs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbfs sets the value of the Dbfs field in InitScriptInfo. +func (o *InitScriptInfo) SetDbfs(ctx context.Context, v DbfsStorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbfs"] + o.Dbfs = types.ListValueMust(t, vs) +} + +// GetFile returns the value of the File field in InitScriptInfo as +// a LocalFileInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetFile(ctx context.Context) (LocalFileInfo, bool) { + var e LocalFileInfo + if o.File.IsNull() || o.File.IsUnknown() { + return e, false + } + var v []LocalFileInfo + d := o.File.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFile sets the value of the File field in InitScriptInfo. +func (o *InitScriptInfo) SetFile(ctx context.Context, v LocalFileInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file"] + o.File = types.ListValueMust(t, vs) +} + +// GetGcs returns the value of the Gcs field in InitScriptInfo as +// a GcsStorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetGcs(ctx context.Context) (GcsStorageInfo, bool) { + var e GcsStorageInfo + if o.Gcs.IsNull() || o.Gcs.IsUnknown() { + return e, false + } + var v []GcsStorageInfo + d := o.Gcs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcs sets the value of the Gcs field in InitScriptInfo. +func (o *InitScriptInfo) SetGcs(ctx context.Context, v GcsStorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcs"] + o.Gcs = types.ListValueMust(t, vs) +} + +// GetS3 returns the value of the S3 field in InitScriptInfo as +// a S3StorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetS3(ctx context.Context) (S3StorageInfo, bool) { + var e S3StorageInfo + if o.S3.IsNull() || o.S3.IsUnknown() { + return e, false + } + var v []S3StorageInfo + d := o.S3.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetS3 sets the value of the S3 field in InitScriptInfo. +func (o *InitScriptInfo) SetS3(ctx context.Context, v S3StorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["s3"] + o.S3 = types.ListValueMust(t, vs) +} + +// GetVolumes returns the value of the Volumes field in InitScriptInfo as +// a VolumesStorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetVolumes(ctx context.Context) (VolumesStorageInfo, bool) { + var e VolumesStorageInfo + if o.Volumes.IsNull() || o.Volumes.IsUnknown() { + return e, false + } + var v []VolumesStorageInfo + d := o.Volumes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVolumes sets the value of the Volumes field in InitScriptInfo. +func (o *InitScriptInfo) SetVolumes(ctx context.Context, v VolumesStorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["volumes"] + o.Volumes = types.ListValueMust(t, vs) +} + +// GetWorkspace returns the value of the Workspace field in InitScriptInfo as +// a WorkspaceStorageInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfo) GetWorkspace(ctx context.Context) (WorkspaceStorageInfo, bool) { + var e WorkspaceStorageInfo + if o.Workspace.IsNull() || o.Workspace.IsUnknown() { + return e, false + } + var v []WorkspaceStorageInfo + d := o.Workspace.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkspace sets the value of the Workspace field in InitScriptInfo. +func (o *InitScriptInfo) SetWorkspace(ctx context.Context, v WorkspaceStorageInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace"] + o.Workspace = types.ListValueMust(t, vs) +} + type InitScriptInfoAndExecutionDetails struct { // Details about the script ExecutionDetails types.List `tfsdk:"execution_details" tf:"optional,object"` @@ -7065,6 +10413,58 @@ func (o InitScriptInfoAndExecutionDetails) Type(ctx context.Context) attr.Type { } } +// GetExecutionDetails returns the value of the ExecutionDetails field in InitScriptInfoAndExecutionDetails as +// a InitScriptExecutionDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfoAndExecutionDetails) GetExecutionDetails(ctx context.Context) (InitScriptExecutionDetails, bool) { + var e InitScriptExecutionDetails + if o.ExecutionDetails.IsNull() || o.ExecutionDetails.IsUnknown() { + return e, false + } + var v []InitScriptExecutionDetails + d := o.ExecutionDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExecutionDetails sets the value of the ExecutionDetails field in InitScriptInfoAndExecutionDetails. +func (o *InitScriptInfoAndExecutionDetails) SetExecutionDetails(ctx context.Context, v InitScriptExecutionDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["execution_details"] + o.ExecutionDetails = types.ListValueMust(t, vs) +} + +// GetScript returns the value of the Script field in InitScriptInfoAndExecutionDetails as +// a InitScriptInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *InitScriptInfoAndExecutionDetails) GetScript(ctx context.Context) (InitScriptInfo, bool) { + var e InitScriptInfo + if o.Script.IsNull() || o.Script.IsUnknown() { + return e, false + } + var v []InitScriptInfo + d := o.Script.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetScript sets the value of the Script field in InitScriptInfoAndExecutionDetails. +func (o *InitScriptInfoAndExecutionDetails) SetScript(ctx context.Context, v InitScriptInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["script"] + o.Script = types.ListValueMust(t, vs) +} + type InstallLibraries struct { // Unique identifier for the cluster on which to install these libraries. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -7115,6 +10515,31 @@ func (o InstallLibraries) Type(ctx context.Context) attr.Type { } } +// GetLibraries returns the value of the Libraries field in InstallLibraries as +// a slice of Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstallLibraries) GetLibraries(ctx context.Context) ([]Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in InstallLibraries. +func (o *InstallLibraries) SetLibraries(ctx context.Context, v []Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + type InstallLibrariesResponse struct { } @@ -7267,6 +10692,31 @@ func (o InstancePoolAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in InstancePoolAccessControlResponse as +// a slice of InstancePoolPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAccessControlResponse) GetAllPermissions(ctx context.Context) ([]InstancePoolPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []InstancePoolPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in InstancePoolAccessControlResponse. +func (o *InstancePoolAccessControlResponse) SetAllPermissions(ctx context.Context, v []InstancePoolPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type InstancePoolAndStats struct { // Attributes related to instance pools running on Amazon Web Services. If // not specified at pool creation, a set of default values will be used. @@ -7445,6 +10895,262 @@ func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { } } +// GetAwsAttributes returns the value of the AwsAttributes field in InstancePoolAndStats as +// a InstancePoolAwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetAwsAttributes(ctx context.Context) (InstancePoolAwsAttributes, bool) { + var e InstancePoolAwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolAwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetAwsAttributes(ctx context.Context, v InstancePoolAwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in InstancePoolAndStats as +// a InstancePoolAzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetAzureAttributes(ctx context.Context) (InstancePoolAzureAttributes, bool) { + var e InstancePoolAzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolAzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetAzureAttributes(ctx context.Context, v InstancePoolAzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in InstancePoolAndStats as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDefaultTags returns the value of the DefaultTags field in InstancePoolAndStats as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetDefaultTags(ctx context.Context) (map[string]types.String, bool) { + if o.DefaultTags.IsNull() || o.DefaultTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.DefaultTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDefaultTags sets the value of the DefaultTags field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetDefaultTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_tags"] + o.DefaultTags = types.MapValueMust(t, vs) +} + +// GetDiskSpec returns the value of the DiskSpec field in InstancePoolAndStats as +// a DiskSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetDiskSpec(ctx context.Context) (DiskSpec, bool) { + var e DiskSpec + if o.DiskSpec.IsNull() || o.DiskSpec.IsUnknown() { + return e, false + } + var v []DiskSpec + d := o.DiskSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDiskSpec sets the value of the DiskSpec field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetDiskSpec(ctx context.Context, v DiskSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disk_spec"] + o.DiskSpec = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in InstancePoolAndStats as +// a InstancePoolGcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetGcpAttributes(ctx context.Context) (InstancePoolGcpAttributes, bool) { + var e InstancePoolGcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []InstancePoolGcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetGcpAttributes(ctx context.Context, v InstancePoolGcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetPreloadedDockerImages returns the value of the PreloadedDockerImages field in InstancePoolAndStats as +// a slice of DockerImage values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetPreloadedDockerImages(ctx context.Context) ([]DockerImage, bool) { + if o.PreloadedDockerImages.IsNull() || o.PreloadedDockerImages.IsUnknown() { + return nil, false + } + var v []DockerImage + d := o.PreloadedDockerImages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPreloadedDockerImages sets the value of the PreloadedDockerImages field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetPreloadedDockerImages(ctx context.Context, v []DockerImage) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_docker_images"] + o.PreloadedDockerImages = types.ListValueMust(t, vs) +} + +// GetPreloadedSparkVersions returns the value of the PreloadedSparkVersions field in InstancePoolAndStats as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetPreloadedSparkVersions(ctx context.Context) ([]types.String, bool) { + if o.PreloadedSparkVersions.IsNull() || o.PreloadedSparkVersions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PreloadedSparkVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPreloadedSparkVersions sets the value of the PreloadedSparkVersions field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetPreloadedSparkVersions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_spark_versions"] + o.PreloadedSparkVersions = types.ListValueMust(t, vs) +} + +// GetStats returns the value of the Stats field in InstancePoolAndStats as +// a InstancePoolStats value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetStats(ctx context.Context) (InstancePoolStats, bool) { + var e InstancePoolStats + if o.Stats.IsNull() || o.Stats.IsUnknown() { + return e, false + } + var v []InstancePoolStats + d := o.Stats.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStats sets the value of the Stats field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetStats(ctx context.Context, v InstancePoolStats) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stats"] + o.Stats = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in InstancePoolAndStats as +// a InstancePoolStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolAndStats) GetStatus(ctx context.Context) (InstancePoolStatus, bool) { + var e InstancePoolStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []InstancePoolStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in InstancePoolAndStats. +func (o *InstancePoolAndStats) SetStatus(ctx context.Context, v InstancePoolStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + type InstancePoolAwsAttributes struct { // Availability type used for the spot nodes. // @@ -7693,6 +11399,31 @@ func (o InstancePoolPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in InstancePoolPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in InstancePoolPermission. +func (o *InstancePoolPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type InstancePoolPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -7746,6 +11477,31 @@ func (o InstancePoolPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in InstancePoolPermissions as +// a slice of InstancePoolAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolPermissions) GetAccessControlList(ctx context.Context) ([]InstancePoolAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []InstancePoolAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in InstancePoolPermissions. +func (o *InstancePoolPermissions) SetAccessControlList(ctx context.Context, v []InstancePoolAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type InstancePoolPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -7840,6 +11596,31 @@ func (o InstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in InstancePoolPermissionsRequest as +// a slice of InstancePoolAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolPermissionsRequest) GetAccessControlList(ctx context.Context) ([]InstancePoolAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []InstancePoolAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in InstancePoolPermissionsRequest. +func (o *InstancePoolPermissionsRequest) SetAccessControlList(ctx context.Context, v []InstancePoolAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type InstancePoolStats struct { // Number of active instances in the pool that are NOT part of a cluster. IdleCount types.Int64 `tfsdk:"idle_count" tf:"optional"` @@ -7943,6 +11724,31 @@ func (o InstancePoolStatus) Type(ctx context.Context) attr.Type { } } +// GetPendingInstanceErrors returns the value of the PendingInstanceErrors field in InstancePoolStatus as +// a slice of PendingInstanceError values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstancePoolStatus) GetPendingInstanceErrors(ctx context.Context) ([]PendingInstanceError, bool) { + if o.PendingInstanceErrors.IsNull() || o.PendingInstanceErrors.IsUnknown() { + return nil, false + } + var v []PendingInstanceError + d := o.PendingInstanceErrors.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPendingInstanceErrors sets the value of the PendingInstanceErrors field in InstancePoolStatus. +func (o *InstancePoolStatus) SetPendingInstanceErrors(ctx context.Context, v []PendingInstanceError) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pending_instance_errors"] + o.PendingInstanceErrors = types.ListValueMust(t, vs) +} + type InstanceProfile struct { // The AWS IAM role ARN of the role associated with the instance profile. // This field is required if your role name and instance profile name do not @@ -8100,6 +11906,84 @@ func (o Library) Type(ctx context.Context) attr.Type { } } +// GetCran returns the value of the Cran field in Library as +// a RCranLibrary value. +// If the field is unknown or null, the boolean return value is false. +func (o *Library) GetCran(ctx context.Context) (RCranLibrary, bool) { + var e RCranLibrary + if o.Cran.IsNull() || o.Cran.IsUnknown() { + return e, false + } + var v []RCranLibrary + d := o.Cran.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCran sets the value of the Cran field in Library. +func (o *Library) SetCran(ctx context.Context, v RCranLibrary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cran"] + o.Cran = types.ListValueMust(t, vs) +} + +// GetMaven returns the value of the Maven field in Library as +// a MavenLibrary value. +// If the field is unknown or null, the boolean return value is false. +func (o *Library) GetMaven(ctx context.Context) (MavenLibrary, bool) { + var e MavenLibrary + if o.Maven.IsNull() || o.Maven.IsUnknown() { + return e, false + } + var v []MavenLibrary + d := o.Maven.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMaven sets the value of the Maven field in Library. +func (o *Library) SetMaven(ctx context.Context, v MavenLibrary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["maven"] + o.Maven = types.ListValueMust(t, vs) +} + +// GetPypi returns the value of the Pypi field in Library as +// a PythonPyPiLibrary value. +// If the field is unknown or null, the boolean return value is false. +func (o *Library) GetPypi(ctx context.Context) (PythonPyPiLibrary, bool) { + var e PythonPyPiLibrary + if o.Pypi.IsNull() || o.Pypi.IsUnknown() { + return e, false + } + var v []PythonPyPiLibrary + d := o.Pypi.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPypi sets the value of the Pypi field in Library. +func (o *Library) SetPypi(ctx context.Context, v PythonPyPiLibrary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pypi"] + o.Pypi = types.ListValueMust(t, vs) +} + // The status of the library on a specific cluster. type LibraryFullStatus struct { // Whether the library was set to be installed on all clusters via the @@ -8164,6 +12048,57 @@ func (o LibraryFullStatus) Type(ctx context.Context) attr.Type { } } +// GetLibrary returns the value of the Library field in LibraryFullStatus as +// a Library value. +// If the field is unknown or null, the boolean return value is false. +func (o *LibraryFullStatus) GetLibrary(ctx context.Context) (Library, bool) { + var e Library + if o.Library.IsNull() || o.Library.IsUnknown() { + return e, false + } + var v []Library + d := o.Library.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetLibrary sets the value of the Library field in LibraryFullStatus. +func (o *LibraryFullStatus) SetLibrary(ctx context.Context, v Library) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + o.Library = types.ListValueMust(t, vs) +} + +// GetMessages returns the value of the Messages field in LibraryFullStatus as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *LibraryFullStatus) GetMessages(ctx context.Context) ([]types.String, bool) { + if o.Messages.IsNull() || o.Messages.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Messages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMessages sets the value of the Messages field in LibraryFullStatus. +func (o *LibraryFullStatus) SetMessages(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["messages"] + o.Messages = types.ListValueMust(t, vs) +} + type ListAllClusterLibraryStatusesResponse struct { // A list of cluster statuses. Statuses types.List `tfsdk:"statuses" tf:"optional"` @@ -8210,6 +12145,31 @@ func (o ListAllClusterLibraryStatusesResponse) Type(ctx context.Context) attr.Ty } } +// GetStatuses returns the value of the Statuses field in ListAllClusterLibraryStatusesResponse as +// a slice of ClusterLibraryStatuses values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAllClusterLibraryStatusesResponse) GetStatuses(ctx context.Context) ([]ClusterLibraryStatuses, bool) { + if o.Statuses.IsNull() || o.Statuses.IsUnknown() { + return nil, false + } + var v []ClusterLibraryStatuses + d := o.Statuses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStatuses sets the value of the Statuses field in ListAllClusterLibraryStatusesResponse. +func (o *ListAllClusterLibraryStatusesResponse) SetStatuses(ctx context.Context, v []ClusterLibraryStatuses) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statuses"] + o.Statuses = types.ListValueMust(t, vs) +} + type ListAvailableZonesResponse struct { // The availability zone if no `zone_id` is provided in the cluster creation // request. @@ -8261,6 +12221,31 @@ func (o ListAvailableZonesResponse) Type(ctx context.Context) attr.Type { } } +// GetZones returns the value of the Zones field in ListAvailableZonesResponse as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAvailableZonesResponse) GetZones(ctx context.Context) ([]types.String, bool) { + if o.Zones.IsNull() || o.Zones.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Zones.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetZones sets the value of the Zones field in ListAvailableZonesResponse. +func (o *ListAvailableZonesResponse) SetZones(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["zones"] + o.Zones = types.ListValueMust(t, vs) +} + // List cluster policy compliance type ListClusterCompliancesRequest struct { // Use this field to specify the maximum number of results to be returned by @@ -8372,6 +12357,31 @@ func (o ListClusterCompliancesResponse) Type(ctx context.Context) attr.Type { } } +// GetClusters returns the value of the Clusters field in ListClusterCompliancesResponse as +// a slice of ClusterCompliance values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListClusterCompliancesResponse) GetClusters(ctx context.Context) ([]ClusterCompliance, bool) { + if o.Clusters.IsNull() || o.Clusters.IsUnknown() { + return nil, false + } + var v []ClusterCompliance + d := o.Clusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusters sets the value of the Clusters field in ListClusterCompliancesResponse. +func (o *ListClusterCompliancesResponse) SetClusters(ctx context.Context, v []ClusterCompliance) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + o.Clusters = types.ListValueMust(t, vs) +} + // List cluster policies type ListClusterPoliciesRequest struct { // The cluster policy attribute to sort by. * `POLICY_CREATION_TIME` - Sort @@ -8483,6 +12493,56 @@ func (o ListClustersFilterBy) Type(ctx context.Context) attr.Type { } } +// GetClusterSources returns the value of the ClusterSources field in ListClustersFilterBy as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListClustersFilterBy) GetClusterSources(ctx context.Context) ([]types.String, bool) { + if o.ClusterSources.IsNull() || o.ClusterSources.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ClusterSources.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusterSources sets the value of the ClusterSources field in ListClustersFilterBy. +func (o *ListClustersFilterBy) SetClusterSources(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_sources"] + o.ClusterSources = types.ListValueMust(t, vs) +} + +// GetClusterStates returns the value of the ClusterStates field in ListClustersFilterBy as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListClustersFilterBy) GetClusterStates(ctx context.Context) ([]types.String, bool) { + if o.ClusterStates.IsNull() || o.ClusterStates.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ClusterStates.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusterStates sets the value of the ClusterStates field in ListClustersFilterBy. +func (o *ListClustersFilterBy) SetClusterStates(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_states"] + o.ClusterStates = types.ListValueMust(t, vs) +} + // List clusters type ListClustersRequest struct { // Filters to apply to the list of clusters. @@ -8548,6 +12608,58 @@ func (o ListClustersRequest) Type(ctx context.Context) attr.Type { } } +// GetFilterBy returns the value of the FilterBy field in ListClustersRequest as +// a ListClustersFilterBy value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListClustersRequest) GetFilterBy(ctx context.Context) (ListClustersFilterBy, bool) { + var e ListClustersFilterBy + if o.FilterBy.IsNull() || o.FilterBy.IsUnknown() { + return e, false + } + var v []ListClustersFilterBy + d := o.FilterBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilterBy sets the value of the FilterBy field in ListClustersRequest. +func (o *ListClustersRequest) SetFilterBy(ctx context.Context, v ListClustersFilterBy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter_by"] + o.FilterBy = types.ListValueMust(t, vs) +} + +// GetSortBy returns the value of the SortBy field in ListClustersRequest as +// a ListClustersSortBy value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListClustersRequest) GetSortBy(ctx context.Context) (ListClustersSortBy, bool) { + var e ListClustersSortBy + if o.SortBy.IsNull() || o.SortBy.IsUnknown() { + return e, false + } + var v []ListClustersSortBy + d := o.SortBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSortBy sets the value of the SortBy field in ListClustersRequest. +func (o *ListClustersRequest) SetSortBy(ctx context.Context, v ListClustersSortBy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sort_by"] + o.SortBy = types.ListValueMust(t, vs) +} + type ListClustersResponse struct { // Clusters types.List `tfsdk:"clusters" tf:"optional"` @@ -8605,6 +12717,31 @@ func (o ListClustersResponse) Type(ctx context.Context) attr.Type { } } +// GetClusters returns the value of the Clusters field in ListClustersResponse as +// a slice of ClusterDetails values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListClustersResponse) GetClusters(ctx context.Context) ([]ClusterDetails, bool) { + if o.Clusters.IsNull() || o.Clusters.IsUnknown() { + return nil, false + } + var v []ClusterDetails + d := o.Clusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusters sets the value of the Clusters field in ListClustersResponse. +func (o *ListClustersResponse) SetClusters(ctx context.Context, v []ClusterDetails) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + o.Clusters = types.ListValueMust(t, vs) +} + type ListClustersSortBy struct { // The direction to sort by. Direction types.String `tfsdk:"direction" tf:"optional"` @@ -8698,6 +12835,31 @@ func (o ListGlobalInitScriptsResponse) Type(ctx context.Context) attr.Type { } } +// GetScripts returns the value of the Scripts field in ListGlobalInitScriptsResponse as +// a slice of GlobalInitScriptDetails values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListGlobalInitScriptsResponse) GetScripts(ctx context.Context) ([]GlobalInitScriptDetails, bool) { + if o.Scripts.IsNull() || o.Scripts.IsUnknown() { + return nil, false + } + var v []GlobalInitScriptDetails + d := o.Scripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScripts sets the value of the Scripts field in ListGlobalInitScriptsResponse. +func (o *ListGlobalInitScriptsResponse) SetScripts(ctx context.Context, v []GlobalInitScriptDetails) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scripts"] + o.Scripts = types.ListValueMust(t, vs) +} + type ListInstancePools struct { InstancePools types.List `tfsdk:"instance_pools" tf:"optional"` } @@ -8743,6 +12905,31 @@ func (o ListInstancePools) Type(ctx context.Context) attr.Type { } } +// GetInstancePools returns the value of the InstancePools field in ListInstancePools as +// a slice of InstancePoolAndStats values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListInstancePools) GetInstancePools(ctx context.Context) ([]InstancePoolAndStats, bool) { + if o.InstancePools.IsNull() || o.InstancePools.IsUnknown() { + return nil, false + } + var v []InstancePoolAndStats + d := o.InstancePools.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInstancePools sets the value of the InstancePools field in ListInstancePools. +func (o *ListInstancePools) SetInstancePools(ctx context.Context, v []InstancePoolAndStats) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["instance_pools"] + o.InstancePools = types.ListValueMust(t, vs) +} + type ListInstanceProfilesResponse struct { // A list of instance profiles that the user can access. InstanceProfiles types.List `tfsdk:"instance_profiles" tf:"optional"` @@ -8789,6 +12976,31 @@ func (o ListInstanceProfilesResponse) Type(ctx context.Context) attr.Type { } } +// GetInstanceProfiles returns the value of the InstanceProfiles field in ListInstanceProfilesResponse as +// a slice of InstanceProfile values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListInstanceProfilesResponse) GetInstanceProfiles(ctx context.Context) ([]InstanceProfile, bool) { + if o.InstanceProfiles.IsNull() || o.InstanceProfiles.IsUnknown() { + return nil, false + } + var v []InstanceProfile + d := o.InstanceProfiles.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInstanceProfiles sets the value of the InstanceProfiles field in ListInstanceProfilesResponse. +func (o *ListInstanceProfilesResponse) SetInstanceProfiles(ctx context.Context, v []InstanceProfile) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["instance_profiles"] + o.InstanceProfiles = types.ListValueMust(t, vs) +} + type ListNodeTypesResponse struct { // The list of available Spark node types. NodeTypes types.List `tfsdk:"node_types" tf:"optional"` @@ -8835,6 +13047,31 @@ func (o ListNodeTypesResponse) Type(ctx context.Context) attr.Type { } } +// GetNodeTypes returns the value of the NodeTypes field in ListNodeTypesResponse as +// a slice of NodeType values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListNodeTypesResponse) GetNodeTypes(ctx context.Context) ([]NodeType, bool) { + if o.NodeTypes.IsNull() || o.NodeTypes.IsUnknown() { + return nil, false + } + var v []NodeType + d := o.NodeTypes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNodeTypes sets the value of the NodeTypes field in ListNodeTypesResponse. +func (o *ListNodeTypesResponse) SetNodeTypes(ctx context.Context, v []NodeType) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["node_types"] + o.NodeTypes = types.ListValueMust(t, vs) +} + type ListPoliciesResponse struct { // List of policies. Policies types.List `tfsdk:"policies" tf:"optional"` @@ -8881,6 +13118,31 @@ func (o ListPoliciesResponse) Type(ctx context.Context) attr.Type { } } +// GetPolicies returns the value of the Policies field in ListPoliciesResponse as +// a slice of Policy values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPoliciesResponse) GetPolicies(ctx context.Context) ([]Policy, bool) { + if o.Policies.IsNull() || o.Policies.IsUnknown() { + return nil, false + } + var v []Policy + d := o.Policies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPolicies sets the value of the Policies field in ListPoliciesResponse. +func (o *ListPoliciesResponse) SetPolicies(ctx context.Context, v []Policy) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["policies"] + o.Policies = types.ListValueMust(t, vs) +} + // List policy families type ListPolicyFamiliesRequest struct { // Maximum number of policy families to return. @@ -8979,6 +13241,31 @@ func (o ListPolicyFamiliesResponse) Type(ctx context.Context) attr.Type { } } +// GetPolicyFamilies returns the value of the PolicyFamilies field in ListPolicyFamiliesResponse as +// a slice of PolicyFamily values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPolicyFamiliesResponse) GetPolicyFamilies(ctx context.Context) ([]PolicyFamily, bool) { + if o.PolicyFamilies.IsNull() || o.PolicyFamilies.IsUnknown() { + return nil, false + } + var v []PolicyFamily + d := o.PolicyFamilies.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPolicyFamilies sets the value of the PolicyFamilies field in ListPolicyFamiliesResponse. +func (o *ListPolicyFamiliesResponse) SetPolicyFamilies(ctx context.Context, v []PolicyFamily) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["policy_families"] + o.PolicyFamilies = types.ListValueMust(t, vs) +} + type LocalFileInfo struct { // local file destination, e.g. `file:/my/local/file.sh` Destination types.String `tfsdk:"destination" tf:""` @@ -9174,6 +13461,31 @@ func (o MavenLibrary) Type(ctx context.Context) attr.Type { } } +// GetExclusions returns the value of the Exclusions field in MavenLibrary as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *MavenLibrary) GetExclusions(ctx context.Context) ([]types.String, bool) { + if o.Exclusions.IsNull() || o.Exclusions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Exclusions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExclusions sets the value of the Exclusions field in MavenLibrary. +func (o *MavenLibrary) SetExclusions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exclusions"] + o.Exclusions = types.ListValueMust(t, vs) +} + type NodeInstanceType struct { InstanceTypeId types.String `tfsdk:"instance_type_id" tf:"optional"` @@ -9365,6 +13677,58 @@ func (o NodeType) Type(ctx context.Context) attr.Type { } } +// GetNodeInfo returns the value of the NodeInfo field in NodeType as +// a CloudProviderNodeInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *NodeType) GetNodeInfo(ctx context.Context) (CloudProviderNodeInfo, bool) { + var e CloudProviderNodeInfo + if o.NodeInfo.IsNull() || o.NodeInfo.IsUnknown() { + return e, false + } + var v []CloudProviderNodeInfo + d := o.NodeInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNodeInfo sets the value of the NodeInfo field in NodeType. +func (o *NodeType) SetNodeInfo(ctx context.Context, v CloudProviderNodeInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["node_info"] + o.NodeInfo = types.ListValueMust(t, vs) +} + +// GetNodeInstanceType returns the value of the NodeInstanceType field in NodeType as +// a NodeInstanceType value. +// If the field is unknown or null, the boolean return value is false. +func (o *NodeType) GetNodeInstanceType(ctx context.Context) (NodeInstanceType, bool) { + var e NodeInstanceType + if o.NodeInstanceType.IsNull() || o.NodeInstanceType.IsUnknown() { + return e, false + } + var v []NodeInstanceType + d := o.NodeInstanceType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNodeInstanceType sets the value of the NodeInstanceType field in NodeType. +func (o *NodeType) SetNodeInstanceType(ctx context.Context, v NodeInstanceType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["node_instance_type"] + o.NodeInstanceType = types.ListValueMust(t, vs) +} + type PendingInstanceError struct { InstanceId types.String `tfsdk:"instance_id" tf:"optional"` @@ -9676,6 +14040,31 @@ func (o Policy) Type(ctx context.Context) attr.Type { } } +// GetLibraries returns the value of the Libraries field in Policy as +// a slice of Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *Policy) GetLibraries(ctx context.Context) ([]Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in Policy. +func (o *Policy) SetLibraries(ctx context.Context, v []Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + type PolicyFamily struct { // Policy definition document expressed in [Databricks Cluster Policy // Definition Language]. @@ -9972,6 +14361,32 @@ func (o ResizeCluster) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in ResizeCluster as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResizeCluster) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in ResizeCluster. +func (o *ResizeCluster) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + type ResizeClusterResponse struct { } @@ -10178,6 +14593,56 @@ func (o Results) Type(ctx context.Context) attr.Type { } } +// GetFileNames returns the value of the FileNames field in Results as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Results) GetFileNames(ctx context.Context) ([]types.String, bool) { + if o.FileNames.IsNull() || o.FileNames.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FileNames.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFileNames sets the value of the FileNames field in Results. +func (o *Results) SetFileNames(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fileNames"] + o.FileNames = types.ListValueMust(t, vs) +} + +// GetSchema returns the value of the Schema field in Results as +// a slice of types.Object values. +// If the field is unknown or null, the boolean return value is false. +func (o *Results) GetSchema(ctx context.Context) ([]types.Object, bool) { + if o.Schema.IsNull() || o.Schema.IsUnknown() { + return nil, false + } + var v []types.Object + d := o.Schema.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchema sets the value of the Schema field in Results. +func (o *Results) SetSchema(ctx context.Context, v []types.Object) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schema"] + o.Schema = types.ListValueMust(t, vs) +} + type S3StorageInfo struct { // (Optional) Set canned access control list for the logs, e.g. // `bucket-owner-full-control`. If `canned_cal` is set, please make sure the @@ -10341,6 +14806,32 @@ func (o SparkNode) Type(ctx context.Context) attr.Type { } } +// GetNodeAwsAttributes returns the value of the NodeAwsAttributes field in SparkNode as +// a SparkNodeAwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *SparkNode) GetNodeAwsAttributes(ctx context.Context) (SparkNodeAwsAttributes, bool) { + var e SparkNodeAwsAttributes + if o.NodeAwsAttributes.IsNull() || o.NodeAwsAttributes.IsUnknown() { + return e, false + } + var v []SparkNodeAwsAttributes + d := o.NodeAwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNodeAwsAttributes sets the value of the NodeAwsAttributes field in SparkNode. +func (o *SparkNode) SetNodeAwsAttributes(ctx context.Context, v SparkNodeAwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["node_aws_attributes"] + o.NodeAwsAttributes = types.ListValueMust(t, vs) +} + type SparkNodeAwsAttributes struct { // Whether this node is on an Amazon spot instance. IsSpot types.Bool `tfsdk:"is_spot" tf:"optional"` @@ -10566,6 +15057,31 @@ func (o TerminationReason) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in TerminationReason as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TerminationReason) GetParameters(ctx context.Context) (map[string]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in TerminationReason. +func (o *TerminationReason) SetParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.MapValueMust(t, vs) +} + type UninstallLibraries struct { // Unique identifier for the cluster on which to uninstall these libraries. ClusterId types.String `tfsdk:"cluster_id" tf:""` @@ -10616,6 +15132,31 @@ func (o UninstallLibraries) Type(ctx context.Context) attr.Type { } } +// GetLibraries returns the value of the Libraries field in UninstallLibraries as +// a slice of Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *UninstallLibraries) GetLibraries(ctx context.Context) ([]Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in UninstallLibraries. +func (o *UninstallLibraries) SetLibraries(ctx context.Context, v []Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + type UninstallLibrariesResponse struct { } @@ -10788,6 +15329,32 @@ func (o UpdateCluster) Type(ctx context.Context) attr.Type { } } +// GetCluster returns the value of the Cluster field in UpdateCluster as +// a UpdateClusterResource value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCluster) GetCluster(ctx context.Context) (UpdateClusterResource, bool) { + var e UpdateClusterResource + if o.Cluster.IsNull() || o.Cluster.IsUnknown() { + return e, false + } + var v []UpdateClusterResource + d := o.Cluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCluster sets the value of the Cluster field in UpdateCluster. +func (o *UpdateCluster) SetCluster(ctx context.Context, v UpdateClusterResource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster"] + o.Cluster = types.ListValueMust(t, vs) +} + type UpdateClusterResource struct { // Parameters needed in order to automatically scale clusters up and down // based on load. Note: autoscaling works best with DB runtime versions 3.0 @@ -11060,6 +15627,313 @@ func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in UpdateClusterResource as +// a AutoScale value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetAutoscale(ctx context.Context) (AutoScale, bool) { + var e AutoScale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []AutoScale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in UpdateClusterResource. +func (o *UpdateClusterResource) SetAutoscale(ctx context.Context, v AutoScale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + +// GetAwsAttributes returns the value of the AwsAttributes field in UpdateClusterResource as +// a AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetAwsAttributes(ctx context.Context) (AwsAttributes, bool) { + var e AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in UpdateClusterResource. +func (o *UpdateClusterResource) SetAwsAttributes(ctx context.Context, v AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in UpdateClusterResource as +// a AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetAzureAttributes(ctx context.Context) (AzureAttributes, bool) { + var e AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in UpdateClusterResource. +func (o *UpdateClusterResource) SetAzureAttributes(ctx context.Context, v AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in UpdateClusterResource as +// a ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetClusterLogConf(ctx context.Context) (ClusterLogConf, bool) { + var e ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in UpdateClusterResource. +func (o *UpdateClusterResource) SetClusterLogConf(ctx context.Context, v ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in UpdateClusterResource as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in UpdateClusterResource. +func (o *UpdateClusterResource) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetDockerImage returns the value of the DockerImage field in UpdateClusterResource as +// a DockerImage value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetDockerImage(ctx context.Context) (DockerImage, bool) { + var e DockerImage + if o.DockerImage.IsNull() || o.DockerImage.IsUnknown() { + return e, false + } + var v []DockerImage + d := o.DockerImage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDockerImage sets the value of the DockerImage field in UpdateClusterResource. +func (o *UpdateClusterResource) SetDockerImage(ctx context.Context, v DockerImage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["docker_image"] + o.DockerImage = types.ListValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in UpdateClusterResource as +// a GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetGcpAttributes(ctx context.Context) (GcpAttributes, bool) { + var e GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in UpdateClusterResource. +func (o *UpdateClusterResource) SetGcpAttributes(ctx context.Context, v GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in UpdateClusterResource as +// a slice of InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetInitScripts(ctx context.Context) ([]InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in UpdateClusterResource. +func (o *UpdateClusterResource) SetInitScripts(ctx context.Context, v []InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in UpdateClusterResource as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in UpdateClusterResource. +func (o *UpdateClusterResource) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in UpdateClusterResource as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in UpdateClusterResource. +func (o *UpdateClusterResource) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in UpdateClusterResource as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in UpdateClusterResource. +func (o *UpdateClusterResource) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + +// GetWorkloadType returns the value of the WorkloadType field in UpdateClusterResource as +// a WorkloadType value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateClusterResource) GetWorkloadType(ctx context.Context) (WorkloadType, bool) { + var e WorkloadType + if o.WorkloadType.IsNull() || o.WorkloadType.IsUnknown() { + return e, false + } + var v []WorkloadType + d := o.WorkloadType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWorkloadType sets the value of the WorkloadType field in UpdateClusterResource. +func (o *UpdateClusterResource) SetWorkloadType(ctx context.Context, v WorkloadType) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workload_type"] + o.WorkloadType = types.ListValueMust(t, vs) +} + type UpdateClusterResponse struct { } @@ -11220,6 +16094,32 @@ func (o WorkloadType) Type(ctx context.Context) attr.Type { } } +// GetClients returns the value of the Clients field in WorkloadType as +// a ClientsTypes value. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkloadType) GetClients(ctx context.Context) (ClientsTypes, bool) { + var e ClientsTypes + if o.Clients.IsNull() || o.Clients.IsUnknown() { + return e, false + } + var v []ClientsTypes + d := o.Clients.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClients sets the value of the Clients field in WorkloadType. +func (o *WorkloadType) SetClients(ctx context.Context, v ClientsTypes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clients"] + o.Clients = types.ListValueMust(t, vs) +} + type WorkspaceStorageInfo struct { // workspace files destination, e.g. // `/Users/user1@databricks.com/my-init.sh` @@ -11262,97 +16162,3 @@ func (o WorkspaceStorageInfo) Type(ctx context.Context) attr.Type { }, } } - -// Availability type used for all subsequent nodes past the `first_on_demand` -// ones. -// -// Note: If `first_on_demand` is zero, this availability type will be used for -// the entire cluster. - -// Availability type used for all subsequent nodes past the `first_on_demand` -// ones. Note: If `first_on_demand` is zero (which only happens on pool -// clusters), this availability type will be used for the entire cluster. - -// Permission level - -// Permission level - -// Determines whether the cluster was created by a user through the UI, created -// by the Databricks Jobs Scheduler, or through an API request. This is the same -// as cluster_creator, but read only. - -// - -// Data security mode decides what data governance model to use when accessing -// data from a cluster. -// -// * `NONE`: No security isolation for multiple users sharing the cluster. Data -// governance features are not available in this mode. * `SINGLE_USER`: A secure -// cluster that can only be exclusively used by a single user specified in -// `single_user_name`. Most programming languages, cluster features and data -// governance features are available in this mode. * `USER_ISOLATION`: A secure -// cluster that can be shared by multiple users. Cluster users are fully -// isolated so that they cannot see each other's data and credentials. Most data -// governance features are supported in this mode. But programming languages and -// cluster features might be limited. -// -// The following modes are deprecated starting with Databricks Runtime 15.0 and -// will be removed for future Databricks Runtime versions: -// -// * `LEGACY_TABLE_ACL`: This mode is for users migrating from legacy Table ACL -// clusters. * `LEGACY_PASSTHROUGH`: This mode is for users migrating from -// legacy Passthrough on high concurrency clusters. * `LEGACY_SINGLE_USER`: This -// mode is for users migrating from legacy Passthrough on standard clusters. * -// `LEGACY_SINGLE_USER_STANDARD`: This mode provides a way that doesn’t have -// UC nor passthrough enabled. - -// The type of EBS volumes that will be launched with this cluster. - -// The cause of a change in target size. - -// This field determines whether the instance pool will contain preemptible VMs, -// on-demand VMs, or preemptible VMs with a fallback to on-demand VMs if the -// former is unavailable. - -// The order to list events in; either "ASC" or "DESC". Defaults to "DESC". - -// The current status of the script - -// Availability type used for the spot nodes. -// -// The default value is defined by -// InstancePoolConf.instancePoolDefaultAwsAvailability - -// Shows the Availability type used for the spot nodes. -// -// The default value is defined by -// InstancePoolConf.instancePoolDefaultAzureAvailability - -// Permission level - -// Current state of the instance pool. - -// The status of a library on a specific cluster. - -// The direction to sort by. - -// The sorting criteria. By default, clusters are sorted by 3 columns from -// highest to lowest precedence: cluster state, pinned or unpinned, then cluster -// name. - -// A generic ordering enum for list-based queries. - -// Determines the cluster's runtime engine, either standard or Photon. -// -// This field is not compatible with legacy `spark_version` values that contain -// `-photon-`. Remove `-photon-` from the `spark_version` and set -// `runtime_engine` to `PHOTON`. -// -// If left unspecified, the runtime engine defaults to standard unless the -// spark_version contains -photon-, in which case Photon will be used. - -// Current state of the cluster. - -// status code indicating why the cluster was terminated - -// type of the termination diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index c5be2f3c56..468fd2142e 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -14,7 +14,7 @@ import ( "context" "reflect" - "github.com/databricks/databricks-sdk-go/service/sql" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/sql_tf" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" @@ -67,6 +67,32 @@ func (o CreateDashboardRequest) Type(ctx context.Context) attr.Type { } } +// GetDashboard returns the value of the Dashboard field in CreateDashboardRequest as +// a Dashboard value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateDashboardRequest) GetDashboard(ctx context.Context) (Dashboard, bool) { + var e Dashboard + if o.Dashboard.IsNull() || o.Dashboard.IsUnknown() { + return e, false + } + var v []Dashboard + d := o.Dashboard.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDashboard sets the value of the Dashboard field in CreateDashboardRequest. +func (o *CreateDashboardRequest) SetDashboard(ctx context.Context, v Dashboard) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dashboard"] + o.Dashboard = types.ListValueMust(t, vs) +} + // Create dashboard schedule type CreateScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. @@ -118,6 +144,32 @@ func (o CreateScheduleRequest) Type(ctx context.Context) attr.Type { } } +// GetSchedule returns the value of the Schedule field in CreateScheduleRequest as +// a Schedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateScheduleRequest) GetSchedule(ctx context.Context) (Schedule, bool) { + var e Schedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []Schedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in CreateScheduleRequest. +func (o *CreateScheduleRequest) SetSchedule(ctx context.Context, v Schedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + // Create schedule subscription type CreateSubscriptionRequest struct { // UUID identifying the dashboard to which the subscription belongs. @@ -173,6 +225,32 @@ func (o CreateSubscriptionRequest) Type(ctx context.Context) attr.Type { } } +// GetSubscription returns the value of the Subscription field in CreateSubscriptionRequest as +// a Subscription value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateSubscriptionRequest) GetSubscription(ctx context.Context) (Subscription, bool) { + var e Subscription + if o.Subscription.IsNull() || o.Subscription.IsUnknown() { + return e, false + } + var v []Subscription + d := o.Subscription.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSubscription sets the value of the Subscription field in CreateSubscriptionRequest. +func (o *CreateSubscriptionRequest) SetSubscription(ctx context.Context, v Subscription) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscription"] + o.Subscription = types.ListValueMust(t, vs) +} + type CronSchedule struct { // A cron expression using quartz syntax. EX: `0 0 8 * * ?` represents // everyday at 8am. See [Cron Trigger] for details. @@ -549,6 +627,58 @@ func (o GenieAttachment) Type(ctx context.Context) attr.Type { } } +// GetQuery returns the value of the Query field in GenieAttachment as +// a QueryAttachment value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieAttachment) GetQuery(ctx context.Context) (QueryAttachment, bool) { + var e QueryAttachment + if o.Query.IsNull() || o.Query.IsUnknown() { + return e, false + } + var v []QueryAttachment + d := o.Query.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuery sets the value of the Query field in GenieAttachment. +func (o *GenieAttachment) SetQuery(ctx context.Context, v QueryAttachment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query"] + o.Query = types.ListValueMust(t, vs) +} + +// GetText returns the value of the Text field in GenieAttachment as +// a TextAttachment value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieAttachment) GetText(ctx context.Context) (TextAttachment, bool) { + var e TextAttachment + if o.Text.IsNull() || o.Text.IsUnknown() { + return e, false + } + var v []TextAttachment + d := o.Text.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetText sets the value of the Text field in GenieAttachment. +func (o *GenieAttachment) SetText(ctx context.Context, v TextAttachment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["text"] + o.Text = types.ListValueMust(t, vs) +} + type GenieConversation struct { // Timestamp when the message was created CreatedTimestamp types.Int64 `tfsdk:"created_timestamp" tf:"optional"` @@ -837,7 +967,7 @@ func (newState *GenieGetMessageQueryResultResponse) SyncEffectiveFieldsDuringRea // SDK values. func (a GenieGetMessageQueryResultResponse) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "statement_response": reflect.TypeOf(sql.StatementResponse{}), + "statement_response": reflect.TypeOf(sql_tf.StatementResponse{}), } } @@ -863,6 +993,32 @@ func (o GenieGetMessageQueryResultResponse) Type(ctx context.Context) attr.Type } } +// GetStatementResponse returns the value of the StatementResponse field in GenieGetMessageQueryResultResponse as +// a sql_tf.StatementResponse value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieGetMessageQueryResultResponse) GetStatementResponse(ctx context.Context) (sql_tf.StatementResponse, bool) { + var e sql_tf.StatementResponse + if o.StatementResponse.IsNull() || o.StatementResponse.IsUnknown() { + return e, false + } + var v []sql_tf.StatementResponse + d := o.StatementResponse.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatementResponse sets the value of the StatementResponse field in GenieGetMessageQueryResultResponse. +func (o *GenieGetMessageQueryResultResponse) SetStatementResponse(ctx context.Context, v sql_tf.StatementResponse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statement_response"] + o.StatementResponse = types.ListValueMust(t, vs) +} + type GenieMessage struct { // AI produced response to the message Attachments types.List `tfsdk:"attachments" tf:"optional"` @@ -970,6 +1126,83 @@ func (o GenieMessage) Type(ctx context.Context) attr.Type { } } +// GetAttachments returns the value of the Attachments field in GenieMessage as +// a slice of GenieAttachment values. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieMessage) GetAttachments(ctx context.Context) ([]GenieAttachment, bool) { + if o.Attachments.IsNull() || o.Attachments.IsUnknown() { + return nil, false + } + var v []GenieAttachment + d := o.Attachments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAttachments sets the value of the Attachments field in GenieMessage. +func (o *GenieMessage) SetAttachments(ctx context.Context, v []GenieAttachment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["attachments"] + o.Attachments = types.ListValueMust(t, vs) +} + +// GetError returns the value of the Error field in GenieMessage as +// a MessageError value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieMessage) GetError(ctx context.Context) (MessageError, bool) { + var e MessageError + if o.Error.IsNull() || o.Error.IsUnknown() { + return e, false + } + var v []MessageError + d := o.Error.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetError sets the value of the Error field in GenieMessage. +func (o *GenieMessage) SetError(ctx context.Context, v MessageError) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error"] + o.Error = types.ListValueMust(t, vs) +} + +// GetQueryResult returns the value of the QueryResult field in GenieMessage as +// a Result value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieMessage) GetQueryResult(ctx context.Context) (Result, bool) { + var e Result + if o.QueryResult.IsNull() || o.QueryResult.IsUnknown() { + return e, false + } + var v []Result + d := o.QueryResult.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueryResult sets the value of the QueryResult field in GenieMessage. +func (o *GenieMessage) SetQueryResult(ctx context.Context, v Result) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_result"] + o.QueryResult = types.ListValueMust(t, vs) +} + type GenieStartConversationMessageRequest struct { // The text of the message that starts the conversation. Content types.String `tfsdk:"content" tf:""` @@ -1077,6 +1310,58 @@ func (o GenieStartConversationResponse) Type(ctx context.Context) attr.Type { } } +// GetConversation returns the value of the Conversation field in GenieStartConversationResponse as +// a GenieConversation value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieStartConversationResponse) GetConversation(ctx context.Context) (GenieConversation, bool) { + var e GenieConversation + if o.Conversation.IsNull() || o.Conversation.IsUnknown() { + return e, false + } + var v []GenieConversation + d := o.Conversation.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConversation sets the value of the Conversation field in GenieStartConversationResponse. +func (o *GenieStartConversationResponse) SetConversation(ctx context.Context, v GenieConversation) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["conversation"] + o.Conversation = types.ListValueMust(t, vs) +} + +// GetMessage returns the value of the Message field in GenieStartConversationResponse as +// a GenieMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *GenieStartConversationResponse) GetMessage(ctx context.Context) (GenieMessage, bool) { + var e GenieMessage + if o.Message.IsNull() || o.Message.IsUnknown() { + return e, false + } + var v []GenieMessage + d := o.Message.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMessage sets the value of the Message field in GenieStartConversationResponse. +func (o *GenieStartConversationResponse) SetMessage(ctx context.Context, v GenieMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["message"] + o.Message = types.ListValueMust(t, vs) +} + // Get dashboard type GetDashboardRequest struct { // UUID identifying the dashboard. @@ -1368,6 +1653,31 @@ func (o ListDashboardsResponse) Type(ctx context.Context) attr.Type { } } +// GetDashboards returns the value of the Dashboards field in ListDashboardsResponse as +// a slice of Dashboard values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListDashboardsResponse) GetDashboards(ctx context.Context) ([]Dashboard, bool) { + if o.Dashboards.IsNull() || o.Dashboards.IsUnknown() { + return nil, false + } + var v []Dashboard + d := o.Dashboards.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDashboards sets the value of the Dashboards field in ListDashboardsResponse. +func (o *ListDashboardsResponse) SetDashboards(ctx context.Context, v []Dashboard) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dashboards"] + o.Dashboards = types.ListValueMust(t, vs) +} + // List dashboard schedules type ListSchedulesRequest struct { // UUID identifying the dashboard to which the schedules belongs. @@ -1472,6 +1782,31 @@ func (o ListSchedulesResponse) Type(ctx context.Context) attr.Type { } } +// GetSchedules returns the value of the Schedules field in ListSchedulesResponse as +// a slice of Schedule values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListSchedulesResponse) GetSchedules(ctx context.Context) ([]Schedule, bool) { + if o.Schedules.IsNull() || o.Schedules.IsUnknown() { + return nil, false + } + var v []Schedule + d := o.Schedules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchedules sets the value of the Schedules field in ListSchedulesResponse. +func (o *ListSchedulesResponse) SetSchedules(ctx context.Context, v []Schedule) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedules"] + o.Schedules = types.ListValueMust(t, vs) +} + // List schedule subscriptions type ListSubscriptionsRequest struct { // UUID identifying the dashboard which the subscriptions belongs. @@ -1580,6 +1915,31 @@ func (o ListSubscriptionsResponse) Type(ctx context.Context) attr.Type { } } +// GetSubscriptions returns the value of the Subscriptions field in ListSubscriptionsResponse as +// a slice of Subscription values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListSubscriptionsResponse) GetSubscriptions(ctx context.Context) ([]Subscription, bool) { + if o.Subscriptions.IsNull() || o.Subscriptions.IsUnknown() { + return nil, false + } + var v []Subscription + d := o.Subscriptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSubscriptions sets the value of the Subscriptions field in ListSubscriptionsResponse. +func (o *ListSubscriptionsResponse) SetSubscriptions(ctx context.Context, v []Subscription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriptions"] + o.Subscriptions = types.ListValueMust(t, vs) +} + type MessageError struct { Error types.String `tfsdk:"error" tf:"optional"` @@ -1984,6 +2344,32 @@ func (o Schedule) Type(ctx context.Context) attr.Type { } } +// GetCronSchedule returns the value of the CronSchedule field in Schedule as +// a CronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *Schedule) GetCronSchedule(ctx context.Context) (CronSchedule, bool) { + var e CronSchedule + if o.CronSchedule.IsNull() || o.CronSchedule.IsUnknown() { + return e, false + } + var v []CronSchedule + d := o.CronSchedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCronSchedule sets the value of the CronSchedule field in Schedule. +func (o *Schedule) SetCronSchedule(ctx context.Context, v CronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cron_schedule"] + o.CronSchedule = types.ListValueMust(t, vs) +} + type Subscriber struct { // The destination to receive the subscription email. This parameter is // mutually exclusive with `user_subscriber`. @@ -2039,6 +2425,58 @@ func (o Subscriber) Type(ctx context.Context) attr.Type { } } +// GetDestinationSubscriber returns the value of the DestinationSubscriber field in Subscriber as +// a SubscriptionSubscriberDestination value. +// If the field is unknown or null, the boolean return value is false. +func (o *Subscriber) GetDestinationSubscriber(ctx context.Context) (SubscriptionSubscriberDestination, bool) { + var e SubscriptionSubscriberDestination + if o.DestinationSubscriber.IsNull() || o.DestinationSubscriber.IsUnknown() { + return e, false + } + var v []SubscriptionSubscriberDestination + d := o.DestinationSubscriber.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDestinationSubscriber sets the value of the DestinationSubscriber field in Subscriber. +func (o *Subscriber) SetDestinationSubscriber(ctx context.Context, v SubscriptionSubscriberDestination) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["destination_subscriber"] + o.DestinationSubscriber = types.ListValueMust(t, vs) +} + +// GetUserSubscriber returns the value of the UserSubscriber field in Subscriber as +// a SubscriptionSubscriberUser value. +// If the field is unknown or null, the boolean return value is false. +func (o *Subscriber) GetUserSubscriber(ctx context.Context) (SubscriptionSubscriberUser, bool) { + var e SubscriptionSubscriberUser + if o.UserSubscriber.IsNull() || o.UserSubscriber.IsUnknown() { + return e, false + } + var v []SubscriptionSubscriberUser + d := o.UserSubscriber.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUserSubscriber sets the value of the UserSubscriber field in Subscriber. +func (o *Subscriber) SetUserSubscriber(ctx context.Context, v SubscriptionSubscriberUser) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["user_subscriber"] + o.UserSubscriber = types.ListValueMust(t, vs) +} + type Subscription struct { // A timestamp indicating when the subscription was created. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` @@ -2117,6 +2555,32 @@ func (o Subscription) Type(ctx context.Context) attr.Type { } } +// GetSubscriber returns the value of the Subscriber field in Subscription as +// a Subscriber value. +// If the field is unknown or null, the boolean return value is false. +func (o *Subscription) GetSubscriber(ctx context.Context) (Subscriber, bool) { + var e Subscriber + if o.Subscriber.IsNull() || o.Subscriber.IsUnknown() { + return e, false + } + var v []Subscriber + d := o.Subscriber.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSubscriber sets the value of the Subscriber field in Subscription. +func (o *Subscription) SetSubscriber(ctx context.Context, v Subscriber) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriber"] + o.Subscriber = types.ListValueMust(t, vs) +} + type SubscriptionSubscriberDestination struct { // The canonical identifier of the destination to receive email // notification. @@ -2456,6 +2920,32 @@ func (o UpdateDashboardRequest) Type(ctx context.Context) attr.Type { } } +// GetDashboard returns the value of the Dashboard field in UpdateDashboardRequest as +// a Dashboard value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateDashboardRequest) GetDashboard(ctx context.Context) (Dashboard, bool) { + var e Dashboard + if o.Dashboard.IsNull() || o.Dashboard.IsUnknown() { + return e, false + } + var v []Dashboard + d := o.Dashboard.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDashboard sets the value of the Dashboard field in UpdateDashboardRequest. +func (o *UpdateDashboardRequest) SetDashboard(ctx context.Context, v Dashboard) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dashboard"] + o.Dashboard = types.ListValueMust(t, vs) +} + // Update dashboard schedule type UpdateScheduleRequest struct { // UUID identifying the dashboard to which the schedule belongs. @@ -2511,18 +3001,28 @@ func (o UpdateScheduleRequest) Type(ctx context.Context) attr.Type { } } -// MesssageStatus. The possible values are: * `FETCHING_METADATA`: Fetching -// metadata from the data sources. * `FILTERING_CONTEXT`: Running smart context -// step to determine relevant context. * `ASKING_AI`: Waiting for the LLM to -// respond to the users question. * `EXECUTING_QUERY`: Executing AI provided SQL -// query. Get the SQL query result by calling -// [getMessageQueryResult](:method:genie/getMessageQueryResult) API. -// **Important: The message status will stay in the `EXECUTING_QUERY` until a -// client calls [getMessageQueryResult](:method:genie/getMessageQueryResult)**. -// * `FAILED`: Generating a response or the executing the query failed. Please -// see `error` field. * `COMPLETED`: Message processing is completed. Results -// are in the `attachments` field. Get the SQL query result by calling -// [getMessageQueryResult](:method:genie/getMessageQueryResult) API. * -// `SUBMITTED`: Message has been submitted. * `QUERY_RESULT_EXPIRED`: SQL result -// is not available anymore. The user needs to execute the query again. * -// `CANCELLED`: Message has been cancelled. +// GetSchedule returns the value of the Schedule field in UpdateScheduleRequest as +// a Schedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateScheduleRequest) GetSchedule(ctx context.Context) (Schedule, bool) { + var e Schedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []Schedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in UpdateScheduleRequest. +func (o *UpdateScheduleRequest) SetSchedule(ctx context.Context, v Schedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 37fe8b3854..2a7f69d1aa 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -1139,6 +1140,31 @@ func (o ListDirectoryResponse) Type(ctx context.Context) attr.Type { } } +// GetContents returns the value of the Contents field in ListDirectoryResponse as +// a slice of DirectoryEntry values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListDirectoryResponse) GetContents(ctx context.Context) ([]DirectoryEntry, bool) { + if o.Contents.IsNull() || o.Contents.IsUnknown() { + return nil, false + } + var v []DirectoryEntry + d := o.Contents.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetContents sets the value of the Contents field in ListDirectoryResponse. +func (o *ListDirectoryResponse) SetContents(ctx context.Context, v []DirectoryEntry) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["contents"] + o.Contents = types.ListValueMust(t, vs) +} + type ListStatusResponse struct { // A list of FileInfo's that describe contents of directory or file. See // example above. @@ -1186,6 +1212,31 @@ func (o ListStatusResponse) Type(ctx context.Context) attr.Type { } } +// GetFiles returns the value of the Files field in ListStatusResponse as +// a slice of FileInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListStatusResponse) GetFiles(ctx context.Context) ([]FileInfo, bool) { + if o.Files.IsNull() || o.Files.IsUnknown() { + return nil, false + } + var v []FileInfo + d := o.Files.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFiles sets the value of the Files field in ListStatusResponse. +func (o *ListStatusResponse) SetFiles(ctx context.Context, v []FileInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["files"] + o.Files = types.ListValueMust(t, vs) +} + type MkDirs struct { // The path of the new directory. The path should be the absolute DBFS path. Path types.String `tfsdk:"path" tf:""` diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 6c9095fa2f..a199c3cbc9 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -135,6 +136,31 @@ func (o AccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in AccessControlResponse as +// a slice of Permission values. +// If the field is unknown or null, the boolean return value is false. +func (o *AccessControlResponse) GetAllPermissions(ctx context.Context) ([]Permission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []Permission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in AccessControlResponse. +func (o *AccessControlResponse) SetAllPermissions(ctx context.Context, v []Permission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type ComplexValue struct { Display types.String `tfsdk:"display" tf:"optional"` @@ -821,6 +847,31 @@ func (o GetAssignableRolesForResourceResponse) Type(ctx context.Context) attr.Ty } } +// GetRoles returns the value of the Roles field in GetAssignableRolesForResourceResponse as +// a slice of Role values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetAssignableRolesForResourceResponse) GetRoles(ctx context.Context) ([]Role, bool) { + if o.Roles.IsNull() || o.Roles.IsUnknown() { + return nil, false + } + var v []Role + d := o.Roles.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRoles sets the value of the Roles field in GetAssignableRolesForResourceResponse. +func (o *GetAssignableRolesForResourceResponse) SetRoles(ctx context.Context, v []Role) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + o.Roles = types.ListValueMust(t, vs) +} + // Get group details type GetGroupRequest struct { // Unique ID for a group in the Databricks workspace. @@ -910,6 +961,31 @@ func (o GetPasswordPermissionLevelsResponse) Type(ctx context.Context) attr.Type } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetPasswordPermissionLevelsResponse as +// a slice of PasswordPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPasswordPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]PasswordPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []PasswordPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetPasswordPermissionLevelsResponse. +func (o *GetPasswordPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []PasswordPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get object permission levels type GetPermissionLevelsRequest struct { // @@ -1003,6 +1079,31 @@ func (o GetPermissionLevelsResponse) Type(ctx context.Context) attr.Type { } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetPermissionLevelsResponse as +// a slice of PermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]PermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []PermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetPermissionLevelsResponse. +func (o *GetPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []PermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get object permissions type GetPermissionRequest struct { // The id of the request object. @@ -1322,6 +1423,31 @@ func (o GrantRule) Type(ctx context.Context) attr.Type { } } +// GetPrincipals returns the value of the Principals field in GrantRule as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GrantRule) GetPrincipals(ctx context.Context) ([]types.String, bool) { + if o.Principals.IsNull() || o.Principals.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Principals.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrincipals sets the value of the Principals field in GrantRule. +func (o *GrantRule) SetPrincipals(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["principals"] + o.Principals = types.ListValueMust(t, vs) +} + type Group struct { // String that represents a human-readable group name DisplayName types.String `tfsdk:"displayName" tf:"optional"` @@ -1418,6 +1544,157 @@ func (o Group) Type(ctx context.Context) attr.Type { } } +// GetEntitlements returns the value of the Entitlements field in Group as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *Group) GetEntitlements(ctx context.Context) ([]ComplexValue, bool) { + if o.Entitlements.IsNull() || o.Entitlements.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Entitlements.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEntitlements sets the value of the Entitlements field in Group. +func (o *Group) SetEntitlements(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["entitlements"] + o.Entitlements = types.ListValueMust(t, vs) +} + +// GetGroups returns the value of the Groups field in Group as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *Group) GetGroups(ctx context.Context) ([]ComplexValue, bool) { + if o.Groups.IsNull() || o.Groups.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Groups.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGroups sets the value of the Groups field in Group. +func (o *Group) SetGroups(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["groups"] + o.Groups = types.ListValueMust(t, vs) +} + +// GetMembers returns the value of the Members field in Group as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *Group) GetMembers(ctx context.Context) ([]ComplexValue, bool) { + if o.Members.IsNull() || o.Members.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Members.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMembers sets the value of the Members field in Group. +func (o *Group) SetMembers(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["members"] + o.Members = types.ListValueMust(t, vs) +} + +// GetMeta returns the value of the Meta field in Group as +// a ResourceMeta value. +// If the field is unknown or null, the boolean return value is false. +func (o *Group) GetMeta(ctx context.Context) (ResourceMeta, bool) { + var e ResourceMeta + if o.Meta.IsNull() || o.Meta.IsUnknown() { + return e, false + } + var v []ResourceMeta + d := o.Meta.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMeta sets the value of the Meta field in Group. +func (o *Group) SetMeta(ctx context.Context, v ResourceMeta) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["meta"] + o.Meta = types.ListValueMust(t, vs) +} + +// GetRoles returns the value of the Roles field in Group as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *Group) GetRoles(ctx context.Context) ([]ComplexValue, bool) { + if o.Roles.IsNull() || o.Roles.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Roles.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRoles sets the value of the Roles field in Group. +func (o *Group) SetRoles(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + o.Roles = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in Group as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Group) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in Group. +func (o *Group) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + // List group details type ListAccountGroupsRequest struct { // Comma-separated list of attributes to return in response. @@ -1777,6 +2054,56 @@ func (o ListGroupsResponse) Type(ctx context.Context) attr.Type { } } +// GetResources returns the value of the Resources field in ListGroupsResponse as +// a slice of Group values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListGroupsResponse) GetResources(ctx context.Context) ([]Group, bool) { + if o.Resources.IsNull() || o.Resources.IsUnknown() { + return nil, false + } + var v []Group + d := o.Resources.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResources sets the value of the Resources field in ListGroupsResponse. +func (o *ListGroupsResponse) SetResources(ctx context.Context, v []Group) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Resources"] + o.Resources = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in ListGroupsResponse as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListGroupsResponse) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in ListGroupsResponse. +func (o *ListGroupsResponse) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + type ListServicePrincipalResponse struct { // Total results returned in the response. ItemsPerPage types.Int64 `tfsdk:"itemsPerPage" tf:"optional"` @@ -1843,6 +2170,56 @@ func (o ListServicePrincipalResponse) Type(ctx context.Context) attr.Type { } } +// GetResources returns the value of the Resources field in ListServicePrincipalResponse as +// a slice of ServicePrincipal values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListServicePrincipalResponse) GetResources(ctx context.Context) ([]ServicePrincipal, bool) { + if o.Resources.IsNull() || o.Resources.IsUnknown() { + return nil, false + } + var v []ServicePrincipal + d := o.Resources.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResources sets the value of the Resources field in ListServicePrincipalResponse. +func (o *ListServicePrincipalResponse) SetResources(ctx context.Context, v []ServicePrincipal) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Resources"] + o.Resources = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in ListServicePrincipalResponse as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListServicePrincipalResponse) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in ListServicePrincipalResponse. +func (o *ListServicePrincipalResponse) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + // List service principals type ListServicePrincipalsRequest struct { // Comma-separated list of attributes to return in response. @@ -2056,6 +2433,56 @@ func (o ListUsersResponse) Type(ctx context.Context) attr.Type { } } +// GetResources returns the value of the Resources field in ListUsersResponse as +// a slice of User values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListUsersResponse) GetResources(ctx context.Context) ([]User, bool) { + if o.Resources.IsNull() || o.Resources.IsUnknown() { + return nil, false + } + var v []User + d := o.Resources.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResources sets the value of the Resources field in ListUsersResponse. +func (o *ListUsersResponse) SetResources(ctx context.Context, v []User) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Resources"] + o.Resources = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in ListUsersResponse as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListUsersResponse) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in ListUsersResponse. +func (o *ListUsersResponse) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + // Get permission assignments type ListWorkspaceAssignmentRequest struct { // The workspace ID for the account. @@ -2295,6 +2722,31 @@ func (o ObjectPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ObjectPermissions as +// a slice of AccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *ObjectPermissions) GetAccessControlList(ctx context.Context) ([]AccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ObjectPermissions. +func (o *ObjectPermissions) SetAccessControlList(ctx context.Context, v []AccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type PartialUpdate struct { // Unique ID for a user in the Databricks workspace. Id types.String `tfsdk:"-"` @@ -2353,6 +2805,56 @@ func (o PartialUpdate) Type(ctx context.Context) attr.Type { } } +// GetOperations returns the value of the Operations field in PartialUpdate as +// a slice of Patch values. +// If the field is unknown or null, the boolean return value is false. +func (o *PartialUpdate) GetOperations(ctx context.Context) ([]Patch, bool) { + if o.Operations.IsNull() || o.Operations.IsUnknown() { + return nil, false + } + var v []Patch + d := o.Operations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOperations sets the value of the Operations field in PartialUpdate. +func (o *PartialUpdate) SetOperations(ctx context.Context, v []Patch) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Operations"] + o.Operations = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in PartialUpdate as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PartialUpdate) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in PartialUpdate. +func (o *PartialUpdate) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + type PasswordAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2469,6 +2971,31 @@ func (o PasswordAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in PasswordAccessControlResponse as +// a slice of PasswordPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *PasswordAccessControlResponse) GetAllPermissions(ctx context.Context) ([]PasswordPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []PasswordPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in PasswordAccessControlResponse. +func (o *PasswordAccessControlResponse) SetAllPermissions(ctx context.Context, v []PasswordPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type PasswordPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2522,6 +3049,31 @@ func (o PasswordPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in PasswordPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PasswordPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in PasswordPermission. +func (o *PasswordPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type PasswordPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -2575,6 +3127,31 @@ func (o PasswordPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in PasswordPermissions as +// a slice of PasswordAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *PasswordPermissions) GetAccessControlList(ctx context.Context) ([]PasswordAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []PasswordAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in PasswordPermissions. +func (o *PasswordPermissions) SetAccessControlList(ctx context.Context, v []PasswordAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type PasswordPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2665,6 +3242,31 @@ func (o PasswordPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in PasswordPermissionsRequest as +// a slice of PasswordAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *PasswordPermissionsRequest) GetAccessControlList(ctx context.Context) ([]PasswordAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []PasswordAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in PasswordPermissionsRequest. +func (o *PasswordPermissionsRequest) SetAccessControlList(ctx context.Context, v []PasswordAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type Patch struct { // Type of patch operation. Op types.String `tfsdk:"op" tf:"optional"` @@ -2804,6 +3406,31 @@ func (o Permission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in Permission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Permission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in Permission. +func (o *Permission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + // The output format for existing workspace PermissionAssignment records, which // contains some info for user consumption. type PermissionAssignment struct { @@ -2863,6 +3490,57 @@ func (o PermissionAssignment) Type(ctx context.Context) attr.Type { } } +// GetPermissions returns the value of the Permissions field in PermissionAssignment as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionAssignment) GetPermissions(ctx context.Context) ([]types.String, bool) { + if o.Permissions.IsNull() || o.Permissions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Permissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissions sets the value of the Permissions field in PermissionAssignment. +func (o *PermissionAssignment) SetPermissions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions"] + o.Permissions = types.ListValueMust(t, vs) +} + +// GetPrincipal returns the value of the Principal field in PermissionAssignment as +// a PrincipalOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionAssignment) GetPrincipal(ctx context.Context) (PrincipalOutput, bool) { + var e PrincipalOutput + if o.Principal.IsNull() || o.Principal.IsUnknown() { + return e, false + } + var v []PrincipalOutput + d := o.Principal.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPrincipal sets the value of the Principal field in PermissionAssignment. +func (o *PermissionAssignment) SetPrincipal(ctx context.Context, v PrincipalOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["principal"] + o.Principal = types.ListValueMust(t, vs) +} + type PermissionAssignments struct { // Array of permissions assignments defined for a workspace. PermissionAssignments types.List `tfsdk:"permission_assignments" tf:"optional"` @@ -2909,6 +3587,31 @@ func (o PermissionAssignments) Type(ctx context.Context) attr.Type { } } +// GetPermissionAssignments returns the value of the PermissionAssignments field in PermissionAssignments as +// a slice of PermissionAssignment values. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionAssignments) GetPermissionAssignments(ctx context.Context) ([]PermissionAssignment, bool) { + if o.PermissionAssignments.IsNull() || o.PermissionAssignments.IsUnknown() { + return nil, false + } + var v []PermissionAssignment + d := o.PermissionAssignments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionAssignments sets the value of the PermissionAssignments field in PermissionAssignments. +func (o *PermissionAssignments) SetPermissionAssignments(ctx context.Context, v []PermissionAssignment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_assignments"] + o.PermissionAssignments = types.ListValueMust(t, vs) +} + type PermissionOutput struct { // The results of a permissions query. Description types.String `tfsdk:"description" tf:"optional"` @@ -3057,6 +3760,31 @@ func (o PermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in PermissionsRequest as +// a slice of AccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *PermissionsRequest) GetAccessControlList(ctx context.Context) ([]AccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in PermissionsRequest. +func (o *PermissionsRequest) SetAccessControlList(ctx context.Context, v []AccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + // Information about the principal assigned to the workspace. type PrincipalOutput struct { // The display name of the principal. @@ -3256,6 +3984,31 @@ func (o RuleSetResponse) Type(ctx context.Context) attr.Type { } } +// GetGrantRules returns the value of the GrantRules field in RuleSetResponse as +// a slice of GrantRule values. +// If the field is unknown or null, the boolean return value is false. +func (o *RuleSetResponse) GetGrantRules(ctx context.Context) ([]GrantRule, bool) { + if o.GrantRules.IsNull() || o.GrantRules.IsUnknown() { + return nil, false + } + var v []GrantRule + d := o.GrantRules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGrantRules sets the value of the GrantRules field in RuleSetResponse. +func (o *RuleSetResponse) SetGrantRules(ctx context.Context, v []GrantRule) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["grant_rules"] + o.GrantRules = types.ListValueMust(t, vs) +} + type RuleSetUpdateRequest struct { // The expected etag of the rule set to update. The update will fail if the // value does not match the value that is stored in account access control @@ -3312,6 +4065,31 @@ func (o RuleSetUpdateRequest) Type(ctx context.Context) attr.Type { } } +// GetGrantRules returns the value of the GrantRules field in RuleSetUpdateRequest as +// a slice of GrantRule values. +// If the field is unknown or null, the boolean return value is false. +func (o *RuleSetUpdateRequest) GetGrantRules(ctx context.Context) ([]GrantRule, bool) { + if o.GrantRules.IsNull() || o.GrantRules.IsUnknown() { + return nil, false + } + var v []GrantRule + d := o.GrantRules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGrantRules sets the value of the GrantRules field in RuleSetUpdateRequest. +func (o *RuleSetUpdateRequest) SetGrantRules(ctx context.Context, v []GrantRule) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["grant_rules"] + o.GrantRules = types.ListValueMust(t, vs) +} + type ServicePrincipal struct { // If this user is active Active types.Bool `tfsdk:"active" tf:"optional"` @@ -3402,6 +4180,106 @@ func (o ServicePrincipal) Type(ctx context.Context) attr.Type { } } +// GetEntitlements returns the value of the Entitlements field in ServicePrincipal as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServicePrincipal) GetEntitlements(ctx context.Context) ([]ComplexValue, bool) { + if o.Entitlements.IsNull() || o.Entitlements.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Entitlements.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEntitlements sets the value of the Entitlements field in ServicePrincipal. +func (o *ServicePrincipal) SetEntitlements(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["entitlements"] + o.Entitlements = types.ListValueMust(t, vs) +} + +// GetGroups returns the value of the Groups field in ServicePrincipal as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServicePrincipal) GetGroups(ctx context.Context) ([]ComplexValue, bool) { + if o.Groups.IsNull() || o.Groups.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Groups.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGroups sets the value of the Groups field in ServicePrincipal. +func (o *ServicePrincipal) SetGroups(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["groups"] + o.Groups = types.ListValueMust(t, vs) +} + +// GetRoles returns the value of the Roles field in ServicePrincipal as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServicePrincipal) GetRoles(ctx context.Context) ([]ComplexValue, bool) { + if o.Roles.IsNull() || o.Roles.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Roles.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRoles sets the value of the Roles field in ServicePrincipal. +func (o *ServicePrincipal) SetRoles(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + o.Roles = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in ServicePrincipal as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServicePrincipal) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in ServicePrincipal. +func (o *ServicePrincipal) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + type UpdateResponse struct { } @@ -3488,6 +4366,32 @@ func (o UpdateRuleSetRequest) Type(ctx context.Context) attr.Type { } } +// GetRuleSet returns the value of the RuleSet field in UpdateRuleSetRequest as +// a RuleSetUpdateRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRuleSetRequest) GetRuleSet(ctx context.Context) (RuleSetUpdateRequest, bool) { + var e RuleSetUpdateRequest + if o.RuleSet.IsNull() || o.RuleSet.IsUnknown() { + return e, false + } + var v []RuleSetUpdateRequest + d := o.RuleSet.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRuleSet sets the value of the RuleSet field in UpdateRuleSetRequest. +func (o *UpdateRuleSetRequest) SetRuleSet(ctx context.Context, v RuleSetUpdateRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rule_set"] + o.RuleSet = types.ListValueMust(t, vs) +} + type UpdateWorkspaceAssignments struct { // Array of permissions assignments to update on the workspace. Valid values // are "USER" and "ADMIN" (case-sensitive). If both "USER" and "ADMIN" are @@ -3547,6 +4451,31 @@ func (o UpdateWorkspaceAssignments) Type(ctx context.Context) attr.Type { } } +// GetPermissions returns the value of the Permissions field in UpdateWorkspaceAssignments as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateWorkspaceAssignments) GetPermissions(ctx context.Context) ([]types.String, bool) { + if o.Permissions.IsNull() || o.Permissions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Permissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissions sets the value of the Permissions field in UpdateWorkspaceAssignments. +func (o *UpdateWorkspaceAssignments) SetPermissions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions"] + o.Permissions = types.ListValueMust(t, vs) +} + type User struct { // If this user is active Active types.Bool `tfsdk:"active" tf:"optional"` @@ -3657,6 +4586,157 @@ func (o User) Type(ctx context.Context) attr.Type { } } +// GetEmails returns the value of the Emails field in User as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *User) GetEmails(ctx context.Context) ([]ComplexValue, bool) { + if o.Emails.IsNull() || o.Emails.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Emails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmails sets the value of the Emails field in User. +func (o *User) SetEmails(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["emails"] + o.Emails = types.ListValueMust(t, vs) +} + +// GetEntitlements returns the value of the Entitlements field in User as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *User) GetEntitlements(ctx context.Context) ([]ComplexValue, bool) { + if o.Entitlements.IsNull() || o.Entitlements.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Entitlements.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEntitlements sets the value of the Entitlements field in User. +func (o *User) SetEntitlements(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["entitlements"] + o.Entitlements = types.ListValueMust(t, vs) +} + +// GetGroups returns the value of the Groups field in User as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *User) GetGroups(ctx context.Context) ([]ComplexValue, bool) { + if o.Groups.IsNull() || o.Groups.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Groups.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetGroups sets the value of the Groups field in User. +func (o *User) SetGroups(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["groups"] + o.Groups = types.ListValueMust(t, vs) +} + +// GetName returns the value of the Name field in User as +// a Name value. +// If the field is unknown or null, the boolean return value is false. +func (o *User) GetName(ctx context.Context) (Name, bool) { + var e Name + if o.Name.IsNull() || o.Name.IsUnknown() { + return e, false + } + var v []Name + d := o.Name.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetName sets the value of the Name field in User. +func (o *User) SetName(ctx context.Context, v Name) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["name"] + o.Name = types.ListValueMust(t, vs) +} + +// GetRoles returns the value of the Roles field in User as +// a slice of ComplexValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *User) GetRoles(ctx context.Context) ([]ComplexValue, bool) { + if o.Roles.IsNull() || o.Roles.IsUnknown() { + return nil, false + } + var v []ComplexValue + d := o.Roles.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRoles sets the value of the Roles field in User. +func (o *User) SetRoles(ctx context.Context, v []ComplexValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + o.Roles = types.ListValueMust(t, vs) +} + +// GetSchemas returns the value of the Schemas field in User as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *User) GetSchemas(ctx context.Context) ([]types.String, bool) { + if o.Schemas.IsNull() || o.Schemas.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Schemas.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSchemas sets the value of the Schemas field in User. +func (o *User) SetSchemas(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + o.Schemas = types.ListValueMust(t, vs) +} + type WorkspacePermissions struct { // Array of permissions defined for a workspace. Permissions types.List `tfsdk:"permissions" tf:"optional"` @@ -3703,8 +4783,27 @@ func (o WorkspacePermissions) Type(ctx context.Context) attr.Type { } } -// Permission level - -// Type of patch operation. +// GetPermissions returns the value of the Permissions field in WorkspacePermissions as +// a slice of PermissionOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkspacePermissions) GetPermissions(ctx context.Context) ([]PermissionOutput, bool) { + if o.Permissions.IsNull() || o.Permissions.IsUnknown() { + return nil, false + } + var v []PermissionOutput + d := o.Permissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// Permission level +// SetPermissions sets the value of the Permissions field in WorkspacePermissions. +func (o *WorkspacePermissions) SetPermissions(ctx context.Context, v []PermissionOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions"] + o.Permissions = types.ListValueMust(t, vs) +} diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 138c755101..a9450fe5c9 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -14,7 +14,7 @@ import ( "context" "reflect" - "github.com/databricks/databricks-sdk-go/service/compute" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" @@ -91,6 +91,32 @@ func (o BaseJob) Type(ctx context.Context) attr.Type { } } +// GetSettings returns the value of the Settings field in BaseJob as +// a JobSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseJob) GetSettings(ctx context.Context) (JobSettings, bool) { + var e JobSettings + if o.Settings.IsNull() || o.Settings.IsUnknown() { + return e, false + } + var v []JobSettings + d := o.Settings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSettings sets the value of the Settings field in BaseJob. +func (o *BaseJob) SetSettings(ctx context.Context, v JobSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["settings"] + o.Settings = types.ListValueMust(t, vs) +} + type BaseRun struct { // The sequence number of this run attempt for a triggered job run. The // initial attempt of a run has an attempt_number of 0. If the initial run @@ -355,6 +381,314 @@ func (o BaseRun) Type(ctx context.Context) attr.Type { } } +// GetClusterInstance returns the value of the ClusterInstance field in BaseRun as +// a ClusterInstance value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetClusterInstance(ctx context.Context) (ClusterInstance, bool) { + var e ClusterInstance + if o.ClusterInstance.IsNull() || o.ClusterInstance.IsUnknown() { + return e, false + } + var v []ClusterInstance + d := o.ClusterInstance.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterInstance sets the value of the ClusterInstance field in BaseRun. +func (o *BaseRun) SetClusterInstance(ctx context.Context, v ClusterInstance) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_instance"] + o.ClusterInstance = types.ListValueMust(t, vs) +} + +// GetClusterSpec returns the value of the ClusterSpec field in BaseRun as +// a ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetClusterSpec(ctx context.Context) (ClusterSpec, bool) { + var e ClusterSpec + if o.ClusterSpec.IsNull() || o.ClusterSpec.IsUnknown() { + return e, false + } + var v []ClusterSpec + d := o.ClusterSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterSpec sets the value of the ClusterSpec field in BaseRun. +func (o *BaseRun) SetClusterSpec(ctx context.Context, v ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_spec"] + o.ClusterSpec = types.ListValueMust(t, vs) +} + +// GetGitSource returns the value of the GitSource field in BaseRun as +// a GitSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetGitSource(ctx context.Context) (GitSource, bool) { + var e GitSource + if o.GitSource.IsNull() || o.GitSource.IsUnknown() { + return e, false + } + var v []GitSource + d := o.GitSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitSource sets the value of the GitSource field in BaseRun. +func (o *BaseRun) SetGitSource(ctx context.Context, v GitSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_source"] + o.GitSource = types.ListValueMust(t, vs) +} + +// GetJobClusters returns the value of the JobClusters field in BaseRun as +// a slice of JobCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetJobClusters(ctx context.Context) ([]JobCluster, bool) { + if o.JobClusters.IsNull() || o.JobClusters.IsUnknown() { + return nil, false + } + var v []JobCluster + d := o.JobClusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobClusters sets the value of the JobClusters field in BaseRun. +func (o *BaseRun) SetJobClusters(ctx context.Context, v []JobCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_clusters"] + o.JobClusters = types.ListValueMust(t, vs) +} + +// GetJobParameters returns the value of the JobParameters field in BaseRun as +// a slice of JobParameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetJobParameters(ctx context.Context) ([]JobParameter, bool) { + if o.JobParameters.IsNull() || o.JobParameters.IsUnknown() { + return nil, false + } + var v []JobParameter + d := o.JobParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobParameters sets the value of the JobParameters field in BaseRun. +func (o *BaseRun) SetJobParameters(ctx context.Context, v []JobParameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + o.JobParameters = types.ListValueMust(t, vs) +} + +// GetOverridingParameters returns the value of the OverridingParameters field in BaseRun as +// a RunParameters value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetOverridingParameters(ctx context.Context) (RunParameters, bool) { + var e RunParameters + if o.OverridingParameters.IsNull() || o.OverridingParameters.IsUnknown() { + return e, false + } + var v []RunParameters + d := o.OverridingParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOverridingParameters sets the value of the OverridingParameters field in BaseRun. +func (o *BaseRun) SetOverridingParameters(ctx context.Context, v RunParameters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["overriding_parameters"] + o.OverridingParameters = types.ListValueMust(t, vs) +} + +// GetRepairHistory returns the value of the RepairHistory field in BaseRun as +// a slice of RepairHistoryItem values. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetRepairHistory(ctx context.Context) ([]RepairHistoryItem, bool) { + if o.RepairHistory.IsNull() || o.RepairHistory.IsUnknown() { + return nil, false + } + var v []RepairHistoryItem + d := o.RepairHistory.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRepairHistory sets the value of the RepairHistory field in BaseRun. +func (o *BaseRun) SetRepairHistory(ctx context.Context, v []RepairHistoryItem) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repair_history"] + o.RepairHistory = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in BaseRun as +// a CronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetSchedule(ctx context.Context) (CronSchedule, bool) { + var e CronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []CronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in BaseRun. +func (o *BaseRun) SetSchedule(ctx context.Context, v CronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetState returns the value of the State field in BaseRun as +// a RunState value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetState(ctx context.Context) (RunState, bool) { + var e RunState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []RunState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in BaseRun. +func (o *BaseRun) SetState(ctx context.Context, v RunState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in BaseRun as +// a RunStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetStatus(ctx context.Context) (RunStatus, bool) { + var e RunStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []RunStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in BaseRun. +func (o *BaseRun) SetStatus(ctx context.Context, v RunStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + +// GetTasks returns the value of the Tasks field in BaseRun as +// a slice of RunTask values. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetTasks(ctx context.Context) ([]RunTask, bool) { + if o.Tasks.IsNull() || o.Tasks.IsUnknown() { + return nil, false + } + var v []RunTask + d := o.Tasks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTasks sets the value of the Tasks field in BaseRun. +func (o *BaseRun) SetTasks(ctx context.Context, v []RunTask) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tasks"] + o.Tasks = types.ListValueMust(t, vs) +} + +// GetTriggerInfo returns the value of the TriggerInfo field in BaseRun as +// a TriggerInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *BaseRun) GetTriggerInfo(ctx context.Context) (TriggerInfo, bool) { + var e TriggerInfo + if o.TriggerInfo.IsNull() || o.TriggerInfo.IsUnknown() { + return e, false + } + var v []TriggerInfo + d := o.TriggerInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTriggerInfo sets the value of the TriggerInfo field in BaseRun. +func (o *BaseRun) SetTriggerInfo(ctx context.Context, v TriggerInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger_info"] + o.TriggerInfo = types.ListValueMust(t, vs) +} + type CancelAllRuns struct { // Optional boolean parameter to cancel all queued runs. If no job_id is // provided, all queued runs in the workspace are canceled. @@ -608,8 +942,8 @@ func (newState *ClusterSpec) SyncEffectiveFieldsDuringRead(existingState Cluster // SDK values. func (a ClusterSpec) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "library": reflect.TypeOf(compute.Library{}), - "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "library": reflect.TypeOf(compute_tf.Library{}), + "new_cluster": reflect.TypeOf(compute_tf.ClusterSpec{}), } } @@ -643,6 +977,57 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { } } +// GetLibraries returns the value of the Libraries field in ClusterSpec as +// a slice of compute_tf.Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetLibraries(ctx context.Context) ([]compute_tf.Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []compute_tf.Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in ClusterSpec. +func (o *ClusterSpec) SetLibraries(ctx context.Context, v []compute_tf.Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNewCluster returns the value of the NewCluster field in ClusterSpec as +// a compute_tf.ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterSpec) GetNewCluster(ctx context.Context) (compute_tf.ClusterSpec, bool) { + var e compute_tf.ClusterSpec + if o.NewCluster.IsNull() || o.NewCluster.IsUnknown() { + return e, false + } + var v []compute_tf.ClusterSpec + d := o.NewCluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewCluster sets the value of the NewCluster field in ClusterSpec. +func (o *ClusterSpec) SetNewCluster(ctx context.Context, v compute_tf.ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_cluster"] + o.NewCluster = types.ListValueMust(t, vs) +} + type ConditionTask struct { // The left operand of the condition task. Can be either a string value or a // job state or parameter reference. @@ -988,6 +1373,442 @@ func (o CreateJob) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in CreateJob as +// a slice of JobAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetAccessControlList(ctx context.Context) ([]JobAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []JobAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in CreateJob. +func (o *CreateJob) SetAccessControlList(ctx context.Context, v []JobAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + +// GetContinuous returns the value of the Continuous field in CreateJob as +// a Continuous value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetContinuous(ctx context.Context) (Continuous, bool) { + var e Continuous + if o.Continuous.IsNull() || o.Continuous.IsUnknown() { + return e, false + } + var v []Continuous + d := o.Continuous.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetContinuous sets the value of the Continuous field in CreateJob. +func (o *CreateJob) SetContinuous(ctx context.Context, v Continuous) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["continuous"] + o.Continuous = types.ListValueMust(t, vs) +} + +// GetDeployment returns the value of the Deployment field in CreateJob as +// a JobDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetDeployment(ctx context.Context) (JobDeployment, bool) { + var e JobDeployment + if o.Deployment.IsNull() || o.Deployment.IsUnknown() { + return e, false + } + var v []JobDeployment + d := o.Deployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeployment sets the value of the Deployment field in CreateJob. +func (o *CreateJob) SetDeployment(ctx context.Context, v JobDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment"] + o.Deployment = types.ListValueMust(t, vs) +} + +// GetEmailNotifications returns the value of the EmailNotifications field in CreateJob as +// a JobEmailNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetEmailNotifications(ctx context.Context) (JobEmailNotifications, bool) { + var e JobEmailNotifications + if o.EmailNotifications.IsNull() || o.EmailNotifications.IsUnknown() { + return e, false + } + var v []JobEmailNotifications + d := o.EmailNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEmailNotifications sets the value of the EmailNotifications field in CreateJob. +func (o *CreateJob) SetEmailNotifications(ctx context.Context, v JobEmailNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_notifications"] + o.EmailNotifications = types.ListValueMust(t, vs) +} + +// GetEnvironments returns the value of the Environments field in CreateJob as +// a slice of JobEnvironment values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetEnvironments(ctx context.Context) ([]JobEnvironment, bool) { + if o.Environments.IsNull() || o.Environments.IsUnknown() { + return nil, false + } + var v []JobEnvironment + d := o.Environments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnvironments sets the value of the Environments field in CreateJob. +func (o *CreateJob) SetEnvironments(ctx context.Context, v []JobEnvironment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment"] + o.Environments = types.ListValueMust(t, vs) +} + +// GetGitSource returns the value of the GitSource field in CreateJob as +// a GitSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetGitSource(ctx context.Context) (GitSource, bool) { + var e GitSource + if o.GitSource.IsNull() || o.GitSource.IsUnknown() { + return e, false + } + var v []GitSource + d := o.GitSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitSource sets the value of the GitSource field in CreateJob. +func (o *CreateJob) SetGitSource(ctx context.Context, v GitSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_source"] + o.GitSource = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in CreateJob as +// a JobsHealthRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetHealth(ctx context.Context) (JobsHealthRules, bool) { + var e JobsHealthRules + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []JobsHealthRules + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in CreateJob. +func (o *CreateJob) SetHealth(ctx context.Context, v JobsHealthRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetJobClusters returns the value of the JobClusters field in CreateJob as +// a slice of JobCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetJobClusters(ctx context.Context) ([]JobCluster, bool) { + if o.JobClusters.IsNull() || o.JobClusters.IsUnknown() { + return nil, false + } + var v []JobCluster + d := o.JobClusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobClusters sets the value of the JobClusters field in CreateJob. +func (o *CreateJob) SetJobClusters(ctx context.Context, v []JobCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_cluster"] + o.JobClusters = types.ListValueMust(t, vs) +} + +// GetNotificationSettings returns the value of the NotificationSettings field in CreateJob as +// a JobNotificationSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetNotificationSettings(ctx context.Context) (JobNotificationSettings, bool) { + var e JobNotificationSettings + if o.NotificationSettings.IsNull() || o.NotificationSettings.IsUnknown() { + return e, false + } + var v []JobNotificationSettings + d := o.NotificationSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotificationSettings sets the value of the NotificationSettings field in CreateJob. +func (o *CreateJob) SetNotificationSettings(ctx context.Context, v JobNotificationSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notification_settings"] + o.NotificationSettings = types.ListValueMust(t, vs) +} + +// GetParameters returns the value of the Parameters field in CreateJob as +// a slice of JobParameterDefinition values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetParameters(ctx context.Context) ([]JobParameterDefinition, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []JobParameterDefinition + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in CreateJob. +func (o *CreateJob) SetParameters(ctx context.Context, v []JobParameterDefinition) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameter"] + o.Parameters = types.ListValueMust(t, vs) +} + +// GetQueue returns the value of the Queue field in CreateJob as +// a QueueSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetQueue(ctx context.Context) (QueueSettings, bool) { + var e QueueSettings + if o.Queue.IsNull() || o.Queue.IsUnknown() { + return e, false + } + var v []QueueSettings + d := o.Queue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueue sets the value of the Queue field in CreateJob. +func (o *CreateJob) SetQueue(ctx context.Context, v QueueSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["queue"] + o.Queue = types.ListValueMust(t, vs) +} + +// GetRunAs returns the value of the RunAs field in CreateJob as +// a JobRunAs value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetRunAs(ctx context.Context) (JobRunAs, bool) { + var e JobRunAs + if o.RunAs.IsNull() || o.RunAs.IsUnknown() { + return e, false + } + var v []JobRunAs + d := o.RunAs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunAs sets the value of the RunAs field in CreateJob. +func (o *CreateJob) SetRunAs(ctx context.Context, v JobRunAs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_as"] + o.RunAs = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in CreateJob as +// a CronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetSchedule(ctx context.Context) (CronSchedule, bool) { + var e CronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []CronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in CreateJob. +func (o *CreateJob) SetSchedule(ctx context.Context, v CronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in CreateJob as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetTags(ctx context.Context) (map[string]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateJob. +func (o *CreateJob) SetTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.MapValueMust(t, vs) +} + +// GetTasks returns the value of the Tasks field in CreateJob as +// a slice of Task values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetTasks(ctx context.Context) ([]Task, bool) { + if o.Tasks.IsNull() || o.Tasks.IsUnknown() { + return nil, false + } + var v []Task + d := o.Tasks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTasks sets the value of the Tasks field in CreateJob. +func (o *CreateJob) SetTasks(ctx context.Context, v []Task) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task"] + o.Tasks = types.ListValueMust(t, vs) +} + +// GetTrigger returns the value of the Trigger field in CreateJob as +// a TriggerSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetTrigger(ctx context.Context) (TriggerSettings, bool) { + var e TriggerSettings + if o.Trigger.IsNull() || o.Trigger.IsUnknown() { + return e, false + } + var v []TriggerSettings + d := o.Trigger.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrigger sets the value of the Trigger field in CreateJob. +func (o *CreateJob) SetTrigger(ctx context.Context, v TriggerSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger"] + o.Trigger = types.ListValueMust(t, vs) +} + +// GetWebhookNotifications returns the value of the WebhookNotifications field in CreateJob as +// a WebhookNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateJob) GetWebhookNotifications(ctx context.Context) (WebhookNotifications, bool) { + var e WebhookNotifications + if o.WebhookNotifications.IsNull() || o.WebhookNotifications.IsUnknown() { + return e, false + } + var v []WebhookNotifications + d := o.WebhookNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhookNotifications sets the value of the WebhookNotifications field in CreateJob. +func (o *CreateJob) SetWebhookNotifications(ctx context.Context, v WebhookNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook_notifications"] + o.WebhookNotifications = types.ListValueMust(t, vs) +} + // Job was created successfully type CreateResponse struct { // The canonical identifier for the newly created job. @@ -1140,6 +1961,31 @@ func (o DbtOutput) Type(ctx context.Context) attr.Type { } } +// GetArtifactsHeaders returns the value of the ArtifactsHeaders field in DbtOutput as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DbtOutput) GetArtifactsHeaders(ctx context.Context) (map[string]types.String, bool) { + if o.ArtifactsHeaders.IsNull() || o.ArtifactsHeaders.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.ArtifactsHeaders.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetArtifactsHeaders sets the value of the ArtifactsHeaders field in DbtOutput. +func (o *DbtOutput) SetArtifactsHeaders(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["artifacts_headers"] + o.ArtifactsHeaders = types.MapValueMust(t, vs) +} + type DbtTask struct { // Optional name of the catalog to use. The value is the top level in the // 3-level namespace of Unity Catalog (catalog / schema / relation). The @@ -1230,6 +2076,31 @@ func (o DbtTask) Type(ctx context.Context) attr.Type { } } +// GetCommands returns the value of the Commands field in DbtTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DbtTask) GetCommands(ctx context.Context) ([]types.String, bool) { + if o.Commands.IsNull() || o.Commands.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Commands.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCommands sets the value of the Commands field in DbtTask. +func (o *DbtTask) SetCommands(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["commands"] + o.Commands = types.ListValueMust(t, vs) +} + type DeleteJob struct { // The canonical identifier of the job to delete. This field is required. JobId types.Int64 `tfsdk:"job_id" tf:""` @@ -1557,6 +2428,57 @@ func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { } } +// GetJobClusterChanges returns the value of the JobClusterChanges field in EnforcePolicyComplianceResponse as +// a slice of EnforcePolicyComplianceForJobResponseJobClusterSettingsChange values. +// If the field is unknown or null, the boolean return value is false. +func (o *EnforcePolicyComplianceResponse) GetJobClusterChanges(ctx context.Context) ([]EnforcePolicyComplianceForJobResponseJobClusterSettingsChange, bool) { + if o.JobClusterChanges.IsNull() || o.JobClusterChanges.IsUnknown() { + return nil, false + } + var v []EnforcePolicyComplianceForJobResponseJobClusterSettingsChange + d := o.JobClusterChanges.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobClusterChanges sets the value of the JobClusterChanges field in EnforcePolicyComplianceResponse. +func (o *EnforcePolicyComplianceResponse) SetJobClusterChanges(ctx context.Context, v []EnforcePolicyComplianceForJobResponseJobClusterSettingsChange) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_cluster_changes"] + o.JobClusterChanges = types.ListValueMust(t, vs) +} + +// GetSettings returns the value of the Settings field in EnforcePolicyComplianceResponse as +// a JobSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *EnforcePolicyComplianceResponse) GetSettings(ctx context.Context) (JobSettings, bool) { + var e JobSettings + if o.Settings.IsNull() || o.Settings.IsUnknown() { + return e, false + } + var v []JobSettings + d := o.Settings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSettings sets the value of the Settings field in EnforcePolicyComplianceResponse. +func (o *EnforcePolicyComplianceResponse) SetSettings(ctx context.Context, v JobSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["settings"] + o.Settings = types.ListValueMust(t, vs) +} + // Run was exported successfully. type ExportRunOutput struct { // The exported content in HTML format (one for every view item). To extract @@ -1608,10 +2530,35 @@ func (o ExportRunOutput) Type(ctx context.Context) attr.Type { } } -// Export and retrieve a job run -type ExportRunRequest struct { - // The canonical identifier for the run. This field is required. - RunId types.Int64 `tfsdk:"-"` +// GetViews returns the value of the Views field in ExportRunOutput as +// a slice of ViewItem values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExportRunOutput) GetViews(ctx context.Context) ([]ViewItem, bool) { + if o.Views.IsNull() || o.Views.IsUnknown() { + return nil, false + } + var v []ViewItem + d := o.Views.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetViews sets the value of the Views field in ExportRunOutput. +func (o *ExportRunOutput) SetViews(ctx context.Context, v []ViewItem) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["views"] + o.Views = types.ListValueMust(t, vs) +} + +// Export and retrieve a job run +type ExportRunRequest struct { + // The canonical identifier for the run. This field is required. + RunId types.Int64 `tfsdk:"-"` // Which views to export (CODE, DASHBOARDS, or ALL). Defaults to CODE. ViewsToExport types.String `tfsdk:"-"` } @@ -1764,6 +2711,57 @@ func (o ForEachStats) Type(ctx context.Context) attr.Type { } } +// GetErrorMessageStats returns the value of the ErrorMessageStats field in ForEachStats as +// a slice of ForEachTaskErrorMessageStats values. +// If the field is unknown or null, the boolean return value is false. +func (o *ForEachStats) GetErrorMessageStats(ctx context.Context) ([]ForEachTaskErrorMessageStats, bool) { + if o.ErrorMessageStats.IsNull() || o.ErrorMessageStats.IsUnknown() { + return nil, false + } + var v []ForEachTaskErrorMessageStats + d := o.ErrorMessageStats.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetErrorMessageStats sets the value of the ErrorMessageStats field in ForEachStats. +func (o *ForEachStats) SetErrorMessageStats(ctx context.Context, v []ForEachTaskErrorMessageStats) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error_message_stats"] + o.ErrorMessageStats = types.ListValueMust(t, vs) +} + +// GetTaskRunStats returns the value of the TaskRunStats field in ForEachStats as +// a ForEachTaskTaskRunStats value. +// If the field is unknown or null, the boolean return value is false. +func (o *ForEachStats) GetTaskRunStats(ctx context.Context) (ForEachTaskTaskRunStats, bool) { + var e ForEachTaskTaskRunStats + if o.TaskRunStats.IsNull() || o.TaskRunStats.IsUnknown() { + return e, false + } + var v []ForEachTaskTaskRunStats + d := o.TaskRunStats.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTaskRunStats sets the value of the TaskRunStats field in ForEachStats. +func (o *ForEachStats) SetTaskRunStats(ctx context.Context, v ForEachTaskTaskRunStats) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task_run_stats"] + o.TaskRunStats = types.ListValueMust(t, vs) +} + type ForEachTask struct { // An optional maximum allowed number of concurrent runs of the task. Set // this value if you want to be able to execute multiple runs of the task @@ -1821,6 +2819,32 @@ func (o ForEachTask) Type(ctx context.Context) attr.Type { } } +// GetTask returns the value of the Task field in ForEachTask as +// a Task value. +// If the field is unknown or null, the boolean return value is false. +func (o *ForEachTask) GetTask(ctx context.Context) (Task, bool) { + var e Task + if o.Task.IsNull() || o.Task.IsUnknown() { + return e, false + } + var v []Task + d := o.Task.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTask sets the value of the Task field in ForEachTask. +func (o *ForEachTask) SetTask(ctx context.Context, v Task) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task"] + o.Task = types.ListValueMust(t, vs) +} + type ForEachTaskErrorMessageStats struct { // Describes the count of such error message encountered during the // iterations. @@ -2024,6 +3048,31 @@ func (o GetJobPermissionLevelsResponse) Type(ctx context.Context) attr.Type { } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetJobPermissionLevelsResponse as +// a slice of JobPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetJobPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]JobPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []JobPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetJobPermissionLevelsResponse. +func (o *GetJobPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []JobPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get job permissions type GetJobPermissionsRequest struct { // The job for which to get or manage permissions. @@ -2211,6 +3260,31 @@ func (o GetPolicyComplianceResponse) Type(ctx context.Context) attr.Type { } } +// GetViolations returns the value of the Violations field in GetPolicyComplianceResponse as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPolicyComplianceResponse) GetViolations(ctx context.Context) (map[string]types.String, bool) { + if o.Violations.IsNull() || o.Violations.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Violations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetViolations sets the value of the Violations field in GetPolicyComplianceResponse. +func (o *GetPolicyComplianceResponse) SetViolations(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + o.Violations = types.MapValueMust(t, vs) +} + // Get the output for a single run type GetRunOutputRequest struct { // The canonical identifier for the run. @@ -2446,6 +3520,58 @@ func (o GitSource) Type(ctx context.Context) attr.Type { } } +// GetGitSnapshot returns the value of the GitSnapshot field in GitSource as +// a GitSnapshot value. +// If the field is unknown or null, the boolean return value is false. +func (o *GitSource) GetGitSnapshot(ctx context.Context) (GitSnapshot, bool) { + var e GitSnapshot + if o.GitSnapshot.IsNull() || o.GitSnapshot.IsUnknown() { + return e, false + } + var v []GitSnapshot + d := o.GitSnapshot.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitSnapshot sets the value of the GitSnapshot field in GitSource. +func (o *GitSource) SetGitSnapshot(ctx context.Context, v GitSnapshot) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_snapshot"] + o.GitSnapshot = types.ListValueMust(t, vs) +} + +// GetJobSource returns the value of the JobSource field in GitSource as +// a JobSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *GitSource) GetJobSource(ctx context.Context) (JobSource, bool) { + var e JobSource + if o.JobSource.IsNull() || o.JobSource.IsUnknown() { + return e, false + } + var v []JobSource + d := o.JobSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetJobSource sets the value of the JobSource field in GitSource. +func (o *GitSource) SetJobSource(ctx context.Context, v JobSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_source"] + o.JobSource = types.ListValueMust(t, vs) +} + // Job was retrieved successfully. type Job struct { // The time at which this job was created in epoch milliseconds @@ -2527,6 +3653,32 @@ func (o Job) Type(ctx context.Context) attr.Type { } } +// GetSettings returns the value of the Settings field in Job as +// a JobSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *Job) GetSettings(ctx context.Context) (JobSettings, bool) { + var e JobSettings + if o.Settings.IsNull() || o.Settings.IsUnknown() { + return e, false + } + var v []JobSettings + d := o.Settings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSettings sets the value of the Settings field in Job. +func (o *Job) SetSettings(ctx context.Context, v JobSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["settings"] + o.Settings = types.ListValueMust(t, vs) +} + type JobAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2643,6 +3795,31 @@ func (o JobAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in JobAccessControlResponse as +// a slice of JobPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobAccessControlResponse) GetAllPermissions(ctx context.Context) ([]JobPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []JobPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in JobAccessControlResponse. +func (o *JobAccessControlResponse) SetAllPermissions(ctx context.Context, v []JobPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type JobCluster struct { // A unique name for the job cluster. This field is required and must be // unique within the job. `JobTaskSettings` may refer to this field to @@ -2667,7 +3844,7 @@ func (newState *JobCluster) SyncEffectiveFieldsDuringRead(existingState JobClust // SDK values. func (a JobCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "new_cluster": reflect.TypeOf(compute_tf.ClusterSpec{}), } } @@ -2695,6 +3872,32 @@ func (o JobCluster) Type(ctx context.Context) attr.Type { } } +// GetNewCluster returns the value of the NewCluster field in JobCluster as +// a compute_tf.ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobCluster) GetNewCluster(ctx context.Context) (compute_tf.ClusterSpec, bool) { + var e compute_tf.ClusterSpec + if o.NewCluster.IsNull() || o.NewCluster.IsUnknown() { + return e, false + } + var v []compute_tf.ClusterSpec + d := o.NewCluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewCluster sets the value of the NewCluster field in JobCluster. +func (o *JobCluster) SetNewCluster(ctx context.Context, v compute_tf.ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_cluster"] + o.NewCluster = types.ListValueMust(t, vs) +} + type JobCompliance struct { // Whether this job is in compliance with the latest version of its policy. IsCompliant types.Bool `tfsdk:"is_compliant" tf:"optional"` @@ -2753,6 +3956,31 @@ func (o JobCompliance) Type(ctx context.Context) attr.Type { } } +// GetViolations returns the value of the Violations field in JobCompliance as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobCompliance) GetViolations(ctx context.Context) (map[string]types.String, bool) { + if o.Violations.IsNull() || o.Violations.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Violations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetViolations sets the value of the Violations field in JobCompliance. +func (o *JobCompliance) SetViolations(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + o.Violations = types.MapValueMust(t, vs) +} + type JobDeployment struct { // The kind of deployment that manages the job. // @@ -2900,6 +4128,131 @@ func (o JobEmailNotifications) Type(ctx context.Context) attr.Type { } } +// GetOnDurationWarningThresholdExceeded returns the value of the OnDurationWarningThresholdExceeded field in JobEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobEmailNotifications) GetOnDurationWarningThresholdExceeded(ctx context.Context) ([]types.String, bool) { + if o.OnDurationWarningThresholdExceeded.IsNull() || o.OnDurationWarningThresholdExceeded.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnDurationWarningThresholdExceeded.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnDurationWarningThresholdExceeded sets the value of the OnDurationWarningThresholdExceeded field in JobEmailNotifications. +func (o *JobEmailNotifications) SetOnDurationWarningThresholdExceeded(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_duration_warning_threshold_exceeded"] + o.OnDurationWarningThresholdExceeded = types.ListValueMust(t, vs) +} + +// GetOnFailure returns the value of the OnFailure field in JobEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobEmailNotifications) GetOnFailure(ctx context.Context) ([]types.String, bool) { + if o.OnFailure.IsNull() || o.OnFailure.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnFailure.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnFailure sets the value of the OnFailure field in JobEmailNotifications. +func (o *JobEmailNotifications) SetOnFailure(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + o.OnFailure = types.ListValueMust(t, vs) +} + +// GetOnStart returns the value of the OnStart field in JobEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobEmailNotifications) GetOnStart(ctx context.Context) ([]types.String, bool) { + if o.OnStart.IsNull() || o.OnStart.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnStart.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnStart sets the value of the OnStart field in JobEmailNotifications. +func (o *JobEmailNotifications) SetOnStart(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_start"] + o.OnStart = types.ListValueMust(t, vs) +} + +// GetOnStreamingBacklogExceeded returns the value of the OnStreamingBacklogExceeded field in JobEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobEmailNotifications) GetOnStreamingBacklogExceeded(ctx context.Context) ([]types.String, bool) { + if o.OnStreamingBacklogExceeded.IsNull() || o.OnStreamingBacklogExceeded.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnStreamingBacklogExceeded.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnStreamingBacklogExceeded sets the value of the OnStreamingBacklogExceeded field in JobEmailNotifications. +func (o *JobEmailNotifications) SetOnStreamingBacklogExceeded(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_streaming_backlog_exceeded"] + o.OnStreamingBacklogExceeded = types.ListValueMust(t, vs) +} + +// GetOnSuccess returns the value of the OnSuccess field in JobEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobEmailNotifications) GetOnSuccess(ctx context.Context) ([]types.String, bool) { + if o.OnSuccess.IsNull() || o.OnSuccess.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnSuccess.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnSuccess sets the value of the OnSuccess field in JobEmailNotifications. +func (o *JobEmailNotifications) SetOnSuccess(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_success"] + o.OnSuccess = types.ListValueMust(t, vs) +} + type JobEnvironment struct { // The key of an environment. It has to be unique within a job. EnvironmentKey types.String `tfsdk:"environment_key" tf:""` @@ -2924,7 +4277,7 @@ func (newState *JobEnvironment) SyncEffectiveFieldsDuringRead(existingState JobE // SDK values. func (a JobEnvironment) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "spec": reflect.TypeOf(compute.Environment{}), + "spec": reflect.TypeOf(compute_tf.Environment{}), } } @@ -2952,6 +4305,32 @@ func (o JobEnvironment) Type(ctx context.Context) attr.Type { } } +// GetSpec returns the value of the Spec field in JobEnvironment as +// a compute_tf.Environment value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobEnvironment) GetSpec(ctx context.Context) (compute_tf.Environment, bool) { + var e compute_tf.Environment + if o.Spec.IsNull() || o.Spec.IsUnknown() { + return e, false + } + var v []compute_tf.Environment + d := o.Spec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSpec sets the value of the Spec field in JobEnvironment. +func (o *JobEnvironment) SetSpec(ctx context.Context, v compute_tf.Environment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spec"] + o.Spec = types.ListValueMust(t, vs) +} + type JobNotificationSettings struct { // If true, do not send notifications to recipients specified in // `on_failure` if the run is canceled. @@ -3150,6 +4529,31 @@ func (o JobPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in JobPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in JobPermission. +func (o *JobPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type JobPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -3203,6 +4607,31 @@ func (o JobPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in JobPermissions as +// a slice of JobAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobPermissions) GetAccessControlList(ctx context.Context) ([]JobAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []JobAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in JobPermissions. +func (o *JobPermissions) SetAccessControlList(ctx context.Context, v []JobAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type JobPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -3297,6 +4726,31 @@ func (o JobPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in JobPermissionsRequest as +// a slice of JobAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobPermissionsRequest) GetAccessControlList(ctx context.Context) ([]JobAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []JobAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in JobPermissionsRequest. +func (o *JobPermissionsRequest) SetAccessControlList(ctx context.Context, v []JobAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + // Write-only setting. Specifies the user, service principal or group that the // job/pipeline runs as. If not specified, the job/pipeline runs as the user who // created the job/pipeline. @@ -3585,116 +5039,527 @@ func (o JobSettings) Type(ctx context.Context) attr.Type { } } -// The source of the job specification in the remote repository when the job is -// source controlled. -type JobSource struct { - // Dirty state indicates the job is not fully synced with the job - // specification in the remote repository. - // - // Possible values are: * `NOT_SYNCED`: The job is not yet synced with the - // remote job specification. Import the remote job specification from UI to - // make the job fully synced. * `DISCONNECTED`: The job is temporary - // disconnected from the remote job specification and is allowed for live - // edit. Import the remote job specification again from UI to make the job - // fully synced. - DirtyState types.String `tfsdk:"dirty_state" tf:"optional"` - // Name of the branch which the job is imported from. - ImportFromGitBranch types.String `tfsdk:"import_from_git_branch" tf:""` - // Path of the job YAML file that contains the job specification. - JobConfigPath types.String `tfsdk:"job_config_path" tf:""` -} - -func (newState *JobSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSource) { +// GetContinuous returns the value of the Continuous field in JobSettings as +// a Continuous value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetContinuous(ctx context.Context) (Continuous, bool) { + var e Continuous + if o.Continuous.IsNull() || o.Continuous.IsUnknown() { + return e, false + } + var v []Continuous + d := o.Continuous.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -func (newState *JobSource) SyncEffectiveFieldsDuringRead(existingState JobSource) { +// SetContinuous sets the value of the Continuous field in JobSettings. +func (o *JobSettings) SetContinuous(ctx context.Context, v Continuous) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["continuous"] + o.Continuous = types.ListValueMust(t, vs) } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobSource. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetDeployment returns the value of the Deployment field in JobSettings as +// a JobDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetDeployment(ctx context.Context) (JobDeployment, bool) { + var e JobDeployment + if o.Deployment.IsNull() || o.Deployment.IsUnknown() { + return e, false + } + var v []JobDeployment + d := o.Deployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise -// interfere with how the plugin framework retrieves and sets values in state. Thus, JobSource -// only implements ToObjectValue() and Type(). -func (o JobSource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { - return types.ObjectValueMust( - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - map[string]attr.Value{ - "dirty_state": o.DirtyState, - "import_from_git_branch": o.ImportFromGitBranch, - "job_config_path": o.JobConfigPath, - }) +// SetDeployment sets the value of the Deployment field in JobSettings. +func (o *JobSettings) SetDeployment(ctx context.Context, v JobDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment"] + o.Deployment = types.ListValueMust(t, vs) } -// Type implements basetypes.ObjectValuable. -func (o JobSource) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "dirty_state": types.StringType, - "import_from_git_branch": types.StringType, - "job_config_path": types.StringType, - }, +// GetEmailNotifications returns the value of the EmailNotifications field in JobSettings as +// a JobEmailNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetEmailNotifications(ctx context.Context) (JobEmailNotifications, bool) { + var e JobEmailNotifications + if o.EmailNotifications.IsNull() || o.EmailNotifications.IsUnknown() { + return e, false + } + var v []JobEmailNotifications + d := o.EmailNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false } + return v[0], true } -type JobsHealthRule struct { - // Specifies the health metric that is being evaluated for a particular - // health rule. - // - // * `RUN_DURATION_SECONDS`: Expected total time for a run in seconds. * - // `STREAMING_BACKLOG_BYTES`: An estimate of the maximum bytes of data - // waiting to be consumed across all streams. This metric is in Private - // Preview. * `STREAMING_BACKLOG_RECORDS`: An estimate of the maximum offset - // lag across all streams. This metric is in Private Preview. * - // `STREAMING_BACKLOG_SECONDS`: An estimate of the maximum consumer delay - // across all streams. This metric is in Private Preview. * - // `STREAMING_BACKLOG_FILES`: An estimate of the maximum number of - // outstanding files across all streams. This metric is in Private Preview. - Metric types.String `tfsdk:"metric" tf:""` - // Specifies the operator used to compare the health metric value with the - // specified threshold. - Op types.String `tfsdk:"op" tf:""` - // Specifies the threshold value that the health metric should obey to - // satisfy the health rule. - Value types.Int64 `tfsdk:"value" tf:""` +// SetEmailNotifications sets the value of the EmailNotifications field in JobSettings. +func (o *JobSettings) SetEmailNotifications(ctx context.Context, v JobEmailNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_notifications"] + o.EmailNotifications = types.ListValueMust(t, vs) } -func (newState *JobsHealthRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobsHealthRule) { +// GetEnvironments returns the value of the Environments field in JobSettings as +// a slice of JobEnvironment values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetEnvironments(ctx context.Context) ([]JobEnvironment, bool) { + if o.Environments.IsNull() || o.Environments.IsUnknown() { + return nil, false + } + var v []JobEnvironment + d := o.Environments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true } -func (newState *JobsHealthRule) SyncEffectiveFieldsDuringRead(existingState JobsHealthRule) { +// SetEnvironments sets the value of the Environments field in JobSettings. +func (o *JobSettings) SetEnvironments(ctx context.Context, v []JobEnvironment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment"] + o.Environments = types.ListValueMust(t, vs) } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobsHealthRule. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// GetGitSource returns the value of the GitSource field in JobSettings as +// a GitSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetGitSource(ctx context.Context) (GitSource, bool) { + var e GitSource + if o.GitSource.IsNull() || o.GitSource.IsUnknown() { + return e, false + } + var v []GitSource + d := o.GitSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise -// interfere with how the plugin framework retrieves and sets values in state. Thus, JobsHealthRule -// only implements ToObjectValue() and Type(). -func (o JobsHealthRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { - return types.ObjectValueMust( - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - map[string]attr.Value{ - "metric": o.Metric, - "op": o.Op, - "value": o.Value, - }) +// SetGitSource sets the value of the GitSource field in JobSettings. +func (o *JobSettings) SetGitSource(ctx context.Context, v GitSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_source"] + o.GitSource = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in JobSettings as +// a JobsHealthRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetHealth(ctx context.Context) (JobsHealthRules, bool) { + var e JobsHealthRules + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []JobsHealthRules + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in JobSettings. +func (o *JobSettings) SetHealth(ctx context.Context, v JobsHealthRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetJobClusters returns the value of the JobClusters field in JobSettings as +// a slice of JobCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetJobClusters(ctx context.Context) ([]JobCluster, bool) { + if o.JobClusters.IsNull() || o.JobClusters.IsUnknown() { + return nil, false + } + var v []JobCluster + d := o.JobClusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobClusters sets the value of the JobClusters field in JobSettings. +func (o *JobSettings) SetJobClusters(ctx context.Context, v []JobCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_cluster"] + o.JobClusters = types.ListValueMust(t, vs) +} + +// GetNotificationSettings returns the value of the NotificationSettings field in JobSettings as +// a JobNotificationSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetNotificationSettings(ctx context.Context) (JobNotificationSettings, bool) { + var e JobNotificationSettings + if o.NotificationSettings.IsNull() || o.NotificationSettings.IsUnknown() { + return e, false + } + var v []JobNotificationSettings + d := o.NotificationSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotificationSettings sets the value of the NotificationSettings field in JobSettings. +func (o *JobSettings) SetNotificationSettings(ctx context.Context, v JobNotificationSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notification_settings"] + o.NotificationSettings = types.ListValueMust(t, vs) +} + +// GetParameters returns the value of the Parameters field in JobSettings as +// a slice of JobParameterDefinition values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetParameters(ctx context.Context) ([]JobParameterDefinition, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []JobParameterDefinition + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in JobSettings. +func (o *JobSettings) SetParameters(ctx context.Context, v []JobParameterDefinition) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameter"] + o.Parameters = types.ListValueMust(t, vs) +} + +// GetQueue returns the value of the Queue field in JobSettings as +// a QueueSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetQueue(ctx context.Context) (QueueSettings, bool) { + var e QueueSettings + if o.Queue.IsNull() || o.Queue.IsUnknown() { + return e, false + } + var v []QueueSettings + d := o.Queue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueue sets the value of the Queue field in JobSettings. +func (o *JobSettings) SetQueue(ctx context.Context, v QueueSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["queue"] + o.Queue = types.ListValueMust(t, vs) +} + +// GetRunAs returns the value of the RunAs field in JobSettings as +// a JobRunAs value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetRunAs(ctx context.Context) (JobRunAs, bool) { + var e JobRunAs + if o.RunAs.IsNull() || o.RunAs.IsUnknown() { + return e, false + } + var v []JobRunAs + d := o.RunAs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunAs sets the value of the RunAs field in JobSettings. +func (o *JobSettings) SetRunAs(ctx context.Context, v JobRunAs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_as"] + o.RunAs = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in JobSettings as +// a CronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetSchedule(ctx context.Context) (CronSchedule, bool) { + var e CronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []CronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in JobSettings. +func (o *JobSettings) SetSchedule(ctx context.Context, v CronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in JobSettings as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetTags(ctx context.Context) (map[string]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in JobSettings. +func (o *JobSettings) SetTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.MapValueMust(t, vs) +} + +// GetTasks returns the value of the Tasks field in JobSettings as +// a slice of Task values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetTasks(ctx context.Context) ([]Task, bool) { + if o.Tasks.IsNull() || o.Tasks.IsUnknown() { + return nil, false + } + var v []Task + d := o.Tasks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTasks sets the value of the Tasks field in JobSettings. +func (o *JobSettings) SetTasks(ctx context.Context, v []Task) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task"] + o.Tasks = types.ListValueMust(t, vs) +} + +// GetTrigger returns the value of the Trigger field in JobSettings as +// a TriggerSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetTrigger(ctx context.Context) (TriggerSettings, bool) { + var e TriggerSettings + if o.Trigger.IsNull() || o.Trigger.IsUnknown() { + return e, false + } + var v []TriggerSettings + d := o.Trigger.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrigger sets the value of the Trigger field in JobSettings. +func (o *JobSettings) SetTrigger(ctx context.Context, v TriggerSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger"] + o.Trigger = types.ListValueMust(t, vs) +} + +// GetWebhookNotifications returns the value of the WebhookNotifications field in JobSettings as +// a WebhookNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *JobSettings) GetWebhookNotifications(ctx context.Context) (WebhookNotifications, bool) { + var e WebhookNotifications + if o.WebhookNotifications.IsNull() || o.WebhookNotifications.IsUnknown() { + return e, false + } + var v []WebhookNotifications + d := o.WebhookNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhookNotifications sets the value of the WebhookNotifications field in JobSettings. +func (o *JobSettings) SetWebhookNotifications(ctx context.Context, v WebhookNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook_notifications"] + o.WebhookNotifications = types.ListValueMust(t, vs) +} + +// The source of the job specification in the remote repository when the job is +// source controlled. +type JobSource struct { + // Dirty state indicates the job is not fully synced with the job + // specification in the remote repository. + // + // Possible values are: * `NOT_SYNCED`: The job is not yet synced with the + // remote job specification. Import the remote job specification from UI to + // make the job fully synced. * `DISCONNECTED`: The job is temporary + // disconnected from the remote job specification and is allowed for live + // edit. Import the remote job specification again from UI to make the job + // fully synced. + DirtyState types.String `tfsdk:"dirty_state" tf:"optional"` + // Name of the branch which the job is imported from. + ImportFromGitBranch types.String `tfsdk:"import_from_git_branch" tf:""` + // Path of the job YAML file that contains the job specification. + JobConfigPath types.String `tfsdk:"job_config_path" tf:""` +} + +func (newState *JobSource) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobSource) { +} + +func (newState *JobSource) SyncEffectiveFieldsDuringRead(existingState JobSource) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobSource. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a JobSource) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobSource +// only implements ToObjectValue() and Type(). +func (o JobSource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "dirty_state": o.DirtyState, + "import_from_git_branch": o.ImportFromGitBranch, + "job_config_path": o.JobConfigPath, + }) +} + +// Type implements basetypes.ObjectValuable. +func (o JobSource) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "dirty_state": types.StringType, + "import_from_git_branch": types.StringType, + "job_config_path": types.StringType, + }, + } +} + +type JobsHealthRule struct { + // Specifies the health metric that is being evaluated for a particular + // health rule. + // + // * `RUN_DURATION_SECONDS`: Expected total time for a run in seconds. * + // `STREAMING_BACKLOG_BYTES`: An estimate of the maximum bytes of data + // waiting to be consumed across all streams. This metric is in Private + // Preview. * `STREAMING_BACKLOG_RECORDS`: An estimate of the maximum offset + // lag across all streams. This metric is in Private Preview. * + // `STREAMING_BACKLOG_SECONDS`: An estimate of the maximum consumer delay + // across all streams. This metric is in Private Preview. * + // `STREAMING_BACKLOG_FILES`: An estimate of the maximum number of + // outstanding files across all streams. This metric is in Private Preview. + Metric types.String `tfsdk:"metric" tf:""` + // Specifies the operator used to compare the health metric value with the + // specified threshold. + Op types.String `tfsdk:"op" tf:""` + // Specifies the threshold value that the health metric should obey to + // satisfy the health rule. + Value types.Int64 `tfsdk:"value" tf:""` +} + +func (newState *JobsHealthRule) SyncEffectiveFieldsDuringCreateOrUpdate(plan JobsHealthRule) { +} + +func (newState *JobsHealthRule) SyncEffectiveFieldsDuringRead(existingState JobsHealthRule) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in JobsHealthRule. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a JobsHealthRule) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// interfere with how the plugin framework retrieves and sets values in state. Thus, JobsHealthRule +// only implements ToObjectValue() and Type(). +func (o JobsHealthRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { + return types.ObjectValueMust( + o.Type(ctx).(basetypes.ObjectType).AttrTypes, + map[string]attr.Value{ + "metric": o.Metric, + "op": o.Op, + "value": o.Value, + }) } // Type implements basetypes.ObjectValuable. @@ -3754,6 +5619,31 @@ func (o JobsHealthRules) Type(ctx context.Context) attr.Type { } } +// GetRules returns the value of the Rules field in JobsHealthRules as +// a slice of JobsHealthRule values. +// If the field is unknown or null, the boolean return value is false. +func (o *JobsHealthRules) GetRules(ctx context.Context) ([]JobsHealthRule, bool) { + if o.Rules.IsNull() || o.Rules.IsUnknown() { + return nil, false + } + var v []JobsHealthRule + d := o.Rules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRules sets the value of the Rules field in JobsHealthRules. +func (o *JobsHealthRules) SetRules(ctx context.Context, v []JobsHealthRule) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rules"] + o.Rules = types.ListValueMust(t, vs) +} + type ListJobComplianceForPolicyResponse struct { // A list of jobs and their policy compliance statuses. Jobs types.List `tfsdk:"jobs" tf:"optional"` @@ -3812,6 +5702,31 @@ func (o ListJobComplianceForPolicyResponse) Type(ctx context.Context) attr.Type } } +// GetJobs returns the value of the Jobs field in ListJobComplianceForPolicyResponse as +// a slice of JobCompliance values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListJobComplianceForPolicyResponse) GetJobs(ctx context.Context) ([]JobCompliance, bool) { + if o.Jobs.IsNull() || o.Jobs.IsUnknown() { + return nil, false + } + var v []JobCompliance + d := o.Jobs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobs sets the value of the Jobs field in ListJobComplianceForPolicyResponse. +func (o *ListJobComplianceForPolicyResponse) SetJobs(ctx context.Context, v []JobCompliance) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jobs"] + o.Jobs = types.ListValueMust(t, vs) +} + // List job policy compliance type ListJobComplianceRequest struct { // Use this field to specify the maximum number of results to be returned by @@ -3991,6 +5906,31 @@ func (o ListJobsResponse) Type(ctx context.Context) attr.Type { } } +// GetJobs returns the value of the Jobs field in ListJobsResponse as +// a slice of BaseJob values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListJobsResponse) GetJobs(ctx context.Context) ([]BaseJob, bool) { + if o.Jobs.IsNull() || o.Jobs.IsUnknown() { + return nil, false + } + var v []BaseJob + d := o.Jobs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobs sets the value of the Jobs field in ListJobsResponse. +func (o *ListJobsResponse) SetJobs(ctx context.Context, v []BaseJob) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jobs"] + o.Jobs = types.ListValueMust(t, vs) +} + // List job runs type ListRunsRequest struct { // If active_only is `true`, only active runs are included in the results; @@ -4148,6 +6088,31 @@ func (o ListRunsResponse) Type(ctx context.Context) attr.Type { } } +// GetRuns returns the value of the Runs field in ListRunsResponse as +// a slice of BaseRun values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListRunsResponse) GetRuns(ctx context.Context) ([]BaseRun, bool) { + if o.Runs.IsNull() || o.Runs.IsUnknown() { + return nil, false + } + var v []BaseRun + d := o.Runs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRuns sets the value of the Runs field in ListRunsResponse. +func (o *ListRunsResponse) SetRuns(ctx context.Context, v []BaseRun) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["runs"] + o.Runs = types.ListValueMust(t, vs) +} + type NotebookOutput struct { // The value passed to // [dbutils.notebook.exit()](/notebooks/notebook-workflows.html#notebook-workflows-exit). @@ -4287,6 +6252,31 @@ func (o NotebookTask) Type(ctx context.Context) attr.Type { } } +// GetBaseParameters returns the value of the BaseParameters field in NotebookTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *NotebookTask) GetBaseParameters(ctx context.Context) (map[string]types.String, bool) { + if o.BaseParameters.IsNull() || o.BaseParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.BaseParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetBaseParameters sets the value of the BaseParameters field in NotebookTask. +func (o *NotebookTask) SetBaseParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["base_parameters"] + o.BaseParameters = types.MapValueMust(t, vs) +} + type PeriodicTriggerConfiguration struct { // The interval at which the trigger should run. Interval types.Int64 `tfsdk:"interval" tf:""` @@ -4487,6 +6477,56 @@ func (o PythonWheelTask) Type(ctx context.Context) attr.Type { } } +// GetNamedParameters returns the value of the NamedParameters field in PythonWheelTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PythonWheelTask) GetNamedParameters(ctx context.Context) (map[string]types.String, bool) { + if o.NamedParameters.IsNull() || o.NamedParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.NamedParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNamedParameters sets the value of the NamedParameters field in PythonWheelTask. +func (o *PythonWheelTask) SetNamedParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["named_parameters"] + o.NamedParameters = types.MapValueMust(t, vs) +} + +// GetParameters returns the value of the Parameters field in PythonWheelTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PythonWheelTask) GetParameters(ctx context.Context) ([]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in PythonWheelTask. +func (o *PythonWheelTask) SetParameters(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type QueueDetails struct { // The reason for queuing the run. * `ACTIVE_RUNS_LIMIT_REACHED`: The run // was queued due to reaching the workspace limit of active task runs. * @@ -4660,24 +6700,101 @@ func (o RepairHistoryItem) Type(ctx context.Context) attr.Type { } } -type RepairRun struct { - // An array of commands to execute for jobs with the dbt task, for example - // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt - // run"]` - DbtCommands types.List `tfsdk:"dbt_commands" tf:"optional"` - // A list of parameters for jobs with Spark JAR tasks, for example - // `"jar_params": ["john doe", "35"]`. The parameters are used to invoke the - // main function of the main class specified in the Spark JAR task. If not - // specified upon `run-now`, it defaults to an empty list. jar_params cannot - // be specified in conjunction with notebook_params. The JSON representation - // of this field (for example `{"jar_params":["john doe","35"]}`) cannot - // exceed 10,000 bytes. - // - // Use [Task parameter variables] to set parameters containing information - // about job runs. - // - // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables - JarParams types.List `tfsdk:"jar_params" tf:"optional"` +// GetState returns the value of the State field in RepairHistoryItem as +// a RunState value. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairHistoryItem) GetState(ctx context.Context) (RunState, bool) { + var e RunState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []RunState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in RepairHistoryItem. +func (o *RepairHistoryItem) SetState(ctx context.Context, v RunState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in RepairHistoryItem as +// a RunStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairHistoryItem) GetStatus(ctx context.Context) (RunStatus, bool) { + var e RunStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []RunStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in RepairHistoryItem. +func (o *RepairHistoryItem) SetStatus(ctx context.Context, v RunStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + +// GetTaskRunIds returns the value of the TaskRunIds field in RepairHistoryItem as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairHistoryItem) GetTaskRunIds(ctx context.Context) ([]types.Int64, bool) { + if o.TaskRunIds.IsNull() || o.TaskRunIds.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.TaskRunIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTaskRunIds sets the value of the TaskRunIds field in RepairHistoryItem. +func (o *RepairHistoryItem) SetTaskRunIds(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task_run_ids"] + o.TaskRunIds = types.ListValueMust(t, vs) +} + +type RepairRun struct { + // An array of commands to execute for jobs with the dbt task, for example + // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt + // run"]` + DbtCommands types.List `tfsdk:"dbt_commands" tf:"optional"` + // A list of parameters for jobs with Spark JAR tasks, for example + // `"jar_params": ["john doe", "35"]`. The parameters are used to invoke the + // main function of the main class specified in the Spark JAR task. If not + // specified upon `run-now`, it defaults to an empty list. jar_params cannot + // be specified in conjunction with notebook_params. The JSON representation + // of this field (for example `{"jar_params":["john doe","35"]}`) cannot + // exceed 10,000 bytes. + // + // Use [Task parameter variables] to set parameters containing information + // about job runs. + // + // [Task parameter variables]: https://docs.databricks.com/jobs.html#parameter-variables + JarParams types.List `tfsdk:"jar_params" tf:"optional"` // Job-level parameters used in the run. for example `"param": // "overriding_val"` JobParameters types.Map `tfsdk:"job_parameters" tf:"optional"` @@ -4857,6 +6974,257 @@ func (o RepairRun) Type(ctx context.Context) attr.Type { } } +// GetDbtCommands returns the value of the DbtCommands field in RepairRun as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetDbtCommands(ctx context.Context) ([]types.String, bool) { + if o.DbtCommands.IsNull() || o.DbtCommands.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DbtCommands.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDbtCommands sets the value of the DbtCommands field in RepairRun. +func (o *RepairRun) SetDbtCommands(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + o.DbtCommands = types.ListValueMust(t, vs) +} + +// GetJarParams returns the value of the JarParams field in RepairRun as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetJarParams(ctx context.Context) ([]types.String, bool) { + if o.JarParams.IsNull() || o.JarParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.JarParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJarParams sets the value of the JarParams field in RepairRun. +func (o *RepairRun) SetJarParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + o.JarParams = types.ListValueMust(t, vs) +} + +// GetJobParameters returns the value of the JobParameters field in RepairRun as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetJobParameters(ctx context.Context) (map[string]types.String, bool) { + if o.JobParameters.IsNull() || o.JobParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.JobParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobParameters sets the value of the JobParameters field in RepairRun. +func (o *RepairRun) SetJobParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + o.JobParameters = types.MapValueMust(t, vs) +} + +// GetNotebookParams returns the value of the NotebookParams field in RepairRun as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetNotebookParams(ctx context.Context) (map[string]types.String, bool) { + if o.NotebookParams.IsNull() || o.NotebookParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.NotebookParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotebookParams sets the value of the NotebookParams field in RepairRun. +func (o *RepairRun) SetNotebookParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + o.NotebookParams = types.MapValueMust(t, vs) +} + +// GetPipelineParams returns the value of the PipelineParams field in RepairRun as +// a PipelineParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetPipelineParams(ctx context.Context) (PipelineParams, bool) { + var e PipelineParams + if o.PipelineParams.IsNull() || o.PipelineParams.IsUnknown() { + return e, false + } + var v []PipelineParams + d := o.PipelineParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineParams sets the value of the PipelineParams field in RepairRun. +func (o *RepairRun) SetPipelineParams(ctx context.Context, v PipelineParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_params"] + o.PipelineParams = types.ListValueMust(t, vs) +} + +// GetPythonNamedParams returns the value of the PythonNamedParams field in RepairRun as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetPythonNamedParams(ctx context.Context) (map[string]types.String, bool) { + if o.PythonNamedParams.IsNull() || o.PythonNamedParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.PythonNamedParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonNamedParams sets the value of the PythonNamedParams field in RepairRun. +func (o *RepairRun) SetPythonNamedParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + o.PythonNamedParams = types.MapValueMust(t, vs) +} + +// GetPythonParams returns the value of the PythonParams field in RepairRun as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetPythonParams(ctx context.Context) ([]types.String, bool) { + if o.PythonParams.IsNull() || o.PythonParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PythonParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonParams sets the value of the PythonParams field in RepairRun. +func (o *RepairRun) SetPythonParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + o.PythonParams = types.ListValueMust(t, vs) +} + +// GetRerunTasks returns the value of the RerunTasks field in RepairRun as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetRerunTasks(ctx context.Context) ([]types.String, bool) { + if o.RerunTasks.IsNull() || o.RerunTasks.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RerunTasks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRerunTasks sets the value of the RerunTasks field in RepairRun. +func (o *RepairRun) SetRerunTasks(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rerun_tasks"] + o.RerunTasks = types.ListValueMust(t, vs) +} + +// GetSparkSubmitParams returns the value of the SparkSubmitParams field in RepairRun as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetSparkSubmitParams(ctx context.Context) ([]types.String, bool) { + if o.SparkSubmitParams.IsNull() || o.SparkSubmitParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SparkSubmitParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkSubmitParams sets the value of the SparkSubmitParams field in RepairRun. +func (o *RepairRun) SetSparkSubmitParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + o.SparkSubmitParams = types.ListValueMust(t, vs) +} + +// GetSqlParams returns the value of the SqlParams field in RepairRun as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepairRun) GetSqlParams(ctx context.Context) (map[string]types.String, bool) { + if o.SqlParams.IsNull() || o.SqlParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SqlParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSqlParams sets the value of the SqlParams field in RepairRun. +func (o *RepairRun) SetSqlParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + o.SqlParams = types.MapValueMust(t, vs) +} + // Run repair was initiated. type RepairRunResponse struct { // The ID of the repair. Must be provided in subsequent repairs using the @@ -4955,6 +7323,32 @@ func (o ResetJob) Type(ctx context.Context) attr.Type { } } +// GetNewSettings returns the value of the NewSettings field in ResetJob as +// a JobSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResetJob) GetNewSettings(ctx context.Context) (JobSettings, bool) { + var e JobSettings + if o.NewSettings.IsNull() || o.NewSettings.IsUnknown() { + return e, false + } + var v []JobSettings + d := o.NewSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewSettings sets the value of the NewSettings field in ResetJob. +func (o *ResetJob) SetNewSettings(ctx context.Context, v JobSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_settings"] + o.NewSettings = types.ListValueMust(t, vs) +} + type ResetResponse struct { } @@ -5081,6 +7475,31 @@ func (o ResolvedDbtTaskValues) Type(ctx context.Context) attr.Type { } } +// GetCommands returns the value of the Commands field in ResolvedDbtTaskValues as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedDbtTaskValues) GetCommands(ctx context.Context) ([]types.String, bool) { + if o.Commands.IsNull() || o.Commands.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Commands.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCommands sets the value of the Commands field in ResolvedDbtTaskValues. +func (o *ResolvedDbtTaskValues) SetCommands(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["commands"] + o.Commands = types.ListValueMust(t, vs) +} + type ResolvedNotebookTaskValues struct { BaseParameters types.Map `tfsdk:"base_parameters" tf:"optional"` } @@ -5126,6 +7545,31 @@ func (o ResolvedNotebookTaskValues) Type(ctx context.Context) attr.Type { } } +// GetBaseParameters returns the value of the BaseParameters field in ResolvedNotebookTaskValues as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedNotebookTaskValues) GetBaseParameters(ctx context.Context) (map[string]types.String, bool) { + if o.BaseParameters.IsNull() || o.BaseParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.BaseParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetBaseParameters sets the value of the BaseParameters field in ResolvedNotebookTaskValues. +func (o *ResolvedNotebookTaskValues) SetBaseParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["base_parameters"] + o.BaseParameters = types.MapValueMust(t, vs) +} + type ResolvedParamPairValues struct { Parameters types.Map `tfsdk:"parameters" tf:"optional"` } @@ -5171,6 +7615,31 @@ func (o ResolvedParamPairValues) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in ResolvedParamPairValues as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedParamPairValues) GetParameters(ctx context.Context) (map[string]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in ResolvedParamPairValues. +func (o *ResolvedParamPairValues) SetParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.MapValueMust(t, vs) +} + type ResolvedPythonWheelTaskValues struct { NamedParameters types.Map `tfsdk:"named_parameters" tf:"optional"` @@ -5223,6 +7692,56 @@ func (o ResolvedPythonWheelTaskValues) Type(ctx context.Context) attr.Type { } } +// GetNamedParameters returns the value of the NamedParameters field in ResolvedPythonWheelTaskValues as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedPythonWheelTaskValues) GetNamedParameters(ctx context.Context) (map[string]types.String, bool) { + if o.NamedParameters.IsNull() || o.NamedParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.NamedParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNamedParameters sets the value of the NamedParameters field in ResolvedPythonWheelTaskValues. +func (o *ResolvedPythonWheelTaskValues) SetNamedParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["named_parameters"] + o.NamedParameters = types.MapValueMust(t, vs) +} + +// GetParameters returns the value of the Parameters field in ResolvedPythonWheelTaskValues as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedPythonWheelTaskValues) GetParameters(ctx context.Context) ([]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in ResolvedPythonWheelTaskValues. +func (o *ResolvedPythonWheelTaskValues) SetParameters(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type ResolvedRunJobTaskValues struct { JobParameters types.Map `tfsdk:"job_parameters" tf:"optional"` @@ -5275,6 +7794,56 @@ func (o ResolvedRunJobTaskValues) Type(ctx context.Context) attr.Type { } } +// GetJobParameters returns the value of the JobParameters field in ResolvedRunJobTaskValues as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedRunJobTaskValues) GetJobParameters(ctx context.Context) (map[string]types.String, bool) { + if o.JobParameters.IsNull() || o.JobParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.JobParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobParameters sets the value of the JobParameters field in ResolvedRunJobTaskValues. +func (o *ResolvedRunJobTaskValues) SetJobParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + o.JobParameters = types.MapValueMust(t, vs) +} + +// GetParameters returns the value of the Parameters field in ResolvedRunJobTaskValues as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedRunJobTaskValues) GetParameters(ctx context.Context) (map[string]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in ResolvedRunJobTaskValues. +func (o *ResolvedRunJobTaskValues) SetParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.MapValueMust(t, vs) +} + type ResolvedStringParamsValues struct { Parameters types.List `tfsdk:"parameters" tf:"optional"` } @@ -5320,6 +7889,31 @@ func (o ResolvedStringParamsValues) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in ResolvedStringParamsValues as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedStringParamsValues) GetParameters(ctx context.Context) ([]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in ResolvedStringParamsValues. +func (o *ResolvedStringParamsValues) SetParameters(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type ResolvedValues struct { ConditionTask types.List `tfsdk:"condition_task" tf:"optional,object"` @@ -5428,6 +8022,266 @@ func (o ResolvedValues) Type(ctx context.Context) attr.Type { } } +// GetConditionTask returns the value of the ConditionTask field in ResolvedValues as +// a ResolvedConditionTaskValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetConditionTask(ctx context.Context) (ResolvedConditionTaskValues, bool) { + var e ResolvedConditionTaskValues + if o.ConditionTask.IsNull() || o.ConditionTask.IsUnknown() { + return e, false + } + var v []ResolvedConditionTaskValues + d := o.ConditionTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConditionTask sets the value of the ConditionTask field in ResolvedValues. +func (o *ResolvedValues) SetConditionTask(ctx context.Context, v ResolvedConditionTaskValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition_task"] + o.ConditionTask = types.ListValueMust(t, vs) +} + +// GetDbtTask returns the value of the DbtTask field in ResolvedValues as +// a ResolvedDbtTaskValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetDbtTask(ctx context.Context) (ResolvedDbtTaskValues, bool) { + var e ResolvedDbtTaskValues + if o.DbtTask.IsNull() || o.DbtTask.IsUnknown() { + return e, false + } + var v []ResolvedDbtTaskValues + d := o.DbtTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbtTask sets the value of the DbtTask field in ResolvedValues. +func (o *ResolvedValues) SetDbtTask(ctx context.Context, v ResolvedDbtTaskValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_task"] + o.DbtTask = types.ListValueMust(t, vs) +} + +// GetNotebookTask returns the value of the NotebookTask field in ResolvedValues as +// a ResolvedNotebookTaskValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetNotebookTask(ctx context.Context) (ResolvedNotebookTaskValues, bool) { + var e ResolvedNotebookTaskValues + if o.NotebookTask.IsNull() || o.NotebookTask.IsUnknown() { + return e, false + } + var v []ResolvedNotebookTaskValues + d := o.NotebookTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotebookTask sets the value of the NotebookTask field in ResolvedValues. +func (o *ResolvedValues) SetNotebookTask(ctx context.Context, v ResolvedNotebookTaskValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_task"] + o.NotebookTask = types.ListValueMust(t, vs) +} + +// GetPythonWheelTask returns the value of the PythonWheelTask field in ResolvedValues as +// a ResolvedPythonWheelTaskValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetPythonWheelTask(ctx context.Context) (ResolvedPythonWheelTaskValues, bool) { + var e ResolvedPythonWheelTaskValues + if o.PythonWheelTask.IsNull() || o.PythonWheelTask.IsUnknown() { + return e, false + } + var v []ResolvedPythonWheelTaskValues + d := o.PythonWheelTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPythonWheelTask sets the value of the PythonWheelTask field in ResolvedValues. +func (o *ResolvedValues) SetPythonWheelTask(ctx context.Context, v ResolvedPythonWheelTaskValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_wheel_task"] + o.PythonWheelTask = types.ListValueMust(t, vs) +} + +// GetRunJobTask returns the value of the RunJobTask field in ResolvedValues as +// a ResolvedRunJobTaskValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetRunJobTask(ctx context.Context) (ResolvedRunJobTaskValues, bool) { + var e ResolvedRunJobTaskValues + if o.RunJobTask.IsNull() || o.RunJobTask.IsUnknown() { + return e, false + } + var v []ResolvedRunJobTaskValues + d := o.RunJobTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunJobTask sets the value of the RunJobTask field in ResolvedValues. +func (o *ResolvedValues) SetRunJobTask(ctx context.Context, v ResolvedRunJobTaskValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_job_task"] + o.RunJobTask = types.ListValueMust(t, vs) +} + +// GetSimulationTask returns the value of the SimulationTask field in ResolvedValues as +// a ResolvedParamPairValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetSimulationTask(ctx context.Context) (ResolvedParamPairValues, bool) { + var e ResolvedParamPairValues + if o.SimulationTask.IsNull() || o.SimulationTask.IsUnknown() { + return e, false + } + var v []ResolvedParamPairValues + d := o.SimulationTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSimulationTask sets the value of the SimulationTask field in ResolvedValues. +func (o *ResolvedValues) SetSimulationTask(ctx context.Context, v ResolvedParamPairValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["simulation_task"] + o.SimulationTask = types.ListValueMust(t, vs) +} + +// GetSparkJarTask returns the value of the SparkJarTask field in ResolvedValues as +// a ResolvedStringParamsValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetSparkJarTask(ctx context.Context) (ResolvedStringParamsValues, bool) { + var e ResolvedStringParamsValues + if o.SparkJarTask.IsNull() || o.SparkJarTask.IsUnknown() { + return e, false + } + var v []ResolvedStringParamsValues + d := o.SparkJarTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkJarTask sets the value of the SparkJarTask field in ResolvedValues. +func (o *ResolvedValues) SetSparkJarTask(ctx context.Context, v ResolvedStringParamsValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_jar_task"] + o.SparkJarTask = types.ListValueMust(t, vs) +} + +// GetSparkPythonTask returns the value of the SparkPythonTask field in ResolvedValues as +// a ResolvedStringParamsValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetSparkPythonTask(ctx context.Context) (ResolvedStringParamsValues, bool) { + var e ResolvedStringParamsValues + if o.SparkPythonTask.IsNull() || o.SparkPythonTask.IsUnknown() { + return e, false + } + var v []ResolvedStringParamsValues + d := o.SparkPythonTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkPythonTask sets the value of the SparkPythonTask field in ResolvedValues. +func (o *ResolvedValues) SetSparkPythonTask(ctx context.Context, v ResolvedStringParamsValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_python_task"] + o.SparkPythonTask = types.ListValueMust(t, vs) +} + +// GetSparkSubmitTask returns the value of the SparkSubmitTask field in ResolvedValues as +// a ResolvedStringParamsValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetSparkSubmitTask(ctx context.Context) (ResolvedStringParamsValues, bool) { + var e ResolvedStringParamsValues + if o.SparkSubmitTask.IsNull() || o.SparkSubmitTask.IsUnknown() { + return e, false + } + var v []ResolvedStringParamsValues + d := o.SparkSubmitTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkSubmitTask sets the value of the SparkSubmitTask field in ResolvedValues. +func (o *ResolvedValues) SetSparkSubmitTask(ctx context.Context, v ResolvedStringParamsValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_task"] + o.SparkSubmitTask = types.ListValueMust(t, vs) +} + +// GetSqlTask returns the value of the SqlTask field in ResolvedValues as +// a ResolvedParamPairValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResolvedValues) GetSqlTask(ctx context.Context) (ResolvedParamPairValues, bool) { + var e ResolvedParamPairValues + if o.SqlTask.IsNull() || o.SqlTask.IsUnknown() { + return e, false + } + var v []ResolvedParamPairValues + d := o.SqlTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlTask sets the value of the SqlTask field in ResolvedValues. +func (o *ResolvedValues) SetSqlTask(ctx context.Context, v ResolvedParamPairValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_task"] + o.SqlTask = types.ListValueMust(t, vs) +} + // Run was retrieved successfully type Run struct { // The sequence number of this run attempt for a triggered job run. The @@ -5705,20 +8559,353 @@ func (o Run) Type(ctx context.Context) attr.Type { } } -type RunConditionTask struct { - // The left operand of the condition task. Can be either a string value or a - // job state or parameter reference. - Left types.String `tfsdk:"left" tf:""` - // * `EQUAL_TO`, `NOT_EQUAL` operators perform string comparison of their - // operands. This means that `“12.0” == “12”` will evaluate to - // `false`. * `GREATER_THAN`, `GREATER_THAN_OR_EQUAL`, `LESS_THAN`, - // `LESS_THAN_OR_EQUAL` operators perform numeric comparison of their - // operands. `“12.0” >= “12”` will evaluate to `true`, `“10.0” - // >= “12”` will evaluate to `false`. - // - // The boolean comparison to task values can be implemented with operators - // `EQUAL_TO`, `NOT_EQUAL`. If a task value was set to a boolean value, it - // will be serialized to `“true”` or `“false”` for the comparison. +// GetClusterInstance returns the value of the ClusterInstance field in Run as +// a ClusterInstance value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetClusterInstance(ctx context.Context) (ClusterInstance, bool) { + var e ClusterInstance + if o.ClusterInstance.IsNull() || o.ClusterInstance.IsUnknown() { + return e, false + } + var v []ClusterInstance + d := o.ClusterInstance.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterInstance sets the value of the ClusterInstance field in Run. +func (o *Run) SetClusterInstance(ctx context.Context, v ClusterInstance) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_instance"] + o.ClusterInstance = types.ListValueMust(t, vs) +} + +// GetClusterSpec returns the value of the ClusterSpec field in Run as +// a ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetClusterSpec(ctx context.Context) (ClusterSpec, bool) { + var e ClusterSpec + if o.ClusterSpec.IsNull() || o.ClusterSpec.IsUnknown() { + return e, false + } + var v []ClusterSpec + d := o.ClusterSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterSpec sets the value of the ClusterSpec field in Run. +func (o *Run) SetClusterSpec(ctx context.Context, v ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_spec"] + o.ClusterSpec = types.ListValueMust(t, vs) +} + +// GetGitSource returns the value of the GitSource field in Run as +// a GitSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetGitSource(ctx context.Context) (GitSource, bool) { + var e GitSource + if o.GitSource.IsNull() || o.GitSource.IsUnknown() { + return e, false + } + var v []GitSource + d := o.GitSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitSource sets the value of the GitSource field in Run. +func (o *Run) SetGitSource(ctx context.Context, v GitSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_source"] + o.GitSource = types.ListValueMust(t, vs) +} + +// GetIterations returns the value of the Iterations field in Run as +// a slice of RunTask values. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetIterations(ctx context.Context) ([]RunTask, bool) { + if o.Iterations.IsNull() || o.Iterations.IsUnknown() { + return nil, false + } + var v []RunTask + d := o.Iterations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIterations sets the value of the Iterations field in Run. +func (o *Run) SetIterations(ctx context.Context, v []RunTask) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["iterations"] + o.Iterations = types.ListValueMust(t, vs) +} + +// GetJobClusters returns the value of the JobClusters field in Run as +// a slice of JobCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetJobClusters(ctx context.Context) ([]JobCluster, bool) { + if o.JobClusters.IsNull() || o.JobClusters.IsUnknown() { + return nil, false + } + var v []JobCluster + d := o.JobClusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobClusters sets the value of the JobClusters field in Run. +func (o *Run) SetJobClusters(ctx context.Context, v []JobCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_clusters"] + o.JobClusters = types.ListValueMust(t, vs) +} + +// GetJobParameters returns the value of the JobParameters field in Run as +// a slice of JobParameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetJobParameters(ctx context.Context) ([]JobParameter, bool) { + if o.JobParameters.IsNull() || o.JobParameters.IsUnknown() { + return nil, false + } + var v []JobParameter + d := o.JobParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobParameters sets the value of the JobParameters field in Run. +func (o *Run) SetJobParameters(ctx context.Context, v []JobParameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + o.JobParameters = types.ListValueMust(t, vs) +} + +// GetOverridingParameters returns the value of the OverridingParameters field in Run as +// a RunParameters value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetOverridingParameters(ctx context.Context) (RunParameters, bool) { + var e RunParameters + if o.OverridingParameters.IsNull() || o.OverridingParameters.IsUnknown() { + return e, false + } + var v []RunParameters + d := o.OverridingParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOverridingParameters sets the value of the OverridingParameters field in Run. +func (o *Run) SetOverridingParameters(ctx context.Context, v RunParameters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["overriding_parameters"] + o.OverridingParameters = types.ListValueMust(t, vs) +} + +// GetRepairHistory returns the value of the RepairHistory field in Run as +// a slice of RepairHistoryItem values. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetRepairHistory(ctx context.Context) ([]RepairHistoryItem, bool) { + if o.RepairHistory.IsNull() || o.RepairHistory.IsUnknown() { + return nil, false + } + var v []RepairHistoryItem + d := o.RepairHistory.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRepairHistory sets the value of the RepairHistory field in Run. +func (o *Run) SetRepairHistory(ctx context.Context, v []RepairHistoryItem) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repair_history"] + o.RepairHistory = types.ListValueMust(t, vs) +} + +// GetSchedule returns the value of the Schedule field in Run as +// a CronSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetSchedule(ctx context.Context) (CronSchedule, bool) { + var e CronSchedule + if o.Schedule.IsNull() || o.Schedule.IsUnknown() { + return e, false + } + var v []CronSchedule + d := o.Schedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchedule sets the value of the Schedule field in Run. +func (o *Run) SetSchedule(ctx context.Context, v CronSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedule"] + o.Schedule = types.ListValueMust(t, vs) +} + +// GetState returns the value of the State field in Run as +// a RunState value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetState(ctx context.Context) (RunState, bool) { + var e RunState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []RunState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in Run. +func (o *Run) SetState(ctx context.Context, v RunState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in Run as +// a RunStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetStatus(ctx context.Context) (RunStatus, bool) { + var e RunStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []RunStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in Run. +func (o *Run) SetStatus(ctx context.Context, v RunStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + +// GetTasks returns the value of the Tasks field in Run as +// a slice of RunTask values. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetTasks(ctx context.Context) ([]RunTask, bool) { + if o.Tasks.IsNull() || o.Tasks.IsUnknown() { + return nil, false + } + var v []RunTask + d := o.Tasks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTasks sets the value of the Tasks field in Run. +func (o *Run) SetTasks(ctx context.Context, v []RunTask) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tasks"] + o.Tasks = types.ListValueMust(t, vs) +} + +// GetTriggerInfo returns the value of the TriggerInfo field in Run as +// a TriggerInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetTriggerInfo(ctx context.Context) (TriggerInfo, bool) { + var e TriggerInfo + if o.TriggerInfo.IsNull() || o.TriggerInfo.IsUnknown() { + return e, false + } + var v []TriggerInfo + d := o.TriggerInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTriggerInfo sets the value of the TriggerInfo field in Run. +func (o *Run) SetTriggerInfo(ctx context.Context, v TriggerInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger_info"] + o.TriggerInfo = types.ListValueMust(t, vs) +} + +type RunConditionTask struct { + // The left operand of the condition task. Can be either a string value or a + // job state or parameter reference. + Left types.String `tfsdk:"left" tf:""` + // * `EQUAL_TO`, `NOT_EQUAL` operators perform string comparison of their + // operands. This means that `“12.0” == “12”` will evaluate to + // `false`. * `GREATER_THAN`, `GREATER_THAN_OR_EQUAL`, `LESS_THAN`, + // `LESS_THAN_OR_EQUAL` operators perform numeric comparison of their + // operands. `“12.0” >= “12”` will evaluate to `true`, `“10.0” + // >= “12”` will evaluate to `false`. + // + // The boolean comparison to task values can be implemented with operators + // `EQUAL_TO`, `NOT_EQUAL`. If a task value was set to a boolean value, it + // will be serialized to `“true”` or `“false”` for the comparison. Op types.String `tfsdk:"op" tf:""` // The condition expression evaluation result. Filled in if the task was // successfully completed. Can be `"true"` or `"false"` @@ -5836,6 +9023,58 @@ func (o RunForEachTask) Type(ctx context.Context) attr.Type { } } +// GetStats returns the value of the Stats field in RunForEachTask as +// a ForEachStats value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunForEachTask) GetStats(ctx context.Context) (ForEachStats, bool) { + var e ForEachStats + if o.Stats.IsNull() || o.Stats.IsUnknown() { + return e, false + } + var v []ForEachStats + d := o.Stats.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStats sets the value of the Stats field in RunForEachTask. +func (o *RunForEachTask) SetStats(ctx context.Context, v ForEachStats) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stats"] + o.Stats = types.ListValueMust(t, vs) +} + +// GetTask returns the value of the Task field in RunForEachTask as +// a Task value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunForEachTask) GetTask(ctx context.Context) (Task, bool) { + var e Task + if o.Task.IsNull() || o.Task.IsUnknown() { + return e, false + } + var v []Task + d := o.Task.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTask sets the value of the Task field in RunForEachTask. +func (o *RunForEachTask) SetTask(ctx context.Context, v Task) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task"] + o.Task = types.ListValueMust(t, vs) +} + type RunJobOutput struct { // The run id of the triggered job run RunId types.Int64 `tfsdk:"run_id" tf:"optional"` @@ -6050,6 +9289,232 @@ func (o RunJobTask) Type(ctx context.Context) attr.Type { } } +// GetDbtCommands returns the value of the DbtCommands field in RunJobTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetDbtCommands(ctx context.Context) ([]types.String, bool) { + if o.DbtCommands.IsNull() || o.DbtCommands.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DbtCommands.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDbtCommands sets the value of the DbtCommands field in RunJobTask. +func (o *RunJobTask) SetDbtCommands(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + o.DbtCommands = types.ListValueMust(t, vs) +} + +// GetJarParams returns the value of the JarParams field in RunJobTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetJarParams(ctx context.Context) ([]types.String, bool) { + if o.JarParams.IsNull() || o.JarParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.JarParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJarParams sets the value of the JarParams field in RunJobTask. +func (o *RunJobTask) SetJarParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + o.JarParams = types.ListValueMust(t, vs) +} + +// GetJobParameters returns the value of the JobParameters field in RunJobTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetJobParameters(ctx context.Context) (map[string]types.String, bool) { + if o.JobParameters.IsNull() || o.JobParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.JobParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobParameters sets the value of the JobParameters field in RunJobTask. +func (o *RunJobTask) SetJobParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + o.JobParameters = types.MapValueMust(t, vs) +} + +// GetNotebookParams returns the value of the NotebookParams field in RunJobTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetNotebookParams(ctx context.Context) (map[string]types.String, bool) { + if o.NotebookParams.IsNull() || o.NotebookParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.NotebookParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotebookParams sets the value of the NotebookParams field in RunJobTask. +func (o *RunJobTask) SetNotebookParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + o.NotebookParams = types.MapValueMust(t, vs) +} + +// GetPipelineParams returns the value of the PipelineParams field in RunJobTask as +// a PipelineParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetPipelineParams(ctx context.Context) (PipelineParams, bool) { + var e PipelineParams + if o.PipelineParams.IsNull() || o.PipelineParams.IsUnknown() { + return e, false + } + var v []PipelineParams + d := o.PipelineParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineParams sets the value of the PipelineParams field in RunJobTask. +func (o *RunJobTask) SetPipelineParams(ctx context.Context, v PipelineParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_params"] + o.PipelineParams = types.ListValueMust(t, vs) +} + +// GetPythonNamedParams returns the value of the PythonNamedParams field in RunJobTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetPythonNamedParams(ctx context.Context) (map[string]types.String, bool) { + if o.PythonNamedParams.IsNull() || o.PythonNamedParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.PythonNamedParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonNamedParams sets the value of the PythonNamedParams field in RunJobTask. +func (o *RunJobTask) SetPythonNamedParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + o.PythonNamedParams = types.MapValueMust(t, vs) +} + +// GetPythonParams returns the value of the PythonParams field in RunJobTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetPythonParams(ctx context.Context) ([]types.String, bool) { + if o.PythonParams.IsNull() || o.PythonParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PythonParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonParams sets the value of the PythonParams field in RunJobTask. +func (o *RunJobTask) SetPythonParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + o.PythonParams = types.ListValueMust(t, vs) +} + +// GetSparkSubmitParams returns the value of the SparkSubmitParams field in RunJobTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetSparkSubmitParams(ctx context.Context) ([]types.String, bool) { + if o.SparkSubmitParams.IsNull() || o.SparkSubmitParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SparkSubmitParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkSubmitParams sets the value of the SparkSubmitParams field in RunJobTask. +func (o *RunJobTask) SetSparkSubmitParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + o.SparkSubmitParams = types.ListValueMust(t, vs) +} + +// GetSqlParams returns the value of the SqlParams field in RunJobTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunJobTask) GetSqlParams(ctx context.Context) (map[string]types.String, bool) { + if o.SqlParams.IsNull() || o.SqlParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SqlParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSqlParams sets the value of the SqlParams field in RunJobTask. +func (o *RunJobTask) SetSqlParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + o.SqlParams = types.MapValueMust(t, vs) +} + type RunNow struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt @@ -6255,6 +9720,283 @@ func (o RunNow) Type(ctx context.Context) attr.Type { } } +// GetDbtCommands returns the value of the DbtCommands field in RunNow as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetDbtCommands(ctx context.Context) ([]types.String, bool) { + if o.DbtCommands.IsNull() || o.DbtCommands.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DbtCommands.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDbtCommands sets the value of the DbtCommands field in RunNow. +func (o *RunNow) SetDbtCommands(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + o.DbtCommands = types.ListValueMust(t, vs) +} + +// GetJarParams returns the value of the JarParams field in RunNow as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetJarParams(ctx context.Context) ([]types.String, bool) { + if o.JarParams.IsNull() || o.JarParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.JarParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJarParams sets the value of the JarParams field in RunNow. +func (o *RunNow) SetJarParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + o.JarParams = types.ListValueMust(t, vs) +} + +// GetJobParameters returns the value of the JobParameters field in RunNow as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetJobParameters(ctx context.Context) (map[string]types.String, bool) { + if o.JobParameters.IsNull() || o.JobParameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.JobParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJobParameters sets the value of the JobParameters field in RunNow. +func (o *RunNow) SetJobParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + o.JobParameters = types.MapValueMust(t, vs) +} + +// GetNotebookParams returns the value of the NotebookParams field in RunNow as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetNotebookParams(ctx context.Context) (map[string]types.String, bool) { + if o.NotebookParams.IsNull() || o.NotebookParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.NotebookParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotebookParams sets the value of the NotebookParams field in RunNow. +func (o *RunNow) SetNotebookParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + o.NotebookParams = types.MapValueMust(t, vs) +} + +// GetOnly returns the value of the Only field in RunNow as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetOnly(ctx context.Context) ([]types.String, bool) { + if o.Only.IsNull() || o.Only.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Only.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnly sets the value of the Only field in RunNow. +func (o *RunNow) SetOnly(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["only"] + o.Only = types.ListValueMust(t, vs) +} + +// GetPipelineParams returns the value of the PipelineParams field in RunNow as +// a PipelineParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetPipelineParams(ctx context.Context) (PipelineParams, bool) { + var e PipelineParams + if o.PipelineParams.IsNull() || o.PipelineParams.IsUnknown() { + return e, false + } + var v []PipelineParams + d := o.PipelineParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineParams sets the value of the PipelineParams field in RunNow. +func (o *RunNow) SetPipelineParams(ctx context.Context, v PipelineParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_params"] + o.PipelineParams = types.ListValueMust(t, vs) +} + +// GetPythonNamedParams returns the value of the PythonNamedParams field in RunNow as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetPythonNamedParams(ctx context.Context) (map[string]types.String, bool) { + if o.PythonNamedParams.IsNull() || o.PythonNamedParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.PythonNamedParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonNamedParams sets the value of the PythonNamedParams field in RunNow. +func (o *RunNow) SetPythonNamedParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + o.PythonNamedParams = types.MapValueMust(t, vs) +} + +// GetPythonParams returns the value of the PythonParams field in RunNow as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetPythonParams(ctx context.Context) ([]types.String, bool) { + if o.PythonParams.IsNull() || o.PythonParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PythonParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonParams sets the value of the PythonParams field in RunNow. +func (o *RunNow) SetPythonParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + o.PythonParams = types.ListValueMust(t, vs) +} + +// GetQueue returns the value of the Queue field in RunNow as +// a QueueSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetQueue(ctx context.Context) (QueueSettings, bool) { + var e QueueSettings + if o.Queue.IsNull() || o.Queue.IsUnknown() { + return e, false + } + var v []QueueSettings + d := o.Queue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueue sets the value of the Queue field in RunNow. +func (o *RunNow) SetQueue(ctx context.Context, v QueueSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["queue"] + o.Queue = types.ListValueMust(t, vs) +} + +// GetSparkSubmitParams returns the value of the SparkSubmitParams field in RunNow as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetSparkSubmitParams(ctx context.Context) ([]types.String, bool) { + if o.SparkSubmitParams.IsNull() || o.SparkSubmitParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SparkSubmitParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkSubmitParams sets the value of the SparkSubmitParams field in RunNow. +func (o *RunNow) SetSparkSubmitParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + o.SparkSubmitParams = types.ListValueMust(t, vs) +} + +// GetSqlParams returns the value of the SqlParams field in RunNow as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunNow) GetSqlParams(ctx context.Context) (map[string]types.String, bool) { + if o.SqlParams.IsNull() || o.SqlParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SqlParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSqlParams sets the value of the SqlParams field in RunNow. +func (o *RunNow) SetSqlParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + o.SqlParams = types.MapValueMust(t, vs) +} + // Run was started successfully. type RunNowResponse struct { // A unique identifier for this job run. This is set to the same value as @@ -6414,6 +10156,136 @@ func (o RunOutput) Type(ctx context.Context) attr.Type { } } +// GetDbtOutput returns the value of the DbtOutput field in RunOutput as +// a DbtOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunOutput) GetDbtOutput(ctx context.Context) (DbtOutput, bool) { + var e DbtOutput + if o.DbtOutput.IsNull() || o.DbtOutput.IsUnknown() { + return e, false + } + var v []DbtOutput + d := o.DbtOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbtOutput sets the value of the DbtOutput field in RunOutput. +func (o *RunOutput) SetDbtOutput(ctx context.Context, v DbtOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_output"] + o.DbtOutput = types.ListValueMust(t, vs) +} + +// GetMetadata returns the value of the Metadata field in RunOutput as +// a Run value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunOutput) GetMetadata(ctx context.Context) (Run, bool) { + var e Run + if o.Metadata.IsNull() || o.Metadata.IsUnknown() { + return e, false + } + var v []Run + d := o.Metadata.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetadata sets the value of the Metadata field in RunOutput. +func (o *RunOutput) SetMetadata(ctx context.Context, v Run) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metadata"] + o.Metadata = types.ListValueMust(t, vs) +} + +// GetNotebookOutput returns the value of the NotebookOutput field in RunOutput as +// a NotebookOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunOutput) GetNotebookOutput(ctx context.Context) (NotebookOutput, bool) { + var e NotebookOutput + if o.NotebookOutput.IsNull() || o.NotebookOutput.IsUnknown() { + return e, false + } + var v []NotebookOutput + d := o.NotebookOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotebookOutput sets the value of the NotebookOutput field in RunOutput. +func (o *RunOutput) SetNotebookOutput(ctx context.Context, v NotebookOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_output"] + o.NotebookOutput = types.ListValueMust(t, vs) +} + +// GetRunJobOutput returns the value of the RunJobOutput field in RunOutput as +// a RunJobOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunOutput) GetRunJobOutput(ctx context.Context) (RunJobOutput, bool) { + var e RunJobOutput + if o.RunJobOutput.IsNull() || o.RunJobOutput.IsUnknown() { + return e, false + } + var v []RunJobOutput + d := o.RunJobOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunJobOutput sets the value of the RunJobOutput field in RunOutput. +func (o *RunOutput) SetRunJobOutput(ctx context.Context, v RunJobOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_job_output"] + o.RunJobOutput = types.ListValueMust(t, vs) +} + +// GetSqlOutput returns the value of the SqlOutput field in RunOutput as +// a SqlOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunOutput) GetSqlOutput(ctx context.Context) (SqlOutput, bool) { + var e SqlOutput + if o.SqlOutput.IsNull() || o.SqlOutput.IsUnknown() { + return e, false + } + var v []SqlOutput + d := o.SqlOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlOutput sets the value of the SqlOutput field in RunOutput. +func (o *RunOutput) SetSqlOutput(ctx context.Context, v SqlOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_output"] + o.SqlOutput = types.ListValueMust(t, vs) +} + type RunParameters struct { // An array of commands to execute for jobs with the dbt task, for example // `"dbt_commands": ["dbt deps", "dbt seed", "dbt deps", "dbt seed", "dbt @@ -6543,36 +10415,237 @@ func (o RunParameters) ToObjectValue(ctx context.Context) basetypes.ObjectValue }) } -// Type implements basetypes.ObjectValuable. -func (o RunParameters) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ - ElemType: types.StringType, - }, - "jar_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "notebook_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.Type(ctx), - }, - "python_named_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "python_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "spark_submit_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "sql_params": basetypes.MapType{ - ElemType: types.StringType, - }, - }, +// Type implements basetypes.ObjectValuable. +func (o RunParameters) Type(ctx context.Context) attr.Type { + return types.ObjectType{ + AttrTypes: map[string]attr.Type{ + "dbt_commands": basetypes.ListType{ + ElemType: types.StringType, + }, + "jar_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "notebook_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.Type(ctx), + }, + "python_named_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "python_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "spark_submit_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "sql_params": basetypes.MapType{ + ElemType: types.StringType, + }, + }, + } +} + +// GetDbtCommands returns the value of the DbtCommands field in RunParameters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetDbtCommands(ctx context.Context) ([]types.String, bool) { + if o.DbtCommands.IsNull() || o.DbtCommands.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DbtCommands.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDbtCommands sets the value of the DbtCommands field in RunParameters. +func (o *RunParameters) SetDbtCommands(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + o.DbtCommands = types.ListValueMust(t, vs) +} + +// GetJarParams returns the value of the JarParams field in RunParameters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetJarParams(ctx context.Context) ([]types.String, bool) { + if o.JarParams.IsNull() || o.JarParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.JarParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetJarParams sets the value of the JarParams field in RunParameters. +func (o *RunParameters) SetJarParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + o.JarParams = types.ListValueMust(t, vs) +} + +// GetNotebookParams returns the value of the NotebookParams field in RunParameters as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetNotebookParams(ctx context.Context) (map[string]types.String, bool) { + if o.NotebookParams.IsNull() || o.NotebookParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.NotebookParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotebookParams sets the value of the NotebookParams field in RunParameters. +func (o *RunParameters) SetNotebookParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + o.NotebookParams = types.MapValueMust(t, vs) +} + +// GetPipelineParams returns the value of the PipelineParams field in RunParameters as +// a PipelineParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetPipelineParams(ctx context.Context) (PipelineParams, bool) { + var e PipelineParams + if o.PipelineParams.IsNull() || o.PipelineParams.IsUnknown() { + return e, false + } + var v []PipelineParams + d := o.PipelineParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineParams sets the value of the PipelineParams field in RunParameters. +func (o *RunParameters) SetPipelineParams(ctx context.Context, v PipelineParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_params"] + o.PipelineParams = types.ListValueMust(t, vs) +} + +// GetPythonNamedParams returns the value of the PythonNamedParams field in RunParameters as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetPythonNamedParams(ctx context.Context) (map[string]types.String, bool) { + if o.PythonNamedParams.IsNull() || o.PythonNamedParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.PythonNamedParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonNamedParams sets the value of the PythonNamedParams field in RunParameters. +func (o *RunParameters) SetPythonNamedParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + o.PythonNamedParams = types.MapValueMust(t, vs) +} + +// GetPythonParams returns the value of the PythonParams field in RunParameters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetPythonParams(ctx context.Context) ([]types.String, bool) { + if o.PythonParams.IsNull() || o.PythonParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PythonParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPythonParams sets the value of the PythonParams field in RunParameters. +func (o *RunParameters) SetPythonParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + o.PythonParams = types.ListValueMust(t, vs) +} + +// GetSparkSubmitParams returns the value of the SparkSubmitParams field in RunParameters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetSparkSubmitParams(ctx context.Context) ([]types.String, bool) { + if o.SparkSubmitParams.IsNull() || o.SparkSubmitParams.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SparkSubmitParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkSubmitParams sets the value of the SparkSubmitParams field in RunParameters. +func (o *RunParameters) SetSparkSubmitParams(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + o.SparkSubmitParams = types.ListValueMust(t, vs) +} + +// GetSqlParams returns the value of the SqlParams field in RunParameters as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunParameters) GetSqlParams(ctx context.Context) (map[string]types.String, bool) { + if o.SqlParams.IsNull() || o.SqlParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SqlParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSqlParams sets the value of the SqlParams field in RunParameters. +func (o *RunParameters) SetSqlParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + o.SqlParams = types.MapValueMust(t, vs) } // The current state of the run. @@ -6697,6 +10770,58 @@ func (o RunStatus) Type(ctx context.Context) attr.Type { } } +// GetQueueDetails returns the value of the QueueDetails field in RunStatus as +// a QueueDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunStatus) GetQueueDetails(ctx context.Context) (QueueDetails, bool) { + var e QueueDetails + if o.QueueDetails.IsNull() || o.QueueDetails.IsUnknown() { + return e, false + } + var v []QueueDetails + d := o.QueueDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueueDetails sets the value of the QueueDetails field in RunStatus. +func (o *RunStatus) SetQueueDetails(ctx context.Context, v QueueDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["queue_details"] + o.QueueDetails = types.ListValueMust(t, vs) +} + +// GetTerminationDetails returns the value of the TerminationDetails field in RunStatus as +// a TerminationDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunStatus) GetTerminationDetails(ctx context.Context) (TerminationDetails, bool) { + var e TerminationDetails + if o.TerminationDetails.IsNull() || o.TerminationDetails.IsUnknown() { + return e, false + } + var v []TerminationDetails + d := o.TerminationDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTerminationDetails sets the value of the TerminationDetails field in RunStatus. +func (o *RunStatus) SetTerminationDetails(ctx context.Context, v TerminationDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["termination_details"] + o.TerminationDetails = types.ListValueMust(t, vs) +} + // Used when outputting a child run, in GetRun or ListRuns. type RunTask struct { // The sequence number of this run attempt for a triggered job run. The @@ -6887,8 +11012,8 @@ func (a RunTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Ty "email_notifications": reflect.TypeOf(JobEmailNotifications{}), "for_each_task": reflect.TypeOf(RunForEachTask{}), "git_source": reflect.TypeOf(GitSource{}), - "library": reflect.TypeOf(compute.Library{}), - "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "library": reflect.TypeOf(compute_tf.Library{}), + "new_cluster": reflect.TypeOf(compute_tf.ClusterSpec{}), "notebook_task": reflect.TypeOf(NotebookTask{}), "notification_settings": reflect.TypeOf(TaskNotificationSettings{}), "pipeline_task": reflect.TypeOf(PipelineTask{}), @@ -7045,6 +11170,576 @@ func (o RunTask) Type(ctx context.Context) attr.Type { } } +// GetClusterInstance returns the value of the ClusterInstance field in RunTask as +// a ClusterInstance value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetClusterInstance(ctx context.Context) (ClusterInstance, bool) { + var e ClusterInstance + if o.ClusterInstance.IsNull() || o.ClusterInstance.IsUnknown() { + return e, false + } + var v []ClusterInstance + d := o.ClusterInstance.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterInstance sets the value of the ClusterInstance field in RunTask. +func (o *RunTask) SetClusterInstance(ctx context.Context, v ClusterInstance) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_instance"] + o.ClusterInstance = types.ListValueMust(t, vs) +} + +// GetConditionTask returns the value of the ConditionTask field in RunTask as +// a RunConditionTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetConditionTask(ctx context.Context) (RunConditionTask, bool) { + var e RunConditionTask + if o.ConditionTask.IsNull() || o.ConditionTask.IsUnknown() { + return e, false + } + var v []RunConditionTask + d := o.ConditionTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConditionTask sets the value of the ConditionTask field in RunTask. +func (o *RunTask) SetConditionTask(ctx context.Context, v RunConditionTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition_task"] + o.ConditionTask = types.ListValueMust(t, vs) +} + +// GetDbtTask returns the value of the DbtTask field in RunTask as +// a DbtTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetDbtTask(ctx context.Context) (DbtTask, bool) { + var e DbtTask + if o.DbtTask.IsNull() || o.DbtTask.IsUnknown() { + return e, false + } + var v []DbtTask + d := o.DbtTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbtTask sets the value of the DbtTask field in RunTask. +func (o *RunTask) SetDbtTask(ctx context.Context, v DbtTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_task"] + o.DbtTask = types.ListValueMust(t, vs) +} + +// GetDependsOn returns the value of the DependsOn field in RunTask as +// a slice of TaskDependency values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetDependsOn(ctx context.Context) ([]TaskDependency, bool) { + if o.DependsOn.IsNull() || o.DependsOn.IsUnknown() { + return nil, false + } + var v []TaskDependency + d := o.DependsOn.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDependsOn sets the value of the DependsOn field in RunTask. +func (o *RunTask) SetDependsOn(ctx context.Context, v []TaskDependency) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["depends_on"] + o.DependsOn = types.ListValueMust(t, vs) +} + +// GetEmailNotifications returns the value of the EmailNotifications field in RunTask as +// a JobEmailNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetEmailNotifications(ctx context.Context) (JobEmailNotifications, bool) { + var e JobEmailNotifications + if o.EmailNotifications.IsNull() || o.EmailNotifications.IsUnknown() { + return e, false + } + var v []JobEmailNotifications + d := o.EmailNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEmailNotifications sets the value of the EmailNotifications field in RunTask. +func (o *RunTask) SetEmailNotifications(ctx context.Context, v JobEmailNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_notifications"] + o.EmailNotifications = types.ListValueMust(t, vs) +} + +// GetForEachTask returns the value of the ForEachTask field in RunTask as +// a RunForEachTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetForEachTask(ctx context.Context) (RunForEachTask, bool) { + var e RunForEachTask + if o.ForEachTask.IsNull() || o.ForEachTask.IsUnknown() { + return e, false + } + var v []RunForEachTask + d := o.ForEachTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetForEachTask sets the value of the ForEachTask field in RunTask. +func (o *RunTask) SetForEachTask(ctx context.Context, v RunForEachTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["for_each_task"] + o.ForEachTask = types.ListValueMust(t, vs) +} + +// GetGitSource returns the value of the GitSource field in RunTask as +// a GitSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetGitSource(ctx context.Context) (GitSource, bool) { + var e GitSource + if o.GitSource.IsNull() || o.GitSource.IsUnknown() { + return e, false + } + var v []GitSource + d := o.GitSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitSource sets the value of the GitSource field in RunTask. +func (o *RunTask) SetGitSource(ctx context.Context, v GitSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_source"] + o.GitSource = types.ListValueMust(t, vs) +} + +// GetLibraries returns the value of the Libraries field in RunTask as +// a slice of compute_tf.Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetLibraries(ctx context.Context) ([]compute_tf.Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []compute_tf.Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in RunTask. +func (o *RunTask) SetLibraries(ctx context.Context, v []compute_tf.Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNewCluster returns the value of the NewCluster field in RunTask as +// a compute_tf.ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetNewCluster(ctx context.Context) (compute_tf.ClusterSpec, bool) { + var e compute_tf.ClusterSpec + if o.NewCluster.IsNull() || o.NewCluster.IsUnknown() { + return e, false + } + var v []compute_tf.ClusterSpec + d := o.NewCluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewCluster sets the value of the NewCluster field in RunTask. +func (o *RunTask) SetNewCluster(ctx context.Context, v compute_tf.ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_cluster"] + o.NewCluster = types.ListValueMust(t, vs) +} + +// GetNotebookTask returns the value of the NotebookTask field in RunTask as +// a NotebookTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetNotebookTask(ctx context.Context) (NotebookTask, bool) { + var e NotebookTask + if o.NotebookTask.IsNull() || o.NotebookTask.IsUnknown() { + return e, false + } + var v []NotebookTask + d := o.NotebookTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotebookTask sets the value of the NotebookTask field in RunTask. +func (o *RunTask) SetNotebookTask(ctx context.Context, v NotebookTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_task"] + o.NotebookTask = types.ListValueMust(t, vs) +} + +// GetNotificationSettings returns the value of the NotificationSettings field in RunTask as +// a TaskNotificationSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetNotificationSettings(ctx context.Context) (TaskNotificationSettings, bool) { + var e TaskNotificationSettings + if o.NotificationSettings.IsNull() || o.NotificationSettings.IsUnknown() { + return e, false + } + var v []TaskNotificationSettings + d := o.NotificationSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotificationSettings sets the value of the NotificationSettings field in RunTask. +func (o *RunTask) SetNotificationSettings(ctx context.Context, v TaskNotificationSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notification_settings"] + o.NotificationSettings = types.ListValueMust(t, vs) +} + +// GetPipelineTask returns the value of the PipelineTask field in RunTask as +// a PipelineTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetPipelineTask(ctx context.Context) (PipelineTask, bool) { + var e PipelineTask + if o.PipelineTask.IsNull() || o.PipelineTask.IsUnknown() { + return e, false + } + var v []PipelineTask + d := o.PipelineTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineTask sets the value of the PipelineTask field in RunTask. +func (o *RunTask) SetPipelineTask(ctx context.Context, v PipelineTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_task"] + o.PipelineTask = types.ListValueMust(t, vs) +} + +// GetPythonWheelTask returns the value of the PythonWheelTask field in RunTask as +// a PythonWheelTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetPythonWheelTask(ctx context.Context) (PythonWheelTask, bool) { + var e PythonWheelTask + if o.PythonWheelTask.IsNull() || o.PythonWheelTask.IsUnknown() { + return e, false + } + var v []PythonWheelTask + d := o.PythonWheelTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPythonWheelTask sets the value of the PythonWheelTask field in RunTask. +func (o *RunTask) SetPythonWheelTask(ctx context.Context, v PythonWheelTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_wheel_task"] + o.PythonWheelTask = types.ListValueMust(t, vs) +} + +// GetResolvedValues returns the value of the ResolvedValues field in RunTask as +// a ResolvedValues value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetResolvedValues(ctx context.Context) (ResolvedValues, bool) { + var e ResolvedValues + if o.ResolvedValues.IsNull() || o.ResolvedValues.IsUnknown() { + return e, false + } + var v []ResolvedValues + d := o.ResolvedValues.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetResolvedValues sets the value of the ResolvedValues field in RunTask. +func (o *RunTask) SetResolvedValues(ctx context.Context, v ResolvedValues) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["resolved_values"] + o.ResolvedValues = types.ListValueMust(t, vs) +} + +// GetRunJobTask returns the value of the RunJobTask field in RunTask as +// a RunJobTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetRunJobTask(ctx context.Context) (RunJobTask, bool) { + var e RunJobTask + if o.RunJobTask.IsNull() || o.RunJobTask.IsUnknown() { + return e, false + } + var v []RunJobTask + d := o.RunJobTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunJobTask sets the value of the RunJobTask field in RunTask. +func (o *RunTask) SetRunJobTask(ctx context.Context, v RunJobTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_job_task"] + o.RunJobTask = types.ListValueMust(t, vs) +} + +// GetSparkJarTask returns the value of the SparkJarTask field in RunTask as +// a SparkJarTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetSparkJarTask(ctx context.Context) (SparkJarTask, bool) { + var e SparkJarTask + if o.SparkJarTask.IsNull() || o.SparkJarTask.IsUnknown() { + return e, false + } + var v []SparkJarTask + d := o.SparkJarTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkJarTask sets the value of the SparkJarTask field in RunTask. +func (o *RunTask) SetSparkJarTask(ctx context.Context, v SparkJarTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_jar_task"] + o.SparkJarTask = types.ListValueMust(t, vs) +} + +// GetSparkPythonTask returns the value of the SparkPythonTask field in RunTask as +// a SparkPythonTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetSparkPythonTask(ctx context.Context) (SparkPythonTask, bool) { + var e SparkPythonTask + if o.SparkPythonTask.IsNull() || o.SparkPythonTask.IsUnknown() { + return e, false + } + var v []SparkPythonTask + d := o.SparkPythonTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkPythonTask sets the value of the SparkPythonTask field in RunTask. +func (o *RunTask) SetSparkPythonTask(ctx context.Context, v SparkPythonTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_python_task"] + o.SparkPythonTask = types.ListValueMust(t, vs) +} + +// GetSparkSubmitTask returns the value of the SparkSubmitTask field in RunTask as +// a SparkSubmitTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetSparkSubmitTask(ctx context.Context) (SparkSubmitTask, bool) { + var e SparkSubmitTask + if o.SparkSubmitTask.IsNull() || o.SparkSubmitTask.IsUnknown() { + return e, false + } + var v []SparkSubmitTask + d := o.SparkSubmitTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkSubmitTask sets the value of the SparkSubmitTask field in RunTask. +func (o *RunTask) SetSparkSubmitTask(ctx context.Context, v SparkSubmitTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_task"] + o.SparkSubmitTask = types.ListValueMust(t, vs) +} + +// GetSqlTask returns the value of the SqlTask field in RunTask as +// a SqlTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetSqlTask(ctx context.Context) (SqlTask, bool) { + var e SqlTask + if o.SqlTask.IsNull() || o.SqlTask.IsUnknown() { + return e, false + } + var v []SqlTask + d := o.SqlTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlTask sets the value of the SqlTask field in RunTask. +func (o *RunTask) SetSqlTask(ctx context.Context, v SqlTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_task"] + o.SqlTask = types.ListValueMust(t, vs) +} + +// GetState returns the value of the State field in RunTask as +// a RunState value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetState(ctx context.Context) (RunState, bool) { + var e RunState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []RunState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in RunTask. +func (o *RunTask) SetState(ctx context.Context, v RunState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in RunTask as +// a RunStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetStatus(ctx context.Context) (RunStatus, bool) { + var e RunStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []RunStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in RunTask. +func (o *RunTask) SetStatus(ctx context.Context, v RunStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + +// GetWebhookNotifications returns the value of the WebhookNotifications field in RunTask as +// a WebhookNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *RunTask) GetWebhookNotifications(ctx context.Context) (WebhookNotifications, bool) { + var e WebhookNotifications + if o.WebhookNotifications.IsNull() || o.WebhookNotifications.IsUnknown() { + return e, false + } + var v []WebhookNotifications + d := o.WebhookNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhookNotifications sets the value of the WebhookNotifications field in RunTask. +func (o *RunTask) SetWebhookNotifications(ctx context.Context, v WebhookNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook_notifications"] + o.WebhookNotifications = types.ListValueMust(t, vs) +} + type SparkJarTask struct { // Deprecated since 04/2016. Provide a `jar` through the `libraries` field // instead. For an example, see :method:jobs/create. @@ -7109,6 +11804,31 @@ func (o SparkJarTask) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in SparkJarTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SparkJarTask) GetParameters(ctx context.Context) ([]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in SparkJarTask. +func (o *SparkJarTask) SetParameters(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type SparkPythonTask struct { // Command line parameters passed to the Python file. // @@ -7180,6 +11900,31 @@ func (o SparkPythonTask) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in SparkPythonTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SparkPythonTask) GetParameters(ctx context.Context) ([]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in SparkPythonTask. +func (o *SparkPythonTask) SetParameters(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type SparkSubmitTask struct { // Command-line parameters passed to spark submit. // @@ -7231,6 +11976,31 @@ func (o SparkSubmitTask) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in SparkSubmitTask as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SparkSubmitTask) GetParameters(ctx context.Context) ([]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in SparkSubmitTask. +func (o *SparkSubmitTask) SetParameters(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type SqlAlertOutput struct { // The state of the SQL alert. // @@ -7298,6 +12068,31 @@ func (o SqlAlertOutput) Type(ctx context.Context) attr.Type { } } +// GetSqlStatements returns the value of the SqlStatements field in SqlAlertOutput as +// a slice of SqlStatementOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlAlertOutput) GetSqlStatements(ctx context.Context) ([]SqlStatementOutput, bool) { + if o.SqlStatements.IsNull() || o.SqlStatements.IsUnknown() { + return nil, false + } + var v []SqlStatementOutput + d := o.SqlStatements.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSqlStatements sets the value of the SqlStatements field in SqlAlertOutput. +func (o *SqlAlertOutput) SetSqlStatements(ctx context.Context, v []SqlStatementOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_statements"] + o.SqlStatements = types.ListValueMust(t, vs) +} + type SqlDashboardOutput struct { // The canonical identifier of the SQL warehouse. WarehouseId types.String `tfsdk:"warehouse_id" tf:"optional"` @@ -7348,6 +12143,31 @@ func (o SqlDashboardOutput) Type(ctx context.Context) attr.Type { } } +// GetWidgets returns the value of the Widgets field in SqlDashboardOutput as +// a slice of SqlDashboardWidgetOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlDashboardOutput) GetWidgets(ctx context.Context) ([]SqlDashboardWidgetOutput, bool) { + if o.Widgets.IsNull() || o.Widgets.IsUnknown() { + return nil, false + } + var v []SqlDashboardWidgetOutput + d := o.Widgets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWidgets sets the value of the Widgets field in SqlDashboardOutput. +func (o *SqlDashboardOutput) SetWidgets(ctx context.Context, v []SqlDashboardWidgetOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["widgets"] + o.Widgets = types.ListValueMust(t, vs) +} + type SqlDashboardWidgetOutput struct { // Time (in epoch milliseconds) when execution of the SQL widget ends. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -7418,6 +12238,32 @@ func (o SqlDashboardWidgetOutput) Type(ctx context.Context) attr.Type { } } +// GetError returns the value of the Error field in SqlDashboardWidgetOutput as +// a SqlOutputError value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlDashboardWidgetOutput) GetError(ctx context.Context) (SqlOutputError, bool) { + var e SqlOutputError + if o.Error.IsNull() || o.Error.IsUnknown() { + return e, false + } + var v []SqlOutputError + d := o.Error.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetError sets the value of the Error field in SqlDashboardWidgetOutput. +func (o *SqlDashboardWidgetOutput) SetError(ctx context.Context, v SqlOutputError) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error"] + o.Error = types.ListValueMust(t, vs) +} + type SqlOutput struct { // The output of a SQL alert task, if available. AlertOutput types.List `tfsdk:"alert_output" tf:"optional,object"` @@ -7478,6 +12324,84 @@ func (o SqlOutput) Type(ctx context.Context) attr.Type { } } +// GetAlertOutput returns the value of the AlertOutput field in SqlOutput as +// a SqlAlertOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlOutput) GetAlertOutput(ctx context.Context) (SqlAlertOutput, bool) { + var e SqlAlertOutput + if o.AlertOutput.IsNull() || o.AlertOutput.IsUnknown() { + return e, false + } + var v []SqlAlertOutput + d := o.AlertOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAlertOutput sets the value of the AlertOutput field in SqlOutput. +func (o *SqlOutput) SetAlertOutput(ctx context.Context, v SqlAlertOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_output"] + o.AlertOutput = types.ListValueMust(t, vs) +} + +// GetDashboardOutput returns the value of the DashboardOutput field in SqlOutput as +// a SqlDashboardOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlOutput) GetDashboardOutput(ctx context.Context) (SqlDashboardOutput, bool) { + var e SqlDashboardOutput + if o.DashboardOutput.IsNull() || o.DashboardOutput.IsUnknown() { + return e, false + } + var v []SqlDashboardOutput + d := o.DashboardOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDashboardOutput sets the value of the DashboardOutput field in SqlOutput. +func (o *SqlOutput) SetDashboardOutput(ctx context.Context, v SqlDashboardOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dashboard_output"] + o.DashboardOutput = types.ListValueMust(t, vs) +} + +// GetQueryOutput returns the value of the QueryOutput field in SqlOutput as +// a SqlQueryOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlOutput) GetQueryOutput(ctx context.Context) (SqlQueryOutput, bool) { + var e SqlQueryOutput + if o.QueryOutput.IsNull() || o.QueryOutput.IsUnknown() { + return e, false + } + var v []SqlQueryOutput + d := o.QueryOutput.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueryOutput sets the value of the QueryOutput field in SqlOutput. +func (o *SqlOutput) SetQueryOutput(ctx context.Context, v SqlQueryOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_output"] + o.QueryOutput = types.ListValueMust(t, vs) +} + type SqlOutputError struct { // The error message when execution fails. Message types.String `tfsdk:"message" tf:"optional"` @@ -7582,6 +12506,31 @@ func (o SqlQueryOutput) Type(ctx context.Context) attr.Type { } } +// GetSqlStatements returns the value of the SqlStatements field in SqlQueryOutput as +// a slice of SqlStatementOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlQueryOutput) GetSqlStatements(ctx context.Context) ([]SqlStatementOutput, bool) { + if o.SqlStatements.IsNull() || o.SqlStatements.IsUnknown() { + return nil, false + } + var v []SqlStatementOutput + d := o.SqlStatements.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSqlStatements sets the value of the SqlStatements field in SqlQueryOutput. +func (o *SqlQueryOutput) SetSqlStatements(ctx context.Context, v []SqlStatementOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_statements"] + o.SqlStatements = types.ListValueMust(t, vs) +} + type SqlStatementOutput struct { // A key that can be used to look up query details. LookupKey types.String `tfsdk:"lookup_key" tf:"optional"` @@ -7707,6 +12656,135 @@ func (o SqlTask) Type(ctx context.Context) attr.Type { } } +// GetAlert returns the value of the Alert field in SqlTask as +// a SqlTaskAlert value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTask) GetAlert(ctx context.Context) (SqlTaskAlert, bool) { + var e SqlTaskAlert + if o.Alert.IsNull() || o.Alert.IsUnknown() { + return e, false + } + var v []SqlTaskAlert + d := o.Alert.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAlert sets the value of the Alert field in SqlTask. +func (o *SqlTask) SetAlert(ctx context.Context, v SqlTaskAlert) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert"] + o.Alert = types.ListValueMust(t, vs) +} + +// GetDashboard returns the value of the Dashboard field in SqlTask as +// a SqlTaskDashboard value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTask) GetDashboard(ctx context.Context) (SqlTaskDashboard, bool) { + var e SqlTaskDashboard + if o.Dashboard.IsNull() || o.Dashboard.IsUnknown() { + return e, false + } + var v []SqlTaskDashboard + d := o.Dashboard.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDashboard sets the value of the Dashboard field in SqlTask. +func (o *SqlTask) SetDashboard(ctx context.Context, v SqlTaskDashboard) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dashboard"] + o.Dashboard = types.ListValueMust(t, vs) +} + +// GetFile returns the value of the File field in SqlTask as +// a SqlTaskFile value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTask) GetFile(ctx context.Context) (SqlTaskFile, bool) { + var e SqlTaskFile + if o.File.IsNull() || o.File.IsUnknown() { + return e, false + } + var v []SqlTaskFile + d := o.File.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFile sets the value of the File field in SqlTask. +func (o *SqlTask) SetFile(ctx context.Context, v SqlTaskFile) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file"] + o.File = types.ListValueMust(t, vs) +} + +// GetParameters returns the value of the Parameters field in SqlTask as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTask) GetParameters(ctx context.Context) (map[string]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in SqlTask. +func (o *SqlTask) SetParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.MapValueMust(t, vs) +} + +// GetQuery returns the value of the Query field in SqlTask as +// a SqlTaskQuery value. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTask) GetQuery(ctx context.Context) (SqlTaskQuery, bool) { + var e SqlTaskQuery + if o.Query.IsNull() || o.Query.IsUnknown() { + return e, false + } + var v []SqlTaskQuery + d := o.Query.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuery sets the value of the Query field in SqlTask. +func (o *SqlTask) SetQuery(ctx context.Context, v SqlTaskQuery) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query"] + o.Query = types.ListValueMust(t, vs) +} + type SqlTaskAlert struct { // The canonical identifier of the SQL alert. AlertId types.String `tfsdk:"alert_id" tf:""` @@ -7761,6 +12839,31 @@ func (o SqlTaskAlert) Type(ctx context.Context) attr.Type { } } +// GetSubscriptions returns the value of the Subscriptions field in SqlTaskAlert as +// a slice of SqlTaskSubscription values. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTaskAlert) GetSubscriptions(ctx context.Context) ([]SqlTaskSubscription, bool) { + if o.Subscriptions.IsNull() || o.Subscriptions.IsUnknown() { + return nil, false + } + var v []SqlTaskSubscription + d := o.Subscriptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSubscriptions sets the value of the Subscriptions field in SqlTaskAlert. +func (o *SqlTaskAlert) SetSubscriptions(ctx context.Context, v []SqlTaskSubscription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriptions"] + o.Subscriptions = types.ListValueMust(t, vs) +} + type SqlTaskDashboard struct { // Subject of the email sent to subscribers of this task. CustomSubject types.String `tfsdk:"custom_subject" tf:"optional"` @@ -7820,6 +12923,31 @@ func (o SqlTaskDashboard) Type(ctx context.Context) attr.Type { } } +// GetSubscriptions returns the value of the Subscriptions field in SqlTaskDashboard as +// a slice of SqlTaskSubscription values. +// If the field is unknown or null, the boolean return value is false. +func (o *SqlTaskDashboard) GetSubscriptions(ctx context.Context) ([]SqlTaskSubscription, bool) { + if o.Subscriptions.IsNull() || o.Subscriptions.IsUnknown() { + return nil, false + } + var v []SqlTaskSubscription + d := o.Subscriptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSubscriptions sets the value of the Subscriptions field in SqlTaskDashboard. +func (o *SqlTaskDashboard) SetSubscriptions(ctx context.Context, v []SqlTaskSubscription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriptions"] + o.Subscriptions = types.ListValueMust(t, vs) +} + type SqlTaskFile struct { // Path of the SQL file. Must be relative if the source is a remote Git // repository and absolute for workspace paths. @@ -8123,6 +13251,263 @@ func (o SubmitRun) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in SubmitRun as +// a slice of JobAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetAccessControlList(ctx context.Context) ([]JobAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []JobAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in SubmitRun. +func (o *SubmitRun) SetAccessControlList(ctx context.Context, v []JobAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + +// GetEmailNotifications returns the value of the EmailNotifications field in SubmitRun as +// a JobEmailNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetEmailNotifications(ctx context.Context) (JobEmailNotifications, bool) { + var e JobEmailNotifications + if o.EmailNotifications.IsNull() || o.EmailNotifications.IsUnknown() { + return e, false + } + var v []JobEmailNotifications + d := o.EmailNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEmailNotifications sets the value of the EmailNotifications field in SubmitRun. +func (o *SubmitRun) SetEmailNotifications(ctx context.Context, v JobEmailNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_notifications"] + o.EmailNotifications = types.ListValueMust(t, vs) +} + +// GetEnvironments returns the value of the Environments field in SubmitRun as +// a slice of JobEnvironment values. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetEnvironments(ctx context.Context) ([]JobEnvironment, bool) { + if o.Environments.IsNull() || o.Environments.IsUnknown() { + return nil, false + } + var v []JobEnvironment + d := o.Environments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnvironments sets the value of the Environments field in SubmitRun. +func (o *SubmitRun) SetEnvironments(ctx context.Context, v []JobEnvironment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environments"] + o.Environments = types.ListValueMust(t, vs) +} + +// GetGitSource returns the value of the GitSource field in SubmitRun as +// a GitSource value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetGitSource(ctx context.Context) (GitSource, bool) { + var e GitSource + if o.GitSource.IsNull() || o.GitSource.IsUnknown() { + return e, false + } + var v []GitSource + d := o.GitSource.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitSource sets the value of the GitSource field in SubmitRun. +func (o *SubmitRun) SetGitSource(ctx context.Context, v GitSource) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_source"] + o.GitSource = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in SubmitRun as +// a JobsHealthRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetHealth(ctx context.Context) (JobsHealthRules, bool) { + var e JobsHealthRules + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []JobsHealthRules + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in SubmitRun. +func (o *SubmitRun) SetHealth(ctx context.Context, v JobsHealthRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetNotificationSettings returns the value of the NotificationSettings field in SubmitRun as +// a JobNotificationSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetNotificationSettings(ctx context.Context) (JobNotificationSettings, bool) { + var e JobNotificationSettings + if o.NotificationSettings.IsNull() || o.NotificationSettings.IsUnknown() { + return e, false + } + var v []JobNotificationSettings + d := o.NotificationSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotificationSettings sets the value of the NotificationSettings field in SubmitRun. +func (o *SubmitRun) SetNotificationSettings(ctx context.Context, v JobNotificationSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notification_settings"] + o.NotificationSettings = types.ListValueMust(t, vs) +} + +// GetQueue returns the value of the Queue field in SubmitRun as +// a QueueSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetQueue(ctx context.Context) (QueueSettings, bool) { + var e QueueSettings + if o.Queue.IsNull() || o.Queue.IsUnknown() { + return e, false + } + var v []QueueSettings + d := o.Queue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueue sets the value of the Queue field in SubmitRun. +func (o *SubmitRun) SetQueue(ctx context.Context, v QueueSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["queue"] + o.Queue = types.ListValueMust(t, vs) +} + +// GetRunAs returns the value of the RunAs field in SubmitRun as +// a JobRunAs value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetRunAs(ctx context.Context) (JobRunAs, bool) { + var e JobRunAs + if o.RunAs.IsNull() || o.RunAs.IsUnknown() { + return e, false + } + var v []JobRunAs + d := o.RunAs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunAs sets the value of the RunAs field in SubmitRun. +func (o *SubmitRun) SetRunAs(ctx context.Context, v JobRunAs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_as"] + o.RunAs = types.ListValueMust(t, vs) +} + +// GetTasks returns the value of the Tasks field in SubmitRun as +// a slice of SubmitTask values. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetTasks(ctx context.Context) ([]SubmitTask, bool) { + if o.Tasks.IsNull() || o.Tasks.IsUnknown() { + return nil, false + } + var v []SubmitTask + d := o.Tasks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTasks sets the value of the Tasks field in SubmitRun. +func (o *SubmitRun) SetTasks(ctx context.Context, v []SubmitTask) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tasks"] + o.Tasks = types.ListValueMust(t, vs) +} + +// GetWebhookNotifications returns the value of the WebhookNotifications field in SubmitRun as +// a WebhookNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitRun) GetWebhookNotifications(ctx context.Context) (WebhookNotifications, bool) { + var e WebhookNotifications + if o.WebhookNotifications.IsNull() || o.WebhookNotifications.IsUnknown() { + return e, false + } + var v []WebhookNotifications + d := o.WebhookNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhookNotifications sets the value of the WebhookNotifications field in SubmitRun. +func (o *SubmitRun) SetWebhookNotifications(ctx context.Context, v WebhookNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook_notifications"] + o.WebhookNotifications = types.ListValueMust(t, vs) +} + // Run was created and started successfully. type SubmitRunResponse struct { // The canonical identifier for the newly submitted run. @@ -8287,8 +13672,8 @@ func (a SubmitTask) GetComplexFieldTypes(ctx context.Context) map[string]reflect "email_notifications": reflect.TypeOf(JobEmailNotifications{}), "for_each_task": reflect.TypeOf(ForEachTask{}), "health": reflect.TypeOf(JobsHealthRules{}), - "library": reflect.TypeOf(compute.Library{}), - "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "library": reflect.TypeOf(compute_tf.Library{}), + "new_cluster": reflect.TypeOf(compute_tf.ClusterSpec{}), "notebook_task": reflect.TypeOf(NotebookTask{}), "notification_settings": reflect.TypeOf(TaskNotificationSettings{}), "pipeline_task": reflect.TypeOf(PipelineTask{}), @@ -8404,6 +13789,472 @@ func (o SubmitTask) Type(ctx context.Context) attr.Type { } } +// GetConditionTask returns the value of the ConditionTask field in SubmitTask as +// a ConditionTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetConditionTask(ctx context.Context) (ConditionTask, bool) { + var e ConditionTask + if o.ConditionTask.IsNull() || o.ConditionTask.IsUnknown() { + return e, false + } + var v []ConditionTask + d := o.ConditionTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConditionTask sets the value of the ConditionTask field in SubmitTask. +func (o *SubmitTask) SetConditionTask(ctx context.Context, v ConditionTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition_task"] + o.ConditionTask = types.ListValueMust(t, vs) +} + +// GetDbtTask returns the value of the DbtTask field in SubmitTask as +// a DbtTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetDbtTask(ctx context.Context) (DbtTask, bool) { + var e DbtTask + if o.DbtTask.IsNull() || o.DbtTask.IsUnknown() { + return e, false + } + var v []DbtTask + d := o.DbtTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbtTask sets the value of the DbtTask field in SubmitTask. +func (o *SubmitTask) SetDbtTask(ctx context.Context, v DbtTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_task"] + o.DbtTask = types.ListValueMust(t, vs) +} + +// GetDependsOn returns the value of the DependsOn field in SubmitTask as +// a slice of TaskDependency values. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetDependsOn(ctx context.Context) ([]TaskDependency, bool) { + if o.DependsOn.IsNull() || o.DependsOn.IsUnknown() { + return nil, false + } + var v []TaskDependency + d := o.DependsOn.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDependsOn sets the value of the DependsOn field in SubmitTask. +func (o *SubmitTask) SetDependsOn(ctx context.Context, v []TaskDependency) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["depends_on"] + o.DependsOn = types.ListValueMust(t, vs) +} + +// GetEmailNotifications returns the value of the EmailNotifications field in SubmitTask as +// a JobEmailNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetEmailNotifications(ctx context.Context) (JobEmailNotifications, bool) { + var e JobEmailNotifications + if o.EmailNotifications.IsNull() || o.EmailNotifications.IsUnknown() { + return e, false + } + var v []JobEmailNotifications + d := o.EmailNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEmailNotifications sets the value of the EmailNotifications field in SubmitTask. +func (o *SubmitTask) SetEmailNotifications(ctx context.Context, v JobEmailNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_notifications"] + o.EmailNotifications = types.ListValueMust(t, vs) +} + +// GetForEachTask returns the value of the ForEachTask field in SubmitTask as +// a ForEachTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetForEachTask(ctx context.Context) (ForEachTask, bool) { + var e ForEachTask + if o.ForEachTask.IsNull() || o.ForEachTask.IsUnknown() { + return e, false + } + var v []ForEachTask + d := o.ForEachTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetForEachTask sets the value of the ForEachTask field in SubmitTask. +func (o *SubmitTask) SetForEachTask(ctx context.Context, v ForEachTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["for_each_task"] + o.ForEachTask = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in SubmitTask as +// a JobsHealthRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetHealth(ctx context.Context) (JobsHealthRules, bool) { + var e JobsHealthRules + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []JobsHealthRules + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in SubmitTask. +func (o *SubmitTask) SetHealth(ctx context.Context, v JobsHealthRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetLibraries returns the value of the Libraries field in SubmitTask as +// a slice of compute_tf.Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetLibraries(ctx context.Context) ([]compute_tf.Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []compute_tf.Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in SubmitTask. +func (o *SubmitTask) SetLibraries(ctx context.Context, v []compute_tf.Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNewCluster returns the value of the NewCluster field in SubmitTask as +// a compute_tf.ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetNewCluster(ctx context.Context) (compute_tf.ClusterSpec, bool) { + var e compute_tf.ClusterSpec + if o.NewCluster.IsNull() || o.NewCluster.IsUnknown() { + return e, false + } + var v []compute_tf.ClusterSpec + d := o.NewCluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewCluster sets the value of the NewCluster field in SubmitTask. +func (o *SubmitTask) SetNewCluster(ctx context.Context, v compute_tf.ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_cluster"] + o.NewCluster = types.ListValueMust(t, vs) +} + +// GetNotebookTask returns the value of the NotebookTask field in SubmitTask as +// a NotebookTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetNotebookTask(ctx context.Context) (NotebookTask, bool) { + var e NotebookTask + if o.NotebookTask.IsNull() || o.NotebookTask.IsUnknown() { + return e, false + } + var v []NotebookTask + d := o.NotebookTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotebookTask sets the value of the NotebookTask field in SubmitTask. +func (o *SubmitTask) SetNotebookTask(ctx context.Context, v NotebookTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_task"] + o.NotebookTask = types.ListValueMust(t, vs) +} + +// GetNotificationSettings returns the value of the NotificationSettings field in SubmitTask as +// a TaskNotificationSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetNotificationSettings(ctx context.Context) (TaskNotificationSettings, bool) { + var e TaskNotificationSettings + if o.NotificationSettings.IsNull() || o.NotificationSettings.IsUnknown() { + return e, false + } + var v []TaskNotificationSettings + d := o.NotificationSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotificationSettings sets the value of the NotificationSettings field in SubmitTask. +func (o *SubmitTask) SetNotificationSettings(ctx context.Context, v TaskNotificationSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notification_settings"] + o.NotificationSettings = types.ListValueMust(t, vs) +} + +// GetPipelineTask returns the value of the PipelineTask field in SubmitTask as +// a PipelineTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetPipelineTask(ctx context.Context) (PipelineTask, bool) { + var e PipelineTask + if o.PipelineTask.IsNull() || o.PipelineTask.IsUnknown() { + return e, false + } + var v []PipelineTask + d := o.PipelineTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineTask sets the value of the PipelineTask field in SubmitTask. +func (o *SubmitTask) SetPipelineTask(ctx context.Context, v PipelineTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_task"] + o.PipelineTask = types.ListValueMust(t, vs) +} + +// GetPythonWheelTask returns the value of the PythonWheelTask field in SubmitTask as +// a PythonWheelTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetPythonWheelTask(ctx context.Context) (PythonWheelTask, bool) { + var e PythonWheelTask + if o.PythonWheelTask.IsNull() || o.PythonWheelTask.IsUnknown() { + return e, false + } + var v []PythonWheelTask + d := o.PythonWheelTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPythonWheelTask sets the value of the PythonWheelTask field in SubmitTask. +func (o *SubmitTask) SetPythonWheelTask(ctx context.Context, v PythonWheelTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_wheel_task"] + o.PythonWheelTask = types.ListValueMust(t, vs) +} + +// GetRunJobTask returns the value of the RunJobTask field in SubmitTask as +// a RunJobTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetRunJobTask(ctx context.Context) (RunJobTask, bool) { + var e RunJobTask + if o.RunJobTask.IsNull() || o.RunJobTask.IsUnknown() { + return e, false + } + var v []RunJobTask + d := o.RunJobTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunJobTask sets the value of the RunJobTask field in SubmitTask. +func (o *SubmitTask) SetRunJobTask(ctx context.Context, v RunJobTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_job_task"] + o.RunJobTask = types.ListValueMust(t, vs) +} + +// GetSparkJarTask returns the value of the SparkJarTask field in SubmitTask as +// a SparkJarTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetSparkJarTask(ctx context.Context) (SparkJarTask, bool) { + var e SparkJarTask + if o.SparkJarTask.IsNull() || o.SparkJarTask.IsUnknown() { + return e, false + } + var v []SparkJarTask + d := o.SparkJarTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkJarTask sets the value of the SparkJarTask field in SubmitTask. +func (o *SubmitTask) SetSparkJarTask(ctx context.Context, v SparkJarTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_jar_task"] + o.SparkJarTask = types.ListValueMust(t, vs) +} + +// GetSparkPythonTask returns the value of the SparkPythonTask field in SubmitTask as +// a SparkPythonTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetSparkPythonTask(ctx context.Context) (SparkPythonTask, bool) { + var e SparkPythonTask + if o.SparkPythonTask.IsNull() || o.SparkPythonTask.IsUnknown() { + return e, false + } + var v []SparkPythonTask + d := o.SparkPythonTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkPythonTask sets the value of the SparkPythonTask field in SubmitTask. +func (o *SubmitTask) SetSparkPythonTask(ctx context.Context, v SparkPythonTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_python_task"] + o.SparkPythonTask = types.ListValueMust(t, vs) +} + +// GetSparkSubmitTask returns the value of the SparkSubmitTask field in SubmitTask as +// a SparkSubmitTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetSparkSubmitTask(ctx context.Context) (SparkSubmitTask, bool) { + var e SparkSubmitTask + if o.SparkSubmitTask.IsNull() || o.SparkSubmitTask.IsUnknown() { + return e, false + } + var v []SparkSubmitTask + d := o.SparkSubmitTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkSubmitTask sets the value of the SparkSubmitTask field in SubmitTask. +func (o *SubmitTask) SetSparkSubmitTask(ctx context.Context, v SparkSubmitTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_task"] + o.SparkSubmitTask = types.ListValueMust(t, vs) +} + +// GetSqlTask returns the value of the SqlTask field in SubmitTask as +// a SqlTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetSqlTask(ctx context.Context) (SqlTask, bool) { + var e SqlTask + if o.SqlTask.IsNull() || o.SqlTask.IsUnknown() { + return e, false + } + var v []SqlTask + d := o.SqlTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlTask sets the value of the SqlTask field in SubmitTask. +func (o *SubmitTask) SetSqlTask(ctx context.Context, v SqlTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_task"] + o.SqlTask = types.ListValueMust(t, vs) +} + +// GetWebhookNotifications returns the value of the WebhookNotifications field in SubmitTask as +// a WebhookNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *SubmitTask) GetWebhookNotifications(ctx context.Context) (WebhookNotifications, bool) { + var e WebhookNotifications + if o.WebhookNotifications.IsNull() || o.WebhookNotifications.IsUnknown() { + return e, false + } + var v []WebhookNotifications + d := o.WebhookNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhookNotifications sets the value of the WebhookNotifications field in SubmitTask. +func (o *SubmitTask) SetWebhookNotifications(ctx context.Context, v WebhookNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook_notifications"] + o.WebhookNotifications = types.ListValueMust(t, vs) +} + type TableUpdateTriggerConfiguration struct { // The table(s) condition based on which to trigger a job run. Condition types.String `tfsdk:"condition" tf:"optional"` @@ -8468,6 +14319,31 @@ func (o TableUpdateTriggerConfiguration) Type(ctx context.Context) attr.Type { } } +// GetTableNames returns the value of the TableNames field in TableUpdateTriggerConfiguration as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableUpdateTriggerConfiguration) GetTableNames(ctx context.Context) ([]types.String, bool) { + if o.TableNames.IsNull() || o.TableNames.IsUnknown() { + return nil, false + } + var v []types.String + d := o.TableNames.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTableNames sets the value of the TableNames field in TableUpdateTriggerConfiguration. +func (o *TableUpdateTriggerConfiguration) SetTableNames(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_names"] + o.TableNames = types.ListValueMust(t, vs) +} + type Task struct { // The task evaluates a condition that can be used to control the execution // of other tasks when the `condition_task` field is present. The condition @@ -8612,8 +14488,8 @@ func (a Task) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type "email_notifications": reflect.TypeOf(TaskEmailNotifications{}), "for_each_task": reflect.TypeOf(ForEachTask{}), "health": reflect.TypeOf(JobsHealthRules{}), - "library": reflect.TypeOf(compute.Library{}), - "new_cluster": reflect.TypeOf(compute.ClusterSpec{}), + "library": reflect.TypeOf(compute_tf.Library{}), + "new_cluster": reflect.TypeOf(compute_tf.ClusterSpec{}), "notebook_task": reflect.TypeOf(NotebookTask{}), "notification_settings": reflect.TypeOf(TaskNotificationSettings{}), "pipeline_task": reflect.TypeOf(PipelineTask{}), @@ -8739,6 +14615,472 @@ func (o Task) Type(ctx context.Context) attr.Type { } } +// GetConditionTask returns the value of the ConditionTask field in Task as +// a ConditionTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetConditionTask(ctx context.Context) (ConditionTask, bool) { + var e ConditionTask + if o.ConditionTask.IsNull() || o.ConditionTask.IsUnknown() { + return e, false + } + var v []ConditionTask + d := o.ConditionTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConditionTask sets the value of the ConditionTask field in Task. +func (o *Task) SetConditionTask(ctx context.Context, v ConditionTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition_task"] + o.ConditionTask = types.ListValueMust(t, vs) +} + +// GetDbtTask returns the value of the DbtTask field in Task as +// a DbtTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetDbtTask(ctx context.Context) (DbtTask, bool) { + var e DbtTask + if o.DbtTask.IsNull() || o.DbtTask.IsUnknown() { + return e, false + } + var v []DbtTask + d := o.DbtTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDbtTask sets the value of the DbtTask field in Task. +func (o *Task) SetDbtTask(ctx context.Context, v DbtTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_task"] + o.DbtTask = types.ListValueMust(t, vs) +} + +// GetDependsOn returns the value of the DependsOn field in Task as +// a slice of TaskDependency values. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetDependsOn(ctx context.Context) ([]TaskDependency, bool) { + if o.DependsOn.IsNull() || o.DependsOn.IsUnknown() { + return nil, false + } + var v []TaskDependency + d := o.DependsOn.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDependsOn sets the value of the DependsOn field in Task. +func (o *Task) SetDependsOn(ctx context.Context, v []TaskDependency) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["depends_on"] + o.DependsOn = types.ListValueMust(t, vs) +} + +// GetEmailNotifications returns the value of the EmailNotifications field in Task as +// a TaskEmailNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetEmailNotifications(ctx context.Context) (TaskEmailNotifications, bool) { + var e TaskEmailNotifications + if o.EmailNotifications.IsNull() || o.EmailNotifications.IsUnknown() { + return e, false + } + var v []TaskEmailNotifications + d := o.EmailNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEmailNotifications sets the value of the EmailNotifications field in Task. +func (o *Task) SetEmailNotifications(ctx context.Context, v TaskEmailNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_notifications"] + o.EmailNotifications = types.ListValueMust(t, vs) +} + +// GetForEachTask returns the value of the ForEachTask field in Task as +// a ForEachTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetForEachTask(ctx context.Context) (ForEachTask, bool) { + var e ForEachTask + if o.ForEachTask.IsNull() || o.ForEachTask.IsUnknown() { + return e, false + } + var v []ForEachTask + d := o.ForEachTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetForEachTask sets the value of the ForEachTask field in Task. +func (o *Task) SetForEachTask(ctx context.Context, v ForEachTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["for_each_task"] + o.ForEachTask = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in Task as +// a JobsHealthRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetHealth(ctx context.Context) (JobsHealthRules, bool) { + var e JobsHealthRules + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []JobsHealthRules + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in Task. +func (o *Task) SetHealth(ctx context.Context, v JobsHealthRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetLibraries returns the value of the Libraries field in Task as +// a slice of compute_tf.Library values. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetLibraries(ctx context.Context) ([]compute_tf.Library, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []compute_tf.Library + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in Task. +func (o *Task) SetLibraries(ctx context.Context, v []compute_tf.Library) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNewCluster returns the value of the NewCluster field in Task as +// a compute_tf.ClusterSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetNewCluster(ctx context.Context) (compute_tf.ClusterSpec, bool) { + var e compute_tf.ClusterSpec + if o.NewCluster.IsNull() || o.NewCluster.IsUnknown() { + return e, false + } + var v []compute_tf.ClusterSpec + d := o.NewCluster.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewCluster sets the value of the NewCluster field in Task. +func (o *Task) SetNewCluster(ctx context.Context, v compute_tf.ClusterSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_cluster"] + o.NewCluster = types.ListValueMust(t, vs) +} + +// GetNotebookTask returns the value of the NotebookTask field in Task as +// a NotebookTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetNotebookTask(ctx context.Context) (NotebookTask, bool) { + var e NotebookTask + if o.NotebookTask.IsNull() || o.NotebookTask.IsUnknown() { + return e, false + } + var v []NotebookTask + d := o.NotebookTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotebookTask sets the value of the NotebookTask field in Task. +func (o *Task) SetNotebookTask(ctx context.Context, v NotebookTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_task"] + o.NotebookTask = types.ListValueMust(t, vs) +} + +// GetNotificationSettings returns the value of the NotificationSettings field in Task as +// a TaskNotificationSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetNotificationSettings(ctx context.Context) (TaskNotificationSettings, bool) { + var e TaskNotificationSettings + if o.NotificationSettings.IsNull() || o.NotificationSettings.IsUnknown() { + return e, false + } + var v []TaskNotificationSettings + d := o.NotificationSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotificationSettings sets the value of the NotificationSettings field in Task. +func (o *Task) SetNotificationSettings(ctx context.Context, v TaskNotificationSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notification_settings"] + o.NotificationSettings = types.ListValueMust(t, vs) +} + +// GetPipelineTask returns the value of the PipelineTask field in Task as +// a PipelineTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetPipelineTask(ctx context.Context) (PipelineTask, bool) { + var e PipelineTask + if o.PipelineTask.IsNull() || o.PipelineTask.IsUnknown() { + return e, false + } + var v []PipelineTask + d := o.PipelineTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPipelineTask sets the value of the PipelineTask field in Task. +func (o *Task) SetPipelineTask(ctx context.Context, v PipelineTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pipeline_task"] + o.PipelineTask = types.ListValueMust(t, vs) +} + +// GetPythonWheelTask returns the value of the PythonWheelTask field in Task as +// a PythonWheelTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetPythonWheelTask(ctx context.Context) (PythonWheelTask, bool) { + var e PythonWheelTask + if o.PythonWheelTask.IsNull() || o.PythonWheelTask.IsUnknown() { + return e, false + } + var v []PythonWheelTask + d := o.PythonWheelTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPythonWheelTask sets the value of the PythonWheelTask field in Task. +func (o *Task) SetPythonWheelTask(ctx context.Context, v PythonWheelTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_wheel_task"] + o.PythonWheelTask = types.ListValueMust(t, vs) +} + +// GetRunJobTask returns the value of the RunJobTask field in Task as +// a RunJobTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetRunJobTask(ctx context.Context) (RunJobTask, bool) { + var e RunJobTask + if o.RunJobTask.IsNull() || o.RunJobTask.IsUnknown() { + return e, false + } + var v []RunJobTask + d := o.RunJobTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunJobTask sets the value of the RunJobTask field in Task. +func (o *Task) SetRunJobTask(ctx context.Context, v RunJobTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_job_task"] + o.RunJobTask = types.ListValueMust(t, vs) +} + +// GetSparkJarTask returns the value of the SparkJarTask field in Task as +// a SparkJarTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetSparkJarTask(ctx context.Context) (SparkJarTask, bool) { + var e SparkJarTask + if o.SparkJarTask.IsNull() || o.SparkJarTask.IsUnknown() { + return e, false + } + var v []SparkJarTask + d := o.SparkJarTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkJarTask sets the value of the SparkJarTask field in Task. +func (o *Task) SetSparkJarTask(ctx context.Context, v SparkJarTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_jar_task"] + o.SparkJarTask = types.ListValueMust(t, vs) +} + +// GetSparkPythonTask returns the value of the SparkPythonTask field in Task as +// a SparkPythonTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetSparkPythonTask(ctx context.Context) (SparkPythonTask, bool) { + var e SparkPythonTask + if o.SparkPythonTask.IsNull() || o.SparkPythonTask.IsUnknown() { + return e, false + } + var v []SparkPythonTask + d := o.SparkPythonTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkPythonTask sets the value of the SparkPythonTask field in Task. +func (o *Task) SetSparkPythonTask(ctx context.Context, v SparkPythonTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_python_task"] + o.SparkPythonTask = types.ListValueMust(t, vs) +} + +// GetSparkSubmitTask returns the value of the SparkSubmitTask field in Task as +// a SparkSubmitTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetSparkSubmitTask(ctx context.Context) (SparkSubmitTask, bool) { + var e SparkSubmitTask + if o.SparkSubmitTask.IsNull() || o.SparkSubmitTask.IsUnknown() { + return e, false + } + var v []SparkSubmitTask + d := o.SparkSubmitTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparkSubmitTask sets the value of the SparkSubmitTask field in Task. +func (o *Task) SetSparkSubmitTask(ctx context.Context, v SparkSubmitTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_task"] + o.SparkSubmitTask = types.ListValueMust(t, vs) +} + +// GetSqlTask returns the value of the SqlTask field in Task as +// a SqlTask value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetSqlTask(ctx context.Context) (SqlTask, bool) { + var e SqlTask + if o.SqlTask.IsNull() || o.SqlTask.IsUnknown() { + return e, false + } + var v []SqlTask + d := o.SqlTask.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlTask sets the value of the SqlTask field in Task. +func (o *Task) SetSqlTask(ctx context.Context, v SqlTask) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_task"] + o.SqlTask = types.ListValueMust(t, vs) +} + +// GetWebhookNotifications returns the value of the WebhookNotifications field in Task as +// a WebhookNotifications value. +// If the field is unknown or null, the boolean return value is false. +func (o *Task) GetWebhookNotifications(ctx context.Context) (WebhookNotifications, bool) { + var e WebhookNotifications + if o.WebhookNotifications.IsNull() || o.WebhookNotifications.IsUnknown() { + return e, false + } + var v []WebhookNotifications + d := o.WebhookNotifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhookNotifications sets the value of the WebhookNotifications field in Task. +func (o *Task) SetWebhookNotifications(ctx context.Context, v WebhookNotifications) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook_notifications"] + o.WebhookNotifications = types.ListValueMust(t, vs) +} + type TaskDependency struct { // Can only be specified on condition task dependencies. The outcome of the // dependent task that must be met for this task to run. @@ -8885,6 +15227,131 @@ func (o TaskEmailNotifications) Type(ctx context.Context) attr.Type { } } +// GetOnDurationWarningThresholdExceeded returns the value of the OnDurationWarningThresholdExceeded field in TaskEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TaskEmailNotifications) GetOnDurationWarningThresholdExceeded(ctx context.Context) ([]types.String, bool) { + if o.OnDurationWarningThresholdExceeded.IsNull() || o.OnDurationWarningThresholdExceeded.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnDurationWarningThresholdExceeded.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnDurationWarningThresholdExceeded sets the value of the OnDurationWarningThresholdExceeded field in TaskEmailNotifications. +func (o *TaskEmailNotifications) SetOnDurationWarningThresholdExceeded(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_duration_warning_threshold_exceeded"] + o.OnDurationWarningThresholdExceeded = types.ListValueMust(t, vs) +} + +// GetOnFailure returns the value of the OnFailure field in TaskEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TaskEmailNotifications) GetOnFailure(ctx context.Context) ([]types.String, bool) { + if o.OnFailure.IsNull() || o.OnFailure.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnFailure.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnFailure sets the value of the OnFailure field in TaskEmailNotifications. +func (o *TaskEmailNotifications) SetOnFailure(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + o.OnFailure = types.ListValueMust(t, vs) +} + +// GetOnStart returns the value of the OnStart field in TaskEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TaskEmailNotifications) GetOnStart(ctx context.Context) ([]types.String, bool) { + if o.OnStart.IsNull() || o.OnStart.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnStart.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnStart sets the value of the OnStart field in TaskEmailNotifications. +func (o *TaskEmailNotifications) SetOnStart(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_start"] + o.OnStart = types.ListValueMust(t, vs) +} + +// GetOnStreamingBacklogExceeded returns the value of the OnStreamingBacklogExceeded field in TaskEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TaskEmailNotifications) GetOnStreamingBacklogExceeded(ctx context.Context) ([]types.String, bool) { + if o.OnStreamingBacklogExceeded.IsNull() || o.OnStreamingBacklogExceeded.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnStreamingBacklogExceeded.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnStreamingBacklogExceeded sets the value of the OnStreamingBacklogExceeded field in TaskEmailNotifications. +func (o *TaskEmailNotifications) SetOnStreamingBacklogExceeded(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_streaming_backlog_exceeded"] + o.OnStreamingBacklogExceeded = types.ListValueMust(t, vs) +} + +// GetOnSuccess returns the value of the OnSuccess field in TaskEmailNotifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TaskEmailNotifications) GetOnSuccess(ctx context.Context) ([]types.String, bool) { + if o.OnSuccess.IsNull() || o.OnSuccess.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OnSuccess.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOnSuccess sets the value of the OnSuccess field in TaskEmailNotifications. +func (o *TaskEmailNotifications) SetOnSuccess(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_success"] + o.OnSuccess = types.ListValueMust(t, vs) +} + type TaskNotificationSettings struct { // If true, do not send notifications to recipients specified in `on_start` // for the retried runs and do not send notifications to recipients @@ -9155,6 +15622,110 @@ func (o TriggerSettings) Type(ctx context.Context) attr.Type { } } +// GetFileArrival returns the value of the FileArrival field in TriggerSettings as +// a FileArrivalTriggerConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *TriggerSettings) GetFileArrival(ctx context.Context) (FileArrivalTriggerConfiguration, bool) { + var e FileArrivalTriggerConfiguration + if o.FileArrival.IsNull() || o.FileArrival.IsUnknown() { + return e, false + } + var v []FileArrivalTriggerConfiguration + d := o.FileArrival.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFileArrival sets the value of the FileArrival field in TriggerSettings. +func (o *TriggerSettings) SetFileArrival(ctx context.Context, v FileArrivalTriggerConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_arrival"] + o.FileArrival = types.ListValueMust(t, vs) +} + +// GetPeriodic returns the value of the Periodic field in TriggerSettings as +// a PeriodicTriggerConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *TriggerSettings) GetPeriodic(ctx context.Context) (PeriodicTriggerConfiguration, bool) { + var e PeriodicTriggerConfiguration + if o.Periodic.IsNull() || o.Periodic.IsUnknown() { + return e, false + } + var v []PeriodicTriggerConfiguration + d := o.Periodic.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPeriodic sets the value of the Periodic field in TriggerSettings. +func (o *TriggerSettings) SetPeriodic(ctx context.Context, v PeriodicTriggerConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["periodic"] + o.Periodic = types.ListValueMust(t, vs) +} + +// GetTable returns the value of the Table field in TriggerSettings as +// a TableUpdateTriggerConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *TriggerSettings) GetTable(ctx context.Context) (TableUpdateTriggerConfiguration, bool) { + var e TableUpdateTriggerConfiguration + if o.Table.IsNull() || o.Table.IsUnknown() { + return e, false + } + var v []TableUpdateTriggerConfiguration + d := o.Table.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTable sets the value of the Table field in TriggerSettings. +func (o *TriggerSettings) SetTable(ctx context.Context, v TableUpdateTriggerConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table"] + o.Table = types.ListValueMust(t, vs) +} + +// GetTableUpdate returns the value of the TableUpdate field in TriggerSettings as +// a TableUpdateTriggerConfiguration value. +// If the field is unknown or null, the boolean return value is false. +func (o *TriggerSettings) GetTableUpdate(ctx context.Context) (TableUpdateTriggerConfiguration, bool) { + var e TableUpdateTriggerConfiguration + if o.TableUpdate.IsNull() || o.TableUpdate.IsUnknown() { + return e, false + } + var v []TableUpdateTriggerConfiguration + d := o.TableUpdate.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTableUpdate sets the value of the TableUpdate field in TriggerSettings. +func (o *TriggerSettings) SetTableUpdate(ctx context.Context, v TableUpdateTriggerConfiguration) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_update"] + o.TableUpdate = types.ListValueMust(t, vs) +} + type UpdateJob struct { // Remove top-level fields in the job settings. Removing nested fields is // not supported, except for tasks and job clusters (`tasks/task_1`). This @@ -9224,6 +15795,57 @@ func (o UpdateJob) Type(ctx context.Context) attr.Type { } } +// GetFieldsToRemove returns the value of the FieldsToRemove field in UpdateJob as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateJob) GetFieldsToRemove(ctx context.Context) ([]types.String, bool) { + if o.FieldsToRemove.IsNull() || o.FieldsToRemove.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FieldsToRemove.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFieldsToRemove sets the value of the FieldsToRemove field in UpdateJob. +func (o *UpdateJob) SetFieldsToRemove(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fields_to_remove"] + o.FieldsToRemove = types.ListValueMust(t, vs) +} + +// GetNewSettings returns the value of the NewSettings field in UpdateJob as +// a JobSettings value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateJob) GetNewSettings(ctx context.Context) (JobSettings, bool) { + var e JobSettings + if o.NewSettings.IsNull() || o.NewSettings.IsUnknown() { + return e, false + } + var v []JobSettings + d := o.NewSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNewSettings sets the value of the NewSettings field in UpdateJob. +func (o *UpdateJob) SetNewSettings(ctx context.Context, v JobSettings) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["new_settings"] + o.NewSettings = types.ListValueMust(t, vs) +} + type UpdateResponse struct { } @@ -9441,189 +16063,127 @@ func (o WebhookNotifications) Type(ctx context.Context) attr.Type { } } -// * `EQUAL_TO`, `NOT_EQUAL` operators perform string comparison of their -// operands. This means that `“12.0” == “12”` will evaluate to `false`. -// * `GREATER_THAN`, `GREATER_THAN_OR_EQUAL`, `LESS_THAN`, `LESS_THAN_OR_EQUAL` -// operators perform numeric comparison of their operands. `“12.0” >= -// “12”` will evaluate to `true`, `“10.0” >= “12”` will evaluate to -// `false`. -// -// The boolean comparison to task values can be implemented with operators -// `EQUAL_TO`, `NOT_EQUAL`. If a task value was set to a boolean value, it will -// be serialized to `“true”` or `“false”` for the comparison. +// GetOnDurationWarningThresholdExceeded returns the value of the OnDurationWarningThresholdExceeded field in WebhookNotifications as +// a slice of Webhook values. +// If the field is unknown or null, the boolean return value is false. +func (o *WebhookNotifications) GetOnDurationWarningThresholdExceeded(ctx context.Context) ([]Webhook, bool) { + if o.OnDurationWarningThresholdExceeded.IsNull() || o.OnDurationWarningThresholdExceeded.IsUnknown() { + return nil, false + } + var v []Webhook + d := o.OnDurationWarningThresholdExceeded.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// * `BUNDLE`: The job is managed by Databricks Asset Bundle. +// SetOnDurationWarningThresholdExceeded sets the value of the OnDurationWarningThresholdExceeded field in WebhookNotifications. +func (o *WebhookNotifications) SetOnDurationWarningThresholdExceeded(ctx context.Context, v []Webhook) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_duration_warning_threshold_exceeded"] + o.OnDurationWarningThresholdExceeded = types.ListValueMust(t, vs) +} -// Edit mode of the job. -// -// * `UI_LOCKED`: The job is in a locked UI state and cannot be modified. * -// `EDITABLE`: The job is in an editable state and can be modified. +// GetOnFailure returns the value of the OnFailure field in WebhookNotifications as +// a slice of Webhook values. +// If the field is unknown or null, the boolean return value is false. +func (o *WebhookNotifications) GetOnFailure(ctx context.Context) ([]Webhook, bool) { + if o.OnFailure.IsNull() || o.OnFailure.IsUnknown() { + return nil, false + } + var v []Webhook + d := o.OnFailure.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// Permission level +// SetOnFailure sets the value of the OnFailure field in WebhookNotifications. +func (o *WebhookNotifications) SetOnFailure(ctx context.Context, v []Webhook) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + o.OnFailure = types.ListValueMust(t, vs) +} -// Dirty state indicates the job is not fully synced with the job specification -// in the remote repository. -// -// Possible values are: * `NOT_SYNCED`: The job is not yet synced with the -// remote job specification. Import the remote job specification from UI to make -// the job fully synced. * `DISCONNECTED`: The job is temporary disconnected -// from the remote job specification and is allowed for live edit. Import the -// remote job specification again from UI to make the job fully synced. - -// Specifies the health metric that is being evaluated for a particular health -// rule. -// -// * `RUN_DURATION_SECONDS`: Expected total time for a run in seconds. * -// `STREAMING_BACKLOG_BYTES`: An estimate of the maximum bytes of data waiting -// to be consumed across all streams. This metric is in Private Preview. * -// `STREAMING_BACKLOG_RECORDS`: An estimate of the maximum offset lag across all -// streams. This metric is in Private Preview. * `STREAMING_BACKLOG_SECONDS`: An -// estimate of the maximum consumer delay across all streams. This metric is in -// Private Preview. * `STREAMING_BACKLOG_FILES`: An estimate of the maximum -// number of outstanding files across all streams. This metric is in Private -// Preview. - -// Specifies the operator used to compare the health metric value with the -// specified threshold. - -// The reason for queuing the run. * `ACTIVE_RUNS_LIMIT_REACHED`: The run was -// queued due to reaching the workspace limit of active task runs. * -// `MAX_CONCURRENT_RUNS_REACHED`: The run was queued due to reaching the per-job -// limit of concurrent job runs. * `ACTIVE_RUN_JOB_TASKS_LIMIT_REACHED`: The run -// was queued due to reaching the workspace limit of active run job tasks. - -// The repair history item type. Indicates whether a run is the original run or -// a repair run. - -// An optional value indicating the condition that determines whether the task -// should be run once its dependencies have been completed. When omitted, -// defaults to `ALL_SUCCESS`. -// -// Possible values are: * `ALL_SUCCESS`: All dependencies have executed and -// succeeded * `AT_LEAST_ONE_SUCCESS`: At least one dependency has succeeded * -// `NONE_FAILED`: None of the dependencies have failed and at least one was -// executed * `ALL_DONE`: All dependencies have been completed * -// `AT_LEAST_ONE_FAILED`: At least one dependency failed * `ALL_FAILED`: ALl -// dependencies have failed - -// A value indicating the run's lifecycle state. The possible values are: * -// `QUEUED`: The run is queued. * `PENDING`: The run is waiting to be executed -// while the cluster and execution context are being prepared. * `RUNNING`: The -// task of this run is being executed. * `TERMINATING`: The task of this run has -// completed, and the cluster and execution context are being cleaned up. * -// `TERMINATED`: The task of this run has completed, and the cluster and -// execution context have been cleaned up. This state is terminal. * `SKIPPED`: -// This run was aborted because a previous run of the same job was already -// active. This state is terminal. * `INTERNAL_ERROR`: An exceptional state that -// indicates a failure in the Jobs service, such as network failure over a long -// period. If a run on a new cluster ends in the `INTERNAL_ERROR` state, the -// Jobs service terminates the cluster as soon as possible. This state is -// terminal. * `BLOCKED`: The run is blocked on an upstream dependency. * -// `WAITING_FOR_RETRY`: The run is waiting for a retry. +// GetOnStart returns the value of the OnStart field in WebhookNotifications as +// a slice of Webhook values. +// If the field is unknown or null, the boolean return value is false. +func (o *WebhookNotifications) GetOnStart(ctx context.Context) ([]Webhook, bool) { + if o.OnStart.IsNull() || o.OnStart.IsUnknown() { + return nil, false + } + var v []Webhook + d := o.OnStart.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// The current state of the run. +// SetOnStart sets the value of the OnStart field in WebhookNotifications. +func (o *WebhookNotifications) SetOnStart(ctx context.Context, v []Webhook) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_start"] + o.OnStart = types.ListValueMust(t, vs) +} -// A value indicating the run's result. The possible values are: * `SUCCESS`: -// The task completed successfully. * `FAILED`: The task completed with an -// error. * `TIMEDOUT`: The run was stopped after reaching the timeout. * -// `CANCELED`: The run was canceled at user request. * -// `MAXIMUM_CONCURRENT_RUNS_REACHED`: The run was skipped because the maximum -// concurrent runs were reached. * `EXCLUDED`: The run was skipped because the -// necessary conditions were not met. * `SUCCESS_WITH_FAILURES`: The job run -// completed successfully with some failures; leaf tasks were successful. * -// `UPSTREAM_FAILED`: The run was skipped because of an upstream failure. * -// `UPSTREAM_CANCELED`: The run was skipped because an upstream task was -// canceled. * `DISABLED`: The run was skipped because it was disabled -// explicitly by the user. - -// The type of a run. * `JOB_RUN`: Normal job run. A run created with -// :method:jobs/runNow. * `WORKFLOW_RUN`: Workflow run. A run created with -// [dbutils.notebook.run]. * `SUBMIT_RUN`: Submit run. A run created with -// :method:jobs/submit. -// -// [dbutils.notebook.run]: https://docs.databricks.com/dev-tools/databricks-utils.html#dbutils-workflow +// GetOnStreamingBacklogExceeded returns the value of the OnStreamingBacklogExceeded field in WebhookNotifications as +// a slice of Webhook values. +// If the field is unknown or null, the boolean return value is false. +func (o *WebhookNotifications) GetOnStreamingBacklogExceeded(ctx context.Context) ([]Webhook, bool) { + if o.OnStreamingBacklogExceeded.IsNull() || o.OnStreamingBacklogExceeded.IsUnknown() { + return nil, false + } + var v []Webhook + d := o.OnStreamingBacklogExceeded.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// Optional location type of the SQL file. When set to `WORKSPACE`, the SQL file -// will be retrieved\ from the local Databricks workspace. When set to `GIT`, -// the SQL file will be retrieved from a Git repository defined in `git_source`. -// If the value is empty, the task will use `GIT` if `git_source` is defined and -// `WORKSPACE` otherwise. -// -// * `WORKSPACE`: SQL file is located in Databricks workspace. * `GIT`: SQL file -// is located in cloud Git provider. +// SetOnStreamingBacklogExceeded sets the value of the OnStreamingBacklogExceeded field in WebhookNotifications. +func (o *WebhookNotifications) SetOnStreamingBacklogExceeded(ctx context.Context, v []Webhook) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_streaming_backlog_exceeded"] + o.OnStreamingBacklogExceeded = types.ListValueMust(t, vs) +} -// The state of the SQL alert. -// -// * UNKNOWN: alert yet to be evaluated * OK: alert evaluated and did not -// fulfill trigger conditions * TRIGGERED: alert evaluated and fulfilled trigger -// conditions - -// The code indicates why the run was terminated. Additional codes might be -// introduced in future releases. * `SUCCESS`: The run was completed -// successfully. * `USER_CANCELED`: The run was successfully canceled during -// execution by a user. * `CANCELED`: The run was canceled during execution by -// the Databricks platform; for example, if the maximum run duration was -// exceeded. * `SKIPPED`: Run was never executed, for example, if the upstream -// task run failed, the dependency type condition was not met, or there were no -// material tasks to execute. * `INTERNAL_ERROR`: The run encountered an -// unexpected error. Refer to the state message for further details. * -// `DRIVER_ERROR`: The run encountered an error while communicating with the -// Spark Driver. * `CLUSTER_ERROR`: The run failed due to a cluster error. Refer -// to the state message for further details. * `REPOSITORY_CHECKOUT_FAILED`: -// Failed to complete the checkout due to an error when communicating with the -// third party service. * `INVALID_CLUSTER_REQUEST`: The run failed because it -// issued an invalid request to start the cluster. * -// `WORKSPACE_RUN_LIMIT_EXCEEDED`: The workspace has reached the quota for the -// maximum number of concurrent active runs. Consider scheduling the runs over a -// larger time frame. * `FEATURE_DISABLED`: The run failed because it tried to -// access a feature unavailable for the workspace. * -// `CLUSTER_REQUEST_LIMIT_EXCEEDED`: The number of cluster creation, start, and -// upsize requests have exceeded the allotted rate limit. Consider spreading the -// run execution over a larger time frame. * `STORAGE_ACCESS_ERROR`: The run -// failed due to an error when accessing the customer blob storage. Refer to the -// state message for further details. * `RUN_EXECUTION_ERROR`: The run was -// completed with task failures. For more details, refer to the state message or -// run output. * `UNAUTHORIZED_ERROR`: The run failed due to a permission issue -// while accessing a resource. Refer to the state message for further details. * -// `LIBRARY_INSTALLATION_ERROR`: The run failed while installing the -// user-requested library. Refer to the state message for further details. The -// causes might include, but are not limited to: The provided library is -// invalid, there are insufficient permissions to install the library, and so -// forth. * `MAX_CONCURRENT_RUNS_EXCEEDED`: The scheduled run exceeds the limit -// of maximum concurrent runs set for the job. * `MAX_SPARK_CONTEXTS_EXCEEDED`: -// The run is scheduled on a cluster that has already reached the maximum number -// of contexts it is configured to create. See: [Link]. * `RESOURCE_NOT_FOUND`: -// A resource necessary for run execution does not exist. Refer to the state -// message for further details. * `INVALID_RUN_CONFIGURATION`: The run failed -// due to an invalid configuration. Refer to the state message for further -// details. * `CLOUD_FAILURE`: The run failed due to a cloud provider issue. -// Refer to the state message for further details. * -// `MAX_JOB_QUEUE_SIZE_EXCEEDED`: The run was skipped due to reaching the job -// level queue size limit. -// -// [Link]: https://kb.databricks.com/en_US/notebooks/too-many-execution-contexts-are-open-right-now - -// * `SUCCESS`: The run terminated without any issues * `INTERNAL_ERROR`: An -// error occurred in the Databricks platform. Please look at the [status page] -// or contact support if the issue persists. * `CLIENT_ERROR`: The run was -// terminated because of an error caused by user input or the job configuration. -// * `CLOUD_FAILURE`: The run was terminated because of an issue with your cloud -// provider. -// -// [status page]: https://status.databricks.com/ +// GetOnSuccess returns the value of the OnSuccess field in WebhookNotifications as +// a slice of Webhook values. +// If the field is unknown or null, the boolean return value is false. +func (o *WebhookNotifications) GetOnSuccess(ctx context.Context) ([]Webhook, bool) { + if o.OnSuccess.IsNull() || o.OnSuccess.IsUnknown() { + return nil, false + } + var v []Webhook + d := o.OnSuccess.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// The type of trigger that fired this run. -// -// * `PERIODIC`: Schedules that periodically trigger runs, such as a cron -// scheduler. * `ONE_TIME`: One time triggers that fire a single run. This -// occurs you triggered a single run on demand through the UI or the API. * -// `RETRY`: Indicates a run that is triggered as a retry of a previously failed -// run. This occurs when you request to re-run the job in case of failures. * -// `RUN_JOB_TASK`: Indicates a run that is triggered using a Run Job task. * -// `FILE_ARRIVAL`: Indicates a run that is triggered by a file arrival. * -// `TABLE`: Indicates a run that is triggered by a table update. - -// * `NOTEBOOK`: Notebook view item. * `DASHBOARD`: Dashboard view item. - -// * `CODE`: Code view of the notebook. * `DASHBOARDS`: All dashboard views of -// the notebook. * `ALL`: All views of the notebook. +// SetOnSuccess sets the value of the OnSuccess field in WebhookNotifications. +func (o *WebhookNotifications) SetOnSuccess(ctx context.Context, v []Webhook) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_success"] + o.OnSuccess = types.ListValueMust(t, vs) +} diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 8d05f64f8d..9079feac5b 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -109,6 +110,32 @@ func (o AddExchangeForListingResponse) Type(ctx context.Context) attr.Type { } } +// GetExchangeForListing returns the value of the ExchangeForListing field in AddExchangeForListingResponse as +// a ExchangeListing value. +// If the field is unknown or null, the boolean return value is false. +func (o *AddExchangeForListingResponse) GetExchangeForListing(ctx context.Context) (ExchangeListing, bool) { + var e ExchangeListing + if o.ExchangeForListing.IsNull() || o.ExchangeForListing.IsUnknown() { + return e, false + } + var v []ExchangeListing + d := o.ExchangeForListing.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExchangeForListing sets the value of the ExchangeForListing field in AddExchangeForListingResponse. +func (o *AddExchangeForListingResponse) SetExchangeForListing(ctx context.Context, v ExchangeListing) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_for_listing"] + o.ExchangeForListing = types.ListValueMust(t, vs) +} + // Get one batch of listings. One may specify up to 50 IDs per request. type BatchGetListingsRequest struct { Ids types.List `tfsdk:"-"` @@ -155,6 +182,31 @@ func (o BatchGetListingsRequest) Type(ctx context.Context) attr.Type { } } +// GetIds returns the value of the Ids field in BatchGetListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *BatchGetListingsRequest) GetIds(ctx context.Context) ([]types.String, bool) { + if o.Ids.IsNull() || o.Ids.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Ids.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIds sets the value of the Ids field in BatchGetListingsRequest. +func (o *BatchGetListingsRequest) SetIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ids"] + o.Ids = types.ListValueMust(t, vs) +} + type BatchGetListingsResponse struct { Listings types.List `tfsdk:"listings" tf:"optional"` } @@ -200,6 +252,31 @@ func (o BatchGetListingsResponse) Type(ctx context.Context) attr.Type { } } +// GetListings returns the value of the Listings field in BatchGetListingsResponse as +// a slice of Listing values. +// If the field is unknown or null, the boolean return value is false. +func (o *BatchGetListingsResponse) GetListings(ctx context.Context) ([]Listing, bool) { + if o.Listings.IsNull() || o.Listings.IsUnknown() { + return nil, false + } + var v []Listing + d := o.Listings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetListings sets the value of the Listings field in BatchGetListingsResponse. +func (o *BatchGetListingsResponse) SetListings(ctx context.Context, v []Listing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + o.Listings = types.ListValueMust(t, vs) +} + // Get one batch of providers. One may specify up to 50 IDs per request. type BatchGetProvidersRequest struct { Ids types.List `tfsdk:"-"` @@ -246,6 +323,31 @@ func (o BatchGetProvidersRequest) Type(ctx context.Context) attr.Type { } } +// GetIds returns the value of the Ids field in BatchGetProvidersRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *BatchGetProvidersRequest) GetIds(ctx context.Context) ([]types.String, bool) { + if o.Ids.IsNull() || o.Ids.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Ids.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIds sets the value of the Ids field in BatchGetProvidersRequest. +func (o *BatchGetProvidersRequest) SetIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ids"] + o.Ids = types.ListValueMust(t, vs) +} + type BatchGetProvidersResponse struct { Providers types.List `tfsdk:"providers" tf:"optional"` } @@ -291,6 +393,31 @@ func (o BatchGetProvidersResponse) Type(ctx context.Context) attr.Type { } } +// GetProviders returns the value of the Providers field in BatchGetProvidersResponse as +// a slice of ProviderInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *BatchGetProvidersResponse) GetProviders(ctx context.Context) ([]ProviderInfo, bool) { + if o.Providers.IsNull() || o.Providers.IsUnknown() { + return nil, false + } + var v []ProviderInfo + d := o.Providers.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProviders sets the value of the Providers field in BatchGetProvidersResponse. +func (o *BatchGetProvidersResponse) SetProviders(ctx context.Context, v []ProviderInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["providers"] + o.Providers = types.ListValueMust(t, vs) +} + type ConsumerTerms struct { Version types.String `tfsdk:"version" tf:""` } @@ -432,6 +559,32 @@ func (o CreateExchangeFilterRequest) Type(ctx context.Context) attr.Type { } } +// GetFilter returns the value of the Filter field in CreateExchangeFilterRequest as +// a ExchangeFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateExchangeFilterRequest) GetFilter(ctx context.Context) (ExchangeFilter, bool) { + var e ExchangeFilter + if o.Filter.IsNull() || o.Filter.IsUnknown() { + return e, false + } + var v []ExchangeFilter + d := o.Filter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilter sets the value of the Filter field in CreateExchangeFilterRequest. +func (o *CreateExchangeFilterRequest) SetFilter(ctx context.Context, v ExchangeFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter"] + o.Filter = types.ListValueMust(t, vs) +} + type CreateExchangeFilterResponse struct { FilterId types.String `tfsdk:"filter_id" tf:"optional"` } @@ -518,6 +671,32 @@ func (o CreateExchangeRequest) Type(ctx context.Context) attr.Type { } } +// GetExchange returns the value of the Exchange field in CreateExchangeRequest as +// a Exchange value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateExchangeRequest) GetExchange(ctx context.Context) (Exchange, bool) { + var e Exchange + if o.Exchange.IsNull() || o.Exchange.IsUnknown() { + return e, false + } + var v []Exchange + d := o.Exchange.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExchange sets the value of the Exchange field in CreateExchangeRequest. +func (o *CreateExchangeRequest) SetExchange(ctx context.Context, v Exchange) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange"] + o.Exchange = types.ListValueMust(t, vs) +} + type CreateExchangeResponse struct { ExchangeId types.String `tfsdk:"exchange_id" tf:"optional"` } @@ -616,6 +795,32 @@ func (o CreateFileRequest) Type(ctx context.Context) attr.Type { } } +// GetFileParent returns the value of the FileParent field in CreateFileRequest as +// a FileParent value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateFileRequest) GetFileParent(ctx context.Context) (FileParent, bool) { + var e FileParent + if o.FileParent.IsNull() || o.FileParent.IsUnknown() { + return e, false + } + var v []FileParent + d := o.FileParent.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFileParent sets the value of the FileParent field in CreateFileRequest. +func (o *CreateFileRequest) SetFileParent(ctx context.Context, v FileParent) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_parent"] + o.FileParent = types.ListValueMust(t, vs) +} + type CreateFileResponse struct { FileInfo types.List `tfsdk:"file_info" tf:"optional,object"` // Pre-signed POST URL to blob storage @@ -665,6 +870,32 @@ func (o CreateFileResponse) Type(ctx context.Context) attr.Type { } } +// GetFileInfo returns the value of the FileInfo field in CreateFileResponse as +// a FileInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateFileResponse) GetFileInfo(ctx context.Context) (FileInfo, bool) { + var e FileInfo + if o.FileInfo.IsNull() || o.FileInfo.IsUnknown() { + return e, false + } + var v []FileInfo + d := o.FileInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFileInfo sets the value of the FileInfo field in CreateFileResponse. +func (o *CreateFileResponse) SetFileInfo(ctx context.Context, v FileInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_info"] + o.FileInfo = types.ListValueMust(t, vs) +} + type CreateInstallationRequest struct { AcceptedConsumerTerms types.List `tfsdk:"accepted_consumer_terms" tf:"optional,object"` @@ -733,6 +964,58 @@ func (o CreateInstallationRequest) Type(ctx context.Context) attr.Type { } } +// GetAcceptedConsumerTerms returns the value of the AcceptedConsumerTerms field in CreateInstallationRequest as +// a ConsumerTerms value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstallationRequest) GetAcceptedConsumerTerms(ctx context.Context) (ConsumerTerms, bool) { + var e ConsumerTerms + if o.AcceptedConsumerTerms.IsNull() || o.AcceptedConsumerTerms.IsUnknown() { + return e, false + } + var v []ConsumerTerms + d := o.AcceptedConsumerTerms.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAcceptedConsumerTerms sets the value of the AcceptedConsumerTerms field in CreateInstallationRequest. +func (o *CreateInstallationRequest) SetAcceptedConsumerTerms(ctx context.Context, v ConsumerTerms) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["accepted_consumer_terms"] + o.AcceptedConsumerTerms = types.ListValueMust(t, vs) +} + +// GetRepoDetail returns the value of the RepoDetail field in CreateInstallationRequest as +// a RepoInstallation value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateInstallationRequest) GetRepoDetail(ctx context.Context) (RepoInstallation, bool) { + var e RepoInstallation + if o.RepoDetail.IsNull() || o.RepoDetail.IsUnknown() { + return e, false + } + var v []RepoInstallation + d := o.RepoDetail.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRepoDetail sets the value of the RepoDetail field in CreateInstallationRequest. +func (o *CreateInstallationRequest) SetRepoDetail(ctx context.Context, v RepoInstallation) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repo_detail"] + o.RepoDetail = types.ListValueMust(t, vs) +} + type CreateListingRequest struct { Listing types.List `tfsdk:"listing" tf:"object"` } @@ -778,6 +1061,32 @@ func (o CreateListingRequest) Type(ctx context.Context) attr.Type { } } +// GetListing returns the value of the Listing field in CreateListingRequest as +// a Listing value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateListingRequest) GetListing(ctx context.Context) (Listing, bool) { + var e Listing + if o.Listing.IsNull() || o.Listing.IsUnknown() { + return e, false + } + var v []Listing + d := o.Listing.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetListing sets the value of the Listing field in CreateListingRequest. +func (o *CreateListingRequest) SetListing(ctx context.Context, v Listing) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listing"] + o.Listing = types.ListValueMust(t, vs) +} + type CreateListingResponse struct { ListingId types.String `tfsdk:"listing_id" tf:"optional"` } @@ -897,6 +1206,32 @@ func (o CreatePersonalizationRequest) Type(ctx context.Context) attr.Type { } } +// GetAcceptedConsumerTerms returns the value of the AcceptedConsumerTerms field in CreatePersonalizationRequest as +// a ConsumerTerms value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePersonalizationRequest) GetAcceptedConsumerTerms(ctx context.Context) (ConsumerTerms, bool) { + var e ConsumerTerms + if o.AcceptedConsumerTerms.IsNull() || o.AcceptedConsumerTerms.IsUnknown() { + return e, false + } + var v []ConsumerTerms + d := o.AcceptedConsumerTerms.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAcceptedConsumerTerms sets the value of the AcceptedConsumerTerms field in CreatePersonalizationRequest. +func (o *CreatePersonalizationRequest) SetAcceptedConsumerTerms(ctx context.Context, v ConsumerTerms) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["accepted_consumer_terms"] + o.AcceptedConsumerTerms = types.ListValueMust(t, vs) +} + type CreatePersonalizationRequestResponse struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -983,6 +1318,32 @@ func (o CreateProviderRequest) Type(ctx context.Context) attr.Type { } } +// GetProvider returns the value of the Provider field in CreateProviderRequest as +// a ProviderInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateProviderRequest) GetProvider(ctx context.Context) (ProviderInfo, bool) { + var e ProviderInfo + if o.Provider.IsNull() || o.Provider.IsUnknown() { + return e, false + } + var v []ProviderInfo + d := o.Provider.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvider sets the value of the Provider field in CreateProviderRequest. +func (o *CreateProviderRequest) SetProvider(ctx context.Context, v ProviderInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider"] + o.Provider = types.ListValueMust(t, vs) +} + type CreateProviderResponse struct { Id types.String `tfsdk:"id" tf:"optional"` } @@ -1621,6 +1982,56 @@ func (o Exchange) Type(ctx context.Context) attr.Type { } } +// GetFilters returns the value of the Filters field in Exchange as +// a slice of ExchangeFilter values. +// If the field is unknown or null, the boolean return value is false. +func (o *Exchange) GetFilters(ctx context.Context) ([]ExchangeFilter, bool) { + if o.Filters.IsNull() || o.Filters.IsUnknown() { + return nil, false + } + var v []ExchangeFilter + d := o.Filters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFilters sets the value of the Filters field in Exchange. +func (o *Exchange) SetFilters(ctx context.Context, v []ExchangeFilter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + o.Filters = types.ListValueMust(t, vs) +} + +// GetLinkedListings returns the value of the LinkedListings field in Exchange as +// a slice of ExchangeListing values. +// If the field is unknown or null, the boolean return value is false. +func (o *Exchange) GetLinkedListings(ctx context.Context) ([]ExchangeListing, bool) { + if o.LinkedListings.IsNull() || o.LinkedListings.IsUnknown() { + return nil, false + } + var v []ExchangeListing + d := o.LinkedListings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLinkedListings sets the value of the LinkedListings field in Exchange. +func (o *Exchange) SetLinkedListings(ctx context.Context, v []ExchangeListing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["linked_listings"] + o.LinkedListings = types.ListValueMust(t, vs) +} + type ExchangeFilter struct { CreatedAt types.Int64 `tfsdk:"created_at" tf:"optional"` @@ -1841,6 +2252,32 @@ func (o FileInfo) Type(ctx context.Context) attr.Type { } } +// GetFileParent returns the value of the FileParent field in FileInfo as +// a FileParent value. +// If the field is unknown or null, the boolean return value is false. +func (o *FileInfo) GetFileParent(ctx context.Context) (FileParent, bool) { + var e FileParent + if o.FileParent.IsNull() || o.FileParent.IsUnknown() { + return e, false + } + var v []FileParent + d := o.FileParent.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFileParent sets the value of the FileParent field in FileInfo. +func (o *FileInfo) SetFileParent(ctx context.Context, v FileParent) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_parent"] + o.FileParent = types.ListValueMust(t, vs) +} + type FileParent struct { FileParentType types.String `tfsdk:"file_parent_type" tf:"optional"` // TODO make the following fields required @@ -1973,6 +2410,32 @@ func (o GetExchangeResponse) Type(ctx context.Context) attr.Type { } } +// GetExchange returns the value of the Exchange field in GetExchangeResponse as +// a Exchange value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetExchangeResponse) GetExchange(ctx context.Context) (Exchange, bool) { + var e Exchange + if o.Exchange.IsNull() || o.Exchange.IsUnknown() { + return e, false + } + var v []Exchange + d := o.Exchange.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExchange sets the value of the Exchange field in GetExchangeResponse. +func (o *GetExchangeResponse) SetExchange(ctx context.Context, v Exchange) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange"] + o.Exchange = types.ListValueMust(t, vs) +} + // Get a file type GetFileRequest struct { FileId types.String `tfsdk:"-"` @@ -2060,6 +2523,32 @@ func (o GetFileResponse) Type(ctx context.Context) attr.Type { } } +// GetFileInfo returns the value of the FileInfo field in GetFileResponse as +// a FileInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetFileResponse) GetFileInfo(ctx context.Context) (FileInfo, bool) { + var e FileInfo + if o.FileInfo.IsNull() || o.FileInfo.IsUnknown() { + return e, false + } + var v []FileInfo + d := o.FileInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFileInfo sets the value of the FileInfo field in GetFileResponse. +func (o *GetFileResponse) SetFileInfo(ctx context.Context, v FileInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_info"] + o.FileInfo = types.ListValueMust(t, vs) +} + type GetLatestVersionProviderAnalyticsDashboardResponse struct { // version here is latest logical version of the dashboard template Version types.Int64 `tfsdk:"version" tf:"optional"` @@ -2201,6 +2690,31 @@ func (o GetListingContentMetadataResponse) Type(ctx context.Context) attr.Type { } } +// GetSharedDataObjects returns the value of the SharedDataObjects field in GetListingContentMetadataResponse as +// a slice of SharedDataObject values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetListingContentMetadataResponse) GetSharedDataObjects(ctx context.Context) ([]SharedDataObject, bool) { + if o.SharedDataObjects.IsNull() || o.SharedDataObjects.IsUnknown() { + return nil, false + } + var v []SharedDataObject + d := o.SharedDataObjects.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSharedDataObjects sets the value of the SharedDataObjects field in GetListingContentMetadataResponse. +func (o *GetListingContentMetadataResponse) SetSharedDataObjects(ctx context.Context, v []SharedDataObject) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["shared_data_objects"] + o.SharedDataObjects = types.ListValueMust(t, vs) +} + // Get listing type GetListingRequest struct { Id types.String `tfsdk:"-"` @@ -2288,6 +2802,32 @@ func (o GetListingResponse) Type(ctx context.Context) attr.Type { } } +// GetListing returns the value of the Listing field in GetListingResponse as +// a Listing value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetListingResponse) GetListing(ctx context.Context) (Listing, bool) { + var e Listing + if o.Listing.IsNull() || o.Listing.IsUnknown() { + return e, false + } + var v []Listing + d := o.Listing.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetListing sets the value of the Listing field in GetListingResponse. +func (o *GetListingResponse) SetListing(ctx context.Context, v Listing) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listing"] + o.Listing = types.ListValueMust(t, vs) +} + // List listings type GetListingsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -2383,6 +2923,31 @@ func (o GetListingsResponse) Type(ctx context.Context) attr.Type { } } +// GetListings returns the value of the Listings field in GetListingsResponse as +// a slice of Listing values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetListingsResponse) GetListings(ctx context.Context) ([]Listing, bool) { + if o.Listings.IsNull() || o.Listings.IsUnknown() { + return nil, false + } + var v []Listing + d := o.Listings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetListings sets the value of the Listings field in GetListingsResponse. +func (o *GetListingsResponse) SetListings(ctx context.Context, v []Listing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + o.Listings = types.ListValueMust(t, vs) +} + // Get the personalization request for a listing type GetPersonalizationRequestRequest struct { ListingId types.String `tfsdk:"-"` @@ -2470,6 +3035,31 @@ func (o GetPersonalizationRequestResponse) Type(ctx context.Context) attr.Type { } } +// GetPersonalizationRequests returns the value of the PersonalizationRequests field in GetPersonalizationRequestResponse as +// a slice of PersonalizationRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPersonalizationRequestResponse) GetPersonalizationRequests(ctx context.Context) ([]PersonalizationRequest, bool) { + if o.PersonalizationRequests.IsNull() || o.PersonalizationRequests.IsUnknown() { + return nil, false + } + var v []PersonalizationRequest + d := o.PersonalizationRequests.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPersonalizationRequests sets the value of the PersonalizationRequests field in GetPersonalizationRequestResponse. +func (o *GetPersonalizationRequestResponse) SetPersonalizationRequests(ctx context.Context, v []PersonalizationRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["personalization_requests"] + o.PersonalizationRequests = types.ListValueMust(t, vs) +} + // Get a provider type GetProviderRequest struct { Id types.String `tfsdk:"-"` @@ -2557,6 +3147,32 @@ func (o GetProviderResponse) Type(ctx context.Context) attr.Type { } } +// GetProvider returns the value of the Provider field in GetProviderResponse as +// a ProviderInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetProviderResponse) GetProvider(ctx context.Context) (ProviderInfo, bool) { + var e ProviderInfo + if o.Provider.IsNull() || o.Provider.IsUnknown() { + return e, false + } + var v []ProviderInfo + d := o.Provider.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvider sets the value of the Provider field in GetProviderResponse. +func (o *GetProviderResponse) SetProvider(ctx context.Context, v ProviderInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider"] + o.Provider = types.ListValueMust(t, vs) +} + type Installation struct { Installation types.List `tfsdk:"installation" tf:"optional,object"` } @@ -2602,6 +3218,32 @@ func (o Installation) Type(ctx context.Context) attr.Type { } } +// GetInstallation returns the value of the Installation field in Installation as +// a InstallationDetail value. +// If the field is unknown or null, the boolean return value is false. +func (o *Installation) GetInstallation(ctx context.Context) (InstallationDetail, bool) { + var e InstallationDetail + if o.Installation.IsNull() || o.Installation.IsUnknown() { + return e, false + } + var v []InstallationDetail + d := o.Installation.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInstallation sets the value of the Installation field in Installation. +func (o *Installation) SetInstallation(ctx context.Context, v InstallationDetail) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installation"] + o.Installation = types.ListValueMust(t, vs) +} + type InstallationDetail struct { CatalogName types.String `tfsdk:"catalog_name" tf:"optional"` @@ -2698,6 +3340,57 @@ func (o InstallationDetail) Type(ctx context.Context) attr.Type { } } +// GetTokenDetail returns the value of the TokenDetail field in InstallationDetail as +// a TokenDetail value. +// If the field is unknown or null, the boolean return value is false. +func (o *InstallationDetail) GetTokenDetail(ctx context.Context) (TokenDetail, bool) { + var e TokenDetail + if o.TokenDetail.IsNull() || o.TokenDetail.IsUnknown() { + return e, false + } + var v []TokenDetail + d := o.TokenDetail.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenDetail sets the value of the TokenDetail field in InstallationDetail. +func (o *InstallationDetail) SetTokenDetail(ctx context.Context, v TokenDetail) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_detail"] + o.TokenDetail = types.ListValueMust(t, vs) +} + +// GetTokens returns the value of the Tokens field in InstallationDetail as +// a slice of TokenInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *InstallationDetail) GetTokens(ctx context.Context) ([]TokenInfo, bool) { + if o.Tokens.IsNull() || o.Tokens.IsUnknown() { + return nil, false + } + var v []TokenInfo + d := o.Tokens.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTokens sets the value of the Tokens field in InstallationDetail. +func (o *InstallationDetail) SetTokens(ctx context.Context, v []TokenInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tokens"] + o.Tokens = types.ListValueMust(t, vs) +} + // List all installations type ListAllInstallationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -2793,6 +3486,31 @@ func (o ListAllInstallationsResponse) Type(ctx context.Context) attr.Type { } } +// GetInstallations returns the value of the Installations field in ListAllInstallationsResponse as +// a slice of InstallationDetail values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAllInstallationsResponse) GetInstallations(ctx context.Context) ([]InstallationDetail, bool) { + if o.Installations.IsNull() || o.Installations.IsUnknown() { + return nil, false + } + var v []InstallationDetail + d := o.Installations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInstallations sets the value of the Installations field in ListAllInstallationsResponse. +func (o *ListAllInstallationsResponse) SetInstallations(ctx context.Context, v []InstallationDetail) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installations"] + o.Installations = types.ListValueMust(t, vs) +} + // List all personalization requests type ListAllPersonalizationRequestsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -2888,6 +3606,31 @@ func (o ListAllPersonalizationRequestsResponse) Type(ctx context.Context) attr.T } } +// GetPersonalizationRequests returns the value of the PersonalizationRequests field in ListAllPersonalizationRequestsResponse as +// a slice of PersonalizationRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAllPersonalizationRequestsResponse) GetPersonalizationRequests(ctx context.Context) ([]PersonalizationRequest, bool) { + if o.PersonalizationRequests.IsNull() || o.PersonalizationRequests.IsUnknown() { + return nil, false + } + var v []PersonalizationRequest + d := o.PersonalizationRequests.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPersonalizationRequests sets the value of the PersonalizationRequests field in ListAllPersonalizationRequestsResponse. +func (o *ListAllPersonalizationRequestsResponse) SetPersonalizationRequests(ctx context.Context, v []PersonalizationRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["personalization_requests"] + o.PersonalizationRequests = types.ListValueMust(t, vs) +} + // List exchange filters type ListExchangeFiltersRequest struct { ExchangeId types.String `tfsdk:"-"` @@ -2987,6 +3730,31 @@ func (o ListExchangeFiltersResponse) Type(ctx context.Context) attr.Type { } } +// GetFilters returns the value of the Filters field in ListExchangeFiltersResponse as +// a slice of ExchangeFilter values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListExchangeFiltersResponse) GetFilters(ctx context.Context) ([]ExchangeFilter, bool) { + if o.Filters.IsNull() || o.Filters.IsUnknown() { + return nil, false + } + var v []ExchangeFilter + d := o.Filters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFilters sets the value of the Filters field in ListExchangeFiltersResponse. +func (o *ListExchangeFiltersResponse) SetFilters(ctx context.Context, v []ExchangeFilter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + o.Filters = types.ListValueMust(t, vs) +} + // List exchanges for listing type ListExchangesForListingRequest struct { ListingId types.String `tfsdk:"-"` @@ -3086,6 +3854,31 @@ func (o ListExchangesForListingResponse) Type(ctx context.Context) attr.Type { } } +// GetExchangeListing returns the value of the ExchangeListing field in ListExchangesForListingResponse as +// a slice of ExchangeListing values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListExchangesForListingResponse) GetExchangeListing(ctx context.Context) ([]ExchangeListing, bool) { + if o.ExchangeListing.IsNull() || o.ExchangeListing.IsUnknown() { + return nil, false + } + var v []ExchangeListing + d := o.ExchangeListing.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExchangeListing sets the value of the ExchangeListing field in ListExchangesForListingResponse. +func (o *ListExchangesForListingResponse) SetExchangeListing(ctx context.Context, v []ExchangeListing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_listing"] + o.ExchangeListing = types.ListValueMust(t, vs) +} + // List exchanges type ListExchangesRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -3181,6 +3974,31 @@ func (o ListExchangesResponse) Type(ctx context.Context) attr.Type { } } +// GetExchanges returns the value of the Exchanges field in ListExchangesResponse as +// a slice of Exchange values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListExchangesResponse) GetExchanges(ctx context.Context) ([]Exchange, bool) { + if o.Exchanges.IsNull() || o.Exchanges.IsUnknown() { + return nil, false + } + var v []Exchange + d := o.Exchanges.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExchanges sets the value of the Exchanges field in ListExchangesResponse. +func (o *ListExchangesResponse) SetExchanges(ctx context.Context, v []Exchange) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchanges"] + o.Exchanges = types.ListValueMust(t, vs) +} + // List files type ListFilesRequest struct { FileParent types.List `tfsdk:"-"` @@ -3235,6 +4053,32 @@ func (o ListFilesRequest) Type(ctx context.Context) attr.Type { } } +// GetFileParent returns the value of the FileParent field in ListFilesRequest as +// a FileParent value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListFilesRequest) GetFileParent(ctx context.Context) (FileParent, bool) { + var e FileParent + if o.FileParent.IsNull() || o.FileParent.IsUnknown() { + return e, false + } + var v []FileParent + d := o.FileParent.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFileParent sets the value of the FileParent field in ListFilesRequest. +func (o *ListFilesRequest) SetFileParent(ctx context.Context, v FileParent) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_parent"] + o.FileParent = types.ListValueMust(t, vs) +} + type ListFilesResponse struct { FileInfos types.List `tfsdk:"file_infos" tf:"optional"` @@ -3284,6 +4128,31 @@ func (o ListFilesResponse) Type(ctx context.Context) attr.Type { } } +// GetFileInfos returns the value of the FileInfos field in ListFilesResponse as +// a slice of FileInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListFilesResponse) GetFileInfos(ctx context.Context) ([]FileInfo, bool) { + if o.FileInfos.IsNull() || o.FileInfos.IsUnknown() { + return nil, false + } + var v []FileInfo + d := o.FileInfos.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFileInfos sets the value of the FileInfos field in ListFilesResponse. +func (o *ListFilesResponse) SetFileInfos(ctx context.Context, v []FileInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_infos"] + o.FileInfos = types.ListValueMust(t, vs) +} + // List all listing fulfillments type ListFulfillmentsRequest struct { ListingId types.String `tfsdk:"-"` @@ -3383,6 +4252,31 @@ func (o ListFulfillmentsResponse) Type(ctx context.Context) attr.Type { } } +// GetFulfillments returns the value of the Fulfillments field in ListFulfillmentsResponse as +// a slice of ListingFulfillment values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListFulfillmentsResponse) GetFulfillments(ctx context.Context) ([]ListingFulfillment, bool) { + if o.Fulfillments.IsNull() || o.Fulfillments.IsUnknown() { + return nil, false + } + var v []ListingFulfillment + d := o.Fulfillments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFulfillments sets the value of the Fulfillments field in ListFulfillmentsResponse. +func (o *ListFulfillmentsResponse) SetFulfillments(ctx context.Context, v []ListingFulfillment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fulfillments"] + o.Fulfillments = types.ListValueMust(t, vs) +} + // List installations for a listing type ListInstallationsRequest struct { ListingId types.String `tfsdk:"-"` @@ -3482,6 +4376,31 @@ func (o ListInstallationsResponse) Type(ctx context.Context) attr.Type { } } +// GetInstallations returns the value of the Installations field in ListInstallationsResponse as +// a slice of InstallationDetail values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListInstallationsResponse) GetInstallations(ctx context.Context) ([]InstallationDetail, bool) { + if o.Installations.IsNull() || o.Installations.IsUnknown() { + return nil, false + } + var v []InstallationDetail + d := o.Installations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInstallations sets the value of the Installations field in ListInstallationsResponse. +func (o *ListInstallationsResponse) SetInstallations(ctx context.Context, v []InstallationDetail) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installations"] + o.Installations = types.ListValueMust(t, vs) +} + // List listings for exchange type ListListingsForExchangeRequest struct { ExchangeId types.String `tfsdk:"-"` @@ -3581,10 +4500,35 @@ func (o ListListingsForExchangeResponse) Type(ctx context.Context) attr.Type { } } -// List listings -type ListListingsRequest struct { - // Matches any of the following asset types - Assets types.List `tfsdk:"-"` +// GetExchangeListings returns the value of the ExchangeListings field in ListListingsForExchangeResponse as +// a slice of ExchangeListing values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListListingsForExchangeResponse) GetExchangeListings(ctx context.Context) ([]ExchangeListing, bool) { + if o.ExchangeListings.IsNull() || o.ExchangeListings.IsUnknown() { + return nil, false + } + var v []ExchangeListing + d := o.ExchangeListings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExchangeListings sets the value of the ExchangeListings field in ListListingsForExchangeResponse. +func (o *ListListingsForExchangeResponse) SetExchangeListings(ctx context.Context, v []ExchangeListing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_listings"] + o.ExchangeListings = types.ListValueMust(t, vs) +} + +// List listings +type ListListingsRequest struct { + // Matches any of the following asset types + Assets types.List `tfsdk:"-"` // Matches any of the following categories Categories types.List `tfsdk:"-"` // Filters each listing based on if it is free. @@ -3669,6 +4613,106 @@ func (o ListListingsRequest) Type(ctx context.Context) attr.Type { } } +// GetAssets returns the value of the Assets field in ListListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListListingsRequest) GetAssets(ctx context.Context) ([]types.String, bool) { + if o.Assets.IsNull() || o.Assets.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Assets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAssets sets the value of the Assets field in ListListingsRequest. +func (o *ListListingsRequest) SetAssets(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assets"] + o.Assets = types.ListValueMust(t, vs) +} + +// GetCategories returns the value of the Categories field in ListListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListListingsRequest) GetCategories(ctx context.Context) ([]types.String, bool) { + if o.Categories.IsNull() || o.Categories.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Categories.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCategories sets the value of the Categories field in ListListingsRequest. +func (o *ListListingsRequest) SetCategories(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["categories"] + o.Categories = types.ListValueMust(t, vs) +} + +// GetProviderIds returns the value of the ProviderIds field in ListListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListListingsRequest) GetProviderIds(ctx context.Context) ([]types.String, bool) { + if o.ProviderIds.IsNull() || o.ProviderIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ProviderIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProviderIds sets the value of the ProviderIds field in ListListingsRequest. +func (o *ListListingsRequest) SetProviderIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider_ids"] + o.ProviderIds = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in ListListingsRequest as +// a slice of ListingTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListListingsRequest) GetTags(ctx context.Context) ([]ListingTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ListingTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ListListingsRequest. +func (o *ListListingsRequest) SetTags(ctx context.Context, v []ListingTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ListListingsResponse struct { Listings types.List `tfsdk:"listings" tf:"optional"` @@ -3718,6 +4762,31 @@ func (o ListListingsResponse) Type(ctx context.Context) attr.Type { } } +// GetListings returns the value of the Listings field in ListListingsResponse as +// a slice of Listing values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListListingsResponse) GetListings(ctx context.Context) ([]Listing, bool) { + if o.Listings.IsNull() || o.Listings.IsUnknown() { + return nil, false + } + var v []Listing + d := o.Listings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetListings sets the value of the Listings field in ListListingsResponse. +func (o *ListListingsResponse) SetListings(ctx context.Context, v []Listing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + o.Listings = types.ListValueMust(t, vs) +} + type ListProviderAnalyticsDashboardResponse struct { // dashboard_id will be used to open Lakeview dashboard. DashboardId types.String `tfsdk:"dashboard_id" tf:""` @@ -3867,6 +4936,31 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { } } +// GetProviders returns the value of the Providers field in ListProvidersResponse as +// a slice of ProviderInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListProvidersResponse) GetProviders(ctx context.Context) ([]ProviderInfo, bool) { + if o.Providers.IsNull() || o.Providers.IsUnknown() { + return nil, false + } + var v []ProviderInfo + d := o.Providers.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProviders sets the value of the Providers field in ListProvidersResponse. +func (o *ListProvidersResponse) SetProviders(ctx context.Context, v []ProviderInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["providers"] + o.Providers = types.ListValueMust(t, vs) +} + type Listing struct { Detail types.List `tfsdk:"detail" tf:"optional,object"` @@ -3923,6 +5017,58 @@ func (o Listing) Type(ctx context.Context) attr.Type { } } +// GetDetail returns the value of the Detail field in Listing as +// a ListingDetail value. +// If the field is unknown or null, the boolean return value is false. +func (o *Listing) GetDetail(ctx context.Context) (ListingDetail, bool) { + var e ListingDetail + if o.Detail.IsNull() || o.Detail.IsUnknown() { + return e, false + } + var v []ListingDetail + d := o.Detail.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDetail sets the value of the Detail field in Listing. +func (o *Listing) SetDetail(ctx context.Context, v ListingDetail) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["detail"] + o.Detail = types.ListValueMust(t, vs) +} + +// GetSummary returns the value of the Summary field in Listing as +// a ListingSummary value. +// If the field is unknown or null, the boolean return value is false. +func (o *Listing) GetSummary(ctx context.Context) (ListingSummary, bool) { + var e ListingSummary + if o.Summary.IsNull() || o.Summary.IsUnknown() { + return e, false + } + var v []ListingSummary + d := o.Summary.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSummary sets the value of the Summary field in Listing. +func (o *Listing) SetSummary(ctx context.Context, v ListingSummary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["summary"] + o.Summary = types.ListValueMust(t, vs) +} + type ListingDetail struct { // Type of assets included in the listing. eg. GIT_REPO, DATA_TABLE, MODEL, // NOTEBOOK @@ -4066,6 +5212,158 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { } } +// GetAssets returns the value of the Assets field in ListingDetail as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingDetail) GetAssets(ctx context.Context) ([]types.String, bool) { + if o.Assets.IsNull() || o.Assets.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Assets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAssets sets the value of the Assets field in ListingDetail. +func (o *ListingDetail) SetAssets(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assets"] + o.Assets = types.ListValueMust(t, vs) +} + +// GetCollectionGranularity returns the value of the CollectionGranularity field in ListingDetail as +// a DataRefreshInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingDetail) GetCollectionGranularity(ctx context.Context) (DataRefreshInfo, bool) { + var e DataRefreshInfo + if o.CollectionGranularity.IsNull() || o.CollectionGranularity.IsUnknown() { + return e, false + } + var v []DataRefreshInfo + d := o.CollectionGranularity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCollectionGranularity sets the value of the CollectionGranularity field in ListingDetail. +func (o *ListingDetail) SetCollectionGranularity(ctx context.Context, v DataRefreshInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["collection_granularity"] + o.CollectionGranularity = types.ListValueMust(t, vs) +} + +// GetEmbeddedNotebookFileInfos returns the value of the EmbeddedNotebookFileInfos field in ListingDetail as +// a slice of FileInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingDetail) GetEmbeddedNotebookFileInfos(ctx context.Context) ([]FileInfo, bool) { + if o.EmbeddedNotebookFileInfos.IsNull() || o.EmbeddedNotebookFileInfos.IsUnknown() { + return nil, false + } + var v []FileInfo + d := o.EmbeddedNotebookFileInfos.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddedNotebookFileInfos sets the value of the EmbeddedNotebookFileInfos field in ListingDetail. +func (o *ListingDetail) SetEmbeddedNotebookFileInfos(ctx context.Context, v []FileInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedded_notebook_file_infos"] + o.EmbeddedNotebookFileInfos = types.ListValueMust(t, vs) +} + +// GetFileIds returns the value of the FileIds field in ListingDetail as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingDetail) GetFileIds(ctx context.Context) ([]types.String, bool) { + if o.FileIds.IsNull() || o.FileIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FileIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFileIds sets the value of the FileIds field in ListingDetail. +func (o *ListingDetail) SetFileIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_ids"] + o.FileIds = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in ListingDetail as +// a slice of ListingTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingDetail) GetTags(ctx context.Context) ([]ListingTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ListingTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ListingDetail. +func (o *ListingDetail) SetTags(ctx context.Context, v []ListingTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + +// GetUpdateFrequency returns the value of the UpdateFrequency field in ListingDetail as +// a DataRefreshInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingDetail) GetUpdateFrequency(ctx context.Context) (DataRefreshInfo, bool) { + var e DataRefreshInfo + if o.UpdateFrequency.IsNull() || o.UpdateFrequency.IsUnknown() { + return e, false + } + var v []DataRefreshInfo + d := o.UpdateFrequency.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUpdateFrequency sets the value of the UpdateFrequency field in ListingDetail. +func (o *ListingDetail) SetUpdateFrequency(ctx context.Context, v DataRefreshInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["update_frequency"] + o.UpdateFrequency = types.ListValueMust(t, vs) +} + type ListingFulfillment struct { FulfillmentType types.String `tfsdk:"fulfillment_type" tf:"optional"` @@ -4130,6 +5428,58 @@ func (o ListingFulfillment) Type(ctx context.Context) attr.Type { } } +// GetRepoInfo returns the value of the RepoInfo field in ListingFulfillment as +// a RepoInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingFulfillment) GetRepoInfo(ctx context.Context) (RepoInfo, bool) { + var e RepoInfo + if o.RepoInfo.IsNull() || o.RepoInfo.IsUnknown() { + return e, false + } + var v []RepoInfo + d := o.RepoInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRepoInfo sets the value of the RepoInfo field in ListingFulfillment. +func (o *ListingFulfillment) SetRepoInfo(ctx context.Context, v RepoInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repo_info"] + o.RepoInfo = types.ListValueMust(t, vs) +} + +// GetShareInfo returns the value of the ShareInfo field in ListingFulfillment as +// a ShareInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingFulfillment) GetShareInfo(ctx context.Context) (ShareInfo, bool) { + var e ShareInfo + if o.ShareInfo.IsNull() || o.ShareInfo.IsUnknown() { + return e, false + } + var v []ShareInfo + d := o.ShareInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetShareInfo sets the value of the ShareInfo field in ListingFulfillment. +func (o *ListingFulfillment) SetShareInfo(ctx context.Context, v ShareInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["share_info"] + o.ShareInfo = types.ListValueMust(t, vs) +} + type ListingSetting struct { Visibility types.String `tfsdk:"visibility" tf:"optional"` } @@ -4305,6 +5655,160 @@ func (o ListingSummary) Type(ctx context.Context) attr.Type { } } +// GetCategories returns the value of the Categories field in ListingSummary as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingSummary) GetCategories(ctx context.Context) ([]types.String, bool) { + if o.Categories.IsNull() || o.Categories.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Categories.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCategories sets the value of the Categories field in ListingSummary. +func (o *ListingSummary) SetCategories(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["categories"] + o.Categories = types.ListValueMust(t, vs) +} + +// GetExchangeIds returns the value of the ExchangeIds field in ListingSummary as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingSummary) GetExchangeIds(ctx context.Context) ([]types.String, bool) { + if o.ExchangeIds.IsNull() || o.ExchangeIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ExchangeIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExchangeIds sets the value of the ExchangeIds field in ListingSummary. +func (o *ListingSummary) SetExchangeIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_ids"] + o.ExchangeIds = types.ListValueMust(t, vs) +} + +// GetGitRepo returns the value of the GitRepo field in ListingSummary as +// a RepoInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingSummary) GetGitRepo(ctx context.Context) (RepoInfo, bool) { + var e RepoInfo + if o.GitRepo.IsNull() || o.GitRepo.IsUnknown() { + return e, false + } + var v []RepoInfo + d := o.GitRepo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGitRepo sets the value of the GitRepo field in ListingSummary. +func (o *ListingSummary) SetGitRepo(ctx context.Context, v RepoInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["git_repo"] + o.GitRepo = types.ListValueMust(t, vs) +} + +// GetProviderRegion returns the value of the ProviderRegion field in ListingSummary as +// a RegionInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingSummary) GetProviderRegion(ctx context.Context) (RegionInfo, bool) { + var e RegionInfo + if o.ProviderRegion.IsNull() || o.ProviderRegion.IsUnknown() { + return e, false + } + var v []RegionInfo + d := o.ProviderRegion.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProviderRegion sets the value of the ProviderRegion field in ListingSummary. +func (o *ListingSummary) SetProviderRegion(ctx context.Context, v RegionInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider_region"] + o.ProviderRegion = types.ListValueMust(t, vs) +} + +// GetSetting returns the value of the Setting field in ListingSummary as +// a ListingSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingSummary) GetSetting(ctx context.Context) (ListingSetting, bool) { + var e ListingSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []ListingSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in ListingSummary. +func (o *ListingSummary) SetSetting(ctx context.Context, v ListingSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + +// GetShare returns the value of the Share field in ListingSummary as +// a ShareInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingSummary) GetShare(ctx context.Context) (ShareInfo, bool) { + var e ShareInfo + if o.Share.IsNull() || o.Share.IsUnknown() { + return e, false + } + var v []ShareInfo + d := o.Share.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetShare sets the value of the Share field in ListingSummary. +func (o *ListingSummary) SetShare(ctx context.Context, v ShareInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["share"] + o.Share = types.ListValueMust(t, vs) +} + type ListingTag struct { // Tag name (enum) TagName types.String `tfsdk:"tag_name" tf:"optional"` @@ -4356,6 +5860,31 @@ func (o ListingTag) Type(ctx context.Context) attr.Type { } } +// GetTagValues returns the value of the TagValues field in ListingTag as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListingTag) GetTagValues(ctx context.Context) ([]types.String, bool) { + if o.TagValues.IsNull() || o.TagValues.IsUnknown() { + return nil, false + } + var v []types.String + d := o.TagValues.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTagValues sets the value of the TagValues field in ListingTag. +func (o *ListingTag) SetTagValues(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tag_values"] + o.TagValues = types.ListValueMust(t, vs) +} + type PersonalizationRequest struct { Comment types.String `tfsdk:"comment" tf:"optional"` @@ -4468,6 +5997,84 @@ func (o PersonalizationRequest) Type(ctx context.Context) attr.Type { } } +// GetConsumerRegion returns the value of the ConsumerRegion field in PersonalizationRequest as +// a RegionInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *PersonalizationRequest) GetConsumerRegion(ctx context.Context) (RegionInfo, bool) { + var e RegionInfo + if o.ConsumerRegion.IsNull() || o.ConsumerRegion.IsUnknown() { + return e, false + } + var v []RegionInfo + d := o.ConsumerRegion.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConsumerRegion sets the value of the ConsumerRegion field in PersonalizationRequest. +func (o *PersonalizationRequest) SetConsumerRegion(ctx context.Context, v RegionInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["consumer_region"] + o.ConsumerRegion = types.ListValueMust(t, vs) +} + +// GetContactInfo returns the value of the ContactInfo field in PersonalizationRequest as +// a ContactInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *PersonalizationRequest) GetContactInfo(ctx context.Context) (ContactInfo, bool) { + var e ContactInfo + if o.ContactInfo.IsNull() || o.ContactInfo.IsUnknown() { + return e, false + } + var v []ContactInfo + d := o.ContactInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetContactInfo sets the value of the ContactInfo field in PersonalizationRequest. +func (o *PersonalizationRequest) SetContactInfo(ctx context.Context, v ContactInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["contact_info"] + o.ContactInfo = types.ListValueMust(t, vs) +} + +// GetShare returns the value of the Share field in PersonalizationRequest as +// a ShareInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *PersonalizationRequest) GetShare(ctx context.Context) (ShareInfo, bool) { + var e ShareInfo + if o.Share.IsNull() || o.Share.IsUnknown() { + return e, false + } + var v []ShareInfo + d := o.Share.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetShare sets the value of the Share field in PersonalizationRequest. +func (o *PersonalizationRequest) SetShare(ctx context.Context, v ShareInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["share"] + o.Share = types.ListValueMust(t, vs) +} + type ProviderAnalyticsDashboard struct { Id types.String `tfsdk:"id" tf:""` } @@ -4896,6 +6503,81 @@ func (o SearchListingsRequest) Type(ctx context.Context) attr.Type { } } +// GetAssets returns the value of the Assets field in SearchListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchListingsRequest) GetAssets(ctx context.Context) ([]types.String, bool) { + if o.Assets.IsNull() || o.Assets.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Assets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAssets sets the value of the Assets field in SearchListingsRequest. +func (o *SearchListingsRequest) SetAssets(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assets"] + o.Assets = types.ListValueMust(t, vs) +} + +// GetCategories returns the value of the Categories field in SearchListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchListingsRequest) GetCategories(ctx context.Context) ([]types.String, bool) { + if o.Categories.IsNull() || o.Categories.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Categories.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCategories sets the value of the Categories field in SearchListingsRequest. +func (o *SearchListingsRequest) SetCategories(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["categories"] + o.Categories = types.ListValueMust(t, vs) +} + +// GetProviderIds returns the value of the ProviderIds field in SearchListingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchListingsRequest) GetProviderIds(ctx context.Context) ([]types.String, bool) { + if o.ProviderIds.IsNull() || o.ProviderIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ProviderIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProviderIds sets the value of the ProviderIds field in SearchListingsRequest. +func (o *SearchListingsRequest) SetProviderIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider_ids"] + o.ProviderIds = types.ListValueMust(t, vs) +} + type SearchListingsResponse struct { Listings types.List `tfsdk:"listings" tf:"optional"` @@ -4945,6 +6627,31 @@ func (o SearchListingsResponse) Type(ctx context.Context) attr.Type { } } +// GetListings returns the value of the Listings field in SearchListingsResponse as +// a slice of Listing values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchListingsResponse) GetListings(ctx context.Context) ([]Listing, bool) { + if o.Listings.IsNull() || o.Listings.IsUnknown() { + return nil, false + } + var v []Listing + d := o.Listings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetListings sets the value of the Listings field in SearchListingsResponse. +func (o *SearchListingsResponse) SetListings(ctx context.Context, v []Listing) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + o.Listings = types.ListValueMust(t, vs) +} + type ShareInfo struct { Name types.String `tfsdk:"name" tf:""` @@ -5208,6 +6915,32 @@ func (o UpdateExchangeFilterRequest) Type(ctx context.Context) attr.Type { } } +// GetFilter returns the value of the Filter field in UpdateExchangeFilterRequest as +// a ExchangeFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateExchangeFilterRequest) GetFilter(ctx context.Context) (ExchangeFilter, bool) { + var e ExchangeFilter + if o.Filter.IsNull() || o.Filter.IsUnknown() { + return e, false + } + var v []ExchangeFilter + d := o.Filter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilter sets the value of the Filter field in UpdateExchangeFilterRequest. +func (o *UpdateExchangeFilterRequest) SetFilter(ctx context.Context, v ExchangeFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter"] + o.Filter = types.ListValueMust(t, vs) +} + type UpdateExchangeFilterResponse struct { Filter types.List `tfsdk:"filter" tf:"optional,object"` } @@ -5253,6 +6986,32 @@ func (o UpdateExchangeFilterResponse) Type(ctx context.Context) attr.Type { } } +// GetFilter returns the value of the Filter field in UpdateExchangeFilterResponse as +// a ExchangeFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateExchangeFilterResponse) GetFilter(ctx context.Context) (ExchangeFilter, bool) { + var e ExchangeFilter + if o.Filter.IsNull() || o.Filter.IsUnknown() { + return e, false + } + var v []ExchangeFilter + d := o.Filter.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilter sets the value of the Filter field in UpdateExchangeFilterResponse. +func (o *UpdateExchangeFilterResponse) SetFilter(ctx context.Context, v ExchangeFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter"] + o.Filter = types.ListValueMust(t, vs) +} + type UpdateExchangeRequest struct { Exchange types.List `tfsdk:"exchange" tf:"object"` @@ -5302,6 +7061,32 @@ func (o UpdateExchangeRequest) Type(ctx context.Context) attr.Type { } } +// GetExchange returns the value of the Exchange field in UpdateExchangeRequest as +// a Exchange value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateExchangeRequest) GetExchange(ctx context.Context) (Exchange, bool) { + var e Exchange + if o.Exchange.IsNull() || o.Exchange.IsUnknown() { + return e, false + } + var v []Exchange + d := o.Exchange.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExchange sets the value of the Exchange field in UpdateExchangeRequest. +func (o *UpdateExchangeRequest) SetExchange(ctx context.Context, v Exchange) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange"] + o.Exchange = types.ListValueMust(t, vs) +} + type UpdateExchangeResponse struct { Exchange types.List `tfsdk:"exchange" tf:"optional,object"` } @@ -5347,6 +7132,32 @@ func (o UpdateExchangeResponse) Type(ctx context.Context) attr.Type { } } +// GetExchange returns the value of the Exchange field in UpdateExchangeResponse as +// a Exchange value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateExchangeResponse) GetExchange(ctx context.Context) (Exchange, bool) { + var e Exchange + if o.Exchange.IsNull() || o.Exchange.IsUnknown() { + return e, false + } + var v []Exchange + d := o.Exchange.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExchange sets the value of the Exchange field in UpdateExchangeResponse. +func (o *UpdateExchangeResponse) SetExchange(ctx context.Context, v Exchange) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange"] + o.Exchange = types.ListValueMust(t, vs) +} + type UpdateInstallationRequest struct { Installation types.List `tfsdk:"installation" tf:"object"` @@ -5404,6 +7215,32 @@ func (o UpdateInstallationRequest) Type(ctx context.Context) attr.Type { } } +// GetInstallation returns the value of the Installation field in UpdateInstallationRequest as +// a InstallationDetail value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateInstallationRequest) GetInstallation(ctx context.Context) (InstallationDetail, bool) { + var e InstallationDetail + if o.Installation.IsNull() || o.Installation.IsUnknown() { + return e, false + } + var v []InstallationDetail + d := o.Installation.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInstallation sets the value of the Installation field in UpdateInstallationRequest. +func (o *UpdateInstallationRequest) SetInstallation(ctx context.Context, v InstallationDetail) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installation"] + o.Installation = types.ListValueMust(t, vs) +} + type UpdateInstallationResponse struct { Installation types.List `tfsdk:"installation" tf:"optional,object"` } @@ -5449,6 +7286,32 @@ func (o UpdateInstallationResponse) Type(ctx context.Context) attr.Type { } } +// GetInstallation returns the value of the Installation field in UpdateInstallationResponse as +// a InstallationDetail value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateInstallationResponse) GetInstallation(ctx context.Context) (InstallationDetail, bool) { + var e InstallationDetail + if o.Installation.IsNull() || o.Installation.IsUnknown() { + return e, false + } + var v []InstallationDetail + d := o.Installation.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInstallation sets the value of the Installation field in UpdateInstallationResponse. +func (o *UpdateInstallationResponse) SetInstallation(ctx context.Context, v InstallationDetail) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installation"] + o.Installation = types.ListValueMust(t, vs) +} + type UpdateListingRequest struct { Id types.String `tfsdk:"-"` @@ -5498,6 +7361,32 @@ func (o UpdateListingRequest) Type(ctx context.Context) attr.Type { } } +// GetListing returns the value of the Listing field in UpdateListingRequest as +// a Listing value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateListingRequest) GetListing(ctx context.Context) (Listing, bool) { + var e Listing + if o.Listing.IsNull() || o.Listing.IsUnknown() { + return e, false + } + var v []Listing + d := o.Listing.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetListing sets the value of the Listing field in UpdateListingRequest. +func (o *UpdateListingRequest) SetListing(ctx context.Context, v Listing) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listing"] + o.Listing = types.ListValueMust(t, vs) +} + type UpdateListingResponse struct { Listing types.List `tfsdk:"listing" tf:"optional,object"` } @@ -5543,6 +7432,32 @@ func (o UpdateListingResponse) Type(ctx context.Context) attr.Type { } } +// GetListing returns the value of the Listing field in UpdateListingResponse as +// a Listing value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateListingResponse) GetListing(ctx context.Context) (Listing, bool) { + var e Listing + if o.Listing.IsNull() || o.Listing.IsUnknown() { + return e, false + } + var v []Listing + d := o.Listing.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetListing sets the value of the Listing field in UpdateListingResponse. +func (o *UpdateListingResponse) SetListing(ctx context.Context, v Listing) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listing"] + o.Listing = types.ListValueMust(t, vs) +} + type UpdatePersonalizationRequestRequest struct { ListingId types.String `tfsdk:"-"` @@ -5604,6 +7519,32 @@ func (o UpdatePersonalizationRequestRequest) Type(ctx context.Context) attr.Type } } +// GetShare returns the value of the Share field in UpdatePersonalizationRequestRequest as +// a ShareInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdatePersonalizationRequestRequest) GetShare(ctx context.Context) (ShareInfo, bool) { + var e ShareInfo + if o.Share.IsNull() || o.Share.IsUnknown() { + return e, false + } + var v []ShareInfo + d := o.Share.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetShare sets the value of the Share field in UpdatePersonalizationRequestRequest. +func (o *UpdatePersonalizationRequestRequest) SetShare(ctx context.Context, v ShareInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["share"] + o.Share = types.ListValueMust(t, vs) +} + type UpdatePersonalizationRequestResponse struct { Request types.List `tfsdk:"request" tf:"optional,object"` } @@ -5649,6 +7590,32 @@ func (o UpdatePersonalizationRequestResponse) Type(ctx context.Context) attr.Typ } } +// GetRequest returns the value of the Request field in UpdatePersonalizationRequestResponse as +// a PersonalizationRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdatePersonalizationRequestResponse) GetRequest(ctx context.Context) (PersonalizationRequest, bool) { + var e PersonalizationRequest + if o.Request.IsNull() || o.Request.IsUnknown() { + return e, false + } + var v []PersonalizationRequest + d := o.Request.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRequest sets the value of the Request field in UpdatePersonalizationRequestResponse. +func (o *UpdatePersonalizationRequestResponse) SetRequest(ctx context.Context, v PersonalizationRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["request"] + o.Request = types.ListValueMust(t, vs) +} + type UpdateProviderAnalyticsDashboardRequest struct { // id is immutable property and can't be updated. Id types.String `tfsdk:"-"` @@ -5796,6 +7763,32 @@ func (o UpdateProviderRequest) Type(ctx context.Context) attr.Type { } } +// GetProvider returns the value of the Provider field in UpdateProviderRequest as +// a ProviderInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateProviderRequest) GetProvider(ctx context.Context) (ProviderInfo, bool) { + var e ProviderInfo + if o.Provider.IsNull() || o.Provider.IsUnknown() { + return e, false + } + var v []ProviderInfo + d := o.Provider.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvider sets the value of the Provider field in UpdateProviderRequest. +func (o *UpdateProviderRequest) SetProvider(ctx context.Context, v ProviderInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider"] + o.Provider = types.ListValueMust(t, vs) +} + type UpdateProviderResponse struct { Provider types.List `tfsdk:"provider" tf:"optional,object"` } @@ -5841,4 +7834,28 @@ func (o UpdateProviderResponse) Type(ctx context.Context) attr.Type { } } -// Enums +// GetProvider returns the value of the Provider field in UpdateProviderResponse as +// a ProviderInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateProviderResponse) GetProvider(ctx context.Context) (ProviderInfo, bool) { + var e ProviderInfo + if o.Provider.IsNull() || o.Provider.IsUnknown() { + return e, false + } + var v []ProviderInfo + d := o.Provider.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetProvider sets the value of the Provider field in UpdateProviderResponse. +func (o *UpdateProviderResponse) SetProvider(ctx context.Context, v ProviderInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider"] + o.Provider = types.ListValueMust(t, vs) +} diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 65207e13ac..f582fdacf2 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -241,6 +242,32 @@ func (o ApproveTransitionRequestResponse) Type(ctx context.Context) attr.Type { } } +// GetActivity returns the value of the Activity field in ApproveTransitionRequestResponse as +// a Activity value. +// If the field is unknown or null, the boolean return value is false. +func (o *ApproveTransitionRequestResponse) GetActivity(ctx context.Context) (Activity, bool) { + var e Activity + if o.Activity.IsNull() || o.Activity.IsUnknown() { + return e, false + } + var v []Activity + d := o.Activity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetActivity sets the value of the Activity field in ApproveTransitionRequestResponse. +func (o *ApproveTransitionRequestResponse) SetActivity(ctx context.Context, v Activity) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["activity"] + o.Activity = types.ListValueMust(t, vs) +} + // Comment details. type CommentObject struct { // Array of actions on the activity allowed for the current viewer. @@ -308,6 +335,31 @@ func (o CommentObject) Type(ctx context.Context) attr.Type { } } +// GetAvailableActions returns the value of the AvailableActions field in CommentObject as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CommentObject) GetAvailableActions(ctx context.Context) ([]types.String, bool) { + if o.AvailableActions.IsNull() || o.AvailableActions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.AvailableActions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAvailableActions sets the value of the AvailableActions field in CommentObject. +func (o *CommentObject) SetAvailableActions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["available_actions"] + o.AvailableActions = types.ListValueMust(t, vs) +} + type CreateComment struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:""` @@ -404,6 +456,32 @@ func (o CreateCommentResponse) Type(ctx context.Context) attr.Type { } } +// GetComment returns the value of the Comment field in CreateCommentResponse as +// a CommentObject value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCommentResponse) GetComment(ctx context.Context) (CommentObject, bool) { + var e CommentObject + if o.Comment.IsNull() || o.Comment.IsUnknown() { + return e, false + } + var v []CommentObject + d := o.Comment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetComment sets the value of the Comment field in CreateCommentResponse. +func (o *CreateCommentResponse) SetComment(ctx context.Context, v CommentObject) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["comment"] + o.Comment = types.ListValueMust(t, vs) +} + type CreateExperiment struct { // Location where all artifacts for the experiment are stored. If not // provided, the remote server will select an appropriate default. @@ -463,6 +541,31 @@ func (o CreateExperiment) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in CreateExperiment as +// a slice of ExperimentTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateExperiment) GetTags(ctx context.Context) ([]ExperimentTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ExperimentTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateExperiment. +func (o *CreateExperiment) SetTags(ctx context.Context, v []ExperimentTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type CreateExperimentResponse struct { // Unique identifier for the experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:"optional"` @@ -559,6 +662,31 @@ func (o CreateModelRequest) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in CreateModelRequest as +// a slice of ModelTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateModelRequest) GetTags(ctx context.Context) ([]ModelTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ModelTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateModelRequest. +func (o *CreateModelRequest) SetTags(ctx context.Context, v []ModelTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type CreateModelResponse struct { RegisteredModel types.List `tfsdk:"registered_model" tf:"optional,object"` } @@ -604,6 +732,32 @@ func (o CreateModelResponse) Type(ctx context.Context) attr.Type { } } +// GetRegisteredModel returns the value of the RegisteredModel field in CreateModelResponse as +// a Model value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateModelResponse) GetRegisteredModel(ctx context.Context) (Model, bool) { + var e Model + if o.RegisteredModel.IsNull() || o.RegisteredModel.IsUnknown() { + return e, false + } + var v []Model + d := o.RegisteredModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRegisteredModel sets the value of the RegisteredModel field in CreateModelResponse. +func (o *CreateModelResponse) SetRegisteredModel(ctx context.Context, v Model) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_model"] + o.RegisteredModel = types.ListValueMust(t, vs) +} + type CreateModelVersionRequest struct { // Optional description for model version. Description types.String `tfsdk:"description" tf:"optional"` @@ -672,6 +826,31 @@ func (o CreateModelVersionRequest) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in CreateModelVersionRequest as +// a slice of ModelVersionTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateModelVersionRequest) GetTags(ctx context.Context) ([]ModelVersionTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ModelVersionTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateModelVersionRequest. +func (o *CreateModelVersionRequest) SetTags(ctx context.Context, v []ModelVersionTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type CreateModelVersionResponse struct { // Return new version number generated for this model in registry. ModelVersion types.List `tfsdk:"model_version" tf:"optional,object"` @@ -718,6 +897,32 @@ func (o CreateModelVersionResponse) Type(ctx context.Context) attr.Type { } } +// GetModelVersion returns the value of the ModelVersion field in CreateModelVersionResponse as +// a ModelVersion value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateModelVersionResponse) GetModelVersion(ctx context.Context) (ModelVersion, bool) { + var e ModelVersion + if o.ModelVersion.IsNull() || o.ModelVersion.IsUnknown() { + return e, false + } + var v []ModelVersion + d := o.ModelVersion.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetModelVersion sets the value of the ModelVersion field in CreateModelVersionResponse. +func (o *CreateModelVersionResponse) SetModelVersion(ctx context.Context, v ModelVersion) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_version"] + o.ModelVersion = types.ListValueMust(t, vs) +} + type CreateRegistryWebhook struct { // User-specified description for the webhook. Description types.String `tfsdk:"description" tf:"optional"` @@ -829,6 +1034,83 @@ func (o CreateRegistryWebhook) Type(ctx context.Context) attr.Type { } } +// GetEvents returns the value of the Events field in CreateRegistryWebhook as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRegistryWebhook) GetEvents(ctx context.Context) ([]types.String, bool) { + if o.Events.IsNull() || o.Events.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Events.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEvents sets the value of the Events field in CreateRegistryWebhook. +func (o *CreateRegistryWebhook) SetEvents(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + o.Events = types.ListValueMust(t, vs) +} + +// GetHttpUrlSpec returns the value of the HttpUrlSpec field in CreateRegistryWebhook as +// a HttpUrlSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRegistryWebhook) GetHttpUrlSpec(ctx context.Context) (HttpUrlSpec, bool) { + var e HttpUrlSpec + if o.HttpUrlSpec.IsNull() || o.HttpUrlSpec.IsUnknown() { + return e, false + } + var v []HttpUrlSpec + d := o.HttpUrlSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHttpUrlSpec sets the value of the HttpUrlSpec field in CreateRegistryWebhook. +func (o *CreateRegistryWebhook) SetHttpUrlSpec(ctx context.Context, v HttpUrlSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["http_url_spec"] + o.HttpUrlSpec = types.ListValueMust(t, vs) +} + +// GetJobSpec returns the value of the JobSpec field in CreateRegistryWebhook as +// a JobSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRegistryWebhook) GetJobSpec(ctx context.Context) (JobSpec, bool) { + var e JobSpec + if o.JobSpec.IsNull() || o.JobSpec.IsUnknown() { + return e, false + } + var v []JobSpec + d := o.JobSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetJobSpec sets the value of the JobSpec field in CreateRegistryWebhook. +func (o *CreateRegistryWebhook) SetJobSpec(ctx context.Context, v JobSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_spec"] + o.JobSpec = types.ListValueMust(t, vs) +} + type CreateRun struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:"optional"` @@ -889,6 +1171,31 @@ func (o CreateRun) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in CreateRun as +// a slice of RunTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRun) GetTags(ctx context.Context) ([]RunTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []RunTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateRun. +func (o *CreateRun) SetTags(ctx context.Context, v []RunTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type CreateRunResponse struct { // The newly created run. Run types.List `tfsdk:"run" tf:"optional,object"` @@ -935,6 +1242,32 @@ func (o CreateRunResponse) Type(ctx context.Context) attr.Type { } } +// GetRun returns the value of the Run field in CreateRunResponse as +// a Run value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRunResponse) GetRun(ctx context.Context) (Run, bool) { + var e Run + if o.Run.IsNull() || o.Run.IsUnknown() { + return e, false + } + var v []Run + d := o.Run.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRun sets the value of the Run field in CreateRunResponse. +func (o *CreateRunResponse) SetRun(ctx context.Context, v Run) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run"] + o.Run = types.ListValueMust(t, vs) +} + type CreateTransitionRequest struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1043,6 +1376,32 @@ func (o CreateTransitionRequestResponse) Type(ctx context.Context) attr.Type { } } +// GetRequest returns the value of the Request field in CreateTransitionRequestResponse as +// a TransitionRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateTransitionRequestResponse) GetRequest(ctx context.Context) (TransitionRequest, bool) { + var e TransitionRequest + if o.Request.IsNull() || o.Request.IsUnknown() { + return e, false + } + var v []TransitionRequest + d := o.Request.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRequest sets the value of the Request field in CreateTransitionRequestResponse. +func (o *CreateTransitionRequestResponse) SetRequest(ctx context.Context, v TransitionRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["request"] + o.Request = types.ListValueMust(t, vs) +} + type CreateWebhookResponse struct { Webhook types.List `tfsdk:"webhook" tf:"optional,object"` } @@ -1088,6 +1447,32 @@ func (o CreateWebhookResponse) Type(ctx context.Context) attr.Type { } } +// GetWebhook returns the value of the Webhook field in CreateWebhookResponse as +// a RegistryWebhook value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWebhookResponse) GetWebhook(ctx context.Context) (RegistryWebhook, bool) { + var e RegistryWebhook + if o.Webhook.IsNull() || o.Webhook.IsUnknown() { + return e, false + } + var v []RegistryWebhook + d := o.Webhook.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhook sets the value of the Webhook field in CreateWebhookResponse. +func (o *CreateWebhookResponse) SetWebhook(ctx context.Context, v RegistryWebhook) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook"] + o.Webhook = types.ListValueMust(t, vs) +} + type Dataset struct { // Dataset digest, e.g. an md5 hash of the dataset that uniquely identifies // it within datasets of the same name. @@ -1212,6 +1597,57 @@ func (o DatasetInput) Type(ctx context.Context) attr.Type { } } +// GetDataset returns the value of the Dataset field in DatasetInput as +// a Dataset value. +// If the field is unknown or null, the boolean return value is false. +func (o *DatasetInput) GetDataset(ctx context.Context) (Dataset, bool) { + var e Dataset + if o.Dataset.IsNull() || o.Dataset.IsUnknown() { + return e, false + } + var v []Dataset + d := o.Dataset.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataset sets the value of the Dataset field in DatasetInput. +func (o *DatasetInput) SetDataset(ctx context.Context, v Dataset) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataset"] + o.Dataset = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in DatasetInput as +// a slice of InputTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *DatasetInput) GetTags(ctx context.Context) ([]InputTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []InputTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in DatasetInput. +func (o *DatasetInput) SetTags(ctx context.Context, v []InputTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + // Delete a comment type DeleteCommentRequest struct { Id types.String `tfsdk:"-"` @@ -2212,6 +2648,31 @@ func (o Experiment) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in Experiment as +// a slice of ExperimentTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *Experiment) GetTags(ctx context.Context) ([]ExperimentTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ExperimentTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in Experiment. +func (o *Experiment) SetTags(ctx context.Context, v []ExperimentTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ExperimentAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -2328,6 +2789,31 @@ func (o ExperimentAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in ExperimentAccessControlResponse as +// a slice of ExperimentPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExperimentAccessControlResponse) GetAllPermissions(ctx context.Context) ([]ExperimentPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []ExperimentPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in ExperimentAccessControlResponse. +func (o *ExperimentAccessControlResponse) SetAllPermissions(ctx context.Context, v []ExperimentPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type ExperimentPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2381,6 +2867,31 @@ func (o ExperimentPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in ExperimentPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExperimentPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in ExperimentPermission. +func (o *ExperimentPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type ExperimentPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -2434,6 +2945,31 @@ func (o ExperimentPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ExperimentPermissions as +// a slice of ExperimentAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExperimentPermissions) GetAccessControlList(ctx context.Context) ([]ExperimentAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ExperimentAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ExperimentPermissions. +func (o *ExperimentPermissions) SetAccessControlList(ctx context.Context, v []ExperimentAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type ExperimentPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2528,6 +3064,31 @@ func (o ExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ExperimentPermissionsRequest as +// a slice of ExperimentAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExperimentPermissionsRequest) GetAccessControlList(ctx context.Context) ([]ExperimentAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ExperimentAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ExperimentPermissionsRequest. +func (o *ExperimentPermissionsRequest) SetAccessControlList(ctx context.Context, v []ExperimentAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type ExperimentTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -2756,6 +3317,31 @@ func (o GetExperimentPermissionLevelsResponse) Type(ctx context.Context) attr.Ty } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetExperimentPermissionLevelsResponse as +// a slice of ExperimentPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetExperimentPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]ExperimentPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []ExperimentPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetExperimentPermissionLevelsResponse. +func (o *GetExperimentPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []ExperimentPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get experiment permissions type GetExperimentPermissionsRequest struct { // The experiment for which to get or manage permissions. @@ -2888,6 +3474,32 @@ func (o GetExperimentResponse) Type(ctx context.Context) attr.Type { } } +// GetExperiment returns the value of the Experiment field in GetExperimentResponse as +// a Experiment value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetExperimentResponse) GetExperiment(ctx context.Context) (Experiment, bool) { + var e Experiment + if o.Experiment.IsNull() || o.Experiment.IsUnknown() { + return e, false + } + var v []Experiment + d := o.Experiment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExperiment sets the value of the Experiment field in GetExperimentResponse. +func (o *GetExperimentResponse) SetExperiment(ctx context.Context, v Experiment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiment"] + o.Experiment = types.ListValueMust(t, vs) +} + // Get history of a given metric within a run type GetHistoryRequest struct { // Maximum number of Metric records to return per paginated request. Default @@ -3000,6 +3612,31 @@ func (o GetLatestVersionsRequest) Type(ctx context.Context) attr.Type { } } +// GetStages returns the value of the Stages field in GetLatestVersionsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetLatestVersionsRequest) GetStages(ctx context.Context) ([]types.String, bool) { + if o.Stages.IsNull() || o.Stages.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Stages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStages sets the value of the Stages field in GetLatestVersionsRequest. +func (o *GetLatestVersionsRequest) SetStages(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stages"] + o.Stages = types.ListValueMust(t, vs) +} + type GetLatestVersionsResponse struct { // Latest version models for each requests stage. Only return models with // current `READY` status. If no `stages` provided, returns the latest @@ -3048,6 +3685,31 @@ func (o GetLatestVersionsResponse) Type(ctx context.Context) attr.Type { } } +// GetModelVersions returns the value of the ModelVersions field in GetLatestVersionsResponse as +// a slice of ModelVersion values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetLatestVersionsResponse) GetModelVersions(ctx context.Context) ([]ModelVersion, bool) { + if o.ModelVersions.IsNull() || o.ModelVersions.IsUnknown() { + return nil, false + } + var v []ModelVersion + d := o.ModelVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetModelVersions sets the value of the ModelVersions field in GetLatestVersionsResponse. +func (o *GetLatestVersionsResponse) SetModelVersions(ctx context.Context, v []ModelVersion) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_versions"] + o.ModelVersions = types.ListValueMust(t, vs) +} + type GetMetricHistoryResponse struct { // All logged values for this metric. Metrics types.List `tfsdk:"metrics" tf:"optional"` @@ -3099,6 +3761,31 @@ func (o GetMetricHistoryResponse) Type(ctx context.Context) attr.Type { } } +// GetMetrics returns the value of the Metrics field in GetMetricHistoryResponse as +// a slice of Metric values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetMetricHistoryResponse) GetMetrics(ctx context.Context) ([]Metric, bool) { + if o.Metrics.IsNull() || o.Metrics.IsUnknown() { + return nil, false + } + var v []Metric + d := o.Metrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMetrics sets the value of the Metrics field in GetMetricHistoryResponse. +func (o *GetMetricHistoryResponse) SetMetrics(ctx context.Context, v []Metric) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + o.Metrics = types.ListValueMust(t, vs) +} + // Get model type GetModelRequest struct { // Registered model unique name identifier. @@ -3187,6 +3874,32 @@ func (o GetModelResponse) Type(ctx context.Context) attr.Type { } } +// GetRegisteredModelDatabricks returns the value of the RegisteredModelDatabricks field in GetModelResponse as +// a ModelDatabricks value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetModelResponse) GetRegisteredModelDatabricks(ctx context.Context) (ModelDatabricks, bool) { + var e ModelDatabricks + if o.RegisteredModelDatabricks.IsNull() || o.RegisteredModelDatabricks.IsUnknown() { + return e, false + } + var v []ModelDatabricks + d := o.RegisteredModelDatabricks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRegisteredModelDatabricks sets the value of the RegisteredModelDatabricks field in GetModelResponse. +func (o *GetModelResponse) SetRegisteredModelDatabricks(ctx context.Context, v ModelDatabricks) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_model_databricks"] + o.RegisteredModelDatabricks = types.ListValueMust(t, vs) +} + // Get a model version URI type GetModelVersionDownloadUriRequest struct { // Name of the registered model @@ -3368,6 +4081,32 @@ func (o GetModelVersionResponse) Type(ctx context.Context) attr.Type { } } +// GetModelVersion returns the value of the ModelVersion field in GetModelVersionResponse as +// a ModelVersion value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetModelVersionResponse) GetModelVersion(ctx context.Context) (ModelVersion, bool) { + var e ModelVersion + if o.ModelVersion.IsNull() || o.ModelVersion.IsUnknown() { + return e, false + } + var v []ModelVersion + d := o.ModelVersion.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetModelVersion sets the value of the ModelVersion field in GetModelVersionResponse. +func (o *GetModelVersionResponse) SetModelVersion(ctx context.Context, v ModelVersion) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_version"] + o.ModelVersion = types.ListValueMust(t, vs) +} + // Get registered model permission levels type GetRegisteredModelPermissionLevelsRequest struct { // The registered model for which to get or manage permissions. @@ -3457,6 +4196,31 @@ func (o GetRegisteredModelPermissionLevelsResponse) Type(ctx context.Context) at } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetRegisteredModelPermissionLevelsResponse as +// a slice of RegisteredModelPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetRegisteredModelPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]RegisteredModelPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []RegisteredModelPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetRegisteredModelPermissionLevelsResponse. +func (o *GetRegisteredModelPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []RegisteredModelPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get registered model permissions type GetRegisteredModelPermissionsRequest struct { // The registered model for which to get or manage permissions. @@ -3595,6 +4359,32 @@ func (o GetRunResponse) Type(ctx context.Context) attr.Type { } } +// GetRun returns the value of the Run field in GetRunResponse as +// a Run value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetRunResponse) GetRun(ctx context.Context) (Run, bool) { + var e Run + if o.Run.IsNull() || o.Run.IsUnknown() { + return e, false + } + var v []Run + d := o.Run.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRun sets the value of the Run field in GetRunResponse. +func (o *GetRunResponse) SetRun(ctx context.Context, v Run) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run"] + o.Run = types.ListValueMust(t, vs) +} + type HttpUrlSpec struct { // Value of the authorization header that should be sent in the request sent // by the wehbook. It should be of the form `" "`. @@ -3974,6 +4764,31 @@ func (o ListArtifactsResponse) Type(ctx context.Context) attr.Type { } } +// GetFiles returns the value of the Files field in ListArtifactsResponse as +// a slice of FileInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListArtifactsResponse) GetFiles(ctx context.Context) ([]FileInfo, bool) { + if o.Files.IsNull() || o.Files.IsUnknown() { + return nil, false + } + var v []FileInfo + d := o.Files.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFiles sets the value of the Files field in ListArtifactsResponse. +func (o *ListArtifactsResponse) SetFiles(ctx context.Context, v []FileInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["files"] + o.Files = types.ListValueMust(t, vs) +} + // List experiments type ListExperimentsRequest struct { // Maximum number of experiments desired. If `max_results` is unspecified, @@ -4082,6 +4897,31 @@ func (o ListExperimentsResponse) Type(ctx context.Context) attr.Type { } } +// GetExperiments returns the value of the Experiments field in ListExperimentsResponse as +// a slice of Experiment values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListExperimentsResponse) GetExperiments(ctx context.Context) ([]Experiment, bool) { + if o.Experiments.IsNull() || o.Experiments.IsUnknown() { + return nil, false + } + var v []Experiment + d := o.Experiments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExperiments sets the value of the Experiments field in ListExperimentsResponse. +func (o *ListExperimentsResponse) SetExperiments(ctx context.Context, v []Experiment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiments"] + o.Experiments = types.ListValueMust(t, vs) +} + // List models type ListModelsRequest struct { // Maximum number of registered models desired. Max threshold is 1000. @@ -4179,6 +5019,31 @@ func (o ListModelsResponse) Type(ctx context.Context) attr.Type { } } +// GetRegisteredModels returns the value of the RegisteredModels field in ListModelsResponse as +// a slice of Model values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListModelsResponse) GetRegisteredModels(ctx context.Context) ([]Model, bool) { + if o.RegisteredModels.IsNull() || o.RegisteredModels.IsUnknown() { + return nil, false + } + var v []Model + d := o.RegisteredModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRegisteredModels sets the value of the RegisteredModels field in ListModelsResponse. +func (o *ListModelsResponse) SetRegisteredModels(ctx context.Context, v []Model) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_models"] + o.RegisteredModels = types.ListValueMust(t, vs) +} + type ListRegistryWebhooks struct { // Token that can be used to retrieve the next page of artifact results NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -4229,6 +5094,31 @@ func (o ListRegistryWebhooks) Type(ctx context.Context) attr.Type { } } +// GetWebhooks returns the value of the Webhooks field in ListRegistryWebhooks as +// a slice of RegistryWebhook values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListRegistryWebhooks) GetWebhooks(ctx context.Context) ([]RegistryWebhook, bool) { + if o.Webhooks.IsNull() || o.Webhooks.IsUnknown() { + return nil, false + } + var v []RegistryWebhook + d := o.Webhooks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWebhooks sets the value of the Webhooks field in ListRegistryWebhooks. +func (o *ListRegistryWebhooks) SetWebhooks(ctx context.Context, v []RegistryWebhook) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhooks"] + o.Webhooks = types.ListValueMust(t, vs) +} + // List transition requests type ListTransitionRequestsRequest struct { // Name of the model. @@ -4322,6 +5212,31 @@ func (o ListTransitionRequestsResponse) Type(ctx context.Context) attr.Type { } } +// GetRequests returns the value of the Requests field in ListTransitionRequestsResponse as +// a slice of Activity values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListTransitionRequestsResponse) GetRequests(ctx context.Context) ([]Activity, bool) { + if o.Requests.IsNull() || o.Requests.IsUnknown() { + return nil, false + } + var v []Activity + d := o.Requests.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRequests sets the value of the Requests field in ListTransitionRequestsResponse. +func (o *ListTransitionRequestsResponse) SetRequests(ctx context.Context, v []Activity) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["requests"] + o.Requests = types.ListValueMust(t, vs) +} + // List registry webhooks type ListWebhooksRequest struct { // If `events` is specified, any webhook with one or more of the specified @@ -4380,10 +5295,35 @@ func (o ListWebhooksRequest) Type(ctx context.Context) attr.Type { } } -type LogBatch struct { - // Metrics to log. A single request can contain up to 1000 metrics, and up - // to 1000 metrics, params, and tags in total. - Metrics types.List `tfsdk:"metrics" tf:"optional"` +// GetEvents returns the value of the Events field in ListWebhooksRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListWebhooksRequest) GetEvents(ctx context.Context) ([]types.String, bool) { + if o.Events.IsNull() || o.Events.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Events.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEvents sets the value of the Events field in ListWebhooksRequest. +func (o *ListWebhooksRequest) SetEvents(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + o.Events = types.ListValueMust(t, vs) +} + +type LogBatch struct { + // Metrics to log. A single request can contain up to 1000 metrics, and up + // to 1000 metrics, params, and tags in total. + Metrics types.List `tfsdk:"metrics" tf:"optional"` // Params to log. A single request can contain up to 100 params, and up to // 1000 metrics, params, and tags in total. Params types.List `tfsdk:"params" tf:"optional"` @@ -4447,6 +5387,81 @@ func (o LogBatch) Type(ctx context.Context) attr.Type { } } +// GetMetrics returns the value of the Metrics field in LogBatch as +// a slice of Metric values. +// If the field is unknown or null, the boolean return value is false. +func (o *LogBatch) GetMetrics(ctx context.Context) ([]Metric, bool) { + if o.Metrics.IsNull() || o.Metrics.IsUnknown() { + return nil, false + } + var v []Metric + d := o.Metrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMetrics sets the value of the Metrics field in LogBatch. +func (o *LogBatch) SetMetrics(ctx context.Context, v []Metric) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + o.Metrics = types.ListValueMust(t, vs) +} + +// GetParams returns the value of the Params field in LogBatch as +// a slice of Param values. +// If the field is unknown or null, the boolean return value is false. +func (o *LogBatch) GetParams(ctx context.Context) ([]Param, bool) { + if o.Params.IsNull() || o.Params.IsUnknown() { + return nil, false + } + var v []Param + d := o.Params.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParams sets the value of the Params field in LogBatch. +func (o *LogBatch) SetParams(ctx context.Context, v []Param) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["params"] + o.Params = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in LogBatch as +// a slice of RunTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *LogBatch) GetTags(ctx context.Context) ([]RunTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []RunTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in LogBatch. +func (o *LogBatch) SetTags(ctx context.Context, v []RunTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type LogBatchResponse struct { } @@ -4533,6 +5548,31 @@ func (o LogInputs) Type(ctx context.Context) attr.Type { } } +// GetDatasets returns the value of the Datasets field in LogInputs as +// a slice of DatasetInput values. +// If the field is unknown or null, the boolean return value is false. +func (o *LogInputs) GetDatasets(ctx context.Context) ([]DatasetInput, bool) { + if o.Datasets.IsNull() || o.Datasets.IsUnknown() { + return nil, false + } + var v []DatasetInput + d := o.Datasets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDatasets sets the value of the Datasets field in LogInputs. +func (o *LogInputs) SetDatasets(ctx context.Context, v []DatasetInput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["datasets"] + o.Datasets = types.ListValueMust(t, vs) +} + type LogInputsResponse struct { } @@ -4970,6 +6010,56 @@ func (o Model) Type(ctx context.Context) attr.Type { } } +// GetLatestVersions returns the value of the LatestVersions field in Model as +// a slice of ModelVersion values. +// If the field is unknown or null, the boolean return value is false. +func (o *Model) GetLatestVersions(ctx context.Context) ([]ModelVersion, bool) { + if o.LatestVersions.IsNull() || o.LatestVersions.IsUnknown() { + return nil, false + } + var v []ModelVersion + d := o.LatestVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLatestVersions sets the value of the LatestVersions field in Model. +func (o *Model) SetLatestVersions(ctx context.Context, v []ModelVersion) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_versions"] + o.LatestVersions = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in Model as +// a slice of ModelTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *Model) GetTags(ctx context.Context) ([]ModelTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ModelTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in Model. +func (o *Model) SetTags(ctx context.Context, v []ModelTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ModelDatabricks struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -5052,6 +6142,56 @@ func (o ModelDatabricks) Type(ctx context.Context) attr.Type { } } +// GetLatestVersions returns the value of the LatestVersions field in ModelDatabricks as +// a slice of ModelVersion values. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelDatabricks) GetLatestVersions(ctx context.Context) ([]ModelVersion, bool) { + if o.LatestVersions.IsNull() || o.LatestVersions.IsUnknown() { + return nil, false + } + var v []ModelVersion + d := o.LatestVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLatestVersions sets the value of the LatestVersions field in ModelDatabricks. +func (o *ModelDatabricks) SetLatestVersions(ctx context.Context, v []ModelVersion) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_versions"] + o.LatestVersions = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in ModelDatabricks as +// a slice of ModelTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelDatabricks) GetTags(ctx context.Context) ([]ModelTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ModelTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ModelDatabricks. +func (o *ModelDatabricks) SetTags(ctx context.Context, v []ModelTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ModelTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -5195,6 +6335,31 @@ func (o ModelVersion) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in ModelVersion as +// a slice of ModelVersionTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelVersion) GetTags(ctx context.Context) ([]ModelVersionTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ModelVersionTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ModelVersion. +func (o *ModelVersion) SetTags(ctx context.Context, v []ModelVersionTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ModelVersionDatabricks struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -5313,6 +6478,31 @@ func (o ModelVersionDatabricks) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in ModelVersionDatabricks as +// a slice of ModelVersionTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelVersionDatabricks) GetTags(ctx context.Context) ([]ModelVersionTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []ModelVersionTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ModelVersionDatabricks. +func (o *ModelVersionDatabricks) SetTags(ctx context.Context, v []ModelVersionTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ModelVersionTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -5521,6 +6711,31 @@ func (o RegisteredModelAccessControlResponse) Type(ctx context.Context) attr.Typ } } +// GetAllPermissions returns the value of the AllPermissions field in RegisteredModelAccessControlResponse as +// a slice of RegisteredModelPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *RegisteredModelAccessControlResponse) GetAllPermissions(ctx context.Context) ([]RegisteredModelPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []RegisteredModelPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in RegisteredModelAccessControlResponse. +func (o *RegisteredModelAccessControlResponse) SetAllPermissions(ctx context.Context, v []RegisteredModelPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type RegisteredModelPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -5574,6 +6789,31 @@ func (o RegisteredModelPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in RegisteredModelPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RegisteredModelPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in RegisteredModelPermission. +func (o *RegisteredModelPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type RegisteredModelPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -5627,6 +6867,31 @@ func (o RegisteredModelPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in RegisteredModelPermissions as +// a slice of RegisteredModelAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *RegisteredModelPermissions) GetAccessControlList(ctx context.Context) ([]RegisteredModelAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []RegisteredModelAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in RegisteredModelPermissions. +func (o *RegisteredModelPermissions) SetAccessControlList(ctx context.Context, v []RegisteredModelAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type RegisteredModelPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -5721,6 +6986,31 @@ func (o RegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in RegisteredModelPermissionsRequest as +// a slice of RegisteredModelAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *RegisteredModelPermissionsRequest) GetAccessControlList(ctx context.Context) ([]RegisteredModelAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []RegisteredModelAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in RegisteredModelPermissionsRequest. +func (o *RegisteredModelPermissionsRequest) SetAccessControlList(ctx context.Context, v []RegisteredModelAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type RegistryWebhook struct { // Creation time of the object, as a Unix timestamp in milliseconds. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -5844,6 +7134,83 @@ func (o RegistryWebhook) Type(ctx context.Context) attr.Type { } } +// GetEvents returns the value of the Events field in RegistryWebhook as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RegistryWebhook) GetEvents(ctx context.Context) ([]types.String, bool) { + if o.Events.IsNull() || o.Events.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Events.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEvents sets the value of the Events field in RegistryWebhook. +func (o *RegistryWebhook) SetEvents(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + o.Events = types.ListValueMust(t, vs) +} + +// GetHttpUrlSpec returns the value of the HttpUrlSpec field in RegistryWebhook as +// a HttpUrlSpecWithoutSecret value. +// If the field is unknown or null, the boolean return value is false. +func (o *RegistryWebhook) GetHttpUrlSpec(ctx context.Context) (HttpUrlSpecWithoutSecret, bool) { + var e HttpUrlSpecWithoutSecret + if o.HttpUrlSpec.IsNull() || o.HttpUrlSpec.IsUnknown() { + return e, false + } + var v []HttpUrlSpecWithoutSecret + d := o.HttpUrlSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHttpUrlSpec sets the value of the HttpUrlSpec field in RegistryWebhook. +func (o *RegistryWebhook) SetHttpUrlSpec(ctx context.Context, v HttpUrlSpecWithoutSecret) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["http_url_spec"] + o.HttpUrlSpec = types.ListValueMust(t, vs) +} + +// GetJobSpec returns the value of the JobSpec field in RegistryWebhook as +// a JobSpecWithoutSecret value. +// If the field is unknown or null, the boolean return value is false. +func (o *RegistryWebhook) GetJobSpec(ctx context.Context) (JobSpecWithoutSecret, bool) { + var e JobSpecWithoutSecret + if o.JobSpec.IsNull() || o.JobSpec.IsUnknown() { + return e, false + } + var v []JobSpecWithoutSecret + d := o.JobSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetJobSpec sets the value of the JobSpec field in RegistryWebhook. +func (o *RegistryWebhook) SetJobSpec(ctx context.Context, v JobSpecWithoutSecret) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_spec"] + o.JobSpec = types.ListValueMust(t, vs) +} + type RejectTransitionRequest struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5952,6 +7319,32 @@ func (o RejectTransitionRequestResponse) Type(ctx context.Context) attr.Type { } } +// GetActivity returns the value of the Activity field in RejectTransitionRequestResponse as +// a Activity value. +// If the field is unknown or null, the boolean return value is false. +func (o *RejectTransitionRequestResponse) GetActivity(ctx context.Context) (Activity, bool) { + var e Activity + if o.Activity.IsNull() || o.Activity.IsUnknown() { + return e, false + } + var v []Activity + d := o.Activity.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetActivity sets the value of the Activity field in RejectTransitionRequestResponse. +func (o *RejectTransitionRequestResponse) SetActivity(ctx context.Context, v Activity) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["activity"] + o.Activity = types.ListValueMust(t, vs) +} + type RenameModelRequest struct { // Registered model unique name identifier. Name types.String `tfsdk:"name" tf:""` @@ -6043,6 +7436,32 @@ func (o RenameModelResponse) Type(ctx context.Context) attr.Type { } } +// GetRegisteredModel returns the value of the RegisteredModel field in RenameModelResponse as +// a Model value. +// If the field is unknown or null, the boolean return value is false. +func (o *RenameModelResponse) GetRegisteredModel(ctx context.Context) (Model, bool) { + var e Model + if o.RegisteredModel.IsNull() || o.RegisteredModel.IsUnknown() { + return e, false + } + var v []Model + d := o.RegisteredModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRegisteredModel sets the value of the RegisteredModel field in RenameModelResponse. +func (o *RenameModelResponse) SetRegisteredModel(ctx context.Context, v Model) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_model"] + o.RegisteredModel = types.ListValueMust(t, vs) +} + type RestoreExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -6354,6 +7773,84 @@ func (o Run) Type(ctx context.Context) attr.Type { } } +// GetData returns the value of the Data field in Run as +// a RunData value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetData(ctx context.Context) (RunData, bool) { + var e RunData + if o.Data.IsNull() || o.Data.IsUnknown() { + return e, false + } + var v []RunData + d := o.Data.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetData sets the value of the Data field in Run. +func (o *Run) SetData(ctx context.Context, v RunData) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + o.Data = types.ListValueMust(t, vs) +} + +// GetInfo returns the value of the Info field in Run as +// a RunInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetInfo(ctx context.Context) (RunInfo, bool) { + var e RunInfo + if o.Info.IsNull() || o.Info.IsUnknown() { + return e, false + } + var v []RunInfo + d := o.Info.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInfo sets the value of the Info field in Run. +func (o *Run) SetInfo(ctx context.Context, v RunInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["info"] + o.Info = types.ListValueMust(t, vs) +} + +// GetInputs returns the value of the Inputs field in Run as +// a RunInputs value. +// If the field is unknown or null, the boolean return value is false. +func (o *Run) GetInputs(ctx context.Context) (RunInputs, bool) { + var e RunInputs + if o.Inputs.IsNull() || o.Inputs.IsUnknown() { + return e, false + } + var v []RunInputs + d := o.Inputs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInputs sets the value of the Inputs field in Run. +func (o *Run) SetInputs(ctx context.Context, v RunInputs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inputs"] + o.Inputs = types.ListValueMust(t, vs) +} + type RunData struct { // Run metrics. Metrics types.List `tfsdk:"metrics" tf:"optional"` @@ -6414,6 +7911,81 @@ func (o RunData) Type(ctx context.Context) attr.Type { } } +// GetMetrics returns the value of the Metrics field in RunData as +// a slice of Metric values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunData) GetMetrics(ctx context.Context) ([]Metric, bool) { + if o.Metrics.IsNull() || o.Metrics.IsUnknown() { + return nil, false + } + var v []Metric + d := o.Metrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMetrics sets the value of the Metrics field in RunData. +func (o *RunData) SetMetrics(ctx context.Context, v []Metric) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + o.Metrics = types.ListValueMust(t, vs) +} + +// GetParams returns the value of the Params field in RunData as +// a slice of Param values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunData) GetParams(ctx context.Context) ([]Param, bool) { + if o.Params.IsNull() || o.Params.IsUnknown() { + return nil, false + } + var v []Param + d := o.Params.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParams sets the value of the Params field in RunData. +func (o *RunData) SetParams(ctx context.Context, v []Param) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["params"] + o.Params = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in RunData as +// a slice of RunTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunData) GetTags(ctx context.Context) ([]RunTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []RunTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in RunData. +func (o *RunData) SetTags(ctx context.Context, v []RunTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type RunInfo struct { // URI of the directory where artifacts should be uploaded. This can be a // local path (starting with "/"), or a distributed file system (DFS) path, @@ -6540,6 +8112,31 @@ func (o RunInputs) Type(ctx context.Context) attr.Type { } } +// GetDatasetInputs returns the value of the DatasetInputs field in RunInputs as +// a slice of DatasetInput values. +// If the field is unknown or null, the boolean return value is false. +func (o *RunInputs) GetDatasetInputs(ctx context.Context) ([]DatasetInput, bool) { + if o.DatasetInputs.IsNull() || o.DatasetInputs.IsUnknown() { + return nil, false + } + var v []DatasetInput + d := o.DatasetInputs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDatasetInputs sets the value of the DatasetInputs field in RunInputs. +func (o *RunInputs) SetDatasetInputs(ctx context.Context, v []DatasetInput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataset_inputs"] + o.DatasetInputs = types.ListValueMust(t, vs) +} + type RunTag struct { // The tag key. Key types.String `tfsdk:"key" tf:"optional"` @@ -6653,6 +8250,31 @@ func (o SearchExperiments) Type(ctx context.Context) attr.Type { } } +// GetOrderBy returns the value of the OrderBy field in SearchExperiments as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchExperiments) GetOrderBy(ctx context.Context) ([]types.String, bool) { + if o.OrderBy.IsNull() || o.OrderBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OrderBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOrderBy sets the value of the OrderBy field in SearchExperiments. +func (o *SearchExperiments) SetOrderBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + o.OrderBy = types.ListValueMust(t, vs) +} + type SearchExperimentsResponse struct { // Experiments that match the search criteria Experiments types.List `tfsdk:"experiments" tf:"optional"` @@ -6704,6 +8326,31 @@ func (o SearchExperimentsResponse) Type(ctx context.Context) attr.Type { } } +// GetExperiments returns the value of the Experiments field in SearchExperimentsResponse as +// a slice of Experiment values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchExperimentsResponse) GetExperiments(ctx context.Context) ([]Experiment, bool) { + if o.Experiments.IsNull() || o.Experiments.IsUnknown() { + return nil, false + } + var v []Experiment + d := o.Experiments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExperiments sets the value of the Experiments field in SearchExperimentsResponse. +func (o *SearchExperimentsResponse) SetExperiments(ctx context.Context, v []Experiment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiments"] + o.Experiments = types.ListValueMust(t, vs) +} + // Searches model versions type SearchModelVersionsRequest struct { // String filter condition, like "name='my-model-name'". Must be a single @@ -6767,6 +8414,31 @@ func (o SearchModelVersionsRequest) Type(ctx context.Context) attr.Type { } } +// GetOrderBy returns the value of the OrderBy field in SearchModelVersionsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchModelVersionsRequest) GetOrderBy(ctx context.Context) ([]types.String, bool) { + if o.OrderBy.IsNull() || o.OrderBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OrderBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOrderBy sets the value of the OrderBy field in SearchModelVersionsRequest. +func (o *SearchModelVersionsRequest) SetOrderBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + o.OrderBy = types.ListValueMust(t, vs) +} + type SearchModelVersionsResponse struct { // Models that match the search criteria ModelVersions types.List `tfsdk:"model_versions" tf:"optional"` @@ -6818,6 +8490,31 @@ func (o SearchModelVersionsResponse) Type(ctx context.Context) attr.Type { } } +// GetModelVersions returns the value of the ModelVersions field in SearchModelVersionsResponse as +// a slice of ModelVersion values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchModelVersionsResponse) GetModelVersions(ctx context.Context) ([]ModelVersion, bool) { + if o.ModelVersions.IsNull() || o.ModelVersions.IsUnknown() { + return nil, false + } + var v []ModelVersion + d := o.ModelVersions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetModelVersions sets the value of the ModelVersions field in SearchModelVersionsResponse. +func (o *SearchModelVersionsResponse) SetModelVersions(ctx context.Context, v []ModelVersion) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_versions"] + o.ModelVersions = types.ListValueMust(t, vs) +} + // Search models type SearchModelsRequest struct { // String filter condition, like "name LIKE 'my-model-name'". Interpreted in @@ -6881,6 +8578,31 @@ func (o SearchModelsRequest) Type(ctx context.Context) attr.Type { } } +// GetOrderBy returns the value of the OrderBy field in SearchModelsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchModelsRequest) GetOrderBy(ctx context.Context) ([]types.String, bool) { + if o.OrderBy.IsNull() || o.OrderBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OrderBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOrderBy sets the value of the OrderBy field in SearchModelsRequest. +func (o *SearchModelsRequest) SetOrderBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + o.OrderBy = types.ListValueMust(t, vs) +} + type SearchModelsResponse struct { // Pagination token to request the next page of models. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -6931,6 +8653,31 @@ func (o SearchModelsResponse) Type(ctx context.Context) attr.Type { } } +// GetRegisteredModels returns the value of the RegisteredModels field in SearchModelsResponse as +// a slice of Model values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchModelsResponse) GetRegisteredModels(ctx context.Context) ([]Model, bool) { + if o.RegisteredModels.IsNull() || o.RegisteredModels.IsUnknown() { + return nil, false + } + var v []Model + d := o.RegisteredModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRegisteredModels sets the value of the RegisteredModels field in SearchModelsResponse. +func (o *SearchModelsResponse) SetRegisteredModels(ctx context.Context, v []Model) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_models"] + o.RegisteredModels = types.ListValueMust(t, vs) +} + type SearchRuns struct { // List of experiment IDs to search over. ExperimentIds types.List `tfsdk:"experiment_ids" tf:"optional"` @@ -7017,6 +8764,56 @@ func (o SearchRuns) Type(ctx context.Context) attr.Type { } } +// GetExperimentIds returns the value of the ExperimentIds field in SearchRuns as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchRuns) GetExperimentIds(ctx context.Context) ([]types.String, bool) { + if o.ExperimentIds.IsNull() || o.ExperimentIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ExperimentIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExperimentIds sets the value of the ExperimentIds field in SearchRuns. +func (o *SearchRuns) SetExperimentIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiment_ids"] + o.ExperimentIds = types.ListValueMust(t, vs) +} + +// GetOrderBy returns the value of the OrderBy field in SearchRuns as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchRuns) GetOrderBy(ctx context.Context) ([]types.String, bool) { + if o.OrderBy.IsNull() || o.OrderBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OrderBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOrderBy sets the value of the OrderBy field in SearchRuns. +func (o *SearchRuns) SetOrderBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + o.OrderBy = types.ListValueMust(t, vs) +} + type SearchRunsResponse struct { // Token for the next page of runs. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -7067,6 +8864,31 @@ func (o SearchRunsResponse) Type(ctx context.Context) attr.Type { } } +// GetRuns returns the value of the Runs field in SearchRunsResponse as +// a slice of Run values. +// If the field is unknown or null, the boolean return value is false. +func (o *SearchRunsResponse) GetRuns(ctx context.Context) ([]Run, bool) { + if o.Runs.IsNull() || o.Runs.IsUnknown() { + return nil, false + } + var v []Run + d := o.Runs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRuns sets the value of the Runs field in SearchRunsResponse. +func (o *SearchRunsResponse) SetRuns(ctx context.Context, v []Run) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["runs"] + o.Runs = types.ListValueMust(t, vs) +} + type SetExperimentTag struct { // ID of the experiment under which to log the tag. Must be provided. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -7577,6 +9399,32 @@ func (o TestRegistryWebhookResponse) Type(ctx context.Context) attr.Type { } } +// GetWebhook returns the value of the Webhook field in TestRegistryWebhookResponse as +// a TestRegistryWebhook value. +// If the field is unknown or null, the boolean return value is false. +func (o *TestRegistryWebhookResponse) GetWebhook(ctx context.Context) (TestRegistryWebhook, bool) { + var e TestRegistryWebhook + if o.Webhook.IsNull() || o.Webhook.IsUnknown() { + return e, false + } + var v []TestRegistryWebhook + d := o.Webhook.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWebhook sets the value of the Webhook field in TestRegistryWebhookResponse. +func (o *TestRegistryWebhookResponse) SetWebhook(ctx context.Context, v TestRegistryWebhook) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhook"] + o.Webhook = types.ListValueMust(t, vs) +} + type TransitionModelVersionStageDatabricks struct { // Specifies whether to archive all current model versions in the target // stage. @@ -7716,6 +9564,31 @@ func (o TransitionRequest) Type(ctx context.Context) attr.Type { } } +// GetAvailableActions returns the value of the AvailableActions field in TransitionRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TransitionRequest) GetAvailableActions(ctx context.Context) ([]types.String, bool) { + if o.AvailableActions.IsNull() || o.AvailableActions.IsUnknown() { + return nil, false + } + var v []types.String + d := o.AvailableActions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAvailableActions sets the value of the AvailableActions field in TransitionRequest. +func (o *TransitionRequest) SetAvailableActions(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["available_actions"] + o.AvailableActions = types.ListValueMust(t, vs) +} + type TransitionStageResponse struct { ModelVersion types.List `tfsdk:"model_version" tf:"optional,object"` } @@ -7761,6 +9634,32 @@ func (o TransitionStageResponse) Type(ctx context.Context) attr.Type { } } +// GetModelVersion returns the value of the ModelVersion field in TransitionStageResponse as +// a ModelVersionDatabricks value. +// If the field is unknown or null, the boolean return value is false. +func (o *TransitionStageResponse) GetModelVersion(ctx context.Context) (ModelVersionDatabricks, bool) { + var e ModelVersionDatabricks + if o.ModelVersion.IsNull() || o.ModelVersion.IsUnknown() { + return e, false + } + var v []ModelVersionDatabricks + d := o.ModelVersion.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetModelVersion sets the value of the ModelVersion field in TransitionStageResponse. +func (o *TransitionStageResponse) SetModelVersion(ctx context.Context, v ModelVersionDatabricks) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_version"] + o.ModelVersion = types.ListValueMust(t, vs) +} + type UpdateComment struct { // User-provided comment on the action. Comment types.String `tfsdk:"comment" tf:""` @@ -7853,6 +9752,32 @@ func (o UpdateCommentResponse) Type(ctx context.Context) attr.Type { } } +// GetComment returns the value of the Comment field in UpdateCommentResponse as +// a CommentObject value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCommentResponse) GetComment(ctx context.Context) (CommentObject, bool) { + var e CommentObject + if o.Comment.IsNull() || o.Comment.IsUnknown() { + return e, false + } + var v []CommentObject + d := o.Comment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetComment sets the value of the Comment field in UpdateCommentResponse. +func (o *UpdateCommentResponse) SetComment(ctx context.Context, v CommentObject) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["comment"] + o.Comment = types.ListValueMust(t, vs) +} + type UpdateExperiment struct { // ID of the associated experiment. ExperimentId types.String `tfsdk:"experiment_id" tf:""` @@ -8215,6 +10140,83 @@ func (o UpdateRegistryWebhook) Type(ctx context.Context) attr.Type { } } +// GetEvents returns the value of the Events field in UpdateRegistryWebhook as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRegistryWebhook) GetEvents(ctx context.Context) ([]types.String, bool) { + if o.Events.IsNull() || o.Events.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Events.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEvents sets the value of the Events field in UpdateRegistryWebhook. +func (o *UpdateRegistryWebhook) SetEvents(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + o.Events = types.ListValueMust(t, vs) +} + +// GetHttpUrlSpec returns the value of the HttpUrlSpec field in UpdateRegistryWebhook as +// a HttpUrlSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRegistryWebhook) GetHttpUrlSpec(ctx context.Context) (HttpUrlSpec, bool) { + var e HttpUrlSpec + if o.HttpUrlSpec.IsNull() || o.HttpUrlSpec.IsUnknown() { + return e, false + } + var v []HttpUrlSpec + d := o.HttpUrlSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHttpUrlSpec sets the value of the HttpUrlSpec field in UpdateRegistryWebhook. +func (o *UpdateRegistryWebhook) SetHttpUrlSpec(ctx context.Context, v HttpUrlSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["http_url_spec"] + o.HttpUrlSpec = types.ListValueMust(t, vs) +} + +// GetJobSpec returns the value of the JobSpec field in UpdateRegistryWebhook as +// a JobSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRegistryWebhook) GetJobSpec(ctx context.Context) (JobSpec, bool) { + var e JobSpec + if o.JobSpec.IsNull() || o.JobSpec.IsUnknown() { + return e, false + } + var v []JobSpec + d := o.JobSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetJobSpec sets the value of the JobSpec field in UpdateRegistryWebhook. +func (o *UpdateRegistryWebhook) SetJobSpec(ctx context.Context, v JobSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_spec"] + o.JobSpec = types.ListValueMust(t, vs) +} + type UpdateRun struct { // Unix timestamp in milliseconds of when the run ended. EndTime types.Int64 `tfsdk:"end_time" tf:"optional"` @@ -8316,6 +10318,32 @@ func (o UpdateRunResponse) Type(ctx context.Context) attr.Type { } } +// GetRunInfo returns the value of the RunInfo field in UpdateRunResponse as +// a RunInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRunResponse) GetRunInfo(ctx context.Context) (RunInfo, bool) { + var e RunInfo + if o.RunInfo.IsNull() || o.RunInfo.IsUnknown() { + return e, false + } + var v []RunInfo + d := o.RunInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRunInfo sets the value of the RunInfo field in UpdateRunResponse. +func (o *UpdateRunResponse) SetRunInfo(ctx context.Context, v RunInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["run_info"] + o.RunInfo = types.ListValueMust(t, vs) +} + type UpdateWebhookResponse struct { } @@ -8351,76 +10379,3 @@ func (o UpdateWebhookResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{}, } } - -// An action that a user (with sufficient permissions) could take on an -// activity. Valid values are: * `APPROVE_TRANSITION_REQUEST`: Approve a -// transition request -// -// * `REJECT_TRANSITION_REQUEST`: Reject a transition request -// -// * `CANCEL_TRANSITION_REQUEST`: Cancel (delete) a transition request - -// Type of activity. Valid values are: * `APPLIED_TRANSITION`: User applied the -// corresponding stage transition. -// -// * `REQUESTED_TRANSITION`: User requested the corresponding stage transition. -// -// * `CANCELLED_REQUEST`: User cancelled an existing transition request. -// -// * `APPROVED_REQUEST`: User approved the corresponding stage transition. -// -// * `REJECTED_REQUEST`: User rejected the coressponding stage transition. -// -// * `SYSTEM_TRANSITION`: For events performed as a side effect, such as -// archiving existing model versions in a stage. - -// An action that a user (with sufficient permissions) could take on a comment. -// Valid values are: * `EDIT_COMMENT`: Edit the comment -// -// * `DELETE_COMMENT`: Delete the comment - -// Permission level - -// Current status of `model_version` - -// Permission level of the requesting user on the object. For what is allowed at -// each level, see [MLflow Model permissions](..). - -// Permission level - -// Enable or disable triggering the webhook, or put the webhook into test mode. -// The default is `ACTIVE`: * `ACTIVE`: Webhook is triggered when an associated -// event happens. -// -// * `DISABLED`: Webhook is not triggered. -// -// * `TEST_MODE`: Webhook can be triggered through the test endpoint, but is not -// triggered on a real event. - -// Current status of the run. - -// Qualifier for type of experiments to be returned. If unspecified, return only -// active experiments. - -// Whether to display only active, only deleted, or all runs. Defaults to only -// active runs. - -// Stage of the model version. Valid values are: -// -// * `None`: The initial stage of a model version. -// -// * `Staging`: Staging or pre-production stage. -// -// * `Production`: Production stage. -// -// * `Archived`: Archived stage. - -// The status of the model version. Valid values are: * `PENDING_REGISTRATION`: -// Request to register a new model version is pending as server performs -// background tasks. -// -// * `FAILED_REGISTRATION`: Request to register a new model version has failed. -// -// * `READY`: Model version is ready for use. - -// Updated status of the run. diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 975ac569c4..ad0d1d0572 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -89,6 +90,82 @@ func (o CreateCustomAppIntegration) Type(ctx context.Context) attr.Type { } } +// GetRedirectUrls returns the value of the RedirectUrls field in CreateCustomAppIntegration as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCustomAppIntegration) GetRedirectUrls(ctx context.Context) ([]types.String, bool) { + if o.RedirectUrls.IsNull() || o.RedirectUrls.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RedirectUrls.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRedirectUrls sets the value of the RedirectUrls field in CreateCustomAppIntegration. +func (o *CreateCustomAppIntegration) SetRedirectUrls(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + o.RedirectUrls = types.ListValueMust(t, vs) +} + +// GetScopes returns the value of the Scopes field in CreateCustomAppIntegration as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCustomAppIntegration) GetScopes(ctx context.Context) ([]types.String, bool) { + if o.Scopes.IsNull() || o.Scopes.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Scopes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScopes sets the value of the Scopes field in CreateCustomAppIntegration. +func (o *CreateCustomAppIntegration) SetScopes(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + o.Scopes = types.ListValueMust(t, vs) +} + +// GetTokenAccessPolicy returns the value of the TokenAccessPolicy field in CreateCustomAppIntegration as +// a TokenAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCustomAppIntegration) GetTokenAccessPolicy(ctx context.Context) (TokenAccessPolicy, bool) { + var e TokenAccessPolicy + if o.TokenAccessPolicy.IsNull() || o.TokenAccessPolicy.IsUnknown() { + return e, false + } + var v []TokenAccessPolicy + d := o.TokenAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenAccessPolicy sets the value of the TokenAccessPolicy field in CreateCustomAppIntegration. +func (o *CreateCustomAppIntegration) SetTokenAccessPolicy(ctx context.Context, v TokenAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_access_policy"] + o.TokenAccessPolicy = types.ListValueMust(t, vs) +} + type CreateCustomAppIntegrationOutput struct { // OAuth client-id generated by the Databricks ClientId types.String `tfsdk:"client_id" tf:"optional"` @@ -191,6 +268,32 @@ func (o CreatePublishedAppIntegration) Type(ctx context.Context) attr.Type { } } +// GetTokenAccessPolicy returns the value of the TokenAccessPolicy field in CreatePublishedAppIntegration as +// a TokenAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePublishedAppIntegration) GetTokenAccessPolicy(ctx context.Context) (TokenAccessPolicy, bool) { + var e TokenAccessPolicy + if o.TokenAccessPolicy.IsNull() || o.TokenAccessPolicy.IsUnknown() { + return e, false + } + var v []TokenAccessPolicy + d := o.TokenAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenAccessPolicy sets the value of the TokenAccessPolicy field in CreatePublishedAppIntegration. +func (o *CreatePublishedAppIntegration) SetTokenAccessPolicy(ctx context.Context, v TokenAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_access_policy"] + o.TokenAccessPolicy = types.ListValueMust(t, vs) +} + type CreatePublishedAppIntegrationOutput struct { // Unique integration id for the published OAuth app IntegrationId types.String `tfsdk:"integration_id" tf:"optional"` @@ -712,6 +815,82 @@ func (o GetCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { } } +// GetRedirectUrls returns the value of the RedirectUrls field in GetCustomAppIntegrationOutput as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetCustomAppIntegrationOutput) GetRedirectUrls(ctx context.Context) ([]types.String, bool) { + if o.RedirectUrls.IsNull() || o.RedirectUrls.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RedirectUrls.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRedirectUrls sets the value of the RedirectUrls field in GetCustomAppIntegrationOutput. +func (o *GetCustomAppIntegrationOutput) SetRedirectUrls(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + o.RedirectUrls = types.ListValueMust(t, vs) +} + +// GetScopes returns the value of the Scopes field in GetCustomAppIntegrationOutput as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetCustomAppIntegrationOutput) GetScopes(ctx context.Context) ([]types.String, bool) { + if o.Scopes.IsNull() || o.Scopes.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Scopes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScopes sets the value of the Scopes field in GetCustomAppIntegrationOutput. +func (o *GetCustomAppIntegrationOutput) SetScopes(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + o.Scopes = types.ListValueMust(t, vs) +} + +// GetTokenAccessPolicy returns the value of the TokenAccessPolicy field in GetCustomAppIntegrationOutput as +// a TokenAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetCustomAppIntegrationOutput) GetTokenAccessPolicy(ctx context.Context) (TokenAccessPolicy, bool) { + var e TokenAccessPolicy + if o.TokenAccessPolicy.IsNull() || o.TokenAccessPolicy.IsUnknown() { + return e, false + } + var v []TokenAccessPolicy + d := o.TokenAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenAccessPolicy sets the value of the TokenAccessPolicy field in GetCustomAppIntegrationOutput. +func (o *GetCustomAppIntegrationOutput) SetTokenAccessPolicy(ctx context.Context, v TokenAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_access_policy"] + o.TokenAccessPolicy = types.ListValueMust(t, vs) +} + // Get OAuth Custom App Integration type GetCustomAppIntegrationRequest struct { // The OAuth app integration ID. @@ -805,6 +984,31 @@ func (o GetCustomAppIntegrationsOutput) Type(ctx context.Context) attr.Type { } } +// GetApps returns the value of the Apps field in GetCustomAppIntegrationsOutput as +// a slice of GetCustomAppIntegrationOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetCustomAppIntegrationsOutput) GetApps(ctx context.Context) ([]GetCustomAppIntegrationOutput, bool) { + if o.Apps.IsNull() || o.Apps.IsUnknown() { + return nil, false + } + var v []GetCustomAppIntegrationOutput + d := o.Apps.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetApps sets the value of the Apps field in GetCustomAppIntegrationsOutput. +func (o *GetCustomAppIntegrationsOutput) SetApps(ctx context.Context, v []GetCustomAppIntegrationOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + o.Apps = types.ListValueMust(t, vs) +} + type GetPublishedAppIntegrationOutput struct { // App-id of the published app integration AppId types.String `tfsdk:"app_id" tf:"optional"` @@ -871,6 +1075,32 @@ func (o GetPublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { } } +// GetTokenAccessPolicy returns the value of the TokenAccessPolicy field in GetPublishedAppIntegrationOutput as +// a TokenAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPublishedAppIntegrationOutput) GetTokenAccessPolicy(ctx context.Context) (TokenAccessPolicy, bool) { + var e TokenAccessPolicy + if o.TokenAccessPolicy.IsNull() || o.TokenAccessPolicy.IsUnknown() { + return e, false + } + var v []TokenAccessPolicy + d := o.TokenAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenAccessPolicy sets the value of the TokenAccessPolicy field in GetPublishedAppIntegrationOutput. +func (o *GetPublishedAppIntegrationOutput) SetTokenAccessPolicy(ctx context.Context, v TokenAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_access_policy"] + o.TokenAccessPolicy = types.ListValueMust(t, vs) +} + // Get OAuth Published App Integration type GetPublishedAppIntegrationRequest struct { IntegrationId types.String `tfsdk:"-"` @@ -963,6 +1193,31 @@ func (o GetPublishedAppIntegrationsOutput) Type(ctx context.Context) attr.Type { } } +// GetApps returns the value of the Apps field in GetPublishedAppIntegrationsOutput as +// a slice of GetPublishedAppIntegrationOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPublishedAppIntegrationsOutput) GetApps(ctx context.Context) ([]GetPublishedAppIntegrationOutput, bool) { + if o.Apps.IsNull() || o.Apps.IsUnknown() { + return nil, false + } + var v []GetPublishedAppIntegrationOutput + d := o.Apps.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetApps sets the value of the Apps field in GetPublishedAppIntegrationsOutput. +func (o *GetPublishedAppIntegrationsOutput) SetApps(ctx context.Context, v []GetPublishedAppIntegrationOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + o.Apps = types.ListValueMust(t, vs) +} + type GetPublishedAppsOutput struct { // List of Published OAuth Apps. Apps types.List `tfsdk:"apps" tf:"optional"` @@ -1014,6 +1269,31 @@ func (o GetPublishedAppsOutput) Type(ctx context.Context) attr.Type { } } +// GetApps returns the value of the Apps field in GetPublishedAppsOutput as +// a slice of PublishedAppOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPublishedAppsOutput) GetApps(ctx context.Context) ([]PublishedAppOutput, bool) { + if o.Apps.IsNull() || o.Apps.IsUnknown() { + return nil, false + } + var v []PublishedAppOutput + d := o.Apps.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetApps sets the value of the Apps field in GetPublishedAppsOutput. +func (o *GetPublishedAppsOutput) SetApps(ctx context.Context, v []PublishedAppOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + o.Apps = types.ListValueMust(t, vs) +} + // Get custom oauth app integrations type ListCustomAppIntegrationsRequest struct { IncludeCreatorUsername types.Bool `tfsdk:"-"` @@ -1262,6 +1542,31 @@ func (o ListServicePrincipalSecretsResponse) Type(ctx context.Context) attr.Type } } +// GetSecrets returns the value of the Secrets field in ListServicePrincipalSecretsResponse as +// a slice of SecretInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListServicePrincipalSecretsResponse) GetSecrets(ctx context.Context) ([]SecretInfo, bool) { + if o.Secrets.IsNull() || o.Secrets.IsUnknown() { + return nil, false + } + var v []SecretInfo + d := o.Secrets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSecrets sets the value of the Secrets field in ListServicePrincipalSecretsResponse. +func (o *ListServicePrincipalSecretsResponse) SetSecrets(ctx context.Context, v []SecretInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["secrets"] + o.Secrets = types.ListValueMust(t, vs) +} + type PublishedAppOutput struct { // Unique ID of the published OAuth app. AppId types.String `tfsdk:"app_id" tf:"optional"` @@ -1337,6 +1642,56 @@ func (o PublishedAppOutput) Type(ctx context.Context) attr.Type { } } +// GetRedirectUrls returns the value of the RedirectUrls field in PublishedAppOutput as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PublishedAppOutput) GetRedirectUrls(ctx context.Context) ([]types.String, bool) { + if o.RedirectUrls.IsNull() || o.RedirectUrls.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RedirectUrls.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRedirectUrls sets the value of the RedirectUrls field in PublishedAppOutput. +func (o *PublishedAppOutput) SetRedirectUrls(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + o.RedirectUrls = types.ListValueMust(t, vs) +} + +// GetScopes returns the value of the Scopes field in PublishedAppOutput as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PublishedAppOutput) GetScopes(ctx context.Context) ([]types.String, bool) { + if o.Scopes.IsNull() || o.Scopes.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Scopes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScopes sets the value of the Scopes field in PublishedAppOutput. +func (o *PublishedAppOutput) SetScopes(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + o.Scopes = types.ListValueMust(t, vs) +} + type SecretInfo struct { // UTC time when the secret was created CreateTime types.String `tfsdk:"create_time" tf:"optional"` @@ -1498,6 +1853,57 @@ func (o UpdateCustomAppIntegration) Type(ctx context.Context) attr.Type { } } +// GetRedirectUrls returns the value of the RedirectUrls field in UpdateCustomAppIntegration as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCustomAppIntegration) GetRedirectUrls(ctx context.Context) ([]types.String, bool) { + if o.RedirectUrls.IsNull() || o.RedirectUrls.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RedirectUrls.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRedirectUrls sets the value of the RedirectUrls field in UpdateCustomAppIntegration. +func (o *UpdateCustomAppIntegration) SetRedirectUrls(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + o.RedirectUrls = types.ListValueMust(t, vs) +} + +// GetTokenAccessPolicy returns the value of the TokenAccessPolicy field in UpdateCustomAppIntegration as +// a TokenAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCustomAppIntegration) GetTokenAccessPolicy(ctx context.Context) (TokenAccessPolicy, bool) { + var e TokenAccessPolicy + if o.TokenAccessPolicy.IsNull() || o.TokenAccessPolicy.IsUnknown() { + return e, false + } + var v []TokenAccessPolicy + d := o.TokenAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenAccessPolicy sets the value of the TokenAccessPolicy field in UpdateCustomAppIntegration. +func (o *UpdateCustomAppIntegration) SetTokenAccessPolicy(ctx context.Context, v TokenAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_access_policy"] + o.TokenAccessPolicy = types.ListValueMust(t, vs) +} + type UpdateCustomAppIntegrationOutput struct { } @@ -1583,6 +1989,32 @@ func (o UpdatePublishedAppIntegration) Type(ctx context.Context) attr.Type { } } +// GetTokenAccessPolicy returns the value of the TokenAccessPolicy field in UpdatePublishedAppIntegration as +// a TokenAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdatePublishedAppIntegration) GetTokenAccessPolicy(ctx context.Context) (TokenAccessPolicy, bool) { + var e TokenAccessPolicy + if o.TokenAccessPolicy.IsNull() || o.TokenAccessPolicy.IsUnknown() { + return e, false + } + var v []TokenAccessPolicy + d := o.TokenAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenAccessPolicy sets the value of the TokenAccessPolicy field in UpdatePublishedAppIntegration. +func (o *UpdatePublishedAppIntegration) SetTokenAccessPolicy(ctx context.Context, v TokenAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_access_policy"] + o.TokenAccessPolicy = types.ListValueMust(t, vs) +} + type UpdatePublishedAppIntegrationOutput struct { } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index e3a8228837..5f423bd51a 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -14,7 +14,7 @@ import ( "context" "reflect" - "github.com/databricks/databricks-sdk-go/service/compute" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/compute_tf" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" @@ -200,6 +200,262 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { } } +// GetClusters returns the value of the Clusters field in CreatePipeline as +// a slice of PipelineCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetClusters(ctx context.Context) ([]PipelineCluster, bool) { + if o.Clusters.IsNull() || o.Clusters.IsUnknown() { + return nil, false + } + var v []PipelineCluster + d := o.Clusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusters sets the value of the Clusters field in CreatePipeline. +func (o *CreatePipeline) SetClusters(ctx context.Context, v []PipelineCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + o.Clusters = types.ListValueMust(t, vs) +} + +// GetConfiguration returns the value of the Configuration field in CreatePipeline as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetConfiguration(ctx context.Context) (map[string]types.String, bool) { + if o.Configuration.IsNull() || o.Configuration.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Configuration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetConfiguration sets the value of the Configuration field in CreatePipeline. +func (o *CreatePipeline) SetConfiguration(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration"] + o.Configuration = types.MapValueMust(t, vs) +} + +// GetDeployment returns the value of the Deployment field in CreatePipeline as +// a PipelineDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetDeployment(ctx context.Context) (PipelineDeployment, bool) { + var e PipelineDeployment + if o.Deployment.IsNull() || o.Deployment.IsUnknown() { + return e, false + } + var v []PipelineDeployment + d := o.Deployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeployment sets the value of the Deployment field in CreatePipeline. +func (o *CreatePipeline) SetDeployment(ctx context.Context, v PipelineDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment"] + o.Deployment = types.ListValueMust(t, vs) +} + +// GetFilters returns the value of the Filters field in CreatePipeline as +// a Filters value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetFilters(ctx context.Context) (Filters, bool) { + var e Filters + if o.Filters.IsNull() || o.Filters.IsUnknown() { + return e, false + } + var v []Filters + d := o.Filters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilters sets the value of the Filters field in CreatePipeline. +func (o *CreatePipeline) SetFilters(ctx context.Context, v Filters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + o.Filters = types.ListValueMust(t, vs) +} + +// GetGatewayDefinition returns the value of the GatewayDefinition field in CreatePipeline as +// a IngestionGatewayPipelineDefinition value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetGatewayDefinition(ctx context.Context) (IngestionGatewayPipelineDefinition, bool) { + var e IngestionGatewayPipelineDefinition + if o.GatewayDefinition.IsNull() || o.GatewayDefinition.IsUnknown() { + return e, false + } + var v []IngestionGatewayPipelineDefinition + d := o.GatewayDefinition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGatewayDefinition sets the value of the GatewayDefinition field in CreatePipeline. +func (o *CreatePipeline) SetGatewayDefinition(ctx context.Context, v IngestionGatewayPipelineDefinition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gateway_definition"] + o.GatewayDefinition = types.ListValueMust(t, vs) +} + +// GetIngestionDefinition returns the value of the IngestionDefinition field in CreatePipeline as +// a IngestionPipelineDefinition value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetIngestionDefinition(ctx context.Context) (IngestionPipelineDefinition, bool) { + var e IngestionPipelineDefinition + if o.IngestionDefinition.IsNull() || o.IngestionDefinition.IsUnknown() { + return e, false + } + var v []IngestionPipelineDefinition + d := o.IngestionDefinition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIngestionDefinition sets the value of the IngestionDefinition field in CreatePipeline. +func (o *CreatePipeline) SetIngestionDefinition(ctx context.Context, v IngestionPipelineDefinition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ingestion_definition"] + o.IngestionDefinition = types.ListValueMust(t, vs) +} + +// GetLibraries returns the value of the Libraries field in CreatePipeline as +// a slice of PipelineLibrary values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetLibraries(ctx context.Context) ([]PipelineLibrary, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []PipelineLibrary + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in CreatePipeline. +func (o *CreatePipeline) SetLibraries(ctx context.Context, v []PipelineLibrary) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNotifications returns the value of the Notifications field in CreatePipeline as +// a slice of Notifications values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetNotifications(ctx context.Context) ([]Notifications, bool) { + if o.Notifications.IsNull() || o.Notifications.IsUnknown() { + return nil, false + } + var v []Notifications + d := o.Notifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotifications sets the value of the Notifications field in CreatePipeline. +func (o *CreatePipeline) SetNotifications(ctx context.Context, v []Notifications) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + o.Notifications = types.ListValueMust(t, vs) +} + +// GetRestartWindow returns the value of the RestartWindow field in CreatePipeline as +// a RestartWindow value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetRestartWindow(ctx context.Context) (RestartWindow, bool) { + var e RestartWindow + if o.RestartWindow.IsNull() || o.RestartWindow.IsUnknown() { + return e, false + } + var v []RestartWindow + d := o.RestartWindow.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRestartWindow sets the value of the RestartWindow field in CreatePipeline. +func (o *CreatePipeline) SetRestartWindow(ctx context.Context, v RestartWindow) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["restart_window"] + o.RestartWindow = types.ListValueMust(t, vs) +} + +// GetTrigger returns the value of the Trigger field in CreatePipeline as +// a PipelineTrigger value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipeline) GetTrigger(ctx context.Context) (PipelineTrigger, bool) { + var e PipelineTrigger + if o.Trigger.IsNull() || o.Trigger.IsUnknown() { + return e, false + } + var v []PipelineTrigger + d := o.Trigger.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrigger sets the value of the Trigger field in CreatePipeline. +func (o *CreatePipeline) SetTrigger(ctx context.Context, v PipelineTrigger) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger"] + o.Trigger = types.ListValueMust(t, vs) +} + type CreatePipelineResponse struct { // Only returned when dry_run is true. EffectiveSettings types.List `tfsdk:"effective_settings" tf:"optional,object"` @@ -251,6 +507,32 @@ func (o CreatePipelineResponse) Type(ctx context.Context) attr.Type { } } +// GetEffectiveSettings returns the value of the EffectiveSettings field in CreatePipelineResponse as +// a PipelineSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreatePipelineResponse) GetEffectiveSettings(ctx context.Context) (PipelineSpec, bool) { + var e PipelineSpec + if o.EffectiveSettings.IsNull() || o.EffectiveSettings.IsUnknown() { + return e, false + } + var v []PipelineSpec + d := o.EffectiveSettings.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEffectiveSettings sets the value of the EffectiveSettings field in CreatePipelineResponse. +func (o *CreatePipelineResponse) SetEffectiveSettings(ctx context.Context, v PipelineSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["effective_settings"] + o.EffectiveSettings = types.ListValueMust(t, vs) +} + type CronTrigger struct { QuartzCronSchedule types.String `tfsdk:"quartz_cron_schedule" tf:"optional"` @@ -605,6 +887,262 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { } } +// GetClusters returns the value of the Clusters field in EditPipeline as +// a slice of PipelineCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetClusters(ctx context.Context) ([]PipelineCluster, bool) { + if o.Clusters.IsNull() || o.Clusters.IsUnknown() { + return nil, false + } + var v []PipelineCluster + d := o.Clusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusters sets the value of the Clusters field in EditPipeline. +func (o *EditPipeline) SetClusters(ctx context.Context, v []PipelineCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + o.Clusters = types.ListValueMust(t, vs) +} + +// GetConfiguration returns the value of the Configuration field in EditPipeline as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetConfiguration(ctx context.Context) (map[string]types.String, bool) { + if o.Configuration.IsNull() || o.Configuration.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Configuration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetConfiguration sets the value of the Configuration field in EditPipeline. +func (o *EditPipeline) SetConfiguration(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration"] + o.Configuration = types.MapValueMust(t, vs) +} + +// GetDeployment returns the value of the Deployment field in EditPipeline as +// a PipelineDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetDeployment(ctx context.Context) (PipelineDeployment, bool) { + var e PipelineDeployment + if o.Deployment.IsNull() || o.Deployment.IsUnknown() { + return e, false + } + var v []PipelineDeployment + d := o.Deployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeployment sets the value of the Deployment field in EditPipeline. +func (o *EditPipeline) SetDeployment(ctx context.Context, v PipelineDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment"] + o.Deployment = types.ListValueMust(t, vs) +} + +// GetFilters returns the value of the Filters field in EditPipeline as +// a Filters value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetFilters(ctx context.Context) (Filters, bool) { + var e Filters + if o.Filters.IsNull() || o.Filters.IsUnknown() { + return e, false + } + var v []Filters + d := o.Filters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilters sets the value of the Filters field in EditPipeline. +func (o *EditPipeline) SetFilters(ctx context.Context, v Filters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + o.Filters = types.ListValueMust(t, vs) +} + +// GetGatewayDefinition returns the value of the GatewayDefinition field in EditPipeline as +// a IngestionGatewayPipelineDefinition value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetGatewayDefinition(ctx context.Context) (IngestionGatewayPipelineDefinition, bool) { + var e IngestionGatewayPipelineDefinition + if o.GatewayDefinition.IsNull() || o.GatewayDefinition.IsUnknown() { + return e, false + } + var v []IngestionGatewayPipelineDefinition + d := o.GatewayDefinition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGatewayDefinition sets the value of the GatewayDefinition field in EditPipeline. +func (o *EditPipeline) SetGatewayDefinition(ctx context.Context, v IngestionGatewayPipelineDefinition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gateway_definition"] + o.GatewayDefinition = types.ListValueMust(t, vs) +} + +// GetIngestionDefinition returns the value of the IngestionDefinition field in EditPipeline as +// a IngestionPipelineDefinition value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetIngestionDefinition(ctx context.Context) (IngestionPipelineDefinition, bool) { + var e IngestionPipelineDefinition + if o.IngestionDefinition.IsNull() || o.IngestionDefinition.IsUnknown() { + return e, false + } + var v []IngestionPipelineDefinition + d := o.IngestionDefinition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIngestionDefinition sets the value of the IngestionDefinition field in EditPipeline. +func (o *EditPipeline) SetIngestionDefinition(ctx context.Context, v IngestionPipelineDefinition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ingestion_definition"] + o.IngestionDefinition = types.ListValueMust(t, vs) +} + +// GetLibraries returns the value of the Libraries field in EditPipeline as +// a slice of PipelineLibrary values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetLibraries(ctx context.Context) ([]PipelineLibrary, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []PipelineLibrary + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in EditPipeline. +func (o *EditPipeline) SetLibraries(ctx context.Context, v []PipelineLibrary) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNotifications returns the value of the Notifications field in EditPipeline as +// a slice of Notifications values. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetNotifications(ctx context.Context) ([]Notifications, bool) { + if o.Notifications.IsNull() || o.Notifications.IsUnknown() { + return nil, false + } + var v []Notifications + d := o.Notifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotifications sets the value of the Notifications field in EditPipeline. +func (o *EditPipeline) SetNotifications(ctx context.Context, v []Notifications) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + o.Notifications = types.ListValueMust(t, vs) +} + +// GetRestartWindow returns the value of the RestartWindow field in EditPipeline as +// a RestartWindow value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetRestartWindow(ctx context.Context) (RestartWindow, bool) { + var e RestartWindow + if o.RestartWindow.IsNull() || o.RestartWindow.IsUnknown() { + return e, false + } + var v []RestartWindow + d := o.RestartWindow.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRestartWindow sets the value of the RestartWindow field in EditPipeline. +func (o *EditPipeline) SetRestartWindow(ctx context.Context, v RestartWindow) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["restart_window"] + o.RestartWindow = types.ListValueMust(t, vs) +} + +// GetTrigger returns the value of the Trigger field in EditPipeline as +// a PipelineTrigger value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditPipeline) GetTrigger(ctx context.Context) (PipelineTrigger, bool) { + var e PipelineTrigger + if o.Trigger.IsNull() || o.Trigger.IsUnknown() { + return e, false + } + var v []PipelineTrigger + d := o.Trigger.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrigger sets the value of the Trigger field in EditPipeline. +func (o *EditPipeline) SetTrigger(ctx context.Context, v PipelineTrigger) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger"] + o.Trigger = types.ListValueMust(t, vs) +} + type EditPipelineResponse struct { } @@ -691,6 +1229,31 @@ func (o ErrorDetail) Type(ctx context.Context) attr.Type { } } +// GetExceptions returns the value of the Exceptions field in ErrorDetail as +// a slice of SerializedException values. +// If the field is unknown or null, the boolean return value is false. +func (o *ErrorDetail) GetExceptions(ctx context.Context) ([]SerializedException, bool) { + if o.Exceptions.IsNull() || o.Exceptions.IsUnknown() { + return nil, false + } + var v []SerializedException + d := o.Exceptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExceptions sets the value of the Exceptions field in ErrorDetail. +func (o *ErrorDetail) SetExceptions(ctx context.Context, v []SerializedException) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exceptions"] + o.Exceptions = types.ListValueMust(t, vs) +} + type FileLibrary struct { // The absolute path of the file. Path types.String `tfsdk:"path" tf:"optional"` @@ -786,6 +1349,56 @@ func (o Filters) Type(ctx context.Context) attr.Type { } } +// GetExclude returns the value of the Exclude field in Filters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Filters) GetExclude(ctx context.Context) ([]types.String, bool) { + if o.Exclude.IsNull() || o.Exclude.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Exclude.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExclude sets the value of the Exclude field in Filters. +func (o *Filters) SetExclude(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exclude"] + o.Exclude = types.ListValueMust(t, vs) +} + +// GetInclude returns the value of the Include field in Filters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Filters) GetInclude(ctx context.Context) ([]types.String, bool) { + if o.Include.IsNull() || o.Include.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Include.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInclude sets the value of the Include field in Filters. +func (o *Filters) SetInclude(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["include"] + o.Include = types.ListValueMust(t, vs) +} + // Get pipeline permission levels type GetPipelinePermissionLevelsRequest struct { // The pipeline for which to get or manage permissions. @@ -875,6 +1488,31 @@ func (o GetPipelinePermissionLevelsResponse) Type(ctx context.Context) attr.Type } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetPipelinePermissionLevelsResponse as +// a slice of PipelinePermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPipelinePermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]PipelinePermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []PipelinePermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetPipelinePermissionLevelsResponse. +func (o *GetPipelinePermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []PipelinePermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get pipeline permissions type GetPipelinePermissionsRequest struct { // The pipeline for which to get or manage permissions. @@ -1055,6 +1693,57 @@ func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { } } +// GetLatestUpdates returns the value of the LatestUpdates field in GetPipelineResponse as +// a slice of UpdateStateInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPipelineResponse) GetLatestUpdates(ctx context.Context) ([]UpdateStateInfo, bool) { + if o.LatestUpdates.IsNull() || o.LatestUpdates.IsUnknown() { + return nil, false + } + var v []UpdateStateInfo + d := o.LatestUpdates.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLatestUpdates sets the value of the LatestUpdates field in GetPipelineResponse. +func (o *GetPipelineResponse) SetLatestUpdates(ctx context.Context, v []UpdateStateInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_updates"] + o.LatestUpdates = types.ListValueMust(t, vs) +} + +// GetSpec returns the value of the Spec field in GetPipelineResponse as +// a PipelineSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetPipelineResponse) GetSpec(ctx context.Context) (PipelineSpec, bool) { + var e PipelineSpec + if o.Spec.IsNull() || o.Spec.IsUnknown() { + return e, false + } + var v []PipelineSpec + d := o.Spec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSpec sets the value of the Spec field in GetPipelineResponse. +func (o *GetPipelineResponse) SetSpec(ctx context.Context, v PipelineSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spec"] + o.Spec = types.ListValueMust(t, vs) +} + // Get a pipeline update type GetUpdateRequest struct { // The ID of the pipeline. @@ -1148,6 +1837,32 @@ func (o GetUpdateResponse) Type(ctx context.Context) attr.Type { } } +// GetUpdate returns the value of the Update field in GetUpdateResponse as +// a UpdateInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetUpdateResponse) GetUpdate(ctx context.Context) (UpdateInfo, bool) { + var e UpdateInfo + if o.Update.IsNull() || o.Update.IsUnknown() { + return e, false + } + var v []UpdateInfo + d := o.Update.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUpdate sets the value of the Update field in GetUpdateResponse. +func (o *GetUpdateResponse) SetUpdate(ctx context.Context, v UpdateInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["update"] + o.Update = types.ListValueMust(t, vs) +} + type IngestionConfig struct { // Select a specific source report. Report types.List `tfsdk:"report" tf:"optional,object"` @@ -1208,6 +1923,84 @@ func (o IngestionConfig) Type(ctx context.Context) attr.Type { } } +// GetReport returns the value of the Report field in IngestionConfig as +// a ReportSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *IngestionConfig) GetReport(ctx context.Context) (ReportSpec, bool) { + var e ReportSpec + if o.Report.IsNull() || o.Report.IsUnknown() { + return e, false + } + var v []ReportSpec + d := o.Report.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetReport sets the value of the Report field in IngestionConfig. +func (o *IngestionConfig) SetReport(ctx context.Context, v ReportSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["report"] + o.Report = types.ListValueMust(t, vs) +} + +// GetSchema returns the value of the Schema field in IngestionConfig as +// a SchemaSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *IngestionConfig) GetSchema(ctx context.Context) (SchemaSpec, bool) { + var e SchemaSpec + if o.Schema.IsNull() || o.Schema.IsUnknown() { + return e, false + } + var v []SchemaSpec + d := o.Schema.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchema sets the value of the Schema field in IngestionConfig. +func (o *IngestionConfig) SetSchema(ctx context.Context, v SchemaSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schema"] + o.Schema = types.ListValueMust(t, vs) +} + +// GetTable returns the value of the Table field in IngestionConfig as +// a TableSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *IngestionConfig) GetTable(ctx context.Context) (TableSpec, bool) { + var e TableSpec + if o.Table.IsNull() || o.Table.IsUnknown() { + return e, false + } + var v []TableSpec + d := o.Table.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTable sets the value of the Table field in IngestionConfig. +func (o *IngestionConfig) SetTable(ctx context.Context, v TableSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table"] + o.Table = types.ListValueMust(t, vs) +} + type IngestionGatewayPipelineDefinition struct { // [Deprecated, use connection_name instead] Immutable. The Unity Catalog // connection that this gateway pipeline uses to communicate with the @@ -1341,6 +2134,57 @@ func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { } } +// GetObjects returns the value of the Objects field in IngestionPipelineDefinition as +// a slice of IngestionConfig values. +// If the field is unknown or null, the boolean return value is false. +func (o *IngestionPipelineDefinition) GetObjects(ctx context.Context) ([]IngestionConfig, bool) { + if o.Objects.IsNull() || o.Objects.IsUnknown() { + return nil, false + } + var v []IngestionConfig + d := o.Objects.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetObjects sets the value of the Objects field in IngestionPipelineDefinition. +func (o *IngestionPipelineDefinition) SetObjects(ctx context.Context, v []IngestionConfig) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["objects"] + o.Objects = types.ListValueMust(t, vs) +} + +// GetTableConfiguration returns the value of the TableConfiguration field in IngestionPipelineDefinition as +// a TableSpecificConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *IngestionPipelineDefinition) GetTableConfiguration(ctx context.Context) (TableSpecificConfig, bool) { + var e TableSpecificConfig + if o.TableConfiguration.IsNull() || o.TableConfiguration.IsUnknown() { + return e, false + } + var v []TableSpecificConfig + d := o.TableConfiguration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTableConfiguration sets the value of the TableConfiguration field in IngestionPipelineDefinition. +func (o *IngestionPipelineDefinition) SetTableConfiguration(ctx context.Context, v TableSpecificConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_configuration"] + o.TableConfiguration = types.ListValueMust(t, vs) +} + // List pipeline events type ListPipelineEventsRequest struct { // Criteria to select a subset of results, expressed using a SQL-like @@ -1417,6 +2261,31 @@ func (o ListPipelineEventsRequest) Type(ctx context.Context) attr.Type { } } +// GetOrderBy returns the value of the OrderBy field in ListPipelineEventsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPipelineEventsRequest) GetOrderBy(ctx context.Context) ([]types.String, bool) { + if o.OrderBy.IsNull() || o.OrderBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OrderBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOrderBy sets the value of the OrderBy field in ListPipelineEventsRequest. +func (o *ListPipelineEventsRequest) SetOrderBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + o.OrderBy = types.ListValueMust(t, vs) +} + type ListPipelineEventsResponse struct { // The list of events matching the request criteria. Events types.List `tfsdk:"events" tf:"optional"` @@ -1471,6 +2340,31 @@ func (o ListPipelineEventsResponse) Type(ctx context.Context) attr.Type { } } +// GetEvents returns the value of the Events field in ListPipelineEventsResponse as +// a slice of PipelineEvent values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPipelineEventsResponse) GetEvents(ctx context.Context) ([]PipelineEvent, bool) { + if o.Events.IsNull() || o.Events.IsUnknown() { + return nil, false + } + var v []PipelineEvent + d := o.Events.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEvents sets the value of the Events field in ListPipelineEventsResponse. +func (o *ListPipelineEventsResponse) SetEvents(ctx context.Context, v []PipelineEvent) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + o.Events = types.ListValueMust(t, vs) +} + // List pipelines type ListPipelinesRequest struct { // Select a subset of results based on the specified criteria. The supported @@ -1543,6 +2437,31 @@ func (o ListPipelinesRequest) Type(ctx context.Context) attr.Type { } } +// GetOrderBy returns the value of the OrderBy field in ListPipelinesRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPipelinesRequest) GetOrderBy(ctx context.Context) ([]types.String, bool) { + if o.OrderBy.IsNull() || o.OrderBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.OrderBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetOrderBy sets the value of the OrderBy field in ListPipelinesRequest. +func (o *ListPipelinesRequest) SetOrderBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + o.OrderBy = types.ListValueMust(t, vs) +} + type ListPipelinesResponse struct { // If present, a token to fetch the next page of events. NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -1593,6 +2512,31 @@ func (o ListPipelinesResponse) Type(ctx context.Context) attr.Type { } } +// GetStatuses returns the value of the Statuses field in ListPipelinesResponse as +// a slice of PipelineStateInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPipelinesResponse) GetStatuses(ctx context.Context) ([]PipelineStateInfo, bool) { + if o.Statuses.IsNull() || o.Statuses.IsUnknown() { + return nil, false + } + var v []PipelineStateInfo + d := o.Statuses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStatuses sets the value of the Statuses field in ListPipelinesResponse. +func (o *ListPipelinesResponse) SetStatuses(ctx context.Context, v []PipelineStateInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statuses"] + o.Statuses = types.ListValueMust(t, vs) +} + // List pipeline updates type ListUpdatesRequest struct { // Max number of entries to return in a single page. @@ -1704,6 +2648,31 @@ func (o ListUpdatesResponse) Type(ctx context.Context) attr.Type { } } +// GetUpdates returns the value of the Updates field in ListUpdatesResponse as +// a slice of UpdateInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListUpdatesResponse) GetUpdates(ctx context.Context) ([]UpdateInfo, bool) { + if o.Updates.IsNull() || o.Updates.IsUnknown() { + return nil, false + } + var v []UpdateInfo + d := o.Updates.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUpdates sets the value of the Updates field in ListUpdatesResponse. +func (o *ListUpdatesResponse) SetUpdates(ctx context.Context, v []UpdateInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["updates"] + o.Updates = types.ListValueMust(t, vs) +} + type ManualTrigger struct { } @@ -1841,6 +2810,56 @@ func (o Notifications) Type(ctx context.Context) attr.Type { } } +// GetAlerts returns the value of the Alerts field in Notifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Notifications) GetAlerts(ctx context.Context) ([]types.String, bool) { + if o.Alerts.IsNull() || o.Alerts.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Alerts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAlerts sets the value of the Alerts field in Notifications. +func (o *Notifications) SetAlerts(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alerts"] + o.Alerts = types.ListValueMust(t, vs) +} + +// GetEmailRecipients returns the value of the EmailRecipients field in Notifications as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Notifications) GetEmailRecipients(ctx context.Context) ([]types.String, bool) { + if o.EmailRecipients.IsNull() || o.EmailRecipients.IsUnknown() { + return nil, false + } + var v []types.String + d := o.EmailRecipients.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmailRecipients sets the value of the EmailRecipients field in Notifications. +func (o *Notifications) SetEmailRecipients(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_recipients"] + o.EmailRecipients = types.ListValueMust(t, vs) +} + type Origin struct { // The id of a batch. Unique within a flow. BatchId types.Int64 `tfsdk:"batch_id" tf:"optional"` @@ -2064,6 +3083,31 @@ func (o PipelineAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in PipelineAccessControlResponse as +// a slice of PipelinePermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineAccessControlResponse) GetAllPermissions(ctx context.Context) ([]PipelinePermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []PipelinePermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in PipelineAccessControlResponse. +func (o *PipelineAccessControlResponse) SetAllPermissions(ctx context.Context, v []PipelinePermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type PipelineCluster struct { // Note: This field won't be persisted. Only API users will check this // field. @@ -2177,12 +3221,12 @@ func (newState *PipelineCluster) SyncEffectiveFieldsDuringRead(existingState Pip func (a PipelineCluster) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "autoscale": reflect.TypeOf(PipelineClusterAutoscale{}), - "aws_attributes": reflect.TypeOf(compute.AwsAttributes{}), - "azure_attributes": reflect.TypeOf(compute.AzureAttributes{}), - "cluster_log_conf": reflect.TypeOf(compute.ClusterLogConf{}), + "aws_attributes": reflect.TypeOf(compute_tf.AwsAttributes{}), + "azure_attributes": reflect.TypeOf(compute_tf.AzureAttributes{}), + "cluster_log_conf": reflect.TypeOf(compute_tf.ClusterLogConf{}), "custom_tags": reflect.TypeOf(types.String{}), - "gcp_attributes": reflect.TypeOf(compute.GcpAttributes{}), - "init_scripts": reflect.TypeOf(compute.InitScriptInfo{}), + "gcp_attributes": reflect.TypeOf(compute_tf.GcpAttributes{}), + "init_scripts": reflect.TypeOf(compute_tf.InitScriptInfo{}), "spark_conf": reflect.TypeOf(types.String{}), "spark_env_vars": reflect.TypeOf(types.String{}), "ssh_public_keys": reflect.TypeOf(types.String{}), @@ -2265,6 +3309,261 @@ func (o PipelineCluster) Type(ctx context.Context) attr.Type { } } +// GetAutoscale returns the value of the Autoscale field in PipelineCluster as +// a PipelineClusterAutoscale value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetAutoscale(ctx context.Context) (PipelineClusterAutoscale, bool) { + var e PipelineClusterAutoscale + if o.Autoscale.IsNull() || o.Autoscale.IsUnknown() { + return e, false + } + var v []PipelineClusterAutoscale + d := o.Autoscale.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoscale sets the value of the Autoscale field in PipelineCluster. +func (o *PipelineCluster) SetAutoscale(ctx context.Context, v PipelineClusterAutoscale) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["autoscale"] + o.Autoscale = types.ListValueMust(t, vs) +} + +// GetAwsAttributes returns the value of the AwsAttributes field in PipelineCluster as +// a compute_tf.AwsAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetAwsAttributes(ctx context.Context) (compute_tf.AwsAttributes, bool) { + var e compute_tf.AwsAttributes + if o.AwsAttributes.IsNull() || o.AwsAttributes.IsUnknown() { + return e, false + } + var v []compute_tf.AwsAttributes + d := o.AwsAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsAttributes sets the value of the AwsAttributes field in PipelineCluster. +func (o *PipelineCluster) SetAwsAttributes(ctx context.Context, v compute_tf.AwsAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_attributes"] + o.AwsAttributes = types.ListValueMust(t, vs) +} + +// GetAzureAttributes returns the value of the AzureAttributes field in PipelineCluster as +// a compute_tf.AzureAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetAzureAttributes(ctx context.Context) (compute_tf.AzureAttributes, bool) { + var e compute_tf.AzureAttributes + if o.AzureAttributes.IsNull() || o.AzureAttributes.IsUnknown() { + return e, false + } + var v []compute_tf.AzureAttributes + d := o.AzureAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureAttributes sets the value of the AzureAttributes field in PipelineCluster. +func (o *PipelineCluster) SetAzureAttributes(ctx context.Context, v compute_tf.AzureAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_attributes"] + o.AzureAttributes = types.ListValueMust(t, vs) +} + +// GetClusterLogConf returns the value of the ClusterLogConf field in PipelineCluster as +// a compute_tf.ClusterLogConf value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetClusterLogConf(ctx context.Context) (compute_tf.ClusterLogConf, bool) { + var e compute_tf.ClusterLogConf + if o.ClusterLogConf.IsNull() || o.ClusterLogConf.IsUnknown() { + return e, false + } + var v []compute_tf.ClusterLogConf + d := o.ClusterLogConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetClusterLogConf sets the value of the ClusterLogConf field in PipelineCluster. +func (o *PipelineCluster) SetClusterLogConf(ctx context.Context, v compute_tf.ClusterLogConf) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_log_conf"] + o.ClusterLogConf = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in PipelineCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in PipelineCluster. +func (o *PipelineCluster) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetGcpAttributes returns the value of the GcpAttributes field in PipelineCluster as +// a compute_tf.GcpAttributes value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetGcpAttributes(ctx context.Context) (compute_tf.GcpAttributes, bool) { + var e compute_tf.GcpAttributes + if o.GcpAttributes.IsNull() || o.GcpAttributes.IsUnknown() { + return e, false + } + var v []compute_tf.GcpAttributes + d := o.GcpAttributes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpAttributes sets the value of the GcpAttributes field in PipelineCluster. +func (o *PipelineCluster) SetGcpAttributes(ctx context.Context, v compute_tf.GcpAttributes) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_attributes"] + o.GcpAttributes = types.ListValueMust(t, vs) +} + +// GetInitScripts returns the value of the InitScripts field in PipelineCluster as +// a slice of compute_tf.InitScriptInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetInitScripts(ctx context.Context) ([]compute_tf.InitScriptInfo, bool) { + if o.InitScripts.IsNull() || o.InitScripts.IsUnknown() { + return nil, false + } + var v []compute_tf.InitScriptInfo + d := o.InitScripts.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInitScripts sets the value of the InitScripts field in PipelineCluster. +func (o *PipelineCluster) SetInitScripts(ctx context.Context, v []compute_tf.InitScriptInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + o.InitScripts = types.ListValueMust(t, vs) +} + +// GetSparkConf returns the value of the SparkConf field in PipelineCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetSparkConf(ctx context.Context) (map[string]types.String, bool) { + if o.SparkConf.IsNull() || o.SparkConf.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkConf.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkConf sets the value of the SparkConf field in PipelineCluster. +func (o *PipelineCluster) SetSparkConf(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + o.SparkConf = types.MapValueMust(t, vs) +} + +// GetSparkEnvVars returns the value of the SparkEnvVars field in PipelineCluster as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetSparkEnvVars(ctx context.Context) (map[string]types.String, bool) { + if o.SparkEnvVars.IsNull() || o.SparkEnvVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.SparkEnvVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSparkEnvVars sets the value of the SparkEnvVars field in PipelineCluster. +func (o *PipelineCluster) SetSparkEnvVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + o.SparkEnvVars = types.MapValueMust(t, vs) +} + +// GetSshPublicKeys returns the value of the SshPublicKeys field in PipelineCluster as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineCluster) GetSshPublicKeys(ctx context.Context) ([]types.String, bool) { + if o.SshPublicKeys.IsNull() || o.SshPublicKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SshPublicKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSshPublicKeys sets the value of the SshPublicKeys field in PipelineCluster. +func (o *PipelineCluster) SetSshPublicKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + o.SshPublicKeys = types.ListValueMust(t, vs) +} + type PipelineClusterAutoscale struct { // The maximum number of workers to which the cluster can scale up when // overloaded. `max_workers` must be strictly greater than `min_workers`. @@ -2452,6 +3751,84 @@ func (o PipelineEvent) Type(ctx context.Context) attr.Type { } } +// GetError returns the value of the Error field in PipelineEvent as +// a ErrorDetail value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineEvent) GetError(ctx context.Context) (ErrorDetail, bool) { + var e ErrorDetail + if o.Error.IsNull() || o.Error.IsUnknown() { + return e, false + } + var v []ErrorDetail + d := o.Error.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetError sets the value of the Error field in PipelineEvent. +func (o *PipelineEvent) SetError(ctx context.Context, v ErrorDetail) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error"] + o.Error = types.ListValueMust(t, vs) +} + +// GetOrigin returns the value of the Origin field in PipelineEvent as +// a Origin value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineEvent) GetOrigin(ctx context.Context) (Origin, bool) { + var e Origin + if o.Origin.IsNull() || o.Origin.IsUnknown() { + return e, false + } + var v []Origin + d := o.Origin.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOrigin sets the value of the Origin field in PipelineEvent. +func (o *PipelineEvent) SetOrigin(ctx context.Context, v Origin) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["origin"] + o.Origin = types.ListValueMust(t, vs) +} + +// GetSequence returns the value of the Sequence field in PipelineEvent as +// a Sequencing value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineEvent) GetSequence(ctx context.Context) (Sequencing, bool) { + var e Sequencing + if o.Sequence.IsNull() || o.Sequence.IsUnknown() { + return e, false + } + var v []Sequencing + d := o.Sequence.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSequence sets the value of the Sequence field in PipelineEvent. +func (o *PipelineEvent) SetSequence(ctx context.Context, v Sequencing) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sequence"] + o.Sequence = types.ListValueMust(t, vs) +} + type PipelineLibrary struct { // The path to a file that defines a pipeline and is stored in the // Databricks Repos. @@ -2483,7 +3860,7 @@ func (newState *PipelineLibrary) SyncEffectiveFieldsDuringRead(existingState Pip func (a PipelineLibrary) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ "file": reflect.TypeOf(FileLibrary{}), - "maven": reflect.TypeOf(compute.MavenLibrary{}), + "maven": reflect.TypeOf(compute_tf.MavenLibrary{}), "notebook": reflect.TypeOf(NotebookLibrary{}), } } @@ -2522,6 +3899,84 @@ func (o PipelineLibrary) Type(ctx context.Context) attr.Type { } } +// GetFile returns the value of the File field in PipelineLibrary as +// a FileLibrary value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineLibrary) GetFile(ctx context.Context) (FileLibrary, bool) { + var e FileLibrary + if o.File.IsNull() || o.File.IsUnknown() { + return e, false + } + var v []FileLibrary + d := o.File.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFile sets the value of the File field in PipelineLibrary. +func (o *PipelineLibrary) SetFile(ctx context.Context, v FileLibrary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file"] + o.File = types.ListValueMust(t, vs) +} + +// GetMaven returns the value of the Maven field in PipelineLibrary as +// a compute_tf.MavenLibrary value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineLibrary) GetMaven(ctx context.Context) (compute_tf.MavenLibrary, bool) { + var e compute_tf.MavenLibrary + if o.Maven.IsNull() || o.Maven.IsUnknown() { + return e, false + } + var v []compute_tf.MavenLibrary + d := o.Maven.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMaven sets the value of the Maven field in PipelineLibrary. +func (o *PipelineLibrary) SetMaven(ctx context.Context, v compute_tf.MavenLibrary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["maven"] + o.Maven = types.ListValueMust(t, vs) +} + +// GetNotebook returns the value of the Notebook field in PipelineLibrary as +// a NotebookLibrary value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineLibrary) GetNotebook(ctx context.Context) (NotebookLibrary, bool) { + var e NotebookLibrary + if o.Notebook.IsNull() || o.Notebook.IsUnknown() { + return e, false + } + var v []NotebookLibrary + d := o.Notebook.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNotebook sets the value of the Notebook field in PipelineLibrary. +func (o *PipelineLibrary) SetNotebook(ctx context.Context, v NotebookLibrary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook"] + o.Notebook = types.ListValueMust(t, vs) +} + type PipelinePermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2575,6 +4030,31 @@ func (o PipelinePermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in PipelinePermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelinePermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in PipelinePermission. +func (o *PipelinePermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type PipelinePermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -2628,6 +4108,31 @@ func (o PipelinePermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in PipelinePermissions as +// a slice of PipelineAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelinePermissions) GetAccessControlList(ctx context.Context) ([]PipelineAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []PipelineAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in PipelinePermissions. +func (o *PipelinePermissions) SetAccessControlList(ctx context.Context, v []PipelineAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type PipelinePermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -2722,6 +4227,31 @@ func (o PipelinePermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in PipelinePermissionsRequest as +// a slice of PipelineAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelinePermissionsRequest) GetAccessControlList(ctx context.Context) ([]PipelineAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []PipelineAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in PipelinePermissionsRequest. +func (o *PipelinePermissionsRequest) SetAccessControlList(ctx context.Context, v []PipelineAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type PipelineSpec struct { // Budget policy of this pipeline. BudgetPolicyId types.String `tfsdk:"budget_policy_id" tf:"optional"` @@ -2892,6 +4422,262 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { } } +// GetClusters returns the value of the Clusters field in PipelineSpec as +// a slice of PipelineCluster values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetClusters(ctx context.Context) ([]PipelineCluster, bool) { + if o.Clusters.IsNull() || o.Clusters.IsUnknown() { + return nil, false + } + var v []PipelineCluster + d := o.Clusters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetClusters sets the value of the Clusters field in PipelineSpec. +func (o *PipelineSpec) SetClusters(ctx context.Context, v []PipelineCluster) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + o.Clusters = types.ListValueMust(t, vs) +} + +// GetConfiguration returns the value of the Configuration field in PipelineSpec as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetConfiguration(ctx context.Context) (map[string]types.String, bool) { + if o.Configuration.IsNull() || o.Configuration.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Configuration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetConfiguration sets the value of the Configuration field in PipelineSpec. +func (o *PipelineSpec) SetConfiguration(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration"] + o.Configuration = types.MapValueMust(t, vs) +} + +// GetDeployment returns the value of the Deployment field in PipelineSpec as +// a PipelineDeployment value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetDeployment(ctx context.Context) (PipelineDeployment, bool) { + var e PipelineDeployment + if o.Deployment.IsNull() || o.Deployment.IsUnknown() { + return e, false + } + var v []PipelineDeployment + d := o.Deployment.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeployment sets the value of the Deployment field in PipelineSpec. +func (o *PipelineSpec) SetDeployment(ctx context.Context, v PipelineDeployment) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment"] + o.Deployment = types.ListValueMust(t, vs) +} + +// GetFilters returns the value of the Filters field in PipelineSpec as +// a Filters value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetFilters(ctx context.Context) (Filters, bool) { + var e Filters + if o.Filters.IsNull() || o.Filters.IsUnknown() { + return e, false + } + var v []Filters + d := o.Filters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilters sets the value of the Filters field in PipelineSpec. +func (o *PipelineSpec) SetFilters(ctx context.Context, v Filters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + o.Filters = types.ListValueMust(t, vs) +} + +// GetGatewayDefinition returns the value of the GatewayDefinition field in PipelineSpec as +// a IngestionGatewayPipelineDefinition value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetGatewayDefinition(ctx context.Context) (IngestionGatewayPipelineDefinition, bool) { + var e IngestionGatewayPipelineDefinition + if o.GatewayDefinition.IsNull() || o.GatewayDefinition.IsUnknown() { + return e, false + } + var v []IngestionGatewayPipelineDefinition + d := o.GatewayDefinition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGatewayDefinition sets the value of the GatewayDefinition field in PipelineSpec. +func (o *PipelineSpec) SetGatewayDefinition(ctx context.Context, v IngestionGatewayPipelineDefinition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gateway_definition"] + o.GatewayDefinition = types.ListValueMust(t, vs) +} + +// GetIngestionDefinition returns the value of the IngestionDefinition field in PipelineSpec as +// a IngestionPipelineDefinition value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetIngestionDefinition(ctx context.Context) (IngestionPipelineDefinition, bool) { + var e IngestionPipelineDefinition + if o.IngestionDefinition.IsNull() || o.IngestionDefinition.IsUnknown() { + return e, false + } + var v []IngestionPipelineDefinition + d := o.IngestionDefinition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIngestionDefinition sets the value of the IngestionDefinition field in PipelineSpec. +func (o *PipelineSpec) SetIngestionDefinition(ctx context.Context, v IngestionPipelineDefinition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ingestion_definition"] + o.IngestionDefinition = types.ListValueMust(t, vs) +} + +// GetLibraries returns the value of the Libraries field in PipelineSpec as +// a slice of PipelineLibrary values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetLibraries(ctx context.Context) ([]PipelineLibrary, bool) { + if o.Libraries.IsNull() || o.Libraries.IsUnknown() { + return nil, false + } + var v []PipelineLibrary + d := o.Libraries.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLibraries sets the value of the Libraries field in PipelineSpec. +func (o *PipelineSpec) SetLibraries(ctx context.Context, v []PipelineLibrary) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + o.Libraries = types.ListValueMust(t, vs) +} + +// GetNotifications returns the value of the Notifications field in PipelineSpec as +// a slice of Notifications values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetNotifications(ctx context.Context) ([]Notifications, bool) { + if o.Notifications.IsNull() || o.Notifications.IsUnknown() { + return nil, false + } + var v []Notifications + d := o.Notifications.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetNotifications sets the value of the Notifications field in PipelineSpec. +func (o *PipelineSpec) SetNotifications(ctx context.Context, v []Notifications) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + o.Notifications = types.ListValueMust(t, vs) +} + +// GetRestartWindow returns the value of the RestartWindow field in PipelineSpec as +// a RestartWindow value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetRestartWindow(ctx context.Context) (RestartWindow, bool) { + var e RestartWindow + if o.RestartWindow.IsNull() || o.RestartWindow.IsUnknown() { + return e, false + } + var v []RestartWindow + d := o.RestartWindow.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRestartWindow sets the value of the RestartWindow field in PipelineSpec. +func (o *PipelineSpec) SetRestartWindow(ctx context.Context, v RestartWindow) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["restart_window"] + o.RestartWindow = types.ListValueMust(t, vs) +} + +// GetTrigger returns the value of the Trigger field in PipelineSpec as +// a PipelineTrigger value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineSpec) GetTrigger(ctx context.Context) (PipelineTrigger, bool) { + var e PipelineTrigger + if o.Trigger.IsNull() || o.Trigger.IsUnknown() { + return e, false + } + var v []PipelineTrigger + d := o.Trigger.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrigger sets the value of the Trigger field in PipelineSpec. +func (o *PipelineSpec) SetTrigger(ctx context.Context, v PipelineTrigger) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["trigger"] + o.Trigger = types.ListValueMust(t, vs) +} + type PipelineStateInfo struct { // The unique identifier of the cluster running the pipeline. ClusterId types.String `tfsdk:"cluster_id" tf:"optional"` @@ -2968,6 +4754,31 @@ func (o PipelineStateInfo) Type(ctx context.Context) attr.Type { } } +// GetLatestUpdates returns the value of the LatestUpdates field in PipelineStateInfo as +// a slice of UpdateStateInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineStateInfo) GetLatestUpdates(ctx context.Context) ([]UpdateStateInfo, bool) { + if o.LatestUpdates.IsNull() || o.LatestUpdates.IsUnknown() { + return nil, false + } + var v []UpdateStateInfo + d := o.LatestUpdates.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetLatestUpdates sets the value of the LatestUpdates field in PipelineStateInfo. +func (o *PipelineStateInfo) SetLatestUpdates(ctx context.Context, v []UpdateStateInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_updates"] + o.LatestUpdates = types.ListValueMust(t, vs) +} + type PipelineTrigger struct { Cron types.List `tfsdk:"cron" tf:"optional,object"` @@ -3020,6 +4831,58 @@ func (o PipelineTrigger) Type(ctx context.Context) attr.Type { } } +// GetCron returns the value of the Cron field in PipelineTrigger as +// a CronTrigger value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineTrigger) GetCron(ctx context.Context) (CronTrigger, bool) { + var e CronTrigger + if o.Cron.IsNull() || o.Cron.IsUnknown() { + return e, false + } + var v []CronTrigger + d := o.Cron.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCron sets the value of the Cron field in PipelineTrigger. +func (o *PipelineTrigger) SetCron(ctx context.Context, v CronTrigger) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cron"] + o.Cron = types.ListValueMust(t, vs) +} + +// GetManual returns the value of the Manual field in PipelineTrigger as +// a ManualTrigger value. +// If the field is unknown or null, the boolean return value is false. +func (o *PipelineTrigger) GetManual(ctx context.Context) (ManualTrigger, bool) { + var e ManualTrigger + if o.Manual.IsNull() || o.Manual.IsUnknown() { + return e, false + } + var v []ManualTrigger + d := o.Manual.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetManual sets the value of the Manual field in PipelineTrigger. +func (o *PipelineTrigger) SetManual(ctx context.Context, v ManualTrigger) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["manual"] + o.Manual = types.ListValueMust(t, vs) +} + type ReportSpec struct { // Required. Destination catalog to store table. DestinationCatalog types.String `tfsdk:"destination_catalog" tf:"optional"` @@ -3085,6 +4948,32 @@ func (o ReportSpec) Type(ctx context.Context) attr.Type { } } +// GetTableConfiguration returns the value of the TableConfiguration field in ReportSpec as +// a TableSpecificConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ReportSpec) GetTableConfiguration(ctx context.Context) (TableSpecificConfig, bool) { + var e TableSpecificConfig + if o.TableConfiguration.IsNull() || o.TableConfiguration.IsUnknown() { + return e, false + } + var v []TableSpecificConfig + d := o.TableConfiguration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTableConfiguration sets the value of the TableConfiguration field in ReportSpec. +func (o *ReportSpec) SetTableConfiguration(ctx context.Context, v TableSpecificConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_configuration"] + o.TableConfiguration = types.ListValueMust(t, vs) +} + type RestartWindow struct { // Days of week in which the restart is allowed to happen (within a // five-hour window starting at start_hour). If not specified all days of @@ -3208,6 +5097,32 @@ func (o SchemaSpec) Type(ctx context.Context) attr.Type { } } +// GetTableConfiguration returns the value of the TableConfiguration field in SchemaSpec as +// a TableSpecificConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *SchemaSpec) GetTableConfiguration(ctx context.Context) (TableSpecificConfig, bool) { + var e TableSpecificConfig + if o.TableConfiguration.IsNull() || o.TableConfiguration.IsUnknown() { + return e, false + } + var v []TableSpecificConfig + d := o.TableConfiguration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTableConfiguration sets the value of the TableConfiguration field in SchemaSpec. +func (o *SchemaSpec) SetTableConfiguration(ctx context.Context, v TableSpecificConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_configuration"] + o.TableConfiguration = types.ListValueMust(t, vs) +} + type Sequencing struct { // A sequence number, unique and increasing within the control plane. ControlPlaneSeqNo types.Int64 `tfsdk:"control_plane_seq_no" tf:"optional"` @@ -3258,6 +5173,32 @@ func (o Sequencing) Type(ctx context.Context) attr.Type { } } +// GetDataPlaneId returns the value of the DataPlaneId field in Sequencing as +// a DataPlaneId value. +// If the field is unknown or null, the boolean return value is false. +func (o *Sequencing) GetDataPlaneId(ctx context.Context) (DataPlaneId, bool) { + var e DataPlaneId + if o.DataPlaneId.IsNull() || o.DataPlaneId.IsUnknown() { + return e, false + } + var v []DataPlaneId + d := o.DataPlaneId.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataPlaneId sets the value of the DataPlaneId field in Sequencing. +func (o *Sequencing) SetDataPlaneId(ctx context.Context, v DataPlaneId) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_plane_id"] + o.DataPlaneId = types.ListValueMust(t, vs) +} + type SerializedException struct { // Runtime class of the exception ClassName types.String `tfsdk:"class_name" tf:"optional"` @@ -3312,6 +5253,31 @@ func (o SerializedException) Type(ctx context.Context) attr.Type { } } +// GetStack returns the value of the Stack field in SerializedException as +// a slice of StackFrame values. +// If the field is unknown or null, the boolean return value is false. +func (o *SerializedException) GetStack(ctx context.Context) ([]StackFrame, bool) { + if o.Stack.IsNull() || o.Stack.IsUnknown() { + return nil, false + } + var v []StackFrame + d := o.Stack.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStack sets the value of the Stack field in SerializedException. +func (o *SerializedException) SetStack(ctx context.Context, v []StackFrame) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stack"] + o.Stack = types.ListValueMust(t, vs) +} + type StackFrame struct { // Class from which the method call originated DeclaringClass types.String `tfsdk:"declaring_class" tf:"optional"` @@ -3441,6 +5407,56 @@ func (o StartUpdate) Type(ctx context.Context) attr.Type { } } +// GetFullRefreshSelection returns the value of the FullRefreshSelection field in StartUpdate as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *StartUpdate) GetFullRefreshSelection(ctx context.Context) ([]types.String, bool) { + if o.FullRefreshSelection.IsNull() || o.FullRefreshSelection.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FullRefreshSelection.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFullRefreshSelection sets the value of the FullRefreshSelection field in StartUpdate. +func (o *StartUpdate) SetFullRefreshSelection(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["full_refresh_selection"] + o.FullRefreshSelection = types.ListValueMust(t, vs) +} + +// GetRefreshSelection returns the value of the RefreshSelection field in StartUpdate as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *StartUpdate) GetRefreshSelection(ctx context.Context) ([]types.String, bool) { + if o.RefreshSelection.IsNull() || o.RefreshSelection.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RefreshSelection.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRefreshSelection sets the value of the RefreshSelection field in StartUpdate. +func (o *StartUpdate) SetRefreshSelection(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["refresh_selection"] + o.RefreshSelection = types.ListValueMust(t, vs) +} + type StartUpdateResponse struct { UpdateId types.String `tfsdk:"update_id" tf:"optional"` } @@ -3634,6 +5650,32 @@ func (o TableSpec) Type(ctx context.Context) attr.Type { } } +// GetTableConfiguration returns the value of the TableConfiguration field in TableSpec as +// a TableSpecificConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *TableSpec) GetTableConfiguration(ctx context.Context) (TableSpecificConfig, bool) { + var e TableSpecificConfig + if o.TableConfiguration.IsNull() || o.TableConfiguration.IsUnknown() { + return e, false + } + var v []TableSpecificConfig + d := o.TableConfiguration.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTableConfiguration sets the value of the TableConfiguration field in TableSpec. +func (o *TableSpec) SetTableConfiguration(ctx context.Context, v TableSpecificConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_configuration"] + o.TableConfiguration = types.ListValueMust(t, vs) +} + type TableSpecificConfig struct { // The primary key of the table used to apply changes. PrimaryKeys types.List `tfsdk:"primary_keys" tf:"optional"` @@ -3698,6 +5740,56 @@ func (o TableSpecificConfig) Type(ctx context.Context) attr.Type { } } +// GetPrimaryKeys returns the value of the PrimaryKeys field in TableSpecificConfig as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableSpecificConfig) GetPrimaryKeys(ctx context.Context) ([]types.String, bool) { + if o.PrimaryKeys.IsNull() || o.PrimaryKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PrimaryKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrimaryKeys sets the value of the PrimaryKeys field in TableSpecificConfig. +func (o *TableSpecificConfig) SetPrimaryKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_keys"] + o.PrimaryKeys = types.ListValueMust(t, vs) +} + +// GetSequenceBy returns the value of the SequenceBy field in TableSpecificConfig as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TableSpecificConfig) GetSequenceBy(ctx context.Context) ([]types.String, bool) { + if o.SequenceBy.IsNull() || o.SequenceBy.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SequenceBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSequenceBy sets the value of the SequenceBy field in TableSpecificConfig. +func (o *TableSpecificConfig) SetSequenceBy(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sequence_by"] + o.SequenceBy = types.ListValueMust(t, vs) +} + type UpdateInfo struct { // What triggered this update. Cause types.String `tfsdk:"cause" tf:"optional"` @@ -3798,6 +5890,82 @@ func (o UpdateInfo) Type(ctx context.Context) attr.Type { } } +// GetConfig returns the value of the Config field in UpdateInfo as +// a PipelineSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateInfo) GetConfig(ctx context.Context) (PipelineSpec, bool) { + var e PipelineSpec + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []PipelineSpec + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in UpdateInfo. +func (o *UpdateInfo) SetConfig(ctx context.Context, v PipelineSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + +// GetFullRefreshSelection returns the value of the FullRefreshSelection field in UpdateInfo as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateInfo) GetFullRefreshSelection(ctx context.Context) ([]types.String, bool) { + if o.FullRefreshSelection.IsNull() || o.FullRefreshSelection.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FullRefreshSelection.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFullRefreshSelection sets the value of the FullRefreshSelection field in UpdateInfo. +func (o *UpdateInfo) SetFullRefreshSelection(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["full_refresh_selection"] + o.FullRefreshSelection = types.ListValueMust(t, vs) +} + +// GetRefreshSelection returns the value of the RefreshSelection field in UpdateInfo as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateInfo) GetRefreshSelection(ctx context.Context) ([]types.String, bool) { + if o.RefreshSelection.IsNull() || o.RefreshSelection.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RefreshSelection.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRefreshSelection sets the value of the RefreshSelection field in UpdateInfo. +func (o *UpdateInfo) SetRefreshSelection(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["refresh_selection"] + o.RefreshSelection = types.ListValueMust(t, vs) +} + type UpdateStateInfo struct { CreationTime types.String `tfsdk:"creation_time" tf:"optional"` @@ -3846,34 +6014,3 @@ func (o UpdateStateInfo) Type(ctx context.Context) attr.Type { }, } } - -// The deployment method that manages the pipeline: - BUNDLE: The pipeline is -// managed by a Databricks Asset Bundle. - -// The severity level of the event. - -// The health of a pipeline. - -// Maturity level for EventDetails. - -// Databricks Enhanced Autoscaling optimizes cluster utilization by -// automatically allocating cluster resources based on workload volume, with -// minimal impact to the data processing latency of your pipelines. Enhanced -// Autoscaling is available for `updates` clusters only. The legacy autoscaling -// feature is used for `maintenance` clusters. - -// Permission level - -// The pipeline state. - -// The health of a pipeline. - -// Days of week in which the restart is allowed to happen (within a five-hour -// window starting at start_hour). If not specified all days of the week will be -// used. - -// The SCD type to use to ingest the table. - -// What triggered this update. - -// The update state. diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 2b91c6f3ed..758abbc096 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -64,6 +65,32 @@ func (o AwsCredentials) Type(ctx context.Context) attr.Type { } } +// GetStsRole returns the value of the StsRole field in AwsCredentials as +// a StsRole value. +// If the field is unknown or null, the boolean return value is false. +func (o *AwsCredentials) GetStsRole(ctx context.Context) (StsRole, bool) { + var e StsRole + if o.StsRole.IsNull() || o.StsRole.IsUnknown() { + return e, false + } + var v []StsRole + d := o.StsRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStsRole sets the value of the StsRole field in AwsCredentials. +func (o *AwsCredentials) SetStsRole(ctx context.Context, v StsRole) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sts_role"] + o.StsRole = types.ListValueMust(t, vs) +} + type AwsKeyInfo struct { // The AWS KMS key alias. KeyAlias types.String `tfsdk:"key_alias" tf:"optional"` @@ -214,6 +241,32 @@ func (o CloudResourceContainer) Type(ctx context.Context) attr.Type { } } +// GetGcp returns the value of the Gcp field in CloudResourceContainer as +// a CustomerFacingGcpCloudResourceContainer value. +// If the field is unknown or null, the boolean return value is false. +func (o *CloudResourceContainer) GetGcp(ctx context.Context) (CustomerFacingGcpCloudResourceContainer, bool) { + var e CustomerFacingGcpCloudResourceContainer + if o.Gcp.IsNull() || o.Gcp.IsUnknown() { + return e, false + } + var v []CustomerFacingGcpCloudResourceContainer + d := o.Gcp.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcp sets the value of the Gcp field in CloudResourceContainer. +func (o *CloudResourceContainer) SetGcp(ctx context.Context, v CustomerFacingGcpCloudResourceContainer) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp"] + o.Gcp = types.ListValueMust(t, vs) +} + type CreateAwsKeyInfo struct { // The AWS KMS key alias. KeyAlias types.String `tfsdk:"key_alias" tf:"optional"` @@ -313,6 +366,32 @@ func (o CreateCredentialAwsCredentials) Type(ctx context.Context) attr.Type { } } +// GetStsRole returns the value of the StsRole field in CreateCredentialAwsCredentials as +// a CreateCredentialStsRole value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCredentialAwsCredentials) GetStsRole(ctx context.Context) (CreateCredentialStsRole, bool) { + var e CreateCredentialStsRole + if o.StsRole.IsNull() || o.StsRole.IsUnknown() { + return e, false + } + var v []CreateCredentialStsRole + d := o.StsRole.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStsRole sets the value of the StsRole field in CreateCredentialAwsCredentials. +func (o *CreateCredentialAwsCredentials) SetStsRole(ctx context.Context, v CreateCredentialStsRole) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sts_role"] + o.StsRole = types.ListValueMust(t, vs) +} + type CreateCredentialRequest struct { AwsCredentials types.List `tfsdk:"aws_credentials" tf:"object"` // The human-readable name of the credential configuration object. @@ -362,6 +441,32 @@ func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { } } +// GetAwsCredentials returns the value of the AwsCredentials field in CreateCredentialRequest as +// a CreateCredentialAwsCredentials value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCredentialRequest) GetAwsCredentials(ctx context.Context) (CreateCredentialAwsCredentials, bool) { + var e CreateCredentialAwsCredentials + if o.AwsCredentials.IsNull() || o.AwsCredentials.IsUnknown() { + return e, false + } + var v []CreateCredentialAwsCredentials + d := o.AwsCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsCredentials sets the value of the AwsCredentials field in CreateCredentialRequest. +func (o *CreateCredentialRequest) SetAwsCredentials(ctx context.Context, v CreateCredentialAwsCredentials) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_credentials"] + o.AwsCredentials = types.ListValueMust(t, vs) +} + type CreateCredentialStsRole struct { // The Amazon Resource Name (ARN) of the cross account role. RoleArn types.String `tfsdk:"role_arn" tf:"optional"` @@ -463,6 +568,83 @@ func (o CreateCustomerManagedKeyRequest) Type(ctx context.Context) attr.Type { } } +// GetAwsKeyInfo returns the value of the AwsKeyInfo field in CreateCustomerManagedKeyRequest as +// a CreateAwsKeyInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCustomerManagedKeyRequest) GetAwsKeyInfo(ctx context.Context) (CreateAwsKeyInfo, bool) { + var e CreateAwsKeyInfo + if o.AwsKeyInfo.IsNull() || o.AwsKeyInfo.IsUnknown() { + return e, false + } + var v []CreateAwsKeyInfo + d := o.AwsKeyInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsKeyInfo sets the value of the AwsKeyInfo field in CreateCustomerManagedKeyRequest. +func (o *CreateCustomerManagedKeyRequest) SetAwsKeyInfo(ctx context.Context, v CreateAwsKeyInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_key_info"] + o.AwsKeyInfo = types.ListValueMust(t, vs) +} + +// GetGcpKeyInfo returns the value of the GcpKeyInfo field in CreateCustomerManagedKeyRequest as +// a CreateGcpKeyInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCustomerManagedKeyRequest) GetGcpKeyInfo(ctx context.Context) (CreateGcpKeyInfo, bool) { + var e CreateGcpKeyInfo + if o.GcpKeyInfo.IsNull() || o.GcpKeyInfo.IsUnknown() { + return e, false + } + var v []CreateGcpKeyInfo + d := o.GcpKeyInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpKeyInfo sets the value of the GcpKeyInfo field in CreateCustomerManagedKeyRequest. +func (o *CreateCustomerManagedKeyRequest) SetGcpKeyInfo(ctx context.Context, v CreateGcpKeyInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_key_info"] + o.GcpKeyInfo = types.ListValueMust(t, vs) +} + +// GetUseCases returns the value of the UseCases field in CreateCustomerManagedKeyRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateCustomerManagedKeyRequest) GetUseCases(ctx context.Context) ([]types.String, bool) { + if o.UseCases.IsNull() || o.UseCases.IsUnknown() { + return nil, false + } + var v []types.String + d := o.UseCases.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUseCases sets the value of the UseCases field in CreateCustomerManagedKeyRequest. +func (o *CreateCustomerManagedKeyRequest) SetUseCases(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["use_cases"] + o.UseCases = types.ListValueMust(t, vs) +} + type CreateGcpKeyInfo struct { // The GCP KMS key's resource name KmsKeyId types.String `tfsdk:"kms_key_id" tf:""` @@ -587,6 +769,108 @@ func (o CreateNetworkRequest) Type(ctx context.Context) attr.Type { } } +// GetGcpNetworkInfo returns the value of the GcpNetworkInfo field in CreateNetworkRequest as +// a GcpNetworkInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateNetworkRequest) GetGcpNetworkInfo(ctx context.Context) (GcpNetworkInfo, bool) { + var e GcpNetworkInfo + if o.GcpNetworkInfo.IsNull() || o.GcpNetworkInfo.IsUnknown() { + return e, false + } + var v []GcpNetworkInfo + d := o.GcpNetworkInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpNetworkInfo sets the value of the GcpNetworkInfo field in CreateNetworkRequest. +func (o *CreateNetworkRequest) SetGcpNetworkInfo(ctx context.Context, v GcpNetworkInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_network_info"] + o.GcpNetworkInfo = types.ListValueMust(t, vs) +} + +// GetSecurityGroupIds returns the value of the SecurityGroupIds field in CreateNetworkRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateNetworkRequest) GetSecurityGroupIds(ctx context.Context) ([]types.String, bool) { + if o.SecurityGroupIds.IsNull() || o.SecurityGroupIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SecurityGroupIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSecurityGroupIds sets the value of the SecurityGroupIds field in CreateNetworkRequest. +func (o *CreateNetworkRequest) SetSecurityGroupIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["security_group_ids"] + o.SecurityGroupIds = types.ListValueMust(t, vs) +} + +// GetSubnetIds returns the value of the SubnetIds field in CreateNetworkRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateNetworkRequest) GetSubnetIds(ctx context.Context) ([]types.String, bool) { + if o.SubnetIds.IsNull() || o.SubnetIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SubnetIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSubnetIds sets the value of the SubnetIds field in CreateNetworkRequest. +func (o *CreateNetworkRequest) SetSubnetIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subnet_ids"] + o.SubnetIds = types.ListValueMust(t, vs) +} + +// GetVpcEndpoints returns the value of the VpcEndpoints field in CreateNetworkRequest as +// a NetworkVpcEndpoints value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateNetworkRequest) GetVpcEndpoints(ctx context.Context) (NetworkVpcEndpoints, bool) { + var e NetworkVpcEndpoints + if o.VpcEndpoints.IsNull() || o.VpcEndpoints.IsUnknown() { + return e, false + } + var v []NetworkVpcEndpoints + d := o.VpcEndpoints.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVpcEndpoints sets the value of the VpcEndpoints field in CreateNetworkRequest. +func (o *CreateNetworkRequest) SetVpcEndpoints(ctx context.Context, v NetworkVpcEndpoints) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["vpc_endpoints"] + o.VpcEndpoints = types.ListValueMust(t, vs) +} + type CreateStorageConfigurationRequest struct { // Root S3 bucket information. RootBucketInfo types.List `tfsdk:"root_bucket_info" tf:"object"` @@ -637,6 +921,32 @@ func (o CreateStorageConfigurationRequest) Type(ctx context.Context) attr.Type { } } +// GetRootBucketInfo returns the value of the RootBucketInfo field in CreateStorageConfigurationRequest as +// a RootBucketInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateStorageConfigurationRequest) GetRootBucketInfo(ctx context.Context) (RootBucketInfo, bool) { + var e RootBucketInfo + if o.RootBucketInfo.IsNull() || o.RootBucketInfo.IsUnknown() { + return e, false + } + var v []RootBucketInfo + d := o.RootBucketInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRootBucketInfo sets the value of the RootBucketInfo field in CreateStorageConfigurationRequest. +func (o *CreateStorageConfigurationRequest) SetRootBucketInfo(ctx context.Context, v RootBucketInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["root_bucket_info"] + o.RootBucketInfo = types.ListValueMust(t, vs) +} + type CreateVpcEndpointRequest struct { // The ID of the VPC endpoint object in AWS. AwsVpcEndpointId types.String `tfsdk:"aws_vpc_endpoint_id" tf:"optional"` @@ -696,6 +1006,32 @@ func (o CreateVpcEndpointRequest) Type(ctx context.Context) attr.Type { } } +// GetGcpVpcEndpointInfo returns the value of the GcpVpcEndpointInfo field in CreateVpcEndpointRequest as +// a GcpVpcEndpointInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateVpcEndpointRequest) GetGcpVpcEndpointInfo(ctx context.Context) (GcpVpcEndpointInfo, bool) { + var e GcpVpcEndpointInfo + if o.GcpVpcEndpointInfo.IsNull() || o.GcpVpcEndpointInfo.IsUnknown() { + return e, false + } + var v []GcpVpcEndpointInfo + d := o.GcpVpcEndpointInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpVpcEndpointInfo sets the value of the GcpVpcEndpointInfo field in CreateVpcEndpointRequest. +func (o *CreateVpcEndpointRequest) SetGcpVpcEndpointInfo(ctx context.Context, v GcpVpcEndpointInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_vpc_endpoint_info"] + o.GcpVpcEndpointInfo = types.ListValueMust(t, vs) +} + type CreateWorkspaceRequest struct { // The AWS region of the workspace's data plane. AwsRegion types.String `tfsdk:"aws_region" tf:"optional"` @@ -891,6 +1227,109 @@ func (o CreateWorkspaceRequest) Type(ctx context.Context) attr.Type { } } +// GetCloudResourceContainer returns the value of the CloudResourceContainer field in CreateWorkspaceRequest as +// a CloudResourceContainer value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWorkspaceRequest) GetCloudResourceContainer(ctx context.Context) (CloudResourceContainer, bool) { + var e CloudResourceContainer + if o.CloudResourceContainer.IsNull() || o.CloudResourceContainer.IsUnknown() { + return e, false + } + var v []CloudResourceContainer + d := o.CloudResourceContainer.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCloudResourceContainer sets the value of the CloudResourceContainer field in CreateWorkspaceRequest. +func (o *CreateWorkspaceRequest) SetCloudResourceContainer(ctx context.Context, v CloudResourceContainer) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cloud_resource_container"] + o.CloudResourceContainer = types.ListValueMust(t, vs) +} + +// GetCustomTags returns the value of the CustomTags field in CreateWorkspaceRequest as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWorkspaceRequest) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in CreateWorkspaceRequest. +func (o *CreateWorkspaceRequest) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + +// GetGcpManagedNetworkConfig returns the value of the GcpManagedNetworkConfig field in CreateWorkspaceRequest as +// a GcpManagedNetworkConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWorkspaceRequest) GetGcpManagedNetworkConfig(ctx context.Context) (GcpManagedNetworkConfig, bool) { + var e GcpManagedNetworkConfig + if o.GcpManagedNetworkConfig.IsNull() || o.GcpManagedNetworkConfig.IsUnknown() { + return e, false + } + var v []GcpManagedNetworkConfig + d := o.GcpManagedNetworkConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpManagedNetworkConfig sets the value of the GcpManagedNetworkConfig field in CreateWorkspaceRequest. +func (o *CreateWorkspaceRequest) SetGcpManagedNetworkConfig(ctx context.Context, v GcpManagedNetworkConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_managed_network_config"] + o.GcpManagedNetworkConfig = types.ListValueMust(t, vs) +} + +// GetGkeConfig returns the value of the GkeConfig field in CreateWorkspaceRequest as +// a GkeConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWorkspaceRequest) GetGkeConfig(ctx context.Context) (GkeConfig, bool) { + var e GkeConfig + if o.GkeConfig.IsNull() || o.GkeConfig.IsUnknown() { + return e, false + } + var v []GkeConfig + d := o.GkeConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGkeConfig sets the value of the GkeConfig field in CreateWorkspaceRequest. +func (o *CreateWorkspaceRequest) SetGkeConfig(ctx context.Context, v GkeConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gke_config"] + o.GkeConfig = types.ListValueMust(t, vs) +} + type Credential struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -953,6 +1392,32 @@ func (o Credential) Type(ctx context.Context) attr.Type { } } +// GetAwsCredentials returns the value of the AwsCredentials field in Credential as +// a AwsCredentials value. +// If the field is unknown or null, the boolean return value is false. +func (o *Credential) GetAwsCredentials(ctx context.Context) (AwsCredentials, bool) { + var e AwsCredentials + if o.AwsCredentials.IsNull() || o.AwsCredentials.IsUnknown() { + return e, false + } + var v []AwsCredentials + d := o.AwsCredentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsCredentials sets the value of the AwsCredentials field in Credential. +func (o *Credential) SetAwsCredentials(ctx context.Context, v AwsCredentials) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_credentials"] + o.AwsCredentials = types.ListValueMust(t, vs) +} + // The general workspace configurations that are specific to Google Cloud. type CustomerFacingGcpCloudResourceContainer struct { // The Google Cloud project ID, which the workspace uses to instantiate @@ -1069,6 +1534,83 @@ func (o CustomerManagedKey) Type(ctx context.Context) attr.Type { } } +// GetAwsKeyInfo returns the value of the AwsKeyInfo field in CustomerManagedKey as +// a AwsKeyInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CustomerManagedKey) GetAwsKeyInfo(ctx context.Context) (AwsKeyInfo, bool) { + var e AwsKeyInfo + if o.AwsKeyInfo.IsNull() || o.AwsKeyInfo.IsUnknown() { + return e, false + } + var v []AwsKeyInfo + d := o.AwsKeyInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsKeyInfo sets the value of the AwsKeyInfo field in CustomerManagedKey. +func (o *CustomerManagedKey) SetAwsKeyInfo(ctx context.Context, v AwsKeyInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_key_info"] + o.AwsKeyInfo = types.ListValueMust(t, vs) +} + +// GetGcpKeyInfo returns the value of the GcpKeyInfo field in CustomerManagedKey as +// a GcpKeyInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CustomerManagedKey) GetGcpKeyInfo(ctx context.Context) (GcpKeyInfo, bool) { + var e GcpKeyInfo + if o.GcpKeyInfo.IsNull() || o.GcpKeyInfo.IsUnknown() { + return e, false + } + var v []GcpKeyInfo + d := o.GcpKeyInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpKeyInfo sets the value of the GcpKeyInfo field in CustomerManagedKey. +func (o *CustomerManagedKey) SetGcpKeyInfo(ctx context.Context, v GcpKeyInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_key_info"] + o.GcpKeyInfo = types.ListValueMust(t, vs) +} + +// GetUseCases returns the value of the UseCases field in CustomerManagedKey as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CustomerManagedKey) GetUseCases(ctx context.Context) ([]types.String, bool) { + if o.UseCases.IsNull() || o.UseCases.IsUnknown() { + return nil, false + } + var v []types.String + d := o.UseCases.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUseCases sets the value of the UseCases field in CustomerManagedKey. +func (o *CustomerManagedKey) SetUseCases(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["use_cases"] + o.UseCases = types.ListValueMust(t, vs) +} + // Delete credential configuration type DeleteCredentialRequest struct { // Databricks Account API credential configuration ID @@ -2179,6 +2721,158 @@ func (o Network) Type(ctx context.Context) attr.Type { } } +// GetErrorMessages returns the value of the ErrorMessages field in Network as +// a slice of NetworkHealth values. +// If the field is unknown or null, the boolean return value is false. +func (o *Network) GetErrorMessages(ctx context.Context) ([]NetworkHealth, bool) { + if o.ErrorMessages.IsNull() || o.ErrorMessages.IsUnknown() { + return nil, false + } + var v []NetworkHealth + d := o.ErrorMessages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetErrorMessages sets the value of the ErrorMessages field in Network. +func (o *Network) SetErrorMessages(ctx context.Context, v []NetworkHealth) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error_messages"] + o.ErrorMessages = types.ListValueMust(t, vs) +} + +// GetGcpNetworkInfo returns the value of the GcpNetworkInfo field in Network as +// a GcpNetworkInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *Network) GetGcpNetworkInfo(ctx context.Context) (GcpNetworkInfo, bool) { + var e GcpNetworkInfo + if o.GcpNetworkInfo.IsNull() || o.GcpNetworkInfo.IsUnknown() { + return e, false + } + var v []GcpNetworkInfo + d := o.GcpNetworkInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpNetworkInfo sets the value of the GcpNetworkInfo field in Network. +func (o *Network) SetGcpNetworkInfo(ctx context.Context, v GcpNetworkInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_network_info"] + o.GcpNetworkInfo = types.ListValueMust(t, vs) +} + +// GetSecurityGroupIds returns the value of the SecurityGroupIds field in Network as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Network) GetSecurityGroupIds(ctx context.Context) ([]types.String, bool) { + if o.SecurityGroupIds.IsNull() || o.SecurityGroupIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SecurityGroupIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSecurityGroupIds sets the value of the SecurityGroupIds field in Network. +func (o *Network) SetSecurityGroupIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["security_group_ids"] + o.SecurityGroupIds = types.ListValueMust(t, vs) +} + +// GetSubnetIds returns the value of the SubnetIds field in Network as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Network) GetSubnetIds(ctx context.Context) ([]types.String, bool) { + if o.SubnetIds.IsNull() || o.SubnetIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.SubnetIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSubnetIds sets the value of the SubnetIds field in Network. +func (o *Network) SetSubnetIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subnet_ids"] + o.SubnetIds = types.ListValueMust(t, vs) +} + +// GetVpcEndpoints returns the value of the VpcEndpoints field in Network as +// a NetworkVpcEndpoints value. +// If the field is unknown or null, the boolean return value is false. +func (o *Network) GetVpcEndpoints(ctx context.Context) (NetworkVpcEndpoints, bool) { + var e NetworkVpcEndpoints + if o.VpcEndpoints.IsNull() || o.VpcEndpoints.IsUnknown() { + return e, false + } + var v []NetworkVpcEndpoints + d := o.VpcEndpoints.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVpcEndpoints sets the value of the VpcEndpoints field in Network. +func (o *Network) SetVpcEndpoints(ctx context.Context, v NetworkVpcEndpoints) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["vpc_endpoints"] + o.VpcEndpoints = types.ListValueMust(t, vs) +} + +// GetWarningMessages returns the value of the WarningMessages field in Network as +// a slice of NetworkWarning values. +// If the field is unknown or null, the boolean return value is false. +func (o *Network) GetWarningMessages(ctx context.Context) ([]NetworkWarning, bool) { + if o.WarningMessages.IsNull() || o.WarningMessages.IsUnknown() { + return nil, false + } + var v []NetworkWarning + d := o.WarningMessages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWarningMessages sets the value of the WarningMessages field in Network. +func (o *Network) SetWarningMessages(ctx context.Context, v []NetworkWarning) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["warning_messages"] + o.WarningMessages = types.ListValueMust(t, vs) +} + type NetworkHealth struct { // Details of the error. ErrorMessage types.String `tfsdk:"error_message" tf:"optional"` @@ -2285,6 +2979,56 @@ func (o NetworkVpcEndpoints) Type(ctx context.Context) attr.Type { } } +// GetDataplaneRelay returns the value of the DataplaneRelay field in NetworkVpcEndpoints as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *NetworkVpcEndpoints) GetDataplaneRelay(ctx context.Context) ([]types.String, bool) { + if o.DataplaneRelay.IsNull() || o.DataplaneRelay.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DataplaneRelay.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDataplaneRelay sets the value of the DataplaneRelay field in NetworkVpcEndpoints. +func (o *NetworkVpcEndpoints) SetDataplaneRelay(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataplane_relay"] + o.DataplaneRelay = types.ListValueMust(t, vs) +} + +// GetRestApi returns the value of the RestApi field in NetworkVpcEndpoints as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *NetworkVpcEndpoints) GetRestApi(ctx context.Context) ([]types.String, bool) { + if o.RestApi.IsNull() || o.RestApi.IsUnknown() { + return nil, false + } + var v []types.String + d := o.RestApi.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRestApi sets the value of the RestApi field in NetworkVpcEndpoints. +func (o *NetworkVpcEndpoints) SetRestApi(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rest_api"] + o.RestApi = types.ListValueMust(t, vs) +} + type NetworkWarning struct { // Details of the warning. WarningMessage types.String `tfsdk:"warning_message" tf:"optional"` @@ -2412,6 +3156,31 @@ func (o PrivateAccessSettings) Type(ctx context.Context) attr.Type { } } +// GetAllowedVpcEndpointIds returns the value of the AllowedVpcEndpointIds field in PrivateAccessSettings as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PrivateAccessSettings) GetAllowedVpcEndpointIds(ctx context.Context) ([]types.String, bool) { + if o.AllowedVpcEndpointIds.IsNull() || o.AllowedVpcEndpointIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.AllowedVpcEndpointIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllowedVpcEndpointIds sets the value of the AllowedVpcEndpointIds field in PrivateAccessSettings. +func (o *PrivateAccessSettings) SetAllowedVpcEndpointIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["allowed_vpc_endpoint_ids"] + o.AllowedVpcEndpointIds = types.ListValueMust(t, vs) +} + type ReplaceResponse struct { } @@ -2553,6 +3322,32 @@ func (o StorageConfiguration) Type(ctx context.Context) attr.Type { } } +// GetRootBucketInfo returns the value of the RootBucketInfo field in StorageConfiguration as +// a RootBucketInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *StorageConfiguration) GetRootBucketInfo(ctx context.Context) (RootBucketInfo, bool) { + var e RootBucketInfo + if o.RootBucketInfo.IsNull() || o.RootBucketInfo.IsUnknown() { + return e, false + } + var v []RootBucketInfo + d := o.RootBucketInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRootBucketInfo sets the value of the RootBucketInfo field in StorageConfiguration. +func (o *StorageConfiguration) SetRootBucketInfo(ctx context.Context, v RootBucketInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["root_bucket_info"] + o.RootBucketInfo = types.ListValueMust(t, vs) +} + type StsRole struct { // The external ID that needs to be trusted by the cross-account role. This // is always your Databricks account ID. @@ -2730,6 +3525,31 @@ func (o UpdateWorkspaceRequest) Type(ctx context.Context) attr.Type { } } +// GetCustomTags returns the value of the CustomTags field in UpdateWorkspaceRequest as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateWorkspaceRequest) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in UpdateWorkspaceRequest. +func (o *UpdateWorkspaceRequest) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} + type UpsertPrivateAccessSettingsRequest struct { // An array of Databricks VPC endpoint IDs. This is the Databricks ID that // is returned when registering the VPC endpoint configuration in your @@ -2819,6 +3639,31 @@ func (o UpsertPrivateAccessSettingsRequest) Type(ctx context.Context) attr.Type } } +// GetAllowedVpcEndpointIds returns the value of the AllowedVpcEndpointIds field in UpsertPrivateAccessSettingsRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpsertPrivateAccessSettingsRequest) GetAllowedVpcEndpointIds(ctx context.Context) ([]types.String, bool) { + if o.AllowedVpcEndpointIds.IsNull() || o.AllowedVpcEndpointIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.AllowedVpcEndpointIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllowedVpcEndpointIds sets the value of the AllowedVpcEndpointIds field in UpsertPrivateAccessSettingsRequest. +func (o *UpsertPrivateAccessSettingsRequest) SetAllowedVpcEndpointIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["allowed_vpc_endpoint_ids"] + o.AllowedVpcEndpointIds = types.ListValueMust(t, vs) +} + type VpcEndpoint struct { // The Databricks account ID that hosts the VPC endpoint configuration. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -2916,6 +3761,32 @@ func (o VpcEndpoint) Type(ctx context.Context) attr.Type { } } +// GetGcpVpcEndpointInfo returns the value of the GcpVpcEndpointInfo field in VpcEndpoint as +// a GcpVpcEndpointInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *VpcEndpoint) GetGcpVpcEndpointInfo(ctx context.Context) (GcpVpcEndpointInfo, bool) { + var e GcpVpcEndpointInfo + if o.GcpVpcEndpointInfo.IsNull() || o.GcpVpcEndpointInfo.IsUnknown() { + return e, false + } + var v []GcpVpcEndpointInfo + d := o.GcpVpcEndpointInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGcpVpcEndpointInfo sets the value of the GcpVpcEndpointInfo field in VpcEndpoint. +func (o *VpcEndpoint) SetGcpVpcEndpointInfo(ctx context.Context, v GcpVpcEndpointInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_vpc_endpoint_info"] + o.GcpVpcEndpointInfo = types.ListValueMust(t, vs) +} + type Workspace struct { // Databricks account ID. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -3118,45 +3989,157 @@ func (o Workspace) Type(ctx context.Context) attr.Type { } } -// This enumeration represents the type of Databricks VPC [endpoint service] -// that was used when creating this VPC endpoint. -// -// [endpoint service]: https://docs.aws.amazon.com/vpc/latest/privatelink/endpoint-service.html +// GetAzureWorkspaceInfo returns the value of the AzureWorkspaceInfo field in Workspace as +// a AzureWorkspaceInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *Workspace) GetAzureWorkspaceInfo(ctx context.Context) (AzureWorkspaceInfo, bool) { + var e AzureWorkspaceInfo + if o.AzureWorkspaceInfo.IsNull() || o.AzureWorkspaceInfo.IsUnknown() { + return e, false + } + var v []AzureWorkspaceInfo + d := o.AzureWorkspaceInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// The AWS resource associated with this error: credentials, VPC, subnet, -// security group, or network ACL. +// SetAzureWorkspaceInfo sets the value of the AzureWorkspaceInfo field in Workspace. +func (o *Workspace) SetAzureWorkspaceInfo(ctx context.Context, v AzureWorkspaceInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_workspace_info"] + o.AzureWorkspaceInfo = types.ListValueMust(t, vs) +} -// Specifies the network connectivity types for the GKE nodes and the GKE master -// network. -// -// Set to `PRIVATE_NODE_PUBLIC_MASTER` for a private GKE cluster for the -// workspace. The GKE nodes will not have public IPs. -// -// Set to `PUBLIC_NODE_PUBLIC_MASTER` for a public GKE cluster. The nodes of a -// public GKE cluster have public IP addresses. +// GetCloudResourceContainer returns the value of the CloudResourceContainer field in Workspace as +// a CloudResourceContainer value. +// If the field is unknown or null, the boolean return value is false. +func (o *Workspace) GetCloudResourceContainer(ctx context.Context) (CloudResourceContainer, bool) { + var e CloudResourceContainer + if o.CloudResourceContainer.IsNull() || o.CloudResourceContainer.IsUnknown() { + return e, false + } + var v []CloudResourceContainer + d := o.CloudResourceContainer.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// Possible values are: * `MANAGED_SERVICES`: Encrypts notebook and secret data -// in the control plane * `STORAGE`: Encrypts the workspace's root S3 bucket -// (root DBFS and system data) and, optionally, cluster EBS volumes. +// SetCloudResourceContainer sets the value of the CloudResourceContainer field in Workspace. +func (o *Workspace) SetCloudResourceContainer(ctx context.Context, v CloudResourceContainer) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cloud_resource_container"] + o.CloudResourceContainer = types.ListValueMust(t, vs) +} -// The pricing tier of the workspace. For pricing tier information, see [AWS -// Pricing]. -// -// [AWS Pricing]: https://databricks.com/product/aws-pricing +// GetCustomTags returns the value of the CustomTags field in Workspace as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Workspace) GetCustomTags(ctx context.Context) (map[string]types.String, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in Workspace. +func (o *Workspace) SetCustomTags(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.MapValueMust(t, vs) +} -// The private access level controls which VPC endpoints can connect to the UI -// or API of any workspace that attaches this private access settings object. * -// `ACCOUNT` level access (the default) allows only VPC endpoints that are -// registered in your Databricks account connect to your workspace. * `ENDPOINT` -// level access allows only specified VPC endpoints connect to your workspace. -// For details, see `allowed_vpc_endpoint_ids`. +// GetExternalCustomerInfo returns the value of the ExternalCustomerInfo field in Workspace as +// a ExternalCustomerInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *Workspace) GetExternalCustomerInfo(ctx context.Context) (ExternalCustomerInfo, bool) { + var e ExternalCustomerInfo + if o.ExternalCustomerInfo.IsNull() || o.ExternalCustomerInfo.IsUnknown() { + return e, false + } + var v []ExternalCustomerInfo + d := o.ExternalCustomerInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// The status of this network configuration object in terms of its use in a -// workspace: * `UNATTACHED`: Unattached. * `VALID`: Valid. * `BROKEN`: Broken. -// * `WARNED`: Warned. +// SetExternalCustomerInfo sets the value of the ExternalCustomerInfo field in Workspace. +func (o *Workspace) SetExternalCustomerInfo(ctx context.Context, v ExternalCustomerInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_customer_info"] + o.ExternalCustomerInfo = types.ListValueMust(t, vs) +} -// The AWS resource associated with this warning: a subnet or a security group. +// GetGcpManagedNetworkConfig returns the value of the GcpManagedNetworkConfig field in Workspace as +// a GcpManagedNetworkConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Workspace) GetGcpManagedNetworkConfig(ctx context.Context) (GcpManagedNetworkConfig, bool) { + var e GcpManagedNetworkConfig + if o.GcpManagedNetworkConfig.IsNull() || o.GcpManagedNetworkConfig.IsUnknown() { + return e, false + } + var v []GcpManagedNetworkConfig + d := o.GcpManagedNetworkConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// The status of the workspace. For workspace creation, usually it is set to -// `PROVISIONING` initially. Continue to check the status until the status is -// `RUNNING`. +// SetGcpManagedNetworkConfig sets the value of the GcpManagedNetworkConfig field in Workspace. +func (o *Workspace) SetGcpManagedNetworkConfig(ctx context.Context, v GcpManagedNetworkConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gcp_managed_network_config"] + o.GcpManagedNetworkConfig = types.ListValueMust(t, vs) +} + +// GetGkeConfig returns the value of the GkeConfig field in Workspace as +// a GkeConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Workspace) GetGkeConfig(ctx context.Context) (GkeConfig, bool) { + var e GkeConfig + if o.GkeConfig.IsNull() || o.GkeConfig.IsUnknown() { + return e, false + } + var v []GkeConfig + d := o.GkeConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGkeConfig sets the value of the GkeConfig field in Workspace. +func (o *Workspace) SetGkeConfig(ctx context.Context, v GkeConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["gke_config"] + o.GkeConfig = types.ListValueMust(t, vs) +} diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 7c5fde1d35..c22de9e2a8 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -14,7 +14,7 @@ import ( "context" "reflect" - "github.com/databricks/databricks-sdk-go/service/oauth2" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/oauth2_tf" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" @@ -145,6 +145,109 @@ func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { } } +// GetGuardrails returns the value of the Guardrails field in AiGatewayConfig as +// a AiGatewayGuardrails value. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayConfig) GetGuardrails(ctx context.Context) (AiGatewayGuardrails, bool) { + var e AiGatewayGuardrails + if o.Guardrails.IsNull() || o.Guardrails.IsUnknown() { + return e, false + } + var v []AiGatewayGuardrails + d := o.Guardrails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGuardrails sets the value of the Guardrails field in AiGatewayConfig. +func (o *AiGatewayConfig) SetGuardrails(ctx context.Context, v AiGatewayGuardrails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["guardrails"] + o.Guardrails = types.ListValueMust(t, vs) +} + +// GetInferenceTableConfig returns the value of the InferenceTableConfig field in AiGatewayConfig as +// a AiGatewayInferenceTableConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayConfig) GetInferenceTableConfig(ctx context.Context) (AiGatewayInferenceTableConfig, bool) { + var e AiGatewayInferenceTableConfig + if o.InferenceTableConfig.IsNull() || o.InferenceTableConfig.IsUnknown() { + return e, false + } + var v []AiGatewayInferenceTableConfig + d := o.InferenceTableConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInferenceTableConfig sets the value of the InferenceTableConfig field in AiGatewayConfig. +func (o *AiGatewayConfig) SetInferenceTableConfig(ctx context.Context, v AiGatewayInferenceTableConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inference_table_config"] + o.InferenceTableConfig = types.ListValueMust(t, vs) +} + +// GetRateLimits returns the value of the RateLimits field in AiGatewayConfig as +// a slice of AiGatewayRateLimit values. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayConfig) GetRateLimits(ctx context.Context) ([]AiGatewayRateLimit, bool) { + if o.RateLimits.IsNull() || o.RateLimits.IsUnknown() { + return nil, false + } + var v []AiGatewayRateLimit + d := o.RateLimits.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRateLimits sets the value of the RateLimits field in AiGatewayConfig. +func (o *AiGatewayConfig) SetRateLimits(ctx context.Context, v []AiGatewayRateLimit) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + o.RateLimits = types.ListValueMust(t, vs) +} + +// GetUsageTrackingConfig returns the value of the UsageTrackingConfig field in AiGatewayConfig as +// a AiGatewayUsageTrackingConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayConfig) GetUsageTrackingConfig(ctx context.Context) (AiGatewayUsageTrackingConfig, bool) { + var e AiGatewayUsageTrackingConfig + if o.UsageTrackingConfig.IsNull() || o.UsageTrackingConfig.IsUnknown() { + return e, false + } + var v []AiGatewayUsageTrackingConfig + d := o.UsageTrackingConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUsageTrackingConfig sets the value of the UsageTrackingConfig field in AiGatewayConfig. +func (o *AiGatewayConfig) SetUsageTrackingConfig(ctx context.Context, v AiGatewayUsageTrackingConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["usage_tracking_config"] + o.UsageTrackingConfig = types.ListValueMust(t, vs) +} + type AiGatewayGuardrailParameters struct { // List of invalid keywords. AI guardrail uses keyword or string matching to // decide if the keyword exists in the request or response content. @@ -211,6 +314,82 @@ func (o AiGatewayGuardrailParameters) Type(ctx context.Context) attr.Type { } } +// GetInvalidKeywords returns the value of the InvalidKeywords field in AiGatewayGuardrailParameters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayGuardrailParameters) GetInvalidKeywords(ctx context.Context) ([]types.String, bool) { + if o.InvalidKeywords.IsNull() || o.InvalidKeywords.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InvalidKeywords.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInvalidKeywords sets the value of the InvalidKeywords field in AiGatewayGuardrailParameters. +func (o *AiGatewayGuardrailParameters) SetInvalidKeywords(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["invalid_keywords"] + o.InvalidKeywords = types.ListValueMust(t, vs) +} + +// GetPii returns the value of the Pii field in AiGatewayGuardrailParameters as +// a AiGatewayGuardrailPiiBehavior value. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayGuardrailParameters) GetPii(ctx context.Context) (AiGatewayGuardrailPiiBehavior, bool) { + var e AiGatewayGuardrailPiiBehavior + if o.Pii.IsNull() || o.Pii.IsUnknown() { + return e, false + } + var v []AiGatewayGuardrailPiiBehavior + d := o.Pii.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPii sets the value of the Pii field in AiGatewayGuardrailParameters. +func (o *AiGatewayGuardrailParameters) SetPii(ctx context.Context, v AiGatewayGuardrailPiiBehavior) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pii"] + o.Pii = types.ListValueMust(t, vs) +} + +// GetValidTopics returns the value of the ValidTopics field in AiGatewayGuardrailParameters as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayGuardrailParameters) GetValidTopics(ctx context.Context) ([]types.String, bool) { + if o.ValidTopics.IsNull() || o.ValidTopics.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ValidTopics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValidTopics sets the value of the ValidTopics field in AiGatewayGuardrailParameters. +func (o *AiGatewayGuardrailParameters) SetValidTopics(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["valid_topics"] + o.ValidTopics = types.ListValueMust(t, vs) +} + type AiGatewayGuardrailPiiBehavior struct { // Behavior for PII filter. Currently only 'BLOCK' is supported. If 'BLOCK' // is set for the input guardrail and the request contains PII, the request @@ -311,6 +490,58 @@ func (o AiGatewayGuardrails) Type(ctx context.Context) attr.Type { } } +// GetInput returns the value of the Input field in AiGatewayGuardrails as +// a AiGatewayGuardrailParameters value. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayGuardrails) GetInput(ctx context.Context) (AiGatewayGuardrailParameters, bool) { + var e AiGatewayGuardrailParameters + if o.Input.IsNull() || o.Input.IsUnknown() { + return e, false + } + var v []AiGatewayGuardrailParameters + d := o.Input.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInput sets the value of the Input field in AiGatewayGuardrails. +func (o *AiGatewayGuardrails) SetInput(ctx context.Context, v AiGatewayGuardrailParameters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input"] + o.Input = types.ListValueMust(t, vs) +} + +// GetOutput returns the value of the Output field in AiGatewayGuardrails as +// a AiGatewayGuardrailParameters value. +// If the field is unknown or null, the boolean return value is false. +func (o *AiGatewayGuardrails) GetOutput(ctx context.Context) (AiGatewayGuardrailParameters, bool) { + var e AiGatewayGuardrailParameters + if o.Output.IsNull() || o.Output.IsUnknown() { + return e, false + } + var v []AiGatewayGuardrailParameters + d := o.Output.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOutput sets the value of the Output field in AiGatewayGuardrails. +func (o *AiGatewayGuardrails) SetOutput(ctx context.Context, v AiGatewayGuardrailParameters) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["output"] + o.Output = types.ListValueMust(t, vs) +} + type AiGatewayInferenceTableConfig struct { // The name of the catalog in Unity Catalog. Required when enabling // inference tables. NOTE: On update, you have to disable inference table @@ -717,6 +948,32 @@ func (o AutoCaptureConfigOutput) Type(ctx context.Context) attr.Type { } } +// GetState returns the value of the State field in AutoCaptureConfigOutput as +// a AutoCaptureState value. +// If the field is unknown or null, the boolean return value is false. +func (o *AutoCaptureConfigOutput) GetState(ctx context.Context) (AutoCaptureState, bool) { + var e AutoCaptureState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []AutoCaptureState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in AutoCaptureConfigOutput. +func (o *AutoCaptureConfigOutput) SetState(ctx context.Context, v AutoCaptureState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + type AutoCaptureState struct { PayloadTable types.List `tfsdk:"payload_table" tf:"optional,object"` } @@ -762,6 +1019,32 @@ func (o AutoCaptureState) Type(ctx context.Context) attr.Type { } } +// GetPayloadTable returns the value of the PayloadTable field in AutoCaptureState as +// a PayloadTable value. +// If the field is unknown or null, the boolean return value is false. +func (o *AutoCaptureState) GetPayloadTable(ctx context.Context) (PayloadTable, bool) { + var e PayloadTable + if o.PayloadTable.IsNull() || o.PayloadTable.IsUnknown() { + return e, false + } + var v []PayloadTable + d := o.PayloadTable.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPayloadTable sets the value of the PayloadTable field in AutoCaptureState. +func (o *AutoCaptureState) SetPayloadTable(ctx context.Context, v PayloadTable) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["payload_table"] + o.PayloadTable = types.ListValueMust(t, vs) +} + // Get build logs for a served model type BuildLogsRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -1036,6 +1319,108 @@ func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { } } +// GetAiGateway returns the value of the AiGateway field in CreateServingEndpoint as +// a AiGatewayConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateServingEndpoint) GetAiGateway(ctx context.Context) (AiGatewayConfig, bool) { + var e AiGatewayConfig + if o.AiGateway.IsNull() || o.AiGateway.IsUnknown() { + return e, false + } + var v []AiGatewayConfig + d := o.AiGateway.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAiGateway sets the value of the AiGateway field in CreateServingEndpoint. +func (o *CreateServingEndpoint) SetAiGateway(ctx context.Context, v AiGatewayConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ai_gateway"] + o.AiGateway = types.ListValueMust(t, vs) +} + +// GetConfig returns the value of the Config field in CreateServingEndpoint as +// a EndpointCoreConfigInput value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateServingEndpoint) GetConfig(ctx context.Context) (EndpointCoreConfigInput, bool) { + var e EndpointCoreConfigInput + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []EndpointCoreConfigInput + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in CreateServingEndpoint. +func (o *CreateServingEndpoint) SetConfig(ctx context.Context, v EndpointCoreConfigInput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + +// GetRateLimits returns the value of the RateLimits field in CreateServingEndpoint as +// a slice of RateLimit values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateServingEndpoint) GetRateLimits(ctx context.Context) ([]RateLimit, bool) { + if o.RateLimits.IsNull() || o.RateLimits.IsUnknown() { + return nil, false + } + var v []RateLimit + d := o.RateLimits.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRateLimits sets the value of the RateLimits field in CreateServingEndpoint. +func (o *CreateServingEndpoint) SetRateLimits(ctx context.Context, v []RateLimit) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + o.RateLimits = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in CreateServingEndpoint as +// a slice of EndpointTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateServingEndpoint) GetTags(ctx context.Context) ([]EndpointTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []EndpointTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateServingEndpoint. +func (o *CreateServingEndpoint) SetTags(ctx context.Context, v []EndpointTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type DatabricksModelServingConfig struct { // The Databricks secret key reference for a Databricks API token that // corresponds to a user or service principal with Can Query access to the @@ -1156,6 +1541,81 @@ func (o DataframeSplitInput) Type(ctx context.Context) attr.Type { } } +// GetColumns returns the value of the Columns field in DataframeSplitInput as +// a slice of types.Object values. +// If the field is unknown or null, the boolean return value is false. +func (o *DataframeSplitInput) GetColumns(ctx context.Context) ([]types.Object, bool) { + if o.Columns.IsNull() || o.Columns.IsUnknown() { + return nil, false + } + var v []types.Object + d := o.Columns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetColumns sets the value of the Columns field in DataframeSplitInput. +func (o *DataframeSplitInput) SetColumns(ctx context.Context, v []types.Object) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + o.Columns = types.ListValueMust(t, vs) +} + +// GetData returns the value of the Data field in DataframeSplitInput as +// a slice of types.Object values. +// If the field is unknown or null, the boolean return value is false. +func (o *DataframeSplitInput) GetData(ctx context.Context) ([]types.Object, bool) { + if o.Data.IsNull() || o.Data.IsUnknown() { + return nil, false + } + var v []types.Object + d := o.Data.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetData sets the value of the Data field in DataframeSplitInput. +func (o *DataframeSplitInput) SetData(ctx context.Context, v []types.Object) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + o.Data = types.ListValueMust(t, vs) +} + +// GetIndex returns the value of the Index field in DataframeSplitInput as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *DataframeSplitInput) GetIndex(ctx context.Context) ([]types.Int64, bool) { + if o.Index.IsNull() || o.Index.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.Index.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIndex sets the value of the Index field in DataframeSplitInput. +func (o *DataframeSplitInput) SetIndex(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["index"] + o.Index = types.ListValueMust(t, vs) +} + type DeleteResponse struct { } @@ -1288,6 +1748,31 @@ func (o EmbeddingsV1ResponseEmbeddingElement) Type(ctx context.Context) attr.Typ } } +// GetEmbedding returns the value of the Embedding field in EmbeddingsV1ResponseEmbeddingElement as +// a slice of types.Float64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *EmbeddingsV1ResponseEmbeddingElement) GetEmbedding(ctx context.Context) ([]types.Float64, bool) { + if o.Embedding.IsNull() || o.Embedding.IsUnknown() { + return nil, false + } + var v []types.Float64 + d := o.Embedding.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbedding sets the value of the Embedding field in EmbeddingsV1ResponseEmbeddingElement. +func (o *EmbeddingsV1ResponseEmbeddingElement) SetEmbedding(ctx context.Context, v []types.Float64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding"] + o.Embedding = types.ListValueMust(t, vs) +} + type EndpointCoreConfigInput struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. @@ -1363,6 +1848,108 @@ func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { } } +// GetAutoCaptureConfig returns the value of the AutoCaptureConfig field in EndpointCoreConfigInput as +// a AutoCaptureConfigInput value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigInput) GetAutoCaptureConfig(ctx context.Context) (AutoCaptureConfigInput, bool) { + var e AutoCaptureConfigInput + if o.AutoCaptureConfig.IsNull() || o.AutoCaptureConfig.IsUnknown() { + return e, false + } + var v []AutoCaptureConfigInput + d := o.AutoCaptureConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoCaptureConfig sets the value of the AutoCaptureConfig field in EndpointCoreConfigInput. +func (o *EndpointCoreConfigInput) SetAutoCaptureConfig(ctx context.Context, v AutoCaptureConfigInput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["auto_capture_config"] + o.AutoCaptureConfig = types.ListValueMust(t, vs) +} + +// GetServedEntities returns the value of the ServedEntities field in EndpointCoreConfigInput as +// a slice of ServedEntityInput values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigInput) GetServedEntities(ctx context.Context) ([]ServedEntityInput, bool) { + if o.ServedEntities.IsNull() || o.ServedEntities.IsUnknown() { + return nil, false + } + var v []ServedEntityInput + d := o.ServedEntities.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedEntities sets the value of the ServedEntities field in EndpointCoreConfigInput. +func (o *EndpointCoreConfigInput) SetServedEntities(ctx context.Context, v []ServedEntityInput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + o.ServedEntities = types.ListValueMust(t, vs) +} + +// GetServedModels returns the value of the ServedModels field in EndpointCoreConfigInput as +// a slice of ServedModelInput values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigInput) GetServedModels(ctx context.Context) ([]ServedModelInput, bool) { + if o.ServedModels.IsNull() || o.ServedModels.IsUnknown() { + return nil, false + } + var v []ServedModelInput + d := o.ServedModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedModels sets the value of the ServedModels field in EndpointCoreConfigInput. +func (o *EndpointCoreConfigInput) SetServedModels(ctx context.Context, v []ServedModelInput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + o.ServedModels = types.ListValueMust(t, vs) +} + +// GetTrafficConfig returns the value of the TrafficConfig field in EndpointCoreConfigInput as +// a TrafficConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigInput) GetTrafficConfig(ctx context.Context) (TrafficConfig, bool) { + var e TrafficConfig + if o.TrafficConfig.IsNull() || o.TrafficConfig.IsUnknown() { + return e, false + } + var v []TrafficConfig + d := o.TrafficConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrafficConfig sets the value of the TrafficConfig field in EndpointCoreConfigInput. +func (o *EndpointCoreConfigInput) SetTrafficConfig(ctx context.Context, v TrafficConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["traffic_config"] + o.TrafficConfig = types.ListValueMust(t, vs) +} + type EndpointCoreConfigOutput struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. @@ -1436,6 +2023,108 @@ func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { } } +// GetAutoCaptureConfig returns the value of the AutoCaptureConfig field in EndpointCoreConfigOutput as +// a AutoCaptureConfigOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigOutput) GetAutoCaptureConfig(ctx context.Context) (AutoCaptureConfigOutput, bool) { + var e AutoCaptureConfigOutput + if o.AutoCaptureConfig.IsNull() || o.AutoCaptureConfig.IsUnknown() { + return e, false + } + var v []AutoCaptureConfigOutput + d := o.AutoCaptureConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoCaptureConfig sets the value of the AutoCaptureConfig field in EndpointCoreConfigOutput. +func (o *EndpointCoreConfigOutput) SetAutoCaptureConfig(ctx context.Context, v AutoCaptureConfigOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["auto_capture_config"] + o.AutoCaptureConfig = types.ListValueMust(t, vs) +} + +// GetServedEntities returns the value of the ServedEntities field in EndpointCoreConfigOutput as +// a slice of ServedEntityOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigOutput) GetServedEntities(ctx context.Context) ([]ServedEntityOutput, bool) { + if o.ServedEntities.IsNull() || o.ServedEntities.IsUnknown() { + return nil, false + } + var v []ServedEntityOutput + d := o.ServedEntities.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedEntities sets the value of the ServedEntities field in EndpointCoreConfigOutput. +func (o *EndpointCoreConfigOutput) SetServedEntities(ctx context.Context, v []ServedEntityOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + o.ServedEntities = types.ListValueMust(t, vs) +} + +// GetServedModels returns the value of the ServedModels field in EndpointCoreConfigOutput as +// a slice of ServedModelOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigOutput) GetServedModels(ctx context.Context) ([]ServedModelOutput, bool) { + if o.ServedModels.IsNull() || o.ServedModels.IsUnknown() { + return nil, false + } + var v []ServedModelOutput + d := o.ServedModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedModels sets the value of the ServedModels field in EndpointCoreConfigOutput. +func (o *EndpointCoreConfigOutput) SetServedModels(ctx context.Context, v []ServedModelOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + o.ServedModels = types.ListValueMust(t, vs) +} + +// GetTrafficConfig returns the value of the TrafficConfig field in EndpointCoreConfigOutput as +// a TrafficConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigOutput) GetTrafficConfig(ctx context.Context) (TrafficConfig, bool) { + var e TrafficConfig + if o.TrafficConfig.IsNull() || o.TrafficConfig.IsUnknown() { + return e, false + } + var v []TrafficConfig + d := o.TrafficConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrafficConfig sets the value of the TrafficConfig field in EndpointCoreConfigOutput. +func (o *EndpointCoreConfigOutput) SetTrafficConfig(ctx context.Context, v TrafficConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["traffic_config"] + o.TrafficConfig = types.ListValueMust(t, vs) +} + type EndpointCoreConfigSummary struct { // The list of served entities under the serving endpoint config. ServedEntities types.List `tfsdk:"served_entities" tf:"optional"` @@ -1490,6 +2179,56 @@ func (o EndpointCoreConfigSummary) Type(ctx context.Context) attr.Type { } } +// GetServedEntities returns the value of the ServedEntities field in EndpointCoreConfigSummary as +// a slice of ServedEntitySpec values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigSummary) GetServedEntities(ctx context.Context) ([]ServedEntitySpec, bool) { + if o.ServedEntities.IsNull() || o.ServedEntities.IsUnknown() { + return nil, false + } + var v []ServedEntitySpec + d := o.ServedEntities.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedEntities sets the value of the ServedEntities field in EndpointCoreConfigSummary. +func (o *EndpointCoreConfigSummary) SetServedEntities(ctx context.Context, v []ServedEntitySpec) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + o.ServedEntities = types.ListValueMust(t, vs) +} + +// GetServedModels returns the value of the ServedModels field in EndpointCoreConfigSummary as +// a slice of ServedModelSpec values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointCoreConfigSummary) GetServedModels(ctx context.Context) ([]ServedModelSpec, bool) { + if o.ServedModels.IsNull() || o.ServedModels.IsUnknown() { + return nil, false + } + var v []ServedModelSpec + d := o.ServedModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedModels sets the value of the ServedModels field in EndpointCoreConfigSummary. +func (o *EndpointCoreConfigSummary) SetServedModels(ctx context.Context, v []ServedModelSpec) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + o.ServedModels = types.ListValueMust(t, vs) +} + type EndpointPendingConfig struct { // Configuration for Inference Tables which automatically logs requests and // responses to Unity Catalog. @@ -1569,6 +2308,108 @@ func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { } } +// GetAutoCaptureConfig returns the value of the AutoCaptureConfig field in EndpointPendingConfig as +// a AutoCaptureConfigOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointPendingConfig) GetAutoCaptureConfig(ctx context.Context) (AutoCaptureConfigOutput, bool) { + var e AutoCaptureConfigOutput + if o.AutoCaptureConfig.IsNull() || o.AutoCaptureConfig.IsUnknown() { + return e, false + } + var v []AutoCaptureConfigOutput + d := o.AutoCaptureConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutoCaptureConfig sets the value of the AutoCaptureConfig field in EndpointPendingConfig. +func (o *EndpointPendingConfig) SetAutoCaptureConfig(ctx context.Context, v AutoCaptureConfigOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["auto_capture_config"] + o.AutoCaptureConfig = types.ListValueMust(t, vs) +} + +// GetServedEntities returns the value of the ServedEntities field in EndpointPendingConfig as +// a slice of ServedEntityOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointPendingConfig) GetServedEntities(ctx context.Context) ([]ServedEntityOutput, bool) { + if o.ServedEntities.IsNull() || o.ServedEntities.IsUnknown() { + return nil, false + } + var v []ServedEntityOutput + d := o.ServedEntities.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedEntities sets the value of the ServedEntities field in EndpointPendingConfig. +func (o *EndpointPendingConfig) SetServedEntities(ctx context.Context, v []ServedEntityOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + o.ServedEntities = types.ListValueMust(t, vs) +} + +// GetServedModels returns the value of the ServedModels field in EndpointPendingConfig as +// a slice of ServedModelOutput values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointPendingConfig) GetServedModels(ctx context.Context) ([]ServedModelOutput, bool) { + if o.ServedModels.IsNull() || o.ServedModels.IsUnknown() { + return nil, false + } + var v []ServedModelOutput + d := o.ServedModels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetServedModels sets the value of the ServedModels field in EndpointPendingConfig. +func (o *EndpointPendingConfig) SetServedModels(ctx context.Context, v []ServedModelOutput) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + o.ServedModels = types.ListValueMust(t, vs) +} + +// GetTrafficConfig returns the value of the TrafficConfig field in EndpointPendingConfig as +// a TrafficConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointPendingConfig) GetTrafficConfig(ctx context.Context) (TrafficConfig, bool) { + var e TrafficConfig + if o.TrafficConfig.IsNull() || o.TrafficConfig.IsUnknown() { + return e, false + } + var v []TrafficConfig + d := o.TrafficConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTrafficConfig sets the value of the TrafficConfig field in EndpointPendingConfig. +func (o *EndpointPendingConfig) SetTrafficConfig(ctx context.Context, v TrafficConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["traffic_config"] + o.TrafficConfig = types.ListValueMust(t, vs) +} + type EndpointState struct { // The state of an endpoint's config update. This informs the user if the // pending_config is in progress, if the update failed, or if there is no @@ -1865,33 +2706,241 @@ func (o ExternalModel) Type(ctx context.Context) attr.Type { } } -type ExternalModelUsageElement struct { - // The number of tokens in the chat/completions response. - CompletionTokens types.Int64 `tfsdk:"completion_tokens" tf:"optional"` - // The number of tokens in the prompt. - PromptTokens types.Int64 `tfsdk:"prompt_tokens" tf:"optional"` - // The total number of tokens in the prompt and response. - TotalTokens types.Int64 `tfsdk:"total_tokens" tf:"optional"` +// GetAi21labsConfig returns the value of the Ai21labsConfig field in ExternalModel as +// a Ai21LabsConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetAi21labsConfig(ctx context.Context) (Ai21LabsConfig, bool) { + var e Ai21LabsConfig + if o.Ai21labsConfig.IsNull() || o.Ai21labsConfig.IsUnknown() { + return e, false + } + var v []Ai21LabsConfig + d := o.Ai21labsConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringCreateOrUpdate(plan ExternalModelUsageElement) { +// SetAi21labsConfig sets the value of the Ai21labsConfig field in ExternalModel. +func (o *ExternalModel) SetAi21labsConfig(ctx context.Context, v Ai21LabsConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ai21labs_config"] + o.Ai21labsConfig = types.ListValueMust(t, vs) } -func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringRead(existingState ExternalModelUsageElement) { +// GetAmazonBedrockConfig returns the value of the AmazonBedrockConfig field in ExternalModel as +// a AmazonBedrockConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetAmazonBedrockConfig(ctx context.Context) (AmazonBedrockConfig, bool) { + var e AmazonBedrockConfig + if o.AmazonBedrockConfig.IsNull() || o.AmazonBedrockConfig.IsUnknown() { + return e, false + } + var v []AmazonBedrockConfig + d := o.AmazonBedrockConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true } -// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalModelUsageElement. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{} +// SetAmazonBedrockConfig sets the value of the AmazonBedrockConfig field in ExternalModel. +func (o *ExternalModel) SetAmazonBedrockConfig(ctx context.Context, v AmazonBedrockConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["amazon_bedrock_config"] + o.AmazonBedrockConfig = types.ListValueMust(t, vs) } -// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise +// GetAnthropicConfig returns the value of the AnthropicConfig field in ExternalModel as +// a AnthropicConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetAnthropicConfig(ctx context.Context) (AnthropicConfig, bool) { + var e AnthropicConfig + if o.AnthropicConfig.IsNull() || o.AnthropicConfig.IsUnknown() { + return e, false + } + var v []AnthropicConfig + d := o.AnthropicConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAnthropicConfig sets the value of the AnthropicConfig field in ExternalModel. +func (o *ExternalModel) SetAnthropicConfig(ctx context.Context, v AnthropicConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["anthropic_config"] + o.AnthropicConfig = types.ListValueMust(t, vs) +} + +// GetCohereConfig returns the value of the CohereConfig field in ExternalModel as +// a CohereConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetCohereConfig(ctx context.Context) (CohereConfig, bool) { + var e CohereConfig + if o.CohereConfig.IsNull() || o.CohereConfig.IsUnknown() { + return e, false + } + var v []CohereConfig + d := o.CohereConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCohereConfig sets the value of the CohereConfig field in ExternalModel. +func (o *ExternalModel) SetCohereConfig(ctx context.Context, v CohereConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cohere_config"] + o.CohereConfig = types.ListValueMust(t, vs) +} + +// GetDatabricksModelServingConfig returns the value of the DatabricksModelServingConfig field in ExternalModel as +// a DatabricksModelServingConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetDatabricksModelServingConfig(ctx context.Context) (DatabricksModelServingConfig, bool) { + var e DatabricksModelServingConfig + if o.DatabricksModelServingConfig.IsNull() || o.DatabricksModelServingConfig.IsUnknown() { + return e, false + } + var v []DatabricksModelServingConfig + d := o.DatabricksModelServingConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDatabricksModelServingConfig sets the value of the DatabricksModelServingConfig field in ExternalModel. +func (o *ExternalModel) SetDatabricksModelServingConfig(ctx context.Context, v DatabricksModelServingConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["databricks_model_serving_config"] + o.DatabricksModelServingConfig = types.ListValueMust(t, vs) +} + +// GetGoogleCloudVertexAiConfig returns the value of the GoogleCloudVertexAiConfig field in ExternalModel as +// a GoogleCloudVertexAiConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetGoogleCloudVertexAiConfig(ctx context.Context) (GoogleCloudVertexAiConfig, bool) { + var e GoogleCloudVertexAiConfig + if o.GoogleCloudVertexAiConfig.IsNull() || o.GoogleCloudVertexAiConfig.IsUnknown() { + return e, false + } + var v []GoogleCloudVertexAiConfig + d := o.GoogleCloudVertexAiConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGoogleCloudVertexAiConfig sets the value of the GoogleCloudVertexAiConfig field in ExternalModel. +func (o *ExternalModel) SetGoogleCloudVertexAiConfig(ctx context.Context, v GoogleCloudVertexAiConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["google_cloud_vertex_ai_config"] + o.GoogleCloudVertexAiConfig = types.ListValueMust(t, vs) +} + +// GetOpenaiConfig returns the value of the OpenaiConfig field in ExternalModel as +// a OpenAiConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetOpenaiConfig(ctx context.Context) (OpenAiConfig, bool) { + var e OpenAiConfig + if o.OpenaiConfig.IsNull() || o.OpenaiConfig.IsUnknown() { + return e, false + } + var v []OpenAiConfig + d := o.OpenaiConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOpenaiConfig sets the value of the OpenaiConfig field in ExternalModel. +func (o *ExternalModel) SetOpenaiConfig(ctx context.Context, v OpenAiConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["openai_config"] + o.OpenaiConfig = types.ListValueMust(t, vs) +} + +// GetPalmConfig returns the value of the PalmConfig field in ExternalModel as +// a PaLmConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalModel) GetPalmConfig(ctx context.Context) (PaLmConfig, bool) { + var e PaLmConfig + if o.PalmConfig.IsNull() || o.PalmConfig.IsUnknown() { + return e, false + } + var v []PaLmConfig + d := o.PalmConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPalmConfig sets the value of the PalmConfig field in ExternalModel. +func (o *ExternalModel) SetPalmConfig(ctx context.Context, v PaLmConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["palm_config"] + o.PalmConfig = types.ListValueMust(t, vs) +} + +type ExternalModelUsageElement struct { + // The number of tokens in the chat/completions response. + CompletionTokens types.Int64 `tfsdk:"completion_tokens" tf:"optional"` + // The number of tokens in the prompt. + PromptTokens types.Int64 `tfsdk:"prompt_tokens" tf:"optional"` + // The total number of tokens in the prompt and response. + TotalTokens types.Int64 `tfsdk:"total_tokens" tf:"optional"` +} + +func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringCreateOrUpdate(plan ExternalModelUsageElement) { +} + +func (newState *ExternalModelUsageElement) SyncEffectiveFieldsDuringRead(existingState ExternalModelUsageElement) { +} + +// GetComplexFieldTypes returns a map of the types of elements in complex fields in ExternalModelUsageElement. +// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry +// the type information of their elements in the Go type system. This function provides a way to +// retrieve the type information of the elements in complex fields at runtime. The values of the map +// are the reflected types of the contained elements. They must be either primitive values from the +// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF +// SDK values. +func (a ExternalModelUsageElement) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { + return map[string]reflect.Type{} +} + +// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise // interfere with how the plugin framework retrieves and sets values in state. Thus, ExternalModelUsageElement // only implements ToObjectValue() and Type(). func (o ExternalModelUsageElement) ToObjectValue(ctx context.Context) basetypes.ObjectValue { @@ -2140,6 +3189,31 @@ func (o GetServingEndpointPermissionLevelsResponse) Type(ctx context.Context) at } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetServingEndpointPermissionLevelsResponse as +// a slice of ServingEndpointPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetServingEndpointPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]ServingEndpointPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []ServingEndpointPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetServingEndpointPermissionLevelsResponse. +func (o *GetServingEndpointPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []ServingEndpointPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get serving endpoint permissions type GetServingEndpointPermissionsRequest struct { // The serving endpoint for which to get or manage permissions. @@ -2345,6 +3419,31 @@ func (o ListEndpointsResponse) Type(ctx context.Context) attr.Type { } } +// GetEndpoints returns the value of the Endpoints field in ListEndpointsResponse as +// a slice of ServingEndpoint values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListEndpointsResponse) GetEndpoints(ctx context.Context) ([]ServingEndpoint, bool) { + if o.Endpoints.IsNull() || o.Endpoints.IsUnknown() { + return nil, false + } + var v []ServingEndpoint + d := o.Endpoints.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEndpoints sets the value of the Endpoints field in ListEndpointsResponse. +func (o *ListEndpointsResponse) SetEndpoints(ctx context.Context, v []ServingEndpoint) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["endpoints"] + o.Endpoints = types.ListValueMust(t, vs) +} + // Get the latest logs for a served model type LogsRequest struct { // The name of the serving endpoint that the served model belongs to. This @@ -2414,7 +3513,7 @@ func (newState *ModelDataPlaneInfo) SyncEffectiveFieldsDuringRead(existingState // SDK values. func (a ModelDataPlaneInfo) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "query_info": reflect.TypeOf(oauth2.DataPlaneInfo{}), + "query_info": reflect.TypeOf(oauth2_tf.DataPlaneInfo{}), } } @@ -2440,6 +3539,32 @@ func (o ModelDataPlaneInfo) Type(ctx context.Context) attr.Type { } } +// GetQueryInfo returns the value of the QueryInfo field in ModelDataPlaneInfo as +// a oauth2_tf.DataPlaneInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ModelDataPlaneInfo) GetQueryInfo(ctx context.Context) (oauth2_tf.DataPlaneInfo, bool) { + var e oauth2_tf.DataPlaneInfo + if o.QueryInfo.IsNull() || o.QueryInfo.IsUnknown() { + return e, false + } + var v []oauth2_tf.DataPlaneInfo + d := o.QueryInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueryInfo sets the value of the QueryInfo field in ModelDataPlaneInfo. +func (o *ModelDataPlaneInfo) SetQueryInfo(ctx context.Context, v oauth2_tf.DataPlaneInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_info"] + o.QueryInfo = types.ListValueMust(t, vs) +} + type OpenAiConfig struct { // This field is only required for Azure AD OpenAI and is the Microsoft // Entra Client ID. @@ -2661,6 +3786,56 @@ func (o PatchServingEndpointTags) Type(ctx context.Context) attr.Type { } } +// GetAddTags returns the value of the AddTags field in PatchServingEndpointTags as +// a slice of EndpointTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *PatchServingEndpointTags) GetAddTags(ctx context.Context) ([]EndpointTag, bool) { + if o.AddTags.IsNull() || o.AddTags.IsUnknown() { + return nil, false + } + var v []EndpointTag + d := o.AddTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAddTags sets the value of the AddTags field in PatchServingEndpointTags. +func (o *PatchServingEndpointTags) SetAddTags(ctx context.Context, v []EndpointTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["add_tags"] + o.AddTags = types.ListValueMust(t, vs) +} + +// GetDeleteTags returns the value of the DeleteTags field in PatchServingEndpointTags as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PatchServingEndpointTags) GetDeleteTags(ctx context.Context) ([]types.String, bool) { + if o.DeleteTags.IsNull() || o.DeleteTags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DeleteTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDeleteTags sets the value of the DeleteTags field in PatchServingEndpointTags. +func (o *PatchServingEndpointTags) SetDeleteTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delete_tags"] + o.DeleteTags = types.ListValueMust(t, vs) +} + type PayloadTable struct { // The name of the payload table. Name types.String `tfsdk:"name" tf:"optional"` @@ -2789,6 +3964,109 @@ func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { } } +// GetGuardrails returns the value of the Guardrails field in PutAiGatewayRequest as +// a AiGatewayGuardrails value. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayRequest) GetGuardrails(ctx context.Context) (AiGatewayGuardrails, bool) { + var e AiGatewayGuardrails + if o.Guardrails.IsNull() || o.Guardrails.IsUnknown() { + return e, false + } + var v []AiGatewayGuardrails + d := o.Guardrails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGuardrails sets the value of the Guardrails field in PutAiGatewayRequest. +func (o *PutAiGatewayRequest) SetGuardrails(ctx context.Context, v AiGatewayGuardrails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["guardrails"] + o.Guardrails = types.ListValueMust(t, vs) +} + +// GetInferenceTableConfig returns the value of the InferenceTableConfig field in PutAiGatewayRequest as +// a AiGatewayInferenceTableConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayRequest) GetInferenceTableConfig(ctx context.Context) (AiGatewayInferenceTableConfig, bool) { + var e AiGatewayInferenceTableConfig + if o.InferenceTableConfig.IsNull() || o.InferenceTableConfig.IsUnknown() { + return e, false + } + var v []AiGatewayInferenceTableConfig + d := o.InferenceTableConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInferenceTableConfig sets the value of the InferenceTableConfig field in PutAiGatewayRequest. +func (o *PutAiGatewayRequest) SetInferenceTableConfig(ctx context.Context, v AiGatewayInferenceTableConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inference_table_config"] + o.InferenceTableConfig = types.ListValueMust(t, vs) +} + +// GetRateLimits returns the value of the RateLimits field in PutAiGatewayRequest as +// a slice of AiGatewayRateLimit values. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayRequest) GetRateLimits(ctx context.Context) ([]AiGatewayRateLimit, bool) { + if o.RateLimits.IsNull() || o.RateLimits.IsUnknown() { + return nil, false + } + var v []AiGatewayRateLimit + d := o.RateLimits.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRateLimits sets the value of the RateLimits field in PutAiGatewayRequest. +func (o *PutAiGatewayRequest) SetRateLimits(ctx context.Context, v []AiGatewayRateLimit) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + o.RateLimits = types.ListValueMust(t, vs) +} + +// GetUsageTrackingConfig returns the value of the UsageTrackingConfig field in PutAiGatewayRequest as +// a AiGatewayUsageTrackingConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayRequest) GetUsageTrackingConfig(ctx context.Context) (AiGatewayUsageTrackingConfig, bool) { + var e AiGatewayUsageTrackingConfig + if o.UsageTrackingConfig.IsNull() || o.UsageTrackingConfig.IsUnknown() { + return e, false + } + var v []AiGatewayUsageTrackingConfig + d := o.UsageTrackingConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUsageTrackingConfig sets the value of the UsageTrackingConfig field in PutAiGatewayRequest. +func (o *PutAiGatewayRequest) SetUsageTrackingConfig(ctx context.Context, v AiGatewayUsageTrackingConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["usage_tracking_config"] + o.UsageTrackingConfig = types.ListValueMust(t, vs) +} + type PutAiGatewayResponse struct { // Configuration for AI Guardrails to prevent unwanted data and unsafe data // in requests and responses. @@ -2861,6 +4139,109 @@ func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { } } +// GetGuardrails returns the value of the Guardrails field in PutAiGatewayResponse as +// a AiGatewayGuardrails value. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayResponse) GetGuardrails(ctx context.Context) (AiGatewayGuardrails, bool) { + var e AiGatewayGuardrails + if o.Guardrails.IsNull() || o.Guardrails.IsUnknown() { + return e, false + } + var v []AiGatewayGuardrails + d := o.Guardrails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGuardrails sets the value of the Guardrails field in PutAiGatewayResponse. +func (o *PutAiGatewayResponse) SetGuardrails(ctx context.Context, v AiGatewayGuardrails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["guardrails"] + o.Guardrails = types.ListValueMust(t, vs) +} + +// GetInferenceTableConfig returns the value of the InferenceTableConfig field in PutAiGatewayResponse as +// a AiGatewayInferenceTableConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayResponse) GetInferenceTableConfig(ctx context.Context) (AiGatewayInferenceTableConfig, bool) { + var e AiGatewayInferenceTableConfig + if o.InferenceTableConfig.IsNull() || o.InferenceTableConfig.IsUnknown() { + return e, false + } + var v []AiGatewayInferenceTableConfig + d := o.InferenceTableConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetInferenceTableConfig sets the value of the InferenceTableConfig field in PutAiGatewayResponse. +func (o *PutAiGatewayResponse) SetInferenceTableConfig(ctx context.Context, v AiGatewayInferenceTableConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inference_table_config"] + o.InferenceTableConfig = types.ListValueMust(t, vs) +} + +// GetRateLimits returns the value of the RateLimits field in PutAiGatewayResponse as +// a slice of AiGatewayRateLimit values. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayResponse) GetRateLimits(ctx context.Context) ([]AiGatewayRateLimit, bool) { + if o.RateLimits.IsNull() || o.RateLimits.IsUnknown() { + return nil, false + } + var v []AiGatewayRateLimit + d := o.RateLimits.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRateLimits sets the value of the RateLimits field in PutAiGatewayResponse. +func (o *PutAiGatewayResponse) SetRateLimits(ctx context.Context, v []AiGatewayRateLimit) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + o.RateLimits = types.ListValueMust(t, vs) +} + +// GetUsageTrackingConfig returns the value of the UsageTrackingConfig field in PutAiGatewayResponse as +// a AiGatewayUsageTrackingConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *PutAiGatewayResponse) GetUsageTrackingConfig(ctx context.Context) (AiGatewayUsageTrackingConfig, bool) { + var e AiGatewayUsageTrackingConfig + if o.UsageTrackingConfig.IsNull() || o.UsageTrackingConfig.IsUnknown() { + return e, false + } + var v []AiGatewayUsageTrackingConfig + d := o.UsageTrackingConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUsageTrackingConfig sets the value of the UsageTrackingConfig field in PutAiGatewayResponse. +func (o *PutAiGatewayResponse) SetUsageTrackingConfig(ctx context.Context, v AiGatewayUsageTrackingConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["usage_tracking_config"] + o.UsageTrackingConfig = types.ListValueMust(t, vs) +} + // Update rate limits of a serving endpoint type PutRequest struct { // The name of the serving endpoint whose rate limits are being updated. @@ -2913,6 +4294,31 @@ func (o PutRequest) Type(ctx context.Context) attr.Type { } } +// GetRateLimits returns the value of the RateLimits field in PutRequest as +// a slice of RateLimit values. +// If the field is unknown or null, the boolean return value is false. +func (o *PutRequest) GetRateLimits(ctx context.Context) ([]RateLimit, bool) { + if o.RateLimits.IsNull() || o.RateLimits.IsUnknown() { + return nil, false + } + var v []RateLimit + d := o.RateLimits.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRateLimits sets the value of the RateLimits field in PutRequest. +func (o *PutRequest) SetRateLimits(ctx context.Context, v []RateLimit) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + o.RateLimits = types.ListValueMust(t, vs) +} + type PutResponse struct { // The list of endpoint rate limits. RateLimits types.List `tfsdk:"rate_limits" tf:"optional"` @@ -2959,6 +4365,31 @@ func (o PutResponse) Type(ctx context.Context) attr.Type { } } +// GetRateLimits returns the value of the RateLimits field in PutResponse as +// a slice of RateLimit values. +// If the field is unknown or null, the boolean return value is false. +func (o *PutResponse) GetRateLimits(ctx context.Context) ([]RateLimit, bool) { + if o.RateLimits.IsNull() || o.RateLimits.IsUnknown() { + return nil, false + } + var v []RateLimit + d := o.RateLimits.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRateLimits sets the value of the RateLimits field in PutResponse. +func (o *PutResponse) SetRateLimits(ctx context.Context, v []RateLimit) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + o.RateLimits = types.ListValueMust(t, vs) +} + type QueryEndpointInput struct { // Pandas Dataframe input in the records orientation. DataframeRecords types.List `tfsdk:"dataframe_records" tf:"optional"` @@ -3093,6 +4524,157 @@ func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { } } +// GetDataframeRecords returns the value of the DataframeRecords field in QueryEndpointInput as +// a slice of types.Object values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointInput) GetDataframeRecords(ctx context.Context) ([]types.Object, bool) { + if o.DataframeRecords.IsNull() || o.DataframeRecords.IsUnknown() { + return nil, false + } + var v []types.Object + d := o.DataframeRecords.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDataframeRecords sets the value of the DataframeRecords field in QueryEndpointInput. +func (o *QueryEndpointInput) SetDataframeRecords(ctx context.Context, v []types.Object) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataframe_records"] + o.DataframeRecords = types.ListValueMust(t, vs) +} + +// GetDataframeSplit returns the value of the DataframeSplit field in QueryEndpointInput as +// a DataframeSplitInput value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointInput) GetDataframeSplit(ctx context.Context) (DataframeSplitInput, bool) { + var e DataframeSplitInput + if o.DataframeSplit.IsNull() || o.DataframeSplit.IsUnknown() { + return e, false + } + var v []DataframeSplitInput + d := o.DataframeSplit.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataframeSplit sets the value of the DataframeSplit field in QueryEndpointInput. +func (o *QueryEndpointInput) SetDataframeSplit(ctx context.Context, v DataframeSplitInput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataframe_split"] + o.DataframeSplit = types.ListValueMust(t, vs) +} + +// GetExtraParams returns the value of the ExtraParams field in QueryEndpointInput as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointInput) GetExtraParams(ctx context.Context) (map[string]types.String, bool) { + if o.ExtraParams.IsNull() || o.ExtraParams.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.ExtraParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExtraParams sets the value of the ExtraParams field in QueryEndpointInput. +func (o *QueryEndpointInput) SetExtraParams(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["extra_params"] + o.ExtraParams = types.MapValueMust(t, vs) +} + +// GetInstances returns the value of the Instances field in QueryEndpointInput as +// a slice of types.Object values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointInput) GetInstances(ctx context.Context) ([]types.Object, bool) { + if o.Instances.IsNull() || o.Instances.IsUnknown() { + return nil, false + } + var v []types.Object + d := o.Instances.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInstances sets the value of the Instances field in QueryEndpointInput. +func (o *QueryEndpointInput) SetInstances(ctx context.Context, v []types.Object) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["instances"] + o.Instances = types.ListValueMust(t, vs) +} + +// GetMessages returns the value of the Messages field in QueryEndpointInput as +// a slice of ChatMessage values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointInput) GetMessages(ctx context.Context) ([]ChatMessage, bool) { + if o.Messages.IsNull() || o.Messages.IsUnknown() { + return nil, false + } + var v []ChatMessage + d := o.Messages.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetMessages sets the value of the Messages field in QueryEndpointInput. +func (o *QueryEndpointInput) SetMessages(ctx context.Context, v []ChatMessage) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["messages"] + o.Messages = types.ListValueMust(t, vs) +} + +// GetStop returns the value of the Stop field in QueryEndpointInput as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointInput) GetStop(ctx context.Context) ([]types.String, bool) { + if o.Stop.IsNull() || o.Stop.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Stop.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStop sets the value of the Stop field in QueryEndpointInput. +func (o *QueryEndpointInput) SetStop(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stop"] + o.Stop = types.ListValueMust(t, vs) +} + type QueryEndpointResponse struct { // The list of choices returned by the __chat or completions // external/foundation model__ serving endpoint. @@ -3190,6 +4772,107 @@ func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { } } +// GetChoices returns the value of the Choices field in QueryEndpointResponse as +// a slice of V1ResponseChoiceElement values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointResponse) GetChoices(ctx context.Context) ([]V1ResponseChoiceElement, bool) { + if o.Choices.IsNull() || o.Choices.IsUnknown() { + return nil, false + } + var v []V1ResponseChoiceElement + d := o.Choices.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetChoices sets the value of the Choices field in QueryEndpointResponse. +func (o *QueryEndpointResponse) SetChoices(ctx context.Context, v []V1ResponseChoiceElement) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["choices"] + o.Choices = types.ListValueMust(t, vs) +} + +// GetData returns the value of the Data field in QueryEndpointResponse as +// a slice of EmbeddingsV1ResponseEmbeddingElement values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointResponse) GetData(ctx context.Context) ([]EmbeddingsV1ResponseEmbeddingElement, bool) { + if o.Data.IsNull() || o.Data.IsUnknown() { + return nil, false + } + var v []EmbeddingsV1ResponseEmbeddingElement + d := o.Data.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetData sets the value of the Data field in QueryEndpointResponse. +func (o *QueryEndpointResponse) SetData(ctx context.Context, v []EmbeddingsV1ResponseEmbeddingElement) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + o.Data = types.ListValueMust(t, vs) +} + +// GetPredictions returns the value of the Predictions field in QueryEndpointResponse as +// a slice of types.Object values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointResponse) GetPredictions(ctx context.Context) ([]types.Object, bool) { + if o.Predictions.IsNull() || o.Predictions.IsUnknown() { + return nil, false + } + var v []types.Object + d := o.Predictions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPredictions sets the value of the Predictions field in QueryEndpointResponse. +func (o *QueryEndpointResponse) SetPredictions(ctx context.Context, v []types.Object) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["predictions"] + o.Predictions = types.ListValueMust(t, vs) +} + +// GetUsage returns the value of the Usage field in QueryEndpointResponse as +// a ExternalModelUsageElement value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEndpointResponse) GetUsage(ctx context.Context) (ExternalModelUsageElement, bool) { + var e ExternalModelUsageElement + if o.Usage.IsNull() || o.Usage.IsUnknown() { + return e, false + } + var v []ExternalModelUsageElement + d := o.Usage.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUsage sets the value of the Usage field in QueryEndpointResponse. +func (o *QueryEndpointResponse) SetUsage(ctx context.Context, v ExternalModelUsageElement) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["usage"] + o.Usage = types.ListValueMust(t, vs) +} + type RateLimit struct { // Used to specify how many calls are allowed for a key within the // renewal_period. @@ -3416,6 +5099,57 @@ func (o ServedEntityInput) Type(ctx context.Context) attr.Type { } } +// GetEnvironmentVars returns the value of the EnvironmentVars field in ServedEntityInput as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntityInput) GetEnvironmentVars(ctx context.Context) (map[string]types.String, bool) { + if o.EnvironmentVars.IsNull() || o.EnvironmentVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.EnvironmentVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnvironmentVars sets the value of the EnvironmentVars field in ServedEntityInput. +func (o *ServedEntityInput) SetEnvironmentVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + o.EnvironmentVars = types.MapValueMust(t, vs) +} + +// GetExternalModel returns the value of the ExternalModel field in ServedEntityInput as +// a ExternalModel value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntityInput) GetExternalModel(ctx context.Context) (ExternalModel, bool) { + var e ExternalModel + if o.ExternalModel.IsNull() || o.ExternalModel.IsUnknown() { + return e, false + } + var v []ExternalModel + d := o.ExternalModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExternalModel sets the value of the ExternalModel field in ServedEntityInput. +func (o *ServedEntityInput) SetExternalModel(ctx context.Context, v ExternalModel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_model"] + o.ExternalModel = types.ListValueMust(t, vs) +} + type ServedEntityOutput struct { // The creation timestamp of the served entity in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -3557,6 +5291,109 @@ func (o ServedEntityOutput) Type(ctx context.Context) attr.Type { } } +// GetEnvironmentVars returns the value of the EnvironmentVars field in ServedEntityOutput as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntityOutput) GetEnvironmentVars(ctx context.Context) (map[string]types.String, bool) { + if o.EnvironmentVars.IsNull() || o.EnvironmentVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.EnvironmentVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnvironmentVars sets the value of the EnvironmentVars field in ServedEntityOutput. +func (o *ServedEntityOutput) SetEnvironmentVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + o.EnvironmentVars = types.MapValueMust(t, vs) +} + +// GetExternalModel returns the value of the ExternalModel field in ServedEntityOutput as +// a ExternalModel value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntityOutput) GetExternalModel(ctx context.Context) (ExternalModel, bool) { + var e ExternalModel + if o.ExternalModel.IsNull() || o.ExternalModel.IsUnknown() { + return e, false + } + var v []ExternalModel + d := o.ExternalModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExternalModel sets the value of the ExternalModel field in ServedEntityOutput. +func (o *ServedEntityOutput) SetExternalModel(ctx context.Context, v ExternalModel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_model"] + o.ExternalModel = types.ListValueMust(t, vs) +} + +// GetFoundationModel returns the value of the FoundationModel field in ServedEntityOutput as +// a FoundationModel value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntityOutput) GetFoundationModel(ctx context.Context) (FoundationModel, bool) { + var e FoundationModel + if o.FoundationModel.IsNull() || o.FoundationModel.IsUnknown() { + return e, false + } + var v []FoundationModel + d := o.FoundationModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFoundationModel sets the value of the FoundationModel field in ServedEntityOutput. +func (o *ServedEntityOutput) SetFoundationModel(ctx context.Context, v FoundationModel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["foundation_model"] + o.FoundationModel = types.ListValueMust(t, vs) +} + +// GetState returns the value of the State field in ServedEntityOutput as +// a ServedModelState value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntityOutput) GetState(ctx context.Context) (ServedModelState, bool) { + var e ServedModelState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []ServedModelState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in ServedEntityOutput. +func (o *ServedEntityOutput) SetState(ctx context.Context, v ServedModelState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + type ServedEntitySpec struct { // The name of the entity served. The entity may be a model in the // Databricks Model Registry, a model in the Unity Catalog (UC), or a @@ -3631,6 +5468,58 @@ func (o ServedEntitySpec) Type(ctx context.Context) attr.Type { } } +// GetExternalModel returns the value of the ExternalModel field in ServedEntitySpec as +// a ExternalModel value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntitySpec) GetExternalModel(ctx context.Context) (ExternalModel, bool) { + var e ExternalModel + if o.ExternalModel.IsNull() || o.ExternalModel.IsUnknown() { + return e, false + } + var v []ExternalModel + d := o.ExternalModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetExternalModel sets the value of the ExternalModel field in ServedEntitySpec. +func (o *ServedEntitySpec) SetExternalModel(ctx context.Context, v ExternalModel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_model"] + o.ExternalModel = types.ListValueMust(t, vs) +} + +// GetFoundationModel returns the value of the FoundationModel field in ServedEntitySpec as +// a FoundationModel value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedEntitySpec) GetFoundationModel(ctx context.Context) (FoundationModel, bool) { + var e FoundationModel + if o.FoundationModel.IsNull() || o.FoundationModel.IsUnknown() { + return e, false + } + var v []FoundationModel + d := o.FoundationModel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFoundationModel sets the value of the FoundationModel field in ServedEntitySpec. +func (o *ServedEntitySpec) SetFoundationModel(ctx context.Context, v FoundationModel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["foundation_model"] + o.FoundationModel = types.ListValueMust(t, vs) +} + type ServedModelInput struct { // An object containing a set of optional, user-specified environment // variable key-value pairs used for serving this model. Note: this is an @@ -3738,6 +5627,31 @@ func (o ServedModelInput) Type(ctx context.Context) attr.Type { } } +// GetEnvironmentVars returns the value of the EnvironmentVars field in ServedModelInput as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedModelInput) GetEnvironmentVars(ctx context.Context) (map[string]types.String, bool) { + if o.EnvironmentVars.IsNull() || o.EnvironmentVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.EnvironmentVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnvironmentVars sets the value of the EnvironmentVars field in ServedModelInput. +func (o *ServedModelInput) SetEnvironmentVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + o.EnvironmentVars = types.MapValueMust(t, vs) +} + type ServedModelOutput struct { // The creation timestamp of the served model in Unix time. CreationTimestamp types.Int64 `tfsdk:"creation_timestamp" tf:"optional"` @@ -3848,6 +5762,57 @@ func (o ServedModelOutput) Type(ctx context.Context) attr.Type { } } +// GetEnvironmentVars returns the value of the EnvironmentVars field in ServedModelOutput as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedModelOutput) GetEnvironmentVars(ctx context.Context) (map[string]types.String, bool) { + if o.EnvironmentVars.IsNull() || o.EnvironmentVars.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.EnvironmentVars.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnvironmentVars sets the value of the EnvironmentVars field in ServedModelOutput. +func (o *ServedModelOutput) SetEnvironmentVars(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + o.EnvironmentVars = types.MapValueMust(t, vs) +} + +// GetState returns the value of the State field in ServedModelOutput as +// a ServedModelState value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServedModelOutput) GetState(ctx context.Context) (ServedModelState, bool) { + var e ServedModelState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []ServedModelState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in ServedModelOutput. +func (o *ServedModelOutput) SetState(ctx context.Context, v ServedModelState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + type ServedModelSpec struct { // The name of the model in Databricks Model Registry or the full name of // the model in Unity Catalog. @@ -4093,6 +6058,109 @@ func (o ServingEndpoint) Type(ctx context.Context) attr.Type { } } +// GetAiGateway returns the value of the AiGateway field in ServingEndpoint as +// a AiGatewayConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpoint) GetAiGateway(ctx context.Context) (AiGatewayConfig, bool) { + var e AiGatewayConfig + if o.AiGateway.IsNull() || o.AiGateway.IsUnknown() { + return e, false + } + var v []AiGatewayConfig + d := o.AiGateway.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAiGateway sets the value of the AiGateway field in ServingEndpoint. +func (o *ServingEndpoint) SetAiGateway(ctx context.Context, v AiGatewayConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ai_gateway"] + o.AiGateway = types.ListValueMust(t, vs) +} + +// GetConfig returns the value of the Config field in ServingEndpoint as +// a EndpointCoreConfigSummary value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpoint) GetConfig(ctx context.Context) (EndpointCoreConfigSummary, bool) { + var e EndpointCoreConfigSummary + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []EndpointCoreConfigSummary + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in ServingEndpoint. +func (o *ServingEndpoint) SetConfig(ctx context.Context, v EndpointCoreConfigSummary) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + +// GetState returns the value of the State field in ServingEndpoint as +// a EndpointState value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpoint) GetState(ctx context.Context) (EndpointState, bool) { + var e EndpointState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []EndpointState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in ServingEndpoint. +func (o *ServingEndpoint) SetState(ctx context.Context, v EndpointState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in ServingEndpoint as +// a slice of EndpointTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpoint) GetTags(ctx context.Context) ([]EndpointTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []EndpointTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ServingEndpoint. +func (o *ServingEndpoint) SetTags(ctx context.Context, v []EndpointTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ServingEndpointAccessControlRequest struct { // name of the group GroupName types.String `tfsdk:"group_name" tf:"optional"` @@ -4209,6 +6277,31 @@ func (o ServingEndpointAccessControlResponse) Type(ctx context.Context) attr.Typ } } +// GetAllPermissions returns the value of the AllPermissions field in ServingEndpointAccessControlResponse as +// a slice of ServingEndpointPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointAccessControlResponse) GetAllPermissions(ctx context.Context) ([]ServingEndpointPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []ServingEndpointPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in ServingEndpointAccessControlResponse. +func (o *ServingEndpointAccessControlResponse) SetAllPermissions(ctx context.Context, v []ServingEndpointPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type ServingEndpointDetailed struct { // The AI Gateway configuration for the serving endpoint. NOTE: Only // external model endpoints are currently supported. @@ -4329,6 +6422,161 @@ func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { } } +// GetAiGateway returns the value of the AiGateway field in ServingEndpointDetailed as +// a AiGatewayConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointDetailed) GetAiGateway(ctx context.Context) (AiGatewayConfig, bool) { + var e AiGatewayConfig + if o.AiGateway.IsNull() || o.AiGateway.IsUnknown() { + return e, false + } + var v []AiGatewayConfig + d := o.AiGateway.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAiGateway sets the value of the AiGateway field in ServingEndpointDetailed. +func (o *ServingEndpointDetailed) SetAiGateway(ctx context.Context, v AiGatewayConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ai_gateway"] + o.AiGateway = types.ListValueMust(t, vs) +} + +// GetConfig returns the value of the Config field in ServingEndpointDetailed as +// a EndpointCoreConfigOutput value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointDetailed) GetConfig(ctx context.Context) (EndpointCoreConfigOutput, bool) { + var e EndpointCoreConfigOutput + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []EndpointCoreConfigOutput + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in ServingEndpointDetailed. +func (o *ServingEndpointDetailed) SetConfig(ctx context.Context, v EndpointCoreConfigOutput) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + +// GetDataPlaneInfo returns the value of the DataPlaneInfo field in ServingEndpointDetailed as +// a ModelDataPlaneInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointDetailed) GetDataPlaneInfo(ctx context.Context) (ModelDataPlaneInfo, bool) { + var e ModelDataPlaneInfo + if o.DataPlaneInfo.IsNull() || o.DataPlaneInfo.IsUnknown() { + return e, false + } + var v []ModelDataPlaneInfo + d := o.DataPlaneInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataPlaneInfo sets the value of the DataPlaneInfo field in ServingEndpointDetailed. +func (o *ServingEndpointDetailed) SetDataPlaneInfo(ctx context.Context, v ModelDataPlaneInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_plane_info"] + o.DataPlaneInfo = types.ListValueMust(t, vs) +} + +// GetPendingConfig returns the value of the PendingConfig field in ServingEndpointDetailed as +// a EndpointPendingConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointDetailed) GetPendingConfig(ctx context.Context) (EndpointPendingConfig, bool) { + var e EndpointPendingConfig + if o.PendingConfig.IsNull() || o.PendingConfig.IsUnknown() { + return e, false + } + var v []EndpointPendingConfig + d := o.PendingConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPendingConfig sets the value of the PendingConfig field in ServingEndpointDetailed. +func (o *ServingEndpointDetailed) SetPendingConfig(ctx context.Context, v EndpointPendingConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pending_config"] + o.PendingConfig = types.ListValueMust(t, vs) +} + +// GetState returns the value of the State field in ServingEndpointDetailed as +// a EndpointState value. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointDetailed) GetState(ctx context.Context) (EndpointState, bool) { + var e EndpointState + if o.State.IsNull() || o.State.IsUnknown() { + return e, false + } + var v []EndpointState + d := o.State.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetState sets the value of the State field in ServingEndpointDetailed. +func (o *ServingEndpointDetailed) SetState(ctx context.Context, v EndpointState) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["state"] + o.State = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in ServingEndpointDetailed as +// a slice of EndpointTag values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointDetailed) GetTags(ctx context.Context) ([]EndpointTag, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []EndpointTag + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ServingEndpointDetailed. +func (o *ServingEndpointDetailed) SetTags(ctx context.Context, v []EndpointTag) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ServingEndpointPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -4382,6 +6630,31 @@ func (o ServingEndpointPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in ServingEndpointPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in ServingEndpointPermission. +func (o *ServingEndpointPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type ServingEndpointPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -4435,6 +6708,31 @@ func (o ServingEndpointPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ServingEndpointPermissions as +// a slice of ServingEndpointAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointPermissions) GetAccessControlList(ctx context.Context) ([]ServingEndpointAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ServingEndpointAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ServingEndpointPermissions. +func (o *ServingEndpointPermissions) SetAccessControlList(ctx context.Context, v []ServingEndpointAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type ServingEndpointPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -4529,6 +6827,31 @@ func (o ServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in ServingEndpointPermissionsRequest as +// a slice of ServingEndpointAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *ServingEndpointPermissionsRequest) GetAccessControlList(ctx context.Context) ([]ServingEndpointAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []ServingEndpointAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in ServingEndpointPermissionsRequest. +func (o *ServingEndpointPermissionsRequest) SetAccessControlList(ctx context.Context, v []ServingEndpointAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type TrafficConfig struct { // The list of routes that define traffic to each served entity. Routes types.List `tfsdk:"routes" tf:"optional"` @@ -4575,6 +6898,31 @@ func (o TrafficConfig) Type(ctx context.Context) attr.Type { } } +// GetRoutes returns the value of the Routes field in TrafficConfig as +// a slice of Route values. +// If the field is unknown or null, the boolean return value is false. +func (o *TrafficConfig) GetRoutes(ctx context.Context) ([]Route, bool) { + if o.Routes.IsNull() || o.Routes.IsUnknown() { + return nil, false + } + var v []Route + d := o.Routes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRoutes sets the value of the Routes field in TrafficConfig. +func (o *TrafficConfig) SetRoutes(ctx context.Context, v []Route) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["routes"] + o.Routes = types.ListValueMust(t, vs) +} + type V1ResponseChoiceElement struct { // The finish reason returned by the endpoint. FinishReason types.String `tfsdk:"finishReason" tf:"optional"` @@ -4637,76 +6985,28 @@ func (o V1ResponseChoiceElement) Type(ctx context.Context) attr.Type { } } -// Behavior for PII filter. Currently only 'BLOCK' is supported. If 'BLOCK' is -// set for the input guardrail and the request contains PII, the request is not -// sent to the model server and 400 status code is returned; if 'BLOCK' is set -// for the output guardrail and the model response contains PII, the PII info in -// the response is redacted and 400 status code is returned. - -// Key field for a rate limit. Currently, only 'user' and 'endpoint' are -// supported, with 'endpoint' being the default if not specified. - -// Renewal period field for a rate limit. Currently, only 'minute' is supported. - -// The underlying provider in Amazon Bedrock. Supported values (case -// insensitive) include: Anthropic, Cohere, AI21Labs, Amazon. - -// The role of the message. One of [system, user, assistant]. - -// This will always be 'embedding'. - -// The state of an endpoint's config update. This informs the user if the -// pending_config is in progress, if the update failed, or if there is no update -// in progress. Note that if the endpoint's config_update state value is -// IN_PROGRESS, another update can not be made until the update completes or -// fails." - -// The state of an endpoint, indicating whether or not the endpoint is -// queryable. An endpoint is READY if all of the served entities in its active -// configuration are ready. If any of the actively served entities are in a -// non-ready state, the endpoint state will be NOT_READY. - -// The name of the provider for the external model. Currently, the supported -// providers are 'ai21labs', 'anthropic', 'amazon-bedrock', 'cohere', -// 'databricks-model-serving', 'google-cloud-vertex-ai', 'openai', and 'palm'.", - -// The type of object returned by the __external/foundation model__ serving -// endpoint, one of [text_completion, chat.completion, list (of embeddings)]. - -// Key field for a serving endpoint rate limit. Currently, only 'user' and -// 'endpoint' are supported, with 'endpoint' being the default if not specified. - -// Renewal period field for a serving endpoint rate limit. Currently, only -// 'minute' is supported. - -// The workload size of the served model. The workload size corresponds to a -// range of provisioned concurrency that the compute will autoscale between. A -// single unit of provisioned concurrency can process one request at a time. -// Valid workload sizes are "Small" (4 - 4 provisioned concurrency), "Medium" (8 -// - 16 provisioned concurrency), and "Large" (16 - 64 provisioned concurrency). -// If scale-to-zero is enabled, the lower bound of the provisioned concurrency -// for each workload size will be 0. - -// The workload type of the served model. The workload type selects which type -// of compute to use in the endpoint. The default value for this parameter is -// "CPU". For deep learning workloads, GPU acceleration is available by -// selecting workload types like GPU_SMALL and others. See the available [GPU -// types]. -// -// [GPU types]: https://docs.databricks.com/machine-learning/model-serving/create-manage-serving-endpoints.html#gpu-workload-types - -// The state of the served entity deployment. DEPLOYMENT_CREATING indicates that -// the served entity is not ready yet because the deployment is still being -// created (i.e container image is building, model server is deploying for the -// first time, etc.). DEPLOYMENT_RECOVERING indicates that the served entity was -// previously in a ready state but no longer is and is attempting to recover. -// DEPLOYMENT_READY indicates that the served entity is ready to receive -// traffic. DEPLOYMENT_FAILED indicates that there was an error trying to bring -// up the served entity (e.g container image build failed, the model server -// failed to start due to a model loading error, etc.) DEPLOYMENT_ABORTED -// indicates that the deployment was terminated likely due to a failure in -// bringing up another served entity under the same endpoint and config version. - -// The permission level of the principal making the request. +// GetMessage returns the value of the Message field in V1ResponseChoiceElement as +// a ChatMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *V1ResponseChoiceElement) GetMessage(ctx context.Context) (ChatMessage, bool) { + var e ChatMessage + if o.Message.IsNull() || o.Message.IsUnknown() { + return e, false + } + var v []ChatMessage + d := o.Message.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// Permission level +// SetMessage sets the value of the Message field in V1ResponseChoiceElement. +func (o *V1ResponseChoiceElement) SetMessage(ctx context.Context, v ChatMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["message"] + o.Message = types.ListValueMust(t, vs) +} diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 4bed86c778..70d3e38bc2 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -123,6 +124,32 @@ func (o AibiDashboardEmbeddingAccessPolicySetting) Type(ctx context.Context) att } } +// GetAibiDashboardEmbeddingAccessPolicy returns the value of the AibiDashboardEmbeddingAccessPolicy field in AibiDashboardEmbeddingAccessPolicySetting as +// a AibiDashboardEmbeddingAccessPolicy value. +// If the field is unknown or null, the boolean return value is false. +func (o *AibiDashboardEmbeddingAccessPolicySetting) GetAibiDashboardEmbeddingAccessPolicy(ctx context.Context) (AibiDashboardEmbeddingAccessPolicy, bool) { + var e AibiDashboardEmbeddingAccessPolicy + if o.AibiDashboardEmbeddingAccessPolicy.IsNull() || o.AibiDashboardEmbeddingAccessPolicy.IsUnknown() { + return e, false + } + var v []AibiDashboardEmbeddingAccessPolicy + d := o.AibiDashboardEmbeddingAccessPolicy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAibiDashboardEmbeddingAccessPolicy sets the value of the AibiDashboardEmbeddingAccessPolicy field in AibiDashboardEmbeddingAccessPolicySetting. +func (o *AibiDashboardEmbeddingAccessPolicySetting) SetAibiDashboardEmbeddingAccessPolicy(ctx context.Context, v AibiDashboardEmbeddingAccessPolicy) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aibi_dashboard_embedding_access_policy"] + o.AibiDashboardEmbeddingAccessPolicy = types.ListValueMust(t, vs) +} + type AibiDashboardEmbeddingApprovedDomains struct { ApprovedDomains types.List `tfsdk:"approved_domains" tf:"optional"` } @@ -168,6 +195,31 @@ func (o AibiDashboardEmbeddingApprovedDomains) Type(ctx context.Context) attr.Ty } } +// GetApprovedDomains returns the value of the ApprovedDomains field in AibiDashboardEmbeddingApprovedDomains as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *AibiDashboardEmbeddingApprovedDomains) GetApprovedDomains(ctx context.Context) ([]types.String, bool) { + if o.ApprovedDomains.IsNull() || o.ApprovedDomains.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ApprovedDomains.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetApprovedDomains sets the value of the ApprovedDomains field in AibiDashboardEmbeddingApprovedDomains. +func (o *AibiDashboardEmbeddingApprovedDomains) SetApprovedDomains(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["approved_domains"] + o.ApprovedDomains = types.ListValueMust(t, vs) +} + type AibiDashboardEmbeddingApprovedDomainsSetting struct { AibiDashboardEmbeddingApprovedDomains types.List `tfsdk:"aibi_dashboard_embedding_approved_domains" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag @@ -231,6 +283,32 @@ func (o AibiDashboardEmbeddingApprovedDomainsSetting) Type(ctx context.Context) } } +// GetAibiDashboardEmbeddingApprovedDomains returns the value of the AibiDashboardEmbeddingApprovedDomains field in AibiDashboardEmbeddingApprovedDomainsSetting as +// a AibiDashboardEmbeddingApprovedDomains value. +// If the field is unknown or null, the boolean return value is false. +func (o *AibiDashboardEmbeddingApprovedDomainsSetting) GetAibiDashboardEmbeddingApprovedDomains(ctx context.Context) (AibiDashboardEmbeddingApprovedDomains, bool) { + var e AibiDashboardEmbeddingApprovedDomains + if o.AibiDashboardEmbeddingApprovedDomains.IsNull() || o.AibiDashboardEmbeddingApprovedDomains.IsUnknown() { + return e, false + } + var v []AibiDashboardEmbeddingApprovedDomains + d := o.AibiDashboardEmbeddingApprovedDomains.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAibiDashboardEmbeddingApprovedDomains sets the value of the AibiDashboardEmbeddingApprovedDomains field in AibiDashboardEmbeddingApprovedDomainsSetting. +func (o *AibiDashboardEmbeddingApprovedDomainsSetting) SetAibiDashboardEmbeddingApprovedDomains(ctx context.Context, v AibiDashboardEmbeddingApprovedDomains) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aibi_dashboard_embedding_approved_domains"] + o.AibiDashboardEmbeddingApprovedDomains = types.ListValueMust(t, vs) +} + type AutomaticClusterUpdateSetting struct { AutomaticClusterUpdateWorkspace types.List `tfsdk:"automatic_cluster_update_workspace" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag @@ -294,6 +372,32 @@ func (o AutomaticClusterUpdateSetting) Type(ctx context.Context) attr.Type { } } +// GetAutomaticClusterUpdateWorkspace returns the value of the AutomaticClusterUpdateWorkspace field in AutomaticClusterUpdateSetting as +// a ClusterAutoRestartMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *AutomaticClusterUpdateSetting) GetAutomaticClusterUpdateWorkspace(ctx context.Context) (ClusterAutoRestartMessage, bool) { + var e ClusterAutoRestartMessage + if o.AutomaticClusterUpdateWorkspace.IsNull() || o.AutomaticClusterUpdateWorkspace.IsUnknown() { + return e, false + } + var v []ClusterAutoRestartMessage + d := o.AutomaticClusterUpdateWorkspace.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAutomaticClusterUpdateWorkspace sets the value of the AutomaticClusterUpdateWorkspace field in AutomaticClusterUpdateSetting. +func (o *AutomaticClusterUpdateSetting) SetAutomaticClusterUpdateWorkspace(ctx context.Context, v ClusterAutoRestartMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["automatic_cluster_update_workspace"] + o.AutomaticClusterUpdateWorkspace = types.ListValueMust(t, vs) +} + type BooleanMessage struct { Value types.Bool `tfsdk:"value" tf:"optional"` } @@ -404,6 +508,58 @@ func (o ClusterAutoRestartMessage) Type(ctx context.Context) attr.Type { } } +// GetEnablementDetails returns the value of the EnablementDetails field in ClusterAutoRestartMessage as +// a ClusterAutoRestartMessageEnablementDetails value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAutoRestartMessage) GetEnablementDetails(ctx context.Context) (ClusterAutoRestartMessageEnablementDetails, bool) { + var e ClusterAutoRestartMessageEnablementDetails + if o.EnablementDetails.IsNull() || o.EnablementDetails.IsUnknown() { + return e, false + } + var v []ClusterAutoRestartMessageEnablementDetails + d := o.EnablementDetails.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEnablementDetails sets the value of the EnablementDetails field in ClusterAutoRestartMessage. +func (o *ClusterAutoRestartMessage) SetEnablementDetails(ctx context.Context, v ClusterAutoRestartMessageEnablementDetails) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enablement_details"] + o.EnablementDetails = types.ListValueMust(t, vs) +} + +// GetMaintenanceWindow returns the value of the MaintenanceWindow field in ClusterAutoRestartMessage as +// a ClusterAutoRestartMessageMaintenanceWindow value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAutoRestartMessage) GetMaintenanceWindow(ctx context.Context) (ClusterAutoRestartMessageMaintenanceWindow, bool) { + var e ClusterAutoRestartMessageMaintenanceWindow + if o.MaintenanceWindow.IsNull() || o.MaintenanceWindow.IsUnknown() { + return e, false + } + var v []ClusterAutoRestartMessageMaintenanceWindow + d := o.MaintenanceWindow.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMaintenanceWindow sets the value of the MaintenanceWindow field in ClusterAutoRestartMessage. +func (o *ClusterAutoRestartMessage) SetMaintenanceWindow(ctx context.Context, v ClusterAutoRestartMessageMaintenanceWindow) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["maintenance_window"] + o.MaintenanceWindow = types.ListValueMust(t, vs) +} + // Contains an information about the enablement status judging (e.g. whether the // enterprise tier is enabled) This is only additional information that MUST NOT // be used to decide whether the setting is enabled or not. This is intended to @@ -506,6 +662,32 @@ func (o ClusterAutoRestartMessageMaintenanceWindow) Type(ctx context.Context) at } } +// GetWeekDayBasedSchedule returns the value of the WeekDayBasedSchedule field in ClusterAutoRestartMessageMaintenanceWindow as +// a ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAutoRestartMessageMaintenanceWindow) GetWeekDayBasedSchedule(ctx context.Context) (ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule, bool) { + var e ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule + if o.WeekDayBasedSchedule.IsNull() || o.WeekDayBasedSchedule.IsUnknown() { + return e, false + } + var v []ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule + d := o.WeekDayBasedSchedule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWeekDayBasedSchedule sets the value of the WeekDayBasedSchedule field in ClusterAutoRestartMessageMaintenanceWindow. +func (o *ClusterAutoRestartMessageMaintenanceWindow) SetWeekDayBasedSchedule(ctx context.Context, v ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["week_day_based_schedule"] + o.WeekDayBasedSchedule = types.ListValueMust(t, vs) +} + type ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule struct { DayOfWeek types.String `tfsdk:"day_of_week" tf:"optional"` @@ -559,6 +741,32 @@ func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) Type(ctx } } +// GetWindowStartTime returns the value of the WindowStartTime field in ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule as +// a ClusterAutoRestartMessageMaintenanceWindowWindowStartTime value. +// If the field is unknown or null, the boolean return value is false. +func (o *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) GetWindowStartTime(ctx context.Context) (ClusterAutoRestartMessageMaintenanceWindowWindowStartTime, bool) { + var e ClusterAutoRestartMessageMaintenanceWindowWindowStartTime + if o.WindowStartTime.IsNull() || o.WindowStartTime.IsUnknown() { + return e, false + } + var v []ClusterAutoRestartMessageMaintenanceWindowWindowStartTime + d := o.WindowStartTime.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetWindowStartTime sets the value of the WindowStartTime field in ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule. +func (o *ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) SetWindowStartTime(ctx context.Context, v ClusterAutoRestartMessageMaintenanceWindowWindowStartTime) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["window_start_time"] + o.WindowStartTime = types.ListValueMust(t, vs) +} + type ClusterAutoRestartMessageMaintenanceWindowWindowStartTime struct { Hours types.Int64 `tfsdk:"hours" tf:"optional"` @@ -655,6 +863,31 @@ func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { } } +// GetComplianceStandards returns the value of the ComplianceStandards field in ComplianceSecurityProfile as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) ([]types.String, bool) { + if o.ComplianceStandards.IsNull() || o.ComplianceStandards.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ComplianceStandards.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetComplianceStandards sets the value of the ComplianceStandards field in ComplianceSecurityProfile. +func (o *ComplianceSecurityProfile) SetComplianceStandards(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_standards"] + o.ComplianceStandards = types.ListValueMust(t, vs) +} + type ComplianceSecurityProfileSetting struct { // SHIELD feature: CSP ComplianceSecurityProfileWorkspace types.List `tfsdk:"compliance_security_profile_workspace" tf:"object"` @@ -719,6 +952,32 @@ func (o ComplianceSecurityProfileSetting) Type(ctx context.Context) attr.Type { } } +// GetComplianceSecurityProfileWorkspace returns the value of the ComplianceSecurityProfileWorkspace field in ComplianceSecurityProfileSetting as +// a ComplianceSecurityProfile value. +// If the field is unknown or null, the boolean return value is false. +func (o *ComplianceSecurityProfileSetting) GetComplianceSecurityProfileWorkspace(ctx context.Context) (ComplianceSecurityProfile, bool) { + var e ComplianceSecurityProfile + if o.ComplianceSecurityProfileWorkspace.IsNull() || o.ComplianceSecurityProfileWorkspace.IsUnknown() { + return e, false + } + var v []ComplianceSecurityProfile + d := o.ComplianceSecurityProfileWorkspace.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetComplianceSecurityProfileWorkspace sets the value of the ComplianceSecurityProfileWorkspace field in ComplianceSecurityProfileSetting. +func (o *ComplianceSecurityProfileSetting) SetComplianceSecurityProfileWorkspace(ctx context.Context, v ComplianceSecurityProfile) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_security_profile_workspace"] + o.ComplianceSecurityProfileWorkspace = types.ListValueMust(t, vs) +} + type Config struct { Email types.List `tfsdk:"email" tf:"optional,object"` @@ -792,6 +1051,136 @@ func (o Config) Type(ctx context.Context) attr.Type { } } +// GetEmail returns the value of the Email field in Config as +// a EmailConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Config) GetEmail(ctx context.Context) (EmailConfig, bool) { + var e EmailConfig + if o.Email.IsNull() || o.Email.IsUnknown() { + return e, false + } + var v []EmailConfig + d := o.Email.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEmail sets the value of the Email field in Config. +func (o *Config) SetEmail(ctx context.Context, v EmailConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email"] + o.Email = types.ListValueMust(t, vs) +} + +// GetGenericWebhook returns the value of the GenericWebhook field in Config as +// a GenericWebhookConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Config) GetGenericWebhook(ctx context.Context) (GenericWebhookConfig, bool) { + var e GenericWebhookConfig + if o.GenericWebhook.IsNull() || o.GenericWebhook.IsUnknown() { + return e, false + } + var v []GenericWebhookConfig + d := o.GenericWebhook.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGenericWebhook sets the value of the GenericWebhook field in Config. +func (o *Config) SetGenericWebhook(ctx context.Context, v GenericWebhookConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["generic_webhook"] + o.GenericWebhook = types.ListValueMust(t, vs) +} + +// GetMicrosoftTeams returns the value of the MicrosoftTeams field in Config as +// a MicrosoftTeamsConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Config) GetMicrosoftTeams(ctx context.Context) (MicrosoftTeamsConfig, bool) { + var e MicrosoftTeamsConfig + if o.MicrosoftTeams.IsNull() || o.MicrosoftTeams.IsUnknown() { + return e, false + } + var v []MicrosoftTeamsConfig + d := o.MicrosoftTeams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMicrosoftTeams sets the value of the MicrosoftTeams field in Config. +func (o *Config) SetMicrosoftTeams(ctx context.Context, v MicrosoftTeamsConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["microsoft_teams"] + o.MicrosoftTeams = types.ListValueMust(t, vs) +} + +// GetPagerduty returns the value of the Pagerduty field in Config as +// a PagerdutyConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Config) GetPagerduty(ctx context.Context) (PagerdutyConfig, bool) { + var e PagerdutyConfig + if o.Pagerduty.IsNull() || o.Pagerduty.IsUnknown() { + return e, false + } + var v []PagerdutyConfig + d := o.Pagerduty.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPagerduty sets the value of the Pagerduty field in Config. +func (o *Config) SetPagerduty(ctx context.Context, v PagerdutyConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pagerduty"] + o.Pagerduty = types.ListValueMust(t, vs) +} + +// GetSlack returns the value of the Slack field in Config as +// a SlackConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *Config) GetSlack(ctx context.Context) (SlackConfig, bool) { + var e SlackConfig + if o.Slack.IsNull() || o.Slack.IsUnknown() { + return e, false + } + var v []SlackConfig + d := o.Slack.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSlack sets the value of the Slack field in Config. +func (o *Config) SetSlack(ctx context.Context, v SlackConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slack"] + o.Slack = types.ListValueMust(t, vs) +} + // Details required to configure a block list or allow list. type CreateIpAccessList struct { IpAddresses types.List `tfsdk:"ip_addresses" tf:"optional"` @@ -851,6 +1240,31 @@ func (o CreateIpAccessList) Type(ctx context.Context) attr.Type { } } +// GetIpAddresses returns the value of the IpAddresses field in CreateIpAccessList as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateIpAccessList) GetIpAddresses(ctx context.Context) ([]types.String, bool) { + if o.IpAddresses.IsNull() || o.IpAddresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.IpAddresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIpAddresses sets the value of the IpAddresses field in CreateIpAccessList. +func (o *CreateIpAccessList) SetIpAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + o.IpAddresses = types.ListValueMust(t, vs) +} + // An IP access list was successfully created. type CreateIpAccessListResponse struct { // Definition of an IP Access list @@ -898,6 +1312,32 @@ func (o CreateIpAccessListResponse) Type(ctx context.Context) attr.Type { } } +// GetIpAccessList returns the value of the IpAccessList field in CreateIpAccessListResponse as +// a IpAccessListInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateIpAccessListResponse) GetIpAccessList(ctx context.Context) (IpAccessListInfo, bool) { + var e IpAccessListInfo + if o.IpAccessList.IsNull() || o.IpAccessList.IsUnknown() { + return e, false + } + var v []IpAccessListInfo + d := o.IpAccessList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIpAccessList sets the value of the IpAccessList field in CreateIpAccessListResponse. +func (o *CreateIpAccessListResponse) SetIpAccessList(ctx context.Context, v IpAccessListInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_list"] + o.IpAccessList = types.ListValueMust(t, vs) +} + type CreateNetworkConnectivityConfigRequest struct { // The name of the network connectivity configuration. The name can contain // alphanumeric characters, hyphens, and underscores. The length must be @@ -1000,6 +1440,32 @@ func (o CreateNotificationDestinationRequest) Type(ctx context.Context) attr.Typ } } +// GetConfig returns the value of the Config field in CreateNotificationDestinationRequest as +// a Config value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateNotificationDestinationRequest) GetConfig(ctx context.Context) (Config, bool) { + var e Config + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []Config + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in CreateNotificationDestinationRequest. +func (o *CreateNotificationDestinationRequest) SetConfig(ctx context.Context, v Config) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + // Configuration details for creating on-behalf tokens. type CreateOboTokenRequest struct { // Application ID of the service principal. @@ -1101,6 +1567,32 @@ func (o CreateOboTokenResponse) Type(ctx context.Context) attr.Type { } } +// GetTokenInfo returns the value of the TokenInfo field in CreateOboTokenResponse as +// a TokenInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateOboTokenResponse) GetTokenInfo(ctx context.Context) (TokenInfo, bool) { + var e TokenInfo + if o.TokenInfo.IsNull() || o.TokenInfo.IsUnknown() { + return e, false + } + var v []TokenInfo + d := o.TokenInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenInfo sets the value of the TokenInfo field in CreateOboTokenResponse. +func (o *CreateOboTokenResponse) SetTokenInfo(ctx context.Context, v TokenInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_info"] + o.TokenInfo = types.ListValueMust(t, vs) +} + type CreatePrivateEndpointRuleRequest struct { // The sub-resource type (group ID) of the target resource. Note that to // connect to workspace root storage (root DBFS), you need two endpoints, @@ -1251,6 +1743,32 @@ func (o CreateTokenResponse) Type(ctx context.Context) attr.Type { } } +// GetTokenInfo returns the value of the TokenInfo field in CreateTokenResponse as +// a PublicTokenInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateTokenResponse) GetTokenInfo(ctx context.Context) (PublicTokenInfo, bool) { + var e PublicTokenInfo + if o.TokenInfo.IsNull() || o.TokenInfo.IsUnknown() { + return e, false + } + var v []PublicTokenInfo + d := o.TokenInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenInfo sets the value of the TokenInfo field in CreateTokenResponse. +func (o *CreateTokenResponse) SetTokenInfo(ctx context.Context, v PublicTokenInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_info"] + o.TokenInfo = types.ListValueMust(t, vs) +} + // Account level policy for CSP type CspEnablementAccount struct { // Set by customers when they request Compliance Security Profile (CSP) @@ -1303,6 +1821,31 @@ func (o CspEnablementAccount) Type(ctx context.Context) attr.Type { } } +// GetComplianceStandards returns the value of the ComplianceStandards field in CspEnablementAccount as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CspEnablementAccount) GetComplianceStandards(ctx context.Context) ([]types.String, bool) { + if o.ComplianceStandards.IsNull() || o.ComplianceStandards.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ComplianceStandards.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetComplianceStandards sets the value of the ComplianceStandards field in CspEnablementAccount. +func (o *CspEnablementAccount) SetComplianceStandards(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_standards"] + o.ComplianceStandards = types.ListValueMust(t, vs) +} + type CspEnablementAccountSetting struct { // Account level policy for CSP CspEnablementAccount types.List `tfsdk:"csp_enablement_account" tf:"object"` @@ -1367,6 +1910,32 @@ func (o CspEnablementAccountSetting) Type(ctx context.Context) attr.Type { } } +// GetCspEnablementAccount returns the value of the CspEnablementAccount field in CspEnablementAccountSetting as +// a CspEnablementAccount value. +// If the field is unknown or null, the boolean return value is false. +func (o *CspEnablementAccountSetting) GetCspEnablementAccount(ctx context.Context) (CspEnablementAccount, bool) { + var e CspEnablementAccount + if o.CspEnablementAccount.IsNull() || o.CspEnablementAccount.IsUnknown() { + return e, false + } + var v []CspEnablementAccount + d := o.CspEnablementAccount.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCspEnablementAccount sets the value of the CspEnablementAccount field in CspEnablementAccountSetting. +func (o *CspEnablementAccountSetting) SetCspEnablementAccount(ctx context.Context, v CspEnablementAccount) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["csp_enablement_account"] + o.CspEnablementAccount = types.ListValueMust(t, vs) +} + // This represents the setting configuration for the default namespace in the // Databricks workspace. Setting the default catalog for the workspace // determines the catalog that is used when queries do not reference a fully @@ -1440,6 +2009,32 @@ func (o DefaultNamespaceSetting) Type(ctx context.Context) attr.Type { } } +// GetNamespace returns the value of the Namespace field in DefaultNamespaceSetting as +// a StringMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *DefaultNamespaceSetting) GetNamespace(ctx context.Context) (StringMessage, bool) { + var e StringMessage + if o.Namespace.IsNull() || o.Namespace.IsUnknown() { + return e, false + } + var v []StringMessage + d := o.Namespace.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNamespace sets the value of the Namespace field in DefaultNamespaceSetting. +func (o *DefaultNamespaceSetting) SetNamespace(ctx context.Context, v StringMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["namespace"] + o.Namespace = types.ListValueMust(t, vs) +} + // Delete access list type DeleteAccountIpAccessListRequest struct { // The ID for the corresponding IP access list @@ -2424,6 +3019,32 @@ func (o DisableLegacyAccess) Type(ctx context.Context) attr.Type { } } +// GetDisableLegacyAccess returns the value of the DisableLegacyAccess field in DisableLegacyAccess as +// a BooleanMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *DisableLegacyAccess) GetDisableLegacyAccess(ctx context.Context) (BooleanMessage, bool) { + var e BooleanMessage + if o.DisableLegacyAccess.IsNull() || o.DisableLegacyAccess.IsUnknown() { + return e, false + } + var v []BooleanMessage + d := o.DisableLegacyAccess.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDisableLegacyAccess sets the value of the DisableLegacyAccess field in DisableLegacyAccess. +func (o *DisableLegacyAccess) SetDisableLegacyAccess(ctx context.Context, v BooleanMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disable_legacy_access"] + o.DisableLegacyAccess = types.ListValueMust(t, vs) +} + type DisableLegacyDbfs struct { DisableLegacyDbfs types.List `tfsdk:"disable_legacy_dbfs" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag @@ -2487,6 +3108,32 @@ func (o DisableLegacyDbfs) Type(ctx context.Context) attr.Type { } } +// GetDisableLegacyDbfs returns the value of the DisableLegacyDbfs field in DisableLegacyDbfs as +// a BooleanMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *DisableLegacyDbfs) GetDisableLegacyDbfs(ctx context.Context) (BooleanMessage, bool) { + var e BooleanMessage + if o.DisableLegacyDbfs.IsNull() || o.DisableLegacyDbfs.IsUnknown() { + return e, false + } + var v []BooleanMessage + d := o.DisableLegacyDbfs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDisableLegacyDbfs sets the value of the DisableLegacyDbfs field in DisableLegacyDbfs. +func (o *DisableLegacyDbfs) SetDisableLegacyDbfs(ctx context.Context, v BooleanMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disable_legacy_dbfs"] + o.DisableLegacyDbfs = types.ListValueMust(t, vs) +} + type DisableLegacyFeatures struct { DisableLegacyFeatures types.List `tfsdk:"disable_legacy_features" tf:"object"` // etag used for versioning. The response is at least as fresh as the eTag @@ -2550,6 +3197,32 @@ func (o DisableLegacyFeatures) Type(ctx context.Context) attr.Type { } } +// GetDisableLegacyFeatures returns the value of the DisableLegacyFeatures field in DisableLegacyFeatures as +// a BooleanMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *DisableLegacyFeatures) GetDisableLegacyFeatures(ctx context.Context) (BooleanMessage, bool) { + var e BooleanMessage + if o.DisableLegacyFeatures.IsNull() || o.DisableLegacyFeatures.IsUnknown() { + return e, false + } + var v []BooleanMessage + d := o.DisableLegacyFeatures.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDisableLegacyFeatures sets the value of the DisableLegacyFeatures field in DisableLegacyFeatures. +func (o *DisableLegacyFeatures) SetDisableLegacyFeatures(ctx context.Context, v BooleanMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["disable_legacy_features"] + o.DisableLegacyFeatures = types.ListValueMust(t, vs) +} + type EmailConfig struct { // Email addresses to notify. Addresses types.List `tfsdk:"addresses" tf:"optional"` @@ -2596,6 +3269,31 @@ func (o EmailConfig) Type(ctx context.Context) attr.Type { } } +// GetAddresses returns the value of the Addresses field in EmailConfig as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EmailConfig) GetAddresses(ctx context.Context) ([]types.String, bool) { + if o.Addresses.IsNull() || o.Addresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Addresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAddresses sets the value of the Addresses field in EmailConfig. +func (o *EmailConfig) SetAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["addresses"] + o.Addresses = types.ListValueMust(t, vs) +} + type Empty struct { } @@ -2738,6 +3436,32 @@ func (o EnhancedSecurityMonitoringSetting) Type(ctx context.Context) attr.Type { } } +// GetEnhancedSecurityMonitoringWorkspace returns the value of the EnhancedSecurityMonitoringWorkspace field in EnhancedSecurityMonitoringSetting as +// a EnhancedSecurityMonitoring value. +// If the field is unknown or null, the boolean return value is false. +func (o *EnhancedSecurityMonitoringSetting) GetEnhancedSecurityMonitoringWorkspace(ctx context.Context) (EnhancedSecurityMonitoring, bool) { + var e EnhancedSecurityMonitoring + if o.EnhancedSecurityMonitoringWorkspace.IsNull() || o.EnhancedSecurityMonitoringWorkspace.IsUnknown() { + return e, false + } + var v []EnhancedSecurityMonitoring + d := o.EnhancedSecurityMonitoringWorkspace.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEnhancedSecurityMonitoringWorkspace sets the value of the EnhancedSecurityMonitoringWorkspace field in EnhancedSecurityMonitoringSetting. +func (o *EnhancedSecurityMonitoringSetting) SetEnhancedSecurityMonitoringWorkspace(ctx context.Context, v EnhancedSecurityMonitoring) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enhanced_security_monitoring_workspace"] + o.EnhancedSecurityMonitoringWorkspace = types.ListValueMust(t, vs) +} + // Account level policy for ESM type EsmEnablementAccount struct { IsEnforced types.Bool `tfsdk:"is_enforced" tf:"optional"` @@ -2844,6 +3568,32 @@ func (o EsmEnablementAccountSetting) Type(ctx context.Context) attr.Type { } } +// GetEsmEnablementAccount returns the value of the EsmEnablementAccount field in EsmEnablementAccountSetting as +// a EsmEnablementAccount value. +// If the field is unknown or null, the boolean return value is false. +func (o *EsmEnablementAccountSetting) GetEsmEnablementAccount(ctx context.Context) (EsmEnablementAccount, bool) { + var e EsmEnablementAccount + if o.EsmEnablementAccount.IsNull() || o.EsmEnablementAccount.IsUnknown() { + return e, false + } + var v []EsmEnablementAccount + d := o.EsmEnablementAccount.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEsmEnablementAccount sets the value of the EsmEnablementAccount field in EsmEnablementAccountSetting. +func (o *EsmEnablementAccountSetting) SetEsmEnablementAccount(ctx context.Context, v EsmEnablementAccount) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["esm_enablement_account"] + o.EsmEnablementAccount = types.ListValueMust(t, vs) +} + // The exchange token is the result of the token exchange with the IdP type ExchangeToken struct { // The requested token. @@ -2908,6 +3658,31 @@ func (o ExchangeToken) Type(ctx context.Context) attr.Type { } } +// GetScopes returns the value of the Scopes field in ExchangeToken as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExchangeToken) GetScopes(ctx context.Context) ([]types.String, bool) { + if o.Scopes.IsNull() || o.Scopes.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Scopes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScopes sets the value of the Scopes field in ExchangeToken. +func (o *ExchangeToken) SetScopes(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + o.Scopes = types.ListValueMust(t, vs) +} + // Exchange a token with the IdP type ExchangeTokenRequest struct { // The partition of Credentials store @@ -2969,6 +3744,82 @@ func (o ExchangeTokenRequest) Type(ctx context.Context) attr.Type { } } +// GetPartitionId returns the value of the PartitionId field in ExchangeTokenRequest as +// a PartitionId value. +// If the field is unknown or null, the boolean return value is false. +func (o *ExchangeTokenRequest) GetPartitionId(ctx context.Context) (PartitionId, bool) { + var e PartitionId + if o.PartitionId.IsNull() || o.PartitionId.IsUnknown() { + return e, false + } + var v []PartitionId + d := o.PartitionId.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPartitionId sets the value of the PartitionId field in ExchangeTokenRequest. +func (o *ExchangeTokenRequest) SetPartitionId(ctx context.Context, v PartitionId) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["partitionId"] + o.PartitionId = types.ListValueMust(t, vs) +} + +// GetScopes returns the value of the Scopes field in ExchangeTokenRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExchangeTokenRequest) GetScopes(ctx context.Context) ([]types.String, bool) { + if o.Scopes.IsNull() || o.Scopes.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Scopes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScopes sets the value of the Scopes field in ExchangeTokenRequest. +func (o *ExchangeTokenRequest) SetScopes(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + o.Scopes = types.ListValueMust(t, vs) +} + +// GetTokenType returns the value of the TokenType field in ExchangeTokenRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExchangeTokenRequest) GetTokenType(ctx context.Context) ([]types.String, bool) { + if o.TokenType.IsNull() || o.TokenType.IsUnknown() { + return nil, false + } + var v []types.String + d := o.TokenType.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTokenType sets the value of the TokenType field in ExchangeTokenRequest. +func (o *ExchangeTokenRequest) SetTokenType(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tokenType"] + o.TokenType = types.ListValueMust(t, vs) +} + // Exhanged tokens were successfully returned. type ExchangeTokenResponse struct { Values types.List `tfsdk:"values" tf:"optional"` @@ -3015,6 +3866,31 @@ func (o ExchangeTokenResponse) Type(ctx context.Context) attr.Type { } } +// GetValues returns the value of the Values field in ExchangeTokenResponse as +// a slice of ExchangeToken values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExchangeTokenResponse) GetValues(ctx context.Context) ([]ExchangeToken, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []ExchangeToken + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in ExchangeTokenResponse. +func (o *ExchangeTokenResponse) SetValues(ctx context.Context, v []ExchangeToken) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + o.Values = types.ListValueMust(t, vs) +} + // An IP access list was successfully returned. type FetchIpAccessListResponse struct { // Definition of an IP Access list @@ -3062,6 +3938,32 @@ func (o FetchIpAccessListResponse) Type(ctx context.Context) attr.Type { } } +// GetIpAccessList returns the value of the IpAccessList field in FetchIpAccessListResponse as +// a IpAccessListInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *FetchIpAccessListResponse) GetIpAccessList(ctx context.Context) (IpAccessListInfo, bool) { + var e IpAccessListInfo + if o.IpAccessList.IsNull() || o.IpAccessList.IsUnknown() { + return e, false + } + var v []IpAccessListInfo + d := o.IpAccessList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIpAccessList sets the value of the IpAccessList field in FetchIpAccessListResponse. +func (o *FetchIpAccessListResponse) SetIpAccessList(ctx context.Context, v IpAccessListInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_list"] + o.IpAccessList = types.ListValueMust(t, vs) +} + type GenericWebhookConfig struct { // [Input-Only][Optional] Password for webhook. Password types.String `tfsdk:"password" tf:"optional"` @@ -3795,6 +4697,32 @@ func (o GetIpAccessListResponse) Type(ctx context.Context) attr.Type { } } +// GetIpAccessList returns the value of the IpAccessList field in GetIpAccessListResponse as +// a IpAccessListInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetIpAccessListResponse) GetIpAccessList(ctx context.Context) (IpAccessListInfo, bool) { + var e IpAccessListInfo + if o.IpAccessList.IsNull() || o.IpAccessList.IsUnknown() { + return e, false + } + var v []IpAccessListInfo + d := o.IpAccessList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIpAccessList sets the value of the IpAccessList field in GetIpAccessListResponse. +func (o *GetIpAccessListResponse) SetIpAccessList(ctx context.Context, v IpAccessListInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_list"] + o.IpAccessList = types.ListValueMust(t, vs) +} + // IP access lists were successfully returned. type GetIpAccessListsResponse struct { IpAccessLists types.List `tfsdk:"ip_access_lists" tf:"optional"` @@ -3841,10 +4769,35 @@ func (o GetIpAccessListsResponse) Type(ctx context.Context) attr.Type { } } -// Get a network connectivity configuration -type GetNetworkConnectivityConfigurationRequest struct { - // Your Network Connectvity Configuration ID. - NetworkConnectivityConfigId types.String `tfsdk:"-"` +// GetIpAccessLists returns the value of the IpAccessLists field in GetIpAccessListsResponse as +// a slice of IpAccessListInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetIpAccessListsResponse) GetIpAccessLists(ctx context.Context) ([]IpAccessListInfo, bool) { + if o.IpAccessLists.IsNull() || o.IpAccessLists.IsUnknown() { + return nil, false + } + var v []IpAccessListInfo + d := o.IpAccessLists.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIpAccessLists sets the value of the IpAccessLists field in GetIpAccessListsResponse. +func (o *GetIpAccessListsResponse) SetIpAccessLists(ctx context.Context, v []IpAccessListInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_lists"] + o.IpAccessLists = types.ListValueMust(t, vs) +} + +// Get a network connectivity configuration +type GetNetworkConnectivityConfigurationRequest struct { + // Your Network Connectvity Configuration ID. + NetworkConnectivityConfigId types.String `tfsdk:"-"` } func (newState *GetNetworkConnectivityConfigurationRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetNetworkConnectivityConfigurationRequest) { @@ -4202,6 +5155,31 @@ func (o GetTokenPermissionLevelsResponse) Type(ctx context.Context) attr.Type { } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetTokenPermissionLevelsResponse as +// a slice of TokenPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetTokenPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]TokenPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []TokenPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetTokenPermissionLevelsResponse. +func (o *GetTokenPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []TokenPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Token with specified Token ID was successfully returned. type GetTokenResponse struct { TokenInfo types.List `tfsdk:"token_info" tf:"optional,object"` @@ -4248,6 +5226,32 @@ func (o GetTokenResponse) Type(ctx context.Context) attr.Type { } } +// GetTokenInfo returns the value of the TokenInfo field in GetTokenResponse as +// a TokenInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetTokenResponse) GetTokenInfo(ctx context.Context) (TokenInfo, bool) { + var e TokenInfo + if o.TokenInfo.IsNull() || o.TokenInfo.IsUnknown() { + return e, false + } + var v []TokenInfo + d := o.TokenInfo.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTokenInfo sets the value of the TokenInfo field in GetTokenResponse. +func (o *GetTokenResponse) SetTokenInfo(ctx context.Context, v TokenInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_info"] + o.TokenInfo = types.ListValueMust(t, vs) +} + // Definition of an IP Access list type IpAccessListInfo struct { // Total number of IP or CIDR values. @@ -4336,6 +5340,31 @@ func (o IpAccessListInfo) Type(ctx context.Context) attr.Type { } } +// GetIpAddresses returns the value of the IpAddresses field in IpAccessListInfo as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *IpAccessListInfo) GetIpAddresses(ctx context.Context) ([]types.String, bool) { + if o.IpAddresses.IsNull() || o.IpAddresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.IpAddresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIpAddresses sets the value of the IpAddresses field in IpAccessListInfo. +func (o *IpAccessListInfo) SetIpAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + o.IpAddresses = types.ListValueMust(t, vs) +} + // IP access lists were successfully returned. type ListIpAccessListResponse struct { IpAccessLists types.List `tfsdk:"ip_access_lists" tf:"optional"` @@ -4382,6 +5411,31 @@ func (o ListIpAccessListResponse) Type(ctx context.Context) attr.Type { } } +// GetIpAccessLists returns the value of the IpAccessLists field in ListIpAccessListResponse as +// a slice of IpAccessListInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListIpAccessListResponse) GetIpAccessLists(ctx context.Context) ([]IpAccessListInfo, bool) { + if o.IpAccessLists.IsNull() || o.IpAccessLists.IsUnknown() { + return nil, false + } + var v []IpAccessListInfo + d := o.IpAccessLists.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIpAccessLists sets the value of the IpAccessLists field in ListIpAccessListResponse. +func (o *ListIpAccessListResponse) SetIpAccessLists(ctx context.Context, v []IpAccessListInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_lists"] + o.IpAccessLists = types.ListValueMust(t, vs) +} + type ListNccAzurePrivateEndpointRulesResponse struct { Items types.List `tfsdk:"items" tf:"optional"` // A token that can be used to get the next page of results. If null, there @@ -4432,6 +5486,31 @@ func (o ListNccAzurePrivateEndpointRulesResponse) Type(ctx context.Context) attr } } +// GetItems returns the value of the Items field in ListNccAzurePrivateEndpointRulesResponse as +// a slice of NccAzurePrivateEndpointRule values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListNccAzurePrivateEndpointRulesResponse) GetItems(ctx context.Context) ([]NccAzurePrivateEndpointRule, bool) { + if o.Items.IsNull() || o.Items.IsUnknown() { + return nil, false + } + var v []NccAzurePrivateEndpointRule + d := o.Items.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetItems sets the value of the Items field in ListNccAzurePrivateEndpointRulesResponse. +func (o *ListNccAzurePrivateEndpointRulesResponse) SetItems(ctx context.Context, v []NccAzurePrivateEndpointRule) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["items"] + o.Items = types.ListValueMust(t, vs) +} + // List network connectivity configurations type ListNetworkConnectivityConfigurationsRequest struct { // Pagination token to go to next page based on previous query. @@ -4525,6 +5604,31 @@ func (o ListNetworkConnectivityConfigurationsResponse) Type(ctx context.Context) } } +// GetItems returns the value of the Items field in ListNetworkConnectivityConfigurationsResponse as +// a slice of NetworkConnectivityConfiguration values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListNetworkConnectivityConfigurationsResponse) GetItems(ctx context.Context) ([]NetworkConnectivityConfiguration, bool) { + if o.Items.IsNull() || o.Items.IsUnknown() { + return nil, false + } + var v []NetworkConnectivityConfiguration + d := o.Items.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetItems sets the value of the Items field in ListNetworkConnectivityConfigurationsResponse. +func (o *ListNetworkConnectivityConfigurationsResponse) SetItems(ctx context.Context, v []NetworkConnectivityConfiguration) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["items"] + o.Items = types.ListValueMust(t, vs) +} + // List notification destinations type ListNotificationDestinationsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -4621,6 +5725,31 @@ func (o ListNotificationDestinationsResponse) Type(ctx context.Context) attr.Typ } } +// GetResults returns the value of the Results field in ListNotificationDestinationsResponse as +// a slice of ListNotificationDestinationsResult values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListNotificationDestinationsResponse) GetResults(ctx context.Context) ([]ListNotificationDestinationsResult, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []ListNotificationDestinationsResult + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ListNotificationDestinationsResponse. +func (o *ListNotificationDestinationsResponse) SetResults(ctx context.Context, v []ListNotificationDestinationsResult) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + type ListNotificationDestinationsResult struct { // [Output-only] The type of the notification destination. The type can not // be changed once set. @@ -4765,6 +5894,31 @@ func (o ListPublicTokensResponse) Type(ctx context.Context) attr.Type { } } +// GetTokenInfos returns the value of the TokenInfos field in ListPublicTokensResponse as +// a slice of PublicTokenInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListPublicTokensResponse) GetTokenInfos(ctx context.Context) ([]PublicTokenInfo, bool) { + if o.TokenInfos.IsNull() || o.TokenInfos.IsUnknown() { + return nil, false + } + var v []PublicTokenInfo + d := o.TokenInfos.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTokenInfos sets the value of the TokenInfos field in ListPublicTokensResponse. +func (o *ListPublicTokensResponse) SetTokenInfos(ctx context.Context, v []PublicTokenInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_infos"] + o.TokenInfos = types.ListValueMust(t, vs) +} + // List all tokens type ListTokenManagementRequest struct { // User ID of the user that created the token. @@ -4859,6 +6013,31 @@ func (o ListTokensResponse) Type(ctx context.Context) attr.Type { } } +// GetTokenInfos returns the value of the TokenInfos field in ListTokensResponse as +// a slice of TokenInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListTokensResponse) GetTokenInfos(ctx context.Context) ([]TokenInfo, bool) { + if o.TokenInfos.IsNull() || o.TokenInfos.IsUnknown() { + return nil, false + } + var v []TokenInfo + d := o.TokenInfos.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTokenInfos sets the value of the TokenInfos field in ListTokensResponse. +func (o *ListTokensResponse) SetTokenInfos(ctx context.Context, v []TokenInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_infos"] + o.TokenInfos = types.ListValueMust(t, vs) +} + type MicrosoftTeamsConfig struct { // [Input-Only] URL for Microsoft Teams. Url types.String `tfsdk:"url" tf:"optional"` @@ -4954,6 +6133,31 @@ func (o NccAwsStableIpRule) Type(ctx context.Context) attr.Type { } } +// GetCidrBlocks returns the value of the CidrBlocks field in NccAwsStableIpRule as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *NccAwsStableIpRule) GetCidrBlocks(ctx context.Context) ([]types.String, bool) { + if o.CidrBlocks.IsNull() || o.CidrBlocks.IsUnknown() { + return nil, false + } + var v []types.String + d := o.CidrBlocks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCidrBlocks sets the value of the CidrBlocks field in NccAwsStableIpRule. +func (o *NccAwsStableIpRule) SetCidrBlocks(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cidr_blocks"] + o.CidrBlocks = types.ListValueMust(t, vs) +} + type NccAzurePrivateEndpointRule struct { // The current status of this private endpoint. The private endpoint rules // are effective only if the connection state is `ESTABLISHED`. Remember @@ -5108,6 +6312,56 @@ func (o NccAzureServiceEndpointRule) Type(ctx context.Context) attr.Type { } } +// GetSubnets returns the value of the Subnets field in NccAzureServiceEndpointRule as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *NccAzureServiceEndpointRule) GetSubnets(ctx context.Context) ([]types.String, bool) { + if o.Subnets.IsNull() || o.Subnets.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Subnets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSubnets sets the value of the Subnets field in NccAzureServiceEndpointRule. +func (o *NccAzureServiceEndpointRule) SetSubnets(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subnets"] + o.Subnets = types.ListValueMust(t, vs) +} + +// GetTargetServices returns the value of the TargetServices field in NccAzureServiceEndpointRule as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *NccAzureServiceEndpointRule) GetTargetServices(ctx context.Context) ([]types.String, bool) { + if o.TargetServices.IsNull() || o.TargetServices.IsUnknown() { + return nil, false + } + var v []types.String + d := o.TargetServices.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTargetServices sets the value of the TargetServices field in NccAzureServiceEndpointRule. +func (o *NccAzureServiceEndpointRule) SetTargetServices(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["target_services"] + o.TargetServices = types.ListValueMust(t, vs) +} + // The network connectivity rules that apply to network traffic from your // serverless compute resources. type NccEgressConfig struct { @@ -5166,6 +6420,58 @@ func (o NccEgressConfig) Type(ctx context.Context) attr.Type { } } +// GetDefaultRules returns the value of the DefaultRules field in NccEgressConfig as +// a NccEgressDefaultRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *NccEgressConfig) GetDefaultRules(ctx context.Context) (NccEgressDefaultRules, bool) { + var e NccEgressDefaultRules + if o.DefaultRules.IsNull() || o.DefaultRules.IsUnknown() { + return e, false + } + var v []NccEgressDefaultRules + d := o.DefaultRules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDefaultRules sets the value of the DefaultRules field in NccEgressConfig. +func (o *NccEgressConfig) SetDefaultRules(ctx context.Context, v NccEgressDefaultRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_rules"] + o.DefaultRules = types.ListValueMust(t, vs) +} + +// GetTargetRules returns the value of the TargetRules field in NccEgressConfig as +// a NccEgressTargetRules value. +// If the field is unknown or null, the boolean return value is false. +func (o *NccEgressConfig) GetTargetRules(ctx context.Context) (NccEgressTargetRules, bool) { + var e NccEgressTargetRules + if o.TargetRules.IsNull() || o.TargetRules.IsUnknown() { + return e, false + } + var v []NccEgressTargetRules + d := o.TargetRules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTargetRules sets the value of the TargetRules field in NccEgressConfig. +func (o *NccEgressConfig) SetTargetRules(ctx context.Context, v NccEgressTargetRules) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["target_rules"] + o.TargetRules = types.ListValueMust(t, vs) +} + // The network connectivity rules that are applied by default without resource // specific configurations. You can find the stable network information of your // serverless compute resources here. @@ -5226,6 +6532,58 @@ func (o NccEgressDefaultRules) Type(ctx context.Context) attr.Type { } } +// GetAwsStableIpRule returns the value of the AwsStableIpRule field in NccEgressDefaultRules as +// a NccAwsStableIpRule value. +// If the field is unknown or null, the boolean return value is false. +func (o *NccEgressDefaultRules) GetAwsStableIpRule(ctx context.Context) (NccAwsStableIpRule, bool) { + var e NccAwsStableIpRule + if o.AwsStableIpRule.IsNull() || o.AwsStableIpRule.IsUnknown() { + return e, false + } + var v []NccAwsStableIpRule + d := o.AwsStableIpRule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAwsStableIpRule sets the value of the AwsStableIpRule field in NccEgressDefaultRules. +func (o *NccEgressDefaultRules) SetAwsStableIpRule(ctx context.Context, v NccAwsStableIpRule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aws_stable_ip_rule"] + o.AwsStableIpRule = types.ListValueMust(t, vs) +} + +// GetAzureServiceEndpointRule returns the value of the AzureServiceEndpointRule field in NccEgressDefaultRules as +// a NccAzureServiceEndpointRule value. +// If the field is unknown or null, the boolean return value is false. +func (o *NccEgressDefaultRules) GetAzureServiceEndpointRule(ctx context.Context) (NccAzureServiceEndpointRule, bool) { + var e NccAzureServiceEndpointRule + if o.AzureServiceEndpointRule.IsNull() || o.AzureServiceEndpointRule.IsUnknown() { + return e, false + } + var v []NccAzureServiceEndpointRule + d := o.AzureServiceEndpointRule.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAzureServiceEndpointRule sets the value of the AzureServiceEndpointRule field in NccEgressDefaultRules. +func (o *NccEgressDefaultRules) SetAzureServiceEndpointRule(ctx context.Context, v NccAzureServiceEndpointRule) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_service_endpoint_rule"] + o.AzureServiceEndpointRule = types.ListValueMust(t, vs) +} + // The network connectivity rules that configured for each destinations. These // rules override default rules. type NccEgressTargetRules struct { @@ -5273,6 +6631,31 @@ func (o NccEgressTargetRules) Type(ctx context.Context) attr.Type { } } +// GetAzurePrivateEndpointRules returns the value of the AzurePrivateEndpointRules field in NccEgressTargetRules as +// a slice of NccAzurePrivateEndpointRule values. +// If the field is unknown or null, the boolean return value is false. +func (o *NccEgressTargetRules) GetAzurePrivateEndpointRules(ctx context.Context) ([]NccAzurePrivateEndpointRule, bool) { + if o.AzurePrivateEndpointRules.IsNull() || o.AzurePrivateEndpointRules.IsUnknown() { + return nil, false + } + var v []NccAzurePrivateEndpointRule + d := o.AzurePrivateEndpointRules.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAzurePrivateEndpointRules sets the value of the AzurePrivateEndpointRules field in NccEgressTargetRules. +func (o *NccEgressTargetRules) SetAzurePrivateEndpointRules(ctx context.Context, v []NccAzurePrivateEndpointRule) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_private_endpoint_rules"] + o.AzurePrivateEndpointRules = types.ListValueMust(t, vs) +} + type NetworkConnectivityConfiguration struct { // The Databricks account ID that hosts the credential. AccountId types.String `tfsdk:"account_id" tf:"optional"` @@ -5349,6 +6732,32 @@ func (o NetworkConnectivityConfiguration) Type(ctx context.Context) attr.Type { } } +// GetEgressConfig returns the value of the EgressConfig field in NetworkConnectivityConfiguration as +// a NccEgressConfig value. +// If the field is unknown or null, the boolean return value is false. +func (o *NetworkConnectivityConfiguration) GetEgressConfig(ctx context.Context) (NccEgressConfig, bool) { + var e NccEgressConfig + if o.EgressConfig.IsNull() || o.EgressConfig.IsUnknown() { + return e, false + } + var v []NccEgressConfig + d := o.EgressConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEgressConfig sets the value of the EgressConfig field in NetworkConnectivityConfiguration. +func (o *NetworkConnectivityConfiguration) SetEgressConfig(ctx context.Context, v NccEgressConfig) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["egress_config"] + o.EgressConfig = types.ListValueMust(t, vs) +} + type NotificationDestination struct { // The configuration for the notification destination. Will be exactly one // of the nested configs. Only returns for users with workspace admin @@ -5410,6 +6819,32 @@ func (o NotificationDestination) Type(ctx context.Context) attr.Type { } } +// GetConfig returns the value of the Config field in NotificationDestination as +// a Config value. +// If the field is unknown or null, the boolean return value is false. +func (o *NotificationDestination) GetConfig(ctx context.Context) (Config, bool) { + var e Config + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []Config + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in NotificationDestination. +func (o *NotificationDestination) SetConfig(ctx context.Context, v Config) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + type PagerdutyConfig struct { // [Input-Only] Integration key for PagerDuty. IntegrationKey types.String `tfsdk:"integration_key" tf:"optional"` @@ -5611,6 +7046,32 @@ func (o PersonalComputeSetting) Type(ctx context.Context) attr.Type { } } +// GetPersonalCompute returns the value of the PersonalCompute field in PersonalComputeSetting as +// a PersonalComputeMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *PersonalComputeSetting) GetPersonalCompute(ctx context.Context) (PersonalComputeMessage, bool) { + var e PersonalComputeMessage + if o.PersonalCompute.IsNull() || o.PersonalCompute.IsUnknown() { + return e, false + } + var v []PersonalComputeMessage + d := o.PersonalCompute.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPersonalCompute sets the value of the PersonalCompute field in PersonalComputeSetting. +func (o *PersonalComputeSetting) SetPersonalCompute(ctx context.Context, v PersonalComputeMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["personal_compute"] + o.PersonalCompute = types.ListValueMust(t, vs) +} + type PublicTokenInfo struct { // Comment the token was created with, if applicable. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -5734,6 +7195,31 @@ func (o ReplaceIpAccessList) Type(ctx context.Context) attr.Type { } } +// GetIpAddresses returns the value of the IpAddresses field in ReplaceIpAccessList as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ReplaceIpAccessList) GetIpAddresses(ctx context.Context) ([]types.String, bool) { + if o.IpAddresses.IsNull() || o.IpAddresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.IpAddresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIpAddresses sets the value of the IpAddresses field in ReplaceIpAccessList. +func (o *ReplaceIpAccessList) SetIpAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + o.IpAddresses = types.ListValueMust(t, vs) +} + type ReplaceResponse struct { } @@ -5875,6 +7361,32 @@ func (o RestrictWorkspaceAdminsSetting) Type(ctx context.Context) attr.Type { } } +// GetRestrictWorkspaceAdmins returns the value of the RestrictWorkspaceAdmins field in RestrictWorkspaceAdminsSetting as +// a RestrictWorkspaceAdminsMessage value. +// If the field is unknown or null, the boolean return value is false. +func (o *RestrictWorkspaceAdminsSetting) GetRestrictWorkspaceAdmins(ctx context.Context) (RestrictWorkspaceAdminsMessage, bool) { + var e RestrictWorkspaceAdminsMessage + if o.RestrictWorkspaceAdmins.IsNull() || o.RestrictWorkspaceAdmins.IsUnknown() { + return e, false + } + var v []RestrictWorkspaceAdminsMessage + d := o.RestrictWorkspaceAdmins.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRestrictWorkspaceAdmins sets the value of the RestrictWorkspaceAdmins field in RestrictWorkspaceAdminsSetting. +func (o *RestrictWorkspaceAdminsSetting) SetRestrictWorkspaceAdmins(ctx context.Context, v RestrictWorkspaceAdminsMessage) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["restrict_workspace_admins"] + o.RestrictWorkspaceAdmins = types.ListValueMust(t, vs) +} + type RevokeTokenRequest struct { // The ID of the token to be revoked. TokenId types.String `tfsdk:"token_id" tf:""` @@ -6193,6 +7705,31 @@ func (o TokenAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in TokenAccessControlResponse as +// a slice of TokenPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *TokenAccessControlResponse) GetAllPermissions(ctx context.Context) ([]TokenPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []TokenPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in TokenAccessControlResponse. +func (o *TokenAccessControlResponse) SetAllPermissions(ctx context.Context, v []TokenPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type TokenInfo struct { // Comment that describes the purpose of the token, specified by the token // creator. @@ -6322,6 +7859,31 @@ func (o TokenPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in TokenPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TokenPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in TokenPermission. +func (o *TokenPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type TokenPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -6375,6 +7937,31 @@ func (o TokenPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in TokenPermissions as +// a slice of TokenAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *TokenPermissions) GetAccessControlList(ctx context.Context) ([]TokenAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []TokenAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in TokenPermissions. +func (o *TokenPermissions) SetAccessControlList(ctx context.Context, v []TokenAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type TokenPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -6465,6 +8052,31 @@ func (o TokenPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in TokenPermissionsRequest as +// a slice of TokenAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *TokenPermissionsRequest) GetAccessControlList(ctx context.Context) ([]TokenAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []TokenAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in TokenPermissionsRequest. +func (o *TokenPermissionsRequest) SetAccessControlList(ctx context.Context, v []TokenAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateAibiDashboardEmbeddingAccessPolicySettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6524,6 +8136,32 @@ func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) Type(ctx context } } +// GetSetting returns the value of the Setting field in UpdateAibiDashboardEmbeddingAccessPolicySettingRequest as +// a AibiDashboardEmbeddingAccessPolicySetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) GetSetting(ctx context.Context) (AibiDashboardEmbeddingAccessPolicySetting, bool) { + var e AibiDashboardEmbeddingAccessPolicySetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []AibiDashboardEmbeddingAccessPolicySetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateAibiDashboardEmbeddingAccessPolicySettingRequest. +func (o *UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) SetSetting(ctx context.Context, v AibiDashboardEmbeddingAccessPolicySetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6583,6 +8221,32 @@ func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) Type(ctx cont } } +// GetSetting returns the value of the Setting field in UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest as +// a AibiDashboardEmbeddingApprovedDomainsSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) GetSetting(ctx context.Context) (AibiDashboardEmbeddingApprovedDomainsSetting, bool) { + var e AibiDashboardEmbeddingApprovedDomainsSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []AibiDashboardEmbeddingApprovedDomainsSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest. +func (o *UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) SetSetting(ctx context.Context, v AibiDashboardEmbeddingApprovedDomainsSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateAutomaticClusterUpdateSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6642,6 +8306,32 @@ func (o UpdateAutomaticClusterUpdateSettingRequest) Type(ctx context.Context) at } } +// GetSetting returns the value of the Setting field in UpdateAutomaticClusterUpdateSettingRequest as +// a AutomaticClusterUpdateSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateAutomaticClusterUpdateSettingRequest) GetSetting(ctx context.Context) (AutomaticClusterUpdateSetting, bool) { + var e AutomaticClusterUpdateSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []AutomaticClusterUpdateSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateAutomaticClusterUpdateSettingRequest. +func (o *UpdateAutomaticClusterUpdateSettingRequest) SetSetting(ctx context.Context, v AutomaticClusterUpdateSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateComplianceSecurityProfileSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6701,6 +8391,32 @@ func (o UpdateComplianceSecurityProfileSettingRequest) Type(ctx context.Context) } } +// GetSetting returns the value of the Setting field in UpdateComplianceSecurityProfileSettingRequest as +// a ComplianceSecurityProfileSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateComplianceSecurityProfileSettingRequest) GetSetting(ctx context.Context) (ComplianceSecurityProfileSetting, bool) { + var e ComplianceSecurityProfileSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []ComplianceSecurityProfileSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateComplianceSecurityProfileSettingRequest. +func (o *UpdateComplianceSecurityProfileSettingRequest) SetSetting(ctx context.Context, v ComplianceSecurityProfileSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateCspEnablementAccountSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6760,6 +8476,32 @@ func (o UpdateCspEnablementAccountSettingRequest) Type(ctx context.Context) attr } } +// GetSetting returns the value of the Setting field in UpdateCspEnablementAccountSettingRequest as +// a CspEnablementAccountSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateCspEnablementAccountSettingRequest) GetSetting(ctx context.Context) (CspEnablementAccountSetting, bool) { + var e CspEnablementAccountSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []CspEnablementAccountSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateCspEnablementAccountSettingRequest. +func (o *UpdateCspEnablementAccountSettingRequest) SetSetting(ctx context.Context, v CspEnablementAccountSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateDefaultNamespaceSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6827,6 +8569,32 @@ func (o UpdateDefaultNamespaceSettingRequest) Type(ctx context.Context) attr.Typ } } +// GetSetting returns the value of the Setting field in UpdateDefaultNamespaceSettingRequest as +// a DefaultNamespaceSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateDefaultNamespaceSettingRequest) GetSetting(ctx context.Context) (DefaultNamespaceSetting, bool) { + var e DefaultNamespaceSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []DefaultNamespaceSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateDefaultNamespaceSettingRequest. +func (o *UpdateDefaultNamespaceSettingRequest) SetSetting(ctx context.Context, v DefaultNamespaceSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateDisableLegacyAccessRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6886,6 +8654,32 @@ func (o UpdateDisableLegacyAccessRequest) Type(ctx context.Context) attr.Type { } } +// GetSetting returns the value of the Setting field in UpdateDisableLegacyAccessRequest as +// a DisableLegacyAccess value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateDisableLegacyAccessRequest) GetSetting(ctx context.Context) (DisableLegacyAccess, bool) { + var e DisableLegacyAccess + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []DisableLegacyAccess + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateDisableLegacyAccessRequest. +func (o *UpdateDisableLegacyAccessRequest) SetSetting(ctx context.Context, v DisableLegacyAccess) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateDisableLegacyDbfsRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -6945,6 +8739,32 @@ func (o UpdateDisableLegacyDbfsRequest) Type(ctx context.Context) attr.Type { } } +// GetSetting returns the value of the Setting field in UpdateDisableLegacyDbfsRequest as +// a DisableLegacyDbfs value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateDisableLegacyDbfsRequest) GetSetting(ctx context.Context) (DisableLegacyDbfs, bool) { + var e DisableLegacyDbfs + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []DisableLegacyDbfs + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateDisableLegacyDbfsRequest. +func (o *UpdateDisableLegacyDbfsRequest) SetSetting(ctx context.Context, v DisableLegacyDbfs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateDisableLegacyFeaturesRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -7004,6 +8824,32 @@ func (o UpdateDisableLegacyFeaturesRequest) Type(ctx context.Context) attr.Type } } +// GetSetting returns the value of the Setting field in UpdateDisableLegacyFeaturesRequest as +// a DisableLegacyFeatures value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateDisableLegacyFeaturesRequest) GetSetting(ctx context.Context) (DisableLegacyFeatures, bool) { + var e DisableLegacyFeatures + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []DisableLegacyFeatures + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateDisableLegacyFeaturesRequest. +func (o *UpdateDisableLegacyFeaturesRequest) SetSetting(ctx context.Context, v DisableLegacyFeatures) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateEnhancedSecurityMonitoringSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -7063,6 +8909,32 @@ func (o UpdateEnhancedSecurityMonitoringSettingRequest) Type(ctx context.Context } } +// GetSetting returns the value of the Setting field in UpdateEnhancedSecurityMonitoringSettingRequest as +// a EnhancedSecurityMonitoringSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateEnhancedSecurityMonitoringSettingRequest) GetSetting(ctx context.Context) (EnhancedSecurityMonitoringSetting, bool) { + var e EnhancedSecurityMonitoringSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []EnhancedSecurityMonitoringSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateEnhancedSecurityMonitoringSettingRequest. +func (o *UpdateEnhancedSecurityMonitoringSettingRequest) SetSetting(ctx context.Context, v EnhancedSecurityMonitoringSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdateEsmEnablementAccountSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -7122,6 +8994,32 @@ func (o UpdateEsmEnablementAccountSettingRequest) Type(ctx context.Context) attr } } +// GetSetting returns the value of the Setting field in UpdateEsmEnablementAccountSettingRequest as +// a EsmEnablementAccountSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateEsmEnablementAccountSettingRequest) GetSetting(ctx context.Context) (EsmEnablementAccountSetting, bool) { + var e EsmEnablementAccountSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []EsmEnablementAccountSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdateEsmEnablementAccountSettingRequest. +func (o *UpdateEsmEnablementAccountSettingRequest) SetSetting(ctx context.Context, v EsmEnablementAccountSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + // Details required to update an IP access list. type UpdateIpAccessList struct { // Specifies whether this IP access list is enabled. @@ -7190,6 +9088,31 @@ func (o UpdateIpAccessList) Type(ctx context.Context) attr.Type { } } +// GetIpAddresses returns the value of the IpAddresses field in UpdateIpAccessList as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateIpAccessList) GetIpAddresses(ctx context.Context) ([]types.String, bool) { + if o.IpAddresses.IsNull() || o.IpAddresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.IpAddresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetIpAddresses sets the value of the IpAddresses field in UpdateIpAccessList. +func (o *UpdateIpAccessList) SetIpAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + o.IpAddresses = types.ListValueMust(t, vs) +} + type UpdateNotificationDestinationRequest struct { // The configuration for the notification destination. Must wrap EXACTLY one // of the nested configs. @@ -7245,6 +9168,32 @@ func (o UpdateNotificationDestinationRequest) Type(ctx context.Context) attr.Typ } } +// GetConfig returns the value of the Config field in UpdateNotificationDestinationRequest as +// a Config value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateNotificationDestinationRequest) GetConfig(ctx context.Context) (Config, bool) { + var e Config + if o.Config.IsNull() || o.Config.IsUnknown() { + return e, false + } + var v []Config + d := o.Config.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfig sets the value of the Config field in UpdateNotificationDestinationRequest. +func (o *UpdateNotificationDestinationRequest) SetConfig(ctx context.Context, v Config) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config"] + o.Config = types.ListValueMust(t, vs) +} + // Details required to update a setting. type UpdatePersonalComputeSettingRequest struct { // This should always be set to true for Settings API. Added for AIP @@ -7304,6 +9253,32 @@ func (o UpdatePersonalComputeSettingRequest) Type(ctx context.Context) attr.Type } } +// GetSetting returns the value of the Setting field in UpdatePersonalComputeSettingRequest as +// a PersonalComputeSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdatePersonalComputeSettingRequest) GetSetting(ctx context.Context) (PersonalComputeSetting, bool) { + var e PersonalComputeSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []PersonalComputeSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSetting sets the value of the Setting field in UpdatePersonalComputeSettingRequest. +func (o *UpdatePersonalComputeSettingRequest) SetSetting(ctx context.Context, v PersonalComputeSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} + type UpdateResponse struct { } @@ -7399,43 +9374,28 @@ func (o UpdateRestrictWorkspaceAdminsSettingRequest) Type(ctx context.Context) a } } -// Compliance stardard for SHIELD customers - -// The sub-resource type (group ID) of the target resource. Note that to connect -// to workspace root storage (root DBFS), you need two endpoints, one for `blob` -// and one for `dfs`. - -// Type of IP access list. Valid values are as follows and are case-sensitive: -// -// * `ALLOW`: An allow list. Include this IP or range. * `BLOCK`: A block list. -// Exclude this IP or range. IP addresses in the block list are excluded even if -// they are included in an allow list. - -// The current status of this private endpoint. The private endpoint rules are -// effective only if the connection state is `ESTABLISHED`. Remember that you -// must approve new endpoints on your resources in the Azure portal before they -// take effect. -// -// The possible values are: - INIT: (deprecated) The endpoint has been created -// and pending approval. - PENDING: The endpoint has been created and pending -// approval. - ESTABLISHED: The endpoint has been approved and is ready to use -// in your serverless compute resources. - REJECTED: Connection was rejected by -// the private link resource owner. - DISCONNECTED: Connection was removed by -// the private link resource owner, the private endpoint becomes informative and -// should be deleted for clean-up. - -// The sub-resource type (group ID) of the target resource. Note that to connect -// to workspace root storage (root DBFS), you need two endpoints, one for `blob` -// and one for `dfs`. - -// ON: Grants all users in all workspaces access to the Personal Compute default -// policy, allowing all users to create single-machine compute resources. -// DELEGATE: Moves access control for the Personal Compute default policy to -// individual workspaces and requires a workspace’s users or groups to be -// added to the ACLs of that workspace’s Personal Compute default policy -// before they will be able to create compute resources through that policy. - -// Permission level +// GetSetting returns the value of the Setting field in UpdateRestrictWorkspaceAdminsSettingRequest as +// a RestrictWorkspaceAdminsSetting value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRestrictWorkspaceAdminsSettingRequest) GetSetting(ctx context.Context) (RestrictWorkspaceAdminsSetting, bool) { + var e RestrictWorkspaceAdminsSetting + if o.Setting.IsNull() || o.Setting.IsUnknown() { + return e, false + } + var v []RestrictWorkspaceAdminsSetting + d := o.Setting.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} -// The type of token request. As of now, only `AZURE_ACTIVE_DIRECTORY_TOKEN` is -// supported. +// SetSetting sets the value of the Setting field in UpdateRestrictWorkspaceAdminsSettingRequest. +func (o *UpdateRestrictWorkspaceAdminsSettingRequest) SetSetting(ctx context.Context, v RestrictWorkspaceAdminsSetting) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["setting"] + o.Setting = types.ListValueMust(t, vs) +} diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index f06778b763..1e75135dde 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -14,7 +14,7 @@ import ( "context" "reflect" - "github.com/databricks/databricks-sdk-go/service/catalog" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/databricks/terraform-provider-databricks/internal/service/catalog_tf" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" @@ -161,6 +161,58 @@ func (o CreateRecipient) Type(ctx context.Context) attr.Type { } } +// GetIpAccessList returns the value of the IpAccessList field in CreateRecipient as +// a IpAccessList value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRecipient) GetIpAccessList(ctx context.Context) (IpAccessList, bool) { + var e IpAccessList + if o.IpAccessList.IsNull() || o.IpAccessList.IsUnknown() { + return e, false + } + var v []IpAccessList + d := o.IpAccessList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIpAccessList sets the value of the IpAccessList field in CreateRecipient. +func (o *CreateRecipient) SetIpAccessList(ctx context.Context, v IpAccessList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_list"] + o.IpAccessList = types.ListValueMust(t, vs) +} + +// GetPropertiesKvpairs returns the value of the PropertiesKvpairs field in CreateRecipient as +// a SecurablePropertiesKvPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRecipient) GetPropertiesKvpairs(ctx context.Context) (SecurablePropertiesKvPairs, bool) { + var e SecurablePropertiesKvPairs + if o.PropertiesKvpairs.IsNull() || o.PropertiesKvpairs.IsUnknown() { + return e, false + } + var v []SecurablePropertiesKvPairs + d := o.PropertiesKvpairs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPropertiesKvpairs sets the value of the PropertiesKvpairs field in CreateRecipient. +func (o *CreateRecipient) SetPropertiesKvpairs(ctx context.Context, v SecurablePropertiesKvPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties_kvpairs"] + o.PropertiesKvpairs = types.ListValueMust(t, vs) +} + type CreateShare struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -593,6 +645,31 @@ func (o GetRecipientSharePermissionsResponse) Type(ctx context.Context) attr.Typ } } +// GetPermissionsOut returns the value of the PermissionsOut field in GetRecipientSharePermissionsResponse as +// a slice of ShareToPrivilegeAssignment values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetRecipientSharePermissionsResponse) GetPermissionsOut(ctx context.Context) ([]ShareToPrivilegeAssignment, bool) { + if o.PermissionsOut.IsNull() || o.PermissionsOut.IsUnknown() { + return nil, false + } + var v []ShareToPrivilegeAssignment + d := o.PermissionsOut.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionsOut sets the value of the PermissionsOut field in GetRecipientSharePermissionsResponse. +func (o *GetRecipientSharePermissionsResponse) SetPermissionsOut(ctx context.Context, v []ShareToPrivilegeAssignment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions_out"] + o.PermissionsOut = types.ListValueMust(t, vs) +} + // Get a share type GetShareRequest struct { // Query for data to include in the share. @@ -686,6 +763,31 @@ func (o IpAccessList) Type(ctx context.Context) attr.Type { } } +// GetAllowedIpAddresses returns the value of the AllowedIpAddresses field in IpAccessList as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *IpAccessList) GetAllowedIpAddresses(ctx context.Context) ([]types.String, bool) { + if o.AllowedIpAddresses.IsNull() || o.AllowedIpAddresses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.AllowedIpAddresses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllowedIpAddresses sets the value of the AllowedIpAddresses field in IpAccessList. +func (o *IpAccessList) SetAllowedIpAddresses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["allowed_ip_addresses"] + o.AllowedIpAddresses = types.ListValueMust(t, vs) +} + type ListProviderSharesResponse struct { // Opaque token to retrieve the next page of results. Absent if there are no // more pages. __page_token__ should be set to this value for the next @@ -738,6 +840,31 @@ func (o ListProviderSharesResponse) Type(ctx context.Context) attr.Type { } } +// GetShares returns the value of the Shares field in ListProviderSharesResponse as +// a slice of ProviderShare values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListProviderSharesResponse) GetShares(ctx context.Context) ([]ProviderShare, bool) { + if o.Shares.IsNull() || o.Shares.IsUnknown() { + return nil, false + } + var v []ProviderShare + d := o.Shares.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetShares sets the value of the Shares field in ListProviderSharesResponse. +func (o *ListProviderSharesResponse) SetShares(ctx context.Context, v []ProviderShare) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["shares"] + o.Shares = types.ListValueMust(t, vs) +} + // List providers type ListProvidersRequest struct { // If not provided, all providers will be returned. If no providers exist @@ -850,6 +977,31 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { } } +// GetProviders returns the value of the Providers field in ListProvidersResponse as +// a slice of ProviderInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListProvidersResponse) GetProviders(ctx context.Context) ([]ProviderInfo, bool) { + if o.Providers.IsNull() || o.Providers.IsUnknown() { + return nil, false + } + var v []ProviderInfo + d := o.Providers.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProviders sets the value of the Providers field in ListProvidersResponse. +func (o *ListProvidersResponse) SetProviders(ctx context.Context, v []ProviderInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["providers"] + o.Providers = types.ListValueMust(t, vs) +} + // List share recipients type ListRecipientsRequest struct { // If not provided, all recipients will be returned. If no recipients exist @@ -962,6 +1114,31 @@ func (o ListRecipientsResponse) Type(ctx context.Context) attr.Type { } } +// GetRecipients returns the value of the Recipients field in ListRecipientsResponse as +// a slice of RecipientInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListRecipientsResponse) GetRecipients(ctx context.Context) ([]RecipientInfo, bool) { + if o.Recipients.IsNull() || o.Recipients.IsUnknown() { + return nil, false + } + var v []RecipientInfo + d := o.Recipients.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRecipients sets the value of the Recipients field in ListRecipientsResponse. +func (o *ListRecipientsResponse) SetRecipients(ctx context.Context, v []RecipientInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["recipients"] + o.Recipients = types.ListValueMust(t, vs) +} + // List shares by Provider type ListSharesRequest struct { // Maximum number of shares to return. - when set to 0, the page length is @@ -1073,6 +1250,31 @@ func (o ListSharesResponse) Type(ctx context.Context) attr.Type { } } +// GetShares returns the value of the Shares field in ListSharesResponse as +// a slice of ShareInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListSharesResponse) GetShares(ctx context.Context) ([]ShareInfo, bool) { + if o.Shares.IsNull() || o.Shares.IsUnknown() { + return nil, false + } + var v []ShareInfo + d := o.Shares.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetShares sets the value of the Shares field in ListSharesResponse. +func (o *ListSharesResponse) SetShares(ctx context.Context, v []ShareInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["shares"] + o.Shares = types.ListValueMust(t, vs) +} + type Partition struct { // An array of partition values. Values types.List `tfsdk:"value" tf:"optional"` @@ -1119,6 +1321,31 @@ func (o Partition) Type(ctx context.Context) attr.Type { } } +// GetValues returns the value of the Values field in Partition as +// a slice of PartitionValue values. +// If the field is unknown or null, the boolean return value is false. +func (o *Partition) GetValues(ctx context.Context) ([]PartitionValue, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []PartitionValue + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in Partition. +func (o *Partition) SetValues(ctx context.Context, v []PartitionValue) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["value"] + o.Values = types.ListValueMust(t, vs) +} + type PartitionValue struct { // The name of the partition column. Name types.String `tfsdk:"name" tf:"optional"` @@ -1227,6 +1454,31 @@ func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { } } +// GetPrivileges returns the value of the Privileges field in PrivilegeAssignment as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *PrivilegeAssignment) GetPrivileges(ctx context.Context) ([]types.String, bool) { + if o.Privileges.IsNull() || o.Privileges.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Privileges.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrivileges sets the value of the Privileges field in PrivilegeAssignment. +func (o *PrivilegeAssignment) SetPrivileges(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privileges"] + o.Privileges = types.ListValueMust(t, vs) +} + type ProviderInfo struct { // The delta sharing authentication type. AuthenticationType types.String `tfsdk:"authentication_type" tf:"optional"` @@ -1332,6 +1584,32 @@ func (o ProviderInfo) Type(ctx context.Context) attr.Type { } } +// GetRecipientProfile returns the value of the RecipientProfile field in ProviderInfo as +// a RecipientProfile value. +// If the field is unknown or null, the boolean return value is false. +func (o *ProviderInfo) GetRecipientProfile(ctx context.Context) (RecipientProfile, bool) { + var e RecipientProfile + if o.RecipientProfile.IsNull() || o.RecipientProfile.IsUnknown() { + return e, false + } + var v []RecipientProfile + d := o.RecipientProfile.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetRecipientProfile sets the value of the RecipientProfile field in ProviderInfo. +func (o *ProviderInfo) SetRecipientProfile(ctx context.Context, v RecipientProfile) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["recipient_profile"] + o.RecipientProfile = types.ListValueMust(t, vs) +} + type ProviderShare struct { // The name of the Provider Share. Name types.String `tfsdk:"name" tf:"optional"` @@ -1503,6 +1781,83 @@ func (o RecipientInfo) Type(ctx context.Context) attr.Type { } } +// GetIpAccessList returns the value of the IpAccessList field in RecipientInfo as +// a IpAccessList value. +// If the field is unknown or null, the boolean return value is false. +func (o *RecipientInfo) GetIpAccessList(ctx context.Context) (IpAccessList, bool) { + var e IpAccessList + if o.IpAccessList.IsNull() || o.IpAccessList.IsUnknown() { + return e, false + } + var v []IpAccessList + d := o.IpAccessList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIpAccessList sets the value of the IpAccessList field in RecipientInfo. +func (o *RecipientInfo) SetIpAccessList(ctx context.Context, v IpAccessList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_list"] + o.IpAccessList = types.ListValueMust(t, vs) +} + +// GetPropertiesKvpairs returns the value of the PropertiesKvpairs field in RecipientInfo as +// a SecurablePropertiesKvPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *RecipientInfo) GetPropertiesKvpairs(ctx context.Context) (SecurablePropertiesKvPairs, bool) { + var e SecurablePropertiesKvPairs + if o.PropertiesKvpairs.IsNull() || o.PropertiesKvpairs.IsUnknown() { + return e, false + } + var v []SecurablePropertiesKvPairs + d := o.PropertiesKvpairs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPropertiesKvpairs sets the value of the PropertiesKvpairs field in RecipientInfo. +func (o *RecipientInfo) SetPropertiesKvpairs(ctx context.Context, v SecurablePropertiesKvPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties_kvpairs"] + o.PropertiesKvpairs = types.ListValueMust(t, vs) +} + +// GetTokens returns the value of the Tokens field in RecipientInfo as +// a slice of RecipientTokenInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *RecipientInfo) GetTokens(ctx context.Context) ([]RecipientTokenInfo, bool) { + if o.Tokens.IsNull() || o.Tokens.IsUnknown() { + return nil, false + } + var v []RecipientTokenInfo + d := o.Tokens.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTokens sets the value of the Tokens field in RecipientInfo. +func (o *RecipientInfo) SetTokens(ctx context.Context, v []RecipientTokenInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tokens"] + o.Tokens = types.ListValueMust(t, vs) +} + type RecipientProfile struct { // The token used to authorize the recipient. BearerToken types.String `tfsdk:"bearer_token" tf:"optional"` @@ -1814,6 +2169,31 @@ func (o SecurablePropertiesKvPairs) Type(ctx context.Context) attr.Type { } } +// GetProperties returns the value of the Properties field in SecurablePropertiesKvPairs as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SecurablePropertiesKvPairs) GetProperties(ctx context.Context) (map[string]types.String, bool) { + if o.Properties.IsNull() || o.Properties.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Properties.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetProperties sets the value of the Properties field in SecurablePropertiesKvPairs. +func (o *SecurablePropertiesKvPairs) SetProperties(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + o.Properties = types.MapValueMust(t, vs) +} + type ShareInfo struct { // User-provided free-form text description. Comment types.String `tfsdk:"comment" tf:"optional"` @@ -1896,6 +2276,31 @@ func (o ShareInfo) Type(ctx context.Context) attr.Type { } } +// GetObjects returns the value of the Objects field in ShareInfo as +// a slice of SharedDataObject values. +// If the field is unknown or null, the boolean return value is false. +func (o *ShareInfo) GetObjects(ctx context.Context) ([]SharedDataObject, bool) { + if o.Objects.IsNull() || o.Objects.IsUnknown() { + return nil, false + } + var v []SharedDataObject + d := o.Objects.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetObjects sets the value of the Objects field in ShareInfo. +func (o *ShareInfo) SetObjects(ctx context.Context, v []SharedDataObject) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["object"] + o.Objects = types.ListValueMust(t, vs) +} + // Get recipient share permissions type SharePermissionsRequest struct { // Maximum number of permissions to return. - when set to 0, the page length @@ -2005,6 +2410,31 @@ func (o ShareToPrivilegeAssignment) Type(ctx context.Context) attr.Type { } } +// GetPrivilegeAssignments returns the value of the PrivilegeAssignments field in ShareToPrivilegeAssignment as +// a slice of PrivilegeAssignment values. +// If the field is unknown or null, the boolean return value is false. +func (o *ShareToPrivilegeAssignment) GetPrivilegeAssignments(ctx context.Context) ([]PrivilegeAssignment, bool) { + if o.PrivilegeAssignments.IsNull() || o.PrivilegeAssignments.IsUnknown() { + return nil, false + } + var v []PrivilegeAssignment + d := o.PrivilegeAssignments.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrivilegeAssignments sets the value of the PrivilegeAssignments field in ShareToPrivilegeAssignment. +func (o *ShareToPrivilegeAssignment) SetPrivilegeAssignments(ctx context.Context, v []PrivilegeAssignment) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privilege_assignments"] + o.PrivilegeAssignments = types.ListValueMust(t, vs) +} + type SharedDataObject struct { // The time when this data object is added to the share, in epoch // milliseconds. @@ -2120,6 +2550,31 @@ func (o SharedDataObject) Type(ctx context.Context) attr.Type { } } +// GetPartitions returns the value of the Partitions field in SharedDataObject as +// a slice of Partition values. +// If the field is unknown or null, the boolean return value is false. +func (o *SharedDataObject) GetPartitions(ctx context.Context) ([]Partition, bool) { + if o.Partitions.IsNull() || o.Partitions.IsUnknown() { + return nil, false + } + var v []Partition + d := o.Partitions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPartitions sets the value of the Partitions field in SharedDataObject. +func (o *SharedDataObject) SetPartitions(ctx context.Context, v []Partition) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["partition"] + o.Partitions = types.ListValueMust(t, vs) +} + type SharedDataObjectUpdate struct { // One of: **ADD**, **REMOVE**, **UPDATE**. Action types.String `tfsdk:"action" tf:"optional"` @@ -2170,6 +2625,32 @@ func (o SharedDataObjectUpdate) Type(ctx context.Context) attr.Type { } } +// GetDataObject returns the value of the DataObject field in SharedDataObjectUpdate as +// a SharedDataObject value. +// If the field is unknown or null, the boolean return value is false. +func (o *SharedDataObjectUpdate) GetDataObject(ctx context.Context) (SharedDataObject, bool) { + var e SharedDataObject + if o.DataObject.IsNull() || o.DataObject.IsUnknown() { + return e, false + } + var v []SharedDataObject + d := o.DataObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDataObject sets the value of the DataObject field in SharedDataObjectUpdate. +func (o *SharedDataObjectUpdate) SetDataObject(ctx context.Context, v SharedDataObject) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_object"] + o.DataObject = types.ListValueMust(t, vs) +} + type UpdatePermissionsResponse struct { } @@ -2341,6 +2822,58 @@ func (o UpdateRecipient) Type(ctx context.Context) attr.Type { } } +// GetIpAccessList returns the value of the IpAccessList field in UpdateRecipient as +// a IpAccessList value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRecipient) GetIpAccessList(ctx context.Context) (IpAccessList, bool) { + var e IpAccessList + if o.IpAccessList.IsNull() || o.IpAccessList.IsUnknown() { + return e, false + } + var v []IpAccessList + d := o.IpAccessList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetIpAccessList sets the value of the IpAccessList field in UpdateRecipient. +func (o *UpdateRecipient) SetIpAccessList(ctx context.Context, v IpAccessList) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_list"] + o.IpAccessList = types.ListValueMust(t, vs) +} + +// GetPropertiesKvpairs returns the value of the PropertiesKvpairs field in UpdateRecipient as +// a SecurablePropertiesKvPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRecipient) GetPropertiesKvpairs(ctx context.Context) (SecurablePropertiesKvPairs, bool) { + var e SecurablePropertiesKvPairs + if o.PropertiesKvpairs.IsNull() || o.PropertiesKvpairs.IsUnknown() { + return e, false + } + var v []SecurablePropertiesKvPairs + d := o.PropertiesKvpairs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPropertiesKvpairs sets the value of the PropertiesKvpairs field in UpdateRecipient. +func (o *UpdateRecipient) SetPropertiesKvpairs(ctx context.Context, v SecurablePropertiesKvPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties_kvpairs"] + o.PropertiesKvpairs = types.ListValueMust(t, vs) +} + type UpdateResponse struct { } @@ -2443,6 +2976,31 @@ func (o UpdateShare) Type(ctx context.Context) attr.Type { } } +// GetUpdates returns the value of the Updates field in UpdateShare as +// a slice of SharedDataObjectUpdate values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateShare) GetUpdates(ctx context.Context) ([]SharedDataObjectUpdate, bool) { + if o.Updates.IsNull() || o.Updates.IsUnknown() { + return nil, false + } + var v []SharedDataObjectUpdate + d := o.Updates.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUpdates sets the value of the Updates field in UpdateShare. +func (o *UpdateShare) SetUpdates(ctx context.Context, v []SharedDataObjectUpdate) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["updates"] + o.Updates = types.ListValueMust(t, vs) +} + type UpdateSharePermissions struct { // Array of permission changes. Changes types.List `tfsdk:"changes" tf:"optional"` @@ -2477,7 +3035,7 @@ func (newState *UpdateSharePermissions) SyncEffectiveFieldsDuringRead(existingSt // SDK values. func (a UpdateSharePermissions) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "changes": reflect.TypeOf(catalog.PermissionsChange{}), + "changes": reflect.TypeOf(catalog_tf.PermissionsChange{}), } } @@ -2509,15 +3067,27 @@ func (o UpdateSharePermissions) Type(ctx context.Context) attr.Type { } } -// The delta sharing authentication type. - -// The operator to apply for the value. - -// The type of the data object. - -// Whether to enable or disable sharing of data history. If not specified, the -// default is **DISABLED**. - -// One of: **ACTIVE**, **PERMISSION_DENIED**. +// GetChanges returns the value of the Changes field in UpdateSharePermissions as +// a slice of catalog_tf.PermissionsChange values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateSharePermissions) GetChanges(ctx context.Context) ([]catalog_tf.PermissionsChange, bool) { + if o.Changes.IsNull() || o.Changes.IsUnknown() { + return nil, false + } + var v []catalog_tf.PermissionsChange + d := o.Changes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// One of: **ADD**, **REMOVE**, **UPDATE**. +// SetChanges sets the value of the Changes field in UpdateSharePermissions. +func (o *UpdateSharePermissions) SetChanges(ctx context.Context, v []catalog_tf.PermissionsChange) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["changes"] + o.Changes = types.ListValueMust(t, vs) +} diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 1688aec95d..485ed75065 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -184,6 +185,32 @@ func (o Alert) Type(ctx context.Context) attr.Type { } } +// GetCondition returns the value of the Condition field in Alert as +// a AlertCondition value. +// If the field is unknown or null, the boolean return value is false. +func (o *Alert) GetCondition(ctx context.Context) (AlertCondition, bool) { + var e AlertCondition + if o.Condition.IsNull() || o.Condition.IsUnknown() { + return e, false + } + var v []AlertCondition + d := o.Condition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCondition sets the value of the Condition field in Alert. +func (o *Alert) SetCondition(ctx context.Context, v AlertCondition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition"] + o.Condition = types.ListValueMust(t, vs) +} + type AlertCondition struct { // Alert state if result is empty. EmptyResultState types.String `tfsdk:"empty_result_state" tf:"optional"` @@ -246,6 +273,58 @@ func (o AlertCondition) Type(ctx context.Context) attr.Type { } } +// GetOperand returns the value of the Operand field in AlertCondition as +// a AlertConditionOperand value. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertCondition) GetOperand(ctx context.Context) (AlertConditionOperand, bool) { + var e AlertConditionOperand + if o.Operand.IsNull() || o.Operand.IsUnknown() { + return e, false + } + var v []AlertConditionOperand + d := o.Operand.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOperand sets the value of the Operand field in AlertCondition. +func (o *AlertCondition) SetOperand(ctx context.Context, v AlertConditionOperand) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["operand"] + o.Operand = types.ListValueMust(t, vs) +} + +// GetThreshold returns the value of the Threshold field in AlertCondition as +// a AlertConditionThreshold value. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertCondition) GetThreshold(ctx context.Context) (AlertConditionThreshold, bool) { + var e AlertConditionThreshold + if o.Threshold.IsNull() || o.Threshold.IsUnknown() { + return e, false + } + var v []AlertConditionThreshold + d := o.Threshold.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetThreshold sets the value of the Threshold field in AlertCondition. +func (o *AlertCondition) SetThreshold(ctx context.Context, v AlertConditionThreshold) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["threshold"] + o.Threshold = types.ListValueMust(t, vs) +} + type AlertConditionOperand struct { Column types.List `tfsdk:"column" tf:"optional,object"` } @@ -291,6 +370,32 @@ func (o AlertConditionOperand) Type(ctx context.Context) attr.Type { } } +// GetColumn returns the value of the Column field in AlertConditionOperand as +// a AlertOperandColumn value. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertConditionOperand) GetColumn(ctx context.Context) (AlertOperandColumn, bool) { + var e AlertOperandColumn + if o.Column.IsNull() || o.Column.IsUnknown() { + return e, false + } + var v []AlertOperandColumn + d := o.Column.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetColumn sets the value of the Column field in AlertConditionOperand. +func (o *AlertConditionOperand) SetColumn(ctx context.Context, v AlertOperandColumn) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["column"] + o.Column = types.ListValueMust(t, vs) +} + type AlertConditionThreshold struct { Value types.List `tfsdk:"value" tf:"optional,object"` } @@ -336,6 +441,32 @@ func (o AlertConditionThreshold) Type(ctx context.Context) attr.Type { } } +// GetValue returns the value of the Value field in AlertConditionThreshold as +// a AlertOperandValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertConditionThreshold) GetValue(ctx context.Context) (AlertOperandValue, bool) { + var e AlertOperandValue + if o.Value.IsNull() || o.Value.IsUnknown() { + return e, false + } + var v []AlertOperandValue + d := o.Value.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetValue sets the value of the Value field in AlertConditionThreshold. +func (o *AlertConditionThreshold) SetValue(ctx context.Context, v AlertOperandValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["value"] + o.Value = types.ListValueMust(t, vs) +} + type AlertOperandColumn struct { Name types.String `tfsdk:"name" tf:"optional"` } @@ -613,6 +744,57 @@ func (o AlertQuery) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in AlertQuery as +// a QueryOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertQuery) GetOptions(ctx context.Context) (QueryOptions, bool) { + var e QueryOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []QueryOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in AlertQuery. +func (o *AlertQuery) SetOptions(ctx context.Context, v QueryOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in AlertQuery as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *AlertQuery) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in AlertQuery. +func (o *AlertQuery) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + // Describes metadata for a particular chunk, within a result set; this // structure is used both within a manifest, and when fetching individual chunk // data or links. @@ -978,6 +1160,32 @@ func (o CreateAlert) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in CreateAlert as +// a AlertOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateAlert) GetOptions(ctx context.Context) (AlertOptions, bool) { + var e AlertOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []AlertOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in CreateAlert. +func (o *CreateAlert) SetOptions(ctx context.Context, v AlertOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + type CreateAlertRequest struct { Alert types.List `tfsdk:"alert" tf:"optional,object"` } @@ -1023,6 +1231,32 @@ func (o CreateAlertRequest) Type(ctx context.Context) attr.Type { } } +// GetAlert returns the value of the Alert field in CreateAlertRequest as +// a CreateAlertRequestAlert value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateAlertRequest) GetAlert(ctx context.Context) (CreateAlertRequestAlert, bool) { + var e CreateAlertRequestAlert + if o.Alert.IsNull() || o.Alert.IsUnknown() { + return e, false + } + var v []CreateAlertRequestAlert + d := o.Alert.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAlert sets the value of the Alert field in CreateAlertRequest. +func (o *CreateAlertRequest) SetAlert(ctx context.Context, v CreateAlertRequestAlert) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert"] + o.Alert = types.ListValueMust(t, vs) +} + type CreateAlertRequestAlert struct { // Trigger conditions of the alert. Condition types.List `tfsdk:"condition" tf:"optional,object"` @@ -1106,6 +1340,32 @@ func (o CreateAlertRequestAlert) Type(ctx context.Context) attr.Type { } } +// GetCondition returns the value of the Condition field in CreateAlertRequestAlert as +// a AlertCondition value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateAlertRequestAlert) GetCondition(ctx context.Context) (AlertCondition, bool) { + var e AlertCondition + if o.Condition.IsNull() || o.Condition.IsUnknown() { + return e, false + } + var v []AlertCondition + d := o.Condition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCondition sets the value of the Condition field in CreateAlertRequestAlert. +func (o *CreateAlertRequestAlert) SetCondition(ctx context.Context, v AlertCondition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition"] + o.Condition = types.ListValueMust(t, vs) +} + type CreateQueryRequest struct { Query types.List `tfsdk:"query" tf:"optional,object"` } @@ -1151,6 +1411,32 @@ func (o CreateQueryRequest) Type(ctx context.Context) attr.Type { } } +// GetQuery returns the value of the Query field in CreateQueryRequest as +// a CreateQueryRequestQuery value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateQueryRequest) GetQuery(ctx context.Context) (CreateQueryRequestQuery, bool) { + var e CreateQueryRequestQuery + if o.Query.IsNull() || o.Query.IsUnknown() { + return e, false + } + var v []CreateQueryRequestQuery + d := o.Query.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuery sets the value of the Query field in CreateQueryRequest. +func (o *CreateQueryRequest) SetQuery(ctx context.Context, v CreateQueryRequestQuery) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query"] + o.Query = types.ListValueMust(t, vs) +} + type CreateQueryRequestQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -1242,6 +1528,56 @@ func (o CreateQueryRequestQuery) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in CreateQueryRequestQuery as +// a slice of QueryParameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateQueryRequestQuery) GetParameters(ctx context.Context) ([]QueryParameter, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []QueryParameter + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in CreateQueryRequestQuery. +func (o *CreateQueryRequestQuery) SetParameters(ctx context.Context, v []QueryParameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in CreateQueryRequestQuery as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateQueryRequestQuery) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in CreateQueryRequestQuery. +func (o *CreateQueryRequestQuery) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + // Add visualization to a query type CreateQueryVisualizationsLegacyRequest struct { // A short description of this visualization. This is not displayed in the @@ -1350,6 +1686,32 @@ func (o CreateVisualizationRequest) Type(ctx context.Context) attr.Type { } } +// GetVisualization returns the value of the Visualization field in CreateVisualizationRequest as +// a CreateVisualizationRequestVisualization value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateVisualizationRequest) GetVisualization(ctx context.Context) (CreateVisualizationRequestVisualization, bool) { + var e CreateVisualizationRequestVisualization + if o.Visualization.IsNull() || o.Visualization.IsUnknown() { + return e, false + } + var v []CreateVisualizationRequestVisualization + d := o.Visualization.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVisualization sets the value of the Visualization field in CreateVisualizationRequest. +func (o *CreateVisualizationRequest) SetVisualization(ctx context.Context, v CreateVisualizationRequestVisualization) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["visualization"] + o.Visualization = types.ListValueMust(t, vs) +} + type CreateVisualizationRequestVisualization struct { // The display name of the visualization. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -1544,6 +1906,58 @@ func (o CreateWarehouseRequest) Type(ctx context.Context) attr.Type { } } +// GetChannel returns the value of the Channel field in CreateWarehouseRequest as +// a Channel value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWarehouseRequest) GetChannel(ctx context.Context) (Channel, bool) { + var e Channel + if o.Channel.IsNull() || o.Channel.IsUnknown() { + return e, false + } + var v []Channel + d := o.Channel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannel sets the value of the Channel field in CreateWarehouseRequest. +func (o *CreateWarehouseRequest) SetChannel(ctx context.Context, v Channel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel"] + o.Channel = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in CreateWarehouseRequest as +// a EndpointTags value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWarehouseRequest) GetTags(ctx context.Context) (EndpointTags, bool) { + var e EndpointTags + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return e, false + } + var v []EndpointTags + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTags sets the value of the Tags field in CreateWarehouseRequest. +func (o *CreateWarehouseRequest) SetTags(ctx context.Context, v EndpointTags) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type CreateWarehouseResponse struct { // Id for the SQL warehouse. This value is unique across all SQL warehouses. Id types.String `tfsdk:"id" tf:"optional"` @@ -1654,6 +2068,32 @@ func (o CreateWidget) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in CreateWidget as +// a WidgetOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateWidget) GetOptions(ctx context.Context) (WidgetOptions, bool) { + var e WidgetOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []WidgetOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in CreateWidget. +func (o *CreateWidget) SetOptions(ctx context.Context, v WidgetOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + // A JSON representing a dashboard containing widgets of visualizations and text // boxes. type Dashboard struct { @@ -1785,6 +2225,108 @@ func (o Dashboard) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in Dashboard as +// a DashboardOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *Dashboard) GetOptions(ctx context.Context) (DashboardOptions, bool) { + var e DashboardOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []DashboardOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in Dashboard. +func (o *Dashboard) SetOptions(ctx context.Context, v DashboardOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in Dashboard as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Dashboard) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in Dashboard. +func (o *Dashboard) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + +// GetUser returns the value of the User field in Dashboard as +// a User value. +// If the field is unknown or null, the boolean return value is false. +func (o *Dashboard) GetUser(ctx context.Context) (User, bool) { + var e User + if o.User.IsNull() || o.User.IsUnknown() { + return e, false + } + var v []User + d := o.User.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUser sets the value of the User field in Dashboard. +func (o *Dashboard) SetUser(ctx context.Context, v User) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["user"] + o.User = types.ListValueMust(t, vs) +} + +// GetWidgets returns the value of the Widgets field in Dashboard as +// a slice of Widget values. +// If the field is unknown or null, the boolean return value is false. +func (o *Dashboard) GetWidgets(ctx context.Context) ([]Widget, bool) { + if o.Widgets.IsNull() || o.Widgets.IsUnknown() { + return nil, false + } + var v []Widget + d := o.Widgets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWidgets sets the value of the Widgets field in Dashboard. +func (o *Dashboard) SetWidgets(ctx context.Context, v []Widget) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["widgets"] + o.Widgets = types.ListValueMust(t, vs) +} + type DashboardEditContent struct { DashboardId types.String `tfsdk:"-"` // The title of this dashboard that appears in list views and at the top of @@ -1845,6 +2387,31 @@ func (o DashboardEditContent) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in DashboardEditContent as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DashboardEditContent) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in DashboardEditContent. +func (o *DashboardEditContent) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type DashboardOptions struct { // The timestamp when this dashboard was moved to trash. Only present when // the `is_archived` property is `true`. Trashed items are deleted after @@ -1959,6 +2526,31 @@ func (o DashboardPostContent) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in DashboardPostContent as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DashboardPostContent) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in DashboardPostContent. +func (o *DashboardPostContent) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + // A JSON object representing a DBSQL data source / SQL warehouse. type DataSource struct { // Data source ID maps to the ID of the data source used by the resource and @@ -2144,6 +2736,32 @@ func (o DateRangeValue) Type(ctx context.Context) attr.Type { } } +// GetDateRangeValue returns the value of the DateRangeValue field in DateRangeValue as +// a DateRange value. +// If the field is unknown or null, the boolean return value is false. +func (o *DateRangeValue) GetDateRangeValue(ctx context.Context) (DateRange, bool) { + var e DateRange + if o.DateRangeValue.IsNull() || o.DateRangeValue.IsUnknown() { + return e, false + } + var v []DateRange + d := o.DateRangeValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDateRangeValue sets the value of the DateRangeValue field in DateRangeValue. +func (o *DateRangeValue) SetDateRangeValue(ctx context.Context, v DateRange) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["date_range_value"] + o.DateRangeValue = types.ListValueMust(t, vs) +} + type DateValue struct { // Manually specified date-time value. DateValue types.String `tfsdk:"date_value" tf:"optional"` @@ -2627,6 +3245,32 @@ func (o EditAlert) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in EditAlert as +// a AlertOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditAlert) GetOptions(ctx context.Context) (AlertOptions, bool) { + var e AlertOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []AlertOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in EditAlert. +func (o *EditAlert) SetOptions(ctx context.Context, v AlertOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + type EditWarehouseRequest struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -2761,6 +3405,58 @@ func (o EditWarehouseRequest) Type(ctx context.Context) attr.Type { } } +// GetChannel returns the value of the Channel field in EditWarehouseRequest as +// a Channel value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditWarehouseRequest) GetChannel(ctx context.Context) (Channel, bool) { + var e Channel + if o.Channel.IsNull() || o.Channel.IsUnknown() { + return e, false + } + var v []Channel + d := o.Channel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannel sets the value of the Channel field in EditWarehouseRequest. +func (o *EditWarehouseRequest) SetChannel(ctx context.Context, v Channel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel"] + o.Channel = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in EditWarehouseRequest as +// a EndpointTags value. +// If the field is unknown or null, the boolean return value is false. +func (o *EditWarehouseRequest) GetTags(ctx context.Context) (EndpointTags, bool) { + var e EndpointTags + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return e, false + } + var v []EndpointTags + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTags sets the value of the Tags field in EditWarehouseRequest. +func (o *EditWarehouseRequest) SetTags(ctx context.Context, v EndpointTags) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type EditWarehouseResponse struct { } @@ -2944,6 +3640,32 @@ func (o EndpointHealth) Type(ctx context.Context) attr.Type { } } +// GetFailureReason returns the value of the FailureReason field in EndpointHealth as +// a TerminationReason value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointHealth) GetFailureReason(ctx context.Context) (TerminationReason, bool) { + var e TerminationReason + if o.FailureReason.IsNull() || o.FailureReason.IsUnknown() { + return e, false + } + var v []TerminationReason + d := o.FailureReason.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFailureReason sets the value of the FailureReason field in EndpointHealth. +func (o *EndpointHealth) SetFailureReason(ctx context.Context, v TerminationReason) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["failure_reason"] + o.FailureReason = types.ListValueMust(t, vs) +} + type EndpointInfo struct { // The amount of time in minutes that a SQL warehouse must be idle (i.e., no // RUNNING queries) before it is automatically stopped. @@ -3109,6 +3831,110 @@ func (o EndpointInfo) Type(ctx context.Context) attr.Type { } } +// GetChannel returns the value of the Channel field in EndpointInfo as +// a Channel value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointInfo) GetChannel(ctx context.Context) (Channel, bool) { + var e Channel + if o.Channel.IsNull() || o.Channel.IsUnknown() { + return e, false + } + var v []Channel + d := o.Channel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannel sets the value of the Channel field in EndpointInfo. +func (o *EndpointInfo) SetChannel(ctx context.Context, v Channel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel"] + o.Channel = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in EndpointInfo as +// a EndpointHealth value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointInfo) GetHealth(ctx context.Context) (EndpointHealth, bool) { + var e EndpointHealth + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []EndpointHealth + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in EndpointInfo. +func (o *EndpointInfo) SetHealth(ctx context.Context, v EndpointHealth) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetOdbcParams returns the value of the OdbcParams field in EndpointInfo as +// a OdbcParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointInfo) GetOdbcParams(ctx context.Context) (OdbcParams, bool) { + var e OdbcParams + if o.OdbcParams.IsNull() || o.OdbcParams.IsUnknown() { + return e, false + } + var v []OdbcParams + d := o.OdbcParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOdbcParams sets the value of the OdbcParams field in EndpointInfo. +func (o *EndpointInfo) SetOdbcParams(ctx context.Context, v OdbcParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["odbc_params"] + o.OdbcParams = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in EndpointInfo as +// a EndpointTags value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointInfo) GetTags(ctx context.Context) (EndpointTags, bool) { + var e EndpointTags + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return e, false + } + var v []EndpointTags + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTags sets the value of the Tags field in EndpointInfo. +func (o *EndpointInfo) SetTags(ctx context.Context, v EndpointTags) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type EndpointTagPair struct { Key types.String `tfsdk:"key" tf:"optional"` @@ -3199,6 +4025,31 @@ func (o EndpointTags) Type(ctx context.Context) attr.Type { } } +// GetCustomTags returns the value of the CustomTags field in EndpointTags as +// a slice of EndpointTagPair values. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointTags) GetCustomTags(ctx context.Context) ([]EndpointTagPair, bool) { + if o.CustomTags.IsNull() || o.CustomTags.IsUnknown() { + return nil, false + } + var v []EndpointTagPair + d := o.CustomTags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCustomTags sets the value of the CustomTags field in EndpointTags. +func (o *EndpointTags) SetCustomTags(ctx context.Context, v []EndpointTagPair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + o.CustomTags = types.ListValueMust(t, vs) +} + type EnumValue struct { // List of valid query parameter values, newline delimited. EnumOptions types.String `tfsdk:"enum_options" tf:"optional"` @@ -3256,6 +4107,57 @@ func (o EnumValue) Type(ctx context.Context) attr.Type { } } +// GetMultiValuesOptions returns the value of the MultiValuesOptions field in EnumValue as +// a MultiValuesOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *EnumValue) GetMultiValuesOptions(ctx context.Context) (MultiValuesOptions, bool) { + var e MultiValuesOptions + if o.MultiValuesOptions.IsNull() || o.MultiValuesOptions.IsUnknown() { + return e, false + } + var v []MultiValuesOptions + d := o.MultiValuesOptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMultiValuesOptions sets the value of the MultiValuesOptions field in EnumValue. +func (o *EnumValue) SetMultiValuesOptions(ctx context.Context, v MultiValuesOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["multi_values_options"] + o.MultiValuesOptions = types.ListValueMust(t, vs) +} + +// GetValues returns the value of the Values field in EnumValue as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *EnumValue) GetValues(ctx context.Context) ([]types.String, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in EnumValue. +func (o *EnumValue) SetValues(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + o.Values = types.ListValueMust(t, vs) +} + type ExecuteStatementRequest struct { // Applies the given byte limit to the statement's result size. Byte counts // are based on internal data representations and might not match the final @@ -3443,6 +4345,31 @@ func (o ExecuteStatementRequest) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in ExecuteStatementRequest as +// a slice of StatementParameterListItem values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExecuteStatementRequest) GetParameters(ctx context.Context) ([]StatementParameterListItem, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []StatementParameterListItem + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in ExecuteStatementRequest. +func (o *ExecuteStatementRequest) SetParameters(ctx context.Context, v []StatementParameterListItem) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type ExternalLink struct { // The number of bytes in the result chunk. This field is not available when // using `INLINE` disposition. @@ -3533,10 +4460,35 @@ func (o ExternalLink) Type(ctx context.Context) attr.Type { } } -// Get an alert -type GetAlertRequest struct { - Id types.String `tfsdk:"-"` -} +// GetHttpHeaders returns the value of the HttpHeaders field in ExternalLink as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ExternalLink) GetHttpHeaders(ctx context.Context) (map[string]types.String, bool) { + if o.HttpHeaders.IsNull() || o.HttpHeaders.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.HttpHeaders.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetHttpHeaders sets the value of the HttpHeaders field in ExternalLink. +func (o *ExternalLink) SetHttpHeaders(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["http_headers"] + o.HttpHeaders = types.MapValueMust(t, vs) +} + +// Get an alert +type GetAlertRequest struct { + Id types.String `tfsdk:"-"` +} func (newState *GetAlertRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan GetAlertRequest) { } @@ -3843,6 +4795,31 @@ func (o GetResponse) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in GetResponse as +// a slice of AccessControl values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetResponse) GetAccessControlList(ctx context.Context) ([]AccessControl, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AccessControl + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in GetResponse. +func (o *GetResponse) SetAccessControlList(ctx context.Context, v []AccessControl) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + // Get status, manifest, and result first chunk type GetStatementRequest struct { // The statement ID is returned upon successfully submitting a SQL @@ -4023,6 +5000,31 @@ func (o GetWarehousePermissionLevelsResponse) Type(ctx context.Context) attr.Typ } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetWarehousePermissionLevelsResponse as +// a slice of WarehousePermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWarehousePermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]WarehousePermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []WarehousePermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetWarehousePermissionLevelsResponse. +func (o *GetWarehousePermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []WarehousePermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get SQL warehouse permissions type GetWarehousePermissionsRequest struct { // The SQL warehouse for which to get or manage permissions. @@ -4274,6 +5276,110 @@ func (o GetWarehouseResponse) Type(ctx context.Context) attr.Type { } } +// GetChannel returns the value of the Channel field in GetWarehouseResponse as +// a Channel value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWarehouseResponse) GetChannel(ctx context.Context) (Channel, bool) { + var e Channel + if o.Channel.IsNull() || o.Channel.IsUnknown() { + return e, false + } + var v []Channel + d := o.Channel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannel sets the value of the Channel field in GetWarehouseResponse. +func (o *GetWarehouseResponse) SetChannel(ctx context.Context, v Channel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel"] + o.Channel = types.ListValueMust(t, vs) +} + +// GetHealth returns the value of the Health field in GetWarehouseResponse as +// a EndpointHealth value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWarehouseResponse) GetHealth(ctx context.Context) (EndpointHealth, bool) { + var e EndpointHealth + if o.Health.IsNull() || o.Health.IsUnknown() { + return e, false + } + var v []EndpointHealth + d := o.Health.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetHealth sets the value of the Health field in GetWarehouseResponse. +func (o *GetWarehouseResponse) SetHealth(ctx context.Context, v EndpointHealth) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["health"] + o.Health = types.ListValueMust(t, vs) +} + +// GetOdbcParams returns the value of the OdbcParams field in GetWarehouseResponse as +// a OdbcParams value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWarehouseResponse) GetOdbcParams(ctx context.Context) (OdbcParams, bool) { + var e OdbcParams + if o.OdbcParams.IsNull() || o.OdbcParams.IsUnknown() { + return e, false + } + var v []OdbcParams + d := o.OdbcParams.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOdbcParams sets the value of the OdbcParams field in GetWarehouseResponse. +func (o *GetWarehouseResponse) SetOdbcParams(ctx context.Context, v OdbcParams) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["odbc_params"] + o.OdbcParams = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in GetWarehouseResponse as +// a EndpointTags value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWarehouseResponse) GetTags(ctx context.Context) (EndpointTags, bool) { + var e EndpointTags + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return e, false + } + var v []EndpointTags + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTags sets the value of the Tags field in GetWarehouseResponse. +func (o *GetWarehouseResponse) SetTags(ctx context.Context, v EndpointTags) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type GetWorkspaceWarehouseConfigResponse struct { // Optional: Channel selection details Channel types.List `tfsdk:"channel" tf:"optional,object"` @@ -4374,6 +5480,160 @@ func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type } } +// GetChannel returns the value of the Channel field in GetWorkspaceWarehouseConfigResponse as +// a Channel value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceWarehouseConfigResponse) GetChannel(ctx context.Context) (Channel, bool) { + var e Channel + if o.Channel.IsNull() || o.Channel.IsUnknown() { + return e, false + } + var v []Channel + d := o.Channel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannel sets the value of the Channel field in GetWorkspaceWarehouseConfigResponse. +func (o *GetWorkspaceWarehouseConfigResponse) SetChannel(ctx context.Context, v Channel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel"] + o.Channel = types.ListValueMust(t, vs) +} + +// GetConfigParam returns the value of the ConfigParam field in GetWorkspaceWarehouseConfigResponse as +// a RepeatedEndpointConfPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceWarehouseConfigResponse) GetConfigParam(ctx context.Context) (RepeatedEndpointConfPairs, bool) { + var e RepeatedEndpointConfPairs + if o.ConfigParam.IsNull() || o.ConfigParam.IsUnknown() { + return e, false + } + var v []RepeatedEndpointConfPairs + d := o.ConfigParam.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfigParam sets the value of the ConfigParam field in GetWorkspaceWarehouseConfigResponse. +func (o *GetWorkspaceWarehouseConfigResponse) SetConfigParam(ctx context.Context, v RepeatedEndpointConfPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config_param"] + o.ConfigParam = types.ListValueMust(t, vs) +} + +// GetDataAccessConfig returns the value of the DataAccessConfig field in GetWorkspaceWarehouseConfigResponse as +// a slice of EndpointConfPair values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceWarehouseConfigResponse) GetDataAccessConfig(ctx context.Context) ([]EndpointConfPair, bool) { + if o.DataAccessConfig.IsNull() || o.DataAccessConfig.IsUnknown() { + return nil, false + } + var v []EndpointConfPair + d := o.DataAccessConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDataAccessConfig sets the value of the DataAccessConfig field in GetWorkspaceWarehouseConfigResponse. +func (o *GetWorkspaceWarehouseConfigResponse) SetDataAccessConfig(ctx context.Context, v []EndpointConfPair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_access_config"] + o.DataAccessConfig = types.ListValueMust(t, vs) +} + +// GetEnabledWarehouseTypes returns the value of the EnabledWarehouseTypes field in GetWorkspaceWarehouseConfigResponse as +// a slice of WarehouseTypePair values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceWarehouseConfigResponse) GetEnabledWarehouseTypes(ctx context.Context) ([]WarehouseTypePair, bool) { + if o.EnabledWarehouseTypes.IsNull() || o.EnabledWarehouseTypes.IsUnknown() { + return nil, false + } + var v []WarehouseTypePair + d := o.EnabledWarehouseTypes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnabledWarehouseTypes sets the value of the EnabledWarehouseTypes field in GetWorkspaceWarehouseConfigResponse. +func (o *GetWorkspaceWarehouseConfigResponse) SetEnabledWarehouseTypes(ctx context.Context, v []WarehouseTypePair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enabled_warehouse_types"] + o.EnabledWarehouseTypes = types.ListValueMust(t, vs) +} + +// GetGlobalParam returns the value of the GlobalParam field in GetWorkspaceWarehouseConfigResponse as +// a RepeatedEndpointConfPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceWarehouseConfigResponse) GetGlobalParam(ctx context.Context) (RepeatedEndpointConfPairs, bool) { + var e RepeatedEndpointConfPairs + if o.GlobalParam.IsNull() || o.GlobalParam.IsUnknown() { + return e, false + } + var v []RepeatedEndpointConfPairs + d := o.GlobalParam.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGlobalParam sets the value of the GlobalParam field in GetWorkspaceWarehouseConfigResponse. +func (o *GetWorkspaceWarehouseConfigResponse) SetGlobalParam(ctx context.Context, v RepeatedEndpointConfPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["global_param"] + o.GlobalParam = types.ListValueMust(t, vs) +} + +// GetSqlConfigurationParameters returns the value of the SqlConfigurationParameters field in GetWorkspaceWarehouseConfigResponse as +// a RepeatedEndpointConfPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceWarehouseConfigResponse) GetSqlConfigurationParameters(ctx context.Context) (RepeatedEndpointConfPairs, bool) { + var e RepeatedEndpointConfPairs + if o.SqlConfigurationParameters.IsNull() || o.SqlConfigurationParameters.IsUnknown() { + return e, false + } + var v []RepeatedEndpointConfPairs + d := o.SqlConfigurationParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlConfigurationParameters sets the value of the SqlConfigurationParameters field in GetWorkspaceWarehouseConfigResponse. +func (o *GetWorkspaceWarehouseConfigResponse) SetSqlConfigurationParameters(ctx context.Context, v RepeatedEndpointConfPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_configuration_parameters"] + o.SqlConfigurationParameters = types.ListValueMust(t, vs) +} + type LegacyAlert struct { // Timestamp when the alert was created. CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -4470,6 +5730,84 @@ func (o LegacyAlert) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in LegacyAlert as +// a AlertOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyAlert) GetOptions(ctx context.Context) (AlertOptions, bool) { + var e AlertOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []AlertOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in LegacyAlert. +func (o *LegacyAlert) SetOptions(ctx context.Context, v AlertOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + +// GetQuery returns the value of the Query field in LegacyAlert as +// a AlertQuery value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyAlert) GetQuery(ctx context.Context) (AlertQuery, bool) { + var e AlertQuery + if o.Query.IsNull() || o.Query.IsUnknown() { + return e, false + } + var v []AlertQuery + d := o.Query.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuery sets the value of the Query field in LegacyAlert. +func (o *LegacyAlert) SetQuery(ctx context.Context, v AlertQuery) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query"] + o.Query = types.ListValueMust(t, vs) +} + +// GetUser returns the value of the User field in LegacyAlert as +// a User value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyAlert) GetUser(ctx context.Context) (User, bool) { + var e User + if o.User.IsNull() || o.User.IsUnknown() { + return e, false + } + var v []User + d := o.User.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUser sets the value of the User field in LegacyAlert. +func (o *LegacyAlert) SetUser(ctx context.Context, v User) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["user"] + o.User = types.ListValueMust(t, vs) +} + type LegacyQuery struct { // Describes whether the authenticated user is allowed to edit the // definition of this query. @@ -4640,6 +5978,134 @@ func (o LegacyQuery) Type(ctx context.Context) attr.Type { } } +// GetLastModifiedBy returns the value of the LastModifiedBy field in LegacyQuery as +// a User value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyQuery) GetLastModifiedBy(ctx context.Context) (User, bool) { + var e User + if o.LastModifiedBy.IsNull() || o.LastModifiedBy.IsUnknown() { + return e, false + } + var v []User + d := o.LastModifiedBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetLastModifiedBy sets the value of the LastModifiedBy field in LegacyQuery. +func (o *LegacyQuery) SetLastModifiedBy(ctx context.Context, v User) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["last_modified_by"] + o.LastModifiedBy = types.ListValueMust(t, vs) +} + +// GetOptions returns the value of the Options field in LegacyQuery as +// a QueryOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyQuery) GetOptions(ctx context.Context) (QueryOptions, bool) { + var e QueryOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []QueryOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in LegacyQuery. +func (o *LegacyQuery) SetOptions(ctx context.Context, v QueryOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in LegacyQuery as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyQuery) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in LegacyQuery. +func (o *LegacyQuery) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + +// GetUser returns the value of the User field in LegacyQuery as +// a User value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyQuery) GetUser(ctx context.Context) (User, bool) { + var e User + if o.User.IsNull() || o.User.IsUnknown() { + return e, false + } + var v []User + d := o.User.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetUser sets the value of the User field in LegacyQuery. +func (o *LegacyQuery) SetUser(ctx context.Context, v User) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["user"] + o.User = types.ListValueMust(t, vs) +} + +// GetVisualizations returns the value of the Visualizations field in LegacyQuery as +// a slice of LegacyVisualization values. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyQuery) GetVisualizations(ctx context.Context) ([]LegacyVisualization, bool) { + if o.Visualizations.IsNull() || o.Visualizations.IsUnknown() { + return nil, false + } + var v []LegacyVisualization + d := o.Visualizations.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetVisualizations sets the value of the Visualizations field in LegacyQuery. +func (o *LegacyQuery) SetVisualizations(ctx context.Context, v []LegacyVisualization) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["visualizations"] + o.Visualizations = types.ListValueMust(t, vs) +} + // The visualization description API changes frequently and is unsupported. You // can duplicate a visualization by copying description objects received _from // the API_ and then using them to create a new one with a POST request to the @@ -4722,6 +6188,32 @@ func (o LegacyVisualization) Type(ctx context.Context) attr.Type { } } +// GetQuery returns the value of the Query field in LegacyVisualization as +// a LegacyQuery value. +// If the field is unknown or null, the boolean return value is false. +func (o *LegacyVisualization) GetQuery(ctx context.Context) (LegacyQuery, bool) { + var e LegacyQuery + if o.Query.IsNull() || o.Query.IsUnknown() { + return e, false + } + var v []LegacyQuery + d := o.Query.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuery sets the value of the Query field in LegacyVisualization. +func (o *LegacyVisualization) SetQuery(ctx context.Context, v LegacyQuery) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query"] + o.Query = types.ListValueMust(t, vs) +} + // List alerts type ListAlertsRequest struct { PageSize types.Int64 `tfsdk:"-"` @@ -4817,6 +6309,31 @@ func (o ListAlertsResponse) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in ListAlertsResponse as +// a slice of ListAlertsResponseAlert values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAlertsResponse) GetResults(ctx context.Context) ([]ListAlertsResponseAlert, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []ListAlertsResponseAlert + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ListAlertsResponse. +func (o *ListAlertsResponse) SetResults(ctx context.Context, v []ListAlertsResponseAlert) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + type ListAlertsResponseAlert struct { // Trigger conditions of the alert. Condition types.List `tfsdk:"condition" tf:"optional,object"` @@ -4928,6 +6445,32 @@ func (o ListAlertsResponseAlert) Type(ctx context.Context) attr.Type { } } +// GetCondition returns the value of the Condition field in ListAlertsResponseAlert as +// a AlertCondition value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAlertsResponseAlert) GetCondition(ctx context.Context) (AlertCondition, bool) { + var e AlertCondition + if o.Condition.IsNull() || o.Condition.IsUnknown() { + return e, false + } + var v []AlertCondition + d := o.Condition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCondition sets the value of the Condition field in ListAlertsResponseAlert. +func (o *ListAlertsResponseAlert) SetCondition(ctx context.Context, v AlertCondition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition"] + o.Condition = types.ListValueMust(t, vs) +} + // Get dashboard objects type ListDashboardsRequest struct { // Name of dashboard attribute to order by. @@ -5151,6 +6694,31 @@ func (o ListQueriesResponse) Type(ctx context.Context) attr.Type { } } +// GetRes returns the value of the Res field in ListQueriesResponse as +// a slice of QueryInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListQueriesResponse) GetRes(ctx context.Context) ([]QueryInfo, bool) { + if o.Res.IsNull() || o.Res.IsUnknown() { + return nil, false + } + var v []QueryInfo + d := o.Res.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRes sets the value of the Res field in ListQueriesResponse. +func (o *ListQueriesResponse) SetRes(ctx context.Context, v []QueryInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["res"] + o.Res = types.ListValueMust(t, vs) +} + // List Queries type ListQueryHistoryRequest struct { // A filter to limit query history results. This field is optional. @@ -5215,6 +6783,32 @@ func (o ListQueryHistoryRequest) Type(ctx context.Context) attr.Type { } } +// GetFilterBy returns the value of the FilterBy field in ListQueryHistoryRequest as +// a QueryFilter value. +// If the field is unknown or null, the boolean return value is false. +func (o *ListQueryHistoryRequest) GetFilterBy(ctx context.Context) (QueryFilter, bool) { + var e QueryFilter + if o.FilterBy.IsNull() || o.FilterBy.IsUnknown() { + return e, false + } + var v []QueryFilter + d := o.FilterBy.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetFilterBy sets the value of the FilterBy field in ListQueryHistoryRequest. +func (o *ListQueryHistoryRequest) SetFilterBy(ctx context.Context, v QueryFilter) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filter_by"] + o.FilterBy = types.ListValueMust(t, vs) +} + type ListQueryObjectsResponse struct { NextPageToken types.String `tfsdk:"next_page_token" tf:"optional"` @@ -5264,6 +6858,31 @@ func (o ListQueryObjectsResponse) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in ListQueryObjectsResponse as +// a slice of ListQueryObjectsResponseQuery values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListQueryObjectsResponse) GetResults(ctx context.Context) ([]ListQueryObjectsResponseQuery, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []ListQueryObjectsResponseQuery + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ListQueryObjectsResponse. +func (o *ListQueryObjectsResponse) SetResults(ctx context.Context, v []ListQueryObjectsResponseQuery) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + type ListQueryObjectsResponseQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -5375,6 +6994,56 @@ func (o ListQueryObjectsResponseQuery) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in ListQueryObjectsResponseQuery as +// a slice of QueryParameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListQueryObjectsResponseQuery) GetParameters(ctx context.Context) ([]QueryParameter, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []QueryParameter + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in ListQueryObjectsResponseQuery. +func (o *ListQueryObjectsResponseQuery) SetParameters(ctx context.Context, v []QueryParameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in ListQueryObjectsResponseQuery as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListQueryObjectsResponseQuery) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in ListQueryObjectsResponseQuery. +func (o *ListQueryObjectsResponseQuery) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type ListResponse struct { // The total number of dashboards. Count types.Int64 `tfsdk:"count" tf:"optional"` @@ -5433,6 +7102,31 @@ func (o ListResponse) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in ListResponse as +// a slice of Dashboard values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListResponse) GetResults(ctx context.Context) ([]Dashboard, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []Dashboard + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ListResponse. +func (o *ListResponse) SetResults(ctx context.Context, v []Dashboard) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + // List visualizations on a query type ListVisualizationsForQueryRequest struct { Id types.String `tfsdk:"-"` @@ -5532,6 +7226,31 @@ func (o ListVisualizationsForQueryResponse) Type(ctx context.Context) attr.Type } } +// GetResults returns the value of the Results field in ListVisualizationsForQueryResponse as +// a slice of Visualization values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListVisualizationsForQueryResponse) GetResults(ctx context.Context) ([]Visualization, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []Visualization + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in ListVisualizationsForQueryResponse. +func (o *ListVisualizationsForQueryResponse) SetResults(ctx context.Context, v []Visualization) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + // List warehouses type ListWarehousesRequest struct { // Service Principal which will be used to fetch the list of warehouses. If @@ -5622,6 +7341,31 @@ func (o ListWarehousesResponse) Type(ctx context.Context) attr.Type { } } +// GetWarehouses returns the value of the Warehouses field in ListWarehousesResponse as +// a slice of EndpointInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListWarehousesResponse) GetWarehouses(ctx context.Context) ([]EndpointInfo, bool) { + if o.Warehouses.IsNull() || o.Warehouses.IsUnknown() { + return nil, false + } + var v []EndpointInfo + d := o.Warehouses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWarehouses sets the value of the Warehouses field in ListWarehousesResponse. +func (o *ListWarehousesResponse) SetWarehouses(ctx context.Context, v []EndpointInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["warehouses"] + o.Warehouses = types.ListValueMust(t, vs) +} + type MultiValuesOptions struct { // Character that prefixes each selected parameter value. Prefix types.String `tfsdk:"prefix" tf:"optional"` @@ -5841,6 +7585,32 @@ func (o Parameter) Type(ctx context.Context) attr.Type { } } +// GetMultiValuesOptions returns the value of the MultiValuesOptions field in Parameter as +// a MultiValuesOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *Parameter) GetMultiValuesOptions(ctx context.Context) (MultiValuesOptions, bool) { + var e MultiValuesOptions + if o.MultiValuesOptions.IsNull() || o.MultiValuesOptions.IsUnknown() { + return e, false + } + var v []MultiValuesOptions + d := o.MultiValuesOptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMultiValuesOptions sets the value of the MultiValuesOptions field in Parameter. +func (o *Parameter) SetMultiValuesOptions(ctx context.Context, v MultiValuesOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["multiValuesOptions"] + o.MultiValuesOptions = types.ListValueMust(t, vs) +} + type Query struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -5956,6 +7726,56 @@ func (o Query) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in Query as +// a slice of QueryParameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *Query) GetParameters(ctx context.Context) ([]QueryParameter, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []QueryParameter + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in Query. +func (o *Query) SetParameters(ctx context.Context, v []QueryParameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in Query as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *Query) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in Query. +func (o *Query) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type QueryBackedValue struct { // If specified, allows multiple values to be selected for this parameter. MultiValuesOptions types.List `tfsdk:"multi_values_options" tf:"optional,object"` @@ -6013,13 +7833,64 @@ func (o QueryBackedValue) Type(ctx context.Context) attr.Type { } } -type QueryEditContent struct { - // Data source ID maps to the ID of the data source used by the resource and - // is distinct from the warehouse ID. [Learn more] - // - // [Learn more]: https://docs.databricks.com/api/workspace/datasources/list - DataSourceId types.String `tfsdk:"data_source_id" tf:"optional"` - // General description that conveys additional information about this query +// GetMultiValuesOptions returns the value of the MultiValuesOptions field in QueryBackedValue as +// a MultiValuesOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryBackedValue) GetMultiValuesOptions(ctx context.Context) (MultiValuesOptions, bool) { + var e MultiValuesOptions + if o.MultiValuesOptions.IsNull() || o.MultiValuesOptions.IsUnknown() { + return e, false + } + var v []MultiValuesOptions + d := o.MultiValuesOptions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMultiValuesOptions sets the value of the MultiValuesOptions field in QueryBackedValue. +func (o *QueryBackedValue) SetMultiValuesOptions(ctx context.Context, v MultiValuesOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["multi_values_options"] + o.MultiValuesOptions = types.ListValueMust(t, vs) +} + +// GetValues returns the value of the Values field in QueryBackedValue as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryBackedValue) GetValues(ctx context.Context) ([]types.String, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in QueryBackedValue. +func (o *QueryBackedValue) SetValues(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + o.Values = types.ListValueMust(t, vs) +} + +type QueryEditContent struct { + // Data source ID maps to the ID of the data source used by the resource and + // is distinct from the warehouse ID. [Learn more] + // + // [Learn more]: https://docs.databricks.com/api/workspace/datasources/list + DataSourceId types.String `tfsdk:"data_source_id" tf:"optional"` + // General description that conveys additional information about this query // such as usage notes. Description types.String `tfsdk:"description" tf:"optional"` // The title of this query that appears in list views, widget headings, and @@ -6096,6 +7967,31 @@ func (o QueryEditContent) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in QueryEditContent as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryEditContent) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in QueryEditContent. +func (o *QueryEditContent) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type QueryFilter struct { // A range filter for query submitted time. The time range must be <= 30 // days. @@ -6171,6 +8067,132 @@ func (o QueryFilter) Type(ctx context.Context) attr.Type { } } +// GetQueryStartTimeRange returns the value of the QueryStartTimeRange field in QueryFilter as +// a TimeRange value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryFilter) GetQueryStartTimeRange(ctx context.Context) (TimeRange, bool) { + var e TimeRange + if o.QueryStartTimeRange.IsNull() || o.QueryStartTimeRange.IsUnknown() { + return e, false + } + var v []TimeRange + d := o.QueryStartTimeRange.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueryStartTimeRange sets the value of the QueryStartTimeRange field in QueryFilter. +func (o *QueryFilter) SetQueryStartTimeRange(ctx context.Context, v TimeRange) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_start_time_range"] + o.QueryStartTimeRange = types.ListValueMust(t, vs) +} + +// GetStatementIds returns the value of the StatementIds field in QueryFilter as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryFilter) GetStatementIds(ctx context.Context) ([]types.String, bool) { + if o.StatementIds.IsNull() || o.StatementIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.StatementIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStatementIds sets the value of the StatementIds field in QueryFilter. +func (o *QueryFilter) SetStatementIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statement_ids"] + o.StatementIds = types.ListValueMust(t, vs) +} + +// GetStatuses returns the value of the Statuses field in QueryFilter as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryFilter) GetStatuses(ctx context.Context) ([]types.String, bool) { + if o.Statuses.IsNull() || o.Statuses.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Statuses.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetStatuses sets the value of the Statuses field in QueryFilter. +func (o *QueryFilter) SetStatuses(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statuses"] + o.Statuses = types.ListValueMust(t, vs) +} + +// GetUserIds returns the value of the UserIds field in QueryFilter as +// a slice of types.Int64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryFilter) GetUserIds(ctx context.Context) ([]types.Int64, bool) { + if o.UserIds.IsNull() || o.UserIds.IsUnknown() { + return nil, false + } + var v []types.Int64 + d := o.UserIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetUserIds sets the value of the UserIds field in QueryFilter. +func (o *QueryFilter) SetUserIds(ctx context.Context, v []types.Int64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["user_ids"] + o.UserIds = types.ListValueMust(t, vs) +} + +// GetWarehouseIds returns the value of the WarehouseIds field in QueryFilter as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryFilter) GetWarehouseIds(ctx context.Context) ([]types.String, bool) { + if o.WarehouseIds.IsNull() || o.WarehouseIds.IsUnknown() { + return nil, false + } + var v []types.String + d := o.WarehouseIds.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetWarehouseIds sets the value of the WarehouseIds field in QueryFilter. +func (o *QueryFilter) SetWarehouseIds(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["warehouse_ids"] + o.WarehouseIds = types.ListValueMust(t, vs) +} + type QueryInfo struct { // SQL Warehouse channel information at the time of query execution ChannelUsed types.List `tfsdk:"channel_used" tf:"optional,object"` @@ -6309,6 +8331,58 @@ func (o QueryInfo) Type(ctx context.Context) attr.Type { } } +// GetChannelUsed returns the value of the ChannelUsed field in QueryInfo as +// a ChannelInfo value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryInfo) GetChannelUsed(ctx context.Context) (ChannelInfo, bool) { + var e ChannelInfo + if o.ChannelUsed.IsNull() || o.ChannelUsed.IsUnknown() { + return e, false + } + var v []ChannelInfo + d := o.ChannelUsed.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannelUsed sets the value of the ChannelUsed field in QueryInfo. +func (o *QueryInfo) SetChannelUsed(ctx context.Context, v ChannelInfo) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel_used"] + o.ChannelUsed = types.ListValueMust(t, vs) +} + +// GetMetrics returns the value of the Metrics field in QueryInfo as +// a QueryMetrics value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryInfo) GetMetrics(ctx context.Context) (QueryMetrics, bool) { + var e QueryMetrics + if o.Metrics.IsNull() || o.Metrics.IsUnknown() { + return e, false + } + var v []QueryMetrics + d := o.Metrics.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetMetrics sets the value of the Metrics field in QueryInfo. +func (o *QueryInfo) SetMetrics(ctx context.Context, v QueryMetrics) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + o.Metrics = types.ListValueMust(t, vs) +} + type QueryList struct { // The total number of queries. Count types.Int64 `tfsdk:"count" tf:"optional"` @@ -6367,6 +8441,31 @@ func (o QueryList) Type(ctx context.Context) attr.Type { } } +// GetResults returns the value of the Results field in QueryList as +// a slice of LegacyQuery values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryList) GetResults(ctx context.Context) ([]LegacyQuery, bool) { + if o.Results.IsNull() || o.Results.IsUnknown() { + return nil, false + } + var v []LegacyQuery + d := o.Results.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetResults sets the value of the Results field in QueryList. +func (o *QueryList) SetResults(ctx context.Context, v []LegacyQuery) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + o.Results = types.ListValueMust(t, vs) +} + // A query metric that encapsulates a set of measurements for a single query. // Metrics come from the driver and are stored in the history service database. type QueryMetrics struct { @@ -6567,6 +8666,31 @@ func (o QueryOptions) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in QueryOptions as +// a slice of Parameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryOptions) GetParameters(ctx context.Context) ([]Parameter, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []Parameter + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in QueryOptions. +func (o *QueryOptions) SetParameters(ctx context.Context, v []Parameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + type QueryParameter struct { // Date-range query parameter value. Can only specify one of // `dynamic_date_range_value` or `date_range_value`. @@ -6659,6 +8783,162 @@ func (o QueryParameter) Type(ctx context.Context) attr.Type { } } +// GetDateRangeValue returns the value of the DateRangeValue field in QueryParameter as +// a DateRangeValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryParameter) GetDateRangeValue(ctx context.Context) (DateRangeValue, bool) { + var e DateRangeValue + if o.DateRangeValue.IsNull() || o.DateRangeValue.IsUnknown() { + return e, false + } + var v []DateRangeValue + d := o.DateRangeValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDateRangeValue sets the value of the DateRangeValue field in QueryParameter. +func (o *QueryParameter) SetDateRangeValue(ctx context.Context, v DateRangeValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["date_range_value"] + o.DateRangeValue = types.ListValueMust(t, vs) +} + +// GetDateValue returns the value of the DateValue field in QueryParameter as +// a DateValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryParameter) GetDateValue(ctx context.Context) (DateValue, bool) { + var e DateValue + if o.DateValue.IsNull() || o.DateValue.IsUnknown() { + return e, false + } + var v []DateValue + d := o.DateValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDateValue sets the value of the DateValue field in QueryParameter. +func (o *QueryParameter) SetDateValue(ctx context.Context, v DateValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["date_value"] + o.DateValue = types.ListValueMust(t, vs) +} + +// GetEnumValue returns the value of the EnumValue field in QueryParameter as +// a EnumValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryParameter) GetEnumValue(ctx context.Context) (EnumValue, bool) { + var e EnumValue + if o.EnumValue.IsNull() || o.EnumValue.IsUnknown() { + return e, false + } + var v []EnumValue + d := o.EnumValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEnumValue sets the value of the EnumValue field in QueryParameter. +func (o *QueryParameter) SetEnumValue(ctx context.Context, v EnumValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enum_value"] + o.EnumValue = types.ListValueMust(t, vs) +} + +// GetNumericValue returns the value of the NumericValue field in QueryParameter as +// a NumericValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryParameter) GetNumericValue(ctx context.Context) (NumericValue, bool) { + var e NumericValue + if o.NumericValue.IsNull() || o.NumericValue.IsUnknown() { + return e, false + } + var v []NumericValue + d := o.NumericValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetNumericValue sets the value of the NumericValue field in QueryParameter. +func (o *QueryParameter) SetNumericValue(ctx context.Context, v NumericValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["numeric_value"] + o.NumericValue = types.ListValueMust(t, vs) +} + +// GetQueryBackedValue returns the value of the QueryBackedValue field in QueryParameter as +// a QueryBackedValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryParameter) GetQueryBackedValue(ctx context.Context) (QueryBackedValue, bool) { + var e QueryBackedValue + if o.QueryBackedValue.IsNull() || o.QueryBackedValue.IsUnknown() { + return e, false + } + var v []QueryBackedValue + d := o.QueryBackedValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQueryBackedValue sets the value of the QueryBackedValue field in QueryParameter. +func (o *QueryParameter) SetQueryBackedValue(ctx context.Context, v QueryBackedValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_backed_value"] + o.QueryBackedValue = types.ListValueMust(t, vs) +} + +// GetTextValue returns the value of the TextValue field in QueryParameter as +// a TextValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryParameter) GetTextValue(ctx context.Context) (TextValue, bool) { + var e TextValue + if o.TextValue.IsNull() || o.TextValue.IsUnknown() { + return e, false + } + var v []TextValue + d := o.TextValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetTextValue sets the value of the TextValue field in QueryParameter. +func (o *QueryParameter) SetTextValue(ctx context.Context, v TextValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["text_value"] + o.TextValue = types.ListValueMust(t, vs) +} + type QueryPostContent struct { // Data source ID maps to the ID of the data source used by the resource and // is distinct from the warehouse ID. [Learn more] @@ -6742,6 +9022,31 @@ func (o QueryPostContent) Type(ctx context.Context) attr.Type { } } +// GetTags returns the value of the Tags field in QueryPostContent as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryPostContent) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in QueryPostContent. +func (o *QueryPostContent) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type RepeatedEndpointConfPairs struct { // Deprecated: Use configuration_pairs ConfigPair types.List `tfsdk:"config_pair" tf:"optional"` @@ -6795,6 +9100,56 @@ func (o RepeatedEndpointConfPairs) Type(ctx context.Context) attr.Type { } } +// GetConfigPair returns the value of the ConfigPair field in RepeatedEndpointConfPairs as +// a slice of EndpointConfPair values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepeatedEndpointConfPairs) GetConfigPair(ctx context.Context) ([]EndpointConfPair, bool) { + if o.ConfigPair.IsNull() || o.ConfigPair.IsUnknown() { + return nil, false + } + var v []EndpointConfPair + d := o.ConfigPair.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetConfigPair sets the value of the ConfigPair field in RepeatedEndpointConfPairs. +func (o *RepeatedEndpointConfPairs) SetConfigPair(ctx context.Context, v []EndpointConfPair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config_pair"] + o.ConfigPair = types.ListValueMust(t, vs) +} + +// GetConfigurationPairs returns the value of the ConfigurationPairs field in RepeatedEndpointConfPairs as +// a slice of EndpointConfPair values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepeatedEndpointConfPairs) GetConfigurationPairs(ctx context.Context) ([]EndpointConfPair, bool) { + if o.ConfigurationPairs.IsNull() || o.ConfigurationPairs.IsUnknown() { + return nil, false + } + var v []EndpointConfPair + d := o.ConfigurationPairs.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetConfigurationPairs sets the value of the ConfigurationPairs field in RepeatedEndpointConfPairs. +func (o *RepeatedEndpointConfPairs) SetConfigurationPairs(ctx context.Context, v []EndpointConfPair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration_pairs"] + o.ConfigurationPairs = types.ListValueMust(t, vs) +} + // Restore a dashboard type RestoreDashboardRequest struct { DashboardId types.String `tfsdk:"-"` @@ -7002,6 +9357,56 @@ func (o ResultData) Type(ctx context.Context) attr.Type { } } +// GetDataArray returns the value of the DataArray field in ResultData as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultData) GetDataArray(ctx context.Context) ([]types.String, bool) { + if o.DataArray.IsNull() || o.DataArray.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DataArray.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDataArray sets the value of the DataArray field in ResultData. +func (o *ResultData) SetDataArray(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_array"] + o.DataArray = types.ListValueMust(t, vs) +} + +// GetExternalLinks returns the value of the ExternalLinks field in ResultData as +// a slice of ExternalLink values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultData) GetExternalLinks(ctx context.Context) ([]ExternalLink, bool) { + if o.ExternalLinks.IsNull() || o.ExternalLinks.IsUnknown() { + return nil, false + } + var v []ExternalLink + d := o.ExternalLinks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetExternalLinks sets the value of the ExternalLinks field in ResultData. +func (o *ResultData) SetExternalLinks(ctx context.Context, v []ExternalLink) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_links"] + o.ExternalLinks = types.ListValueMust(t, vs) +} + // The result manifest provides schema and metadata for the result set. type ResultManifest struct { // Array of result set chunk metadata. @@ -7078,6 +9483,57 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { } } +// GetChunks returns the value of the Chunks field in ResultManifest as +// a slice of BaseChunkInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultManifest) GetChunks(ctx context.Context) ([]BaseChunkInfo, bool) { + if o.Chunks.IsNull() || o.Chunks.IsUnknown() { + return nil, false + } + var v []BaseChunkInfo + d := o.Chunks.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetChunks sets the value of the Chunks field in ResultManifest. +func (o *ResultManifest) SetChunks(ctx context.Context, v []BaseChunkInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["chunks"] + o.Chunks = types.ListValueMust(t, vs) +} + +// GetSchema returns the value of the Schema field in ResultManifest as +// a ResultSchema value. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultManifest) GetSchema(ctx context.Context) (ResultSchema, bool) { + var e ResultSchema + if o.Schema.IsNull() || o.Schema.IsUnknown() { + return e, false + } + var v []ResultSchema + d := o.Schema.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSchema sets the value of the Schema field in ResultManifest. +func (o *ResultManifest) SetSchema(ctx context.Context, v ResultSchema) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schema"] + o.Schema = types.ListValueMust(t, vs) +} + // The schema is an ordered list of column descriptions. type ResultSchema struct { ColumnCount types.Int64 `tfsdk:"column_count" tf:"optional"` @@ -7128,6 +9584,31 @@ func (o ResultSchema) Type(ctx context.Context) attr.Type { } } +// GetColumns returns the value of the Columns field in ResultSchema as +// a slice of ColumnInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultSchema) GetColumns(ctx context.Context) ([]ColumnInfo, bool) { + if o.Columns.IsNull() || o.Columns.IsUnknown() { + return nil, false + } + var v []ColumnInfo + d := o.Columns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetColumns sets the value of the Columns field in ResultSchema. +func (o *ResultSchema) SetColumns(ctx context.Context, v []ColumnInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + o.Columns = types.ListValueMust(t, vs) +} + type ServiceError struct { ErrorCode types.String `tfsdk:"error_code" tf:"optional"` // A brief summary of the error condition. @@ -7228,6 +9709,31 @@ func (o SetRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in SetRequest as +// a slice of AccessControl values. +// If the field is unknown or null, the boolean return value is false. +func (o *SetRequest) GetAccessControlList(ctx context.Context) ([]AccessControl, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AccessControl + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in SetRequest. +func (o *SetRequest) SetAccessControlList(ctx context.Context, v []AccessControl) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type SetResponse struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` // An object's type and UUID, separated by a forward slash (/) character. @@ -7281,6 +9787,31 @@ func (o SetResponse) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in SetResponse as +// a slice of AccessControl values. +// If the field is unknown or null, the boolean return value is false. +func (o *SetResponse) GetAccessControlList(ctx context.Context) ([]AccessControl, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []AccessControl + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in SetResponse. +func (o *SetResponse) SetAccessControlList(ctx context.Context, v []AccessControl) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type SetWorkspaceWarehouseConfigRequest struct { // Optional: Channel selection details Channel types.List `tfsdk:"channel" tf:"optional,object"` @@ -7381,6 +9912,160 @@ func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type } } +// GetChannel returns the value of the Channel field in SetWorkspaceWarehouseConfigRequest as +// a Channel value. +// If the field is unknown or null, the boolean return value is false. +func (o *SetWorkspaceWarehouseConfigRequest) GetChannel(ctx context.Context) (Channel, bool) { + var e Channel + if o.Channel.IsNull() || o.Channel.IsUnknown() { + return e, false + } + var v []Channel + d := o.Channel.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetChannel sets the value of the Channel field in SetWorkspaceWarehouseConfigRequest. +func (o *SetWorkspaceWarehouseConfigRequest) SetChannel(ctx context.Context, v Channel) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["channel"] + o.Channel = types.ListValueMust(t, vs) +} + +// GetConfigParam returns the value of the ConfigParam field in SetWorkspaceWarehouseConfigRequest as +// a RepeatedEndpointConfPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *SetWorkspaceWarehouseConfigRequest) GetConfigParam(ctx context.Context) (RepeatedEndpointConfPairs, bool) { + var e RepeatedEndpointConfPairs + if o.ConfigParam.IsNull() || o.ConfigParam.IsUnknown() { + return e, false + } + var v []RepeatedEndpointConfPairs + d := o.ConfigParam.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetConfigParam sets the value of the ConfigParam field in SetWorkspaceWarehouseConfigRequest. +func (o *SetWorkspaceWarehouseConfigRequest) SetConfigParam(ctx context.Context, v RepeatedEndpointConfPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config_param"] + o.ConfigParam = types.ListValueMust(t, vs) +} + +// GetDataAccessConfig returns the value of the DataAccessConfig field in SetWorkspaceWarehouseConfigRequest as +// a slice of EndpointConfPair values. +// If the field is unknown or null, the boolean return value is false. +func (o *SetWorkspaceWarehouseConfigRequest) GetDataAccessConfig(ctx context.Context) ([]EndpointConfPair, bool) { + if o.DataAccessConfig.IsNull() || o.DataAccessConfig.IsUnknown() { + return nil, false + } + var v []EndpointConfPair + d := o.DataAccessConfig.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDataAccessConfig sets the value of the DataAccessConfig field in SetWorkspaceWarehouseConfigRequest. +func (o *SetWorkspaceWarehouseConfigRequest) SetDataAccessConfig(ctx context.Context, v []EndpointConfPair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_access_config"] + o.DataAccessConfig = types.ListValueMust(t, vs) +} + +// GetEnabledWarehouseTypes returns the value of the EnabledWarehouseTypes field in SetWorkspaceWarehouseConfigRequest as +// a slice of WarehouseTypePair values. +// If the field is unknown or null, the boolean return value is false. +func (o *SetWorkspaceWarehouseConfigRequest) GetEnabledWarehouseTypes(ctx context.Context) ([]WarehouseTypePair, bool) { + if o.EnabledWarehouseTypes.IsNull() || o.EnabledWarehouseTypes.IsUnknown() { + return nil, false + } + var v []WarehouseTypePair + d := o.EnabledWarehouseTypes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEnabledWarehouseTypes sets the value of the EnabledWarehouseTypes field in SetWorkspaceWarehouseConfigRequest. +func (o *SetWorkspaceWarehouseConfigRequest) SetEnabledWarehouseTypes(ctx context.Context, v []WarehouseTypePair) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enabled_warehouse_types"] + o.EnabledWarehouseTypes = types.ListValueMust(t, vs) +} + +// GetGlobalParam returns the value of the GlobalParam field in SetWorkspaceWarehouseConfigRequest as +// a RepeatedEndpointConfPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *SetWorkspaceWarehouseConfigRequest) GetGlobalParam(ctx context.Context) (RepeatedEndpointConfPairs, bool) { + var e RepeatedEndpointConfPairs + if o.GlobalParam.IsNull() || o.GlobalParam.IsUnknown() { + return e, false + } + var v []RepeatedEndpointConfPairs + d := o.GlobalParam.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetGlobalParam sets the value of the GlobalParam field in SetWorkspaceWarehouseConfigRequest. +func (o *SetWorkspaceWarehouseConfigRequest) SetGlobalParam(ctx context.Context, v RepeatedEndpointConfPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["global_param"] + o.GlobalParam = types.ListValueMust(t, vs) +} + +// GetSqlConfigurationParameters returns the value of the SqlConfigurationParameters field in SetWorkspaceWarehouseConfigRequest as +// a RepeatedEndpointConfPairs value. +// If the field is unknown or null, the boolean return value is false. +func (o *SetWorkspaceWarehouseConfigRequest) GetSqlConfigurationParameters(ctx context.Context) (RepeatedEndpointConfPairs, bool) { + var e RepeatedEndpointConfPairs + if o.SqlConfigurationParameters.IsNull() || o.SqlConfigurationParameters.IsUnknown() { + return e, false + } + var v []RepeatedEndpointConfPairs + d := o.SqlConfigurationParameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSqlConfigurationParameters sets the value of the SqlConfigurationParameters field in SetWorkspaceWarehouseConfigRequest. +func (o *SetWorkspaceWarehouseConfigRequest) SetSqlConfigurationParameters(ctx context.Context, v RepeatedEndpointConfPairs) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_configuration_parameters"] + o.SqlConfigurationParameters = types.ListValueMust(t, vs) +} + type SetWorkspaceWarehouseConfigResponse struct { } @@ -7619,6 +10304,84 @@ func (o StatementResponse) Type(ctx context.Context) attr.Type { } } +// GetManifest returns the value of the Manifest field in StatementResponse as +// a ResultManifest value. +// If the field is unknown or null, the boolean return value is false. +func (o *StatementResponse) GetManifest(ctx context.Context) (ResultManifest, bool) { + var e ResultManifest + if o.Manifest.IsNull() || o.Manifest.IsUnknown() { + return e, false + } + var v []ResultManifest + d := o.Manifest.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetManifest sets the value of the Manifest field in StatementResponse. +func (o *StatementResponse) SetManifest(ctx context.Context, v ResultManifest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["manifest"] + o.Manifest = types.ListValueMust(t, vs) +} + +// GetResult returns the value of the Result field in StatementResponse as +// a ResultData value. +// If the field is unknown or null, the boolean return value is false. +func (o *StatementResponse) GetResult(ctx context.Context) (ResultData, bool) { + var e ResultData + if o.Result.IsNull() || o.Result.IsUnknown() { + return e, false + } + var v []ResultData + d := o.Result.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetResult sets the value of the Result field in StatementResponse. +func (o *StatementResponse) SetResult(ctx context.Context, v ResultData) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["result"] + o.Result = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in StatementResponse as +// a StatementStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *StatementResponse) GetStatus(ctx context.Context) (StatementStatus, bool) { + var e StatementStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []StatementStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in StatementResponse. +func (o *StatementResponse) SetStatus(ctx context.Context, v StatementStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + // The status response includes execution state and if relevant, error // information. type StatementStatus struct { @@ -7676,6 +10439,32 @@ func (o StatementStatus) Type(ctx context.Context) attr.Type { } } +// GetError returns the value of the Error field in StatementStatus as +// a ServiceError value. +// If the field is unknown or null, the boolean return value is false. +func (o *StatementStatus) GetError(ctx context.Context) (ServiceError, bool) { + var e ServiceError + if o.Error.IsNull() || o.Error.IsUnknown() { + return e, false + } + var v []ServiceError + d := o.Error.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetError sets the value of the Error field in StatementStatus. +func (o *StatementStatus) SetError(ctx context.Context, v ServiceError) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error"] + o.Error = types.ListValueMust(t, vs) +} + // Stop a warehouse type StopRequest struct { // Required. Id of the SQL warehouse. @@ -7851,6 +10640,31 @@ func (o TerminationReason) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in TerminationReason as +// a map of string to types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *TerminationReason) GetParameters(ctx context.Context) (map[string]types.String, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v map[string]types.String + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in TerminationReason. +func (o *TerminationReason) SetParameters(ctx context.Context, v map[string]types.String) { + vs := make(map[string]attr.Value, len(v)) + for k, e := range v { + vs[k] = e + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.MapValueMust(t, vs) +} + type TextValue struct { Value types.String `tfsdk:"value" tf:"optional"` } @@ -8035,6 +10849,32 @@ func (o TransferOwnershipRequest) Type(ctx context.Context) attr.Type { } } +// GetObjectId returns the value of the ObjectId field in TransferOwnershipRequest as +// a TransferOwnershipObjectId value. +// If the field is unknown or null, the boolean return value is false. +func (o *TransferOwnershipRequest) GetObjectId(ctx context.Context) (TransferOwnershipObjectId, bool) { + var e TransferOwnershipObjectId + if o.ObjectId.IsNull() || o.ObjectId.IsUnknown() { + return e, false + } + var v []TransferOwnershipObjectId + d := o.ObjectId.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetObjectId sets the value of the ObjectId field in TransferOwnershipRequest. +func (o *TransferOwnershipRequest) SetObjectId(ctx context.Context, v TransferOwnershipObjectId) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["objectId"] + o.ObjectId = types.ListValueMust(t, vs) +} + // Delete an alert type TrashAlertRequest struct { Id types.String `tfsdk:"-"` @@ -8175,6 +11015,32 @@ func (o UpdateAlertRequest) Type(ctx context.Context) attr.Type { } } +// GetAlert returns the value of the Alert field in UpdateAlertRequest as +// a UpdateAlertRequestAlert value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateAlertRequest) GetAlert(ctx context.Context) (UpdateAlertRequestAlert, bool) { + var e UpdateAlertRequestAlert + if o.Alert.IsNull() || o.Alert.IsUnknown() { + return e, false + } + var v []UpdateAlertRequestAlert + d := o.Alert.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetAlert sets the value of the Alert field in UpdateAlertRequest. +func (o *UpdateAlertRequest) SetAlert(ctx context.Context, v UpdateAlertRequestAlert) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert"] + o.Alert = types.ListValueMust(t, vs) +} + type UpdateAlertRequestAlert struct { // Trigger conditions of the alert. Condition types.List `tfsdk:"condition" tf:"optional,object"` @@ -8259,6 +11125,32 @@ func (o UpdateAlertRequestAlert) Type(ctx context.Context) attr.Type { } } +// GetCondition returns the value of the Condition field in UpdateAlertRequestAlert as +// a AlertCondition value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateAlertRequestAlert) GetCondition(ctx context.Context) (AlertCondition, bool) { + var e AlertCondition + if o.Condition.IsNull() || o.Condition.IsUnknown() { + return e, false + } + var v []AlertCondition + d := o.Condition.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetCondition sets the value of the Condition field in UpdateAlertRequestAlert. +func (o *UpdateAlertRequestAlert) SetCondition(ctx context.Context, v AlertCondition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["condition"] + o.Condition = types.ListValueMust(t, vs) +} + type UpdateQueryRequest struct { Id types.String `tfsdk:"-"` @@ -8315,6 +11207,32 @@ func (o UpdateQueryRequest) Type(ctx context.Context) attr.Type { } } +// GetQuery returns the value of the Query field in UpdateQueryRequest as +// a UpdateQueryRequestQuery value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateQueryRequest) GetQuery(ctx context.Context) (UpdateQueryRequestQuery, bool) { + var e UpdateQueryRequestQuery + if o.Query.IsNull() || o.Query.IsUnknown() { + return e, false + } + var v []UpdateQueryRequestQuery + d := o.Query.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetQuery sets the value of the Query field in UpdateQueryRequest. +func (o *UpdateQueryRequest) SetQuery(ctx context.Context, v UpdateQueryRequestQuery) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query"] + o.Query = types.ListValueMust(t, vs) +} + type UpdateQueryRequestQuery struct { // Whether to apply a 1000 row limit to the query result. ApplyAutoLimit types.Bool `tfsdk:"apply_auto_limit" tf:"optional"` @@ -8406,6 +11324,56 @@ func (o UpdateQueryRequestQuery) Type(ctx context.Context) attr.Type { } } +// GetParameters returns the value of the Parameters field in UpdateQueryRequestQuery as +// a slice of QueryParameter values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateQueryRequestQuery) GetParameters(ctx context.Context) ([]QueryParameter, bool) { + if o.Parameters.IsNull() || o.Parameters.IsUnknown() { + return nil, false + } + var v []QueryParameter + d := o.Parameters.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetParameters sets the value of the Parameters field in UpdateQueryRequestQuery. +func (o *UpdateQueryRequestQuery) SetParameters(ctx context.Context, v []QueryParameter) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + o.Parameters = types.ListValueMust(t, vs) +} + +// GetTags returns the value of the Tags field in UpdateQueryRequestQuery as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateQueryRequestQuery) GetTags(ctx context.Context) ([]types.String, bool) { + if o.Tags.IsNull() || o.Tags.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Tags.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetTags sets the value of the Tags field in UpdateQueryRequestQuery. +func (o *UpdateQueryRequestQuery) SetTags(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + o.Tags = types.ListValueMust(t, vs) +} + type UpdateResponse struct { } @@ -8498,6 +11466,32 @@ func (o UpdateVisualizationRequest) Type(ctx context.Context) attr.Type { } } +// GetVisualization returns the value of the Visualization field in UpdateVisualizationRequest as +// a UpdateVisualizationRequestVisualization value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateVisualizationRequest) GetVisualization(ctx context.Context) (UpdateVisualizationRequestVisualization, bool) { + var e UpdateVisualizationRequestVisualization + if o.Visualization.IsNull() || o.Visualization.IsUnknown() { + return e, false + } + var v []UpdateVisualizationRequestVisualization + d := o.Visualization.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVisualization sets the value of the Visualization field in UpdateVisualizationRequest. +func (o *UpdateVisualizationRequest) SetVisualization(ctx context.Context, v UpdateVisualizationRequestVisualization) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["visualization"] + o.Visualization = types.ListValueMust(t, vs) +} + type UpdateVisualizationRequestVisualization struct { // The display name of the visualization. DisplayName types.String `tfsdk:"display_name" tf:"optional"` @@ -8795,6 +11789,31 @@ func (o WarehouseAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in WarehouseAccessControlResponse as +// a slice of WarehousePermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *WarehouseAccessControlResponse) GetAllPermissions(ctx context.Context) ([]WarehousePermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []WarehousePermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in WarehouseAccessControlResponse. +func (o *WarehouseAccessControlResponse) SetAllPermissions(ctx context.Context, v []WarehousePermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type WarehousePermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -8848,6 +11867,31 @@ func (o WarehousePermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in WarehousePermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *WarehousePermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in WarehousePermission. +func (o *WarehousePermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type WarehousePermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -8901,6 +11945,31 @@ func (o WarehousePermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in WarehousePermissions as +// a slice of WarehouseAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *WarehousePermissions) GetAccessControlList(ctx context.Context) ([]WarehouseAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []WarehouseAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in WarehousePermissions. +func (o *WarehousePermissions) SetAccessControlList(ctx context.Context, v []WarehouseAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type WarehousePermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -8995,6 +12064,31 @@ func (o WarehousePermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in WarehousePermissionsRequest as +// a slice of WarehouseAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *WarehousePermissionsRequest) GetAccessControlList(ctx context.Context) ([]WarehouseAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []WarehouseAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in WarehousePermissionsRequest. +func (o *WarehousePermissionsRequest) SetAccessControlList(ctx context.Context, v []WarehouseAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type WarehouseTypePair struct { // If set to false the specific warehouse type will not be be allowed as a // value for warehouse_type in CreateWarehouse and EditWarehouse @@ -9107,6 +12201,58 @@ func (o Widget) Type(ctx context.Context) attr.Type { } } +// GetOptions returns the value of the Options field in Widget as +// a WidgetOptions value. +// If the field is unknown or null, the boolean return value is false. +func (o *Widget) GetOptions(ctx context.Context) (WidgetOptions, bool) { + var e WidgetOptions + if o.Options.IsNull() || o.Options.IsUnknown() { + return e, false + } + var v []WidgetOptions + d := o.Options.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetOptions sets the value of the Options field in Widget. +func (o *Widget) SetOptions(ctx context.Context, v WidgetOptions) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + o.Options = types.ListValueMust(t, vs) +} + +// GetVisualization returns the value of the Visualization field in Widget as +// a LegacyVisualization value. +// If the field is unknown or null, the boolean return value is false. +func (o *Widget) GetVisualization(ctx context.Context) (LegacyVisualization, bool) { + var e LegacyVisualization + if o.Visualization.IsNull() || o.Visualization.IsUnknown() { + return e, false + } + var v []LegacyVisualization + d := o.Visualization.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVisualization sets the value of the Visualization field in Widget. +func (o *Widget) SetVisualization(ctx context.Context, v LegacyVisualization) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["visualization"] + o.Visualization = types.ListValueMust(t, vs) +} + type WidgetOptions struct { // Timestamp when this object was created CreatedAt types.String `tfsdk:"created_at" tf:"optional"` @@ -9180,6 +12326,32 @@ func (o WidgetOptions) Type(ctx context.Context) attr.Type { } } +// GetPosition returns the value of the Position field in WidgetOptions as +// a WidgetPosition value. +// If the field is unknown or null, the boolean return value is false. +func (o *WidgetOptions) GetPosition(ctx context.Context) (WidgetPosition, bool) { + var e WidgetPosition + if o.Position.IsNull() || o.Position.IsUnknown() { + return e, false + } + var v []WidgetPosition + d := o.Position.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetPosition sets the value of the Position field in WidgetOptions. +func (o *WidgetOptions) SetPosition(ctx context.Context, v WidgetPosition) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["position"] + o.Position = types.ListValueMust(t, vs) +} + // Coordinates of this widget on a dashboard. This portion of the API changes // frequently and is unsupported. type WidgetPosition struct { @@ -9239,80 +12411,3 @@ func (o WidgetPosition) Type(ctx context.Context) attr.Type { }, } } - -// State that alert evaluates to when query result is empty. - -// The name of the base data type. This doesn't include details for complex -// types such as STRUCT, MAP or ARRAY. - -// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, -// you must set to `PRO` and also set the field `enable_serverless_compute` to -// `true`. - -// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, -// you must set to `PRO` and also set the field `enable_serverless_compute` to -// `true`. - -// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, -// you must set to `PRO` and also set the field `enable_serverless_compute` to -// `true`. - -// When `wait_timeout > 0s`, the call will block up to the specified time. If -// the statement execution doesn't finish within this time, `on_wait_timeout` -// determines whether the execution should continue or be canceled. When set to -// `CONTINUE`, the statement execution continues asynchronously and the call -// returns a statement ID which can be used for polling with -// :method:statementexecution/getStatement. When set to `CANCEL`, the statement -// execution is canceled and the call returns with a `CANCELED` state. - -// Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, -// you must set to `PRO` and also set the field `enable_serverless_compute` to -// `true`. - -// Security policy for warehouses - -// State of the alert. Possible values are: `unknown` (yet to be evaluated), -// `triggered` (evaluated and fulfilled trigger conditions), or `ok` (evaluated -// and did not fulfill trigger conditions). - -// A singular noun object type. - -// Always a plural of the object type. - -// The singular form of the type of object which can be owned. - -// Parameters can have several different types. - -// * `CAN_VIEW`: Can view the query * `CAN_RUN`: Can run the query * `CAN_EDIT`: -// Can edit the query * `CAN_MANAGE`: Can manage the query - -// Possible Reasons for which we have not saved plans in the database - -// Statuses which are also used by OperationStatus in runtime - -// Sets the **Run as** role for the object. Must be set to one of `"viewer"` -// (signifying "run as viewer" behavior) or `"owner"` (signifying "run as owner" -// behavior) - -// Security policy for warehouses - -// Configurations whether the warehouse should use spot instances. - -// State of the warehouse - -// Statement execution state: - `PENDING`: waiting for warehouse - `RUNNING`: -// running - `SUCCEEDED`: execution was successful, result data available for -// fetch - `FAILED`: execution failed; reason for failure described in -// accomanying error message - `CANCELED`: user canceled; can come from explicit -// cancel call, or timeout with `on_wait_timeout=CANCEL` - `CLOSED`: execution -// successful, and statement closed; result no longer available for fetch - -// Health status of the warehouse. - -// status code indicating why the cluster was terminated - -// type of the termination - -// Permission level - -// Warehouse type: `PRO` or `CLASSIC`. diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 20b03299a8..d8bd24cc31 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -184,6 +185,58 @@ func (o CreateVectorIndexRequest) Type(ctx context.Context) attr.Type { } } +// GetDeltaSyncIndexSpec returns the value of the DeltaSyncIndexSpec field in CreateVectorIndexRequest as +// a DeltaSyncVectorIndexSpecRequest value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateVectorIndexRequest) GetDeltaSyncIndexSpec(ctx context.Context) (DeltaSyncVectorIndexSpecRequest, bool) { + var e DeltaSyncVectorIndexSpecRequest + if o.DeltaSyncIndexSpec.IsNull() || o.DeltaSyncIndexSpec.IsUnknown() { + return e, false + } + var v []DeltaSyncVectorIndexSpecRequest + d := o.DeltaSyncIndexSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeltaSyncIndexSpec sets the value of the DeltaSyncIndexSpec field in CreateVectorIndexRequest. +func (o *CreateVectorIndexRequest) SetDeltaSyncIndexSpec(ctx context.Context, v DeltaSyncVectorIndexSpecRequest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delta_sync_index_spec"] + o.DeltaSyncIndexSpec = types.ListValueMust(t, vs) +} + +// GetDirectAccessIndexSpec returns the value of the DirectAccessIndexSpec field in CreateVectorIndexRequest as +// a DirectAccessVectorIndexSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateVectorIndexRequest) GetDirectAccessIndexSpec(ctx context.Context) (DirectAccessVectorIndexSpec, bool) { + var e DirectAccessVectorIndexSpec + if o.DirectAccessIndexSpec.IsNull() || o.DirectAccessIndexSpec.IsUnknown() { + return e, false + } + var v []DirectAccessVectorIndexSpec + d := o.DirectAccessIndexSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDirectAccessIndexSpec sets the value of the DirectAccessIndexSpec field in CreateVectorIndexRequest. +func (o *CreateVectorIndexRequest) SetDirectAccessIndexSpec(ctx context.Context, v DirectAccessVectorIndexSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["direct_access_index_spec"] + o.DirectAccessIndexSpec = types.ListValueMust(t, vs) +} + type CreateVectorIndexResponse struct { VectorIndex types.List `tfsdk:"vector_index" tf:"optional,object"` } @@ -229,6 +282,32 @@ func (o CreateVectorIndexResponse) Type(ctx context.Context) attr.Type { } } +// GetVectorIndex returns the value of the VectorIndex field in CreateVectorIndexResponse as +// a VectorIndex value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateVectorIndexResponse) GetVectorIndex(ctx context.Context) (VectorIndex, bool) { + var e VectorIndex + if o.VectorIndex.IsNull() || o.VectorIndex.IsUnknown() { + return e, false + } + var v []VectorIndex + d := o.VectorIndex.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetVectorIndex sets the value of the VectorIndex field in CreateVectorIndexResponse. +func (o *CreateVectorIndexResponse) SetVectorIndex(ctx context.Context, v VectorIndex) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["vector_index"] + o.VectorIndex = types.ListValueMust(t, vs) +} + // Result of the upsert or delete operation. type DeleteDataResult struct { // List of primary keys for rows that failed to process. @@ -280,6 +359,31 @@ func (o DeleteDataResult) Type(ctx context.Context) attr.Type { } } +// GetFailedPrimaryKeys returns the value of the FailedPrimaryKeys field in DeleteDataResult as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeleteDataResult) GetFailedPrimaryKeys(ctx context.Context) ([]types.String, bool) { + if o.FailedPrimaryKeys.IsNull() || o.FailedPrimaryKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FailedPrimaryKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFailedPrimaryKeys sets the value of the FailedPrimaryKeys field in DeleteDataResult. +func (o *DeleteDataResult) SetFailedPrimaryKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["failed_primary_keys"] + o.FailedPrimaryKeys = types.ListValueMust(t, vs) +} + // Request payload for deleting data from a vector index. type DeleteDataVectorIndexRequest struct { // Name of the vector index where data is to be deleted. Must be a Direct @@ -332,6 +436,31 @@ func (o DeleteDataVectorIndexRequest) Type(ctx context.Context) attr.Type { } } +// GetPrimaryKeys returns the value of the PrimaryKeys field in DeleteDataVectorIndexRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeleteDataVectorIndexRequest) GetPrimaryKeys(ctx context.Context) ([]types.String, bool) { + if o.PrimaryKeys.IsNull() || o.PrimaryKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.PrimaryKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPrimaryKeys sets the value of the PrimaryKeys field in DeleteDataVectorIndexRequest. +func (o *DeleteDataVectorIndexRequest) SetPrimaryKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_keys"] + o.PrimaryKeys = types.ListValueMust(t, vs) +} + // Response to a delete data vector index request. type DeleteDataVectorIndexResponse struct { // Result of the upsert or delete operation. @@ -383,6 +512,32 @@ func (o DeleteDataVectorIndexResponse) Type(ctx context.Context) attr.Type { } } +// GetResult returns the value of the Result field in DeleteDataVectorIndexResponse as +// a DeleteDataResult value. +// If the field is unknown or null, the boolean return value is false. +func (o *DeleteDataVectorIndexResponse) GetResult(ctx context.Context) (DeleteDataResult, bool) { + var e DeleteDataResult + if o.Result.IsNull() || o.Result.IsUnknown() { + return e, false + } + var v []DeleteDataResult + d := o.Result.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetResult sets the value of the Result field in DeleteDataVectorIndexResponse. +func (o *DeleteDataVectorIndexResponse) SetResult(ctx context.Context, v DeleteDataResult) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["result"] + o.Result = types.ListValueMust(t, vs) +} + // Delete an endpoint type DeleteEndpointRequest struct { // Name of the endpoint @@ -626,6 +781,81 @@ func (o DeltaSyncVectorIndexSpecRequest) Type(ctx context.Context) attr.Type { } } +// GetColumnsToSync returns the value of the ColumnsToSync field in DeltaSyncVectorIndexSpecRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeltaSyncVectorIndexSpecRequest) GetColumnsToSync(ctx context.Context) ([]types.String, bool) { + if o.ColumnsToSync.IsNull() || o.ColumnsToSync.IsUnknown() { + return nil, false + } + var v []types.String + d := o.ColumnsToSync.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetColumnsToSync sets the value of the ColumnsToSync field in DeltaSyncVectorIndexSpecRequest. +func (o *DeltaSyncVectorIndexSpecRequest) SetColumnsToSync(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns_to_sync"] + o.ColumnsToSync = types.ListValueMust(t, vs) +} + +// GetEmbeddingSourceColumns returns the value of the EmbeddingSourceColumns field in DeltaSyncVectorIndexSpecRequest as +// a slice of EmbeddingSourceColumn values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeltaSyncVectorIndexSpecRequest) GetEmbeddingSourceColumns(ctx context.Context) ([]EmbeddingSourceColumn, bool) { + if o.EmbeddingSourceColumns.IsNull() || o.EmbeddingSourceColumns.IsUnknown() { + return nil, false + } + var v []EmbeddingSourceColumn + d := o.EmbeddingSourceColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddingSourceColumns sets the value of the EmbeddingSourceColumns field in DeltaSyncVectorIndexSpecRequest. +func (o *DeltaSyncVectorIndexSpecRequest) SetEmbeddingSourceColumns(ctx context.Context, v []EmbeddingSourceColumn) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_source_columns"] + o.EmbeddingSourceColumns = types.ListValueMust(t, vs) +} + +// GetEmbeddingVectorColumns returns the value of the EmbeddingVectorColumns field in DeltaSyncVectorIndexSpecRequest as +// a slice of EmbeddingVectorColumn values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeltaSyncVectorIndexSpecRequest) GetEmbeddingVectorColumns(ctx context.Context) ([]EmbeddingVectorColumn, bool) { + if o.EmbeddingVectorColumns.IsNull() || o.EmbeddingVectorColumns.IsUnknown() { + return nil, false + } + var v []EmbeddingVectorColumn + d := o.EmbeddingVectorColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddingVectorColumns sets the value of the EmbeddingVectorColumns field in DeltaSyncVectorIndexSpecRequest. +func (o *DeltaSyncVectorIndexSpecRequest) SetEmbeddingVectorColumns(ctx context.Context, v []EmbeddingVectorColumn) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_vector_columns"] + o.EmbeddingVectorColumns = types.ListValueMust(t, vs) +} + type DeltaSyncVectorIndexSpecResponse struct { // The columns that contain the embedding source. EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` @@ -703,6 +933,56 @@ func (o DeltaSyncVectorIndexSpecResponse) Type(ctx context.Context) attr.Type { } } +// GetEmbeddingSourceColumns returns the value of the EmbeddingSourceColumns field in DeltaSyncVectorIndexSpecResponse as +// a slice of EmbeddingSourceColumn values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeltaSyncVectorIndexSpecResponse) GetEmbeddingSourceColumns(ctx context.Context) ([]EmbeddingSourceColumn, bool) { + if o.EmbeddingSourceColumns.IsNull() || o.EmbeddingSourceColumns.IsUnknown() { + return nil, false + } + var v []EmbeddingSourceColumn + d := o.EmbeddingSourceColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddingSourceColumns sets the value of the EmbeddingSourceColumns field in DeltaSyncVectorIndexSpecResponse. +func (o *DeltaSyncVectorIndexSpecResponse) SetEmbeddingSourceColumns(ctx context.Context, v []EmbeddingSourceColumn) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_source_columns"] + o.EmbeddingSourceColumns = types.ListValueMust(t, vs) +} + +// GetEmbeddingVectorColumns returns the value of the EmbeddingVectorColumns field in DeltaSyncVectorIndexSpecResponse as +// a slice of EmbeddingVectorColumn values. +// If the field is unknown or null, the boolean return value is false. +func (o *DeltaSyncVectorIndexSpecResponse) GetEmbeddingVectorColumns(ctx context.Context) ([]EmbeddingVectorColumn, bool) { + if o.EmbeddingVectorColumns.IsNull() || o.EmbeddingVectorColumns.IsUnknown() { + return nil, false + } + var v []EmbeddingVectorColumn + d := o.EmbeddingVectorColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddingVectorColumns sets the value of the EmbeddingVectorColumns field in DeltaSyncVectorIndexSpecResponse. +func (o *DeltaSyncVectorIndexSpecResponse) SetEmbeddingVectorColumns(ctx context.Context, v []EmbeddingVectorColumn) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_vector_columns"] + o.EmbeddingVectorColumns = types.ListValueMust(t, vs) +} + type DirectAccessVectorIndexSpec struct { // Contains the optional model endpoint to use during query time. EmbeddingSourceColumns types.List `tfsdk:"embedding_source_columns" tf:"optional"` @@ -765,6 +1045,56 @@ func (o DirectAccessVectorIndexSpec) Type(ctx context.Context) attr.Type { } } +// GetEmbeddingSourceColumns returns the value of the EmbeddingSourceColumns field in DirectAccessVectorIndexSpec as +// a slice of EmbeddingSourceColumn values. +// If the field is unknown or null, the boolean return value is false. +func (o *DirectAccessVectorIndexSpec) GetEmbeddingSourceColumns(ctx context.Context) ([]EmbeddingSourceColumn, bool) { + if o.EmbeddingSourceColumns.IsNull() || o.EmbeddingSourceColumns.IsUnknown() { + return nil, false + } + var v []EmbeddingSourceColumn + d := o.EmbeddingSourceColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddingSourceColumns sets the value of the EmbeddingSourceColumns field in DirectAccessVectorIndexSpec. +func (o *DirectAccessVectorIndexSpec) SetEmbeddingSourceColumns(ctx context.Context, v []EmbeddingSourceColumn) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_source_columns"] + o.EmbeddingSourceColumns = types.ListValueMust(t, vs) +} + +// GetEmbeddingVectorColumns returns the value of the EmbeddingVectorColumns field in DirectAccessVectorIndexSpec as +// a slice of EmbeddingVectorColumn values. +// If the field is unknown or null, the boolean return value is false. +func (o *DirectAccessVectorIndexSpec) GetEmbeddingVectorColumns(ctx context.Context) ([]EmbeddingVectorColumn, bool) { + if o.EmbeddingVectorColumns.IsNull() || o.EmbeddingVectorColumns.IsUnknown() { + return nil, false + } + var v []EmbeddingVectorColumn + d := o.EmbeddingVectorColumns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEmbeddingVectorColumns sets the value of the EmbeddingVectorColumns field in DirectAccessVectorIndexSpec. +func (o *DirectAccessVectorIndexSpec) SetEmbeddingVectorColumns(ctx context.Context, v []EmbeddingVectorColumn) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_vector_columns"] + o.EmbeddingVectorColumns = types.ListValueMust(t, vs) +} + type EmbeddingSourceColumn struct { // Name of the embedding model endpoint EmbeddingModelEndpointName types.String `tfsdk:"embedding_model_endpoint_name" tf:"optional"` @@ -935,6 +1265,32 @@ func (o EndpointInfo) Type(ctx context.Context) attr.Type { } } +// GetEndpointStatus returns the value of the EndpointStatus field in EndpointInfo as +// a EndpointStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *EndpointInfo) GetEndpointStatus(ctx context.Context) (EndpointStatus, bool) { + var e EndpointStatus + if o.EndpointStatus.IsNull() || o.EndpointStatus.IsUnknown() { + return e, false + } + var v []EndpointStatus + d := o.EndpointStatus.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetEndpointStatus sets the value of the EndpointStatus field in EndpointInfo. +func (o *EndpointInfo) SetEndpointStatus(ctx context.Context, v EndpointStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["endpoint_status"] + o.EndpointStatus = types.ListValueMust(t, vs) +} + // Status information of an endpoint type EndpointStatus struct { // Additional status message @@ -1119,6 +1475,31 @@ func (o ListEndpointResponse) Type(ctx context.Context) attr.Type { } } +// GetEndpoints returns the value of the Endpoints field in ListEndpointResponse as +// a slice of EndpointInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListEndpointResponse) GetEndpoints(ctx context.Context) ([]EndpointInfo, bool) { + if o.Endpoints.IsNull() || o.Endpoints.IsUnknown() { + return nil, false + } + var v []EndpointInfo + d := o.Endpoints.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetEndpoints sets the value of the Endpoints field in ListEndpointResponse. +func (o *ListEndpointResponse) SetEndpoints(ctx context.Context, v []EndpointInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["endpoints"] + o.Endpoints = types.ListValueMust(t, vs) +} + // List all endpoints type ListEndpointsRequest struct { // Token for pagination @@ -1254,6 +1635,31 @@ func (o ListValue) Type(ctx context.Context) attr.Type { } } +// GetValues returns the value of the Values field in ListValue as +// a slice of Value values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListValue) GetValues(ctx context.Context) ([]Value, bool) { + if o.Values.IsNull() || o.Values.IsUnknown() { + return nil, false + } + var v []Value + d := o.Values.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetValues sets the value of the Values field in ListValue. +func (o *ListValue) SetValues(ctx context.Context, v []Value) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + o.Values = types.ListValueMust(t, vs) +} + type ListVectorIndexesResponse struct { // A token that can be used to get the next page of results. If not present, // there are no more results to show. @@ -1305,6 +1711,31 @@ func (o ListVectorIndexesResponse) Type(ctx context.Context) attr.Type { } } +// GetVectorIndexes returns the value of the VectorIndexes field in ListVectorIndexesResponse as +// a slice of MiniVectorIndex values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListVectorIndexesResponse) GetVectorIndexes(ctx context.Context) ([]MiniVectorIndex, bool) { + if o.VectorIndexes.IsNull() || o.VectorIndexes.IsUnknown() { + return nil, false + } + var v []MiniVectorIndex + d := o.VectorIndexes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetVectorIndexes sets the value of the VectorIndexes field in ListVectorIndexesResponse. +func (o *ListVectorIndexesResponse) SetVectorIndexes(ctx context.Context, v []MiniVectorIndex) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["vector_indexes"] + o.VectorIndexes = types.ListValueMust(t, vs) +} + // Key-value pair. type MapStringValueEntry struct { // Column name. @@ -1356,6 +1787,32 @@ func (o MapStringValueEntry) Type(ctx context.Context) attr.Type { } } +// GetValue returns the value of the Value field in MapStringValueEntry as +// a Value value. +// If the field is unknown or null, the boolean return value is false. +func (o *MapStringValueEntry) GetValue(ctx context.Context) (Value, bool) { + var e Value + if o.Value.IsNull() || o.Value.IsUnknown() { + return e, false + } + var v []Value + d := o.Value.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetValue sets the value of the Value field in MapStringValueEntry. +func (o *MapStringValueEntry) SetValue(ctx context.Context, v Value) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["value"] + o.Value = types.ListValueMust(t, vs) +} + type MiniVectorIndex struct { // The user who created the index. Creator types.String `tfsdk:"creator" tf:"optional"` @@ -1555,6 +2012,56 @@ func (o QueryVectorIndexRequest) Type(ctx context.Context) attr.Type { } } +// GetColumns returns the value of the Columns field in QueryVectorIndexRequest as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryVectorIndexRequest) GetColumns(ctx context.Context) ([]types.String, bool) { + if o.Columns.IsNull() || o.Columns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Columns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetColumns sets the value of the Columns field in QueryVectorIndexRequest. +func (o *QueryVectorIndexRequest) SetColumns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + o.Columns = types.ListValueMust(t, vs) +} + +// GetQueryVector returns the value of the QueryVector field in QueryVectorIndexRequest as +// a slice of types.Float64 values. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryVectorIndexRequest) GetQueryVector(ctx context.Context) ([]types.Float64, bool) { + if o.QueryVector.IsNull() || o.QueryVector.IsUnknown() { + return nil, false + } + var v []types.Float64 + d := o.QueryVector.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetQueryVector sets the value of the QueryVector field in QueryVectorIndexRequest. +func (o *QueryVectorIndexRequest) SetQueryVector(ctx context.Context, v []types.Float64) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_vector"] + o.QueryVector = types.ListValueMust(t, vs) +} + type QueryVectorIndexResponse struct { // Metadata about the result set. Manifest types.List `tfsdk:"manifest" tf:"optional,object"` @@ -1614,6 +2121,58 @@ func (o QueryVectorIndexResponse) Type(ctx context.Context) attr.Type { } } +// GetManifest returns the value of the Manifest field in QueryVectorIndexResponse as +// a ResultManifest value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryVectorIndexResponse) GetManifest(ctx context.Context) (ResultManifest, bool) { + var e ResultManifest + if o.Manifest.IsNull() || o.Manifest.IsUnknown() { + return e, false + } + var v []ResultManifest + d := o.Manifest.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetManifest sets the value of the Manifest field in QueryVectorIndexResponse. +func (o *QueryVectorIndexResponse) SetManifest(ctx context.Context, v ResultManifest) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["manifest"] + o.Manifest = types.ListValueMust(t, vs) +} + +// GetResult returns the value of the Result field in QueryVectorIndexResponse as +// a ResultData value. +// If the field is unknown or null, the boolean return value is false. +func (o *QueryVectorIndexResponse) GetResult(ctx context.Context) (ResultData, bool) { + var e ResultData + if o.Result.IsNull() || o.Result.IsUnknown() { + return e, false + } + var v []ResultData + d := o.Result.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetResult sets the value of the Result field in QueryVectorIndexResponse. +func (o *QueryVectorIndexResponse) SetResult(ctx context.Context, v ResultData) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["result"] + o.Result = types.ListValueMust(t, vs) +} + // Data returned in the query result. type ResultData struct { // Data rows returned in the query. @@ -1667,6 +2226,31 @@ func (o ResultData) Type(ctx context.Context) attr.Type { } } +// GetDataArray returns the value of the DataArray field in ResultData as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultData) GetDataArray(ctx context.Context) ([]types.String, bool) { + if o.DataArray.IsNull() || o.DataArray.IsUnknown() { + return nil, false + } + var v []types.String + d := o.DataArray.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetDataArray sets the value of the DataArray field in ResultData. +func (o *ResultData) SetDataArray(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_array"] + o.DataArray = types.ListValueMust(t, vs) +} + // Metadata about the result set. type ResultManifest struct { // Number of columns in the result set. @@ -1718,6 +2302,31 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { } } +// GetColumns returns the value of the Columns field in ResultManifest as +// a slice of ColumnInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ResultManifest) GetColumns(ctx context.Context) ([]ColumnInfo, bool) { + if o.Columns.IsNull() || o.Columns.IsUnknown() { + return nil, false + } + var v []ColumnInfo + d := o.Columns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetColumns sets the value of the Columns field in ResultManifest. +func (o *ResultManifest) SetColumns(ctx context.Context, v []ColumnInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + o.Columns = types.ListValueMust(t, vs) +} + // Request payload for scanning data from a vector index. type ScanVectorIndexRequest struct { // Name of the vector index to scan. @@ -1820,6 +2429,31 @@ func (o ScanVectorIndexResponse) Type(ctx context.Context) attr.Type { } } +// GetData returns the value of the Data field in ScanVectorIndexResponse as +// a slice of Struct values. +// If the field is unknown or null, the boolean return value is false. +func (o *ScanVectorIndexResponse) GetData(ctx context.Context) ([]Struct, bool) { + if o.Data.IsNull() || o.Data.IsUnknown() { + return nil, false + } + var v []Struct + d := o.Data.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetData sets the value of the Data field in ScanVectorIndexResponse. +func (o *ScanVectorIndexResponse) SetData(ctx context.Context, v []Struct) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + o.Data = types.ListValueMust(t, vs) +} + type Struct struct { // Data entry, corresponding to a row in a vector index. Fields types.List `tfsdk:"fields" tf:"optional"` @@ -1866,6 +2500,31 @@ func (o Struct) Type(ctx context.Context) attr.Type { } } +// GetFields returns the value of the Fields field in Struct as +// a slice of MapStringValueEntry values. +// If the field is unknown or null, the boolean return value is false. +func (o *Struct) GetFields(ctx context.Context) ([]MapStringValueEntry, bool) { + if o.Fields.IsNull() || o.Fields.IsUnknown() { + return nil, false + } + var v []MapStringValueEntry + d := o.Fields.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFields sets the value of the Fields field in Struct. +func (o *Struct) SetFields(ctx context.Context, v []MapStringValueEntry) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fields"] + o.Fields = types.ListValueMust(t, vs) +} + // Synchronize an index type SyncIndexRequest struct { // Name of the vector index to synchronize. Must be a Delta Sync Index. @@ -1996,6 +2655,31 @@ func (o UpsertDataResult) Type(ctx context.Context) attr.Type { } } +// GetFailedPrimaryKeys returns the value of the FailedPrimaryKeys field in UpsertDataResult as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *UpsertDataResult) GetFailedPrimaryKeys(ctx context.Context) ([]types.String, bool) { + if o.FailedPrimaryKeys.IsNull() || o.FailedPrimaryKeys.IsUnknown() { + return nil, false + } + var v []types.String + d := o.FailedPrimaryKeys.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetFailedPrimaryKeys sets the value of the FailedPrimaryKeys field in UpsertDataResult. +func (o *UpsertDataResult) SetFailedPrimaryKeys(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["failed_primary_keys"] + o.FailedPrimaryKeys = types.ListValueMust(t, vs) +} + // Request payload for upserting data into a vector index. type UpsertDataVectorIndexRequest struct { // Name of the vector index where data is to be upserted. Must be a Direct @@ -2095,6 +2779,32 @@ func (o UpsertDataVectorIndexResponse) Type(ctx context.Context) attr.Type { } } +// GetResult returns the value of the Result field in UpsertDataVectorIndexResponse as +// a UpsertDataResult value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpsertDataVectorIndexResponse) GetResult(ctx context.Context) (UpsertDataResult, bool) { + var e UpsertDataResult + if o.Result.IsNull() || o.Result.IsUnknown() { + return e, false + } + var v []UpsertDataResult + d := o.Result.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetResult sets the value of the Result field in UpsertDataVectorIndexResponse. +func (o *UpsertDataVectorIndexResponse) SetResult(ctx context.Context, v UpsertDataResult) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["result"] + o.Result = types.ListValueMust(t, vs) +} + type Value struct { BoolValue types.Bool `tfsdk:"bool_value" tf:"optional"` @@ -2163,6 +2873,58 @@ func (o Value) Type(ctx context.Context) attr.Type { } } +// GetListValue returns the value of the ListValue field in Value as +// a ListValue value. +// If the field is unknown or null, the boolean return value is false. +func (o *Value) GetListValue(ctx context.Context) (ListValue, bool) { + var e ListValue + if o.ListValue.IsNull() || o.ListValue.IsUnknown() { + return e, false + } + var v []ListValue + d := o.ListValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetListValue sets the value of the ListValue field in Value. +func (o *Value) SetListValue(ctx context.Context, v ListValue) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["list_value"] + o.ListValue = types.ListValueMust(t, vs) +} + +// GetStructValue returns the value of the StructValue field in Value as +// a Struct value. +// If the field is unknown or null, the boolean return value is false. +func (o *Value) GetStructValue(ctx context.Context) (Struct, bool) { + var e Struct + if o.StructValue.IsNull() || o.StructValue.IsUnknown() { + return e, false + } + var v []Struct + d := o.StructValue.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStructValue sets the value of the StructValue field in Value. +func (o *Value) SetStructValue(ctx context.Context, v Struct) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["struct_value"] + o.StructValue = types.ListValueMust(t, vs) +} + type VectorIndex struct { // The user who created the index. Creator types.String `tfsdk:"creator" tf:"optional"` @@ -2249,6 +3011,84 @@ func (o VectorIndex) Type(ctx context.Context) attr.Type { } } +// GetDeltaSyncIndexSpec returns the value of the DeltaSyncIndexSpec field in VectorIndex as +// a DeltaSyncVectorIndexSpecResponse value. +// If the field is unknown or null, the boolean return value is false. +func (o *VectorIndex) GetDeltaSyncIndexSpec(ctx context.Context) (DeltaSyncVectorIndexSpecResponse, bool) { + var e DeltaSyncVectorIndexSpecResponse + if o.DeltaSyncIndexSpec.IsNull() || o.DeltaSyncIndexSpec.IsUnknown() { + return e, false + } + var v []DeltaSyncVectorIndexSpecResponse + d := o.DeltaSyncIndexSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDeltaSyncIndexSpec sets the value of the DeltaSyncIndexSpec field in VectorIndex. +func (o *VectorIndex) SetDeltaSyncIndexSpec(ctx context.Context, v DeltaSyncVectorIndexSpecResponse) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delta_sync_index_spec"] + o.DeltaSyncIndexSpec = types.ListValueMust(t, vs) +} + +// GetDirectAccessIndexSpec returns the value of the DirectAccessIndexSpec field in VectorIndex as +// a DirectAccessVectorIndexSpec value. +// If the field is unknown or null, the boolean return value is false. +func (o *VectorIndex) GetDirectAccessIndexSpec(ctx context.Context) (DirectAccessVectorIndexSpec, bool) { + var e DirectAccessVectorIndexSpec + if o.DirectAccessIndexSpec.IsNull() || o.DirectAccessIndexSpec.IsUnknown() { + return e, false + } + var v []DirectAccessVectorIndexSpec + d := o.DirectAccessIndexSpec.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetDirectAccessIndexSpec sets the value of the DirectAccessIndexSpec field in VectorIndex. +func (o *VectorIndex) SetDirectAccessIndexSpec(ctx context.Context, v DirectAccessVectorIndexSpec) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["direct_access_index_spec"] + o.DirectAccessIndexSpec = types.ListValueMust(t, vs) +} + +// GetStatus returns the value of the Status field in VectorIndex as +// a VectorIndexStatus value. +// If the field is unknown or null, the boolean return value is false. +func (o *VectorIndex) GetStatus(ctx context.Context) (VectorIndexStatus, bool) { + var e VectorIndexStatus + if o.Status.IsNull() || o.Status.IsUnknown() { + return e, false + } + var v []VectorIndexStatus + d := o.Status.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetStatus sets the value of the Status field in VectorIndex. +func (o *VectorIndex) SetStatus(ctx context.Context, v VectorIndexStatus) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + o.Status = types.ListValueMust(t, vs) +} + type VectorIndexStatus struct { // Index API Url to be used to perform operations on the index IndexUrl types.String `tfsdk:"index_url" tf:"optional"` @@ -2302,28 +3142,3 @@ func (o VectorIndexStatus) Type(ctx context.Context) attr.Type { }, } } - -// Status of the delete operation. - -// Current state of the endpoint - -// Type of endpoint. - -// Pipeline execution mode. -// -// - `TRIGGERED`: If the pipeline uses the triggered execution mode, the system -// stops processing after successfully refreshing the source table in the -// pipeline once, ensuring the table is updated based on the data available when -// the update started. - `CONTINUOUS`: If the pipeline uses continuous -// execution, the pipeline processes new data as it arrives in the source table -// to keep vector index fresh. - -// Status of the upsert operation. - -// There are 2 types of Vector Search indexes: -// -// - `DELTA_SYNC`: An index that automatically syncs with a source Delta Table, -// automatically and incrementally updating the index as the underlying data in -// the Delta Table changes. - `DIRECT_ACCESS`: An index that supports direct -// read and write of vectors and metadata through our REST and SDK APIs. With -// this model, the user manages index updates. diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index e510b6ac47..b6fef9cd19 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -14,6 +14,7 @@ import ( "context" "reflect" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-framework/types/basetypes" @@ -290,6 +291,32 @@ func (o CreateRepoRequest) Type(ctx context.Context) attr.Type { } } +// GetSparseCheckout returns the value of the SparseCheckout field in CreateRepoRequest as +// a SparseCheckout value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRepoRequest) GetSparseCheckout(ctx context.Context) (SparseCheckout, bool) { + var e SparseCheckout + if o.SparseCheckout.IsNull() || o.SparseCheckout.IsUnknown() { + return e, false + } + var v []SparseCheckout + d := o.SparseCheckout.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparseCheckout sets the value of the SparseCheckout field in CreateRepoRequest. +func (o *CreateRepoRequest) SetSparseCheckout(ctx context.Context, v SparseCheckout) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sparse_checkout"] + o.SparseCheckout = types.ListValueMust(t, vs) +} + type CreateRepoResponse struct { // Branch that the Git folder (repo) is checked out to. Branch types.String `tfsdk:"branch" tf:"optional"` @@ -361,6 +388,32 @@ func (o CreateRepoResponse) Type(ctx context.Context) attr.Type { } } +// GetSparseCheckout returns the value of the SparseCheckout field in CreateRepoResponse as +// a SparseCheckout value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateRepoResponse) GetSparseCheckout(ctx context.Context) (SparseCheckout, bool) { + var e SparseCheckout + if o.SparseCheckout.IsNull() || o.SparseCheckout.IsUnknown() { + return e, false + } + var v []SparseCheckout + d := o.SparseCheckout.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparseCheckout sets the value of the SparseCheckout field in CreateRepoResponse. +func (o *CreateRepoResponse) SetSparseCheckout(ctx context.Context, v SparseCheckout) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sparse_checkout"] + o.SparseCheckout = types.ListValueMust(t, vs) +} + type CreateScope struct { // The metadata for the secret scope if the type is `AZURE_KEYVAULT` BackendAzureKeyvault types.List `tfsdk:"backend_azure_keyvault" tf:"optional,object"` @@ -421,6 +474,32 @@ func (o CreateScope) Type(ctx context.Context) attr.Type { } } +// GetBackendAzureKeyvault returns the value of the BackendAzureKeyvault field in CreateScope as +// a AzureKeyVaultSecretScopeMetadata value. +// If the field is unknown or null, the boolean return value is false. +func (o *CreateScope) GetBackendAzureKeyvault(ctx context.Context) (AzureKeyVaultSecretScopeMetadata, bool) { + var e AzureKeyVaultSecretScopeMetadata + if o.BackendAzureKeyvault.IsNull() || o.BackendAzureKeyvault.IsUnknown() { + return e, false + } + var v []AzureKeyVaultSecretScopeMetadata + d := o.BackendAzureKeyvault.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetBackendAzureKeyvault sets the value of the BackendAzureKeyvault field in CreateScope. +func (o *CreateScope) SetBackendAzureKeyvault(ctx context.Context, v AzureKeyVaultSecretScopeMetadata) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["backend_azure_keyvault"] + o.BackendAzureKeyvault = types.ListValueMust(t, vs) +} + type CreateScopeResponse struct { } @@ -1331,6 +1410,31 @@ func (o GetRepoPermissionLevelsResponse) Type(ctx context.Context) attr.Type { } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetRepoPermissionLevelsResponse as +// a slice of RepoPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetRepoPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]RepoPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []RepoPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetRepoPermissionLevelsResponse. +func (o *GetRepoPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []RepoPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get repo permissions type GetRepoPermissionsRequest struct { // The repo for which to get or manage permissions. @@ -1487,6 +1591,32 @@ func (o GetRepoResponse) Type(ctx context.Context) attr.Type { } } +// GetSparseCheckout returns the value of the SparseCheckout field in GetRepoResponse as +// a SparseCheckout value. +// If the field is unknown or null, the boolean return value is false. +func (o *GetRepoResponse) GetSparseCheckout(ctx context.Context) (SparseCheckout, bool) { + var e SparseCheckout + if o.SparseCheckout.IsNull() || o.SparseCheckout.IsUnknown() { + return e, false + } + var v []SparseCheckout + d := o.SparseCheckout.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparseCheckout sets the value of the SparseCheckout field in GetRepoResponse. +func (o *GetRepoResponse) SetSparseCheckout(ctx context.Context, v SparseCheckout) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sparse_checkout"] + o.SparseCheckout = types.ListValueMust(t, vs) +} + // Get a secret type GetSecretRequest struct { // The key to fetch secret for. @@ -1716,6 +1846,31 @@ func (o GetWorkspaceObjectPermissionLevelsResponse) Type(ctx context.Context) at } } +// GetPermissionLevels returns the value of the PermissionLevels field in GetWorkspaceObjectPermissionLevelsResponse as +// a slice of WorkspaceObjectPermissionsDescription values. +// If the field is unknown or null, the boolean return value is false. +func (o *GetWorkspaceObjectPermissionLevelsResponse) GetPermissionLevels(ctx context.Context) ([]WorkspaceObjectPermissionsDescription, bool) { + if o.PermissionLevels.IsNull() || o.PermissionLevels.IsUnknown() { + return nil, false + } + var v []WorkspaceObjectPermissionsDescription + d := o.PermissionLevels.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPermissionLevels sets the value of the PermissionLevels field in GetWorkspaceObjectPermissionLevelsResponse. +func (o *GetWorkspaceObjectPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v []WorkspaceObjectPermissionsDescription) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + o.PermissionLevels = types.ListValueMust(t, vs) +} + // Get workspace object permissions type GetWorkspaceObjectPermissionsRequest struct { // The workspace object for which to get or manage permissions. @@ -1966,6 +2121,31 @@ func (o ListAclsResponse) Type(ctx context.Context) attr.Type { } } +// GetItems returns the value of the Items field in ListAclsResponse as +// a slice of AclItem values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListAclsResponse) GetItems(ctx context.Context) ([]AclItem, bool) { + if o.Items.IsNull() || o.Items.IsUnknown() { + return nil, false + } + var v []AclItem + d := o.Items.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetItems sets the value of the Items field in ListAclsResponse. +func (o *ListAclsResponse) SetItems(ctx context.Context, v []AclItem) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["items"] + o.Items = types.ListValueMust(t, vs) +} + type ListCredentialsResponse struct { // List of credentials. Credentials types.List `tfsdk:"credentials" tf:"optional"` @@ -2012,6 +2192,31 @@ func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { } } +// GetCredentials returns the value of the Credentials field in ListCredentialsResponse as +// a slice of CredentialInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListCredentialsResponse) GetCredentials(ctx context.Context) ([]CredentialInfo, bool) { + if o.Credentials.IsNull() || o.Credentials.IsUnknown() { + return nil, false + } + var v []CredentialInfo + d := o.Credentials.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetCredentials sets the value of the Credentials field in ListCredentialsResponse. +func (o *ListCredentialsResponse) SetCredentials(ctx context.Context, v []CredentialInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credentials"] + o.Credentials = types.ListValueMust(t, vs) +} + // Get repos type ListReposRequest struct { // Token used to get the next page of results. If not specified, returns the @@ -2114,6 +2319,31 @@ func (o ListReposResponse) Type(ctx context.Context) attr.Type { } } +// GetRepos returns the value of the Repos field in ListReposResponse as +// a slice of RepoInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListReposResponse) GetRepos(ctx context.Context) ([]RepoInfo, bool) { + if o.Repos.IsNull() || o.Repos.IsUnknown() { + return nil, false + } + var v []RepoInfo + d := o.Repos.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetRepos sets the value of the Repos field in ListReposResponse. +func (o *ListReposResponse) SetRepos(ctx context.Context, v []RepoInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repos"] + o.Repos = types.ListValueMust(t, vs) +} + type ListResponse struct { // List of objects. Objects types.List `tfsdk:"objects" tf:"optional"` @@ -2160,6 +2390,31 @@ func (o ListResponse) Type(ctx context.Context) attr.Type { } } +// GetObjects returns the value of the Objects field in ListResponse as +// a slice of ObjectInfo values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListResponse) GetObjects(ctx context.Context) ([]ObjectInfo, bool) { + if o.Objects.IsNull() || o.Objects.IsUnknown() { + return nil, false + } + var v []ObjectInfo + d := o.Objects.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetObjects sets the value of the Objects field in ListResponse. +func (o *ListResponse) SetObjects(ctx context.Context, v []ObjectInfo) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["objects"] + o.Objects = types.ListValueMust(t, vs) +} + type ListScopesResponse struct { // The available secret scopes. Scopes types.List `tfsdk:"scopes" tf:"optional"` @@ -2206,6 +2461,31 @@ func (o ListScopesResponse) Type(ctx context.Context) attr.Type { } } +// GetScopes returns the value of the Scopes field in ListScopesResponse as +// a slice of SecretScope values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListScopesResponse) GetScopes(ctx context.Context) ([]SecretScope, bool) { + if o.Scopes.IsNull() || o.Scopes.IsUnknown() { + return nil, false + } + var v []SecretScope + d := o.Scopes.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetScopes sets the value of the Scopes field in ListScopesResponse. +func (o *ListScopesResponse) SetScopes(ctx context.Context, v []SecretScope) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + o.Scopes = types.ListValueMust(t, vs) +} + // List secret keys type ListSecretsRequest struct { // The name of the scope to list secrets within. @@ -2295,6 +2575,31 @@ func (o ListSecretsResponse) Type(ctx context.Context) attr.Type { } } +// GetSecrets returns the value of the Secrets field in ListSecretsResponse as +// a slice of SecretMetadata values. +// If the field is unknown or null, the boolean return value is false. +func (o *ListSecretsResponse) GetSecrets(ctx context.Context) ([]SecretMetadata, bool) { + if o.Secrets.IsNull() || o.Secrets.IsUnknown() { + return nil, false + } + var v []SecretMetadata + d := o.Secrets.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetSecrets sets the value of the Secrets field in ListSecretsResponse. +func (o *ListSecretsResponse) SetSecrets(ctx context.Context, v []SecretMetadata) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["secrets"] + o.Secrets = types.ListValueMust(t, vs) +} + // List contents type ListWorkspaceRequest struct { // UTC timestamp in milliseconds @@ -2790,6 +3095,31 @@ func (o RepoAccessControlResponse) Type(ctx context.Context) attr.Type { } } +// GetAllPermissions returns the value of the AllPermissions field in RepoAccessControlResponse as +// a slice of RepoPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepoAccessControlResponse) GetAllPermissions(ctx context.Context) ([]RepoPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []RepoPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in RepoAccessControlResponse. +func (o *RepoAccessControlResponse) SetAllPermissions(ctx context.Context, v []RepoPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + // Git folder (repo) information. type RepoInfo struct { // Name of the current git branch of the git folder (repo). @@ -2861,6 +3191,32 @@ func (o RepoInfo) Type(ctx context.Context) attr.Type { } } +// GetSparseCheckout returns the value of the SparseCheckout field in RepoInfo as +// a SparseCheckout value. +// If the field is unknown or null, the boolean return value is false. +func (o *RepoInfo) GetSparseCheckout(ctx context.Context) (SparseCheckout, bool) { + var e SparseCheckout + if o.SparseCheckout.IsNull() || o.SparseCheckout.IsUnknown() { + return e, false + } + var v []SparseCheckout + d := o.SparseCheckout.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparseCheckout sets the value of the SparseCheckout field in RepoInfo. +func (o *RepoInfo) SetSparseCheckout(ctx context.Context, v SparseCheckout) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sparse_checkout"] + o.SparseCheckout = types.ListValueMust(t, vs) +} + type RepoPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -2914,6 +3270,31 @@ func (o RepoPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in RepoPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepoPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in RepoPermission. +func (o *RepoPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type RepoPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -2967,6 +3348,31 @@ func (o RepoPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in RepoPermissions as +// a slice of RepoAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepoPermissions) GetAccessControlList(ctx context.Context) ([]RepoAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []RepoAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in RepoPermissions. +func (o *RepoPermissions) SetAccessControlList(ctx context.Context, v []RepoAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type RepoPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -3061,6 +3467,31 @@ func (o RepoPermissionsRequest) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in RepoPermissionsRequest as +// a slice of RepoAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *RepoPermissionsRequest) GetAccessControlList(ctx context.Context) ([]RepoAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []RepoAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in RepoPermissionsRequest. +func (o *RepoPermissionsRequest) SetAccessControlList(ctx context.Context, v []RepoAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type SecretMetadata struct { // A unique name to identify the secret. Key types.String `tfsdk:"key" tf:"optional"` @@ -3161,6 +3592,32 @@ func (o SecretScope) Type(ctx context.Context) attr.Type { } } +// GetKeyvaultMetadata returns the value of the KeyvaultMetadata field in SecretScope as +// a AzureKeyVaultSecretScopeMetadata value. +// If the field is unknown or null, the boolean return value is false. +func (o *SecretScope) GetKeyvaultMetadata(ctx context.Context) (AzureKeyVaultSecretScopeMetadata, bool) { + var e AzureKeyVaultSecretScopeMetadata + if o.KeyvaultMetadata.IsNull() || o.KeyvaultMetadata.IsUnknown() { + return e, false + } + var v []AzureKeyVaultSecretScopeMetadata + d := o.KeyvaultMetadata.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetKeyvaultMetadata sets the value of the KeyvaultMetadata field in SecretScope. +func (o *SecretScope) SetKeyvaultMetadata(ctx context.Context, v AzureKeyVaultSecretScopeMetadata) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["keyvault_metadata"] + o.KeyvaultMetadata = types.ListValueMust(t, vs) +} + // Sparse checkout configuration, it contains options like cone patterns. type SparseCheckout struct { // List of sparse checkout cone patterns, see [cone mode handling] for @@ -3211,6 +3668,31 @@ func (o SparseCheckout) Type(ctx context.Context) attr.Type { } } +// GetPatterns returns the value of the Patterns field in SparseCheckout as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SparseCheckout) GetPatterns(ctx context.Context) ([]types.String, bool) { + if o.Patterns.IsNull() || o.Patterns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Patterns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPatterns sets the value of the Patterns field in SparseCheckout. +func (o *SparseCheckout) SetPatterns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["patterns"] + o.Patterns = types.ListValueMust(t, vs) +} + // Sparse checkout configuration, it contains options like cone patterns. type SparseCheckoutUpdate struct { // List of sparse checkout cone patterns, see [cone mode handling] for @@ -3261,6 +3743,31 @@ func (o SparseCheckoutUpdate) Type(ctx context.Context) attr.Type { } } +// GetPatterns returns the value of the Patterns field in SparseCheckoutUpdate as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *SparseCheckoutUpdate) GetPatterns(ctx context.Context) ([]types.String, bool) { + if o.Patterns.IsNull() || o.Patterns.IsUnknown() { + return nil, false + } + var v []types.String + d := o.Patterns.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetPatterns sets the value of the Patterns field in SparseCheckoutUpdate. +func (o *SparseCheckoutUpdate) SetPatterns(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["patterns"] + o.Patterns = types.ListValueMust(t, vs) +} + type UpdateCredentialsRequest struct { // The ID for the corresponding credential to access. CredentialId types.Int64 `tfsdk:"-"` @@ -3426,6 +3933,32 @@ func (o UpdateRepoRequest) Type(ctx context.Context) attr.Type { } } +// GetSparseCheckout returns the value of the SparseCheckout field in UpdateRepoRequest as +// a SparseCheckoutUpdate value. +// If the field is unknown or null, the boolean return value is false. +func (o *UpdateRepoRequest) GetSparseCheckout(ctx context.Context) (SparseCheckoutUpdate, bool) { + var e SparseCheckoutUpdate + if o.SparseCheckout.IsNull() || o.SparseCheckout.IsUnknown() { + return e, false + } + var v []SparseCheckoutUpdate + d := o.SparseCheckout.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + if len(v) == 0 { + return e, false + } + return v[0], true +} + +// SetSparseCheckout sets the value of the SparseCheckout field in UpdateRepoRequest. +func (o *UpdateRepoRequest) SetSparseCheckout(ctx context.Context, v SparseCheckoutUpdate) { + vs := []attr.Value{v.ToObjectValue(ctx)} + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sparse_checkout"] + o.SparseCheckout = types.ListValueMust(t, vs) +} + type UpdateRepoResponse struct { } @@ -3578,6 +4111,31 @@ func (o WorkspaceObjectAccessControlResponse) Type(ctx context.Context) attr.Typ } } +// GetAllPermissions returns the value of the AllPermissions field in WorkspaceObjectAccessControlResponse as +// a slice of WorkspaceObjectPermission values. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkspaceObjectAccessControlResponse) GetAllPermissions(ctx context.Context) ([]WorkspaceObjectPermission, bool) { + if o.AllPermissions.IsNull() || o.AllPermissions.IsUnknown() { + return nil, false + } + var v []WorkspaceObjectPermission + d := o.AllPermissions.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAllPermissions sets the value of the AllPermissions field in WorkspaceObjectAccessControlResponse. +func (o *WorkspaceObjectAccessControlResponse) SetAllPermissions(ctx context.Context, v []WorkspaceObjectPermission) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + o.AllPermissions = types.ListValueMust(t, vs) +} + type WorkspaceObjectPermission struct { Inherited types.Bool `tfsdk:"inherited" tf:"optional"` @@ -3631,6 +4189,31 @@ func (o WorkspaceObjectPermission) Type(ctx context.Context) attr.Type { } } +// GetInheritedFromObject returns the value of the InheritedFromObject field in WorkspaceObjectPermission as +// a slice of types.String values. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkspaceObjectPermission) GetInheritedFromObject(ctx context.Context) ([]types.String, bool) { + if o.InheritedFromObject.IsNull() || o.InheritedFromObject.IsUnknown() { + return nil, false + } + var v []types.String + d := o.InheritedFromObject.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetInheritedFromObject sets the value of the InheritedFromObject field in WorkspaceObjectPermission. +func (o *WorkspaceObjectPermission) SetInheritedFromObject(ctx context.Context, v []types.String) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + o.InheritedFromObject = types.ListValueMust(t, vs) +} + type WorkspaceObjectPermissions struct { AccessControlList types.List `tfsdk:"access_control_list" tf:"optional"` @@ -3684,6 +4267,31 @@ func (o WorkspaceObjectPermissions) Type(ctx context.Context) attr.Type { } } +// GetAccessControlList returns the value of the AccessControlList field in WorkspaceObjectPermissions as +// a slice of WorkspaceObjectAccessControlResponse values. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkspaceObjectPermissions) GetAccessControlList(ctx context.Context) ([]WorkspaceObjectAccessControlResponse, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []WorkspaceObjectAccessControlResponse + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} + +// SetAccessControlList sets the value of the AccessControlList field in WorkspaceObjectPermissions. +func (o *WorkspaceObjectPermissions) SetAccessControlList(ctx context.Context, v []WorkspaceObjectAccessControlResponse) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} + type WorkspaceObjectPermissionsDescription struct { Description types.String `tfsdk:"description" tf:"optional"` // Permission level @@ -3782,28 +4390,27 @@ func (o WorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { } } -// This specifies the format of the file to be imported. -// -// The value is case sensitive. -// -// - `AUTO`: The item is imported depending on an analysis of the item's -// extension and the header content provided in the request. If the item is -// imported as a notebook, then the item's extension is automatically removed. - -// `SOURCE`: The notebook or directory is imported as source code. - `HTML`: The -// notebook is imported as an HTML file. - `JUPYTER`: The notebook is imported -// as a Jupyter/IPython Notebook file. - `DBC`: The notebook is imported in -// Databricks archive format. Required for directories. - `R_MARKDOWN`: The -// notebook is imported from R Markdown format. - -// The language of the object. This value is set only if the object type is -// `NOTEBOOK`. - -// The type of the object in workspace. -// -// - `NOTEBOOK`: document that contains runnable code, visualizations, and -// explanatory text. - `DIRECTORY`: directory - `LIBRARY`: library - `FILE`: -// file - `REPO`: repository - `DASHBOARD`: Lakeview dashboard - -// Permission level +// GetAccessControlList returns the value of the AccessControlList field in WorkspaceObjectPermissionsRequest as +// a slice of WorkspaceObjectAccessControlRequest values. +// If the field is unknown or null, the boolean return value is false. +func (o *WorkspaceObjectPermissionsRequest) GetAccessControlList(ctx context.Context) ([]WorkspaceObjectAccessControlRequest, bool) { + if o.AccessControlList.IsNull() || o.AccessControlList.IsUnknown() { + return nil, false + } + var v []WorkspaceObjectAccessControlRequest + d := o.AccessControlList.ElementsAs(ctx, &v, true) + if d.HasError() { + panic(pluginfwcommon.DiagToString(d)) + } + return v, true +} -// Permission level +// SetAccessControlList sets the value of the AccessControlList field in WorkspaceObjectPermissionsRequest. +func (o *WorkspaceObjectPermissionsRequest) SetAccessControlList(ctx context.Context, v []WorkspaceObjectAccessControlRequest) { + vs := make([]attr.Value, 0, len(v)) + for _, e := range v { + vs = append(vs, e.ToObjectValue(ctx)) + } + t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + o.AccessControlList = types.ListValueMust(t, vs) +} From a9f12b6bb7f9c04533061b7a929bb42d9ac89592 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 9 Dec 2024 10:42:47 +0100 Subject: [PATCH 54/91] bugfix --- .codegen/model.go.tmpl | 3 + internal/service/apps_tf/model.go | 8 ++ internal/service/billing_tf/model.go | 12 +++ internal/service/catalog_tf/model.go | 73 ++++++++++++++ internal/service/compute_tf/model.go | 93 +++++++++++++++++ internal/service/dashboards_tf/model.go | 4 + internal/service/files_tf/model.go | 2 + internal/service/iam_tf/model.go | 40 ++++++++ internal/service/jobs_tf/model.go | 117 ++++++++++++++++++++++ internal/service/marketplace_tf/model.go | 36 +++++++ internal/service/ml_tf/model.go | 53 ++++++++++ internal/service/oauth2_tf/model.go | 11 ++ internal/service/pipelines_tf/model.go | 42 ++++++++ internal/service/provisioning_tf/model.go | 15 +++ internal/service/serving_tf/model.go | 44 ++++++++ internal/service/settings_tf/model.go | 28 ++++++ internal/service/sharing_tf/model.go | 15 +++ internal/service/sql_tf/model.go | 53 ++++++++++ internal/service/vectorsearch_tf/model.go | 19 ++++ internal/service/workspace_tf/model.go | 18 ++++ 20 files changed, 686 insertions(+) diff --git a/.codegen/model.go.tmpl b/.codegen/model.go.tmpl index 54f7b5cf10..55145cbc5e 100644 --- a/.codegen/model.go.tmpl +++ b/.codegen/model.go.tmpl @@ -159,6 +159,9 @@ func (o *{{ $parent.PascalName}}) Set{{.PascalName}}(ctx context.Context, v {{te } {{- end}} t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["{{template "tfsdk-name" (dict "field" .)}}"] + {{- if or .Entity.ArrayValue .Entity.MapValue }} + t = t.(attr.TypeWithElementType).ElementType() + {{- end }} o.{{.PascalName}}{{if eq .PascalName "Type"}}_{{end}} = types.{{if .Entity.MapValue}}Map{{else}}List{{end}}ValueMust(t, vs) } {{end}} diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index c1777ed1d5..804d6c4841 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -269,6 +269,7 @@ func (o *App) SetResources(ctx context.Context, v []AppResource) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["resources"] + t = t.(attr.TypeWithElementType).ElementType() o.Resources = types.ListValueMust(t, vs) } @@ -410,6 +411,7 @@ func (o *AppAccessControlResponse) SetAllPermissions(ctx context.Context, v []Ap vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -712,6 +714,7 @@ func (o *AppPermission) SetInheritedFromObject(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -790,6 +793,7 @@ func (o *AppPermissions) SetAccessControlList(ctx context.Context, v []AppAccess vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -909,6 +913,7 @@ func (o *AppPermissionsRequest) SetAccessControlList(ctx context.Context, v []Ap vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -1724,6 +1729,7 @@ func (o *GetAppPermissionLevelsResponse) SetPermissionLevels(ctx context.Context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -1937,6 +1943,7 @@ func (o *ListAppDeploymentsResponse) SetAppDeployments(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app_deployments"] + t = t.(attr.TypeWithElementType).ElementType() o.AppDeployments = types.ListValueMust(t, vs) } @@ -2059,6 +2066,7 @@ func (o *ListAppsResponse) SetApps(ctx context.Context, v []App) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + t = t.(attr.TypeWithElementType).ElementType() o.Apps = types.ListValueMust(t, vs) } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 6c5decf04b..f8297f5cc9 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -162,6 +162,7 @@ func (o *AlertConfiguration) SetActionConfigurations(ctx context.Context, v []Ac vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["action_configurations"] + t = t.(attr.TypeWithElementType).ElementType() o.ActionConfigurations = types.ListValueMust(t, vs) } @@ -264,6 +265,7 @@ func (o *BudgetConfiguration) SetAlertConfigurations(ctx context.Context, v []Al vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_configurations"] + t = t.(attr.TypeWithElementType).ElementType() o.AlertConfigurations = types.ListValueMust(t, vs) } @@ -370,6 +372,7 @@ func (o *BudgetConfigurationFilter) SetTags(ctx context.Context, v []BudgetConfi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -470,6 +473,7 @@ func (o *BudgetConfigurationFilterClause) SetValues(ctx context.Context, v []typ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -619,6 +623,7 @@ func (o *BudgetConfigurationFilterWorkspaceIdClause) SetValues(ctx context.Conte vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -800,6 +805,7 @@ func (o *CreateBudgetConfigurationBudget) SetAlertConfigurations(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_configurations"] + t = t.(attr.TypeWithElementType).ElementType() o.AlertConfigurations = types.ListValueMust(t, vs) } @@ -963,6 +969,7 @@ func (o *CreateBudgetConfigurationBudgetAlertConfigurations) SetActionConfigurat vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["action_configurations"] + t = t.(attr.TypeWithElementType).ElementType() o.ActionConfigurations = types.ListValueMust(t, vs) } @@ -1261,6 +1268,7 @@ func (o *CreateLogDeliveryConfigurationParams) SetWorkspaceIdsFilter(ctx context vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_ids_filter"] + t = t.(attr.TypeWithElementType).ElementType() o.WorkspaceIdsFilter = types.ListValueMust(t, vs) } @@ -1809,6 +1817,7 @@ func (o *ListBudgetConfigurationsResponse) SetBudgets(ctx context.Context, v []B vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["budgets"] + t = t.(attr.TypeWithElementType).ElementType() o.Budgets = types.ListValueMust(t, vs) } @@ -2065,6 +2074,7 @@ func (o *LogDeliveryConfiguration) SetWorkspaceIdsFilter(ctx context.Context, v vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_ids_filter"] + t = t.(attr.TypeWithElementType).ElementType() o.WorkspaceIdsFilter = types.ListValueMust(t, vs) } @@ -2261,6 +2271,7 @@ func (o *UpdateBudgetConfigurationBudget) SetAlertConfigurations(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alert_configurations"] + t = t.(attr.TypeWithElementType).ElementType() o.AlertConfigurations = types.ListValueMust(t, vs) } @@ -2698,5 +2709,6 @@ func (o *WrappedLogDeliveryConfigurations) SetLogDeliveryConfigurations(ctx cont vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["log_delivery_configurations"] + t = t.(attr.TypeWithElementType).ElementType() o.LogDeliveryConfigurations = types.ListValueMust(t, vs) } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 4b36a1f2da..ab5d2f4a3c 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -772,6 +772,7 @@ func (o *ArtifactAllowlistInfo) SetArtifactMatchers(ctx context.Context, v []Art vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["artifact_matchers"] + t = t.(attr.TypeWithElementType).ElementType() o.ArtifactMatchers = types.ListValueMust(t, vs) } @@ -1662,6 +1663,7 @@ func (o *CatalogInfo) SetOptions(ctx context.Context, v map[string]types.String) vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + t = t.(attr.TypeWithElementType).ElementType() o.Options = types.MapValueMust(t, vs) } @@ -1687,6 +1689,7 @@ func (o *CatalogInfo) SetProperties(ctx context.Context, v map[string]types.Stri vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -1957,6 +1960,7 @@ func (o *ColumnMask) SetUsingColumnNames(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["using_column_names"] + t = t.(attr.TypeWithElementType).ElementType() o.UsingColumnNames = types.ListValueMust(t, vs) } @@ -2107,6 +2111,7 @@ func (o *ConnectionInfo) SetOptions(ctx context.Context, v map[string]types.Stri vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + t = t.(attr.TypeWithElementType).ElementType() o.Options = types.MapValueMust(t, vs) } @@ -2132,6 +2137,7 @@ func (o *ConnectionInfo) SetProperties(ctx context.Context, v map[string]types.S vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -2348,6 +2354,7 @@ func (o *CreateCatalog) SetOptions(ctx context.Context, v map[string]types.Strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + t = t.(attr.TypeWithElementType).ElementType() o.Options = types.MapValueMust(t, vs) } @@ -2373,6 +2380,7 @@ func (o *CreateCatalog) SetProperties(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -2468,6 +2476,7 @@ func (o *CreateConnection) SetOptions(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + t = t.(attr.TypeWithElementType).ElementType() o.Options = types.MapValueMust(t, vs) } @@ -2493,6 +2502,7 @@ func (o *CreateConnection) SetProperties(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -3340,6 +3350,7 @@ func (o *CreateMonitor) SetCustomMetrics(ctx context.Context, v []MonitorMetric) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_metrics"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomMetrics = types.ListValueMust(t, vs) } @@ -3469,6 +3480,7 @@ func (o *CreateMonitor) SetSlicingExprs(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slicing_exprs"] + t = t.(attr.TypeWithElementType).ElementType() o.SlicingExprs = types.ListValueMust(t, vs) } @@ -3776,6 +3788,7 @@ func (o *CreateSchema) SetProperties(ctx context.Context, v map[string]types.Str vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -4453,6 +4466,7 @@ func (o *CurrentWorkspaceBindings) SetWorkspaces(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspaces"] + t = t.(attr.TypeWithElementType).ElementType() o.Workspaces = types.ListValueMust(t, vs) } @@ -5602,6 +5616,7 @@ func (o *DeltaRuntimePropertiesKvPairs) SetDeltaRuntimeProperties(ctx context.Co vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delta_runtime_properties"] + t = t.(attr.TypeWithElementType).ElementType() o.DeltaRuntimeProperties = types.MapValueMust(t, vs) } @@ -5781,6 +5796,7 @@ func (o *DependencyList) SetDependencies(ctx context.Context, v []Dependency) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dependencies"] + t = t.(attr.TypeWithElementType).ElementType() o.Dependencies = types.ListValueMust(t, vs) } @@ -5936,6 +5952,7 @@ func (o *EffectivePermissionsList) SetPrivilegeAssignments(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privilege_assignments"] + t = t.(attr.TypeWithElementType).ElementType() o.PrivilegeAssignments = types.ListValueMust(t, vs) } @@ -6119,6 +6136,7 @@ func (o *EffectivePrivilegeAssignment) SetPrivileges(ctx context.Context, v []Ef vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privileges"] + t = t.(attr.TypeWithElementType).ElementType() o.Privileges = types.ListValueMust(t, vs) } @@ -6598,6 +6616,7 @@ func (o *ForeignKeyConstraint) SetChildColumns(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["child_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.ChildColumns = types.ListValueMust(t, vs) } @@ -6623,6 +6642,7 @@ func (o *ForeignKeyConstraint) SetParentColumns(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parent_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.ParentColumns = types.ListValueMust(t, vs) } @@ -7078,6 +7098,7 @@ func (o *FunctionParameterInfos) SetParameters(ctx context.Context, v []Function vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -7246,6 +7267,7 @@ func (o *GenerateTemporaryServiceCredentialAzureOptions) SetResources(ctx contex vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["resources"] + t = t.(attr.TypeWithElementType).ElementType() o.Resources = types.ListValueMust(t, vs) } @@ -9045,6 +9067,7 @@ func (o *ListAccountMetastoreAssignmentsResponse) SetWorkspaceIds(ctx context.Co vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["workspace_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.WorkspaceIds = types.ListValueMust(t, vs) } @@ -9159,6 +9182,7 @@ func (o *ListAccountStorageCredentialsResponse) SetStorageCredentials(ctx contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["storage_credentials"] + t = t.(attr.TypeWithElementType).ElementType() o.StorageCredentials = types.ListValueMust(t, vs) } @@ -9296,6 +9320,7 @@ func (o *ListCatalogsResponse) SetCatalogs(ctx context.Context, v []CatalogInfo) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["catalogs"] + t = t.(attr.TypeWithElementType).ElementType() o.Catalogs = types.ListValueMust(t, vs) } @@ -9425,6 +9450,7 @@ func (o *ListConnectionsResponse) SetConnections(ctx context.Context, v []Connec vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["connections"] + t = t.(attr.TypeWithElementType).ElementType() o.Connections = types.ListValueMust(t, vs) } @@ -9556,6 +9582,7 @@ func (o *ListCredentialsResponse) SetCredentials(ctx context.Context, v []Creden vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credentials"] + t = t.(attr.TypeWithElementType).ElementType() o.Credentials = types.ListValueMust(t, vs) } @@ -9690,6 +9717,7 @@ func (o *ListExternalLocationsResponse) SetExternalLocations(ctx context.Context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_locations"] + t = t.(attr.TypeWithElementType).ElementType() o.ExternalLocations = types.ListValueMust(t, vs) } @@ -9832,6 +9860,7 @@ func (o *ListFunctionsResponse) SetFunctions(ctx context.Context, v []FunctionIn vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["functions"] + t = t.(attr.TypeWithElementType).ElementType() o.Functions = types.ListValueMust(t, vs) } @@ -9903,6 +9932,7 @@ func (o *ListMetastoresResponse) SetMetastores(ctx context.Context, v []Metastor vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metastores"] + t = t.(attr.TypeWithElementType).ElementType() o.Metastores = types.ListValueMust(t, vs) } @@ -10042,6 +10072,7 @@ func (o *ListModelVersionsResponse) SetModelVersions(ctx context.Context, v []Mo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.ModelVersions = types.ListValueMust(t, vs) } @@ -10166,6 +10197,7 @@ func (o *ListQuotasResponse) SetQuotas(ctx context.Context, v []QuotaInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["quotas"] + t = t.(attr.TypeWithElementType).ElementType() o.Quotas = types.ListValueMust(t, vs) } @@ -10363,6 +10395,7 @@ func (o *ListRegisteredModelsResponse) SetRegisteredModels(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_models"] + t = t.(attr.TypeWithElementType).ElementType() o.RegisteredModels = types.ListValueMust(t, vs) } @@ -10501,6 +10534,7 @@ func (o *ListSchemasResponse) SetSchemas(ctx context.Context, v []SchemaInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -10630,6 +10664,7 @@ func (o *ListStorageCredentialsResponse) SetStorageCredentials(ctx context.Conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["storage_credentials"] + t = t.(attr.TypeWithElementType).ElementType() o.StorageCredentials = types.ListValueMust(t, vs) } @@ -10834,6 +10869,7 @@ func (o *ListSystemSchemasResponse) SetSchemas(ctx context.Context, v []SystemSc vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -10911,6 +10947,7 @@ func (o *ListTableSummariesResponse) SetTables(ctx context.Context, v []TableSum vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tables"] + t = t.(attr.TypeWithElementType).ElementType() o.Tables = types.ListValueMust(t, vs) } @@ -11074,6 +11111,7 @@ func (o *ListTablesResponse) SetTables(ctx context.Context, v []TableInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tables"] + t = t.(attr.TypeWithElementType).ElementType() o.Tables = types.ListValueMust(t, vs) } @@ -11223,6 +11261,7 @@ func (o *ListVolumesResponseContent) SetVolumes(ctx context.Context, v []VolumeI vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["volumes"] + t = t.(attr.TypeWithElementType).ElementType() o.Volumes = types.ListValueMust(t, vs) } @@ -11549,6 +11588,7 @@ func (o *ModelVersionInfo) SetAliases(ctx context.Context, v []RegisteredModelAl vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aliases"] + t = t.(attr.TypeWithElementType).ElementType() o.Aliases = types.ListValueMust(t, vs) } @@ -11742,6 +11782,7 @@ func (o *MonitorDestination) SetEmailAddresses(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.EmailAddresses = types.ListValueMust(t, vs) } @@ -11851,6 +11892,7 @@ func (o *MonitorInferenceLog) SetGranularities(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["granularities"] + t = t.(attr.TypeWithElementType).ElementType() o.Granularities = types.ListValueMust(t, vs) } @@ -12024,6 +12066,7 @@ func (o *MonitorInfo) SetCustomMetrics(ctx context.Context, v []MonitorMetric) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_metrics"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomMetrics = types.ListValueMust(t, vs) } @@ -12153,6 +12196,7 @@ func (o *MonitorInfo) SetSlicingExprs(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slicing_exprs"] + t = t.(attr.TypeWithElementType).ElementType() o.SlicingExprs = types.ListValueMust(t, vs) } @@ -12306,6 +12350,7 @@ func (o *MonitorMetric) SetInputColumns(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.InputColumns = types.ListValueMust(t, vs) } @@ -12548,6 +12593,7 @@ func (o *MonitorRefreshListResponse) SetRefreshes(ctx context.Context, v []Monit vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["refreshes"] + t = t.(attr.TypeWithElementType).ElementType() o.Refreshes = types.ListValueMust(t, vs) } @@ -12667,6 +12713,7 @@ func (o *MonitorTimeSeries) SetGranularities(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["granularities"] + t = t.(attr.TypeWithElementType).ElementType() o.Granularities = types.ListValueMust(t, vs) } @@ -12941,6 +12988,7 @@ func (o *OnlineTableSpec) SetPrimaryKeyColumns(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_key_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.PrimaryKeyColumns = types.ListValueMust(t, vs) } @@ -13332,6 +13380,7 @@ func (o *PermissionsChange) SetAdd(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["add"] + t = t.(attr.TypeWithElementType).ElementType() o.Add = types.ListValueMust(t, vs) } @@ -13357,6 +13406,7 @@ func (o *PermissionsChange) SetRemove(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["remove"] + t = t.(attr.TypeWithElementType).ElementType() o.Remove = types.ListValueMust(t, vs) } @@ -13428,6 +13478,7 @@ func (o *PermissionsList) SetPrivilegeAssignments(ctx context.Context, v []Privi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privilege_assignments"] + t = t.(attr.TypeWithElementType).ElementType() o.PrivilegeAssignments = types.ListValueMust(t, vs) } @@ -13564,6 +13615,7 @@ func (o *PrimaryKeyConstraint) SetChildColumns(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["child_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.ChildColumns = types.ListValueMust(t, vs) } @@ -13639,6 +13691,7 @@ func (o *PrivilegeAssignment) SetPrivileges(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privileges"] + t = t.(attr.TypeWithElementType).ElementType() o.Privileges = types.ListValueMust(t, vs) } @@ -14187,6 +14240,7 @@ func (o *RegisteredModelInfo) SetAliases(ctx context.Context, v []RegisteredMode vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["aliases"] + t = t.(attr.TypeWithElementType).ElementType() o.Aliases = types.ListValueMust(t, vs) } @@ -14401,6 +14455,7 @@ func (o *SchemaInfo) SetProperties(ctx context.Context, v map[string]types.Strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -14476,6 +14531,7 @@ func (o *SetArtifactAllowlist) SetArtifactMatchers(ctx context.Context, v []Arti vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["artifact_matchers"] + t = t.(attr.TypeWithElementType).ElementType() o.ArtifactMatchers = types.ListValueMust(t, vs) } @@ -15333,6 +15389,7 @@ func (o *TableInfo) SetColumns(ctx context.Context, v []ColumnInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + t = t.(attr.TypeWithElementType).ElementType() o.Columns = types.ListValueMust(t, vs) } @@ -15436,6 +15493,7 @@ func (o *TableInfo) SetProperties(ctx context.Context, v map[string]types.String vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -15487,6 +15545,7 @@ func (o *TableInfo) SetTableConstraints(ctx context.Context, v []TableConstraint vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_constraints"] + t = t.(attr.TypeWithElementType).ElementType() o.TableConstraints = types.ListValueMust(t, vs) } @@ -15590,6 +15649,7 @@ func (o *TableRowFilter) SetInputColumnNames(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["input_column_names"] + t = t.(attr.TypeWithElementType).ElementType() o.InputColumnNames = types.ListValueMust(t, vs) } @@ -16050,6 +16110,7 @@ func (o *UpdateCatalog) SetProperties(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -16133,6 +16194,7 @@ func (o *UpdateConnection) SetOptions(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["options"] + t = t.(attr.TypeWithElementType).ElementType() o.Options = types.MapValueMust(t, vs) } @@ -16798,6 +16860,7 @@ func (o *UpdateMonitor) SetCustomMetrics(ctx context.Context, v []MonitorMetric) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_metrics"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomMetrics = types.ListValueMust(t, vs) } @@ -16927,6 +16990,7 @@ func (o *UpdateMonitor) SetSlicingExprs(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["slicing_exprs"] + t = t.(attr.TypeWithElementType).ElementType() o.SlicingExprs = types.ListValueMust(t, vs) } @@ -17058,6 +17122,7 @@ func (o *UpdatePermissions) SetChanges(ctx context.Context, v []PermissionsChang vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["changes"] + t = t.(attr.TypeWithElementType).ElementType() o.Changes = types.ListValueMust(t, vs) } @@ -17240,6 +17305,7 @@ func (o *UpdateSchema) SetProperties(ctx context.Context, v map[string]types.Str vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -17661,6 +17727,7 @@ func (o *UpdateWorkspaceBindings) SetAssignWorkspaces(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assign_workspaces"] + t = t.(attr.TypeWithElementType).ElementType() o.AssignWorkspaces = types.ListValueMust(t, vs) } @@ -17686,6 +17753,7 @@ func (o *UpdateWorkspaceBindings) SetUnassignWorkspaces(ctx context.Context, v [ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["unassign_workspaces"] + t = t.(attr.TypeWithElementType).ElementType() o.UnassignWorkspaces = types.ListValueMust(t, vs) } @@ -17772,6 +17840,7 @@ func (o *UpdateWorkspaceBindingsParameters) SetAdd(ctx context.Context, v []Work vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["add"] + t = t.(attr.TypeWithElementType).ElementType() o.Add = types.ListValueMust(t, vs) } @@ -17797,6 +17866,7 @@ func (o *UpdateWorkspaceBindingsParameters) SetRemove(ctx context.Context, v []W vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["remove"] + t = t.(attr.TypeWithElementType).ElementType() o.Remove = types.ListValueMust(t, vs) } @@ -18003,6 +18073,7 @@ func (o *ValidateCredentialResponse) SetResults(ctx context.Context, v []Credent vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -18298,6 +18369,7 @@ func (o *ValidateStorageCredentialResponse) SetResults(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -18609,5 +18681,6 @@ func (o *WorkspaceBindingsResponse) SetBindings(ctx context.Context, v []Workspa vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["bindings"] + t = t.(attr.TypeWithElementType).ElementType() o.Bindings = types.ListValueMust(t, vs) } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 6f5c23288e..e359043ac7 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -783,6 +783,7 @@ func (o *CloudProviderNodeInfo) SetStatus(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] + t = t.(attr.TypeWithElementType).ElementType() o.Status = types.ListValueMust(t, vs) } @@ -924,6 +925,7 @@ func (o *ClusterAccessControlResponse) SetAllPermissions(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -1277,6 +1279,7 @@ func (o *ClusterAttributes) SetCustomTags(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -1354,6 +1357,7 @@ func (o *ClusterAttributes) SetInitScripts(ctx context.Context, v []InitScriptIn vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -1379,6 +1383,7 @@ func (o *ClusterAttributes) SetSparkConf(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -1404,6 +1409,7 @@ func (o *ClusterAttributes) SetSparkEnvVars(ctx context.Context, v map[string]ty vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -1429,6 +1435,7 @@ func (o *ClusterAttributes) SetSshPublicKeys(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } @@ -1538,6 +1545,7 @@ func (o *ClusterCompliance) SetViolations(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + t = t.(attr.TypeWithElementType).ElementType() o.Violations = types.MapValueMust(t, vs) } @@ -2089,6 +2097,7 @@ func (o *ClusterDetails) SetCustomTags(ctx context.Context, v map[string]types.S vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -2114,6 +2123,7 @@ func (o *ClusterDetails) SetDefaultTags(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.DefaultTags = types.MapValueMust(t, vs) } @@ -2191,6 +2201,7 @@ func (o *ClusterDetails) SetExecutors(ctx context.Context, v []SparkNode) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["executors"] + t = t.(attr.TypeWithElementType).ElementType() o.Executors = types.ListValueMust(t, vs) } @@ -2242,6 +2253,7 @@ func (o *ClusterDetails) SetInitScripts(ctx context.Context, v []InitScriptInfo) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -2267,6 +2279,7 @@ func (o *ClusterDetails) SetSparkConf(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -2292,6 +2305,7 @@ func (o *ClusterDetails) SetSparkEnvVars(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -2343,6 +2357,7 @@ func (o *ClusterDetails) SetSshPublicKeys(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } @@ -2589,6 +2604,7 @@ func (o *ClusterLibraryStatuses) SetLibraryStatuses(ctx context.Context, v []Lib vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library_statuses"] + t = t.(attr.TypeWithElementType).ElementType() o.LibraryStatuses = types.ListValueMust(t, vs) } @@ -2777,6 +2793,7 @@ func (o *ClusterPermission) SetInheritedFromObject(ctx context.Context, v []type vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -2855,6 +2872,7 @@ func (o *ClusterPermissions) SetAccessControlList(ctx context.Context, v []Clust vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -2974,6 +2992,7 @@ func (o *ClusterPermissionsRequest) SetAccessControlList(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3115,6 +3134,7 @@ func (o *ClusterPolicyAccessControlResponse) SetAllPermissions(ctx context.Conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -3193,6 +3213,7 @@ func (o *ClusterPolicyPermission) SetInheritedFromObject(ctx context.Context, v vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -3271,6 +3292,7 @@ func (o *ClusterPolicyPermissions) SetAccessControlList(ctx context.Context, v [ vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3390,6 +3412,7 @@ func (o *ClusterPolicyPermissionsRequest) SetAccessControlList(ctx context.Conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3942,6 +3965,7 @@ func (o *ClusterSpec) SetCustomTags(ctx context.Context, v map[string]types.Stri vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -4019,6 +4043,7 @@ func (o *ClusterSpec) SetInitScripts(ctx context.Context, v []InitScriptInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -4044,6 +4069,7 @@ func (o *ClusterSpec) SetSparkConf(ctx context.Context, v map[string]types.Strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -4069,6 +4095,7 @@ func (o *ClusterSpec) SetSparkEnvVars(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -4094,6 +4121,7 @@ func (o *ClusterSpec) SetSshPublicKeys(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } @@ -4878,6 +4906,7 @@ func (o *CreateCluster) SetCustomTags(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -4955,6 +4984,7 @@ func (o *CreateCluster) SetInitScripts(ctx context.Context, v []InitScriptInfo) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -4980,6 +5010,7 @@ func (o *CreateCluster) SetSparkConf(ctx context.Context, v map[string]types.Str vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -5005,6 +5036,7 @@ func (o *CreateCluster) SetSparkEnvVars(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -5030,6 +5062,7 @@ func (o *CreateCluster) SetSshPublicKeys(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } @@ -5360,6 +5393,7 @@ func (o *CreateInstancePool) SetCustomTags(ctx context.Context, v map[string]typ vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -5437,6 +5471,7 @@ func (o *CreateInstancePool) SetPreloadedDockerImages(ctx context.Context, v []D vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_docker_images"] + t = t.(attr.TypeWithElementType).ElementType() o.PreloadedDockerImages = types.ListValueMust(t, vs) } @@ -5462,6 +5497,7 @@ func (o *CreateInstancePool) SetPreloadedSparkVersions(ctx context.Context, v [] vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_spark_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.PreloadedSparkVersions = types.ListValueMust(t, vs) } @@ -5618,6 +5654,7 @@ func (o *CreatePolicy) SetLibraries(ctx context.Context, v []Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -6920,6 +6957,7 @@ func (o *EditCluster) SetCustomTags(ctx context.Context, v map[string]types.Stri vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -6997,6 +7035,7 @@ func (o *EditCluster) SetInitScripts(ctx context.Context, v []InitScriptInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -7022,6 +7061,7 @@ func (o *EditCluster) SetSparkConf(ctx context.Context, v map[string]types.Strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -7047,6 +7087,7 @@ func (o *EditCluster) SetSparkEnvVars(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -7072,6 +7113,7 @@ func (o *EditCluster) SetSshPublicKeys(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } @@ -7246,6 +7288,7 @@ func (o *EditInstancePool) SetCustomTags(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -7400,6 +7443,7 @@ func (o *EditPolicy) SetLibraries(ctx context.Context, v []Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -7596,6 +7640,7 @@ func (o *EnforceClusterComplianceResponse) SetChanges(ctx context.Context, v []C vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["changes"] + t = t.(attr.TypeWithElementType).ElementType() o.Changes = types.ListValueMust(t, vs) } @@ -7682,6 +7727,7 @@ func (o *Environment) SetDependencies(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dependencies"] + t = t.(attr.TypeWithElementType).ElementType() o.Dependencies = types.ListValueMust(t, vs) } @@ -8229,6 +8275,7 @@ func (o *GetClusterComplianceResponse) SetViolations(ctx context.Context, v map[ vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + t = t.(attr.TypeWithElementType).ElementType() o.Violations = types.MapValueMust(t, vs) } @@ -8343,6 +8390,7 @@ func (o *GetClusterPermissionLevelsResponse) SetPermissionLevels(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -8500,6 +8548,7 @@ func (o *GetClusterPolicyPermissionLevelsResponse) SetPermissionLevels(ctx conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -8730,6 +8779,7 @@ func (o *GetEvents) SetEventTypes(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["event_types"] + t = t.(attr.TypeWithElementType).ElementType() o.EventTypes = types.ListValueMust(t, vs) } @@ -8814,6 +8864,7 @@ func (o *GetEventsResponse) SetEvents(ctx context.Context, v []ClusterEvent) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + t = t.(attr.TypeWithElementType).ElementType() o.Events = types.ListValueMust(t, vs) } @@ -9138,6 +9189,7 @@ func (o *GetInstancePool) SetCustomTags(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -9163,6 +9215,7 @@ func (o *GetInstancePool) SetDefaultTags(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.DefaultTags = types.MapValueMust(t, vs) } @@ -9240,6 +9293,7 @@ func (o *GetInstancePool) SetPreloadedDockerImages(ctx context.Context, v []Dock vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_docker_images"] + t = t.(attr.TypeWithElementType).ElementType() o.PreloadedDockerImages = types.ListValueMust(t, vs) } @@ -9265,6 +9319,7 @@ func (o *GetInstancePool) SetPreloadedSparkVersions(ctx context.Context, v []typ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_spark_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.PreloadedSparkVersions = types.ListValueMust(t, vs) } @@ -9431,6 +9486,7 @@ func (o *GetInstancePoolPermissionLevelsResponse) SetPermissionLevels(ctx contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -9636,6 +9692,7 @@ func (o *GetSparkVersionsResponse) SetVersions(ctx context.Context, v []SparkVer vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["versions"] + t = t.(attr.TypeWithElementType).ElementType() o.Versions = types.ListValueMust(t, vs) } @@ -10001,6 +10058,7 @@ func (o *InitScriptEventDetails) SetCluster(ctx context.Context, v []InitScriptI vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster"] + t = t.(attr.TypeWithElementType).ElementType() o.Cluster = types.ListValueMust(t, vs) } @@ -10026,6 +10084,7 @@ func (o *InitScriptEventDetails) SetGlobal(ctx context.Context, v []InitScriptIn vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["global"] + t = t.(attr.TypeWithElementType).ElementType() o.Global = types.ListValueMust(t, vs) } @@ -10537,6 +10596,7 @@ func (o *InstallLibraries) SetLibraries(ctx context.Context, v []Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -10714,6 +10774,7 @@ func (o *InstancePoolAccessControlResponse) SetAllPermissions(ctx context.Contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -10969,6 +11030,7 @@ func (o *InstancePoolAndStats) SetCustomTags(ctx context.Context, v map[string]t vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -10994,6 +11056,7 @@ func (o *InstancePoolAndStats) SetDefaultTags(ctx context.Context, v map[string] vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["default_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.DefaultTags = types.MapValueMust(t, vs) } @@ -11071,6 +11134,7 @@ func (o *InstancePoolAndStats) SetPreloadedDockerImages(ctx context.Context, v [ vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_docker_images"] + t = t.(attr.TypeWithElementType).ElementType() o.PreloadedDockerImages = types.ListValueMust(t, vs) } @@ -11096,6 +11160,7 @@ func (o *InstancePoolAndStats) SetPreloadedSparkVersions(ctx context.Context, v vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["preloaded_spark_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.PreloadedSparkVersions = types.ListValueMust(t, vs) } @@ -11421,6 +11486,7 @@ func (o *InstancePoolPermission) SetInheritedFromObject(ctx context.Context, v [ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -11499,6 +11565,7 @@ func (o *InstancePoolPermissions) SetAccessControlList(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -11618,6 +11685,7 @@ func (o *InstancePoolPermissionsRequest) SetAccessControlList(ctx context.Contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -11746,6 +11814,7 @@ func (o *InstancePoolStatus) SetPendingInstanceErrors(ctx context.Context, v []P vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pending_instance_errors"] + t = t.(attr.TypeWithElementType).ElementType() o.PendingInstanceErrors = types.ListValueMust(t, vs) } @@ -12096,6 +12165,7 @@ func (o *LibraryFullStatus) SetMessages(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["messages"] + t = t.(attr.TypeWithElementType).ElementType() o.Messages = types.ListValueMust(t, vs) } @@ -12167,6 +12237,7 @@ func (o *ListAllClusterLibraryStatusesResponse) SetStatuses(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statuses"] + t = t.(attr.TypeWithElementType).ElementType() o.Statuses = types.ListValueMust(t, vs) } @@ -12243,6 +12314,7 @@ func (o *ListAvailableZonesResponse) SetZones(ctx context.Context, v []types.Str vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["zones"] + t = t.(attr.TypeWithElementType).ElementType() o.Zones = types.ListValueMust(t, vs) } @@ -12379,6 +12451,7 @@ func (o *ListClusterCompliancesResponse) SetClusters(ctx context.Context, v []Cl vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.Clusters = types.ListValueMust(t, vs) } @@ -12515,6 +12588,7 @@ func (o *ListClustersFilterBy) SetClusterSources(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_sources"] + t = t.(attr.TypeWithElementType).ElementType() o.ClusterSources = types.ListValueMust(t, vs) } @@ -12540,6 +12614,7 @@ func (o *ListClustersFilterBy) SetClusterStates(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cluster_states"] + t = t.(attr.TypeWithElementType).ElementType() o.ClusterStates = types.ListValueMust(t, vs) } @@ -12739,6 +12814,7 @@ func (o *ListClustersResponse) SetClusters(ctx context.Context, v []ClusterDetai vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.Clusters = types.ListValueMust(t, vs) } @@ -12857,6 +12933,7 @@ func (o *ListGlobalInitScriptsResponse) SetScripts(ctx context.Context, v []Glob vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.Scripts = types.ListValueMust(t, vs) } @@ -12927,6 +13004,7 @@ func (o *ListInstancePools) SetInstancePools(ctx context.Context, v []InstancePo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["instance_pools"] + t = t.(attr.TypeWithElementType).ElementType() o.InstancePools = types.ListValueMust(t, vs) } @@ -12998,6 +13076,7 @@ func (o *ListInstanceProfilesResponse) SetInstanceProfiles(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["instance_profiles"] + t = t.(attr.TypeWithElementType).ElementType() o.InstanceProfiles = types.ListValueMust(t, vs) } @@ -13069,6 +13148,7 @@ func (o *ListNodeTypesResponse) SetNodeTypes(ctx context.Context, v []NodeType) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["node_types"] + t = t.(attr.TypeWithElementType).ElementType() o.NodeTypes = types.ListValueMust(t, vs) } @@ -13140,6 +13220,7 @@ func (o *ListPoliciesResponse) SetPolicies(ctx context.Context, v []Policy) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["policies"] + t = t.(attr.TypeWithElementType).ElementType() o.Policies = types.ListValueMust(t, vs) } @@ -13263,6 +13344,7 @@ func (o *ListPolicyFamiliesResponse) SetPolicyFamilies(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["policy_families"] + t = t.(attr.TypeWithElementType).ElementType() o.PolicyFamilies = types.ListValueMust(t, vs) } @@ -13483,6 +13565,7 @@ func (o *MavenLibrary) SetExclusions(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exclusions"] + t = t.(attr.TypeWithElementType).ElementType() o.Exclusions = types.ListValueMust(t, vs) } @@ -14062,6 +14145,7 @@ func (o *Policy) SetLibraries(ctx context.Context, v []Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -14615,6 +14699,7 @@ func (o *Results) SetFileNames(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fileNames"] + t = t.(attr.TypeWithElementType).ElementType() o.FileNames = types.ListValueMust(t, vs) } @@ -14640,6 +14725,7 @@ func (o *Results) SetSchema(ctx context.Context, v []types.Object) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schema"] + t = t.(attr.TypeWithElementType).ElementType() o.Schema = types.ListValueMust(t, vs) } @@ -15079,6 +15165,7 @@ func (o *TerminationReason) SetParameters(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.MapValueMust(t, vs) } @@ -15154,6 +15241,7 @@ func (o *UninstallLibraries) SetLibraries(ctx context.Context, v []Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -15753,6 +15841,7 @@ func (o *UpdateClusterResource) SetCustomTags(ctx context.Context, v map[string] vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -15830,6 +15919,7 @@ func (o *UpdateClusterResource) SetInitScripts(ctx context.Context, v []InitScri vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -15855,6 +15945,7 @@ func (o *UpdateClusterResource) SetSparkConf(ctx context.Context, v map[string]t vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -15880,6 +15971,7 @@ func (o *UpdateClusterResource) SetSparkEnvVars(ctx context.Context, v map[strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -15905,6 +15997,7 @@ func (o *UpdateClusterResource) SetSshPublicKeys(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 468fd2142e..31f23a96b8 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -1148,6 +1148,7 @@ func (o *GenieMessage) SetAttachments(ctx context.Context, v []GenieAttachment) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["attachments"] + t = t.(attr.TypeWithElementType).ElementType() o.Attachments = types.ListValueMust(t, vs) } @@ -1675,6 +1676,7 @@ func (o *ListDashboardsResponse) SetDashboards(ctx context.Context, v []Dashboar vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dashboards"] + t = t.(attr.TypeWithElementType).ElementType() o.Dashboards = types.ListValueMust(t, vs) } @@ -1804,6 +1806,7 @@ func (o *ListSchedulesResponse) SetSchedules(ctx context.Context, v []Schedule) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schedules"] + t = t.(attr.TypeWithElementType).ElementType() o.Schedules = types.ListValueMust(t, vs) } @@ -1937,6 +1940,7 @@ func (o *ListSubscriptionsResponse) SetSubscriptions(ctx context.Context, v []Su vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriptions"] + t = t.(attr.TypeWithElementType).ElementType() o.Subscriptions = types.ListValueMust(t, vs) } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 2a7f69d1aa..fc3cc33e65 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -1162,6 +1162,7 @@ func (o *ListDirectoryResponse) SetContents(ctx context.Context, v []DirectoryEn vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["contents"] + t = t.(attr.TypeWithElementType).ElementType() o.Contents = types.ListValueMust(t, vs) } @@ -1234,6 +1235,7 @@ func (o *ListStatusResponse) SetFiles(ctx context.Context, v []FileInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["files"] + t = t.(attr.TypeWithElementType).ElementType() o.Files = types.ListValueMust(t, vs) } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index a199c3cbc9..6482e55d67 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -158,6 +158,7 @@ func (o *AccessControlResponse) SetAllPermissions(ctx context.Context, v []Permi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -869,6 +870,7 @@ func (o *GetAssignableRolesForResourceResponse) SetRoles(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + t = t.(attr.TypeWithElementType).ElementType() o.Roles = types.ListValueMust(t, vs) } @@ -983,6 +985,7 @@ func (o *GetPasswordPermissionLevelsResponse) SetPermissionLevels(ctx context.Co vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -1101,6 +1104,7 @@ func (o *GetPermissionLevelsResponse) SetPermissionLevels(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -1445,6 +1449,7 @@ func (o *GrantRule) SetPrincipals(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["principals"] + t = t.(attr.TypeWithElementType).ElementType() o.Principals = types.ListValueMust(t, vs) } @@ -1566,6 +1571,7 @@ func (o *Group) SetEntitlements(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["entitlements"] + t = t.(attr.TypeWithElementType).ElementType() o.Entitlements = types.ListValueMust(t, vs) } @@ -1591,6 +1597,7 @@ func (o *Group) SetGroups(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["groups"] + t = t.(attr.TypeWithElementType).ElementType() o.Groups = types.ListValueMust(t, vs) } @@ -1616,6 +1623,7 @@ func (o *Group) SetMembers(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["members"] + t = t.(attr.TypeWithElementType).ElementType() o.Members = types.ListValueMust(t, vs) } @@ -1667,6 +1675,7 @@ func (o *Group) SetRoles(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + t = t.(attr.TypeWithElementType).ElementType() o.Roles = types.ListValueMust(t, vs) } @@ -1692,6 +1701,7 @@ func (o *Group) SetSchemas(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -2076,6 +2086,7 @@ func (o *ListGroupsResponse) SetResources(ctx context.Context, v []Group) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Resources"] + t = t.(attr.TypeWithElementType).ElementType() o.Resources = types.ListValueMust(t, vs) } @@ -2101,6 +2112,7 @@ func (o *ListGroupsResponse) SetSchemas(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -2192,6 +2204,7 @@ func (o *ListServicePrincipalResponse) SetResources(ctx context.Context, v []Ser vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Resources"] + t = t.(attr.TypeWithElementType).ElementType() o.Resources = types.ListValueMust(t, vs) } @@ -2217,6 +2230,7 @@ func (o *ListServicePrincipalResponse) SetSchemas(ctx context.Context, v []types vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -2455,6 +2469,7 @@ func (o *ListUsersResponse) SetResources(ctx context.Context, v []User) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Resources"] + t = t.(attr.TypeWithElementType).ElementType() o.Resources = types.ListValueMust(t, vs) } @@ -2480,6 +2495,7 @@ func (o *ListUsersResponse) SetSchemas(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -2744,6 +2760,7 @@ func (o *ObjectPermissions) SetAccessControlList(ctx context.Context, v []Access vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -2827,6 +2844,7 @@ func (o *PartialUpdate) SetOperations(ctx context.Context, v []Patch) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["Operations"] + t = t.(attr.TypeWithElementType).ElementType() o.Operations = types.ListValueMust(t, vs) } @@ -2852,6 +2870,7 @@ func (o *PartialUpdate) SetSchemas(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -2993,6 +3012,7 @@ func (o *PasswordAccessControlResponse) SetAllPermissions(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -3071,6 +3091,7 @@ func (o *PasswordPermission) SetInheritedFromObject(ctx context.Context, v []typ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -3149,6 +3170,7 @@ func (o *PasswordPermissions) SetAccessControlList(ctx context.Context, v []Pass vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3264,6 +3286,7 @@ func (o *PasswordPermissionsRequest) SetAccessControlList(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3428,6 +3451,7 @@ func (o *Permission) SetInheritedFromObject(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -3512,6 +3536,7 @@ func (o *PermissionAssignment) SetPermissions(ctx context.Context, v []types.Str vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.Permissions = types.ListValueMust(t, vs) } @@ -3609,6 +3634,7 @@ func (o *PermissionAssignments) SetPermissionAssignments(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_assignments"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionAssignments = types.ListValueMust(t, vs) } @@ -3782,6 +3808,7 @@ func (o *PermissionsRequest) SetAccessControlList(ctx context.Context, v []Acces vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -4006,6 +4033,7 @@ func (o *RuleSetResponse) SetGrantRules(ctx context.Context, v []GrantRule) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["grant_rules"] + t = t.(attr.TypeWithElementType).ElementType() o.GrantRules = types.ListValueMust(t, vs) } @@ -4087,6 +4115,7 @@ func (o *RuleSetUpdateRequest) SetGrantRules(ctx context.Context, v []GrantRule) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["grant_rules"] + t = t.(attr.TypeWithElementType).ElementType() o.GrantRules = types.ListValueMust(t, vs) } @@ -4202,6 +4231,7 @@ func (o *ServicePrincipal) SetEntitlements(ctx context.Context, v []ComplexValue vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["entitlements"] + t = t.(attr.TypeWithElementType).ElementType() o.Entitlements = types.ListValueMust(t, vs) } @@ -4227,6 +4257,7 @@ func (o *ServicePrincipal) SetGroups(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["groups"] + t = t.(attr.TypeWithElementType).ElementType() o.Groups = types.ListValueMust(t, vs) } @@ -4252,6 +4283,7 @@ func (o *ServicePrincipal) SetRoles(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + t = t.(attr.TypeWithElementType).ElementType() o.Roles = types.ListValueMust(t, vs) } @@ -4277,6 +4309,7 @@ func (o *ServicePrincipal) SetSchemas(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -4473,6 +4506,7 @@ func (o *UpdateWorkspaceAssignments) SetPermissions(ctx context.Context, v []typ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.Permissions = types.ListValueMust(t, vs) } @@ -4608,6 +4642,7 @@ func (o *User) SetEmails(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["emails"] + t = t.(attr.TypeWithElementType).ElementType() o.Emails = types.ListValueMust(t, vs) } @@ -4633,6 +4668,7 @@ func (o *User) SetEntitlements(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["entitlements"] + t = t.(attr.TypeWithElementType).ElementType() o.Entitlements = types.ListValueMust(t, vs) } @@ -4658,6 +4694,7 @@ func (o *User) SetGroups(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["groups"] + t = t.(attr.TypeWithElementType).ElementType() o.Groups = types.ListValueMust(t, vs) } @@ -4709,6 +4746,7 @@ func (o *User) SetRoles(ctx context.Context, v []ComplexValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["roles"] + t = t.(attr.TypeWithElementType).ElementType() o.Roles = types.ListValueMust(t, vs) } @@ -4734,6 +4772,7 @@ func (o *User) SetSchemas(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["schemas"] + t = t.(attr.TypeWithElementType).ElementType() o.Schemas = types.ListValueMust(t, vs) } @@ -4805,5 +4844,6 @@ func (o *WorkspacePermissions) SetPermissions(ctx context.Context, v []Permissio vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.Permissions = types.ListValueMust(t, vs) } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index a9450fe5c9..50c0f92f42 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -481,6 +481,7 @@ func (o *BaseRun) SetJobClusters(ctx context.Context, v []JobCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobClusters = types.ListValueMust(t, vs) } @@ -506,6 +507,7 @@ func (o *BaseRun) SetJobParameters(ctx context.Context, v []JobParameter) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobParameters = types.ListValueMust(t, vs) } @@ -557,6 +559,7 @@ func (o *BaseRun) SetRepairHistory(ctx context.Context, v []RepairHistoryItem) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repair_history"] + t = t.(attr.TypeWithElementType).ElementType() o.RepairHistory = types.ListValueMust(t, vs) } @@ -660,6 +663,7 @@ func (o *BaseRun) SetTasks(ctx context.Context, v []RunTask) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tasks"] + t = t.(attr.TypeWithElementType).ElementType() o.Tasks = types.ListValueMust(t, vs) } @@ -999,6 +1003,7 @@ func (o *ClusterSpec) SetLibraries(ctx context.Context, v []compute_tf.Library) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -1395,6 +1400,7 @@ func (o *CreateJob) SetAccessControlList(ctx context.Context, v []JobAccessContr vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -1498,6 +1504,7 @@ func (o *CreateJob) SetEnvironments(ctx context.Context, v []JobEnvironment) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment"] + t = t.(attr.TypeWithElementType).ElementType() o.Environments = types.ListValueMust(t, vs) } @@ -1575,6 +1582,7 @@ func (o *CreateJob) SetJobClusters(ctx context.Context, v []JobCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_cluster"] + t = t.(attr.TypeWithElementType).ElementType() o.JobClusters = types.ListValueMust(t, vs) } @@ -1626,6 +1634,7 @@ func (o *CreateJob) SetParameters(ctx context.Context, v []JobParameterDefinitio vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameter"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -1729,6 +1738,7 @@ func (o *CreateJob) SetTags(ctx context.Context, v map[string]types.String) { vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.MapValueMust(t, vs) } @@ -1754,6 +1764,7 @@ func (o *CreateJob) SetTasks(ctx context.Context, v []Task) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task"] + t = t.(attr.TypeWithElementType).ElementType() o.Tasks = types.ListValueMust(t, vs) } @@ -1983,6 +1994,7 @@ func (o *DbtOutput) SetArtifactsHeaders(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["artifacts_headers"] + t = t.(attr.TypeWithElementType).ElementType() o.ArtifactsHeaders = types.MapValueMust(t, vs) } @@ -2098,6 +2110,7 @@ func (o *DbtTask) SetCommands(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["commands"] + t = t.(attr.TypeWithElementType).ElementType() o.Commands = types.ListValueMust(t, vs) } @@ -2450,6 +2463,7 @@ func (o *EnforcePolicyComplianceResponse) SetJobClusterChanges(ctx context.Conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_cluster_changes"] + t = t.(attr.TypeWithElementType).ElementType() o.JobClusterChanges = types.ListValueMust(t, vs) } @@ -2552,6 +2566,7 @@ func (o *ExportRunOutput) SetViews(ctx context.Context, v []ViewItem) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["views"] + t = t.(attr.TypeWithElementType).ElementType() o.Views = types.ListValueMust(t, vs) } @@ -2733,6 +2748,7 @@ func (o *ForEachStats) SetErrorMessageStats(ctx context.Context, v []ForEachTask vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error_message_stats"] + t = t.(attr.TypeWithElementType).ElementType() o.ErrorMessageStats = types.ListValueMust(t, vs) } @@ -3070,6 +3086,7 @@ func (o *GetJobPermissionLevelsResponse) SetPermissionLevels(ctx context.Context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -3282,6 +3299,7 @@ func (o *GetPolicyComplianceResponse) SetViolations(ctx context.Context, v map[s vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + t = t.(attr.TypeWithElementType).ElementType() o.Violations = types.MapValueMust(t, vs) } @@ -3817,6 +3835,7 @@ func (o *JobAccessControlResponse) SetAllPermissions(ctx context.Context, v []Jo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -3978,6 +3997,7 @@ func (o *JobCompliance) SetViolations(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["violations"] + t = t.(attr.TypeWithElementType).ElementType() o.Violations = types.MapValueMust(t, vs) } @@ -4150,6 +4170,7 @@ func (o *JobEmailNotifications) SetOnDurationWarningThresholdExceeded(ctx contex vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_duration_warning_threshold_exceeded"] + t = t.(attr.TypeWithElementType).ElementType() o.OnDurationWarningThresholdExceeded = types.ListValueMust(t, vs) } @@ -4175,6 +4196,7 @@ func (o *JobEmailNotifications) SetOnFailure(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + t = t.(attr.TypeWithElementType).ElementType() o.OnFailure = types.ListValueMust(t, vs) } @@ -4200,6 +4222,7 @@ func (o *JobEmailNotifications) SetOnStart(ctx context.Context, v []types.String vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_start"] + t = t.(attr.TypeWithElementType).ElementType() o.OnStart = types.ListValueMust(t, vs) } @@ -4225,6 +4248,7 @@ func (o *JobEmailNotifications) SetOnStreamingBacklogExceeded(ctx context.Contex vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_streaming_backlog_exceeded"] + t = t.(attr.TypeWithElementType).ElementType() o.OnStreamingBacklogExceeded = types.ListValueMust(t, vs) } @@ -4250,6 +4274,7 @@ func (o *JobEmailNotifications) SetOnSuccess(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_success"] + t = t.(attr.TypeWithElementType).ElementType() o.OnSuccess = types.ListValueMust(t, vs) } @@ -4551,6 +4576,7 @@ func (o *JobPermission) SetInheritedFromObject(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -4629,6 +4655,7 @@ func (o *JobPermissions) SetAccessControlList(ctx context.Context, v []JobAccess vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -4748,6 +4775,7 @@ func (o *JobPermissionsRequest) SetAccessControlList(ctx context.Context, v []Jo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -5139,6 +5167,7 @@ func (o *JobSettings) SetEnvironments(ctx context.Context, v []JobEnvironment) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment"] + t = t.(attr.TypeWithElementType).ElementType() o.Environments = types.ListValueMust(t, vs) } @@ -5216,6 +5245,7 @@ func (o *JobSettings) SetJobClusters(ctx context.Context, v []JobCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_cluster"] + t = t.(attr.TypeWithElementType).ElementType() o.JobClusters = types.ListValueMust(t, vs) } @@ -5267,6 +5297,7 @@ func (o *JobSettings) SetParameters(ctx context.Context, v []JobParameterDefinit vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameter"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -5370,6 +5401,7 @@ func (o *JobSettings) SetTags(ctx context.Context, v map[string]types.String) { vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.MapValueMust(t, vs) } @@ -5395,6 +5427,7 @@ func (o *JobSettings) SetTasks(ctx context.Context, v []Task) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task"] + t = t.(attr.TypeWithElementType).ElementType() o.Tasks = types.ListValueMust(t, vs) } @@ -5641,6 +5674,7 @@ func (o *JobsHealthRules) SetRules(ctx context.Context, v []JobsHealthRule) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rules"] + t = t.(attr.TypeWithElementType).ElementType() o.Rules = types.ListValueMust(t, vs) } @@ -5724,6 +5758,7 @@ func (o *ListJobComplianceForPolicyResponse) SetJobs(ctx context.Context, v []Jo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jobs"] + t = t.(attr.TypeWithElementType).ElementType() o.Jobs = types.ListValueMust(t, vs) } @@ -5928,6 +5963,7 @@ func (o *ListJobsResponse) SetJobs(ctx context.Context, v []BaseJob) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jobs"] + t = t.(attr.TypeWithElementType).ElementType() o.Jobs = types.ListValueMust(t, vs) } @@ -6110,6 +6146,7 @@ func (o *ListRunsResponse) SetRuns(ctx context.Context, v []BaseRun) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["runs"] + t = t.(attr.TypeWithElementType).ElementType() o.Runs = types.ListValueMust(t, vs) } @@ -6274,6 +6311,7 @@ func (o *NotebookTask) SetBaseParameters(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["base_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.BaseParameters = types.MapValueMust(t, vs) } @@ -6499,6 +6537,7 @@ func (o *PythonWheelTask) SetNamedParameters(ctx context.Context, v map[string]t vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["named_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.NamedParameters = types.MapValueMust(t, vs) } @@ -6524,6 +6563,7 @@ func (o *PythonWheelTask) SetParameters(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -6774,6 +6814,7 @@ func (o *RepairHistoryItem) SetTaskRunIds(ctx context.Context, v []types.Int64) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["task_run_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.TaskRunIds = types.ListValueMust(t, vs) } @@ -6996,6 +7037,7 @@ func (o *RepairRun) SetDbtCommands(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + t = t.(attr.TypeWithElementType).ElementType() o.DbtCommands = types.ListValueMust(t, vs) } @@ -7021,6 +7063,7 @@ func (o *RepairRun) SetJarParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + t = t.(attr.TypeWithElementType).ElementType() o.JarParams = types.ListValueMust(t, vs) } @@ -7046,6 +7089,7 @@ func (o *RepairRun) SetJobParameters(ctx context.Context, v map[string]types.Str vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobParameters = types.MapValueMust(t, vs) } @@ -7071,6 +7115,7 @@ func (o *RepairRun) SetNotebookParams(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + t = t.(attr.TypeWithElementType).ElementType() o.NotebookParams = types.MapValueMust(t, vs) } @@ -7122,6 +7167,7 @@ func (o *RepairRun) SetPythonNamedParams(ctx context.Context, v map[string]types vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonNamedParams = types.MapValueMust(t, vs) } @@ -7147,6 +7193,7 @@ func (o *RepairRun) SetPythonParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonParams = types.ListValueMust(t, vs) } @@ -7172,6 +7219,7 @@ func (o *RepairRun) SetRerunTasks(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rerun_tasks"] + t = t.(attr.TypeWithElementType).ElementType() o.RerunTasks = types.ListValueMust(t, vs) } @@ -7197,6 +7245,7 @@ func (o *RepairRun) SetSparkSubmitParams(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkSubmitParams = types.ListValueMust(t, vs) } @@ -7222,6 +7271,7 @@ func (o *RepairRun) SetSqlParams(ctx context.Context, v map[string]types.String) vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SqlParams = types.MapValueMust(t, vs) } @@ -7497,6 +7547,7 @@ func (o *ResolvedDbtTaskValues) SetCommands(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["commands"] + t = t.(attr.TypeWithElementType).ElementType() o.Commands = types.ListValueMust(t, vs) } @@ -7567,6 +7618,7 @@ func (o *ResolvedNotebookTaskValues) SetBaseParameters(ctx context.Context, v ma vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["base_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.BaseParameters = types.MapValueMust(t, vs) } @@ -7637,6 +7689,7 @@ func (o *ResolvedParamPairValues) SetParameters(ctx context.Context, v map[strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.MapValueMust(t, vs) } @@ -7714,6 +7767,7 @@ func (o *ResolvedPythonWheelTaskValues) SetNamedParameters(ctx context.Context, vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["named_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.NamedParameters = types.MapValueMust(t, vs) } @@ -7739,6 +7793,7 @@ func (o *ResolvedPythonWheelTaskValues) SetParameters(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -7816,6 +7871,7 @@ func (o *ResolvedRunJobTaskValues) SetJobParameters(ctx context.Context, v map[s vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobParameters = types.MapValueMust(t, vs) } @@ -7841,6 +7897,7 @@ func (o *ResolvedRunJobTaskValues) SetParameters(ctx context.Context, v map[stri vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.MapValueMust(t, vs) } @@ -7911,6 +7968,7 @@ func (o *ResolvedStringParamsValues) SetParameters(ctx context.Context, v []type vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -8659,6 +8717,7 @@ func (o *Run) SetIterations(ctx context.Context, v []RunTask) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["iterations"] + t = t.(attr.TypeWithElementType).ElementType() o.Iterations = types.ListValueMust(t, vs) } @@ -8684,6 +8743,7 @@ func (o *Run) SetJobClusters(ctx context.Context, v []JobCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobClusters = types.ListValueMust(t, vs) } @@ -8709,6 +8769,7 @@ func (o *Run) SetJobParameters(ctx context.Context, v []JobParameter) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobParameters = types.ListValueMust(t, vs) } @@ -8760,6 +8821,7 @@ func (o *Run) SetRepairHistory(ctx context.Context, v []RepairHistoryItem) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repair_history"] + t = t.(attr.TypeWithElementType).ElementType() o.RepairHistory = types.ListValueMust(t, vs) } @@ -8863,6 +8925,7 @@ func (o *Run) SetTasks(ctx context.Context, v []RunTask) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tasks"] + t = t.(attr.TypeWithElementType).ElementType() o.Tasks = types.ListValueMust(t, vs) } @@ -9311,6 +9374,7 @@ func (o *RunJobTask) SetDbtCommands(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + t = t.(attr.TypeWithElementType).ElementType() o.DbtCommands = types.ListValueMust(t, vs) } @@ -9336,6 +9400,7 @@ func (o *RunJobTask) SetJarParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + t = t.(attr.TypeWithElementType).ElementType() o.JarParams = types.ListValueMust(t, vs) } @@ -9361,6 +9426,7 @@ func (o *RunJobTask) SetJobParameters(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobParameters = types.MapValueMust(t, vs) } @@ -9386,6 +9452,7 @@ func (o *RunJobTask) SetNotebookParams(ctx context.Context, v map[string]types.S vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + t = t.(attr.TypeWithElementType).ElementType() o.NotebookParams = types.MapValueMust(t, vs) } @@ -9437,6 +9504,7 @@ func (o *RunJobTask) SetPythonNamedParams(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonNamedParams = types.MapValueMust(t, vs) } @@ -9462,6 +9530,7 @@ func (o *RunJobTask) SetPythonParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonParams = types.ListValueMust(t, vs) } @@ -9487,6 +9556,7 @@ func (o *RunJobTask) SetSparkSubmitParams(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkSubmitParams = types.ListValueMust(t, vs) } @@ -9512,6 +9582,7 @@ func (o *RunJobTask) SetSqlParams(ctx context.Context, v map[string]types.String vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SqlParams = types.MapValueMust(t, vs) } @@ -9742,6 +9813,7 @@ func (o *RunNow) SetDbtCommands(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + t = t.(attr.TypeWithElementType).ElementType() o.DbtCommands = types.ListValueMust(t, vs) } @@ -9767,6 +9839,7 @@ func (o *RunNow) SetJarParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + t = t.(attr.TypeWithElementType).ElementType() o.JarParams = types.ListValueMust(t, vs) } @@ -9792,6 +9865,7 @@ func (o *RunNow) SetJobParameters(ctx context.Context, v map[string]types.String vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job_parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.JobParameters = types.MapValueMust(t, vs) } @@ -9817,6 +9891,7 @@ func (o *RunNow) SetNotebookParams(ctx context.Context, v map[string]types.Strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + t = t.(attr.TypeWithElementType).ElementType() o.NotebookParams = types.MapValueMust(t, vs) } @@ -9842,6 +9917,7 @@ func (o *RunNow) SetOnly(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["only"] + t = t.(attr.TypeWithElementType).ElementType() o.Only = types.ListValueMust(t, vs) } @@ -9893,6 +9969,7 @@ func (o *RunNow) SetPythonNamedParams(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonNamedParams = types.MapValueMust(t, vs) } @@ -9918,6 +9995,7 @@ func (o *RunNow) SetPythonParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonParams = types.ListValueMust(t, vs) } @@ -9969,6 +10047,7 @@ func (o *RunNow) SetSparkSubmitParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkSubmitParams = types.ListValueMust(t, vs) } @@ -9994,6 +10073,7 @@ func (o *RunNow) SetSqlParams(ctx context.Context, v map[string]types.String) { vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SqlParams = types.MapValueMust(t, vs) } @@ -10469,6 +10549,7 @@ func (o *RunParameters) SetDbtCommands(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dbt_commands"] + t = t.(attr.TypeWithElementType).ElementType() o.DbtCommands = types.ListValueMust(t, vs) } @@ -10494,6 +10575,7 @@ func (o *RunParameters) SetJarParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["jar_params"] + t = t.(attr.TypeWithElementType).ElementType() o.JarParams = types.ListValueMust(t, vs) } @@ -10519,6 +10601,7 @@ func (o *RunParameters) SetNotebookParams(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notebook_params"] + t = t.(attr.TypeWithElementType).ElementType() o.NotebookParams = types.MapValueMust(t, vs) } @@ -10570,6 +10653,7 @@ func (o *RunParameters) SetPythonNamedParams(ctx context.Context, v map[string]t vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_named_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonNamedParams = types.MapValueMust(t, vs) } @@ -10595,6 +10679,7 @@ func (o *RunParameters) SetPythonParams(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["python_params"] + t = t.(attr.TypeWithElementType).ElementType() o.PythonParams = types.ListValueMust(t, vs) } @@ -10620,6 +10705,7 @@ func (o *RunParameters) SetSparkSubmitParams(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_submit_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkSubmitParams = types.ListValueMust(t, vs) } @@ -10645,6 +10731,7 @@ func (o *RunParameters) SetSqlParams(ctx context.Context, v map[string]types.Str vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_params"] + t = t.(attr.TypeWithElementType).ElementType() o.SqlParams = types.MapValueMust(t, vs) } @@ -11270,6 +11357,7 @@ func (o *RunTask) SetDependsOn(ctx context.Context, v []TaskDependency) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["depends_on"] + t = t.(attr.TypeWithElementType).ElementType() o.DependsOn = types.ListValueMust(t, vs) } @@ -11373,6 +11461,7 @@ func (o *RunTask) SetLibraries(ctx context.Context, v []compute_tf.Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -11826,6 +11915,7 @@ func (o *SparkJarTask) SetParameters(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -11922,6 +12012,7 @@ func (o *SparkPythonTask) SetParameters(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -11998,6 +12089,7 @@ func (o *SparkSubmitTask) SetParameters(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -12090,6 +12182,7 @@ func (o *SqlAlertOutput) SetSqlStatements(ctx context.Context, v []SqlStatementO vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_statements"] + t = t.(attr.TypeWithElementType).ElementType() o.SqlStatements = types.ListValueMust(t, vs) } @@ -12165,6 +12258,7 @@ func (o *SqlDashboardOutput) SetWidgets(ctx context.Context, v []SqlDashboardWid vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["widgets"] + t = t.(attr.TypeWithElementType).ElementType() o.Widgets = types.ListValueMust(t, vs) } @@ -12528,6 +12622,7 @@ func (o *SqlQueryOutput) SetSqlStatements(ctx context.Context, v []SqlStatementO vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_statements"] + t = t.(attr.TypeWithElementType).ElementType() o.SqlStatements = types.ListValueMust(t, vs) } @@ -12756,6 +12851,7 @@ func (o *SqlTask) SetParameters(ctx context.Context, v map[string]types.String) vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.MapValueMust(t, vs) } @@ -12861,6 +12957,7 @@ func (o *SqlTaskAlert) SetSubscriptions(ctx context.Context, v []SqlTaskSubscrip vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriptions"] + t = t.(attr.TypeWithElementType).ElementType() o.Subscriptions = types.ListValueMust(t, vs) } @@ -12945,6 +13042,7 @@ func (o *SqlTaskDashboard) SetSubscriptions(ctx context.Context, v []SqlTaskSubs vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subscriptions"] + t = t.(attr.TypeWithElementType).ElementType() o.Subscriptions = types.ListValueMust(t, vs) } @@ -13273,6 +13371,7 @@ func (o *SubmitRun) SetAccessControlList(ctx context.Context, v []JobAccessContr vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -13324,6 +13423,7 @@ func (o *SubmitRun) SetEnvironments(ctx context.Context, v []JobEnvironment) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environments"] + t = t.(attr.TypeWithElementType).ElementType() o.Environments = types.ListValueMust(t, vs) } @@ -13479,6 +13579,7 @@ func (o *SubmitRun) SetTasks(ctx context.Context, v []SubmitTask) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tasks"] + t = t.(attr.TypeWithElementType).ElementType() o.Tasks = types.ListValueMust(t, vs) } @@ -13863,6 +13964,7 @@ func (o *SubmitTask) SetDependsOn(ctx context.Context, v []TaskDependency) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["depends_on"] + t = t.(attr.TypeWithElementType).ElementType() o.DependsOn = types.ListValueMust(t, vs) } @@ -13966,6 +14068,7 @@ func (o *SubmitTask) SetLibraries(ctx context.Context, v []compute_tf.Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -14341,6 +14444,7 @@ func (o *TableUpdateTriggerConfiguration) SetTableNames(ctx context.Context, v [ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["table_names"] + t = t.(attr.TypeWithElementType).ElementType() o.TableNames = types.ListValueMust(t, vs) } @@ -14689,6 +14793,7 @@ func (o *Task) SetDependsOn(ctx context.Context, v []TaskDependency) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["depends_on"] + t = t.(attr.TypeWithElementType).ElementType() o.DependsOn = types.ListValueMust(t, vs) } @@ -14792,6 +14897,7 @@ func (o *Task) SetLibraries(ctx context.Context, v []compute_tf.Library) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["library"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -15249,6 +15355,7 @@ func (o *TaskEmailNotifications) SetOnDurationWarningThresholdExceeded(ctx conte vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_duration_warning_threshold_exceeded"] + t = t.(attr.TypeWithElementType).ElementType() o.OnDurationWarningThresholdExceeded = types.ListValueMust(t, vs) } @@ -15274,6 +15381,7 @@ func (o *TaskEmailNotifications) SetOnFailure(ctx context.Context, v []types.Str vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + t = t.(attr.TypeWithElementType).ElementType() o.OnFailure = types.ListValueMust(t, vs) } @@ -15299,6 +15407,7 @@ func (o *TaskEmailNotifications) SetOnStart(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_start"] + t = t.(attr.TypeWithElementType).ElementType() o.OnStart = types.ListValueMust(t, vs) } @@ -15324,6 +15433,7 @@ func (o *TaskEmailNotifications) SetOnStreamingBacklogExceeded(ctx context.Conte vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_streaming_backlog_exceeded"] + t = t.(attr.TypeWithElementType).ElementType() o.OnStreamingBacklogExceeded = types.ListValueMust(t, vs) } @@ -15349,6 +15459,7 @@ func (o *TaskEmailNotifications) SetOnSuccess(ctx context.Context, v []types.Str vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_success"] + t = t.(attr.TypeWithElementType).ElementType() o.OnSuccess = types.ListValueMust(t, vs) } @@ -15817,6 +15928,7 @@ func (o *UpdateJob) SetFieldsToRemove(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fields_to_remove"] + t = t.(attr.TypeWithElementType).ElementType() o.FieldsToRemove = types.ListValueMust(t, vs) } @@ -16085,6 +16197,7 @@ func (o *WebhookNotifications) SetOnDurationWarningThresholdExceeded(ctx context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_duration_warning_threshold_exceeded"] + t = t.(attr.TypeWithElementType).ElementType() o.OnDurationWarningThresholdExceeded = types.ListValueMust(t, vs) } @@ -16110,6 +16223,7 @@ func (o *WebhookNotifications) SetOnFailure(ctx context.Context, v []Webhook) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_failure"] + t = t.(attr.TypeWithElementType).ElementType() o.OnFailure = types.ListValueMust(t, vs) } @@ -16135,6 +16249,7 @@ func (o *WebhookNotifications) SetOnStart(ctx context.Context, v []Webhook) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_start"] + t = t.(attr.TypeWithElementType).ElementType() o.OnStart = types.ListValueMust(t, vs) } @@ -16160,6 +16275,7 @@ func (o *WebhookNotifications) SetOnStreamingBacklogExceeded(ctx context.Context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_streaming_backlog_exceeded"] + t = t.(attr.TypeWithElementType).ElementType() o.OnStreamingBacklogExceeded = types.ListValueMust(t, vs) } @@ -16185,5 +16301,6 @@ func (o *WebhookNotifications) SetOnSuccess(ctx context.Context, v []Webhook) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["on_success"] + t = t.(attr.TypeWithElementType).ElementType() o.OnSuccess = types.ListValueMust(t, vs) } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 9079feac5b..d42be7eed5 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -204,6 +204,7 @@ func (o *BatchGetListingsRequest) SetIds(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ids"] + t = t.(attr.TypeWithElementType).ElementType() o.Ids = types.ListValueMust(t, vs) } @@ -274,6 +275,7 @@ func (o *BatchGetListingsResponse) SetListings(ctx context.Context, v []Listing) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + t = t.(attr.TypeWithElementType).ElementType() o.Listings = types.ListValueMust(t, vs) } @@ -345,6 +347,7 @@ func (o *BatchGetProvidersRequest) SetIds(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ids"] + t = t.(attr.TypeWithElementType).ElementType() o.Ids = types.ListValueMust(t, vs) } @@ -415,6 +418,7 @@ func (o *BatchGetProvidersResponse) SetProviders(ctx context.Context, v []Provid vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["providers"] + t = t.(attr.TypeWithElementType).ElementType() o.Providers = types.ListValueMust(t, vs) } @@ -2004,6 +2008,7 @@ func (o *Exchange) SetFilters(ctx context.Context, v []ExchangeFilter) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + t = t.(attr.TypeWithElementType).ElementType() o.Filters = types.ListValueMust(t, vs) } @@ -2029,6 +2034,7 @@ func (o *Exchange) SetLinkedListings(ctx context.Context, v []ExchangeListing) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["linked_listings"] + t = t.(attr.TypeWithElementType).ElementType() o.LinkedListings = types.ListValueMust(t, vs) } @@ -2712,6 +2718,7 @@ func (o *GetListingContentMetadataResponse) SetSharedDataObjects(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["shared_data_objects"] + t = t.(attr.TypeWithElementType).ElementType() o.SharedDataObjects = types.ListValueMust(t, vs) } @@ -2945,6 +2952,7 @@ func (o *GetListingsResponse) SetListings(ctx context.Context, v []Listing) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + t = t.(attr.TypeWithElementType).ElementType() o.Listings = types.ListValueMust(t, vs) } @@ -3057,6 +3065,7 @@ func (o *GetPersonalizationRequestResponse) SetPersonalizationRequests(ctx conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["personalization_requests"] + t = t.(attr.TypeWithElementType).ElementType() o.PersonalizationRequests = types.ListValueMust(t, vs) } @@ -3388,6 +3397,7 @@ func (o *InstallationDetail) SetTokens(ctx context.Context, v []TokenInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tokens"] + t = t.(attr.TypeWithElementType).ElementType() o.Tokens = types.ListValueMust(t, vs) } @@ -3508,6 +3518,7 @@ func (o *ListAllInstallationsResponse) SetInstallations(ctx context.Context, v [ vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installations"] + t = t.(attr.TypeWithElementType).ElementType() o.Installations = types.ListValueMust(t, vs) } @@ -3628,6 +3639,7 @@ func (o *ListAllPersonalizationRequestsResponse) SetPersonalizationRequests(ctx vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["personalization_requests"] + t = t.(attr.TypeWithElementType).ElementType() o.PersonalizationRequests = types.ListValueMust(t, vs) } @@ -3752,6 +3764,7 @@ func (o *ListExchangeFiltersResponse) SetFilters(ctx context.Context, v []Exchan vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["filters"] + t = t.(attr.TypeWithElementType).ElementType() o.Filters = types.ListValueMust(t, vs) } @@ -3876,6 +3889,7 @@ func (o *ListExchangesForListingResponse) SetExchangeListing(ctx context.Context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_listing"] + t = t.(attr.TypeWithElementType).ElementType() o.ExchangeListing = types.ListValueMust(t, vs) } @@ -3996,6 +4010,7 @@ func (o *ListExchangesResponse) SetExchanges(ctx context.Context, v []Exchange) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchanges"] + t = t.(attr.TypeWithElementType).ElementType() o.Exchanges = types.ListValueMust(t, vs) } @@ -4150,6 +4165,7 @@ func (o *ListFilesResponse) SetFileInfos(ctx context.Context, v []FileInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_infos"] + t = t.(attr.TypeWithElementType).ElementType() o.FileInfos = types.ListValueMust(t, vs) } @@ -4274,6 +4290,7 @@ func (o *ListFulfillmentsResponse) SetFulfillments(ctx context.Context, v []List vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fulfillments"] + t = t.(attr.TypeWithElementType).ElementType() o.Fulfillments = types.ListValueMust(t, vs) } @@ -4398,6 +4415,7 @@ func (o *ListInstallationsResponse) SetInstallations(ctx context.Context, v []In vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["installations"] + t = t.(attr.TypeWithElementType).ElementType() o.Installations = types.ListValueMust(t, vs) } @@ -4522,6 +4540,7 @@ func (o *ListListingsForExchangeResponse) SetExchangeListings(ctx context.Contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_listings"] + t = t.(attr.TypeWithElementType).ElementType() o.ExchangeListings = types.ListValueMust(t, vs) } @@ -4635,6 +4654,7 @@ func (o *ListListingsRequest) SetAssets(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assets"] + t = t.(attr.TypeWithElementType).ElementType() o.Assets = types.ListValueMust(t, vs) } @@ -4660,6 +4680,7 @@ func (o *ListListingsRequest) SetCategories(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["categories"] + t = t.(attr.TypeWithElementType).ElementType() o.Categories = types.ListValueMust(t, vs) } @@ -4685,6 +4706,7 @@ func (o *ListListingsRequest) SetProviderIds(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.ProviderIds = types.ListValueMust(t, vs) } @@ -4710,6 +4732,7 @@ func (o *ListListingsRequest) SetTags(ctx context.Context, v []ListingTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -4784,6 +4807,7 @@ func (o *ListListingsResponse) SetListings(ctx context.Context, v []Listing) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + t = t.(attr.TypeWithElementType).ElementType() o.Listings = types.ListValueMust(t, vs) } @@ -4958,6 +4982,7 @@ func (o *ListProvidersResponse) SetProviders(ctx context.Context, v []ProviderIn vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["providers"] + t = t.(attr.TypeWithElementType).ElementType() o.Providers = types.ListValueMust(t, vs) } @@ -5234,6 +5259,7 @@ func (o *ListingDetail) SetAssets(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assets"] + t = t.(attr.TypeWithElementType).ElementType() o.Assets = types.ListValueMust(t, vs) } @@ -5285,6 +5311,7 @@ func (o *ListingDetail) SetEmbeddedNotebookFileInfos(ctx context.Context, v []Fi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedded_notebook_file_infos"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddedNotebookFileInfos = types.ListValueMust(t, vs) } @@ -5310,6 +5337,7 @@ func (o *ListingDetail) SetFileIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["file_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.FileIds = types.ListValueMust(t, vs) } @@ -5335,6 +5363,7 @@ func (o *ListingDetail) SetTags(ctx context.Context, v []ListingTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -5677,6 +5706,7 @@ func (o *ListingSummary) SetCategories(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["categories"] + t = t.(attr.TypeWithElementType).ElementType() o.Categories = types.ListValueMust(t, vs) } @@ -5702,6 +5732,7 @@ func (o *ListingSummary) SetExchangeIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exchange_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.ExchangeIds = types.ListValueMust(t, vs) } @@ -5882,6 +5913,7 @@ func (o *ListingTag) SetTagValues(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tag_values"] + t = t.(attr.TypeWithElementType).ElementType() o.TagValues = types.ListValueMust(t, vs) } @@ -6525,6 +6557,7 @@ func (o *SearchListingsRequest) SetAssets(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["assets"] + t = t.(attr.TypeWithElementType).ElementType() o.Assets = types.ListValueMust(t, vs) } @@ -6550,6 +6583,7 @@ func (o *SearchListingsRequest) SetCategories(ctx context.Context, v []types.Str vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["categories"] + t = t.(attr.TypeWithElementType).ElementType() o.Categories = types.ListValueMust(t, vs) } @@ -6575,6 +6609,7 @@ func (o *SearchListingsRequest) SetProviderIds(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["provider_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.ProviderIds = types.ListValueMust(t, vs) } @@ -6649,6 +6684,7 @@ func (o *SearchListingsResponse) SetListings(ctx context.Context, v []Listing) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["listings"] + t = t.(attr.TypeWithElementType).ElementType() o.Listings = types.ListValueMust(t, vs) } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index f582fdacf2..a6150a3c4f 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -357,6 +357,7 @@ func (o *CommentObject) SetAvailableActions(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["available_actions"] + t = t.(attr.TypeWithElementType).ElementType() o.AvailableActions = types.ListValueMust(t, vs) } @@ -563,6 +564,7 @@ func (o *CreateExperiment) SetTags(ctx context.Context, v []ExperimentTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -684,6 +686,7 @@ func (o *CreateModelRequest) SetTags(ctx context.Context, v []ModelTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -848,6 +851,7 @@ func (o *CreateModelVersionRequest) SetTags(ctx context.Context, v []ModelVersio vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -1056,6 +1060,7 @@ func (o *CreateRegistryWebhook) SetEvents(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + t = t.(attr.TypeWithElementType).ElementType() o.Events = types.ListValueMust(t, vs) } @@ -1193,6 +1198,7 @@ func (o *CreateRun) SetTags(ctx context.Context, v []RunTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -1645,6 +1651,7 @@ func (o *DatasetInput) SetTags(ctx context.Context, v []InputTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -2670,6 +2677,7 @@ func (o *Experiment) SetTags(ctx context.Context, v []ExperimentTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -2811,6 +2819,7 @@ func (o *ExperimentAccessControlResponse) SetAllPermissions(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -2889,6 +2898,7 @@ func (o *ExperimentPermission) SetInheritedFromObject(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -2967,6 +2977,7 @@ func (o *ExperimentPermissions) SetAccessControlList(ctx context.Context, v []Ex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3086,6 +3097,7 @@ func (o *ExperimentPermissionsRequest) SetAccessControlList(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3339,6 +3351,7 @@ func (o *GetExperimentPermissionLevelsResponse) SetPermissionLevels(ctx context. vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -3634,6 +3647,7 @@ func (o *GetLatestVersionsRequest) SetStages(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stages"] + t = t.(attr.TypeWithElementType).ElementType() o.Stages = types.ListValueMust(t, vs) } @@ -3707,6 +3721,7 @@ func (o *GetLatestVersionsResponse) SetModelVersions(ctx context.Context, v []Mo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.ModelVersions = types.ListValueMust(t, vs) } @@ -3783,6 +3798,7 @@ func (o *GetMetricHistoryResponse) SetMetrics(ctx context.Context, v []Metric) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + t = t.(attr.TypeWithElementType).ElementType() o.Metrics = types.ListValueMust(t, vs) } @@ -4218,6 +4234,7 @@ func (o *GetRegisteredModelPermissionLevelsResponse) SetPermissionLevels(ctx con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -4786,6 +4803,7 @@ func (o *ListArtifactsResponse) SetFiles(ctx context.Context, v []FileInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["files"] + t = t.(attr.TypeWithElementType).ElementType() o.Files = types.ListValueMust(t, vs) } @@ -4919,6 +4937,7 @@ func (o *ListExperimentsResponse) SetExperiments(ctx context.Context, v []Experi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiments"] + t = t.(attr.TypeWithElementType).ElementType() o.Experiments = types.ListValueMust(t, vs) } @@ -5041,6 +5060,7 @@ func (o *ListModelsResponse) SetRegisteredModels(ctx context.Context, v []Model) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_models"] + t = t.(attr.TypeWithElementType).ElementType() o.RegisteredModels = types.ListValueMust(t, vs) } @@ -5116,6 +5136,7 @@ func (o *ListRegistryWebhooks) SetWebhooks(ctx context.Context, v []RegistryWebh vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["webhooks"] + t = t.(attr.TypeWithElementType).ElementType() o.Webhooks = types.ListValueMust(t, vs) } @@ -5234,6 +5255,7 @@ func (o *ListTransitionRequestsResponse) SetRequests(ctx context.Context, v []Ac vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["requests"] + t = t.(attr.TypeWithElementType).ElementType() o.Requests = types.ListValueMust(t, vs) } @@ -5317,6 +5339,7 @@ func (o *ListWebhooksRequest) SetEvents(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + t = t.(attr.TypeWithElementType).ElementType() o.Events = types.ListValueMust(t, vs) } @@ -5409,6 +5432,7 @@ func (o *LogBatch) SetMetrics(ctx context.Context, v []Metric) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + t = t.(attr.TypeWithElementType).ElementType() o.Metrics = types.ListValueMust(t, vs) } @@ -5434,6 +5458,7 @@ func (o *LogBatch) SetParams(ctx context.Context, v []Param) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["params"] + t = t.(attr.TypeWithElementType).ElementType() o.Params = types.ListValueMust(t, vs) } @@ -5459,6 +5484,7 @@ func (o *LogBatch) SetTags(ctx context.Context, v []RunTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -5570,6 +5596,7 @@ func (o *LogInputs) SetDatasets(ctx context.Context, v []DatasetInput) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["datasets"] + t = t.(attr.TypeWithElementType).ElementType() o.Datasets = types.ListValueMust(t, vs) } @@ -6032,6 +6059,7 @@ func (o *Model) SetLatestVersions(ctx context.Context, v []ModelVersion) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.LatestVersions = types.ListValueMust(t, vs) } @@ -6057,6 +6085,7 @@ func (o *Model) SetTags(ctx context.Context, v []ModelTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6164,6 +6193,7 @@ func (o *ModelDatabricks) SetLatestVersions(ctx context.Context, v []ModelVersio vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.LatestVersions = types.ListValueMust(t, vs) } @@ -6189,6 +6219,7 @@ func (o *ModelDatabricks) SetTags(ctx context.Context, v []ModelTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6357,6 +6388,7 @@ func (o *ModelVersion) SetTags(ctx context.Context, v []ModelVersionTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6500,6 +6532,7 @@ func (o *ModelVersionDatabricks) SetTags(ctx context.Context, v []ModelVersionTa vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6733,6 +6766,7 @@ func (o *RegisteredModelAccessControlResponse) SetAllPermissions(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -6811,6 +6845,7 @@ func (o *RegisteredModelPermission) SetInheritedFromObject(ctx context.Context, vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -6889,6 +6924,7 @@ func (o *RegisteredModelPermissions) SetAccessControlList(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -7008,6 +7044,7 @@ func (o *RegisteredModelPermissionsRequest) SetAccessControlList(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -7156,6 +7193,7 @@ func (o *RegistryWebhook) SetEvents(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + t = t.(attr.TypeWithElementType).ElementType() o.Events = types.ListValueMust(t, vs) } @@ -7933,6 +7971,7 @@ func (o *RunData) SetMetrics(ctx context.Context, v []Metric) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["metrics"] + t = t.(attr.TypeWithElementType).ElementType() o.Metrics = types.ListValueMust(t, vs) } @@ -7958,6 +7997,7 @@ func (o *RunData) SetParams(ctx context.Context, v []Param) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["params"] + t = t.(attr.TypeWithElementType).ElementType() o.Params = types.ListValueMust(t, vs) } @@ -7983,6 +8023,7 @@ func (o *RunData) SetTags(ctx context.Context, v []RunTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -8134,6 +8175,7 @@ func (o *RunInputs) SetDatasetInputs(ctx context.Context, v []DatasetInput) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataset_inputs"] + t = t.(attr.TypeWithElementType).ElementType() o.DatasetInputs = types.ListValueMust(t, vs) } @@ -8272,6 +8314,7 @@ func (o *SearchExperiments) SetOrderBy(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + t = t.(attr.TypeWithElementType).ElementType() o.OrderBy = types.ListValueMust(t, vs) } @@ -8348,6 +8391,7 @@ func (o *SearchExperimentsResponse) SetExperiments(ctx context.Context, v []Expe vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiments"] + t = t.(attr.TypeWithElementType).ElementType() o.Experiments = types.ListValueMust(t, vs) } @@ -8436,6 +8480,7 @@ func (o *SearchModelVersionsRequest) SetOrderBy(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + t = t.(attr.TypeWithElementType).ElementType() o.OrderBy = types.ListValueMust(t, vs) } @@ -8512,6 +8557,7 @@ func (o *SearchModelVersionsResponse) SetModelVersions(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["model_versions"] + t = t.(attr.TypeWithElementType).ElementType() o.ModelVersions = types.ListValueMust(t, vs) } @@ -8600,6 +8646,7 @@ func (o *SearchModelsRequest) SetOrderBy(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + t = t.(attr.TypeWithElementType).ElementType() o.OrderBy = types.ListValueMust(t, vs) } @@ -8675,6 +8722,7 @@ func (o *SearchModelsResponse) SetRegisteredModels(ctx context.Context, v []Mode vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["registered_models"] + t = t.(attr.TypeWithElementType).ElementType() o.RegisteredModels = types.ListValueMust(t, vs) } @@ -8786,6 +8834,7 @@ func (o *SearchRuns) SetExperimentIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["experiment_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.ExperimentIds = types.ListValueMust(t, vs) } @@ -8811,6 +8860,7 @@ func (o *SearchRuns) SetOrderBy(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + t = t.(attr.TypeWithElementType).ElementType() o.OrderBy = types.ListValueMust(t, vs) } @@ -8886,6 +8936,7 @@ func (o *SearchRunsResponse) SetRuns(ctx context.Context, v []Run) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["runs"] + t = t.(attr.TypeWithElementType).ElementType() o.Runs = types.ListValueMust(t, vs) } @@ -9586,6 +9637,7 @@ func (o *TransitionRequest) SetAvailableActions(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["available_actions"] + t = t.(attr.TypeWithElementType).ElementType() o.AvailableActions = types.ListValueMust(t, vs) } @@ -10162,6 +10214,7 @@ func (o *UpdateRegistryWebhook) SetEvents(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + t = t.(attr.TypeWithElementType).ElementType() o.Events = types.ListValueMust(t, vs) } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index ad0d1d0572..3fea0e39db 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -112,6 +112,7 @@ func (o *CreateCustomAppIntegration) SetRedirectUrls(ctx context.Context, v []ty vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + t = t.(attr.TypeWithElementType).ElementType() o.RedirectUrls = types.ListValueMust(t, vs) } @@ -137,6 +138,7 @@ func (o *CreateCustomAppIntegration) SetScopes(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + t = t.(attr.TypeWithElementType).ElementType() o.Scopes = types.ListValueMust(t, vs) } @@ -837,6 +839,7 @@ func (o *GetCustomAppIntegrationOutput) SetRedirectUrls(ctx context.Context, v [ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + t = t.(attr.TypeWithElementType).ElementType() o.RedirectUrls = types.ListValueMust(t, vs) } @@ -862,6 +865,7 @@ func (o *GetCustomAppIntegrationOutput) SetScopes(ctx context.Context, v []types vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + t = t.(attr.TypeWithElementType).ElementType() o.Scopes = types.ListValueMust(t, vs) } @@ -1006,6 +1010,7 @@ func (o *GetCustomAppIntegrationsOutput) SetApps(ctx context.Context, v []GetCus vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + t = t.(attr.TypeWithElementType).ElementType() o.Apps = types.ListValueMust(t, vs) } @@ -1215,6 +1220,7 @@ func (o *GetPublishedAppIntegrationsOutput) SetApps(ctx context.Context, v []Get vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + t = t.(attr.TypeWithElementType).ElementType() o.Apps = types.ListValueMust(t, vs) } @@ -1291,6 +1297,7 @@ func (o *GetPublishedAppsOutput) SetApps(ctx context.Context, v []PublishedAppOu vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["apps"] + t = t.(attr.TypeWithElementType).ElementType() o.Apps = types.ListValueMust(t, vs) } @@ -1564,6 +1571,7 @@ func (o *ListServicePrincipalSecretsResponse) SetSecrets(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["secrets"] + t = t.(attr.TypeWithElementType).ElementType() o.Secrets = types.ListValueMust(t, vs) } @@ -1664,6 +1672,7 @@ func (o *PublishedAppOutput) SetRedirectUrls(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + t = t.(attr.TypeWithElementType).ElementType() o.RedirectUrls = types.ListValueMust(t, vs) } @@ -1689,6 +1698,7 @@ func (o *PublishedAppOutput) SetScopes(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + t = t.(attr.TypeWithElementType).ElementType() o.Scopes = types.ListValueMust(t, vs) } @@ -1875,6 +1885,7 @@ func (o *UpdateCustomAppIntegration) SetRedirectUrls(ctx context.Context, v []ty vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["redirect_urls"] + t = t.(attr.TypeWithElementType).ElementType() o.RedirectUrls = types.ListValueMust(t, vs) } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 5f423bd51a..122d37780f 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -222,6 +222,7 @@ func (o *CreatePipeline) SetClusters(ctx context.Context, v []PipelineCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.Clusters = types.ListValueMust(t, vs) } @@ -247,6 +248,7 @@ func (o *CreatePipeline) SetConfiguration(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration"] + t = t.(attr.TypeWithElementType).ElementType() o.Configuration = types.MapValueMust(t, vs) } @@ -376,6 +378,7 @@ func (o *CreatePipeline) SetLibraries(ctx context.Context, v []PipelineLibrary) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -401,6 +404,7 @@ func (o *CreatePipeline) SetNotifications(ctx context.Context, v []Notifications vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + t = t.(attr.TypeWithElementType).ElementType() o.Notifications = types.ListValueMust(t, vs) } @@ -909,6 +913,7 @@ func (o *EditPipeline) SetClusters(ctx context.Context, v []PipelineCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.Clusters = types.ListValueMust(t, vs) } @@ -934,6 +939,7 @@ func (o *EditPipeline) SetConfiguration(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration"] + t = t.(attr.TypeWithElementType).ElementType() o.Configuration = types.MapValueMust(t, vs) } @@ -1063,6 +1069,7 @@ func (o *EditPipeline) SetLibraries(ctx context.Context, v []PipelineLibrary) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -1088,6 +1095,7 @@ func (o *EditPipeline) SetNotifications(ctx context.Context, v []Notifications) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + t = t.(attr.TypeWithElementType).ElementType() o.Notifications = types.ListValueMust(t, vs) } @@ -1251,6 +1259,7 @@ func (o *ErrorDetail) SetExceptions(ctx context.Context, v []SerializedException vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exceptions"] + t = t.(attr.TypeWithElementType).ElementType() o.Exceptions = types.ListValueMust(t, vs) } @@ -1371,6 +1380,7 @@ func (o *Filters) SetExclude(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["exclude"] + t = t.(attr.TypeWithElementType).ElementType() o.Exclude = types.ListValueMust(t, vs) } @@ -1396,6 +1406,7 @@ func (o *Filters) SetInclude(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["include"] + t = t.(attr.TypeWithElementType).ElementType() o.Include = types.ListValueMust(t, vs) } @@ -1510,6 +1521,7 @@ func (o *GetPipelinePermissionLevelsResponse) SetPermissionLevels(ctx context.Co vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -1715,6 +1727,7 @@ func (o *GetPipelineResponse) SetLatestUpdates(ctx context.Context, v []UpdateSt vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_updates"] + t = t.(attr.TypeWithElementType).ElementType() o.LatestUpdates = types.ListValueMust(t, vs) } @@ -2156,6 +2169,7 @@ func (o *IngestionPipelineDefinition) SetObjects(ctx context.Context, v []Ingest vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["objects"] + t = t.(attr.TypeWithElementType).ElementType() o.Objects = types.ListValueMust(t, vs) } @@ -2283,6 +2297,7 @@ func (o *ListPipelineEventsRequest) SetOrderBy(ctx context.Context, v []types.St vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + t = t.(attr.TypeWithElementType).ElementType() o.OrderBy = types.ListValueMust(t, vs) } @@ -2362,6 +2377,7 @@ func (o *ListPipelineEventsResponse) SetEvents(ctx context.Context, v []Pipeline vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["events"] + t = t.(attr.TypeWithElementType).ElementType() o.Events = types.ListValueMust(t, vs) } @@ -2459,6 +2475,7 @@ func (o *ListPipelinesRequest) SetOrderBy(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["order_by"] + t = t.(attr.TypeWithElementType).ElementType() o.OrderBy = types.ListValueMust(t, vs) } @@ -2534,6 +2551,7 @@ func (o *ListPipelinesResponse) SetStatuses(ctx context.Context, v []PipelineSta vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statuses"] + t = t.(attr.TypeWithElementType).ElementType() o.Statuses = types.ListValueMust(t, vs) } @@ -2670,6 +2688,7 @@ func (o *ListUpdatesResponse) SetUpdates(ctx context.Context, v []UpdateInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["updates"] + t = t.(attr.TypeWithElementType).ElementType() o.Updates = types.ListValueMust(t, vs) } @@ -2832,6 +2851,7 @@ func (o *Notifications) SetAlerts(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["alerts"] + t = t.(attr.TypeWithElementType).ElementType() o.Alerts = types.ListValueMust(t, vs) } @@ -2857,6 +2877,7 @@ func (o *Notifications) SetEmailRecipients(ctx context.Context, v []types.String vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["email_recipients"] + t = t.(attr.TypeWithElementType).ElementType() o.EmailRecipients = types.ListValueMust(t, vs) } @@ -3105,6 +3126,7 @@ func (o *PipelineAccessControlResponse) SetAllPermissions(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -3435,6 +3457,7 @@ func (o *PipelineCluster) SetCustomTags(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -3486,6 +3509,7 @@ func (o *PipelineCluster) SetInitScripts(ctx context.Context, v []compute_tf.Ini vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["init_scripts"] + t = t.(attr.TypeWithElementType).ElementType() o.InitScripts = types.ListValueMust(t, vs) } @@ -3511,6 +3535,7 @@ func (o *PipelineCluster) SetSparkConf(ctx context.Context, v map[string]types.S vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_conf"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkConf = types.MapValueMust(t, vs) } @@ -3536,6 +3561,7 @@ func (o *PipelineCluster) SetSparkEnvVars(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["spark_env_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.SparkEnvVars = types.MapValueMust(t, vs) } @@ -3561,6 +3587,7 @@ func (o *PipelineCluster) SetSshPublicKeys(ctx context.Context, v []types.String vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ssh_public_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.SshPublicKeys = types.ListValueMust(t, vs) } @@ -4052,6 +4079,7 @@ func (o *PipelinePermission) SetInheritedFromObject(ctx context.Context, v []typ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -4130,6 +4158,7 @@ func (o *PipelinePermissions) SetAccessControlList(ctx context.Context, v []Pipe vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -4249,6 +4278,7 @@ func (o *PipelinePermissionsRequest) SetAccessControlList(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -4444,6 +4474,7 @@ func (o *PipelineSpec) SetClusters(ctx context.Context, v []PipelineCluster) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["clusters"] + t = t.(attr.TypeWithElementType).ElementType() o.Clusters = types.ListValueMust(t, vs) } @@ -4469,6 +4500,7 @@ func (o *PipelineSpec) SetConfiguration(ctx context.Context, v map[string]types. vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration"] + t = t.(attr.TypeWithElementType).ElementType() o.Configuration = types.MapValueMust(t, vs) } @@ -4598,6 +4630,7 @@ func (o *PipelineSpec) SetLibraries(ctx context.Context, v []PipelineLibrary) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["libraries"] + t = t.(attr.TypeWithElementType).ElementType() o.Libraries = types.ListValueMust(t, vs) } @@ -4623,6 +4656,7 @@ func (o *PipelineSpec) SetNotifications(ctx context.Context, v []Notifications) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["notifications"] + t = t.(attr.TypeWithElementType).ElementType() o.Notifications = types.ListValueMust(t, vs) } @@ -4776,6 +4810,7 @@ func (o *PipelineStateInfo) SetLatestUpdates(ctx context.Context, v []UpdateStat vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["latest_updates"] + t = t.(attr.TypeWithElementType).ElementType() o.LatestUpdates = types.ListValueMust(t, vs) } @@ -5275,6 +5310,7 @@ func (o *SerializedException) SetStack(ctx context.Context, v []StackFrame) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stack"] + t = t.(attr.TypeWithElementType).ElementType() o.Stack = types.ListValueMust(t, vs) } @@ -5429,6 +5465,7 @@ func (o *StartUpdate) SetFullRefreshSelection(ctx context.Context, v []types.Str vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["full_refresh_selection"] + t = t.(attr.TypeWithElementType).ElementType() o.FullRefreshSelection = types.ListValueMust(t, vs) } @@ -5454,6 +5491,7 @@ func (o *StartUpdate) SetRefreshSelection(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["refresh_selection"] + t = t.(attr.TypeWithElementType).ElementType() o.RefreshSelection = types.ListValueMust(t, vs) } @@ -5762,6 +5800,7 @@ func (o *TableSpecificConfig) SetPrimaryKeys(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.PrimaryKeys = types.ListValueMust(t, vs) } @@ -5787,6 +5826,7 @@ func (o *TableSpecificConfig) SetSequenceBy(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sequence_by"] + t = t.(attr.TypeWithElementType).ElementType() o.SequenceBy = types.ListValueMust(t, vs) } @@ -5938,6 +5978,7 @@ func (o *UpdateInfo) SetFullRefreshSelection(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["full_refresh_selection"] + t = t.(attr.TypeWithElementType).ElementType() o.FullRefreshSelection = types.ListValueMust(t, vs) } @@ -5963,6 +6004,7 @@ func (o *UpdateInfo) SetRefreshSelection(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["refresh_selection"] + t = t.(attr.TypeWithElementType).ElementType() o.RefreshSelection = types.ListValueMust(t, vs) } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 758abbc096..1990d3bb1f 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -642,6 +642,7 @@ func (o *CreateCustomerManagedKeyRequest) SetUseCases(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["use_cases"] + t = t.(attr.TypeWithElementType).ElementType() o.UseCases = types.ListValueMust(t, vs) } @@ -817,6 +818,7 @@ func (o *CreateNetworkRequest) SetSecurityGroupIds(ctx context.Context, v []type vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["security_group_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.SecurityGroupIds = types.ListValueMust(t, vs) } @@ -842,6 +844,7 @@ func (o *CreateNetworkRequest) SetSubnetIds(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subnet_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.SubnetIds = types.ListValueMust(t, vs) } @@ -1275,6 +1278,7 @@ func (o *CreateWorkspaceRequest) SetCustomTags(ctx context.Context, v map[string vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -1608,6 +1612,7 @@ func (o *CustomerManagedKey) SetUseCases(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["use_cases"] + t = t.(attr.TypeWithElementType).ElementType() o.UseCases = types.ListValueMust(t, vs) } @@ -2743,6 +2748,7 @@ func (o *Network) SetErrorMessages(ctx context.Context, v []NetworkHealth) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["error_messages"] + t = t.(attr.TypeWithElementType).ElementType() o.ErrorMessages = types.ListValueMust(t, vs) } @@ -2794,6 +2800,7 @@ func (o *Network) SetSecurityGroupIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["security_group_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.SecurityGroupIds = types.ListValueMust(t, vs) } @@ -2819,6 +2826,7 @@ func (o *Network) SetSubnetIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subnet_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.SubnetIds = types.ListValueMust(t, vs) } @@ -2870,6 +2878,7 @@ func (o *Network) SetWarningMessages(ctx context.Context, v []NetworkWarning) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["warning_messages"] + t = t.(attr.TypeWithElementType).ElementType() o.WarningMessages = types.ListValueMust(t, vs) } @@ -3001,6 +3010,7 @@ func (o *NetworkVpcEndpoints) SetDataplaneRelay(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataplane_relay"] + t = t.(attr.TypeWithElementType).ElementType() o.DataplaneRelay = types.ListValueMust(t, vs) } @@ -3026,6 +3036,7 @@ func (o *NetworkVpcEndpoints) SetRestApi(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rest_api"] + t = t.(attr.TypeWithElementType).ElementType() o.RestApi = types.ListValueMust(t, vs) } @@ -3178,6 +3189,7 @@ func (o *PrivateAccessSettings) SetAllowedVpcEndpointIds(ctx context.Context, v vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["allowed_vpc_endpoint_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.AllowedVpcEndpointIds = types.ListValueMust(t, vs) } @@ -3547,6 +3559,7 @@ func (o *UpdateWorkspaceRequest) SetCustomTags(ctx context.Context, v map[string vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } @@ -3661,6 +3674,7 @@ func (o *UpsertPrivateAccessSettingsRequest) SetAllowedVpcEndpointIds(ctx contex vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["allowed_vpc_endpoint_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.AllowedVpcEndpointIds = types.ListValueMust(t, vs) } @@ -4063,6 +4077,7 @@ func (o *Workspace) SetCustomTags(ctx context.Context, v map[string]types.String vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.MapValueMust(t, vs) } diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index c22de9e2a8..24cf077582 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -219,6 +219,7 @@ func (o *AiGatewayConfig) SetRateLimits(ctx context.Context, v []AiGatewayRateLi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + t = t.(attr.TypeWithElementType).ElementType() o.RateLimits = types.ListValueMust(t, vs) } @@ -336,6 +337,7 @@ func (o *AiGatewayGuardrailParameters) SetInvalidKeywords(ctx context.Context, v vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["invalid_keywords"] + t = t.(attr.TypeWithElementType).ElementType() o.InvalidKeywords = types.ListValueMust(t, vs) } @@ -387,6 +389,7 @@ func (o *AiGatewayGuardrailParameters) SetValidTopics(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["valid_topics"] + t = t.(attr.TypeWithElementType).ElementType() o.ValidTopics = types.ListValueMust(t, vs) } @@ -1393,6 +1396,7 @@ func (o *CreateServingEndpoint) SetRateLimits(ctx context.Context, v []RateLimit vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + t = t.(attr.TypeWithElementType).ElementType() o.RateLimits = types.ListValueMust(t, vs) } @@ -1418,6 +1422,7 @@ func (o *CreateServingEndpoint) SetTags(ctx context.Context, v []EndpointTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -1563,6 +1568,7 @@ func (o *DataframeSplitInput) SetColumns(ctx context.Context, v []types.Object) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + t = t.(attr.TypeWithElementType).ElementType() o.Columns = types.ListValueMust(t, vs) } @@ -1588,6 +1594,7 @@ func (o *DataframeSplitInput) SetData(ctx context.Context, v []types.Object) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + t = t.(attr.TypeWithElementType).ElementType() o.Data = types.ListValueMust(t, vs) } @@ -1613,6 +1620,7 @@ func (o *DataframeSplitInput) SetIndex(ctx context.Context, v []types.Int64) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["index"] + t = t.(attr.TypeWithElementType).ElementType() o.Index = types.ListValueMust(t, vs) } @@ -1770,6 +1778,7 @@ func (o *EmbeddingsV1ResponseEmbeddingElement) SetEmbedding(ctx context.Context, vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding"] + t = t.(attr.TypeWithElementType).ElementType() o.Embedding = types.ListValueMust(t, vs) } @@ -1896,6 +1905,7 @@ func (o *EndpointCoreConfigInput) SetServedEntities(ctx context.Context, v []Ser vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedEntities = types.ListValueMust(t, vs) } @@ -1921,6 +1931,7 @@ func (o *EndpointCoreConfigInput) SetServedModels(ctx context.Context, v []Serve vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedModels = types.ListValueMust(t, vs) } @@ -2071,6 +2082,7 @@ func (o *EndpointCoreConfigOutput) SetServedEntities(ctx context.Context, v []Se vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedEntities = types.ListValueMust(t, vs) } @@ -2096,6 +2108,7 @@ func (o *EndpointCoreConfigOutput) SetServedModels(ctx context.Context, v []Serv vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedModels = types.ListValueMust(t, vs) } @@ -2201,6 +2214,7 @@ func (o *EndpointCoreConfigSummary) SetServedEntities(ctx context.Context, v []S vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedEntities = types.ListValueMust(t, vs) } @@ -2226,6 +2240,7 @@ func (o *EndpointCoreConfigSummary) SetServedModels(ctx context.Context, v []Ser vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedModels = types.ListValueMust(t, vs) } @@ -2356,6 +2371,7 @@ func (o *EndpointPendingConfig) SetServedEntities(ctx context.Context, v []Serve vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_entities"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedEntities = types.ListValueMust(t, vs) } @@ -2381,6 +2397,7 @@ func (o *EndpointPendingConfig) SetServedModels(ctx context.Context, v []ServedM vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["served_models"] + t = t.(attr.TypeWithElementType).ElementType() o.ServedModels = types.ListValueMust(t, vs) } @@ -3211,6 +3228,7 @@ func (o *GetServingEndpointPermissionLevelsResponse) SetPermissionLevels(ctx con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -3441,6 +3459,7 @@ func (o *ListEndpointsResponse) SetEndpoints(ctx context.Context, v []ServingEnd vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["endpoints"] + t = t.(attr.TypeWithElementType).ElementType() o.Endpoints = types.ListValueMust(t, vs) } @@ -3808,6 +3827,7 @@ func (o *PatchServingEndpointTags) SetAddTags(ctx context.Context, v []EndpointT vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["add_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.AddTags = types.ListValueMust(t, vs) } @@ -3833,6 +3853,7 @@ func (o *PatchServingEndpointTags) SetDeleteTags(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["delete_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.DeleteTags = types.ListValueMust(t, vs) } @@ -4038,6 +4059,7 @@ func (o *PutAiGatewayRequest) SetRateLimits(ctx context.Context, v []AiGatewayRa vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + t = t.(attr.TypeWithElementType).ElementType() o.RateLimits = types.ListValueMust(t, vs) } @@ -4213,6 +4235,7 @@ func (o *PutAiGatewayResponse) SetRateLimits(ctx context.Context, v []AiGatewayR vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + t = t.(attr.TypeWithElementType).ElementType() o.RateLimits = types.ListValueMust(t, vs) } @@ -4316,6 +4339,7 @@ func (o *PutRequest) SetRateLimits(ctx context.Context, v []RateLimit) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + t = t.(attr.TypeWithElementType).ElementType() o.RateLimits = types.ListValueMust(t, vs) } @@ -4387,6 +4411,7 @@ func (o *PutResponse) SetRateLimits(ctx context.Context, v []RateLimit) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["rate_limits"] + t = t.(attr.TypeWithElementType).ElementType() o.RateLimits = types.ListValueMust(t, vs) } @@ -4546,6 +4571,7 @@ func (o *QueryEndpointInput) SetDataframeRecords(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["dataframe_records"] + t = t.(attr.TypeWithElementType).ElementType() o.DataframeRecords = types.ListValueMust(t, vs) } @@ -4597,6 +4623,7 @@ func (o *QueryEndpointInput) SetExtraParams(ctx context.Context, v map[string]ty vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["extra_params"] + t = t.(attr.TypeWithElementType).ElementType() o.ExtraParams = types.MapValueMust(t, vs) } @@ -4622,6 +4649,7 @@ func (o *QueryEndpointInput) SetInstances(ctx context.Context, v []types.Object) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["instances"] + t = t.(attr.TypeWithElementType).ElementType() o.Instances = types.ListValueMust(t, vs) } @@ -4647,6 +4675,7 @@ func (o *QueryEndpointInput) SetMessages(ctx context.Context, v []ChatMessage) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["messages"] + t = t.(attr.TypeWithElementType).ElementType() o.Messages = types.ListValueMust(t, vs) } @@ -4672,6 +4701,7 @@ func (o *QueryEndpointInput) SetStop(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["stop"] + t = t.(attr.TypeWithElementType).ElementType() o.Stop = types.ListValueMust(t, vs) } @@ -4794,6 +4824,7 @@ func (o *QueryEndpointResponse) SetChoices(ctx context.Context, v []V1ResponseCh vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["choices"] + t = t.(attr.TypeWithElementType).ElementType() o.Choices = types.ListValueMust(t, vs) } @@ -4819,6 +4850,7 @@ func (o *QueryEndpointResponse) SetData(ctx context.Context, v []EmbeddingsV1Res vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + t = t.(attr.TypeWithElementType).ElementType() o.Data = types.ListValueMust(t, vs) } @@ -4844,6 +4876,7 @@ func (o *QueryEndpointResponse) SetPredictions(ctx context.Context, v []types.Ob vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["predictions"] + t = t.(attr.TypeWithElementType).ElementType() o.Predictions = types.ListValueMust(t, vs) } @@ -5121,6 +5154,7 @@ func (o *ServedEntityInput) SetEnvironmentVars(ctx context.Context, v map[string vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.EnvironmentVars = types.MapValueMust(t, vs) } @@ -5313,6 +5347,7 @@ func (o *ServedEntityOutput) SetEnvironmentVars(ctx context.Context, v map[strin vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.EnvironmentVars = types.MapValueMust(t, vs) } @@ -5649,6 +5684,7 @@ func (o *ServedModelInput) SetEnvironmentVars(ctx context.Context, v map[string] vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.EnvironmentVars = types.MapValueMust(t, vs) } @@ -5784,6 +5820,7 @@ func (o *ServedModelOutput) SetEnvironmentVars(ctx context.Context, v map[string vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["environment_vars"] + t = t.(attr.TypeWithElementType).ElementType() o.EnvironmentVars = types.MapValueMust(t, vs) } @@ -6158,6 +6195,7 @@ func (o *ServingEndpoint) SetTags(ctx context.Context, v []EndpointTag) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6299,6 +6337,7 @@ func (o *ServingEndpointAccessControlResponse) SetAllPermissions(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -6574,6 +6613,7 @@ func (o *ServingEndpointDetailed) SetTags(ctx context.Context, v []EndpointTag) vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6652,6 +6692,7 @@ func (o *ServingEndpointPermission) SetInheritedFromObject(ctx context.Context, vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -6730,6 +6771,7 @@ func (o *ServingEndpointPermissions) SetAccessControlList(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -6849,6 +6891,7 @@ func (o *ServingEndpointPermissionsRequest) SetAccessControlList(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -6920,6 +6963,7 @@ func (o *TrafficConfig) SetRoutes(ctx context.Context, v []Route) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["routes"] + t = t.(attr.TypeWithElementType).ElementType() o.Routes = types.ListValueMust(t, vs) } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 70d3e38bc2..92fb1d94cf 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -217,6 +217,7 @@ func (o *AibiDashboardEmbeddingApprovedDomains) SetApprovedDomains(ctx context.C vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["approved_domains"] + t = t.(attr.TypeWithElementType).ElementType() o.ApprovedDomains = types.ListValueMust(t, vs) } @@ -885,6 +886,7 @@ func (o *ComplianceSecurityProfile) SetComplianceStandards(ctx context.Context, vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_standards"] + t = t.(attr.TypeWithElementType).ElementType() o.ComplianceStandards = types.ListValueMust(t, vs) } @@ -1262,6 +1264,7 @@ func (o *CreateIpAccessList) SetIpAddresses(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.IpAddresses = types.ListValueMust(t, vs) } @@ -1843,6 +1846,7 @@ func (o *CspEnablementAccount) SetComplianceStandards(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_standards"] + t = t.(attr.TypeWithElementType).ElementType() o.ComplianceStandards = types.ListValueMust(t, vs) } @@ -3291,6 +3295,7 @@ func (o *EmailConfig) SetAddresses(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.Addresses = types.ListValueMust(t, vs) } @@ -3680,6 +3685,7 @@ func (o *ExchangeToken) SetScopes(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + t = t.(attr.TypeWithElementType).ElementType() o.Scopes = types.ListValueMust(t, vs) } @@ -3792,6 +3798,7 @@ func (o *ExchangeTokenRequest) SetScopes(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + t = t.(attr.TypeWithElementType).ElementType() o.Scopes = types.ListValueMust(t, vs) } @@ -3817,6 +3824,7 @@ func (o *ExchangeTokenRequest) SetTokenType(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tokenType"] + t = t.(attr.TypeWithElementType).ElementType() o.TokenType = types.ListValueMust(t, vs) } @@ -3888,6 +3896,7 @@ func (o *ExchangeTokenResponse) SetValues(ctx context.Context, v []ExchangeToken vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -4791,6 +4800,7 @@ func (o *GetIpAccessListsResponse) SetIpAccessLists(ctx context.Context, v []IpA vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_lists"] + t = t.(attr.TypeWithElementType).ElementType() o.IpAccessLists = types.ListValueMust(t, vs) } @@ -5177,6 +5187,7 @@ func (o *GetTokenPermissionLevelsResponse) SetPermissionLevels(ctx context.Conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -5362,6 +5373,7 @@ func (o *IpAccessListInfo) SetIpAddresses(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.IpAddresses = types.ListValueMust(t, vs) } @@ -5433,6 +5445,7 @@ func (o *ListIpAccessListResponse) SetIpAccessLists(ctx context.Context, v []IpA vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_access_lists"] + t = t.(attr.TypeWithElementType).ElementType() o.IpAccessLists = types.ListValueMust(t, vs) } @@ -5508,6 +5521,7 @@ func (o *ListNccAzurePrivateEndpointRulesResponse) SetItems(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["items"] + t = t.(attr.TypeWithElementType).ElementType() o.Items = types.ListValueMust(t, vs) } @@ -5626,6 +5640,7 @@ func (o *ListNetworkConnectivityConfigurationsResponse) SetItems(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["items"] + t = t.(attr.TypeWithElementType).ElementType() o.Items = types.ListValueMust(t, vs) } @@ -5747,6 +5762,7 @@ func (o *ListNotificationDestinationsResponse) SetResults(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -5916,6 +5932,7 @@ func (o *ListPublicTokensResponse) SetTokenInfos(ctx context.Context, v []Public vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_infos"] + t = t.(attr.TypeWithElementType).ElementType() o.TokenInfos = types.ListValueMust(t, vs) } @@ -6035,6 +6052,7 @@ func (o *ListTokensResponse) SetTokenInfos(ctx context.Context, v []TokenInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["token_infos"] + t = t.(attr.TypeWithElementType).ElementType() o.TokenInfos = types.ListValueMust(t, vs) } @@ -6155,6 +6173,7 @@ func (o *NccAwsStableIpRule) SetCidrBlocks(ctx context.Context, v []types.String vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["cidr_blocks"] + t = t.(attr.TypeWithElementType).ElementType() o.CidrBlocks = types.ListValueMust(t, vs) } @@ -6334,6 +6353,7 @@ func (o *NccAzureServiceEndpointRule) SetSubnets(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["subnets"] + t = t.(attr.TypeWithElementType).ElementType() o.Subnets = types.ListValueMust(t, vs) } @@ -6359,6 +6379,7 @@ func (o *NccAzureServiceEndpointRule) SetTargetServices(ctx context.Context, v [ vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["target_services"] + t = t.(attr.TypeWithElementType).ElementType() o.TargetServices = types.ListValueMust(t, vs) } @@ -6653,6 +6674,7 @@ func (o *NccEgressTargetRules) SetAzurePrivateEndpointRules(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["azure_private_endpoint_rules"] + t = t.(attr.TypeWithElementType).ElementType() o.AzurePrivateEndpointRules = types.ListValueMust(t, vs) } @@ -7217,6 +7239,7 @@ func (o *ReplaceIpAccessList) SetIpAddresses(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.IpAddresses = types.ListValueMust(t, vs) } @@ -7727,6 +7750,7 @@ func (o *TokenAccessControlResponse) SetAllPermissions(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -7881,6 +7905,7 @@ func (o *TokenPermission) SetInheritedFromObject(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -7959,6 +7984,7 @@ func (o *TokenPermissions) SetAccessControlList(ctx context.Context, v []TokenAc vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -8074,6 +8100,7 @@ func (o *TokenPermissionsRequest) SetAccessControlList(ctx context.Context, v [] vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -9110,6 +9137,7 @@ func (o *UpdateIpAccessList) SetIpAddresses(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["ip_addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.IpAddresses = types.ListValueMust(t, vs) } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 1e75135dde..d8b772b951 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -667,6 +667,7 @@ func (o *GetRecipientSharePermissionsResponse) SetPermissionsOut(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permissions_out"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionsOut = types.ListValueMust(t, vs) } @@ -785,6 +786,7 @@ func (o *IpAccessList) SetAllowedIpAddresses(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["allowed_ip_addresses"] + t = t.(attr.TypeWithElementType).ElementType() o.AllowedIpAddresses = types.ListValueMust(t, vs) } @@ -862,6 +864,7 @@ func (o *ListProviderSharesResponse) SetShares(ctx context.Context, v []Provider vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["shares"] + t = t.(attr.TypeWithElementType).ElementType() o.Shares = types.ListValueMust(t, vs) } @@ -999,6 +1002,7 @@ func (o *ListProvidersResponse) SetProviders(ctx context.Context, v []ProviderIn vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["providers"] + t = t.(attr.TypeWithElementType).ElementType() o.Providers = types.ListValueMust(t, vs) } @@ -1136,6 +1140,7 @@ func (o *ListRecipientsResponse) SetRecipients(ctx context.Context, v []Recipien vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["recipients"] + t = t.(attr.TypeWithElementType).ElementType() o.Recipients = types.ListValueMust(t, vs) } @@ -1272,6 +1277,7 @@ func (o *ListSharesResponse) SetShares(ctx context.Context, v []ShareInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["shares"] + t = t.(attr.TypeWithElementType).ElementType() o.Shares = types.ListValueMust(t, vs) } @@ -1343,6 +1349,7 @@ func (o *Partition) SetValues(ctx context.Context, v []PartitionValue) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["value"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -1476,6 +1483,7 @@ func (o *PrivilegeAssignment) SetPrivileges(ctx context.Context, v []types.Strin vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privileges"] + t = t.(attr.TypeWithElementType).ElementType() o.Privileges = types.ListValueMust(t, vs) } @@ -1855,6 +1863,7 @@ func (o *RecipientInfo) SetTokens(ctx context.Context, v []RecipientTokenInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tokens"] + t = t.(attr.TypeWithElementType).ElementType() o.Tokens = types.ListValueMust(t, vs) } @@ -2191,6 +2200,7 @@ func (o *SecurablePropertiesKvPairs) SetProperties(ctx context.Context, v map[st vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["properties"] + t = t.(attr.TypeWithElementType).ElementType() o.Properties = types.MapValueMust(t, vs) } @@ -2298,6 +2308,7 @@ func (o *ShareInfo) SetObjects(ctx context.Context, v []SharedDataObject) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["object"] + t = t.(attr.TypeWithElementType).ElementType() o.Objects = types.ListValueMust(t, vs) } @@ -2432,6 +2443,7 @@ func (o *ShareToPrivilegeAssignment) SetPrivilegeAssignments(ctx context.Context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["privilege_assignments"] + t = t.(attr.TypeWithElementType).ElementType() o.PrivilegeAssignments = types.ListValueMust(t, vs) } @@ -2572,6 +2584,7 @@ func (o *SharedDataObject) SetPartitions(ctx context.Context, v []Partition) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["partition"] + t = t.(attr.TypeWithElementType).ElementType() o.Partitions = types.ListValueMust(t, vs) } @@ -2998,6 +3011,7 @@ func (o *UpdateShare) SetUpdates(ctx context.Context, v []SharedDataObjectUpdate vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["updates"] + t = t.(attr.TypeWithElementType).ElementType() o.Updates = types.ListValueMust(t, vs) } @@ -3089,5 +3103,6 @@ func (o *UpdateSharePermissions) SetChanges(ctx context.Context, v []catalog_tf. vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["changes"] + t = t.(attr.TypeWithElementType).ElementType() o.Changes = types.ListValueMust(t, vs) } diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 485ed75065..3fc002ee63 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -792,6 +792,7 @@ func (o *AlertQuery) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -1550,6 +1551,7 @@ func (o *CreateQueryRequestQuery) SetParameters(ctx context.Context, v []QueryPa vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -1575,6 +1577,7 @@ func (o *CreateQueryRequestQuery) SetTags(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -2273,6 +2276,7 @@ func (o *Dashboard) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -2324,6 +2328,7 @@ func (o *Dashboard) SetWidgets(ctx context.Context, v []Widget) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["widgets"] + t = t.(attr.TypeWithElementType).ElementType() o.Widgets = types.ListValueMust(t, vs) } @@ -2409,6 +2414,7 @@ func (o *DashboardEditContent) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -2548,6 +2554,7 @@ func (o *DashboardPostContent) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -4047,6 +4054,7 @@ func (o *EndpointTags) SetCustomTags(ctx context.Context, v []EndpointTagPair) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["custom_tags"] + t = t.(attr.TypeWithElementType).ElementType() o.CustomTags = types.ListValueMust(t, vs) } @@ -4155,6 +4163,7 @@ func (o *EnumValue) SetValues(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -4367,6 +4376,7 @@ func (o *ExecuteStatementRequest) SetParameters(ctx context.Context, v []Stateme vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -4482,6 +4492,7 @@ func (o *ExternalLink) SetHttpHeaders(ctx context.Context, v map[string]types.St vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["http_headers"] + t = t.(attr.TypeWithElementType).ElementType() o.HttpHeaders = types.MapValueMust(t, vs) } @@ -4817,6 +4828,7 @@ func (o *GetResponse) SetAccessControlList(ctx context.Context, v []AccessContro vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -5022,6 +5034,7 @@ func (o *GetWarehousePermissionLevelsResponse) SetPermissionLevels(ctx context.C vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -5554,6 +5567,7 @@ func (o *GetWorkspaceWarehouseConfigResponse) SetDataAccessConfig(ctx context.Co vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_access_config"] + t = t.(attr.TypeWithElementType).ElementType() o.DataAccessConfig = types.ListValueMust(t, vs) } @@ -5579,6 +5593,7 @@ func (o *GetWorkspaceWarehouseConfigResponse) SetEnabledWarehouseTypes(ctx conte vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enabled_warehouse_types"] + t = t.(attr.TypeWithElementType).ElementType() o.EnabledWarehouseTypes = types.ListValueMust(t, vs) } @@ -6052,6 +6067,7 @@ func (o *LegacyQuery) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -6103,6 +6119,7 @@ func (o *LegacyQuery) SetVisualizations(ctx context.Context, v []LegacyVisualiza vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["visualizations"] + t = t.(attr.TypeWithElementType).ElementType() o.Visualizations = types.ListValueMust(t, vs) } @@ -6331,6 +6348,7 @@ func (o *ListAlertsResponse) SetResults(ctx context.Context, v []ListAlertsRespo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -6716,6 +6734,7 @@ func (o *ListQueriesResponse) SetRes(ctx context.Context, v []QueryInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["res"] + t = t.(attr.TypeWithElementType).ElementType() o.Res = types.ListValueMust(t, vs) } @@ -6880,6 +6899,7 @@ func (o *ListQueryObjectsResponse) SetResults(ctx context.Context, v []ListQuery vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -7016,6 +7036,7 @@ func (o *ListQueryObjectsResponseQuery) SetParameters(ctx context.Context, v []Q vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -7041,6 +7062,7 @@ func (o *ListQueryObjectsResponseQuery) SetTags(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -7124,6 +7146,7 @@ func (o *ListResponse) SetResults(ctx context.Context, v []Dashboard) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -7248,6 +7271,7 @@ func (o *ListVisualizationsForQueryResponse) SetResults(ctx context.Context, v [ vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -7363,6 +7387,7 @@ func (o *ListWarehousesResponse) SetWarehouses(ctx context.Context, v []Endpoint vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["warehouses"] + t = t.(attr.TypeWithElementType).ElementType() o.Warehouses = types.ListValueMust(t, vs) } @@ -7748,6 +7773,7 @@ func (o *Query) SetParameters(ctx context.Context, v []QueryParameter) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -7773,6 +7799,7 @@ func (o *Query) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -7881,6 +7908,7 @@ func (o *QueryBackedValue) SetValues(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -7989,6 +8017,7 @@ func (o *QueryEditContent) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -8115,6 +8144,7 @@ func (o *QueryFilter) SetStatementIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statement_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.StatementIds = types.ListValueMust(t, vs) } @@ -8140,6 +8170,7 @@ func (o *QueryFilter) SetStatuses(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["statuses"] + t = t.(attr.TypeWithElementType).ElementType() o.Statuses = types.ListValueMust(t, vs) } @@ -8165,6 +8196,7 @@ func (o *QueryFilter) SetUserIds(ctx context.Context, v []types.Int64) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["user_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.UserIds = types.ListValueMust(t, vs) } @@ -8190,6 +8222,7 @@ func (o *QueryFilter) SetWarehouseIds(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["warehouse_ids"] + t = t.(attr.TypeWithElementType).ElementType() o.WarehouseIds = types.ListValueMust(t, vs) } @@ -8463,6 +8496,7 @@ func (o *QueryList) SetResults(ctx context.Context, v []LegacyQuery) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["results"] + t = t.(attr.TypeWithElementType).ElementType() o.Results = types.ListValueMust(t, vs) } @@ -8688,6 +8722,7 @@ func (o *QueryOptions) SetParameters(ctx context.Context, v []Parameter) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -9044,6 +9079,7 @@ func (o *QueryPostContent) SetTags(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -9122,6 +9158,7 @@ func (o *RepeatedEndpointConfPairs) SetConfigPair(ctx context.Context, v []Endpo vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["config_pair"] + t = t.(attr.TypeWithElementType).ElementType() o.ConfigPair = types.ListValueMust(t, vs) } @@ -9147,6 +9184,7 @@ func (o *RepeatedEndpointConfPairs) SetConfigurationPairs(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["configuration_pairs"] + t = t.(attr.TypeWithElementType).ElementType() o.ConfigurationPairs = types.ListValueMust(t, vs) } @@ -9379,6 +9417,7 @@ func (o *ResultData) SetDataArray(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_array"] + t = t.(attr.TypeWithElementType).ElementType() o.DataArray = types.ListValueMust(t, vs) } @@ -9404,6 +9443,7 @@ func (o *ResultData) SetExternalLinks(ctx context.Context, v []ExternalLink) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["external_links"] + t = t.(attr.TypeWithElementType).ElementType() o.ExternalLinks = types.ListValueMust(t, vs) } @@ -9505,6 +9545,7 @@ func (o *ResultManifest) SetChunks(ctx context.Context, v []BaseChunkInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["chunks"] + t = t.(attr.TypeWithElementType).ElementType() o.Chunks = types.ListValueMust(t, vs) } @@ -9606,6 +9647,7 @@ func (o *ResultSchema) SetColumns(ctx context.Context, v []ColumnInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + t = t.(attr.TypeWithElementType).ElementType() o.Columns = types.ListValueMust(t, vs) } @@ -9731,6 +9773,7 @@ func (o *SetRequest) SetAccessControlList(ctx context.Context, v []AccessControl vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -9809,6 +9852,7 @@ func (o *SetResponse) SetAccessControlList(ctx context.Context, v []AccessContro vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -9986,6 +10030,7 @@ func (o *SetWorkspaceWarehouseConfigRequest) SetDataAccessConfig(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_access_config"] + t = t.(attr.TypeWithElementType).ElementType() o.DataAccessConfig = types.ListValueMust(t, vs) } @@ -10011,6 +10056,7 @@ func (o *SetWorkspaceWarehouseConfigRequest) SetEnabledWarehouseTypes(ctx contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["enabled_warehouse_types"] + t = t.(attr.TypeWithElementType).ElementType() o.EnabledWarehouseTypes = types.ListValueMust(t, vs) } @@ -10662,6 +10708,7 @@ func (o *TerminationReason) SetParameters(ctx context.Context, v map[string]type vs[k] = e } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.MapValueMust(t, vs) } @@ -11346,6 +11393,7 @@ func (o *UpdateQueryRequestQuery) SetParameters(ctx context.Context, v []QueryPa vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["parameters"] + t = t.(attr.TypeWithElementType).ElementType() o.Parameters = types.ListValueMust(t, vs) } @@ -11371,6 +11419,7 @@ func (o *UpdateQueryRequestQuery) SetTags(ctx context.Context, v []types.String) vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["tags"] + t = t.(attr.TypeWithElementType).ElementType() o.Tags = types.ListValueMust(t, vs) } @@ -11811,6 +11860,7 @@ func (o *WarehouseAccessControlResponse) SetAllPermissions(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -11889,6 +11939,7 @@ func (o *WarehousePermission) SetInheritedFromObject(ctx context.Context, v []ty vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -11967,6 +12018,7 @@ func (o *WarehousePermissions) SetAccessControlList(ctx context.Context, v []War vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -12086,6 +12138,7 @@ func (o *WarehousePermissionsRequest) SetAccessControlList(ctx context.Context, vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index d8bd24cc31..376b1e9033 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -381,6 +381,7 @@ func (o *DeleteDataResult) SetFailedPrimaryKeys(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["failed_primary_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.FailedPrimaryKeys = types.ListValueMust(t, vs) } @@ -458,6 +459,7 @@ func (o *DeleteDataVectorIndexRequest) SetPrimaryKeys(ctx context.Context, v []t vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["primary_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.PrimaryKeys = types.ListValueMust(t, vs) } @@ -803,6 +805,7 @@ func (o *DeltaSyncVectorIndexSpecRequest) SetColumnsToSync(ctx context.Context, vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns_to_sync"] + t = t.(attr.TypeWithElementType).ElementType() o.ColumnsToSync = types.ListValueMust(t, vs) } @@ -828,6 +831,7 @@ func (o *DeltaSyncVectorIndexSpecRequest) SetEmbeddingSourceColumns(ctx context. vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_source_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddingSourceColumns = types.ListValueMust(t, vs) } @@ -853,6 +857,7 @@ func (o *DeltaSyncVectorIndexSpecRequest) SetEmbeddingVectorColumns(ctx context. vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_vector_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddingVectorColumns = types.ListValueMust(t, vs) } @@ -955,6 +960,7 @@ func (o *DeltaSyncVectorIndexSpecResponse) SetEmbeddingSourceColumns(ctx context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_source_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddingSourceColumns = types.ListValueMust(t, vs) } @@ -980,6 +986,7 @@ func (o *DeltaSyncVectorIndexSpecResponse) SetEmbeddingVectorColumns(ctx context vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_vector_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddingVectorColumns = types.ListValueMust(t, vs) } @@ -1067,6 +1074,7 @@ func (o *DirectAccessVectorIndexSpec) SetEmbeddingSourceColumns(ctx context.Cont vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_source_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddingSourceColumns = types.ListValueMust(t, vs) } @@ -1092,6 +1100,7 @@ func (o *DirectAccessVectorIndexSpec) SetEmbeddingVectorColumns(ctx context.Cont vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["embedding_vector_columns"] + t = t.(attr.TypeWithElementType).ElementType() o.EmbeddingVectorColumns = types.ListValueMust(t, vs) } @@ -1497,6 +1506,7 @@ func (o *ListEndpointResponse) SetEndpoints(ctx context.Context, v []EndpointInf vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["endpoints"] + t = t.(attr.TypeWithElementType).ElementType() o.Endpoints = types.ListValueMust(t, vs) } @@ -1657,6 +1667,7 @@ func (o *ListValue) SetValues(ctx context.Context, v []Value) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["values"] + t = t.(attr.TypeWithElementType).ElementType() o.Values = types.ListValueMust(t, vs) } @@ -1733,6 +1744,7 @@ func (o *ListVectorIndexesResponse) SetVectorIndexes(ctx context.Context, v []Mi vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["vector_indexes"] + t = t.(attr.TypeWithElementType).ElementType() o.VectorIndexes = types.ListValueMust(t, vs) } @@ -2034,6 +2046,7 @@ func (o *QueryVectorIndexRequest) SetColumns(ctx context.Context, v []types.Stri vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + t = t.(attr.TypeWithElementType).ElementType() o.Columns = types.ListValueMust(t, vs) } @@ -2059,6 +2072,7 @@ func (o *QueryVectorIndexRequest) SetQueryVector(ctx context.Context, v []types. vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["query_vector"] + t = t.(attr.TypeWithElementType).ElementType() o.QueryVector = types.ListValueMust(t, vs) } @@ -2248,6 +2262,7 @@ func (o *ResultData) SetDataArray(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data_array"] + t = t.(attr.TypeWithElementType).ElementType() o.DataArray = types.ListValueMust(t, vs) } @@ -2324,6 +2339,7 @@ func (o *ResultManifest) SetColumns(ctx context.Context, v []ColumnInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["columns"] + t = t.(attr.TypeWithElementType).ElementType() o.Columns = types.ListValueMust(t, vs) } @@ -2451,6 +2467,7 @@ func (o *ScanVectorIndexResponse) SetData(ctx context.Context, v []Struct) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["data"] + t = t.(attr.TypeWithElementType).ElementType() o.Data = types.ListValueMust(t, vs) } @@ -2522,6 +2539,7 @@ func (o *Struct) SetFields(ctx context.Context, v []MapStringValueEntry) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["fields"] + t = t.(attr.TypeWithElementType).ElementType() o.Fields = types.ListValueMust(t, vs) } @@ -2677,6 +2695,7 @@ func (o *UpsertDataResult) SetFailedPrimaryKeys(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["failed_primary_keys"] + t = t.(attr.TypeWithElementType).ElementType() o.FailedPrimaryKeys = types.ListValueMust(t, vs) } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index b6fef9cd19..1089548205 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -1432,6 +1432,7 @@ func (o *GetRepoPermissionLevelsResponse) SetPermissionLevels(ctx context.Contex vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -1868,6 +1869,7 @@ func (o *GetWorkspaceObjectPermissionLevelsResponse) SetPermissionLevels(ctx con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["permission_levels"] + t = t.(attr.TypeWithElementType).ElementType() o.PermissionLevels = types.ListValueMust(t, vs) } @@ -2143,6 +2145,7 @@ func (o *ListAclsResponse) SetItems(ctx context.Context, v []AclItem) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["items"] + t = t.(attr.TypeWithElementType).ElementType() o.Items = types.ListValueMust(t, vs) } @@ -2214,6 +2217,7 @@ func (o *ListCredentialsResponse) SetCredentials(ctx context.Context, v []Creden vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["credentials"] + t = t.(attr.TypeWithElementType).ElementType() o.Credentials = types.ListValueMust(t, vs) } @@ -2341,6 +2345,7 @@ func (o *ListReposResponse) SetRepos(ctx context.Context, v []RepoInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["repos"] + t = t.(attr.TypeWithElementType).ElementType() o.Repos = types.ListValueMust(t, vs) } @@ -2412,6 +2417,7 @@ func (o *ListResponse) SetObjects(ctx context.Context, v []ObjectInfo) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["objects"] + t = t.(attr.TypeWithElementType).ElementType() o.Objects = types.ListValueMust(t, vs) } @@ -2483,6 +2489,7 @@ func (o *ListScopesResponse) SetScopes(ctx context.Context, v []SecretScope) { vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["scopes"] + t = t.(attr.TypeWithElementType).ElementType() o.Scopes = types.ListValueMust(t, vs) } @@ -2597,6 +2604,7 @@ func (o *ListSecretsResponse) SetSecrets(ctx context.Context, v []SecretMetadata vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["secrets"] + t = t.(attr.TypeWithElementType).ElementType() o.Secrets = types.ListValueMust(t, vs) } @@ -3117,6 +3125,7 @@ func (o *RepoAccessControlResponse) SetAllPermissions(ctx context.Context, v []R vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -3292,6 +3301,7 @@ func (o *RepoPermission) SetInheritedFromObject(ctx context.Context, v []types.S vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -3370,6 +3380,7 @@ func (o *RepoPermissions) SetAccessControlList(ctx context.Context, v []RepoAcce vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3489,6 +3500,7 @@ func (o *RepoPermissionsRequest) SetAccessControlList(ctx context.Context, v []R vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -3690,6 +3702,7 @@ func (o *SparseCheckout) SetPatterns(ctx context.Context, v []types.String) { vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["patterns"] + t = t.(attr.TypeWithElementType).ElementType() o.Patterns = types.ListValueMust(t, vs) } @@ -3765,6 +3778,7 @@ func (o *SparseCheckoutUpdate) SetPatterns(ctx context.Context, v []types.String vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["patterns"] + t = t.(attr.TypeWithElementType).ElementType() o.Patterns = types.ListValueMust(t, vs) } @@ -4133,6 +4147,7 @@ func (o *WorkspaceObjectAccessControlResponse) SetAllPermissions(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["all_permissions"] + t = t.(attr.TypeWithElementType).ElementType() o.AllPermissions = types.ListValueMust(t, vs) } @@ -4211,6 +4226,7 @@ func (o *WorkspaceObjectPermission) SetInheritedFromObject(ctx context.Context, vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["inherited_from_object"] + t = t.(attr.TypeWithElementType).ElementType() o.InheritedFromObject = types.ListValueMust(t, vs) } @@ -4289,6 +4305,7 @@ func (o *WorkspaceObjectPermissions) SetAccessControlList(ctx context.Context, v vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } @@ -4412,5 +4429,6 @@ func (o *WorkspaceObjectPermissionsRequest) SetAccessControlList(ctx context.Con vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["access_control_list"] + t = t.(attr.TypeWithElementType).ElementType() o.AccessControlList = types.ListValueMust(t, vs) } From 2feedf4815372095442ccf58673ae338d090ca6d Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 9 Dec 2024 10:53:39 +0100 Subject: [PATCH 55/91] improve error message --- .../pluginfw/tfschema/struct_to_schema.go | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 4c940cced9..318029a34e 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -116,7 +116,30 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { } } } + // No other types are supported. Instead, we provide helpful error messages to help users writing + // custom TFSDK structures to use the appropriate types. + case int, int32, int64: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Int intead. %s", value, common.TerraformBugErrorMessage)) + case float32, float64: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Float64 instead. %s", value, common.TerraformBugErrorMessage)) + case string: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.String instead. %s", value, common.TerraformBugErrorMessage)) + case bool: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Bool instead. %s", value, common.TerraformBugErrorMessage)) default: + fieldType := field.Value.Type() + if fieldType.Kind() == reflect.Slice { + fieldElemType := fieldType.Elem() + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + } + if fieldType.Kind() == reflect.Map { + fieldElemType := fieldType.Elem() + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Map instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + } + if fieldType.Kind() == reflect.Struct { + // TODO: change the recommendation to use types.Object when support is added. + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead, and treat the nested object as a list of length 1. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldType.Name(), common.TerraformBugErrorMessage)) + } panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } // types.List fields of complex types correspond to ListNestedBlock, which don't have optional/required/computed flags. From 4feb0530f1f36cee3cc8a61a5b2746cce24e9903 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 9 Dec 2024 14:24:20 +0100 Subject: [PATCH 56/91] fix go to tf conversion --- .../pluginfw/converters/converters_test.go | 90 +++++++++---------- .../providers/pluginfw/converters/go_to_tf.go | 6 -- 2 files changed, 42 insertions(+), 54 deletions(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index 0de36f9bef..3238965388 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -32,6 +32,7 @@ type DummyTfSdk struct { SliceStructPtr types.List `tfsdk:"slice_struct_ptr" tf:"optional"` Irrelevant types.String `tfsdk:"-"` Object types.Object `tfsdk:"object" tf:"optional"` + ObjectPtr types.Object `tfsdk:"object_ptr" tf:"optional"` } func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { @@ -43,9 +44,9 @@ func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T "nested_map": reflect.TypeOf(DummyNestedTfSdk{}), "repeated": reflect.TypeOf(types.Int64{}), "attributes": reflect.TypeOf(types.String{}), - "slice_struct": reflect.TypeOf(DummyNestedTfSdk{}), "slice_struct_ptr": reflect.TypeOf(DummyNestedTfSdk{}), "object": reflect.TypeOf(DummyNestedTfSdk{}), + "object_ptr": reflect.TypeOf(DummyNestedTfSdk{}), } } @@ -98,8 +99,9 @@ type DummyGoSdk struct { AdditionalField string `json:"additional_field"` DistinctField string `json:"distinct_field"` // distinct field that the tfsdk struct doesn't have SliceStructPtr *DummyNestedGoSdk `json:"slice_struct_ptr"` - ForceSendFields []string `json:"-"` Object DummyNestedGoSdk `json:"object"` + ObjectPtr *DummyNestedGoSdk `json:"object_ptr"` + ForceSendFields []string `json:"-"` } type DummyNestedGoSdk struct { @@ -112,53 +114,45 @@ type DummyNestedGoSdk struct { // This is required because the Go->TF conversion function instantiates list, map, and // object fields with empty values, which are not equal to null values in the tfsdk struct. func populateEmptyFields(c DummyTfSdk) DummyTfSdk { - complexFields := c.GetComplexFieldTypes(context.Background()) - v := reflect.ValueOf(&c).Elem() - for i := 0; i < v.NumField(); i++ { - field := v.Field(i) - // If the field is a simple type, the zero value is OK. - switch field.Type() { - case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): - continue - } - if !field.IsZero() { - continue - } - - tfsdkName := v.Type().Field(i).Tag.Get("tfsdk") - complexType, ok := complexFields[tfsdkName] - if !ok { - continue - } - - var typ attr.Type - switch complexType { - case reflect.TypeOf(types.Bool{}): - typ = types.BoolType - case reflect.TypeOf(types.Int64{}): - typ = types.Int64Type - case reflect.TypeOf(types.Float64{}): - typ = types.Float64Type - case reflect.TypeOf(types.String{}): - typ = types.StringType - default: - innerVal := reflect.New(complexType).Elem().Interface() - typ = tfcommon.NewObjectTyper(innerVal).Type(context.Background()) - } - switch field.Type() { - case reflect.TypeOf(types.List{}): - value := types.ListNull(typ) - field.Set(reflect.ValueOf(value)) - case reflect.TypeOf(types.Map{}): - value := types.MapNull(typ) - field.Set(reflect.ValueOf(value)) - case reflect.TypeOf(types.Object{}): - objectType := typ.(types.ObjectType) - value := types.ObjectNull(objectType.AttrTypes) - field.Set(reflect.ValueOf(value)) - } + if c.NoPointerNested.IsNull() { + c.NoPointerNested = types.ListValueMust(dummyType, []attr.Value{ + types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringNull(), + "enabled": types.BoolNull(), + }), + }) + } + if c.NestedList.IsNull() { + c.NestedList = types.ListNull(dummyType) + } + if c.NestedPointerList.IsNull() { + c.NestedPointerList = types.ListNull(dummyType) + } + if c.Map.IsNull() { + c.Map = types.MapNull(types.StringType) + } + if c.NestedMap.IsNull() { + c.NestedMap = types.MapNull(dummyType) + } + if c.Repeated.IsNull() { + c.Repeated = types.ListNull(types.Int64Type) + } + if c.Attributes.IsNull() { + c.Attributes = types.MapNull(types.StringType) + } + if c.SliceStructPtr.IsNull() { + c.SliceStructPtr = types.ListNull(dummyType) + } + if c.Object.IsNull() { + c.Object = types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ + "name": types.StringNull(), + "enabled": types.BoolNull(), + }) + } + if c.ObjectPtr.IsNull() { + c.ObjectPtr = types.ObjectNull(dummyType.AttrTypes) } - return v.Interface().(DummyTfSdk) + return c } // Function to construct individual test case with a pair of matching tfSdkStruct and gosdkStruct. diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index 70e6653a5f..387a86450e 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -186,12 +186,6 @@ func goSdkToTfSdkSingleField( } case reflect.Struct: // This corresponds to either a types.List or types.Object. - // If the struct is zero value, set the destination field to the null value of the appropriate type. - if srcField.IsZero() { - setFieldToNull(destField, tfType) - return - } - // If the destination field is a types.List, treat the source field as a slice with length 1 // containing only this struct. if destField.Type() == reflect.TypeOf(types.List{}) { From d10447f30af7b6798ea15e098586e1ad66dbfc4a Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 9 Dec 2024 14:49:00 +0100 Subject: [PATCH 57/91] fixes --- internal/providers/pluginfw/converters/converters_test.go | 7 +++++++ internal/providers/pluginfw/converters/go_to_tf.go | 5 +++-- .../providers/pluginfw/products/cluster/data_cluster.go | 3 +++ 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index 3238965388..7ef925e626 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -33,6 +33,7 @@ type DummyTfSdk struct { Irrelevant types.String `tfsdk:"-"` Object types.Object `tfsdk:"object" tf:"optional"` ObjectPtr types.Object `tfsdk:"object_ptr" tf:"optional"` + Type_ types.String `tfsdk:"type" tf:""` // Test Type_ renaming } func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { @@ -101,6 +102,7 @@ type DummyGoSdk struct { SliceStructPtr *DummyNestedGoSdk `json:"slice_struct_ptr"` Object DummyNestedGoSdk `json:"object"` ObjectPtr *DummyNestedGoSdk `json:"object_ptr"` + Type string `json:"type"` // Test Type_ renaming ForceSendFields []string `json:"-"` } @@ -354,6 +356,11 @@ var tests = []struct { ForceSendFields: []string{"Name", "Enabled"}, }, ForceSendFields: []string{"Object"}}, }, + { + "type name", + DummyTfSdk{Type_: types.StringValue("abc")}, + DummyGoSdk{Type: "abc", ForceSendFields: []string{"Type"}}, + }, } func TestConverter(t *testing.T) { diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index 387a86450e..e01ee25c92 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -82,8 +82,9 @@ func GoSdkToTfSdkStruct(ctx context.Context, gosdk interface{}, tfsdk interface{ if srcFieldTag == "-" { continue } - destField := destVal.FieldByName(toTfSdkName(srcFieldName)) - destFieldType, ok := destVal.Type().FieldByName(field.StructField.Name) + destFieldStructName := toTfSdkName(srcFieldName) + destField := destVal.FieldByName(destFieldStructName) + destFieldType, ok := destVal.Type().FieldByName(destFieldStructName) if !ok { d.AddError(goSdkToTfSdkStructConversionFailureMessage, fmt.Sprintf("destination struct does not have field %s. %s", srcFieldName, common.TerraformBugErrorMessage)) return diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index 6db44eaee1..ffcf6a70dd 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -87,6 +87,9 @@ func (d *ClusterDataSource) Read(ctx context.Context, req datasource.ReadRequest var tfCluster compute_tf.ClusterDetails resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, cluster, &tfCluster)...) + if resp.Diagnostics.HasError() { + return + } clusterInfo.ClusterId = tfCluster.ClusterId clusterInfo.Name = tfCluster.ClusterName From ed7246edfe46a41b1ae40403fdfe8b3303c18c78 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 9 Dec 2024 14:50:14 +0100 Subject: [PATCH 58/91] fmt --- internal/providers/pluginfw/converters/converters_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index 7ef925e626..a6bccb43f3 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -33,7 +33,7 @@ type DummyTfSdk struct { Irrelevant types.String `tfsdk:"-"` Object types.Object `tfsdk:"object" tf:"optional"` ObjectPtr types.Object `tfsdk:"object_ptr" tf:"optional"` - Type_ types.String `tfsdk:"type" tf:""` // Test Type_ renaming + Type_ types.String `tfsdk:"type" tf:""` // Test Type_ renaming } func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { @@ -102,7 +102,7 @@ type DummyGoSdk struct { SliceStructPtr *DummyNestedGoSdk `json:"slice_struct_ptr"` Object DummyNestedGoSdk `json:"object"` ObjectPtr *DummyNestedGoSdk `json:"object_ptr"` - Type string `json:"type"` // Test Type_ renaming + Type string `json:"type"` // Test Type_ renaming ForceSendFields []string `json:"-"` } From 0d497600af7bb81c6484598554b25d5dbf167f52 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Mon, 9 Dec 2024 17:03:25 +0100 Subject: [PATCH 59/91] fix types.Object handling --- .../pluginfw/converters/converters_test.go | 45 ++++++++++++++++--- .../providers/pluginfw/converters/go_to_tf.go | 23 ++++++++-- .../providers/pluginfw/converters/tf_to_go.go | 15 ++++++- 3 files changed, 73 insertions(+), 10 deletions(-) diff --git a/internal/providers/pluginfw/converters/converters_test.go b/internal/providers/pluginfw/converters/converters_test.go index a6bccb43f3..c8f4bf1720 100644 --- a/internal/providers/pluginfw/converters/converters_test.go +++ b/internal/providers/pluginfw/converters/converters_test.go @@ -10,6 +10,7 @@ import ( "github.com/hashicorp/terraform-plugin-framework/attr" "github.com/hashicorp/terraform-plugin-framework/diag" "github.com/hashicorp/terraform-plugin-framework/types" + "github.com/hashicorp/terraform-plugin-framework/types/basetypes" "github.com/stretchr/testify/assert" ) @@ -34,6 +35,8 @@ type DummyTfSdk struct { Object types.Object `tfsdk:"object" tf:"optional"` ObjectPtr types.Object `tfsdk:"object_ptr" tf:"optional"` Type_ types.String `tfsdk:"type" tf:""` // Test Type_ renaming + EmptyStructList types.List `tfsdk:"empty_struct_list" tf:"optional"` + EmptyStructObject types.Object `tfsdk:"empty_struct_object" tf:"optional"` } func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { @@ -48,6 +51,8 @@ func (DummyTfSdk) GetComplexFieldTypes(ctx context.Context) map[string]reflect.T "slice_struct_ptr": reflect.TypeOf(DummyNestedTfSdk{}), "object": reflect.TypeOf(DummyNestedTfSdk{}), "object_ptr": reflect.TypeOf(DummyNestedTfSdk{}), + "empty_struct_list": reflect.TypeOf(DummyNestedTfSdkEmpty{}), + "empty_struct_object": reflect.TypeOf(DummyNestedTfSdkEmpty{}), } } @@ -83,6 +88,8 @@ type DummyNestedTfSdk struct { Enabled types.Bool `tfsdk:"enabled" tf:"optional"` } +type DummyNestedTfSdkEmpty struct{} + type DummyGoSdk struct { Enabled bool `json:"enabled"` Workers int64 `json:"workers"` @@ -103,6 +110,8 @@ type DummyGoSdk struct { Object DummyNestedGoSdk `json:"object"` ObjectPtr *DummyNestedGoSdk `json:"object_ptr"` Type string `json:"type"` // Test Type_ renaming + EmptyStructList []DummyNestedGoSdkEmpty `json:"empty_struct_list"` + EmptyStructObject *DummyNestedGoSdkEmpty `json:"empty_struct_object"` ForceSendFields []string `json:"-"` } @@ -112,17 +121,14 @@ type DummyNestedGoSdk struct { ForceSendFields []string `json:"-"` } +type DummyNestedGoSdkEmpty struct{} + // This function is used to populate empty fields in the tfsdk struct with null values. // This is required because the Go->TF conversion function instantiates list, map, and // object fields with empty values, which are not equal to null values in the tfsdk struct. func populateEmptyFields(c DummyTfSdk) DummyTfSdk { if c.NoPointerNested.IsNull() { - c.NoPointerNested = types.ListValueMust(dummyType, []attr.Value{ - types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ - "name": types.StringNull(), - "enabled": types.BoolNull(), - }), - }) + c.NoPointerNested = types.ListNull(dummyType) } if c.NestedList.IsNull() { c.NestedList = types.ListNull(dummyType) @@ -146,14 +152,22 @@ func populateEmptyFields(c DummyTfSdk) DummyTfSdk { c.SliceStructPtr = types.ListNull(dummyType) } if c.Object.IsNull() { + // type.Object fields that correspond to structs are considered never to be null. c.Object = types.ObjectValueMust(dummyType.AttrTypes, map[string]attr.Value{ "name": types.StringNull(), "enabled": types.BoolNull(), }) } if c.ObjectPtr.IsNull() { + // type.Object fields that correspond to pointers are considered null when the Go SDK value is nil. c.ObjectPtr = types.ObjectNull(dummyType.AttrTypes) } + if c.EmptyStructList.IsNull() { + c.EmptyStructList = types.ListNull(basetypes.ObjectType{AttrTypes: map[string]attr.Type{}}) + } + if c.EmptyStructObject.IsNull() { + c.EmptyStructObject = types.ObjectNull(map[string]attr.Type{}) + } return c } @@ -194,6 +208,7 @@ func TestGoSdkToTfSdkStructConversionFailure(t *testing.T) { } var dummyType = tfcommon.NewObjectTyper(DummyNestedTfSdk{}).Type(context.Background()).(types.ObjectType) +var emptyType = basetypes.ObjectType{AttrTypes: map[string]attr.Type{}} var tests = []struct { name string @@ -361,6 +376,24 @@ var tests = []struct { DummyTfSdk{Type_: types.StringValue("abc")}, DummyGoSdk{Type: "abc", ForceSendFields: []string{"Type"}}, }, + { + "empty list of empty struct to list conversion", + DummyTfSdk{EmptyStructList: types.ListValueMust(emptyType, []attr.Value{})}, + DummyGoSdk{EmptyStructList: []DummyNestedGoSdkEmpty{}}, + }, + { + "non-empty list empty struct to list conversion", + DummyTfSdk{EmptyStructList: types.ListValueMust(emptyType, []attr.Value{ + types.ObjectValueMust(map[string]attr.Type{}, map[string]attr.Value{}), + types.ObjectValueMust(map[string]attr.Type{}, map[string]attr.Value{}), + })}, + DummyGoSdk{EmptyStructList: []DummyNestedGoSdkEmpty{{}, {}}}, + }, + { + "non-nil pointer of empty struct to object conversion", + DummyTfSdk{EmptyStructObject: types.ObjectValueMust(emptyType.AttrTypes, map[string]attr.Value{})}, + DummyGoSdk{EmptyStructObject: &DummyNestedGoSdkEmpty{}, ForceSendFields: []string{"EmptyStructObject"}}, + }, } func TestConverter(t *testing.T) { diff --git a/internal/providers/pluginfw/converters/go_to_tf.go b/internal/providers/pluginfw/converters/go_to_tf.go index e01ee25c92..058995296c 100644 --- a/internal/providers/pluginfw/converters/go_to_tf.go +++ b/internal/providers/pluginfw/converters/go_to_tf.go @@ -137,9 +137,19 @@ func goSdkToTfSdkSingleField( return } - // Otherwise, dereference the pointer and continue. - srcField = srcField.Elem() - d.Append(goSdkToTfSdkSingleField(ctx, srcField, destField, forceSendField, tfType, innerType)...) + // Otherwise, the source field is a non-nil pointer to a struct. + // If the target is a list, we treat the source field as a slice with length 1 + // containing only the dereferenced pointer. + if destField.Type() == reflect.TypeOf(types.List{}) { + listSrc := reflect.MakeSlice(reflect.SliceOf(srcField.Type().Elem()), 1, 1) + listSrc.Index(0).Set(srcField.Elem()) + d.Append(goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, tfType, innerType)...) + return + } + + // Otherwise, the target is an object. Dereference the pointer and convert the underlying struct. + d.Append(goSdkToTfSdkSingleField(ctx, srcField.Elem(), destField, forceSendField, tfType, innerType)...) + return case reflect.Bool: boolVal := srcField.Interface().(bool) // check if the value is non-zero or if the field is in the forceSendFields list @@ -190,6 +200,13 @@ func goSdkToTfSdkSingleField( // If the destination field is a types.List, treat the source field as a slice with length 1 // containing only this struct. if destField.Type() == reflect.TypeOf(types.List{}) { + // For compatibility, a field consisting of a zero-valued struct that is mapped to lists is treated as an + // empty list. + if srcField.IsZero() { + setFieldToNull(destField, tfType) + return + } + listSrc := reflect.MakeSlice(reflect.SliceOf(srcField.Type()), 1, 1) listSrc.Index(0).Set(srcField) d.Append(goSdkToTfSdkSingleField(ctx, listSrc, destField, forceSendField, tfType, innerType)...) diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index d5e4f828ed..27f18feaee 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -254,7 +254,20 @@ func tfsdkToGoSdkStructField( return } - d.Append(TfSdkToGoSdkStruct(ctx, innerValue.Interface(), destField.Addr().Interface())...) + destType := destField.Type() + if destType.Kind() == reflect.Ptr { + destType = destType.Elem() + } + destValue := reflect.New(destType) + d.Append(TfSdkToGoSdkStruct(ctx, innerValue.Interface(), destValue.Interface())...) + if d.HasError() { + return + } + if destField.Type().Kind() == reflect.Ptr { + destField.Set(destValue) + } else { + destField.Set(destValue.Elem()) + } default: d.AddError(tfSdkToGoSdkFieldConversionFailureMessage, fmt.Sprintf("%T is not currently supported as a source field. %s", v, common.TerraformBugErrorMessage)) return From 5adec2ee1068e85ae9640d0c2a8f609eebe73e4e Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:04:07 +0100 Subject: [PATCH 60/91] revert sharing change --- internal/service/sharing_tf/model.go | 113 +++++++-------------------- 1 file changed, 28 insertions(+), 85 deletions(-) diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 0b4f8efd47..9b7d073b34 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -2527,7 +2527,8 @@ type SharedDataObject struct { // Username of the sharer. AddedBy types.String `tfsdk:"added_by" tf:"computed,optional"` // Whether to enable cdf or indicate if cdf is enabled on the shared object. - CdfEnabled types.Bool `tfsdk:"cdf_enabled" tf:"computed,optional"` + CdfEnabled types.Bool `tfsdk:"cdf_enabled" tf:"optional"` + EffectiveCdfEnabled types.Bool `tfsdk:"effective_cdf_enabled" tf:"computed,optional"` // A user-provided comment when adding the data object to the share. // [Update:OPT] Comment types.String `tfsdk:"comment" tf:"optional"` @@ -2539,7 +2540,8 @@ type SharedDataObject struct { DataObjectType types.String `tfsdk:"data_object_type" tf:"optional"` // Whether to enable or disable sharing of data history. If not specified, // the default is **DISABLED**. - HistoryDataSharingStatus types.String `tfsdk:"history_data_sharing_status" tf:"computed,optional"` + HistoryDataSharingStatus types.String `tfsdk:"history_data_sharing_status" tf:"optional"` + EffectiveHistoryDataSharingStatus types.String `tfsdk:"effective_history_data_sharing_status" tf:"computed,optional"` // A fully qualified name that uniquely identifies a data object. // // For example, a table's fully qualified name is in the format of @@ -2551,7 +2553,8 @@ type SharedDataObject struct { // new name is not provided, the object's original name will be used as the // `shared_as` name. The `shared_as` name must be unique within a share. For // tables, the new name must follow the format of `.
`. - SharedAs types.String `tfsdk:"shared_as" tf:"computed,optional"` + SharedAs types.String `tfsdk:"shared_as" tf:"optional"` + EffectiveSharedAs types.String `tfsdk:"effective_shared_as" tf:"computed,optional"` // The start version associated with the object. This allows data providers // to control the lowest object version that is accessible by clients. If // specified, clients can query snapshots or changes for versions >= @@ -2559,7 +2562,8 @@ type SharedDataObject struct { // version of the object at the time it was added to the share. // // NOTE: The start_version should be <= the `current` version of the object. - StartVersion types.Int64 `tfsdk:"start_version" tf:"computed,optional"` + StartVersion types.Int64 `tfsdk:"start_version" tf:"optional"` + EffectiveStartVersion types.Int64 `tfsdk:"effective_start_version" tf:"computed,optional"` // One of: **ACTIVE**, **PERMISSION_DENIED**. Status types.String `tfsdk:"status" tf:"computed,optional"` // A user-provided new name for the data object within the share. If this @@ -2571,94 +2575,33 @@ type SharedDataObject struct { } func (newState *SharedDataObject) SyncEffectiveFieldsDuringCreateOrUpdate(plan SharedDataObject) { + newState.EffectiveCdfEnabled = newState.CdfEnabled + newState.CdfEnabled = plan.CdfEnabled + newState.EffectiveHistoryDataSharingStatus = newState.HistoryDataSharingStatus + newState.HistoryDataSharingStatus = plan.HistoryDataSharingStatus + newState.EffectiveSharedAs = newState.SharedAs + newState.SharedAs = plan.SharedAs + newState.EffectiveStartVersion = newState.StartVersion + newState.StartVersion = plan.StartVersion } func (newState *SharedDataObject) SyncEffectiveFieldsDuringRead(existingState SharedDataObject) { -} - -// GetComplexFieldTypes returns a map of the types of elements in complex fields in SharedDataObject. -// Container types (types.Map, types.List, types.Set) and object types (types.Object) do not carry -// the type information of their elements in the Go type system. This function provides a way to -// retrieve the type information of the elements in complex fields at runtime. The values of the map -// are the reflected types of the contained elements. They must be either primitive values from the -// plugin framework type system (types.String{}, types.Bool{}, types.Int64{}, types.Float64{}) or TF -// SDK values. -func (a SharedDataObject) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { - return map[string]reflect.Type{ - "partition": reflect.TypeOf(Partition{}), - } -} - -// TFSDK types cannot implement the ObjectValuable interface directly, as it would otherwise -// interfere with how the plugin framework retrieves and sets values in state. Thus, SharedDataObject -// only implements ToObjectValue() and Type(). -func (o SharedDataObject) ToObjectValue(ctx context.Context) basetypes.ObjectValue { - return types.ObjectValueMust( - o.Type(ctx).(basetypes.ObjectType).AttrTypes, - map[string]attr.Value{ - "added_at": o.AddedAt, - "added_by": o.AddedBy, - "cdf_enabled": o.CdfEnabled, - "comment": o.Comment, - "content": o.Content, - "data_object_type": o.DataObjectType, - "history_data_sharing_status": o.HistoryDataSharingStatus, - "name": o.Name, - "partition": o.Partitions, - "shared_as": o.SharedAs, - "start_version": o.StartVersion, - "status": o.Status, - "string_shared_as": o.StringSharedAs, - }) -} - -// Type implements basetypes.ObjectValuable. -func (o SharedDataObject) Type(ctx context.Context) attr.Type { - return types.ObjectType{ - AttrTypes: map[string]attr.Type{ - "added_at": types.Int64Type, - "added_by": types.StringType, - "cdf_enabled": types.BoolType, - "comment": types.StringType, - "content": types.StringType, - "data_object_type": types.StringType, - "history_data_sharing_status": types.StringType, - "name": types.StringType, - "partition": basetypes.ListType{ - ElemType: Partition{}.Type(ctx), - }, - "shared_as": types.StringType, - "start_version": types.Int64Type, - "status": types.StringType, - "string_shared_as": types.StringType, - }, + newState.EffectiveCdfEnabled = existingState.EffectiveCdfEnabled + if existingState.EffectiveCdfEnabled.ValueBool() == newState.CdfEnabled.ValueBool() { + newState.CdfEnabled = existingState.CdfEnabled } -} - -// GetPartitions returns the value of the Partitions field in SharedDataObject as -// a slice of Partition values. -// If the field is unknown or null, the boolean return value is false. -func (o *SharedDataObject) GetPartitions(ctx context.Context) ([]Partition, bool) { - if o.Partitions.IsNull() || o.Partitions.IsUnknown() { - return nil, false + newState.EffectiveHistoryDataSharingStatus = existingState.EffectiveHistoryDataSharingStatus + if existingState.EffectiveHistoryDataSharingStatus.ValueString() == newState.HistoryDataSharingStatus.ValueString() { + newState.HistoryDataSharingStatus = existingState.HistoryDataSharingStatus } - var v []Partition - d := o.Partitions.ElementsAs(ctx, &v, true) - if d.HasError() { - panic(pluginfwcommon.DiagToString(d)) + newState.EffectiveSharedAs = existingState.EffectiveSharedAs + if existingState.EffectiveSharedAs.ValueString() == newState.SharedAs.ValueString() { + newState.SharedAs = existingState.SharedAs } - return v, true -} - -// SetPartitions sets the value of the Partitions field in SharedDataObject. -func (o *SharedDataObject) SetPartitions(ctx context.Context, v []Partition) { - vs := make([]attr.Value, 0, len(v)) - for _, e := range v { - vs = append(vs, e.ToObjectValue(ctx)) + newState.EffectiveStartVersion = existingState.EffectiveStartVersion + if existingState.EffectiveStartVersion.ValueInt64() == newState.StartVersion.ValueInt64() { + newState.StartVersion = existingState.StartVersion } - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["partition"] - t = t.(attr.TypeWithElementType).ElementType() - o.Partitions = types.ListValueMust(t, vs) } // GetComplexFieldTypes returns a map of the types of elements in complex fields in SharedDataObject. From 6496607ce81ba07c9b2b2260d8086df157182b80 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:04:30 +0100 Subject: [PATCH 61/91] remove extra file --- .../validators/exactly_one_attribute.go | 97 ------------------- 1 file changed, 97 deletions(-) delete mode 100644 internal/providers/pluginfw/validators/exactly_one_attribute.go diff --git a/internal/providers/pluginfw/validators/exactly_one_attribute.go b/internal/providers/pluginfw/validators/exactly_one_attribute.go deleted file mode 100644 index 138e00b7c1..0000000000 --- a/internal/providers/pluginfw/validators/exactly_one_attribute.go +++ /dev/null @@ -1,97 +0,0 @@ -package validators - -import ( - "context" - "fmt" - - "github.com/hashicorp/terraform-plugin-framework-validators/helpers/validatordiag" - "github.com/hashicorp/terraform-plugin-framework/attr" - "github.com/hashicorp/terraform-plugin-framework/path" - "github.com/hashicorp/terraform-plugin-framework/schema/validator" -) - -// Identical to objectvalidators.ExactlyOneOf() except that it doesn't count the current attribute. -// Great for migrating ExactlyOneOf and defining it on the containing schema. -type ExactlyOneAttributeValidator struct { - paths path.Expressions -} - -func ExactlyOneOf(expressions ...path.Expression) validator.Object { - return ExactlyOneAttributeValidator{ - paths: expressions, - } -} - -// Description implements validator.Object. -func (e ExactlyOneAttributeValidator) Description(ctx context.Context) string { - return e.MarkdownDescription(ctx) -} - -// MarkdownDescription implements validator.Object. -func (e ExactlyOneAttributeValidator) MarkdownDescription(context.Context) string { - return fmt.Sprintf("Requires exactly one of the following attributes on the specified object to be set: " + e.paths.String()) -} - -// ValidateObject implements validator.Object. -func (e ExactlyOneAttributeValidator) ValidateObject(ctx context.Context, req validator.ObjectRequest, res *validator.ObjectResponse) { - count := 0 - expressions := req.PathExpression.MergeExpressions(e.paths...) - - // If current attribute is unknown, delay validation - if req.ConfigValue.IsUnknown() { - return - } - - for _, expression := range expressions { - matchedPaths, diags := req.Config.PathMatches(ctx, expression) - - res.Diagnostics.Append(diags...) - - // Collect all errors - if diags.HasError() { - continue - } - - for _, mp := range matchedPaths { - // If the user specifies the same attribute this validator is applied to, - // also as part of the input, skip it - if mp.Equal(req.Path) { - continue - } - - var mpVal attr.Value - diags := req.Config.GetAttribute(ctx, mp, &mpVal) - res.Diagnostics.Append(diags...) - - // Collect all errors - if diags.HasError() { - continue - } - - // Delay validation until all involved attribute have a known value - if mpVal.IsUnknown() { - return - } - - if !mpVal.IsNull() { - count++ - } - } - } - - if count == 0 { - res.Diagnostics.Append(validatordiag.InvalidAttributeCombinationDiagnostic( - req.Path, - fmt.Sprintf("No attribute specified when one (and only one) of %s is required", expressions), - )) - } - - if count > 1 { - res.Diagnostics.Append(validatordiag.InvalidAttributeCombinationDiagnostic( - req.Path, - fmt.Sprintf("%d attributes specified when one (and only one) of %s is required", count, expressions), - )) - } -} - -var _ validator.Object = ExactlyOneAttributeValidator{} From 285c29fa608fbb8f015caf2131c33f3914566241 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:13:13 +0100 Subject: [PATCH 62/91] work --- .../providers/pluginfw/converters/tf_to_go.go | 1 + .../pluginfw/tfschema/customizable_schema.go | 2 -- .../pluginfw/tfschema/nested_block_object.go | 23 ++++--------------- 3 files changed, 5 insertions(+), 21 deletions(-) diff --git a/internal/providers/pluginfw/converters/tf_to_go.go b/internal/providers/pluginfw/converters/tf_to_go.go index 942a90adcc..27f18feaee 100644 --- a/internal/providers/pluginfw/converters/tf_to_go.go +++ b/internal/providers/pluginfw/converters/tf_to_go.go @@ -25,6 +25,7 @@ const tfSdkToGoSdkFieldConversionFailureMessage = "tfsdk to gosdk field conversi // types.Bool -> bool // types.Int64 -> int64 // types.Float64 -> float64 +// types.String -> string // // NOTE: // diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index b2837371a5..b7051b4502 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -61,8 +61,6 @@ func (s *CustomizableSchema) AddValidator(v any, path ...string) *CustomizableSc return a.AddValidator(v.(validator.List)) case ListNestedAttributeBuilder: return a.AddValidator(v.(validator.List)) - case ListNestedBlockBuilder: - return a.AddValidator(v.(validator.List)) case MapAttributeBuilder: return a.AddValidator(v.(validator.Map)) case MapNestedAttributeBuilder: diff --git a/internal/providers/pluginfw/tfschema/nested_block_object.go b/internal/providers/pluginfw/tfschema/nested_block_object.go index c6a5bb31d9..2be8935d6b 100644 --- a/internal/providers/pluginfw/tfschema/nested_block_object.go +++ b/internal/providers/pluginfw/tfschema/nested_block_object.go @@ -3,16 +3,12 @@ package tfschema import ( dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" - "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" - "github.com/hashicorp/terraform-plugin-framework/schema/validator" ) // NestedAttributteObject is the intermediate type for nested complex (non-primitive) types. type NestedBlockObject struct { - Attributes map[string]AttributeBuilder - Blocks map[string]BlockBuilder - Validators []validator.Object - PlanModifiers []planmodifier.Object + Attributes map[string]AttributeBuilder + Blocks map[string]BlockBuilder } func (a NestedBlockObject) ToNestedAttributeObject() NestedAttributeObject { @@ -35,7 +31,6 @@ func (a NestedBlockObject) BuildDataSourceAttribute() dataschema.NestedBlockObje return dataschema.NestedBlockObject{ Attributes: dataSourceAttributes, Blocks: dataSourceBlocks, - Validators: a.Validators, } } @@ -44,17 +39,7 @@ func (a NestedBlockObject) BuildResourceAttribute() schema.NestedBlockObject { resourceBlocks := BuildResourceBlockMap(a.Blocks) return schema.NestedBlockObject{ - Attributes: resourceAttributes, - Blocks: resourceBlocks, - Validators: a.Validators, - PlanModifiers: a.PlanModifiers, + Attributes: resourceAttributes, + Blocks: resourceBlocks, } } - -func (a *NestedBlockObject) AddValidator(v validator.Object) { - a.Validators = append(a.Validators, v) -} - -func (a *NestedBlockObject) AddPlanModifier(p planmodifier.Object) { - a.PlanModifiers = append(a.PlanModifiers, p) -} From ed7b0ec81b70a2585d1096b083c7109de5a64592 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:14:27 +0100 Subject: [PATCH 63/91] Panic if the provided path is invalid --- .../providers/pluginfw/tfschema/customizable_schema.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index 4ef249cf43..b7051b4502 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -230,7 +230,7 @@ func (s *CustomizableSchema) ConvertToAttribute(path ...string) *CustomizableSch } // navigateSchemaWithCallback navigates through schema attributes and executes callback on the target, panics if path does not exist or invalid. -func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) BaseSchemaBuilder, path ...string) (BaseSchemaBuilder, error) { +func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) BaseSchemaBuilder, path ...string) { currentScm := s for i, p := range path { m := attributeToNestedBlockObject(currentScm) @@ -241,7 +241,7 @@ func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) if i == len(path)-1 { newV := cb(v).(AttributeBuilder) mAttr[p] = newV - return mAttr[p], nil + return } castedV := v.(BaseSchemaBuilder) currentScm = &castedV @@ -249,14 +249,14 @@ func navigateSchemaWithCallback(s *BaseSchemaBuilder, cb func(BaseSchemaBuilder) if i == len(path)-1 { newV := cb(v).(BlockBuilder) mBlock[p] = newV - return mBlock[p], nil + return } castedV := v.(BaseSchemaBuilder) currentScm = &castedV } else { - return nil, fmt.Errorf("missing key %s", p) + panic(fmt.Errorf("missing key %s", p)) } } - return nil, fmt.Errorf("path %v is incomplete", path) + panic(fmt.Errorf("path %v is incomplete", path)) } From 958814989e2e1e1b78fe4e4dd5dd088665c82263 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:17:29 +0100 Subject: [PATCH 64/91] fix --- docs/resources/app.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/resources/app.md b/docs/resources/app.md index f713b35181..c699189e3d 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -33,7 +33,7 @@ resource "databricks_app" "this" { id = "1234" permission = "CAN_MANAGE" } - } + } } ``` From 07a77bc294a0d99fd832ed63ba1d297ea6348d7f Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:19:08 +0100 Subject: [PATCH 65/91] Expose several integration test helpers for use in plugin framework integration tests --- internal/acceptance/account_rule_set_test.go | 4 ++-- internal/acceptance/budget_test.go | 8 +++---- internal/acceptance/catalog_test.go | 4 ++-- internal/acceptance/cluster_test.go | 4 ++-- internal/acceptance/credential_test.go | 4 ++-- .../acceptance/custom_app_integration_test.go | 4 ++-- .../acceptance/data_current_config_test.go | 16 +++++++------- ...ta_mws_network_connectivity_config_test.go | 8 +++---- ...a_mws_network_connectivity_configs_test.go | 8 +++---- internal/acceptance/entitlements_test.go | 4 ++-- internal/acceptance/init.go | 22 +++++++++---------- internal/acceptance/job_test.go | 4 ++-- internal/acceptance/metastore_test.go | 22 +++++++++---------- internal/acceptance/model_serving_test.go | 12 +++++----- .../mws_network_connectivity_config_test.go | 4 ++-- internal/acceptance/mws_workspaces_test.go | 2 +- internal/acceptance/permissions_test.go | 6 ++--- internal/acceptance/schema_test.go | 4 ++-- internal/acceptance/service_principal_test.go | 8 +++---- internal/acceptance/sql_global_config_test.go | 6 ++--- internal/acceptance/sql_permissions_test.go | 2 +- .../acceptance/storage_credential_test.go | 6 ++--- internal/acceptance/vector_search_test.go | 4 ++-- internal/acceptance/workspace_conf_test.go | 10 ++++----- 24 files changed, 88 insertions(+), 88 deletions(-) diff --git a/internal/acceptance/account_rule_set_test.go b/internal/acceptance/account_rule_set_test.go index a134cdf667..ae7f5e4cc9 100644 --- a/internal/acceptance/account_rule_set_test.go +++ b/internal/acceptance/account_rule_set_test.go @@ -14,7 +14,7 @@ import ( // Application ID is mandatory in Azure today. func getServicePrincipalResource(t *testing.T) string { - if isAzure(t) { + if IsAzure(t) { return ` resource "databricks_service_principal" "this" { application_id = "{var.RANDOM_UUID}" @@ -30,7 +30,7 @@ func getServicePrincipalResource(t *testing.T) string { } func TestMwsAccAccountServicePrincipalRuleSetsFullLifeCycle(t *testing.T) { - loadAccountEnv(t) + LoadAccountEnv(t) spResource := getServicePrincipalResource(t) AccountLevel(t, Step{ Template: spResource + ` diff --git a/internal/acceptance/budget_test.go b/internal/acceptance/budget_test.go index 44b8262de9..3344e94aad 100644 --- a/internal/acceptance/budget_test.go +++ b/internal/acceptance/budget_test.go @@ -41,8 +41,8 @@ var ( ) func TestMwsAccBudgetCreate(t *testing.T) { - loadAccountEnv(t) - if isGcp(t) { + LoadAccountEnv(t) + if IsGcp(t) { skipf(t)("not available on GCP") } AccountLevel(t, Step{ @@ -51,8 +51,8 @@ func TestMwsAccBudgetCreate(t *testing.T) { } func TestMwsAccBudgetUpdate(t *testing.T) { - loadAccountEnv(t) - if isGcp(t) { + LoadAccountEnv(t) + if IsGcp(t) { skipf(t)("not available on GCP") } AccountLevel(t, Step{ diff --git a/internal/acceptance/catalog_test.go b/internal/acceptance/catalog_test.go index 3b1278c36e..17d81d6547 100644 --- a/internal/acceptance/catalog_test.go +++ b/internal/acceptance/catalog_test.go @@ -6,7 +6,7 @@ import ( ) func TestUcAccCatalog(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) UnityWorkspaceLevel(t, Step{ Template: fmt.Sprintf(` resource "databricks_catalog" "sandbox" { @@ -54,7 +54,7 @@ func TestUcAccCatalogIsolated(t *testing.T) { } func TestUcAccCatalogUpdate(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) UnityWorkspaceLevel(t, Step{ Template: fmt.Sprintf(` resource "databricks_catalog" "sandbox" { diff --git a/internal/acceptance/cluster_test.go b/internal/acceptance/cluster_test.go index bc1c4023d9..1f3bb71608 100644 --- a/internal/acceptance/cluster_test.go +++ b/internal/acceptance/cluster_test.go @@ -102,8 +102,8 @@ func awsClusterTemplate(availability string) string { } func TestAccClusterResource_CreateAndUpdateAwsAttributes(t *testing.T) { - loadWorkspaceEnv(t) - if isAws(t) { + LoadWorkspaceEnv(t) + if IsAws(t) { WorkspaceLevel(t, Step{ Template: awsClusterTemplate("SPOT"), }, Step{ diff --git a/internal/acceptance/credential_test.go b/internal/acceptance/credential_test.go index 73a2b15b31..efbd492318 100644 --- a/internal/acceptance/credential_test.go +++ b/internal/acceptance/credential_test.go @@ -5,8 +5,8 @@ import ( ) func TestUcAccCredential(t *testing.T) { - loadUcwsEnv(t) - if isAws(t) { + LoadUcwsEnv(t) + if IsAws(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_credential" "external" { diff --git a/internal/acceptance/custom_app_integration_test.go b/internal/acceptance/custom_app_integration_test.go index 280e5c039b..c1b51da906 100644 --- a/internal/acceptance/custom_app_integration_test.go +++ b/internal/acceptance/custom_app_integration_test.go @@ -18,14 +18,14 @@ var ( ) func TestMwsAccCustomAppIntegrationCreate(t *testing.T) { - loadAccountEnv(t) + LoadAccountEnv(t) AccountLevel(t, Step{ Template: fmt.Sprintf(customAppIntegrationTemplate, "30"), }) } func TestMwsAccCustomAppIntegrationUpdate(t *testing.T) { - loadAccountEnv(t) + LoadAccountEnv(t) AccountLevel(t, Step{ Template: fmt.Sprintf(customAppIntegrationTemplate, "30"), }, Step{ diff --git a/internal/acceptance/data_current_config_test.go b/internal/acceptance/data_current_config_test.go index 25fcce48e4..505b0ad5c4 100644 --- a/internal/acceptance/data_current_config_test.go +++ b/internal/acceptance/data_current_config_test.go @@ -22,18 +22,18 @@ func checkCurrentConfig(t *testing.T, cloudType string, isAccount string) func(s } func TestAccDataCurrentConfig(t *testing.T) { - loadWorkspaceEnv(t) - if isAws(t) { + LoadWorkspaceEnv(t) + if IsAws(t) { WorkspaceLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "aws", "false"), }) - } else if isAzure(t) { + } else if IsAzure(t) { WorkspaceLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "azure", "false"), }) - } else if isGcp(t) { + } else if IsGcp(t) { WorkspaceLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "gcp", "false"), @@ -42,18 +42,18 @@ func TestAccDataCurrentConfig(t *testing.T) { } func TestMwsAccDataCurrentConfig(t *testing.T) { - loadAccountEnv(t) - if isAws(t) { + LoadAccountEnv(t) + if IsAws(t) { AccountLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "aws", "true"), }) - } else if isAzure(t) { + } else if IsAzure(t) { AccountLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "azure", "true"), }) - } else if isGcp(t) { + } else if IsGcp(t) { AccountLevel(t, Step{ Template: `data "databricks_current_config" "this" {}`, Check: checkCurrentConfig(t, "gcp", "true"), diff --git a/internal/acceptance/data_mws_network_connectivity_config_test.go b/internal/acceptance/data_mws_network_connectivity_config_test.go index 15dc457d62..7d7b423ec3 100755 --- a/internal/acceptance/data_mws_network_connectivity_config_test.go +++ b/internal/acceptance/data_mws_network_connectivity_config_test.go @@ -8,14 +8,14 @@ import ( ) func TestAccDataSourceMwsNetworkConnectivityConfigTest(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { + LoadWorkspaceEnv(t) + if IsGcp(t) { skipf(t)("GCP not supported") } var sourceRegion string - if isAzure(t) { + if IsAzure(t) { sourceRegion = "eastus2" - } else if isAws(t) { + } else if IsAws(t) { sourceRegion = "us-east-2" } AccountLevel(t, diff --git a/internal/acceptance/data_mws_network_connectivity_configs_test.go b/internal/acceptance/data_mws_network_connectivity_configs_test.go index 94647bb4ca..0ab5196435 100755 --- a/internal/acceptance/data_mws_network_connectivity_configs_test.go +++ b/internal/acceptance/data_mws_network_connectivity_configs_test.go @@ -8,14 +8,14 @@ import ( ) func TestAccDataSourceMwsNetworkConnectivityConfigsTest(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { + LoadWorkspaceEnv(t) + if IsGcp(t) { skipf(t)("GCP not supported") } var region string - if isAzure(t) { + if IsAzure(t) { region = "eastus2" - } else if isAws(t) { + } else if IsAws(t) { region = "us-east-2" } AccountLevel(t, diff --git a/internal/acceptance/entitlements_test.go b/internal/acceptance/entitlements_test.go index 2aeb4e2d0b..d36cf3123e 100644 --- a/internal/acceptance/entitlements_test.go +++ b/internal/acceptance/entitlements_test.go @@ -84,9 +84,9 @@ func makePreconfig(t *testing.T, r entitlementResource) func() { } func entitlementsTest(t *testing.T, f func(*testing.T, entitlementResource)) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) sp := &servicePrincipalResource{} - if isAzure(t) { + if IsAzure(t) { // A long-lived application is used in Azure. sp.applicationId = GetEnvOrSkipTest(t, "ACCOUNT_LEVEL_SERVICE_PRINCIPAL_ID") sp.cleanup = false diff --git a/internal/acceptance/init.go b/internal/acceptance/init.go index 604d7b636c..9ecdd9d89a 100644 --- a/internal/acceptance/init.go +++ b/internal/acceptance/init.go @@ -37,22 +37,22 @@ func init() { } func WorkspaceLevel(t *testing.T, steps ...Step) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) run(t, steps) } func AccountLevel(t *testing.T, steps ...Step) { - loadAccountEnv(t) + LoadAccountEnv(t) run(t, steps) } func UnityWorkspaceLevel(t *testing.T, steps ...Step) { - loadUcwsEnv(t) + LoadUcwsEnv(t) run(t, steps) } func UnityAccountLevel(t *testing.T, steps ...Step) { - loadUcacctEnv(t) + LoadUcacctEnv(t) run(t, steps) } @@ -359,21 +359,21 @@ func setDebugLogger() { } } -func loadWorkspaceEnv(t *testing.T) { +func LoadWorkspaceEnv(t *testing.T) { initTest(t, "workspace") if os.Getenv("DATABRICKS_ACCOUNT_ID") != "" { skipf(t)("Skipping workspace test on account level") } } -func loadAccountEnv(t *testing.T) { +func LoadAccountEnv(t *testing.T) { initTest(t, "account") if os.Getenv("DATABRICKS_ACCOUNT_ID") == "" { skipf(t)("Skipping account test on workspace level") } } -func loadUcwsEnv(t *testing.T) { +func LoadUcwsEnv(t *testing.T) { initTest(t, "ucws") if os.Getenv("TEST_METASTORE_ID") == "" { skipf(t)("Skipping non-Unity Catalog test") @@ -383,7 +383,7 @@ func loadUcwsEnv(t *testing.T) { } } -func loadUcacctEnv(t *testing.T) { +func LoadUcacctEnv(t *testing.T) { initTest(t, "ucacct") if os.Getenv("TEST_METASTORE_ID") == "" { skipf(t)("Skipping non-Unity Catalog test") @@ -393,17 +393,17 @@ func loadUcacctEnv(t *testing.T) { } } -func isAws(t *testing.T) bool { +func IsAws(t *testing.T) bool { awsCloudEnvs := []string{"MWS", "aws", "ucws", "ucacct"} return isCloudEnvInList(t, awsCloudEnvs) } -func isAzure(t *testing.T) bool { +func IsAzure(t *testing.T) bool { azureCloudEnvs := []string{"azure", "azure-ucacct"} return isCloudEnvInList(t, azureCloudEnvs) } -func isGcp(t *testing.T) bool { +func IsGcp(t *testing.T) bool { gcpCloudEnvs := []string{"gcp-accounts", "gcp-ucacct", "gcp-ucws", "gcp"} return isCloudEnvInList(t, gcpCloudEnvs) } diff --git a/internal/acceptance/job_test.go b/internal/acceptance/job_test.go index b28b5a6bb9..10f918a30b 100644 --- a/internal/acceptance/job_test.go +++ b/internal/acceptance/job_test.go @@ -356,7 +356,7 @@ func TestAccJobRunAsUser(t *testing.T) { } func TestUcAccJobRunAsServicePrincipal(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) spId := GetEnvOrSkipTest(t, "ACCOUNT_LEVEL_SERVICE_PRINCIPAL_ID") UnityWorkspaceLevel(t, Step{ Template: runAsTemplate(`service_principal_name = "` + spId + `"`), @@ -373,7 +373,7 @@ func getRunAsAttribute(t *testing.T, ctx context.Context) string { } func TestUcAccJobRunAsMutations(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) spId := GetEnvOrSkipTest(t, "ACCOUNT_LEVEL_SERVICE_PRINCIPAL_ID") // Note: the attribute must match the type of principal that the test is run as. ctx := context.Background() diff --git a/internal/acceptance/metastore_test.go b/internal/acceptance/metastore_test.go index a430b91839..3dfb387a34 100644 --- a/internal/acceptance/metastore_test.go +++ b/internal/acceptance/metastore_test.go @@ -10,36 +10,36 @@ import ( ) func getStorageRoot(t *testing.T) string { - if isAws(t) { + if IsAws(t) { return "s3://{env.TEST_BUCKET}/test{var.RANDOM}" - } else if isAzure(t) { + } else if IsAzure(t) { return "abfss://{var.RANDOM}@{var.RANDOM}/" - } else if isGcp(t) { + } else if IsGcp(t) { return "gs://{var.RANDOM}/metastore" } return "" } func getRegion(t *testing.T) string { - if isAws(t) { + if IsAws(t) { return "us-east-1" - } else if isAzure(t) { + } else if IsAzure(t) { return "eastus" - } else if isGcp(t) { + } else if IsGcp(t) { return "us-east1" } return "" } func TestUcAccRootlessMetastore(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "region": getRegion(t), }) } func TestUcAccMetastore(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), @@ -47,7 +47,7 @@ func TestUcAccMetastore(t *testing.T) { } func TestUcAccMetastoreDeltaSharing(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), @@ -58,7 +58,7 @@ func TestUcAccMetastoreDeltaSharing(t *testing.T) { } func TestUcAccMetastoreDeltaSharingInfiniteLifetime(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTest(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), @@ -68,7 +68,7 @@ func TestUcAccMetastoreDeltaSharingInfiniteLifetime(t *testing.T) { } func TestUcAccMetastoreWithOwnerUpdates(t *testing.T) { - loadUcacctEnv(t) + LoadUcacctEnv(t) runMetastoreTestWithOwnerUpdates(t, map[string]any{ "storage_root": getStorageRoot(t), "region": getRegion(t), diff --git a/internal/acceptance/model_serving_test.go b/internal/acceptance/model_serving_test.go index 808ef634ab..73711667c9 100644 --- a/internal/acceptance/model_serving_test.go +++ b/internal/acceptance/model_serving_test.go @@ -8,8 +8,8 @@ import ( ) func TestAccModelServing(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { + LoadWorkspaceEnv(t) + if IsGcp(t) { skipf(t)("not available on GCP") } @@ -86,8 +86,8 @@ func TestAccModelServing(t *testing.T) { } func TestUcAccModelServingProvisionedThroughput(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { + LoadWorkspaceEnv(t) + if IsGcp(t) { skipf(t)("not available on GCP") } @@ -161,8 +161,8 @@ func TestUcAccModelServingProvisionedThroughput(t *testing.T) { } func TestAccModelServingExternalModel(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { + LoadWorkspaceEnv(t) + if IsGcp(t) { skipf(t)("not available on GCP") } diff --git a/internal/acceptance/mws_network_connectivity_config_test.go b/internal/acceptance/mws_network_connectivity_config_test.go index d7fbf5d8f8..29d6239620 100644 --- a/internal/acceptance/mws_network_connectivity_config_test.go +++ b/internal/acceptance/mws_network_connectivity_config_test.go @@ -5,7 +5,7 @@ import ( ) func TestMwsAccNetworkConnectivityConfig(t *testing.T) { - if isAzure(t) { + if IsAzure(t) { AccountLevel(t, Step{ Template: ` resource "databricks_mws_network_connectivity_config" "this" { @@ -34,7 +34,7 @@ func TestMwsAccNetworkConnectivityConfig(t *testing.T) { `, }) } - if isAws(t) { + if IsAws(t) { AccountLevel(t, Step{ Template: ` resource "databricks_mws_network_connectivity_config" "this" { diff --git a/internal/acceptance/mws_workspaces_test.go b/internal/acceptance/mws_workspaces_test.go index 07d5279874..d13424bec5 100644 --- a/internal/acceptance/mws_workspaces_test.go +++ b/internal/acceptance/mws_workspaces_test.go @@ -301,7 +301,7 @@ func TestMwsAccGcpPscWorkspaces(t *testing.T) { } func TestMwsAccAwsChangeToServicePrincipal(t *testing.T) { - if !isAws(t) { + if !IsAws(t) { skipf(t)("TestMwsAccAwsChangeToServicePrincipal should only run on AWS") } workspaceTemplate := func(tokenBlock string) string { diff --git a/internal/acceptance/permissions_test.go b/internal/acceptance/permissions_test.go index 20dfb564d0..6177716334 100644 --- a/internal/acceptance/permissions_test.go +++ b/internal/acceptance/permissions_test.go @@ -68,7 +68,7 @@ func currentPrincipalPermission(t *testing.T, permissionLevel string) func(*make skipCreation: true, } return func(config *makePermissionsConfig) { - if isGcp(t) { + if IsGcp(t) { config.user = append(config.user, settings) } else { config.servicePrincipal = append(config.servicePrincipal, settings) @@ -77,7 +77,7 @@ func currentPrincipalPermission(t *testing.T, permissionLevel string) func(*make } func currentPrincipalType(t *testing.T) string { - if isGcp(t) { + if IsGcp(t) { return "user" } return "service_principal" @@ -833,7 +833,7 @@ func TestAccPermissions_RegisteredModel_Root(t *testing.T) { func TestAccPermissions_ServingEndpoint(t *testing.T) { loadDebugEnvIfRunsFromIDE(t, "workspace") - if isGcp(t) { + if IsGcp(t) { skipf(t)("Serving endpoints are not supported on GCP") } endpointTemplate := ` diff --git a/internal/acceptance/schema_test.go b/internal/acceptance/schema_test.go index e257597237..24cf5ff892 100644 --- a/internal/acceptance/schema_test.go +++ b/internal/acceptance/schema_test.go @@ -90,7 +90,7 @@ func schemaTemplateWithOwner(t *testing.T, comment string, owner string) string } func getPredictiveOptimizationSetting(t *testing.T, enabled bool) string { - if isGcp(t) { + if IsGcp(t) { return "" } value := "ENABLE" @@ -101,7 +101,7 @@ func getPredictiveOptimizationSetting(t *testing.T, enabled bool) string { } func TestUcAccSchemaUpdate(t *testing.T) { - loadUcwsEnv(t) + LoadUcwsEnv(t) UnityWorkspaceLevel(t, Step{ Template: catalogTemplate + schemaTemplateWithOwner(t, "this database is managed by terraform", "account users"), }, Step{ diff --git a/internal/acceptance/service_principal_test.go b/internal/acceptance/service_principal_test.go index d1b75198e8..44a9d22305 100644 --- a/internal/acceptance/service_principal_test.go +++ b/internal/acceptance/service_principal_test.go @@ -22,8 +22,8 @@ const awsSpn = `resource "databricks_service_principal" "this" { }` func TestAccServicePrincipalHomeDeleteSuccess(t *testing.T) { - loadWorkspaceEnv(t) - if !isAzure(t) { + LoadWorkspaceEnv(t) + if !IsAzure(t) { skipf(t)("Test only valid for Azure") } uuid := createUuid() @@ -58,8 +58,8 @@ func TestAccServicePrincipalHomeDeleteSuccess(t *testing.T) { } func TestAccServicePrinicpalHomeDeleteNotDeleted(t *testing.T) { - loadWorkspaceEnv(t) - if !isAzure(t) { + LoadWorkspaceEnv(t) + if !IsAzure(t) { skipf(t)("Test only valid for Azure") } uuid := createUuid() diff --git a/internal/acceptance/sql_global_config_test.go b/internal/acceptance/sql_global_config_test.go index 03c67e356e..e813547ca2 100644 --- a/internal/acceptance/sql_global_config_test.go +++ b/internal/acceptance/sql_global_config_test.go @@ -37,7 +37,7 @@ resource "databricks_sql_global_config" "this" { } func TestAccSQLGlobalConfig(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) WorkspaceLevel(t, Step{ PreConfig: func() { ctx := context.Background() @@ -49,8 +49,8 @@ func TestAccSQLGlobalConfig(t *testing.T) { } func TestAccSQLGlobalConfigServerless(t *testing.T) { - loadWorkspaceEnv(t) - if isGcp(t) { + LoadWorkspaceEnv(t) + if IsGcp(t) { skipf(t)("GCP does not support serverless compute") } diff --git a/internal/acceptance/sql_permissions_test.go b/internal/acceptance/sql_permissions_test.go index 23aa37a51f..3f3e924653 100644 --- a/internal/acceptance/sql_permissions_test.go +++ b/internal/acceptance/sql_permissions_test.go @@ -12,7 +12,7 @@ import ( ) func TestAccTableACL(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) tableName := qa.RandomName("table_acl_") clusterId := GetEnvOrSkipTest(t, "TEST_TABLE_ACL_CLUSTER_ID") ctx := context.Background() diff --git a/internal/acceptance/storage_credential_test.go b/internal/acceptance/storage_credential_test.go index c78598f729..bdc10e8324 100644 --- a/internal/acceptance/storage_credential_test.go +++ b/internal/acceptance/storage_credential_test.go @@ -5,8 +5,8 @@ import ( ) func TestUcAccStorageCredential(t *testing.T) { - loadUcwsEnv(t) - if isAws(t) { + LoadUcwsEnv(t) + if IsAws(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_storage_credential" "external" { @@ -28,7 +28,7 @@ func TestUcAccStorageCredential(t *testing.T) { comment = "Managed by TF" }`, }) - } else if isGcp(t) { + } else if IsGcp(t) { UnityWorkspaceLevel(t, Step{ Template: ` resource "databricks_storage_credential" "external" { diff --git a/internal/acceptance/vector_search_test.go b/internal/acceptance/vector_search_test.go index 890f36ca34..9e8712b6ad 100644 --- a/internal/acceptance/vector_search_test.go +++ b/internal/acceptance/vector_search_test.go @@ -8,8 +8,8 @@ import ( ) func TestUcAccVectorSearchEndpoint(t *testing.T) { - loadUcwsEnv(t) - if isGcp(t) { + LoadUcwsEnv(t) + if IsGcp(t) { skipf(t)("not available on GCP") } diff --git a/internal/acceptance/workspace_conf_test.go b/internal/acceptance/workspace_conf_test.go index 80f12bfe89..2284ff5382 100644 --- a/internal/acceptance/workspace_conf_test.go +++ b/internal/acceptance/workspace_conf_test.go @@ -82,7 +82,7 @@ func TestAccWorkspaceConfFullLifecycle(t *testing.T) { } func TestAccWorkspaceConf_GetValidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) conf, err := workspace.SafeGetStatus(ctx, w, []string{"enableIpAccessLists"}) @@ -91,7 +91,7 @@ func TestAccWorkspaceConf_GetValidKey(t *testing.T) { } func TestAccWorkspaceConf_GetInvalidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) conf, err := workspace.SafeGetStatus(ctx, w, []string{"invalidKey", "enableIpAccessLists"}) @@ -100,7 +100,7 @@ func TestAccWorkspaceConf_GetInvalidKey(t *testing.T) { } func TestAccWorkspaceConf_GetOnlyInvalidKeys(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) _, err := workspace.SafeGetStatus(ctx, w, []string{"invalidKey"}) @@ -108,7 +108,7 @@ func TestAccWorkspaceConf_GetOnlyInvalidKeys(t *testing.T) { } func TestAccWorkspaceConf_SetInvalidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) err := workspace.SafeSetStatus(ctx, w, map[string]struct{}{}, map[string]string{ @@ -118,7 +118,7 @@ func TestAccWorkspaceConf_SetInvalidKey(t *testing.T) { } func TestAccWorkspaceConf_DeleteInvalidKey(t *testing.T) { - loadWorkspaceEnv(t) + LoadWorkspaceEnv(t) ctx := context.Background() w := databricks.Must(databricks.NewWorkspaceClient()) err := workspace.SafeSetStatus(ctx, w, map[string]struct{}{"invalidKey": {}}, map[string]string{ From c3ef93329be1a16237371234c8044b41f7e125c9 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 13:21:07 +0100 Subject: [PATCH 66/91] more --- internal/acceptance/budget_test.go | 4 +-- ...ta_mws_network_connectivity_config_test.go | 2 +- ...a_mws_network_connectivity_configs_test.go | 2 +- internal/acceptance/init.go | 26 +++++++------- internal/acceptance/job_test.go | 2 +- internal/acceptance/model_serving_test.go | 6 ++-- internal/acceptance/mws_workspaces_test.go | 2 +- internal/acceptance/permissions_test.go | 4 +-- internal/acceptance/service_principal_test.go | 4 +-- internal/acceptance/sql_global_config_test.go | 2 +- internal/acceptance/sql_table_test.go | 34 +++++++++---------- internal/acceptance/vector_search_test.go | 2 +- 12 files changed, 45 insertions(+), 45 deletions(-) diff --git a/internal/acceptance/budget_test.go b/internal/acceptance/budget_test.go index 3344e94aad..c139daa47f 100644 --- a/internal/acceptance/budget_test.go +++ b/internal/acceptance/budget_test.go @@ -43,7 +43,7 @@ var ( func TestMwsAccBudgetCreate(t *testing.T) { LoadAccountEnv(t) if IsGcp(t) { - skipf(t)("not available on GCP") + Skipf(t)("not available on GCP") } AccountLevel(t, Step{ Template: fmt.Sprintf(budgetTemplate, "840"), @@ -53,7 +53,7 @@ func TestMwsAccBudgetCreate(t *testing.T) { func TestMwsAccBudgetUpdate(t *testing.T) { LoadAccountEnv(t) if IsGcp(t) { - skipf(t)("not available on GCP") + Skipf(t)("not available on GCP") } AccountLevel(t, Step{ Template: fmt.Sprintf(budgetTemplate, "840"), diff --git a/internal/acceptance/data_mws_network_connectivity_config_test.go b/internal/acceptance/data_mws_network_connectivity_config_test.go index 7d7b423ec3..b76f9bee44 100755 --- a/internal/acceptance/data_mws_network_connectivity_config_test.go +++ b/internal/acceptance/data_mws_network_connectivity_config_test.go @@ -10,7 +10,7 @@ import ( func TestAccDataSourceMwsNetworkConnectivityConfigTest(t *testing.T) { LoadWorkspaceEnv(t) if IsGcp(t) { - skipf(t)("GCP not supported") + Skipf(t)("GCP not supported") } var sourceRegion string if IsAzure(t) { diff --git a/internal/acceptance/data_mws_network_connectivity_configs_test.go b/internal/acceptance/data_mws_network_connectivity_configs_test.go index 0ab5196435..ecf61dd807 100755 --- a/internal/acceptance/data_mws_network_connectivity_configs_test.go +++ b/internal/acceptance/data_mws_network_connectivity_configs_test.go @@ -10,7 +10,7 @@ import ( func TestAccDataSourceMwsNetworkConnectivityConfigsTest(t *testing.T) { LoadWorkspaceEnv(t) if IsGcp(t) { - skipf(t)("GCP not supported") + Skipf(t)("GCP not supported") } var region string if IsAzure(t) { diff --git a/internal/acceptance/init.go b/internal/acceptance/init.go index 9ecdd9d89a..4a869919cf 100644 --- a/internal/acceptance/init.go +++ b/internal/acceptance/init.go @@ -125,7 +125,7 @@ func environmentTemplate(t *testing.T, template string, otherVars ...map[string] "RANDOM_UUID": createUuid(), } if len(otherVars) > 1 { - skipf(t)("cannot have more than one custom variable map") + Skipf(t)("cannot have more than one custom variable map") } if len(otherVars) == 1 { for k, v := range otherVars[0] { @@ -147,14 +147,14 @@ func environmentTemplate(t *testing.T, template string, otherVars ...map[string] value = vars[varName] } if value == "" { - skipf(t)("Missing %s %s variable.", varType, varName) + Skipf(t)("Missing %s %s variable.", varType, varName) missing++ continue } template = strings.ReplaceAll(template, `{`+varType+`.`+varName+`}`, value) } if missing > 0 { - skipf(t)("please set %d variables and restart", missing) + Skipf(t)("please set %d variables and restart", missing) } return commands.TrimLeadingWhitespace(template) } @@ -291,7 +291,7 @@ const hexCharset = "0123456789abcdef" func GetEnvOrSkipTest(t *testing.T, name string) string { value := os.Getenv(name) if value == "" { - skipf(t)("Environment variable %s is missing", name) + Skipf(t)("Environment variable %s is missing", name) } return value } @@ -300,7 +300,7 @@ func GetEnvInt64OrSkipTest(t *testing.T, name string) int64 { v := GetEnvOrSkipTest(t, name) i, err := strconv.ParseInt(v, 10, 64) if err != nil { - skipf(t)("`%s` is not int64: %s", v, err) + Skipf(t)("`%s` is not int64: %s", v, err) } return i } @@ -338,7 +338,7 @@ func RandomHex(prefix string, randLen int) string { return string(b) } -func skipf(t *testing.T) func(format string, args ...any) { +func Skipf(t *testing.T) func(format string, args ...any) { if isInDebug() { // VSCode "debug test" feature doesn't show dlv logs, // so that we fail here for maintainer productivity. @@ -362,34 +362,34 @@ func setDebugLogger() { func LoadWorkspaceEnv(t *testing.T) { initTest(t, "workspace") if os.Getenv("DATABRICKS_ACCOUNT_ID") != "" { - skipf(t)("Skipping workspace test on account level") + Skipf(t)("Skipping workspace test on account level") } } func LoadAccountEnv(t *testing.T) { initTest(t, "account") if os.Getenv("DATABRICKS_ACCOUNT_ID") == "" { - skipf(t)("Skipping account test on workspace level") + Skipf(t)("Skipping account test on workspace level") } } func LoadUcwsEnv(t *testing.T) { initTest(t, "ucws") if os.Getenv("TEST_METASTORE_ID") == "" { - skipf(t)("Skipping non-Unity Catalog test") + Skipf(t)("Skipping non-Unity Catalog test") } if os.Getenv("DATABRICKS_ACCOUNT_ID") != "" { - skipf(t)("Skipping workspace test on account level") + Skipf(t)("Skipping workspace test on account level") } } func LoadUcacctEnv(t *testing.T) { initTest(t, "ucacct") if os.Getenv("TEST_METASTORE_ID") == "" { - skipf(t)("Skipping non-Unity Catalog test") + Skipf(t)("Skipping non-Unity Catalog test") } if os.Getenv("DATABRICKS_ACCOUNT_ID") == "" { - skipf(t)("Skipping account test on workspace level") + Skipf(t)("Skipping account test on workspace level") } } @@ -411,7 +411,7 @@ func IsGcp(t *testing.T) bool { func isCloudEnvInList(t *testing.T, cloudEnvs []string) bool { cloudEnv := os.Getenv("CLOUD_ENV") if cloudEnv == "" { - skipf(t)("Acceptance tests skipped unless env 'CLOUD_ENV' is set") + Skipf(t)("Acceptance tests skipped unless env 'CLOUD_ENV' is set") } return slices.Contains(cloudEnvs, cloudEnv) } diff --git a/internal/acceptance/job_test.go b/internal/acceptance/job_test.go index 10f918a30b..61aa41a8fc 100644 --- a/internal/acceptance/job_test.go +++ b/internal/acceptance/job_test.go @@ -396,7 +396,7 @@ func TestUcAccJobRunAsMutations(t *testing.T) { } func TestAccRemoveWebhooks(t *testing.T) { - skipf(t)("There is no API to create notification destinations. Once available, add here and enable this test.") + Skipf(t)("There is no API to create notification destinations. Once available, add here and enable this test.") WorkspaceLevel(t, Step{ Template: ` resource databricks_job test { diff --git a/internal/acceptance/model_serving_test.go b/internal/acceptance/model_serving_test.go index 73711667c9..a7c0887df1 100644 --- a/internal/acceptance/model_serving_test.go +++ b/internal/acceptance/model_serving_test.go @@ -10,7 +10,7 @@ import ( func TestAccModelServing(t *testing.T) { LoadWorkspaceEnv(t) if IsGcp(t) { - skipf(t)("not available on GCP") + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-model-serving-%s", @@ -88,7 +88,7 @@ func TestAccModelServing(t *testing.T) { func TestUcAccModelServingProvisionedThroughput(t *testing.T) { LoadWorkspaceEnv(t) if IsGcp(t) { - skipf(t)("not available on GCP") + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-model-serving-pt-%s", @@ -163,7 +163,7 @@ func TestUcAccModelServingProvisionedThroughput(t *testing.T) { func TestAccModelServingExternalModel(t *testing.T) { LoadWorkspaceEnv(t) if IsGcp(t) { - skipf(t)("not available on GCP") + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-model-serving-em-%s", diff --git a/internal/acceptance/mws_workspaces_test.go b/internal/acceptance/mws_workspaces_test.go index d13424bec5..e0ce44c72e 100644 --- a/internal/acceptance/mws_workspaces_test.go +++ b/internal/acceptance/mws_workspaces_test.go @@ -302,7 +302,7 @@ func TestMwsAccGcpPscWorkspaces(t *testing.T) { func TestMwsAccAwsChangeToServicePrincipal(t *testing.T) { if !IsAws(t) { - skipf(t)("TestMwsAccAwsChangeToServicePrincipal should only run on AWS") + Skipf(t)("TestMwsAccAwsChangeToServicePrincipal should only run on AWS") } workspaceTemplate := func(tokenBlock string) string { return ` diff --git a/internal/acceptance/permissions_test.go b/internal/acceptance/permissions_test.go index 6177716334..254a8a8a0b 100644 --- a/internal/acceptance/permissions_test.go +++ b/internal/acceptance/permissions_test.go @@ -583,7 +583,7 @@ func TestAccPermissions_Repo_Path(t *testing.T) { } func TestAccPermissions_Authorization_Passwords(t *testing.T) { - skipf(t)("ACLs for passwords are disabled on testing workspaces") + Skipf(t)("ACLs for passwords are disabled on testing workspaces") loadDebugEnvIfRunsFromIDE(t, "workspace") WorkspaceLevel(t, Step{ Template: makePermissionsTestStage("authorization", "\"passwords\"", groupPermissions("CAN_USE")), @@ -834,7 +834,7 @@ func TestAccPermissions_RegisteredModel_Root(t *testing.T) { func TestAccPermissions_ServingEndpoint(t *testing.T) { loadDebugEnvIfRunsFromIDE(t, "workspace") if IsGcp(t) { - skipf(t)("Serving endpoints are not supported on GCP") + Skipf(t)("Serving endpoints are not supported on GCP") } endpointTemplate := ` resource "databricks_model_serving" "endpoint" { diff --git a/internal/acceptance/service_principal_test.go b/internal/acceptance/service_principal_test.go index 44a9d22305..6bf750a838 100644 --- a/internal/acceptance/service_principal_test.go +++ b/internal/acceptance/service_principal_test.go @@ -24,7 +24,7 @@ const awsSpn = `resource "databricks_service_principal" "this" { func TestAccServicePrincipalHomeDeleteSuccess(t *testing.T) { LoadWorkspaceEnv(t) if !IsAzure(t) { - skipf(t)("Test only valid for Azure") + Skipf(t)("Test only valid for Azure") } uuid := createUuid() template := ` @@ -60,7 +60,7 @@ func TestAccServicePrincipalHomeDeleteSuccess(t *testing.T) { func TestAccServicePrinicpalHomeDeleteNotDeleted(t *testing.T) { LoadWorkspaceEnv(t) if !IsAzure(t) { - skipf(t)("Test only valid for Azure") + Skipf(t)("Test only valid for Azure") } uuid := createUuid() template := ` diff --git a/internal/acceptance/sql_global_config_test.go b/internal/acceptance/sql_global_config_test.go index e813547ca2..61d0b0b2f7 100644 --- a/internal/acceptance/sql_global_config_test.go +++ b/internal/acceptance/sql_global_config_test.go @@ -51,7 +51,7 @@ func TestAccSQLGlobalConfig(t *testing.T) { func TestAccSQLGlobalConfigServerless(t *testing.T) { LoadWorkspaceEnv(t) if IsGcp(t) { - skipf(t)("GCP does not support serverless compute") + Skipf(t)("GCP does not support serverless compute") } checkServerlessEnabled := func(enabled bool) func(state *terraform.State) error { diff --git a/internal/acceptance/sql_table_test.go b/internal/acceptance/sql_table_test.go index 6ba5a83714..1c7412a57c 100644 --- a/internal/acceptance/sql_table_test.go +++ b/internal/acceptance/sql_table_test.go @@ -12,7 +12,7 @@ import ( func TestUcAccResourceSqlTable_Managed(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -74,7 +74,7 @@ func TestUcAccResourceSqlTable_Managed(t *testing.T) { func TestUcAccResourceSqlTableWithIdentityColumn_Managed(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -175,7 +175,7 @@ func TestUcAccResourceSqlTable_External(t *testing.T) { func TestUcAccResourceSqlTable_View(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -226,7 +226,7 @@ func TestUcAccResourceSqlTable_View(t *testing.T) { func TestUcAccResourceSqlTable_WarehousePartition(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -277,7 +277,7 @@ func TestUcAccResourceSqlTable_WarehousePartition(t *testing.T) { } func TestUcAccResourceSqlTable_Liquid(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } UnityWorkspaceLevel(t, Step{ Template: ` @@ -381,7 +381,7 @@ var inlineAndMembershipChangeErrorRegex = regexp.MustCompile(inlineAndMembership func TestUcAccResourceSqlTable_RenameColumn(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -406,7 +406,7 @@ func constructManagedSqlTableTemplateWithColumnTypeUpdates(tableName string, col func TestUcAccResourceSqlTable_ColumnTypeSuppressDiff(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() columnName := RandomName() @@ -448,7 +448,7 @@ func TestUcAccResourceSqlTable_ColumnTypeSuppressDiff(t *testing.T) { func TestUcAccResourceSqlTable_AddColumnComment(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -460,7 +460,7 @@ func TestUcAccResourceSqlTable_AddColumnComment(t *testing.T) { func TestUcAccResourceSqlTable_DropColumnNullable(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -472,7 +472,7 @@ func TestUcAccResourceSqlTable_DropColumnNullable(t *testing.T) { func TestUcAccResourceSqlTable_MultipleColumnUpdates(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -484,7 +484,7 @@ func TestUcAccResourceSqlTable_MultipleColumnUpdates(t *testing.T) { func TestUcAccResourceSqlTable_ChangeColumnTypeThrows(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() @@ -498,7 +498,7 @@ func TestUcAccResourceSqlTable_ChangeColumnTypeThrows(t *testing.T) { func TestUcAccResourceSqlTable_DropColumn(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -513,7 +513,7 @@ func TestUcAccResourceSqlTable_DropColumn(t *testing.T) { func TestUcAccResourceSqlTable_DropMultipleColumns(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -529,7 +529,7 @@ func TestUcAccResourceSqlTable_DropMultipleColumns(t *testing.T) { func TestUcAccResourceSqlTable_AddColumn(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -544,7 +544,7 @@ func TestUcAccResourceSqlTable_AddColumn(t *testing.T) { func TestUcAccResourceSqlTable_AddMultipleColumns(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() UnityWorkspaceLevel(t, Step{ @@ -560,7 +560,7 @@ func TestUcAccResourceSqlTable_AddMultipleColumns(t *testing.T) { func TestUcAccResourceSqlTable_AddColumnAndUpdateThrows(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() @@ -577,7 +577,7 @@ func TestUcAccResourceSqlTable_AddColumnAndUpdateThrows(t *testing.T) { func TestUcAccResourceSqlTable_DropColumnAndUpdateThrows(t *testing.T) { if os.Getenv("GOOGLE_CREDENTIALS") != "" { - skipf(t)("databricks_sql_table resource not available on GCP") + Skipf(t)("databricks_sql_table resource not available on GCP") } tableName := RandomName() diff --git a/internal/acceptance/vector_search_test.go b/internal/acceptance/vector_search_test.go index 9e8712b6ad..1b09302a94 100644 --- a/internal/acceptance/vector_search_test.go +++ b/internal/acceptance/vector_search_test.go @@ -10,7 +10,7 @@ import ( func TestUcAccVectorSearchEndpoint(t *testing.T) { LoadUcwsEnv(t) if IsGcp(t) { - skipf(t)("not available on GCP") + Skipf(t)("not available on GCP") } name := fmt.Sprintf("terraform-test-vector-search-%[1]s", From ecd7d2902b884bd7de70e53ac51d46d8dd292bcd Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 14:44:21 +0100 Subject: [PATCH 67/91] tests --- .../pluginfw/products/app/app_acc_test.go | 79 +++++++++---------- .../pluginfw/products/app/resource_app.go | 16 ++-- .../pluginfw/tfschema/customizable_schema.go | 2 + .../tfschema/customizable_schema_test.go | 22 ++++++ 4 files changed, 70 insertions(+), 49 deletions(-) diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index 8fc8c5950d..10da74154a 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -8,7 +8,17 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/acceptance" ) -/* +const baseResources = ` + resource "databricks_secret_scope" "this" { + name = "tf-{var.STICKY_RANDOM}" + } + + resource "databricks_secret" "this" { + scope = databricks_secret_scope.this.name + key = "tf-{var.STICKY_RANDOM}" + string_value = "secret" + } + resource "databricks_sql_endpoint" "this" { name = "tf-{var.STICKY_RANDOM}" cluster_size = "2X-Small" @@ -38,49 +48,8 @@ import ( } } } -*/ -const baseResources = ` - - resource "databricks_secret_scope" "this" { - name = "tf-{var.STICKY_RANDOM}" - } - - resource "databricks_secret" "this" { - scope = databricks_secret_scope.this.name - key = "tf-{var.STICKY_RANDOM}" - string_value = "secret" - } - ` -/* - resources { - name = "warehouse" - description = "warehouse for app" - job { - id = databricks_job.this.id - permission = "CAN_MANAGE" - } - } - - resources { - name = "serving endpoint" - description = "serving endpoint for app" - serving_endpoint { - name = databricks_model_serving.this.name - permission = "CAN_MANAGE" - } - } - - resources { - name = "sql warehouse" - description = "sql warehouse for app" - sql_warehouse { - id = databricks_sql_endpoint.this.id - permission = "CAN_MANAGE" - } - } -*/ func makeTemplate(description string) string { appTemplate := baseResources + ` resource "databricks_app" "this" { @@ -95,6 +64,32 @@ func makeTemplate(description string) string { permission = "MANAGE" } } + resources { + name = "warehouse" + description = "warehouse for app" + job { + id = databricks_job.this.id + permission = "CAN_MANAGE" + } + } + + resources { + name = "serving endpoint" + description = "serving endpoint for app" + serving_endpoint { + name = databricks_model_serving.this.name + permission = "CAN_MANAGE" + } + } + + resources { + name = "sql warehouse" + description = "sql warehouse for app" + sql_warehouse { + id = databricks_sql_endpoint.this.id + permission = "CAN_MANAGE" + } + } }` return fmt.Sprintf(appTemplate, description) } diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 928f2d0d3d..1042c184fc 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -2,7 +2,6 @@ package app import ( "context" - "time" "github.com/databricks/databricks-sdk-go/apierr" "github.com/databricks/databricks-sdk-go/service/apps" @@ -19,9 +18,7 @@ import ( ) const ( - resourceName = "app" - defaultAppProvisionTimeout = 10 * time.Minute - deleteCallTimeout = 10 * time.Second + resourceName = "app" ) func ResourceApp() resource.Resource { @@ -120,7 +117,7 @@ func (a *resourceApp) Create(ctx context.Context, req resource.CreateRequest, re // Wait for the app to be created finalApp, err := waiter.Get() if err != nil { - resp.Diagnostics.AddError("failed to create app", err.Error()) + resp.Diagnostics.AddError("error waiting for app to be ready", err.Error()) return } @@ -151,7 +148,7 @@ func (a *resourceApp) Read(ctx context.Context, req resource.ReadRequest, resp * appGoSdk, err := w.Apps.GetByName(ctx, app.Name.ValueString()) if err != nil { - resp.Diagnostics.AddError("failed to get app", err.Error()) + resp.Diagnostics.AddError("failed to read app", err.Error()) return } @@ -160,8 +157,10 @@ func (a *resourceApp) Read(ctx context.Context, req resource.ReadRequest, resp * if resp.Diagnostics.HasError() { return } - resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) + if resp.Diagnostics.HasError() { + return + } } func (a *resourceApp) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse) { @@ -197,6 +196,9 @@ func (a *resourceApp) Update(ctx context.Context, req resource.UpdateRequest, re return } resp.Diagnostics.Append(resp.State.Set(ctx, newApp)...) + if resp.Diagnostics.HasError() { + return + } } func (a *resourceApp) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse) { diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index b7051b4502..b2837371a5 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -61,6 +61,8 @@ func (s *CustomizableSchema) AddValidator(v any, path ...string) *CustomizableSc return a.AddValidator(v.(validator.List)) case ListNestedAttributeBuilder: return a.AddValidator(v.(validator.List)) + case ListNestedBlockBuilder: + return a.AddValidator(v.(validator.List)) case MapAttributeBuilder: return a.AddValidator(v.(validator.Map)) case MapNestedAttributeBuilder: diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 6de3c00021..0b6fc49ebd 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -115,6 +115,28 @@ func TestCustomizeSchemaSetReadOnly(t *testing.T) { assert.True(t, scm.Attributes["map"].IsComputed()) } +type testTfSdkListNestedAttribute struct { + List types.List `tfsdk:"list"` +} + +func (testTfSdkListNestedAttribute) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "list": reflect.TypeOf(NestedTfSdk{}), + } +} + +func TestCustomizeSchemaSetReadOnly_RecursivelySetsFieldsOfListNestedAttributes(t *testing.T) { + scm := ResourceStructToSchema(context.Background(), testTfSdkListNestedAttribute{}, func(c CustomizableSchema) CustomizableSchema { + c.ConvertToAttribute("list").SetReadOnly("list") + return c + }) + for _, field := range []string{"name", "enabled"} { + assert.True(t, !scm.Attributes["list"].(schema.ListNestedAttribute).NestedObject.Attributes[field].IsOptional()) + assert.True(t, !scm.Attributes["list"].(schema.ListNestedAttribute).NestedObject.Attributes[field].IsRequired()) + assert.True(t, scm.Attributes["list"].(schema.ListNestedAttribute).NestedObject.Attributes[field].IsComputed()) + } +} + func TestCustomizeSchemaAddValidator(t *testing.T) { scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.AddValidator(stringLengthBetweenValidator{}, "description") From b929583a77ca8f849e3b5f8e816f8d504c8d5213 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 19:07:27 +0100 Subject: [PATCH 68/91] first attempt --- .../pluginfw/tfschema/attribute_converter.go | 24 +- .../pluginfw/tfschema/customizable_schema.go | 29 +- .../tfschema/customizable_schema_test.go | 330 ++-- .../tfschema/list_nested_attribute.go | 9 + .../tfschema/single_nested_attribute.go | 7 + .../pluginfw/tfschema/struct_to_schema.go | 211 ++- internal/service/apps_tf/model.go | 278 ++-- internal/service/billing_tf/model.go | 134 +- internal/service/catalog_tf/model.go | 1356 ++++++----------- internal/service/cleanrooms_tf/model.go | 158 +- internal/service/compute_tf/model.go | 1076 +++++-------- internal/service/dashboards_tf/model.go | 124 +- internal/service/files_tf/model.go | 8 +- internal/service/iam_tf/model.go | 228 +-- internal/service/jobs_tf/model.go | 1306 +++++----------- internal/service/marketplace_tf/model.go | 450 ++---- internal/service/ml_tf/model.go | 402 ++--- internal/service/oauth2_tf/model.go | 102 +- internal/service/pipelines_tf/model.go | 488 ++---- internal/service/provisioning_tf/model.go | 232 +-- internal/service/serving_tf/model.go | 482 ++---- internal/service/settings_tf/model.go | 434 ++---- internal/service/sharing_tf/model.go | 160 +- internal/service/sql_tf/model.go | 792 ++++------ internal/service/vectorsearch_tf/model.go | 180 +-- internal/service/workspace_tf/model.go | 170 +-- 26 files changed, 3128 insertions(+), 6042 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/attribute_converter.go b/internal/providers/pluginfw/tfschema/attribute_converter.go index db2b1bda5c..74d84d62d3 100644 --- a/internal/providers/pluginfw/tfschema/attribute_converter.go +++ b/internal/providers/pluginfw/tfschema/attribute_converter.go @@ -1,6 +1,24 @@ package tfschema -type BlockToAttributeConverter interface { - // ConvertBlockToAttribute converts a contained block to its corresponding attribute type. - ConvertBlockToAttribute(string) BaseSchemaBuilder +type Blockable interface { + ToBlock() BlockBuilder +} + +func convertAttributesToBlocks(attributes map[string]AttributeBuilder, blocks map[string]BlockBuilder) NestedBlockObject { + newAttributes := make(map[string]AttributeBuilder) + newBlocks := make(map[string]BlockBuilder) + for name, attr := range attributes { + if lnab, ok := attr.(Blockable); ok { + newBlocks[name] = lnab.ToBlock() + } else { + newAttributes[name] = attr + } + } + for name, block := range blocks { + newBlocks[name] = block + } + return NestedBlockObject{ + Attributes: newAttributes, + Blocks: newBlocks, + } } diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index b7051b4502..aea849a36b 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -200,32 +200,9 @@ func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { return s } -// ConvertToAttribute converts the last element of the path from a block to an attribute. -// It panics if the path is empty, if the path does not exist in the schema, or if the path -// points to an attribute, not a block. -func (s *CustomizableSchema) ConvertToAttribute(path ...string) *CustomizableSchema { - if len(path) == 0 { - panic(fmt.Errorf("ConvertToAttribute called on root schema. %s", common.TerraformBugErrorMessage)) - } - field := path[len(path)-1] - - cb := func(attr BaseSchemaBuilder) BaseSchemaBuilder { - switch a := attr.(type) { - case BlockToAttributeConverter: - return a.ConvertBlockToAttribute(field) - default: - panic(fmt.Errorf("ConvertToAttribute called on invalid attribute type: %s. %s", reflect.TypeOf(attr).String(), common.TerraformBugErrorMessage)) - } - } - - // We have to go only as far as the second-to-last entry, since we need to change the parent schema - // by moving the last entry from a block to an attribute. - if len(path) == 1 { - s.attr = cb(s.attr) - } else { - navigateSchemaWithCallback(&s.attr, cb, path[0:len(path)-1]...) - } - +func (s *CustomizableSchema) ConfigureForSdkV2Migration() *CustomizableSchema { + nbo := s.attr.(SingleNestedBlockBuilder).NestedObject + s.attr = SingleNestedBlockBuilder{NestedObject: convertAttributesToBlocks(nbo.Attributes, nbo.Blocks)} return s } diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 6de3c00021..1d88e32f1c 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -236,168 +236,168 @@ func (m mockValidator) ValidateObject(context.Context, validator.ObjectRequest, var _ validator.List = mockValidator{} var _ validator.Object = mockValidator{} -func TestCustomizeSchema_ConvertToAttribute(t *testing.T) { - v := mockValidator{} - pm := mockPlanModifier{} - testCases := []struct { - name string - baseSchema NestedBlockObject - path []string - want NestedBlockObject - expectPanic bool - }{ - { - name: "ListNestedBlock", - baseSchema: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "list": ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - DeprecationMessage: "deprecated", - Validators: []validator.List{v}, - PlanModifiers: []planmodifier.List{pm}, - }, - }, - }, - path: []string{"list"}, - want: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "list": ListNestedAttributeBuilder{ - NestedObject: NestedAttributeObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - DeprecationMessage: "deprecated", - Validators: []validator.List{v}, - PlanModifiers: []planmodifier.List{pm}, - }, - }, - }, - }, - { - name: "ListNestedBlock/CalledOnInnerBlock", - baseSchema: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "list": ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "nested_block": ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - }, - }, - }, - }, - }, - }, - path: []string{"list", "nested_block"}, - want: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "list": ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "nested_block": ListNestedAttributeBuilder{ - NestedObject: NestedAttributeObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - }, - }, - }, - }, - }, - }, - }, - { - name: "SingleNestedBlock", - baseSchema: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "single": SingleNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - DeprecationMessage: "deprecated", - Validators: []validator.Object{v}, - PlanModifiers: []planmodifier.Object{pm}, - }, - }, - }, - path: []string{"single"}, - want: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "single": SingleNestedAttributeBuilder{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - DeprecationMessage: "deprecated", - Validators: []validator.Object{v}, - PlanModifiers: []planmodifier.Object{pm}, - }, - }, - }, - }, - { - name: "SingleNestedBlock/RecursiveBlocks", - baseSchema: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "single": SingleNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Blocks: map[string]BlockBuilder{ - "nested_block": ListNestedBlockBuilder{ - NestedObject: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - }, - }, - }, - }, - }, - }, - path: []string{"single"}, - want: NestedBlockObject{ - Attributes: map[string]AttributeBuilder{ - "single": SingleNestedAttributeBuilder{ - Attributes: map[string]AttributeBuilder{ - "nested_block": ListNestedAttributeBuilder{ - NestedObject: NestedAttributeObject{ - Attributes: map[string]AttributeBuilder{ - "attr": StringAttributeBuilder{}, - }, - }, - }, - }, - }, - }, - }, - }, - { - name: "PanicOnEmptyPath", - path: nil, - expectPanic: true, - }, - } - for _, c := range testCases { - t.Run(c.name, func(t *testing.T) { - if c.expectPanic { - assert.Panics(t, func() { - ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) - }) - } else { - got := ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) - assert.Equal(t, c.want, got.attr.(SingleNestedBlockBuilder).NestedObject) - } - }) - } -} +// func TestCustomizeSchema_ConvertToAttribute(t *testing.T) { +// v := mockValidator{} +// pm := mockPlanModifier{} +// testCases := []struct { +// name string +// baseSchema NestedBlockObject +// path []string +// want NestedBlockObject +// expectPanic bool +// }{ +// { +// name: "ListNestedBlock", +// baseSchema: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "list": ListNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// DeprecationMessage: "deprecated", +// Validators: []validator.List{v}, +// PlanModifiers: []planmodifier.List{pm}, +// }, +// }, +// }, +// path: []string{"list"}, +// want: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "list": ListNestedAttributeBuilder{ +// NestedObject: NestedAttributeObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// DeprecationMessage: "deprecated", +// Validators: []validator.List{v}, +// PlanModifiers: []planmodifier.List{pm}, +// }, +// }, +// }, +// }, +// { +// name: "ListNestedBlock/CalledOnInnerBlock", +// baseSchema: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "list": ListNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "nested_block": ListNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// path: []string{"list", "nested_block"}, +// want: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "list": ListNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "nested_block": ListNestedAttributeBuilder{ +// NestedObject: NestedAttributeObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// { +// name: "SingleNestedBlock", +// baseSchema: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "single": SingleNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// DeprecationMessage: "deprecated", +// Validators: []validator.Object{v}, +// PlanModifiers: []planmodifier.Object{pm}, +// }, +// }, +// }, +// path: []string{"single"}, +// want: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "single": SingleNestedAttributeBuilder{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// DeprecationMessage: "deprecated", +// Validators: []validator.Object{v}, +// PlanModifiers: []planmodifier.Object{pm}, +// }, +// }, +// }, +// }, +// { +// name: "SingleNestedBlock/RecursiveBlocks", +// baseSchema: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "single": SingleNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Blocks: map[string]BlockBuilder{ +// "nested_block": ListNestedBlockBuilder{ +// NestedObject: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// path: []string{"single"}, +// want: NestedBlockObject{ +// Attributes: map[string]AttributeBuilder{ +// "single": SingleNestedAttributeBuilder{ +// Attributes: map[string]AttributeBuilder{ +// "nested_block": ListNestedAttributeBuilder{ +// NestedObject: NestedAttributeObject{ +// Attributes: map[string]AttributeBuilder{ +// "attr": StringAttributeBuilder{}, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// }, +// { +// name: "PanicOnEmptyPath", +// path: nil, +// expectPanic: true, +// }, +// } +// for _, c := range testCases { +// t.Run(c.name, func(t *testing.T) { +// if c.expectPanic { +// assert.Panics(t, func() { +// ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) +// }) +// } else { +// got := ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) +// assert.Equal(t, c.want, got.attr.(SingleNestedBlockBuilder).NestedObject) +// } +// }) +// } +// } diff --git a/internal/providers/pluginfw/tfschema/list_nested_attribute.go b/internal/providers/pluginfw/tfschema/list_nested_attribute.go index 9cd882990c..d2743b2fdd 100644 --- a/internal/providers/pluginfw/tfschema/list_nested_attribute.go +++ b/internal/providers/pluginfw/tfschema/list_nested_attribute.go @@ -102,3 +102,12 @@ func (a ListNestedAttributeBuilder) AddPlanModifier(v planmodifier.List) BaseSch a.PlanModifiers = append(a.PlanModifiers, v) return a } + +func (a ListNestedAttributeBuilder) ToBlock() BlockBuilder { + return ListNestedBlockBuilder{ + NestedObject: convertAttributesToBlocks(a.NestedObject.Attributes, nil), + DeprecationMessage: a.DeprecationMessage, + Validators: a.Validators, + PlanModifiers: a.PlanModifiers, + } +} diff --git a/internal/providers/pluginfw/tfschema/single_nested_attribute.go b/internal/providers/pluginfw/tfschema/single_nested_attribute.go index 10885e98e7..62fe04bdcf 100644 --- a/internal/providers/pluginfw/tfschema/single_nested_attribute.go +++ b/internal/providers/pluginfw/tfschema/single_nested_attribute.go @@ -1,6 +1,9 @@ package tfschema import ( + "fmt" + + "github.com/databricks/terraform-provider-databricks/common" dataschema "github.com/hashicorp/terraform-plugin-framework/datasource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" @@ -102,3 +105,7 @@ func (a SingleNestedAttributeBuilder) AddPlanModifier(v planmodifier.Object) Att a.PlanModifiers = append(a.PlanModifiers, v) return a } + +func (a SingleNestedAttributeBuilder) ToBlock() BlockBuilder { + panic(fmt.Errorf("SingleNestedAttributeBuilder used for legacy resource. This is unexpected. %s", common.TerraformBugErrorMessage)) +} diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 318029a34e..ceb83d7f6c 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -25,7 +25,6 @@ type structTag struct { func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { scmAttr := map[string]AttributeBuilder{} - scmBlock := map[string]BlockBuilder{} rk := v.Kind() if rk == reflect.Ptr { v = v.Elem() @@ -42,122 +41,122 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { continue } structTag := getStructTag(typeField) - value := field.Value.Interface() - if _, ok := value.(attr.Value); !ok { - panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) + attr := getAttribute(ctx, v, field, structTag) + if structTag.optional { + attr = attr.SetOptional() + } else { + attr = attr.SetRequired() } - switch value.(type) { - case types.Bool: - scmAttr[fieldName] = BoolAttributeBuilder{} - case types.Int64: - scmAttr[fieldName] = Int64AttributeBuilder{} - case types.Float64: - scmAttr[fieldName] = Float64AttributeBuilder{} - case types.String: - scmAttr[fieldName] = StringAttributeBuilder{} - case types.List, types.Map, types.Object: - // Additional metadata is required to determine the type of the list elements. - // This is available via the ComplexFieldTypeProvider interface, implemented on the parent type. - provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider) + if structTag.computed { + attr = attr.SetComputed() + } + scmAttr[fieldName] = attr + } + return NestedBlockObject{Attributes: scmAttr} +} + +func getAttribute(ctx context.Context, v reflect.Value, field tfreflect.Field, structTag structTag) AttributeBuilder { + typeField := field.StructField + fieldName := typeField.Tag.Get("tfsdk") + value := field.Value.Interface() + if _, ok := value.(attr.Value); !ok { + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) + } + switch value.(type) { + case types.Bool: + return BoolAttributeBuilder{} + case types.Int64: + return Int64AttributeBuilder{} + case types.Float64: + return Float64AttributeBuilder{} + case types.String: + return StringAttributeBuilder{} + case types.List, types.Map, types.Object: + // Additional metadata is required to determine the type of the list elements. + // This is available via the ComplexFieldTypeProvider interface, implemented on the parent type. + provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider) + if !ok { + panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) + } + complexFieldTypes := provider.GetComplexFieldTypes(ctx) + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + } + // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. + // Otherwise, use ListNestedBlockBuilder. + switch fieldType { + // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. + // If new types are added there, they must also be added here to work properly. + case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): + // Look up the element type from the Type() methods for TF SDK structs. + // This is always a attr.TypeWithElementType because the field is a list or map. + objectType := tfcommon.NewObjectTyper(v.Interface()).Type(ctx).(types.ObjectType) + attrType, ok := objectType.AttrTypes[fieldName] if !ok { - panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) + panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } - complexFieldTypes := provider.GetComplexFieldTypes(ctx) - fieldType, ok := complexFieldTypes[fieldName] - if !ok { - panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + containerType := attrType.(attr.TypeWithElementType) + switch value.(type) { + case types.List: + return ListAttributeBuilder{ElementType: containerType.ElementType()} + case types.Map: + return MapAttributeBuilder{ElementType: containerType.ElementType()} } - // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. - // Otherwise, use ListNestedBlockBuilder. - switch fieldType { - // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. - // If new types are added there, they must also be added here to work properly. - case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): - // Look up the element type from the Type() methods for TF SDK structs. - // This is always a attr.TypeWithElementType because the field is a list or map. - objectType := tfcommon.NewObjectTyper(v.Interface()).Type(ctx).(types.ObjectType) - attrType, ok := objectType.AttrTypes[fieldName] - if !ok { - panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + default: + // The element type is a TFSDK type. Map fields are treated as MapNestedAttributes, and list + // fields are treated as ListNestedAttributes. Object fields are treated as SingleNestedAttributes. + fieldValue := reflect.New(fieldType).Elem() + + // Generate the nested block schema + nestedSchema := typeToSchema(ctx, fieldValue) + switch value.(type) { + case types.List: + validators := []validator.List{} + if structTag.singleObject { + validators = append(validators, listvalidator.SizeAtMost(1)) } - containerType := attrType.(attr.TypeWithElementType) - switch value.(type) { - case types.List: - scmAttr[fieldName] = ListAttributeBuilder{ElementType: containerType.ElementType()} - case types.Map: - scmAttr[fieldName] = MapAttributeBuilder{ElementType: containerType.ElementType()} + return ListNestedAttributeBuilder{ + NestedObject: nestedSchema.ToNestedAttributeObject(), + Validators: validators, } - default: - // The element type is a TFSDK type. Map fields are treated as MapNestedAttributes. For compatibility, - // list fields are treated as ListNestedBlocks. - // TODO: Change the default for lists to ListNestedAttribute. - fieldValue := reflect.New(fieldType).Elem() - - // Generate the nested block schema - nestedSchema := typeToSchema(ctx, fieldValue) - switch value.(type) { - case types.List: - validators := []validator.List{} - if structTag.singleObject { - validators = append(validators, listvalidator.SizeAtMost(1)) - } - // Note that this is being added to the block map, not the attribute map. - scmBlock[fieldName] = ListNestedBlockBuilder{ - NestedObject: nestedSchema, - Validators: validators, - } - case types.Map: - scmAttr[fieldName] = MapNestedAttributeBuilder{ - NestedObject: nestedSchema.ToNestedAttributeObject(), - } - case types.Object: - scmAttr[fieldName] = SingleNestedAttributeBuilder{ - Attributes: nestedSchema.ToNestedAttributeObject().Attributes, - } + case types.Map: + return MapNestedAttributeBuilder{ + NestedObject: nestedSchema.ToNestedAttributeObject(), + } + case types.Object: + return SingleNestedAttributeBuilder{ + Attributes: nestedSchema.ToNestedAttributeObject().Attributes, } } - // No other types are supported. Instead, we provide helpful error messages to help users writing - // custom TFSDK structures to use the appropriate types. - case int, int32, int64: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Int intead. %s", value, common.TerraformBugErrorMessage)) - case float32, float64: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Float64 instead. %s", value, common.TerraformBugErrorMessage)) - case string: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.String instead. %s", value, common.TerraformBugErrorMessage)) - case bool: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Bool instead. %s", value, common.TerraformBugErrorMessage)) - default: - fieldType := field.Value.Type() - if fieldType.Kind() == reflect.Slice { - fieldElemType := fieldType.Elem() - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) - } - if fieldType.Kind() == reflect.Map { - fieldElemType := fieldType.Elem() - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Map instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) - } - if fieldType.Kind() == reflect.Struct { - // TODO: change the recommendation to use types.Object when support is added. - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead, and treat the nested object as a list of length 1. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldType.Name(), common.TerraformBugErrorMessage)) - } - panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } - // types.List fields of complex types correspond to ListNestedBlock, which don't have optional/required/computed flags. - // When these fields are later changed to use ListNestedAttribute, we can inline the if statement below, as all fields - // will be attributes. - if attr, ok := scmAttr[fieldName]; ok { - if structTag.optional { - attr = attr.SetOptional() - } else { - attr = attr.SetRequired() - } - if structTag.computed { - attr = attr.SetComputed() - } - scmAttr[fieldName] = attr + // No other types are supported. Instead, we provide helpful error messages to help users writing + // custom TFSDK structures to use the appropriate types. + case int, int32, int64: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Int intead. %s", value, common.TerraformBugErrorMessage)) + case float32, float64: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Float64 instead. %s", value, common.TerraformBugErrorMessage)) + case string: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.String instead. %s", value, common.TerraformBugErrorMessage)) + case bool: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Bool instead. %s", value, common.TerraformBugErrorMessage)) + default: + fieldType := field.Value.Type() + if fieldType.Kind() == reflect.Slice { + fieldElemType := fieldType.Elem() + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + } + if fieldType.Kind() == reflect.Map { + fieldElemType := fieldType.Elem() + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Map instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + } + if fieldType.Kind() == reflect.Struct { + // TODO: change the recommendation to use types.Object when support is added. + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead, and treat the nested object as a list of length 1. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldType.Name(), common.TerraformBugErrorMessage)) } + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } - return NestedBlockObject{Attributes: scmAttr, Blocks: scmBlock} + panic(fmt.Errorf("unreachable code reached. %s", common.TerraformBugErrorMessage)) } func getStructTag(field reflect.StructField) structTag { diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index ec2b5a415d..88accf4d8e 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -24,11 +24,11 @@ import ( type App struct { // The active deployment of the app. A deployment is considered active when // it has been deployed to the app compute. - ActiveDeployment types.List `tfsdk:"active_deployment" tf:"optional,object"` + ActiveDeployment types.Object `tfsdk:"active_deployment" tf:"optional,object"` - AppStatus types.List `tfsdk:"app_status" tf:"optional,object"` + AppStatus types.Object `tfsdk:"app_status" tf:"optional,object"` - ComputeStatus types.List `tfsdk:"compute_status" tf:"optional,object"` + ComputeStatus types.Object `tfsdk:"compute_status" tf:"optional,object"` // The creation time of the app. Formatted timestamp in ISO 6801. CreateTime types.String `tfsdk:"create_time" tf:"computed,optional"` // The email of the user that created the app. @@ -44,7 +44,7 @@ type App struct { Name types.String `tfsdk:"name" tf:""` // The pending deployment of the app. A deployment is considered pending // when it is being prepared for deployment to the app compute. - PendingDeployment types.List `tfsdk:"pending_deployment" tf:"optional,object"` + PendingDeployment types.Object `tfsdk:"pending_deployment" tf:"optional,object"` // Resources for the app. Resources types.List `tfsdk:"resources" tf:"optional"` @@ -114,26 +114,16 @@ func (o App) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o App) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "active_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.Type(ctx), - }, - "app_status": basetypes.ListType{ - ElemType: ApplicationStatus{}.Type(ctx), - }, - "compute_status": basetypes.ListType{ - ElemType: ComputeStatus{}.Type(ctx), - }, - "create_time": types.StringType, - "creator": types.StringType, - "default_source_code_path": types.StringType, - "description": types.StringType, - "name": types.StringType, - "pending_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.Type(ctx), - }, - "resources": basetypes.ListType{ - ElemType: AppResource{}.Type(ctx), - }, + "active_deployment": AppDeployment{}.Type(ctx), + "app_status": ApplicationStatus{}.Type(ctx), + "compute_status": ComputeStatus{}.Type(ctx), + "create_time": types.StringType, + "creator": types.StringType, + "default_source_code_path": types.StringType, + "description": types.StringType, + "name": types.StringType, + "pending_deployment": AppDeployment{}.Type(ctx), + "resources": AppResource{}.Type(ctx), "service_principal_client_id": types.StringType, "service_principal_id": types.Int64Type, "service_principal_name": types.StringType, @@ -153,7 +143,10 @@ func (o *App) GetActiveDeployment(ctx context.Context) (AppDeployment, bool) { return e, false } var v []AppDeployment - d := o.ActiveDeployment.ElementsAs(ctx, &v, true) + d := o.ActiveDeployment.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -165,9 +158,8 @@ func (o *App) GetActiveDeployment(ctx context.Context) (AppDeployment, bool) { // SetActiveDeployment sets the value of the ActiveDeployment field in App. func (o *App) SetActiveDeployment(ctx context.Context, v AppDeployment) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["active_deployment"] - o.ActiveDeployment = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.ActiveDeployment = vs } // GetAppStatus returns the value of the AppStatus field in App as @@ -179,7 +171,10 @@ func (o *App) GetAppStatus(ctx context.Context) (ApplicationStatus, bool) { return e, false } var v []ApplicationStatus - d := o.AppStatus.ElementsAs(ctx, &v, true) + d := o.AppStatus.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -191,9 +186,8 @@ func (o *App) GetAppStatus(ctx context.Context) (ApplicationStatus, bool) { // SetAppStatus sets the value of the AppStatus field in App. func (o *App) SetAppStatus(ctx context.Context, v ApplicationStatus) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app_status"] - o.AppStatus = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.AppStatus = vs } // GetComputeStatus returns the value of the ComputeStatus field in App as @@ -205,7 +199,10 @@ func (o *App) GetComputeStatus(ctx context.Context) (ComputeStatus, bool) { return e, false } var v []ComputeStatus - d := o.ComputeStatus.ElementsAs(ctx, &v, true) + d := o.ComputeStatus.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -217,9 +214,8 @@ func (o *App) GetComputeStatus(ctx context.Context) (ComputeStatus, bool) { // SetComputeStatus sets the value of the ComputeStatus field in App. func (o *App) SetComputeStatus(ctx context.Context, v ComputeStatus) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compute_status"] - o.ComputeStatus = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.ComputeStatus = vs } // GetPendingDeployment returns the value of the PendingDeployment field in App as @@ -231,7 +227,10 @@ func (o *App) GetPendingDeployment(ctx context.Context) (AppDeployment, bool) { return e, false } var v []AppDeployment - d := o.PendingDeployment.ElementsAs(ctx, &v, true) + d := o.PendingDeployment.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -243,9 +242,8 @@ func (o *App) GetPendingDeployment(ctx context.Context) (AppDeployment, bool) { // SetPendingDeployment sets the value of the PendingDeployment field in App. func (o *App) SetPendingDeployment(ctx context.Context, v AppDeployment) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["pending_deployment"] - o.PendingDeployment = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.PendingDeployment = vs } // GetResources returns the value of the Resources field in App as @@ -379,9 +377,7 @@ func (o AppAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o AppAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: AppPermission{}.Type(ctx), - }, + "all_permissions": AppPermission{}.Type(ctx), "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -422,7 +418,7 @@ type AppDeployment struct { // The email of the user creates the deployment. Creator types.String `tfsdk:"creator" tf:"computed,optional"` // The deployment artifacts for an app. - DeploymentArtifacts types.List `tfsdk:"deployment_artifacts" tf:"optional,object"` + DeploymentArtifacts types.Object `tfsdk:"deployment_artifacts" tf:"optional,object"` // The unique id of the deployment. DeploymentId types.String `tfsdk:"deployment_id" tf:"optional"` // The mode of which the deployment will manage the source code. @@ -436,7 +432,7 @@ type AppDeployment struct { // the deployment. SourceCodePath types.String `tfsdk:"source_code_path" tf:"optional"` // Status and status message of the deployment - Status types.List `tfsdk:"status" tf:"optional,object"` + Status types.Object `tfsdk:"status" tf:"optional,object"` // The update time of the deployment. Formatted timestamp in ISO 6801. UpdateTime types.String `tfsdk:"update_time" tf:"computed,optional"` } @@ -483,18 +479,14 @@ func (o AppDeployment) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AppDeployment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "create_time": types.StringType, - "creator": types.StringType, - "deployment_artifacts": basetypes.ListType{ - ElemType: AppDeploymentArtifacts{}.Type(ctx), - }, - "deployment_id": types.StringType, - "mode": types.StringType, - "source_code_path": types.StringType, - "status": basetypes.ListType{ - ElemType: AppDeploymentStatus{}.Type(ctx), - }, - "update_time": types.StringType, + "create_time": types.StringType, + "creator": types.StringType, + "deployment_artifacts": AppDeploymentArtifacts{}.Type(ctx), + "deployment_id": types.StringType, + "mode": types.StringType, + "source_code_path": types.StringType, + "status": AppDeploymentStatus{}.Type(ctx), + "update_time": types.StringType, }, } } @@ -508,7 +500,10 @@ func (o *AppDeployment) GetDeploymentArtifacts(ctx context.Context) (AppDeployme return e, false } var v []AppDeploymentArtifacts - d := o.DeploymentArtifacts.ElementsAs(ctx, &v, true) + d := o.DeploymentArtifacts.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -520,9 +515,8 @@ func (o *AppDeployment) GetDeploymentArtifacts(ctx context.Context) (AppDeployme // SetDeploymentArtifacts sets the value of the DeploymentArtifacts field in AppDeployment. func (o *AppDeployment) SetDeploymentArtifacts(ctx context.Context, v AppDeploymentArtifacts) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["deployment_artifacts"] - o.DeploymentArtifacts = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.DeploymentArtifacts = vs } // GetStatus returns the value of the Status field in AppDeployment as @@ -534,7 +528,10 @@ func (o *AppDeployment) GetStatus(ctx context.Context) (AppDeploymentStatus, boo return e, false } var v []AppDeploymentStatus - d := o.Status.ElementsAs(ctx, &v, true) + d := o.Status.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -546,9 +543,8 @@ func (o *AppDeployment) GetStatus(ctx context.Context) (AppDeploymentStatus, boo // SetStatus sets the value of the Status field in AppDeployment. func (o *AppDeployment) SetStatus(ctx context.Context, v AppDeploymentStatus) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["status"] - o.Status = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.Status = vs } type AppDeploymentArtifacts struct { @@ -684,11 +680,9 @@ func (o AppPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AppPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -763,11 +757,9 @@ func (o AppPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AppPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AppAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": AppAccessControlResponse{}.Type(ctx), + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -884,10 +876,8 @@ func (o AppPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o AppPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AppAccessControlRequest{}.Type(ctx), - }, - "app_name": types.StringType, + "access_control_list": AppAccessControlRequest{}.Type(ctx), + "app_name": types.StringType, }, } } @@ -922,15 +912,15 @@ type AppResource struct { // Description of the App Resource. Description types.String `tfsdk:"description" tf:"optional"` - Job types.List `tfsdk:"job" tf:"optional,object"` + Job types.Object `tfsdk:"job" tf:"optional,object"` // Name of the App Resource. Name types.String `tfsdk:"name" tf:""` - Secret types.List `tfsdk:"secret" tf:"optional,object"` + Secret types.Object `tfsdk:"secret" tf:"optional,object"` - ServingEndpoint types.List `tfsdk:"serving_endpoint" tf:"optional,object"` + ServingEndpoint types.Object `tfsdk:"serving_endpoint" tf:"optional,object"` - SqlWarehouse types.List `tfsdk:"sql_warehouse" tf:"optional,object"` + SqlWarehouse types.Object `tfsdk:"sql_warehouse" tf:"optional,object"` } func (newState *AppResource) SyncEffectiveFieldsDuringCreateOrUpdate(plan AppResource) { @@ -975,20 +965,12 @@ func (o AppResource) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o AppResource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "description": types.StringType, - "job": basetypes.ListType{ - ElemType: AppResourceJob{}.Type(ctx), - }, - "name": types.StringType, - "secret": basetypes.ListType{ - ElemType: AppResourceSecret{}.Type(ctx), - }, - "serving_endpoint": basetypes.ListType{ - ElemType: AppResourceServingEndpoint{}.Type(ctx), - }, - "sql_warehouse": basetypes.ListType{ - ElemType: AppResourceSqlWarehouse{}.Type(ctx), - }, + "description": types.StringType, + "job": AppResourceJob{}.Type(ctx), + "name": types.StringType, + "secret": AppResourceSecret{}.Type(ctx), + "serving_endpoint": AppResourceServingEndpoint{}.Type(ctx), + "sql_warehouse": AppResourceSqlWarehouse{}.Type(ctx), }, } } @@ -1002,7 +984,10 @@ func (o *AppResource) GetJob(ctx context.Context) (AppResourceJob, bool) { return e, false } var v []AppResourceJob - d := o.Job.ElementsAs(ctx, &v, true) + d := o.Job.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -1014,9 +999,8 @@ func (o *AppResource) GetJob(ctx context.Context) (AppResourceJob, bool) { // SetJob sets the value of the Job field in AppResource. func (o *AppResource) SetJob(ctx context.Context, v AppResourceJob) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["job"] - o.Job = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.Job = vs } // GetSecret returns the value of the Secret field in AppResource as @@ -1028,7 +1012,10 @@ func (o *AppResource) GetSecret(ctx context.Context) (AppResourceSecret, bool) { return e, false } var v []AppResourceSecret - d := o.Secret.ElementsAs(ctx, &v, true) + d := o.Secret.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -1040,9 +1027,8 @@ func (o *AppResource) GetSecret(ctx context.Context) (AppResourceSecret, bool) { // SetSecret sets the value of the Secret field in AppResource. func (o *AppResource) SetSecret(ctx context.Context, v AppResourceSecret) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["secret"] - o.Secret = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.Secret = vs } // GetServingEndpoint returns the value of the ServingEndpoint field in AppResource as @@ -1054,7 +1040,10 @@ func (o *AppResource) GetServingEndpoint(ctx context.Context) (AppResourceServin return e, false } var v []AppResourceServingEndpoint - d := o.ServingEndpoint.ElementsAs(ctx, &v, true) + d := o.ServingEndpoint.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -1066,9 +1055,8 @@ func (o *AppResource) GetServingEndpoint(ctx context.Context) (AppResourceServin // SetServingEndpoint sets the value of the ServingEndpoint field in AppResource. func (o *AppResource) SetServingEndpoint(ctx context.Context, v AppResourceServingEndpoint) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["serving_endpoint"] - o.ServingEndpoint = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.ServingEndpoint = vs } // GetSqlWarehouse returns the value of the SqlWarehouse field in AppResource as @@ -1080,7 +1068,10 @@ func (o *AppResource) GetSqlWarehouse(ctx context.Context) (AppResourceSqlWareho return e, false } var v []AppResourceSqlWarehouse - d := o.SqlWarehouse.ElementsAs(ctx, &v, true) + d := o.SqlWarehouse.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -1092,9 +1083,8 @@ func (o *AppResource) GetSqlWarehouse(ctx context.Context) (AppResourceSqlWareho // SetSqlWarehouse sets the value of the SqlWarehouse field in AppResource. func (o *AppResource) SetSqlWarehouse(ctx context.Context, v AppResourceSqlWarehouse) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["sql_warehouse"] - o.SqlWarehouse = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.SqlWarehouse = vs } type AppResourceJob struct { @@ -1383,7 +1373,7 @@ func (o ComputeStatus) Type(ctx context.Context) attr.Type { // Create an app deployment type CreateAppDeploymentRequest struct { - AppDeployment types.List `tfsdk:"app_deployment" tf:"optional,object"` + AppDeployment types.Object `tfsdk:"app_deployment" tf:"optional,object"` // The name of the app. AppName types.String `tfsdk:"-"` } @@ -1423,10 +1413,8 @@ func (o CreateAppDeploymentRequest) ToObjectValue(ctx context.Context) basetypes func (o CreateAppDeploymentRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_deployment": basetypes.ListType{ - ElemType: AppDeployment{}.Type(ctx), - }, - "app_name": types.StringType, + "app_deployment": AppDeployment{}.Type(ctx), + "app_name": types.StringType, }, } } @@ -1440,7 +1428,10 @@ func (o *CreateAppDeploymentRequest) GetAppDeployment(ctx context.Context) (AppD return e, false } var v []AppDeployment - d := o.AppDeployment.ElementsAs(ctx, &v, true) + d := o.AppDeployment.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -1452,14 +1443,13 @@ func (o *CreateAppDeploymentRequest) GetAppDeployment(ctx context.Context) (AppD // SetAppDeployment sets the value of the AppDeployment field in CreateAppDeploymentRequest. func (o *CreateAppDeploymentRequest) SetAppDeployment(ctx context.Context, v AppDeployment) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app_deployment"] - o.AppDeployment = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.AppDeployment = vs } // Create an app type CreateAppRequest struct { - App types.List `tfsdk:"app" tf:"optional,object"` + App types.Object `tfsdk:"app" tf:"optional,object"` } func (newState *CreateAppRequest) SyncEffectiveFieldsDuringCreateOrUpdate(plan CreateAppRequest) { @@ -1496,9 +1486,7 @@ func (o CreateAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o CreateAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app": basetypes.ListType{ - ElemType: App{}.Type(ctx), - }, + "app": App{}.Type(ctx), }, } } @@ -1512,7 +1500,10 @@ func (o *CreateAppRequest) GetApp(ctx context.Context) (App, bool) { return e, false } var v []App - d := o.App.ElementsAs(ctx, &v, true) + d := o.App.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -1524,9 +1515,8 @@ func (o *CreateAppRequest) GetApp(ctx context.Context) (App, bool) { // SetApp sets the value of the App field in CreateAppRequest. func (o *CreateAppRequest) SetApp(ctx context.Context, v App) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app"] - o.App = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.App = vs } // Delete an app @@ -1701,9 +1691,7 @@ func (o GetAppPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetAppPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: AppPermissionsDescription{}.Type(ctx), - }, + "permission_levels": AppPermissionsDescription{}.Type(ctx), }, } } @@ -1914,9 +1902,7 @@ func (o ListAppDeploymentsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListAppDeploymentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_deployments": basetypes.ListType{ - ElemType: AppDeployment{}.Type(ctx), - }, + "app_deployments": AppDeployment{}.Type(ctx), "next_page_token": types.StringType, }, } @@ -2037,9 +2023,7 @@ func (o ListAppsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAppsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ - ElemType: App{}.Type(ctx), - }, + "apps": App{}.Type(ctx), "next_page_token": types.StringType, }, } @@ -2157,7 +2141,7 @@ func (o StopAppRequest) Type(ctx context.Context) attr.Type { // Update an app type UpdateAppRequest struct { - App types.List `tfsdk:"app" tf:"optional,object"` + App types.Object `tfsdk:"app" tf:"optional,object"` // The name of the app. The name must contain only lowercase alphanumeric // characters and hyphens. It must be unique within the workspace. Name types.String `tfsdk:"-"` @@ -2198,9 +2182,7 @@ func (o UpdateAppRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o UpdateAppRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app": basetypes.ListType{ - ElemType: App{}.Type(ctx), - }, + "app": App{}.Type(ctx), "name": types.StringType, }, } @@ -2215,7 +2197,10 @@ func (o *UpdateAppRequest) GetApp(ctx context.Context) (App, bool) { return e, false } var v []App - d := o.App.ElementsAs(ctx, &v, true) + d := o.App.As(ctx, &v, basetypes.ObjectAsOptions{ + UnhandledNullAsEmpty: true, + UnhandledUnknownAsEmpty: true, + }) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) } @@ -2227,7 +2212,6 @@ func (o *UpdateAppRequest) GetApp(ctx context.Context) (App, bool) { // SetApp sets the value of the App field in UpdateAppRequest. func (o *UpdateAppRequest) SetApp(ctx context.Context, v App) { - vs := []attr.Value{v.ToObjectValue(ctx)} - t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["app"] - o.App = types.ListValueMust(t, vs) + vs := v.ToObjectValue(ctx) + o.App = vs } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 45f387b508..8d76cda34a 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -129,9 +129,7 @@ func (o AlertConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o AlertConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ - ElemType: ActionConfiguration{}.Type(ctx), - }, + "action_configurations": basetypes.ListType{ElemType: ActionConfiguration{}.Type(ctx)}, "alert_configuration_id": types.StringType, "quantity_threshold": types.StringType, "quantity_type": types.StringType, @@ -229,17 +227,13 @@ func (o BudgetConfiguration) ToObjectValue(ctx context.Context) basetypes.Object func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ - ElemType: AlertConfiguration{}.Type(ctx), - }, + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, - "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.Type(ctx), - }, - "update_time": types.Int64Type, + "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, + "update_time": types.Int64Type, }, } } @@ -341,12 +335,8 @@ func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) basetypes. func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "tags": basetypes.ListType{ - ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx), - }, - "workspace_id": basetypes.ListType{ - ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx), - }, + "tags": basetypes.ListType{ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx)}, + "workspace_id": basetypes.ListType{ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx)}, }, } } @@ -445,9 +435,7 @@ func (o BudgetConfigurationFilterClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, - "values": basetypes.ListType{ - ElemType: types.StringType, - }, + "values": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -519,10 +507,8 @@ func (o BudgetConfigurationFilterTagClause) ToObjectValue(ctx context.Context) b func (o BudgetConfigurationFilterTagClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "key": types.StringType, - "value": basetypes.ListType{ - ElemType: BudgetConfigurationFilterClause{}.Type(ctx), - }, + "key": types.StringType, + "value": basetypes.ListType{ElemType: BudgetConfigurationFilterClause{}.Type(ctx)}, }, } } @@ -595,9 +581,7 @@ func (o BudgetConfigurationFilterWorkspaceIdClause) Type(ctx context.Context) at return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, - "values": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "values": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -772,14 +756,10 @@ func (o CreateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) base func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx), - }, - "display_name": types.StringType, - "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.Type(ctx), - }, + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx)}, + "display_name": types.StringType, + "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, }, } } @@ -937,13 +917,11 @@ func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx co func (o CreateBudgetConfigurationBudgetAlertConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx), - }, - "quantity_threshold": types.StringType, - "quantity_type": types.StringType, - "time_period": types.StringType, - "trigger_type": types.StringType, + "action_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx)}, + "quantity_threshold": types.StringType, + "quantity_type": types.StringType, + "time_period": types.StringType, + "trigger_type": types.StringType, }, } } @@ -1013,9 +991,7 @@ func (o CreateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) bas func (o CreateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ - ElemType: CreateBudgetConfigurationBudget{}.Type(ctx), - }, + "budget": basetypes.ListType{ElemType: CreateBudgetConfigurationBudget{}.Type(ctx)}, }, } } @@ -1085,9 +1061,7 @@ func (o CreateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) ba func (o CreateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.Type(ctx), - }, + "budget": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, }, } } @@ -1240,9 +1214,7 @@ func (o CreateLogDeliveryConfigurationParams) Type(ctx context.Context) attr.Typ "output_format": types.StringType, "status": types.StringType, "storage_configuration_id": types.StringType, - "workspace_ids_filter": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "workspace_ids_filter": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -1625,9 +1597,7 @@ func (o GetBudgetConfigurationResponse) ToObjectValue(ctx context.Context) baset func (o GetBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.Type(ctx), - }, + "budget": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, }, } } @@ -1788,9 +1758,7 @@ func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) bas func (o ListBudgetConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budgets": basetypes.ListType{ - ElemType: BudgetConfiguration{}.Type(ctx), - }, + "budgets": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2005,24 +1973,20 @@ func (o LogDeliveryConfiguration) ToObjectValue(ctx context.Context) basetypes.O func (o LogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "config_id": types.StringType, - "config_name": types.StringType, - "creation_time": types.Int64Type, - "credentials_id": types.StringType, - "delivery_path_prefix": types.StringType, - "delivery_start_time": types.StringType, - "log_delivery_status": basetypes.ListType{ - ElemType: LogDeliveryStatus{}.Type(ctx), - }, + "account_id": types.StringType, + "config_id": types.StringType, + "config_name": types.StringType, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "delivery_path_prefix": types.StringType, + "delivery_start_time": types.StringType, + "log_delivery_status": basetypes.ListType{ElemType: LogDeliveryStatus{}.Type(ctx)}, "log_type": types.StringType, "output_format": types.StringType, "status": types.StringType, "storage_configuration_id": types.StringType, "update_time": types.Int64Type, - "workspace_ids_filter": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "workspace_ids_filter": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -2237,15 +2201,11 @@ func (o UpdateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) base func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ - ElemType: AlertConfiguration{}.Type(ctx), - }, + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, "budget_configuration_id": types.StringType, "display_name": types.StringType, - "filter": basetypes.ListType{ - ElemType: BudgetConfigurationFilter{}.Type(ctx), - }, + "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, }, } } @@ -2345,9 +2305,7 @@ func (o UpdateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) bas func (o UpdateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ - ElemType: UpdateBudgetConfigurationBudget{}.Type(ctx), - }, + "budget": basetypes.ListType{ElemType: UpdateBudgetConfigurationBudget{}.Type(ctx)}, "budget_id": types.StringType, }, } @@ -2418,9 +2376,7 @@ func (o UpdateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) ba func (o UpdateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ - ElemType: BudgetConfiguration{}.Type(ctx), - }, + "budget": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, }, } } @@ -2539,9 +2495,7 @@ func (o WrappedCreateLogDeliveryConfiguration) ToObjectValue(ctx context.Context func (o WrappedCreateLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configuration": basetypes.ListType{ - ElemType: CreateLogDeliveryConfigurationParams{}.Type(ctx), - }, + "log_delivery_configuration": basetypes.ListType{ElemType: CreateLogDeliveryConfigurationParams{}.Type(ctx)}, }, } } @@ -2610,9 +2564,7 @@ func (o WrappedLogDeliveryConfiguration) ToObjectValue(ctx context.Context) base func (o WrappedLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configuration": basetypes.ListType{ - ElemType: LogDeliveryConfiguration{}.Type(ctx), - }, + "log_delivery_configuration": basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}, }, } } @@ -2681,9 +2633,7 @@ func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) bas func (o WrappedLogDeliveryConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configurations": basetypes.ListType{ - ElemType: LogDeliveryConfiguration{}.Type(ctx), - }, + "log_delivery_configurations": basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}, }, } } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 2c1bf7ab23..0a29009bcb 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -59,9 +59,7 @@ func (o AccountsCreateMetastore) ToObjectValue(ctx context.Context) basetypes.Ob func (o AccountsCreateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_info": basetypes.ListType{ - ElemType: CreateMetastore{}.Type(ctx), - }, + "metastore_info": basetypes.ListType{ElemType: CreateMetastore{}.Type(ctx)}, }, } } @@ -136,11 +134,9 @@ func (o AccountsCreateMetastoreAssignment) ToObjectValue(ctx context.Context) ba func (o AccountsCreateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_assignment": basetypes.ListType{ - ElemType: CreateMetastoreAssignment{}.Type(ctx), - }, - "metastore_id": types.StringType, - "workspace_id": types.Int64Type, + "metastore_assignment": basetypes.ListType{ElemType: CreateMetastoreAssignment{}.Type(ctx)}, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -212,10 +208,8 @@ func (o AccountsCreateStorageCredential) ToObjectValue(ctx context.Context) base func (o AccountsCreateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credential_info": basetypes.ListType{ - ElemType: CreateStorageCredential{}.Type(ctx), - }, - "metastore_id": types.StringType, + "credential_info": basetypes.ListType{ElemType: CreateStorageCredential{}.Type(ctx)}, + "metastore_id": types.StringType, }, } } @@ -284,9 +278,7 @@ func (o AccountsMetastoreAssignment) ToObjectValue(ctx context.Context) basetype func (o AccountsMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_assignment": basetypes.ListType{ - ElemType: MetastoreAssignment{}.Type(ctx), - }, + "metastore_assignment": basetypes.ListType{ElemType: MetastoreAssignment{}.Type(ctx)}, }, } } @@ -355,9 +347,7 @@ func (o AccountsMetastoreInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o AccountsMetastoreInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_info": basetypes.ListType{ - ElemType: MetastoreInfo{}.Type(ctx), - }, + "metastore_info": basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}, }, } } @@ -426,9 +416,7 @@ func (o AccountsStorageCredentialInfo) ToObjectValue(ctx context.Context) basety func (o AccountsStorageCredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credential_info": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.Type(ctx), - }, + "credential_info": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, }, } } @@ -501,10 +489,8 @@ func (o AccountsUpdateMetastore) ToObjectValue(ctx context.Context) basetypes.Ob func (o AccountsUpdateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_id": types.StringType, - "metastore_info": basetypes.ListType{ - ElemType: UpdateMetastore{}.Type(ctx), - }, + "metastore_id": types.StringType, + "metastore_info": basetypes.ListType{ElemType: UpdateMetastore{}.Type(ctx)}, }, } } @@ -579,11 +565,9 @@ func (o AccountsUpdateMetastoreAssignment) ToObjectValue(ctx context.Context) ba func (o AccountsUpdateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_assignment": basetypes.ListType{ - ElemType: UpdateMetastoreAssignment{}.Type(ctx), - }, - "metastore_id": types.StringType, - "workspace_id": types.Int64Type, + "metastore_assignment": basetypes.ListType{ElemType: UpdateMetastoreAssignment{}.Type(ctx)}, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -658,9 +642,7 @@ func (o AccountsUpdateStorageCredential) ToObjectValue(ctx context.Context) base func (o AccountsUpdateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credential_info": basetypes.ListType{ - ElemType: UpdateStorageCredential{}.Type(ctx), - }, + "credential_info": basetypes.ListType{ElemType: UpdateStorageCredential{}.Type(ctx)}, "metastore_id": types.StringType, "storage_credential_name": types.StringType, }, @@ -741,12 +723,10 @@ func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o ArtifactAllowlistInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ - ElemType: ArtifactMatcher{}.Type(ctx), - }, - "created_at": types.Int64Type, - "created_by": types.StringType, - "metastore_id": types.StringType, + "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, + "created_at": types.Int64Type, + "created_by": types.StringType, + "metastore_id": types.StringType, }, } } @@ -1581,38 +1561,30 @@ func (o CatalogInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CatalogInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "browse_only": types.BoolType, - "catalog_type": types.StringType, - "comment": types.StringType, - "connection_name": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), - }, - "enable_predictive_optimization": types.StringType, - "full_name": types.StringType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "options": basetypes.MapType{ - ElemType: types.StringType, - }, - "owner": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, - "provider_name": types.StringType, - "provisioning_info": basetypes.ListType{ - ElemType: ProvisioningInfo{}.Type(ctx), - }, - "securable_kind": types.StringType, - "securable_type": types.StringType, - "share_name": types.StringType, - "storage_location": types.StringType, - "storage_root": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "browse_only": types.BoolType, + "catalog_type": types.StringType, + "comment": types.StringType, + "connection_name": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "effective_predictive_optimization_flag": basetypes.ListType{ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx)}, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ElemType: types.StringType}, + "owner": types.StringType, + "properties": basetypes.MapType{ElemType: types.StringType}, + "provider_name": types.StringType, + "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "share_name": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1843,10 +1815,8 @@ func (o ColumnInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ColumnInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "mask": basetypes.ListType{ - ElemType: ColumnMask{}.Type(ctx), - }, + "comment": types.StringType, + "mask": basetypes.ListType{ElemType: ColumnMask{}.Type(ctx)}, "name": types.StringType, "nullable": types.BoolType, "partition_index": types.Int64Type, @@ -1932,10 +1902,8 @@ func (o ColumnMask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ColumnMask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function_name": types.StringType, - "using_column_names": basetypes.ListType{ - ElemType: types.StringType, - }, + "function_name": types.StringType, + "using_column_names": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -2062,31 +2030,25 @@ func (o ConnectionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ConnectionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "connection_id": types.StringType, - "connection_type": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "credential_type": types.StringType, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "options": basetypes.MapType{ - ElemType: types.StringType, - }, - "owner": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, - "provisioning_info": basetypes.ListType{ - ElemType: ProvisioningInfo{}.Type(ctx), - }, - "read_only": types.BoolType, - "securable_kind": types.StringType, - "securable_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "url": types.StringType, + "comment": types.StringType, + "connection_id": types.StringType, + "connection_type": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "credential_type": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ElemType: types.StringType}, + "owner": types.StringType, + "properties": basetypes.MapType{ElemType: types.StringType}, + "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, + "read_only": types.BoolType, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "url": types.StringType, }, } } @@ -2219,11 +2181,9 @@ func (o ContinuousUpdateStatus) ToObjectValue(ctx context.Context) basetypes.Obj func (o ContinuousUpdateStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "initial_pipeline_sync_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.Type(ctx), - }, - "last_processed_commit_version": types.Int64Type, - "timestamp": types.StringType, + "initial_pipeline_sync_progress": basetypes.ListType{ElemType: PipelineProgress{}.Type(ctx)}, + "last_processed_commit_version": types.Int64Type, + "timestamp": types.StringType, }, } } @@ -2321,15 +2281,11 @@ func (o CreateCatalog) Type(ctx context.Context) attr.Type { "comment": types.StringType, "connection_name": types.StringType, "name": types.StringType, - "options": basetypes.MapType{ - ElemType: types.StringType, - }, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, - "provider_name": types.StringType, - "share_name": types.StringType, - "storage_root": types.StringType, + "options": basetypes.MapType{ElemType: types.StringType}, + "properties": basetypes.MapType{ElemType: types.StringType}, + "provider_name": types.StringType, + "share_name": types.StringType, + "storage_root": types.StringType, }, } } @@ -2445,13 +2401,9 @@ func (o CreateConnection) Type(ctx context.Context) attr.Type { "comment": types.StringType, "connection_type": types.StringType, "name": types.StringType, - "options": basetypes.MapType{ - ElemType: types.StringType, - }, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, - "read_only": types.BoolType, + "options": basetypes.MapType{ElemType: types.StringType}, + "properties": basetypes.MapType{ElemType: types.StringType}, + "read_only": types.BoolType, }, } } @@ -2579,23 +2531,15 @@ func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccount{}.Type(ctx), - }, - "name": types.StringType, - "purpose": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccount{}.Type(ctx)}, + "name": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -2770,17 +2714,15 @@ func (o CreateExternalLocation) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateExternalLocation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "comment": types.StringType, - "credential_name": types.StringType, - "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.Type(ctx), - }, - "fallback": types.BoolType, - "name": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, - "url": types.StringType, + "access_point": types.StringType, + "comment": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, + "fallback": types.BoolType, + "name": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, + "url": types.StringType, }, } } @@ -2916,33 +2858,27 @@ func (o CreateFunction) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CreateFunction) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalog_name": types.StringType, - "comment": types.StringType, - "data_type": types.StringType, - "external_language": types.StringType, - "external_name": types.StringType, - "full_data_type": types.StringType, - "input_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.Type(ctx), - }, - "is_deterministic": types.BoolType, - "is_null_call": types.BoolType, - "name": types.StringType, - "parameter_style": types.StringType, - "properties": types.StringType, - "return_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.Type(ctx), - }, - "routine_body": types.StringType, - "routine_definition": types.StringType, - "routine_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.Type(ctx), - }, - "schema_name": types.StringType, - "security_type": types.StringType, - "specific_name": types.StringType, - "sql_data_access": types.StringType, - "sql_path": types.StringType, + "catalog_name": types.StringType, + "comment": types.StringType, + "data_type": types.StringType, + "external_language": types.StringType, + "external_name": types.StringType, + "full_data_type": types.StringType, + "input_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, + "is_deterministic": types.BoolType, + "is_null_call": types.BoolType, + "name": types.StringType, + "parameter_style": types.StringType, + "properties": types.StringType, + "return_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, + "routine_body": types.StringType, + "routine_definition": types.StringType, + "routine_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, + "schema_name": types.StringType, + "security_type": types.StringType, + "specific_name": types.StringType, + "sql_data_access": types.StringType, + "sql_path": types.StringType, }, } } @@ -3064,9 +3000,7 @@ func (o CreateFunctionRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateFunctionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function_info": basetypes.ListType{ - ElemType: CreateFunction{}.Type(ctx), - }, + "function_info": basetypes.ListType{ElemType: CreateFunction{}.Type(ctx)}, }, } } @@ -3297,36 +3231,20 @@ func (o CreateMonitor) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CreateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets_dir": types.StringType, - "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.Type(ctx), - }, - "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.Type(ctx), - }, - "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.Type(ctx), - }, - "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.Type(ctx), - }, - "output_schema_name": types.StringType, - "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.Type(ctx), - }, - "skip_builtin_dashboard": types.BoolType, - "slicing_exprs": basetypes.ListType{ - ElemType: types.StringType, - }, - "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.Type(ctx), - }, - "table_name": types.StringType, - "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.Type(ctx), - }, - "warehouse_id": types.StringType, + "assets_dir": types.StringType, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, + "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, + "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, + "output_schema_name": types.StringType, + "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, + "skip_builtin_dashboard": types.BoolType, + "slicing_exprs": basetypes.ListType{ElemType: types.StringType}, + "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, + "table_name": types.StringType, + "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "warehouse_id": types.StringType, }, } } @@ -3579,9 +3497,7 @@ func (o CreateOnlineTableRequest) ToObjectValue(ctx context.Context) basetypes.O func (o CreateOnlineTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "table": basetypes.ListType{ - ElemType: OnlineTable{}.Type(ctx), - }, + "table": basetypes.ListType{ElemType: OnlineTable{}.Type(ctx)}, }, } } @@ -3761,9 +3677,7 @@ func (o CreateSchema) Type(ctx context.Context) attr.Type { "catalog_name": types.StringType, "comment": types.StringType, "name": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, + "properties": basetypes.MapType{ElemType: types.StringType}, "storage_root": types.StringType, }, } @@ -3863,25 +3777,15 @@ func (o CreateStorageCredential) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityRequest{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.Type(ctx), - }, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), - }, - "name": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleRequest{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityRequest{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx)}, + "name": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -4060,9 +3964,7 @@ func (o CreateTableConstraint) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateTableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "constraint": basetypes.ListType{ - ElemType: TableConstraint{}.Type(ctx), - }, + "constraint": basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}, "full_name_arg": types.StringType, }, } @@ -4255,32 +4157,24 @@ func (o CredentialInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccount{}.Type(ctx), - }, - "full_name": types.StringType, - "id": types.StringType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "purpose": types.StringType, - "read_only": types.BoolType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "used_for_managed_storage": types.BoolType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccount{}.Type(ctx)}, + "full_name": types.StringType, + "id": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "used_for_managed_storage": types.BoolType, }, } } @@ -4475,9 +4369,7 @@ func (o CurrentWorkspaceBindings) ToObjectValue(ctx context.Context) basetypes.O func (o CurrentWorkspaceBindings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "workspaces": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "workspaces": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -5680,9 +5572,7 @@ func (o DeltaRuntimePropertiesKvPairs) ToObjectValue(ctx context.Context) basety func (o DeltaRuntimePropertiesKvPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "delta_runtime_properties": basetypes.MapType{ - ElemType: types.StringType, - }, + "delta_runtime_properties": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -5758,12 +5648,8 @@ func (o Dependency) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Dependency) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function": basetypes.ListType{ - ElemType: FunctionDependency{}.Type(ctx), - }, - "table": basetypes.ListType{ - ElemType: TableDependency{}.Type(ctx), - }, + "function": basetypes.ListType{ElemType: FunctionDependency{}.Type(ctx)}, + "table": basetypes.ListType{ElemType: TableDependency{}.Type(ctx)}, }, } } @@ -5860,9 +5746,7 @@ func (o DependencyList) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o DependencyList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dependencies": basetypes.ListType{ - ElemType: Dependency{}.Type(ctx), - }, + "dependencies": basetypes.ListType{ElemType: Dependency{}.Type(ctx)}, }, } } @@ -6016,9 +5900,7 @@ func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) basetypes.O func (o EffectivePermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ - ElemType: EffectivePrivilegeAssignment{}.Type(ctx), - }, + "privilege_assignments": basetypes.ListType{ElemType: EffectivePrivilegeAssignment{}.Type(ctx)}, }, } } @@ -6199,10 +6081,8 @@ func (o EffectivePrivilegeAssignment) ToObjectValue(ctx context.Context) basetyp func (o EffectivePrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principal": types.StringType, - "privileges": basetypes.ListType{ - ElemType: EffectivePrivilege{}.Type(ctx), - }, + "principal": types.StringType, + "privileges": basetypes.ListType{ElemType: EffectivePrivilege{}.Type(ctx)}, }, } } @@ -6356,9 +6236,7 @@ func (o EncryptionDetails) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o EncryptionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "sse_encryption_details": basetypes.ListType{ - ElemType: SseEncryptionDetails{}.Type(ctx), - }, + "sse_encryption_details": basetypes.ListType{ElemType: SseEncryptionDetails{}.Type(ctx)}, }, } } @@ -6524,25 +6402,23 @@ func (o ExternalLocationInfo) ToObjectValue(ctx context.Context) basetypes.Objec func (o ExternalLocationInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "browse_only": types.BoolType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "credential_id": types.StringType, - "credential_name": types.StringType, - "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.Type(ctx), - }, - "fallback": types.BoolType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "url": types.StringType, + "access_point": types.StringType, + "browse_only": types.BoolType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "credential_id": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, + "fallback": types.BoolType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "url": types.StringType, }, } } @@ -6675,14 +6551,10 @@ func (o ForeignKeyConstraint) ToObjectValue(ctx context.Context) basetypes.Objec func (o ForeignKeyConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "child_columns": basetypes.ListType{ - ElemType: types.StringType, - }, - "name": types.StringType, - "parent_columns": basetypes.ListType{ - ElemType: types.StringType, - }, - "parent_table": types.StringType, + "child_columns": basetypes.ListType{ElemType: types.StringType}, + "name": types.StringType, + "parent_columns": basetypes.ListType{ElemType: types.StringType}, + "parent_table": types.StringType, }, } } @@ -6918,42 +6790,36 @@ func (o FunctionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o FunctionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "data_type": types.StringType, - "external_language": types.StringType, - "external_name": types.StringType, - "full_data_type": types.StringType, - "full_name": types.StringType, - "function_id": types.StringType, - "input_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.Type(ctx), - }, - "is_deterministic": types.BoolType, - "is_null_call": types.BoolType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "parameter_style": types.StringType, - "properties": types.StringType, - "return_params": basetypes.ListType{ - ElemType: FunctionParameterInfos{}.Type(ctx), - }, - "routine_body": types.StringType, - "routine_definition": types.StringType, - "routine_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.Type(ctx), - }, - "schema_name": types.StringType, - "security_type": types.StringType, - "specific_name": types.StringType, - "sql_data_access": types.StringType, - "sql_path": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_type": types.StringType, + "external_language": types.StringType, + "external_name": types.StringType, + "full_data_type": types.StringType, + "full_name": types.StringType, + "function_id": types.StringType, + "input_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, + "is_deterministic": types.BoolType, + "is_null_call": types.BoolType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "parameter_style": types.StringType, + "properties": types.StringType, + "return_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, + "routine_body": types.StringType, + "routine_definition": types.StringType, + "routine_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, + "schema_name": types.StringType, + "security_type": types.StringType, + "specific_name": types.StringType, + "sql_data_access": types.StringType, + "sql_path": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -7162,9 +7028,7 @@ func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) basetypes.Obj func (o FunctionParameterInfos) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ - ElemType: FunctionParameterInfo{}.Type(ctx), - }, + "parameters": basetypes.ListType{ElemType: FunctionParameterInfo{}.Type(ctx)}, }, } } @@ -7280,9 +7144,7 @@ func (o GenerateTemporaryServiceCredentialAzureOptions) ToObjectValue(ctx contex func (o GenerateTemporaryServiceCredentialAzureOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "resources": basetypes.ListType{ - ElemType: types.StringType, - }, + "resources": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7355,9 +7217,7 @@ func (o GenerateTemporaryServiceCredentialGcpOptions) ToObjectValue(ctx context. func (o GenerateTemporaryServiceCredentialGcpOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scopes": basetypes.ListType{ - ElemType: types.StringType, - }, + "scopes": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7435,13 +7295,9 @@ func (o GenerateTemporaryServiceCredentialRequest) ToObjectValue(ctx context.Con func (o GenerateTemporaryServiceCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "azure_options": basetypes.ListType{ - ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.Type(ctx), - }, + "azure_options": basetypes.ListType{ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.Type(ctx)}, "credential_name": types.StringType, - "gcp_options": basetypes.ListType{ - ElemType: GenerateTemporaryServiceCredentialGcpOptions{}.Type(ctx), - }, + "gcp_options": basetypes.ListType{ElemType: GenerateTemporaryServiceCredentialGcpOptions{}.Type(ctx)}, }, } } @@ -7614,23 +7470,13 @@ func (o GenerateTemporaryTableCredentialResponse) ToObjectValue(ctx context.Cont func (o GenerateTemporaryTableCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_temp_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.Type(ctx), - }, - "azure_aad": basetypes.ListType{ - ElemType: AzureActiveDirectoryToken{}.Type(ctx), - }, - "azure_user_delegation_sas": basetypes.ListType{ - ElemType: AzureUserDelegationSas{}.Type(ctx), - }, - "expiration_time": types.Int64Type, - "gcp_oauth_token": basetypes.ListType{ - ElemType: GcpOauthToken{}.Type(ctx), - }, - "r2_temp_credentials": basetypes.ListType{ - ElemType: R2Credentials{}.Type(ctx), - }, - "url": types.StringType, + "aws_temp_credentials": basetypes.ListType{ElemType: AwsCredentials{}.Type(ctx)}, + "azure_aad": basetypes.ListType{ElemType: AzureActiveDirectoryToken{}.Type(ctx)}, + "azure_user_delegation_sas": basetypes.ListType{ElemType: AzureUserDelegationSas{}.Type(ctx)}, + "expiration_time": types.Int64Type, + "gcp_oauth_token": basetypes.ListType{ElemType: GcpOauthToken{}.Type(ctx)}, + "r2_temp_credentials": basetypes.ListType{ElemType: R2Credentials{}.Type(ctx)}, + "url": types.StringType, }, } } @@ -8784,9 +8630,7 @@ func (o GetQuotaResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o GetQuotaResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "quota_info": basetypes.ListType{ - ElemType: QuotaInfo{}.Type(ctx), - }, + "quota_info": basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}, }, } } @@ -9188,9 +9032,7 @@ func (o ListAccountMetastoreAssignmentsResponse) ToObjectValue(ctx context.Conte func (o ListAccountMetastoreAssignmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "workspace_ids": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "workspace_ids": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -9303,9 +9145,7 @@ func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context func (o ListAccountStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "storage_credentials": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.Type(ctx), - }, + "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, }, } } @@ -9440,9 +9280,7 @@ func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListCatalogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalogs": basetypes.ListType{ - ElemType: CatalogInfo{}.Type(ctx), - }, + "catalogs": basetypes.ListType{ElemType: CatalogInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9570,9 +9408,7 @@ func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListConnectionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "connections": basetypes.ListType{ - ElemType: ConnectionInfo{}.Type(ctx), - }, + "connections": basetypes.ListType{ElemType: ConnectionInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9702,9 +9538,7 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ - ElemType: CredentialInfo{}.Type(ctx), - }, + "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9837,10 +9671,8 @@ func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) basety func (o ListExternalLocationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "external_locations": basetypes.ListType{ - ElemType: ExternalLocationInfo{}.Type(ctx), - }, - "next_page_token": types.StringType, + "external_locations": basetypes.ListType{ElemType: ExternalLocationInfo{}.Type(ctx)}, + "next_page_token": types.StringType, }, } } @@ -9980,9 +9812,7 @@ func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListFunctionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "functions": basetypes.ListType{ - ElemType: FunctionInfo{}.Type(ctx), - }, + "functions": basetypes.ListType{ElemType: FunctionInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -10053,9 +9883,7 @@ func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListMetastoresResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastores": basetypes.ListType{ - ElemType: MetastoreInfo{}.Type(ctx), - }, + "metastores": basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}, }, } } @@ -10192,9 +10020,7 @@ func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ - ElemType: ModelVersionInfo{}.Type(ctx), - }, + "model_versions": basetypes.ListType{ElemType: ModelVersionInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -10318,9 +10144,7 @@ func (o ListQuotasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "quotas": basetypes.ListType{ - ElemType: QuotaInfo{}.Type(ctx), - }, + "quotas": basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}, }, } } @@ -10515,10 +10339,8 @@ func (o ListRegisteredModelsResponse) ToObjectValue(ctx context.Context) basetyp func (o ListRegisteredModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ - ElemType: RegisteredModelInfo{}.Type(ctx), - }, + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ElemType: RegisteredModelInfo{}.Type(ctx)}, }, } } @@ -10655,9 +10477,7 @@ func (o ListSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ - ElemType: SchemaInfo{}.Type(ctx), - }, + "schemas": basetypes.ListType{ElemType: SchemaInfo{}.Type(ctx)}, }, } } @@ -10784,10 +10604,8 @@ func (o ListStorageCredentialsResponse) ToObjectValue(ctx context.Context) baset func (o ListStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "storage_credentials": basetypes.ListType{ - ElemType: StorageCredentialInfo{}.Type(ctx), - }, + "next_page_token": types.StringType, + "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, }, } } @@ -10990,9 +10808,7 @@ func (o ListSystemSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ - ElemType: SystemSchemaInfo{}.Type(ctx), - }, + "schemas": basetypes.ListType{ElemType: SystemSchemaInfo{}.Type(ctx)}, }, } } @@ -11068,9 +10884,7 @@ func (o ListTableSummariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ - ElemType: TableSummary{}.Type(ctx), - }, + "tables": basetypes.ListType{ElemType: TableSummary{}.Type(ctx)}, }, } } @@ -11232,9 +11046,7 @@ func (o ListTablesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ - ElemType: TableInfo{}.Type(ctx), - }, + "tables": basetypes.ListType{ElemType: TableInfo{}.Type(ctx)}, }, } } @@ -11382,9 +11194,7 @@ func (o ListVolumesResponseContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "volumes": basetypes.ListType{ - ElemType: VolumeInfo{}.Type(ctx), - }, + "volumes": basetypes.ListType{ElemType: VolumeInfo{}.Type(ctx)}, }, } } @@ -11689,29 +11499,25 @@ func (o ModelVersionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ - ElemType: RegisteredModelAlias{}.Type(ctx), - }, - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "id": types.StringType, - "metastore_id": types.StringType, - "model_name": types.StringType, - "model_version_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.Type(ctx), - }, - "run_id": types.StringType, - "run_workspace_id": types.Int64Type, - "schema_name": types.StringType, - "source": types.StringType, - "status": types.StringType, - "storage_location": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "version": types.Int64Type, + "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "id": types.StringType, + "metastore_id": types.StringType, + "model_name": types.StringType, + "model_version_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, + "run_id": types.StringType, + "run_workspace_id": types.Int64Type, + "schema_name": types.StringType, + "source": types.StringType, + "status": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "version": types.Int64Type, }, } } @@ -11903,9 +11709,7 @@ func (o MonitorDestination) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o MonitorDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "email_addresses": basetypes.ListType{ - ElemType: types.StringType, - }, + "email_addresses": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -12007,9 +11811,7 @@ func (o MonitorInferenceLog) ToObjectValue(ctx context.Context) basetypes.Object func (o MonitorInferenceLog) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "granularities": basetypes.ListType{ - ElemType: types.StringType, - }, + "granularities": basetypes.ListType{ElemType: types.StringType}, "label_col": types.StringType, "model_id_col": types.StringType, "prediction_col": types.StringType, @@ -12156,40 +11958,24 @@ func (o MonitorInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o MonitorInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets_dir": types.StringType, - "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.Type(ctx), - }, - "dashboard_id": types.StringType, - "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.Type(ctx), - }, - "drift_metrics_table_name": types.StringType, - "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.Type(ctx), - }, + "assets_dir": types.StringType, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "dashboard_id": types.StringType, + "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, + "drift_metrics_table_name": types.StringType, + "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, "latest_monitor_failure_msg": types.StringType, "monitor_version": types.StringType, - "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.Type(ctx), - }, + "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, "output_schema_name": types.StringType, "profile_metrics_table_name": types.StringType, - "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.Type(ctx), - }, - "slicing_exprs": basetypes.ListType{ - ElemType: types.StringType, - }, - "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.Type(ctx), - }, - "status": types.StringType, - "table_name": types.StringType, - "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.Type(ctx), - }, + "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, + "slicing_exprs": basetypes.ListType{ElemType: types.StringType}, + "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, + "status": types.StringType, + "table_name": types.StringType, + "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, }, } } @@ -12467,10 +12253,8 @@ func (o MonitorMetric) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o MonitorMetric) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "definition": types.StringType, - "input_columns": basetypes.ListType{ - ElemType: types.StringType, - }, + "definition": types.StringType, + "input_columns": basetypes.ListType{ElemType: types.StringType}, "name": types.StringType, "output_data_type": types.StringType, "type": types.StringType, @@ -12548,12 +12332,8 @@ func (o MonitorNotifications) ToObjectValue(ctx context.Context) basetypes.Objec func (o MonitorNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "on_failure": basetypes.ListType{ - ElemType: MonitorDestination{}.Type(ctx), - }, - "on_new_classification_tag_detected": basetypes.ListType{ - ElemType: MonitorDestination{}.Type(ctx), - }, + "on_failure": basetypes.ListType{ElemType: MonitorDestination{}.Type(ctx)}, + "on_new_classification_tag_detected": basetypes.ListType{ElemType: MonitorDestination{}.Type(ctx)}, }, } } @@ -12714,9 +12494,7 @@ func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) basetypes func (o MonitorRefreshListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "refreshes": basetypes.ListType{ - ElemType: MonitorRefreshInfo{}.Type(ctx), - }, + "refreshes": basetypes.ListType{ElemType: MonitorRefreshInfo{}.Type(ctx)}, }, } } @@ -12833,9 +12611,7 @@ func (o MonitorTimeSeries) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o MonitorTimeSeries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "granularities": basetypes.ListType{ - ElemType: types.StringType, - }, + "granularities": basetypes.ListType{ElemType: types.StringType}, "timestamp_col": types.StringType, }, } @@ -12965,13 +12741,9 @@ func (o OnlineTable) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o OnlineTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "spec": basetypes.ListType{ - ElemType: OnlineTableSpec{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: OnlineTableStatus{}.Type(ctx), - }, + "name": types.StringType, + "spec": basetypes.ListType{ElemType: OnlineTableSpec{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: OnlineTableStatus{}.Type(ctx)}, "table_serving_url": types.StringType, "unity_catalog_provisioning_state": types.StringType, }, @@ -13099,17 +12871,11 @@ func (o OnlineTableSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o OnlineTableSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "perform_full_copy": types.BoolType, - "pipeline_id": types.StringType, - "primary_key_columns": basetypes.ListType{ - ElemType: types.StringType, - }, - "run_continuously": basetypes.ListType{ - ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.Type(ctx), - }, - "run_triggered": basetypes.ListType{ - ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.Type(ctx), - }, + "perform_full_copy": types.BoolType, + "pipeline_id": types.StringType, + "primary_key_columns": basetypes.ListType{ElemType: types.StringType}, + "run_continuously": basetypes.ListType{ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.Type(ctx)}, + "run_triggered": basetypes.ListType{ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.Type(ctx)}, "source_table_full_name": types.StringType, "timeseries_key": types.StringType, }, @@ -13329,20 +13095,12 @@ func (o OnlineTableStatus) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o OnlineTableStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "continuous_update_status": basetypes.ListType{ - ElemType: ContinuousUpdateStatus{}.Type(ctx), - }, - "detailed_state": types.StringType, - "failed_status": basetypes.ListType{ - ElemType: FailedStatus{}.Type(ctx), - }, - "message": types.StringType, - "provisioning_status": basetypes.ListType{ - ElemType: ProvisioningStatus{}.Type(ctx), - }, - "triggered_update_status": basetypes.ListType{ - ElemType: TriggeredUpdateStatus{}.Type(ctx), - }, + "continuous_update_status": basetypes.ListType{ElemType: ContinuousUpdateStatus{}.Type(ctx)}, + "detailed_state": types.StringType, + "failed_status": basetypes.ListType{ElemType: FailedStatus{}.Type(ctx)}, + "message": types.StringType, + "provisioning_status": basetypes.ListType{ElemType: ProvisioningStatus{}.Type(ctx)}, + "triggered_update_status": basetypes.ListType{ElemType: TriggeredUpdateStatus{}.Type(ctx)}, }, } } @@ -13497,13 +13255,9 @@ func (o PermissionsChange) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o PermissionsChange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add": basetypes.ListType{ - ElemType: types.StringType, - }, + "add": basetypes.ListType{ElemType: types.StringType}, "principal": types.StringType, - "remove": basetypes.ListType{ - ElemType: types.StringType, - }, + "remove": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -13599,9 +13353,7 @@ func (o PermissionsList) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ - ElemType: PrivilegeAssignment{}.Type(ctx), - }, + "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, }, } } @@ -13735,10 +13487,8 @@ func (o PrimaryKeyConstraint) ToObjectValue(ctx context.Context) basetypes.Objec func (o PrimaryKeyConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "child_columns": basetypes.ListType{ - ElemType: types.StringType, - }, - "name": types.StringType, + "child_columns": basetypes.ListType{ElemType: types.StringType}, + "name": types.StringType, }, } } @@ -13811,10 +13561,8 @@ func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.Object func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principal": types.StringType, - "privileges": basetypes.ListType{ - ElemType: types.StringType, - }, + "principal": types.StringType, + "privileges": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -13929,9 +13677,7 @@ func (o ProvisioningStatus) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ProvisioningStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "initial_pipeline_sync_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.Type(ctx), - }, + "initial_pipeline_sync_progress": basetypes.ListType{ElemType: PipelineProgress{}.Type(ctx)}, }, } } @@ -14348,9 +14094,7 @@ func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) basetypes.Object func (o RegisteredModelInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ - ElemType: RegisteredModelAlias{}.Type(ctx), - }, + "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -14531,28 +14275,24 @@ func (o SchemaInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SchemaInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "catalog_type": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), - }, - "enable_predictive_optimization": types.StringType, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, - "schema_id": types.StringType, - "storage_location": types.StringType, - "storage_root": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "catalog_type": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "effective_predictive_optimization_flag": basetypes.ListType{ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx)}, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "properties": basetypes.MapType{ElemType: types.StringType}, + "schema_id": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -14651,10 +14391,8 @@ func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) basetypes.Objec func (o SetArtifactAllowlist) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ - ElemType: ArtifactMatcher{}.Type(ctx), - }, - "artifact_type": types.StringType, + "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, + "artifact_type": types.StringType, }, } } @@ -14878,34 +14616,24 @@ func (o StorageCredentialInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o StorageCredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleResponse{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityResponse{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.Type(ctx), - }, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountResponse{}.Type(ctx), - }, - "full_name": types.StringType, - "id": types.StringType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "used_for_managed_storage": types.BoolType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleResponse{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityResponse{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountResponse{}.Type(ctx)}, + "full_name": types.StringType, + "id": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "used_for_managed_storage": types.BoolType, }, } } @@ -15136,15 +14864,9 @@ func (o TableConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o TableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "foreign_key_constraint": basetypes.ListType{ - ElemType: ForeignKeyConstraint{}.Type(ctx), - }, - "named_table_constraint": basetypes.ListType{ - ElemType: NamedTableConstraint{}.Type(ctx), - }, - "primary_key_constraint": basetypes.ListType{ - ElemType: PrimaryKeyConstraint{}.Type(ctx), - }, + "foreign_key_constraint": basetypes.ListType{ElemType: ForeignKeyConstraint{}.Type(ctx)}, + "named_table_constraint": basetypes.ListType{ElemType: NamedTableConstraint{}.Type(ctx)}, + "primary_key_constraint": basetypes.ListType{ElemType: PrimaryKeyConstraint{}.Type(ctx)}, }, } } @@ -15465,54 +15187,38 @@ func (o TableInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o TableInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.Type(ctx), - }, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "data_access_configuration_id": types.StringType, - "data_source_format": types.StringType, - "deleted_at": types.Int64Type, - "delta_runtime_properties_kvpairs": basetypes.ListType{ - ElemType: DeltaRuntimePropertiesKvPairs{}.Type(ctx), - }, - "effective_predictive_optimization_flag": basetypes.ListType{ - ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), - }, - "enable_predictive_optimization": types.StringType, - "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.Type(ctx), - }, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "pipeline_id": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, - "row_filter": basetypes.ListType{ - ElemType: TableRowFilter{}.Type(ctx), - }, - "schema_name": types.StringType, - "sql_path": types.StringType, - "storage_credential_name": types.StringType, - "storage_location": types.StringType, - "table_constraints": basetypes.ListType{ - ElemType: TableConstraint{}.Type(ctx), - }, - "table_id": types.StringType, - "table_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "view_definition": types.StringType, - "view_dependencies": basetypes.ListType{ - ElemType: DependencyList{}.Type(ctx), - }, + "access_point": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_access_configuration_id": types.StringType, + "data_source_format": types.StringType, + "deleted_at": types.Int64Type, + "delta_runtime_properties_kvpairs": basetypes.ListType{ElemType: DeltaRuntimePropertiesKvPairs{}.Type(ctx)}, + "effective_predictive_optimization_flag": basetypes.ListType{ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx)}, + "enable_predictive_optimization": types.StringType, + "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "pipeline_id": types.StringType, + "properties": basetypes.MapType{ElemType: types.StringType}, + "row_filter": basetypes.ListType{ElemType: TableRowFilter{}.Type(ctx)}, + "schema_name": types.StringType, + "sql_path": types.StringType, + "storage_credential_name": types.StringType, + "storage_location": types.StringType, + "table_constraints": basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}, + "table_id": types.StringType, + "table_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "view_definition": types.StringType, + "view_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, }, } } @@ -15769,10 +15475,8 @@ func (o TableRowFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o TableRowFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function_name": types.StringType, - "input_column_names": basetypes.ListType{ - ElemType: types.StringType, - }, + "function_name": types.StringType, + "input_column_names": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -15899,13 +15603,9 @@ func (o TemporaryCredentials) ToObjectValue(ctx context.Context) basetypes.Objec func (o TemporaryCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_temp_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.Type(ctx), - }, - "azure_aad": basetypes.ListType{ - ElemType: AzureActiveDirectoryToken{}.Type(ctx), - }, - "expiration_time": types.Int64Type, + "aws_temp_credentials": basetypes.ListType{ElemType: AwsCredentials{}.Type(ctx)}, + "azure_aad": basetypes.ListType{ElemType: AzureActiveDirectoryToken{}.Type(ctx)}, + "expiration_time": types.Int64Type, }, } } @@ -16014,9 +15714,7 @@ func (o TriggeredUpdateStatus) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "last_processed_commit_version": types.Int64Type, "timestamp": types.StringType, - "triggered_update_progress": basetypes.ListType{ - ElemType: PipelineProgress{}.Type(ctx), - }, + "triggered_update_progress": basetypes.ListType{ElemType: PipelineProgress{}.Type(ctx)}, }, } } @@ -16231,9 +15929,7 @@ func (o UpdateCatalog) Type(ctx context.Context) attr.Type { "name": types.StringType, "new_name": types.StringType, "owner": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, + "properties": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -16314,10 +16010,8 @@ func (o UpdateConnection) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "name": types.StringType, "new_name": types.StringType, - "options": basetypes.MapType{ - ElemType: types.StringType, - }, - "owner": types.StringType, + "options": basetypes.MapType{ElemType: types.StringType}, + "owner": types.StringType, }, } } @@ -16430,26 +16124,18 @@ func (o UpdateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccount{}.Type(ctx), - }, - "force": types.BoolType, - "isolation_mode": types.StringType, - "name_arg": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccount{}.Type(ctx)}, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name_arg": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -16637,21 +16323,19 @@ func (o UpdateExternalLocation) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateExternalLocation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "comment": types.StringType, - "credential_name": types.StringType, - "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.Type(ctx), - }, - "fallback": types.BoolType, - "force": types.BoolType, - "isolation_mode": types.StringType, - "name": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, - "url": types.StringType, + "access_point": types.StringType, + "comment": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, + "fallback": types.BoolType, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, + "url": types.StringType, }, } } @@ -16991,34 +16675,18 @@ func (o UpdateMonitor) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o UpdateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ - ElemType: MonitorMetric{}.Type(ctx), - }, - "dashboard_id": types.StringType, - "data_classification_config": basetypes.ListType{ - ElemType: MonitorDataClassificationConfig{}.Type(ctx), - }, - "inference_log": basetypes.ListType{ - ElemType: MonitorInferenceLog{}.Type(ctx), - }, - "notifications": basetypes.ListType{ - ElemType: MonitorNotifications{}.Type(ctx), - }, - "output_schema_name": types.StringType, - "schedule": basetypes.ListType{ - ElemType: MonitorCronSchedule{}.Type(ctx), - }, - "slicing_exprs": basetypes.ListType{ - ElemType: types.StringType, - }, - "snapshot": basetypes.ListType{ - ElemType: MonitorSnapshot{}.Type(ctx), - }, - "table_name": types.StringType, - "time_series": basetypes.ListType{ - ElemType: MonitorTimeSeries{}.Type(ctx), - }, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "dashboard_id": types.StringType, + "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, + "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, + "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, + "output_schema_name": types.StringType, + "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, + "slicing_exprs": basetypes.ListType{ElemType: types.StringType}, + "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, + "table_name": types.StringType, + "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, }, } } @@ -17276,9 +16944,7 @@ func (o UpdatePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdatePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ - ElemType: PermissionsChange{}.Type(ctx), - }, + "changes": basetypes.ListType{ElemType: PermissionsChange{}.Type(ctx)}, "full_name": types.StringType, "securable_type": types.StringType, }, @@ -17461,9 +17127,7 @@ func (o UpdateSchema) Type(ctx context.Context) attr.Type { "full_name": types.StringType, "new_name": types.StringType, "owner": types.StringType, - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, + "properties": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -17575,29 +17239,19 @@ func (o UpdateStorageCredential) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityResponse{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.Type(ctx), - }, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), - }, - "force": types.BoolType, - "isolation_mode": types.StringType, - "name": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleRequest{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityResponse{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx)}, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -17879,13 +17533,9 @@ func (o UpdateWorkspaceBindings) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateWorkspaceBindings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assign_workspaces": basetypes.ListType{ - ElemType: types.Int64Type, - }, - "name": types.StringType, - "unassign_workspaces": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "assign_workspaces": basetypes.ListType{ElemType: types.Int64Type}, + "name": types.StringType, + "unassign_workspaces": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -17991,12 +17641,8 @@ func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) ba func (o UpdateWorkspaceBindingsParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add": basetypes.ListType{ - ElemType: WorkspaceBinding{}.Type(ctx), - }, - "remove": basetypes.ListType{ - ElemType: WorkspaceBinding{}.Type(ctx), - }, + "add": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, + "remove": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, "securable_name": types.StringType, "securable_type": types.StringType, }, @@ -18118,12 +17764,8 @@ func (o ValidateCredentialRequest) ToObjectValue(ctx context.Context) basetypes. func (o ValidateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRole{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentity{}.Type(ctx), - }, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, "credential_name": types.StringType, "external_location_name": types.StringType, "purpose": types.StringType, @@ -18228,10 +17870,8 @@ func (o ValidateCredentialResponse) ToObjectValue(ctx context.Context) basetypes func (o ValidateCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "isDir": types.BoolType, - "results": basetypes.ListType{ - ElemType: CredentialValidationResult{}.Type(ctx), - }, + "isDir": types.BoolType, + "results": basetypes.ListType{ElemType: CredentialValidationResult{}.Type(ctx)}, }, } } @@ -18329,25 +17969,15 @@ func (o ValidateStorageCredential) ToObjectValue(ctx context.Context) basetypes. func (o ValidateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ - ElemType: AwsIamRoleRequest{}.Type(ctx), - }, - "azure_managed_identity": basetypes.ListType{ - ElemType: AzureManagedIdentityRequest{}.Type(ctx), - }, - "azure_service_principal": basetypes.ListType{ - ElemType: AzureServicePrincipal{}.Type(ctx), - }, - "cloudflare_api_token": basetypes.ListType{ - ElemType: CloudflareApiToken{}.Type(ctx), - }, - "databricks_gcp_service_account": basetypes.ListType{ - ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), - }, - "external_location_name": types.StringType, - "read_only": types.BoolType, - "storage_credential_name": types.StringType, - "url": types.StringType, + "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleRequest{}.Type(ctx)}, + "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityRequest{}.Type(ctx)}, + "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, + "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, + "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx)}, + "external_location_name": types.StringType, + "read_only": types.BoolType, + "storage_credential_name": types.StringType, + "url": types.StringType, }, } } @@ -18524,10 +18154,8 @@ func (o ValidateStorageCredentialResponse) ToObjectValue(ctx context.Context) ba func (o ValidateStorageCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "isDir": types.BoolType, - "results": basetypes.ListType{ - ElemType: ValidationResult{}.Type(ctx), - }, + "isDir": types.BoolType, + "results": basetypes.ListType{ElemType: ValidationResult{}.Type(ctx)}, }, } } @@ -18697,25 +18325,23 @@ func (o VolumeInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o VolumeInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "encryption_details": basetypes.ListType{ - ElemType: EncryptionDetails{}.Type(ctx), - }, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "schema_name": types.StringType, - "storage_location": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "volume_id": types.StringType, - "volume_type": types.StringType, + "access_point": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "schema_name": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "volume_id": types.StringType, + "volume_type": types.StringType, }, } } @@ -18836,9 +18462,7 @@ func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) basetypes. func (o WorkspaceBindingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "bindings": basetypes.ListType{ - ElemType: WorkspaceBinding{}.Type(ctx), - }, + "bindings": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, "next_page_token": types.StringType, }, } diff --git a/internal/service/cleanrooms_tf/model.go b/internal/service/cleanrooms_tf/model.go index 8ff8e18842..191ab84573 100755 --- a/internal/service/cleanrooms_tf/model.go +++ b/internal/service/cleanrooms_tf/model.go @@ -107,15 +107,11 @@ func (o CleanRoom) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "local_collaborator_alias": types.StringType, "name": types.StringType, - "output_catalog": basetypes.ListType{ - ElemType: CleanRoomOutputCatalog{}.Type(ctx), - }, - "owner": types.StringType, - "remote_detailed_info": basetypes.ListType{ - ElemType: CleanRoomRemoteDetail{}.Type(ctx), - }, - "status": types.StringType, - "updated_at": types.Int64Type, + "output_catalog": basetypes.ListType{ElemType: CleanRoomOutputCatalog{}.Type(ctx)}, + "owner": types.StringType, + "remote_detailed_info": basetypes.ListType{ElemType: CleanRoomRemoteDetail{}.Type(ctx)}, + "status": types.StringType, + "updated_at": types.Int64Type, }, } } @@ -269,35 +265,19 @@ func (o CleanRoomAsset) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CleanRoomAsset) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "added_at": types.Int64Type, - "asset_type": types.StringType, - "foreign_table": basetypes.ListType{ - ElemType: CleanRoomAssetForeignTable{}.Type(ctx), - }, - "foreign_table_local_details": basetypes.ListType{ - ElemType: CleanRoomAssetForeignTableLocalDetails{}.Type(ctx), - }, - "name": types.StringType, - "notebook": basetypes.ListType{ - ElemType: CleanRoomAssetNotebook{}.Type(ctx), - }, - "owner_collaborator_alias": types.StringType, - "status": types.StringType, - "table": basetypes.ListType{ - ElemType: CleanRoomAssetTable{}.Type(ctx), - }, - "table_local_details": basetypes.ListType{ - ElemType: CleanRoomAssetTableLocalDetails{}.Type(ctx), - }, - "view": basetypes.ListType{ - ElemType: CleanRoomAssetView{}.Type(ctx), - }, - "view_local_details": basetypes.ListType{ - ElemType: CleanRoomAssetViewLocalDetails{}.Type(ctx), - }, - "volume_local_details": basetypes.ListType{ - ElemType: CleanRoomAssetVolumeLocalDetails{}.Type(ctx), - }, + "added_at": types.Int64Type, + "asset_type": types.StringType, + "foreign_table": basetypes.ListType{ElemType: CleanRoomAssetForeignTable{}.Type(ctx)}, + "foreign_table_local_details": basetypes.ListType{ElemType: CleanRoomAssetForeignTableLocalDetails{}.Type(ctx)}, + "name": types.StringType, + "notebook": basetypes.ListType{ElemType: CleanRoomAssetNotebook{}.Type(ctx)}, + "owner_collaborator_alias": types.StringType, + "status": types.StringType, + "table": basetypes.ListType{ElemType: CleanRoomAssetTable{}.Type(ctx)}, + "table_local_details": basetypes.ListType{ElemType: CleanRoomAssetTableLocalDetails{}.Type(ctx)}, + "view": basetypes.ListType{ElemType: CleanRoomAssetView{}.Type(ctx)}, + "view_local_details": basetypes.ListType{ElemType: CleanRoomAssetViewLocalDetails{}.Type(ctx)}, + "volume_local_details": basetypes.ListType{ElemType: CleanRoomAssetVolumeLocalDetails{}.Type(ctx)}, }, } } @@ -549,9 +529,7 @@ func (o CleanRoomAssetForeignTable) ToObjectValue(ctx context.Context) basetypes func (o CleanRoomAssetForeignTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ - ElemType: catalog_tf.ColumnInfo{}.Type(ctx), - }, + "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, }, } } @@ -711,9 +689,7 @@ func (o CleanRoomAssetTable) ToObjectValue(ctx context.Context) basetypes.Object func (o CleanRoomAssetTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ - ElemType: catalog_tf.ColumnInfo{}.Type(ctx), - }, + "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, }, } } @@ -788,9 +764,7 @@ func (o CleanRoomAssetTableLocalDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "local_name": types.StringType, - "partitions": basetypes.ListType{ - ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx), - }, + "partitions": basetypes.ListType{ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx)}, }, } } @@ -860,9 +834,7 @@ func (o CleanRoomAssetView) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CleanRoomAssetView) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ - ElemType: catalog_tf.ColumnInfo{}.Type(ctx), - }, + "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, }, } } @@ -1123,12 +1095,8 @@ func (o CleanRoomNotebookTaskRun) ToObjectValue(ctx context.Context) basetypes.O func (o CleanRoomNotebookTaskRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "collaborator_job_run_info": basetypes.ListType{ - ElemType: CollaboratorJobRunInfo{}.Type(ctx), - }, - "notebook_job_run_state": basetypes.ListType{ - ElemType: jobs_tf.CleanRoomTaskRunState{}.Type(ctx), - }, + "collaborator_job_run_info": basetypes.ListType{ElemType: CollaboratorJobRunInfo{}.Type(ctx)}, + "notebook_job_run_state": basetypes.ListType{ElemType: jobs_tf.CleanRoomTaskRunState{}.Type(ctx)}, "notebook_name": types.StringType, "output_schema_expiration_time": types.Int64Type, "output_schema_name": types.StringType, @@ -1307,21 +1275,13 @@ func (o CleanRoomRemoteDetail) ToObjectValue(ctx context.Context) basetypes.Obje func (o CleanRoomRemoteDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "central_clean_room_id": types.StringType, - "cloud_vendor": types.StringType, - "collaborators": basetypes.ListType{ - ElemType: CleanRoomCollaborator{}.Type(ctx), - }, - "compliance_security_profile": basetypes.ListType{ - ElemType: ComplianceSecurityProfile{}.Type(ctx), - }, - "creator": basetypes.ListType{ - ElemType: CleanRoomCollaborator{}.Type(ctx), - }, - "egress_network_policy": basetypes.ListType{ - ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx), - }, - "region": types.StringType, + "central_clean_room_id": types.StringType, + "cloud_vendor": types.StringType, + "collaborators": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, + "compliance_security_profile": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, + "creator": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, + "egress_network_policy": basetypes.ListType{ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx)}, + "region": types.StringType, }, } } @@ -1513,7 +1473,7 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existin // SDK values. func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "compliance_standards": reflect.TypeOf(types.String{}), + "compliance_standards": reflect.TypeOf(settings_tf.ComplianceStandard{}), } } @@ -1533,22 +1493,20 @@ func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) basetypes. func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ - ElemType: types.String{}.Type(ctx), - }, - "is_enabled": types.BoolType, + "compliance_standards": basetypes.ListType{ElemType: settings_tf.ComplianceStandard{}.Type(ctx)}, + "is_enabled": types.BoolType, }, } } // GetComplianceStandards returns the value of the ComplianceStandards field in ComplianceSecurityProfile as -// a slice of types.String values. +// a slice of settings_tf.ComplianceStandard values. // If the field is unknown or null, the boolean return value is false. -func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) ([]types.String, bool) { +func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) ([]settings_tf.ComplianceStandard, bool) { if o.ComplianceStandards.IsNull() || o.ComplianceStandards.IsUnknown() { return nil, false } - var v []types.String + var v []settings_tf.ComplianceStandard d := o.ComplianceStandards.ElementsAs(ctx, &v, true) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) @@ -1557,10 +1515,10 @@ func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) } // SetComplianceStandards sets the value of the ComplianceStandards field in ComplianceSecurityProfile. -func (o *ComplianceSecurityProfile) SetComplianceStandards(ctx context.Context, v []types.String) { +func (o *ComplianceSecurityProfile) SetComplianceStandards(ctx context.Context, v []settings_tf.ComplianceStandard) { vs := make([]attr.Value, 0, len(v)) for _, e := range v { - vs = append(vs, e) + vs = append(vs, e.ToObjectValue(ctx)) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_standards"] t = t.(attr.TypeWithElementType).ElementType() @@ -1610,9 +1568,7 @@ func (o CreateCleanRoomAssetRequest) ToObjectValue(ctx context.Context) basetype func (o CreateCleanRoomAssetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "asset": basetypes.ListType{ - ElemType: CleanRoomAsset{}.Type(ctx), - }, + "asset": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, "clean_room_name": types.StringType, }, } @@ -1688,9 +1644,7 @@ func (o CreateCleanRoomOutputCatalogRequest) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clean_room_name": types.StringType, - "output_catalog": basetypes.ListType{ - ElemType: CleanRoomOutputCatalog{}.Type(ctx), - }, + "output_catalog": basetypes.ListType{ElemType: CleanRoomOutputCatalog{}.Type(ctx)}, }, } } @@ -1759,9 +1713,7 @@ func (o CreateCleanRoomOutputCatalogResponse) ToObjectValue(ctx context.Context) func (o CreateCleanRoomOutputCatalogResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "output_catalog": basetypes.ListType{ - ElemType: CleanRoomOutputCatalog{}.Type(ctx), - }, + "output_catalog": basetypes.ListType{ElemType: CleanRoomOutputCatalog{}.Type(ctx)}, }, } } @@ -1831,9 +1783,7 @@ func (o CreateCleanRoomRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateCleanRoomRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_room": basetypes.ListType{ - ElemType: CleanRoom{}.Type(ctx), - }, + "clean_room": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, }, } } @@ -2218,9 +2168,7 @@ func (o ListCleanRoomAssetsResponse) ToObjectValue(ctx context.Context) basetype func (o ListCleanRoomAssetsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ - ElemType: CleanRoomAsset{}.Type(ctx), - }, + "assets": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2352,9 +2300,7 @@ func (o ListCleanRoomNotebookTaskRunsResponse) Type(ctx context.Context) attr.Ty return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ - ElemType: CleanRoomNotebookTaskRun{}.Type(ctx), - }, + "runs": basetypes.ListType{ElemType: CleanRoomNotebookTaskRun{}.Type(ctx)}, }, } } @@ -2476,9 +2422,7 @@ func (o ListCleanRoomsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListCleanRoomsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_rooms": basetypes.ListType{ - ElemType: CleanRoom{}.Type(ctx), - }, + "clean_rooms": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2565,9 +2509,7 @@ func (o UpdateCleanRoomAssetRequest) ToObjectValue(ctx context.Context) basetype func (o UpdateCleanRoomAssetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "asset": basetypes.ListType{ - ElemType: CleanRoomAsset{}.Type(ctx), - }, + "asset": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, "asset_type": types.StringType, "clean_room_name": types.StringType, "name": types.StringType, @@ -2642,10 +2584,8 @@ func (o UpdateCleanRoomRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateCleanRoomRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_room": basetypes.ListType{ - ElemType: CleanRoom{}.Type(ctx), - }, - "name": types.StringType, + "clean_room": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, + "name": types.StringType, }, } } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index ad9792e562..4c000e2c98 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -426,11 +426,9 @@ func (o AzureAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o AzureAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "availability": types.StringType, - "first_on_demand": types.Int64Type, - "log_analytics_info": basetypes.ListType{ - ElemType: LogAnalyticsInfo{}.Type(ctx), - }, + "availability": types.StringType, + "first_on_demand": types.Int64Type, + "log_analytics_info": basetypes.ListType{ElemType: LogAnalyticsInfo{}.Type(ctx)}, "spot_bid_max_price": types.Float64Type, }, } @@ -755,9 +753,7 @@ func (o CloudProviderNodeInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o CloudProviderNodeInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "status": basetypes.ListType{ - ElemType: types.StringType, - }, + "status": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -893,9 +889,7 @@ func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) basetyp func (o ClusterAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: ClusterPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: ClusterPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -1130,52 +1124,30 @@ func (o ClusterAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ClusterAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.Type(ctx), - }, - "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.Type(ctx), - }, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.Type(ctx), - }, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -1517,9 +1489,7 @@ func (o ClusterCompliance) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "is_compliant": types.BoolType, - "violations": basetypes.MapType{ - ElemType: types.StringType, - }, + "violations": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -1861,87 +1831,51 @@ func (o ClusterDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ClusterDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.Type(ctx), - }, - "cluster_cores": types.Float64Type, - "cluster_id": types.StringType, - "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.Type(ctx), - }, - "cluster_log_status": basetypes.ListType{ - ElemType: LogSyncStatus{}.Type(ctx), - }, - "cluster_memory_mb": types.Int64Type, - "cluster_name": types.StringType, - "cluster_source": types.StringType, - "creator_user_name": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "data_security_mode": types.StringType, - "default_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, - "driver": basetypes.ListType{ - ElemType: SparkNode{}.Type(ctx), - }, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_cores": types.Float64Type, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_log_status": basetypes.ListType{ElemType: LogSyncStatus{}.Type(ctx)}, + "cluster_memory_mb": types.Int64Type, + "cluster_name": types.StringType, + "cluster_source": types.StringType, + "creator_user_name": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "data_security_mode": types.StringType, + "default_tags": basetypes.MapType{ElemType: types.StringType}, + "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "driver": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "executors": basetypes.ListType{ - ElemType: SparkNode{}.Type(ctx), - }, - "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "jdbc_port": types.Int64Type, - "last_restarted_time": types.Int64Type, - "last_state_loss_time": types.Int64Type, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_context_id": types.Int64Type, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_version": types.StringType, - "spec": basetypes.ListType{ - ElemType: ClusterSpec{}.Type(ctx), - }, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "start_time": types.Int64Type, - "state": types.StringType, - "state_message": types.StringType, - "terminated_time": types.Int64Type, - "termination_reason": basetypes.ListType{ - ElemType: TerminationReason{}.Type(ctx), - }, - "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.Type(ctx), - }, + "executors": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "jdbc_port": types.Int64Type, + "last_restarted_time": types.Int64Type, + "last_state_loss_time": types.Int64Type, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_context_id": types.Int64Type, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "spark_version": types.StringType, + "spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "start_time": types.Int64Type, + "state": types.StringType, + "state_message": types.StringType, + "terminated_time": types.Int64Type, + "termination_reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -2468,15 +2402,11 @@ func (o ClusterEvent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ClusterEvent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "data_plane_event_details": basetypes.ListType{ - ElemType: DataPlaneEventDetails{}.Type(ctx), - }, - "details": basetypes.ListType{ - ElemType: EventDetails{}.Type(ctx), - }, - "timestamp": types.Int64Type, - "type": types.StringType, + "cluster_id": types.StringType, + "data_plane_event_details": basetypes.ListType{ElemType: DataPlaneEventDetails{}.Type(ctx)}, + "details": basetypes.ListType{ElemType: EventDetails{}.Type(ctx)}, + "timestamp": types.Int64Type, + "type": types.StringType, }, } } @@ -2575,10 +2505,8 @@ func (o ClusterLibraryStatuses) ToObjectValue(ctx context.Context) basetypes.Obj func (o ClusterLibraryStatuses) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "library_statuses": basetypes.ListType{ - ElemType: LibraryFullStatus{}.Type(ctx), - }, + "cluster_id": types.StringType, + "library_statuses": basetypes.ListType{ElemType: LibraryFullStatus{}.Type(ctx)}, }, } } @@ -2657,12 +2585,8 @@ func (o ClusterLogConf) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ClusterLogConf) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbfs": basetypes.ListType{ - ElemType: DbfsStorageInfo{}.Type(ctx), - }, - "s3": basetypes.ListType{ - ElemType: S3StorageInfo{}.Type(ctx), - }, + "dbfs": basetypes.ListType{ElemType: DbfsStorageInfo{}.Type(ctx)}, + "s3": basetypes.ListType{ElemType: S3StorageInfo{}.Type(ctx)}, }, } } @@ -2763,11 +2687,9 @@ func (o ClusterPermission) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ClusterPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -2842,11 +2764,9 @@ func (o ClusterPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ClusterPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ClusterAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2963,10 +2883,8 @@ func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) basetypes. func (o ClusterPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ClusterAccessControlRequest{}.Type(ctx), - }, - "cluster_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlRequest{}.Type(ctx)}, + "cluster_id": types.StringType, }, } } @@ -3102,9 +3020,7 @@ func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) b func (o ClusterPolicyAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: ClusterPolicyPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: ClusterPolicyPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3183,11 +3099,9 @@ func (o ClusterPolicyPermission) ToObjectValue(ctx context.Context) basetypes.Ob func (o ClusterPolicyPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -3262,11 +3176,9 @@ func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) basetypes.O func (o ClusterPolicyPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3383,10 +3295,8 @@ func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) base func (o ClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx), - }, - "cluster_policy_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx)}, + "cluster_policy_id": types.StringType, }, } } @@ -3528,9 +3438,7 @@ func (o ClusterSize) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ClusterSize) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, "num_workers": types.Int64Type, }, } @@ -3785,57 +3693,33 @@ func (o ClusterSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ClusterSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.Type(ctx), - }, - "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.Type(ctx), - }, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.Type(ctx), - }, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -4343,11 +4227,9 @@ func (o CommandStatusResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o CommandStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "results": basetypes.ListType{ - ElemType: Results{}.Type(ctx), - }, - "status": types.StringType, + "id": types.StringType, + "results": basetypes.ListType{ElemType: Results{}.Type(ctx)}, + "status": types.StringType, }, } } @@ -4697,60 +4579,34 @@ func (o CreateCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CreateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.Type(ctx), - }, - "clone_from": basetypes.ListType{ - ElemType: CloneCluster{}.Type(ctx), - }, - "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.Type(ctx), - }, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "clone_from": basetypes.ListType{ElemType: CloneCluster{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.Type(ctx), - }, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -5289,33 +5145,19 @@ func (o CreateInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.Type(ctx), - }, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.Type(ctx), - }, - "enable_elastic_disk": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.Type(ctx), - }, + "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_name": types.StringType, "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, - "preloaded_spark_versions": basetypes.ListType{ - ElemType: types.StringType, - }, + "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -5620,11 +5462,9 @@ func (o CreatePolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreatePolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "definition": types.StringType, - "description": types.StringType, - "libraries": basetypes.ListType{ - ElemType: Library{}.Type(ctx), - }, + "definition": types.StringType, + "description": types.StringType, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -6351,9 +6191,7 @@ func (o DiskSpec) Type(ctx context.Context) attr.Type { "disk_iops": types.Int64Type, "disk_size": types.Int64Type, "disk_throughput": types.Int64Type, - "disk_type": basetypes.ListType{ - ElemType: DiskType{}.Type(ctx), - }, + "disk_type": basetypes.ListType{ElemType: DiskType{}.Type(ctx)}, }, } } @@ -6516,10 +6354,8 @@ func (o DockerImage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DockerImage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "basic_auth": basetypes.ListType{ - ElemType: DockerBasicAuth{}.Type(ctx), - }, - "url": types.StringType, + "basic_auth": basetypes.ListType{ElemType: DockerBasicAuth{}.Type(ctx)}, + "url": types.StringType, }, } } @@ -6776,58 +6612,34 @@ func (o EditCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EditCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.Type(ctx), - }, - "cluster_id": types.StringType, - "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.Type(ctx), - }, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.Type(ctx), - }, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -7254,9 +7066,7 @@ func (o EditInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o EditInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, "instance_pool_name": types.StringType, @@ -7408,11 +7218,9 @@ func (o EditPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EditPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "definition": types.StringType, - "description": types.StringType, - "libraries": basetypes.ListType{ - ElemType: Library{}.Type(ctx), - }, + "definition": types.StringType, + "description": types.StringType, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -7611,9 +7419,7 @@ func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) bas func (o EnforceClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ - ElemType: ClusterSettingsChange{}.Type(ctx), - }, + "changes": basetypes.ListType{ElemType: ClusterSettingsChange{}.Type(ctx)}, "has_changes": types.BoolType, }, } @@ -7698,10 +7504,8 @@ func (o Environment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Environment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "client": types.StringType, - "dependencies": basetypes.ListType{ - ElemType: types.StringType, - }, + "client": types.StringType, + "dependencies": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7841,38 +7645,26 @@ func (o EventDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attributes": basetypes.ListType{ - ElemType: ClusterAttributes{}.Type(ctx), - }, - "cause": types.StringType, - "cluster_size": basetypes.ListType{ - ElemType: ClusterSize{}.Type(ctx), - }, - "current_num_vcpus": types.Int64Type, - "current_num_workers": types.Int64Type, - "did_not_expand_reason": types.StringType, - "disk_size": types.Int64Type, - "driver_state_message": types.StringType, + "attributes": basetypes.ListType{ElemType: ClusterAttributes{}.Type(ctx)}, + "cause": types.StringType, + "cluster_size": basetypes.ListType{ElemType: ClusterSize{}.Type(ctx)}, + "current_num_vcpus": types.Int64Type, + "current_num_workers": types.Int64Type, + "did_not_expand_reason": types.StringType, + "disk_size": types.Int64Type, + "driver_state_message": types.StringType, "enable_termination_for_node_blocklisted": types.BoolType, - "free_space": types.Int64Type, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptEventDetails{}.Type(ctx), - }, - "instance_id": types.StringType, - "job_run_name": types.StringType, - "previous_attributes": basetypes.ListType{ - ElemType: ClusterAttributes{}.Type(ctx), - }, - "previous_cluster_size": basetypes.ListType{ - ElemType: ClusterSize{}.Type(ctx), - }, - "previous_disk_size": types.Int64Type, - "reason": basetypes.ListType{ - ElemType: TerminationReason{}.Type(ctx), - }, - "target_num_vcpus": types.Int64Type, - "target_num_workers": types.Int64Type, - "user": types.StringType, + "free_space": types.Int64Type, + "init_scripts": basetypes.ListType{ElemType: InitScriptEventDetails{}.Type(ctx)}, + "instance_id": types.StringType, + "job_run_name": types.StringType, + "previous_attributes": basetypes.ListType{ElemType: ClusterAttributes{}.Type(ctx)}, + "previous_cluster_size": basetypes.ListType{ElemType: ClusterSize{}.Type(ctx)}, + "previous_disk_size": types.Int64Type, + "reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, + "target_num_vcpus": types.Int64Type, + "target_num_workers": types.Int64Type, + "user": types.StringType, }, } } @@ -8247,9 +8039,7 @@ func (o GetClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, - "violations": basetypes.MapType{ - ElemType: types.StringType, - }, + "violations": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -8362,9 +8152,7 @@ func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) b func (o GetClusterPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: ClusterPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: ClusterPermissionsDescription{}.Type(ctx)}, }, } } @@ -8520,9 +8308,7 @@ func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Cont func (o GetClusterPolicyPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx)}, }, } } @@ -8745,15 +8531,13 @@ func (o GetEvents) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GetEvents) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "end_time": types.Int64Type, - "event_types": basetypes.ListType{ - ElemType: types.StringType, - }, - "limit": types.Int64Type, - "offset": types.Int64Type, - "order": types.StringType, - "start_time": types.Int64Type, + "cluster_id": types.StringType, + "end_time": types.Int64Type, + "event_types": basetypes.ListType{ElemType: types.StringType}, + "limit": types.Int64Type, + "offset": types.Int64Type, + "order": types.StringType, + "start_time": types.Int64Type, }, } } @@ -8832,12 +8616,8 @@ func (o GetEventsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o GetEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ - ElemType: ClusterEvent{}.Type(ctx), - }, - "next_page": basetypes.ListType{ - ElemType: GetEvents{}.Type(ctx), - }, + "events": basetypes.ListType{ElemType: ClusterEvent{}.Type(ctx)}, + "next_page": basetypes.ListType{ElemType: GetEvents{}.Type(ctx)}, "total_count": types.Int64Type, }, } @@ -9074,44 +8854,24 @@ func (o GetInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.Type(ctx), - }, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "default_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.Type(ctx), - }, - "enable_elastic_disk": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.Type(ctx), - }, + "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "default_tags": basetypes.MapType{ElemType: types.StringType}, + "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, "instance_pool_name": types.StringType, "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, - "preloaded_spark_versions": basetypes.ListType{ - ElemType: types.StringType, - }, - "state": types.StringType, - "stats": basetypes.ListType{ - ElemType: InstancePoolStats{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: InstancePoolStatus{}.Type(ctx), - }, + "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, + "state": types.StringType, + "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, }, } } @@ -9458,9 +9218,7 @@ func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Conte func (o GetInstancePoolPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: InstancePoolPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: InstancePoolPermissionsDescription{}.Type(ctx)}, }, } } @@ -9664,9 +9422,7 @@ func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetSparkVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "versions": basetypes.ListType{ - ElemType: SparkVersion{}.Type(ctx), - }, + "versions": basetypes.ListType{ElemType: SparkVersion{}.Type(ctx)}, }, } } @@ -10026,12 +9782,8 @@ func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) basetypes.Obj func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), - }, - "global": basetypes.ListType{ - ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), - }, + "cluster": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, + "global": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, "reported_for_node": types.StringType, }, } @@ -10213,27 +9965,13 @@ func (o InitScriptInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o InitScriptInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "abfss": basetypes.ListType{ - ElemType: Adlsgen2Info{}.Type(ctx), - }, - "dbfs": basetypes.ListType{ - ElemType: DbfsStorageInfo{}.Type(ctx), - }, - "file": basetypes.ListType{ - ElemType: LocalFileInfo{}.Type(ctx), - }, - "gcs": basetypes.ListType{ - ElemType: GcsStorageInfo{}.Type(ctx), - }, - "s3": basetypes.ListType{ - ElemType: S3StorageInfo{}.Type(ctx), - }, - "volumes": basetypes.ListType{ - ElemType: VolumesStorageInfo{}.Type(ctx), - }, - "workspace": basetypes.ListType{ - ElemType: WorkspaceStorageInfo{}.Type(ctx), - }, + "abfss": basetypes.ListType{ElemType: Adlsgen2Info{}.Type(ctx)}, + "dbfs": basetypes.ListType{ElemType: DbfsStorageInfo{}.Type(ctx)}, + "file": basetypes.ListType{ElemType: LocalFileInfo{}.Type(ctx)}, + "gcs": basetypes.ListType{ElemType: GcsStorageInfo{}.Type(ctx)}, + "s3": basetypes.ListType{ElemType: S3StorageInfo{}.Type(ctx)}, + "volumes": basetypes.ListType{ElemType: VolumesStorageInfo{}.Type(ctx)}, + "workspace": basetypes.ListType{ElemType: WorkspaceStorageInfo{}.Type(ctx)}, }, } } @@ -10463,12 +10201,8 @@ func (o InitScriptInfoAndExecutionDetails) ToObjectValue(ctx context.Context) ba func (o InitScriptInfoAndExecutionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "execution_details": basetypes.ListType{ - ElemType: InitScriptExecutionDetails{}.Type(ctx), - }, - "script": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, + "execution_details": basetypes.ListType{ElemType: InitScriptExecutionDetails{}.Type(ctx)}, + "script": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, }, } } @@ -10568,9 +10302,7 @@ func (o InstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ - ElemType: Library{}.Type(ctx), - }, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, }, } } @@ -10742,9 +10474,7 @@ func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) ba func (o InstancePoolAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: InstancePoolPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: InstancePoolPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -10915,44 +10645,24 @@ func (o InstancePoolAndStats) ToObjectValue(ctx context.Context) basetypes.Objec func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ - ElemType: InstancePoolAwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: InstancePoolAzureAttributes{}.Type(ctx), - }, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "default_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "disk_spec": basetypes.ListType{ - ElemType: DiskSpec{}.Type(ctx), - }, - "enable_elastic_disk": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: InstancePoolGcpAttributes{}.Type(ctx), - }, + "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "default_tags": basetypes.MapType{ElemType: types.StringType}, + "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, "instance_pool_name": types.StringType, "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, - "preloaded_spark_versions": basetypes.ListType{ - ElemType: types.StringType, - }, - "state": types.StringType, - "stats": basetypes.ListType{ - ElemType: InstancePoolStats{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: InstancePoolStatus{}.Type(ctx), - }, + "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, + "state": types.StringType, + "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, }, } } @@ -11456,11 +11166,9 @@ func (o InstancePoolPermission) ToObjectValue(ctx context.Context) basetypes.Obj func (o InstancePoolPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -11535,11 +11243,9 @@ func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) basetypes.Ob func (o InstancePoolPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: InstancePoolAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -11656,10 +11362,8 @@ func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) baset func (o InstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: InstancePoolAccessControlRequest{}.Type(ctx), - }, - "instance_pool_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlRequest{}.Type(ctx)}, + "instance_pool_id": types.StringType, }, } } @@ -11786,9 +11490,7 @@ func (o InstancePoolStatus) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o InstancePoolStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "pending_instance_errors": basetypes.ListType{ - ElemType: PendingInstanceError{}.Type(ctx), - }, + "pending_instance_errors": basetypes.ListType{ElemType: PendingInstanceError{}.Type(ctx)}, }, } } @@ -11959,17 +11661,11 @@ func (o Library) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Library) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cran": basetypes.ListType{ - ElemType: RCranLibrary{}.Type(ctx), - }, - "egg": types.StringType, - "jar": types.StringType, - "maven": basetypes.ListType{ - ElemType: MavenLibrary{}.Type(ctx), - }, - "pypi": basetypes.ListType{ - ElemType: PythonPyPiLibrary{}.Type(ctx), - }, + "cran": basetypes.ListType{ElemType: RCranLibrary{}.Type(ctx)}, + "egg": types.StringType, + "jar": types.StringType, + "maven": basetypes.ListType{ElemType: MavenLibrary{}.Type(ctx)}, + "pypi": basetypes.ListType{ElemType: PythonPyPiLibrary{}.Type(ctx)}, "requirements": types.StringType, "whl": types.StringType, }, @@ -12107,13 +11803,9 @@ func (o LibraryFullStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_library_for_all_clusters": types.BoolType, - "library": basetypes.ListType{ - ElemType: Library{}.Type(ctx), - }, - "messages": basetypes.ListType{ - ElemType: types.StringType, - }, - "status": types.StringType, + "library": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "messages": basetypes.ListType{ElemType: types.StringType}, + "status": types.StringType, }, } } @@ -12209,9 +11901,7 @@ func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context func (o ListAllClusterLibraryStatusesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "statuses": basetypes.ListType{ - ElemType: ClusterLibraryStatuses{}.Type(ctx), - }, + "statuses": basetypes.ListType{ElemType: ClusterLibraryStatuses{}.Type(ctx)}, }, } } @@ -12286,9 +11976,7 @@ func (o ListAvailableZonesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_zone": types.StringType, - "zones": basetypes.ListType{ - ElemType: types.StringType, - }, + "zones": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -12421,9 +12109,7 @@ func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) baset func (o ListClusterCompliancesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ - ElemType: ClusterCompliance{}.Type(ctx), - }, + "clusters": basetypes.ListType{ElemType: ClusterCompliance{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12555,14 +12241,10 @@ func (o ListClustersFilterBy) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListClustersFilterBy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_sources": basetypes.ListType{ - ElemType: types.StringType, - }, - "cluster_states": basetypes.ListType{ - ElemType: types.StringType, - }, - "is_pinned": types.BoolType, - "policy_id": types.StringType, + "cluster_sources": basetypes.ListType{ElemType: types.StringType}, + "cluster_states": basetypes.ListType{ElemType: types.StringType}, + "is_pinned": types.BoolType, + "policy_id": types.StringType, }, } } @@ -12672,14 +12354,10 @@ func (o ListClustersRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o ListClustersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter_by": basetypes.ListType{ - ElemType: ListClustersFilterBy{}.Type(ctx), - }, + "filter_by": basetypes.ListType{ElemType: ListClustersFilterBy{}.Type(ctx)}, "page_size": types.Int64Type, "page_token": types.StringType, - "sort_by": basetypes.ListType{ - ElemType: ListClustersSortBy{}.Type(ctx), - }, + "sort_by": basetypes.ListType{ElemType: ListClustersSortBy{}.Type(ctx)}, }, } } @@ -12784,9 +12462,7 @@ func (o ListClustersResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListClustersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ - ElemType: ClusterDetails{}.Type(ctx), - }, + "clusters": basetypes.ListType{ElemType: ClusterDetails{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12905,9 +12581,7 @@ func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) basety func (o ListGlobalInitScriptsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scripts": basetypes.ListType{ - ElemType: GlobalInitScriptDetails{}.Type(ctx), - }, + "scripts": basetypes.ListType{ElemType: GlobalInitScriptDetails{}.Type(ctx)}, }, } } @@ -12976,9 +12650,7 @@ func (o ListInstancePools) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListInstancePools) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_pools": basetypes.ListType{ - ElemType: InstancePoolAndStats{}.Type(ctx), - }, + "instance_pools": basetypes.ListType{ElemType: InstancePoolAndStats{}.Type(ctx)}, }, } } @@ -13048,9 +12720,7 @@ func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) basetyp func (o ListInstanceProfilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_profiles": basetypes.ListType{ - ElemType: InstanceProfile{}.Type(ctx), - }, + "instance_profiles": basetypes.ListType{ElemType: InstanceProfile{}.Type(ctx)}, }, } } @@ -13120,9 +12790,7 @@ func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListNodeTypesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "node_types": basetypes.ListType{ - ElemType: NodeType{}.Type(ctx), - }, + "node_types": basetypes.ListType{ElemType: NodeType{}.Type(ctx)}, }, } } @@ -13192,9 +12860,7 @@ func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListPoliciesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "policies": basetypes.ListType{ - ElemType: Policy{}.Type(ctx), - }, + "policies": basetypes.ListType{ElemType: Policy{}.Type(ctx)}, }, } } @@ -13316,9 +12982,7 @@ func (o ListPolicyFamiliesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "policy_families": basetypes.ListType{ - ElemType: PolicyFamily{}.Type(ctx), - }, + "policy_families": basetypes.ListType{ElemType: PolicyFamily{}.Type(ctx)}, }, } } @@ -13536,10 +13200,8 @@ func (o MavenLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "coordinates": types.StringType, - "exclusions": basetypes.ListType{ - ElemType: types.StringType, - }, - "repo": types.StringType, + "exclusions": basetypes.ListType{ElemType: types.StringType}, + "repo": types.StringType, }, } } @@ -13742,12 +13404,8 @@ func (o NodeType) Type(ctx context.Context) attr.Type { "is_hidden": types.BoolType, "is_io_cache_enabled": types.BoolType, "memory_mb": types.Int64Type, - "node_info": basetypes.ListType{ - ElemType: CloudProviderNodeInfo{}.Type(ctx), - }, - "node_instance_type": basetypes.ListType{ - ElemType: NodeInstanceType{}.Type(ctx), - }, + "node_info": basetypes.ListType{ElemType: CloudProviderNodeInfo{}.Type(ctx)}, + "node_instance_type": basetypes.ListType{ElemType: NodeInstanceType{}.Type(ctx)}, "node_type_id": types.StringType, "num_cores": types.Float64Type, "num_gpus": types.Int64Type, @@ -14107,14 +13765,12 @@ func (o Policy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Policy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "created_at_timestamp": types.Int64Type, - "creator_user_name": types.StringType, - "definition": types.StringType, - "description": types.StringType, - "is_default": types.BoolType, - "libraries": basetypes.ListType{ - ElemType: Library{}.Type(ctx), - }, + "created_at_timestamp": types.Int64Type, + "creator_user_name": types.StringType, + "definition": types.StringType, + "description": types.StringType, + "is_default": types.BoolType, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -14437,9 +14093,7 @@ func (o ResizeCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResizeCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, "cluster_id": types.StringType, "num_workers": types.Int64Type, }, @@ -14658,22 +14312,16 @@ func (o Results) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Results) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "data": types.ObjectType{}, - "fileName": types.StringType, - "fileNames": basetypes.ListType{ - ElemType: types.StringType, - }, + "cause": types.StringType, + "data": types.ObjectType{}, + "fileName": types.StringType, + "fileNames": basetypes.ListType{ElemType: types.StringType}, "isJsonSchema": types.BoolType, "pos": types.Int64Type, "resultType": types.StringType, - "schema": basetypes.ListType{ - ElemType: basetypes.MapType{ - ElemType: types.ObjectType{}, - }, - }, - "summary": types.StringType, - "truncated": types.BoolType, + "schema": basetypes.ListType{ElemType: basetypes.MapType{ElemType: types.ObjectType{}}}, + "summary": types.StringType, + "truncated": types.BoolType, }, } } @@ -14880,15 +14528,13 @@ func (o SparkNode) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SparkNode) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "host_private_ip": types.StringType, - "instance_id": types.StringType, - "node_aws_attributes": basetypes.ListType{ - ElemType: SparkNodeAwsAttributes{}.Type(ctx), - }, - "node_id": types.StringType, - "private_ip": types.StringType, - "public_dns": types.StringType, - "start_timestamp": types.Int64Type, + "host_private_ip": types.StringType, + "instance_id": types.StringType, + "node_aws_attributes": basetypes.ListType{ElemType: SparkNodeAwsAttributes{}.Type(ctx)}, + "node_id": types.StringType, + "private_ip": types.StringType, + "public_dns": types.StringType, + "start_timestamp": types.Int64Type, }, } } @@ -15135,11 +14781,9 @@ func (o TerminationReason) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o TerminationReason) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "code": types.StringType, - "parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "type": types.StringType, + "code": types.StringType, + "parameters": basetypes.MapType{ElemType: types.StringType}, + "type": types.StringType, }, } } @@ -15213,9 +14857,7 @@ func (o UninstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ - ElemType: Library{}.Type(ctx), - }, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, }, } } @@ -15409,9 +15051,7 @@ func (o UpdateCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o UpdateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ - ElemType: UpdateClusterResource{}.Type(ctx), - }, + "cluster": basetypes.ListType{ElemType: UpdateClusterResource{}.Type(ctx)}, "cluster_id": types.StringType, "update_mask": types.StringType, }, @@ -15662,56 +15302,32 @@ func (o UpdateClusterResource) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ - ElemType: AutoScale{}.Type(ctx), - }, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ - ElemType: AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: AzureAttributes{}.Type(ctx), - }, - "cluster_log_conf": basetypes.ListType{ - ElemType: ClusterLogConf{}.Type(ctx), - }, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ - ElemType: DockerImage{}.Type(ctx), - }, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "workload_type": basetypes.ListType{ - ElemType: WorkloadType{}.Type(ctx), - }, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -16181,9 +15797,7 @@ func (o WorkloadType) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o WorkloadType) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clients": basetypes.ListType{ - ElemType: ClientsTypes{}.Type(ctx), - }, + "clients": basetypes.ListType{ElemType: ClientsTypes{}.Type(ctx)}, }, } } diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index c77ba8ef1f..cbb72a4262 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -61,9 +61,7 @@ func (o CreateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboard": basetypes.ListType{ - ElemType: Dashboard{}.Type(ctx), - }, + "dashboard": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, }, } } @@ -138,9 +136,7 @@ func (o CreateScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, - "schedule": basetypes.ListType{ - ElemType: Schedule{}.Type(ctx), - }, + "schedule": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, }, } } @@ -219,9 +215,7 @@ func (o CreateSubscriptionRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule_id": types.StringType, - "subscription": basetypes.ListType{ - ElemType: Subscription{}.Type(ctx), - }, + "subscription": basetypes.ListType{ElemType: Subscription{}.Type(ctx)}, }, } } @@ -618,12 +612,8 @@ func (o GenieAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GenieAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query": basetypes.ListType{ - ElemType: QueryAttachment{}.Type(ctx), - }, - "text": basetypes.ListType{ - ElemType: TextAttachment{}.Type(ctx), - }, + "query": basetypes.ListType{ElemType: QueryAttachment{}.Type(ctx)}, + "text": basetypes.ListType{ElemType: TextAttachment{}.Type(ctx)}, }, } } @@ -987,9 +977,7 @@ func (o GenieGetMessageQueryResultResponse) ToObjectValue(ctx context.Context) b func (o GenieGetMessageQueryResultResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "statement_response": basetypes.ListType{ - ElemType: sql_tf.StatementResponse{}.Type(ctx), - }, + "statement_response": basetypes.ListType{ElemType: sql_tf.StatementResponse{}.Type(ctx)}, }, } } @@ -1106,23 +1094,17 @@ func (o GenieMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GenieMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attachments": basetypes.ListType{ - ElemType: GenieAttachment{}.Type(ctx), - }, - "content": types.StringType, - "conversation_id": types.StringType, - "created_timestamp": types.Int64Type, - "error": basetypes.ListType{ - ElemType: MessageError{}.Type(ctx), - }, + "attachments": basetypes.ListType{ElemType: GenieAttachment{}.Type(ctx)}, + "content": types.StringType, + "conversation_id": types.StringType, + "created_timestamp": types.Int64Type, + "error": basetypes.ListType{ElemType: MessageError{}.Type(ctx)}, "id": types.StringType, "last_updated_timestamp": types.Int64Type, - "query_result": basetypes.ListType{ - ElemType: Result{}.Type(ctx), - }, - "space_id": types.StringType, - "status": types.StringType, - "user_id": types.Int64Type, + "query_result": basetypes.ListType{ElemType: Result{}.Type(ctx)}, + "space_id": types.StringType, + "status": types.StringType, + "user_id": types.Int64Type, }, } } @@ -1300,14 +1282,10 @@ func (o GenieStartConversationResponse) ToObjectValue(ctx context.Context) baset func (o GenieStartConversationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "conversation": basetypes.ListType{ - ElemType: GenieConversation{}.Type(ctx), - }, + "conversation": basetypes.ListType{ElemType: GenieConversation{}.Type(ctx)}, "conversation_id": types.StringType, - "message": basetypes.ListType{ - ElemType: GenieMessage{}.Type(ctx), - }, - "message_id": types.StringType, + "message": basetypes.ListType{ElemType: GenieMessage{}.Type(ctx)}, + "message_id": types.StringType, }, } } @@ -1647,9 +1625,7 @@ func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListDashboardsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboards": basetypes.ListType{ - ElemType: Dashboard{}.Type(ctx), - }, + "dashboards": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1778,9 +1754,7 @@ func (o ListSchedulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schedules": basetypes.ListType{ - ElemType: Schedule{}.Type(ctx), - }, + "schedules": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, }, } } @@ -1912,9 +1886,7 @@ func (o ListSubscriptionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "subscriptions": basetypes.ListType{ - ElemType: Subscription{}.Type(ctx), - }, + "subscriptions": basetypes.ListType{ElemType: Subscription{}.Type(ctx)}, }, } } @@ -2209,9 +2181,7 @@ func (o QueryAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o QueryAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cached_query_schema": basetypes.ListType{ - ElemType: QuerySchema{}.Type(ctx), - }, + "cached_query_schema": basetypes.ListType{ElemType: QuerySchema{}.Type(ctx)}, "description": types.StringType, "id": types.StringType, "instruction_id": types.StringType, @@ -2292,9 +2262,7 @@ func (o QuerySchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QuerySchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ - ElemType: QuerySchemaColumn{}.Type(ctx), - }, + "columns": basetypes.ListType{ElemType: QuerySchemaColumn{}.Type(ctx)}, "statement_id": types.StringType, }, } @@ -2495,17 +2463,15 @@ func (o Schedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Schedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "create_time": types.StringType, - "cron_schedule": basetypes.ListType{ - ElemType: CronSchedule{}.Type(ctx), - }, - "dashboard_id": types.StringType, - "display_name": types.StringType, - "etag": types.StringType, - "pause_status": types.StringType, - "schedule_id": types.StringType, - "update_time": types.StringType, - "warehouse_id": types.StringType, + "create_time": types.StringType, + "cron_schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "dashboard_id": types.StringType, + "display_name": types.StringType, + "etag": types.StringType, + "pause_status": types.StringType, + "schedule_id": types.StringType, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -2581,12 +2547,8 @@ func (o Subscriber) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Subscriber) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "destination_subscriber": basetypes.ListType{ - ElemType: SubscriptionSubscriberDestination{}.Type(ctx), - }, - "user_subscriber": basetypes.ListType{ - ElemType: SubscriptionSubscriberUser{}.Type(ctx), - }, + "destination_subscriber": basetypes.ListType{ElemType: SubscriptionSubscriberDestination{}.Type(ctx)}, + "user_subscriber": basetypes.ListType{ElemType: SubscriptionSubscriberUser{}.Type(ctx)}, }, } } @@ -2712,11 +2674,9 @@ func (o Subscription) Type(ctx context.Context) attr.Type { "dashboard_id": types.StringType, "etag": types.StringType, "schedule_id": types.StringType, - "subscriber": basetypes.ListType{ - ElemType: Subscriber{}.Type(ctx), - }, - "subscription_id": types.StringType, - "update_time": types.StringType, + "subscriber": basetypes.ListType{ElemType: Subscriber{}.Type(ctx)}, + "subscription_id": types.StringType, + "update_time": types.StringType, }, } } @@ -3078,9 +3038,7 @@ func (o UpdateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboard": basetypes.ListType{ - ElemType: Dashboard{}.Type(ctx), - }, + "dashboard": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, "dashboard_id": types.StringType, }, } @@ -3159,10 +3117,8 @@ func (o UpdateScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, - "schedule": basetypes.ListType{ - ElemType: Schedule{}.Type(ctx), - }, - "schedule_id": types.StringType, + "schedule": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, + "schedule_id": types.StringType, }, } } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index c596edcbff..11b76683b7 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -1133,9 +1133,7 @@ func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "contents": basetypes.ListType{ - ElemType: DirectoryEntry{}.Type(ctx), - }, + "contents": basetypes.ListType{ElemType: DirectoryEntry{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1207,9 +1205,7 @@ func (o ListStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ - ElemType: FileInfo{}.Type(ctx), - }, + "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, }, } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 04df338c05..3753b284f1 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -126,9 +126,7 @@ func (o AccessControlResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o AccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: Permission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: Permission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -842,9 +840,7 @@ func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context func (o GetAssignableRolesForResourceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "roles": basetypes.ListType{ - ElemType: Role{}.Type(ctx), - }, + "roles": basetypes.ListType{ElemType: Role{}.Type(ctx)}, }, } } @@ -957,9 +953,7 @@ func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPasswordPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: PasswordPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: PasswordPermissionsDescription{}.Type(ctx)}, }, } } @@ -1076,9 +1070,7 @@ func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetype func (o GetPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: PermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: PermissionsDescription{}.Type(ctx)}, }, } } @@ -1420,10 +1412,8 @@ func (o GrantRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GrantRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principals": basetypes.ListType{ - ElemType: types.StringType, - }, - "role": types.StringType, + "principals": basetypes.ListType{ElemType: types.StringType}, + "role": types.StringType, }, } } @@ -1525,27 +1515,15 @@ func (o Group) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Group) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "displayName": types.StringType, - "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "externalId": types.StringType, - "groups": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "id": types.StringType, - "members": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "meta": basetypes.ListType{ - ElemType: ResourceMeta{}.Type(ctx), - }, - "roles": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, + "displayName": types.StringType, + "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "externalId": types.StringType, + "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "id": types.StringType, + "members": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "meta": basetypes.ListType{ElemType: ResourceMeta{}.Type(ctx)}, + "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -2053,12 +2031,8 @@ func (o ListGroupsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ - ElemType: Group{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, + "Resources": basetypes.ListType{ElemType: Group{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, }, @@ -2171,12 +2145,8 @@ func (o ListServicePrincipalResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ - ElemType: ServicePrincipal{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, + "Resources": basetypes.ListType{ElemType: ServicePrincipal{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, }, @@ -2436,12 +2406,8 @@ func (o ListUsersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ - ElemType: User{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, + "Resources": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, }, @@ -2730,11 +2696,9 @@ func (o ObjectPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: AccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2812,13 +2776,9 @@ func (o PartialUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o PartialUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "Operations": basetypes.ListType{ - ElemType: Patch{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, + "id": types.StringType, + "Operations": basetypes.ListType{ElemType: Patch{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -2980,9 +2940,7 @@ func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PasswordAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: PasswordPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: PasswordPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3061,11 +3019,9 @@ func (o PasswordPermission) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PasswordPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -3140,11 +3096,9 @@ func (o PasswordPermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PasswordPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: PasswordAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3258,9 +3212,7 @@ func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PasswordPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: PasswordAccessControlRequest{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlRequest{}.Type(ctx)}, }, } } @@ -3421,11 +3373,9 @@ func (o Permission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Permission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -3504,13 +3454,9 @@ func (o PermissionAssignment) ToObjectValue(ctx context.Context) basetypes.Objec func (o PermissionAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error": types.StringType, - "permissions": basetypes.ListType{ - ElemType: types.StringType, - }, - "principal": basetypes.ListType{ - ElemType: PrincipalOutput{}.Type(ctx), - }, + "error": types.StringType, + "permissions": basetypes.ListType{ElemType: types.StringType}, + "principal": basetypes.ListType{ElemType: PrincipalOutput{}.Type(ctx)}, }, } } @@ -3606,9 +3552,7 @@ func (o PermissionAssignments) ToObjectValue(ctx context.Context) basetypes.Obje func (o PermissionAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_assignments": basetypes.ListType{ - ElemType: PermissionAssignment{}.Type(ctx), - }, + "permission_assignments": basetypes.ListType{ElemType: PermissionAssignment{}.Type(ctx)}, }, } } @@ -3778,9 +3722,7 @@ func (o PermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AccessControlRequest{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: AccessControlRequest{}.Type(ctx)}, "request_object_id": types.StringType, "request_object_type": types.StringType, }, @@ -4003,11 +3945,9 @@ func (o RuleSetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RuleSetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "grant_rules": basetypes.ListType{ - ElemType: GrantRule{}.Type(ctx), - }, - "name": types.StringType, + "etag": types.StringType, + "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, + "name": types.StringType, }, } } @@ -4085,11 +4025,9 @@ func (o RuleSetUpdateRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o RuleSetUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "grant_rules": basetypes.ListType{ - ElemType: GrantRule{}.Type(ctx), - }, - "name": types.StringType, + "etag": types.StringType, + "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, + "name": types.StringType, }, } } @@ -4192,20 +4130,12 @@ func (o ServicePrincipal) Type(ctx context.Context) attr.Type { "active": types.BoolType, "applicationId": types.StringType, "displayName": types.StringType, - "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "externalId": types.StringType, - "groups": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "id": types.StringType, - "roles": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, + "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "externalId": types.StringType, + "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "id": types.StringType, + "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -4392,10 +4322,8 @@ func (o UpdateRuleSetRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o UpdateRuleSetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "rule_set": basetypes.ListType{ - ElemType: RuleSetUpdateRequest{}.Type(ctx), - }, + "name": types.StringType, + "rule_set": basetypes.ListType{ElemType: RuleSetUpdateRequest{}.Type(ctx)}, }, } } @@ -4476,9 +4404,7 @@ func (o UpdateWorkspaceAssignments) ToObjectValue(ctx context.Context) basetypes func (o UpdateWorkspaceAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permissions": basetypes.ListType{ - ElemType: types.StringType, - }, + "permissions": basetypes.ListType{ElemType: types.StringType}, "principal_id": types.Int64Type, "workspace_id": types.Int64Type, }, @@ -4594,29 +4520,17 @@ func (o User) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o User) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "active": types.BoolType, - "displayName": types.StringType, - "emails": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "entitlements": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "externalId": types.StringType, - "groups": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "id": types.StringType, - "name": basetypes.ListType{ - ElemType: Name{}.Type(ctx), - }, - "roles": basetypes.ListType{ - ElemType: ComplexValue{}.Type(ctx), - }, - "schemas": basetypes.ListType{ - ElemType: types.StringType, - }, - "userName": types.StringType, + "active": types.BoolType, + "displayName": types.StringType, + "emails": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "externalId": types.StringType, + "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "id": types.StringType, + "name": basetypes.ListType{ElemType: Name{}.Type(ctx)}, + "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: types.StringType}, + "userName": types.StringType, }, } } @@ -4816,9 +4730,7 @@ func (o WorkspacePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WorkspacePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permissions": basetypes.ListType{ - ElemType: PermissionOutput{}.Type(ctx), - }, + "permissions": basetypes.ListType{ElemType: PermissionOutput{}.Type(ctx)}, }, } } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index c1c45c8606..a64f6c3f66 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -85,9 +85,7 @@ func (o BaseJob) Type(ctx context.Context) attr.Type { "creator_user_name": types.StringType, "effective_budget_policy_id": types.StringType, "job_id": types.Int64Type, - "settings": basetypes.ListType{ - ElemType: JobSettings{}.Type(ctx), - }, + "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -323,61 +321,37 @@ func (o BaseRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o BaseRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.Type(ctx), - }, - "cluster_spec": basetypes.ListType{ - ElemType: ClusterSpec{}.Type(ctx), - }, - "creator_user_name": types.StringType, - "description": types.StringType, - "end_time": types.Int64Type, - "execution_duration": types.Int64Type, - "git_source": basetypes.ListType{ - ElemType: GitSource{}.Type(ctx), - }, - "job_clusters": basetypes.ListType{ - ElemType: JobCluster{}.Type(ctx), - }, - "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ - ElemType: JobParameter{}.Type(ctx), - }, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, + "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "creator_user_name": types.StringType, + "description": types.StringType, + "end_time": types.Int64Type, + "execution_duration": types.Int64Type, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "job_id": types.Int64Type, + "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, - "overriding_parameters": basetypes.ListType{ - ElemType: RunParameters{}.Type(ctx), - }, - "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ - ElemType: RepairHistoryItem{}.Type(ctx), - }, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_name": types.StringType, - "run_page_url": types.StringType, - "run_type": types.StringType, - "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.Type(ctx), - }, - "setup_duration": types.Int64Type, - "start_time": types.Int64Type, - "state": basetypes.ListType{ - ElemType: RunState{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: RunStatus{}.Type(ctx), - }, - "tasks": basetypes.ListType{ - ElemType: RunTask{}.Type(ctx), - }, - "trigger": types.StringType, - "trigger_info": basetypes.ListType{ - ElemType: TriggerInfo{}.Type(ctx), - }, + "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, + "queue_duration": types.Int64Type, + "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "setup_duration": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, } } @@ -1021,12 +995,8 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "existing_cluster_id": types.StringType, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.Type(ctx), - }, - "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.Type(ctx), - }, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, }, } } @@ -1365,64 +1335,30 @@ func (o CreateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.Type(ctx), - }, - "budget_policy_id": types.StringType, - "continuous": basetypes.ListType{ - ElemType: Continuous{}.Type(ctx), - }, - "deployment": basetypes.ListType{ - ElemType: JobDeployment{}.Type(ctx), - }, - "description": types.StringType, - "edit_mode": types.StringType, - "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.Type(ctx), - }, - "environment": basetypes.ListType{ - ElemType: JobEnvironment{}.Type(ctx), - }, - "format": types.StringType, - "git_source": basetypes.ListType{ - ElemType: GitSource{}.Type(ctx), - }, - "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.Type(ctx), - }, - "job_cluster": basetypes.ListType{ - ElemType: JobCluster{}.Type(ctx), - }, - "max_concurrent_runs": types.Int64Type, - "name": types.StringType, - "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.Type(ctx), - }, - "parameter": basetypes.ListType{ - ElemType: JobParameterDefinition{}.Type(ctx), - }, - "queue": basetypes.ListType{ - ElemType: QueueSettings{}.Type(ctx), - }, - "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.Type(ctx), - }, - "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.Type(ctx), - }, - "tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "task": basetypes.ListType{ - ElemType: Task{}.Type(ctx), - }, - "timeout_seconds": types.Int64Type, - "trigger": basetypes.ListType{ - ElemType: TriggerSettings{}.Type(ctx), - }, - "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, + "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "format": types.StringType, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "max_concurrent_runs": types.Int64Type, + "name": types.StringType, + "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, + "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "tags": basetypes.MapType{ElemType: types.StringType}, + "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "timeout_seconds": types.Int64Type, + "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, + "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, } } @@ -2013,10 +1949,8 @@ func (o DbtOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DbtOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifacts_headers": basetypes.MapType{ - ElemType: types.StringType, - }, - "artifacts_link": types.StringType, + "artifacts_headers": basetypes.MapType{ElemType: types.StringType}, + "artifacts_link": types.StringType, }, } } @@ -2124,10 +2058,8 @@ func (o DbtTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DbtTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalog": types.StringType, - "commands": basetypes.ListType{ - ElemType: types.StringType, - }, + "catalog": types.StringType, + "commands": basetypes.ListType{ElemType: types.StringType}, "profiles_directory": types.StringType, "project_directory": types.StringType, "schema": types.StringType, @@ -2479,13 +2411,9 @@ func (o EnforcePolicyComplianceResponse) ToObjectValue(ctx context.Context) base func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "has_changes": types.BoolType, - "job_cluster_changes": basetypes.ListType{ - ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx), - }, - "settings": basetypes.ListType{ - ElemType: JobSettings{}.Type(ctx), - }, + "has_changes": types.BoolType, + "job_cluster_changes": basetypes.ListType{ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx)}, + "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -2586,9 +2514,7 @@ func (o ExportRunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o ExportRunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "views": basetypes.ListType{ - ElemType: ViewItem{}.Type(ctx), - }, + "views": basetypes.ListType{ElemType: ViewItem{}.Type(ctx)}, }, } } @@ -2765,12 +2691,8 @@ func (o ForEachStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ForEachStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error_message_stats": basetypes.ListType{ - ElemType: ForEachTaskErrorMessageStats{}.Type(ctx), - }, - "task_run_stats": basetypes.ListType{ - ElemType: ForEachTaskTaskRunStats{}.Type(ctx), - }, + "error_message_stats": basetypes.ListType{ElemType: ForEachTaskErrorMessageStats{}.Type(ctx)}, + "task_run_stats": basetypes.ListType{ElemType: ForEachTaskTaskRunStats{}.Type(ctx)}, }, } } @@ -2877,9 +2799,7 @@ func (o ForEachTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, - "task": basetypes.ListType{ - ElemType: Task{}.Type(ctx), - }, + "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, }, } } @@ -3106,9 +3026,7 @@ func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetJobPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: JobPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: JobPermissionsDescription{}.Type(ctx)}, }, } } @@ -3319,9 +3237,7 @@ func (o GetPolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, - "violations": basetypes.MapType{ - ElemType: types.StringType, - }, + "violations": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -3575,14 +3491,10 @@ func (o GitSource) Type(ctx context.Context) attr.Type { "branch": types.StringType, "commit": types.StringType, "git_provider": types.StringType, - "git_snapshot": basetypes.ListType{ - ElemType: GitSnapshot{}.Type(ctx), - }, - "tag": types.StringType, - "url": types.StringType, - "job_source": basetypes.ListType{ - ElemType: JobSource{}.Type(ctx), - }, + "git_snapshot": basetypes.ListType{ElemType: GitSnapshot{}.Type(ctx)}, + "tag": types.StringType, + "url": types.StringType, + "job_source": basetypes.ListType{ElemType: JobSource{}.Type(ctx)}, }, } } @@ -3713,9 +3625,7 @@ func (o Job) Type(ctx context.Context) attr.Type { "effective_budget_policy_id": types.StringType, "job_id": types.Int64Type, "run_as_user_name": types.StringType, - "settings": basetypes.ListType{ - ElemType: JobSettings{}.Type(ctx), - }, + "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -3851,9 +3761,7 @@ func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o JobAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: JobPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: JobPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3933,9 +3841,7 @@ func (o JobCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_cluster_key": types.StringType, - "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.Type(ctx), - }, + "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, }, } } @@ -4017,9 +3923,7 @@ func (o JobCompliance) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, "job_id": types.Int64Type, - "violations": basetypes.MapType{ - ElemType: types.StringType, - }, + "violations": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -4177,22 +4081,12 @@ func (o JobEmailNotifications) ToObjectValue(ctx context.Context) basetypes.Obje func (o JobEmailNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "no_alert_for_skipped_runs": types.BoolType, - "on_duration_warning_threshold_exceeded": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_failure": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_start": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_streaming_backlog_exceeded": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_success": basetypes.ListType{ - ElemType: types.StringType, - }, + "no_alert_for_skipped_runs": types.BoolType, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: types.StringType}, + "on_failure": basetypes.ListType{ElemType: types.StringType}, + "on_start": basetypes.ListType{ElemType: types.StringType}, + "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: types.StringType}, + "on_success": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -4372,9 +4266,7 @@ func (o JobEnvironment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "environment_key": types.StringType, - "spec": basetypes.ListType{ - ElemType: compute_tf.Environment{}.Type(ctx), - }, + "spec": basetypes.ListType{ElemType: compute_tf.Environment{}.Type(ctx)}, }, } } @@ -4594,11 +4486,9 @@ func (o JobPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o JobPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -4673,11 +4563,9 @@ func (o JobPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o JobPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4794,10 +4682,8 @@ func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o JobPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.Type(ctx), - }, - "job_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, + "job_id": types.StringType, }, } } @@ -5055,61 +4941,29 @@ func (o JobSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o JobSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget_policy_id": types.StringType, - "continuous": basetypes.ListType{ - ElemType: Continuous{}.Type(ctx), - }, - "deployment": basetypes.ListType{ - ElemType: JobDeployment{}.Type(ctx), - }, - "description": types.StringType, - "edit_mode": types.StringType, - "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.Type(ctx), - }, - "environment": basetypes.ListType{ - ElemType: JobEnvironment{}.Type(ctx), - }, - "format": types.StringType, - "git_source": basetypes.ListType{ - ElemType: GitSource{}.Type(ctx), - }, - "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.Type(ctx), - }, - "job_cluster": basetypes.ListType{ - ElemType: JobCluster{}.Type(ctx), - }, - "max_concurrent_runs": types.Int64Type, - "name": types.StringType, - "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.Type(ctx), - }, - "parameter": basetypes.ListType{ - ElemType: JobParameterDefinition{}.Type(ctx), - }, - "queue": basetypes.ListType{ - ElemType: QueueSettings{}.Type(ctx), - }, - "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.Type(ctx), - }, - "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.Type(ctx), - }, - "tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "task": basetypes.ListType{ - ElemType: Task{}.Type(ctx), - }, - "timeout_seconds": types.Int64Type, - "trigger": basetypes.ListType{ - ElemType: TriggerSettings{}.Type(ctx), - }, - "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.Type(ctx), - }, + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, + "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "format": types.StringType, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "max_concurrent_runs": types.Int64Type, + "name": types.StringType, + "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, + "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "tags": basetypes.MapType{ElemType: types.StringType}, + "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "timeout_seconds": types.Int64Type, + "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, + "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, } } @@ -5692,9 +5546,7 @@ func (o JobsHealthRules) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o JobsHealthRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rules": basetypes.ListType{ - ElemType: JobsHealthRule{}.Type(ctx), - }, + "rules": basetypes.ListType{ElemType: JobsHealthRule{}.Type(ctx)}, }, } } @@ -5774,9 +5626,7 @@ func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) b func (o ListJobComplianceForPolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "jobs": basetypes.ListType{ - ElemType: JobCompliance{}.Type(ctx), - }, + "jobs": basetypes.ListType{ElemType: JobCompliance{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -5978,10 +5828,8 @@ func (o ListJobsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListJobsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "has_more": types.BoolType, - "jobs": basetypes.ListType{ - ElemType: BaseJob{}.Type(ctx), - }, + "has_more": types.BoolType, + "jobs": basetypes.ListType{ElemType: BaseJob{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -6164,9 +6012,7 @@ func (o ListRunsResponse) Type(ctx context.Context) attr.Type { "has_more": types.BoolType, "next_page_token": types.StringType, "prev_page_token": types.StringType, - "runs": basetypes.ListType{ - ElemType: BaseRun{}.Type(ctx), - }, + "runs": basetypes.ListType{ElemType: BaseRun{}.Type(ctx)}, }, } } @@ -6326,12 +6172,10 @@ func (o NotebookTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o NotebookTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "base_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "notebook_path": types.StringType, - "source": types.StringType, - "warehouse_id": types.StringType, + "base_parameters": basetypes.MapType{ElemType: types.StringType}, + "notebook_path": types.StringType, + "source": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -6550,14 +6394,10 @@ func (o PythonWheelTask) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PythonWheelTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "entry_point": types.StringType, - "named_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "package_name": types.StringType, - "parameters": basetypes.ListType{ - ElemType: types.StringType, - }, + "entry_point": types.StringType, + "named_parameters": basetypes.MapType{ElemType: types.StringType}, + "package_name": types.StringType, + "parameters": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -6770,19 +6610,13 @@ func (o RepairHistoryItem) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o RepairHistoryItem) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "end_time": types.Int64Type, - "id": types.Int64Type, - "start_time": types.Int64Type, - "state": basetypes.ListType{ - ElemType: RunState{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: RunStatus{}.Type(ctx), - }, - "task_run_ids": basetypes.ListType{ - ElemType: types.Int64Type, - }, - "type": types.StringType, + "end_time": types.Int64Type, + "id": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "task_run_ids": basetypes.ListType{ElemType: types.Int64Type}, + "type": types.StringType, }, } } @@ -7024,40 +6858,20 @@ func (o RepairRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RepairRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ - ElemType: types.StringType, - }, - "jar_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "job_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "latest_repair_id": types.Int64Type, - "notebook_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.Type(ctx), - }, - "python_named_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "python_params": basetypes.ListType{ - ElemType: types.StringType, - }, + "dbt_commands": basetypes.ListType{ElemType: types.StringType}, + "jar_params": basetypes.ListType{ElemType: types.StringType}, + "job_parameters": basetypes.MapType{ElemType: types.StringType}, + "latest_repair_id": types.Int64Type, + "notebook_params": basetypes.MapType{ElemType: types.StringType}, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ElemType: types.StringType}, + "python_params": basetypes.ListType{ElemType: types.StringType}, "rerun_all_failed_tasks": types.BoolType, "rerun_dependent_tasks": types.BoolType, - "rerun_tasks": basetypes.ListType{ - ElemType: types.StringType, - }, - "run_id": types.Int64Type, - "spark_submit_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "sql_params": basetypes.MapType{ - ElemType: types.StringType, - }, + "rerun_tasks": basetypes.ListType{ElemType: types.StringType}, + "run_id": types.Int64Type, + "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, + "sql_params": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -7412,10 +7226,8 @@ func (o ResetJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ResetJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "job_id": types.Int64Type, - "new_settings": basetypes.ListType{ - ElemType: JobSettings{}.Type(ctx), - }, + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -7565,9 +7377,7 @@ func (o ResolvedDbtTaskValues) ToObjectValue(ctx context.Context) basetypes.Obje func (o ResolvedDbtTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "commands": basetypes.ListType{ - ElemType: types.StringType, - }, + "commands": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7636,9 +7446,7 @@ func (o ResolvedNotebookTaskValues) ToObjectValue(ctx context.Context) basetypes func (o ResolvedNotebookTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "base_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, + "base_parameters": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -7707,9 +7515,7 @@ func (o ResolvedParamPairValues) ToObjectValue(ctx context.Context) basetypes.Ob func (o ResolvedParamPairValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.MapType{ - ElemType: types.StringType, - }, + "parameters": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -7782,12 +7588,8 @@ func (o ResolvedPythonWheelTaskValues) ToObjectValue(ctx context.Context) basety func (o ResolvedPythonWheelTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "named_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "parameters": basetypes.ListType{ - ElemType: types.StringType, - }, + "named_parameters": basetypes.MapType{ElemType: types.StringType}, + "parameters": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7886,12 +7688,8 @@ func (o ResolvedRunJobTaskValues) ToObjectValue(ctx context.Context) basetypes.O func (o ResolvedRunJobTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "job_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "parameters": basetypes.MapType{ - ElemType: types.StringType, - }, + "job_parameters": basetypes.MapType{ElemType: types.StringType}, + "parameters": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -7986,9 +7784,7 @@ func (o ResolvedStringParamsValues) ToObjectValue(ctx context.Context) basetypes func (o ResolvedStringParamsValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ - ElemType: types.StringType, - }, + "parameters": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -8093,36 +7889,16 @@ func (o ResolvedValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResolvedValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ - ElemType: ResolvedConditionTaskValues{}.Type(ctx), - }, - "dbt_task": basetypes.ListType{ - ElemType: ResolvedDbtTaskValues{}.Type(ctx), - }, - "notebook_task": basetypes.ListType{ - ElemType: ResolvedNotebookTaskValues{}.Type(ctx), - }, - "python_wheel_task": basetypes.ListType{ - ElemType: ResolvedPythonWheelTaskValues{}.Type(ctx), - }, - "run_job_task": basetypes.ListType{ - ElemType: ResolvedRunJobTaskValues{}.Type(ctx), - }, - "simulation_task": basetypes.ListType{ - ElemType: ResolvedParamPairValues{}.Type(ctx), - }, - "spark_jar_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.Type(ctx), - }, - "spark_python_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.Type(ctx), - }, - "spark_submit_task": basetypes.ListType{ - ElemType: ResolvedStringParamsValues{}.Type(ctx), - }, - "sql_task": basetypes.ListType{ - ElemType: ResolvedParamPairValues{}.Type(ctx), - }, + "condition_task": basetypes.ListType{ElemType: ResolvedConditionTaskValues{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: ResolvedDbtTaskValues{}.Type(ctx)}, + "notebook_task": basetypes.ListType{ElemType: ResolvedNotebookTaskValues{}.Type(ctx)}, + "python_wheel_task": basetypes.ListType{ElemType: ResolvedPythonWheelTaskValues{}.Type(ctx)}, + "run_job_task": basetypes.ListType{ElemType: ResolvedRunJobTaskValues{}.Type(ctx)}, + "simulation_task": basetypes.ListType{ElemType: ResolvedParamPairValues{}.Type(ctx)}, + "spark_jar_task": basetypes.ListType{ElemType: ResolvedStringParamsValues{}.Type(ctx)}, + "spark_python_task": basetypes.ListType{ElemType: ResolvedStringParamsValues{}.Type(ctx)}, + "spark_submit_task": basetypes.ListType{ElemType: ResolvedStringParamsValues{}.Type(ctx)}, + "sql_task": basetypes.ListType{ElemType: ResolvedParamPairValues{}.Type(ctx)}, }, } } @@ -8601,65 +8377,39 @@ func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.Type(ctx), - }, - "cluster_spec": basetypes.ListType{ - ElemType: ClusterSpec{}.Type(ctx), - }, - "creator_user_name": types.StringType, - "description": types.StringType, - "end_time": types.Int64Type, - "execution_duration": types.Int64Type, - "git_source": basetypes.ListType{ - ElemType: GitSource{}.Type(ctx), - }, - "iterations": basetypes.ListType{ - ElemType: RunTask{}.Type(ctx), - }, - "job_clusters": basetypes.ListType{ - ElemType: JobCluster{}.Type(ctx), - }, - "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ - ElemType: JobParameter{}.Type(ctx), - }, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, + "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "creator_user_name": types.StringType, + "description": types.StringType, + "end_time": types.Int64Type, + "execution_duration": types.Int64Type, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "iterations": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, + "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "job_id": types.Int64Type, + "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, "job_run_id": types.Int64Type, "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, - "overriding_parameters": basetypes.ListType{ - ElemType: RunParameters{}.Type(ctx), - }, - "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ - ElemType: RepairHistoryItem{}.Type(ctx), - }, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_name": types.StringType, - "run_page_url": types.StringType, - "run_type": types.StringType, - "schedule": basetypes.ListType{ - ElemType: CronSchedule{}.Type(ctx), - }, - "setup_duration": types.Int64Type, - "start_time": types.Int64Type, - "state": basetypes.ListType{ - ElemType: RunState{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: RunStatus{}.Type(ctx), - }, - "tasks": basetypes.ListType{ - ElemType: RunTask{}.Type(ctx), - }, - "trigger": types.StringType, - "trigger_info": basetypes.ListType{ - ElemType: TriggerInfo{}.Type(ctx), - }, + "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, + "queue_duration": types.Int64Type, + "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "setup_duration": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, } } @@ -9123,12 +8873,8 @@ func (o RunForEachTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, - "stats": basetypes.ListType{ - ElemType: ForEachStats{}.Type(ctx), - }, - "task": basetypes.ListType{ - ElemType: Task{}.Type(ctx), - }, + "stats": basetypes.ListType{ElemType: ForEachStats{}.Type(ctx)}, + "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, }, } } @@ -9367,34 +9113,16 @@ func (o RunJobTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunJobTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ - ElemType: types.StringType, - }, - "jar_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "job_id": types.Int64Type, - "job_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "notebook_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.Type(ctx), - }, - "python_named_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "python_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "spark_submit_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "sql_params": basetypes.MapType{ - ElemType: types.StringType, - }, + "dbt_commands": basetypes.ListType{ElemType: types.StringType}, + "jar_params": basetypes.ListType{ElemType: types.StringType}, + "job_id": types.Int64Type, + "job_parameters": basetypes.MapType{ElemType: types.StringType}, + "notebook_params": basetypes.MapType{ElemType: types.StringType}, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ElemType: types.StringType}, + "python_params": basetypes.ListType{ElemType: types.StringType}, + "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, + "sql_params": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -9799,41 +9527,19 @@ func (o RunNow) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunNow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ - ElemType: types.StringType, - }, - "idempotency_token": types.StringType, - "jar_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "job_id": types.Int64Type, - "job_parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "notebook_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "only": basetypes.ListType{ - ElemType: types.StringType, - }, - "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.Type(ctx), - }, - "python_named_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "python_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "queue": basetypes.ListType{ - ElemType: QueueSettings{}.Type(ctx), - }, - "spark_submit_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "sql_params": basetypes.MapType{ - ElemType: types.StringType, - }, + "dbt_commands": basetypes.ListType{ElemType: types.StringType}, + "idempotency_token": types.StringType, + "jar_params": basetypes.ListType{ElemType: types.StringType}, + "job_id": types.Int64Type, + "job_parameters": basetypes.MapType{ElemType: types.StringType}, + "notebook_params": basetypes.MapType{ElemType: types.StringType}, + "only": basetypes.ListType{ElemType: types.StringType}, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ElemType: types.StringType}, + "python_params": basetypes.ListType{ElemType: types.StringType}, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, + "sql_params": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -10259,26 +9965,16 @@ func (o RunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_output": basetypes.ListType{ - ElemType: DbtOutput{}.Type(ctx), - }, - "error": types.StringType, - "error_trace": types.StringType, - "info": types.StringType, - "logs": types.StringType, - "logs_truncated": types.BoolType, - "metadata": basetypes.ListType{ - ElemType: Run{}.Type(ctx), - }, - "notebook_output": basetypes.ListType{ - ElemType: NotebookOutput{}.Type(ctx), - }, - "run_job_output": basetypes.ListType{ - ElemType: RunJobOutput{}.Type(ctx), - }, - "sql_output": basetypes.ListType{ - ElemType: SqlOutput{}.Type(ctx), - }, + "dbt_output": basetypes.ListType{ElemType: DbtOutput{}.Type(ctx)}, + "error": types.StringType, + "error_trace": types.StringType, + "info": types.StringType, + "logs": types.StringType, + "logs_truncated": types.BoolType, + "metadata": basetypes.ListType{ElemType: Run{}.Type(ctx)}, + "notebook_output": basetypes.ListType{ElemType: NotebookOutput{}.Type(ctx)}, + "run_job_output": basetypes.ListType{ElemType: RunJobOutput{}.Type(ctx)}, + "sql_output": basetypes.ListType{ElemType: SqlOutput{}.Type(ctx)}, }, } } @@ -10546,30 +10242,14 @@ func (o RunParameters) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o RunParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ - ElemType: types.StringType, - }, - "jar_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "notebook_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "pipeline_params": basetypes.ListType{ - ElemType: PipelineParams{}.Type(ctx), - }, - "python_named_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "python_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "spark_submit_params": basetypes.ListType{ - ElemType: types.StringType, - }, - "sql_params": basetypes.MapType{ - ElemType: types.StringType, - }, + "dbt_commands": basetypes.ListType{ElemType: types.StringType}, + "jar_params": basetypes.ListType{ElemType: types.StringType}, + "notebook_params": basetypes.MapType{ElemType: types.StringType}, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ElemType: types.StringType}, + "python_params": basetypes.ListType{ElemType: types.StringType}, + "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, + "sql_params": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -10893,13 +10573,9 @@ func (o RunStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "queue_details": basetypes.ListType{ - ElemType: QueueDetails{}.Type(ctx), - }, - "state": types.StringType, - "termination_details": basetypes.ListType{ - ElemType: TerminationDetails{}.Type(ctx), - }, + "queue_details": basetypes.ListType{ElemType: QueueDetails{}.Type(ctx)}, + "state": types.StringType, + "termination_details": basetypes.ListType{ElemType: TerminationDetails{}.Type(ctx)}, }, } } @@ -11217,89 +10893,45 @@ func (o RunTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ - ElemType: ClusterInstance{}.Type(ctx), - }, - "condition_task": basetypes.ListType{ - ElemType: RunConditionTask{}.Type(ctx), - }, - "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.Type(ctx), - }, - "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.Type(ctx), - }, - "description": types.StringType, - "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.Type(ctx), - }, - "end_time": types.Int64Type, - "environment_key": types.StringType, - "execution_duration": types.Int64Type, - "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ - ElemType: RunForEachTask{}.Type(ctx), - }, - "git_source": basetypes.ListType{ - ElemType: GitSource{}.Type(ctx), - }, - "job_cluster_key": types.StringType, - "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.Type(ctx), - }, - "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.Type(ctx), - }, - "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.Type(ctx), - }, - "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.Type(ctx), - }, - "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.Type(ctx), - }, - "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.Type(ctx), - }, - "queue_duration": types.Int64Type, - "resolved_values": basetypes.ListType{ - ElemType: ResolvedValues{}.Type(ctx), - }, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_if": types.StringType, - "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.Type(ctx), - }, - "run_page_url": types.StringType, - "setup_duration": types.Int64Type, - "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.Type(ctx), - }, - "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.Type(ctx), - }, - "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.Type(ctx), - }, - "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.Type(ctx), - }, - "start_time": types.Int64Type, - "state": basetypes.ListType{ - ElemType: RunState{}.Type(ctx), - }, - "status": basetypes.ListType{ - ElemType: RunStatus{}.Type(ctx), - }, - "task_key": types.StringType, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.Type(ctx), - }, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, + "condition_task": basetypes.ListType{ElemType: RunConditionTask{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, + "description": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "end_time": types.Int64Type, + "environment_key": types.StringType, + "execution_duration": types.Int64Type, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ElemType: RunForEachTask{}.Type(ctx)}, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "job_cluster_key": types.StringType, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, + "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, + "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, + "pipeline_task": basetypes.ListType{ElemType: PipelineTask{}.Type(ctx)}, + "python_wheel_task": basetypes.ListType{ElemType: PythonWheelTask{}.Type(ctx)}, + "queue_duration": types.Int64Type, + "resolved_values": basetypes.ListType{ElemType: ResolvedValues{}.Type(ctx)}, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ElemType: RunJobTask{}.Type(ctx)}, + "run_page_url": types.StringType, + "setup_duration": types.Int64Type, + "spark_jar_task": basetypes.ListType{ElemType: SparkJarTask{}.Type(ctx)}, + "spark_python_task": basetypes.ListType{ElemType: SparkPythonTask{}.Type(ctx)}, + "spark_submit_task": basetypes.ListType{ElemType: SparkSubmitTask{}.Type(ctx)}, + "sql_task": basetypes.ListType{ElemType: SqlTask{}.Type(ctx)}, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, } } @@ -11933,9 +11565,7 @@ func (o SparkJarTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "jar_uri": types.StringType, "main_class_name": types.StringType, - "parameters": basetypes.ListType{ - ElemType: types.StringType, - }, + "parameters": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -12028,9 +11658,7 @@ func (o SparkPythonTask) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o SparkPythonTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ - ElemType: types.StringType, - }, + "parameters": basetypes.ListType{ElemType: types.StringType}, "python_file": types.StringType, "source": types.StringType, }, @@ -12107,9 +11735,7 @@ func (o SparkSubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o SparkSubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ - ElemType: types.StringType, - }, + "parameters": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -12196,13 +11822,11 @@ func (o SqlAlertOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o SqlAlertOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert_state": types.StringType, - "output_link": types.StringType, - "query_text": types.StringType, - "sql_statements": basetypes.ListType{ - ElemType: SqlStatementOutput{}.Type(ctx), - }, - "warehouse_id": types.StringType, + "alert_state": types.StringType, + "output_link": types.StringType, + "query_text": types.StringType, + "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, + "warehouse_id": types.StringType, }, } } @@ -12276,9 +11900,7 @@ func (o SqlDashboardOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, - "widgets": basetypes.ListType{ - ElemType: SqlDashboardWidgetOutput{}.Type(ctx), - }, + "widgets": basetypes.ListType{ElemType: SqlDashboardWidgetOutput{}.Type(ctx)}, }, } } @@ -12366,10 +11988,8 @@ func (o SqlDashboardWidgetOutput) ToObjectValue(ctx context.Context) basetypes.O func (o SqlDashboardWidgetOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "end_time": types.Int64Type, - "error": basetypes.ListType{ - ElemType: SqlOutputError{}.Type(ctx), - }, + "end_time": types.Int64Type, + "error": basetypes.ListType{ElemType: SqlOutputError{}.Type(ctx)}, "output_link": types.StringType, "start_time": types.Int64Type, "status": types.StringType, @@ -12452,15 +12072,9 @@ func (o SqlOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SqlOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert_output": basetypes.ListType{ - ElemType: SqlAlertOutput{}.Type(ctx), - }, - "dashboard_output": basetypes.ListType{ - ElemType: SqlDashboardOutput{}.Type(ctx), - }, - "query_output": basetypes.ListType{ - ElemType: SqlQueryOutput{}.Type(ctx), - }, + "alert_output": basetypes.ListType{ElemType: SqlAlertOutput{}.Type(ctx)}, + "dashboard_output": basetypes.ListType{ElemType: SqlDashboardOutput{}.Type(ctx)}, + "query_output": basetypes.ListType{ElemType: SqlQueryOutput{}.Type(ctx)}, }, } } @@ -12636,13 +12250,11 @@ func (o SqlQueryOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o SqlQueryOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoint_id": types.StringType, - "output_link": types.StringType, - "query_text": types.StringType, - "sql_statements": basetypes.ListType{ - ElemType: SqlStatementOutput{}.Type(ctx), - }, - "warehouse_id": types.StringType, + "endpoint_id": types.StringType, + "output_link": types.StringType, + "query_text": types.StringType, + "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, + "warehouse_id": types.StringType, }, } } @@ -12778,21 +12390,11 @@ func (o SqlTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SqlTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ - ElemType: SqlTaskAlert{}.Type(ctx), - }, - "dashboard": basetypes.ListType{ - ElemType: SqlTaskDashboard{}.Type(ctx), - }, - "file": basetypes.ListType{ - ElemType: SqlTaskFile{}.Type(ctx), - }, - "parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "query": basetypes.ListType{ - ElemType: SqlTaskQuery{}.Type(ctx), - }, + "alert": basetypes.ListType{ElemType: SqlTaskAlert{}.Type(ctx)}, + "dashboard": basetypes.ListType{ElemType: SqlTaskDashboard{}.Type(ctx)}, + "file": basetypes.ListType{ElemType: SqlTaskFile{}.Type(ctx)}, + "parameters": basetypes.MapType{ElemType: types.StringType}, + "query": basetypes.ListType{ElemType: SqlTaskQuery{}.Type(ctx)}, "warehouse_id": types.StringType, }, } @@ -12975,9 +12577,7 @@ func (o SqlTaskAlert) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ - ElemType: SqlTaskSubscription{}.Type(ctx), - }, + "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, }, } } @@ -13060,9 +12660,7 @@ func (o SqlTaskDashboard) Type(ctx context.Context) attr.Type { "custom_subject": types.StringType, "dashboard_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ - ElemType: SqlTaskSubscription{}.Type(ctx), - }, + "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, }, } } @@ -13358,40 +12956,20 @@ func (o SubmitRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: JobAccessControlRequest{}.Type(ctx), - }, - "budget_policy_id": types.StringType, - "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.Type(ctx), - }, - "environments": basetypes.ListType{ - ElemType: JobEnvironment{}.Type(ctx), - }, - "git_source": basetypes.ListType{ - ElemType: GitSource{}.Type(ctx), - }, - "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.Type(ctx), - }, - "idempotency_token": types.StringType, - "notification_settings": basetypes.ListType{ - ElemType: JobNotificationSettings{}.Type(ctx), - }, - "queue": basetypes.ListType{ - ElemType: QueueSettings{}.Type(ctx), - }, - "run_as": basetypes.ListType{ - ElemType: JobRunAs{}.Type(ctx), - }, - "run_name": types.StringType, - "tasks": basetypes.ListType{ - ElemType: SubmitTask{}.Type(ctx), - }, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, + "budget_policy_id": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environments": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "idempotency_token": types.StringType, + "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, + "run_name": types.StringType, + "tasks": basetypes.ListType{ElemType: SubmitTask{}.Type(ctx)}, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, } } @@ -13873,66 +13451,30 @@ func (o SubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ - ElemType: ConditionTask{}.Type(ctx), - }, - "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.Type(ctx), - }, - "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.Type(ctx), - }, - "description": types.StringType, - "email_notifications": basetypes.ListType{ - ElemType: JobEmailNotifications{}.Type(ctx), - }, - "environment_key": types.StringType, - "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ - ElemType: ForEachTask{}.Type(ctx), - }, - "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.Type(ctx), - }, - "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.Type(ctx), - }, - "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.Type(ctx), - }, - "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.Type(ctx), - }, - "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.Type(ctx), - }, - "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.Type(ctx), - }, - "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.Type(ctx), - }, - "run_if": types.StringType, - "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.Type(ctx), - }, - "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.Type(ctx), - }, - "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.Type(ctx), - }, - "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.Type(ctx), - }, - "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.Type(ctx), - }, - "task_key": types.StringType, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.Type(ctx), - }, + "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, + "description": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environment_key": types.StringType, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, + "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, + "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, + "pipeline_task": basetypes.ListType{ElemType: PipelineTask{}.Type(ctx)}, + "python_wheel_task": basetypes.ListType{ElemType: PythonWheelTask{}.Type(ctx)}, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ElemType: RunJobTask{}.Type(ctx)}, + "spark_jar_task": basetypes.ListType{ElemType: SparkJarTask{}.Type(ctx)}, + "spark_python_task": basetypes.ListType{ElemType: SparkPythonTask{}.Type(ctx)}, + "spark_submit_task": basetypes.ListType{ElemType: SparkSubmitTask{}.Type(ctx)}, + "sql_task": basetypes.ListType{ElemType: SqlTask{}.Type(ctx)}, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, } } @@ -14461,10 +14003,8 @@ func (o TableUpdateTriggerConfiguration) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "condition": types.StringType, "min_time_between_triggers_seconds": types.Int64Type, - "table_names": basetypes.ListType{ - ElemType: types.StringType, - }, - "wait_after_last_change_seconds": types.Int64Type, + "table_names": basetypes.ListType{ElemType: types.StringType}, + "wait_after_last_change_seconds": types.Int64Type, }, } } @@ -14697,71 +14237,35 @@ func (o Task) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Task) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ - ElemType: ConditionTask{}.Type(ctx), - }, - "dbt_task": basetypes.ListType{ - ElemType: DbtTask{}.Type(ctx), - }, - "depends_on": basetypes.ListType{ - ElemType: TaskDependency{}.Type(ctx), - }, + "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, "description": types.StringType, "disable_auto_optimization": types.BoolType, - "email_notifications": basetypes.ListType{ - ElemType: TaskEmailNotifications{}.Type(ctx), - }, - "environment_key": types.StringType, - "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ - ElemType: ForEachTask{}.Type(ctx), - }, - "health": basetypes.ListType{ - ElemType: JobsHealthRules{}.Type(ctx), - }, - "job_cluster_key": types.StringType, - "library": basetypes.ListType{ - ElemType: compute_tf.Library{}.Type(ctx), - }, + "email_notifications": basetypes.ListType{ElemType: TaskEmailNotifications{}.Type(ctx)}, + "environment_key": types.StringType, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "job_cluster_key": types.StringType, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, - "new_cluster": basetypes.ListType{ - ElemType: compute_tf.ClusterSpec{}.Type(ctx), - }, - "notebook_task": basetypes.ListType{ - ElemType: NotebookTask{}.Type(ctx), - }, - "notification_settings": basetypes.ListType{ - ElemType: TaskNotificationSettings{}.Type(ctx), - }, - "pipeline_task": basetypes.ListType{ - ElemType: PipelineTask{}.Type(ctx), - }, - "python_wheel_task": basetypes.ListType{ - ElemType: PythonWheelTask{}.Type(ctx), - }, - "retry_on_timeout": types.BoolType, - "run_if": types.StringType, - "run_job_task": basetypes.ListType{ - ElemType: RunJobTask{}.Type(ctx), - }, - "spark_jar_task": basetypes.ListType{ - ElemType: SparkJarTask{}.Type(ctx), - }, - "spark_python_task": basetypes.ListType{ - ElemType: SparkPythonTask{}.Type(ctx), - }, - "spark_submit_task": basetypes.ListType{ - ElemType: SparkSubmitTask{}.Type(ctx), - }, - "sql_task": basetypes.ListType{ - ElemType: SqlTask{}.Type(ctx), - }, - "task_key": types.StringType, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ - ElemType: WebhookNotifications{}.Type(ctx), - }, + "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, + "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, + "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, + "pipeline_task": basetypes.ListType{ElemType: PipelineTask{}.Type(ctx)}, + "python_wheel_task": basetypes.ListType{ElemType: PythonWheelTask{}.Type(ctx)}, + "retry_on_timeout": types.BoolType, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ElemType: RunJobTask{}.Type(ctx)}, + "spark_jar_task": basetypes.ListType{ElemType: SparkJarTask{}.Type(ctx)}, + "spark_python_task": basetypes.ListType{ElemType: SparkPythonTask{}.Type(ctx)}, + "spark_submit_task": basetypes.ListType{ElemType: SparkSubmitTask{}.Type(ctx)}, + "sql_task": basetypes.ListType{ElemType: SqlTask{}.Type(ctx)}, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, } } @@ -15360,22 +14864,12 @@ func (o TaskEmailNotifications) ToObjectValue(ctx context.Context) basetypes.Obj func (o TaskEmailNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "no_alert_for_skipped_runs": types.BoolType, - "on_duration_warning_threshold_exceeded": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_failure": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_start": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_streaming_backlog_exceeded": basetypes.ListType{ - ElemType: types.StringType, - }, - "on_success": basetypes.ListType{ - ElemType: types.StringType, - }, + "no_alert_for_skipped_runs": types.BoolType, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: types.StringType}, + "on_failure": basetypes.ListType{ElemType: types.StringType}, + "on_start": basetypes.ListType{ElemType: types.StringType}, + "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: types.StringType}, + "on_success": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -15763,19 +15257,11 @@ func (o TriggerSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o TriggerSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_arrival": basetypes.ListType{ - ElemType: FileArrivalTriggerConfiguration{}.Type(ctx), - }, + "file_arrival": basetypes.ListType{ElemType: FileArrivalTriggerConfiguration{}.Type(ctx)}, "pause_status": types.StringType, - "periodic": basetypes.ListType{ - ElemType: PeriodicTriggerConfiguration{}.Type(ctx), - }, - "table": basetypes.ListType{ - ElemType: TableUpdateTriggerConfiguration{}.Type(ctx), - }, - "table_update": basetypes.ListType{ - ElemType: TableUpdateTriggerConfiguration{}.Type(ctx), - }, + "periodic": basetypes.ListType{ElemType: PeriodicTriggerConfiguration{}.Type(ctx)}, + "table": basetypes.ListType{ElemType: TableUpdateTriggerConfiguration{}.Type(ctx)}, + "table_update": basetypes.ListType{ElemType: TableUpdateTriggerConfiguration{}.Type(ctx)}, }, } } @@ -15942,13 +15428,9 @@ func (o UpdateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o UpdateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fields_to_remove": basetypes.ListType{ - ElemType: types.StringType, - }, - "job_id": types.Int64Type, - "new_settings": basetypes.ListType{ - ElemType: JobSettings{}.Type(ctx), - }, + "fields_to_remove": basetypes.ListType{ElemType: types.StringType}, + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -16203,21 +15685,11 @@ func (o WebhookNotifications) ToObjectValue(ctx context.Context) basetypes.Objec func (o WebhookNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "on_duration_warning_threshold_exceeded": basetypes.ListType{ - ElemType: Webhook{}.Type(ctx), - }, - "on_failure": basetypes.ListType{ - ElemType: Webhook{}.Type(ctx), - }, - "on_start": basetypes.ListType{ - ElemType: Webhook{}.Type(ctx), - }, - "on_streaming_backlog_exceeded": basetypes.ListType{ - ElemType: Webhook{}.Type(ctx), - }, - "on_success": basetypes.ListType{ - ElemType: Webhook{}.Type(ctx), - }, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_failure": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_start": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_success": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, }, } } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 8d04b4a043..5c5145f045 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -104,9 +104,7 @@ func (o AddExchangeForListingResponse) ToObjectValue(ctx context.Context) basety func (o AddExchangeForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_for_listing": basetypes.ListType{ - ElemType: ExchangeListing{}.Type(ctx), - }, + "exchange_for_listing": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, }, } } @@ -176,9 +174,7 @@ func (o BatchGetListingsRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o BatchGetListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ids": basetypes.ListType{ - ElemType: types.StringType, - }, + "ids": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -247,9 +243,7 @@ func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o BatchGetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, }, } } @@ -319,9 +313,7 @@ func (o BatchGetProvidersRequest) ToObjectValue(ctx context.Context) basetypes.O func (o BatchGetProvidersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ids": basetypes.ListType{ - ElemType: types.StringType, - }, + "ids": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -390,9 +382,7 @@ func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) basetypes. func (o BatchGetProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -557,9 +547,7 @@ func (o CreateExchangeFilterRequest) ToObjectValue(ctx context.Context) basetype func (o CreateExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.Type(ctx), - }, + "filter": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, }, } } @@ -669,9 +657,7 @@ func (o CreateExchangeRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ - ElemType: Exchange{}.Type(ctx), - }, + "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, }, } } @@ -790,10 +776,8 @@ func (o CreateFileRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o CreateFileRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "display_name": types.StringType, - "file_parent": basetypes.ListType{ - ElemType: FileParent{}.Type(ctx), - }, + "display_name": types.StringType, + "file_parent": basetypes.ListType{ElemType: FileParent{}.Type(ctx)}, "marketplace_file_type": types.StringType, "mime_type": types.StringType, }, @@ -867,9 +851,7 @@ func (o CreateFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_info": basetypes.ListType{ - ElemType: FileInfo{}.Type(ctx), - }, + "file_info": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, "upload_url": types.StringType, }, } @@ -955,16 +937,12 @@ func (o CreateInstallationRequest) ToObjectValue(ctx context.Context) basetypes. func (o CreateInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "accepted_consumer_terms": basetypes.ListType{ - ElemType: ConsumerTerms{}.Type(ctx), - }, - "catalog_name": types.StringType, - "listing_id": types.StringType, - "recipient_type": types.StringType, - "repo_detail": basetypes.ListType{ - ElemType: RepoInstallation{}.Type(ctx), - }, - "share_name": types.StringType, + "accepted_consumer_terms": basetypes.ListType{ElemType: ConsumerTerms{}.Type(ctx)}, + "catalog_name": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, + "repo_detail": basetypes.ListType{ElemType: RepoInstallation{}.Type(ctx)}, + "share_name": types.StringType, }, } } @@ -1059,9 +1037,7 @@ func (o CreateListingRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o CreateListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listing": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, }, } } @@ -1196,17 +1172,15 @@ func (o CreatePersonalizationRequest) ToObjectValue(ctx context.Context) basetyp func (o CreatePersonalizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "accepted_consumer_terms": basetypes.ListType{ - ElemType: ConsumerTerms{}.Type(ctx), - }, - "comment": types.StringType, - "company": types.StringType, - "first_name": types.StringType, - "intended_use": types.StringType, - "is_from_lighthouse": types.BoolType, - "last_name": types.StringType, - "listing_id": types.StringType, - "recipient_type": types.StringType, + "accepted_consumer_terms": basetypes.ListType{ElemType: ConsumerTerms{}.Type(ctx)}, + "comment": types.StringType, + "company": types.StringType, + "first_name": types.StringType, + "intended_use": types.StringType, + "is_from_lighthouse": types.BoolType, + "last_name": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, }, } } @@ -1316,9 +1290,7 @@ func (o CreateProviderRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -1970,19 +1942,15 @@ func (o Exchange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Exchange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "filters": basetypes.ListType{ - ElemType: ExchangeFilter{}.Type(ctx), - }, - "id": types.StringType, - "linked_listings": basetypes.ListType{ - ElemType: ExchangeListing{}.Type(ctx), - }, - "name": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "id": types.StringType, + "linked_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "name": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -2243,12 +2211,10 @@ func (o FileInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o FileInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "created_at": types.Int64Type, - "display_name": types.StringType, - "download_link": types.StringType, - "file_parent": basetypes.ListType{ - ElemType: FileParent{}.Type(ctx), - }, + "created_at": types.Int64Type, + "display_name": types.StringType, + "download_link": types.StringType, + "file_parent": basetypes.ListType{ElemType: FileParent{}.Type(ctx)}, "id": types.StringType, "marketplace_file_type": types.StringType, "mime_type": types.StringType, @@ -2410,9 +2376,7 @@ func (o GetExchangeResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ - ElemType: Exchange{}.Type(ctx), - }, + "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, }, } } @@ -2523,9 +2487,7 @@ func (o GetFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_info": basetypes.ListType{ - ElemType: FileInfo{}.Type(ctx), - }, + "file_info": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, }, } } @@ -2689,10 +2651,8 @@ func (o GetListingContentMetadataResponse) ToObjectValue(ctx context.Context) ba func (o GetListingContentMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "shared_data_objects": basetypes.ListType{ - ElemType: SharedDataObject{}.Type(ctx), - }, + "next_page_token": types.StringType, + "shared_data_objects": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, }, } } @@ -2803,9 +2763,7 @@ func (o GetListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o GetListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listing": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, }, } } @@ -2923,9 +2881,7 @@ func (o GetListingsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3037,9 +2993,7 @@ func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) ba func (o GetPersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "personalization_requests": basetypes.ListType{ - ElemType: PersonalizationRequest{}.Type(ctx), - }, + "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, }, } } @@ -3150,9 +3104,7 @@ func (o GetProviderResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -3221,9 +3173,7 @@ func (o Installation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Installation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.Type(ctx), - }, + "installation": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, }, } } @@ -3340,12 +3290,8 @@ func (o InstallationDetail) Type(ctx context.Context) attr.Type { "repo_path": types.StringType, "share_name": types.StringType, "status": types.StringType, - "token_detail": basetypes.ListType{ - ElemType: TokenDetail{}.Type(ctx), - }, - "tokens": basetypes.ListType{ - ElemType: TokenInfo{}.Type(ctx), - }, + "token_detail": basetypes.ListType{ElemType: TokenDetail{}.Type(ctx)}, + "tokens": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, }, } } @@ -3489,9 +3435,7 @@ func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) basetyp func (o ListAllInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ - ElemType: InstallationDetail{}.Type(ctx), - }, + "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3610,10 +3554,8 @@ func (o ListAllPersonalizationRequestsResponse) ToObjectValue(ctx context.Contex func (o ListAllPersonalizationRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "personalization_requests": basetypes.ListType{ - ElemType: PersonalizationRequest{}.Type(ctx), - }, + "next_page_token": types.StringType, + "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, }, } } @@ -3735,9 +3677,7 @@ func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) basetype func (o ListExchangeFiltersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filters": basetypes.ListType{ - ElemType: ExchangeFilter{}.Type(ctx), - }, + "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3860,10 +3800,8 @@ func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) base func (o ListExchangesForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listing": basetypes.ListType{ - ElemType: ExchangeListing{}.Type(ctx), - }, - "next_page_token": types.StringType, + "exchange_listing": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "next_page_token": types.StringType, }, } } @@ -3981,9 +3919,7 @@ func (o ListExchangesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListExchangesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchanges": basetypes.ListType{ - ElemType: Exchange{}.Type(ctx), - }, + "exchanges": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4060,11 +3996,9 @@ func (o ListFilesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListFilesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_parent": basetypes.ListType{ - ElemType: FileParent{}.Type(ctx), - }, - "page_size": types.Int64Type, - "page_token": types.StringType, + "file_parent": basetypes.ListType{ElemType: FileParent{}.Type(ctx)}, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4136,9 +4070,7 @@ func (o ListFilesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListFilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_infos": basetypes.ListType{ - ElemType: FileInfo{}.Type(ctx), - }, + "file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4261,9 +4193,7 @@ func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListFulfillmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fulfillments": basetypes.ListType{ - ElemType: ListingFulfillment{}.Type(ctx), - }, + "fulfillments": basetypes.ListType{ElemType: ListingFulfillment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4386,9 +4316,7 @@ func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ - ElemType: InstallationDetail{}.Type(ctx), - }, + "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4511,10 +4439,8 @@ func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) base func (o ListListingsForExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listings": basetypes.ListType{ - ElemType: ExchangeListing{}.Type(ctx), - }, - "next_page_token": types.StringType, + "exchange_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "next_page_token": types.StringType, }, } } @@ -4612,23 +4538,15 @@ func (o ListListingsRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o ListListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ - ElemType: types.StringType, - }, - "categories": basetypes.ListType{ - ElemType: types.StringType, - }, + "assets": basetypes.ListType{ElemType: types.StringType}, + "categories": basetypes.ListType{ElemType: types.StringType}, "is_free": types.BoolType, "is_private_exchange": types.BoolType, "is_staff_pick": types.BoolType, "page_size": types.Int64Type, "page_token": types.StringType, - "provider_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "tags": basetypes.ListType{ - ElemType: ListingTag{}.Type(ctx), - }, + "provider_ids": basetypes.ListType{ElemType: types.StringType}, + "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, }, } } @@ -4778,9 +4696,7 @@ func (o ListListingsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4954,9 +4870,7 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -5032,13 +4946,9 @@ func (o Listing) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Listing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "detail": basetypes.ListType{ - ElemType: ListingDetail{}.Type(ctx), - }, - "id": types.StringType, - "summary": basetypes.ListType{ - ElemType: ListingSummary{}.Type(ctx), - }, + "detail": basetypes.ListType{ElemType: ListingDetail{}.Type(ctx)}, + "id": types.StringType, + "summary": basetypes.ListType{ElemType: ListingSummary{}.Type(ctx)}, }, } } @@ -5203,37 +5113,25 @@ func (o ListingDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ListingDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ - ElemType: types.StringType, - }, - "collection_date_end": types.Int64Type, - "collection_date_start": types.Int64Type, - "collection_granularity": basetypes.ListType{ - ElemType: DataRefreshInfo{}.Type(ctx), - }, - "cost": types.StringType, - "data_source": types.StringType, - "description": types.StringType, - "documentation_link": types.StringType, - "embedded_notebook_file_infos": basetypes.ListType{ - ElemType: FileInfo{}.Type(ctx), - }, - "file_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "geographical_coverage": types.StringType, - "license": types.StringType, - "pricing_model": types.StringType, - "privacy_policy_link": types.StringType, - "size": types.Float64Type, - "support_link": types.StringType, - "tags": basetypes.ListType{ - ElemType: ListingTag{}.Type(ctx), - }, - "terms_of_service": types.StringType, - "update_frequency": basetypes.ListType{ - ElemType: DataRefreshInfo{}.Type(ctx), - }, + "assets": basetypes.ListType{ElemType: types.StringType}, + "collection_date_end": types.Int64Type, + "collection_date_start": types.Int64Type, + "collection_granularity": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, + "cost": types.StringType, + "data_source": types.StringType, + "description": types.StringType, + "documentation_link": types.StringType, + "embedded_notebook_file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "file_ids": basetypes.ListType{ElemType: types.StringType}, + "geographical_coverage": types.StringType, + "license": types.StringType, + "pricing_model": types.StringType, + "privacy_policy_link": types.StringType, + "size": types.Float64Type, + "support_link": types.StringType, + "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, + "terms_of_service": types.StringType, + "update_frequency": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, }, } } @@ -5448,12 +5346,8 @@ func (o ListingFulfillment) Type(ctx context.Context) attr.Type { "fulfillment_type": types.StringType, "listing_id": types.StringType, "recipient_type": types.StringType, - "repo_info": basetypes.ListType{ - ElemType: RepoInfo{}.Type(ctx), - }, - "share_info": basetypes.ListType{ - ElemType: ShareInfo{}.Type(ctx), - }, + "repo_info": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, + "share_info": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, }, } } @@ -5650,37 +5544,25 @@ func (o ListingSummary) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ListingSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "categories": basetypes.ListType{ - ElemType: types.StringType, - }, - "created_at": types.Int64Type, - "created_by": types.StringType, - "created_by_id": types.Int64Type, - "exchange_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "git_repo": basetypes.ListType{ - ElemType: RepoInfo{}.Type(ctx), - }, - "listingType": types.StringType, - "name": types.StringType, - "provider_id": types.StringType, - "provider_region": basetypes.ListType{ - ElemType: RegionInfo{}.Type(ctx), - }, - "published_at": types.Int64Type, - "published_by": types.StringType, - "setting": basetypes.ListType{ - ElemType: ListingSetting{}.Type(ctx), - }, - "share": basetypes.ListType{ - ElemType: ShareInfo{}.Type(ctx), - }, - "status": types.StringType, - "subtitle": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "updated_by_id": types.Int64Type, + "categories": basetypes.ListType{ElemType: types.StringType}, + "created_at": types.Int64Type, + "created_by": types.StringType, + "created_by_id": types.Int64Type, + "exchange_ids": basetypes.ListType{ElemType: types.StringType}, + "git_repo": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, + "listingType": types.StringType, + "name": types.StringType, + "provider_id": types.StringType, + "provider_region": basetypes.ListType{ElemType: RegionInfo{}.Type(ctx)}, + "published_at": types.Int64Type, + "published_by": types.StringType, + "setting": basetypes.ListType{ElemType: ListingSetting{}.Type(ctx)}, + "share": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, + "status": types.StringType, + "subtitle": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "updated_by_id": types.Int64Type, }, } } @@ -5884,10 +5766,8 @@ func (o ListingTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListingTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "tag_name": types.StringType, - "tag_values": basetypes.ListType{ - ElemType: types.StringType, - }, + "tag_name": types.StringType, + "tag_values": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -6004,13 +5884,9 @@ func (o PersonalizationRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o PersonalizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "consumer_region": basetypes.ListType{ - ElemType: RegionInfo{}.Type(ctx), - }, - "contact_info": basetypes.ListType{ - ElemType: ContactInfo{}.Type(ctx), - }, + "comment": types.StringType, + "consumer_region": basetypes.ListType{ElemType: RegionInfo{}.Type(ctx)}, + "contact_info": basetypes.ListType{ElemType: ContactInfo{}.Type(ctx)}, "created_at": types.Int64Type, "id": types.StringType, "intended_use": types.StringType, @@ -6020,12 +5896,10 @@ func (o PersonalizationRequest) Type(ctx context.Context) attr.Type { "metastore_id": types.StringType, "provider_id": types.StringType, "recipient_type": types.StringType, - "share": basetypes.ListType{ - ElemType: ShareInfo{}.Type(ctx), - }, - "status": types.StringType, - "status_message": types.StringType, - "updated_at": types.Int64Type, + "share": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, + "status": types.StringType, + "status_message": types.StringType, + "updated_at": types.Int64Type, }, } } @@ -6518,20 +6392,14 @@ func (o SearchListingsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o SearchListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ - ElemType: types.StringType, - }, - "categories": basetypes.ListType{ - ElemType: types.StringType, - }, + "assets": basetypes.ListType{ElemType: types.StringType}, + "categories": basetypes.ListType{ElemType: types.StringType}, "is_free": types.BoolType, "is_private_exchange": types.BoolType, "page_size": types.Int64Type, "page_token": types.StringType, - "provider_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "query": types.StringType, + "provider_ids": basetypes.ListType{ElemType: types.StringType}, + "query": types.StringType, }, } } @@ -6655,9 +6523,7 @@ func (o SearchListingsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o SearchListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -6944,10 +6810,8 @@ func (o UpdateExchangeFilterRequest) ToObjectValue(ctx context.Context) basetype func (o UpdateExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.Type(ctx), - }, - "id": types.StringType, + "filter": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "id": types.StringType, }, } } @@ -7016,9 +6880,7 @@ func (o UpdateExchangeFilterResponse) ToObjectValue(ctx context.Context) basetyp func (o UpdateExchangeFilterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter": basetypes.ListType{ - ElemType: ExchangeFilter{}.Type(ctx), - }, + "filter": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, }, } } @@ -7090,10 +6952,8 @@ func (o UpdateExchangeRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ - ElemType: Exchange{}.Type(ctx), - }, - "id": types.StringType, + "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, + "id": types.StringType, }, } } @@ -7162,9 +7022,7 @@ func (o UpdateExchangeResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ - ElemType: Exchange{}.Type(ctx), - }, + "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, }, } } @@ -7242,9 +7100,7 @@ func (o UpdateInstallationRequest) ToObjectValue(ctx context.Context) basetypes. func (o UpdateInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.Type(ctx), - }, + "installation": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, "installation_id": types.StringType, "listing_id": types.StringType, "rotate_token": types.BoolType, @@ -7316,9 +7172,7 @@ func (o UpdateInstallationResponse) ToObjectValue(ctx context.Context) basetypes func (o UpdateInstallationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installation": basetypes.ListType{ - ElemType: InstallationDetail{}.Type(ctx), - }, + "installation": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, }, } } @@ -7390,10 +7244,8 @@ func (o UpdateListingRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o UpdateListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "listing": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "id": types.StringType, + "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, }, } } @@ -7462,9 +7314,7 @@ func (o UpdateListingResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listing": basetypes.ListType{ - ElemType: Listing{}.Type(ctx), - }, + "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, }, } } @@ -7548,10 +7398,8 @@ func (o UpdatePersonalizationRequestRequest) Type(ctx context.Context) attr.Type "listing_id": types.StringType, "reason": types.StringType, "request_id": types.StringType, - "share": basetypes.ListType{ - ElemType: ShareInfo{}.Type(ctx), - }, - "status": types.StringType, + "share": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, + "status": types.StringType, }, } } @@ -7620,9 +7468,7 @@ func (o UpdatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) func (o UpdatePersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "request": basetypes.ListType{ - ElemType: PersonalizationRequest{}.Type(ctx), - }, + "request": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, }, } } @@ -7792,10 +7638,8 @@ func (o UpdateProviderRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "id": types.StringType, + "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -7864,9 +7708,7 @@ func (o UpdateProviderResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "provider": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index c93c99fe96..f6518c907e 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -236,9 +236,7 @@ func (o ApproveTransitionRequestResponse) ToObjectValue(ctx context.Context) bas func (o ApproveTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "activity": basetypes.ListType{ - ElemType: Activity{}.Type(ctx), - }, + "activity": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, }, } } @@ -324,9 +322,7 @@ func (o CommentObject) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CommentObject) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "available_actions": basetypes.ListType{ - ElemType: types.StringType, - }, + "available_actions": basetypes.ListType{ElemType: types.StringType}, "comment": types.StringType, "creation_timestamp": types.Int64Type, "id": types.StringType, @@ -451,9 +447,7 @@ func (o CreateCommentResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": basetypes.ListType{ - ElemType: CommentObject{}.Type(ctx), - }, + "comment": basetypes.ListType{ElemType: CommentObject{}.Type(ctx)}, }, } } @@ -536,9 +530,7 @@ func (o CreateExperiment) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ - ElemType: ExperimentTag{}.Type(ctx), - }, + "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, }, } } @@ -658,9 +650,7 @@ func (o CreateModelRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "description": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ - ElemType: ModelTag{}.Type(ctx), - }, + "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, }, } } @@ -729,9 +719,7 @@ func (o CreateModelResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o CreateModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "registered_model": basetypes.ListType{ - ElemType: Model{}.Type(ctx), - }, + "registered_model": basetypes.ListType{ElemType: Model{}.Type(ctx)}, }, } } @@ -823,9 +811,7 @@ func (o CreateModelVersionRequest) Type(ctx context.Context) attr.Type { "run_id": types.StringType, "run_link": types.StringType, "source": types.StringType, - "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.Type(ctx), - }, + "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, }, } } @@ -895,9 +881,7 @@ func (o CreateModelVersionResponse) ToObjectValue(ctx context.Context) basetypes func (o CreateModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_version": basetypes.ListType{ - ElemType: ModelVersion{}.Type(ctx), - }, + "model_version": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, }, } } @@ -1023,18 +1007,12 @@ func (o CreateRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "description": types.StringType, - "events": basetypes.ListType{ - ElemType: types.StringType, - }, - "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpec{}.Type(ctx), - }, - "job_spec": basetypes.ListType{ - ElemType: JobSpec{}.Type(ctx), - }, - "model_name": types.StringType, - "status": types.StringType, + "description": types.StringType, + "events": basetypes.ListType{ElemType: types.StringType}, + "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpec{}.Type(ctx)}, + "job_spec": basetypes.ListType{ElemType: JobSpec{}.Type(ctx)}, + "model_name": types.StringType, + "status": types.StringType, }, } } @@ -1169,10 +1147,8 @@ func (o CreateRun) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, "start_time": types.Int64Type, - "tags": basetypes.ListType{ - ElemType: RunTag{}.Type(ctx), - }, - "user_id": types.StringType, + "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, + "user_id": types.StringType, }, } } @@ -1242,9 +1218,7 @@ func (o CreateRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o CreateRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "run": basetypes.ListType{ - ElemType: Run{}.Type(ctx), - }, + "run": basetypes.ListType{ElemType: Run{}.Type(ctx)}, }, } } @@ -1376,9 +1350,7 @@ func (o CreateTransitionRequestResponse) ToObjectValue(ctx context.Context) base func (o CreateTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "request": basetypes.ListType{ - ElemType: TransitionRequest{}.Type(ctx), - }, + "request": basetypes.ListType{ElemType: TransitionRequest{}.Type(ctx)}, }, } } @@ -1447,9 +1419,7 @@ func (o CreateWebhookResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "webhook": basetypes.ListType{ - ElemType: RegistryWebhook{}.Type(ctx), - }, + "webhook": basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}, }, } } @@ -1594,12 +1564,8 @@ func (o DatasetInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DatasetInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataset": basetypes.ListType{ - ElemType: Dataset{}.Type(ctx), - }, - "tags": basetypes.ListType{ - ElemType: InputTag{}.Type(ctx), - }, + "dataset": basetypes.ListType{ElemType: Dataset{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: InputTag{}.Type(ctx)}, }, } } @@ -2649,9 +2615,7 @@ func (o Experiment) Type(ctx context.Context) attr.Type { "last_update_time": types.Int64Type, "lifecycle_stage": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ - ElemType: ExperimentTag{}.Type(ctx), - }, + "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, }, } } @@ -2787,9 +2751,7 @@ func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) base func (o ExperimentAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: ExperimentPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: ExperimentPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -2868,11 +2830,9 @@ func (o ExperimentPermission) ToObjectValue(ctx context.Context) basetypes.Objec func (o ExperimentPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -2947,11 +2907,9 @@ func (o ExperimentPermissions) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExperimentPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ExperimentAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3068,10 +3026,8 @@ func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) basetyp func (o ExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ExperimentAccessControlRequest{}.Type(ctx), - }, - "experiment_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlRequest{}.Type(ctx)}, + "experiment_id": types.StringType, }, } } @@ -3323,9 +3279,7 @@ func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context func (o GetExperimentPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: ExperimentPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: ExperimentPermissionsDescription{}.Type(ctx)}, }, } } @@ -3481,9 +3435,7 @@ func (o GetExperimentResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o GetExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiment": basetypes.ListType{ - ElemType: Experiment{}.Type(ctx), - }, + "experiment": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, }, } } @@ -3618,10 +3570,8 @@ func (o GetLatestVersionsRequest) ToObjectValue(ctx context.Context) basetypes.O func (o GetLatestVersionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "stages": basetypes.ListType{ - ElemType: types.StringType, - }, + "name": types.StringType, + "stages": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3693,9 +3643,7 @@ func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o GetLatestVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ - ElemType: ModelVersion{}.Type(ctx), - }, + "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, }, } } @@ -3769,9 +3717,7 @@ func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetMetricHistoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ - ElemType: Metric{}.Type(ctx), - }, + "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3884,9 +3830,7 @@ func (o GetModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o GetModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "registered_model_databricks": basetypes.ListType{ - ElemType: ModelDatabricks{}.Type(ctx), - }, + "registered_model_databricks": basetypes.ListType{ElemType: ModelDatabricks{}.Type(ctx)}, }, } } @@ -4091,9 +4035,7 @@ func (o GetModelVersionResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o GetModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_version": basetypes.ListType{ - ElemType: ModelVersion{}.Type(ctx), - }, + "model_version": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, }, } } @@ -4206,9 +4148,7 @@ func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetRegisteredModelPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: RegisteredModelPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: RegisteredModelPermissionsDescription{}.Type(ctx)}, }, } } @@ -4370,9 +4310,7 @@ func (o GetRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o GetRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "run": basetypes.ListType{ - ElemType: Run{}.Type(ctx), - }, + "run": basetypes.ListType{ElemType: Run{}.Type(ctx)}, }, } } @@ -4773,9 +4711,7 @@ func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListArtifactsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ - ElemType: FileInfo{}.Type(ctx), - }, + "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, "next_page_token": types.StringType, "root_uri": types.StringType, }, @@ -4908,9 +4844,7 @@ func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ - ElemType: Experiment{}.Type(ctx), - }, + "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -5031,10 +4965,8 @@ func (o ListModelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ - ElemType: Model{}.Type(ctx), - }, + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, }, } } @@ -5108,9 +5040,7 @@ func (o ListRegistryWebhooks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "webhooks": basetypes.ListType{ - ElemType: RegistryWebhook{}.Type(ctx), - }, + "webhooks": basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}, }, } } @@ -5227,9 +5157,7 @@ func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) baset func (o ListTransitionRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "requests": basetypes.ListType{ - ElemType: Activity{}.Type(ctx), - }, + "requests": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, }, } } @@ -5309,9 +5237,7 @@ func (o ListWebhooksRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o ListWebhooksRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ - ElemType: types.StringType, - }, + "events": basetypes.ListType{ElemType: types.StringType}, "model_name": types.StringType, "page_token": types.StringType, }, @@ -5397,16 +5323,10 @@ func (o LogBatch) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogBatch) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ - ElemType: Metric{}.Type(ctx), - }, - "params": basetypes.ListType{ - ElemType: Param{}.Type(ctx), - }, - "run_id": types.StringType, - "tags": basetypes.ListType{ - ElemType: RunTag{}.Type(ctx), - }, + "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, + "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, + "run_id": types.StringType, + "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, }, } } @@ -5567,10 +5487,8 @@ func (o LogInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "datasets": basetypes.ListType{ - ElemType: DatasetInput{}.Type(ctx), - }, - "run_id": types.StringType, + "datasets": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, + "run_id": types.StringType, }, } } @@ -6026,14 +5944,10 @@ func (o Model) Type(ctx context.Context) attr.Type { "creation_timestamp": types.Int64Type, "description": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ - ElemType: ModelVersion{}.Type(ctx), - }, - "name": types.StringType, - "tags": basetypes.ListType{ - ElemType: ModelTag{}.Type(ctx), - }, - "user_id": types.StringType, + "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "name": types.StringType, + "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, + "user_id": types.StringType, }, } } @@ -6159,15 +6073,11 @@ func (o ModelDatabricks) Type(ctx context.Context) attr.Type { "description": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ - ElemType: ModelVersion{}.Type(ctx), - }, - "name": types.StringType, - "permission_level": types.StringType, - "tags": basetypes.ListType{ - ElemType: ModelTag{}.Type(ctx), - }, - "user_id": types.StringType, + "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "name": types.StringType, + "permission_level": types.StringType, + "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, + "user_id": types.StringType, }, } } @@ -6358,11 +6268,9 @@ func (o ModelVersion) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.Type(ctx), - }, - "user_id": types.StringType, - "version": types.StringType, + "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, + "user_id": types.StringType, + "version": types.StringType, }, } } @@ -6502,11 +6410,9 @@ func (o ModelVersionDatabricks) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ - ElemType: ModelVersionTag{}.Type(ctx), - }, - "user_id": types.StringType, - "version": types.StringType, + "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, + "user_id": types.StringType, + "version": types.StringType, }, } } @@ -6734,9 +6640,7 @@ func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) func (o RegisteredModelAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: RegisteredModelPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: RegisteredModelPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6815,11 +6719,9 @@ func (o RegisteredModelPermission) ToObjectValue(ctx context.Context) basetypes. func (o RegisteredModelPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -6894,11 +6796,9 @@ func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) basetypes func (o RegisteredModelPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: RegisteredModelAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -7015,9 +6915,7 @@ func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o RegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: RegisteredModelAccessControlRequest{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlRequest{}.Type(ctx)}, "registered_model_id": types.StringType, }, } @@ -7153,18 +7051,12 @@ func (o RegistryWebhook) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "description": types.StringType, - "events": basetypes.ListType{ - ElemType: types.StringType, - }, - "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpecWithoutSecret{}.Type(ctx), - }, - "id": types.StringType, - "job_spec": basetypes.ListType{ - ElemType: JobSpecWithoutSecret{}.Type(ctx), - }, + "creation_timestamp": types.Int64Type, + "description": types.StringType, + "events": basetypes.ListType{ElemType: types.StringType}, + "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpecWithoutSecret{}.Type(ctx)}, + "id": types.StringType, + "job_spec": basetypes.ListType{ElemType: JobSpecWithoutSecret{}.Type(ctx)}, "last_updated_timestamp": types.Int64Type, "model_name": types.StringType, "status": types.StringType, @@ -7351,9 +7243,7 @@ func (o RejectTransitionRequestResponse) ToObjectValue(ctx context.Context) base func (o RejectTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "activity": basetypes.ListType{ - ElemType: Activity{}.Type(ctx), - }, + "activity": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, }, } } @@ -7468,9 +7358,7 @@ func (o RenameModelResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o RenameModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "registered_model": basetypes.ListType{ - ElemType: Model{}.Type(ctx), - }, + "registered_model": basetypes.ListType{ElemType: Model{}.Type(ctx)}, }, } } @@ -7799,15 +7687,9 @@ func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data": basetypes.ListType{ - ElemType: RunData{}.Type(ctx), - }, - "info": basetypes.ListType{ - ElemType: RunInfo{}.Type(ctx), - }, - "inputs": basetypes.ListType{ - ElemType: RunInputs{}.Type(ctx), - }, + "data": basetypes.ListType{ElemType: RunData{}.Type(ctx)}, + "info": basetypes.ListType{ElemType: RunInfo{}.Type(ctx)}, + "inputs": basetypes.ListType{ElemType: RunInputs{}.Type(ctx)}, }, } } @@ -7937,15 +7819,9 @@ func (o RunData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ - ElemType: Metric{}.Type(ctx), - }, - "params": basetypes.ListType{ - ElemType: Param{}.Type(ctx), - }, - "tags": basetypes.ListType{ - ElemType: RunTag{}.Type(ctx), - }, + "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, + "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, }, } } @@ -8147,9 +8023,7 @@ func (o RunInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataset_inputs": basetypes.ListType{ - ElemType: DatasetInput{}.Type(ctx), - }, + "dataset_inputs": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, }, } } @@ -8284,11 +8158,9 @@ func (o SearchExperiments) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ - ElemType: types.StringType, - }, - "page_token": types.StringType, - "view_type": types.StringType, + "order_by": basetypes.ListType{ElemType: types.StringType}, + "page_token": types.StringType, + "view_type": types.StringType, }, } } @@ -8362,9 +8234,7 @@ func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) basetypes. func (o SearchExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ - ElemType: Experiment{}.Type(ctx), - }, + "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -8451,10 +8321,8 @@ func (o SearchModelVersionsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ - ElemType: types.StringType, - }, - "page_token": types.StringType, + "order_by": basetypes.ListType{ElemType: types.StringType}, + "page_token": types.StringType, }, } } @@ -8528,9 +8396,7 @@ func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) basetype func (o SearchModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ - ElemType: ModelVersion{}.Type(ctx), - }, + "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -8617,10 +8483,8 @@ func (o SearchModelsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ - ElemType: types.StringType, - }, - "page_token": types.StringType, + "order_by": basetypes.ListType{ElemType: types.StringType}, + "page_token": types.StringType, }, } } @@ -8693,10 +8557,8 @@ func (o SearchModelsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o SearchModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ - ElemType: Model{}.Type(ctx), - }, + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, }, } } @@ -8799,16 +8661,12 @@ func (o SearchRuns) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SearchRuns) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiment_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "filter": types.StringType, - "max_results": types.Int64Type, - "order_by": basetypes.ListType{ - ElemType: types.StringType, - }, - "page_token": types.StringType, - "run_view_type": types.StringType, + "experiment_ids": basetypes.ListType{ElemType: types.StringType}, + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ElemType: types.StringType}, + "page_token": types.StringType, + "run_view_type": types.StringType, }, } } @@ -8908,9 +8766,7 @@ func (o SearchRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ - ElemType: Run{}.Type(ctx), - }, + "runs": basetypes.ListType{ElemType: Run{}.Type(ctx)}, }, } } @@ -9444,9 +9300,7 @@ func (o TestRegistryWebhookResponse) ToObjectValue(ctx context.Context) basetype func (o TestRegistryWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "webhook": basetypes.ListType{ - ElemType: TestRegistryWebhook{}.Type(ctx), - }, + "webhook": basetypes.ListType{ElemType: TestRegistryWebhook{}.Type(ctx)}, }, } } @@ -9605,9 +9459,7 @@ func (o TransitionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o TransitionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "available_actions": basetypes.ListType{ - ElemType: types.StringType, - }, + "available_actions": basetypes.ListType{ElemType: types.StringType}, "comment": types.StringType, "creation_timestamp": types.Int64Type, "to_stage": types.StringType, @@ -9680,9 +9532,7 @@ func (o TransitionStageResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o TransitionStageResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_version": basetypes.ListType{ - ElemType: ModelVersionDatabricks{}.Type(ctx), - }, + "model_version": basetypes.ListType{ElemType: ModelVersionDatabricks{}.Type(ctx)}, }, } } @@ -9798,9 +9648,7 @@ func (o UpdateCommentResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": basetypes.ListType{ - ElemType: CommentObject{}.Type(ctx), - }, + "comment": basetypes.ListType{ElemType: CommentObject{}.Type(ctx)}, }, } } @@ -10177,18 +10025,12 @@ func (o UpdateRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "description": types.StringType, - "events": basetypes.ListType{ - ElemType: types.StringType, - }, - "http_url_spec": basetypes.ListType{ - ElemType: HttpUrlSpec{}.Type(ctx), - }, - "id": types.StringType, - "job_spec": basetypes.ListType{ - ElemType: JobSpec{}.Type(ctx), - }, - "status": types.StringType, + "description": types.StringType, + "events": basetypes.ListType{ElemType: types.StringType}, + "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpec{}.Type(ctx)}, + "id": types.StringType, + "job_spec": basetypes.ListType{ElemType: JobSpec{}.Type(ctx)}, + "status": types.StringType, }, } } @@ -10365,9 +10207,7 @@ func (o UpdateRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdateRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "run_info": basetypes.ListType{ - ElemType: RunInfo{}.Type(ctx), - }, + "run_info": basetypes.ListType{ElemType: RunInfo{}.Type(ctx)}, }, } } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index e2e8defbdf..02bf433cb5 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -76,17 +76,11 @@ func (o CreateCustomAppIntegration) ToObjectValue(ctx context.Context) basetypes func (o CreateCustomAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "confidential": types.BoolType, - "name": types.StringType, - "redirect_urls": basetypes.ListType{ - ElemType: types.StringType, - }, - "scopes": basetypes.ListType{ - ElemType: types.StringType, - }, - "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.Type(ctx), - }, + "confidential": types.BoolType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ElemType: types.StringType}, + "scopes": basetypes.ListType{ElemType: types.StringType}, + "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } } @@ -263,10 +257,8 @@ func (o CreatePublishedAppIntegration) ToObjectValue(ctx context.Context) basety func (o CreatePublishedAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_id": types.StringType, - "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.Type(ctx), - }, + "app_id": types.StringType, + "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } } @@ -798,22 +790,16 @@ func (o GetCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) basety func (o GetCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "client_id": types.StringType, - "confidential": types.BoolType, - "create_time": types.StringType, - "created_by": types.Int64Type, - "creator_username": types.StringType, - "integration_id": types.StringType, - "name": types.StringType, - "redirect_urls": basetypes.ListType{ - ElemType: types.StringType, - }, - "scopes": basetypes.ListType{ - ElemType: types.StringType, - }, - "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.Type(ctx), - }, + "client_id": types.StringType, + "confidential": types.BoolType, + "create_time": types.StringType, + "created_by": types.Int64Type, + "creator_username": types.StringType, + "integration_id": types.StringType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ElemType: types.StringType}, + "scopes": basetypes.ListType{ElemType: types.StringType}, + "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } } @@ -981,9 +967,7 @@ func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) baset func (o GetCustomAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ - ElemType: GetCustomAppIntegrationOutput{}.Type(ctx), - }, + "apps": basetypes.ListType{ElemType: GetCustomAppIntegrationOutput{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1069,14 +1053,12 @@ func (o GetPublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) bas func (o GetPublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_id": types.StringType, - "create_time": types.StringType, - "created_by": types.Int64Type, - "integration_id": types.StringType, - "name": types.StringType, - "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.Type(ctx), - }, + "app_id": types.StringType, + "create_time": types.StringType, + "created_by": types.Int64Type, + "integration_id": types.StringType, + "name": types.StringType, + "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } } @@ -1191,9 +1173,7 @@ func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) ba func (o GetPublishedAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ - ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx), - }, + "apps": basetypes.ListType{ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1268,9 +1248,7 @@ func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) basetypes.Obj func (o GetPublishedAppsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ - ElemType: PublishedAppOutput{}.Type(ctx), - }, + "apps": basetypes.ListType{ElemType: PublishedAppOutput{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1543,9 +1521,7 @@ func (o ListServicePrincipalSecretsResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "secrets": basetypes.ListType{ - ElemType: SecretInfo{}.Type(ctx), - }, + "secrets": basetypes.ListType{ElemType: SecretInfo{}.Type(ctx)}, }, } } @@ -1641,12 +1617,8 @@ func (o PublishedAppOutput) Type(ctx context.Context) attr.Type { "description": types.StringType, "is_confidential_client": types.BoolType, "name": types.StringType, - "redirect_urls": basetypes.ListType{ - ElemType: types.StringType, - }, - "scopes": basetypes.ListType{ - ElemType: types.StringType, - }, + "redirect_urls": basetypes.ListType{ElemType: types.StringType}, + "scopes": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -1853,13 +1825,9 @@ func (o UpdateCustomAppIntegration) ToObjectValue(ctx context.Context) basetypes func (o UpdateCustomAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "integration_id": types.StringType, - "redirect_urls": basetypes.ListType{ - ElemType: types.StringType, - }, - "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.Type(ctx), - }, + "integration_id": types.StringType, + "redirect_urls": basetypes.ListType{ElemType: types.StringType}, + "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } } @@ -1993,10 +1961,8 @@ func (o UpdatePublishedAppIntegration) ToObjectValue(ctx context.Context) basety func (o UpdatePublishedAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "integration_id": types.StringType, - "token_access_policy": basetypes.ListType{ - ElemType: TokenAccessPolicy{}.Type(ctx), - }, + "integration_id": types.StringType, + "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 311cb5ccbd..2234b9bf6b 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -156,47 +156,27 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.Type(ctx), - }, - "configuration": basetypes.MapType{ - ElemType: types.StringType, - }, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.Type(ctx), - }, - "development": types.BoolType, - "dry_run": types.BoolType, - "edition": types.StringType, - "filters": basetypes.ListType{ - ElemType: Filters{}.Type(ctx), - }, - "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), - }, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.Type(ctx), - }, - "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.Type(ctx), - }, - "name": types.StringType, - "notifications": basetypes.ListType{ - ElemType: Notifications{}.Type(ctx), - }, - "photon": types.BoolType, - "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.Type(ctx), - }, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.Type(ctx), - }, + "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, + "configuration": basetypes.MapType{ElemType: types.StringType}, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, + "development": types.BoolType, + "dry_run": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, + "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, + "name": types.StringType, + "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, + "photon": types.BoolType, + "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, }, } } @@ -504,10 +484,8 @@ func (o CreatePipelineResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreatePipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "effective_settings": basetypes.ListType{ - ElemType: PipelineSpec{}.Type(ctx), - }, - "pipeline_id": types.StringType, + "effective_settings": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, + "pipeline_id": types.StringType, }, } } @@ -842,52 +820,32 @@ func (o EditPipeline) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EditPipeline) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allow_duplicate_names": types.BoolType, - "budget_policy_id": types.StringType, - "catalog": types.StringType, - "channel": types.StringType, - "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.Type(ctx), - }, - "configuration": basetypes.MapType{ - ElemType: types.StringType, - }, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.Type(ctx), - }, + "allow_duplicate_names": types.BoolType, + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, + "configuration": basetypes.MapType{ElemType: types.StringType}, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, "development": types.BoolType, "edition": types.StringType, "expected_last_modified": types.Int64Type, - "filters": basetypes.ListType{ - ElemType: Filters{}.Type(ctx), - }, - "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), - }, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.Type(ctx), - }, - "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.Type(ctx), - }, - "name": types.StringType, - "notifications": basetypes.ListType{ - ElemType: Notifications{}.Type(ctx), - }, - "photon": types.BoolType, - "pipeline_id": types.StringType, - "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.Type(ctx), - }, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.Type(ctx), - }, + "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, + "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, + "name": types.StringType, + "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, + "photon": types.BoolType, + "pipeline_id": types.StringType, + "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, }, } } @@ -1230,10 +1188,8 @@ func (o ErrorDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ErrorDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exceptions": basetypes.ListType{ - ElemType: SerializedException{}.Type(ctx), - }, - "fatal": types.BoolType, + "exceptions": basetypes.ListType{ElemType: SerializedException{}.Type(ctx)}, + "fatal": types.BoolType, }, } } @@ -1349,12 +1305,8 @@ func (o Filters) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Filters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exclude": basetypes.ListType{ - ElemType: types.StringType, - }, - "include": basetypes.ListType{ - ElemType: types.StringType, - }, + "exclude": basetypes.ListType{ElemType: types.StringType}, + "include": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -1493,9 +1445,7 @@ func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPipelinePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: PipelinePermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: PipelinePermissionsDescription{}.Type(ctx)}, }, } } @@ -1692,16 +1642,12 @@ func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { "effective_budget_policy_id": types.StringType, "health": types.StringType, "last_modified": types.Int64Type, - "latest_updates": basetypes.ListType{ - ElemType: UpdateStateInfo{}.Type(ctx), - }, - "name": types.StringType, - "pipeline_id": types.StringType, - "run_as_user_name": types.StringType, - "spec": basetypes.ListType{ - ElemType: PipelineSpec{}.Type(ctx), - }, - "state": types.StringType, + "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, + "name": types.StringType, + "pipeline_id": types.StringType, + "run_as_user_name": types.StringType, + "spec": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, + "state": types.StringType, }, } } @@ -1844,9 +1790,7 @@ func (o GetUpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o GetUpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "update": basetypes.ListType{ - ElemType: UpdateInfo{}.Type(ctx), - }, + "update": basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}, }, } } @@ -1924,15 +1868,9 @@ func (o IngestionConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o IngestionConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "report": basetypes.ListType{ - ElemType: ReportSpec{}.Type(ctx), - }, - "schema": basetypes.ListType{ - ElemType: SchemaSpec{}.Type(ctx), - }, - "table": basetypes.ListType{ - ElemType: TableSpec{}.Type(ctx), - }, + "report": basetypes.ListType{ElemType: ReportSpec{}.Type(ctx)}, + "schema": basetypes.ListType{ElemType: SchemaSpec{}.Type(ctx)}, + "table": basetypes.ListType{ElemType: TableSpec{}.Type(ctx)}, }, } } @@ -2138,12 +2076,8 @@ func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "connection_name": types.StringType, "ingestion_gateway_id": types.StringType, - "objects": basetypes.ListType{ - ElemType: IngestionConfig{}.Type(ctx), - }, - "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.Type(ctx), - }, + "objects": basetypes.ListType{ElemType: IngestionConfig{}.Type(ctx)}, + "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } } @@ -2267,9 +2201,7 @@ func (o ListPipelineEventsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ - ElemType: types.StringType, - }, + "order_by": basetypes.ListType{ElemType: types.StringType}, "page_token": types.StringType, "pipeline_id": types.StringType, }, @@ -2347,9 +2279,7 @@ func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListPipelineEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ - ElemType: PipelineEvent{}.Type(ctx), - }, + "events": basetypes.ListType{ElemType: PipelineEvent{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -2446,10 +2376,8 @@ func (o ListPipelinesRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ - ElemType: types.StringType, - }, - "page_token": types.StringType, + "order_by": basetypes.ListType{ElemType: types.StringType}, + "page_token": types.StringType, }, } } @@ -2523,9 +2451,7 @@ func (o ListPipelinesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "statuses": basetypes.ListType{ - ElemType: PipelineStateInfo{}.Type(ctx), - }, + "statuses": basetypes.ListType{ElemType: PipelineStateInfo{}.Type(ctx)}, }, } } @@ -2660,9 +2586,7 @@ func (o ListUpdatesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "prev_page_token": types.StringType, - "updates": basetypes.ListType{ - ElemType: UpdateInfo{}.Type(ctx), - }, + "updates": basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}, }, } } @@ -2820,12 +2744,8 @@ func (o Notifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o Notifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alerts": basetypes.ListType{ - ElemType: types.StringType, - }, - "email_recipients": basetypes.ListType{ - ElemType: types.StringType, - }, + "alerts": basetypes.ListType{ElemType: types.StringType}, + "email_recipients": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3094,9 +3014,7 @@ func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PipelineAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: PipelinePermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: PipelinePermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3289,45 +3207,25 @@ func (o PipelineCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PipelineCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ - ElemType: PipelineClusterAutoscale{}.Type(ctx), - }, - "aws_attributes": basetypes.ListType{ - ElemType: compute_tf.AwsAttributes{}.Type(ctx), - }, - "azure_attributes": basetypes.ListType{ - ElemType: compute_tf.AzureAttributes{}.Type(ctx), - }, - "cluster_log_conf": basetypes.ListType{ - ElemType: compute_tf.ClusterLogConf{}.Type(ctx), - }, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: PipelineClusterAutoscale{}.Type(ctx)}, + "aws_attributes": basetypes.ListType{ElemType: compute_tf.AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: compute_tf.AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: compute_tf.ClusterLogConf{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ - ElemType: compute_tf.GcpAttributes{}.Type(ctx), - }, - "init_scripts": basetypes.ListType{ - ElemType: compute_tf.InitScriptInfo{}.Type(ctx), - }, - "instance_pool_id": types.StringType, - "label": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "spark_conf": basetypes.MapType{ - ElemType: types.StringType, - }, - "spark_env_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "ssh_public_keys": basetypes.ListType{ - ElemType: types.StringType, - }, + "gcp_attributes": basetypes.ListType{ElemType: compute_tf.GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: compute_tf.InitScriptInfo{}.Type(ctx)}, + "instance_pool_id": types.StringType, + "label": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "spark_conf": basetypes.MapType{ElemType: types.StringType}, + "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, + "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3760,21 +3658,15 @@ func (o PipelineEvent) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o PipelineEvent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error": basetypes.ListType{ - ElemType: ErrorDetail{}.Type(ctx), - }, + "error": basetypes.ListType{ElemType: ErrorDetail{}.Type(ctx)}, "event_type": types.StringType, "id": types.StringType, "level": types.StringType, "maturity_level": types.StringType, "message": types.StringType, - "origin": basetypes.ListType{ - ElemType: Origin{}.Type(ctx), - }, - "sequence": basetypes.ListType{ - ElemType: Sequencing{}.Type(ctx), - }, - "timestamp": types.StringType, + "origin": basetypes.ListType{ElemType: Origin{}.Type(ctx)}, + "sequence": basetypes.ListType{ElemType: Sequencing{}.Type(ctx)}, + "timestamp": types.StringType, }, } } @@ -3912,17 +3804,11 @@ func (o PipelineLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PipelineLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file": basetypes.ListType{ - ElemType: FileLibrary{}.Type(ctx), - }, - "jar": types.StringType, - "maven": basetypes.ListType{ - ElemType: compute_tf.MavenLibrary{}.Type(ctx), - }, - "notebook": basetypes.ListType{ - ElemType: NotebookLibrary{}.Type(ctx), - }, - "whl": types.StringType, + "file": basetypes.ListType{ElemType: FileLibrary{}.Type(ctx)}, + "jar": types.StringType, + "maven": basetypes.ListType{ElemType: compute_tf.MavenLibrary{}.Type(ctx)}, + "notebook": basetypes.ListType{ElemType: NotebookLibrary{}.Type(ctx)}, + "whl": types.StringType, }, } } @@ -4049,11 +3935,9 @@ func (o PipelinePermission) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PipelinePermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -4128,11 +4012,9 @@ func (o PipelinePermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PipelinePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: PipelineAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4249,10 +4131,8 @@ func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PipelinePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: PipelineAccessControlRequest{}.Type(ctx), - }, - "pipeline_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlRequest{}.Type(ctx)}, + "pipeline_id": types.StringType, }, } } @@ -4406,49 +4286,29 @@ func (o PipelineSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PipelineSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget_policy_id": types.StringType, - "catalog": types.StringType, - "channel": types.StringType, - "clusters": basetypes.ListType{ - ElemType: PipelineCluster{}.Type(ctx), - }, - "configuration": basetypes.MapType{ - ElemType: types.StringType, - }, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ - ElemType: PipelineDeployment{}.Type(ctx), - }, - "development": types.BoolType, - "edition": types.StringType, - "filters": basetypes.ListType{ - ElemType: Filters{}.Type(ctx), - }, - "gateway_definition": basetypes.ListType{ - ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), - }, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ - ElemType: IngestionPipelineDefinition{}.Type(ctx), - }, - "libraries": basetypes.ListType{ - ElemType: PipelineLibrary{}.Type(ctx), - }, - "name": types.StringType, - "notifications": basetypes.ListType{ - ElemType: Notifications{}.Type(ctx), - }, - "photon": types.BoolType, - "restart_window": basetypes.ListType{ - ElemType: RestartWindow{}.Type(ctx), - }, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ - ElemType: PipelineTrigger{}.Type(ctx), - }, + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, + "configuration": basetypes.MapType{ElemType: types.StringType}, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, + "development": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, + "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, + "name": types.StringType, + "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, + "photon": types.BoolType, + "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, }, } } @@ -4778,13 +4638,11 @@ func (o PipelineStateInfo) Type(ctx context.Context) attr.Type { "cluster_id": types.StringType, "creator_user_name": types.StringType, "health": types.StringType, - "latest_updates": basetypes.ListType{ - ElemType: UpdateStateInfo{}.Type(ctx), - }, - "name": types.StringType, - "pipeline_id": types.StringType, - "run_as_user_name": types.StringType, - "state": types.StringType, + "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, + "name": types.StringType, + "pipeline_id": types.StringType, + "run_as_user_name": types.StringType, + "state": types.StringType, }, } } @@ -4857,12 +4715,8 @@ func (o PipelineTrigger) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PipelineTrigger) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cron": basetypes.ListType{ - ElemType: CronTrigger{}.Type(ctx), - }, - "manual": basetypes.ListType{ - ElemType: ManualTrigger{}.Type(ctx), - }, + "cron": basetypes.ListType{ElemType: CronTrigger{}.Type(ctx)}, + "manual": basetypes.ListType{ElemType: ManualTrigger{}.Type(ctx)}, }, } } @@ -4977,9 +4831,7 @@ func (o ReportSpec) Type(ctx context.Context) attr.Type { "destination_schema": types.StringType, "destination_table": types.StringType, "source_url": types.StringType, - "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.Type(ctx), - }, + "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } } @@ -5126,9 +4978,7 @@ func (o SchemaSpec) Type(ctx context.Context) attr.Type { "destination_schema": types.StringType, "source_catalog": types.StringType, "source_schema": types.StringType, - "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.Type(ctx), - }, + "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } } @@ -5202,9 +5052,7 @@ func (o Sequencing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "control_plane_seq_no": types.Int64Type, - "data_plane_id": basetypes.ListType{ - ElemType: DataPlaneId{}.Type(ctx), - }, + "data_plane_id": basetypes.ListType{ElemType: DataPlaneId{}.Type(ctx)}, }, } } @@ -5282,9 +5130,7 @@ func (o SerializedException) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "class_name": types.StringType, "message": types.StringType, - "stack": basetypes.ListType{ - ElemType: StackFrame{}.Type(ctx), - }, + "stack": basetypes.ListType{ElemType: StackFrame{}.Type(ctx)}, }, } } @@ -5430,16 +5276,12 @@ func (o StartUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o StartUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "full_refresh": types.BoolType, - "full_refresh_selection": basetypes.ListType{ - ElemType: types.StringType, - }, - "pipeline_id": types.StringType, - "refresh_selection": basetypes.ListType{ - ElemType: types.StringType, - }, - "validate_only": types.BoolType, + "cause": types.StringType, + "full_refresh": types.BoolType, + "full_refresh_selection": basetypes.ListType{ElemType: types.StringType}, + "pipeline_id": types.StringType, + "refresh_selection": basetypes.ListType{ElemType: types.StringType}, + "validate_only": types.BoolType, }, } } @@ -5682,9 +5524,7 @@ func (o TableSpec) Type(ctx context.Context) attr.Type { "source_catalog": types.StringType, "source_schema": types.StringType, "source_table": types.StringType, - "table_configuration": basetypes.ListType{ - ElemType: TableSpecificConfig{}.Type(ctx), - }, + "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } } @@ -5767,14 +5607,10 @@ func (o TableSpecificConfig) ToObjectValue(ctx context.Context) basetypes.Object func (o TableSpecificConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "primary_keys": basetypes.ListType{ - ElemType: types.StringType, - }, + "primary_keys": basetypes.ListType{ElemType: types.StringType}, "salesforce_include_formula_fields": types.BoolType, "scd_type": types.StringType, - "sequence_by": basetypes.ListType{ - ElemType: types.StringType, - }, + "sequence_by": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -5910,23 +5746,17 @@ func (o UpdateInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o UpdateInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "cluster_id": types.StringType, - "config": basetypes.ListType{ - ElemType: PipelineSpec{}.Type(ctx), - }, - "creation_time": types.Int64Type, - "full_refresh": types.BoolType, - "full_refresh_selection": basetypes.ListType{ - ElemType: types.StringType, - }, - "pipeline_id": types.StringType, - "refresh_selection": basetypes.ListType{ - ElemType: types.StringType, - }, - "state": types.StringType, - "update_id": types.StringType, - "validate_only": types.BoolType, + "cause": types.StringType, + "cluster_id": types.StringType, + "config": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, + "creation_time": types.Int64Type, + "full_refresh": types.BoolType, + "full_refresh_selection": basetypes.ListType{ElemType: types.StringType}, + "pipeline_id": types.StringType, + "refresh_selection": basetypes.ListType{ElemType: types.StringType}, + "state": types.StringType, + "update_id": types.StringType, + "validate_only": types.BoolType, }, } } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 14101d4765..30fede620c 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -59,9 +59,7 @@ func (o AwsCredentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "sts_role": basetypes.ListType{ - ElemType: StsRole{}.Type(ctx), - }, + "sts_role": basetypes.ListType{ElemType: StsRole{}.Type(ctx)}, }, } } @@ -235,9 +233,7 @@ func (o CloudResourceContainer) ToObjectValue(ctx context.Context) basetypes.Obj func (o CloudResourceContainer) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "gcp": basetypes.ListType{ - ElemType: CustomerFacingGcpCloudResourceContainer{}.Type(ctx), - }, + "gcp": basetypes.ListType{ElemType: CustomerFacingGcpCloudResourceContainer{}.Type(ctx)}, }, } } @@ -360,9 +356,7 @@ func (o CreateCredentialAwsCredentials) ToObjectValue(ctx context.Context) baset func (o CreateCredentialAwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "sts_role": basetypes.ListType{ - ElemType: CreateCredentialStsRole{}.Type(ctx), - }, + "sts_role": basetypes.ListType{ElemType: CreateCredentialStsRole{}.Type(ctx)}, }, } } @@ -434,9 +428,7 @@ func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_credentials": basetypes.ListType{ - ElemType: CreateCredentialAwsCredentials{}.Type(ctx), - }, + "aws_credentials": basetypes.ListType{ElemType: CreateCredentialAwsCredentials{}.Type(ctx)}, "credentials_name": types.StringType, }, } @@ -556,15 +548,9 @@ func (o CreateCustomerManagedKeyRequest) ToObjectValue(ctx context.Context) base func (o CreateCustomerManagedKeyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_key_info": basetypes.ListType{ - ElemType: CreateAwsKeyInfo{}.Type(ctx), - }, - "gcp_key_info": basetypes.ListType{ - ElemType: CreateGcpKeyInfo{}.Type(ctx), - }, - "use_cases": basetypes.ListType{ - ElemType: types.StringType, - }, + "aws_key_info": basetypes.ListType{ElemType: CreateAwsKeyInfo{}.Type(ctx)}, + "gcp_key_info": basetypes.ListType{ElemType: CreateGcpKeyInfo{}.Type(ctx)}, + "use_cases": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -753,20 +739,12 @@ func (o CreateNetworkRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o CreateNetworkRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "gcp_network_info": basetypes.ListType{ - ElemType: GcpNetworkInfo{}.Type(ctx), - }, - "network_name": types.StringType, - "security_group_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "subnet_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "vpc_endpoints": basetypes.ListType{ - ElemType: NetworkVpcEndpoints{}.Type(ctx), - }, - "vpc_id": types.StringType, + "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, + "network_name": types.StringType, + "security_group_ids": basetypes.ListType{ElemType: types.StringType}, + "subnet_ids": basetypes.ListType{ElemType: types.StringType}, + "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, + "vpc_id": types.StringType, }, } } @@ -917,9 +895,7 @@ func (o CreateStorageConfigurationRequest) ToObjectValue(ctx context.Context) ba func (o CreateStorageConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "root_bucket_info": basetypes.ListType{ - ElemType: RootBucketInfo{}.Type(ctx), - }, + "root_bucket_info": basetypes.ListType{ElemType: RootBucketInfo{}.Type(ctx)}, "storage_configuration_name": types.StringType, }, } @@ -1000,12 +976,10 @@ func (o CreateVpcEndpointRequest) ToObjectValue(ctx context.Context) basetypes.O func (o CreateVpcEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_vpc_endpoint_id": types.StringType, - "gcp_vpc_endpoint_info": basetypes.ListType{ - ElemType: GcpVpcEndpointInfo{}.Type(ctx), - }, - "region": types.StringType, - "vpc_endpoint_name": types.StringType, + "aws_vpc_endpoint_id": types.StringType, + "gcp_vpc_endpoint_info": basetypes.ListType{ElemType: GcpVpcEndpointInfo{}.Type(ctx)}, + "region": types.StringType, + "vpc_endpoint_name": types.StringType, }, } } @@ -1202,24 +1176,16 @@ func (o CreateWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_region": types.StringType, - "cloud": types.StringType, - "cloud_resource_container": basetypes.ListType{ - ElemType: CloudResourceContainer{}.Type(ctx), - }, - "credentials_id": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "deployment_name": types.StringType, - "gcp_managed_network_config": basetypes.ListType{ - ElemType: GcpManagedNetworkConfig{}.Type(ctx), - }, - "gke_config": basetypes.ListType{ - ElemType: GkeConfig{}.Type(ctx), - }, - "is_no_public_ip_enabled": types.BoolType, - "location": types.StringType, + "aws_region": types.StringType, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "deployment_name": types.StringType, + "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, + "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, "managed_services_customer_managed_key_id": types.StringType, "network_id": types.StringType, "pricing_tier": types.StringType, @@ -1386,10 +1352,8 @@ func (o Credential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Credential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_credentials": basetypes.ListType{ - ElemType: AwsCredentials{}.Type(ctx), - }, + "account_id": types.StringType, + "aws_credentials": basetypes.ListType{ElemType: AwsCredentials{}.Type(ctx)}, "creation_time": types.Int64Type, "credentials_id": types.StringType, "credentials_name": types.StringType, @@ -1523,18 +1487,12 @@ func (o CustomerManagedKey) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CustomerManagedKey) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_key_info": basetypes.ListType{ - ElemType: AwsKeyInfo{}.Type(ctx), - }, + "account_id": types.StringType, + "aws_key_info": basetypes.ListType{ElemType: AwsKeyInfo{}.Type(ctx)}, "creation_time": types.Int64Type, "customer_managed_key_id": types.StringType, - "gcp_key_info": basetypes.ListType{ - ElemType: GcpKeyInfo{}.Type(ctx), - }, - "use_cases": basetypes.ListType{ - ElemType: types.StringType, - }, + "gcp_key_info": basetypes.ListType{ElemType: GcpKeyInfo{}.Type(ctx)}, + "use_cases": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -2698,31 +2656,19 @@ func (o Network) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Network) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "creation_time": types.Int64Type, - "error_messages": basetypes.ListType{ - ElemType: NetworkHealth{}.Type(ctx), - }, - "gcp_network_info": basetypes.ListType{ - ElemType: GcpNetworkInfo{}.Type(ctx), - }, - "network_id": types.StringType, - "network_name": types.StringType, - "security_group_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "subnet_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "vpc_endpoints": basetypes.ListType{ - ElemType: NetworkVpcEndpoints{}.Type(ctx), - }, - "vpc_id": types.StringType, - "vpc_status": types.StringType, - "warning_messages": basetypes.ListType{ - ElemType: NetworkWarning{}.Type(ctx), - }, - "workspace_id": types.Int64Type, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "error_messages": basetypes.ListType{ElemType: NetworkHealth{}.Type(ctx)}, + "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, + "network_id": types.StringType, + "network_name": types.StringType, + "security_group_ids": basetypes.ListType{ElemType: types.StringType}, + "subnet_ids": basetypes.ListType{ElemType: types.StringType}, + "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, + "vpc_id": types.StringType, + "vpc_status": types.StringType, + "warning_messages": basetypes.ListType{ElemType: NetworkWarning{}.Type(ctx)}, + "workspace_id": types.Int64Type, }, } } @@ -2979,12 +2925,8 @@ func (o NetworkVpcEndpoints) ToObjectValue(ctx context.Context) basetypes.Object func (o NetworkVpcEndpoints) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataplane_relay": basetypes.ListType{ - ElemType: types.StringType, - }, - "rest_api": basetypes.ListType{ - ElemType: types.StringType, - }, + "dataplane_relay": basetypes.ListType{ElemType: types.StringType}, + "rest_api": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3155,10 +3097,8 @@ func (o PrivateAccessSettings) ToObjectValue(ctx context.Context) basetypes.Obje func (o PrivateAccessSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "allowed_vpc_endpoint_ids": basetypes.ListType{ - ElemType: types.StringType, - }, + "account_id": types.StringType, + "allowed_vpc_endpoint_ids": basetypes.ListType{ElemType: types.StringType}, "private_access_level": types.StringType, "private_access_settings_id": types.StringType, "private_access_settings_name": types.StringType, @@ -3324,11 +3264,9 @@ func (o StorageConfiguration) ToObjectValue(ctx context.Context) basetypes.Objec func (o StorageConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "creation_time": types.Int64Type, - "root_bucket_info": basetypes.ListType{ - ElemType: RootBucketInfo{}.Type(ctx), - }, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "root_bucket_info": basetypes.ListType{ElemType: RootBucketInfo{}.Type(ctx)}, "storage_configuration_id": types.StringType, "storage_configuration_name": types.StringType, }, @@ -3524,9 +3462,7 @@ func (o UpdateWorkspaceRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "aws_region": types.StringType, "credentials_id": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, "managed_services_customer_managed_key_id": types.StringType, "network_connectivity_config_id": types.StringType, "network_id": types.StringType, @@ -3641,9 +3577,7 @@ func (o UpsertPrivateAccessSettingsRequest) ToObjectValue(ctx context.Context) b func (o UpsertPrivateAccessSettingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_vpc_endpoint_ids": basetypes.ListType{ - ElemType: types.StringType, - }, + "allowed_vpc_endpoint_ids": basetypes.ListType{ElemType: types.StringType}, "private_access_level": types.StringType, "private_access_settings_id": types.StringType, "private_access_settings_name": types.StringType, @@ -3764,14 +3698,12 @@ func (o VpcEndpoint) Type(ctx context.Context) attr.Type { "aws_account_id": types.StringType, "aws_endpoint_service_id": types.StringType, "aws_vpc_endpoint_id": types.StringType, - "gcp_vpc_endpoint_info": basetypes.ListType{ - ElemType: GcpVpcEndpointInfo{}.Type(ctx), - }, - "region": types.StringType, - "state": types.StringType, - "use_case": types.StringType, - "vpc_endpoint_id": types.StringType, - "vpc_endpoint_name": types.StringType, + "gcp_vpc_endpoint_info": basetypes.ListType{ElemType: GcpVpcEndpointInfo{}.Type(ctx)}, + "region": types.StringType, + "state": types.StringType, + "use_case": types.StringType, + "vpc_endpoint_id": types.StringType, + "vpc_endpoint_name": types.StringType, }, } } @@ -3964,32 +3896,20 @@ func (o Workspace) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Workspace) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_region": types.StringType, - "azure_workspace_info": basetypes.ListType{ - ElemType: AzureWorkspaceInfo{}.Type(ctx), - }, - "cloud": types.StringType, - "cloud_resource_container": basetypes.ListType{ - ElemType: CloudResourceContainer{}.Type(ctx), - }, - "creation_time": types.Int64Type, - "credentials_id": types.StringType, - "custom_tags": basetypes.MapType{ - ElemType: types.StringType, - }, - "deployment_name": types.StringType, - "external_customer_info": basetypes.ListType{ - ElemType: ExternalCustomerInfo{}.Type(ctx), - }, - "gcp_managed_network_config": basetypes.ListType{ - ElemType: GcpManagedNetworkConfig{}.Type(ctx), - }, - "gke_config": basetypes.ListType{ - ElemType: GkeConfig{}.Type(ctx), - }, - "is_no_public_ip_enabled": types.BoolType, - "location": types.StringType, + "account_id": types.StringType, + "aws_region": types.StringType, + "azure_workspace_info": basetypes.ListType{ElemType: AzureWorkspaceInfo{}.Type(ctx)}, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "deployment_name": types.StringType, + "external_customer_info": basetypes.ListType{ElemType: ExternalCustomerInfo{}.Type(ctx)}, + "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, + "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, "managed_services_customer_managed_key_id": types.StringType, "network_id": types.StringType, "pricing_tier": types.StringType, diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 0a1d00c0c5..58da69e190 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -130,18 +130,10 @@ func (o AiGatewayConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.Type(ctx), - }, - "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), - }, - "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.Type(ctx), - }, - "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), - }, + "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, + "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, + "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } } @@ -302,16 +294,10 @@ func (o AiGatewayGuardrailParameters) ToObjectValue(ctx context.Context) basetyp func (o AiGatewayGuardrailParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "invalid_keywords": basetypes.ListType{ - ElemType: types.StringType, - }, - "pii": basetypes.ListType{ - ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx), - }, - "safety": types.BoolType, - "valid_topics": basetypes.ListType{ - ElemType: types.StringType, - }, + "invalid_keywords": basetypes.ListType{ElemType: types.StringType}, + "pii": basetypes.ListType{ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx)}, + "safety": types.BoolType, + "valid_topics": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -484,12 +470,8 @@ func (o AiGatewayGuardrails) ToObjectValue(ctx context.Context) basetypes.Object func (o AiGatewayGuardrails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "input": basetypes.ListType{ - ElemType: AiGatewayGuardrailParameters{}.Type(ctx), - }, - "output": basetypes.ListType{ - ElemType: AiGatewayGuardrailParameters{}.Type(ctx), - }, + "input": basetypes.ListType{ElemType: AiGatewayGuardrailParameters{}.Type(ctx)}, + "output": basetypes.ListType{ElemType: AiGatewayGuardrailParameters{}.Type(ctx)}, }, } } @@ -941,12 +923,10 @@ func (o AutoCaptureConfigOutput) ToObjectValue(ctx context.Context) basetypes.Ob func (o AutoCaptureConfigOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalog_name": types.StringType, - "enabled": types.BoolType, - "schema_name": types.StringType, - "state": basetypes.ListType{ - ElemType: AutoCaptureState{}.Type(ctx), - }, + "catalog_name": types.StringType, + "enabled": types.BoolType, + "schema_name": types.StringType, + "state": basetypes.ListType{ElemType: AutoCaptureState{}.Type(ctx)}, "table_name_prefix": types.StringType, }, } @@ -1016,9 +996,7 @@ func (o AutoCaptureState) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o AutoCaptureState) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "payload_table": basetypes.ListType{ - ElemType: PayloadTable{}.Type(ctx), - }, + "payload_table": basetypes.ListType{ElemType: PayloadTable{}.Type(ctx)}, }, } } @@ -1305,20 +1283,12 @@ func (o CreateServingEndpoint) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.Type(ctx), - }, - "config": basetypes.ListType{ - ElemType: EndpointCoreConfigInput{}.Type(ctx), - }, - "name": types.StringType, - "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.Type(ctx), - }, + "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, + "config": basetypes.ListType{ElemType: EndpointCoreConfigInput{}.Type(ctx)}, + "name": types.StringType, + "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, "route_optimized": types.BoolType, - "tags": basetypes.ListType{ - ElemType: EndpointTag{}.Type(ctx), - }, + "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, }, } } @@ -1534,15 +1504,9 @@ func (o DataframeSplitInput) ToObjectValue(ctx context.Context) basetypes.Object func (o DataframeSplitInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ - ElemType: types.ObjectType{}, - }, - "data": basetypes.ListType{ - ElemType: types.ObjectType{}, - }, - "index": basetypes.ListType{ - ElemType: types.Int64Type, - }, + "columns": basetypes.ListType{ElemType: types.ObjectType{}}, + "data": basetypes.ListType{ElemType: types.ObjectType{}}, + "index": basetypes.ListType{ElemType: types.Int64Type}, }, } } @@ -1748,11 +1712,9 @@ func (o EmbeddingsV1ResponseEmbeddingElement) ToObjectValue(ctx context.Context) func (o EmbeddingsV1ResponseEmbeddingElement) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding": basetypes.ListType{ - ElemType: types.Float64Type, - }, - "index": types.Int64Type, - "object": types.StringType, + "embedding": basetypes.ListType{ElemType: types.Float64Type}, + "index": types.Int64Type, + "object": types.StringType, }, } } @@ -1841,19 +1803,11 @@ func (o EndpointCoreConfigInput) ToObjectValue(ctx context.Context) basetypes.Ob func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigInput{}.Type(ctx), - }, - "name": types.StringType, - "served_entities": basetypes.ListType{ - ElemType: ServedEntityInput{}.Type(ctx), - }, - "served_models": basetypes.ListType{ - ElemType: ServedModelInput{}.Type(ctx), - }, - "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.Type(ctx), - }, + "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigInput{}.Type(ctx)}, + "name": types.StringType, + "served_entities": basetypes.ListType{ElemType: ServedEntityInput{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelInput{}.Type(ctx)}, + "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } } @@ -2018,19 +1972,11 @@ func (o EndpointCoreConfigOutput) ToObjectValue(ctx context.Context) basetypes.O func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigOutput{}.Type(ctx), - }, - "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ - ElemType: ServedEntityOutput{}.Type(ctx), - }, - "served_models": basetypes.ListType{ - ElemType: ServedModelOutput{}.Type(ctx), - }, - "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.Type(ctx), - }, + "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, + "config_version": types.Int64Type, + "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, + "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } } @@ -2183,12 +2129,8 @@ func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) basetypes. func (o EndpointCoreConfigSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "served_entities": basetypes.ListType{ - ElemType: ServedEntitySpec{}.Type(ctx), - }, - "served_models": basetypes.ListType{ - ElemType: ServedModelSpec{}.Type(ctx), - }, + "served_entities": basetypes.ListType{ElemType: ServedEntitySpec{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelSpec{}.Type(ctx)}, }, } } @@ -2306,20 +2248,12 @@ func (o EndpointPendingConfig) ToObjectValue(ctx context.Context) basetypes.Obje func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_capture_config": basetypes.ListType{ - ElemType: AutoCaptureConfigOutput{}.Type(ctx), - }, - "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ - ElemType: ServedEntityOutput{}.Type(ctx), - }, - "served_models": basetypes.ListType{ - ElemType: ServedModelOutput{}.Type(ctx), - }, - "start_time": types.Int64Type, - "traffic_config": basetypes.ListType{ - ElemType: TrafficConfig{}.Type(ctx), - }, + "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, + "config_version": types.Int64Type, + "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, + "start_time": types.Int64Type, + "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } } @@ -2693,33 +2627,17 @@ func (o ExternalModel) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ExternalModel) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai21labs_config": basetypes.ListType{ - ElemType: Ai21LabsConfig{}.Type(ctx), - }, - "amazon_bedrock_config": basetypes.ListType{ - ElemType: AmazonBedrockConfig{}.Type(ctx), - }, - "anthropic_config": basetypes.ListType{ - ElemType: AnthropicConfig{}.Type(ctx), - }, - "cohere_config": basetypes.ListType{ - ElemType: CohereConfig{}.Type(ctx), - }, - "databricks_model_serving_config": basetypes.ListType{ - ElemType: DatabricksModelServingConfig{}.Type(ctx), - }, - "google_cloud_vertex_ai_config": basetypes.ListType{ - ElemType: GoogleCloudVertexAiConfig{}.Type(ctx), - }, - "name": types.StringType, - "openai_config": basetypes.ListType{ - ElemType: OpenAiConfig{}.Type(ctx), - }, - "palm_config": basetypes.ListType{ - ElemType: PaLmConfig{}.Type(ctx), - }, - "provider": types.StringType, - "task": types.StringType, + "ai21labs_config": basetypes.ListType{ElemType: Ai21LabsConfig{}.Type(ctx)}, + "amazon_bedrock_config": basetypes.ListType{ElemType: AmazonBedrockConfig{}.Type(ctx)}, + "anthropic_config": basetypes.ListType{ElemType: AnthropicConfig{}.Type(ctx)}, + "cohere_config": basetypes.ListType{ElemType: CohereConfig{}.Type(ctx)}, + "databricks_model_serving_config": basetypes.ListType{ElemType: DatabricksModelServingConfig{}.Type(ctx)}, + "google_cloud_vertex_ai_config": basetypes.ListType{ElemType: GoogleCloudVertexAiConfig{}.Type(ctx)}, + "name": types.StringType, + "openai_config": basetypes.ListType{ElemType: OpenAiConfig{}.Type(ctx)}, + "palm_config": basetypes.ListType{ElemType: PaLmConfig{}.Type(ctx)}, + "provider": types.StringType, + "task": types.StringType, }, } } @@ -3200,9 +3118,7 @@ func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetServingEndpointPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: ServingEndpointPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: ServingEndpointPermissionsDescription{}.Type(ctx)}, }, } } @@ -3431,9 +3347,7 @@ func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListEndpointsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ - ElemType: ServingEndpoint{}.Type(ctx), - }, + "endpoints": basetypes.ListType{ElemType: ServingEndpoint{}.Type(ctx)}, }, } } @@ -3552,9 +3466,7 @@ func (o ModelDataPlaneInfo) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ModelDataPlaneInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query_info": basetypes.ListType{ - ElemType: oauth2_tf.DataPlaneInfo{}.Type(ctx), - }, + "query_info": basetypes.ListType{ElemType: oauth2_tf.DataPlaneInfo{}.Type(ctx)}, }, } } @@ -3795,13 +3707,9 @@ func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) basetypes.O func (o PatchServingEndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add_tags": basetypes.ListType{ - ElemType: EndpointTag{}.Type(ctx), - }, - "delete_tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "name": types.StringType, + "add_tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "delete_tags": basetypes.ListType{ElemType: types.StringType}, + "name": types.StringType, }, } } @@ -3969,19 +3877,11 @@ func (o PutAiGatewayRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.Type(ctx), - }, - "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), - }, - "name": types.StringType, - "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.Type(ctx), - }, - "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), - }, + "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, + "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, + "name": types.StringType, + "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, + "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } } @@ -4146,18 +4046,10 @@ func (o PutAiGatewayResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "guardrails": basetypes.ListType{ - ElemType: AiGatewayGuardrails{}.Type(ctx), - }, - "inference_table_config": basetypes.ListType{ - ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), - }, - "rate_limits": basetypes.ListType{ - ElemType: AiGatewayRateLimit{}.Type(ctx), - }, - "usage_tracking_config": basetypes.ListType{ - ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), - }, + "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, + "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, + "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } } @@ -4310,10 +4202,8 @@ func (o PutRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PutRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.Type(ctx), - }, + "name": types.StringType, + "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, }, } } @@ -4383,9 +4273,7 @@ func (o PutResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PutResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rate_limits": basetypes.ListType{ - ElemType: RateLimit{}.Type(ctx), - }, + "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, }, } } @@ -4520,32 +4408,20 @@ func (o QueryEndpointInput) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataframe_records": basetypes.ListType{ - ElemType: types.ObjectType{}, - }, - "dataframe_split": basetypes.ListType{ - ElemType: DataframeSplitInput{}.Type(ctx), - }, - "extra_params": basetypes.MapType{ - ElemType: types.StringType, - }, - "input": types.ObjectType{}, - "inputs": types.ObjectType{}, - "instances": basetypes.ListType{ - ElemType: types.ObjectType{}, - }, - "max_tokens": types.Int64Type, - "messages": basetypes.ListType{ - ElemType: ChatMessage{}.Type(ctx), - }, - "n": types.Int64Type, - "name": types.StringType, - "prompt": types.ObjectType{}, - "stop": basetypes.ListType{ - ElemType: types.StringType, - }, - "stream": types.BoolType, - "temperature": types.Float64Type, + "dataframe_records": basetypes.ListType{ElemType: types.ObjectType{}}, + "dataframe_split": basetypes.ListType{ElemType: DataframeSplitInput{}.Type(ctx)}, + "extra_params": basetypes.MapType{ElemType: types.StringType}, + "input": types.ObjectType{}, + "inputs": types.ObjectType{}, + "instances": basetypes.ListType{ElemType: types.ObjectType{}}, + "max_tokens": types.Int64Type, + "messages": basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}, + "n": types.Int64Type, + "name": types.StringType, + "prompt": types.ObjectType{}, + "stop": basetypes.ListType{ElemType: types.StringType}, + "stream": types.BoolType, + "temperature": types.Float64Type, }, } } @@ -4782,23 +4658,15 @@ func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "choices": basetypes.ListType{ - ElemType: V1ResponseChoiceElement{}.Type(ctx), - }, - "created": types.Int64Type, - "data": basetypes.ListType{ - ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx), - }, - "id": types.StringType, - "model": types.StringType, - "object": types.StringType, - "predictions": basetypes.ListType{ - ElemType: types.ObjectType{}, - }, + "choices": basetypes.ListType{ElemType: V1ResponseChoiceElement{}.Type(ctx)}, + "created": types.Int64Type, + "data": basetypes.ListType{ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx)}, + "id": types.StringType, + "model": types.StringType, + "object": types.StringType, + "predictions": basetypes.ListType{ElemType: types.ObjectType{}}, "served-model-name": types.StringType, - "usage": basetypes.ListType{ - ElemType: ExternalModelUsageElement{}.Type(ctx), - }, + "usage": basetypes.ListType{ElemType: ExternalModelUsageElement{}.Type(ctx)}, }, } } @@ -5114,14 +4982,10 @@ func (o ServedEntityInput) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ServedEntityInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "entity_name": types.StringType, - "entity_version": types.StringType, - "environment_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.Type(ctx), - }, + "entity_name": types.StringType, + "entity_version": types.StringType, + "environment_vars": basetypes.MapType{ElemType: types.StringType}, + "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, "min_provisioned_throughput": types.Int64Type, @@ -5299,29 +5163,21 @@ func (o ServedEntityOutput) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ServedEntityOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "entity_name": types.StringType, - "entity_version": types.StringType, - "environment_vars": basetypes.MapType{ - ElemType: types.StringType, - }, - "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.Type(ctx), - }, - "foundation_model": basetypes.ListType{ - ElemType: FoundationModel{}.Type(ctx), - }, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "entity_name": types.StringType, + "entity_version": types.StringType, + "environment_vars": basetypes.MapType{ElemType: types.StringType}, + "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, + "foundation_model": basetypes.ListType{ElemType: FoundationModel{}.Type(ctx)}, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, "min_provisioned_throughput": types.Int64Type, "name": types.StringType, "scale_to_zero_enabled": types.BoolType, - "state": basetypes.ListType{ - ElemType: ServedModelState{}.Type(ctx), - }, - "workload_size": types.StringType, - "workload_type": types.StringType, + "state": basetypes.ListType{ElemType: ServedModelState{}.Type(ctx)}, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -5491,15 +5347,11 @@ func (o ServedEntitySpec) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ServedEntitySpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "entity_name": types.StringType, - "entity_version": types.StringType, - "external_model": basetypes.ListType{ - ElemType: ExternalModel{}.Type(ctx), - }, - "foundation_model": basetypes.ListType{ - ElemType: FoundationModel{}.Type(ctx), - }, - "name": types.StringType, + "entity_name": types.StringType, + "entity_version": types.StringType, + "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, + "foundation_model": basetypes.ListType{ElemType: FoundationModel{}.Type(ctx)}, + "name": types.StringType, }, } } @@ -5647,9 +5499,7 @@ func (o ServedModelInput) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ServedModelInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "environment_vars": basetypes.MapType{ - ElemType: types.StringType, - }, + "environment_vars": basetypes.MapType{ElemType: types.StringType}, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, "min_provisioned_throughput": types.Int64Type, @@ -5780,21 +5630,17 @@ func (o ServedModelOutput) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ServedModelOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "environment_vars": basetypes.MapType{ - ElemType: types.StringType, - }, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "environment_vars": basetypes.MapType{ElemType: types.StringType}, "instance_profile_arn": types.StringType, "model_name": types.StringType, "model_version": types.StringType, "name": types.StringType, "scale_to_zero_enabled": types.BoolType, - "state": basetypes.ListType{ - ElemType: ServedModelState{}.Type(ctx), - }, - "workload_size": types.StringType, - "workload_type": types.StringType, + "state": basetypes.ListType{ElemType: ServedModelState{}.Type(ctx)}, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -6074,24 +5920,16 @@ func (o ServingEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o ServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.Type(ctx), - }, - "config": basetypes.ListType{ - ElemType: EndpointCoreConfigSummary{}.Type(ctx), - }, + "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, + "config": basetypes.ListType{ElemType: EndpointCoreConfigSummary{}.Type(ctx)}, "creation_timestamp": types.Int64Type, "creator": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "name": types.StringType, - "state": basetypes.ListType{ - ElemType: EndpointState{}.Type(ctx), - }, - "tags": basetypes.ListType{ - ElemType: EndpointTag{}.Type(ctx), - }, - "task": types.StringType, + "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "task": types.StringType, }, } } @@ -6305,9 +6143,7 @@ func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) func (o ServingEndpointAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: ServingEndpointPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: ServingEndpointPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6431,33 +6267,21 @@ func (o ServingEndpointDetailed) ToObjectValue(ctx context.Context) basetypes.Ob func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ - ElemType: AiGatewayConfig{}.Type(ctx), - }, - "config": basetypes.ListType{ - ElemType: EndpointCoreConfigOutput{}.Type(ctx), - }, - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "data_plane_info": basetypes.ListType{ - ElemType: ModelDataPlaneInfo{}.Type(ctx), - }, + "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, + "config": basetypes.ListType{ElemType: EndpointCoreConfigOutput{}.Type(ctx)}, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "data_plane_info": basetypes.ListType{ElemType: ModelDataPlaneInfo{}.Type(ctx)}, "endpoint_url": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "name": types.StringType, - "pending_config": basetypes.ListType{ - ElemType: EndpointPendingConfig{}.Type(ctx), - }, - "permission_level": types.StringType, - "route_optimized": types.BoolType, - "state": basetypes.ListType{ - ElemType: EndpointState{}.Type(ctx), - }, - "tags": basetypes.ListType{ - ElemType: EndpointTag{}.Type(ctx), - }, - "task": types.StringType, + "pending_config": basetypes.ListType{ElemType: EndpointPendingConfig{}.Type(ctx)}, + "permission_level": types.StringType, + "route_optimized": types.BoolType, + "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "task": types.StringType, }, } } @@ -6662,11 +6486,9 @@ func (o ServingEndpointPermission) ToObjectValue(ctx context.Context) basetypes. func (o ServingEndpointPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -6741,11 +6563,9 @@ func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) basetypes func (o ServingEndpointPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ServingEndpointAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -6862,9 +6682,7 @@ func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o ServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: ServingEndpointAccessControlRequest{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlRequest{}.Type(ctx)}, "serving_endpoint_id": types.StringType, }, } @@ -6935,9 +6753,7 @@ func (o TrafficConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o TrafficConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "routes": basetypes.ListType{ - ElemType: Route{}.Type(ctx), - }, + "routes": basetypes.ListType{ElemType: Route{}.Type(ctx)}, }, } } @@ -7022,10 +6838,8 @@ func (o V1ResponseChoiceElement) Type(ctx context.Context) attr.Type { "finishReason": types.StringType, "index": types.Int64Type, "logprobs": types.Int64Type, - "message": basetypes.ListType{ - ElemType: ChatMessage{}.Type(ctx), - }, - "text": types.StringType, + "message": basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}, + "text": types.StringType, }, } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index bc3f2a8f12..c5d38a66b7 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -116,11 +116,9 @@ func (o AibiDashboardEmbeddingAccessPolicySetting) ToObjectValue(ctx context.Con func (o AibiDashboardEmbeddingAccessPolicySetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aibi_dashboard_embedding_access_policy": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingAccessPolicy{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "aibi_dashboard_embedding_access_policy": basetypes.ListType{ElemType: AibiDashboardEmbeddingAccessPolicy{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -189,9 +187,7 @@ func (o AibiDashboardEmbeddingApprovedDomains) ToObjectValue(ctx context.Context func (o AibiDashboardEmbeddingApprovedDomains) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "approved_domains": basetypes.ListType{ - ElemType: types.StringType, - }, + "approved_domains": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -276,9 +272,7 @@ func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectValue(ctx context. func (o AibiDashboardEmbeddingApprovedDomainsSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingApprovedDomains{}.Type(ctx), - }, + "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ElemType: AibiDashboardEmbeddingApprovedDomains{}.Type(ctx)}, "etag": types.StringType, "setting_name": types.StringType, }, @@ -365,11 +359,9 @@ func (o AutomaticClusterUpdateSetting) ToObjectValue(ctx context.Context) basety func (o AutomaticClusterUpdateSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "automatic_cluster_update_workspace": basetypes.ListType{ - ElemType: ClusterAutoRestartMessage{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "automatic_cluster_update_workspace": basetypes.ListType{ElemType: ClusterAutoRestartMessage{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -497,14 +489,10 @@ func (o ClusterAutoRestartMessage) ToObjectValue(ctx context.Context) basetypes. func (o ClusterAutoRestartMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "can_toggle": types.BoolType, - "enabled": types.BoolType, - "enablement_details": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageEnablementDetails{}.Type(ctx), - }, - "maintenance_window": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.Type(ctx), - }, + "can_toggle": types.BoolType, + "enabled": types.BoolType, + "enablement_details": basetypes.ListType{ElemType: ClusterAutoRestartMessageEnablementDetails{}.Type(ctx)}, + "maintenance_window": basetypes.ListType{ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.Type(ctx)}, "restart_even_if_no_updates_available": types.BoolType, }, } @@ -657,9 +645,7 @@ func (o ClusterAutoRestartMessageMaintenanceWindow) ToObjectValue(ctx context.Co func (o ClusterAutoRestartMessageMaintenanceWindow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "week_day_based_schedule": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.Type(ctx), - }, + "week_day_based_schedule": basetypes.ListType{ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.Type(ctx)}, }, } } @@ -734,11 +720,9 @@ func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObject func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "day_of_week": types.StringType, - "frequency": types.StringType, - "window_start_time": basetypes.ListType{ - ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.Type(ctx), - }, + "day_of_week": types.StringType, + "frequency": types.StringType, + "window_start_time": basetypes.ListType{ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.Type(ctx)}, }, } } @@ -857,10 +841,8 @@ func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) basetypes. func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ - ElemType: types.StringType, - }, - "is_enabled": types.BoolType, + "compliance_standards": basetypes.ListType{ElemType: types.StringType}, + "is_enabled": types.BoolType, }, } } @@ -946,11 +928,9 @@ func (o ComplianceSecurityProfileSetting) ToObjectValue(ctx context.Context) bas func (o ComplianceSecurityProfileSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_security_profile_workspace": basetypes.ListType{ - ElemType: ComplianceSecurityProfile{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "compliance_security_profile_workspace": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1035,21 +1015,11 @@ func (o Config) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Config) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "email": basetypes.ListType{ - ElemType: EmailConfig{}.Type(ctx), - }, - "generic_webhook": basetypes.ListType{ - ElemType: GenericWebhookConfig{}.Type(ctx), - }, - "microsoft_teams": basetypes.ListType{ - ElemType: MicrosoftTeamsConfig{}.Type(ctx), - }, - "pagerduty": basetypes.ListType{ - ElemType: PagerdutyConfig{}.Type(ctx), - }, - "slack": basetypes.ListType{ - ElemType: SlackConfig{}.Type(ctx), - }, + "email": basetypes.ListType{ElemType: EmailConfig{}.Type(ctx)}, + "generic_webhook": basetypes.ListType{ElemType: GenericWebhookConfig{}.Type(ctx)}, + "microsoft_teams": basetypes.ListType{ElemType: MicrosoftTeamsConfig{}.Type(ctx)}, + "pagerduty": basetypes.ListType{ElemType: PagerdutyConfig{}.Type(ctx)}, + "slack": basetypes.ListType{ElemType: SlackConfig{}.Type(ctx)}, }, } } @@ -1234,11 +1204,9 @@ func (o CreateIpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateIpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_addresses": basetypes.ListType{ - ElemType: types.StringType, - }, - "label": types.StringType, - "list_type": types.StringType, + "ip_addresses": basetypes.ListType{ElemType: types.StringType}, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -1309,9 +1277,7 @@ func (o CreateIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes func (o CreateIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.Type(ctx), - }, + "ip_access_list": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -1436,9 +1402,7 @@ func (o CreateNotificationDestinationRequest) ToObjectValue(ctx context.Context) func (o CreateNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config": basetypes.ListType{ - ElemType: Config{}.Type(ctx), - }, + "config": basetypes.ListType{ElemType: Config{}.Type(ctx)}, "display_name": types.StringType, }, } @@ -1563,9 +1527,7 @@ func (o CreateOboTokenResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateOboTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_info": basetypes.ListType{ - ElemType: TokenInfo{}.Type(ctx), - }, + "token_info": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, "token_value": types.StringType, }, } @@ -1739,9 +1701,7 @@ func (o CreateTokenResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o CreateTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_info": basetypes.ListType{ - ElemType: PublicTokenInfo{}.Type(ctx), - }, + "token_info": basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}, "token_value": types.StringType, }, } @@ -1817,10 +1777,8 @@ func (o CspEnablementAccount) ToObjectValue(ctx context.Context) basetypes.Objec func (o CspEnablementAccount) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ - ElemType: types.StringType, - }, - "is_enforced": types.BoolType, + "compliance_standards": basetypes.ListType{ElemType: types.StringType}, + "is_enforced": types.BoolType, }, } } @@ -1906,11 +1864,9 @@ func (o CspEnablementAccountSetting) ToObjectValue(ctx context.Context) basetype func (o CspEnablementAccountSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "csp_enablement_account": basetypes.ListType{ - ElemType: CspEnablementAccount{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "csp_enablement_account": basetypes.ListType{ElemType: CspEnablementAccount{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -2005,10 +1961,8 @@ func (o DefaultNamespaceSetting) ToObjectValue(ctx context.Context) basetypes.Ob func (o DefaultNamespaceSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "namespace": basetypes.ListType{ - ElemType: StringMessage{}.Type(ctx), - }, + "etag": types.StringType, + "namespace": basetypes.ListType{ElemType: StringMessage{}.Type(ctx)}, "setting_name": types.StringType, }, } @@ -3211,11 +3165,9 @@ func (o DisableLegacyAccess) ToObjectValue(ctx context.Context) basetypes.Object func (o DisableLegacyAccess) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "disable_legacy_access": basetypes.ListType{ - ElemType: BooleanMessage{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "disable_legacy_access": basetypes.ListType{ElemType: BooleanMessage{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -3300,11 +3252,9 @@ func (o DisableLegacyDbfs) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o DisableLegacyDbfs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "disable_legacy_dbfs": basetypes.ListType{ - ElemType: BooleanMessage{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "disable_legacy_dbfs": basetypes.ListType{ElemType: BooleanMessage{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -3389,11 +3339,9 @@ func (o DisableLegacyFeatures) ToObjectValue(ctx context.Context) basetypes.Obje func (o DisableLegacyFeatures) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "disable_legacy_features": basetypes.ListType{ - ElemType: BooleanMessage{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "disable_legacy_features": basetypes.ListType{ElemType: BooleanMessage{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -3467,9 +3415,7 @@ func (o EgressNetworkPolicy) ToObjectValue(ctx context.Context) basetypes.Object func (o EgressNetworkPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "internet_access": basetypes.ListType{ - ElemType: EgressNetworkPolicyInternetAccessPolicy{}.Type(ctx), - }, + "internet_access": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicy{}.Type(ctx)}, }, } } @@ -3555,16 +3501,10 @@ func (o EgressNetworkPolicyInternetAccessPolicy) ToObjectValue(ctx context.Conte func (o EgressNetworkPolicyInternetAccessPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_internet_destinations": basetypes.ListType{ - ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx), - }, - "allowed_storage_destinations": basetypes.ListType{ - ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx), - }, - "log_only_mode": basetypes.ListType{ - ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx), - }, - "restriction_mode": types.StringType, + "allowed_internet_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx)}, + "allowed_storage_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx)}, + "log_only_mode": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx)}, + "restriction_mode": types.StringType, }, } } @@ -3745,9 +3685,7 @@ func (o EgressNetworkPolicyInternetAccessPolicyLogOnlyMode) Type(ctx context.Con return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_only_mode_type": types.StringType, - "workloads": basetypes.ListType{ - ElemType: types.StringType, - }, + "workloads": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3838,9 +3776,7 @@ func (o EgressNetworkPolicyInternetAccessPolicyStorageDestination) ToObjectValue func (o EgressNetworkPolicyInternetAccessPolicyStorageDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_paths": basetypes.ListType{ - ElemType: types.StringType, - }, + "allowed_paths": basetypes.ListType{ElemType: types.StringType}, "azure_container": types.StringType, "azure_dns_zone": types.StringType, "azure_storage_account": types.StringType, @@ -3917,9 +3853,7 @@ func (o EmailConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EmailConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "addresses": basetypes.ListType{ - ElemType: types.StringType, - }, + "addresses": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -4083,11 +4017,9 @@ func (o EnhancedSecurityMonitoringSetting) ToObjectValue(ctx context.Context) ba func (o EnhancedSecurityMonitoringSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "enhanced_security_monitoring_workspace": basetypes.ListType{ - ElemType: EnhancedSecurityMonitoring{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "enhanced_security_monitoring_workspace": basetypes.ListType{ElemType: EnhancedSecurityMonitoring{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -4215,11 +4147,9 @@ func (o EsmEnablementAccountSetting) ToObjectValue(ctx context.Context) basetype func (o EsmEnablementAccountSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "esm_enablement_account": basetypes.ListType{ - ElemType: EsmEnablementAccount{}.Type(ctx), - }, - "etag": types.StringType, - "setting_name": types.StringType, + "esm_enablement_account": basetypes.ListType{ElemType: EsmEnablementAccount{}.Type(ctx)}, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -4306,10 +4236,8 @@ func (o ExchangeToken) Type(ctx context.Context) attr.Type { "credential": types.StringType, "credentialEolTime": types.Int64Type, "ownerId": types.Int64Type, - "scopes": basetypes.ListType{ - ElemType: types.StringType, - }, - "tokenType": types.StringType, + "scopes": basetypes.ListType{ElemType: types.StringType}, + "tokenType": types.StringType, }, } } @@ -4388,15 +4316,9 @@ func (o ExchangeTokenRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o ExchangeTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "partitionId": basetypes.ListType{ - ElemType: PartitionId{}.Type(ctx), - }, - "scopes": basetypes.ListType{ - ElemType: types.StringType, - }, - "tokenType": basetypes.ListType{ - ElemType: types.StringType, - }, + "partitionId": basetypes.ListType{ElemType: PartitionId{}.Type(ctx)}, + "scopes": basetypes.ListType{ElemType: types.StringType}, + "tokenType": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -4518,9 +4440,7 @@ func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExchangeTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ - ElemType: ExchangeToken{}.Type(ctx), - }, + "values": basetypes.ListType{ElemType: ExchangeToken{}.Type(ctx)}, }, } } @@ -4591,9 +4511,7 @@ func (o FetchIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes. func (o FetchIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.Type(ctx), - }, + "ip_access_list": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -5350,9 +5268,7 @@ func (o GetIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o GetIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessListInfo{}.Type(ctx), - }, + "ip_access_list": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -5422,9 +5338,7 @@ func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetIpAccessListsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ - ElemType: IpAccessListInfo{}.Type(ctx), - }, + "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -5809,9 +5723,7 @@ func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) bas func (o GetTokenPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: TokenPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: TokenPermissionsDescription{}.Type(ctx)}, }, } } @@ -5881,9 +5793,7 @@ func (o GetTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o GetTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_info": basetypes.ListType{ - ElemType: TokenInfo{}.Type(ctx), - }, + "token_info": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, }, } } @@ -5990,14 +5900,12 @@ func (o IpAccessListInfo) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "created_by": types.Int64Type, "enabled": types.BoolType, - "ip_addresses": basetypes.ListType{ - ElemType: types.StringType, - }, - "label": types.StringType, - "list_id": types.StringType, - "list_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.Int64Type, + "ip_addresses": basetypes.ListType{ElemType: types.StringType}, + "label": types.StringType, + "list_id": types.StringType, + "list_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.Int64Type, }, } } @@ -6067,9 +5975,7 @@ func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ - ElemType: IpAccessListInfo{}.Type(ctx), - }, + "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -6142,9 +6048,7 @@ func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Cont func (o ListNccAzurePrivateEndpointRulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ - ElemType: NccAzurePrivateEndpointRule{}.Type(ctx), - }, + "items": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -6261,9 +6165,7 @@ func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context func (o ListNetworkConnectivityConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ - ElemType: NetworkConnectivityConfiguration{}.Type(ctx), - }, + "items": basetypes.ListType{ElemType: NetworkConnectivityConfiguration{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -6384,9 +6286,7 @@ func (o ListNotificationDestinationsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ - ElemType: ListNotificationDestinationsResult{}.Type(ctx), - }, + "results": basetypes.ListType{ElemType: ListNotificationDestinationsResult{}.Type(ctx)}, }, } } @@ -6554,9 +6454,7 @@ func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListPublicTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ - ElemType: PublicTokenInfo{}.Type(ctx), - }, + "token_infos": basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}, }, } } @@ -6674,9 +6572,7 @@ func (o ListTokensResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ - ElemType: TokenInfo{}.Type(ctx), - }, + "token_infos": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, }, } } @@ -6795,9 +6691,7 @@ func (o NccAwsStableIpRule) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o NccAwsStableIpRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cidr_blocks": basetypes.ListType{ - ElemType: types.StringType, - }, + "cidr_blocks": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -6971,13 +6865,9 @@ func (o NccAzureServiceEndpointRule) ToObjectValue(ctx context.Context) basetype func (o NccAzureServiceEndpointRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "subnets": basetypes.ListType{ - ElemType: types.StringType, - }, - "target_region": types.StringType, - "target_services": basetypes.ListType{ - ElemType: types.StringType, - }, + "subnets": basetypes.ListType{ElemType: types.StringType}, + "target_region": types.StringType, + "target_services": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7082,12 +6972,8 @@ func (o NccEgressConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o NccEgressConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "default_rules": basetypes.ListType{ - ElemType: NccEgressDefaultRules{}.Type(ctx), - }, - "target_rules": basetypes.ListType{ - ElemType: NccEgressTargetRules{}.Type(ctx), - }, + "default_rules": basetypes.ListType{ElemType: NccEgressDefaultRules{}.Type(ctx)}, + "target_rules": basetypes.ListType{ElemType: NccEgressTargetRules{}.Type(ctx)}, }, } } @@ -7194,12 +7080,8 @@ func (o NccEgressDefaultRules) ToObjectValue(ctx context.Context) basetypes.Obje func (o NccEgressDefaultRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_stable_ip_rule": basetypes.ListType{ - ElemType: NccAwsStableIpRule{}.Type(ctx), - }, - "azure_service_endpoint_rule": basetypes.ListType{ - ElemType: NccAzureServiceEndpointRule{}.Type(ctx), - }, + "aws_stable_ip_rule": basetypes.ListType{ElemType: NccAwsStableIpRule{}.Type(ctx)}, + "azure_service_endpoint_rule": basetypes.ListType{ElemType: NccAzureServiceEndpointRule{}.Type(ctx)}, }, } } @@ -7296,9 +7178,7 @@ func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) basetypes.Objec func (o NccEgressTargetRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "azure_private_endpoint_rules": basetypes.ListType{ - ElemType: NccAzurePrivateEndpointRule{}.Type(ctx), - }, + "azure_private_endpoint_rules": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, }, } } @@ -7392,11 +7272,9 @@ func (o NetworkConnectivityConfiguration) ToObjectValue(ctx context.Context) bas func (o NetworkConnectivityConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "creation_time": types.Int64Type, - "egress_config": basetypes.ListType{ - ElemType: NccEgressConfig{}.Type(ctx), - }, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "egress_config": basetypes.ListType{ElemType: NccEgressConfig{}.Type(ctx)}, "name": types.StringType, "network_connectivity_config_id": types.StringType, "region": types.StringType, @@ -7482,9 +7360,7 @@ func (o NotificationDestination) ToObjectValue(ctx context.Context) basetypes.Ob func (o NotificationDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config": basetypes.ListType{ - ElemType: Config{}.Type(ctx), - }, + "config": basetypes.ListType{ElemType: Config{}.Type(ctx)}, "destination_type": types.StringType, "display_name": types.StringType, "id": types.StringType, @@ -7710,11 +7586,9 @@ func (o PersonalComputeSetting) ToObjectValue(ctx context.Context) basetypes.Obj func (o PersonalComputeSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "personal_compute": basetypes.ListType{ - ElemType: PersonalComputeMessage{}.Type(ctx), - }, - "setting_name": types.StringType, + "etag": types.StringType, + "personal_compute": basetypes.ListType{ElemType: PersonalComputeMessage{}.Type(ctx)}, + "setting_name": types.StringType, }, } } @@ -7859,11 +7733,9 @@ func (o ReplaceIpAccessList) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, "ip_access_list_id": types.StringType, - "ip_addresses": basetypes.ListType{ - ElemType: types.StringType, - }, - "label": types.StringType, - "list_type": types.StringType, + "ip_addresses": basetypes.ListType{ElemType: types.StringType}, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -8026,11 +7898,9 @@ func (o RestrictWorkspaceAdminsSetting) ToObjectValue(ctx context.Context) baset func (o RestrictWorkspaceAdminsSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "restrict_workspace_admins": basetypes.ListType{ - ElemType: RestrictWorkspaceAdminsMessage{}.Type(ctx), - }, - "setting_name": types.StringType, + "etag": types.StringType, + "restrict_workspace_admins": basetypes.ListType{ElemType: RestrictWorkspaceAdminsMessage{}.Type(ctx)}, + "setting_name": types.StringType, }, } } @@ -8368,9 +8238,7 @@ func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) basetypes func (o TokenAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: TokenPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: TokenPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -8525,11 +8393,9 @@ func (o TokenPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o TokenPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -8604,11 +8470,9 @@ func (o TokenPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o TokenPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: TokenAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: TokenAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -8722,9 +8586,7 @@ func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o TokenPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: TokenAccessControlRequest{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: TokenAccessControlRequest{}.Type(ctx)}, }, } } @@ -8807,9 +8669,7 @@ func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) Type(ctx context AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.Type(ctx)}, }, } } @@ -8892,9 +8752,7 @@ func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) Type(ctx cont AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.Type(ctx)}, }, } } @@ -8977,9 +8835,7 @@ func (o UpdateAutomaticClusterUpdateSettingRequest) Type(ctx context.Context) at AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: AutomaticClusterUpdateSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: AutomaticClusterUpdateSetting{}.Type(ctx)}, }, } } @@ -9062,9 +8918,7 @@ func (o UpdateComplianceSecurityProfileSettingRequest) Type(ctx context.Context) AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: ComplianceSecurityProfileSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: ComplianceSecurityProfileSetting{}.Type(ctx)}, }, } } @@ -9147,9 +9001,7 @@ func (o UpdateCspEnablementAccountSettingRequest) Type(ctx context.Context) attr AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: CspEnablementAccountSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: CspEnablementAccountSetting{}.Type(ctx)}, }, } } @@ -9240,9 +9092,7 @@ func (o UpdateDefaultNamespaceSettingRequest) Type(ctx context.Context) attr.Typ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: DefaultNamespaceSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: DefaultNamespaceSetting{}.Type(ctx)}, }, } } @@ -9325,9 +9175,7 @@ func (o UpdateDisableLegacyAccessRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: DisableLegacyAccess{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: DisableLegacyAccess{}.Type(ctx)}, }, } } @@ -9410,9 +9258,7 @@ func (o UpdateDisableLegacyDbfsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: DisableLegacyDbfs{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: DisableLegacyDbfs{}.Type(ctx)}, }, } } @@ -9495,9 +9341,7 @@ func (o UpdateDisableLegacyFeaturesRequest) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: DisableLegacyFeatures{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: DisableLegacyFeatures{}.Type(ctx)}, }, } } @@ -9580,9 +9424,7 @@ func (o UpdateEnhancedSecurityMonitoringSettingRequest) Type(ctx context.Context AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: EnhancedSecurityMonitoringSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: EnhancedSecurityMonitoringSetting{}.Type(ctx)}, }, } } @@ -9665,9 +9507,7 @@ func (o UpdateEsmEnablementAccountSettingRequest) Type(ctx context.Context) attr AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: EsmEnablementAccountSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: EsmEnablementAccountSetting{}.Type(ctx)}, }, } } @@ -9757,11 +9597,9 @@ func (o UpdateIpAccessList) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, "ip_access_list_id": types.StringType, - "ip_addresses": basetypes.ListType{ - ElemType: types.StringType, - }, - "label": types.StringType, - "list_type": types.StringType, + "ip_addresses": basetypes.ListType{ElemType: types.StringType}, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -9838,9 +9676,7 @@ func (o UpdateNotificationDestinationRequest) ToObjectValue(ctx context.Context) func (o UpdateNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config": basetypes.ListType{ - ElemType: Config{}.Type(ctx), - }, + "config": basetypes.ListType{ElemType: Config{}.Type(ctx)}, "display_name": types.StringType, "id": types.StringType, }, @@ -9925,9 +9761,7 @@ func (o UpdatePersonalComputeSettingRequest) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: PersonalComputeSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: PersonalComputeSetting{}.Type(ctx)}, }, } } @@ -10046,9 +9880,7 @@ func (o UpdateRestrictWorkspaceAdminsSettingRequest) Type(ctx context.Context) a AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ - ElemType: RestrictWorkspaceAdminsSetting{}.Type(ctx), - }, + "setting": basetypes.ListType{ElemType: RestrictWorkspaceAdminsSetting{}.Type(ctx)}, }, } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index 9b7d073b34..fa69b5ac8b 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -149,15 +149,11 @@ func (o CreateRecipient) Type(ctx context.Context) attr.Type { "comment": types.StringType, "data_recipient_global_metastore_id": types.StringType, "expiration_time": types.Int64Type, - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.Type(ctx), - }, - "name": types.StringType, - "owner": types.StringType, - "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.Type(ctx), - }, - "sharing_code": types.StringType, + "ip_access_list": basetypes.ListType{ElemType: IpAccessList{}.Type(ctx)}, + "name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, + "sharing_code": types.StringType, }, } } @@ -639,9 +635,7 @@ func (o GetRecipientSharePermissionsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "permissions_out": basetypes.ListType{ - ElemType: ShareToPrivilegeAssignment{}.Type(ctx), - }, + "permissions_out": basetypes.ListType{ElemType: ShareToPrivilegeAssignment{}.Type(ctx)}, }, } } @@ -758,9 +752,7 @@ func (o IpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o IpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_ip_addresses": basetypes.ListType{ - ElemType: types.StringType, - }, + "allowed_ip_addresses": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -836,9 +828,7 @@ func (o ListProviderSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ - ElemType: ProviderShare{}.Type(ctx), - }, + "shares": basetypes.ListType{ElemType: ProviderShare{}.Type(ctx)}, }, } } @@ -974,9 +964,7 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ - ElemType: ProviderInfo{}.Type(ctx), - }, + "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -1112,9 +1100,7 @@ func (o ListRecipientsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "recipients": basetypes.ListType{ - ElemType: RecipientInfo{}.Type(ctx), - }, + "recipients": basetypes.ListType{ElemType: RecipientInfo{}.Type(ctx)}, }, } } @@ -1249,9 +1235,7 @@ func (o ListSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ - ElemType: ShareInfo{}.Type(ctx), - }, + "shares": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, }, } } @@ -1321,9 +1305,7 @@ func (o Partition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Partition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ - ElemType: PartitionValue{}.Type(ctx), - }, + "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, }, } } @@ -1393,9 +1375,7 @@ func (o PartitionSpecificationPartition) ToObjectValue(ctx context.Context) base func (o PartitionSpecificationPartition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ - ElemType: PartitionValue{}.Type(ctx), - }, + "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, }, } } @@ -1526,10 +1506,8 @@ func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.Object func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principal": types.StringType, - "privileges": basetypes.ListType{ - ElemType: types.StringType, - }, + "principal": types.StringType, + "privileges": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -1654,13 +1632,11 @@ func (o ProviderInfo) Type(ctx context.Context) attr.Type { "metastore_id": types.StringType, "name": types.StringType, "owner": types.StringType, - "recipient_profile": basetypes.ListType{ - ElemType: RecipientProfile{}.Type(ctx), - }, - "recipient_profile_str": types.StringType, - "region": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "recipient_profile": basetypes.ListType{ElemType: RecipientProfile{}.Type(ctx)}, + "recipient_profile_str": types.StringType, + "region": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1842,22 +1818,16 @@ func (o RecipientInfo) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "created_by": types.StringType, "data_recipient_global_metastore_id": types.StringType, - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.Type(ctx), - }, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.Type(ctx), - }, - "region": types.StringType, - "sharing_code": types.StringType, - "tokens": basetypes.ListType{ - ElemType: RecipientTokenInfo{}.Type(ctx), - }, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "ip_access_list": basetypes.ListType{ElemType: IpAccessList{}.Type(ctx)}, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, + "region": types.StringType, + "sharing_code": types.StringType, + "tokens": basetypes.ListType{ElemType: RecipientTokenInfo{}.Type(ctx)}, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -2244,9 +2214,7 @@ func (o SecurablePropertiesKvPairs) ToObjectValue(ctx context.Context) basetypes func (o SecurablePropertiesKvPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "properties": basetypes.MapType{ - ElemType: types.StringType, - }, + "properties": basetypes.MapType{ElemType: types.StringType}, }, } } @@ -2343,13 +2311,11 @@ func (o ShareInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ShareInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "name": types.StringType, - "object": basetypes.ListType{ - ElemType: SharedDataObject{}.Type(ctx), - }, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "name": types.StringType, + "object": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, "owner": types.StringType, "storage_location": types.StringType, "storage_root": types.StringType, @@ -2486,10 +2452,8 @@ func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes func (o ShareToPrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ - ElemType: PrivilegeAssignment{}.Type(ctx), - }, - "share_name": types.StringType, + "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, + "share_name": types.StringType, }, } } @@ -2658,15 +2622,13 @@ func (o SharedDataObject) Type(ctx context.Context) attr.Type { "history_data_sharing_status": types.StringType, "effective_history_data_sharing_status": types.StringType, "name": types.StringType, - "partition": basetypes.ListType{ - ElemType: Partition{}.Type(ctx), - }, - "shared_as": types.StringType, - "effective_shared_as": types.StringType, - "start_version": types.Int64Type, - "effective_start_version": types.Int64Type, - "status": types.StringType, - "string_shared_as": types.StringType, + "partition": basetypes.ListType{ElemType: Partition{}.Type(ctx)}, + "shared_as": types.StringType, + "effective_shared_as": types.StringType, + "start_version": types.Int64Type, + "effective_start_version": types.Int64Type, + "status": types.StringType, + "string_shared_as": types.StringType, }, } } @@ -2739,10 +2701,8 @@ func (o SharedDataObjectUpdate) ToObjectValue(ctx context.Context) basetypes.Obj func (o SharedDataObjectUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action": types.StringType, - "data_object": basetypes.ListType{ - ElemType: SharedDataObject{}.Type(ctx), - }, + "action": types.StringType, + "data_object": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, }, } } @@ -2929,17 +2889,13 @@ func (o UpdateRecipient) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o UpdateRecipient) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "expiration_time": types.Int64Type, - "ip_access_list": basetypes.ListType{ - ElemType: IpAccessList{}.Type(ctx), - }, - "name": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "properties_kvpairs": basetypes.ListType{ - ElemType: SecurablePropertiesKvPairs{}.Type(ctx), - }, + "comment": types.StringType, + "expiration_time": types.Int64Type, + "ip_access_list": basetypes.ListType{ElemType: IpAccessList{}.Type(ctx)}, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, }, } } @@ -3091,9 +3047,7 @@ func (o UpdateShare) Type(ctx context.Context) attr.Type { "new_name": types.StringType, "owner": types.StringType, "storage_root": types.StringType, - "updates": basetypes.ListType{ - ElemType: SharedDataObjectUpdate{}.Type(ctx), - }, + "updates": basetypes.ListType{ElemType: SharedDataObjectUpdate{}.Type(ctx)}, }, } } @@ -3180,9 +3134,7 @@ func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateSharePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ - ElemType: catalog_tf.PermissionsChange{}.Type(ctx), - }, + "changes": basetypes.ListType{ElemType: catalog_tf.PermissionsChange{}.Type(ctx)}, "max_results": types.Int64Type, "name": types.StringType, "page_token": types.StringType, diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 9fe1288aaf..1490896a65 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -165,9 +165,7 @@ func (o Alert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Alert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ - ElemType: AlertCondition{}.Type(ctx), - }, + "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, "create_time": types.StringType, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -264,12 +262,8 @@ func (o AlertCondition) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "empty_result_state": types.StringType, "op": types.StringType, - "operand": basetypes.ListType{ - ElemType: AlertConditionOperand{}.Type(ctx), - }, - "threshold": basetypes.ListType{ - ElemType: AlertConditionThreshold{}.Type(ctx), - }, + "operand": basetypes.ListType{ElemType: AlertConditionOperand{}.Type(ctx)}, + "threshold": basetypes.ListType{ElemType: AlertConditionThreshold{}.Type(ctx)}, }, } } @@ -364,9 +358,7 @@ func (o AlertConditionOperand) ToObjectValue(ctx context.Context) basetypes.Obje func (o AlertConditionOperand) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "column": basetypes.ListType{ - ElemType: AlertOperandColumn{}.Type(ctx), - }, + "column": basetypes.ListType{ElemType: AlertOperandColumn{}.Type(ctx)}, }, } } @@ -435,9 +427,7 @@ func (o AlertConditionThreshold) ToObjectValue(ctx context.Context) basetypes.Ob func (o AlertConditionThreshold) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ - ElemType: AlertOperandValue{}.Type(ctx), - }, + "value": basetypes.ListType{ElemType: AlertOperandValue{}.Type(ctx)}, }, } } @@ -732,15 +722,11 @@ func (o AlertQuery) Type(ctx context.Context) attr.Type { "is_draft": types.BoolType, "is_safe": types.BoolType, "name": types.StringType, - "options": basetypes.ListType{ - ElemType: QueryOptions{}.Type(ctx), - }, - "query": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "updated_at": types.StringType, - "user_id": types.Int64Type, + "options": basetypes.ListType{ElemType: QueryOptions{}.Type(ctx)}, + "query": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "updated_at": types.StringType, + "user_id": types.Int64Type, }, } } @@ -1151,10 +1137,8 @@ func (o CreateAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "options": basetypes.ListType{ - ElemType: AlertOptions{}.Type(ctx), - }, + "name": types.StringType, + "options": basetypes.ListType{ElemType: AlertOptions{}.Type(ctx)}, "parent": types.StringType, "query_id": types.StringType, "rearm": types.Int64Type, @@ -1226,9 +1210,7 @@ func (o CreateAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ - ElemType: CreateAlertRequestAlert{}.Type(ctx), - }, + "alert": basetypes.ListType{ElemType: CreateAlertRequestAlert{}.Type(ctx)}, }, } } @@ -1328,9 +1310,7 @@ func (o CreateAlertRequestAlert) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateAlertRequestAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ - ElemType: AlertCondition{}.Type(ctx), - }, + "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, "custom_body": types.StringType, "custom_subject": types.StringType, "display_name": types.StringType, @@ -1406,9 +1386,7 @@ func (o CreateQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query": basetypes.ListType{ - ElemType: CreateQueryRequestQuery{}.Type(ctx), - }, + "query": basetypes.ListType{ElemType: CreateQueryRequestQuery{}.Type(ctx)}, }, } } @@ -1515,17 +1493,13 @@ func (o CreateQueryRequestQuery) Type(ctx context.Context) attr.Type { "catalog": types.StringType, "description": types.StringType, "display_name": types.StringType, - "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.Type(ctx), - }, - "parent_path": types.StringType, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "parent_path": types.StringType, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "warehouse_id": types.StringType, }, } } @@ -1683,9 +1657,7 @@ func (o CreateVisualizationRequest) ToObjectValue(ctx context.Context) basetypes func (o CreateVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "visualization": basetypes.ListType{ - ElemType: CreateVisualizationRequestVisualization{}.Type(ctx), - }, + "visualization": basetypes.ListType{ElemType: CreateVisualizationRequestVisualization{}.Type(ctx)}, }, } } @@ -1889,10 +1861,8 @@ func (o CreateWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ - ElemType: Channel{}.Type(ctx), - }, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, @@ -1902,10 +1872,8 @@ func (o CreateWarehouseRequest) Type(ctx context.Context) attr.Type { "min_num_clusters": types.Int64Type, "name": types.StringType, "spot_instance_policy": types.StringType, - "tags": basetypes.ListType{ - ElemType: EndpointTags{}.Type(ctx), - }, - "warehouse_type": types.StringType, + "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, + "warehouse_type": types.StringType, }, } } @@ -2060,11 +2028,9 @@ func (o CreateWidget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateWidget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboard_id": types.StringType, - "id": types.StringType, - "options": basetypes.ListType{ - ElemType: WidgetOptions{}.Type(ctx), - }, + "dashboard_id": types.StringType, + "id": types.StringType, + "options": basetypes.ListType{ElemType: WidgetOptions{}.Type(ctx)}, "text": types.StringType, "visualization_id": types.StringType, "width": types.Int64Type, @@ -2208,23 +2174,15 @@ func (o Dashboard) Type(ctx context.Context) attr.Type { "is_draft": types.BoolType, "is_favorite": types.BoolType, "name": types.StringType, - "options": basetypes.ListType{ - ElemType: DashboardOptions{}.Type(ctx), - }, - "parent": types.StringType, - "permission_tier": types.StringType, - "slug": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "updated_at": types.StringType, - "user": basetypes.ListType{ - ElemType: User{}.Type(ctx), - }, - "user_id": types.Int64Type, - "widgets": basetypes.ListType{ - ElemType: Widget{}.Type(ctx), - }, + "options": basetypes.ListType{ElemType: DashboardOptions{}.Type(ctx)}, + "parent": types.StringType, + "permission_tier": types.StringType, + "slug": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "updated_at": types.StringType, + "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "user_id": types.Int64Type, + "widgets": basetypes.ListType{ElemType: Widget{}.Type(ctx)}, }, } } @@ -2386,9 +2344,7 @@ func (o DashboardEditContent) Type(ctx context.Context) attr.Type { "dashboard_id": types.StringType, "name": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, + "tags": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -2526,9 +2482,7 @@ func (o DashboardPostContent) Type(ctx context.Context) attr.Type { "name": types.StringType, "parent": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, + "tags": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -2734,9 +2688,7 @@ func (o DateRangeValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o DateRangeValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "date_range_value": basetypes.ListType{ - ElemType: DateRange{}.Type(ctx), - }, + "date_range_value": basetypes.ListType{ElemType: DateRange{}.Type(ctx)}, "dynamic_date_range_value": types.StringType, "precision": types.StringType, "start_day_of_week": types.Int64Type, @@ -3244,9 +3196,7 @@ func (o EditAlert) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "name": types.StringType, - "options": basetypes.ListType{ - ElemType: AlertOptions{}.Type(ctx), - }, + "options": basetypes.ListType{ElemType: AlertOptions{}.Type(ctx)}, "query_id": types.StringType, "rearm": types.Int64Type, }, @@ -3391,10 +3341,8 @@ func (o EditWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o EditWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ - ElemType: Channel{}.Type(ctx), - }, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, @@ -3405,10 +3353,8 @@ func (o EditWarehouseRequest) Type(ctx context.Context) attr.Type { "min_num_clusters": types.Int64Type, "name": types.StringType, "spot_instance_policy": types.StringType, - "tags": basetypes.ListType{ - ElemType: EndpointTags{}.Type(ctx), - }, - "warehouse_type": types.StringType, + "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, + "warehouse_type": types.StringType, }, } } @@ -3637,13 +3583,11 @@ func (o EndpointHealth) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o EndpointHealth) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "details": types.StringType, - "failure_reason": basetypes.ListType{ - ElemType: TerminationReason{}.Type(ctx), - }, - "message": types.StringType, - "status": types.StringType, - "summary": types.StringType, + "details": types.StringType, + "failure_reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, + "message": types.StringType, + "status": types.StringType, + "summary": types.StringType, }, } } @@ -3807,34 +3751,26 @@ func (o EndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ - ElemType: Channel{}.Type(ctx), - }, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, - "health": basetypes.ListType{ - ElemType: EndpointHealth{}.Type(ctx), - }, - "id": types.StringType, - "instance_profile_arn": types.StringType, - "jdbc_url": types.StringType, - "max_num_clusters": types.Int64Type, - "min_num_clusters": types.Int64Type, - "name": types.StringType, - "num_active_sessions": types.Int64Type, - "num_clusters": types.Int64Type, - "odbc_params": basetypes.ListType{ - ElemType: OdbcParams{}.Type(ctx), - }, - "spot_instance_policy": types.StringType, - "state": types.StringType, - "tags": basetypes.ListType{ - ElemType: EndpointTags{}.Type(ctx), - }, - "warehouse_type": types.StringType, + "health": basetypes.ListType{ElemType: EndpointHealth{}.Type(ctx)}, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "jdbc_url": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "num_active_sessions": types.Int64Type, + "num_clusters": types.Int64Type, + "odbc_params": basetypes.ListType{ElemType: OdbcParams{}.Type(ctx)}, + "spot_instance_policy": types.StringType, + "state": types.StringType, + "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, + "warehouse_type": types.StringType, }, } } @@ -4026,9 +3962,7 @@ func (o EndpointTags) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "custom_tags": basetypes.ListType{ - ElemType: EndpointTagPair{}.Type(ctx), - }, + "custom_tags": basetypes.ListType{ElemType: EndpointTagPair{}.Type(ctx)}, }, } } @@ -4105,13 +4039,9 @@ func (o EnumValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EnumValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "enum_options": types.StringType, - "multi_values_options": basetypes.ListType{ - ElemType: MultiValuesOptions{}.Type(ctx), - }, - "values": basetypes.ListType{ - ElemType: types.StringType, - }, + "enum_options": types.StringType, + "multi_values_options": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, + "values": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -4343,14 +4273,12 @@ func (o ExecuteStatementRequest) Type(ctx context.Context) attr.Type { "disposition": types.StringType, "format": types.StringType, "on_wait_timeout": types.StringType, - "parameters": basetypes.ListType{ - ElemType: StatementParameterListItem{}.Type(ctx), - }, - "row_limit": types.Int64Type, - "schema": types.StringType, - "statement": types.StringType, - "wait_timeout": types.StringType, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ElemType: StatementParameterListItem{}.Type(ctx)}, + "row_limit": types.Int64Type, + "schema": types.StringType, + "statement": types.StringType, + "wait_timeout": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -4456,13 +4384,11 @@ func (o ExternalLink) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ExternalLink) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "byte_count": types.Int64Type, - "chunk_index": types.Int64Type, - "expiration": types.StringType, - "external_link": types.StringType, - "http_headers": basetypes.MapType{ - ElemType: types.StringType, - }, + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "expiration": types.StringType, + "external_link": types.StringType, + "http_headers": basetypes.MapType{ElemType: types.StringType}, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, "row_count": types.Int64Type, @@ -4798,11 +4724,9 @@ func (o GetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -5006,9 +4930,7 @@ func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetWarehousePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: WarehousePermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: WarehousePermissionsDescription{}.Type(ctx)}, }, } } @@ -5258,34 +5180,26 @@ func (o GetWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o GetWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ - ElemType: Channel{}.Type(ctx), - }, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, - "health": basetypes.ListType{ - ElemType: EndpointHealth{}.Type(ctx), - }, - "id": types.StringType, - "instance_profile_arn": types.StringType, - "jdbc_url": types.StringType, - "max_num_clusters": types.Int64Type, - "min_num_clusters": types.Int64Type, - "name": types.StringType, - "num_active_sessions": types.Int64Type, - "num_clusters": types.Int64Type, - "odbc_params": basetypes.ListType{ - ElemType: OdbcParams{}.Type(ctx), - }, - "spot_instance_policy": types.StringType, - "state": types.StringType, - "tags": basetypes.ListType{ - ElemType: EndpointTags{}.Type(ctx), - }, - "warehouse_type": types.StringType, + "health": basetypes.ListType{ElemType: EndpointHealth{}.Type(ctx)}, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "jdbc_url": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "num_active_sessions": types.Int64Type, + "num_clusters": types.Int64Type, + "odbc_params": basetypes.ListType{ElemType: OdbcParams{}.Type(ctx)}, + "spot_instance_policy": types.StringType, + "state": types.StringType, + "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, + "warehouse_type": types.StringType, }, } } @@ -5469,27 +5383,15 @@ func (o GetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel": basetypes.ListType{ - ElemType: Channel{}.Type(ctx), - }, - "config_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.Type(ctx), - }, - "data_access_config": basetypes.ListType{ - ElemType: EndpointConfPair{}.Type(ctx), - }, - "enabled_warehouse_types": basetypes.ListType{ - ElemType: WarehouseTypePair{}.Type(ctx), - }, - "global_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.Type(ctx), - }, - "google_service_account": types.StringType, - "instance_profile_arn": types.StringType, - "security_policy": types.StringType, - "sql_configuration_parameters": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.Type(ctx), - }, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, + "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "google_service_account": types.StringType, + "instance_profile_arn": types.StringType, + "security_policy": types.StringType, + "sql_configuration_parameters": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, }, } } @@ -5729,19 +5631,13 @@ func (o LegacyAlert) Type(ctx context.Context) attr.Type { "id": types.StringType, "last_triggered_at": types.StringType, "name": types.StringType, - "options": basetypes.ListType{ - ElemType: AlertOptions{}.Type(ctx), - }, - "parent": types.StringType, - "query": basetypes.ListType{ - ElemType: AlertQuery{}.Type(ctx), - }, - "rearm": types.Int64Type, - "state": types.StringType, - "updated_at": types.StringType, - "user": basetypes.ListType{ - ElemType: User{}.Type(ctx), - }, + "options": basetypes.ListType{ElemType: AlertOptions{}.Type(ctx)}, + "parent": types.StringType, + "query": basetypes.ListType{ElemType: AlertQuery{}.Type(ctx)}, + "rearm": types.Int64Type, + "state": types.StringType, + "updated_at": types.StringType, + "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, }, } } @@ -5956,40 +5852,30 @@ func (o LegacyQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LegacyQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "can_edit": types.BoolType, - "created_at": types.StringType, - "data_source_id": types.StringType, - "description": types.StringType, - "id": types.StringType, - "is_archived": types.BoolType, - "is_draft": types.BoolType, - "is_favorite": types.BoolType, - "is_safe": types.BoolType, - "last_modified_by": basetypes.ListType{ - ElemType: User{}.Type(ctx), - }, + "can_edit": types.BoolType, + "created_at": types.StringType, + "data_source_id": types.StringType, + "description": types.StringType, + "id": types.StringType, + "is_archived": types.BoolType, + "is_draft": types.BoolType, + "is_favorite": types.BoolType, + "is_safe": types.BoolType, + "last_modified_by": basetypes.ListType{ElemType: User{}.Type(ctx)}, "last_modified_by_id": types.Int64Type, "latest_query_data_id": types.StringType, "name": types.StringType, - "options": basetypes.ListType{ - ElemType: QueryOptions{}.Type(ctx), - }, - "parent": types.StringType, - "permission_tier": types.StringType, - "query": types.StringType, - "query_hash": types.StringType, - "run_as_role": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "updated_at": types.StringType, - "user": basetypes.ListType{ - ElemType: User{}.Type(ctx), - }, - "user_id": types.Int64Type, - "visualizations": basetypes.ListType{ - ElemType: LegacyVisualization{}.Type(ctx), - }, + "options": basetypes.ListType{ElemType: QueryOptions{}.Type(ctx)}, + "parent": types.StringType, + "permission_tier": types.StringType, + "query": types.StringType, + "query_hash": types.StringType, + "run_as_role": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "updated_at": types.StringType, + "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "user_id": types.Int64Type, + "visualizations": basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}, }, } } @@ -6197,11 +6083,9 @@ func (o LegacyVisualization) Type(ctx context.Context) attr.Type { "id": types.StringType, "name": types.StringType, "options": types.ObjectType{}, - "query": basetypes.ListType{ - ElemType: LegacyQuery{}.Type(ctx), - }, - "type": types.StringType, - "updated_at": types.StringType, + "query": basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}, + "type": types.StringType, + "updated_at": types.StringType, }, } } @@ -6320,9 +6204,7 @@ func (o ListAlertsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ - ElemType: ListAlertsResponseAlert{}.Type(ctx), - }, + "results": basetypes.ListType{ElemType: ListAlertsResponseAlert{}.Type(ctx)}, }, } } @@ -6444,9 +6326,7 @@ func (o ListAlertsResponseAlert) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListAlertsResponseAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ - ElemType: AlertCondition{}.Type(ctx), - }, + "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, "create_time": types.StringType, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -6706,9 +6586,7 @@ func (o ListQueriesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "has_next_page": types.BoolType, "next_page_token": types.StringType, - "res": basetypes.ListType{ - ElemType: QueryInfo{}.Type(ctx), - }, + "res": basetypes.ListType{ElemType: QueryInfo{}.Type(ctx)}, }, } } @@ -6793,9 +6671,7 @@ func (o ListQueryHistoryRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListQueryHistoryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter_by": basetypes.ListType{ - ElemType: QueryFilter{}.Type(ctx), - }, + "filter_by": basetypes.ListType{ElemType: QueryFilter{}.Type(ctx)}, "include_metrics": types.BoolType, "max_results": types.Int64Type, "page_token": types.StringType, @@ -6871,9 +6747,7 @@ func (o ListQueryObjectsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ - ElemType: ListQueryObjectsResponseQuery{}.Type(ctx), - }, + "results": basetypes.ListType{ElemType: ListQueryObjectsResponseQuery{}.Type(ctx)}, }, } } @@ -7000,17 +6874,13 @@ func (o ListQueryObjectsResponseQuery) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.Type(ctx), - }, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "update_time": types.StringType, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -7118,9 +6988,7 @@ func (o ListResponse) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ - ElemType: Dashboard{}.Type(ctx), - }, + "results": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, }, } } @@ -7243,9 +7111,7 @@ func (o ListVisualizationsForQueryResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ - ElemType: Visualization{}.Type(ctx), - }, + "results": basetypes.ListType{ElemType: Visualization{}.Type(ctx)}, }, } } @@ -7359,9 +7225,7 @@ func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListWarehousesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "warehouses": basetypes.ListType{ - ElemType: EndpointInfo{}.Type(ctx), - }, + "warehouses": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, }, } } @@ -7598,15 +7462,13 @@ func (o Parameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Parameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "enumOptions": types.StringType, - "multiValuesOptions": basetypes.ListType{ - ElemType: MultiValuesOptions{}.Type(ctx), - }, - "name": types.StringType, - "queryId": types.StringType, - "title": types.StringType, - "type": types.StringType, - "value": types.ObjectType{}, + "enumOptions": types.StringType, + "multiValuesOptions": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, + "name": types.StringType, + "queryId": types.StringType, + "title": types.StringType, + "type": types.StringType, + "value": types.ObjectType{}, }, } } @@ -7736,18 +7598,14 @@ func (o Query) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.Type(ctx), - }, - "parent_path": types.StringType, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "update_time": types.StringType, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "parent_path": types.StringType, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -7850,13 +7708,9 @@ func (o QueryBackedValue) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o QueryBackedValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "multi_values_options": basetypes.ListType{ - ElemType: MultiValuesOptions{}.Type(ctx), - }, - "query_id": types.StringType, - "values": basetypes.ListType{ - ElemType: types.StringType, - }, + "multi_values_options": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, + "query_id": types.StringType, + "values": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -7989,9 +7843,7 @@ func (o QueryEditContent) Type(ctx context.Context) attr.Type { "query": types.StringType, "query_id": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, + "tags": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -8078,21 +7930,11 @@ func (o QueryFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QueryFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query_start_time_range": basetypes.ListType{ - ElemType: TimeRange{}.Type(ctx), - }, - "statement_ids": basetypes.ListType{ - ElemType: types.StringType, - }, - "statuses": basetypes.ListType{ - ElemType: types.StringType, - }, - "user_ids": basetypes.ListType{ - ElemType: types.Int64Type, - }, - "warehouse_ids": basetypes.ListType{ - ElemType: types.StringType, - }, + "query_start_time_range": basetypes.ListType{ElemType: TimeRange{}.Type(ctx)}, + "statement_ids": basetypes.ListType{ElemType: types.StringType}, + "statuses": basetypes.ListType{ElemType: types.StringType}, + "user_ids": basetypes.ListType{ElemType: types.Int64Type}, + "warehouse_ids": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -8335,9 +8177,7 @@ func (o QueryInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QueryInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel_used": basetypes.ListType{ - ElemType: ChannelInfo{}.Type(ctx), - }, + "channel_used": basetypes.ListType{ElemType: ChannelInfo{}.Type(ctx)}, "duration": types.Int64Type, "endpoint_id": types.StringType, "error_message": types.StringType, @@ -8346,21 +8186,19 @@ func (o QueryInfo) Type(ctx context.Context) attr.Type { "execution_end_time_ms": types.Int64Type, "is_final": types.BoolType, "lookup_key": types.StringType, - "metrics": basetypes.ListType{ - ElemType: QueryMetrics{}.Type(ctx), - }, - "plans_state": types.StringType, - "query_end_time_ms": types.Int64Type, - "query_id": types.StringType, - "query_start_time_ms": types.Int64Type, - "query_text": types.StringType, - "rows_produced": types.Int64Type, - "spark_ui_url": types.StringType, - "statement_type": types.StringType, - "status": types.StringType, - "user_id": types.Int64Type, - "user_name": types.StringType, - "warehouse_id": types.StringType, + "metrics": basetypes.ListType{ElemType: QueryMetrics{}.Type(ctx)}, + "plans_state": types.StringType, + "query_end_time_ms": types.Int64Type, + "query_id": types.StringType, + "query_start_time_ms": types.Int64Type, + "query_text": types.StringType, + "rows_produced": types.Int64Type, + "spark_ui_url": types.StringType, + "statement_type": types.StringType, + "status": types.StringType, + "user_id": types.Int64Type, + "user_name": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -8468,9 +8306,7 @@ func (o QueryList) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ - ElemType: LegacyQuery{}.Type(ctx), - }, + "results": basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}, }, } } @@ -8693,10 +8529,8 @@ func (o QueryOptions) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "catalog": types.StringType, "moved_to_trash_at": types.StringType, - "parameters": basetypes.ListType{ - ElemType: Parameter{}.Type(ctx), - }, - "schema": types.StringType, + "parameters": basetypes.ListType{ElemType: Parameter{}.Type(ctx)}, + "schema": types.StringType, }, } } @@ -8795,26 +8629,14 @@ func (o QueryParameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o QueryParameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "date_range_value": basetypes.ListType{ - ElemType: DateRangeValue{}.Type(ctx), - }, - "date_value": basetypes.ListType{ - ElemType: DateValue{}.Type(ctx), - }, - "enum_value": basetypes.ListType{ - ElemType: EnumValue{}.Type(ctx), - }, - "name": types.StringType, - "numeric_value": basetypes.ListType{ - ElemType: NumericValue{}.Type(ctx), - }, - "query_backed_value": basetypes.ListType{ - ElemType: QueryBackedValue{}.Type(ctx), - }, - "text_value": basetypes.ListType{ - ElemType: TextValue{}.Type(ctx), - }, - "title": types.StringType, + "date_range_value": basetypes.ListType{ElemType: DateRangeValue{}.Type(ctx)}, + "date_value": basetypes.ListType{ElemType: DateValue{}.Type(ctx)}, + "enum_value": basetypes.ListType{ElemType: EnumValue{}.Type(ctx)}, + "name": types.StringType, + "numeric_value": basetypes.ListType{ElemType: NumericValue{}.Type(ctx)}, + "query_backed_value": basetypes.ListType{ElemType: QueryBackedValue{}.Type(ctx)}, + "text_value": basetypes.ListType{ElemType: TextValue{}.Type(ctx)}, + "title": types.StringType, }, } } @@ -9051,9 +8873,7 @@ func (o QueryPostContent) Type(ctx context.Context) attr.Type { "parent": types.StringType, "query": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, + "tags": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -9127,12 +8947,8 @@ func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) basetypes. func (o RepeatedEndpointConfPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config_pair": basetypes.ListType{ - ElemType: EndpointConfPair{}.Type(ctx), - }, - "configuration_pairs": basetypes.ListType{ - ElemType: EndpointConfPair{}.Type(ctx), - }, + "config_pair": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "configuration_pairs": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, }, } } @@ -9378,16 +9194,10 @@ func (o ResultData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ResultData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "byte_count": types.Int64Type, - "chunk_index": types.Int64Type, - "data_array": basetypes.ListType{ - ElemType: basetypes.ListType{ - ElemType: types.StringType, - }, - }, - "external_links": basetypes.ListType{ - ElemType: ExternalLink{}.Type(ctx), - }, + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "data_array": basetypes.ListType{ElemType: basetypes.ListType{ElemType: types.StringType}}, + "external_links": basetypes.ListType{ElemType: ExternalLink{}.Type(ctx)}, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, "row_count": types.Int64Type, @@ -9509,13 +9319,9 @@ func (o ResultManifest) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "chunks": basetypes.ListType{ - ElemType: BaseChunkInfo{}.Type(ctx), - }, - "format": types.StringType, - "schema": basetypes.ListType{ - ElemType: ResultSchema{}.Type(ctx), - }, + "chunks": basetypes.ListType{ElemType: BaseChunkInfo{}.Type(ctx)}, + "format": types.StringType, + "schema": basetypes.ListType{ElemType: ResultSchema{}.Type(ctx)}, "total_byte_count": types.Int64Type, "total_chunk_count": types.Int64Type, "total_row_count": types.Int64Type, @@ -9619,9 +9425,7 @@ func (o ResultSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.Type(ctx), - }, + "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, }, } } @@ -9743,11 +9547,9 @@ func (o SetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.Type(ctx), - }, - "objectId": types.StringType, - "objectType": types.StringType, + "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, + "objectId": types.StringType, + "objectType": types.StringType, }, } } @@ -9822,11 +9624,9 @@ func (o SetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: AccessControl{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -9932,27 +9732,15 @@ func (o SetWorkspaceWarehouseConfigRequest) ToObjectValue(ctx context.Context) b func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel": basetypes.ListType{ - ElemType: Channel{}.Type(ctx), - }, - "config_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.Type(ctx), - }, - "data_access_config": basetypes.ListType{ - ElemType: EndpointConfPair{}.Type(ctx), - }, - "enabled_warehouse_types": basetypes.ListType{ - ElemType: WarehouseTypePair{}.Type(ctx), - }, - "global_param": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.Type(ctx), - }, - "google_service_account": types.StringType, - "instance_profile_arn": types.StringType, - "security_policy": types.StringType, - "sql_configuration_parameters": basetypes.ListType{ - ElemType: RepeatedEndpointConfPairs{}.Type(ctx), - }, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, + "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "google_service_account": types.StringType, + "instance_profile_arn": types.StringType, + "security_policy": types.StringType, + "sql_configuration_parameters": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, }, } } @@ -10337,16 +10125,10 @@ func (o StatementResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o StatementResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "manifest": basetypes.ListType{ - ElemType: ResultManifest{}.Type(ctx), - }, - "result": basetypes.ListType{ - ElemType: ResultData{}.Type(ctx), - }, + "manifest": basetypes.ListType{ElemType: ResultManifest{}.Type(ctx)}, + "result": basetypes.ListType{ElemType: ResultData{}.Type(ctx)}, "statement_id": types.StringType, - "status": basetypes.ListType{ - ElemType: StatementStatus{}.Type(ctx), - }, + "status": basetypes.ListType{ElemType: StatementStatus{}.Type(ctx)}, }, } } @@ -10478,9 +10260,7 @@ func (o StatementStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o StatementStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error": basetypes.ListType{ - ElemType: ServiceError{}.Type(ctx), - }, + "error": basetypes.ListType{ElemType: ServiceError{}.Type(ctx)}, "state": types.StringType, }, } @@ -10678,11 +10458,9 @@ func (o TerminationReason) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o TerminationReason) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "code": types.StringType, - "parameters": basetypes.MapType{ - ElemType: types.StringType, - }, - "type": types.StringType, + "code": types.StringType, + "parameters": basetypes.MapType{ElemType: types.StringType}, + "type": types.StringType, }, } } @@ -10888,10 +10666,8 @@ func (o TransferOwnershipRequest) ToObjectValue(ctx context.Context) basetypes.O func (o TransferOwnershipRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "new_owner": types.StringType, - "objectId": basetypes.ListType{ - ElemType: TransferOwnershipObjectId{}.Type(ctx), - }, + "new_owner": types.StringType, + "objectId": basetypes.ListType{ElemType: TransferOwnershipObjectId{}.Type(ctx)}, "objectType": types.StringType, }, } @@ -11054,9 +10830,7 @@ func (o UpdateAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o UpdateAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ - ElemType: UpdateAlertRequestAlert{}.Type(ctx), - }, + "alert": basetypes.ListType{ElemType: UpdateAlertRequestAlert{}.Type(ctx)}, "id": types.StringType, "update_mask": types.StringType, }, @@ -11159,9 +10933,7 @@ func (o UpdateAlertRequestAlert) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateAlertRequestAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ - ElemType: AlertCondition{}.Type(ctx), - }, + "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, "custom_body": types.StringType, "custom_subject": types.StringType, "display_name": types.StringType, @@ -11246,10 +11018,8 @@ func (o UpdateQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o UpdateQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "query": basetypes.ListType{ - ElemType: UpdateQueryRequestQuery{}.Type(ctx), - }, + "id": types.StringType, + "query": basetypes.ListType{ElemType: UpdateQueryRequestQuery{}.Type(ctx)}, "update_mask": types.StringType, }, } @@ -11358,16 +11128,12 @@ func (o UpdateQueryRequestQuery) Type(ctx context.Context) attr.Type { "description": types.StringType, "display_name": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ - ElemType: QueryParameter{}.Type(ctx), - }, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ - ElemType: types.StringType, - }, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ElemType: types.StringType}, + "warehouse_id": types.StringType, }, } } @@ -11507,11 +11273,9 @@ func (o UpdateVisualizationRequest) ToObjectValue(ctx context.Context) basetypes func (o UpdateVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "update_mask": types.StringType, - "visualization": basetypes.ListType{ - ElemType: UpdateVisualizationRequestVisualization{}.Type(ctx), - }, + "id": types.StringType, + "update_mask": types.StringType, + "visualization": basetypes.ListType{ElemType: UpdateVisualizationRequestVisualization{}.Type(ctx)}, }, } } @@ -11828,9 +11592,7 @@ func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) baset func (o WarehouseAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: WarehousePermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: WarehousePermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -11909,11 +11671,9 @@ func (o WarehousePermission) ToObjectValue(ctx context.Context) basetypes.Object func (o WarehousePermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -11988,11 +11748,9 @@ func (o WarehousePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WarehousePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: WarehouseAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -12109,10 +11867,8 @@ func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) basetype func (o WarehousePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: WarehouseAccessControlRequest{}.Type(ctx), - }, - "warehouse_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlRequest{}.Type(ctx)}, + "warehouse_id": types.StringType, }, } } @@ -12243,14 +11999,10 @@ func (o Widget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Widget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "options": basetypes.ListType{ - ElemType: WidgetOptions{}.Type(ctx), - }, - "visualization": basetypes.ListType{ - ElemType: LegacyVisualization{}.Type(ctx), - }, - "width": types.Int64Type, + "id": types.StringType, + "options": basetypes.ListType{ElemType: WidgetOptions{}.Type(ctx)}, + "visualization": basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}, + "width": types.Int64Type, }, } } @@ -12371,11 +12123,9 @@ func (o WidgetOptions) Type(ctx context.Context) attr.Type { "description": types.StringType, "isHidden": types.BoolType, "parameterMappings": types.ObjectType{}, - "position": basetypes.ListType{ - ElemType: WidgetPosition{}.Type(ctx), - }, - "title": types.StringType, - "updated_at": types.StringType, + "position": basetypes.ListType{ElemType: WidgetPosition{}.Type(ctx)}, + "title": types.StringType, + "updated_at": types.StringType, }, } } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index e54058ff9a..390cf5883b 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -172,16 +172,12 @@ func (o CreateVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.O func (o CreateVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "delta_sync_index_spec": basetypes.ListType{ - ElemType: DeltaSyncVectorIndexSpecRequest{}.Type(ctx), - }, - "direct_access_index_spec": basetypes.ListType{ - ElemType: DirectAccessVectorIndexSpec{}.Type(ctx), - }, - "endpoint_name": types.StringType, - "index_type": types.StringType, - "name": types.StringType, - "primary_key": types.StringType, + "delta_sync_index_spec": basetypes.ListType{ElemType: DeltaSyncVectorIndexSpecRequest{}.Type(ctx)}, + "direct_access_index_spec": basetypes.ListType{ElemType: DirectAccessVectorIndexSpec{}.Type(ctx)}, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, }, } } @@ -276,9 +272,7 @@ func (o CreateVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes. func (o CreateVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "vector_index": basetypes.ListType{ - ElemType: VectorIndex{}.Type(ctx), - }, + "vector_index": basetypes.ListType{ElemType: VectorIndex{}.Type(ctx)}, }, } } @@ -352,10 +346,8 @@ func (o DeleteDataResult) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o DeleteDataResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "failed_primary_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "success_row_count": types.Int64Type, + "failed_primary_keys": basetypes.ListType{ElemType: types.StringType}, + "success_row_count": types.Int64Type, }, } } @@ -430,10 +422,8 @@ func (o DeleteDataVectorIndexRequest) ToObjectValue(ctx context.Context) basetyp func (o DeleteDataVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "index_name": types.StringType, - "primary_keys": basetypes.ListType{ - ElemType: types.StringType, - }, + "index_name": types.StringType, + "primary_keys": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -507,9 +497,7 @@ func (o DeleteDataVectorIndexResponse) ToObjectValue(ctx context.Context) basety func (o DeleteDataVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "result": basetypes.ListType{ - ElemType: DeleteDataResult{}.Type(ctx), - }, + "result": basetypes.ListType{ElemType: DeleteDataResult{}.Type(ctx)}, "status": types.StringType, }, } @@ -768,15 +756,9 @@ func (o DeltaSyncVectorIndexSpecRequest) ToObjectValue(ctx context.Context) base func (o DeltaSyncVectorIndexSpecRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns_to_sync": basetypes.ListType{ - ElemType: types.StringType, - }, - "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.Type(ctx), - }, - "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.Type(ctx), - }, + "columns_to_sync": basetypes.ListType{ElemType: types.StringType}, + "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, + "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, "embedding_writeback_table": types.StringType, "pipeline_type": types.StringType, "source_table": types.StringType, @@ -925,12 +907,8 @@ func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) bas func (o DeltaSyncVectorIndexSpecResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.Type(ctx), - }, - "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.Type(ctx), - }, + "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, + "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, "embedding_writeback_table": types.StringType, "pipeline_id": types.StringType, "pipeline_type": types.StringType, @@ -1042,13 +1020,9 @@ func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) basetype func (o DirectAccessVectorIndexSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ - ElemType: EmbeddingSourceColumn{}.Type(ctx), - }, - "embedding_vector_columns": basetypes.ListType{ - ElemType: EmbeddingVectorColumn{}.Type(ctx), - }, - "schema_json": types.StringType, + "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, + "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, + "schema_json": types.StringType, }, } } @@ -1260,11 +1234,9 @@ func (o EndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "endpoint_status": basetypes.ListType{ - ElemType: EndpointStatus{}.Type(ctx), - }, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "endpoint_status": basetypes.ListType{ElemType: EndpointStatus{}.Type(ctx)}, "endpoint_type": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, @@ -1477,9 +1449,7 @@ func (o ListEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ - ElemType: EndpointInfo{}.Type(ctx), - }, + "endpoints": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1639,9 +1609,7 @@ func (o ListValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ - ElemType: Value{}.Type(ctx), - }, + "values": basetypes.ListType{ElemType: Value{}.Type(ctx)}, }, } } @@ -1716,9 +1684,7 @@ func (o ListVectorIndexesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "vector_indexes": basetypes.ListType{ - ElemType: MiniVectorIndex{}.Type(ctx), - }, + "vector_indexes": basetypes.ListType{ElemType: MiniVectorIndex{}.Type(ctx)}, }, } } @@ -1792,10 +1758,8 @@ func (o MapStringValueEntry) ToObjectValue(ctx context.Context) basetypes.Object func (o MapStringValueEntry) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "key": types.StringType, - "value": basetypes.ListType{ - ElemType: Value{}.Type(ctx), - }, + "key": types.StringType, + "value": basetypes.ListType{ElemType: Value{}.Type(ctx)}, }, } } @@ -2009,17 +1973,13 @@ func (o QueryVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o QueryVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ - ElemType: types.StringType, - }, - "filters_json": types.StringType, - "index_name": types.StringType, - "num_results": types.Int64Type, - "query_text": types.StringType, - "query_type": types.StringType, - "query_vector": basetypes.ListType{ - ElemType: types.Float64Type, - }, + "columns": basetypes.ListType{ElemType: types.StringType}, + "filters_json": types.StringType, + "index_name": types.StringType, + "num_results": types.Int64Type, + "query_text": types.StringType, + "query_type": types.StringType, + "query_vector": basetypes.ListType{ElemType: types.Float64Type}, "score_threshold": types.Float64Type, }, } @@ -2125,13 +2085,9 @@ func (o QueryVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.O func (o QueryVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "manifest": basetypes.ListType{ - ElemType: ResultManifest{}.Type(ctx), - }, + "manifest": basetypes.ListType{ElemType: ResultManifest{}.Type(ctx)}, "next_page_token": types.StringType, - "result": basetypes.ListType{ - ElemType: ResultData{}.Type(ctx), - }, + "result": basetypes.ListType{ElemType: ResultData{}.Type(ctx)}, }, } } @@ -2231,12 +2187,8 @@ func (o ResultData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ResultData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data_array": basetypes.ListType{ - ElemType: basetypes.ListType{ - ElemType: types.StringType, - }, - }, - "row_count": types.Int64Type, + "data_array": basetypes.ListType{ElemType: basetypes.ListType{ElemType: types.StringType}}, + "row_count": types.Int64Type, }, } } @@ -2311,9 +2263,7 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ - ElemType: ColumnInfo{}.Type(ctx), - }, + "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, }, } } @@ -2438,9 +2388,7 @@ func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ScanVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data": basetypes.ListType{ - ElemType: Struct{}.Type(ctx), - }, + "data": basetypes.ListType{ElemType: Struct{}.Type(ctx)}, "last_primary_key": types.StringType, }, } @@ -2511,9 +2459,7 @@ func (o Struct) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Struct) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fields": basetypes.ListType{ - ElemType: MapStringValueEntry{}.Type(ctx), - }, + "fields": basetypes.ListType{ElemType: MapStringValueEntry{}.Type(ctx)}, }, } } @@ -2666,10 +2612,8 @@ func (o UpsertDataResult) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o UpsertDataResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "failed_primary_keys": basetypes.ListType{ - ElemType: types.StringType, - }, - "success_row_count": types.Int64Type, + "failed_primary_keys": basetypes.ListType{ElemType: types.StringType}, + "success_row_count": types.Int64Type, }, } } @@ -2791,9 +2735,7 @@ func (o UpsertDataVectorIndexResponse) ToObjectValue(ctx context.Context) basety func (o UpsertDataVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "result": basetypes.ListType{ - ElemType: UpsertDataResult{}.Type(ctx), - }, + "result": basetypes.ListType{ElemType: UpsertDataResult{}.Type(ctx)}, "status": types.StringType, }, } @@ -2879,16 +2821,12 @@ func (o Value) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Value) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "bool_value": types.BoolType, - "list_value": basetypes.ListType{ - ElemType: ListValue{}.Type(ctx), - }, + "bool_value": types.BoolType, + "list_value": basetypes.ListType{ElemType: ListValue{}.Type(ctx)}, "null_value": types.StringType, "number_value": types.Float64Type, "string_value": types.StringType, - "struct_value": basetypes.ListType{ - ElemType: Struct{}.Type(ctx), - }, + "struct_value": basetypes.ListType{ElemType: Struct{}.Type(ctx)}, }, } } @@ -3013,20 +2951,14 @@ func (o VectorIndex) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o VectorIndex) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creator": types.StringType, - "delta_sync_index_spec": basetypes.ListType{ - ElemType: DeltaSyncVectorIndexSpecResponse{}.Type(ctx), - }, - "direct_access_index_spec": basetypes.ListType{ - ElemType: DirectAccessVectorIndexSpec{}.Type(ctx), - }, - "endpoint_name": types.StringType, - "index_type": types.StringType, - "name": types.StringType, - "primary_key": types.StringType, - "status": basetypes.ListType{ - ElemType: VectorIndexStatus{}.Type(ctx), - }, + "creator": types.StringType, + "delta_sync_index_spec": basetypes.ListType{ElemType: DeltaSyncVectorIndexSpecResponse{}.Type(ctx)}, + "direct_access_index_spec": basetypes.ListType{ElemType: DirectAccessVectorIndexSpec{}.Type(ctx)}, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, + "status": basetypes.ListType{ElemType: VectorIndexStatus{}.Type(ctx)}, }, } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index ea6811069c..e3b4c1b747 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -282,12 +282,10 @@ func (o CreateRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o CreateRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.Type(ctx), - }, - "url": types.StringType, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, + "url": types.StringType, }, } } @@ -376,15 +374,13 @@ func (o CreateRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "head_commit_id": types.StringType, - "id": types.Int64Type, - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.Type(ctx), - }, - "url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, + "url": types.StringType, }, } } @@ -465,9 +461,7 @@ func (o CreateScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateScope) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "backend_azure_keyvault": basetypes.ListType{ - ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx), - }, + "backend_azure_keyvault": basetypes.ListType{ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx)}, "initial_manage_principal": types.StringType, "scope": types.StringType, "scope_backend_type": types.StringType, @@ -1404,9 +1398,7 @@ func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) base func (o GetRepoPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: RepoPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: RepoPermissionsDescription{}.Type(ctx)}, }, } } @@ -1580,15 +1572,13 @@ func (o GetRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "head_commit_id": types.StringType, - "id": types.Int64Type, - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.Type(ctx), - }, - "url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, + "url": types.StringType, }, } } @@ -1841,9 +1831,7 @@ func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetWorkspaceObjectPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ - ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx), - }, + "permission_levels": basetypes.ListType{ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx)}, }, } } @@ -2117,9 +2105,7 @@ func (o ListAclsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAclsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ - ElemType: AclItem{}.Type(ctx), - }, + "items": basetypes.ListType{ElemType: AclItem{}.Type(ctx)}, }, } } @@ -2189,9 +2175,7 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ - ElemType: CredentialInfo{}.Type(ctx), - }, + "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, }, } } @@ -2317,9 +2301,7 @@ func (o ListReposResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "repos": basetypes.ListType{ - ElemType: RepoInfo{}.Type(ctx), - }, + "repos": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, }, } } @@ -2389,9 +2371,7 @@ func (o ListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "objects": basetypes.ListType{ - ElemType: ObjectInfo{}.Type(ctx), - }, + "objects": basetypes.ListType{ElemType: ObjectInfo{}.Type(ctx)}, }, } } @@ -2461,9 +2441,7 @@ func (o ListScopesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListScopesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scopes": basetypes.ListType{ - ElemType: SecretScope{}.Type(ctx), - }, + "scopes": basetypes.ListType{ElemType: SecretScope{}.Type(ctx)}, }, } } @@ -2576,9 +2554,7 @@ func (o ListSecretsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o ListSecretsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "secrets": basetypes.ListType{ - ElemType: SecretMetadata{}.Type(ctx), - }, + "secrets": basetypes.ListType{ElemType: SecretMetadata{}.Type(ctx)}, }, } } @@ -3093,9 +3069,7 @@ func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) basetypes. func (o RepoAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: RepoPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: RepoPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3188,15 +3162,13 @@ func (o RepoInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RepoInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "head_commit_id": types.StringType, - "id": types.Int64Type, - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckout{}.Type(ctx), - }, - "url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, + "url": types.StringType, }, } } @@ -3271,11 +3243,9 @@ func (o RepoPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o RepoPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -3350,11 +3320,9 @@ func (o RepoPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RepoPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: RepoAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: RepoAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3471,10 +3439,8 @@ func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o RepoPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: RepoAccessControlRequest{}.Type(ctx), - }, - "repo_id": types.StringType, + "access_control_list": basetypes.ListType{ElemType: RepoAccessControlRequest{}.Type(ctx)}, + "repo_id": types.StringType, }, } } @@ -3596,11 +3562,9 @@ func (o SecretScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SecretScope) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "backend_type": types.StringType, - "keyvault_metadata": basetypes.ListType{ - ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx), - }, - "name": types.StringType, + "backend_type": types.StringType, + "keyvault_metadata": basetypes.ListType{ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx)}, + "name": types.StringType, }, } } @@ -3674,9 +3638,7 @@ func (o SparseCheckout) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o SparseCheckout) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "patterns": basetypes.ListType{ - ElemType: types.StringType, - }, + "patterns": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3750,9 +3712,7 @@ func (o SparseCheckoutUpdate) ToObjectValue(ctx context.Context) basetypes.Objec func (o SparseCheckoutUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "patterns": basetypes.ListType{ - ElemType: types.StringType, - }, + "patterns": basetypes.ListType{ElemType: types.StringType}, }, } } @@ -3938,12 +3898,10 @@ func (o UpdateRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdateRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "repo_id": types.Int64Type, - "sparse_checkout": basetypes.ListType{ - ElemType: SparseCheckoutUpdate{}.Type(ctx), - }, - "tag": types.StringType, + "branch": types.StringType, + "repo_id": types.Int64Type, + "sparse_checkout": basetypes.ListType{ElemType: SparseCheckoutUpdate{}.Type(ctx)}, + "tag": types.StringType, }, } } @@ -4115,9 +4073,7 @@ func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) func (o WorkspaceObjectAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ - ElemType: WorkspaceObjectPermission{}.Type(ctx), - }, + "all_permissions": basetypes.ListType{ElemType: WorkspaceObjectPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -4196,11 +4152,9 @@ func (o WorkspaceObjectPermission) ToObjectValue(ctx context.Context) basetypes. func (o WorkspaceObjectPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ - ElemType: types.StringType, - }, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, + "permission_level": types.StringType, }, } } @@ -4275,11 +4229,9 @@ func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) basetypes func (o WorkspaceObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx), - }, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx)}, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4399,9 +4351,7 @@ func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o WorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ - ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx), - }, + "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx)}, "workspace_object_id": types.StringType, "workspace_object_type": types.StringType, }, From ec950fb679fa1385fd060d86550019ea7b14c269 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 19:08:20 +0100 Subject: [PATCH 69/91] fix --- internal/providers/pluginfw/products/app/resource_app.go | 7 ------- 1 file changed, 7 deletions(-) diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 1042c184fc..3b436ada4b 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -36,13 +36,6 @@ func (a resourceApp) Metadata(ctx context.Context, req resource.MetadataRequest, func (a resourceApp) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { resp.Schema = tfschema.ResourceStructToSchema(ctx, apps_tf.App{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { cs.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") - // All pointers are treated as list blocks to be compatible with resources implemented in SDKv2. - // The plugin framework requires that the number of blocks in the config and plan match. This means that - // it isn't possible to have a computed list block that is not part of the config. To work around this, - // we need to treat these blocks as attributes in the schema, which allows us to set them as computed. - for _, p := range []string{"active_deployment", "app_status", "compute_status", "pending_deployment"} { - cs.ConvertToAttribute(p) - } // Computed fields for _, p := range []string{ "active_deployment", From eaf71eb54f407b93567bb54abb09868ecc1b1ee0 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 19:29:46 +0100 Subject: [PATCH 70/91] work --- .../pluginfw/products/app/app_acc_test.go | 106 +++++++++--------- 1 file changed, 53 insertions(+), 53 deletions(-) diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index 10da74154a..d47fadfaec 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -19,35 +19,35 @@ const baseResources = ` string_value = "secret" } - resource "databricks_sql_endpoint" "this" { - name = "tf-{var.STICKY_RANDOM}" - cluster_size = "2X-Small" - max_num_clusters = 1 +# resource "databricks_sql_endpoint" "this" { +# name = "tf-{var.STICKY_RANDOM}" +# cluster_size = "2X-Small" +# max_num_clusters = 1 - tags { - custom_tags { - key = "Owner" - value = "eng-dev-ecosystem-team_at_databricks.com" - } - } - } +# tags { +# custom_tags { +# key = "Owner" +# value = "eng-dev-ecosystem-team_at_databricks.com" +# } +# } +# } - resource "databricks_job" "this" { - name = "tf-{var.STICKY_RANDOM}" - } +# resource "databricks_job" "this" { +# name = "tf-{var.STICKY_RANDOM}" +# } - resource "databricks_model_serving" "this" { - name = "tf-{var.STICKY_RANDOM}" - config { - served_models { - name = "prod_model" - model_name = "experiment-fixture-model" - model_version = "1" - workload_size = "Small" - scale_to_zero_enabled = true - } - } - } +# resource "databricks_model_serving" "this" { +# name = "tf-{var.STICKY_RANDOM}" +# config { +# served_models { +# name = "prod_model" +# model_name = "experiment-fixture-model" +# model_version = "1" +# workload_size = "Small" +# scale_to_zero_enabled = true +# } +# } +# } ` func makeTemplate(description string) string { @@ -55,41 +55,41 @@ func makeTemplate(description string) string { resource "databricks_app" "this" { name = "{var.STICKY_RANDOM}" description = "%s" - resources { + resources = [{ name = "secret" description = "secret for app" - secret { + secret = { scope = databricks_secret_scope.this.name key = databricks_secret.this.key permission = "MANAGE" } - } - resources { - name = "warehouse" - description = "warehouse for app" - job { - id = databricks_job.this.id - permission = "CAN_MANAGE" - } - } + }] +# resources { +# name = "warehouse" +# description = "warehouse for app" +# job { +# id = databricks_job.this.id +# permission = "CAN_MANAGE" +# } +# } - resources { - name = "serving endpoint" - description = "serving endpoint for app" - serving_endpoint { - name = databricks_model_serving.this.name - permission = "CAN_MANAGE" - } - } +# resources { +# name = "serving endpoint" +# description = "serving endpoint for app" +# serving_endpoint { +# name = databricks_model_serving.this.name +# permission = "CAN_MANAGE" +# } +# } - resources { - name = "sql warehouse" - description = "sql warehouse for app" - sql_warehouse { - id = databricks_sql_endpoint.this.id - permission = "CAN_MANAGE" - } - } +# resources { +# name = "sql warehouse" +# description = "sql warehouse for app" +# sql_warehouse { +# id = databricks_sql_endpoint.this.id +# permission = "CAN_MANAGE" +# } +# } }` return fmt.Sprintf(appTemplate, description) } From 7f8a84517efaf0c6426bf2107350d94fc60d6578 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 19:30:36 +0100 Subject: [PATCH 71/91] work --- .../data_notification_destinations.go | 2 +- .../tfschema/customizable_schema_test.go | 11 ++- .../pluginfw/tfschema/struct_to_schema.go | 5 + internal/service/apps_tf/model.go | 14 +-- internal/service/billing_tf/model.go | 16 +-- internal/service/catalog_tf/model.go | 74 +++++++------- internal/service/cleanrooms_tf/model.go | 30 +++--- internal/service/compute_tf/model.go | 86 ++++++++-------- internal/service/dashboards_tf/model.go | 10 +- internal/service/files_tf/model.go | 4 +- internal/service/iam_tf/model.go | 56 +++++------ internal/service/jobs_tf/model.go | 98 +++++++++---------- internal/service/marketplace_tf/model.go | 46 ++++----- internal/service/ml_tf/model.go | 78 +++++++-------- internal/service/oauth2_tf/model.go | 8 +- internal/service/pipelines_tf/model.go | 44 ++++----- internal/service/provisioning_tf/model.go | 4 +- internal/service/serving_tf/model.go | 54 +++++----- internal/service/settings_tf/model.go | 30 +++--- internal/service/sharing_tf/model.go | 26 ++--- internal/service/sql_tf/model.go | 64 ++++++------ internal/service/vectorsearch_tf/model.go | 24 ++--- internal/service/workspace_tf/model.go | 28 +++--- 23 files changed, 411 insertions(+), 401 deletions(-) diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index 5e6688bb79..f81361830f 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -36,7 +36,7 @@ type NotificationDestinationsDataSource struct { type NotificationDestinationsInfo struct { DisplayNameContains types.String `tfsdk:"display_name_contains" tf:"optional"` Type types.String `tfsdk:"type" tf:"optional"` - NotificationDestinations types.List `tfsdk:"notification_destinations" tf:"computed"` + NotificationDestinations types.List `tfsdk:"notification_destinations" tf:"readonly"` } func (NotificationDestinationsInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 1d88e32f1c..94d0570c7e 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -75,7 +75,7 @@ func TestCustomizeSchemaSetRequired(t *testing.T) { return c }) - assert.True(t, scm.Blocks["nested"].(schema.ListNestedBlock).NestedObject.Attributes["enabled"].IsRequired()) + assert.True(t, scm.Attributes["nested"].(schema.ListNestedAttribute).NestedObject.Attributes["enabled"].IsRequired()) } func TestCustomizeSchemaSetOptional(t *testing.T) { @@ -93,7 +93,7 @@ func TestCustomizeSchemaSetSensitive(t *testing.T) { return c }) - assert.True(t, scm.Blocks["nested"].(schema.ListNestedBlock).NestedObject.Attributes["name"].IsSensitive()) + assert.True(t, scm.Attributes["nested"].(schema.ListNestedAttribute).NestedObject.Attributes["name"].IsSensitive()) } func TestCustomizeSchemaSetDeprecated(t *testing.T) { @@ -138,12 +138,13 @@ func TestCustomizeSchemaObjectTypeValidatorAdded(t *testing.T) { return c }) - assert.True(t, len(scm.Blocks["nested_slice_object"].(schema.ListNestedBlock).Validators) == 1) + assert.True(t, len(scm.Attributes["nested_slice_object"].(schema.ListNestedAttribute).Validators) == 1) } func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetRequired("nested") return c }) @@ -153,6 +154,7 @@ func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetOptional("nested") return c }) @@ -162,6 +164,7 @@ func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetSensitive("nested") return c }) @@ -171,6 +174,7 @@ func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetReadOnly("nested") return c }) @@ -180,6 +184,7 @@ func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetComputed_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetComputed("nested") return c }) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index ceb83d7f6c..8f545f209e 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -20,6 +20,7 @@ import ( type structTag struct { optional bool computed bool + readonly bool singleObject bool } @@ -50,6 +51,9 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { if structTag.computed { attr = attr.SetComputed() } + if structTag.readonly { + attr = attr.SetReadOnly() + } scmAttr[fieldName] = attr } return NestedBlockObject{Attributes: scmAttr} @@ -164,6 +168,7 @@ func getStructTag(field reflect.StructField) structTag { return structTag{ optional: strings.Contains(tagValue, "optional"), computed: strings.Contains(tagValue, "computed"), + readonly: strings.Contains(tagValue, "readonly"), singleObject: strings.Contains(tagValue, "object"), } } diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 88accf4d8e..9921b6c284 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -123,7 +123,7 @@ func (o App) Type(ctx context.Context) attr.Type { "description": types.StringType, "name": types.StringType, "pending_deployment": AppDeployment{}.Type(ctx), - "resources": AppResource{}.Type(ctx), + "resources": basetypes.ListType{ElemType: AppResource{}.Type(ctx)}, "service_principal_client_id": types.StringType, "service_principal_id": types.Int64Type, "service_principal_name": types.StringType, @@ -377,7 +377,7 @@ func (o AppAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o AppAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": AppPermission{}.Type(ctx), + "all_permissions": basetypes.ListType{ElemType: AppPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -757,7 +757,7 @@ func (o AppPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AppPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": AppAccessControlResponse{}.Type(ctx), + "access_control_list": basetypes.ListType{ElemType: AppAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -876,7 +876,7 @@ func (o AppPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o AppPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": AppAccessControlRequest{}.Type(ctx), + "access_control_list": basetypes.ListType{ElemType: AppAccessControlRequest{}.Type(ctx)}, "app_name": types.StringType, }, } @@ -1691,7 +1691,7 @@ func (o GetAppPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetAppPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": AppPermissionsDescription{}.Type(ctx), + "permission_levels": basetypes.ListType{ElemType: AppPermissionsDescription{}.Type(ctx)}, }, } } @@ -1902,7 +1902,7 @@ func (o ListAppDeploymentsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListAppDeploymentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_deployments": AppDeployment{}.Type(ctx), + "app_deployments": basetypes.ListType{ElemType: AppDeployment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2023,7 +2023,7 @@ func (o ListAppsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAppsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": App{}.Type(ctx), + "apps": basetypes.ListType{ElemType: App{}.Type(ctx)}, "next_page_token": types.StringType, }, } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 8d76cda34a..7dfbc275b4 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -129,7 +129,7 @@ func (o AlertConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o AlertConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ElemType: ActionConfiguration{}.Type(ctx)}, + "action_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ActionConfiguration{}.Type(ctx)}}, "alert_configuration_id": types.StringType, "quantity_threshold": types.StringType, "quantity_type": types.StringType, @@ -228,7 +228,7 @@ func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, + "alert_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}}, "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, @@ -335,7 +335,7 @@ func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) basetypes. func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "tags": basetypes.ListType{ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx)}}, "workspace_id": basetypes.ListType{ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx)}, }, } @@ -757,7 +757,7 @@ func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx)}, + "alert_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx)}}, "display_name": types.StringType, "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, }, @@ -917,7 +917,7 @@ func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx co func (o CreateBudgetConfigurationBudgetAlertConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx)}, + "action_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx)}}, "quantity_threshold": types.StringType, "quantity_type": types.StringType, "time_period": types.StringType, @@ -1758,7 +1758,7 @@ func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) bas func (o ListBudgetConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budgets": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, + "budgets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -2202,7 +2202,7 @@ func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, + "alert_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}}, "budget_configuration_id": types.StringType, "display_name": types.StringType, "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, @@ -2633,7 +2633,7 @@ func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) bas func (o WrappedLogDeliveryConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configurations": basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}, + "log_delivery_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}}, }, } } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 0a29009bcb..8d141d4a98 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -723,7 +723,7 @@ func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o ArtifactAllowlistInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, + "artifact_matchers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}}, "created_at": types.Int64Type, "created_by": types.StringType, "metastore_id": types.StringType, @@ -3233,7 +3233,7 @@ func (o CreateMonitor) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "custom_metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}}, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, @@ -5746,7 +5746,7 @@ func (o DependencyList) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o DependencyList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dependencies": basetypes.ListType{ElemType: Dependency{}.Type(ctx)}, + "dependencies": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Dependency{}.Type(ctx)}}, }, } } @@ -5900,7 +5900,7 @@ func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) basetypes.O func (o EffectivePermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: EffectivePrivilegeAssignment{}.Type(ctx)}, + "privilege_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EffectivePrivilegeAssignment{}.Type(ctx)}}, }, } } @@ -6082,7 +6082,7 @@ func (o EffectivePrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, - "privileges": basetypes.ListType{ElemType: EffectivePrivilege{}.Type(ctx)}, + "privileges": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EffectivePrivilege{}.Type(ctx)}}, }, } } @@ -7028,7 +7028,7 @@ func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) basetypes.Obj func (o FunctionParameterInfos) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ElemType: FunctionParameterInfo{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FunctionParameterInfo{}.Type(ctx)}}, }, } } @@ -9145,7 +9145,7 @@ func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context func (o ListAccountStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, + "storage_credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}}, }, } } @@ -9280,7 +9280,7 @@ func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListCatalogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalogs": basetypes.ListType{ElemType: CatalogInfo{}.Type(ctx)}, + "catalogs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CatalogInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -9408,7 +9408,7 @@ func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListConnectionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "connections": basetypes.ListType{ElemType: ConnectionInfo{}.Type(ctx)}, + "connections": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ConnectionInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -9538,7 +9538,7 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, + "credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -9671,7 +9671,7 @@ func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) basety func (o ListExternalLocationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "external_locations": basetypes.ListType{ElemType: ExternalLocationInfo{}.Type(ctx)}, + "external_locations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExternalLocationInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -9812,7 +9812,7 @@ func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListFunctionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "functions": basetypes.ListType{ElemType: FunctionInfo{}.Type(ctx)}, + "functions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FunctionInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -9883,7 +9883,7 @@ func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListMetastoresResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastores": basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}, + "metastores": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}}, }, } } @@ -10020,7 +10020,7 @@ func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: ModelVersionInfo{}.Type(ctx)}, + "model_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -10144,7 +10144,7 @@ func (o ListQuotasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "quotas": basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}, + "quotas": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}}, }, } } @@ -10340,7 +10340,7 @@ func (o ListRegisteredModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: RegisteredModelInfo{}.Type(ctx)}, + "registered_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelInfo{}.Type(ctx)}}, }, } } @@ -10477,7 +10477,7 @@ func (o ListSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ElemType: SchemaInfo{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SchemaInfo{}.Type(ctx)}}, }, } } @@ -10605,7 +10605,7 @@ func (o ListStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, + "storage_credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}}, }, } } @@ -10808,7 +10808,7 @@ func (o ListSystemSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ElemType: SystemSchemaInfo{}.Type(ctx)}, + "schemas": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SystemSchemaInfo{}.Type(ctx)}}, }, } } @@ -10884,7 +10884,7 @@ func (o ListTableSummariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ElemType: TableSummary{}.Type(ctx)}, + "tables": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TableSummary{}.Type(ctx)}}, }, } } @@ -11046,7 +11046,7 @@ func (o ListTablesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ElemType: TableInfo{}.Type(ctx)}, + "tables": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TableInfo{}.Type(ctx)}}, }, } } @@ -11194,7 +11194,7 @@ func (o ListVolumesResponseContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "volumes": basetypes.ListType{ElemType: VolumeInfo{}.Type(ctx)}, + "volumes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: VolumeInfo{}.Type(ctx)}}, }, } } @@ -11499,7 +11499,7 @@ func (o ModelVersionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, + "aliases": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}}, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -11960,7 +11960,7 @@ func (o MonitorInfo) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "custom_metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}}, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "drift_metrics_table_name": types.StringType, @@ -12494,7 +12494,7 @@ func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) basetypes func (o MonitorRefreshListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "refreshes": basetypes.ListType{ElemType: MonitorRefreshInfo{}.Type(ctx)}, + "refreshes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorRefreshInfo{}.Type(ctx)}}, }, } } @@ -13353,7 +13353,7 @@ func (o PermissionsList) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, + "privilege_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}}, }, } } @@ -14094,7 +14094,7 @@ func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) basetypes.Object func (o RegisteredModelInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, + "aliases": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}}, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -14391,7 +14391,7 @@ func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) basetypes.Objec func (o SetArtifactAllowlist) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, + "artifact_matchers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}}, "artifact_type": types.StringType, }, } @@ -15190,7 +15190,7 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "access_point": types.StringType, "browse_only": types.BoolType, "catalog_name": types.StringType, - "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}}, "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, @@ -15212,7 +15212,7 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "sql_path": types.StringType, "storage_credential_name": types.StringType, "storage_location": types.StringType, - "table_constraints": basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}, + "table_constraints": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}}, "table_id": types.StringType, "table_type": types.StringType, "updated_at": types.Int64Type, @@ -16676,7 +16676,7 @@ func (o UpdateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "custom_metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}}, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, @@ -16944,7 +16944,7 @@ func (o UpdatePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdatePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: PermissionsChange{}.Type(ctx)}, + "changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionsChange{}.Type(ctx)}}, "full_name": types.StringType, "securable_type": types.StringType, }, @@ -17641,8 +17641,8 @@ func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) ba func (o UpdateWorkspaceBindingsParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, - "remove": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, + "add": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}}, + "remove": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}}, "securable_name": types.StringType, "securable_type": types.StringType, }, @@ -17871,7 +17871,7 @@ func (o ValidateCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, - "results": basetypes.ListType{ElemType: CredentialValidationResult{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CredentialValidationResult{}.Type(ctx)}}, }, } } @@ -18155,7 +18155,7 @@ func (o ValidateStorageCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, - "results": basetypes.ListType{ElemType: ValidationResult{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ValidationResult{}.Type(ctx)}}, }, } } @@ -18462,7 +18462,7 @@ func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) basetypes. func (o WorkspaceBindingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "bindings": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, + "bindings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}}, "next_page_token": types.StringType, }, } diff --git a/internal/service/cleanrooms_tf/model.go b/internal/service/cleanrooms_tf/model.go index 191ab84573..fe9886fafc 100755 --- a/internal/service/cleanrooms_tf/model.go +++ b/internal/service/cleanrooms_tf/model.go @@ -529,7 +529,7 @@ func (o CleanRoomAssetForeignTable) ToObjectValue(ctx context.Context) basetypes func (o CleanRoomAssetForeignTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}}, }, } } @@ -689,7 +689,7 @@ func (o CleanRoomAssetTable) ToObjectValue(ctx context.Context) basetypes.Object func (o CleanRoomAssetTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}}, }, } } @@ -764,7 +764,7 @@ func (o CleanRoomAssetTableLocalDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "local_name": types.StringType, - "partitions": basetypes.ListType{ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx)}, + "partitions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx)}}, }, } } @@ -834,7 +834,7 @@ func (o CleanRoomAssetView) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CleanRoomAssetView) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}}, }, } } @@ -1277,7 +1277,7 @@ func (o CleanRoomRemoteDetail) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "central_clean_room_id": types.StringType, "cloud_vendor": types.StringType, - "collaborators": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, + "collaborators": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}}, "compliance_security_profile": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, "creator": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, "egress_network_policy": basetypes.ListType{ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx)}, @@ -1473,7 +1473,7 @@ func (newState *ComplianceSecurityProfile) SyncEffectiveFieldsDuringRead(existin // SDK values. func (a ComplianceSecurityProfile) GetComplexFieldTypes(ctx context.Context) map[string]reflect.Type { return map[string]reflect.Type{ - "compliance_standards": reflect.TypeOf(settings_tf.ComplianceStandard{}), + "compliance_standards": reflect.TypeOf(types.String{}), } } @@ -1493,20 +1493,20 @@ func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) basetypes. func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ElemType: settings_tf.ComplianceStandard{}.Type(ctx)}, + "compliance_standards": basetypes.ListType{ElemType: types.StringType}, "is_enabled": types.BoolType, }, } } // GetComplianceStandards returns the value of the ComplianceStandards field in ComplianceSecurityProfile as -// a slice of settings_tf.ComplianceStandard values. +// a slice of types.String values. // If the field is unknown or null, the boolean return value is false. -func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) ([]settings_tf.ComplianceStandard, bool) { +func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) ([]types.String, bool) { if o.ComplianceStandards.IsNull() || o.ComplianceStandards.IsUnknown() { return nil, false } - var v []settings_tf.ComplianceStandard + var v []types.String d := o.ComplianceStandards.ElementsAs(ctx, &v, true) if d.HasError() { panic(pluginfwcommon.DiagToString(d)) @@ -1515,10 +1515,10 @@ func (o *ComplianceSecurityProfile) GetComplianceStandards(ctx context.Context) } // SetComplianceStandards sets the value of the ComplianceStandards field in ComplianceSecurityProfile. -func (o *ComplianceSecurityProfile) SetComplianceStandards(ctx context.Context, v []settings_tf.ComplianceStandard) { +func (o *ComplianceSecurityProfile) SetComplianceStandards(ctx context.Context, v []types.String) { vs := make([]attr.Value, 0, len(v)) for _, e := range v { - vs = append(vs, e.ToObjectValue(ctx)) + vs = append(vs, e) } t := o.Type(ctx).(basetypes.ObjectType).AttrTypes["compliance_standards"] t = t.(attr.TypeWithElementType).ElementType() @@ -2168,7 +2168,7 @@ func (o ListCleanRoomAssetsResponse) ToObjectValue(ctx context.Context) basetype func (o ListCleanRoomAssetsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, + "assets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -2300,7 +2300,7 @@ func (o ListCleanRoomNotebookTaskRunsResponse) Type(ctx context.Context) attr.Ty return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: CleanRoomNotebookTaskRun{}.Type(ctx)}, + "runs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoomNotebookTaskRun{}.Type(ctx)}}, }, } } @@ -2422,7 +2422,7 @@ func (o ListCleanRoomsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListCleanRoomsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_rooms": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, + "clean_rooms": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}}, "next_page_token": types.StringType, }, } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 4c000e2c98..07050ff7d4 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -889,7 +889,7 @@ func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) basetyp func (o ClusterAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ClusterPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -1137,7 +1137,7 @@ func (o ClusterAttributes) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "policy_id": types.StringType, @@ -1852,9 +1852,9 @@ func (o ClusterDetails) Type(ctx context.Context) attr.Type { "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "executors": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, + "executors": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}}, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "jdbc_port": types.Int64Type, "last_restarted_time": types.Int64Type, @@ -2506,7 +2506,7 @@ func (o ClusterLibraryStatuses) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "library_statuses": basetypes.ListType{ElemType: LibraryFullStatus{}.Type(ctx)}, + "library_statuses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LibraryFullStatus{}.Type(ctx)}}, }, } } @@ -2764,7 +2764,7 @@ func (o ClusterPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ClusterPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -2883,7 +2883,7 @@ func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) basetypes. func (o ClusterPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterAccessControlRequest{}.Type(ctx)}}, "cluster_id": types.StringType, }, } @@ -3020,7 +3020,7 @@ func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) b func (o ClusterPolicyAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ClusterPolicyPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3176,7 +3176,7 @@ func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) basetypes.O func (o ClusterPolicyPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3295,7 +3295,7 @@ func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) base func (o ClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx)}}, "cluster_policy_id": types.StringType, }, } @@ -3708,7 +3708,7 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, @@ -4595,7 +4595,7 @@ func (o CreateCluster) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, @@ -5156,7 +5156,7 @@ func (o CreateInstancePool) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "preloaded_docker_images": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}}, "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, }, } @@ -5464,7 +5464,7 @@ func (o CreatePolicy) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -6628,7 +6628,7 @@ func (o EditCluster) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, @@ -7220,7 +7220,7 @@ func (o EditPolicy) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -7419,7 +7419,7 @@ func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) bas func (o EnforceClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: ClusterSettingsChange{}.Type(ctx)}, + "changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterSettingsChange{}.Type(ctx)}}, "has_changes": types.BoolType, }, } @@ -8152,7 +8152,7 @@ func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) b func (o GetClusterPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ClusterPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPermissionsDescription{}.Type(ctx)}}, }, } } @@ -8308,7 +8308,7 @@ func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Cont func (o GetClusterPolicyPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx)}}, }, } } @@ -8616,7 +8616,7 @@ func (o GetEventsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o GetEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: ClusterEvent{}.Type(ctx)}, + "events": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterEvent{}.Type(ctx)}}, "next_page": basetypes.ListType{ElemType: GetEvents{}.Type(ctx)}, "total_count": types.Int64Type, }, @@ -8867,7 +8867,7 @@ func (o GetInstancePool) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "preloaded_docker_images": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}}, "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, "state": types.StringType, "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, @@ -9218,7 +9218,7 @@ func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Conte func (o GetInstancePoolPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: InstancePoolPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolPermissionsDescription{}.Type(ctx)}}, }, } } @@ -9422,7 +9422,7 @@ func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetSparkVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "versions": basetypes.ListType{ElemType: SparkVersion{}.Type(ctx)}, + "versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SparkVersion{}.Type(ctx)}}, }, } } @@ -9782,8 +9782,8 @@ func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) basetypes.Obj func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, - "global": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, + "cluster": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}}, + "global": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}}, "reported_for_node": types.StringType, }, } @@ -10302,7 +10302,7 @@ func (o InstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, }, } } @@ -10474,7 +10474,7 @@ func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) ba func (o InstancePoolAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: InstancePoolPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -10658,7 +10658,7 @@ func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "preloaded_docker_images": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}}, "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, "state": types.StringType, "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, @@ -11243,7 +11243,7 @@ func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) basetypes.Ob func (o InstancePoolPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -11362,7 +11362,7 @@ func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) baset func (o InstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolAccessControlRequest{}.Type(ctx)}}, "instance_pool_id": types.StringType, }, } @@ -11490,7 +11490,7 @@ func (o InstancePoolStatus) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o InstancePoolStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "pending_instance_errors": basetypes.ListType{ElemType: PendingInstanceError{}.Type(ctx)}, + "pending_instance_errors": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PendingInstanceError{}.Type(ctx)}}, }, } } @@ -11901,7 +11901,7 @@ func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context func (o ListAllClusterLibraryStatusesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "statuses": basetypes.ListType{ElemType: ClusterLibraryStatuses{}.Type(ctx)}, + "statuses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterLibraryStatuses{}.Type(ctx)}}, }, } } @@ -12109,7 +12109,7 @@ func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) baset func (o ListClusterCompliancesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ElemType: ClusterCompliance{}.Type(ctx)}, + "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterCompliance{}.Type(ctx)}}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12462,7 +12462,7 @@ func (o ListClustersResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListClustersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ElemType: ClusterDetails{}.Type(ctx)}, + "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterDetails{}.Type(ctx)}}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12581,7 +12581,7 @@ func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) basety func (o ListGlobalInitScriptsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scripts": basetypes.ListType{ElemType: GlobalInitScriptDetails{}.Type(ctx)}, + "scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GlobalInitScriptDetails{}.Type(ctx)}}, }, } } @@ -12650,7 +12650,7 @@ func (o ListInstancePools) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListInstancePools) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_pools": basetypes.ListType{ElemType: InstancePoolAndStats{}.Type(ctx)}, + "instance_pools": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolAndStats{}.Type(ctx)}}, }, } } @@ -12720,7 +12720,7 @@ func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) basetyp func (o ListInstanceProfilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_profiles": basetypes.ListType{ElemType: InstanceProfile{}.Type(ctx)}, + "instance_profiles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstanceProfile{}.Type(ctx)}}, }, } } @@ -12790,7 +12790,7 @@ func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListNodeTypesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "node_types": basetypes.ListType{ElemType: NodeType{}.Type(ctx)}, + "node_types": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NodeType{}.Type(ctx)}}, }, } } @@ -12860,7 +12860,7 @@ func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListPoliciesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "policies": basetypes.ListType{ElemType: Policy{}.Type(ctx)}, + "policies": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Policy{}.Type(ctx)}}, }, } } @@ -12982,7 +12982,7 @@ func (o ListPolicyFamiliesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "policy_families": basetypes.ListType{ElemType: PolicyFamily{}.Type(ctx)}, + "policy_families": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PolicyFamily{}.Type(ctx)}}, }, } } @@ -13770,7 +13770,7 @@ func (o Policy) Type(ctx context.Context) attr.Type { "definition": types.StringType, "description": types.StringType, "is_default": types.BoolType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -14857,7 +14857,7 @@ func (o UninstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, }, } } @@ -15316,7 +15316,7 @@ func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index cbb72a4262..0be0577abc 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -1094,7 +1094,7 @@ func (o GenieMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GenieMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attachments": basetypes.ListType{ElemType: GenieAttachment{}.Type(ctx)}, + "attachments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GenieAttachment{}.Type(ctx)}}, "content": types.StringType, "conversation_id": types.StringType, "created_timestamp": types.Int64Type, @@ -1625,7 +1625,7 @@ func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListDashboardsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboards": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, + "dashboards": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -1754,7 +1754,7 @@ func (o ListSchedulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schedules": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, + "schedules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Schedule{}.Type(ctx)}}, }, } } @@ -1886,7 +1886,7 @@ func (o ListSubscriptionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "subscriptions": basetypes.ListType{ElemType: Subscription{}.Type(ctx)}, + "subscriptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Subscription{}.Type(ctx)}}, }, } } @@ -2262,7 +2262,7 @@ func (o QuerySchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QuerySchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: QuerySchemaColumn{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QuerySchemaColumn{}.Type(ctx)}}, "statement_id": types.StringType, }, } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 11b76683b7..9768cf96af 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -1133,7 +1133,7 @@ func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "contents": basetypes.ListType{ElemType: DirectoryEntry{}.Type(ctx)}, + "contents": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DirectoryEntry{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -1205,7 +1205,7 @@ func (o ListStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "files": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, }, } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 3753b284f1..e3cd7db9de 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -126,7 +126,7 @@ func (o AccessControlResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o AccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: Permission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Permission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -840,7 +840,7 @@ func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context func (o GetAssignableRolesForResourceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "roles": basetypes.ListType{ElemType: Role{}.Type(ctx)}, + "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Role{}.Type(ctx)}}, }, } } @@ -953,7 +953,7 @@ func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPasswordPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: PasswordPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordPermissionsDescription{}.Type(ctx)}}, }, } } @@ -1070,7 +1070,7 @@ func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetype func (o GetPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: PermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionsDescription{}.Type(ctx)}}, }, } } @@ -1516,13 +1516,13 @@ func (o Group) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "displayName": types.StringType, - "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "entitlements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "groups": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "id": types.StringType, - "members": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "members": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "meta": basetypes.ListType{ElemType: ResourceMeta{}.Type(ctx)}, - "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, }, } @@ -2031,7 +2031,7 @@ func (o ListGroupsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: Group{}.Type(ctx)}, + "Resources": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Group{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, @@ -2145,7 +2145,7 @@ func (o ListServicePrincipalResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: ServicePrincipal{}.Type(ctx)}, + "Resources": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServicePrincipal{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, @@ -2406,7 +2406,7 @@ func (o ListUsersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "Resources": basetypes.ListType{ElemType: basetypes.ListType{ElemType: User{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, @@ -2696,7 +2696,7 @@ func (o ObjectPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -2777,7 +2777,7 @@ func (o PartialUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, - "Operations": basetypes.ListType{ElemType: Patch{}.Type(ctx)}, + "Operations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Patch{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, }, } @@ -2940,7 +2940,7 @@ func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PasswordAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: PasswordPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3096,7 +3096,7 @@ func (o PasswordPermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PasswordPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3212,7 +3212,7 @@ func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PasswordPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordAccessControlRequest{}.Type(ctx)}}, }, } } @@ -3552,7 +3552,7 @@ func (o PermissionAssignments) ToObjectValue(ctx context.Context) basetypes.Obje func (o PermissionAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_assignments": basetypes.ListType{ElemType: PermissionAssignment{}.Type(ctx)}, + "permission_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionAssignment{}.Type(ctx)}}, }, } } @@ -3722,7 +3722,7 @@ func (o PermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControlRequest{}.Type(ctx)}}, "request_object_id": types.StringType, "request_object_type": types.StringType, }, @@ -3946,7 +3946,7 @@ func (o RuleSetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, - "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, + "grant_rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}}, "name": types.StringType, }, } @@ -4026,7 +4026,7 @@ func (o RuleSetUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, - "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, + "grant_rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}}, "name": types.StringType, }, } @@ -4130,11 +4130,11 @@ func (o ServicePrincipal) Type(ctx context.Context) attr.Type { "active": types.BoolType, "applicationId": types.StringType, "displayName": types.StringType, - "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "entitlements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "groups": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "id": types.StringType, - "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, }, } @@ -4522,13 +4522,13 @@ func (o User) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "active": types.BoolType, "displayName": types.StringType, - "emails": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "emails": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "entitlements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "groups": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "id": types.StringType, "name": basetypes.ListType{ElemType: Name{}.Type(ctx)}, - "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, "schemas": basetypes.ListType{ElemType: types.StringType}, "userName": types.StringType, }, @@ -4730,7 +4730,7 @@ func (o WorkspacePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WorkspacePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permissions": basetypes.ListType{ElemType: PermissionOutput{}.Type(ctx)}, + "permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionOutput{}.Type(ctx)}}, }, } } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index a64f6c3f66..950974e5ed 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -330,15 +330,15 @@ func (o BaseRun) Type(ctx context.Context) attr.Type { "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "job_clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, + "job_parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}}, "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, + "repair_history": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}}, "run_duration": types.Int64Type, "run_id": types.Int64Type, "run_name": types.StringType, @@ -349,7 +349,7 @@ func (o BaseRun) Type(ctx context.Context) attr.Type { "start_time": types.Int64Type, "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, + "tasks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTask{}.Type(ctx)}}, "trigger": types.StringType, "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, @@ -995,7 +995,7 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "existing_cluster_id": types.StringType, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, }, } @@ -1335,27 +1335,27 @@ func (o CreateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}}, "budget_policy_id": types.StringType, "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "environment": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}}, "format": types.StringType, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "job_cluster": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, + "parameter": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}}, "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, "tags": basetypes.MapType{ElemType: types.StringType}, - "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "task": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Task{}.Type(ctx)}}, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, @@ -2412,7 +2412,7 @@ func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_changes": types.BoolType, - "job_cluster_changes": basetypes.ListType{ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx)}, + "job_cluster_changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx)}}, "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } @@ -2514,7 +2514,7 @@ func (o ExportRunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o ExportRunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "views": basetypes.ListType{ElemType: ViewItem{}.Type(ctx)}, + "views": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ViewItem{}.Type(ctx)}}, }, } } @@ -2691,7 +2691,7 @@ func (o ForEachStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ForEachStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error_message_stats": basetypes.ListType{ElemType: ForEachTaskErrorMessageStats{}.Type(ctx)}, + "error_message_stats": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ForEachTaskErrorMessageStats{}.Type(ctx)}}, "task_run_stats": basetypes.ListType{ElemType: ForEachTaskTaskRunStats{}.Type(ctx)}, }, } @@ -3026,7 +3026,7 @@ func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetJobPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: JobPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobPermissionsDescription{}.Type(ctx)}}, }, } } @@ -3761,7 +3761,7 @@ func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o JobAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: JobPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -4563,7 +4563,7 @@ func (o JobPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o JobPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4682,7 +4682,7 @@ func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o JobPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}}, "job_id": types.StringType, }, } @@ -4947,20 +4947,20 @@ func (o JobSettings) Type(ctx context.Context) attr.Type { "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "environment": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}}, "format": types.StringType, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "job_cluster": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, + "parameter": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}}, "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, "tags": basetypes.MapType{ElemType: types.StringType}, - "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "task": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Task{}.Type(ctx)}}, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, @@ -5546,7 +5546,7 @@ func (o JobsHealthRules) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o JobsHealthRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rules": basetypes.ListType{ElemType: JobsHealthRule{}.Type(ctx)}, + "rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobsHealthRule{}.Type(ctx)}}, }, } } @@ -5626,7 +5626,7 @@ func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) b func (o ListJobComplianceForPolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "jobs": basetypes.ListType{ElemType: JobCompliance{}.Type(ctx)}, + "jobs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCompliance{}.Type(ctx)}}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -5829,7 +5829,7 @@ func (o ListJobsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_more": types.BoolType, - "jobs": basetypes.ListType{ElemType: BaseJob{}.Type(ctx)}, + "jobs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BaseJob{}.Type(ctx)}}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -6012,7 +6012,7 @@ func (o ListRunsResponse) Type(ctx context.Context) attr.Type { "has_more": types.BoolType, "next_page_token": types.StringType, "prev_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: BaseRun{}.Type(ctx)}, + "runs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BaseRun{}.Type(ctx)}}, }, } } @@ -8386,17 +8386,17 @@ func (o Run) Type(ctx context.Context) attr.Type { "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "iterations": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, - "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "iterations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTask{}.Type(ctx)}}, + "job_clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, + "job_parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}}, "job_run_id": types.Int64Type, "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, + "repair_history": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}}, "run_duration": types.Int64Type, "run_id": types.Int64Type, "run_name": types.StringType, @@ -8407,7 +8407,7 @@ func (o Run) Type(ctx context.Context) attr.Type { "start_time": types.Int64Type, "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, + "tasks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTask{}.Type(ctx)}}, "trigger": types.StringType, "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, @@ -10898,7 +10898,7 @@ func (o RunTask) Type(ctx context.Context) attr.Type { "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, "condition_task": basetypes.ListType{ElemType: RunConditionTask{}.Type(ctx)}, "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, + "depends_on": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}}, "description": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, "end_time": types.Int64Type, @@ -10908,7 +10908,7 @@ func (o RunTask) Type(ctx context.Context) attr.Type { "for_each_task": basetypes.ListType{ElemType: RunForEachTask{}.Type(ctx)}, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, @@ -11825,7 +11825,7 @@ func (o SqlAlertOutput) Type(ctx context.Context) attr.Type { "alert_state": types.StringType, "output_link": types.StringType, "query_text": types.StringType, - "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, + "sql_statements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}}, "warehouse_id": types.StringType, }, } @@ -11900,7 +11900,7 @@ func (o SqlDashboardOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, - "widgets": basetypes.ListType{ElemType: SqlDashboardWidgetOutput{}.Type(ctx)}, + "widgets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlDashboardWidgetOutput{}.Type(ctx)}}, }, } } @@ -12253,7 +12253,7 @@ func (o SqlQueryOutput) Type(ctx context.Context) attr.Type { "endpoint_id": types.StringType, "output_link": types.StringType, "query_text": types.StringType, - "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, + "sql_statements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}}, "warehouse_id": types.StringType, }, } @@ -12577,7 +12577,7 @@ func (o SqlTaskAlert) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, + "subscriptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}}, }, } } @@ -12660,7 +12660,7 @@ func (o SqlTaskDashboard) Type(ctx context.Context) attr.Type { "custom_subject": types.StringType, "dashboard_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, + "subscriptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}}, }, } } @@ -12956,10 +12956,10 @@ func (o SubmitRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}}, "budget_policy_id": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environments": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "environments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}}, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, "idempotency_token": types.StringType, @@ -12967,7 +12967,7 @@ func (o SubmitRun) Type(ctx context.Context) attr.Type { "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "run_name": types.StringType, - "tasks": basetypes.ListType{ElemType: SubmitTask{}.Type(ctx)}, + "tasks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SubmitTask{}.Type(ctx)}}, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, @@ -13453,14 +13453,14 @@ func (o SubmitTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, + "depends_on": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}}, "description": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, "environment_key": types.StringType, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, @@ -14239,7 +14239,7 @@ func (o Task) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, + "depends_on": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}}, "description": types.StringType, "disable_auto_optimization": types.BoolType, "email_notifications": basetypes.ListType{ElemType: TaskEmailNotifications{}.Type(ctx)}, @@ -14248,7 +14248,7 @@ func (o Task) Type(ctx context.Context) attr.Type { "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, @@ -15685,11 +15685,11 @@ func (o WebhookNotifications) ToObjectValue(ctx context.Context) basetypes.Objec func (o WebhookNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_failure": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_start": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_success": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, + "on_failure": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, + "on_start": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, + "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, + "on_success": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, }, } } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 5c5145f045..597cec230c 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -243,7 +243,7 @@ func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o BatchGetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, }, } } @@ -382,7 +382,7 @@ func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) basetypes. func (o BatchGetProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "providers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}}, }, } } @@ -1945,9 +1945,9 @@ func (o Exchange) Type(ctx context.Context) attr.Type { "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, - "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "filters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}}, "id": types.StringType, - "linked_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "linked_listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}}, "name": types.StringType, "updated_at": types.Int64Type, "updated_by": types.StringType, @@ -2652,7 +2652,7 @@ func (o GetListingContentMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shared_data_objects": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, + "shared_data_objects": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}}, }, } } @@ -2881,7 +2881,7 @@ func (o GetListingsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -2993,7 +2993,7 @@ func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) ba func (o GetPersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, + "personalization_requests": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}}, }, } } @@ -3291,7 +3291,7 @@ func (o InstallationDetail) Type(ctx context.Context) attr.Type { "share_name": types.StringType, "status": types.StringType, "token_detail": basetypes.ListType{ElemType: TokenDetail{}.Type(ctx)}, - "tokens": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, + "tokens": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}}, }, } } @@ -3435,7 +3435,7 @@ func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) basetyp func (o ListAllInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -3555,7 +3555,7 @@ func (o ListAllPersonalizationRequestsResponse) Type(ctx context.Context) attr.T return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, + "personalization_requests": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}}, }, } } @@ -3677,7 +3677,7 @@ func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) basetype func (o ListExchangeFiltersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "filters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -3800,7 +3800,7 @@ func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) base func (o ListExchangesForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listing": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "exchange_listing": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -3919,7 +3919,7 @@ func (o ListExchangesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListExchangesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchanges": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, + "exchanges": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Exchange{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4070,7 +4070,7 @@ func (o ListFilesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListFilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "file_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4193,7 +4193,7 @@ func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListFulfillmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fulfillments": basetypes.ListType{ElemType: ListingFulfillment{}.Type(ctx)}, + "fulfillments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListingFulfillment{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4316,7 +4316,7 @@ func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4439,7 +4439,7 @@ func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) base func (o ListListingsForExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "exchange_listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4546,7 +4546,7 @@ func (o ListListingsRequest) Type(ctx context.Context) attr.Type { "page_size": types.Int64Type, "page_token": types.StringType, "provider_ids": basetypes.ListType{ElemType: types.StringType}, - "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}}, }, } } @@ -4696,7 +4696,7 @@ func (o ListListingsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4870,7 +4870,7 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "providers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}}, }, } } @@ -5121,7 +5121,7 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { "data_source": types.StringType, "description": types.StringType, "documentation_link": types.StringType, - "embedded_notebook_file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "embedded_notebook_file_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, "file_ids": basetypes.ListType{ElemType: types.StringType}, "geographical_coverage": types.StringType, "license": types.StringType, @@ -5129,7 +5129,7 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { "privacy_policy_link": types.StringType, "size": types.Float64Type, "support_link": types.StringType, - "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}}, "terms_of_service": types.StringType, "update_frequency": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, }, @@ -6523,7 +6523,7 @@ func (o SearchListingsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o SearchListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, "next_page_token": types.StringType, }, } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index f6518c907e..96616debb7 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -530,7 +530,7 @@ func (o CreateExperiment) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}}, }, } } @@ -650,7 +650,7 @@ func (o CreateModelRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "description": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}}, }, } } @@ -811,7 +811,7 @@ func (o CreateModelVersionRequest) Type(ctx context.Context) attr.Type { "run_id": types.StringType, "run_link": types.StringType, "source": types.StringType, - "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}}, }, } } @@ -1147,7 +1147,7 @@ func (o CreateRun) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, "start_time": types.Int64Type, - "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTag{}.Type(ctx)}}, "user_id": types.StringType, }, } @@ -1565,7 +1565,7 @@ func (o DatasetInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset": basetypes.ListType{ElemType: Dataset{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: InputTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InputTag{}.Type(ctx)}}, }, } } @@ -2615,7 +2615,7 @@ func (o Experiment) Type(ctx context.Context) attr.Type { "last_update_time": types.Int64Type, "lifecycle_stage": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}}, }, } } @@ -2751,7 +2751,7 @@ func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) base func (o ExperimentAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ExperimentPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -2907,7 +2907,7 @@ func (o ExperimentPermissions) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExperimentPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3026,7 +3026,7 @@ func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) basetyp func (o ExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentAccessControlRequest{}.Type(ctx)}}, "experiment_id": types.StringType, }, } @@ -3279,7 +3279,7 @@ func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context func (o GetExperimentPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ExperimentPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentPermissionsDescription{}.Type(ctx)}}, }, } } @@ -3643,7 +3643,7 @@ func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o GetLatestVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "model_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, }, } } @@ -3717,7 +3717,7 @@ func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetMetricHistoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, + "metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Metric{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4148,7 +4148,7 @@ func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetRegisteredModelPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: RegisteredModelPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelPermissionsDescription{}.Type(ctx)}}, }, } } @@ -4711,7 +4711,7 @@ func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListArtifactsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "files": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, "next_page_token": types.StringType, "root_uri": types.StringType, }, @@ -4844,7 +4844,7 @@ func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, + "experiments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Experiment{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -4966,7 +4966,7 @@ func (o ListModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, + "registered_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Model{}.Type(ctx)}}, }, } } @@ -5040,7 +5040,7 @@ func (o ListRegistryWebhooks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "webhooks": basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}, + "webhooks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}}, }, } } @@ -5157,7 +5157,7 @@ func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) baset func (o ListTransitionRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "requests": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, + "requests": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Activity{}.Type(ctx)}}, }, } } @@ -5323,10 +5323,10 @@ func (o LogBatch) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogBatch) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, - "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, + "metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Metric{}.Type(ctx)}}, + "params": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Param{}.Type(ctx)}}, "run_id": types.StringType, - "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTag{}.Type(ctx)}}, }, } } @@ -5487,7 +5487,7 @@ func (o LogInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "datasets": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, + "datasets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}}, "run_id": types.StringType, }, } @@ -5944,9 +5944,9 @@ func (o Model) Type(ctx context.Context) attr.Type { "creation_timestamp": types.Int64Type, "description": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "latest_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}}, "user_id": types.StringType, }, } @@ -6073,10 +6073,10 @@ func (o ModelDatabricks) Type(ctx context.Context) attr.Type { "description": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "latest_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, "name": types.StringType, "permission_level": types.StringType, - "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}}, "user_id": types.StringType, }, } @@ -6268,7 +6268,7 @@ func (o ModelVersion) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}}, "user_id": types.StringType, "version": types.StringType, }, @@ -6410,7 +6410,7 @@ func (o ModelVersionDatabricks) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}}, "user_id": types.StringType, "version": types.StringType, }, @@ -6640,7 +6640,7 @@ func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) func (o RegisteredModelAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: RegisteredModelPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6796,7 +6796,7 @@ func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) basetypes func (o RegisteredModelPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -6915,7 +6915,7 @@ func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o RegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAccessControlRequest{}.Type(ctx)}}, "registered_model_id": types.StringType, }, } @@ -7819,9 +7819,9 @@ func (o RunData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, - "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, + "metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Metric{}.Type(ctx)}}, + "params": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Param{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTag{}.Type(ctx)}}, }, } } @@ -8023,7 +8023,7 @@ func (o RunInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataset_inputs": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, + "dataset_inputs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}}, }, } } @@ -8234,7 +8234,7 @@ func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) basetypes. func (o SearchExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, + "experiments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Experiment{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -8396,7 +8396,7 @@ func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) basetype func (o SearchModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "model_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -8558,7 +8558,7 @@ func (o SearchModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, + "registered_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Model{}.Type(ctx)}}, }, } } @@ -8766,7 +8766,7 @@ func (o SearchRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: Run{}.Type(ctx)}, + "runs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Run{}.Type(ctx)}}, }, } } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 02bf433cb5..691c462c4d 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -967,7 +967,7 @@ func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) baset func (o GetCustomAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: GetCustomAppIntegrationOutput{}.Type(ctx)}, + "apps": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GetCustomAppIntegrationOutput{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -1173,7 +1173,7 @@ func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) ba func (o GetPublishedAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx)}, + "apps": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -1248,7 +1248,7 @@ func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) basetypes.Obj func (o GetPublishedAppsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: PublishedAppOutput{}.Type(ctx)}, + "apps": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PublishedAppOutput{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -1521,7 +1521,7 @@ func (o ListServicePrincipalSecretsResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "secrets": basetypes.ListType{ElemType: SecretInfo{}.Type(ctx)}, + "secrets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SecretInfo{}.Type(ctx)}}, }, } } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 2234b9bf6b..35b3bb290b 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -156,7 +156,7 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, + "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}}, "configuration": basetypes.MapType{ElemType: types.StringType}, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, @@ -167,9 +167,9 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}}, "name": types.StringType, - "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, + "notifications": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Notifications{}.Type(ctx)}}, "photon": types.BoolType, "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, "schema": types.StringType, @@ -824,7 +824,7 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, + "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}}, "configuration": basetypes.MapType{ElemType: types.StringType}, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, @@ -835,9 +835,9 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}}, "name": types.StringType, - "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, + "notifications": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Notifications{}.Type(ctx)}}, "photon": types.BoolType, "pipeline_id": types.StringType, "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, @@ -1188,7 +1188,7 @@ func (o ErrorDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ErrorDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exceptions": basetypes.ListType{ElemType: SerializedException{}.Type(ctx)}, + "exceptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SerializedException{}.Type(ctx)}}, "fatal": types.BoolType, }, } @@ -1445,7 +1445,7 @@ func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPipelinePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: PipelinePermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelinePermissionsDescription{}.Type(ctx)}}, }, } } @@ -1642,7 +1642,7 @@ func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { "effective_budget_policy_id": types.StringType, "health": types.StringType, "last_modified": types.Int64Type, - "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, + "latest_updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}}, "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, @@ -2076,7 +2076,7 @@ func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "connection_name": types.StringType, "ingestion_gateway_id": types.StringType, - "objects": basetypes.ListType{ElemType: IngestionConfig{}.Type(ctx)}, + "objects": basetypes.ListType{ElemType: basetypes.ListType{ElemType: IngestionConfig{}.Type(ctx)}}, "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } @@ -2279,7 +2279,7 @@ func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListPipelineEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: PipelineEvent{}.Type(ctx)}, + "events": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineEvent{}.Type(ctx)}}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -2451,7 +2451,7 @@ func (o ListPipelinesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "statuses": basetypes.ListType{ElemType: PipelineStateInfo{}.Type(ctx)}, + "statuses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineStateInfo{}.Type(ctx)}}, }, } } @@ -2586,7 +2586,7 @@ func (o ListUpdatesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "prev_page_token": types.StringType, - "updates": basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}, + "updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}}, }, } } @@ -3014,7 +3014,7 @@ func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PipelineAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: PipelinePermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelinePermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3217,7 +3217,7 @@ func (o PipelineCluster) Type(ctx context.Context) attr.Type { "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: compute_tf.GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: compute_tf.InitScriptInfo{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.InitScriptInfo{}.Type(ctx)}}, "instance_pool_id": types.StringType, "label": types.StringType, "node_type_id": types.StringType, @@ -4012,7 +4012,7 @@ func (o PipelinePermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PipelinePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4131,7 +4131,7 @@ func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PipelinePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineAccessControlRequest{}.Type(ctx)}}, "pipeline_id": types.StringType, }, } @@ -4289,7 +4289,7 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, + "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}}, "configuration": basetypes.MapType{ElemType: types.StringType}, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, @@ -4299,9 +4299,9 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, + "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}}, "name": types.StringType, - "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, + "notifications": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Notifications{}.Type(ctx)}}, "photon": types.BoolType, "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, "schema": types.StringType, @@ -4638,7 +4638,7 @@ func (o PipelineStateInfo) Type(ctx context.Context) attr.Type { "cluster_id": types.StringType, "creator_user_name": types.StringType, "health": types.StringType, - "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, + "latest_updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}}, "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, @@ -5130,7 +5130,7 @@ func (o SerializedException) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "class_name": types.StringType, "message": types.StringType, - "stack": basetypes.ListType{ElemType: StackFrame{}.Type(ctx)}, + "stack": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StackFrame{}.Type(ctx)}}, }, } } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 30fede620c..5b3a6bce87 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -2658,7 +2658,7 @@ func (o Network) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, - "error_messages": basetypes.ListType{ElemType: NetworkHealth{}.Type(ctx)}, + "error_messages": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NetworkHealth{}.Type(ctx)}}, "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, "network_id": types.StringType, "network_name": types.StringType, @@ -2667,7 +2667,7 @@ func (o Network) Type(ctx context.Context) attr.Type { "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, "vpc_id": types.StringType, "vpc_status": types.StringType, - "warning_messages": basetypes.ListType{ElemType: NetworkWarning{}.Type(ctx)}, + "warning_messages": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NetworkWarning{}.Type(ctx)}}, "workspace_id": types.Int64Type, }, } diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 58da69e190..47f87b85e9 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -132,7 +132,7 @@ func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}}, "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } @@ -1286,9 +1286,9 @@ func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, "config": basetypes.ListType{ElemType: EndpointCoreConfigInput{}.Type(ctx)}, "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}}, "route_optimized": types.BoolType, - "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, }, } } @@ -1805,8 +1805,8 @@ func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigInput{}.Type(ctx)}, "name": types.StringType, - "served_entities": basetypes.ListType{ElemType: ServedEntityInput{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelInput{}.Type(ctx)}, + "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntityInput{}.Type(ctx)}}, + "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelInput{}.Type(ctx)}}, "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } @@ -1974,8 +1974,8 @@ func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, + "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}}, + "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}}, "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } @@ -2129,8 +2129,8 @@ func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) basetypes. func (o EndpointCoreConfigSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "served_entities": basetypes.ListType{ElemType: ServedEntitySpec{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelSpec{}.Type(ctx)}, + "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntitySpec{}.Type(ctx)}}, + "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelSpec{}.Type(ctx)}}, }, } } @@ -2250,8 +2250,8 @@ func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, + "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}}, + "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}}, "start_time": types.Int64Type, "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, @@ -3118,7 +3118,7 @@ func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetServingEndpointPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ServingEndpointPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointPermissionsDescription{}.Type(ctx)}}, }, } } @@ -3347,7 +3347,7 @@ func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListEndpointsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ElemType: ServingEndpoint{}.Type(ctx)}, + "endpoints": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpoint{}.Type(ctx)}}, }, } } @@ -3707,7 +3707,7 @@ func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) basetypes.O func (o PatchServingEndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add_tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "add_tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, "delete_tags": basetypes.ListType{ElemType: types.StringType}, "name": types.StringType, }, @@ -3880,7 +3880,7 @@ func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}}, "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } @@ -4048,7 +4048,7 @@ func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}}, "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } @@ -4203,7 +4203,7 @@ func (o PutRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}}, }, } } @@ -4273,7 +4273,7 @@ func (o PutResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PutResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}}, }, } } @@ -4415,7 +4415,7 @@ func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { "inputs": types.ObjectType{}, "instances": basetypes.ListType{ElemType: types.ObjectType{}}, "max_tokens": types.Int64Type, - "messages": basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}, + "messages": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}}, "n": types.Int64Type, "name": types.StringType, "prompt": types.ObjectType{}, @@ -4658,9 +4658,9 @@ func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "choices": basetypes.ListType{ElemType: V1ResponseChoiceElement{}.Type(ctx)}, + "choices": basetypes.ListType{ElemType: basetypes.ListType{ElemType: V1ResponseChoiceElement{}.Type(ctx)}}, "created": types.Int64Type, - "data": basetypes.ListType{ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx)}, + "data": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx)}}, "id": types.StringType, "model": types.StringType, "object": types.StringType, @@ -5928,7 +5928,7 @@ func (o ServingEndpoint) Type(ctx context.Context) attr.Type { "last_updated_timestamp": types.Int64Type, "name": types.StringType, "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, "task": types.StringType, }, } @@ -6143,7 +6143,7 @@ func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) func (o ServingEndpointAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ServingEndpointPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6280,7 +6280,7 @@ func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { "permission_level": types.StringType, "route_optimized": types.BoolType, "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, "task": types.StringType, }, } @@ -6563,7 +6563,7 @@ func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) basetypes func (o ServingEndpointPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -6682,7 +6682,7 @@ func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o ServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointAccessControlRequest{}.Type(ctx)}}, "serving_endpoint_id": types.StringType, }, } @@ -6753,7 +6753,7 @@ func (o TrafficConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o TrafficConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "routes": basetypes.ListType{ElemType: Route{}.Type(ctx)}, + "routes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Route{}.Type(ctx)}}, }, } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index c5d38a66b7..c70e5c4933 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -3501,8 +3501,8 @@ func (o EgressNetworkPolicyInternetAccessPolicy) ToObjectValue(ctx context.Conte func (o EgressNetworkPolicyInternetAccessPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_internet_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx)}, - "allowed_storage_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx)}, + "allowed_internet_destinations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx)}}, + "allowed_storage_destinations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx)}}, "log_only_mode": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx)}, "restriction_mode": types.StringType, }, @@ -4440,7 +4440,7 @@ func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExchangeTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ElemType: ExchangeToken{}.Type(ctx)}, + "values": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeToken{}.Type(ctx)}}, }, } } @@ -5338,7 +5338,7 @@ func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetIpAccessListsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_lists": basetypes.ListType{ElemType: basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}}, }, } } @@ -5723,7 +5723,7 @@ func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) bas func (o GetTokenPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: TokenPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenPermissionsDescription{}.Type(ctx)}}, }, } } @@ -5975,7 +5975,7 @@ func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_lists": basetypes.ListType{ElemType: basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}}, }, } } @@ -6048,7 +6048,7 @@ func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Cont func (o ListNccAzurePrivateEndpointRulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, + "items": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -6165,7 +6165,7 @@ func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context func (o ListNetworkConnectivityConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: NetworkConnectivityConfiguration{}.Type(ctx)}, + "items": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NetworkConnectivityConfiguration{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -6286,7 +6286,7 @@ func (o ListNotificationDestinationsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: ListNotificationDestinationsResult{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListNotificationDestinationsResult{}.Type(ctx)}}, }, } } @@ -6454,7 +6454,7 @@ func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListPublicTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}, + "token_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}}, }, } } @@ -6572,7 +6572,7 @@ func (o ListTokensResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, + "token_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}}, }, } } @@ -7178,7 +7178,7 @@ func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) basetypes.Objec func (o NccEgressTargetRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "azure_private_endpoint_rules": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, + "azure_private_endpoint_rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}}, }, } } @@ -8238,7 +8238,7 @@ func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) basetypes func (o TokenAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: TokenPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -8470,7 +8470,7 @@ func (o TokenPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o TokenPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: TokenAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -8586,7 +8586,7 @@ func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o TokenPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: TokenAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenAccessControlRequest{}.Type(ctx)}}, }, } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index fa69b5ac8b..fea8d95037 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -635,7 +635,7 @@ func (o GetRecipientSharePermissionsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "permissions_out": basetypes.ListType{ElemType: ShareToPrivilegeAssignment{}.Type(ctx)}, + "permissions_out": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ShareToPrivilegeAssignment{}.Type(ctx)}}, }, } } @@ -828,7 +828,7 @@ func (o ListProviderSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ElemType: ProviderShare{}.Type(ctx)}, + "shares": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderShare{}.Type(ctx)}}, }, } } @@ -964,7 +964,7 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "providers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}}, }, } } @@ -1100,7 +1100,7 @@ func (o ListRecipientsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "recipients": basetypes.ListType{ElemType: RecipientInfo{}.Type(ctx)}, + "recipients": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RecipientInfo{}.Type(ctx)}}, }, } } @@ -1235,7 +1235,7 @@ func (o ListSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, + "shares": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}}, }, } } @@ -1305,7 +1305,7 @@ func (o Partition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Partition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, + "value": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}}, }, } } @@ -1375,7 +1375,7 @@ func (o PartitionSpecificationPartition) ToObjectValue(ctx context.Context) base func (o PartitionSpecificationPartition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, + "value": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}}, }, } } @@ -1825,7 +1825,7 @@ func (o RecipientInfo) Type(ctx context.Context) attr.Type { "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, "region": types.StringType, "sharing_code": types.StringType, - "tokens": basetypes.ListType{ElemType: RecipientTokenInfo{}.Type(ctx)}, + "tokens": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RecipientTokenInfo{}.Type(ctx)}}, "updated_at": types.Int64Type, "updated_by": types.StringType, }, @@ -2315,7 +2315,7 @@ func (o ShareInfo) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "created_by": types.StringType, "name": types.StringType, - "object": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, + "object": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}}, "owner": types.StringType, "storage_location": types.StringType, "storage_root": types.StringType, @@ -2452,7 +2452,7 @@ func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes func (o ShareToPrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, + "privilege_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}}, "share_name": types.StringType, }, } @@ -2622,7 +2622,7 @@ func (o SharedDataObject) Type(ctx context.Context) attr.Type { "history_data_sharing_status": types.StringType, "effective_history_data_sharing_status": types.StringType, "name": types.StringType, - "partition": basetypes.ListType{ElemType: Partition{}.Type(ctx)}, + "partition": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Partition{}.Type(ctx)}}, "shared_as": types.StringType, "effective_shared_as": types.StringType, "start_version": types.Int64Type, @@ -3047,7 +3047,7 @@ func (o UpdateShare) Type(ctx context.Context) attr.Type { "new_name": types.StringType, "owner": types.StringType, "storage_root": types.StringType, - "updates": basetypes.ListType{ElemType: SharedDataObjectUpdate{}.Type(ctx)}, + "updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SharedDataObjectUpdate{}.Type(ctx)}}, }, } } @@ -3134,7 +3134,7 @@ func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateSharePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: catalog_tf.PermissionsChange{}.Type(ctx)}, + "changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.PermissionsChange{}.Type(ctx)}}, "max_results": types.Int64Type, "name": types.StringType, "page_token": types.StringType, diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 1490896a65..a48f72f7d9 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -1493,7 +1493,7 @@ func (o CreateQueryRequestQuery) Type(ctx context.Context) attr.Type { "catalog": types.StringType, "description": types.StringType, "display_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, "parent_path": types.StringType, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -2182,7 +2182,7 @@ func (o Dashboard) Type(ctx context.Context) attr.Type { "updated_at": types.StringType, "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, "user_id": types.Int64Type, - "widgets": basetypes.ListType{ElemType: Widget{}.Type(ctx)}, + "widgets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Widget{}.Type(ctx)}}, }, } } @@ -3962,7 +3962,7 @@ func (o EndpointTags) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "custom_tags": basetypes.ListType{ElemType: EndpointTagPair{}.Type(ctx)}, + "custom_tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTagPair{}.Type(ctx)}}, }, } } @@ -4273,7 +4273,7 @@ func (o ExecuteStatementRequest) Type(ctx context.Context) attr.Type { "disposition": types.StringType, "format": types.StringType, "on_wait_timeout": types.StringType, - "parameters": basetypes.ListType{ElemType: StatementParameterListItem{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StatementParameterListItem{}.Type(ctx)}}, "row_limit": types.Int64Type, "schema": types.StringType, "statement": types.StringType, @@ -4724,7 +4724,7 @@ func (o GetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4930,7 +4930,7 @@ func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetWarehousePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: WarehousePermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehousePermissionsDescription{}.Type(ctx)}}, }, } } @@ -5385,8 +5385,8 @@ func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, - "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, + "data_access_config": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, + "enabled_warehouse_types": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}}, "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, @@ -5875,7 +5875,7 @@ func (o LegacyQuery) Type(ctx context.Context) attr.Type { "updated_at": types.StringType, "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, "user_id": types.Int64Type, - "visualizations": basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}, + "visualizations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}}, }, } } @@ -6204,7 +6204,7 @@ func (o ListAlertsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: ListAlertsResponseAlert{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListAlertsResponseAlert{}.Type(ctx)}}, }, } } @@ -6586,7 +6586,7 @@ func (o ListQueriesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "has_next_page": types.BoolType, "next_page_token": types.StringType, - "res": basetypes.ListType{ElemType: QueryInfo{}.Type(ctx)}, + "res": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryInfo{}.Type(ctx)}}, }, } } @@ -6747,7 +6747,7 @@ func (o ListQueryObjectsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: ListQueryObjectsResponseQuery{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListQueryObjectsResponseQuery{}.Type(ctx)}}, }, } } @@ -6874,7 +6874,7 @@ func (o ListQueryObjectsResponseQuery) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, "query_text": types.StringType, "run_as_mode": types.StringType, "schema": types.StringType, @@ -6988,7 +6988,7 @@ func (o ListResponse) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}}, }, } } @@ -7111,7 +7111,7 @@ func (o ListVisualizationsForQueryResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: Visualization{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Visualization{}.Type(ctx)}}, }, } } @@ -7225,7 +7225,7 @@ func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListWarehousesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "warehouses": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, + "warehouses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}}, }, } } @@ -7598,7 +7598,7 @@ func (o Query) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, "parent_path": types.StringType, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -8306,7 +8306,7 @@ func (o QueryList) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}, + "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}}, }, } } @@ -8529,7 +8529,7 @@ func (o QueryOptions) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "catalog": types.StringType, "moved_to_trash_at": types.StringType, - "parameters": basetypes.ListType{ElemType: Parameter{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Parameter{}.Type(ctx)}}, "schema": types.StringType, }, } @@ -8947,8 +8947,8 @@ func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) basetypes. func (o RepeatedEndpointConfPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config_pair": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, - "configuration_pairs": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "config_pair": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, + "configuration_pairs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, }, } } @@ -9197,7 +9197,7 @@ func (o ResultData) Type(ctx context.Context) attr.Type { "byte_count": types.Int64Type, "chunk_index": types.Int64Type, "data_array": basetypes.ListType{ElemType: basetypes.ListType{ElemType: types.StringType}}, - "external_links": basetypes.ListType{ElemType: ExternalLink{}.Type(ctx)}, + "external_links": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExternalLink{}.Type(ctx)}}, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, "row_count": types.Int64Type, @@ -9319,7 +9319,7 @@ func (o ResultManifest) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "chunks": basetypes.ListType{ElemType: BaseChunkInfo{}.Type(ctx)}, + "chunks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BaseChunkInfo{}.Type(ctx)}}, "format": types.StringType, "schema": basetypes.ListType{ElemType: ResultSchema{}.Type(ctx)}, "total_byte_count": types.Int64Type, @@ -9425,7 +9425,7 @@ func (o ResultSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}}, }, } } @@ -9547,7 +9547,7 @@ func (o SetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}}, "objectId": types.StringType, "objectType": types.StringType, }, @@ -9624,7 +9624,7 @@ func (o SetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -9734,8 +9734,8 @@ func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, - "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, + "data_access_config": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, + "enabled_warehouse_types": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}}, "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, @@ -11128,7 +11128,7 @@ func (o UpdateQueryRequestQuery) Type(ctx context.Context) attr.Type { "description": types.StringType, "display_name": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, + "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, "query_text": types.StringType, "run_as_mode": types.StringType, "schema": types.StringType, @@ -11592,7 +11592,7 @@ func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) baset func (o WarehouseAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: WarehousePermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehousePermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -11748,7 +11748,7 @@ func (o WarehousePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WarehousePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -11867,7 +11867,7 @@ func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) basetype func (o WarehousePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseAccessControlRequest{}.Type(ctx)}}, "warehouse_id": types.StringType, }, } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 390cf5883b..c917298c7b 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -757,8 +757,8 @@ func (o DeltaSyncVectorIndexSpecRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns_to_sync": basetypes.ListType{ElemType: types.StringType}, - "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, - "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, + "embedding_source_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}}, + "embedding_vector_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}}, "embedding_writeback_table": types.StringType, "pipeline_type": types.StringType, "source_table": types.StringType, @@ -907,8 +907,8 @@ func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) bas func (o DeltaSyncVectorIndexSpecResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, - "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, + "embedding_source_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}}, + "embedding_vector_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}}, "embedding_writeback_table": types.StringType, "pipeline_id": types.StringType, "pipeline_type": types.StringType, @@ -1020,8 +1020,8 @@ func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) basetype func (o DirectAccessVectorIndexSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, - "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, + "embedding_source_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}}, + "embedding_vector_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}}, "schema_json": types.StringType, }, } @@ -1449,7 +1449,7 @@ func (o ListEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, + "endpoints": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}}, "next_page_token": types.StringType, }, } @@ -1609,7 +1609,7 @@ func (o ListValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ElemType: Value{}.Type(ctx)}, + "values": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Value{}.Type(ctx)}}, }, } } @@ -1684,7 +1684,7 @@ func (o ListVectorIndexesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "vector_indexes": basetypes.ListType{ElemType: MiniVectorIndex{}.Type(ctx)}, + "vector_indexes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MiniVectorIndex{}.Type(ctx)}}, }, } } @@ -2263,7 +2263,7 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}}, }, } } @@ -2388,7 +2388,7 @@ func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ScanVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data": basetypes.ListType{ElemType: Struct{}.Type(ctx)}, + "data": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Struct{}.Type(ctx)}}, "last_primary_key": types.StringType, }, } @@ -2459,7 +2459,7 @@ func (o Struct) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Struct) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fields": basetypes.ListType{ElemType: MapStringValueEntry{}.Type(ctx)}, + "fields": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MapStringValueEntry{}.Type(ctx)}}, }, } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index e3b4c1b747..401059a9fa 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -1398,7 +1398,7 @@ func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) base func (o GetRepoPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: RepoPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoPermissionsDescription{}.Type(ctx)}}, }, } } @@ -1831,7 +1831,7 @@ func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetWorkspaceObjectPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx)}}, }, } } @@ -2105,7 +2105,7 @@ func (o ListAclsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAclsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: AclItem{}.Type(ctx)}, + "items": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AclItem{}.Type(ctx)}}, }, } } @@ -2175,7 +2175,7 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, + "credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}}, }, } } @@ -2301,7 +2301,7 @@ func (o ListReposResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "repos": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, + "repos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}}, }, } } @@ -2371,7 +2371,7 @@ func (o ListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "objects": basetypes.ListType{ElemType: ObjectInfo{}.Type(ctx)}, + "objects": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ObjectInfo{}.Type(ctx)}}, }, } } @@ -2441,7 +2441,7 @@ func (o ListScopesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListScopesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scopes": basetypes.ListType{ElemType: SecretScope{}.Type(ctx)}, + "scopes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SecretScope{}.Type(ctx)}}, }, } } @@ -2554,7 +2554,7 @@ func (o ListSecretsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o ListSecretsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "secrets": basetypes.ListType{ElemType: SecretMetadata{}.Type(ctx)}, + "secrets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SecretMetadata{}.Type(ctx)}}, }, } } @@ -3069,7 +3069,7 @@ func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) basetypes. func (o RepoAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: RepoPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3320,7 +3320,7 @@ func (o RepoPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RepoPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RepoAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3439,7 +3439,7 @@ func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o RepoPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RepoAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoAccessControlRequest{}.Type(ctx)}}, "repo_id": types.StringType, }, } @@ -4073,7 +4073,7 @@ func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) func (o WorkspaceObjectAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: WorkspaceObjectPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectPermission{}.Type(ctx)}}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -4229,7 +4229,7 @@ func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) basetypes func (o WorkspaceObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx)}}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4351,7 +4351,7 @@ func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o WorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx)}}, "workspace_object_id": types.StringType, "workspace_object_type": types.StringType, }, From d16ec817ff81ae885876ac52c74cc036a391ad86 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 19:34:12 +0100 Subject: [PATCH 72/91] fixes --- .../pluginfw/tfschema/customizable_schema.go | 2 ++ .../tfschema/customizable_schema_test.go | 22 +++++++++++++++++++ .../tfschema/list_nested_attribute.go | 1 + .../tfschema/nested_attribute_object.go | 6 +++++ 4 files changed, 31 insertions(+) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index b7051b4502..b2837371a5 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -61,6 +61,8 @@ func (s *CustomizableSchema) AddValidator(v any, path ...string) *CustomizableSc return a.AddValidator(v.(validator.List)) case ListNestedAttributeBuilder: return a.AddValidator(v.(validator.List)) + case ListNestedBlockBuilder: + return a.AddValidator(v.(validator.List)) case MapAttributeBuilder: return a.AddValidator(v.(validator.Map)) case MapNestedAttributeBuilder: diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 6de3c00021..0b6fc49ebd 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -115,6 +115,28 @@ func TestCustomizeSchemaSetReadOnly(t *testing.T) { assert.True(t, scm.Attributes["map"].IsComputed()) } +type testTfSdkListNestedAttribute struct { + List types.List `tfsdk:"list"` +} + +func (testTfSdkListNestedAttribute) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "list": reflect.TypeOf(NestedTfSdk{}), + } +} + +func TestCustomizeSchemaSetReadOnly_RecursivelySetsFieldsOfListNestedAttributes(t *testing.T) { + scm := ResourceStructToSchema(context.Background(), testTfSdkListNestedAttribute{}, func(c CustomizableSchema) CustomizableSchema { + c.ConvertToAttribute("list").SetReadOnly("list") + return c + }) + for _, field := range []string{"name", "enabled"} { + assert.True(t, !scm.Attributes["list"].(schema.ListNestedAttribute).NestedObject.Attributes[field].IsOptional()) + assert.True(t, !scm.Attributes["list"].(schema.ListNestedAttribute).NestedObject.Attributes[field].IsRequired()) + assert.True(t, scm.Attributes["list"].(schema.ListNestedAttribute).NestedObject.Attributes[field].IsComputed()) + } +} + func TestCustomizeSchemaAddValidator(t *testing.T) { scm := ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { c.AddValidator(stringLengthBetweenValidator{}, "description") diff --git a/internal/providers/pluginfw/tfschema/list_nested_attribute.go b/internal/providers/pluginfw/tfschema/list_nested_attribute.go index 9cd882990c..adc97a7ed8 100644 --- a/internal/providers/pluginfw/tfschema/list_nested_attribute.go +++ b/internal/providers/pluginfw/tfschema/list_nested_attribute.go @@ -85,6 +85,7 @@ func (a ListNestedAttributeBuilder) SetReadOnly() AttributeBuilder { a.Computed = true a.Optional = false a.Required = false + a.NestedObject.SetReadOnly() return a } diff --git a/internal/providers/pluginfw/tfschema/nested_attribute_object.go b/internal/providers/pluginfw/tfschema/nested_attribute_object.go index bf9f639231..f12702f7b9 100644 --- a/internal/providers/pluginfw/tfschema/nested_attribute_object.go +++ b/internal/providers/pluginfw/tfschema/nested_attribute_object.go @@ -25,3 +25,9 @@ func (a NestedAttributeObject) BuildResourceAttribute() schema.NestedAttributeOb Attributes: resourceAttributes, } } + +func (a NestedAttributeObject) SetReadOnly() { + for attr, attrV := range a.Attributes { + a.Attributes[attr] = attrV.SetReadOnly() + } +} From 7c539b83d9bef2c5ea06b2deee5ee44c0cd1b4a3 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 19:46:09 +0100 Subject: [PATCH 73/91] some work --- internal/providers/pluginfw/products/catalog/data_functions.go | 2 +- internal/providers/pluginfw/products/cluster/data_cluster.go | 2 +- .../providers/pluginfw/products/library/resource_library.go | 1 + .../products/qualitymonitor/resource_quality_monitor.go | 1 + .../pluginfw/products/registered_model/data_registered_model.go | 2 +- .../pluginfw/products/serving/data_serving_endpoints.go | 2 +- internal/providers/pluginfw/products/sharing/data_shares.go | 2 +- internal/providers/pluginfw/products/sharing/resource_share.go | 1 + internal/providers/pluginfw/products/volume/data_volumes.go | 2 +- 9 files changed, 9 insertions(+), 6 deletions(-) diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index 5c0ca3bead..f0845fb186 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -35,7 +35,7 @@ type FunctionsData struct { CatalogName types.String `tfsdk:"catalog_name"` SchemaName types.String `tfsdk:"schema_name"` IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` - Functions types.List `tfsdk:"functions" tf:"optional,computed"` + Functions types.List `tfsdk:"functions" tf:"readonly"` } func (FunctionsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index ffcf6a70dd..d7800ef650 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -36,7 +36,7 @@ type ClusterDataSource struct { type ClusterInfo struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional,computed"` Name types.String `tfsdk:"cluster_name" tf:"optional,computed"` - ClusterInfo types.List `tfsdk:"cluster_info" tf:"optional,computed"` + ClusterInfo types.List `tfsdk:"cluster_info" tf:"readonly"` } func (ClusterInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/library/resource_library.go b/internal/providers/pluginfw/products/library/resource_library.go index 178687495d..ba74429279 100644 --- a/internal/providers/pluginfw/products/library/resource_library.go +++ b/internal/providers/pluginfw/products/library/resource_library.go @@ -88,6 +88,7 @@ func (r *LibraryResource) Metadata(ctx context.Context, req resource.MetadataReq func (r *LibraryResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, LibraryExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + c.ConfigureForSdkV2Migration() for field, attribute := range c.ToNestedBlockObject().Attributes { switch attribute.(type) { case tfschema.StringAttributeBuilder: diff --git a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go index 00e04a3bd8..d4e0248f65 100644 --- a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go +++ b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go @@ -78,6 +78,7 @@ func (r *QualityMonitorResource) Metadata(ctx context.Context, req resource.Meta func (r *QualityMonitorResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, MonitorInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetRequired("assets_dir") c.SetRequired("output_schema_name") c.SetReadOnly("monitor_version") diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index 912f5b6060..eca91989d8 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -37,7 +37,7 @@ type RegisteredModelData struct { FullName types.String `tfsdk:"full_name"` IncludeAliases types.Bool `tfsdk:"include_aliases" tf:"optional"` IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` - ModelInfo types.List `tfsdk:"model_info" tf:"optional,computed"` + ModelInfo types.List `tfsdk:"model_info" tf:"readonly"` } func (RegisteredModelData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go index 51c5e2c64b..9acd3bdaab 100644 --- a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go +++ b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go @@ -27,7 +27,7 @@ type ServingEndpointsDataSource struct { } type ServingEndpointsData struct { - Endpoints types.List `tfsdk:"endpoints" tf:"optional,computed"` + Endpoints types.List `tfsdk:"endpoints" tf:"readonly"` } func (ServingEndpointsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/sharing/data_shares.go b/internal/providers/pluginfw/products/sharing/data_shares.go index 457ba8633d..32ff7c71ea 100644 --- a/internal/providers/pluginfw/products/sharing/data_shares.go +++ b/internal/providers/pluginfw/products/sharing/data_shares.go @@ -18,7 +18,7 @@ import ( const dataSourceNameShares = "shares" type SharesList struct { - Shares types.List `tfsdk:"shares" tf:"computed,optional,slice_set"` + Shares types.List `tfsdk:"shares" tf:"readonly,slice_set"` } func (SharesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index 39d1cf2cb4..61219eda84 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -145,6 +145,7 @@ func (r *ShareResource) Metadata(ctx context.Context, req resource.MetadataReque func (r *ShareResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, ShareInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + c.ConfigureForSdkV2Migration() c.SetRequired("name") c.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") // ForceNew diff --git a/internal/providers/pluginfw/products/volume/data_volumes.go b/internal/providers/pluginfw/products/volume/data_volumes.go index 6727dc20cb..61df9ca56e 100644 --- a/internal/providers/pluginfw/products/volume/data_volumes.go +++ b/internal/providers/pluginfw/products/volume/data_volumes.go @@ -33,7 +33,7 @@ type VolumesDataSource struct { type VolumesList struct { CatalogName types.String `tfsdk:"catalog_name"` SchemaName types.String `tfsdk:"schema_name"` - Ids types.List `tfsdk:"ids" tf:"optional,computed"` + Ids types.List `tfsdk:"ids" tf:"readonly"` } func (VolumesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type { From e282b55bb84ebbb5567faf79df7c0514112af653 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 20:00:53 +0100 Subject: [PATCH 74/91] work --- .../tfschema/customizable_schema_test.go | 2 +- internal/service/billing_tf/model.go | 16 +-- internal/service/catalog_tf/model.go | 74 +++++++------- internal/service/cleanrooms_tf/model.go | 16 +-- internal/service/compute_tf/model.go | 86 ++++++++-------- internal/service/dashboards_tf/model.go | 10 +- internal/service/files_tf/model.go | 4 +- internal/service/iam_tf/model.go | 56 +++++------ internal/service/jobs_tf/model.go | 98 +++++++++---------- internal/service/marketplace_tf/model.go | 46 ++++----- internal/service/ml_tf/model.go | 78 +++++++-------- internal/service/oauth2_tf/model.go | 8 +- internal/service/pipelines_tf/model.go | 44 ++++----- internal/service/provisioning_tf/model.go | 4 +- internal/service/serving_tf/model.go | 54 +++++----- internal/service/settings_tf/model.go | 30 +++--- internal/service/sharing_tf/model.go | 26 ++--- internal/service/sql_tf/model.go | 64 ++++++------ internal/service/vectorsearch_tf/model.go | 24 ++--- internal/service/workspace_tf/model.go | 28 +++--- 20 files changed, 384 insertions(+), 384 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 50102704b0..12d8f44ade 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -127,7 +127,7 @@ func (testTfSdkListNestedAttribute) GetComplexFieldTypes(context.Context) map[st func TestCustomizeSchemaSetReadOnly_RecursivelySetsFieldsOfListNestedAttributes(t *testing.T) { scm := ResourceStructToSchema(context.Background(), testTfSdkListNestedAttribute{}, func(c CustomizableSchema) CustomizableSchema { - c.ConvertToAttribute("list").SetReadOnly("list") + c.SetReadOnly("list") return c }) for _, field := range []string{"name", "enabled"} { diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 7dfbc275b4..8d76cda34a 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -129,7 +129,7 @@ func (o AlertConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o AlertConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ActionConfiguration{}.Type(ctx)}}, + "action_configurations": basetypes.ListType{ElemType: ActionConfiguration{}.Type(ctx)}, "alert_configuration_id": types.StringType, "quantity_threshold": types.StringType, "quantity_type": types.StringType, @@ -228,7 +228,7 @@ func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}}, + "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, @@ -335,7 +335,7 @@ func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) basetypes. func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx)}, "workspace_id": basetypes.ListType{ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx)}, }, } @@ -757,7 +757,7 @@ func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx)}}, + "alert_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx)}, "display_name": types.StringType, "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, }, @@ -917,7 +917,7 @@ func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx co func (o CreateBudgetConfigurationBudgetAlertConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx)}}, + "action_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx)}, "quantity_threshold": types.StringType, "quantity_type": types.StringType, "time_period": types.StringType, @@ -1758,7 +1758,7 @@ func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) bas func (o ListBudgetConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budgets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}}, + "budgets": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2202,7 +2202,7 @@ func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}}, + "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, "budget_configuration_id": types.StringType, "display_name": types.StringType, "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, @@ -2633,7 +2633,7 @@ func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) bas func (o WrappedLogDeliveryConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configurations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}}, + "log_delivery_configurations": basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}, }, } } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 8d141d4a98..0a29009bcb 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -723,7 +723,7 @@ func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o ArtifactAllowlistInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}}, + "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, "created_at": types.Int64Type, "created_by": types.StringType, "metastore_id": types.StringType, @@ -3233,7 +3233,7 @@ func (o CreateMonitor) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}}, + "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, @@ -5746,7 +5746,7 @@ func (o DependencyList) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o DependencyList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dependencies": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Dependency{}.Type(ctx)}}, + "dependencies": basetypes.ListType{ElemType: Dependency{}.Type(ctx)}, }, } } @@ -5900,7 +5900,7 @@ func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) basetypes.O func (o EffectivePermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EffectivePrivilegeAssignment{}.Type(ctx)}}, + "privilege_assignments": basetypes.ListType{ElemType: EffectivePrivilegeAssignment{}.Type(ctx)}, }, } } @@ -6082,7 +6082,7 @@ func (o EffectivePrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "principal": types.StringType, - "privileges": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EffectivePrivilege{}.Type(ctx)}}, + "privileges": basetypes.ListType{ElemType: EffectivePrivilege{}.Type(ctx)}, }, } } @@ -7028,7 +7028,7 @@ func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) basetypes.Obj func (o FunctionParameterInfos) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FunctionParameterInfo{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: FunctionParameterInfo{}.Type(ctx)}, }, } } @@ -9145,7 +9145,7 @@ func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context func (o ListAccountStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "storage_credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}}, + "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, }, } } @@ -9280,7 +9280,7 @@ func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListCatalogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalogs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CatalogInfo{}.Type(ctx)}}, + "catalogs": basetypes.ListType{ElemType: CatalogInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9408,7 +9408,7 @@ func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListConnectionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "connections": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ConnectionInfo{}.Type(ctx)}}, + "connections": basetypes.ListType{ElemType: ConnectionInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9538,7 +9538,7 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}}, + "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9671,7 +9671,7 @@ func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) basety func (o ListExternalLocationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "external_locations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExternalLocationInfo{}.Type(ctx)}}, + "external_locations": basetypes.ListType{ElemType: ExternalLocationInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9812,7 +9812,7 @@ func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListFunctionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "functions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FunctionInfo{}.Type(ctx)}}, + "functions": basetypes.ListType{ElemType: FunctionInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -9883,7 +9883,7 @@ func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListMetastoresResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastores": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}}, + "metastores": basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}, }, } } @@ -10020,7 +10020,7 @@ func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionInfo{}.Type(ctx)}}, + "model_versions": basetypes.ListType{ElemType: ModelVersionInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -10144,7 +10144,7 @@ func (o ListQuotasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "quotas": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}}, + "quotas": basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}, }, } } @@ -10340,7 +10340,7 @@ func (o ListRegisteredModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelInfo{}.Type(ctx)}}, + "registered_models": basetypes.ListType{ElemType: RegisteredModelInfo{}.Type(ctx)}, }, } } @@ -10477,7 +10477,7 @@ func (o ListSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SchemaInfo{}.Type(ctx)}}, + "schemas": basetypes.ListType{ElemType: SchemaInfo{}.Type(ctx)}, }, } } @@ -10605,7 +10605,7 @@ func (o ListStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "storage_credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}}, + "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, }, } } @@ -10808,7 +10808,7 @@ func (o ListSystemSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SystemSchemaInfo{}.Type(ctx)}}, + "schemas": basetypes.ListType{ElemType: SystemSchemaInfo{}.Type(ctx)}, }, } } @@ -10884,7 +10884,7 @@ func (o ListTableSummariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TableSummary{}.Type(ctx)}}, + "tables": basetypes.ListType{ElemType: TableSummary{}.Type(ctx)}, }, } } @@ -11046,7 +11046,7 @@ func (o ListTablesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TableInfo{}.Type(ctx)}}, + "tables": basetypes.ListType{ElemType: TableInfo{}.Type(ctx)}, }, } } @@ -11194,7 +11194,7 @@ func (o ListVolumesResponseContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "volumes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: VolumeInfo{}.Type(ctx)}}, + "volumes": basetypes.ListType{ElemType: VolumeInfo{}.Type(ctx)}, }, } } @@ -11499,7 +11499,7 @@ func (o ModelVersionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}}, + "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -11960,7 +11960,7 @@ func (o MonitorInfo) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "assets_dir": types.StringType, "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}}, + "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "drift_metrics_table_name": types.StringType, @@ -12494,7 +12494,7 @@ func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) basetypes func (o MonitorRefreshListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "refreshes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorRefreshInfo{}.Type(ctx)}}, + "refreshes": basetypes.ListType{ElemType: MonitorRefreshInfo{}.Type(ctx)}, }, } } @@ -13353,7 +13353,7 @@ func (o PermissionsList) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}}, + "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, }, } } @@ -14094,7 +14094,7 @@ func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) basetypes.Object func (o RegisteredModelInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}}, + "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -14391,7 +14391,7 @@ func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) basetypes.Objec func (o SetArtifactAllowlist) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}}, + "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, "artifact_type": types.StringType, }, } @@ -15190,7 +15190,7 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "access_point": types.StringType, "browse_only": types.BoolType, "catalog_name": types.StringType, - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, @@ -15212,7 +15212,7 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "sql_path": types.StringType, "storage_credential_name": types.StringType, "storage_location": types.StringType, - "table_constraints": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}}, + "table_constraints": basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}, "table_id": types.StringType, "table_type": types.StringType, "updated_at": types.Int64Type, @@ -16676,7 +16676,7 @@ func (o UpdateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}}, + "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, @@ -16944,7 +16944,7 @@ func (o UpdatePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdatePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionsChange{}.Type(ctx)}}, + "changes": basetypes.ListType{ElemType: PermissionsChange{}.Type(ctx)}, "full_name": types.StringType, "securable_type": types.StringType, }, @@ -17641,8 +17641,8 @@ func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) ba func (o UpdateWorkspaceBindingsParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}}, - "remove": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}}, + "add": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, + "remove": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, "securable_name": types.StringType, "securable_type": types.StringType, }, @@ -17871,7 +17871,7 @@ func (o ValidateCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CredentialValidationResult{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: CredentialValidationResult{}.Type(ctx)}, }, } } @@ -18155,7 +18155,7 @@ func (o ValidateStorageCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "isDir": types.BoolType, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ValidationResult{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: ValidationResult{}.Type(ctx)}, }, } } @@ -18462,7 +18462,7 @@ func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) basetypes. func (o WorkspaceBindingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "bindings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}}, + "bindings": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, "next_page_token": types.StringType, }, } diff --git a/internal/service/cleanrooms_tf/model.go b/internal/service/cleanrooms_tf/model.go index fe9886fafc..fda64ded2b 100755 --- a/internal/service/cleanrooms_tf/model.go +++ b/internal/service/cleanrooms_tf/model.go @@ -529,7 +529,7 @@ func (o CleanRoomAssetForeignTable) ToObjectValue(ctx context.Context) basetypes func (o CleanRoomAssetForeignTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, }, } } @@ -689,7 +689,7 @@ func (o CleanRoomAssetTable) ToObjectValue(ctx context.Context) basetypes.Object func (o CleanRoomAssetTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, }, } } @@ -764,7 +764,7 @@ func (o CleanRoomAssetTableLocalDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "local_name": types.StringType, - "partitions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx)}}, + "partitions": basetypes.ListType{ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx)}, }, } } @@ -834,7 +834,7 @@ func (o CleanRoomAssetView) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CleanRoomAssetView) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, }, } } @@ -1277,7 +1277,7 @@ func (o CleanRoomRemoteDetail) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "central_clean_room_id": types.StringType, "cloud_vendor": types.StringType, - "collaborators": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}}, + "collaborators": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, "compliance_security_profile": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, "creator": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, "egress_network_policy": basetypes.ListType{ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx)}, @@ -2168,7 +2168,7 @@ func (o ListCleanRoomAssetsResponse) ToObjectValue(ctx context.Context) basetype func (o ListCleanRoomAssetsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}}, + "assets": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2300,7 +2300,7 @@ func (o ListCleanRoomNotebookTaskRunsResponse) Type(ctx context.Context) attr.Ty return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoomNotebookTaskRun{}.Type(ctx)}}, + "runs": basetypes.ListType{ElemType: CleanRoomNotebookTaskRun{}.Type(ctx)}, }, } } @@ -2422,7 +2422,7 @@ func (o ListCleanRoomsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListCleanRoomsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_rooms": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}}, + "clean_rooms": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, "next_page_token": types.StringType, }, } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 07050ff7d4..4c000e2c98 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -889,7 +889,7 @@ func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) basetyp func (o ClusterAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: ClusterPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -1137,7 +1137,7 @@ func (o ClusterAttributes) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "policy_id": types.StringType, @@ -1852,9 +1852,9 @@ func (o ClusterDetails) Type(ctx context.Context) attr.Type { "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "executors": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}}, + "executors": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "jdbc_port": types.Int64Type, "last_restarted_time": types.Int64Type, @@ -2506,7 +2506,7 @@ func (o ClusterLibraryStatuses) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "library_statuses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LibraryFullStatus{}.Type(ctx)}}, + "library_statuses": basetypes.ListType{ElemType: LibraryFullStatus{}.Type(ctx)}, }, } } @@ -2764,7 +2764,7 @@ func (o ClusterPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ClusterPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -2883,7 +2883,7 @@ func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) basetypes. func (o ClusterPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlRequest{}.Type(ctx)}, "cluster_id": types.StringType, }, } @@ -3020,7 +3020,7 @@ func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) b func (o ClusterPolicyAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: ClusterPolicyPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3176,7 +3176,7 @@ func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) basetypes.O func (o ClusterPolicyPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3295,7 +3295,7 @@ func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) base func (o ClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx)}, "cluster_policy_id": types.StringType, }, } @@ -3708,7 +3708,7 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, @@ -4595,7 +4595,7 @@ func (o CreateCluster) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, @@ -5156,7 +5156,7 @@ func (o CreateInstancePool) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}}, + "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, }, } @@ -5464,7 +5464,7 @@ func (o CreatePolicy) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -6628,7 +6628,7 @@ func (o EditCluster) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, @@ -7220,7 +7220,7 @@ func (o EditPolicy) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "definition": types.StringType, "description": types.StringType, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -7419,7 +7419,7 @@ func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) bas func (o EnforceClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterSettingsChange{}.Type(ctx)}}, + "changes": basetypes.ListType{ElemType: ClusterSettingsChange{}.Type(ctx)}, "has_changes": types.BoolType, }, } @@ -8152,7 +8152,7 @@ func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) b func (o GetClusterPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: ClusterPermissionsDescription{}.Type(ctx)}, }, } } @@ -8308,7 +8308,7 @@ func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Cont func (o GetClusterPolicyPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx)}, }, } } @@ -8616,7 +8616,7 @@ func (o GetEventsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o GetEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterEvent{}.Type(ctx)}}, + "events": basetypes.ListType{ElemType: ClusterEvent{}.Type(ctx)}, "next_page": basetypes.ListType{ElemType: GetEvents{}.Type(ctx)}, "total_count": types.Int64Type, }, @@ -8867,7 +8867,7 @@ func (o GetInstancePool) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}}, + "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, "state": types.StringType, "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, @@ -9218,7 +9218,7 @@ func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Conte func (o GetInstancePoolPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: InstancePoolPermissionsDescription{}.Type(ctx)}, }, } } @@ -9422,7 +9422,7 @@ func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetSparkVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SparkVersion{}.Type(ctx)}}, + "versions": basetypes.ListType{ElemType: SparkVersion{}.Type(ctx)}, }, } } @@ -9782,8 +9782,8 @@ func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) basetypes.Obj func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}}, - "global": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}}, + "cluster": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, + "global": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, "reported_for_node": types.StringType, }, } @@ -10302,7 +10302,7 @@ func (o InstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, }, } } @@ -10474,7 +10474,7 @@ func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) ba func (o InstancePoolAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: InstancePoolPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -10658,7 +10658,7 @@ func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}}, + "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, "state": types.StringType, "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, @@ -11243,7 +11243,7 @@ func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) basetypes.Ob func (o InstancePoolPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -11362,7 +11362,7 @@ func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) baset func (o InstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlRequest{}.Type(ctx)}, "instance_pool_id": types.StringType, }, } @@ -11490,7 +11490,7 @@ func (o InstancePoolStatus) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o InstancePoolStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "pending_instance_errors": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PendingInstanceError{}.Type(ctx)}}, + "pending_instance_errors": basetypes.ListType{ElemType: PendingInstanceError{}.Type(ctx)}, }, } } @@ -11901,7 +11901,7 @@ func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context func (o ListAllClusterLibraryStatusesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "statuses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterLibraryStatuses{}.Type(ctx)}}, + "statuses": basetypes.ListType{ElemType: ClusterLibraryStatuses{}.Type(ctx)}, }, } } @@ -12109,7 +12109,7 @@ func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) baset func (o ListClusterCompliancesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterCompliance{}.Type(ctx)}}, + "clusters": basetypes.ListType{ElemType: ClusterCompliance{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12462,7 +12462,7 @@ func (o ListClustersResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListClustersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ClusterDetails{}.Type(ctx)}}, + "clusters": basetypes.ListType{ElemType: ClusterDetails{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12581,7 +12581,7 @@ func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) basety func (o ListGlobalInitScriptsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GlobalInitScriptDetails{}.Type(ctx)}}, + "scripts": basetypes.ListType{ElemType: GlobalInitScriptDetails{}.Type(ctx)}, }, } } @@ -12650,7 +12650,7 @@ func (o ListInstancePools) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListInstancePools) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_pools": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstancePoolAndStats{}.Type(ctx)}}, + "instance_pools": basetypes.ListType{ElemType: InstancePoolAndStats{}.Type(ctx)}, }, } } @@ -12720,7 +12720,7 @@ func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) basetyp func (o ListInstanceProfilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_profiles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstanceProfile{}.Type(ctx)}}, + "instance_profiles": basetypes.ListType{ElemType: InstanceProfile{}.Type(ctx)}, }, } } @@ -12790,7 +12790,7 @@ func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListNodeTypesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "node_types": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NodeType{}.Type(ctx)}}, + "node_types": basetypes.ListType{ElemType: NodeType{}.Type(ctx)}, }, } } @@ -12860,7 +12860,7 @@ func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListPoliciesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "policies": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Policy{}.Type(ctx)}}, + "policies": basetypes.ListType{ElemType: Policy{}.Type(ctx)}, }, } } @@ -12982,7 +12982,7 @@ func (o ListPolicyFamiliesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "policy_families": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PolicyFamily{}.Type(ctx)}}, + "policy_families": basetypes.ListType{ElemType: PolicyFamily{}.Type(ctx)}, }, } } @@ -13770,7 +13770,7 @@ func (o Policy) Type(ctx context.Context) attr.Type { "definition": types.StringType, "description": types.StringType, "is_default": types.BoolType, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -14857,7 +14857,7 @@ func (o UninstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Library{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, }, } } @@ -15316,7 +15316,7 @@ func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "node_type_id": types.StringType, "num_workers": types.Int64Type, diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 0be0577abc..cbb72a4262 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -1094,7 +1094,7 @@ func (o GenieMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GenieMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attachments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GenieAttachment{}.Type(ctx)}}, + "attachments": basetypes.ListType{ElemType: GenieAttachment{}.Type(ctx)}, "content": types.StringType, "conversation_id": types.StringType, "created_timestamp": types.Int64Type, @@ -1625,7 +1625,7 @@ func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListDashboardsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboards": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}}, + "dashboards": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1754,7 +1754,7 @@ func (o ListSchedulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schedules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Schedule{}.Type(ctx)}}, + "schedules": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, }, } } @@ -1886,7 +1886,7 @@ func (o ListSubscriptionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "subscriptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Subscription{}.Type(ctx)}}, + "subscriptions": basetypes.ListType{ElemType: Subscription{}.Type(ctx)}, }, } } @@ -2262,7 +2262,7 @@ func (o QuerySchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QuerySchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QuerySchemaColumn{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: QuerySchemaColumn{}.Type(ctx)}, "statement_id": types.StringType, }, } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 9768cf96af..11b76683b7 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -1133,7 +1133,7 @@ func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "contents": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DirectoryEntry{}.Type(ctx)}}, + "contents": basetypes.ListType{ElemType: DirectoryEntry{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1205,7 +1205,7 @@ func (o ListStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, + "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, }, } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index e3cd7db9de..3753b284f1 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -126,7 +126,7 @@ func (o AccessControlResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o AccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Permission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: Permission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -840,7 +840,7 @@ func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context func (o GetAssignableRolesForResourceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Role{}.Type(ctx)}}, + "roles": basetypes.ListType{ElemType: Role{}.Type(ctx)}, }, } } @@ -953,7 +953,7 @@ func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPasswordPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: PasswordPermissionsDescription{}.Type(ctx)}, }, } } @@ -1070,7 +1070,7 @@ func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetype func (o GetPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: PermissionsDescription{}.Type(ctx)}, }, } } @@ -1516,13 +1516,13 @@ func (o Group) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "displayName": types.StringType, - "entitlements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "id": types.StringType, - "members": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "members": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "meta": basetypes.ListType{ElemType: ResourceMeta{}.Type(ctx)}, - "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, }, } @@ -2031,7 +2031,7 @@ func (o ListGroupsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Group{}.Type(ctx)}}, + "Resources": basetypes.ListType{ElemType: Group{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, @@ -2145,7 +2145,7 @@ func (o ListServicePrincipalResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServicePrincipal{}.Type(ctx)}}, + "Resources": basetypes.ListType{ElemType: ServicePrincipal{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, @@ -2406,7 +2406,7 @@ func (o ListUsersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: basetypes.ListType{ElemType: User{}.Type(ctx)}}, + "Resources": basetypes.ListType{ElemType: User{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, "startIndex": types.Int64Type, "totalResults": types.Int64Type, @@ -2696,7 +2696,7 @@ func (o ObjectPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: AccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -2777,7 +2777,7 @@ func (o PartialUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "id": types.StringType, - "Operations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Patch{}.Type(ctx)}}, + "Operations": basetypes.ListType{ElemType: Patch{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, }, } @@ -2940,7 +2940,7 @@ func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PasswordAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: PasswordPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3096,7 +3096,7 @@ func (o PasswordPermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PasswordPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3212,7 +3212,7 @@ func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PasswordPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PasswordAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlRequest{}.Type(ctx)}, }, } } @@ -3552,7 +3552,7 @@ func (o PermissionAssignments) ToObjectValue(ctx context.Context) basetypes.Obje func (o PermissionAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionAssignment{}.Type(ctx)}}, + "permission_assignments": basetypes.ListType{ElemType: PermissionAssignment{}.Type(ctx)}, }, } } @@ -3722,7 +3722,7 @@ func (o PermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: AccessControlRequest{}.Type(ctx)}, "request_object_id": types.StringType, "request_object_type": types.StringType, }, @@ -3946,7 +3946,7 @@ func (o RuleSetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, - "grant_rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}}, + "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, "name": types.StringType, }, } @@ -4026,7 +4026,7 @@ func (o RuleSetUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "etag": types.StringType, - "grant_rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}}, + "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, "name": types.StringType, }, } @@ -4130,11 +4130,11 @@ func (o ServicePrincipal) Type(ctx context.Context) attr.Type { "active": types.BoolType, "applicationId": types.StringType, "displayName": types.StringType, - "entitlements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "id": types.StringType, - "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, }, } @@ -4522,13 +4522,13 @@ func (o User) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "active": types.BoolType, "displayName": types.StringType, - "emails": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, - "entitlements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "emails": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, + "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "id": types.StringType, "name": basetypes.ListType{ElemType: Name{}.Type(ctx)}, - "roles": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}}, + "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, "schemas": basetypes.ListType{ElemType: types.StringType}, "userName": types.StringType, }, @@ -4730,7 +4730,7 @@ func (o WorkspacePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WorkspacePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PermissionOutput{}.Type(ctx)}}, + "permissions": basetypes.ListType{ElemType: PermissionOutput{}.Type(ctx)}, }, } } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 950974e5ed..a64f6c3f66 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -330,15 +330,15 @@ func (o BaseRun) Type(ctx context.Context) attr.Type { "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "job_clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, + "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}}, + "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}}, + "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, "run_duration": types.Int64Type, "run_id": types.Int64Type, "run_name": types.StringType, @@ -349,7 +349,7 @@ func (o BaseRun) Type(ctx context.Context) attr.Type { "start_time": types.Int64Type, "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "tasks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTask{}.Type(ctx)}}, + "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, "trigger": types.StringType, "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, @@ -995,7 +995,7 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "existing_cluster_id": types.StringType, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, }, } @@ -1335,27 +1335,27 @@ func (o CreateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, "budget_policy_id": types.StringType, "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}}, + "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, "format": types.StringType, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, + "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "parameter": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}}, + "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, "tags": basetypes.MapType{ElemType: types.StringType}, - "task": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Task{}.Type(ctx)}}, + "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, @@ -2412,7 +2412,7 @@ func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_changes": types.BoolType, - "job_cluster_changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx)}}, + "job_cluster_changes": basetypes.ListType{ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx)}, "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } @@ -2514,7 +2514,7 @@ func (o ExportRunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o ExportRunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "views": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ViewItem{}.Type(ctx)}}, + "views": basetypes.ListType{ElemType: ViewItem{}.Type(ctx)}, }, } } @@ -2691,7 +2691,7 @@ func (o ForEachStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ForEachStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error_message_stats": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ForEachTaskErrorMessageStats{}.Type(ctx)}}, + "error_message_stats": basetypes.ListType{ElemType: ForEachTaskErrorMessageStats{}.Type(ctx)}, "task_run_stats": basetypes.ListType{ElemType: ForEachTaskTaskRunStats{}.Type(ctx)}, }, } @@ -3026,7 +3026,7 @@ func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetJobPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: JobPermissionsDescription{}.Type(ctx)}, }, } } @@ -3761,7 +3761,7 @@ func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o JobAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: JobPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -4563,7 +4563,7 @@ func (o JobPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o JobPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4682,7 +4682,7 @@ func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o JobPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, "job_id": types.StringType, }, } @@ -4947,20 +4947,20 @@ func (o JobSettings) Type(ctx context.Context) attr.Type { "description": types.StringType, "edit_mode": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}}, + "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, "format": types.StringType, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, + "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "parameter": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}}, + "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, "tags": basetypes.MapType{ElemType: types.StringType}, - "task": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Task{}.Type(ctx)}}, + "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, @@ -5546,7 +5546,7 @@ func (o JobsHealthRules) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o JobsHealthRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobsHealthRule{}.Type(ctx)}}, + "rules": basetypes.ListType{ElemType: JobsHealthRule{}.Type(ctx)}, }, } } @@ -5626,7 +5626,7 @@ func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) b func (o ListJobComplianceForPolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "jobs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCompliance{}.Type(ctx)}}, + "jobs": basetypes.ListType{ElemType: JobCompliance{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -5829,7 +5829,7 @@ func (o ListJobsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "has_more": types.BoolType, - "jobs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BaseJob{}.Type(ctx)}}, + "jobs": basetypes.ListType{ElemType: BaseJob{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -6012,7 +6012,7 @@ func (o ListRunsResponse) Type(ctx context.Context) attr.Type { "has_more": types.BoolType, "next_page_token": types.StringType, "prev_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BaseRun{}.Type(ctx)}}, + "runs": basetypes.ListType{ElemType: BaseRun{}.Type(ctx)}, }, } } @@ -8386,17 +8386,17 @@ func (o Run) Type(ctx context.Context) attr.Type { "end_time": types.Int64Type, "execution_duration": types.Int64Type, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "iterations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTask{}.Type(ctx)}}, - "job_clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}}, + "iterations": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, + "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}}, + "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, "job_run_id": types.Int64Type, "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}}, + "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, "run_duration": types.Int64Type, "run_id": types.Int64Type, "run_name": types.StringType, @@ -8407,7 +8407,7 @@ func (o Run) Type(ctx context.Context) attr.Type { "start_time": types.Int64Type, "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "tasks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTask{}.Type(ctx)}}, + "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, "trigger": types.StringType, "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, @@ -10898,7 +10898,7 @@ func (o RunTask) Type(ctx context.Context) attr.Type { "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, "condition_task": basetypes.ListType{ElemType: RunConditionTask{}.Type(ctx)}, "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}}, + "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, "description": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, "end_time": types.Int64Type, @@ -10908,7 +10908,7 @@ func (o RunTask) Type(ctx context.Context) attr.Type { "for_each_task": basetypes.ListType{ElemType: RunForEachTask{}.Type(ctx)}, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, @@ -11825,7 +11825,7 @@ func (o SqlAlertOutput) Type(ctx context.Context) attr.Type { "alert_state": types.StringType, "output_link": types.StringType, "query_text": types.StringType, - "sql_statements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}}, + "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, "warehouse_id": types.StringType, }, } @@ -11900,7 +11900,7 @@ func (o SqlDashboardOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, - "widgets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlDashboardWidgetOutput{}.Type(ctx)}}, + "widgets": basetypes.ListType{ElemType: SqlDashboardWidgetOutput{}.Type(ctx)}, }, } } @@ -12253,7 +12253,7 @@ func (o SqlQueryOutput) Type(ctx context.Context) attr.Type { "endpoint_id": types.StringType, "output_link": types.StringType, "query_text": types.StringType, - "sql_statements": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}}, + "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, "warehouse_id": types.StringType, }, } @@ -12577,7 +12577,7 @@ func (o SqlTaskAlert) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}}, + "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, }, } } @@ -12660,7 +12660,7 @@ func (o SqlTaskDashboard) Type(ctx context.Context) attr.Type { "custom_subject": types.StringType, "dashboard_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}}, + "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, }, } } @@ -12956,10 +12956,10 @@ func (o SubmitRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, "budget_policy_id": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}}, + "environments": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, "idempotency_token": types.StringType, @@ -12967,7 +12967,7 @@ func (o SubmitRun) Type(ctx context.Context) attr.Type { "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "run_name": types.StringType, - "tasks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SubmitTask{}.Type(ctx)}}, + "tasks": basetypes.ListType{ElemType: SubmitTask{}.Type(ctx)}, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, @@ -13453,14 +13453,14 @@ func (o SubmitTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}}, + "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, "description": types.StringType, "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, "environment_key": types.StringType, "existing_cluster_id": types.StringType, "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, @@ -14239,7 +14239,7 @@ func (o Task) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}}, + "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, "description": types.StringType, "disable_auto_optimization": types.BoolType, "email_notifications": basetypes.ListType{ElemType: TaskEmailNotifications{}.Type(ctx)}, @@ -14248,7 +14248,7 @@ func (o Task) Type(ctx context.Context) attr.Type { "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}}, + "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, @@ -15685,11 +15685,11 @@ func (o WebhookNotifications) ToObjectValue(ctx context.Context) basetypes.Objec func (o WebhookNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, - "on_failure": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, - "on_start": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, - "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, - "on_success": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Webhook{}.Type(ctx)}}, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_failure": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_start": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_success": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, }, } } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 597cec230c..5c5145f045 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -243,7 +243,7 @@ func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o BatchGetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, }, } } @@ -382,7 +382,7 @@ func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) basetypes. func (o BatchGetProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "providers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}}, + "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -1945,9 +1945,9 @@ func (o Exchange) Type(ctx context.Context) attr.Type { "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, - "filters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}}, + "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, "id": types.StringType, - "linked_listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}}, + "linked_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, "name": types.StringType, "updated_at": types.Int64Type, "updated_by": types.StringType, @@ -2652,7 +2652,7 @@ func (o GetListingContentMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shared_data_objects": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}}, + "shared_data_objects": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, }, } } @@ -2881,7 +2881,7 @@ func (o GetListingsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -2993,7 +2993,7 @@ func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) ba func (o GetPersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "personalization_requests": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}}, + "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, }, } } @@ -3291,7 +3291,7 @@ func (o InstallationDetail) Type(ctx context.Context) attr.Type { "share_name": types.StringType, "status": types.StringType, "token_detail": basetypes.ListType{ElemType: TokenDetail{}.Type(ctx)}, - "tokens": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}}, + "tokens": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, }, } } @@ -3435,7 +3435,7 @@ func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) basetyp func (o ListAllInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}}, + "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3555,7 +3555,7 @@ func (o ListAllPersonalizationRequestsResponse) Type(ctx context.Context) attr.T return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "personalization_requests": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}}, + "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, }, } } @@ -3677,7 +3677,7 @@ func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) basetype func (o ListExchangeFiltersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}}, + "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3800,7 +3800,7 @@ func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) base func (o ListExchangesForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listing": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}}, + "exchange_listing": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -3919,7 +3919,7 @@ func (o ListExchangesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListExchangesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchanges": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Exchange{}.Type(ctx)}}, + "exchanges": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4070,7 +4070,7 @@ func (o ListFilesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListFilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, + "file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4193,7 +4193,7 @@ func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListFulfillmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fulfillments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListingFulfillment{}.Type(ctx)}}, + "fulfillments": basetypes.ListType{ElemType: ListingFulfillment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4316,7 +4316,7 @@ func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}}, + "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4439,7 +4439,7 @@ func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) base func (o ListListingsForExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}}, + "exchange_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4546,7 +4546,7 @@ func (o ListListingsRequest) Type(ctx context.Context) attr.Type { "page_size": types.Int64Type, "page_token": types.StringType, "provider_ids": basetypes.ListType{ElemType: types.StringType}, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, }, } } @@ -4696,7 +4696,7 @@ func (o ListListingsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4870,7 +4870,7 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}}, + "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -5121,7 +5121,7 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { "data_source": types.StringType, "description": types.StringType, "documentation_link": types.StringType, - "embedded_notebook_file_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, + "embedded_notebook_file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, "file_ids": basetypes.ListType{ElemType: types.StringType}, "geographical_coverage": types.StringType, "license": types.StringType, @@ -5129,7 +5129,7 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { "privacy_policy_link": types.StringType, "size": types.Float64Type, "support_link": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, "terms_of_service": types.StringType, "update_frequency": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, }, @@ -6523,7 +6523,7 @@ func (o SearchListingsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o SearchListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Listing{}.Type(ctx)}}, + "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, "next_page_token": types.StringType, }, } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 96616debb7..f6518c907e 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -530,7 +530,7 @@ func (o CreateExperiment) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, }, } } @@ -650,7 +650,7 @@ func (o CreateModelRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "description": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, }, } } @@ -811,7 +811,7 @@ func (o CreateModelVersionRequest) Type(ctx context.Context) attr.Type { "run_id": types.StringType, "run_link": types.StringType, "source": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, }, } } @@ -1147,7 +1147,7 @@ func (o CreateRun) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, "start_time": types.Int64Type, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, "user_id": types.StringType, }, } @@ -1565,7 +1565,7 @@ func (o DatasetInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset": basetypes.ListType{ElemType: Dataset{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: InputTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: InputTag{}.Type(ctx)}, }, } } @@ -2615,7 +2615,7 @@ func (o Experiment) Type(ctx context.Context) attr.Type { "last_update_time": types.Int64Type, "lifecycle_stage": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, }, } } @@ -2751,7 +2751,7 @@ func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) base func (o ExperimentAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: ExperimentPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -2907,7 +2907,7 @@ func (o ExperimentPermissions) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExperimentPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3026,7 +3026,7 @@ func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) basetyp func (o ExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlRequest{}.Type(ctx)}, "experiment_id": types.StringType, }, } @@ -3279,7 +3279,7 @@ func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context func (o GetExperimentPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExperimentPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: ExperimentPermissionsDescription{}.Type(ctx)}, }, } } @@ -3643,7 +3643,7 @@ func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o GetLatestVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, + "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, }, } } @@ -3717,7 +3717,7 @@ func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetMetricHistoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Metric{}.Type(ctx)}}, + "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4148,7 +4148,7 @@ func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetRegisteredModelPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: RegisteredModelPermissionsDescription{}.Type(ctx)}, }, } } @@ -4711,7 +4711,7 @@ func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListArtifactsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ElemType: basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}}, + "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, "next_page_token": types.StringType, "root_uri": types.StringType, }, @@ -4844,7 +4844,7 @@ func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Experiment{}.Type(ctx)}}, + "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -4966,7 +4966,7 @@ func (o ListModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Model{}.Type(ctx)}}, + "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, }, } } @@ -5040,7 +5040,7 @@ func (o ListRegistryWebhooks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "webhooks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}}, + "webhooks": basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}, }, } } @@ -5157,7 +5157,7 @@ func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) baset func (o ListTransitionRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "requests": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Activity{}.Type(ctx)}}, + "requests": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, }, } } @@ -5323,10 +5323,10 @@ func (o LogBatch) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogBatch) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Metric{}.Type(ctx)}}, - "params": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Param{}.Type(ctx)}}, + "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, + "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, "run_id": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, }, } } @@ -5487,7 +5487,7 @@ func (o LogInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "datasets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}}, + "datasets": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, "run_id": types.StringType, }, } @@ -5944,9 +5944,9 @@ func (o Model) Type(ctx context.Context) attr.Type { "creation_timestamp": types.Int64Type, "description": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, + "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, "name": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, "user_id": types.StringType, }, } @@ -6073,10 +6073,10 @@ func (o ModelDatabricks) Type(ctx context.Context) attr.Type { "description": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, + "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, "name": types.StringType, "permission_level": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, "user_id": types.StringType, }, } @@ -6268,7 +6268,7 @@ func (o ModelVersion) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, "user_id": types.StringType, "version": types.StringType, }, @@ -6410,7 +6410,7 @@ func (o ModelVersionDatabricks) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, "user_id": types.StringType, "version": types.StringType, }, @@ -6640,7 +6640,7 @@ func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) func (o RegisteredModelAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: RegisteredModelPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6796,7 +6796,7 @@ func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) basetypes func (o RegisteredModelPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -6915,7 +6915,7 @@ func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o RegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RegisteredModelAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlRequest{}.Type(ctx)}, "registered_model_id": types.StringType, }, } @@ -7819,9 +7819,9 @@ func (o RunData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Metric{}.Type(ctx)}}, - "params": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Param{}.Type(ctx)}}, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RunTag{}.Type(ctx)}}, + "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, + "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, + "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, }, } } @@ -8023,7 +8023,7 @@ func (o RunInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataset_inputs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}}, + "dataset_inputs": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, }, } } @@ -8234,7 +8234,7 @@ func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) basetypes. func (o SearchExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Experiment{}.Type(ctx)}}, + "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -8396,7 +8396,7 @@ func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) basetype func (o SearchModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}}, + "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -8558,7 +8558,7 @@ func (o SearchModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Model{}.Type(ctx)}}, + "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, }, } } @@ -8766,7 +8766,7 @@ func (o SearchRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Run{}.Type(ctx)}}, + "runs": basetypes.ListType{ElemType: Run{}.Type(ctx)}, }, } } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 691c462c4d..02bf433cb5 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -967,7 +967,7 @@ func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) baset func (o GetCustomAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GetCustomAppIntegrationOutput{}.Type(ctx)}}, + "apps": basetypes.ListType{ElemType: GetCustomAppIntegrationOutput{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1173,7 +1173,7 @@ func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) ba func (o GetPublishedAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: basetypes.ListType{ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx)}}, + "apps": basetypes.ListType{ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1248,7 +1248,7 @@ func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) basetypes.Obj func (o GetPublishedAppsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PublishedAppOutput{}.Type(ctx)}}, + "apps": basetypes.ListType{ElemType: PublishedAppOutput{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1521,7 +1521,7 @@ func (o ListServicePrincipalSecretsResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "secrets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SecretInfo{}.Type(ctx)}}, + "secrets": basetypes.ListType{ElemType: SecretInfo{}.Type(ctx)}, }, } } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 35b3bb290b..2234b9bf6b 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -156,7 +156,7 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}}, + "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, "configuration": basetypes.MapType{ElemType: types.StringType}, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, @@ -167,9 +167,9 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, "name": types.StringType, - "notifications": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Notifications{}.Type(ctx)}}, + "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, "photon": types.BoolType, "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, "schema": types.StringType, @@ -824,7 +824,7 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}}, + "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, "configuration": basetypes.MapType{ElemType: types.StringType}, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, @@ -835,9 +835,9 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, "name": types.StringType, - "notifications": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Notifications{}.Type(ctx)}}, + "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, "photon": types.BoolType, "pipeline_id": types.StringType, "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, @@ -1188,7 +1188,7 @@ func (o ErrorDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ErrorDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exceptions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SerializedException{}.Type(ctx)}}, + "exceptions": basetypes.ListType{ElemType: SerializedException{}.Type(ctx)}, "fatal": types.BoolType, }, } @@ -1445,7 +1445,7 @@ func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPipelinePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelinePermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: PipelinePermissionsDescription{}.Type(ctx)}, }, } } @@ -1642,7 +1642,7 @@ func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { "effective_budget_policy_id": types.StringType, "health": types.StringType, "last_modified": types.Int64Type, - "latest_updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}}, + "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, @@ -2076,7 +2076,7 @@ func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "connection_name": types.StringType, "ingestion_gateway_id": types.StringType, - "objects": basetypes.ListType{ElemType: basetypes.ListType{ElemType: IngestionConfig{}.Type(ctx)}}, + "objects": basetypes.ListType{ElemType: IngestionConfig{}.Type(ctx)}, "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } @@ -2279,7 +2279,7 @@ func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListPipelineEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineEvent{}.Type(ctx)}}, + "events": basetypes.ListType{ElemType: PipelineEvent{}.Type(ctx)}, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -2451,7 +2451,7 @@ func (o ListPipelinesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "statuses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineStateInfo{}.Type(ctx)}}, + "statuses": basetypes.ListType{ElemType: PipelineStateInfo{}.Type(ctx)}, }, } } @@ -2586,7 +2586,7 @@ func (o ListUpdatesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "prev_page_token": types.StringType, - "updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}}, + "updates": basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}, }, } } @@ -3014,7 +3014,7 @@ func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PipelineAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelinePermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: PipelinePermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3217,7 +3217,7 @@ func (o PipelineCluster) Type(ctx context.Context) attr.Type { "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: compute_tf.GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: basetypes.ListType{ElemType: compute_tf.InitScriptInfo{}.Type(ctx)}}, + "init_scripts": basetypes.ListType{ElemType: compute_tf.InitScriptInfo{}.Type(ctx)}, "instance_pool_id": types.StringType, "label": types.StringType, "node_type_id": types.StringType, @@ -4012,7 +4012,7 @@ func (o PipelinePermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PipelinePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4131,7 +4131,7 @@ func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PipelinePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlRequest{}.Type(ctx)}, "pipeline_id": types.StringType, }, } @@ -4289,7 +4289,7 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}}, + "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, "configuration": basetypes.MapType{ElemType: types.StringType}, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, @@ -4299,9 +4299,9 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}}, + "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, "name": types.StringType, - "notifications": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Notifications{}.Type(ctx)}}, + "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, "photon": types.BoolType, "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, "schema": types.StringType, @@ -4638,7 +4638,7 @@ func (o PipelineStateInfo) Type(ctx context.Context) attr.Type { "cluster_id": types.StringType, "creator_user_name": types.StringType, "health": types.StringType, - "latest_updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}}, + "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, @@ -5130,7 +5130,7 @@ func (o SerializedException) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "class_name": types.StringType, "message": types.StringType, - "stack": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StackFrame{}.Type(ctx)}}, + "stack": basetypes.ListType{ElemType: StackFrame{}.Type(ctx)}, }, } } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 5b3a6bce87..30fede620c 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -2658,7 +2658,7 @@ func (o Network) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "account_id": types.StringType, "creation_time": types.Int64Type, - "error_messages": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NetworkHealth{}.Type(ctx)}}, + "error_messages": basetypes.ListType{ElemType: NetworkHealth{}.Type(ctx)}, "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, "network_id": types.StringType, "network_name": types.StringType, @@ -2667,7 +2667,7 @@ func (o Network) Type(ctx context.Context) attr.Type { "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, "vpc_id": types.StringType, "vpc_status": types.StringType, - "warning_messages": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NetworkWarning{}.Type(ctx)}}, + "warning_messages": basetypes.ListType{ElemType: NetworkWarning{}.Type(ctx)}, "workspace_id": types.Int64Type, }, } diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 47f87b85e9..58da69e190 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -132,7 +132,7 @@ func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}}, + "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } @@ -1286,9 +1286,9 @@ func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, "config": basetypes.ListType{ElemType: EndpointCoreConfigInput{}.Type(ctx)}, "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}}, + "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, "route_optimized": types.BoolType, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, }, } } @@ -1805,8 +1805,8 @@ func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigInput{}.Type(ctx)}, "name": types.StringType, - "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntityInput{}.Type(ctx)}}, - "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelInput{}.Type(ctx)}}, + "served_entities": basetypes.ListType{ElemType: ServedEntityInput{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelInput{}.Type(ctx)}, "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } @@ -1974,8 +1974,8 @@ func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}}, - "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}}, + "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } @@ -2129,8 +2129,8 @@ func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) basetypes. func (o EndpointCoreConfigSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntitySpec{}.Type(ctx)}}, - "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelSpec{}.Type(ctx)}}, + "served_entities": basetypes.ListType{ElemType: ServedEntitySpec{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelSpec{}.Type(ctx)}, }, } } @@ -2250,8 +2250,8 @@ func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}}, - "served_models": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}}, + "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, + "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, "start_time": types.Int64Type, "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, @@ -3118,7 +3118,7 @@ func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetServingEndpointPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: ServingEndpointPermissionsDescription{}.Type(ctx)}, }, } } @@ -3347,7 +3347,7 @@ func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListEndpointsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpoint{}.Type(ctx)}}, + "endpoints": basetypes.ListType{ElemType: ServingEndpoint{}.Type(ctx)}, }, } } @@ -3707,7 +3707,7 @@ func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) basetypes.O func (o PatchServingEndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add_tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, + "add_tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, "delete_tags": basetypes.ListType{ElemType: types.StringType}, "name": types.StringType, }, @@ -3880,7 +3880,7 @@ func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}}, + "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } @@ -4048,7 +4048,7 @@ func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}}, + "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } @@ -4203,7 +4203,7 @@ func (o PutRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}}, + "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, }, } } @@ -4273,7 +4273,7 @@ func (o PutResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PutResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rate_limits": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}}, + "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, }, } } @@ -4415,7 +4415,7 @@ func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { "inputs": types.ObjectType{}, "instances": basetypes.ListType{ElemType: types.ObjectType{}}, "max_tokens": types.Int64Type, - "messages": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}}, + "messages": basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}, "n": types.Int64Type, "name": types.StringType, "prompt": types.ObjectType{}, @@ -4658,9 +4658,9 @@ func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "choices": basetypes.ListType{ElemType: basetypes.ListType{ElemType: V1ResponseChoiceElement{}.Type(ctx)}}, + "choices": basetypes.ListType{ElemType: V1ResponseChoiceElement{}.Type(ctx)}, "created": types.Int64Type, - "data": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx)}}, + "data": basetypes.ListType{ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx)}, "id": types.StringType, "model": types.StringType, "object": types.StringType, @@ -5928,7 +5928,7 @@ func (o ServingEndpoint) Type(ctx context.Context) attr.Type { "last_updated_timestamp": types.Int64Type, "name": types.StringType, "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, "task": types.StringType, }, } @@ -6143,7 +6143,7 @@ func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) func (o ServingEndpointAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: ServingEndpointPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6280,7 +6280,7 @@ func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { "permission_level": types.StringType, "route_optimized": types.BoolType, "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}}, + "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, "task": types.StringType, }, } @@ -6563,7 +6563,7 @@ func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) basetypes func (o ServingEndpointPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -6682,7 +6682,7 @@ func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o ServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ServingEndpointAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlRequest{}.Type(ctx)}, "serving_endpoint_id": types.StringType, }, } @@ -6753,7 +6753,7 @@ func (o TrafficConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o TrafficConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "routes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Route{}.Type(ctx)}}, + "routes": basetypes.ListType{ElemType: Route{}.Type(ctx)}, }, } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index c70e5c4933..c5d38a66b7 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -3501,8 +3501,8 @@ func (o EgressNetworkPolicyInternetAccessPolicy) ToObjectValue(ctx context.Conte func (o EgressNetworkPolicyInternetAccessPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_internet_destinations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx)}}, - "allowed_storage_destinations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx)}}, + "allowed_internet_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx)}, + "allowed_storage_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx)}, "log_only_mode": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx)}, "restriction_mode": types.StringType, }, @@ -4440,7 +4440,7 @@ func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExchangeTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExchangeToken{}.Type(ctx)}}, + "values": basetypes.ListType{ElemType: ExchangeToken{}.Type(ctx)}, }, } } @@ -5338,7 +5338,7 @@ func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetIpAccessListsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ElemType: basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}}, + "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -5723,7 +5723,7 @@ func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) bas func (o GetTokenPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: TokenPermissionsDescription{}.Type(ctx)}, }, } } @@ -5975,7 +5975,7 @@ func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ElemType: basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}}, + "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, }, } } @@ -6048,7 +6048,7 @@ func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Cont func (o ListNccAzurePrivateEndpointRulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}}, + "items": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -6165,7 +6165,7 @@ func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context func (o ListNetworkConnectivityConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NetworkConnectivityConfiguration{}.Type(ctx)}}, + "items": basetypes.ListType{ElemType: NetworkConnectivityConfiguration{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -6286,7 +6286,7 @@ func (o ListNotificationDestinationsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListNotificationDestinationsResult{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: ListNotificationDestinationsResult{}.Type(ctx)}, }, } } @@ -6454,7 +6454,7 @@ func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListPublicTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}}, + "token_infos": basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}, }, } } @@ -6572,7 +6572,7 @@ func (o ListTokensResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}}, + "token_infos": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, }, } } @@ -7178,7 +7178,7 @@ func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) basetypes.Objec func (o NccEgressTargetRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "azure_private_endpoint_rules": basetypes.ListType{ElemType: basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}}, + "azure_private_endpoint_rules": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, }, } } @@ -8238,7 +8238,7 @@ func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) basetypes func (o TokenAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: TokenPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -8470,7 +8470,7 @@ func (o TokenPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o TokenPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: TokenAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -8586,7 +8586,7 @@ func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o TokenPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: TokenAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: TokenAccessControlRequest{}.Type(ctx)}, }, } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index fea8d95037..fa69b5ac8b 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -635,7 +635,7 @@ func (o GetRecipientSharePermissionsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "permissions_out": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ShareToPrivilegeAssignment{}.Type(ctx)}}, + "permissions_out": basetypes.ListType{ElemType: ShareToPrivilegeAssignment{}.Type(ctx)}, }, } } @@ -828,7 +828,7 @@ func (o ListProviderSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderShare{}.Type(ctx)}}, + "shares": basetypes.ListType{ElemType: ProviderShare{}.Type(ctx)}, }, } } @@ -964,7 +964,7 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}}, + "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, }, } } @@ -1100,7 +1100,7 @@ func (o ListRecipientsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "recipients": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RecipientInfo{}.Type(ctx)}}, + "recipients": basetypes.ListType{ElemType: RecipientInfo{}.Type(ctx)}, }, } } @@ -1235,7 +1235,7 @@ func (o ListSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}}, + "shares": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, }, } } @@ -1305,7 +1305,7 @@ func (o Partition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Partition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}}, + "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, }, } } @@ -1375,7 +1375,7 @@ func (o PartitionSpecificationPartition) ToObjectValue(ctx context.Context) base func (o PartitionSpecificationPartition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}}, + "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, }, } } @@ -1825,7 +1825,7 @@ func (o RecipientInfo) Type(ctx context.Context) attr.Type { "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, "region": types.StringType, "sharing_code": types.StringType, - "tokens": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RecipientTokenInfo{}.Type(ctx)}}, + "tokens": basetypes.ListType{ElemType: RecipientTokenInfo{}.Type(ctx)}, "updated_at": types.Int64Type, "updated_by": types.StringType, }, @@ -2315,7 +2315,7 @@ func (o ShareInfo) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "created_by": types.StringType, "name": types.StringType, - "object": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}}, + "object": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, "owner": types.StringType, "storage_location": types.StringType, "storage_root": types.StringType, @@ -2452,7 +2452,7 @@ func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes func (o ShareToPrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}}, + "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, "share_name": types.StringType, }, } @@ -2622,7 +2622,7 @@ func (o SharedDataObject) Type(ctx context.Context) attr.Type { "history_data_sharing_status": types.StringType, "effective_history_data_sharing_status": types.StringType, "name": types.StringType, - "partition": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Partition{}.Type(ctx)}}, + "partition": basetypes.ListType{ElemType: Partition{}.Type(ctx)}, "shared_as": types.StringType, "effective_shared_as": types.StringType, "start_version": types.Int64Type, @@ -3047,7 +3047,7 @@ func (o UpdateShare) Type(ctx context.Context) attr.Type { "new_name": types.StringType, "owner": types.StringType, "storage_root": types.StringType, - "updates": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SharedDataObjectUpdate{}.Type(ctx)}}, + "updates": basetypes.ListType{ElemType: SharedDataObjectUpdate{}.Type(ctx)}, }, } } @@ -3134,7 +3134,7 @@ func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateSharePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: catalog_tf.PermissionsChange{}.Type(ctx)}}, + "changes": basetypes.ListType{ElemType: catalog_tf.PermissionsChange{}.Type(ctx)}, "max_results": types.Int64Type, "name": types.StringType, "page_token": types.StringType, diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index a48f72f7d9..1490896a65 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -1493,7 +1493,7 @@ func (o CreateQueryRequestQuery) Type(ctx context.Context) attr.Type { "catalog": types.StringType, "description": types.StringType, "display_name": types.StringType, - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, "parent_path": types.StringType, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -2182,7 +2182,7 @@ func (o Dashboard) Type(ctx context.Context) attr.Type { "updated_at": types.StringType, "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, "user_id": types.Int64Type, - "widgets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Widget{}.Type(ctx)}}, + "widgets": basetypes.ListType{ElemType: Widget{}.Type(ctx)}, }, } } @@ -3962,7 +3962,7 @@ func (o EndpointTags) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "custom_tags": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointTagPair{}.Type(ctx)}}, + "custom_tags": basetypes.ListType{ElemType: EndpointTagPair{}.Type(ctx)}, }, } } @@ -4273,7 +4273,7 @@ func (o ExecuteStatementRequest) Type(ctx context.Context) attr.Type { "disposition": types.StringType, "format": types.StringType, "on_wait_timeout": types.StringType, - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: StatementParameterListItem{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: StatementParameterListItem{}.Type(ctx)}, "row_limit": types.Int64Type, "schema": types.StringType, "statement": types.StringType, @@ -4724,7 +4724,7 @@ func (o GetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4930,7 +4930,7 @@ func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetWarehousePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehousePermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: WarehousePermissionsDescription{}.Type(ctx)}, }, } } @@ -5385,8 +5385,8 @@ func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "data_access_config": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, - "enabled_warehouse_types": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}}, + "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, @@ -5875,7 +5875,7 @@ func (o LegacyQuery) Type(ctx context.Context) attr.Type { "updated_at": types.StringType, "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, "user_id": types.Int64Type, - "visualizations": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}}, + "visualizations": basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}, }, } } @@ -6204,7 +6204,7 @@ func (o ListAlertsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListAlertsResponseAlert{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: ListAlertsResponseAlert{}.Type(ctx)}, }, } } @@ -6586,7 +6586,7 @@ func (o ListQueriesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "has_next_page": types.BoolType, "next_page_token": types.StringType, - "res": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryInfo{}.Type(ctx)}}, + "res": basetypes.ListType{ElemType: QueryInfo{}.Type(ctx)}, }, } } @@ -6747,7 +6747,7 @@ func (o ListQueryObjectsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ListQueryObjectsResponseQuery{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: ListQueryObjectsResponseQuery{}.Type(ctx)}, }, } } @@ -6874,7 +6874,7 @@ func (o ListQueryObjectsResponseQuery) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, "query_text": types.StringType, "run_as_mode": types.StringType, "schema": types.StringType, @@ -6988,7 +6988,7 @@ func (o ListResponse) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, }, } } @@ -7111,7 +7111,7 @@ func (o ListVisualizationsForQueryResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Visualization{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: Visualization{}.Type(ctx)}, }, } } @@ -7225,7 +7225,7 @@ func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListWarehousesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "warehouses": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}}, + "warehouses": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, }, } } @@ -7598,7 +7598,7 @@ func (o Query) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, "parent_path": types.StringType, "query_text": types.StringType, "run_as_mode": types.StringType, @@ -8306,7 +8306,7 @@ func (o QueryList) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ElemType: basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}}, + "results": basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}, }, } } @@ -8529,7 +8529,7 @@ func (o QueryOptions) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "catalog": types.StringType, "moved_to_trash_at": types.StringType, - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Parameter{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: Parameter{}.Type(ctx)}, "schema": types.StringType, }, } @@ -8947,8 +8947,8 @@ func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) basetypes. func (o RepeatedEndpointConfPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config_pair": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, - "configuration_pairs": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, + "config_pair": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "configuration_pairs": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, }, } } @@ -9197,7 +9197,7 @@ func (o ResultData) Type(ctx context.Context) attr.Type { "byte_count": types.Int64Type, "chunk_index": types.Int64Type, "data_array": basetypes.ListType{ElemType: basetypes.ListType{ElemType: types.StringType}}, - "external_links": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ExternalLink{}.Type(ctx)}}, + "external_links": basetypes.ListType{ElemType: ExternalLink{}.Type(ctx)}, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, "row_count": types.Int64Type, @@ -9319,7 +9319,7 @@ func (o ResultManifest) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "chunks": basetypes.ListType{ElemType: basetypes.ListType{ElemType: BaseChunkInfo{}.Type(ctx)}}, + "chunks": basetypes.ListType{ElemType: BaseChunkInfo{}.Type(ctx)}, "format": types.StringType, "schema": basetypes.ListType{ElemType: ResultSchema{}.Type(ctx)}, "total_byte_count": types.Int64Type, @@ -9425,7 +9425,7 @@ func (o ResultSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, }, } } @@ -9547,7 +9547,7 @@ func (o SetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, "objectId": types.StringType, "objectType": types.StringType, }, @@ -9624,7 +9624,7 @@ func (o SetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -9734,8 +9734,8 @@ func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "data_access_config": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}}, - "enabled_warehouse_types": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}}, + "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, @@ -11128,7 +11128,7 @@ func (o UpdateQueryRequestQuery) Type(ctx context.Context) attr.Type { "description": types.StringType, "display_name": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}}, + "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, "query_text": types.StringType, "run_as_mode": types.StringType, "schema": types.StringType, @@ -11592,7 +11592,7 @@ func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) baset func (o WarehouseAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehousePermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: WarehousePermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -11748,7 +11748,7 @@ func (o WarehousePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WarehousePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -11867,7 +11867,7 @@ func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) basetype func (o WarehousePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WarehouseAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlRequest{}.Type(ctx)}, "warehouse_id": types.StringType, }, } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index c917298c7b..390cf5883b 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -757,8 +757,8 @@ func (o DeltaSyncVectorIndexSpecRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "columns_to_sync": basetypes.ListType{ElemType: types.StringType}, - "embedding_source_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}}, - "embedding_vector_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}}, + "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, + "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, "embedding_writeback_table": types.StringType, "pipeline_type": types.StringType, "source_table": types.StringType, @@ -907,8 +907,8 @@ func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) bas func (o DeltaSyncVectorIndexSpecResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}}, - "embedding_vector_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}}, + "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, + "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, "embedding_writeback_table": types.StringType, "pipeline_id": types.StringType, "pipeline_type": types.StringType, @@ -1020,8 +1020,8 @@ func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) basetype func (o DirectAccessVectorIndexSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}}, - "embedding_vector_columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}}, + "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, + "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, "schema_json": types.StringType, }, } @@ -1449,7 +1449,7 @@ func (o ListEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ElemType: basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}}, + "endpoints": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, "next_page_token": types.StringType, }, } @@ -1609,7 +1609,7 @@ func (o ListValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Value{}.Type(ctx)}}, + "values": basetypes.ListType{ElemType: Value{}.Type(ctx)}, }, } } @@ -1684,7 +1684,7 @@ func (o ListVectorIndexesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "vector_indexes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MiniVectorIndex{}.Type(ctx)}}, + "vector_indexes": basetypes.ListType{ElemType: MiniVectorIndex{}.Type(ctx)}, }, } } @@ -2263,7 +2263,7 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}}, + "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, }, } } @@ -2388,7 +2388,7 @@ func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ScanVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data": basetypes.ListType{ElemType: basetypes.ListType{ElemType: Struct{}.Type(ctx)}}, + "data": basetypes.ListType{ElemType: Struct{}.Type(ctx)}, "last_primary_key": types.StringType, }, } @@ -2459,7 +2459,7 @@ func (o Struct) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Struct) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fields": basetypes.ListType{ElemType: basetypes.ListType{ElemType: MapStringValueEntry{}.Type(ctx)}}, + "fields": basetypes.ListType{ElemType: MapStringValueEntry{}.Type(ctx)}, }, } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index 401059a9fa..e3b4c1b747 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -1398,7 +1398,7 @@ func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) base func (o GetRepoPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: RepoPermissionsDescription{}.Type(ctx)}, }, } } @@ -1831,7 +1831,7 @@ func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetWorkspaceObjectPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx)}}, + "permission_levels": basetypes.ListType{ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx)}, }, } } @@ -2105,7 +2105,7 @@ func (o ListAclsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAclsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: basetypes.ListType{ElemType: AclItem{}.Type(ctx)}}, + "items": basetypes.ListType{ElemType: AclItem{}.Type(ctx)}, }, } } @@ -2175,7 +2175,7 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ElemType: basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}}, + "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, }, } } @@ -2301,7 +2301,7 @@ func (o ListReposResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "repos": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}}, + "repos": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, }, } } @@ -2371,7 +2371,7 @@ func (o ListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "objects": basetypes.ListType{ElemType: basetypes.ListType{ElemType: ObjectInfo{}.Type(ctx)}}, + "objects": basetypes.ListType{ElemType: ObjectInfo{}.Type(ctx)}, }, } } @@ -2441,7 +2441,7 @@ func (o ListScopesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListScopesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scopes": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SecretScope{}.Type(ctx)}}, + "scopes": basetypes.ListType{ElemType: SecretScope{}.Type(ctx)}, }, } } @@ -2554,7 +2554,7 @@ func (o ListSecretsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o ListSecretsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "secrets": basetypes.ListType{ElemType: basetypes.ListType{ElemType: SecretMetadata{}.Type(ctx)}}, + "secrets": basetypes.ListType{ElemType: SecretMetadata{}.Type(ctx)}, }, } } @@ -3069,7 +3069,7 @@ func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) basetypes. func (o RepoAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: RepoPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3320,7 +3320,7 @@ func (o RepoPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RepoPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: RepoAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -3439,7 +3439,7 @@ func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o RepoPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: RepoAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: RepoAccessControlRequest{}.Type(ctx)}, "repo_id": types.StringType, }, } @@ -4073,7 +4073,7 @@ func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) func (o WorkspaceObjectAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectPermission{}.Type(ctx)}}, + "all_permissions": basetypes.ListType{ElemType: WorkspaceObjectPermission{}.Type(ctx)}, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -4229,7 +4229,7 @@ func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) basetypes func (o WorkspaceObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx)}, "object_id": types.StringType, "object_type": types.StringType, }, @@ -4351,7 +4351,7 @@ func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o WorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: basetypes.ListType{ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx)}}, + "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx)}, "workspace_object_id": types.StringType, "workspace_object_type": types.StringType, }, From 223acf8472aaf679a3e4f78baa391f7a33fc16e1 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 20:29:20 +0100 Subject: [PATCH 75/91] fix formatting --- internal/service/apps_tf/model.go | 60 +- internal/service/billing_tf/model.go | 66 +- internal/service/catalog_tf/model.go | 456 ++++++++----- internal/service/cleanrooms_tf/model.go | 42 +- internal/service/compute_tf/model.go | 694 ++++++++++++-------- internal/service/dashboards_tf/model.go | 20 +- internal/service/files_tf/model.go | 8 +- internal/service/iam_tf/model.go | 216 +++++-- internal/service/jobs_tf/model.go | 754 ++++++++++++++-------- internal/service/marketplace_tf/model.go | 206 ++++-- internal/service/ml_tf/model.go | 284 +++++--- internal/service/oauth2_tf/model.go | 64 +- internal/service/pipelines_tf/model.go | 330 ++++++---- internal/service/provisioning_tf/model.go | 162 +++-- internal/service/serving_tf/model.go | 262 +++++--- internal/service/settings_tf/model.go | 170 +++-- internal/service/sharing_tf/model.go | 92 ++- internal/service/sql_tf/model.go | 328 ++++++---- internal/service/vectorsearch_tf/model.go | 98 ++- internal/service/workspace_tf/model.go | 90 ++- 20 files changed, 2903 insertions(+), 1499 deletions(-) diff --git a/internal/service/apps_tf/model.go b/internal/service/apps_tf/model.go index 9921b6c284..e570ec50e4 100755 --- a/internal/service/apps_tf/model.go +++ b/internal/service/apps_tf/model.go @@ -114,16 +114,18 @@ func (o App) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o App) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "active_deployment": AppDeployment{}.Type(ctx), - "app_status": ApplicationStatus{}.Type(ctx), - "compute_status": ComputeStatus{}.Type(ctx), - "create_time": types.StringType, - "creator": types.StringType, - "default_source_code_path": types.StringType, - "description": types.StringType, - "name": types.StringType, - "pending_deployment": AppDeployment{}.Type(ctx), - "resources": basetypes.ListType{ElemType: AppResource{}.Type(ctx)}, + "active_deployment": AppDeployment{}.Type(ctx), + "app_status": ApplicationStatus{}.Type(ctx), + "compute_status": ComputeStatus{}.Type(ctx), + "create_time": types.StringType, + "creator": types.StringType, + "default_source_code_path": types.StringType, + "description": types.StringType, + "name": types.StringType, + "pending_deployment": AppDeployment{}.Type(ctx), + "resources": basetypes.ListType{ + ElemType: AppResource{}.Type(ctx), + }, "service_principal_client_id": types.StringType, "service_principal_id": types.Int64Type, "service_principal_name": types.StringType, @@ -377,7 +379,9 @@ func (o AppAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o AppAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: AppPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: AppPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -680,9 +684,11 @@ func (o AppPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AppPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -757,9 +763,11 @@ func (o AppPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AppPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AppAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: AppAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -876,8 +884,10 @@ func (o AppPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o AppPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AppAccessControlRequest{}.Type(ctx)}, - "app_name": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: AppAccessControlRequest{}.Type(ctx), + }, + "app_name": types.StringType, }, } } @@ -1691,7 +1701,9 @@ func (o GetAppPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetAppPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: AppPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: AppPermissionsDescription{}.Type(ctx), + }, }, } } @@ -1902,7 +1914,9 @@ func (o ListAppDeploymentsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListAppDeploymentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_deployments": basetypes.ListType{ElemType: AppDeployment{}.Type(ctx)}, + "app_deployments": basetypes.ListType{ + ElemType: AppDeployment{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -2023,7 +2037,9 @@ func (o ListAppsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAppsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: App{}.Type(ctx)}, + "apps": basetypes.ListType{ + ElemType: App{}.Type(ctx), + }, "next_page_token": types.StringType, }, } diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index 8d76cda34a..ec3ef6734c 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -129,7 +129,9 @@ func (o AlertConfiguration) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o AlertConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ElemType: ActionConfiguration{}.Type(ctx)}, + "action_configurations": basetypes.ListType{ + ElemType: ActionConfiguration{}.Type(ctx), + }, "alert_configuration_id": types.StringType, "quantity_threshold": types.StringType, "quantity_type": types.StringType, @@ -227,8 +229,10 @@ func (o BudgetConfiguration) ToObjectValue(ctx context.Context) basetypes.Object func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ + ElemType: AlertConfiguration{}.Type(ctx), + }, "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, @@ -335,7 +339,9 @@ func (o BudgetConfigurationFilter) ToObjectValue(ctx context.Context) basetypes. func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "tags": basetypes.ListType{ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx), + }, "workspace_id": basetypes.ListType{ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx)}, }, } @@ -435,7 +441,9 @@ func (o BudgetConfigurationFilterClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, - "values": basetypes.ListType{ElemType: types.StringType}, + "values": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -581,7 +589,9 @@ func (o BudgetConfigurationFilterWorkspaceIdClause) Type(ctx context.Context) at return types.ObjectType{ AttrTypes: map[string]attr.Type{ "operator": types.StringType, - "values": basetypes.ListType{ElemType: types.Int64Type}, + "values": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -756,10 +766,12 @@ func (o CreateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) base func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx)}, - "display_name": types.StringType, - "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ + ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx), + }, + "display_name": types.StringType, + "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, }, } } @@ -917,11 +929,13 @@ func (o CreateBudgetConfigurationBudgetAlertConfigurations) ToObjectValue(ctx co func (o CreateBudgetConfigurationBudgetAlertConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action_configurations": basetypes.ListType{ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx)}, - "quantity_threshold": types.StringType, - "quantity_type": types.StringType, - "time_period": types.StringType, - "trigger_type": types.StringType, + "action_configurations": basetypes.ListType{ + ElemType: CreateBudgetConfigurationBudgetActionConfigurations{}.Type(ctx), + }, + "quantity_threshold": types.StringType, + "quantity_type": types.StringType, + "time_period": types.StringType, + "trigger_type": types.StringType, }, } } @@ -1214,7 +1228,9 @@ func (o CreateLogDeliveryConfigurationParams) Type(ctx context.Context) attr.Typ "output_format": types.StringType, "status": types.StringType, "storage_configuration_id": types.StringType, - "workspace_ids_filter": basetypes.ListType{ElemType: types.Int64Type}, + "workspace_ids_filter": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -1758,7 +1774,9 @@ func (o ListBudgetConfigurationsResponse) ToObjectValue(ctx context.Context) bas func (o ListBudgetConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budgets": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, + "budgets": basetypes.ListType{ + ElemType: BudgetConfiguration{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1986,7 +2004,9 @@ func (o LogDeliveryConfiguration) Type(ctx context.Context) attr.Type { "status": types.StringType, "storage_configuration_id": types.StringType, "update_time": types.Int64Type, - "workspace_ids_filter": basetypes.ListType{ElemType: types.Int64Type}, + "workspace_ids_filter": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -2201,8 +2221,10 @@ func (o UpdateBudgetConfigurationBudget) ToObjectValue(ctx context.Context) base func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "alert_configurations": basetypes.ListType{ElemType: AlertConfiguration{}.Type(ctx)}, + "account_id": types.StringType, + "alert_configurations": basetypes.ListType{ + ElemType: AlertConfiguration{}.Type(ctx), + }, "budget_configuration_id": types.StringType, "display_name": types.StringType, "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, @@ -2633,7 +2655,9 @@ func (o WrappedLogDeliveryConfigurations) ToObjectValue(ctx context.Context) bas func (o WrappedLogDeliveryConfigurations) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configurations": basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}, + "log_delivery_configurations": basetypes.ListType{ + ElemType: LogDeliveryConfiguration{}.Type(ctx), + }, }, } } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 0a29009bcb..74c010723a 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -723,10 +723,12 @@ func (o ArtifactAllowlistInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o ArtifactAllowlistInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, - "created_at": types.Int64Type, - "created_by": types.StringType, - "metastore_id": types.StringType, + "artifact_matchers": basetypes.ListType{ + ElemType: ArtifactMatcher{}.Type(ctx), + }, + "created_at": types.Int64Type, + "created_by": types.StringType, + "metastore_id": types.StringType, }, } } @@ -1573,18 +1575,22 @@ func (o CatalogInfo) Type(ctx context.Context) attr.Type { "isolation_mode": types.StringType, "metastore_id": types.StringType, "name": types.StringType, - "options": basetypes.MapType{ElemType: types.StringType}, - "owner": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, - "provider_name": types.StringType, - "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, - "securable_kind": types.StringType, - "securable_type": types.StringType, - "share_name": types.StringType, - "storage_location": types.StringType, - "storage_root": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "options": basetypes.MapType{ + ElemType: types.StringType, + }, + "owner": types.StringType, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "provider_name": types.StringType, + "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "share_name": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1902,8 +1908,10 @@ func (o ColumnMask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ColumnMask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function_name": types.StringType, - "using_column_names": basetypes.ListType{ElemType: types.StringType}, + "function_name": types.StringType, + "using_column_names": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -2030,18 +2038,22 @@ func (o ConnectionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ConnectionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "connection_id": types.StringType, - "connection_type": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "credential_type": types.StringType, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "options": basetypes.MapType{ElemType: types.StringType}, - "owner": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, + "comment": types.StringType, + "connection_id": types.StringType, + "connection_type": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "credential_type": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "options": basetypes.MapType{ + ElemType: types.StringType, + }, + "owner": types.StringType, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, "read_only": types.BoolType, "securable_kind": types.StringType, @@ -2281,11 +2293,15 @@ func (o CreateCatalog) Type(ctx context.Context) attr.Type { "comment": types.StringType, "connection_name": types.StringType, "name": types.StringType, - "options": basetypes.MapType{ElemType: types.StringType}, - "properties": basetypes.MapType{ElemType: types.StringType}, - "provider_name": types.StringType, - "share_name": types.StringType, - "storage_root": types.StringType, + "options": basetypes.MapType{ + ElemType: types.StringType, + }, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "provider_name": types.StringType, + "share_name": types.StringType, + "storage_root": types.StringType, }, } } @@ -2401,9 +2417,13 @@ func (o CreateConnection) Type(ctx context.Context) attr.Type { "comment": types.StringType, "connection_type": types.StringType, "name": types.StringType, - "options": basetypes.MapType{ElemType: types.StringType}, - "properties": basetypes.MapType{ElemType: types.StringType}, - "read_only": types.BoolType, + "options": basetypes.MapType{ + ElemType: types.StringType, + }, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "read_only": types.BoolType, }, } } @@ -3231,20 +3251,24 @@ func (o CreateMonitor) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CreateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets_dir": types.StringType, - "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "assets_dir": types.StringType, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ + ElemType: MonitorMetric{}.Type(ctx), + }, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, "output_schema_name": types.StringType, "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, "skip_builtin_dashboard": types.BoolType, - "slicing_exprs": basetypes.ListType{ElemType: types.StringType}, - "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, - "table_name": types.StringType, - "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, - "warehouse_id": types.StringType, + "slicing_exprs": basetypes.ListType{ + ElemType: types.StringType, + }, + "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, + "table_name": types.StringType, + "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "warehouse_id": types.StringType, }, } } @@ -3677,7 +3701,9 @@ func (o CreateSchema) Type(ctx context.Context) attr.Type { "catalog_name": types.StringType, "comment": types.StringType, "name": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, "storage_root": types.StringType, }, } @@ -4369,7 +4395,9 @@ func (o CurrentWorkspaceBindings) ToObjectValue(ctx context.Context) basetypes.O func (o CurrentWorkspaceBindings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "workspaces": basetypes.ListType{ElemType: types.Int64Type}, + "workspaces": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -5572,7 +5600,9 @@ func (o DeltaRuntimePropertiesKvPairs) ToObjectValue(ctx context.Context) basety func (o DeltaRuntimePropertiesKvPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "delta_runtime_properties": basetypes.MapType{ElemType: types.StringType}, + "delta_runtime_properties": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -5746,7 +5776,9 @@ func (o DependencyList) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o DependencyList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dependencies": basetypes.ListType{ElemType: Dependency{}.Type(ctx)}, + "dependencies": basetypes.ListType{ + ElemType: Dependency{}.Type(ctx), + }, }, } } @@ -5900,7 +5932,9 @@ func (o EffectivePermissionsList) ToObjectValue(ctx context.Context) basetypes.O func (o EffectivePermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: EffectivePrivilegeAssignment{}.Type(ctx)}, + "privilege_assignments": basetypes.ListType{ + ElemType: EffectivePrivilegeAssignment{}.Type(ctx), + }, }, } } @@ -6081,8 +6115,10 @@ func (o EffectivePrivilegeAssignment) ToObjectValue(ctx context.Context) basetyp func (o EffectivePrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principal": types.StringType, - "privileges": basetypes.ListType{ElemType: EffectivePrivilege{}.Type(ctx)}, + "principal": types.StringType, + "privileges": basetypes.ListType{ + ElemType: EffectivePrivilege{}.Type(ctx), + }, }, } } @@ -6551,10 +6587,14 @@ func (o ForeignKeyConstraint) ToObjectValue(ctx context.Context) basetypes.Objec func (o ForeignKeyConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "child_columns": basetypes.ListType{ElemType: types.StringType}, - "name": types.StringType, - "parent_columns": basetypes.ListType{ElemType: types.StringType}, - "parent_table": types.StringType, + "child_columns": basetypes.ListType{ + ElemType: types.StringType, + }, + "name": types.StringType, + "parent_columns": basetypes.ListType{ + ElemType: types.StringType, + }, + "parent_table": types.StringType, }, } } @@ -7028,7 +7068,9 @@ func (o FunctionParameterInfos) ToObjectValue(ctx context.Context) basetypes.Obj func (o FunctionParameterInfos) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ElemType: FunctionParameterInfo{}.Type(ctx)}, + "parameters": basetypes.ListType{ + ElemType: FunctionParameterInfo{}.Type(ctx), + }, }, } } @@ -7144,7 +7186,9 @@ func (o GenerateTemporaryServiceCredentialAzureOptions) ToObjectValue(ctx contex func (o GenerateTemporaryServiceCredentialAzureOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "resources": basetypes.ListType{ElemType: types.StringType}, + "resources": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -7217,7 +7261,9 @@ func (o GenerateTemporaryServiceCredentialGcpOptions) ToObjectValue(ctx context. func (o GenerateTemporaryServiceCredentialGcpOptions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scopes": basetypes.ListType{ElemType: types.StringType}, + "scopes": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -9032,7 +9078,9 @@ func (o ListAccountMetastoreAssignmentsResponse) ToObjectValue(ctx context.Conte func (o ListAccountMetastoreAssignmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "workspace_ids": basetypes.ListType{ElemType: types.Int64Type}, + "workspace_ids": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -9145,7 +9193,9 @@ func (o ListAccountStorageCredentialsResponse) ToObjectValue(ctx context.Context func (o ListAccountStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, + "storage_credentials": basetypes.ListType{ + ElemType: StorageCredentialInfo{}.Type(ctx), + }, }, } } @@ -9280,7 +9330,9 @@ func (o ListCatalogsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListCatalogsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalogs": basetypes.ListType{ElemType: CatalogInfo{}.Type(ctx)}, + "catalogs": basetypes.ListType{ + ElemType: CatalogInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -9408,7 +9460,9 @@ func (o ListConnectionsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListConnectionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "connections": basetypes.ListType{ElemType: ConnectionInfo{}.Type(ctx)}, + "connections": basetypes.ListType{ + ElemType: ConnectionInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -9538,7 +9592,9 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, + "credentials": basetypes.ListType{ + ElemType: CredentialInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -9671,8 +9727,10 @@ func (o ListExternalLocationsResponse) ToObjectValue(ctx context.Context) basety func (o ListExternalLocationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "external_locations": basetypes.ListType{ElemType: ExternalLocationInfo{}.Type(ctx)}, - "next_page_token": types.StringType, + "external_locations": basetypes.ListType{ + ElemType: ExternalLocationInfo{}.Type(ctx), + }, + "next_page_token": types.StringType, }, } } @@ -9812,7 +9870,9 @@ func (o ListFunctionsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListFunctionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "functions": basetypes.ListType{ElemType: FunctionInfo{}.Type(ctx)}, + "functions": basetypes.ListType{ + ElemType: FunctionInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -9883,7 +9943,9 @@ func (o ListMetastoresResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListMetastoresResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastores": basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}, + "metastores": basetypes.ListType{ + ElemType: MetastoreInfo{}.Type(ctx), + }, }, } } @@ -10020,7 +10082,9 @@ func (o ListModelVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: ModelVersionInfo{}.Type(ctx)}, + "model_versions": basetypes.ListType{ + ElemType: ModelVersionInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -10144,7 +10208,9 @@ func (o ListQuotasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "quotas": basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}, + "quotas": basetypes.ListType{ + ElemType: QuotaInfo{}.Type(ctx), + }, }, } } @@ -10339,8 +10405,10 @@ func (o ListRegisteredModelsResponse) ToObjectValue(ctx context.Context) basetyp func (o ListRegisteredModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: RegisteredModelInfo{}.Type(ctx)}, + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ + ElemType: RegisteredModelInfo{}.Type(ctx), + }, }, } } @@ -10477,7 +10545,9 @@ func (o ListSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ElemType: SchemaInfo{}.Type(ctx)}, + "schemas": basetypes.ListType{ + ElemType: SchemaInfo{}.Type(ctx), + }, }, } } @@ -10604,8 +10674,10 @@ func (o ListStorageCredentialsResponse) ToObjectValue(ctx context.Context) baset func (o ListStorageCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "storage_credentials": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, + "next_page_token": types.StringType, + "storage_credentials": basetypes.ListType{ + ElemType: StorageCredentialInfo{}.Type(ctx), + }, }, } } @@ -10808,7 +10880,9 @@ func (o ListSystemSchemasResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schemas": basetypes.ListType{ElemType: SystemSchemaInfo{}.Type(ctx)}, + "schemas": basetypes.ListType{ + ElemType: SystemSchemaInfo{}.Type(ctx), + }, }, } } @@ -10884,7 +10958,9 @@ func (o ListTableSummariesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ElemType: TableSummary{}.Type(ctx)}, + "tables": basetypes.ListType{ + ElemType: TableSummary{}.Type(ctx), + }, }, } } @@ -11046,7 +11122,9 @@ func (o ListTablesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "tables": basetypes.ListType{ElemType: TableInfo{}.Type(ctx)}, + "tables": basetypes.ListType{ + ElemType: TableInfo{}.Type(ctx), + }, }, } } @@ -11194,7 +11272,9 @@ func (o ListVolumesResponseContent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "volumes": basetypes.ListType{ElemType: VolumeInfo{}.Type(ctx)}, + "volumes": basetypes.ListType{ + ElemType: VolumeInfo{}.Type(ctx), + }, }, } } @@ -11499,7 +11579,9 @@ func (o ModelVersionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, + "aliases": basetypes.ListType{ + ElemType: RegisteredModelAlias{}.Type(ctx), + }, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -11709,7 +11791,9 @@ func (o MonitorDestination) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o MonitorDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "email_addresses": basetypes.ListType{ElemType: types.StringType}, + "email_addresses": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -11811,7 +11895,9 @@ func (o MonitorInferenceLog) ToObjectValue(ctx context.Context) basetypes.Object func (o MonitorInferenceLog) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "granularities": basetypes.ListType{ElemType: types.StringType}, + "granularities": basetypes.ListType{ + ElemType: types.StringType, + }, "label_col": types.StringType, "model_id_col": types.StringType, "prediction_col": types.StringType, @@ -11958,9 +12044,11 @@ func (o MonitorInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o MonitorInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets_dir": types.StringType, - "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "assets_dir": types.StringType, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ + ElemType: MonitorMetric{}.Type(ctx), + }, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "drift_metrics_table_name": types.StringType, @@ -11971,11 +12059,13 @@ func (o MonitorInfo) Type(ctx context.Context) attr.Type { "output_schema_name": types.StringType, "profile_metrics_table_name": types.StringType, "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, - "slicing_exprs": basetypes.ListType{ElemType: types.StringType}, - "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, - "status": types.StringType, - "table_name": types.StringType, - "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "slicing_exprs": basetypes.ListType{ + ElemType: types.StringType, + }, + "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, + "status": types.StringType, + "table_name": types.StringType, + "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, }, } } @@ -12253,8 +12343,10 @@ func (o MonitorMetric) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o MonitorMetric) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "definition": types.StringType, - "input_columns": basetypes.ListType{ElemType: types.StringType}, + "definition": types.StringType, + "input_columns": basetypes.ListType{ + ElemType: types.StringType, + }, "name": types.StringType, "output_data_type": types.StringType, "type": types.StringType, @@ -12494,7 +12586,9 @@ func (o MonitorRefreshListResponse) ToObjectValue(ctx context.Context) basetypes func (o MonitorRefreshListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "refreshes": basetypes.ListType{ElemType: MonitorRefreshInfo{}.Type(ctx)}, + "refreshes": basetypes.ListType{ + ElemType: MonitorRefreshInfo{}.Type(ctx), + }, }, } } @@ -12611,7 +12705,9 @@ func (o MonitorTimeSeries) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o MonitorTimeSeries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "granularities": basetypes.ListType{ElemType: types.StringType}, + "granularities": basetypes.ListType{ + ElemType: types.StringType, + }, "timestamp_col": types.StringType, }, } @@ -12871,9 +12967,11 @@ func (o OnlineTableSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o OnlineTableSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "perform_full_copy": types.BoolType, - "pipeline_id": types.StringType, - "primary_key_columns": basetypes.ListType{ElemType: types.StringType}, + "perform_full_copy": types.BoolType, + "pipeline_id": types.StringType, + "primary_key_columns": basetypes.ListType{ + ElemType: types.StringType, + }, "run_continuously": basetypes.ListType{ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.Type(ctx)}, "run_triggered": basetypes.ListType{ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.Type(ctx)}, "source_table_full_name": types.StringType, @@ -13255,9 +13353,13 @@ func (o PermissionsChange) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o PermissionsChange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add": basetypes.ListType{ElemType: types.StringType}, + "add": basetypes.ListType{ + ElemType: types.StringType, + }, "principal": types.StringType, - "remove": basetypes.ListType{ElemType: types.StringType}, + "remove": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -13353,7 +13455,9 @@ func (o PermissionsList) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PermissionsList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, + "privilege_assignments": basetypes.ListType{ + ElemType: PrivilegeAssignment{}.Type(ctx), + }, }, } } @@ -13487,8 +13591,10 @@ func (o PrimaryKeyConstraint) ToObjectValue(ctx context.Context) basetypes.Objec func (o PrimaryKeyConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "child_columns": basetypes.ListType{ElemType: types.StringType}, - "name": types.StringType, + "child_columns": basetypes.ListType{ + ElemType: types.StringType, + }, + "name": types.StringType, }, } } @@ -13561,8 +13667,10 @@ func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.Object func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principal": types.StringType, - "privileges": basetypes.ListType{ElemType: types.StringType}, + "principal": types.StringType, + "privileges": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -14094,7 +14202,9 @@ func (o RegisteredModelInfo) ToObjectValue(ctx context.Context) basetypes.Object func (o RegisteredModelInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aliases": basetypes.ListType{ElemType: RegisteredModelAlias{}.Type(ctx)}, + "aliases": basetypes.ListType{ + ElemType: RegisteredModelAlias{}.Type(ctx), + }, "browse_only": types.BoolType, "catalog_name": types.StringType, "comment": types.StringType, @@ -14287,12 +14397,14 @@ func (o SchemaInfo) Type(ctx context.Context) attr.Type { "metastore_id": types.StringType, "name": types.StringType, "owner": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, - "schema_id": types.StringType, - "storage_location": types.StringType, - "storage_root": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "schema_id": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -14391,8 +14503,10 @@ func (o SetArtifactAllowlist) ToObjectValue(ctx context.Context) basetypes.Objec func (o SetArtifactAllowlist) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifact_matchers": basetypes.ListType{ElemType: ArtifactMatcher{}.Type(ctx)}, - "artifact_type": types.StringType, + "artifact_matchers": basetypes.ListType{ + ElemType: ArtifactMatcher{}.Type(ctx), + }, + "artifact_type": types.StringType, }, } } @@ -15187,10 +15301,12 @@ func (o TableInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o TableInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "access_point": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "columns": basetypes.ListType{ + ElemType: ColumnInfo{}.Type(ctx), + }, "comment": types.StringType, "created_at": types.Int64Type, "created_by": types.StringType, @@ -15206,19 +15322,23 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "name": types.StringType, "owner": types.StringType, "pipeline_id": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, - "row_filter": basetypes.ListType{ElemType: TableRowFilter{}.Type(ctx)}, - "schema_name": types.StringType, - "sql_path": types.StringType, - "storage_credential_name": types.StringType, - "storage_location": types.StringType, - "table_constraints": basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}, - "table_id": types.StringType, - "table_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "view_definition": types.StringType, - "view_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, + "row_filter": basetypes.ListType{ElemType: TableRowFilter{}.Type(ctx)}, + "schema_name": types.StringType, + "sql_path": types.StringType, + "storage_credential_name": types.StringType, + "storage_location": types.StringType, + "table_constraints": basetypes.ListType{ + ElemType: TableConstraint{}.Type(ctx), + }, + "table_id": types.StringType, + "table_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "view_definition": types.StringType, + "view_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, }, } } @@ -15475,8 +15595,10 @@ func (o TableRowFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o TableRowFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function_name": types.StringType, - "input_column_names": basetypes.ListType{ElemType: types.StringType}, + "function_name": types.StringType, + "input_column_names": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -15929,7 +16051,9 @@ func (o UpdateCatalog) Type(ctx context.Context) attr.Type { "name": types.StringType, "new_name": types.StringType, "owner": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -16010,8 +16134,10 @@ func (o UpdateConnection) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "name": types.StringType, "new_name": types.StringType, - "options": basetypes.MapType{ElemType: types.StringType}, - "owner": types.StringType, + "options": basetypes.MapType{ + ElemType: types.StringType, + }, + "owner": types.StringType, }, } } @@ -16675,18 +16801,22 @@ func (o UpdateMonitor) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o UpdateMonitor) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "baseline_table_name": types.StringType, - "custom_metrics": basetypes.ListType{ElemType: MonitorMetric{}.Type(ctx)}, + "baseline_table_name": types.StringType, + "custom_metrics": basetypes.ListType{ + ElemType: MonitorMetric{}.Type(ctx), + }, "dashboard_id": types.StringType, "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, "output_schema_name": types.StringType, "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, - "slicing_exprs": basetypes.ListType{ElemType: types.StringType}, - "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, - "table_name": types.StringType, - "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "slicing_exprs": basetypes.ListType{ + ElemType: types.StringType, + }, + "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, + "table_name": types.StringType, + "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, }, } } @@ -16944,7 +17074,9 @@ func (o UpdatePermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdatePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: PermissionsChange{}.Type(ctx)}, + "changes": basetypes.ListType{ + ElemType: PermissionsChange{}.Type(ctx), + }, "full_name": types.StringType, "securable_type": types.StringType, }, @@ -17127,7 +17259,9 @@ func (o UpdateSchema) Type(ctx context.Context) attr.Type { "full_name": types.StringType, "new_name": types.StringType, "owner": types.StringType, - "properties": basetypes.MapType{ElemType: types.StringType}, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -17533,9 +17667,13 @@ func (o UpdateWorkspaceBindings) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateWorkspaceBindings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assign_workspaces": basetypes.ListType{ElemType: types.Int64Type}, - "name": types.StringType, - "unassign_workspaces": basetypes.ListType{ElemType: types.Int64Type}, + "assign_workspaces": basetypes.ListType{ + ElemType: types.Int64Type, + }, + "name": types.StringType, + "unassign_workspaces": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -17641,8 +17779,12 @@ func (o UpdateWorkspaceBindingsParameters) ToObjectValue(ctx context.Context) ba func (o UpdateWorkspaceBindingsParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, - "remove": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, + "add": basetypes.ListType{ + ElemType: WorkspaceBinding{}.Type(ctx), + }, + "remove": basetypes.ListType{ + ElemType: WorkspaceBinding{}.Type(ctx), + }, "securable_name": types.StringType, "securable_type": types.StringType, }, @@ -17870,8 +18012,10 @@ func (o ValidateCredentialResponse) ToObjectValue(ctx context.Context) basetypes func (o ValidateCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "isDir": types.BoolType, - "results": basetypes.ListType{ElemType: CredentialValidationResult{}.Type(ctx)}, + "isDir": types.BoolType, + "results": basetypes.ListType{ + ElemType: CredentialValidationResult{}.Type(ctx), + }, }, } } @@ -18154,8 +18298,10 @@ func (o ValidateStorageCredentialResponse) ToObjectValue(ctx context.Context) ba func (o ValidateStorageCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "isDir": types.BoolType, - "results": basetypes.ListType{ElemType: ValidationResult{}.Type(ctx)}, + "isDir": types.BoolType, + "results": basetypes.ListType{ + ElemType: ValidationResult{}.Type(ctx), + }, }, } } @@ -18462,7 +18608,9 @@ func (o WorkspaceBindingsResponse) ToObjectValue(ctx context.Context) basetypes. func (o WorkspaceBindingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "bindings": basetypes.ListType{ElemType: WorkspaceBinding{}.Type(ctx)}, + "bindings": basetypes.ListType{ + ElemType: WorkspaceBinding{}.Type(ctx), + }, "next_page_token": types.StringType, }, } diff --git a/internal/service/cleanrooms_tf/model.go b/internal/service/cleanrooms_tf/model.go index fda64ded2b..ad59ad6da3 100755 --- a/internal/service/cleanrooms_tf/model.go +++ b/internal/service/cleanrooms_tf/model.go @@ -529,7 +529,9 @@ func (o CleanRoomAssetForeignTable) ToObjectValue(ctx context.Context) basetypes func (o CleanRoomAssetForeignTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ + ElemType: catalog_tf.ColumnInfo{}.Type(ctx), + }, }, } } @@ -689,7 +691,9 @@ func (o CleanRoomAssetTable) ToObjectValue(ctx context.Context) basetypes.Object func (o CleanRoomAssetTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ + ElemType: catalog_tf.ColumnInfo{}.Type(ctx), + }, }, } } @@ -764,7 +768,9 @@ func (o CleanRoomAssetTableLocalDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "local_name": types.StringType, - "partitions": basetypes.ListType{ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx)}, + "partitions": basetypes.ListType{ + ElemType: sharing_tf.PartitionSpecificationPartition{}.Type(ctx), + }, }, } } @@ -834,7 +840,9 @@ func (o CleanRoomAssetView) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CleanRoomAssetView) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: catalog_tf.ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ + ElemType: catalog_tf.ColumnInfo{}.Type(ctx), + }, }, } } @@ -1275,9 +1283,11 @@ func (o CleanRoomRemoteDetail) ToObjectValue(ctx context.Context) basetypes.Obje func (o CleanRoomRemoteDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "central_clean_room_id": types.StringType, - "cloud_vendor": types.StringType, - "collaborators": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, + "central_clean_room_id": types.StringType, + "cloud_vendor": types.StringType, + "collaborators": basetypes.ListType{ + ElemType: CleanRoomCollaborator{}.Type(ctx), + }, "compliance_security_profile": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, "creator": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, "egress_network_policy": basetypes.ListType{ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx)}, @@ -1493,8 +1503,10 @@ func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) basetypes. func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ElemType: types.StringType}, - "is_enabled": types.BoolType, + "compliance_standards": basetypes.ListType{ + ElemType: types.StringType, + }, + "is_enabled": types.BoolType, }, } } @@ -2168,7 +2180,9 @@ func (o ListCleanRoomAssetsResponse) ToObjectValue(ctx context.Context) basetype func (o ListCleanRoomAssetsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, + "assets": basetypes.ListType{ + ElemType: CleanRoomAsset{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -2300,7 +2314,9 @@ func (o ListCleanRoomNotebookTaskRunsResponse) Type(ctx context.Context) attr.Ty return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: CleanRoomNotebookTaskRun{}.Type(ctx)}, + "runs": basetypes.ListType{ + ElemType: CleanRoomNotebookTaskRun{}.Type(ctx), + }, }, } } @@ -2422,7 +2438,9 @@ func (o ListCleanRoomsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListCleanRoomsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_rooms": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, + "clean_rooms": basetypes.ListType{ + ElemType: CleanRoom{}.Type(ctx), + }, "next_page_token": types.StringType, }, } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 4c000e2c98..980ca1ec1e 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -753,7 +753,9 @@ func (o CloudProviderNodeInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o CloudProviderNodeInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "status": basetypes.ListType{ElemType: types.StringType}, + "status": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -889,7 +891,9 @@ func (o ClusterAccessControlResponse) ToObjectValue(ctx context.Context) basetyp func (o ClusterAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ClusterPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: ClusterPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -1124,12 +1128,14 @@ func (o ClusterAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ClusterAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, @@ -1137,17 +1143,25 @@ func (o ClusterAttributes) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -1489,7 +1503,9 @@ func (o ClusterCompliance) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, "is_compliant": types.BoolType, - "violations": basetypes.MapType{ElemType: types.StringType}, + "violations": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -1831,51 +1847,65 @@ func (o ClusterDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ClusterDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_cores": types.Float64Type, - "cluster_id": types.StringType, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_log_status": basetypes.ListType{ElemType: LogSyncStatus{}.Type(ctx)}, - "cluster_memory_mb": types.Int64Type, - "cluster_name": types.StringType, - "cluster_source": types.StringType, - "creator_user_name": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, - "data_security_mode": types.StringType, - "default_tags": basetypes.MapType{ElemType: types.StringType}, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_cores": types.Float64Type, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_log_status": basetypes.ListType{ElemType: LogSyncStatus{}.Type(ctx)}, + "cluster_memory_mb": types.Int64Type, + "cluster_name": types.StringType, + "cluster_source": types.StringType, + "creator_user_name": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "data_security_mode": types.StringType, + "default_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "executors": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "jdbc_port": types.Int64Type, - "last_restarted_time": types.Int64Type, - "last_state_loss_time": types.Int64Type, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_context_id": types.Int64Type, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "spark_version": types.StringType, - "spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, - "start_time": types.Int64Type, - "state": types.StringType, - "state_message": types.StringType, - "terminated_time": types.Int64Type, - "termination_reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "executors": basetypes.ListType{ + ElemType: SparkNode{}.Type(ctx), + }, + "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "jdbc_port": types.Int64Type, + "last_restarted_time": types.Int64Type, + "last_state_loss_time": types.Int64Type, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_context_id": types.Int64Type, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_version": types.StringType, + "spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "start_time": types.Int64Type, + "state": types.StringType, + "state_message": types.StringType, + "terminated_time": types.Int64Type, + "termination_reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -2505,8 +2535,10 @@ func (o ClusterLibraryStatuses) ToObjectValue(ctx context.Context) basetypes.Obj func (o ClusterLibraryStatuses) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "library_statuses": basetypes.ListType{ElemType: LibraryFullStatus{}.Type(ctx)}, + "cluster_id": types.StringType, + "library_statuses": basetypes.ListType{ + ElemType: LibraryFullStatus{}.Type(ctx), + }, }, } } @@ -2687,9 +2719,11 @@ func (o ClusterPermission) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ClusterPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -2764,9 +2798,11 @@ func (o ClusterPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ClusterPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ClusterAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2883,8 +2919,10 @@ func (o ClusterPermissionsRequest) ToObjectValue(ctx context.Context) basetypes. func (o ClusterPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterAccessControlRequest{}.Type(ctx)}, - "cluster_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ClusterAccessControlRequest{}.Type(ctx), + }, + "cluster_id": types.StringType, }, } } @@ -3020,7 +3058,9 @@ func (o ClusterPolicyAccessControlResponse) ToObjectValue(ctx context.Context) b func (o ClusterPolicyAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ClusterPolicyPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: ClusterPolicyPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3099,9 +3139,11 @@ func (o ClusterPolicyPermission) ToObjectValue(ctx context.Context) basetypes.Ob func (o ClusterPolicyPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -3176,9 +3218,11 @@ func (o ClusterPolicyPermissions) ToObjectValue(ctx context.Context) basetypes.O func (o ClusterPolicyPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ClusterPolicyAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3295,8 +3339,10 @@ func (o ClusterPolicyPermissionsRequest) ToObjectValue(ctx context.Context) base func (o ClusterPolicyPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx)}, - "cluster_policy_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ClusterPolicyAccessControlRequest{}.Type(ctx), + }, + "cluster_policy_id": types.StringType, }, } } @@ -3693,14 +3739,16 @@ func (o ClusterSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ClusterSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, @@ -3708,18 +3756,26 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -4579,15 +4635,17 @@ func (o CreateCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CreateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "clone_from": basetypes.ListType{ElemType: CloneCluster{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "clone_from": basetypes.ListType{ElemType: CloneCluster{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, @@ -4595,18 +4653,26 @@ func (o CreateCluster) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -5145,9 +5211,11 @@ func (o CreateInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, @@ -5156,8 +5224,12 @@ func (o CreateInstancePool) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, - "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, + "preloaded_docker_images": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, + "preloaded_spark_versions": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -5462,9 +5534,11 @@ func (o CreatePolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreatePolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "definition": types.StringType, - "description": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "definition": types.StringType, + "description": types.StringType, + "libraries": basetypes.ListType{ + ElemType: Library{}.Type(ctx), + }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -6612,15 +6686,17 @@ func (o EditCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EditCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_id": types.StringType, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, @@ -6628,18 +6704,26 @@ func (o EditCluster) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } @@ -7066,7 +7150,9 @@ func (o EditInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o EditInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, "instance_pool_name": types.StringType, @@ -7218,9 +7304,11 @@ func (o EditPolicy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EditPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "definition": types.StringType, - "description": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "definition": types.StringType, + "description": types.StringType, + "libraries": basetypes.ListType{ + ElemType: Library{}.Type(ctx), + }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -7419,7 +7507,9 @@ func (o EnforceClusterComplianceResponse) ToObjectValue(ctx context.Context) bas func (o EnforceClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: ClusterSettingsChange{}.Type(ctx)}, + "changes": basetypes.ListType{ + ElemType: ClusterSettingsChange{}.Type(ctx), + }, "has_changes": types.BoolType, }, } @@ -7504,8 +7594,10 @@ func (o Environment) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Environment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "client": types.StringType, - "dependencies": basetypes.ListType{ElemType: types.StringType}, + "client": types.StringType, + "dependencies": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -8039,7 +8131,9 @@ func (o GetClusterComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, - "violations": basetypes.MapType{ElemType: types.StringType}, + "violations": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -8152,7 +8246,9 @@ func (o GetClusterPermissionLevelsResponse) ToObjectValue(ctx context.Context) b func (o GetClusterPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ClusterPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: ClusterPermissionsDescription{}.Type(ctx), + }, }, } } @@ -8308,7 +8404,9 @@ func (o GetClusterPolicyPermissionLevelsResponse) ToObjectValue(ctx context.Cont func (o GetClusterPolicyPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: ClusterPolicyPermissionsDescription{}.Type(ctx), + }, }, } } @@ -8531,13 +8629,15 @@ func (o GetEvents) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GetEvents) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "end_time": types.Int64Type, - "event_types": basetypes.ListType{ElemType: types.StringType}, - "limit": types.Int64Type, - "offset": types.Int64Type, - "order": types.StringType, - "start_time": types.Int64Type, + "cluster_id": types.StringType, + "end_time": types.Int64Type, + "event_types": basetypes.ListType{ + ElemType: types.StringType, + }, + "limit": types.Int64Type, + "offset": types.Int64Type, + "order": types.StringType, + "start_time": types.Int64Type, }, } } @@ -8616,7 +8716,9 @@ func (o GetEventsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o GetEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: ClusterEvent{}.Type(ctx)}, + "events": basetypes.ListType{ + ElemType: ClusterEvent{}.Type(ctx), + }, "next_page": basetypes.ListType{ElemType: GetEvents{}.Type(ctx)}, "total_count": types.Int64Type, }, @@ -8854,10 +8956,14 @@ func (o GetInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, - "default_tags": basetypes.MapType{ElemType: types.StringType}, + "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "default_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, @@ -8867,11 +8973,15 @@ func (o GetInstancePool) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, - "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, - "state": types.StringType, - "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, + "preloaded_docker_images": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, + "preloaded_spark_versions": basetypes.ListType{ + ElemType: types.StringType, + }, + "state": types.StringType, + "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, }, } } @@ -9218,7 +9328,9 @@ func (o GetInstancePoolPermissionLevelsResponse) ToObjectValue(ctx context.Conte func (o GetInstancePoolPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: InstancePoolPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: InstancePoolPermissionsDescription{}.Type(ctx), + }, }, } } @@ -9422,7 +9534,9 @@ func (o GetSparkVersionsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetSparkVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "versions": basetypes.ListType{ElemType: SparkVersion{}.Type(ctx)}, + "versions": basetypes.ListType{ + ElemType: SparkVersion{}.Type(ctx), + }, }, } } @@ -9782,8 +9896,12 @@ func (o InitScriptEventDetails) ToObjectValue(ctx context.Context) basetypes.Obj func (o InitScriptEventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, - "global": basetypes.ListType{ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx)}, + "cluster": basetypes.ListType{ + ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), + }, + "global": basetypes.ListType{ + ElemType: InitScriptInfoAndExecutionDetails{}.Type(ctx), + }, "reported_for_node": types.StringType, }, } @@ -10302,7 +10420,9 @@ func (o InstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ + ElemType: Library{}.Type(ctx), + }, }, } } @@ -10474,7 +10594,9 @@ func (o InstancePoolAccessControlResponse) ToObjectValue(ctx context.Context) ba func (o InstancePoolAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: InstancePoolPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: InstancePoolPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -10645,10 +10767,14 @@ func (o InstancePoolAndStats) ToObjectValue(ctx context.Context) basetypes.Objec func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, - "default_tags": basetypes.MapType{ElemType: types.StringType}, + "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "default_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, "enable_elastic_disk": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, @@ -10658,11 +10784,15 @@ func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { "max_capacity": types.Int64Type, "min_idle_instances": types.Int64Type, "node_type_id": types.StringType, - "preloaded_docker_images": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, - "preloaded_spark_versions": basetypes.ListType{ElemType: types.StringType}, - "state": types.StringType, - "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, + "preloaded_docker_images": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, + "preloaded_spark_versions": basetypes.ListType{ + ElemType: types.StringType, + }, + "state": types.StringType, + "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, }, } } @@ -11166,9 +11296,11 @@ func (o InstancePoolPermission) ToObjectValue(ctx context.Context) basetypes.Obj func (o InstancePoolPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -11243,9 +11375,11 @@ func (o InstancePoolPermissions) ToObjectValue(ctx context.Context) basetypes.Ob func (o InstancePoolPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: InstancePoolAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -11362,8 +11496,10 @@ func (o InstancePoolPermissionsRequest) ToObjectValue(ctx context.Context) baset func (o InstancePoolPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: InstancePoolAccessControlRequest{}.Type(ctx)}, - "instance_pool_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: InstancePoolAccessControlRequest{}.Type(ctx), + }, + "instance_pool_id": types.StringType, }, } } @@ -11490,7 +11626,9 @@ func (o InstancePoolStatus) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o InstancePoolStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "pending_instance_errors": basetypes.ListType{ElemType: PendingInstanceError{}.Type(ctx)}, + "pending_instance_errors": basetypes.ListType{ + ElemType: PendingInstanceError{}.Type(ctx), + }, }, } } @@ -11804,8 +11942,10 @@ func (o LibraryFullStatus) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "is_library_for_all_clusters": types.BoolType, "library": basetypes.ListType{ElemType: Library{}.Type(ctx)}, - "messages": basetypes.ListType{ElemType: types.StringType}, - "status": types.StringType, + "messages": basetypes.ListType{ + ElemType: types.StringType, + }, + "status": types.StringType, }, } } @@ -11901,7 +12041,9 @@ func (o ListAllClusterLibraryStatusesResponse) ToObjectValue(ctx context.Context func (o ListAllClusterLibraryStatusesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "statuses": basetypes.ListType{ElemType: ClusterLibraryStatuses{}.Type(ctx)}, + "statuses": basetypes.ListType{ + ElemType: ClusterLibraryStatuses{}.Type(ctx), + }, }, } } @@ -11976,7 +12118,9 @@ func (o ListAvailableZonesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "default_zone": types.StringType, - "zones": basetypes.ListType{ElemType: types.StringType}, + "zones": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -12109,7 +12253,9 @@ func (o ListClusterCompliancesResponse) ToObjectValue(ctx context.Context) baset func (o ListClusterCompliancesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ElemType: ClusterCompliance{}.Type(ctx)}, + "clusters": basetypes.ListType{ + ElemType: ClusterCompliance{}.Type(ctx), + }, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12241,10 +12387,14 @@ func (o ListClustersFilterBy) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListClustersFilterBy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_sources": basetypes.ListType{ElemType: types.StringType}, - "cluster_states": basetypes.ListType{ElemType: types.StringType}, - "is_pinned": types.BoolType, - "policy_id": types.StringType, + "cluster_sources": basetypes.ListType{ + ElemType: types.StringType, + }, + "cluster_states": basetypes.ListType{ + ElemType: types.StringType, + }, + "is_pinned": types.BoolType, + "policy_id": types.StringType, }, } } @@ -12462,7 +12612,9 @@ func (o ListClustersResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListClustersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clusters": basetypes.ListType{ElemType: ClusterDetails{}.Type(ctx)}, + "clusters": basetypes.ListType{ + ElemType: ClusterDetails{}.Type(ctx), + }, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -12581,7 +12733,9 @@ func (o ListGlobalInitScriptsResponse) ToObjectValue(ctx context.Context) basety func (o ListGlobalInitScriptsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scripts": basetypes.ListType{ElemType: GlobalInitScriptDetails{}.Type(ctx)}, + "scripts": basetypes.ListType{ + ElemType: GlobalInitScriptDetails{}.Type(ctx), + }, }, } } @@ -12650,7 +12804,9 @@ func (o ListInstancePools) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListInstancePools) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_pools": basetypes.ListType{ElemType: InstancePoolAndStats{}.Type(ctx)}, + "instance_pools": basetypes.ListType{ + ElemType: InstancePoolAndStats{}.Type(ctx), + }, }, } } @@ -12720,7 +12876,9 @@ func (o ListInstanceProfilesResponse) ToObjectValue(ctx context.Context) basetyp func (o ListInstanceProfilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "instance_profiles": basetypes.ListType{ElemType: InstanceProfile{}.Type(ctx)}, + "instance_profiles": basetypes.ListType{ + ElemType: InstanceProfile{}.Type(ctx), + }, }, } } @@ -12790,7 +12948,9 @@ func (o ListNodeTypesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListNodeTypesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "node_types": basetypes.ListType{ElemType: NodeType{}.Type(ctx)}, + "node_types": basetypes.ListType{ + ElemType: NodeType{}.Type(ctx), + }, }, } } @@ -12860,7 +13020,9 @@ func (o ListPoliciesResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListPoliciesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "policies": basetypes.ListType{ElemType: Policy{}.Type(ctx)}, + "policies": basetypes.ListType{ + ElemType: Policy{}.Type(ctx), + }, }, } } @@ -12982,7 +13144,9 @@ func (o ListPolicyFamiliesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "policy_families": basetypes.ListType{ElemType: PolicyFamily{}.Type(ctx)}, + "policy_families": basetypes.ListType{ + ElemType: PolicyFamily{}.Type(ctx), + }, }, } } @@ -13200,8 +13364,10 @@ func (o MavenLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "coordinates": types.StringType, - "exclusions": basetypes.ListType{ElemType: types.StringType}, - "repo": types.StringType, + "exclusions": basetypes.ListType{ + ElemType: types.StringType, + }, + "repo": types.StringType, }, } } @@ -13765,12 +13931,14 @@ func (o Policy) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Policy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "created_at_timestamp": types.Int64Type, - "creator_user_name": types.StringType, - "definition": types.StringType, - "description": types.StringType, - "is_default": types.BoolType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "created_at_timestamp": types.Int64Type, + "creator_user_name": types.StringType, + "definition": types.StringType, + "description": types.StringType, + "is_default": types.BoolType, + "libraries": basetypes.ListType{ + ElemType: Library{}.Type(ctx), + }, "max_clusters_per_user": types.Int64Type, "name": types.StringType, "policy_family_definition_overrides": types.StringType, @@ -14312,16 +14480,22 @@ func (o Results) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Results) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "data": types.ObjectType{}, - "fileName": types.StringType, - "fileNames": basetypes.ListType{ElemType: types.StringType}, + "cause": types.StringType, + "data": types.ObjectType{}, + "fileName": types.StringType, + "fileNames": basetypes.ListType{ + ElemType: types.StringType, + }, "isJsonSchema": types.BoolType, "pos": types.Int64Type, "resultType": types.StringType, - "schema": basetypes.ListType{ElemType: basetypes.MapType{ElemType: types.ObjectType{}}}, - "summary": types.StringType, - "truncated": types.BoolType, + "schema": basetypes.ListType{ + ElemType: basetypes.MapType{ + ElemType: types.ObjectType{}, + }, + }, + "summary": types.StringType, + "truncated": types.BoolType, }, } } @@ -14781,9 +14955,11 @@ func (o TerminationReason) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o TerminationReason) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "code": types.StringType, - "parameters": basetypes.MapType{ElemType: types.StringType}, - "type": types.StringType, + "code": types.StringType, + "parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "type": types.StringType, }, } } @@ -14857,7 +15033,9 @@ func (o UninstallLibraries) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "cluster_id": types.StringType, - "libraries": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "libraries": basetypes.ListType{ + ElemType: Library{}.Type(ctx), + }, }, } } @@ -15302,13 +15480,15 @@ func (o UpdateClusterResource) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, + "cluster_name": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "data_security_mode": types.StringType, "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, "driver_instance_pool_id": types.StringType, @@ -15316,18 +15496,26 @@ func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "runtime_engine": types.StringType, - "single_user_name": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "spark_version": types.StringType, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "runtime_engine": types.StringType, + "single_user_name": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_version": types.StringType, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, }, } } diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index cbb72a4262..56a1eb2719 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -1094,7 +1094,9 @@ func (o GenieMessage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GenieMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attachments": basetypes.ListType{ElemType: GenieAttachment{}.Type(ctx)}, + "attachments": basetypes.ListType{ + ElemType: GenieAttachment{}.Type(ctx), + }, "content": types.StringType, "conversation_id": types.StringType, "created_timestamp": types.Int64Type, @@ -1625,7 +1627,9 @@ func (o ListDashboardsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListDashboardsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboards": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, + "dashboards": basetypes.ListType{ + ElemType: Dashboard{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1754,7 +1758,9 @@ func (o ListSchedulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "schedules": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, + "schedules": basetypes.ListType{ + ElemType: Schedule{}.Type(ctx), + }, }, } } @@ -1886,7 +1892,9 @@ func (o ListSubscriptionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "subscriptions": basetypes.ListType{ElemType: Subscription{}.Type(ctx)}, + "subscriptions": basetypes.ListType{ + ElemType: Subscription{}.Type(ctx), + }, }, } } @@ -2262,7 +2270,9 @@ func (o QuerySchema) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QuerySchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: QuerySchemaColumn{}.Type(ctx)}, + "columns": basetypes.ListType{ + ElemType: QuerySchemaColumn{}.Type(ctx), + }, "statement_id": types.StringType, }, } diff --git a/internal/service/files_tf/model.go b/internal/service/files_tf/model.go index 11b76683b7..c596edcbff 100755 --- a/internal/service/files_tf/model.go +++ b/internal/service/files_tf/model.go @@ -1133,7 +1133,9 @@ func (o ListDirectoryResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListDirectoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "contents": basetypes.ListType{ElemType: DirectoryEntry{}.Type(ctx)}, + "contents": basetypes.ListType{ + ElemType: DirectoryEntry{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1205,7 +1207,9 @@ func (o ListStatusResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "files": basetypes.ListType{ + ElemType: FileInfo{}.Type(ctx), + }, }, } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 3753b284f1..03825478b5 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -126,7 +126,9 @@ func (o AccessControlResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o AccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: Permission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: Permission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -840,7 +842,9 @@ func (o GetAssignableRolesForResourceResponse) ToObjectValue(ctx context.Context func (o GetAssignableRolesForResourceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "roles": basetypes.ListType{ElemType: Role{}.Type(ctx)}, + "roles": basetypes.ListType{ + ElemType: Role{}.Type(ctx), + }, }, } } @@ -953,7 +957,9 @@ func (o GetPasswordPermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPasswordPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: PasswordPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: PasswordPermissionsDescription{}.Type(ctx), + }, }, } } @@ -1070,7 +1076,9 @@ func (o GetPermissionLevelsResponse) ToObjectValue(ctx context.Context) basetype func (o GetPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: PermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: PermissionsDescription{}.Type(ctx), + }, }, } } @@ -1412,8 +1420,10 @@ func (o GrantRule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GrantRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principals": basetypes.ListType{ElemType: types.StringType}, - "role": types.StringType, + "principals": basetypes.ListType{ + ElemType: types.StringType, + }, + "role": types.StringType, }, } } @@ -1515,15 +1525,25 @@ func (o Group) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Group) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "displayName": types.StringType, - "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "id": types.StringType, - "members": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "meta": basetypes.ListType{ElemType: ResourceMeta{}.Type(ctx)}, - "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, + "displayName": types.StringType, + "entitlements": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "externalId": types.StringType, + "groups": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "id": types.StringType, + "members": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "meta": basetypes.ListType{ElemType: ResourceMeta{}.Type(ctx)}, + "roles": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -2031,8 +2051,12 @@ func (o ListGroupsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: Group{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, + "Resources": basetypes.ListType{ + ElemType: Group{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, "startIndex": types.Int64Type, "totalResults": types.Int64Type, }, @@ -2145,8 +2169,12 @@ func (o ListServicePrincipalResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: ServicePrincipal{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, + "Resources": basetypes.ListType{ + ElemType: ServicePrincipal{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, "startIndex": types.Int64Type, "totalResults": types.Int64Type, }, @@ -2406,8 +2434,12 @@ func (o ListUsersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "itemsPerPage": types.Int64Type, - "Resources": basetypes.ListType{ElemType: User{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, + "Resources": basetypes.ListType{ + ElemType: User{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, "startIndex": types.Int64Type, "totalResults": types.Int64Type, }, @@ -2696,9 +2728,11 @@ func (o ObjectPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: AccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -2776,9 +2810,13 @@ func (o PartialUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o PartialUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "Operations": basetypes.ListType{ElemType: Patch{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, + "id": types.StringType, + "Operations": basetypes.ListType{ + ElemType: Patch{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -2940,7 +2978,9 @@ func (o PasswordAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PasswordAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: PasswordPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: PasswordPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3019,9 +3059,11 @@ func (o PasswordPermission) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PasswordPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -3096,9 +3138,11 @@ func (o PasswordPermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PasswordPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: PasswordAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3212,7 +3256,9 @@ func (o PasswordPermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PasswordPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PasswordAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: PasswordAccessControlRequest{}.Type(ctx), + }, }, } } @@ -3373,9 +3419,11 @@ func (o Permission) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Permission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -3454,9 +3502,11 @@ func (o PermissionAssignment) ToObjectValue(ctx context.Context) basetypes.Objec func (o PermissionAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error": types.StringType, - "permissions": basetypes.ListType{ElemType: types.StringType}, - "principal": basetypes.ListType{ElemType: PrincipalOutput{}.Type(ctx)}, + "error": types.StringType, + "permissions": basetypes.ListType{ + ElemType: types.StringType, + }, + "principal": basetypes.ListType{ElemType: PrincipalOutput{}.Type(ctx)}, }, } } @@ -3552,7 +3602,9 @@ func (o PermissionAssignments) ToObjectValue(ctx context.Context) basetypes.Obje func (o PermissionAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_assignments": basetypes.ListType{ElemType: PermissionAssignment{}.Type(ctx)}, + "permission_assignments": basetypes.ListType{ + ElemType: PermissionAssignment{}.Type(ctx), + }, }, } } @@ -3722,7 +3774,9 @@ func (o PermissionsRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: AccessControlRequest{}.Type(ctx), + }, "request_object_id": types.StringType, "request_object_type": types.StringType, }, @@ -3945,9 +3999,11 @@ func (o RuleSetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RuleSetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, - "name": types.StringType, + "etag": types.StringType, + "grant_rules": basetypes.ListType{ + ElemType: GrantRule{}.Type(ctx), + }, + "name": types.StringType, }, } } @@ -4025,9 +4081,11 @@ func (o RuleSetUpdateRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o RuleSetUpdateRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "grant_rules": basetypes.ListType{ElemType: GrantRule{}.Type(ctx)}, - "name": types.StringType, + "etag": types.StringType, + "grant_rules": basetypes.ListType{ + ElemType: GrantRule{}.Type(ctx), + }, + "name": types.StringType, }, } } @@ -4130,12 +4188,20 @@ func (o ServicePrincipal) Type(ctx context.Context) attr.Type { "active": types.BoolType, "applicationId": types.StringType, "displayName": types.StringType, - "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "id": types.StringType, - "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, + "entitlements": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "externalId": types.StringType, + "groups": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "id": types.StringType, + "roles": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -4404,7 +4470,9 @@ func (o UpdateWorkspaceAssignments) ToObjectValue(ctx context.Context) basetypes func (o UpdateWorkspaceAssignments) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permissions": basetypes.ListType{ElemType: types.StringType}, + "permissions": basetypes.ListType{ + ElemType: types.StringType, + }, "principal_id": types.Int64Type, "workspace_id": types.Int64Type, }, @@ -4520,17 +4588,27 @@ func (o User) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o User) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "active": types.BoolType, - "displayName": types.StringType, - "emails": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "entitlements": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "externalId": types.StringType, - "groups": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "id": types.StringType, - "name": basetypes.ListType{ElemType: Name{}.Type(ctx)}, - "roles": basetypes.ListType{ElemType: ComplexValue{}.Type(ctx)}, - "schemas": basetypes.ListType{ElemType: types.StringType}, - "userName": types.StringType, + "active": types.BoolType, + "displayName": types.StringType, + "emails": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "entitlements": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "externalId": types.StringType, + "groups": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "id": types.StringType, + "name": basetypes.ListType{ElemType: Name{}.Type(ctx)}, + "roles": basetypes.ListType{ + ElemType: ComplexValue{}.Type(ctx), + }, + "schemas": basetypes.ListType{ + ElemType: types.StringType, + }, + "userName": types.StringType, }, } } @@ -4730,7 +4808,9 @@ func (o WorkspacePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WorkspacePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permissions": basetypes.ListType{ElemType: PermissionOutput{}.Type(ctx)}, + "permissions": basetypes.ListType{ + ElemType: PermissionOutput{}.Type(ctx), + }, }, } } diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index a64f6c3f66..8ea8bc5fd9 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -321,37 +321,45 @@ func (o BaseRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o BaseRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, - "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, - "creator_user_name": types.StringType, - "description": types.StringType, - "end_time": types.Int64Type, - "execution_duration": types.Int64Type, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, - "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, + "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "creator_user_name": types.StringType, + "description": types.StringType, + "end_time": types.Int64Type, + "execution_duration": types.Int64Type, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "job_clusters": basetypes.ListType{ + ElemType: JobCluster{}.Type(ctx), + }, + "job_id": types.Int64Type, + "job_parameters": basetypes.ListType{ + ElemType: JobParameter{}.Type(ctx), + }, "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_name": types.StringType, - "run_page_url": types.StringType, - "run_type": types.StringType, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, - "setup_duration": types.Int64Type, - "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, - "trigger": types.StringType, - "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, + "repair_history": basetypes.ListType{ + ElemType: RepairHistoryItem{}.Type(ctx), + }, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "setup_duration": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "tasks": basetypes.ListType{ + ElemType: RunTask{}.Type(ctx), + }, + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, } } @@ -995,8 +1003,10 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "existing_cluster_id": types.StringType, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, - "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, + "library": basetypes.ListType{ + ElemType: compute_tf.Library{}.Type(ctx), + }, + "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, }, } } @@ -1335,27 +1345,39 @@ func (o CreateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, - "budget_policy_id": types.StringType, - "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, - "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, - "description": types.StringType, - "edit_mode": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, - "format": types.StringType, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: JobAccessControlRequest{}.Type(ctx), + }, + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, + "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environment": basetypes.ListType{ + ElemType: JobEnvironment{}.Type(ctx), + }, + "format": types.StringType, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "job_cluster": basetypes.ListType{ + ElemType: JobCluster{}.Type(ctx), + }, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, - "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, - "tags": basetypes.MapType{ElemType: types.StringType}, - "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "parameter": basetypes.ListType{ + ElemType: JobParameterDefinition{}.Type(ctx), + }, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "task": basetypes.ListType{ + ElemType: Task{}.Type(ctx), + }, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, @@ -1949,8 +1971,10 @@ func (o DbtOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DbtOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "artifacts_headers": basetypes.MapType{ElemType: types.StringType}, - "artifacts_link": types.StringType, + "artifacts_headers": basetypes.MapType{ + ElemType: types.StringType, + }, + "artifacts_link": types.StringType, }, } } @@ -2058,8 +2082,10 @@ func (o DbtTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DbtTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalog": types.StringType, - "commands": basetypes.ListType{ElemType: types.StringType}, + "catalog": types.StringType, + "commands": basetypes.ListType{ + ElemType: types.StringType, + }, "profiles_directory": types.StringType, "project_directory": types.StringType, "schema": types.StringType, @@ -2411,9 +2437,11 @@ func (o EnforcePolicyComplianceResponse) ToObjectValue(ctx context.Context) base func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "has_changes": types.BoolType, - "job_cluster_changes": basetypes.ListType{ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx)}, - "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "has_changes": types.BoolType, + "job_cluster_changes": basetypes.ListType{ + ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx), + }, + "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -2514,7 +2542,9 @@ func (o ExportRunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o ExportRunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "views": basetypes.ListType{ElemType: ViewItem{}.Type(ctx)}, + "views": basetypes.ListType{ + ElemType: ViewItem{}.Type(ctx), + }, }, } } @@ -2691,8 +2721,10 @@ func (o ForEachStats) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ForEachStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error_message_stats": basetypes.ListType{ElemType: ForEachTaskErrorMessageStats{}.Type(ctx)}, - "task_run_stats": basetypes.ListType{ElemType: ForEachTaskTaskRunStats{}.Type(ctx)}, + "error_message_stats": basetypes.ListType{ + ElemType: ForEachTaskErrorMessageStats{}.Type(ctx), + }, + "task_run_stats": basetypes.ListType{ElemType: ForEachTaskTaskRunStats{}.Type(ctx)}, }, } } @@ -3026,7 +3058,9 @@ func (o GetJobPermissionLevelsResponse) ToObjectValue(ctx context.Context) baset func (o GetJobPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: JobPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: JobPermissionsDescription{}.Type(ctx), + }, }, } } @@ -3237,7 +3271,9 @@ func (o GetPolicyComplianceResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, - "violations": basetypes.MapType{ElemType: types.StringType}, + "violations": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -3761,7 +3797,9 @@ func (o JobAccessControlResponse) ToObjectValue(ctx context.Context) basetypes.O func (o JobAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: JobPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: JobPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3923,7 +3961,9 @@ func (o JobCompliance) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "is_compliant": types.BoolType, "job_id": types.Int64Type, - "violations": basetypes.MapType{ElemType: types.StringType}, + "violations": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -4081,12 +4121,22 @@ func (o JobEmailNotifications) ToObjectValue(ctx context.Context) basetypes.Obje func (o JobEmailNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "no_alert_for_skipped_runs": types.BoolType, - "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: types.StringType}, - "on_failure": basetypes.ListType{ElemType: types.StringType}, - "on_start": basetypes.ListType{ElemType: types.StringType}, - "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: types.StringType}, - "on_success": basetypes.ListType{ElemType: types.StringType}, + "no_alert_for_skipped_runs": types.BoolType, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_failure": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_start": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_streaming_backlog_exceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_success": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -4486,9 +4536,11 @@ func (o JobPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o JobPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -4563,9 +4615,11 @@ func (o JobPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o JobPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: JobAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4682,8 +4736,10 @@ func (o JobPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o JobPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, - "job_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: JobAccessControlRequest{}.Type(ctx), + }, + "job_id": types.StringType, }, } } @@ -4941,26 +4997,36 @@ func (o JobSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o JobSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget_policy_id": types.StringType, - "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, - "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, - "description": types.StringType, - "edit_mode": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, - "format": types.StringType, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, + "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environment": basetypes.ListType{ + ElemType: JobEnvironment{}.Type(ctx), + }, + "format": types.StringType, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "job_cluster": basetypes.ListType{ + ElemType: JobCluster{}.Type(ctx), + }, "max_concurrent_runs": types.Int64Type, "name": types.StringType, "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "parameter": basetypes.ListType{ElemType: JobParameterDefinition{}.Type(ctx)}, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, - "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, - "tags": basetypes.MapType{ElemType: types.StringType}, - "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "parameter": basetypes.ListType{ + ElemType: JobParameterDefinition{}.Type(ctx), + }, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "task": basetypes.ListType{ + ElemType: Task{}.Type(ctx), + }, "timeout_seconds": types.Int64Type, "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, @@ -5546,7 +5612,9 @@ func (o JobsHealthRules) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o JobsHealthRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rules": basetypes.ListType{ElemType: JobsHealthRule{}.Type(ctx)}, + "rules": basetypes.ListType{ + ElemType: JobsHealthRule{}.Type(ctx), + }, }, } } @@ -5626,7 +5694,9 @@ func (o ListJobComplianceForPolicyResponse) ToObjectValue(ctx context.Context) b func (o ListJobComplianceForPolicyResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "jobs": basetypes.ListType{ElemType: JobCompliance{}.Type(ctx)}, + "jobs": basetypes.ListType{ + ElemType: JobCompliance{}.Type(ctx), + }, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -5828,8 +5898,10 @@ func (o ListJobsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListJobsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "has_more": types.BoolType, - "jobs": basetypes.ListType{ElemType: BaseJob{}.Type(ctx)}, + "has_more": types.BoolType, + "jobs": basetypes.ListType{ + ElemType: BaseJob{}.Type(ctx), + }, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -6012,7 +6084,9 @@ func (o ListRunsResponse) Type(ctx context.Context) attr.Type { "has_more": types.BoolType, "next_page_token": types.StringType, "prev_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: BaseRun{}.Type(ctx)}, + "runs": basetypes.ListType{ + ElemType: BaseRun{}.Type(ctx), + }, }, } } @@ -6172,10 +6246,12 @@ func (o NotebookTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o NotebookTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "base_parameters": basetypes.MapType{ElemType: types.StringType}, - "notebook_path": types.StringType, - "source": types.StringType, - "warehouse_id": types.StringType, + "base_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "notebook_path": types.StringType, + "source": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -6394,10 +6470,14 @@ func (o PythonWheelTask) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PythonWheelTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "entry_point": types.StringType, - "named_parameters": basetypes.MapType{ElemType: types.StringType}, - "package_name": types.StringType, - "parameters": basetypes.ListType{ElemType: types.StringType}, + "entry_point": types.StringType, + "named_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "package_name": types.StringType, + "parameters": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -6610,13 +6690,15 @@ func (o RepairHistoryItem) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o RepairHistoryItem) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "end_time": types.Int64Type, - "id": types.Int64Type, - "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "task_run_ids": basetypes.ListType{ElemType: types.Int64Type}, - "type": types.StringType, + "end_time": types.Int64Type, + "id": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "task_run_ids": basetypes.ListType{ + ElemType: types.Int64Type, + }, + "type": types.StringType, }, } } @@ -6858,20 +6940,38 @@ func (o RepairRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RepairRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ElemType: types.StringType}, - "jar_params": basetypes.ListType{ElemType: types.StringType}, - "job_parameters": basetypes.MapType{ElemType: types.StringType}, - "latest_repair_id": types.Int64Type, - "notebook_params": basetypes.MapType{ElemType: types.StringType}, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, - "python_named_params": basetypes.MapType{ElemType: types.StringType}, - "python_params": basetypes.ListType{ElemType: types.StringType}, + "dbt_commands": basetypes.ListType{ + ElemType: types.StringType, + }, + "jar_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "job_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "latest_repair_id": types.Int64Type, + "notebook_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "python_params": basetypes.ListType{ + ElemType: types.StringType, + }, "rerun_all_failed_tasks": types.BoolType, "rerun_dependent_tasks": types.BoolType, - "rerun_tasks": basetypes.ListType{ElemType: types.StringType}, - "run_id": types.Int64Type, - "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, - "sql_params": basetypes.MapType{ElemType: types.StringType}, + "rerun_tasks": basetypes.ListType{ + ElemType: types.StringType, + }, + "run_id": types.Int64Type, + "spark_submit_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "sql_params": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -7377,7 +7477,9 @@ func (o ResolvedDbtTaskValues) ToObjectValue(ctx context.Context) basetypes.Obje func (o ResolvedDbtTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "commands": basetypes.ListType{ElemType: types.StringType}, + "commands": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -7446,7 +7548,9 @@ func (o ResolvedNotebookTaskValues) ToObjectValue(ctx context.Context) basetypes func (o ResolvedNotebookTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "base_parameters": basetypes.MapType{ElemType: types.StringType}, + "base_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -7515,7 +7619,9 @@ func (o ResolvedParamPairValues) ToObjectValue(ctx context.Context) basetypes.Ob func (o ResolvedParamPairValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.MapType{ElemType: types.StringType}, + "parameters": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -7588,8 +7694,12 @@ func (o ResolvedPythonWheelTaskValues) ToObjectValue(ctx context.Context) basety func (o ResolvedPythonWheelTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "named_parameters": basetypes.MapType{ElemType: types.StringType}, - "parameters": basetypes.ListType{ElemType: types.StringType}, + "named_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "parameters": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -7688,8 +7798,12 @@ func (o ResolvedRunJobTaskValues) ToObjectValue(ctx context.Context) basetypes.O func (o ResolvedRunJobTaskValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "job_parameters": basetypes.MapType{ElemType: types.StringType}, - "parameters": basetypes.MapType{ElemType: types.StringType}, + "job_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "parameters": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -7784,7 +7898,9 @@ func (o ResolvedStringParamsValues) ToObjectValue(ctx context.Context) basetypes func (o ResolvedStringParamsValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ElemType: types.StringType}, + "parameters": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -8377,39 +8493,49 @@ func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, - "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, - "creator_user_name": types.StringType, - "description": types.StringType, - "end_time": types.Int64Type, - "execution_duration": types.Int64Type, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "iterations": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, - "job_clusters": basetypes.ListType{ElemType: JobCluster{}.Type(ctx)}, - "job_id": types.Int64Type, - "job_parameters": basetypes.ListType{ElemType: JobParameter{}.Type(ctx)}, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, + "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "creator_user_name": types.StringType, + "description": types.StringType, + "end_time": types.Int64Type, + "execution_duration": types.Int64Type, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "iterations": basetypes.ListType{ + ElemType: RunTask{}.Type(ctx), + }, + "job_clusters": basetypes.ListType{ + ElemType: JobCluster{}.Type(ctx), + }, + "job_id": types.Int64Type, + "job_parameters": basetypes.ListType{ + ElemType: JobParameter{}.Type(ctx), + }, "job_run_id": types.Int64Type, "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, "queue_duration": types.Int64Type, - "repair_history": basetypes.ListType{ElemType: RepairHistoryItem{}.Type(ctx)}, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_name": types.StringType, - "run_page_url": types.StringType, - "run_type": types.StringType, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, - "setup_duration": types.Int64Type, - "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "tasks": basetypes.ListType{ElemType: RunTask{}.Type(ctx)}, - "trigger": types.StringType, - "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, + "repair_history": basetypes.ListType{ + ElemType: RepairHistoryItem{}.Type(ctx), + }, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "setup_duration": types.Int64Type, + "start_time": types.Int64Type, + "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, + "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "tasks": basetypes.ListType{ + ElemType: RunTask{}.Type(ctx), + }, + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, }, } } @@ -9113,16 +9239,32 @@ func (o RunJobTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunJobTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ElemType: types.StringType}, - "jar_params": basetypes.ListType{ElemType: types.StringType}, - "job_id": types.Int64Type, - "job_parameters": basetypes.MapType{ElemType: types.StringType}, - "notebook_params": basetypes.MapType{ElemType: types.StringType}, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, - "python_named_params": basetypes.MapType{ElemType: types.StringType}, - "python_params": basetypes.ListType{ElemType: types.StringType}, - "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, - "sql_params": basetypes.MapType{ElemType: types.StringType}, + "dbt_commands": basetypes.ListType{ + ElemType: types.StringType, + }, + "jar_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "job_id": types.Int64Type, + "job_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "notebook_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "python_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "spark_submit_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "sql_params": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -9527,19 +9669,37 @@ func (o RunNow) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunNow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ElemType: types.StringType}, - "idempotency_token": types.StringType, - "jar_params": basetypes.ListType{ElemType: types.StringType}, - "job_id": types.Int64Type, - "job_parameters": basetypes.MapType{ElemType: types.StringType}, - "notebook_params": basetypes.MapType{ElemType: types.StringType}, - "only": basetypes.ListType{ElemType: types.StringType}, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, - "python_named_params": basetypes.MapType{ElemType: types.StringType}, - "python_params": basetypes.ListType{ElemType: types.StringType}, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, - "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, - "sql_params": basetypes.MapType{ElemType: types.StringType}, + "dbt_commands": basetypes.ListType{ + ElemType: types.StringType, + }, + "idempotency_token": types.StringType, + "jar_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "job_id": types.Int64Type, + "job_parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "notebook_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "only": basetypes.ListType{ + ElemType: types.StringType, + }, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "python_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "spark_submit_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "sql_params": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -10242,14 +10402,28 @@ func (o RunParameters) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o RunParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_commands": basetypes.ListType{ElemType: types.StringType}, - "jar_params": basetypes.ListType{ElemType: types.StringType}, - "notebook_params": basetypes.MapType{ElemType: types.StringType}, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, - "python_named_params": basetypes.MapType{ElemType: types.StringType}, - "python_params": basetypes.ListType{ElemType: types.StringType}, - "spark_submit_params": basetypes.ListType{ElemType: types.StringType}, - "sql_params": basetypes.MapType{ElemType: types.StringType}, + "dbt_commands": basetypes.ListType{ + ElemType: types.StringType, + }, + "jar_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "notebook_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "python_named_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "python_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "spark_submit_params": basetypes.ListType{ + ElemType: types.StringType, + }, + "sql_params": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -10893,22 +11067,26 @@ func (o RunTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, - "condition_task": basetypes.ListType{ElemType: RunConditionTask{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, - "description": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "end_time": types.Int64Type, - "environment_key": types.StringType, - "execution_duration": types.Int64Type, - "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ElemType: RunForEachTask{}.Type(ctx)}, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, + "condition_task": basetypes.ListType{ElemType: RunConditionTask{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "depends_on": basetypes.ListType{ + ElemType: TaskDependency{}.Type(ctx), + }, + "description": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "end_time": types.Int64Type, + "environment_key": types.StringType, + "execution_duration": types.Int64Type, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ElemType: RunForEachTask{}.Type(ctx)}, + "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "job_cluster_key": types.StringType, + "library": basetypes.ListType{ + ElemType: compute_tf.Library{}.Type(ctx), + }, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, @@ -11565,7 +11743,9 @@ func (o SparkJarTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "jar_uri": types.StringType, "main_class_name": types.StringType, - "parameters": basetypes.ListType{ElemType: types.StringType}, + "parameters": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -11658,7 +11838,9 @@ func (o SparkPythonTask) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o SparkPythonTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ElemType: types.StringType}, + "parameters": basetypes.ListType{ + ElemType: types.StringType, + }, "python_file": types.StringType, "source": types.StringType, }, @@ -11735,7 +11917,9 @@ func (o SparkSubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o SparkSubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "parameters": basetypes.ListType{ElemType: types.StringType}, + "parameters": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -11822,11 +12006,13 @@ func (o SqlAlertOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o SqlAlertOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert_state": types.StringType, - "output_link": types.StringType, - "query_text": types.StringType, - "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, - "warehouse_id": types.StringType, + "alert_state": types.StringType, + "output_link": types.StringType, + "query_text": types.StringType, + "sql_statements": basetypes.ListType{ + ElemType: SqlStatementOutput{}.Type(ctx), + }, + "warehouse_id": types.StringType, }, } } @@ -11900,7 +12086,9 @@ func (o SqlDashboardOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "warehouse_id": types.StringType, - "widgets": basetypes.ListType{ElemType: SqlDashboardWidgetOutput{}.Type(ctx)}, + "widgets": basetypes.ListType{ + ElemType: SqlDashboardWidgetOutput{}.Type(ctx), + }, }, } } @@ -12250,11 +12438,13 @@ func (o SqlQueryOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o SqlQueryOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoint_id": types.StringType, - "output_link": types.StringType, - "query_text": types.StringType, - "sql_statements": basetypes.ListType{ElemType: SqlStatementOutput{}.Type(ctx)}, - "warehouse_id": types.StringType, + "endpoint_id": types.StringType, + "output_link": types.StringType, + "query_text": types.StringType, + "sql_statements": basetypes.ListType{ + ElemType: SqlStatementOutput{}.Type(ctx), + }, + "warehouse_id": types.StringType, }, } } @@ -12390,10 +12580,12 @@ func (o SqlTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SqlTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ElemType: SqlTaskAlert{}.Type(ctx)}, - "dashboard": basetypes.ListType{ElemType: SqlTaskDashboard{}.Type(ctx)}, - "file": basetypes.ListType{ElemType: SqlTaskFile{}.Type(ctx)}, - "parameters": basetypes.MapType{ElemType: types.StringType}, + "alert": basetypes.ListType{ElemType: SqlTaskAlert{}.Type(ctx)}, + "dashboard": basetypes.ListType{ElemType: SqlTaskDashboard{}.Type(ctx)}, + "file": basetypes.ListType{ElemType: SqlTaskFile{}.Type(ctx)}, + "parameters": basetypes.MapType{ + ElemType: types.StringType, + }, "query": basetypes.ListType{ElemType: SqlTaskQuery{}.Type(ctx)}, "warehouse_id": types.StringType, }, @@ -12577,7 +12769,9 @@ func (o SqlTaskAlert) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, + "subscriptions": basetypes.ListType{ + ElemType: SqlTaskSubscription{}.Type(ctx), + }, }, } } @@ -12660,7 +12854,9 @@ func (o SqlTaskDashboard) Type(ctx context.Context) attr.Type { "custom_subject": types.StringType, "dashboard_id": types.StringType, "pause_subscriptions": types.BoolType, - "subscriptions": basetypes.ListType{ElemType: SqlTaskSubscription{}.Type(ctx)}, + "subscriptions": basetypes.ListType{ + ElemType: SqlTaskSubscription{}.Type(ctx), + }, }, } } @@ -12956,10 +13152,14 @@ func (o SubmitRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: JobAccessControlRequest{}.Type(ctx)}, - "budget_policy_id": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environments": basetypes.ListType{ElemType: JobEnvironment{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: JobAccessControlRequest{}.Type(ctx), + }, + "budget_policy_id": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environments": basetypes.ListType{ + ElemType: JobEnvironment{}.Type(ctx), + }, "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, "idempotency_token": types.StringType, @@ -12967,7 +13167,9 @@ func (o SubmitRun) Type(ctx context.Context) attr.Type { "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, "run_name": types.StringType, - "tasks": basetypes.ListType{ElemType: SubmitTask{}.Type(ctx)}, + "tasks": basetypes.ListType{ + ElemType: SubmitTask{}.Type(ctx), + }, "timeout_seconds": types.Int64Type, "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, }, @@ -13451,16 +13653,20 @@ func (o SubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, - "description": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, - "environment_key": types.StringType, - "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "depends_on": basetypes.ListType{ + ElemType: TaskDependency{}.Type(ctx), + }, + "description": types.StringType, + "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "environment_key": types.StringType, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, + "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "library": basetypes.ListType{ + ElemType: compute_tf.Library{}.Type(ctx), + }, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, @@ -14003,8 +14209,10 @@ func (o TableUpdateTriggerConfiguration) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "condition": types.StringType, "min_time_between_triggers_seconds": types.Int64Type, - "table_names": basetypes.ListType{ElemType: types.StringType}, - "wait_after_last_change_seconds": types.Int64Type, + "table_names": basetypes.ListType{ + ElemType: types.StringType, + }, + "wait_after_last_change_seconds": types.Int64Type, }, } } @@ -14237,9 +14445,11 @@ func (o Task) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Task) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, - "depends_on": basetypes.ListType{ElemType: TaskDependency{}.Type(ctx)}, + "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, + "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "depends_on": basetypes.ListType{ + ElemType: TaskDependency{}.Type(ctx), + }, "description": types.StringType, "disable_auto_optimization": types.BoolType, "email_notifications": basetypes.ListType{ElemType: TaskEmailNotifications{}.Type(ctx)}, @@ -14248,7 +14458,9 @@ func (o Task) Type(ctx context.Context) attr.Type { "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, "job_cluster_key": types.StringType, - "library": basetypes.ListType{ElemType: compute_tf.Library{}.Type(ctx)}, + "library": basetypes.ListType{ + ElemType: compute_tf.Library{}.Type(ctx), + }, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, @@ -14864,12 +15076,22 @@ func (o TaskEmailNotifications) ToObjectValue(ctx context.Context) basetypes.Obj func (o TaskEmailNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "no_alert_for_skipped_runs": types.BoolType, - "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: types.StringType}, - "on_failure": basetypes.ListType{ElemType: types.StringType}, - "on_start": basetypes.ListType{ElemType: types.StringType}, - "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: types.StringType}, - "on_success": basetypes.ListType{ElemType: types.StringType}, + "no_alert_for_skipped_runs": types.BoolType, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_failure": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_start": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_streaming_backlog_exceeded": basetypes.ListType{ + ElemType: types.StringType, + }, + "on_success": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -15428,9 +15650,11 @@ func (o UpdateJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o UpdateJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fields_to_remove": basetypes.ListType{ElemType: types.StringType}, - "job_id": types.Int64Type, - "new_settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "fields_to_remove": basetypes.ListType{ + ElemType: types.StringType, + }, + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, }, } } @@ -15685,11 +15909,21 @@ func (o WebhookNotifications) ToObjectValue(ctx context.Context) basetypes.Objec func (o WebhookNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "on_duration_warning_threshold_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_failure": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_start": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_streaming_backlog_exceeded": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, - "on_success": basetypes.ListType{ElemType: Webhook{}.Type(ctx)}, + "on_duration_warning_threshold_exceeded": basetypes.ListType{ + ElemType: Webhook{}.Type(ctx), + }, + "on_failure": basetypes.ListType{ + ElemType: Webhook{}.Type(ctx), + }, + "on_start": basetypes.ListType{ + ElemType: Webhook{}.Type(ctx), + }, + "on_streaming_backlog_exceeded": basetypes.ListType{ + ElemType: Webhook{}.Type(ctx), + }, + "on_success": basetypes.ListType{ + ElemType: Webhook{}.Type(ctx), + }, }, } } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 5c5145f045..8d8b8454b1 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -174,7 +174,9 @@ func (o BatchGetListingsRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o BatchGetListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ids": basetypes.ListType{ElemType: types.StringType}, + "ids": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -243,7 +245,9 @@ func (o BatchGetListingsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o BatchGetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, }, } } @@ -313,7 +317,9 @@ func (o BatchGetProvidersRequest) ToObjectValue(ctx context.Context) basetypes.O func (o BatchGetProvidersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ids": basetypes.ListType{ElemType: types.StringType}, + "ids": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -382,7 +388,9 @@ func (o BatchGetProvidersResponse) ToObjectValue(ctx context.Context) basetypes. func (o BatchGetProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "providers": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } @@ -1942,15 +1950,19 @@ func (o Exchange) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Exchange) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, - "id": types.StringType, - "linked_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, - "name": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "filters": basetypes.ListType{ + ElemType: ExchangeFilter{}.Type(ctx), + }, + "id": types.StringType, + "linked_listings": basetypes.ListType{ + ElemType: ExchangeListing{}.Type(ctx), + }, + "name": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -2651,8 +2663,10 @@ func (o GetListingContentMetadataResponse) ToObjectValue(ctx context.Context) ba func (o GetListingContentMetadataResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "shared_data_objects": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, + "next_page_token": types.StringType, + "shared_data_objects": basetypes.ListType{ + ElemType: SharedDataObject{}.Type(ctx), + }, }, } } @@ -2881,7 +2895,9 @@ func (o GetListingsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -2993,7 +3009,9 @@ func (o GetPersonalizationRequestResponse) ToObjectValue(ctx context.Context) ba func (o GetPersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, + "personalization_requests": basetypes.ListType{ + ElemType: PersonalizationRequest{}.Type(ctx), + }, }, } } @@ -3291,7 +3309,9 @@ func (o InstallationDetail) Type(ctx context.Context) attr.Type { "share_name": types.StringType, "status": types.StringType, "token_detail": basetypes.ListType{ElemType: TokenDetail{}.Type(ctx)}, - "tokens": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, + "tokens": basetypes.ListType{ + ElemType: TokenInfo{}.Type(ctx), + }, }, } } @@ -3435,7 +3455,9 @@ func (o ListAllInstallationsResponse) ToObjectValue(ctx context.Context) basetyp func (o ListAllInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installations": basetypes.ListType{ + ElemType: InstallationDetail{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -3554,8 +3576,10 @@ func (o ListAllPersonalizationRequestsResponse) ToObjectValue(ctx context.Contex func (o ListAllPersonalizationRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "personalization_requests": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, + "next_page_token": types.StringType, + "personalization_requests": basetypes.ListType{ + ElemType: PersonalizationRequest{}.Type(ctx), + }, }, } } @@ -3677,7 +3701,9 @@ func (o ListExchangeFiltersResponse) ToObjectValue(ctx context.Context) basetype func (o ListExchangeFiltersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filters": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "filters": basetypes.ListType{ + ElemType: ExchangeFilter{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -3800,8 +3826,10 @@ func (o ListExchangesForListingResponse) ToObjectValue(ctx context.Context) base func (o ListExchangesForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listing": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, - "next_page_token": types.StringType, + "exchange_listing": basetypes.ListType{ + ElemType: ExchangeListing{}.Type(ctx), + }, + "next_page_token": types.StringType, }, } } @@ -3919,7 +3947,9 @@ func (o ListExchangesResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListExchangesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchanges": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, + "exchanges": basetypes.ListType{ + ElemType: Exchange{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4070,7 +4100,9 @@ func (o ListFilesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ListFilesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "file_infos": basetypes.ListType{ + ElemType: FileInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4193,7 +4225,9 @@ func (o ListFulfillmentsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListFulfillmentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fulfillments": basetypes.ListType{ElemType: ListingFulfillment{}.Type(ctx)}, + "fulfillments": basetypes.ListType{ + ElemType: ListingFulfillment{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4316,7 +4350,9 @@ func (o ListInstallationsResponse) ToObjectValue(ctx context.Context) basetypes. func (o ListInstallationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installations": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installations": basetypes.ListType{ + ElemType: InstallationDetail{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4439,8 +4475,10 @@ func (o ListListingsForExchangeResponse) ToObjectValue(ctx context.Context) base func (o ListListingsForExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_listings": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, - "next_page_token": types.StringType, + "exchange_listings": basetypes.ListType{ + ElemType: ExchangeListing{}.Type(ctx), + }, + "next_page_token": types.StringType, }, } } @@ -4538,15 +4576,23 @@ func (o ListListingsRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o ListListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ElemType: types.StringType}, - "categories": basetypes.ListType{ElemType: types.StringType}, + "assets": basetypes.ListType{ + ElemType: types.StringType, + }, + "categories": basetypes.ListType{ + ElemType: types.StringType, + }, "is_free": types.BoolType, "is_private_exchange": types.BoolType, "is_staff_pick": types.BoolType, "page_size": types.Int64Type, "page_token": types.StringType, - "provider_ids": basetypes.ListType{ElemType: types.StringType}, - "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, + "provider_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "tags": basetypes.ListType{ + ElemType: ListingTag{}.Type(ctx), + }, }, } } @@ -4696,7 +4742,9 @@ func (o ListListingsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4870,7 +4918,9 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "providers": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } @@ -5113,25 +5163,33 @@ func (o ListingDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ListingDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ElemType: types.StringType}, - "collection_date_end": types.Int64Type, - "collection_date_start": types.Int64Type, - "collection_granularity": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, - "cost": types.StringType, - "data_source": types.StringType, - "description": types.StringType, - "documentation_link": types.StringType, - "embedded_notebook_file_infos": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, - "file_ids": basetypes.ListType{ElemType: types.StringType}, - "geographical_coverage": types.StringType, - "license": types.StringType, - "pricing_model": types.StringType, - "privacy_policy_link": types.StringType, - "size": types.Float64Type, - "support_link": types.StringType, - "tags": basetypes.ListType{ElemType: ListingTag{}.Type(ctx)}, - "terms_of_service": types.StringType, - "update_frequency": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, + "assets": basetypes.ListType{ + ElemType: types.StringType, + }, + "collection_date_end": types.Int64Type, + "collection_date_start": types.Int64Type, + "collection_granularity": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, + "cost": types.StringType, + "data_source": types.StringType, + "description": types.StringType, + "documentation_link": types.StringType, + "embedded_notebook_file_infos": basetypes.ListType{ + ElemType: FileInfo{}.Type(ctx), + }, + "file_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "geographical_coverage": types.StringType, + "license": types.StringType, + "pricing_model": types.StringType, + "privacy_policy_link": types.StringType, + "size": types.Float64Type, + "support_link": types.StringType, + "tags": basetypes.ListType{ + ElemType: ListingTag{}.Type(ctx), + }, + "terms_of_service": types.StringType, + "update_frequency": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, }, } } @@ -5544,11 +5602,15 @@ func (o ListingSummary) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ListingSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "categories": basetypes.ListType{ElemType: types.StringType}, - "created_at": types.Int64Type, - "created_by": types.StringType, - "created_by_id": types.Int64Type, - "exchange_ids": basetypes.ListType{ElemType: types.StringType}, + "categories": basetypes.ListType{ + ElemType: types.StringType, + }, + "created_at": types.Int64Type, + "created_by": types.StringType, + "created_by_id": types.Int64Type, + "exchange_ids": basetypes.ListType{ + ElemType: types.StringType, + }, "git_repo": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, "listingType": types.StringType, "name": types.StringType, @@ -5766,8 +5828,10 @@ func (o ListingTag) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListingTag) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "tag_name": types.StringType, - "tag_values": basetypes.ListType{ElemType: types.StringType}, + "tag_name": types.StringType, + "tag_values": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -6392,14 +6456,20 @@ func (o SearchListingsRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o SearchListingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "assets": basetypes.ListType{ElemType: types.StringType}, - "categories": basetypes.ListType{ElemType: types.StringType}, + "assets": basetypes.ListType{ + ElemType: types.StringType, + }, + "categories": basetypes.ListType{ + ElemType: types.StringType, + }, "is_free": types.BoolType, "is_private_exchange": types.BoolType, "page_size": types.Int64Type, "page_token": types.StringType, - "provider_ids": basetypes.ListType{ElemType: types.StringType}, - "query": types.StringType, + "provider_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "query": types.StringType, }, } } @@ -6523,7 +6593,9 @@ func (o SearchListingsResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o SearchListingsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listings": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listings": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, "next_page_token": types.StringType, }, } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index f6518c907e..7c104a4af5 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -322,7 +322,9 @@ func (o CommentObject) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CommentObject) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "available_actions": basetypes.ListType{ElemType: types.StringType}, + "available_actions": basetypes.ListType{ + ElemType: types.StringType, + }, "comment": types.StringType, "creation_timestamp": types.Int64Type, "id": types.StringType, @@ -530,7 +532,9 @@ func (o CreateExperiment) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "artifact_location": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: ExperimentTag{}.Type(ctx), + }, }, } } @@ -650,7 +654,9 @@ func (o CreateModelRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "description": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: ModelTag{}.Type(ctx), + }, }, } } @@ -811,7 +817,9 @@ func (o CreateModelVersionRequest) Type(ctx context.Context) attr.Type { "run_id": types.StringType, "run_link": types.StringType, "source": types.StringType, - "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: ModelVersionTag{}.Type(ctx), + }, }, } } @@ -1007,8 +1015,10 @@ func (o CreateRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "description": types.StringType, - "events": basetypes.ListType{ElemType: types.StringType}, + "description": types.StringType, + "events": basetypes.ListType{ + ElemType: types.StringType, + }, "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpec{}.Type(ctx)}, "job_spec": basetypes.ListType{ElemType: JobSpec{}.Type(ctx)}, "model_name": types.StringType, @@ -1147,8 +1157,10 @@ func (o CreateRun) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "experiment_id": types.StringType, "start_time": types.Int64Type, - "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, - "user_id": types.StringType, + "tags": basetypes.ListType{ + ElemType: RunTag{}.Type(ctx), + }, + "user_id": types.StringType, }, } } @@ -1565,7 +1577,9 @@ func (o DatasetInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dataset": basetypes.ListType{ElemType: Dataset{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: InputTag{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: InputTag{}.Type(ctx), + }, }, } } @@ -2615,7 +2629,9 @@ func (o Experiment) Type(ctx context.Context) attr.Type { "last_update_time": types.Int64Type, "lifecycle_stage": types.StringType, "name": types.StringType, - "tags": basetypes.ListType{ElemType: ExperimentTag{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: ExperimentTag{}.Type(ctx), + }, }, } } @@ -2751,7 +2767,9 @@ func (o ExperimentAccessControlResponse) ToObjectValue(ctx context.Context) base func (o ExperimentAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ExperimentPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: ExperimentPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -2830,9 +2848,11 @@ func (o ExperimentPermission) ToObjectValue(ctx context.Context) basetypes.Objec func (o ExperimentPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -2907,9 +2927,11 @@ func (o ExperimentPermissions) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExperimentPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ExperimentAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3026,8 +3048,10 @@ func (o ExperimentPermissionsRequest) ToObjectValue(ctx context.Context) basetyp func (o ExperimentPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ExperimentAccessControlRequest{}.Type(ctx)}, - "experiment_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ExperimentAccessControlRequest{}.Type(ctx), + }, + "experiment_id": types.StringType, }, } } @@ -3279,7 +3303,9 @@ func (o GetExperimentPermissionLevelsResponse) ToObjectValue(ctx context.Context func (o GetExperimentPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ExperimentPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: ExperimentPermissionsDescription{}.Type(ctx), + }, }, } } @@ -3570,8 +3596,10 @@ func (o GetLatestVersionsRequest) ToObjectValue(ctx context.Context) basetypes.O func (o GetLatestVersionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "stages": basetypes.ListType{ElemType: types.StringType}, + "name": types.StringType, + "stages": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3643,7 +3671,9 @@ func (o GetLatestVersionsResponse) ToObjectValue(ctx context.Context) basetypes. func (o GetLatestVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "model_versions": basetypes.ListType{ + ElemType: ModelVersion{}.Type(ctx), + }, }, } } @@ -3717,7 +3747,9 @@ func (o GetMetricHistoryResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetMetricHistoryResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, + "metrics": basetypes.ListType{ + ElemType: Metric{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4148,7 +4180,9 @@ func (o GetRegisteredModelPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetRegisteredModelPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: RegisteredModelPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: RegisteredModelPermissionsDescription{}.Type(ctx), + }, }, } } @@ -4711,7 +4745,9 @@ func (o ListArtifactsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListArtifactsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "files": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "files": basetypes.ListType{ + ElemType: FileInfo{}.Type(ctx), + }, "next_page_token": types.StringType, "root_uri": types.StringType, }, @@ -4844,7 +4880,9 @@ func (o ListExperimentsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, + "experiments": basetypes.ListType{ + ElemType: Experiment{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -4965,8 +5003,10 @@ func (o ListModelsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ + ElemType: Model{}.Type(ctx), + }, }, } } @@ -5040,7 +5080,9 @@ func (o ListRegistryWebhooks) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "webhooks": basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}, + "webhooks": basetypes.ListType{ + ElemType: RegistryWebhook{}.Type(ctx), + }, }, } } @@ -5157,7 +5199,9 @@ func (o ListTransitionRequestsResponse) ToObjectValue(ctx context.Context) baset func (o ListTransitionRequestsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "requests": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, + "requests": basetypes.ListType{ + ElemType: Activity{}.Type(ctx), + }, }, } } @@ -5237,7 +5281,9 @@ func (o ListWebhooksRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o ListWebhooksRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: types.StringType}, + "events": basetypes.ListType{ + ElemType: types.StringType, + }, "model_name": types.StringType, "page_token": types.StringType, }, @@ -5323,10 +5369,16 @@ func (o LogBatch) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogBatch) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, - "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, - "run_id": types.StringType, - "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, + "metrics": basetypes.ListType{ + ElemType: Metric{}.Type(ctx), + }, + "params": basetypes.ListType{ + ElemType: Param{}.Type(ctx), + }, + "run_id": types.StringType, + "tags": basetypes.ListType{ + ElemType: RunTag{}.Type(ctx), + }, }, } } @@ -5487,8 +5539,10 @@ func (o LogInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LogInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "datasets": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, - "run_id": types.StringType, + "datasets": basetypes.ListType{ + ElemType: DatasetInput{}.Type(ctx), + }, + "run_id": types.StringType, }, } } @@ -5944,10 +5998,14 @@ func (o Model) Type(ctx context.Context) attr.Type { "creation_timestamp": types.Int64Type, "description": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, - "name": types.StringType, - "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, - "user_id": types.StringType, + "latest_versions": basetypes.ListType{ + ElemType: ModelVersion{}.Type(ctx), + }, + "name": types.StringType, + "tags": basetypes.ListType{ + ElemType: ModelTag{}.Type(ctx), + }, + "user_id": types.StringType, }, } } @@ -6073,11 +6131,15 @@ func (o ModelDatabricks) Type(ctx context.Context) attr.Type { "description": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, - "latest_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, - "name": types.StringType, - "permission_level": types.StringType, - "tags": basetypes.ListType{ElemType: ModelTag{}.Type(ctx)}, - "user_id": types.StringType, + "latest_versions": basetypes.ListType{ + ElemType: ModelVersion{}.Type(ctx), + }, + "name": types.StringType, + "permission_level": types.StringType, + "tags": basetypes.ListType{ + ElemType: ModelTag{}.Type(ctx), + }, + "user_id": types.StringType, }, } } @@ -6268,9 +6330,11 @@ func (o ModelVersion) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, - "user_id": types.StringType, - "version": types.StringType, + "tags": basetypes.ListType{ + ElemType: ModelVersionTag{}.Type(ctx), + }, + "user_id": types.StringType, + "version": types.StringType, }, } } @@ -6410,9 +6474,11 @@ func (o ModelVersionDatabricks) Type(ctx context.Context) attr.Type { "source": types.StringType, "status": types.StringType, "status_message": types.StringType, - "tags": basetypes.ListType{ElemType: ModelVersionTag{}.Type(ctx)}, - "user_id": types.StringType, - "version": types.StringType, + "tags": basetypes.ListType{ + ElemType: ModelVersionTag{}.Type(ctx), + }, + "user_id": types.StringType, + "version": types.StringType, }, } } @@ -6640,7 +6706,9 @@ func (o RegisteredModelAccessControlResponse) ToObjectValue(ctx context.Context) func (o RegisteredModelAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: RegisteredModelPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: RegisteredModelPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6719,9 +6787,11 @@ func (o RegisteredModelPermission) ToObjectValue(ctx context.Context) basetypes. func (o RegisteredModelPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -6796,9 +6866,11 @@ func (o RegisteredModelPermissions) ToObjectValue(ctx context.Context) basetypes func (o RegisteredModelPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: RegisteredModelAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -6915,7 +6987,9 @@ func (o RegisteredModelPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o RegisteredModelPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RegisteredModelAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: RegisteredModelAccessControlRequest{}.Type(ctx), + }, "registered_model_id": types.StringType, }, } @@ -7051,9 +7125,11 @@ func (o RegistryWebhook) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "description": types.StringType, - "events": basetypes.ListType{ElemType: types.StringType}, + "creation_timestamp": types.Int64Type, + "description": types.StringType, + "events": basetypes.ListType{ + ElemType: types.StringType, + }, "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpecWithoutSecret{}.Type(ctx)}, "id": types.StringType, "job_spec": basetypes.ListType{ElemType: JobSpecWithoutSecret{}.Type(ctx)}, @@ -7819,9 +7895,15 @@ func (o RunData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metrics": basetypes.ListType{ElemType: Metric{}.Type(ctx)}, - "params": basetypes.ListType{ElemType: Param{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: RunTag{}.Type(ctx)}, + "metrics": basetypes.ListType{ + ElemType: Metric{}.Type(ctx), + }, + "params": basetypes.ListType{ + ElemType: Param{}.Type(ctx), + }, + "tags": basetypes.ListType{ + ElemType: RunTag{}.Type(ctx), + }, }, } } @@ -8023,7 +8105,9 @@ func (o RunInputs) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunInputs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataset_inputs": basetypes.ListType{ElemType: DatasetInput{}.Type(ctx)}, + "dataset_inputs": basetypes.ListType{ + ElemType: DatasetInput{}.Type(ctx), + }, }, } } @@ -8158,9 +8242,11 @@ func (o SearchExperiments) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ElemType: types.StringType}, - "page_token": types.StringType, - "view_type": types.StringType, + "order_by": basetypes.ListType{ + ElemType: types.StringType, + }, + "page_token": types.StringType, + "view_type": types.StringType, }, } } @@ -8234,7 +8320,9 @@ func (o SearchExperimentsResponse) ToObjectValue(ctx context.Context) basetypes. func (o SearchExperimentsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiments": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, + "experiments": basetypes.ListType{ + ElemType: Experiment{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -8321,8 +8409,10 @@ func (o SearchModelVersionsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ElemType: types.StringType}, - "page_token": types.StringType, + "order_by": basetypes.ListType{ + ElemType: types.StringType, + }, + "page_token": types.StringType, }, } } @@ -8396,7 +8486,9 @@ func (o SearchModelVersionsResponse) ToObjectValue(ctx context.Context) basetype func (o SearchModelVersionsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_versions": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "model_versions": basetypes.ListType{ + ElemType: ModelVersion{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -8483,8 +8575,10 @@ func (o SearchModelsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ElemType: types.StringType}, - "page_token": types.StringType, + "order_by": basetypes.ListType{ + ElemType: types.StringType, + }, + "page_token": types.StringType, }, } } @@ -8557,8 +8651,10 @@ func (o SearchModelsResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o SearchModelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "next_page_token": types.StringType, - "registered_models": basetypes.ListType{ElemType: Model{}.Type(ctx)}, + "next_page_token": types.StringType, + "registered_models": basetypes.ListType{ + ElemType: Model{}.Type(ctx), + }, }, } } @@ -8661,12 +8757,16 @@ func (o SearchRuns) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SearchRuns) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiment_ids": basetypes.ListType{ElemType: types.StringType}, - "filter": types.StringType, - "max_results": types.Int64Type, - "order_by": basetypes.ListType{ElemType: types.StringType}, - "page_token": types.StringType, - "run_view_type": types.StringType, + "experiment_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "filter": types.StringType, + "max_results": types.Int64Type, + "order_by": basetypes.ListType{ + ElemType: types.StringType, + }, + "page_token": types.StringType, + "run_view_type": types.StringType, }, } } @@ -8766,7 +8866,9 @@ func (o SearchRunsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "runs": basetypes.ListType{ElemType: Run{}.Type(ctx)}, + "runs": basetypes.ListType{ + ElemType: Run{}.Type(ctx), + }, }, } } @@ -9459,7 +9561,9 @@ func (o TransitionRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o TransitionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "available_actions": basetypes.ListType{ElemType: types.StringType}, + "available_actions": basetypes.ListType{ + ElemType: types.StringType, + }, "comment": types.StringType, "creation_timestamp": types.Int64Type, "to_stage": types.StringType, @@ -10025,8 +10129,10 @@ func (o UpdateRegistryWebhook) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateRegistryWebhook) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "description": types.StringType, - "events": basetypes.ListType{ElemType: types.StringType}, + "description": types.StringType, + "events": basetypes.ListType{ + ElemType: types.StringType, + }, "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpec{}.Type(ctx)}, "id": types.StringType, "job_spec": basetypes.ListType{ElemType: JobSpec{}.Type(ctx)}, diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 02bf433cb5..1e9b022b29 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -76,10 +76,14 @@ func (o CreateCustomAppIntegration) ToObjectValue(ctx context.Context) basetypes func (o CreateCustomAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "confidential": types.BoolType, - "name": types.StringType, - "redirect_urls": basetypes.ListType{ElemType: types.StringType}, - "scopes": basetypes.ListType{ElemType: types.StringType}, + "confidential": types.BoolType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ + ElemType: types.StringType, + }, + "scopes": basetypes.ListType{ + ElemType: types.StringType, + }, "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } @@ -790,15 +794,19 @@ func (o GetCustomAppIntegrationOutput) ToObjectValue(ctx context.Context) basety func (o GetCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "client_id": types.StringType, - "confidential": types.BoolType, - "create_time": types.StringType, - "created_by": types.Int64Type, - "creator_username": types.StringType, - "integration_id": types.StringType, - "name": types.StringType, - "redirect_urls": basetypes.ListType{ElemType: types.StringType}, - "scopes": basetypes.ListType{ElemType: types.StringType}, + "client_id": types.StringType, + "confidential": types.BoolType, + "create_time": types.StringType, + "created_by": types.Int64Type, + "creator_username": types.StringType, + "integration_id": types.StringType, + "name": types.StringType, + "redirect_urls": basetypes.ListType{ + ElemType: types.StringType, + }, + "scopes": basetypes.ListType{ + ElemType: types.StringType, + }, "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } @@ -967,7 +975,9 @@ func (o GetCustomAppIntegrationsOutput) ToObjectValue(ctx context.Context) baset func (o GetCustomAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: GetCustomAppIntegrationOutput{}.Type(ctx)}, + "apps": basetypes.ListType{ + ElemType: GetCustomAppIntegrationOutput{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1173,7 +1183,9 @@ func (o GetPublishedAppIntegrationsOutput) ToObjectValue(ctx context.Context) ba func (o GetPublishedAppIntegrationsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx)}, + "apps": basetypes.ListType{ + ElemType: GetPublishedAppIntegrationOutput{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1248,7 +1260,9 @@ func (o GetPublishedAppsOutput) ToObjectValue(ctx context.Context) basetypes.Obj func (o GetPublishedAppsOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apps": basetypes.ListType{ElemType: PublishedAppOutput{}.Type(ctx)}, + "apps": basetypes.ListType{ + ElemType: PublishedAppOutput{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1521,7 +1535,9 @@ func (o ListServicePrincipalSecretsResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "secrets": basetypes.ListType{ElemType: SecretInfo{}.Type(ctx)}, + "secrets": basetypes.ListType{ + ElemType: SecretInfo{}.Type(ctx), + }, }, } } @@ -1617,8 +1633,12 @@ func (o PublishedAppOutput) Type(ctx context.Context) attr.Type { "description": types.StringType, "is_confidential_client": types.BoolType, "name": types.StringType, - "redirect_urls": basetypes.ListType{ElemType: types.StringType}, - "scopes": basetypes.ListType{ElemType: types.StringType}, + "redirect_urls": basetypes.ListType{ + ElemType: types.StringType, + }, + "scopes": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -1825,8 +1845,10 @@ func (o UpdateCustomAppIntegration) ToObjectValue(ctx context.Context) basetypes func (o UpdateCustomAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "integration_id": types.StringType, - "redirect_urls": basetypes.ListType{ElemType: types.StringType}, + "integration_id": types.StringType, + "redirect_urls": basetypes.ListType{ + ElemType: types.StringType, + }, "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, }, } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 2234b9bf6b..0412223661 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -156,27 +156,35 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "budget_policy_id": types.StringType, "catalog": types.StringType, "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, - "configuration": basetypes.MapType{ElemType: types.StringType}, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, - "development": types.BoolType, - "dry_run": types.BoolType, - "edition": types.StringType, - "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, - "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, - "name": types.StringType, - "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, - "photon": types.BoolType, - "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, + "clusters": basetypes.ListType{ + ElemType: PipelineCluster{}.Type(ctx), + }, + "configuration": basetypes.MapType{ + ElemType: types.StringType, + }, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, + "development": types.BoolType, + "dry_run": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, + "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "libraries": basetypes.ListType{ + ElemType: PipelineLibrary{}.Type(ctx), + }, + "name": types.StringType, + "notifications": basetypes.ListType{ + ElemType: Notifications{}.Type(ctx), + }, + "photon": types.BoolType, + "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, }, } } @@ -820,12 +828,16 @@ func (o EditPipeline) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EditPipeline) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allow_duplicate_names": types.BoolType, - "budget_policy_id": types.StringType, - "catalog": types.StringType, - "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, - "configuration": basetypes.MapType{ElemType: types.StringType}, + "allow_duplicate_names": types.BoolType, + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ + ElemType: PipelineCluster{}.Type(ctx), + }, + "configuration": basetypes.MapType{ + ElemType: types.StringType, + }, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, "development": types.BoolType, @@ -835,17 +847,21 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, - "name": types.StringType, - "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, - "photon": types.BoolType, - "pipeline_id": types.StringType, - "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, + "libraries": basetypes.ListType{ + ElemType: PipelineLibrary{}.Type(ctx), + }, + "name": types.StringType, + "notifications": basetypes.ListType{ + ElemType: Notifications{}.Type(ctx), + }, + "photon": types.BoolType, + "pipeline_id": types.StringType, + "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, }, } } @@ -1188,8 +1204,10 @@ func (o ErrorDetail) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ErrorDetail) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exceptions": basetypes.ListType{ElemType: SerializedException{}.Type(ctx)}, - "fatal": types.BoolType, + "exceptions": basetypes.ListType{ + ElemType: SerializedException{}.Type(ctx), + }, + "fatal": types.BoolType, }, } } @@ -1305,8 +1323,12 @@ func (o Filters) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Filters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exclude": basetypes.ListType{ElemType: types.StringType}, - "include": basetypes.ListType{ElemType: types.StringType}, + "exclude": basetypes.ListType{ + ElemType: types.StringType, + }, + "include": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -1445,7 +1467,9 @@ func (o GetPipelinePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetPipelinePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: PipelinePermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: PipelinePermissionsDescription{}.Type(ctx), + }, }, } } @@ -1642,12 +1666,14 @@ func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { "effective_budget_policy_id": types.StringType, "health": types.StringType, "last_modified": types.Int64Type, - "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, - "name": types.StringType, - "pipeline_id": types.StringType, - "run_as_user_name": types.StringType, - "spec": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, - "state": types.StringType, + "latest_updates": basetypes.ListType{ + ElemType: UpdateStateInfo{}.Type(ctx), + }, + "name": types.StringType, + "pipeline_id": types.StringType, + "run_as_user_name": types.StringType, + "spec": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, + "state": types.StringType, }, } } @@ -2076,8 +2102,10 @@ func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "connection_name": types.StringType, "ingestion_gateway_id": types.StringType, - "objects": basetypes.ListType{ElemType: IngestionConfig{}.Type(ctx)}, - "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, + "objects": basetypes.ListType{ + ElemType: IngestionConfig{}.Type(ctx), + }, + "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, }, } } @@ -2201,7 +2229,9 @@ func (o ListPipelineEventsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ElemType: types.StringType}, + "order_by": basetypes.ListType{ + ElemType: types.StringType, + }, "page_token": types.StringType, "pipeline_id": types.StringType, }, @@ -2279,7 +2309,9 @@ func (o ListPipelineEventsResponse) ToObjectValue(ctx context.Context) basetypes func (o ListPipelineEventsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "events": basetypes.ListType{ElemType: PipelineEvent{}.Type(ctx)}, + "events": basetypes.ListType{ + ElemType: PipelineEvent{}.Type(ctx), + }, "next_page_token": types.StringType, "prev_page_token": types.StringType, }, @@ -2376,8 +2408,10 @@ func (o ListPipelinesRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "filter": types.StringType, "max_results": types.Int64Type, - "order_by": basetypes.ListType{ElemType: types.StringType}, - "page_token": types.StringType, + "order_by": basetypes.ListType{ + ElemType: types.StringType, + }, + "page_token": types.StringType, }, } } @@ -2451,7 +2485,9 @@ func (o ListPipelinesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "statuses": basetypes.ListType{ElemType: PipelineStateInfo{}.Type(ctx)}, + "statuses": basetypes.ListType{ + ElemType: PipelineStateInfo{}.Type(ctx), + }, }, } } @@ -2586,7 +2622,9 @@ func (o ListUpdatesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, "prev_page_token": types.StringType, - "updates": basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}, + "updates": basetypes.ListType{ + ElemType: UpdateInfo{}.Type(ctx), + }, }, } } @@ -2744,8 +2782,12 @@ func (o Notifications) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o Notifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alerts": basetypes.ListType{ElemType: types.StringType}, - "email_recipients": basetypes.ListType{ElemType: types.StringType}, + "alerts": basetypes.ListType{ + ElemType: types.StringType, + }, + "email_recipients": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3014,7 +3056,9 @@ func (o PipelineAccessControlResponse) ToObjectValue(ctx context.Context) basety func (o PipelineAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: PipelinePermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: PipelinePermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3207,25 +3251,35 @@ func (o PipelineCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PipelineCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: PipelineClusterAutoscale{}.Type(ctx)}, - "aws_attributes": basetypes.ListType{ElemType: compute_tf.AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: compute_tf.AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: compute_tf.ClusterLogConf{}.Type(ctx)}, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "apply_policy_default_values": types.BoolType, + "autoscale": basetypes.ListType{ElemType: PipelineClusterAutoscale{}.Type(ctx)}, + "aws_attributes": basetypes.ListType{ElemType: compute_tf.AwsAttributes{}.Type(ctx)}, + "azure_attributes": basetypes.ListType{ElemType: compute_tf.AzureAttributes{}.Type(ctx)}, + "cluster_log_conf": basetypes.ListType{ElemType: compute_tf.ClusterLogConf{}.Type(ctx)}, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, "gcp_attributes": basetypes.ListType{ElemType: compute_tf.GcpAttributes{}.Type(ctx)}, - "init_scripts": basetypes.ListType{ElemType: compute_tf.InitScriptInfo{}.Type(ctx)}, - "instance_pool_id": types.StringType, - "label": types.StringType, - "node_type_id": types.StringType, - "num_workers": types.Int64Type, - "policy_id": types.StringType, - "spark_conf": basetypes.MapType{ElemType: types.StringType}, - "spark_env_vars": basetypes.MapType{ElemType: types.StringType}, - "ssh_public_keys": basetypes.ListType{ElemType: types.StringType}, + "init_scripts": basetypes.ListType{ + ElemType: compute_tf.InitScriptInfo{}.Type(ctx), + }, + "instance_pool_id": types.StringType, + "label": types.StringType, + "node_type_id": types.StringType, + "num_workers": types.Int64Type, + "policy_id": types.StringType, + "spark_conf": basetypes.MapType{ + ElemType: types.StringType, + }, + "spark_env_vars": basetypes.MapType{ + ElemType: types.StringType, + }, + "ssh_public_keys": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3935,9 +3989,11 @@ func (o PipelinePermission) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o PipelinePermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -4012,9 +4068,11 @@ func (o PipelinePermissions) ToObjectValue(ctx context.Context) basetypes.Object func (o PipelinePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: PipelineAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4131,8 +4189,10 @@ func (o PipelinePermissionsRequest) ToObjectValue(ctx context.Context) basetypes func (o PipelinePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: PipelineAccessControlRequest{}.Type(ctx)}, - "pipeline_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: PipelineAccessControlRequest{}.Type(ctx), + }, + "pipeline_id": types.StringType, }, } } @@ -4286,11 +4346,15 @@ func (o PipelineSpec) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PipelineSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget_policy_id": types.StringType, - "catalog": types.StringType, - "channel": types.StringType, - "clusters": basetypes.ListType{ElemType: PipelineCluster{}.Type(ctx)}, - "configuration": basetypes.MapType{ElemType: types.StringType}, + "budget_policy_id": types.StringType, + "catalog": types.StringType, + "channel": types.StringType, + "clusters": basetypes.ListType{ + ElemType: PipelineCluster{}.Type(ctx), + }, + "configuration": basetypes.MapType{ + ElemType: types.StringType, + }, "continuous": types.BoolType, "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, "development": types.BoolType, @@ -4299,16 +4363,20 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, "id": types.StringType, "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, - "libraries": basetypes.ListType{ElemType: PipelineLibrary{}.Type(ctx)}, - "name": types.StringType, - "notifications": basetypes.ListType{ElemType: Notifications{}.Type(ctx)}, - "photon": types.BoolType, - "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, + "libraries": basetypes.ListType{ + ElemType: PipelineLibrary{}.Type(ctx), + }, + "name": types.StringType, + "notifications": basetypes.ListType{ + ElemType: Notifications{}.Type(ctx), + }, + "photon": types.BoolType, + "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, }, } } @@ -4638,11 +4706,13 @@ func (o PipelineStateInfo) Type(ctx context.Context) attr.Type { "cluster_id": types.StringType, "creator_user_name": types.StringType, "health": types.StringType, - "latest_updates": basetypes.ListType{ElemType: UpdateStateInfo{}.Type(ctx)}, - "name": types.StringType, - "pipeline_id": types.StringType, - "run_as_user_name": types.StringType, - "state": types.StringType, + "latest_updates": basetypes.ListType{ + ElemType: UpdateStateInfo{}.Type(ctx), + }, + "name": types.StringType, + "pipeline_id": types.StringType, + "run_as_user_name": types.StringType, + "state": types.StringType, }, } } @@ -5130,7 +5200,9 @@ func (o SerializedException) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "class_name": types.StringType, "message": types.StringType, - "stack": basetypes.ListType{ElemType: StackFrame{}.Type(ctx)}, + "stack": basetypes.ListType{ + ElemType: StackFrame{}.Type(ctx), + }, }, } } @@ -5276,12 +5348,16 @@ func (o StartUpdate) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o StartUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "full_refresh": types.BoolType, - "full_refresh_selection": basetypes.ListType{ElemType: types.StringType}, - "pipeline_id": types.StringType, - "refresh_selection": basetypes.ListType{ElemType: types.StringType}, - "validate_only": types.BoolType, + "cause": types.StringType, + "full_refresh": types.BoolType, + "full_refresh_selection": basetypes.ListType{ + ElemType: types.StringType, + }, + "pipeline_id": types.StringType, + "refresh_selection": basetypes.ListType{ + ElemType: types.StringType, + }, + "validate_only": types.BoolType, }, } } @@ -5607,10 +5683,14 @@ func (o TableSpecificConfig) ToObjectValue(ctx context.Context) basetypes.Object func (o TableSpecificConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "primary_keys": basetypes.ListType{ElemType: types.StringType}, + "primary_keys": basetypes.ListType{ + ElemType: types.StringType, + }, "salesforce_include_formula_fields": types.BoolType, "scd_type": types.StringType, - "sequence_by": basetypes.ListType{ElemType: types.StringType}, + "sequence_by": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -5746,17 +5826,21 @@ func (o UpdateInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o UpdateInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "cluster_id": types.StringType, - "config": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, - "creation_time": types.Int64Type, - "full_refresh": types.BoolType, - "full_refresh_selection": basetypes.ListType{ElemType: types.StringType}, - "pipeline_id": types.StringType, - "refresh_selection": basetypes.ListType{ElemType: types.StringType}, - "state": types.StringType, - "update_id": types.StringType, - "validate_only": types.BoolType, + "cause": types.StringType, + "cluster_id": types.StringType, + "config": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, + "creation_time": types.Int64Type, + "full_refresh": types.BoolType, + "full_refresh_selection": basetypes.ListType{ + ElemType: types.StringType, + }, + "pipeline_id": types.StringType, + "refresh_selection": basetypes.ListType{ + ElemType: types.StringType, + }, + "state": types.StringType, + "update_id": types.StringType, + "validate_only": types.BoolType, }, } } diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index 30fede620c..ce465d0fe1 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -550,7 +550,9 @@ func (o CreateCustomerManagedKeyRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "aws_key_info": basetypes.ListType{ElemType: CreateAwsKeyInfo{}.Type(ctx)}, "gcp_key_info": basetypes.ListType{ElemType: CreateGcpKeyInfo{}.Type(ctx)}, - "use_cases": basetypes.ListType{ElemType: types.StringType}, + "use_cases": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -739,12 +741,16 @@ func (o CreateNetworkRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o CreateNetworkRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, - "network_name": types.StringType, - "security_group_ids": basetypes.ListType{ElemType: types.StringType}, - "subnet_ids": basetypes.ListType{ElemType: types.StringType}, - "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, - "vpc_id": types.StringType, + "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, + "network_name": types.StringType, + "security_group_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "subnet_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, + "vpc_id": types.StringType, }, } } @@ -1176,23 +1182,25 @@ func (o CreateWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_region": types.StringType, - "cloud": types.StringType, - "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, - "credentials_id": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, - "deployment_name": types.StringType, - "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, - "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, - "is_no_public_ip_enabled": types.BoolType, - "location": types.StringType, + "aws_region": types.StringType, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "deployment_name": types.StringType, + "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, + "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, "managed_services_customer_managed_key_id": types.StringType, - "network_id": types.StringType, - "pricing_tier": types.StringType, - "private_access_settings_id": types.StringType, - "storage_configuration_id": types.StringType, - "storage_customer_managed_key_id": types.StringType, - "workspace_name": types.StringType, + "network_id": types.StringType, + "pricing_tier": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_name": types.StringType, }, } } @@ -1492,7 +1500,9 @@ func (o CustomerManagedKey) Type(ctx context.Context) attr.Type { "creation_time": types.Int64Type, "customer_managed_key_id": types.StringType, "gcp_key_info": basetypes.ListType{ElemType: GcpKeyInfo{}.Type(ctx)}, - "use_cases": basetypes.ListType{ElemType: types.StringType}, + "use_cases": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -2656,19 +2666,27 @@ func (o Network) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Network) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "creation_time": types.Int64Type, - "error_messages": basetypes.ListType{ElemType: NetworkHealth{}.Type(ctx)}, - "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, - "network_id": types.StringType, - "network_name": types.StringType, - "security_group_ids": basetypes.ListType{ElemType: types.StringType}, - "subnet_ids": basetypes.ListType{ElemType: types.StringType}, - "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, - "vpc_id": types.StringType, - "vpc_status": types.StringType, - "warning_messages": basetypes.ListType{ElemType: NetworkWarning{}.Type(ctx)}, - "workspace_id": types.Int64Type, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "error_messages": basetypes.ListType{ + ElemType: NetworkHealth{}.Type(ctx), + }, + "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, + "network_id": types.StringType, + "network_name": types.StringType, + "security_group_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "subnet_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, + "vpc_id": types.StringType, + "vpc_status": types.StringType, + "warning_messages": basetypes.ListType{ + ElemType: NetworkWarning{}.Type(ctx), + }, + "workspace_id": types.Int64Type, }, } } @@ -2925,8 +2943,12 @@ func (o NetworkVpcEndpoints) ToObjectValue(ctx context.Context) basetypes.Object func (o NetworkVpcEndpoints) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataplane_relay": basetypes.ListType{ElemType: types.StringType}, - "rest_api": basetypes.ListType{ElemType: types.StringType}, + "dataplane_relay": basetypes.ListType{ + ElemType: types.StringType, + }, + "rest_api": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3097,8 +3119,10 @@ func (o PrivateAccessSettings) ToObjectValue(ctx context.Context) basetypes.Obje func (o PrivateAccessSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "allowed_vpc_endpoint_ids": basetypes.ListType{ElemType: types.StringType}, + "account_id": types.StringType, + "allowed_vpc_endpoint_ids": basetypes.ListType{ + ElemType: types.StringType, + }, "private_access_level": types.StringType, "private_access_settings_id": types.StringType, "private_access_settings_name": types.StringType, @@ -3462,7 +3486,9 @@ func (o UpdateWorkspaceRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "aws_region": types.StringType, "credentials_id": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, "managed_services_customer_managed_key_id": types.StringType, "network_connectivity_config_id": types.StringType, "network_id": types.StringType, @@ -3577,7 +3603,9 @@ func (o UpsertPrivateAccessSettingsRequest) ToObjectValue(ctx context.Context) b func (o UpsertPrivateAccessSettingsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_vpc_endpoint_ids": basetypes.ListType{ElemType: types.StringType}, + "allowed_vpc_endpoint_ids": basetypes.ListType{ + ElemType: types.StringType, + }, "private_access_level": types.StringType, "private_access_settings_id": types.StringType, "private_access_settings_name": types.StringType, @@ -3896,30 +3924,32 @@ func (o Workspace) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Workspace) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_region": types.StringType, - "azure_workspace_info": basetypes.ListType{ElemType: AzureWorkspaceInfo{}.Type(ctx)}, - "cloud": types.StringType, - "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, - "creation_time": types.Int64Type, - "credentials_id": types.StringType, - "custom_tags": basetypes.MapType{ElemType: types.StringType}, - "deployment_name": types.StringType, - "external_customer_info": basetypes.ListType{ElemType: ExternalCustomerInfo{}.Type(ctx)}, - "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, - "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, - "is_no_public_ip_enabled": types.BoolType, - "location": types.StringType, + "account_id": types.StringType, + "aws_region": types.StringType, + "azure_workspace_info": basetypes.ListType{ElemType: AzureWorkspaceInfo{}.Type(ctx)}, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "custom_tags": basetypes.MapType{ + ElemType: types.StringType, + }, + "deployment_name": types.StringType, + "external_customer_info": basetypes.ListType{ElemType: ExternalCustomerInfo{}.Type(ctx)}, + "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, + "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, "managed_services_customer_managed_key_id": types.StringType, - "network_id": types.StringType, - "pricing_tier": types.StringType, - "private_access_settings_id": types.StringType, - "storage_configuration_id": types.StringType, - "storage_customer_managed_key_id": types.StringType, - "workspace_id": types.Int64Type, - "workspace_name": types.StringType, - "workspace_status": types.StringType, - "workspace_status_message": types.StringType, + "network_id": types.StringType, + "pricing_tier": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_id": types.Int64Type, + "workspace_name": types.StringType, + "workspace_status": types.StringType, + "workspace_status_message": types.StringType, }, } } diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index 58da69e190..f20aaf7c00 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -132,8 +132,10 @@ func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, - "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ + ElemType: AiGatewayRateLimit{}.Type(ctx), + }, + "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } } @@ -294,10 +296,14 @@ func (o AiGatewayGuardrailParameters) ToObjectValue(ctx context.Context) basetyp func (o AiGatewayGuardrailParameters) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "invalid_keywords": basetypes.ListType{ElemType: types.StringType}, - "pii": basetypes.ListType{ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx)}, - "safety": types.BoolType, - "valid_topics": basetypes.ListType{ElemType: types.StringType}, + "invalid_keywords": basetypes.ListType{ + ElemType: types.StringType, + }, + "pii": basetypes.ListType{ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx)}, + "safety": types.BoolType, + "valid_topics": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -1283,12 +1289,16 @@ func (o CreateServingEndpoint) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, - "config": basetypes.ListType{ElemType: EndpointCoreConfigInput{}.Type(ctx)}, - "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, + "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, + "config": basetypes.ListType{ElemType: EndpointCoreConfigInput{}.Type(ctx)}, + "name": types.StringType, + "rate_limits": basetypes.ListType{ + ElemType: RateLimit{}.Type(ctx), + }, "route_optimized": types.BoolType, - "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: EndpointTag{}.Type(ctx), + }, }, } } @@ -1504,9 +1514,15 @@ func (o DataframeSplitInput) ToObjectValue(ctx context.Context) basetypes.Object func (o DataframeSplitInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: types.ObjectType{}}, - "data": basetypes.ListType{ElemType: types.ObjectType{}}, - "index": basetypes.ListType{ElemType: types.Int64Type}, + "columns": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "data": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "index": basetypes.ListType{ + ElemType: types.Int64Type, + }, }, } } @@ -1712,9 +1728,11 @@ func (o EmbeddingsV1ResponseEmbeddingElement) ToObjectValue(ctx context.Context) func (o EmbeddingsV1ResponseEmbeddingElement) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding": basetypes.ListType{ElemType: types.Float64Type}, - "index": types.Int64Type, - "object": types.StringType, + "embedding": basetypes.ListType{ + ElemType: types.Float64Type, + }, + "index": types.Int64Type, + "object": types.StringType, }, } } @@ -1805,9 +1823,13 @@ func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigInput{}.Type(ctx)}, "name": types.StringType, - "served_entities": basetypes.ListType{ElemType: ServedEntityInput{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelInput{}.Type(ctx)}, - "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, + "served_entities": basetypes.ListType{ + ElemType: ServedEntityInput{}.Type(ctx), + }, + "served_models": basetypes.ListType{ + ElemType: ServedModelInput{}.Type(ctx), + }, + "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } } @@ -1974,9 +1996,13 @@ func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, - "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, + "served_entities": basetypes.ListType{ + ElemType: ServedEntityOutput{}.Type(ctx), + }, + "served_models": basetypes.ListType{ + ElemType: ServedModelOutput{}.Type(ctx), + }, + "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } } @@ -2129,8 +2155,12 @@ func (o EndpointCoreConfigSummary) ToObjectValue(ctx context.Context) basetypes. func (o EndpointCoreConfigSummary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "served_entities": basetypes.ListType{ElemType: ServedEntitySpec{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelSpec{}.Type(ctx)}, + "served_entities": basetypes.ListType{ + ElemType: ServedEntitySpec{}.Type(ctx), + }, + "served_models": basetypes.ListType{ + ElemType: ServedModelSpec{}.Type(ctx), + }, }, } } @@ -2250,10 +2280,14 @@ func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, "config_version": types.Int64Type, - "served_entities": basetypes.ListType{ElemType: ServedEntityOutput{}.Type(ctx)}, - "served_models": basetypes.ListType{ElemType: ServedModelOutput{}.Type(ctx)}, - "start_time": types.Int64Type, - "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, + "served_entities": basetypes.ListType{ + ElemType: ServedEntityOutput{}.Type(ctx), + }, + "served_models": basetypes.ListType{ + ElemType: ServedModelOutput{}.Type(ctx), + }, + "start_time": types.Int64Type, + "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, }, } } @@ -3118,7 +3152,9 @@ func (o GetServingEndpointPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetServingEndpointPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: ServingEndpointPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: ServingEndpointPermissionsDescription{}.Type(ctx), + }, }, } } @@ -3347,7 +3383,9 @@ func (o ListEndpointsResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ListEndpointsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ElemType: ServingEndpoint{}.Type(ctx)}, + "endpoints": basetypes.ListType{ + ElemType: ServingEndpoint{}.Type(ctx), + }, }, } } @@ -3707,9 +3745,13 @@ func (o PatchServingEndpointTags) ToObjectValue(ctx context.Context) basetypes.O func (o PatchServingEndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "add_tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, - "delete_tags": basetypes.ListType{ElemType: types.StringType}, - "name": types.StringType, + "add_tags": basetypes.ListType{ + ElemType: EndpointTag{}.Type(ctx), + }, + "delete_tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "name": types.StringType, }, } } @@ -3880,8 +3922,10 @@ func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, - "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ + ElemType: AiGatewayRateLimit{}.Type(ctx), + }, + "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } } @@ -4048,8 +4092,10 @@ func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "rate_limits": basetypes.ListType{ElemType: AiGatewayRateLimit{}.Type(ctx)}, - "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ + ElemType: AiGatewayRateLimit{}.Type(ctx), + }, + "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, }, } } @@ -4202,8 +4248,10 @@ func (o PutRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PutRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, + "name": types.StringType, + "rate_limits": basetypes.ListType{ + ElemType: RateLimit{}.Type(ctx), + }, }, } } @@ -4273,7 +4321,9 @@ func (o PutResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o PutResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "rate_limits": basetypes.ListType{ElemType: RateLimit{}.Type(ctx)}, + "rate_limits": basetypes.ListType{ + ElemType: RateLimit{}.Type(ctx), + }, }, } } @@ -4408,20 +4458,30 @@ func (o QueryEndpointInput) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataframe_records": basetypes.ListType{ElemType: types.ObjectType{}}, - "dataframe_split": basetypes.ListType{ElemType: DataframeSplitInput{}.Type(ctx)}, - "extra_params": basetypes.MapType{ElemType: types.StringType}, - "input": types.ObjectType{}, - "inputs": types.ObjectType{}, - "instances": basetypes.ListType{ElemType: types.ObjectType{}}, - "max_tokens": types.Int64Type, - "messages": basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}, - "n": types.Int64Type, - "name": types.StringType, - "prompt": types.ObjectType{}, - "stop": basetypes.ListType{ElemType: types.StringType}, - "stream": types.BoolType, - "temperature": types.Float64Type, + "dataframe_records": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "dataframe_split": basetypes.ListType{ElemType: DataframeSplitInput{}.Type(ctx)}, + "extra_params": basetypes.MapType{ + ElemType: types.StringType, + }, + "input": types.ObjectType{}, + "inputs": types.ObjectType{}, + "instances": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, + "max_tokens": types.Int64Type, + "messages": basetypes.ListType{ + ElemType: ChatMessage{}.Type(ctx), + }, + "n": types.Int64Type, + "name": types.StringType, + "prompt": types.ObjectType{}, + "stop": basetypes.ListType{ + ElemType: types.StringType, + }, + "stream": types.BoolType, + "temperature": types.Float64Type, }, } } @@ -4658,13 +4718,19 @@ func (o QueryEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "choices": basetypes.ListType{ElemType: V1ResponseChoiceElement{}.Type(ctx)}, - "created": types.Int64Type, - "data": basetypes.ListType{ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx)}, - "id": types.StringType, - "model": types.StringType, - "object": types.StringType, - "predictions": basetypes.ListType{ElemType: types.ObjectType{}}, + "choices": basetypes.ListType{ + ElemType: V1ResponseChoiceElement{}.Type(ctx), + }, + "created": types.Int64Type, + "data": basetypes.ListType{ + ElemType: EmbeddingsV1ResponseEmbeddingElement{}.Type(ctx), + }, + "id": types.StringType, + "model": types.StringType, + "object": types.StringType, + "predictions": basetypes.ListType{ + ElemType: types.ObjectType{}, + }, "served-model-name": types.StringType, "usage": basetypes.ListType{ElemType: ExternalModelUsageElement{}.Type(ctx)}, }, @@ -4982,9 +5048,11 @@ func (o ServedEntityInput) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ServedEntityInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "entity_name": types.StringType, - "entity_version": types.StringType, - "environment_vars": basetypes.MapType{ElemType: types.StringType}, + "entity_name": types.StringType, + "entity_version": types.StringType, + "environment_vars": basetypes.MapType{ + ElemType: types.StringType, + }, "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, @@ -5163,11 +5231,13 @@ func (o ServedEntityOutput) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ServedEntityOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "entity_name": types.StringType, - "entity_version": types.StringType, - "environment_vars": basetypes.MapType{ElemType: types.StringType}, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "entity_name": types.StringType, + "entity_version": types.StringType, + "environment_vars": basetypes.MapType{ + ElemType: types.StringType, + }, "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, "foundation_model": basetypes.ListType{ElemType: FoundationModel{}.Type(ctx)}, "instance_profile_arn": types.StringType, @@ -5499,7 +5569,9 @@ func (o ServedModelInput) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ServedModelInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "environment_vars": basetypes.MapType{ElemType: types.StringType}, + "environment_vars": basetypes.MapType{ + ElemType: types.StringType, + }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, "min_provisioned_throughput": types.Int64Type, @@ -5630,9 +5702,11 @@ func (o ServedModelOutput) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o ServedModelOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "environment_vars": basetypes.MapType{ElemType: types.StringType}, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "environment_vars": basetypes.MapType{ + ElemType: types.StringType, + }, "instance_profile_arn": types.StringType, "model_name": types.StringType, "model_version": types.StringType, @@ -5928,8 +6002,10 @@ func (o ServingEndpoint) Type(ctx context.Context) attr.Type { "last_updated_timestamp": types.Int64Type, "name": types.StringType, "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, - "task": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTag{}.Type(ctx), + }, + "task": types.StringType, }, } } @@ -6143,7 +6219,9 @@ func (o ServingEndpointAccessControlResponse) ToObjectValue(ctx context.Context) func (o ServingEndpointAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: ServingEndpointPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: ServingEndpointPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -6280,8 +6358,10 @@ func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { "permission_level": types.StringType, "route_optimized": types.BoolType, "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, - "tags": basetypes.ListType{ElemType: EndpointTag{}.Type(ctx)}, - "task": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTag{}.Type(ctx), + }, + "task": types.StringType, }, } } @@ -6486,9 +6566,11 @@ func (o ServingEndpointPermission) ToObjectValue(ctx context.Context) basetypes. func (o ServingEndpointPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -6563,9 +6645,11 @@ func (o ServingEndpointPermissions) ToObjectValue(ctx context.Context) basetypes func (o ServingEndpointPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: ServingEndpointAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -6682,7 +6766,9 @@ func (o ServingEndpointPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o ServingEndpointPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: ServingEndpointAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: ServingEndpointAccessControlRequest{}.Type(ctx), + }, "serving_endpoint_id": types.StringType, }, } @@ -6753,7 +6839,9 @@ func (o TrafficConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o TrafficConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "routes": basetypes.ListType{ElemType: Route{}.Type(ctx)}, + "routes": basetypes.ListType{ + ElemType: Route{}.Type(ctx), + }, }, } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index c5d38a66b7..75f73fb161 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -187,7 +187,9 @@ func (o AibiDashboardEmbeddingApprovedDomains) ToObjectValue(ctx context.Context func (o AibiDashboardEmbeddingApprovedDomains) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "approved_domains": basetypes.ListType{ElemType: types.StringType}, + "approved_domains": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -841,8 +843,10 @@ func (o ComplianceSecurityProfile) ToObjectValue(ctx context.Context) basetypes. func (o ComplianceSecurityProfile) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ElemType: types.StringType}, - "is_enabled": types.BoolType, + "compliance_standards": basetypes.ListType{ + ElemType: types.StringType, + }, + "is_enabled": types.BoolType, }, } } @@ -1204,9 +1208,11 @@ func (o CreateIpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateIpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_addresses": basetypes.ListType{ElemType: types.StringType}, - "label": types.StringType, - "list_type": types.StringType, + "ip_addresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -1777,8 +1783,10 @@ func (o CspEnablementAccount) ToObjectValue(ctx context.Context) basetypes.Objec func (o CspEnablementAccount) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_standards": basetypes.ListType{ElemType: types.StringType}, - "is_enforced": types.BoolType, + "compliance_standards": basetypes.ListType{ + ElemType: types.StringType, + }, + "is_enforced": types.BoolType, }, } } @@ -3501,10 +3509,14 @@ func (o EgressNetworkPolicyInternetAccessPolicy) ToObjectValue(ctx context.Conte func (o EgressNetworkPolicyInternetAccessPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_internet_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx)}, - "allowed_storage_destinations": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx)}, - "log_only_mode": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx)}, - "restriction_mode": types.StringType, + "allowed_internet_destinations": basetypes.ListType{ + ElemType: EgressNetworkPolicyInternetAccessPolicyInternetDestination{}.Type(ctx), + }, + "allowed_storage_destinations": basetypes.ListType{ + ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx), + }, + "log_only_mode": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx)}, + "restriction_mode": types.StringType, }, } } @@ -3685,7 +3697,9 @@ func (o EgressNetworkPolicyInternetAccessPolicyLogOnlyMode) Type(ctx context.Con return types.ObjectType{ AttrTypes: map[string]attr.Type{ "log_only_mode_type": types.StringType, - "workloads": basetypes.ListType{ElemType: types.StringType}, + "workloads": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3776,7 +3790,9 @@ func (o EgressNetworkPolicyInternetAccessPolicyStorageDestination) ToObjectValue func (o EgressNetworkPolicyInternetAccessPolicyStorageDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_paths": basetypes.ListType{ElemType: types.StringType}, + "allowed_paths": basetypes.ListType{ + ElemType: types.StringType, + }, "azure_container": types.StringType, "azure_dns_zone": types.StringType, "azure_storage_account": types.StringType, @@ -3853,7 +3869,9 @@ func (o EmailConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EmailConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "addresses": basetypes.ListType{ElemType: types.StringType}, + "addresses": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -4236,8 +4254,10 @@ func (o ExchangeToken) Type(ctx context.Context) attr.Type { "credential": types.StringType, "credentialEolTime": types.Int64Type, "ownerId": types.Int64Type, - "scopes": basetypes.ListType{ElemType: types.StringType}, - "tokenType": types.StringType, + "scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + "tokenType": types.StringType, }, } } @@ -4317,8 +4337,12 @@ func (o ExchangeTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "partitionId": basetypes.ListType{ElemType: PartitionId{}.Type(ctx)}, - "scopes": basetypes.ListType{ElemType: types.StringType}, - "tokenType": basetypes.ListType{ElemType: types.StringType}, + "scopes": basetypes.ListType{ + ElemType: types.StringType, + }, + "tokenType": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -4440,7 +4464,9 @@ func (o ExchangeTokenResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o ExchangeTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ElemType: ExchangeToken{}.Type(ctx)}, + "values": basetypes.ListType{ + ElemType: ExchangeToken{}.Type(ctx), + }, }, } } @@ -5338,7 +5364,9 @@ func (o GetIpAccessListsResponse) ToObjectValue(ctx context.Context) basetypes.O func (o GetIpAccessListsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_lists": basetypes.ListType{ + ElemType: IpAccessListInfo{}.Type(ctx), + }, }, } } @@ -5723,7 +5751,9 @@ func (o GetTokenPermissionLevelsResponse) ToObjectValue(ctx context.Context) bas func (o GetTokenPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: TokenPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: TokenPermissionsDescription{}.Type(ctx), + }, }, } } @@ -5900,12 +5930,14 @@ func (o IpAccessListInfo) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "created_by": types.Int64Type, "enabled": types.BoolType, - "ip_addresses": basetypes.ListType{ElemType: types.StringType}, - "label": types.StringType, - "list_id": types.StringType, - "list_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.Int64Type, + "ip_addresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "label": types.StringType, + "list_id": types.StringType, + "list_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.Int64Type, }, } } @@ -5975,7 +6007,9 @@ func (o ListIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_lists": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_lists": basetypes.ListType{ + ElemType: IpAccessListInfo{}.Type(ctx), + }, }, } } @@ -6048,7 +6082,9 @@ func (o ListNccAzurePrivateEndpointRulesResponse) ToObjectValue(ctx context.Cont func (o ListNccAzurePrivateEndpointRulesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, + "items": basetypes.ListType{ + ElemType: NccAzurePrivateEndpointRule{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -6165,7 +6201,9 @@ func (o ListNetworkConnectivityConfigurationsResponse) ToObjectValue(ctx context func (o ListNetworkConnectivityConfigurationsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: NetworkConnectivityConfiguration{}.Type(ctx)}, + "items": basetypes.ListType{ + ElemType: NetworkConnectivityConfiguration{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -6286,7 +6324,9 @@ func (o ListNotificationDestinationsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: ListNotificationDestinationsResult{}.Type(ctx)}, + "results": basetypes.ListType{ + ElemType: ListNotificationDestinationsResult{}.Type(ctx), + }, }, } } @@ -6454,7 +6494,9 @@ func (o ListPublicTokensResponse) ToObjectValue(ctx context.Context) basetypes.O func (o ListPublicTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}, + "token_infos": basetypes.ListType{ + ElemType: PublicTokenInfo{}.Type(ctx), + }, }, } } @@ -6572,7 +6614,9 @@ func (o ListTokensResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListTokensResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_infos": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, + "token_infos": basetypes.ListType{ + ElemType: TokenInfo{}.Type(ctx), + }, }, } } @@ -6691,7 +6735,9 @@ func (o NccAwsStableIpRule) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o NccAwsStableIpRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cidr_blocks": basetypes.ListType{ElemType: types.StringType}, + "cidr_blocks": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -6865,9 +6911,13 @@ func (o NccAzureServiceEndpointRule) ToObjectValue(ctx context.Context) basetype func (o NccAzureServiceEndpointRule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "subnets": basetypes.ListType{ElemType: types.StringType}, - "target_region": types.StringType, - "target_services": basetypes.ListType{ElemType: types.StringType}, + "subnets": basetypes.ListType{ + ElemType: types.StringType, + }, + "target_region": types.StringType, + "target_services": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -7178,7 +7228,9 @@ func (o NccEgressTargetRules) ToObjectValue(ctx context.Context) basetypes.Objec func (o NccEgressTargetRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "azure_private_endpoint_rules": basetypes.ListType{ElemType: NccAzurePrivateEndpointRule{}.Type(ctx)}, + "azure_private_endpoint_rules": basetypes.ListType{ + ElemType: NccAzurePrivateEndpointRule{}.Type(ctx), + }, }, } } @@ -7733,9 +7785,11 @@ func (o ReplaceIpAccessList) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, "ip_access_list_id": types.StringType, - "ip_addresses": basetypes.ListType{ElemType: types.StringType}, - "label": types.StringType, - "list_type": types.StringType, + "ip_addresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "label": types.StringType, + "list_type": types.StringType, }, } } @@ -8238,7 +8292,9 @@ func (o TokenAccessControlResponse) ToObjectValue(ctx context.Context) basetypes func (o TokenAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: TokenPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: TokenPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -8393,9 +8449,11 @@ func (o TokenPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o TokenPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -8470,9 +8528,11 @@ func (o TokenPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o TokenPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: TokenAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: TokenAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -8586,7 +8646,9 @@ func (o TokenPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o TokenPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: TokenAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: TokenAccessControlRequest{}.Type(ctx), + }, }, } } @@ -9597,9 +9659,11 @@ func (o UpdateIpAccessList) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "enabled": types.BoolType, "ip_access_list_id": types.StringType, - "ip_addresses": basetypes.ListType{ElemType: types.StringType}, - "label": types.StringType, - "list_type": types.StringType, + "ip_addresses": basetypes.ListType{ + ElemType: types.StringType, + }, + "label": types.StringType, + "list_type": types.StringType, }, } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index fa69b5ac8b..a15a6e55c8 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -635,7 +635,9 @@ func (o GetRecipientSharePermissionsResponse) Type(ctx context.Context) attr.Typ return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "permissions_out": basetypes.ListType{ElemType: ShareToPrivilegeAssignment{}.Type(ctx)}, + "permissions_out": basetypes.ListType{ + ElemType: ShareToPrivilegeAssignment{}.Type(ctx), + }, }, } } @@ -752,7 +754,9 @@ func (o IpAccessList) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o IpAccessList) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "allowed_ip_addresses": basetypes.ListType{ElemType: types.StringType}, + "allowed_ip_addresses": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -828,7 +832,9 @@ func (o ListProviderSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ElemType: ProviderShare{}.Type(ctx)}, + "shares": basetypes.ListType{ + ElemType: ProviderShare{}.Type(ctx), + }, }, } } @@ -964,7 +970,9 @@ func (o ListProvidersResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "providers": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "providers": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } @@ -1100,7 +1108,9 @@ func (o ListRecipientsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "recipients": basetypes.ListType{ElemType: RecipientInfo{}.Type(ctx)}, + "recipients": basetypes.ListType{ + ElemType: RecipientInfo{}.Type(ctx), + }, }, } } @@ -1235,7 +1245,9 @@ func (o ListSharesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "shares": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, + "shares": basetypes.ListType{ + ElemType: ShareInfo{}.Type(ctx), + }, }, } } @@ -1305,7 +1317,9 @@ func (o Partition) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Partition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, + "value": basetypes.ListType{ + ElemType: PartitionValue{}.Type(ctx), + }, }, } } @@ -1375,7 +1389,9 @@ func (o PartitionSpecificationPartition) ToObjectValue(ctx context.Context) base func (o PartitionSpecificationPartition) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: PartitionValue{}.Type(ctx)}, + "value": basetypes.ListType{ + ElemType: PartitionValue{}.Type(ctx), + }, }, } } @@ -1506,8 +1522,10 @@ func (o PrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes.Object func (o PrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "principal": types.StringType, - "privileges": basetypes.ListType{ElemType: types.StringType}, + "principal": types.StringType, + "privileges": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -1825,9 +1843,11 @@ func (o RecipientInfo) Type(ctx context.Context) attr.Type { "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, "region": types.StringType, "sharing_code": types.StringType, - "tokens": basetypes.ListType{ElemType: RecipientTokenInfo{}.Type(ctx)}, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "tokens": basetypes.ListType{ + ElemType: RecipientTokenInfo{}.Type(ctx), + }, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -2214,7 +2234,9 @@ func (o SecurablePropertiesKvPairs) ToObjectValue(ctx context.Context) basetypes func (o SecurablePropertiesKvPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "properties": basetypes.MapType{ElemType: types.StringType}, + "properties": basetypes.MapType{ + ElemType: types.StringType, + }, }, } } @@ -2311,11 +2333,13 @@ func (o ShareInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ShareInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "name": types.StringType, - "object": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "name": types.StringType, + "object": basetypes.ListType{ + ElemType: SharedDataObject{}.Type(ctx), + }, "owner": types.StringType, "storage_location": types.StringType, "storage_root": types.StringType, @@ -2452,8 +2476,10 @@ func (o ShareToPrivilegeAssignment) ToObjectValue(ctx context.Context) basetypes func (o ShareToPrivilegeAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "privilege_assignments": basetypes.ListType{ElemType: PrivilegeAssignment{}.Type(ctx)}, - "share_name": types.StringType, + "privilege_assignments": basetypes.ListType{ + ElemType: PrivilegeAssignment{}.Type(ctx), + }, + "share_name": types.StringType, }, } } @@ -2622,13 +2648,15 @@ func (o SharedDataObject) Type(ctx context.Context) attr.Type { "history_data_sharing_status": types.StringType, "effective_history_data_sharing_status": types.StringType, "name": types.StringType, - "partition": basetypes.ListType{ElemType: Partition{}.Type(ctx)}, - "shared_as": types.StringType, - "effective_shared_as": types.StringType, - "start_version": types.Int64Type, - "effective_start_version": types.Int64Type, - "status": types.StringType, - "string_shared_as": types.StringType, + "partition": basetypes.ListType{ + ElemType: Partition{}.Type(ctx), + }, + "shared_as": types.StringType, + "effective_shared_as": types.StringType, + "start_version": types.Int64Type, + "effective_start_version": types.Int64Type, + "status": types.StringType, + "string_shared_as": types.StringType, }, } } @@ -3047,7 +3075,9 @@ func (o UpdateShare) Type(ctx context.Context) attr.Type { "new_name": types.StringType, "owner": types.StringType, "storage_root": types.StringType, - "updates": basetypes.ListType{ElemType: SharedDataObjectUpdate{}.Type(ctx)}, + "updates": basetypes.ListType{ + ElemType: SharedDataObjectUpdate{}.Type(ctx), + }, }, } } @@ -3134,7 +3164,9 @@ func (o UpdateSharePermissions) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateSharePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "changes": basetypes.ListType{ElemType: catalog_tf.PermissionsChange{}.Type(ctx)}, + "changes": basetypes.ListType{ + ElemType: catalog_tf.PermissionsChange{}.Type(ctx), + }, "max_results": types.Int64Type, "name": types.StringType, "page_token": types.StringType, diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index 1490896a65..e5ccf52c75 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -724,9 +724,11 @@ func (o AlertQuery) Type(ctx context.Context) attr.Type { "name": types.StringType, "options": basetypes.ListType{ElemType: QueryOptions{}.Type(ctx)}, "query": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "updated_at": types.StringType, - "user_id": types.Int64Type, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "updated_at": types.StringType, + "user_id": types.Int64Type, }, } } @@ -1493,13 +1495,17 @@ func (o CreateQueryRequestQuery) Type(ctx context.Context) attr.Type { "catalog": types.StringType, "description": types.StringType, "display_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, - "parent_path": types.StringType, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ + ElemType: QueryParameter{}.Type(ctx), + }, + "parent_path": types.StringType, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "warehouse_id": types.StringType, }, } } @@ -2178,11 +2184,15 @@ func (o Dashboard) Type(ctx context.Context) attr.Type { "parent": types.StringType, "permission_tier": types.StringType, "slug": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "updated_at": types.StringType, - "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, - "user_id": types.Int64Type, - "widgets": basetypes.ListType{ElemType: Widget{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "updated_at": types.StringType, + "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "user_id": types.Int64Type, + "widgets": basetypes.ListType{ + ElemType: Widget{}.Type(ctx), + }, }, } } @@ -2344,7 +2354,9 @@ func (o DashboardEditContent) Type(ctx context.Context) attr.Type { "dashboard_id": types.StringType, "name": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -2482,7 +2494,9 @@ func (o DashboardPostContent) Type(ctx context.Context) attr.Type { "name": types.StringType, "parent": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3962,7 +3976,9 @@ func (o EndpointTags) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointTags) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "custom_tags": basetypes.ListType{ElemType: EndpointTagPair{}.Type(ctx)}, + "custom_tags": basetypes.ListType{ + ElemType: EndpointTagPair{}.Type(ctx), + }, }, } } @@ -4041,7 +4057,9 @@ func (o EnumValue) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "enum_options": types.StringType, "multi_values_options": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, - "values": basetypes.ListType{ElemType: types.StringType}, + "values": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -4273,12 +4291,14 @@ func (o ExecuteStatementRequest) Type(ctx context.Context) attr.Type { "disposition": types.StringType, "format": types.StringType, "on_wait_timeout": types.StringType, - "parameters": basetypes.ListType{ElemType: StatementParameterListItem{}.Type(ctx)}, - "row_limit": types.Int64Type, - "schema": types.StringType, - "statement": types.StringType, - "wait_timeout": types.StringType, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ + ElemType: StatementParameterListItem{}.Type(ctx), + }, + "row_limit": types.Int64Type, + "schema": types.StringType, + "statement": types.StringType, + "wait_timeout": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -4384,11 +4404,13 @@ func (o ExternalLink) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ExternalLink) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "byte_count": types.Int64Type, - "chunk_index": types.Int64Type, - "expiration": types.StringType, - "external_link": types.StringType, - "http_headers": basetypes.MapType{ElemType: types.StringType}, + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "expiration": types.StringType, + "external_link": types.StringType, + "http_headers": basetypes.MapType{ + ElemType: types.StringType, + }, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, "row_count": types.Int64Type, @@ -4724,9 +4746,11 @@ func (o GetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o GetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: AccessControl{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4930,7 +4954,9 @@ func (o GetWarehousePermissionLevelsResponse) ToObjectValue(ctx context.Context) func (o GetWarehousePermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: WarehousePermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: WarehousePermissionsDescription{}.Type(ctx), + }, }, } } @@ -5383,10 +5409,14 @@ func (o GetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, - "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, - "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "data_access_config": basetypes.ListType{ + ElemType: EndpointConfPair{}.Type(ctx), + }, + "enabled_warehouse_types": basetypes.ListType{ + ElemType: WarehouseTypePair{}.Type(ctx), + }, "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, @@ -5871,11 +5901,15 @@ func (o LegacyQuery) Type(ctx context.Context) attr.Type { "query": types.StringType, "query_hash": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "updated_at": types.StringType, - "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, - "user_id": types.Int64Type, - "visualizations": basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "updated_at": types.StringType, + "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "user_id": types.Int64Type, + "visualizations": basetypes.ListType{ + ElemType: LegacyVisualization{}.Type(ctx), + }, }, } } @@ -6204,7 +6238,9 @@ func (o ListAlertsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: ListAlertsResponseAlert{}.Type(ctx)}, + "results": basetypes.ListType{ + ElemType: ListAlertsResponseAlert{}.Type(ctx), + }, }, } } @@ -6586,7 +6622,9 @@ func (o ListQueriesResponse) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "has_next_page": types.BoolType, "next_page_token": types.StringType, - "res": basetypes.ListType{ElemType: QueryInfo{}.Type(ctx)}, + "res": basetypes.ListType{ + ElemType: QueryInfo{}.Type(ctx), + }, }, } } @@ -6747,7 +6785,9 @@ func (o ListQueryObjectsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: ListQueryObjectsResponseQuery{}.Type(ctx)}, + "results": basetypes.ListType{ + ElemType: ListQueryObjectsResponseQuery{}.Type(ctx), + }, }, } } @@ -6874,13 +6914,17 @@ func (o ListQueryObjectsResponseQuery) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "update_time": types.StringType, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ + ElemType: QueryParameter{}.Type(ctx), + }, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -6988,7 +7032,9 @@ func (o ListResponse) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, + "results": basetypes.ListType{ + ElemType: Dashboard{}.Type(ctx), + }, }, } } @@ -7111,7 +7157,9 @@ func (o ListVisualizationsForQueryResponse) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "results": basetypes.ListType{ElemType: Visualization{}.Type(ctx)}, + "results": basetypes.ListType{ + ElemType: Visualization{}.Type(ctx), + }, }, } } @@ -7225,7 +7273,9 @@ func (o ListWarehousesResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o ListWarehousesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "warehouses": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, + "warehouses": basetypes.ListType{ + ElemType: EndpointInfo{}.Type(ctx), + }, }, } } @@ -7598,14 +7648,18 @@ func (o Query) Type(ctx context.Context) attr.Type { "last_modifier_user_name": types.StringType, "lifecycle_state": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, - "parent_path": types.StringType, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "update_time": types.StringType, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ + ElemType: QueryParameter{}.Type(ctx), + }, + "parent_path": types.StringType, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -7710,7 +7764,9 @@ func (o QueryBackedValue) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "multi_values_options": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, "query_id": types.StringType, - "values": basetypes.ListType{ElemType: types.StringType}, + "values": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -7843,7 +7899,9 @@ func (o QueryEditContent) Type(ctx context.Context) attr.Type { "query": types.StringType, "query_id": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -7931,10 +7989,18 @@ func (o QueryFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "query_start_time_range": basetypes.ListType{ElemType: TimeRange{}.Type(ctx)}, - "statement_ids": basetypes.ListType{ElemType: types.StringType}, - "statuses": basetypes.ListType{ElemType: types.StringType}, - "user_ids": basetypes.ListType{ElemType: types.Int64Type}, - "warehouse_ids": basetypes.ListType{ElemType: types.StringType}, + "statement_ids": basetypes.ListType{ + ElemType: types.StringType, + }, + "statuses": basetypes.ListType{ + ElemType: types.StringType, + }, + "user_ids": basetypes.ListType{ + ElemType: types.Int64Type, + }, + "warehouse_ids": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -8306,7 +8372,9 @@ func (o QueryList) Type(ctx context.Context) attr.Type { "count": types.Int64Type, "page": types.Int64Type, "page_size": types.Int64Type, - "results": basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}, + "results": basetypes.ListType{ + ElemType: LegacyQuery{}.Type(ctx), + }, }, } } @@ -8529,8 +8597,10 @@ func (o QueryOptions) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "catalog": types.StringType, "moved_to_trash_at": types.StringType, - "parameters": basetypes.ListType{ElemType: Parameter{}.Type(ctx)}, - "schema": types.StringType, + "parameters": basetypes.ListType{ + ElemType: Parameter{}.Type(ctx), + }, + "schema": types.StringType, }, } } @@ -8873,7 +8943,9 @@ func (o QueryPostContent) Type(ctx context.Context) attr.Type { "parent": types.StringType, "query": types.StringType, "run_as_role": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -8947,8 +9019,12 @@ func (o RepeatedEndpointConfPairs) ToObjectValue(ctx context.Context) basetypes. func (o RepeatedEndpointConfPairs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config_pair": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, - "configuration_pairs": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, + "config_pair": basetypes.ListType{ + ElemType: EndpointConfPair{}.Type(ctx), + }, + "configuration_pairs": basetypes.ListType{ + ElemType: EndpointConfPair{}.Type(ctx), + }, }, } } @@ -9194,10 +9270,16 @@ func (o ResultData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ResultData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "byte_count": types.Int64Type, - "chunk_index": types.Int64Type, - "data_array": basetypes.ListType{ElemType: basetypes.ListType{ElemType: types.StringType}}, - "external_links": basetypes.ListType{ElemType: ExternalLink{}.Type(ctx)}, + "byte_count": types.Int64Type, + "chunk_index": types.Int64Type, + "data_array": basetypes.ListType{ + ElemType: basetypes.ListType{ + ElemType: types.StringType, + }, + }, + "external_links": basetypes.ListType{ + ElemType: ExternalLink{}.Type(ctx), + }, "next_chunk_index": types.Int64Type, "next_chunk_internal_link": types.StringType, "row_count": types.Int64Type, @@ -9319,7 +9401,9 @@ func (o ResultManifest) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "chunks": basetypes.ListType{ElemType: BaseChunkInfo{}.Type(ctx)}, + "chunks": basetypes.ListType{ + ElemType: BaseChunkInfo{}.Type(ctx), + }, "format": types.StringType, "schema": basetypes.ListType{ElemType: ResultSchema{}.Type(ctx)}, "total_byte_count": types.Int64Type, @@ -9425,7 +9509,9 @@ func (o ResultSchema) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ + ElemType: ColumnInfo{}.Type(ctx), + }, }, } } @@ -9547,9 +9633,11 @@ func (o SetRequest) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, - "objectId": types.StringType, - "objectType": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: AccessControl{}.Type(ctx), + }, + "objectId": types.StringType, + "objectType": types.StringType, }, } } @@ -9624,9 +9712,11 @@ func (o SetResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SetResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: AccessControl{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: AccessControl{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -9732,10 +9822,14 @@ func (o SetWorkspaceWarehouseConfigRequest) ToObjectValue(ctx context.Context) b func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, - "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "data_access_config": basetypes.ListType{ElemType: EndpointConfPair{}.Type(ctx)}, - "enabled_warehouse_types": basetypes.ListType{ElemType: WarehouseTypePair{}.Type(ctx)}, + "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "data_access_config": basetypes.ListType{ + ElemType: EndpointConfPair{}.Type(ctx), + }, + "enabled_warehouse_types": basetypes.ListType{ + ElemType: WarehouseTypePair{}.Type(ctx), + }, "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, "google_service_account": types.StringType, "instance_profile_arn": types.StringType, @@ -10458,9 +10552,11 @@ func (o TerminationReason) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o TerminationReason) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "code": types.StringType, - "parameters": basetypes.MapType{ElemType: types.StringType}, - "type": types.StringType, + "code": types.StringType, + "parameters": basetypes.MapType{ + ElemType: types.StringType, + }, + "type": types.StringType, }, } } @@ -11128,12 +11224,16 @@ func (o UpdateQueryRequestQuery) Type(ctx context.Context) attr.Type { "description": types.StringType, "display_name": types.StringType, "owner_user_name": types.StringType, - "parameters": basetypes.ListType{ElemType: QueryParameter{}.Type(ctx)}, - "query_text": types.StringType, - "run_as_mode": types.StringType, - "schema": types.StringType, - "tags": basetypes.ListType{ElemType: types.StringType}, - "warehouse_id": types.StringType, + "parameters": basetypes.ListType{ + ElemType: QueryParameter{}.Type(ctx), + }, + "query_text": types.StringType, + "run_as_mode": types.StringType, + "schema": types.StringType, + "tags": basetypes.ListType{ + ElemType: types.StringType, + }, + "warehouse_id": types.StringType, }, } } @@ -11592,7 +11692,9 @@ func (o WarehouseAccessControlResponse) ToObjectValue(ctx context.Context) baset func (o WarehouseAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: WarehousePermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: WarehousePermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -11671,9 +11773,11 @@ func (o WarehousePermission) ToObjectValue(ctx context.Context) basetypes.Object func (o WarehousePermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -11748,9 +11852,11 @@ func (o WarehousePermissions) ToObjectValue(ctx context.Context) basetypes.Objec func (o WarehousePermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: WarehouseAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -11867,8 +11973,10 @@ func (o WarehousePermissionsRequest) ToObjectValue(ctx context.Context) basetype func (o WarehousePermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WarehouseAccessControlRequest{}.Type(ctx)}, - "warehouse_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: WarehouseAccessControlRequest{}.Type(ctx), + }, + "warehouse_id": types.StringType, }, } } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 390cf5883b..27136ff7c5 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -346,8 +346,10 @@ func (o DeleteDataResult) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o DeleteDataResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "failed_primary_keys": basetypes.ListType{ElemType: types.StringType}, - "success_row_count": types.Int64Type, + "failed_primary_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "success_row_count": types.Int64Type, }, } } @@ -422,8 +424,10 @@ func (o DeleteDataVectorIndexRequest) ToObjectValue(ctx context.Context) basetyp func (o DeleteDataVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "index_name": types.StringType, - "primary_keys": basetypes.ListType{ElemType: types.StringType}, + "index_name": types.StringType, + "primary_keys": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -756,9 +760,15 @@ func (o DeltaSyncVectorIndexSpecRequest) ToObjectValue(ctx context.Context) base func (o DeltaSyncVectorIndexSpecRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns_to_sync": basetypes.ListType{ElemType: types.StringType}, - "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, - "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, + "columns_to_sync": basetypes.ListType{ + ElemType: types.StringType, + }, + "embedding_source_columns": basetypes.ListType{ + ElemType: EmbeddingSourceColumn{}.Type(ctx), + }, + "embedding_vector_columns": basetypes.ListType{ + ElemType: EmbeddingVectorColumn{}.Type(ctx), + }, "embedding_writeback_table": types.StringType, "pipeline_type": types.StringType, "source_table": types.StringType, @@ -907,8 +917,12 @@ func (o DeltaSyncVectorIndexSpecResponse) ToObjectValue(ctx context.Context) bas func (o DeltaSyncVectorIndexSpecResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, - "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, + "embedding_source_columns": basetypes.ListType{ + ElemType: EmbeddingSourceColumn{}.Type(ctx), + }, + "embedding_vector_columns": basetypes.ListType{ + ElemType: EmbeddingVectorColumn{}.Type(ctx), + }, "embedding_writeback_table": types.StringType, "pipeline_id": types.StringType, "pipeline_type": types.StringType, @@ -1020,9 +1034,13 @@ func (o DirectAccessVectorIndexSpec) ToObjectValue(ctx context.Context) basetype func (o DirectAccessVectorIndexSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "embedding_source_columns": basetypes.ListType{ElemType: EmbeddingSourceColumn{}.Type(ctx)}, - "embedding_vector_columns": basetypes.ListType{ElemType: EmbeddingVectorColumn{}.Type(ctx)}, - "schema_json": types.StringType, + "embedding_source_columns": basetypes.ListType{ + ElemType: EmbeddingSourceColumn{}.Type(ctx), + }, + "embedding_vector_columns": basetypes.ListType{ + ElemType: EmbeddingVectorColumn{}.Type(ctx), + }, + "schema_json": types.StringType, }, } } @@ -1449,7 +1467,9 @@ func (o ListEndpointResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o ListEndpointResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "endpoints": basetypes.ListType{ElemType: EndpointInfo{}.Type(ctx)}, + "endpoints": basetypes.ListType{ + ElemType: EndpointInfo{}.Type(ctx), + }, "next_page_token": types.StringType, }, } @@ -1609,7 +1629,9 @@ func (o ListValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "values": basetypes.ListType{ElemType: Value{}.Type(ctx)}, + "values": basetypes.ListType{ + ElemType: Value{}.Type(ctx), + }, }, } } @@ -1684,7 +1706,9 @@ func (o ListVectorIndexesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "vector_indexes": basetypes.ListType{ElemType: MiniVectorIndex{}.Type(ctx)}, + "vector_indexes": basetypes.ListType{ + ElemType: MiniVectorIndex{}.Type(ctx), + }, }, } } @@ -1973,13 +1997,17 @@ func (o QueryVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o QueryVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "columns": basetypes.ListType{ElemType: types.StringType}, - "filters_json": types.StringType, - "index_name": types.StringType, - "num_results": types.Int64Type, - "query_text": types.StringType, - "query_type": types.StringType, - "query_vector": basetypes.ListType{ElemType: types.Float64Type}, + "columns": basetypes.ListType{ + ElemType: types.StringType, + }, + "filters_json": types.StringType, + "index_name": types.StringType, + "num_results": types.Int64Type, + "query_text": types.StringType, + "query_type": types.StringType, + "query_vector": basetypes.ListType{ + ElemType: types.Float64Type, + }, "score_threshold": types.Float64Type, }, } @@ -2187,8 +2215,12 @@ func (o ResultData) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ResultData) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data_array": basetypes.ListType{ElemType: basetypes.ListType{ElemType: types.StringType}}, - "row_count": types.Int64Type, + "data_array": basetypes.ListType{ + ElemType: basetypes.ListType{ + ElemType: types.StringType, + }, + }, + "row_count": types.Int64Type, }, } } @@ -2263,7 +2295,9 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "column_count": types.Int64Type, - "columns": basetypes.ListType{ElemType: ColumnInfo{}.Type(ctx)}, + "columns": basetypes.ListType{ + ElemType: ColumnInfo{}.Type(ctx), + }, }, } } @@ -2388,7 +2422,9 @@ func (o ScanVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ScanVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data": basetypes.ListType{ElemType: Struct{}.Type(ctx)}, + "data": basetypes.ListType{ + ElemType: Struct{}.Type(ctx), + }, "last_primary_key": types.StringType, }, } @@ -2459,7 +2495,9 @@ func (o Struct) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Struct) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "fields": basetypes.ListType{ElemType: MapStringValueEntry{}.Type(ctx)}, + "fields": basetypes.ListType{ + ElemType: MapStringValueEntry{}.Type(ctx), + }, }, } } @@ -2612,8 +2650,10 @@ func (o UpsertDataResult) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o UpsertDataResult) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "failed_primary_keys": basetypes.ListType{ElemType: types.StringType}, - "success_row_count": types.Int64Type, + "failed_primary_keys": basetypes.ListType{ + ElemType: types.StringType, + }, + "success_row_count": types.Int64Type, }, } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index e3b4c1b747..bea47f332a 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -1398,7 +1398,9 @@ func (o GetRepoPermissionLevelsResponse) ToObjectValue(ctx context.Context) base func (o GetRepoPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: RepoPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: RepoPermissionsDescription{}.Type(ctx), + }, }, } } @@ -1831,7 +1833,9 @@ func (o GetWorkspaceObjectPermissionLevelsResponse) ToObjectValue(ctx context.Co func (o GetWorkspaceObjectPermissionLevelsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "permission_levels": basetypes.ListType{ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx)}, + "permission_levels": basetypes.ListType{ + ElemType: WorkspaceObjectPermissionsDescription{}.Type(ctx), + }, }, } } @@ -2105,7 +2109,9 @@ func (o ListAclsResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListAclsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "items": basetypes.ListType{ElemType: AclItem{}.Type(ctx)}, + "items": basetypes.ListType{ + ElemType: AclItem{}.Type(ctx), + }, }, } } @@ -2175,7 +2181,9 @@ func (o ListCredentialsResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListCredentialsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credentials": basetypes.ListType{ElemType: CredentialInfo{}.Type(ctx)}, + "credentials": basetypes.ListType{ + ElemType: CredentialInfo{}.Type(ctx), + }, }, } } @@ -2301,7 +2309,9 @@ func (o ListReposResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "next_page_token": types.StringType, - "repos": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, + "repos": basetypes.ListType{ + ElemType: RepoInfo{}.Type(ctx), + }, }, } } @@ -2371,7 +2381,9 @@ func (o ListResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "objects": basetypes.ListType{ElemType: ObjectInfo{}.Type(ctx)}, + "objects": basetypes.ListType{ + ElemType: ObjectInfo{}.Type(ctx), + }, }, } } @@ -2441,7 +2453,9 @@ func (o ListScopesResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ListScopesResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "scopes": basetypes.ListType{ElemType: SecretScope{}.Type(ctx)}, + "scopes": basetypes.ListType{ + ElemType: SecretScope{}.Type(ctx), + }, }, } } @@ -2554,7 +2568,9 @@ func (o ListSecretsResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o ListSecretsResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "secrets": basetypes.ListType{ElemType: SecretMetadata{}.Type(ctx)}, + "secrets": basetypes.ListType{ + ElemType: SecretMetadata{}.Type(ctx), + }, }, } } @@ -3069,7 +3085,9 @@ func (o RepoAccessControlResponse) ToObjectValue(ctx context.Context) basetypes. func (o RepoAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: RepoPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: RepoPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -3243,9 +3261,11 @@ func (o RepoPermission) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o RepoPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -3320,9 +3340,11 @@ func (o RepoPermissions) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o RepoPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RepoAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: RepoAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -3439,8 +3461,10 @@ func (o RepoPermissionsRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o RepoPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: RepoAccessControlRequest{}.Type(ctx)}, - "repo_id": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: RepoAccessControlRequest{}.Type(ctx), + }, + "repo_id": types.StringType, }, } } @@ -3638,7 +3662,9 @@ func (o SparseCheckout) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o SparseCheckout) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "patterns": basetypes.ListType{ElemType: types.StringType}, + "patterns": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -3712,7 +3738,9 @@ func (o SparseCheckoutUpdate) ToObjectValue(ctx context.Context) basetypes.Objec func (o SparseCheckoutUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "patterns": basetypes.ListType{ElemType: types.StringType}, + "patterns": basetypes.ListType{ + ElemType: types.StringType, + }, }, } } @@ -4073,7 +4101,9 @@ func (o WorkspaceObjectAccessControlResponse) ToObjectValue(ctx context.Context) func (o WorkspaceObjectAccessControlResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "all_permissions": basetypes.ListType{ElemType: WorkspaceObjectPermission{}.Type(ctx)}, + "all_permissions": basetypes.ListType{ + ElemType: WorkspaceObjectPermission{}.Type(ctx), + }, "display_name": types.StringType, "group_name": types.StringType, "service_principal_name": types.StringType, @@ -4152,9 +4182,11 @@ func (o WorkspaceObjectPermission) ToObjectValue(ctx context.Context) basetypes. func (o WorkspaceObjectPermission) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "inherited": types.BoolType, - "inherited_from_object": basetypes.ListType{ElemType: types.StringType}, - "permission_level": types.StringType, + "inherited": types.BoolType, + "inherited_from_object": basetypes.ListType{ + ElemType: types.StringType, + }, + "permission_level": types.StringType, }, } } @@ -4229,9 +4261,11 @@ func (o WorkspaceObjectPermissions) ToObjectValue(ctx context.Context) basetypes func (o WorkspaceObjectPermissions) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx)}, - "object_id": types.StringType, - "object_type": types.StringType, + "access_control_list": basetypes.ListType{ + ElemType: WorkspaceObjectAccessControlResponse{}.Type(ctx), + }, + "object_id": types.StringType, + "object_type": types.StringType, }, } } @@ -4351,7 +4385,9 @@ func (o WorkspaceObjectPermissionsRequest) ToObjectValue(ctx context.Context) ba func (o WorkspaceObjectPermissionsRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_control_list": basetypes.ListType{ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx)}, + "access_control_list": basetypes.ListType{ + ElemType: WorkspaceObjectAccessControlRequest{}.Type(ctx), + }, "workspace_object_id": types.StringType, "workspace_object_type": types.StringType, }, From 92dbbe99aa21c8431a31a8ec91c25fc54f85f8fc Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Wed, 11 Dec 2024 20:32:37 +0100 Subject: [PATCH 76/91] fix formatting --- internal/service/billing_tf/model.go | 70 +- internal/service/catalog_tf/model.go | 952 ++++++++++++++-------- internal/service/cleanrooms_tf/model.go | 104 ++- internal/service/compute_tf/model.go | 512 ++++++++---- internal/service/dashboards_tf/model.go | 104 ++- internal/service/iam_tf/model.go | 20 +- internal/service/jobs_tf/model.go | 726 ++++++++++++----- internal/service/marketplace_tf/model.go | 260 ++++-- internal/service/ml_tf/model.go | 118 ++- internal/service/oauth2_tf/model.go | 38 +- internal/service/pipelines_tf/model.go | 240 ++++-- internal/service/provisioning_tf/model.go | 194 +++-- internal/service/serving_tf/model.go | 244 ++++-- internal/service/settings_tf/model.go | 266 ++++-- internal/service/sharing_tf/model.go | 68 +- internal/service/sql_tf/model.go | 480 +++++++---- internal/service/vectorsearch_tf/model.go | 82 +- internal/service/workspace_tf/model.go | 80 +- 18 files changed, 3039 insertions(+), 1519 deletions(-) diff --git a/internal/service/billing_tf/model.go b/internal/service/billing_tf/model.go index ec3ef6734c..45f387b508 100755 --- a/internal/service/billing_tf/model.go +++ b/internal/service/billing_tf/model.go @@ -236,8 +236,10 @@ func (o BudgetConfiguration) Type(ctx context.Context) attr.Type { "budget_configuration_id": types.StringType, "create_time": types.Int64Type, "display_name": types.StringType, - "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, - "update_time": types.Int64Type, + "filter": basetypes.ListType{ + ElemType: BudgetConfigurationFilter{}.Type(ctx), + }, + "update_time": types.Int64Type, }, } } @@ -342,7 +344,9 @@ func (o BudgetConfigurationFilter) Type(ctx context.Context) attr.Type { "tags": basetypes.ListType{ ElemType: BudgetConfigurationFilterTagClause{}.Type(ctx), }, - "workspace_id": basetypes.ListType{ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx)}, + "workspace_id": basetypes.ListType{ + ElemType: BudgetConfigurationFilterWorkspaceIdClause{}.Type(ctx), + }, }, } } @@ -515,8 +519,10 @@ func (o BudgetConfigurationFilterTagClause) ToObjectValue(ctx context.Context) b func (o BudgetConfigurationFilterTagClause) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "key": types.StringType, - "value": basetypes.ListType{ElemType: BudgetConfigurationFilterClause{}.Type(ctx)}, + "key": types.StringType, + "value": basetypes.ListType{ + ElemType: BudgetConfigurationFilterClause{}.Type(ctx), + }, }, } } @@ -771,7 +777,9 @@ func (o CreateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { ElemType: CreateBudgetConfigurationBudgetAlertConfigurations{}.Type(ctx), }, "display_name": types.StringType, - "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, + "filter": basetypes.ListType{ + ElemType: BudgetConfigurationFilter{}.Type(ctx), + }, }, } } @@ -1005,7 +1013,9 @@ func (o CreateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) bas func (o CreateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ElemType: CreateBudgetConfigurationBudget{}.Type(ctx)}, + "budget": basetypes.ListType{ + ElemType: CreateBudgetConfigurationBudget{}.Type(ctx), + }, }, } } @@ -1075,7 +1085,9 @@ func (o CreateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) ba func (o CreateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, + "budget": basetypes.ListType{ + ElemType: BudgetConfiguration{}.Type(ctx), + }, }, } } @@ -1613,7 +1625,9 @@ func (o GetBudgetConfigurationResponse) ToObjectValue(ctx context.Context) baset func (o GetBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, + "budget": basetypes.ListType{ + ElemType: BudgetConfiguration{}.Type(ctx), + }, }, } } @@ -1991,14 +2005,16 @@ func (o LogDeliveryConfiguration) ToObjectValue(ctx context.Context) basetypes.O func (o LogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "config_id": types.StringType, - "config_name": types.StringType, - "creation_time": types.Int64Type, - "credentials_id": types.StringType, - "delivery_path_prefix": types.StringType, - "delivery_start_time": types.StringType, - "log_delivery_status": basetypes.ListType{ElemType: LogDeliveryStatus{}.Type(ctx)}, + "account_id": types.StringType, + "config_id": types.StringType, + "config_name": types.StringType, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, + "delivery_path_prefix": types.StringType, + "delivery_start_time": types.StringType, + "log_delivery_status": basetypes.ListType{ + ElemType: LogDeliveryStatus{}.Type(ctx), + }, "log_type": types.StringType, "output_format": types.StringType, "status": types.StringType, @@ -2227,7 +2243,9 @@ func (o UpdateBudgetConfigurationBudget) Type(ctx context.Context) attr.Type { }, "budget_configuration_id": types.StringType, "display_name": types.StringType, - "filter": basetypes.ListType{ElemType: BudgetConfigurationFilter{}.Type(ctx)}, + "filter": basetypes.ListType{ + ElemType: BudgetConfigurationFilter{}.Type(ctx), + }, }, } } @@ -2327,7 +2345,9 @@ func (o UpdateBudgetConfigurationRequest) ToObjectValue(ctx context.Context) bas func (o UpdateBudgetConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ElemType: UpdateBudgetConfigurationBudget{}.Type(ctx)}, + "budget": basetypes.ListType{ + ElemType: UpdateBudgetConfigurationBudget{}.Type(ctx), + }, "budget_id": types.StringType, }, } @@ -2398,7 +2418,9 @@ func (o UpdateBudgetConfigurationResponse) ToObjectValue(ctx context.Context) ba func (o UpdateBudgetConfigurationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget": basetypes.ListType{ElemType: BudgetConfiguration{}.Type(ctx)}, + "budget": basetypes.ListType{ + ElemType: BudgetConfiguration{}.Type(ctx), + }, }, } } @@ -2517,7 +2539,9 @@ func (o WrappedCreateLogDeliveryConfiguration) ToObjectValue(ctx context.Context func (o WrappedCreateLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configuration": basetypes.ListType{ElemType: CreateLogDeliveryConfigurationParams{}.Type(ctx)}, + "log_delivery_configuration": basetypes.ListType{ + ElemType: CreateLogDeliveryConfigurationParams{}.Type(ctx), + }, }, } } @@ -2586,7 +2610,9 @@ func (o WrappedLogDeliveryConfiguration) ToObjectValue(ctx context.Context) base func (o WrappedLogDeliveryConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "log_delivery_configuration": basetypes.ListType{ElemType: LogDeliveryConfiguration{}.Type(ctx)}, + "log_delivery_configuration": basetypes.ListType{ + ElemType: LogDeliveryConfiguration{}.Type(ctx), + }, }, } } diff --git a/internal/service/catalog_tf/model.go b/internal/service/catalog_tf/model.go index 74c010723a..2c1bf7ab23 100755 --- a/internal/service/catalog_tf/model.go +++ b/internal/service/catalog_tf/model.go @@ -59,7 +59,9 @@ func (o AccountsCreateMetastore) ToObjectValue(ctx context.Context) basetypes.Ob func (o AccountsCreateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_info": basetypes.ListType{ElemType: CreateMetastore{}.Type(ctx)}, + "metastore_info": basetypes.ListType{ + ElemType: CreateMetastore{}.Type(ctx), + }, }, } } @@ -134,9 +136,11 @@ func (o AccountsCreateMetastoreAssignment) ToObjectValue(ctx context.Context) ba func (o AccountsCreateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_assignment": basetypes.ListType{ElemType: CreateMetastoreAssignment{}.Type(ctx)}, - "metastore_id": types.StringType, - "workspace_id": types.Int64Type, + "metastore_assignment": basetypes.ListType{ + ElemType: CreateMetastoreAssignment{}.Type(ctx), + }, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -208,8 +212,10 @@ func (o AccountsCreateStorageCredential) ToObjectValue(ctx context.Context) base func (o AccountsCreateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credential_info": basetypes.ListType{ElemType: CreateStorageCredential{}.Type(ctx)}, - "metastore_id": types.StringType, + "credential_info": basetypes.ListType{ + ElemType: CreateStorageCredential{}.Type(ctx), + }, + "metastore_id": types.StringType, }, } } @@ -278,7 +284,9 @@ func (o AccountsMetastoreAssignment) ToObjectValue(ctx context.Context) basetype func (o AccountsMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_assignment": basetypes.ListType{ElemType: MetastoreAssignment{}.Type(ctx)}, + "metastore_assignment": basetypes.ListType{ + ElemType: MetastoreAssignment{}.Type(ctx), + }, }, } } @@ -347,7 +355,9 @@ func (o AccountsMetastoreInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o AccountsMetastoreInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_info": basetypes.ListType{ElemType: MetastoreInfo{}.Type(ctx)}, + "metastore_info": basetypes.ListType{ + ElemType: MetastoreInfo{}.Type(ctx), + }, }, } } @@ -416,7 +426,9 @@ func (o AccountsStorageCredentialInfo) ToObjectValue(ctx context.Context) basety func (o AccountsStorageCredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credential_info": basetypes.ListType{ElemType: StorageCredentialInfo{}.Type(ctx)}, + "credential_info": basetypes.ListType{ + ElemType: StorageCredentialInfo{}.Type(ctx), + }, }, } } @@ -489,8 +501,10 @@ func (o AccountsUpdateMetastore) ToObjectValue(ctx context.Context) basetypes.Ob func (o AccountsUpdateMetastore) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_id": types.StringType, - "metastore_info": basetypes.ListType{ElemType: UpdateMetastore{}.Type(ctx)}, + "metastore_id": types.StringType, + "metastore_info": basetypes.ListType{ + ElemType: UpdateMetastore{}.Type(ctx), + }, }, } } @@ -565,9 +579,11 @@ func (o AccountsUpdateMetastoreAssignment) ToObjectValue(ctx context.Context) ba func (o AccountsUpdateMetastoreAssignment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "metastore_assignment": basetypes.ListType{ElemType: UpdateMetastoreAssignment{}.Type(ctx)}, - "metastore_id": types.StringType, - "workspace_id": types.Int64Type, + "metastore_assignment": basetypes.ListType{ + ElemType: UpdateMetastoreAssignment{}.Type(ctx), + }, + "metastore_id": types.StringType, + "workspace_id": types.Int64Type, }, } } @@ -642,7 +658,9 @@ func (o AccountsUpdateStorageCredential) ToObjectValue(ctx context.Context) base func (o AccountsUpdateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "credential_info": basetypes.ListType{ElemType: UpdateStorageCredential{}.Type(ctx)}, + "credential_info": basetypes.ListType{ + ElemType: UpdateStorageCredential{}.Type(ctx), + }, "metastore_id": types.StringType, "storage_credential_name": types.StringType, }, @@ -1563,18 +1581,20 @@ func (o CatalogInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CatalogInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "browse_only": types.BoolType, - "catalog_type": types.StringType, - "comment": types.StringType, - "connection_name": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "effective_predictive_optimization_flag": basetypes.ListType{ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx)}, - "enable_predictive_optimization": types.StringType, - "full_name": types.StringType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, + "browse_only": types.BoolType, + "catalog_type": types.StringType, + "comment": types.StringType, + "connection_name": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "effective_predictive_optimization_flag": basetypes.ListType{ + ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), + }, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, "options": basetypes.MapType{ ElemType: types.StringType, }, @@ -1582,15 +1602,17 @@ func (o CatalogInfo) Type(ctx context.Context) attr.Type { "properties": basetypes.MapType{ ElemType: types.StringType, }, - "provider_name": types.StringType, - "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, - "securable_kind": types.StringType, - "securable_type": types.StringType, - "share_name": types.StringType, - "storage_location": types.StringType, - "storage_root": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "provider_name": types.StringType, + "provisioning_info": basetypes.ListType{ + ElemType: ProvisioningInfo{}.Type(ctx), + }, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "share_name": types.StringType, + "storage_location": types.StringType, + "storage_root": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1821,8 +1843,10 @@ func (o ColumnInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ColumnInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "mask": basetypes.ListType{ElemType: ColumnMask{}.Type(ctx)}, + "comment": types.StringType, + "mask": basetypes.ListType{ + ElemType: ColumnMask{}.Type(ctx), + }, "name": types.StringType, "nullable": types.BoolType, "partition_index": types.Int64Type, @@ -2054,13 +2078,15 @@ func (o ConnectionInfo) Type(ctx context.Context) attr.Type { "properties": basetypes.MapType{ ElemType: types.StringType, }, - "provisioning_info": basetypes.ListType{ElemType: ProvisioningInfo{}.Type(ctx)}, - "read_only": types.BoolType, - "securable_kind": types.StringType, - "securable_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "url": types.StringType, + "provisioning_info": basetypes.ListType{ + ElemType: ProvisioningInfo{}.Type(ctx), + }, + "read_only": types.BoolType, + "securable_kind": types.StringType, + "securable_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "url": types.StringType, }, } } @@ -2193,9 +2219,11 @@ func (o ContinuousUpdateStatus) ToObjectValue(ctx context.Context) basetypes.Obj func (o ContinuousUpdateStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "initial_pipeline_sync_progress": basetypes.ListType{ElemType: PipelineProgress{}.Type(ctx)}, - "last_processed_commit_version": types.Int64Type, - "timestamp": types.StringType, + "initial_pipeline_sync_progress": basetypes.ListType{ + ElemType: PipelineProgress{}.Type(ctx), + }, + "last_processed_commit_version": types.Int64Type, + "timestamp": types.StringType, }, } } @@ -2551,15 +2579,23 @@ func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccount{}.Type(ctx)}, - "name": types.StringType, - "purpose": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccount{}.Type(ctx), + }, + "name": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -2734,15 +2770,17 @@ func (o CreateExternalLocation) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateExternalLocation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "comment": types.StringType, - "credential_name": types.StringType, - "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, - "fallback": types.BoolType, - "name": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, - "url": types.StringType, + "access_point": types.StringType, + "comment": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.Type(ctx), + }, + "fallback": types.BoolType, + "name": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, + "url": types.StringType, }, } } @@ -2878,27 +2916,33 @@ func (o CreateFunction) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CreateFunction) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalog_name": types.StringType, - "comment": types.StringType, - "data_type": types.StringType, - "external_language": types.StringType, - "external_name": types.StringType, - "full_data_type": types.StringType, - "input_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, - "is_deterministic": types.BoolType, - "is_null_call": types.BoolType, - "name": types.StringType, - "parameter_style": types.StringType, - "properties": types.StringType, - "return_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, - "routine_body": types.StringType, - "routine_definition": types.StringType, - "routine_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, - "schema_name": types.StringType, - "security_type": types.StringType, - "specific_name": types.StringType, - "sql_data_access": types.StringType, - "sql_path": types.StringType, + "catalog_name": types.StringType, + "comment": types.StringType, + "data_type": types.StringType, + "external_language": types.StringType, + "external_name": types.StringType, + "full_data_type": types.StringType, + "input_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.Type(ctx), + }, + "is_deterministic": types.BoolType, + "is_null_call": types.BoolType, + "name": types.StringType, + "parameter_style": types.StringType, + "properties": types.StringType, + "return_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.Type(ctx), + }, + "routine_body": types.StringType, + "routine_definition": types.StringType, + "routine_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.Type(ctx), + }, + "schema_name": types.StringType, + "security_type": types.StringType, + "specific_name": types.StringType, + "sql_data_access": types.StringType, + "sql_path": types.StringType, }, } } @@ -3020,7 +3064,9 @@ func (o CreateFunctionRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateFunctionRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function_info": basetypes.ListType{ElemType: CreateFunction{}.Type(ctx)}, + "function_info": basetypes.ListType{ + ElemType: CreateFunction{}.Type(ctx), + }, }, } } @@ -3256,18 +3302,30 @@ func (o CreateMonitor) Type(ctx context.Context) attr.Type { "custom_metrics": basetypes.ListType{ ElemType: MonitorMetric{}.Type(ctx), }, - "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, - "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, - "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, - "output_schema_name": types.StringType, - "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, - "skip_builtin_dashboard": types.BoolType, + "data_classification_config": basetypes.ListType{ + ElemType: MonitorDataClassificationConfig{}.Type(ctx), + }, + "inference_log": basetypes.ListType{ + ElemType: MonitorInferenceLog{}.Type(ctx), + }, + "notifications": basetypes.ListType{ + ElemType: MonitorNotifications{}.Type(ctx), + }, + "output_schema_name": types.StringType, + "schedule": basetypes.ListType{ + ElemType: MonitorCronSchedule{}.Type(ctx), + }, + "skip_builtin_dashboard": types.BoolType, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, - "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, - "table_name": types.StringType, - "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "snapshot": basetypes.ListType{ + ElemType: MonitorSnapshot{}.Type(ctx), + }, + "table_name": types.StringType, + "time_series": basetypes.ListType{ + ElemType: MonitorTimeSeries{}.Type(ctx), + }, "warehouse_id": types.StringType, }, } @@ -3521,7 +3579,9 @@ func (o CreateOnlineTableRequest) ToObjectValue(ctx context.Context) basetypes.O func (o CreateOnlineTableRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "table": basetypes.ListType{ElemType: OnlineTable{}.Type(ctx)}, + "table": basetypes.ListType{ + ElemType: OnlineTable{}.Type(ctx), + }, }, } } @@ -3803,15 +3863,25 @@ func (o CreateStorageCredential) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleRequest{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityRequest{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx)}, - "name": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleRequest{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityRequest{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.Type(ctx), + }, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), + }, + "name": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -3990,7 +4060,9 @@ func (o CreateTableConstraint) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateTableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "constraint": basetypes.ListType{ElemType: TableConstraint{}.Type(ctx)}, + "constraint": basetypes.ListType{ + ElemType: TableConstraint{}.Type(ctx), + }, "full_name_arg": types.StringType, }, } @@ -4183,24 +4255,32 @@ func (o CredentialInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccount{}.Type(ctx)}, - "full_name": types.StringType, - "id": types.StringType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "purpose": types.StringType, - "read_only": types.BoolType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "used_for_managed_storage": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccount{}.Type(ctx), + }, + "full_name": types.StringType, + "id": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "purpose": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "used_for_managed_storage": types.BoolType, }, } } @@ -5678,8 +5758,12 @@ func (o Dependency) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Dependency) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "function": basetypes.ListType{ElemType: FunctionDependency{}.Type(ctx)}, - "table": basetypes.ListType{ElemType: TableDependency{}.Type(ctx)}, + "function": basetypes.ListType{ + ElemType: FunctionDependency{}.Type(ctx), + }, + "table": basetypes.ListType{ + ElemType: TableDependency{}.Type(ctx), + }, }, } } @@ -6272,7 +6356,9 @@ func (o EncryptionDetails) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o EncryptionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "sse_encryption_details": basetypes.ListType{ElemType: SseEncryptionDetails{}.Type(ctx)}, + "sse_encryption_details": basetypes.ListType{ + ElemType: SseEncryptionDetails{}.Type(ctx), + }, }, } } @@ -6438,23 +6524,25 @@ func (o ExternalLocationInfo) ToObjectValue(ctx context.Context) basetypes.Objec func (o ExternalLocationInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "browse_only": types.BoolType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "credential_id": types.StringType, - "credential_name": types.StringType, - "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, - "fallback": types.BoolType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "url": types.StringType, + "access_point": types.StringType, + "browse_only": types.BoolType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "credential_id": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.Type(ctx), + }, + "fallback": types.BoolType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "url": types.StringType, }, } } @@ -6830,36 +6918,42 @@ func (o FunctionInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o FunctionInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "data_type": types.StringType, - "external_language": types.StringType, - "external_name": types.StringType, - "full_data_type": types.StringType, - "full_name": types.StringType, - "function_id": types.StringType, - "input_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, - "is_deterministic": types.BoolType, - "is_null_call": types.BoolType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "parameter_style": types.StringType, - "properties": types.StringType, - "return_params": basetypes.ListType{ElemType: FunctionParameterInfos{}.Type(ctx)}, - "routine_body": types.StringType, - "routine_definition": types.StringType, - "routine_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, - "schema_name": types.StringType, - "security_type": types.StringType, - "specific_name": types.StringType, - "sql_data_access": types.StringType, - "sql_path": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_type": types.StringType, + "external_language": types.StringType, + "external_name": types.StringType, + "full_data_type": types.StringType, + "full_name": types.StringType, + "function_id": types.StringType, + "input_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.Type(ctx), + }, + "is_deterministic": types.BoolType, + "is_null_call": types.BoolType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "parameter_style": types.StringType, + "properties": types.StringType, + "return_params": basetypes.ListType{ + ElemType: FunctionParameterInfos{}.Type(ctx), + }, + "routine_body": types.StringType, + "routine_definition": types.StringType, + "routine_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.Type(ctx), + }, + "schema_name": types.StringType, + "security_type": types.StringType, + "specific_name": types.StringType, + "sql_data_access": types.StringType, + "sql_path": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -7341,9 +7435,13 @@ func (o GenerateTemporaryServiceCredentialRequest) ToObjectValue(ctx context.Con func (o GenerateTemporaryServiceCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "azure_options": basetypes.ListType{ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.Type(ctx)}, + "azure_options": basetypes.ListType{ + ElemType: GenerateTemporaryServiceCredentialAzureOptions{}.Type(ctx), + }, "credential_name": types.StringType, - "gcp_options": basetypes.ListType{ElemType: GenerateTemporaryServiceCredentialGcpOptions{}.Type(ctx)}, + "gcp_options": basetypes.ListType{ + ElemType: GenerateTemporaryServiceCredentialGcpOptions{}.Type(ctx), + }, }, } } @@ -7516,13 +7614,23 @@ func (o GenerateTemporaryTableCredentialResponse) ToObjectValue(ctx context.Cont func (o GenerateTemporaryTableCredentialResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_temp_credentials": basetypes.ListType{ElemType: AwsCredentials{}.Type(ctx)}, - "azure_aad": basetypes.ListType{ElemType: AzureActiveDirectoryToken{}.Type(ctx)}, - "azure_user_delegation_sas": basetypes.ListType{ElemType: AzureUserDelegationSas{}.Type(ctx)}, - "expiration_time": types.Int64Type, - "gcp_oauth_token": basetypes.ListType{ElemType: GcpOauthToken{}.Type(ctx)}, - "r2_temp_credentials": basetypes.ListType{ElemType: R2Credentials{}.Type(ctx)}, - "url": types.StringType, + "aws_temp_credentials": basetypes.ListType{ + ElemType: AwsCredentials{}.Type(ctx), + }, + "azure_aad": basetypes.ListType{ + ElemType: AzureActiveDirectoryToken{}.Type(ctx), + }, + "azure_user_delegation_sas": basetypes.ListType{ + ElemType: AzureUserDelegationSas{}.Type(ctx), + }, + "expiration_time": types.Int64Type, + "gcp_oauth_token": basetypes.ListType{ + ElemType: GcpOauthToken{}.Type(ctx), + }, + "r2_temp_credentials": basetypes.ListType{ + ElemType: R2Credentials{}.Type(ctx), + }, + "url": types.StringType, }, } } @@ -8676,7 +8784,9 @@ func (o GetQuotaResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o GetQuotaResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "quota_info": basetypes.ListType{ElemType: QuotaInfo{}.Type(ctx)}, + "quota_info": basetypes.ListType{ + ElemType: QuotaInfo{}.Type(ctx), + }, }, } } @@ -11582,24 +11692,26 @@ func (o ModelVersionInfo) Type(ctx context.Context) attr.Type { "aliases": basetypes.ListType{ ElemType: RegisteredModelAlias{}.Type(ctx), }, - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "id": types.StringType, - "metastore_id": types.StringType, - "model_name": types.StringType, - "model_version_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, - "run_id": types.StringType, - "run_workspace_id": types.Int64Type, - "schema_name": types.StringType, - "source": types.StringType, - "status": types.StringType, - "storage_location": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "version": types.Int64Type, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "id": types.StringType, + "metastore_id": types.StringType, + "model_name": types.StringType, + "model_version_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.Type(ctx), + }, + "run_id": types.StringType, + "run_workspace_id": types.Int64Type, + "schema_name": types.StringType, + "source": types.StringType, + "status": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "version": types.Int64Type, }, } } @@ -12049,23 +12161,35 @@ func (o MonitorInfo) Type(ctx context.Context) attr.Type { "custom_metrics": basetypes.ListType{ ElemType: MonitorMetric{}.Type(ctx), }, - "dashboard_id": types.StringType, - "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, - "drift_metrics_table_name": types.StringType, - "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, + "dashboard_id": types.StringType, + "data_classification_config": basetypes.ListType{ + ElemType: MonitorDataClassificationConfig{}.Type(ctx), + }, + "drift_metrics_table_name": types.StringType, + "inference_log": basetypes.ListType{ + ElemType: MonitorInferenceLog{}.Type(ctx), + }, "latest_monitor_failure_msg": types.StringType, "monitor_version": types.StringType, - "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, + "notifications": basetypes.ListType{ + ElemType: MonitorNotifications{}.Type(ctx), + }, "output_schema_name": types.StringType, "profile_metrics_table_name": types.StringType, - "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, + "schedule": basetypes.ListType{ + ElemType: MonitorCronSchedule{}.Type(ctx), + }, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, - "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, - "status": types.StringType, - "table_name": types.StringType, - "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "snapshot": basetypes.ListType{ + ElemType: MonitorSnapshot{}.Type(ctx), + }, + "status": types.StringType, + "table_name": types.StringType, + "time_series": basetypes.ListType{ + ElemType: MonitorTimeSeries{}.Type(ctx), + }, }, } } @@ -12424,8 +12548,12 @@ func (o MonitorNotifications) ToObjectValue(ctx context.Context) basetypes.Objec func (o MonitorNotifications) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "on_failure": basetypes.ListType{ElemType: MonitorDestination{}.Type(ctx)}, - "on_new_classification_tag_detected": basetypes.ListType{ElemType: MonitorDestination{}.Type(ctx)}, + "on_failure": basetypes.ListType{ + ElemType: MonitorDestination{}.Type(ctx), + }, + "on_new_classification_tag_detected": basetypes.ListType{ + ElemType: MonitorDestination{}.Type(ctx), + }, }, } } @@ -12837,9 +12965,13 @@ func (o OnlineTable) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o OnlineTable) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "spec": basetypes.ListType{ElemType: OnlineTableSpec{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: OnlineTableStatus{}.Type(ctx)}, + "name": types.StringType, + "spec": basetypes.ListType{ + ElemType: OnlineTableSpec{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: OnlineTableStatus{}.Type(ctx), + }, "table_serving_url": types.StringType, "unity_catalog_provisioning_state": types.StringType, }, @@ -12972,8 +13104,12 @@ func (o OnlineTableSpec) Type(ctx context.Context) attr.Type { "primary_key_columns": basetypes.ListType{ ElemType: types.StringType, }, - "run_continuously": basetypes.ListType{ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.Type(ctx)}, - "run_triggered": basetypes.ListType{ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.Type(ctx)}, + "run_continuously": basetypes.ListType{ + ElemType: OnlineTableSpecContinuousSchedulingPolicy{}.Type(ctx), + }, + "run_triggered": basetypes.ListType{ + ElemType: OnlineTableSpecTriggeredSchedulingPolicy{}.Type(ctx), + }, "source_table_full_name": types.StringType, "timeseries_key": types.StringType, }, @@ -13193,12 +13329,20 @@ func (o OnlineTableStatus) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o OnlineTableStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "continuous_update_status": basetypes.ListType{ElemType: ContinuousUpdateStatus{}.Type(ctx)}, - "detailed_state": types.StringType, - "failed_status": basetypes.ListType{ElemType: FailedStatus{}.Type(ctx)}, - "message": types.StringType, - "provisioning_status": basetypes.ListType{ElemType: ProvisioningStatus{}.Type(ctx)}, - "triggered_update_status": basetypes.ListType{ElemType: TriggeredUpdateStatus{}.Type(ctx)}, + "continuous_update_status": basetypes.ListType{ + ElemType: ContinuousUpdateStatus{}.Type(ctx), + }, + "detailed_state": types.StringType, + "failed_status": basetypes.ListType{ + ElemType: FailedStatus{}.Type(ctx), + }, + "message": types.StringType, + "provisioning_status": basetypes.ListType{ + ElemType: ProvisioningStatus{}.Type(ctx), + }, + "triggered_update_status": basetypes.ListType{ + ElemType: TriggeredUpdateStatus{}.Type(ctx), + }, }, } } @@ -13785,7 +13929,9 @@ func (o ProvisioningStatus) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ProvisioningStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "initial_pipeline_sync_progress": basetypes.ListType{ElemType: PipelineProgress{}.Type(ctx)}, + "initial_pipeline_sync_progress": basetypes.ListType{ + ElemType: PipelineProgress{}.Type(ctx), + }, }, } } @@ -14385,18 +14531,20 @@ func (o SchemaInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SchemaInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "catalog_type": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "effective_predictive_optimization_flag": basetypes.ListType{ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx)}, - "enable_predictive_optimization": types.StringType, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "catalog_type": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "effective_predictive_optimization_flag": basetypes.ListType{ + ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), + }, + "enable_predictive_optimization": types.StringType, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, "properties": basetypes.MapType{ ElemType: types.StringType, }, @@ -14730,24 +14878,34 @@ func (o StorageCredentialInfo) ToObjectValue(ctx context.Context) basetypes.Obje func (o StorageCredentialInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleResponse{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityResponse{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountResponse{}.Type(ctx)}, - "full_name": types.StringType, - "id": types.StringType, - "isolation_mode": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "used_for_managed_storage": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleResponse{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityResponse{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.Type(ctx), + }, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountResponse{}.Type(ctx), + }, + "full_name": types.StringType, + "id": types.StringType, + "isolation_mode": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "used_for_managed_storage": types.BoolType, }, } } @@ -14978,9 +15136,15 @@ func (o TableConstraint) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o TableConstraint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "foreign_key_constraint": basetypes.ListType{ElemType: ForeignKeyConstraint{}.Type(ctx)}, - "named_table_constraint": basetypes.ListType{ElemType: NamedTableConstraint{}.Type(ctx)}, - "primary_key_constraint": basetypes.ListType{ElemType: PrimaryKeyConstraint{}.Type(ctx)}, + "foreign_key_constraint": basetypes.ListType{ + ElemType: ForeignKeyConstraint{}.Type(ctx), + }, + "named_table_constraint": basetypes.ListType{ + ElemType: NamedTableConstraint{}.Type(ctx), + }, + "primary_key_constraint": basetypes.ListType{ + ElemType: PrimaryKeyConstraint{}.Type(ctx), + }, }, } } @@ -15307,25 +15471,33 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "columns": basetypes.ListType{ ElemType: ColumnInfo{}.Type(ctx), }, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "data_access_configuration_id": types.StringType, - "data_source_format": types.StringType, - "deleted_at": types.Int64Type, - "delta_runtime_properties_kvpairs": basetypes.ListType{ElemType: DeltaRuntimePropertiesKvPairs{}.Type(ctx)}, - "effective_predictive_optimization_flag": basetypes.ListType{ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx)}, - "enable_predictive_optimization": types.StringType, - "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "pipeline_id": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "data_access_configuration_id": types.StringType, + "data_source_format": types.StringType, + "deleted_at": types.Int64Type, + "delta_runtime_properties_kvpairs": basetypes.ListType{ + ElemType: DeltaRuntimePropertiesKvPairs{}.Type(ctx), + }, + "effective_predictive_optimization_flag": basetypes.ListType{ + ElemType: EffectivePredictiveOptimizationFlag{}.Type(ctx), + }, + "enable_predictive_optimization": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.Type(ctx), + }, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "pipeline_id": types.StringType, "properties": basetypes.MapType{ ElemType: types.StringType, }, - "row_filter": basetypes.ListType{ElemType: TableRowFilter{}.Type(ctx)}, + "row_filter": basetypes.ListType{ + ElemType: TableRowFilter{}.Type(ctx), + }, "schema_name": types.StringType, "sql_path": types.StringType, "storage_credential_name": types.StringType, @@ -15333,12 +15505,14 @@ func (o TableInfo) Type(ctx context.Context) attr.Type { "table_constraints": basetypes.ListType{ ElemType: TableConstraint{}.Type(ctx), }, - "table_id": types.StringType, - "table_type": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "view_definition": types.StringType, - "view_dependencies": basetypes.ListType{ElemType: DependencyList{}.Type(ctx)}, + "table_id": types.StringType, + "table_type": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "view_definition": types.StringType, + "view_dependencies": basetypes.ListType{ + ElemType: DependencyList{}.Type(ctx), + }, }, } } @@ -15725,9 +15899,13 @@ func (o TemporaryCredentials) ToObjectValue(ctx context.Context) basetypes.Objec func (o TemporaryCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_temp_credentials": basetypes.ListType{ElemType: AwsCredentials{}.Type(ctx)}, - "azure_aad": basetypes.ListType{ElemType: AzureActiveDirectoryToken{}.Type(ctx)}, - "expiration_time": types.Int64Type, + "aws_temp_credentials": basetypes.ListType{ + ElemType: AwsCredentials{}.Type(ctx), + }, + "azure_aad": basetypes.ListType{ + ElemType: AzureActiveDirectoryToken{}.Type(ctx), + }, + "expiration_time": types.Int64Type, }, } } @@ -15836,7 +16014,9 @@ func (o TriggeredUpdateStatus) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "last_processed_commit_version": types.Int64Type, "timestamp": types.StringType, - "triggered_update_progress": basetypes.ListType{ElemType: PipelineProgress{}.Type(ctx)}, + "triggered_update_progress": basetypes.ListType{ + ElemType: PipelineProgress{}.Type(ctx), + }, }, } } @@ -16250,18 +16430,26 @@ func (o UpdateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccount{}.Type(ctx)}, - "force": types.BoolType, - "isolation_mode": types.StringType, - "name_arg": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccount{}.Type(ctx), + }, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name_arg": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -16449,19 +16637,21 @@ func (o UpdateExternalLocation) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateExternalLocation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "comment": types.StringType, - "credential_name": types.StringType, - "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, - "fallback": types.BoolType, - "force": types.BoolType, - "isolation_mode": types.StringType, - "name": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, - "url": types.StringType, + "access_point": types.StringType, + "comment": types.StringType, + "credential_name": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.Type(ctx), + }, + "fallback": types.BoolType, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, + "url": types.StringType, }, } } @@ -16805,18 +16995,30 @@ func (o UpdateMonitor) Type(ctx context.Context) attr.Type { "custom_metrics": basetypes.ListType{ ElemType: MonitorMetric{}.Type(ctx), }, - "dashboard_id": types.StringType, - "data_classification_config": basetypes.ListType{ElemType: MonitorDataClassificationConfig{}.Type(ctx)}, - "inference_log": basetypes.ListType{ElemType: MonitorInferenceLog{}.Type(ctx)}, - "notifications": basetypes.ListType{ElemType: MonitorNotifications{}.Type(ctx)}, - "output_schema_name": types.StringType, - "schedule": basetypes.ListType{ElemType: MonitorCronSchedule{}.Type(ctx)}, + "dashboard_id": types.StringType, + "data_classification_config": basetypes.ListType{ + ElemType: MonitorDataClassificationConfig{}.Type(ctx), + }, + "inference_log": basetypes.ListType{ + ElemType: MonitorInferenceLog{}.Type(ctx), + }, + "notifications": basetypes.ListType{ + ElemType: MonitorNotifications{}.Type(ctx), + }, + "output_schema_name": types.StringType, + "schedule": basetypes.ListType{ + ElemType: MonitorCronSchedule{}.Type(ctx), + }, "slicing_exprs": basetypes.ListType{ ElemType: types.StringType, }, - "snapshot": basetypes.ListType{ElemType: MonitorSnapshot{}.Type(ctx)}, - "table_name": types.StringType, - "time_series": basetypes.ListType{ElemType: MonitorTimeSeries{}.Type(ctx)}, + "snapshot": basetypes.ListType{ + ElemType: MonitorSnapshot{}.Type(ctx), + }, + "table_name": types.StringType, + "time_series": basetypes.ListType{ + ElemType: MonitorTimeSeries{}.Type(ctx), + }, }, } } @@ -17373,19 +17575,29 @@ func (o UpdateStorageCredential) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleRequest{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityResponse{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, - "comment": types.StringType, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx)}, - "force": types.BoolType, - "isolation_mode": types.StringType, - "name": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "read_only": types.BoolType, - "skip_validation": types.BoolType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleRequest{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityResponse{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.Type(ctx), + }, + "comment": types.StringType, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), + }, + "force": types.BoolType, + "isolation_mode": types.StringType, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "read_only": types.BoolType, + "skip_validation": types.BoolType, }, } } @@ -17906,8 +18118,12 @@ func (o ValidateCredentialRequest) ToObjectValue(ctx context.Context) basetypes. func (o ValidateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRole{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentity{}.Type(ctx)}, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRole{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentity{}.Type(ctx), + }, "credential_name": types.StringType, "external_location_name": types.StringType, "purpose": types.StringType, @@ -18113,15 +18329,25 @@ func (o ValidateStorageCredential) ToObjectValue(ctx context.Context) basetypes. func (o ValidateStorageCredential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_iam_role": basetypes.ListType{ElemType: AwsIamRoleRequest{}.Type(ctx)}, - "azure_managed_identity": basetypes.ListType{ElemType: AzureManagedIdentityRequest{}.Type(ctx)}, - "azure_service_principal": basetypes.ListType{ElemType: AzureServicePrincipal{}.Type(ctx)}, - "cloudflare_api_token": basetypes.ListType{ElemType: CloudflareApiToken{}.Type(ctx)}, - "databricks_gcp_service_account": basetypes.ListType{ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx)}, - "external_location_name": types.StringType, - "read_only": types.BoolType, - "storage_credential_name": types.StringType, - "url": types.StringType, + "aws_iam_role": basetypes.ListType{ + ElemType: AwsIamRoleRequest{}.Type(ctx), + }, + "azure_managed_identity": basetypes.ListType{ + ElemType: AzureManagedIdentityRequest{}.Type(ctx), + }, + "azure_service_principal": basetypes.ListType{ + ElemType: AzureServicePrincipal{}.Type(ctx), + }, + "cloudflare_api_token": basetypes.ListType{ + ElemType: CloudflareApiToken{}.Type(ctx), + }, + "databricks_gcp_service_account": basetypes.ListType{ + ElemType: DatabricksGcpServiceAccountRequest{}.Type(ctx), + }, + "external_location_name": types.StringType, + "read_only": types.BoolType, + "storage_credential_name": types.StringType, + "url": types.StringType, }, } } @@ -18471,23 +18697,25 @@ func (o VolumeInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o VolumeInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "access_point": types.StringType, - "browse_only": types.BoolType, - "catalog_name": types.StringType, - "comment": types.StringType, - "created_at": types.Int64Type, - "created_by": types.StringType, - "encryption_details": basetypes.ListType{ElemType: EncryptionDetails{}.Type(ctx)}, - "full_name": types.StringType, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "schema_name": types.StringType, - "storage_location": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "volume_id": types.StringType, - "volume_type": types.StringType, + "access_point": types.StringType, + "browse_only": types.BoolType, + "catalog_name": types.StringType, + "comment": types.StringType, + "created_at": types.Int64Type, + "created_by": types.StringType, + "encryption_details": basetypes.ListType{ + ElemType: EncryptionDetails{}.Type(ctx), + }, + "full_name": types.StringType, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "schema_name": types.StringType, + "storage_location": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "volume_id": types.StringType, + "volume_type": types.StringType, }, } } diff --git a/internal/service/cleanrooms_tf/model.go b/internal/service/cleanrooms_tf/model.go index ad59ad6da3..71f1a62633 100755 --- a/internal/service/cleanrooms_tf/model.go +++ b/internal/service/cleanrooms_tf/model.go @@ -107,11 +107,15 @@ func (o CleanRoom) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "local_collaborator_alias": types.StringType, "name": types.StringType, - "output_catalog": basetypes.ListType{ElemType: CleanRoomOutputCatalog{}.Type(ctx)}, - "owner": types.StringType, - "remote_detailed_info": basetypes.ListType{ElemType: CleanRoomRemoteDetail{}.Type(ctx)}, - "status": types.StringType, - "updated_at": types.Int64Type, + "output_catalog": basetypes.ListType{ + ElemType: CleanRoomOutputCatalog{}.Type(ctx), + }, + "owner": types.StringType, + "remote_detailed_info": basetypes.ListType{ + ElemType: CleanRoomRemoteDetail{}.Type(ctx), + }, + "status": types.StringType, + "updated_at": types.Int64Type, }, } } @@ -265,19 +269,35 @@ func (o CleanRoomAsset) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o CleanRoomAsset) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "added_at": types.Int64Type, - "asset_type": types.StringType, - "foreign_table": basetypes.ListType{ElemType: CleanRoomAssetForeignTable{}.Type(ctx)}, - "foreign_table_local_details": basetypes.ListType{ElemType: CleanRoomAssetForeignTableLocalDetails{}.Type(ctx)}, - "name": types.StringType, - "notebook": basetypes.ListType{ElemType: CleanRoomAssetNotebook{}.Type(ctx)}, - "owner_collaborator_alias": types.StringType, - "status": types.StringType, - "table": basetypes.ListType{ElemType: CleanRoomAssetTable{}.Type(ctx)}, - "table_local_details": basetypes.ListType{ElemType: CleanRoomAssetTableLocalDetails{}.Type(ctx)}, - "view": basetypes.ListType{ElemType: CleanRoomAssetView{}.Type(ctx)}, - "view_local_details": basetypes.ListType{ElemType: CleanRoomAssetViewLocalDetails{}.Type(ctx)}, - "volume_local_details": basetypes.ListType{ElemType: CleanRoomAssetVolumeLocalDetails{}.Type(ctx)}, + "added_at": types.Int64Type, + "asset_type": types.StringType, + "foreign_table": basetypes.ListType{ + ElemType: CleanRoomAssetForeignTable{}.Type(ctx), + }, + "foreign_table_local_details": basetypes.ListType{ + ElemType: CleanRoomAssetForeignTableLocalDetails{}.Type(ctx), + }, + "name": types.StringType, + "notebook": basetypes.ListType{ + ElemType: CleanRoomAssetNotebook{}.Type(ctx), + }, + "owner_collaborator_alias": types.StringType, + "status": types.StringType, + "table": basetypes.ListType{ + ElemType: CleanRoomAssetTable{}.Type(ctx), + }, + "table_local_details": basetypes.ListType{ + ElemType: CleanRoomAssetTableLocalDetails{}.Type(ctx), + }, + "view": basetypes.ListType{ + ElemType: CleanRoomAssetView{}.Type(ctx), + }, + "view_local_details": basetypes.ListType{ + ElemType: CleanRoomAssetViewLocalDetails{}.Type(ctx), + }, + "volume_local_details": basetypes.ListType{ + ElemType: CleanRoomAssetVolumeLocalDetails{}.Type(ctx), + }, }, } } @@ -1103,8 +1123,12 @@ func (o CleanRoomNotebookTaskRun) ToObjectValue(ctx context.Context) basetypes.O func (o CleanRoomNotebookTaskRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "collaborator_job_run_info": basetypes.ListType{ElemType: CollaboratorJobRunInfo{}.Type(ctx)}, - "notebook_job_run_state": basetypes.ListType{ElemType: jobs_tf.CleanRoomTaskRunState{}.Type(ctx)}, + "collaborator_job_run_info": basetypes.ListType{ + ElemType: CollaboratorJobRunInfo{}.Type(ctx), + }, + "notebook_job_run_state": basetypes.ListType{ + ElemType: jobs_tf.CleanRoomTaskRunState{}.Type(ctx), + }, "notebook_name": types.StringType, "output_schema_expiration_time": types.Int64Type, "output_schema_name": types.StringType, @@ -1288,10 +1312,16 @@ func (o CleanRoomRemoteDetail) Type(ctx context.Context) attr.Type { "collaborators": basetypes.ListType{ ElemType: CleanRoomCollaborator{}.Type(ctx), }, - "compliance_security_profile": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, - "creator": basetypes.ListType{ElemType: CleanRoomCollaborator{}.Type(ctx)}, - "egress_network_policy": basetypes.ListType{ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx)}, - "region": types.StringType, + "compliance_security_profile": basetypes.ListType{ + ElemType: ComplianceSecurityProfile{}.Type(ctx), + }, + "creator": basetypes.ListType{ + ElemType: CleanRoomCollaborator{}.Type(ctx), + }, + "egress_network_policy": basetypes.ListType{ + ElemType: settings_tf.EgressNetworkPolicy{}.Type(ctx), + }, + "region": types.StringType, }, } } @@ -1580,7 +1610,9 @@ func (o CreateCleanRoomAssetRequest) ToObjectValue(ctx context.Context) basetype func (o CreateCleanRoomAssetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "asset": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, + "asset": basetypes.ListType{ + ElemType: CleanRoomAsset{}.Type(ctx), + }, "clean_room_name": types.StringType, }, } @@ -1656,7 +1688,9 @@ func (o CreateCleanRoomOutputCatalogRequest) Type(ctx context.Context) attr.Type return types.ObjectType{ AttrTypes: map[string]attr.Type{ "clean_room_name": types.StringType, - "output_catalog": basetypes.ListType{ElemType: CleanRoomOutputCatalog{}.Type(ctx)}, + "output_catalog": basetypes.ListType{ + ElemType: CleanRoomOutputCatalog{}.Type(ctx), + }, }, } } @@ -1725,7 +1759,9 @@ func (o CreateCleanRoomOutputCatalogResponse) ToObjectValue(ctx context.Context) func (o CreateCleanRoomOutputCatalogResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "output_catalog": basetypes.ListType{ElemType: CleanRoomOutputCatalog{}.Type(ctx)}, + "output_catalog": basetypes.ListType{ + ElemType: CleanRoomOutputCatalog{}.Type(ctx), + }, }, } } @@ -1795,7 +1831,9 @@ func (o CreateCleanRoomRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateCleanRoomRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_room": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, + "clean_room": basetypes.ListType{ + ElemType: CleanRoom{}.Type(ctx), + }, }, } } @@ -2527,7 +2565,9 @@ func (o UpdateCleanRoomAssetRequest) ToObjectValue(ctx context.Context) basetype func (o UpdateCleanRoomAssetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "asset": basetypes.ListType{ElemType: CleanRoomAsset{}.Type(ctx)}, + "asset": basetypes.ListType{ + ElemType: CleanRoomAsset{}.Type(ctx), + }, "asset_type": types.StringType, "clean_room_name": types.StringType, "name": types.StringType, @@ -2602,8 +2642,10 @@ func (o UpdateCleanRoomRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateCleanRoomRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clean_room": basetypes.ListType{ElemType: CleanRoom{}.Type(ctx)}, - "name": types.StringType, + "clean_room": basetypes.ListType{ + ElemType: CleanRoom{}.Type(ctx), + }, + "name": types.StringType, }, } } diff --git a/internal/service/compute_tf/model.go b/internal/service/compute_tf/model.go index 980ca1ec1e..ad9792e562 100755 --- a/internal/service/compute_tf/model.go +++ b/internal/service/compute_tf/model.go @@ -426,9 +426,11 @@ func (o AzureAttributes) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o AzureAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "availability": types.StringType, - "first_on_demand": types.Int64Type, - "log_analytics_info": basetypes.ListType{ElemType: LogAnalyticsInfo{}.Type(ctx)}, + "availability": types.StringType, + "first_on_demand": types.Int64Type, + "log_analytics_info": basetypes.ListType{ + ElemType: LogAnalyticsInfo{}.Type(ctx), + }, "spot_bid_max_price": types.Float64Type, }, } @@ -1129,20 +1131,30 @@ func (o ClusterAttributes) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.Type(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.Type(ctx), + }, + "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.Type(ctx), }, @@ -1161,7 +1173,9 @@ func (o ClusterAttributes) Type(ctx context.Context) attr.Type { "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.Type(ctx), + }, }, } } @@ -1847,18 +1861,28 @@ func (o ClusterDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ClusterDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_cores": types.Float64Type, - "cluster_id": types.StringType, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_log_status": basetypes.ListType{ElemType: LogSyncStatus{}.Type(ctx)}, - "cluster_memory_mb": types.Int64Type, - "cluster_name": types.StringType, - "cluster_source": types.StringType, - "creator_user_name": types.StringType, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.Type(ctx), + }, + "cluster_cores": types.Float64Type, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.Type(ctx), + }, + "cluster_log_status": basetypes.ListType{ + ElemType: LogSyncStatus{}.Type(ctx), + }, + "cluster_memory_mb": types.Int64Type, + "cluster_name": types.StringType, + "cluster_source": types.StringType, + "creator_user_name": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, @@ -1866,8 +1890,12 @@ func (o ClusterDetails) Type(ctx context.Context) attr.Type { "default_tags": basetypes.MapType{ ElemType: types.StringType, }, - "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, - "driver": basetypes.ListType{ElemType: SparkNode{}.Type(ctx)}, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, + "driver": basetypes.ListType{ + ElemType: SparkNode{}.Type(ctx), + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, @@ -1875,7 +1903,9 @@ func (o ClusterDetails) Type(ctx context.Context) attr.Type { "executors": basetypes.ListType{ ElemType: SparkNode{}.Type(ctx), }, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.Type(ctx), }, @@ -1896,16 +1926,22 @@ func (o ClusterDetails) Type(ctx context.Context) attr.Type { ElemType: types.StringType, }, "spark_version": types.StringType, - "spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "spec": basetypes.ListType{ + ElemType: ClusterSpec{}.Type(ctx), + }, "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "start_time": types.Int64Type, - "state": types.StringType, - "state_message": types.StringType, - "terminated_time": types.Int64Type, - "termination_reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "start_time": types.Int64Type, + "state": types.StringType, + "state_message": types.StringType, + "terminated_time": types.Int64Type, + "termination_reason": basetypes.ListType{ + ElemType: TerminationReason{}.Type(ctx), + }, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.Type(ctx), + }, }, } } @@ -2432,11 +2468,15 @@ func (o ClusterEvent) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ClusterEvent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster_id": types.StringType, - "data_plane_event_details": basetypes.ListType{ElemType: DataPlaneEventDetails{}.Type(ctx)}, - "details": basetypes.ListType{ElemType: EventDetails{}.Type(ctx)}, - "timestamp": types.Int64Type, - "type": types.StringType, + "cluster_id": types.StringType, + "data_plane_event_details": basetypes.ListType{ + ElemType: DataPlaneEventDetails{}.Type(ctx), + }, + "details": basetypes.ListType{ + ElemType: EventDetails{}.Type(ctx), + }, + "timestamp": types.Int64Type, + "type": types.StringType, }, } } @@ -2617,8 +2657,12 @@ func (o ClusterLogConf) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ClusterLogConf) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbfs": basetypes.ListType{ElemType: DbfsStorageInfo{}.Type(ctx)}, - "s3": basetypes.ListType{ElemType: S3StorageInfo{}.Type(ctx)}, + "dbfs": basetypes.ListType{ + ElemType: DbfsStorageInfo{}.Type(ctx), + }, + "s3": basetypes.ListType{ + ElemType: S3StorageInfo{}.Type(ctx), + }, }, } } @@ -3484,7 +3528,9 @@ func (o ClusterSize) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ClusterSize) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, "num_workers": types.Int64Type, }, } @@ -3740,22 +3786,34 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.Type(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.Type(ctx), + }, + "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.Type(ctx), }, @@ -3775,7 +3833,9 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.Type(ctx), + }, }, } } @@ -4283,9 +4343,11 @@ func (o CommandStatusResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o CommandStatusResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "results": basetypes.ListType{ElemType: Results{}.Type(ctx)}, - "status": types.StringType, + "id": types.StringType, + "results": basetypes.ListType{ + ElemType: Results{}.Type(ctx), + }, + "status": types.StringType, }, } } @@ -4636,23 +4698,37 @@ func (o CreateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "clone_from": basetypes.ListType{ElemType: CloneCluster{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.Type(ctx), + }, + "clone_from": basetypes.ListType{ + ElemType: CloneCluster{}.Type(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.Type(ctx), + }, + "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.Type(ctx), }, @@ -4672,7 +4748,9 @@ func (o CreateCluster) Type(ctx context.Context) attr.Type { "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.Type(ctx), + }, }, } } @@ -5211,14 +5289,22 @@ func (o CreateInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "aws_attributes": basetypes.ListType{ + ElemType: InstancePoolAwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: InstancePoolAzureAttributes{}.Type(ctx), + }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, - "enable_elastic_disk": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, + "disk_spec": basetypes.ListType{ + ElemType: DiskSpec{}.Type(ctx), + }, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: InstancePoolGcpAttributes{}.Type(ctx), + }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_name": types.StringType, "max_capacity": types.Int64Type, @@ -6265,7 +6351,9 @@ func (o DiskSpec) Type(ctx context.Context) attr.Type { "disk_iops": types.Int64Type, "disk_size": types.Int64Type, "disk_throughput": types.Int64Type, - "disk_type": basetypes.ListType{ElemType: DiskType{}.Type(ctx)}, + "disk_type": basetypes.ListType{ + ElemType: DiskType{}.Type(ctx), + }, }, } } @@ -6428,8 +6516,10 @@ func (o DockerImage) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DockerImage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "basic_auth": basetypes.ListType{ElemType: DockerBasicAuth{}.Type(ctx)}, - "url": types.StringType, + "basic_auth": basetypes.ListType{ + ElemType: DockerBasicAuth{}.Type(ctx), + }, + "url": types.StringType, }, } } @@ -6687,23 +6777,35 @@ func (o EditCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, - "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_id": types.StringType, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, + "autotermination_minutes": types.Int64Type, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.Type(ctx), + }, + "cluster_id": types.StringType, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.Type(ctx), + }, + "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.Type(ctx), }, @@ -6723,7 +6825,9 @@ func (o EditCluster) Type(ctx context.Context) attr.Type { "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.Type(ctx), + }, }, } } @@ -7737,26 +7841,38 @@ func (o EventDetails) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EventDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attributes": basetypes.ListType{ElemType: ClusterAttributes{}.Type(ctx)}, - "cause": types.StringType, - "cluster_size": basetypes.ListType{ElemType: ClusterSize{}.Type(ctx)}, - "current_num_vcpus": types.Int64Type, - "current_num_workers": types.Int64Type, - "did_not_expand_reason": types.StringType, - "disk_size": types.Int64Type, - "driver_state_message": types.StringType, + "attributes": basetypes.ListType{ + ElemType: ClusterAttributes{}.Type(ctx), + }, + "cause": types.StringType, + "cluster_size": basetypes.ListType{ + ElemType: ClusterSize{}.Type(ctx), + }, + "current_num_vcpus": types.Int64Type, + "current_num_workers": types.Int64Type, + "did_not_expand_reason": types.StringType, + "disk_size": types.Int64Type, + "driver_state_message": types.StringType, "enable_termination_for_node_blocklisted": types.BoolType, - "free_space": types.Int64Type, - "init_scripts": basetypes.ListType{ElemType: InitScriptEventDetails{}.Type(ctx)}, - "instance_id": types.StringType, - "job_run_name": types.StringType, - "previous_attributes": basetypes.ListType{ElemType: ClusterAttributes{}.Type(ctx)}, - "previous_cluster_size": basetypes.ListType{ElemType: ClusterSize{}.Type(ctx)}, - "previous_disk_size": types.Int64Type, - "reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, - "target_num_vcpus": types.Int64Type, - "target_num_workers": types.Int64Type, - "user": types.StringType, + "free_space": types.Int64Type, + "init_scripts": basetypes.ListType{ + ElemType: InitScriptEventDetails{}.Type(ctx), + }, + "instance_id": types.StringType, + "job_run_name": types.StringType, + "previous_attributes": basetypes.ListType{ + ElemType: ClusterAttributes{}.Type(ctx), + }, + "previous_cluster_size": basetypes.ListType{ + ElemType: ClusterSize{}.Type(ctx), + }, + "previous_disk_size": types.Int64Type, + "reason": basetypes.ListType{ + ElemType: TerminationReason{}.Type(ctx), + }, + "target_num_vcpus": types.Int64Type, + "target_num_workers": types.Int64Type, + "user": types.StringType, }, } } @@ -8719,7 +8835,9 @@ func (o GetEventsResponse) Type(ctx context.Context) attr.Type { "events": basetypes.ListType{ ElemType: ClusterEvent{}.Type(ctx), }, - "next_page": basetypes.ListType{ElemType: GetEvents{}.Type(ctx)}, + "next_page": basetypes.ListType{ + ElemType: GetEvents{}.Type(ctx), + }, "total_count": types.Int64Type, }, } @@ -8956,17 +9074,25 @@ func (o GetInstancePool) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetInstancePool) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "aws_attributes": basetypes.ListType{ + ElemType: InstancePoolAwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: InstancePoolAzureAttributes{}.Type(ctx), + }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, "default_tags": basetypes.MapType{ ElemType: types.StringType, }, - "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, - "enable_elastic_disk": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, + "disk_spec": basetypes.ListType{ + ElemType: DiskSpec{}.Type(ctx), + }, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: InstancePoolGcpAttributes{}.Type(ctx), + }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, "instance_pool_name": types.StringType, @@ -8979,9 +9105,13 @@ func (o GetInstancePool) Type(ctx context.Context) attr.Type { "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, - "state": types.StringType, - "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, + "state": types.StringType, + "stats": basetypes.ListType{ + ElemType: InstancePoolStats{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: InstancePoolStatus{}.Type(ctx), + }, }, } } @@ -10083,13 +10213,27 @@ func (o InitScriptInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o InitScriptInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "abfss": basetypes.ListType{ElemType: Adlsgen2Info{}.Type(ctx)}, - "dbfs": basetypes.ListType{ElemType: DbfsStorageInfo{}.Type(ctx)}, - "file": basetypes.ListType{ElemType: LocalFileInfo{}.Type(ctx)}, - "gcs": basetypes.ListType{ElemType: GcsStorageInfo{}.Type(ctx)}, - "s3": basetypes.ListType{ElemType: S3StorageInfo{}.Type(ctx)}, - "volumes": basetypes.ListType{ElemType: VolumesStorageInfo{}.Type(ctx)}, - "workspace": basetypes.ListType{ElemType: WorkspaceStorageInfo{}.Type(ctx)}, + "abfss": basetypes.ListType{ + ElemType: Adlsgen2Info{}.Type(ctx), + }, + "dbfs": basetypes.ListType{ + ElemType: DbfsStorageInfo{}.Type(ctx), + }, + "file": basetypes.ListType{ + ElemType: LocalFileInfo{}.Type(ctx), + }, + "gcs": basetypes.ListType{ + ElemType: GcsStorageInfo{}.Type(ctx), + }, + "s3": basetypes.ListType{ + ElemType: S3StorageInfo{}.Type(ctx), + }, + "volumes": basetypes.ListType{ + ElemType: VolumesStorageInfo{}.Type(ctx), + }, + "workspace": basetypes.ListType{ + ElemType: WorkspaceStorageInfo{}.Type(ctx), + }, }, } } @@ -10319,8 +10463,12 @@ func (o InitScriptInfoAndExecutionDetails) ToObjectValue(ctx context.Context) ba func (o InitScriptInfoAndExecutionDetails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "execution_details": basetypes.ListType{ElemType: InitScriptExecutionDetails{}.Type(ctx)}, - "script": basetypes.ListType{ElemType: InitScriptInfo{}.Type(ctx)}, + "execution_details": basetypes.ListType{ + ElemType: InitScriptExecutionDetails{}.Type(ctx), + }, + "script": basetypes.ListType{ + ElemType: InitScriptInfo{}.Type(ctx), + }, }, } } @@ -10767,17 +10915,25 @@ func (o InstancePoolAndStats) ToObjectValue(ctx context.Context) basetypes.Objec func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_attributes": basetypes.ListType{ElemType: InstancePoolAwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: InstancePoolAzureAttributes{}.Type(ctx)}, + "aws_attributes": basetypes.ListType{ + ElemType: InstancePoolAwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: InstancePoolAzureAttributes{}.Type(ctx), + }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, "default_tags": basetypes.MapType{ ElemType: types.StringType, }, - "disk_spec": basetypes.ListType{ElemType: DiskSpec{}.Type(ctx)}, - "enable_elastic_disk": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: InstancePoolGcpAttributes{}.Type(ctx)}, + "disk_spec": basetypes.ListType{ + ElemType: DiskSpec{}.Type(ctx), + }, + "enable_elastic_disk": types.BoolType, + "gcp_attributes": basetypes.ListType{ + ElemType: InstancePoolGcpAttributes{}.Type(ctx), + }, "idle_instance_autotermination_minutes": types.Int64Type, "instance_pool_id": types.StringType, "instance_pool_name": types.StringType, @@ -10790,9 +10946,13 @@ func (o InstancePoolAndStats) Type(ctx context.Context) attr.Type { "preloaded_spark_versions": basetypes.ListType{ ElemType: types.StringType, }, - "state": types.StringType, - "stats": basetypes.ListType{ElemType: InstancePoolStats{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: InstancePoolStatus{}.Type(ctx)}, + "state": types.StringType, + "stats": basetypes.ListType{ + ElemType: InstancePoolStats{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: InstancePoolStatus{}.Type(ctx), + }, }, } } @@ -11799,11 +11959,17 @@ func (o Library) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Library) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cran": basetypes.ListType{ElemType: RCranLibrary{}.Type(ctx)}, - "egg": types.StringType, - "jar": types.StringType, - "maven": basetypes.ListType{ElemType: MavenLibrary{}.Type(ctx)}, - "pypi": basetypes.ListType{ElemType: PythonPyPiLibrary{}.Type(ctx)}, + "cran": basetypes.ListType{ + ElemType: RCranLibrary{}.Type(ctx), + }, + "egg": types.StringType, + "jar": types.StringType, + "maven": basetypes.ListType{ + ElemType: MavenLibrary{}.Type(ctx), + }, + "pypi": basetypes.ListType{ + ElemType: PythonPyPiLibrary{}.Type(ctx), + }, "requirements": types.StringType, "whl": types.StringType, }, @@ -11941,7 +12107,9 @@ func (o LibraryFullStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "is_library_for_all_clusters": types.BoolType, - "library": basetypes.ListType{ElemType: Library{}.Type(ctx)}, + "library": basetypes.ListType{ + ElemType: Library{}.Type(ctx), + }, "messages": basetypes.ListType{ ElemType: types.StringType, }, @@ -12504,10 +12672,14 @@ func (o ListClustersRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o ListClustersRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter_by": basetypes.ListType{ElemType: ListClustersFilterBy{}.Type(ctx)}, + "filter_by": basetypes.ListType{ + ElemType: ListClustersFilterBy{}.Type(ctx), + }, "page_size": types.Int64Type, "page_token": types.StringType, - "sort_by": basetypes.ListType{ElemType: ListClustersSortBy{}.Type(ctx)}, + "sort_by": basetypes.ListType{ + ElemType: ListClustersSortBy{}.Type(ctx), + }, }, } } @@ -13570,8 +13742,12 @@ func (o NodeType) Type(ctx context.Context) attr.Type { "is_hidden": types.BoolType, "is_io_cache_enabled": types.BoolType, "memory_mb": types.Int64Type, - "node_info": basetypes.ListType{ElemType: CloudProviderNodeInfo{}.Type(ctx)}, - "node_instance_type": basetypes.ListType{ElemType: NodeInstanceType{}.Type(ctx)}, + "node_info": basetypes.ListType{ + ElemType: CloudProviderNodeInfo{}.Type(ctx), + }, + "node_instance_type": basetypes.ListType{ + ElemType: NodeInstanceType{}.Type(ctx), + }, "node_type_id": types.StringType, "num_cores": types.Float64Type, "num_gpus": types.Int64Type, @@ -14261,7 +14437,9 @@ func (o ResizeCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResizeCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, "cluster_id": types.StringType, "num_workers": types.Int64Type, }, @@ -14702,13 +14880,15 @@ func (o SparkNode) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SparkNode) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "host_private_ip": types.StringType, - "instance_id": types.StringType, - "node_aws_attributes": basetypes.ListType{ElemType: SparkNodeAwsAttributes{}.Type(ctx)}, - "node_id": types.StringType, - "private_ip": types.StringType, - "public_dns": types.StringType, - "start_timestamp": types.Int64Type, + "host_private_ip": types.StringType, + "instance_id": types.StringType, + "node_aws_attributes": basetypes.ListType{ + ElemType: SparkNodeAwsAttributes{}.Type(ctx), + }, + "node_id": types.StringType, + "private_ip": types.StringType, + "public_dns": types.StringType, + "start_timestamp": types.Int64Type, }, } } @@ -15229,7 +15409,9 @@ func (o UpdateCluster) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o UpdateCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cluster": basetypes.ListType{ElemType: UpdateClusterResource{}.Type(ctx)}, + "cluster": basetypes.ListType{ + ElemType: UpdateClusterResource{}.Type(ctx), + }, "cluster_id": types.StringType, "update_mask": types.StringType, }, @@ -15480,22 +15662,34 @@ func (o UpdateClusterResource) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "autoscale": basetypes.ListType{ElemType: AutoScale{}.Type(ctx)}, + "autoscale": basetypes.ListType{ + ElemType: AutoScale{}.Type(ctx), + }, "autotermination_minutes": types.Int64Type, - "aws_attributes": basetypes.ListType{ElemType: AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: ClusterLogConf{}.Type(ctx)}, - "cluster_name": types.StringType, + "aws_attributes": basetypes.ListType{ + ElemType: AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: AzureAttributes{}.Type(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: ClusterLogConf{}.Type(ctx), + }, + "cluster_name": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "data_security_mode": types.StringType, - "docker_image": basetypes.ListType{ElemType: DockerImage{}.Type(ctx)}, + "data_security_mode": types.StringType, + "docker_image": basetypes.ListType{ + ElemType: DockerImage{}.Type(ctx), + }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_elastic_disk": types.BoolType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: InitScriptInfo{}.Type(ctx), }, @@ -15515,7 +15709,9 @@ func (o UpdateClusterResource) Type(ctx context.Context) attr.Type { "ssh_public_keys": basetypes.ListType{ ElemType: types.StringType, }, - "workload_type": basetypes.ListType{ElemType: WorkloadType{}.Type(ctx)}, + "workload_type": basetypes.ListType{ + ElemType: WorkloadType{}.Type(ctx), + }, }, } } @@ -15985,7 +16181,9 @@ func (o WorkloadType) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o WorkloadType) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "clients": basetypes.ListType{ElemType: ClientsTypes{}.Type(ctx)}, + "clients": basetypes.ListType{ + ElemType: ClientsTypes{}.Type(ctx), + }, }, } } diff --git a/internal/service/dashboards_tf/model.go b/internal/service/dashboards_tf/model.go index 56a1eb2719..c77ba8ef1f 100755 --- a/internal/service/dashboards_tf/model.go +++ b/internal/service/dashboards_tf/model.go @@ -61,7 +61,9 @@ func (o CreateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboard": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, + "dashboard": basetypes.ListType{ + ElemType: Dashboard{}.Type(ctx), + }, }, } } @@ -136,7 +138,9 @@ func (o CreateScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, - "schedule": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, + "schedule": basetypes.ListType{ + ElemType: Schedule{}.Type(ctx), + }, }, } } @@ -215,7 +219,9 @@ func (o CreateSubscriptionRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, "schedule_id": types.StringType, - "subscription": basetypes.ListType{ElemType: Subscription{}.Type(ctx)}, + "subscription": basetypes.ListType{ + ElemType: Subscription{}.Type(ctx), + }, }, } } @@ -612,8 +618,12 @@ func (o GenieAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GenieAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query": basetypes.ListType{ElemType: QueryAttachment{}.Type(ctx)}, - "text": basetypes.ListType{ElemType: TextAttachment{}.Type(ctx)}, + "query": basetypes.ListType{ + ElemType: QueryAttachment{}.Type(ctx), + }, + "text": basetypes.ListType{ + ElemType: TextAttachment{}.Type(ctx), + }, }, } } @@ -977,7 +987,9 @@ func (o GenieGetMessageQueryResultResponse) ToObjectValue(ctx context.Context) b func (o GenieGetMessageQueryResultResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "statement_response": basetypes.ListType{ElemType: sql_tf.StatementResponse{}.Type(ctx)}, + "statement_response": basetypes.ListType{ + ElemType: sql_tf.StatementResponse{}.Type(ctx), + }, }, } } @@ -1097,16 +1109,20 @@ func (o GenieMessage) Type(ctx context.Context) attr.Type { "attachments": basetypes.ListType{ ElemType: GenieAttachment{}.Type(ctx), }, - "content": types.StringType, - "conversation_id": types.StringType, - "created_timestamp": types.Int64Type, - "error": basetypes.ListType{ElemType: MessageError{}.Type(ctx)}, + "content": types.StringType, + "conversation_id": types.StringType, + "created_timestamp": types.Int64Type, + "error": basetypes.ListType{ + ElemType: MessageError{}.Type(ctx), + }, "id": types.StringType, "last_updated_timestamp": types.Int64Type, - "query_result": basetypes.ListType{ElemType: Result{}.Type(ctx)}, - "space_id": types.StringType, - "status": types.StringType, - "user_id": types.Int64Type, + "query_result": basetypes.ListType{ + ElemType: Result{}.Type(ctx), + }, + "space_id": types.StringType, + "status": types.StringType, + "user_id": types.Int64Type, }, } } @@ -1284,10 +1300,14 @@ func (o GenieStartConversationResponse) ToObjectValue(ctx context.Context) baset func (o GenieStartConversationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "conversation": basetypes.ListType{ElemType: GenieConversation{}.Type(ctx)}, + "conversation": basetypes.ListType{ + ElemType: GenieConversation{}.Type(ctx), + }, "conversation_id": types.StringType, - "message": basetypes.ListType{ElemType: GenieMessage{}.Type(ctx)}, - "message_id": types.StringType, + "message": basetypes.ListType{ + ElemType: GenieMessage{}.Type(ctx), + }, + "message_id": types.StringType, }, } } @@ -2189,7 +2209,9 @@ func (o QueryAttachment) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o QueryAttachment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cached_query_schema": basetypes.ListType{ElemType: QuerySchema{}.Type(ctx)}, + "cached_query_schema": basetypes.ListType{ + ElemType: QuerySchema{}.Type(ctx), + }, "description": types.StringType, "id": types.StringType, "instruction_id": types.StringType, @@ -2473,15 +2495,17 @@ func (o Schedule) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Schedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "create_time": types.StringType, - "cron_schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, - "dashboard_id": types.StringType, - "display_name": types.StringType, - "etag": types.StringType, - "pause_status": types.StringType, - "schedule_id": types.StringType, - "update_time": types.StringType, - "warehouse_id": types.StringType, + "create_time": types.StringType, + "cron_schedule": basetypes.ListType{ + ElemType: CronSchedule{}.Type(ctx), + }, + "dashboard_id": types.StringType, + "display_name": types.StringType, + "etag": types.StringType, + "pause_status": types.StringType, + "schedule_id": types.StringType, + "update_time": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -2557,8 +2581,12 @@ func (o Subscriber) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Subscriber) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "destination_subscriber": basetypes.ListType{ElemType: SubscriptionSubscriberDestination{}.Type(ctx)}, - "user_subscriber": basetypes.ListType{ElemType: SubscriptionSubscriberUser{}.Type(ctx)}, + "destination_subscriber": basetypes.ListType{ + ElemType: SubscriptionSubscriberDestination{}.Type(ctx), + }, + "user_subscriber": basetypes.ListType{ + ElemType: SubscriptionSubscriberUser{}.Type(ctx), + }, }, } } @@ -2684,9 +2712,11 @@ func (o Subscription) Type(ctx context.Context) attr.Type { "dashboard_id": types.StringType, "etag": types.StringType, "schedule_id": types.StringType, - "subscriber": basetypes.ListType{ElemType: Subscriber{}.Type(ctx)}, - "subscription_id": types.StringType, - "update_time": types.StringType, + "subscriber": basetypes.ListType{ + ElemType: Subscriber{}.Type(ctx), + }, + "subscription_id": types.StringType, + "update_time": types.StringType, }, } } @@ -3048,7 +3078,9 @@ func (o UpdateDashboardRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateDashboardRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboard": basetypes.ListType{ElemType: Dashboard{}.Type(ctx)}, + "dashboard": basetypes.ListType{ + ElemType: Dashboard{}.Type(ctx), + }, "dashboard_id": types.StringType, }, } @@ -3127,8 +3159,10 @@ func (o UpdateScheduleRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "dashboard_id": types.StringType, - "schedule": basetypes.ListType{ElemType: Schedule{}.Type(ctx)}, - "schedule_id": types.StringType, + "schedule": basetypes.ListType{ + ElemType: Schedule{}.Type(ctx), + }, + "schedule_id": types.StringType, }, } } diff --git a/internal/service/iam_tf/model.go b/internal/service/iam_tf/model.go index 03825478b5..04df338c05 100755 --- a/internal/service/iam_tf/model.go +++ b/internal/service/iam_tf/model.go @@ -1537,7 +1537,9 @@ func (o Group) Type(ctx context.Context) attr.Type { "members": basetypes.ListType{ ElemType: ComplexValue{}.Type(ctx), }, - "meta": basetypes.ListType{ElemType: ResourceMeta{}.Type(ctx)}, + "meta": basetypes.ListType{ + ElemType: ResourceMeta{}.Type(ctx), + }, "roles": basetypes.ListType{ ElemType: ComplexValue{}.Type(ctx), }, @@ -3506,7 +3508,9 @@ func (o PermissionAssignment) Type(ctx context.Context) attr.Type { "permissions": basetypes.ListType{ ElemType: types.StringType, }, - "principal": basetypes.ListType{ElemType: PrincipalOutput{}.Type(ctx)}, + "principal": basetypes.ListType{ + ElemType: PrincipalOutput{}.Type(ctx), + }, }, } } @@ -4388,8 +4392,10 @@ func (o UpdateRuleSetRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o UpdateRuleSetRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "rule_set": basetypes.ListType{ElemType: RuleSetUpdateRequest{}.Type(ctx)}, + "name": types.StringType, + "rule_set": basetypes.ListType{ + ElemType: RuleSetUpdateRequest{}.Type(ctx), + }, }, } } @@ -4600,8 +4606,10 @@ func (o User) Type(ctx context.Context) attr.Type { "groups": basetypes.ListType{ ElemType: ComplexValue{}.Type(ctx), }, - "id": types.StringType, - "name": basetypes.ListType{ElemType: Name{}.Type(ctx)}, + "id": types.StringType, + "name": basetypes.ListType{ + ElemType: Name{}.Type(ctx), + }, "roles": basetypes.ListType{ ElemType: ComplexValue{}.Type(ctx), }, diff --git a/internal/service/jobs_tf/model.go b/internal/service/jobs_tf/model.go index 8ea8bc5fd9..c1c45c8606 100755 --- a/internal/service/jobs_tf/model.go +++ b/internal/service/jobs_tf/model.go @@ -85,7 +85,9 @@ func (o BaseJob) Type(ctx context.Context) attr.Type { "creator_user_name": types.StringType, "effective_budget_policy_id": types.StringType, "job_id": types.Int64Type, - "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "settings": basetypes.ListType{ + ElemType: JobSettings{}.Type(ctx), + }, }, } } @@ -321,15 +323,21 @@ func (o BaseRun) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o BaseRun) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, - "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ + ElemType: ClusterInstance{}.Type(ctx), + }, + "cluster_spec": basetypes.ListType{ + ElemType: ClusterSpec{}.Type(ctx), + }, "creator_user_name": types.StringType, "description": types.StringType, "end_time": types.Int64Type, "execution_duration": types.Int64Type, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.Type(ctx), + }, "job_clusters": basetypes.ListType{ ElemType: JobCluster{}.Type(ctx), }, @@ -340,26 +348,36 @@ func (o BaseRun) Type(ctx context.Context) attr.Type { "job_run_id": types.Int64Type, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, - "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, - "queue_duration": types.Int64Type, + "overriding_parameters": basetypes.ListType{ + ElemType: RunParameters{}.Type(ctx), + }, + "queue_duration": types.Int64Type, "repair_history": basetypes.ListType{ ElemType: RepairHistoryItem{}.Type(ctx), }, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_name": types.StringType, - "run_page_url": types.StringType, - "run_type": types.StringType, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.Type(ctx), + }, "setup_duration": types.Int64Type, "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "state": basetypes.ListType{ + ElemType: RunState{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.Type(ctx), + }, "tasks": basetypes.ListType{ ElemType: RunTask{}.Type(ctx), }, - "trigger": types.StringType, - "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ + ElemType: TriggerInfo{}.Type(ctx), + }, }, } } @@ -1006,7 +1024,9 @@ func (o ClusterSpec) Type(ctx context.Context) attr.Type { "library": basetypes.ListType{ ElemType: compute_tf.Library{}.Type(ctx), }, - "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.Type(ctx), + }, }, } } @@ -1348,39 +1368,61 @@ func (o CreateJob) Type(ctx context.Context) attr.Type { "access_control_list": basetypes.ListType{ ElemType: JobAccessControlRequest{}.Type(ctx), }, - "budget_policy_id": types.StringType, - "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, - "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, - "description": types.StringType, - "edit_mode": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ + ElemType: Continuous{}.Type(ctx), + }, + "deployment": basetypes.ListType{ + ElemType: JobDeployment{}.Type(ctx), + }, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.Type(ctx), + }, "environment": basetypes.ListType{ ElemType: JobEnvironment{}.Type(ctx), }, - "format": types.StringType, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "format": types.StringType, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.Type(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.Type(ctx), + }, "job_cluster": basetypes.ListType{ ElemType: JobCluster{}.Type(ctx), }, - "max_concurrent_runs": types.Int64Type, - "name": types.StringType, - "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, + "max_concurrent_runs": types.Int64Type, + "name": types.StringType, + "notification_settings": basetypes.ListType{ + ElemType: JobNotificationSettings{}.Type(ctx), + }, "parameter": basetypes.ListType{ ElemType: JobParameterDefinition{}.Type(ctx), }, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, - "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.Type(ctx), + }, + "run_as": basetypes.ListType{ + ElemType: JobRunAs{}.Type(ctx), + }, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.Type(ctx), + }, "tags": basetypes.MapType{ ElemType: types.StringType, }, "task": basetypes.ListType{ ElemType: Task{}.Type(ctx), }, - "timeout_seconds": types.Int64Type, - "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, - "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, + "timeout_seconds": types.Int64Type, + "trigger": basetypes.ListType{ + ElemType: TriggerSettings{}.Type(ctx), + }, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.Type(ctx), + }, }, } } @@ -2441,7 +2483,9 @@ func (o EnforcePolicyComplianceResponse) Type(ctx context.Context) attr.Type { "job_cluster_changes": basetypes.ListType{ ElemType: EnforcePolicyComplianceForJobResponseJobClusterSettingsChange{}.Type(ctx), }, - "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "settings": basetypes.ListType{ + ElemType: JobSettings{}.Type(ctx), + }, }, } } @@ -2724,7 +2768,9 @@ func (o ForEachStats) Type(ctx context.Context) attr.Type { "error_message_stats": basetypes.ListType{ ElemType: ForEachTaskErrorMessageStats{}.Type(ctx), }, - "task_run_stats": basetypes.ListType{ElemType: ForEachTaskTaskRunStats{}.Type(ctx)}, + "task_run_stats": basetypes.ListType{ + ElemType: ForEachTaskTaskRunStats{}.Type(ctx), + }, }, } } @@ -2831,7 +2877,9 @@ func (o ForEachTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, - "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "task": basetypes.ListType{ + ElemType: Task{}.Type(ctx), + }, }, } } @@ -3527,10 +3575,14 @@ func (o GitSource) Type(ctx context.Context) attr.Type { "branch": types.StringType, "commit": types.StringType, "git_provider": types.StringType, - "git_snapshot": basetypes.ListType{ElemType: GitSnapshot{}.Type(ctx)}, - "tag": types.StringType, - "url": types.StringType, - "job_source": basetypes.ListType{ElemType: JobSource{}.Type(ctx)}, + "git_snapshot": basetypes.ListType{ + ElemType: GitSnapshot{}.Type(ctx), + }, + "tag": types.StringType, + "url": types.StringType, + "job_source": basetypes.ListType{ + ElemType: JobSource{}.Type(ctx), + }, }, } } @@ -3661,7 +3713,9 @@ func (o Job) Type(ctx context.Context) attr.Type { "effective_budget_policy_id": types.StringType, "job_id": types.Int64Type, "run_as_user_name": types.StringType, - "settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "settings": basetypes.ListType{ + ElemType: JobSettings{}.Type(ctx), + }, }, } } @@ -3879,7 +3933,9 @@ func (o JobCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "job_cluster_key": types.StringType, - "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.Type(ctx), + }, }, } } @@ -4316,7 +4372,9 @@ func (o JobEnvironment) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "environment_key": types.StringType, - "spec": basetypes.ListType{ElemType: compute_tf.Environment{}.Type(ctx)}, + "spec": basetypes.ListType{ + ElemType: compute_tf.Environment{}.Type(ctx), + }, }, } } @@ -4997,39 +5055,61 @@ func (o JobSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o JobSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "budget_policy_id": types.StringType, - "continuous": basetypes.ListType{ElemType: Continuous{}.Type(ctx)}, - "deployment": basetypes.ListType{ElemType: JobDeployment{}.Type(ctx)}, - "description": types.StringType, - "edit_mode": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "budget_policy_id": types.StringType, + "continuous": basetypes.ListType{ + ElemType: Continuous{}.Type(ctx), + }, + "deployment": basetypes.ListType{ + ElemType: JobDeployment{}.Type(ctx), + }, + "description": types.StringType, + "edit_mode": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.Type(ctx), + }, "environment": basetypes.ListType{ ElemType: JobEnvironment{}.Type(ctx), }, - "format": types.StringType, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "format": types.StringType, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.Type(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.Type(ctx), + }, "job_cluster": basetypes.ListType{ ElemType: JobCluster{}.Type(ctx), }, - "max_concurrent_runs": types.Int64Type, - "name": types.StringType, - "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, + "max_concurrent_runs": types.Int64Type, + "name": types.StringType, + "notification_settings": basetypes.ListType{ + ElemType: JobNotificationSettings{}.Type(ctx), + }, "parameter": basetypes.ListType{ ElemType: JobParameterDefinition{}.Type(ctx), }, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, - "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.Type(ctx), + }, + "run_as": basetypes.ListType{ + ElemType: JobRunAs{}.Type(ctx), + }, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.Type(ctx), + }, "tags": basetypes.MapType{ ElemType: types.StringType, }, "task": basetypes.ListType{ ElemType: Task{}.Type(ctx), }, - "timeout_seconds": types.Int64Type, - "trigger": basetypes.ListType{ElemType: TriggerSettings{}.Type(ctx)}, - "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, + "timeout_seconds": types.Int64Type, + "trigger": basetypes.ListType{ + ElemType: TriggerSettings{}.Type(ctx), + }, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.Type(ctx), + }, }, } } @@ -6693,8 +6773,12 @@ func (o RepairHistoryItem) Type(ctx context.Context) attr.Type { "end_time": types.Int64Type, "id": types.Int64Type, "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "state": basetypes.ListType{ + ElemType: RunState{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.Type(ctx), + }, "task_run_ids": basetypes.ListType{ ElemType: types.Int64Type, }, @@ -6953,7 +7037,9 @@ func (o RepairRun) Type(ctx context.Context) attr.Type { "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.Type(ctx), + }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, @@ -7326,8 +7412,10 @@ func (o ResetJob) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o ResetJob) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "job_id": types.Int64Type, - "new_settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ + ElemType: JobSettings{}.Type(ctx), + }, }, } } @@ -8005,16 +8093,36 @@ func (o ResolvedValues) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ResolvedValues) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ElemType: ResolvedConditionTaskValues{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: ResolvedDbtTaskValues{}.Type(ctx)}, - "notebook_task": basetypes.ListType{ElemType: ResolvedNotebookTaskValues{}.Type(ctx)}, - "python_wheel_task": basetypes.ListType{ElemType: ResolvedPythonWheelTaskValues{}.Type(ctx)}, - "run_job_task": basetypes.ListType{ElemType: ResolvedRunJobTaskValues{}.Type(ctx)}, - "simulation_task": basetypes.ListType{ElemType: ResolvedParamPairValues{}.Type(ctx)}, - "spark_jar_task": basetypes.ListType{ElemType: ResolvedStringParamsValues{}.Type(ctx)}, - "spark_python_task": basetypes.ListType{ElemType: ResolvedStringParamsValues{}.Type(ctx)}, - "spark_submit_task": basetypes.ListType{ElemType: ResolvedStringParamsValues{}.Type(ctx)}, - "sql_task": basetypes.ListType{ElemType: ResolvedParamPairValues{}.Type(ctx)}, + "condition_task": basetypes.ListType{ + ElemType: ResolvedConditionTaskValues{}.Type(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: ResolvedDbtTaskValues{}.Type(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: ResolvedNotebookTaskValues{}.Type(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: ResolvedPythonWheelTaskValues{}.Type(ctx), + }, + "run_job_task": basetypes.ListType{ + ElemType: ResolvedRunJobTaskValues{}.Type(ctx), + }, + "simulation_task": basetypes.ListType{ + ElemType: ResolvedParamPairValues{}.Type(ctx), + }, + "spark_jar_task": basetypes.ListType{ + ElemType: ResolvedStringParamsValues{}.Type(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: ResolvedStringParamsValues{}.Type(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: ResolvedStringParamsValues{}.Type(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: ResolvedParamPairValues{}.Type(ctx), + }, }, } } @@ -8493,15 +8601,21 @@ func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "attempt_number": types.Int64Type, - "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, - "cluster_spec": basetypes.ListType{ElemType: ClusterSpec{}.Type(ctx)}, + "attempt_number": types.Int64Type, + "cleanup_duration": types.Int64Type, + "cluster_instance": basetypes.ListType{ + ElemType: ClusterInstance{}.Type(ctx), + }, + "cluster_spec": basetypes.ListType{ + ElemType: ClusterSpec{}.Type(ctx), + }, "creator_user_name": types.StringType, "description": types.StringType, "end_time": types.Int64Type, "execution_duration": types.Int64Type, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.Type(ctx), + }, "iterations": basetypes.ListType{ ElemType: RunTask{}.Type(ctx), }, @@ -8516,26 +8630,36 @@ func (o Run) Type(ctx context.Context) attr.Type { "next_page_token": types.StringType, "number_in_job": types.Int64Type, "original_attempt_run_id": types.Int64Type, - "overriding_parameters": basetypes.ListType{ElemType: RunParameters{}.Type(ctx)}, - "queue_duration": types.Int64Type, + "overriding_parameters": basetypes.ListType{ + ElemType: RunParameters{}.Type(ctx), + }, + "queue_duration": types.Int64Type, "repair_history": basetypes.ListType{ ElemType: RepairHistoryItem{}.Type(ctx), }, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_name": types.StringType, - "run_page_url": types.StringType, - "run_type": types.StringType, - "schedule": basetypes.ListType{ElemType: CronSchedule{}.Type(ctx)}, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_name": types.StringType, + "run_page_url": types.StringType, + "run_type": types.StringType, + "schedule": basetypes.ListType{ + ElemType: CronSchedule{}.Type(ctx), + }, "setup_duration": types.Int64Type, "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, + "state": basetypes.ListType{ + ElemType: RunState{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.Type(ctx), + }, "tasks": basetypes.ListType{ ElemType: RunTask{}.Type(ctx), }, - "trigger": types.StringType, - "trigger_info": basetypes.ListType{ElemType: TriggerInfo{}.Type(ctx)}, + "trigger": types.StringType, + "trigger_info": basetypes.ListType{ + ElemType: TriggerInfo{}.Type(ctx), + }, }, } } @@ -8999,8 +9123,12 @@ func (o RunForEachTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "concurrency": types.Int64Type, "inputs": types.StringType, - "stats": basetypes.ListType{ElemType: ForEachStats{}.Type(ctx)}, - "task": basetypes.ListType{ElemType: Task{}.Type(ctx)}, + "stats": basetypes.ListType{ + ElemType: ForEachStats{}.Type(ctx), + }, + "task": basetypes.ListType{ + ElemType: Task{}.Type(ctx), + }, }, } } @@ -9252,7 +9380,9 @@ func (o RunJobTask) Type(ctx context.Context) attr.Type { "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.Type(ctx), + }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, @@ -9686,14 +9816,18 @@ func (o RunNow) Type(ctx context.Context) attr.Type { "only": basetypes.ListType{ ElemType: types.StringType, }, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.Type(ctx), + }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, "python_params": basetypes.ListType{ ElemType: types.StringType, }, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.Type(ctx), + }, "spark_submit_params": basetypes.ListType{ ElemType: types.StringType, }, @@ -10125,16 +10259,26 @@ func (o RunOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dbt_output": basetypes.ListType{ElemType: DbtOutput{}.Type(ctx)}, - "error": types.StringType, - "error_trace": types.StringType, - "info": types.StringType, - "logs": types.StringType, - "logs_truncated": types.BoolType, - "metadata": basetypes.ListType{ElemType: Run{}.Type(ctx)}, - "notebook_output": basetypes.ListType{ElemType: NotebookOutput{}.Type(ctx)}, - "run_job_output": basetypes.ListType{ElemType: RunJobOutput{}.Type(ctx)}, - "sql_output": basetypes.ListType{ElemType: SqlOutput{}.Type(ctx)}, + "dbt_output": basetypes.ListType{ + ElemType: DbtOutput{}.Type(ctx), + }, + "error": types.StringType, + "error_trace": types.StringType, + "info": types.StringType, + "logs": types.StringType, + "logs_truncated": types.BoolType, + "metadata": basetypes.ListType{ + ElemType: Run{}.Type(ctx), + }, + "notebook_output": basetypes.ListType{ + ElemType: NotebookOutput{}.Type(ctx), + }, + "run_job_output": basetypes.ListType{ + ElemType: RunJobOutput{}.Type(ctx), + }, + "sql_output": basetypes.ListType{ + ElemType: SqlOutput{}.Type(ctx), + }, }, } } @@ -10411,7 +10555,9 @@ func (o RunParameters) Type(ctx context.Context) attr.Type { "notebook_params": basetypes.MapType{ ElemType: types.StringType, }, - "pipeline_params": basetypes.ListType{ElemType: PipelineParams{}.Type(ctx)}, + "pipeline_params": basetypes.ListType{ + ElemType: PipelineParams{}.Type(ctx), + }, "python_named_params": basetypes.MapType{ ElemType: types.StringType, }, @@ -10747,9 +10893,13 @@ func (o RunStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RunStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "queue_details": basetypes.ListType{ElemType: QueueDetails{}.Type(ctx)}, - "state": types.StringType, - "termination_details": basetypes.ListType{ElemType: TerminationDetails{}.Type(ctx)}, + "queue_details": basetypes.ListType{ + ElemType: QueueDetails{}.Type(ctx), + }, + "state": types.StringType, + "termination_details": basetypes.ListType{ + ElemType: TerminationDetails{}.Type(ctx), + }, }, } } @@ -11069,47 +11219,87 @@ func (o RunTask) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "attempt_number": types.Int64Type, "cleanup_duration": types.Int64Type, - "cluster_instance": basetypes.ListType{ElemType: ClusterInstance{}.Type(ctx)}, - "condition_task": basetypes.ListType{ElemType: RunConditionTask{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "cluster_instance": basetypes.ListType{ + ElemType: ClusterInstance{}.Type(ctx), + }, + "condition_task": basetypes.ListType{ + ElemType: RunConditionTask{}.Type(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: DbtTask{}.Type(ctx), + }, "depends_on": basetypes.ListType{ ElemType: TaskDependency{}.Type(ctx), }, - "description": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "description": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.Type(ctx), + }, "end_time": types.Int64Type, "environment_key": types.StringType, "execution_duration": types.Int64Type, "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ElemType: RunForEachTask{}.Type(ctx)}, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "job_cluster_key": types.StringType, + "for_each_task": basetypes.ListType{ + ElemType: RunForEachTask{}.Type(ctx), + }, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.Type(ctx), + }, + "job_cluster_key": types.StringType, "library": basetypes.ListType{ ElemType: compute_tf.Library{}.Type(ctx), }, - "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, - "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, - "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, - "pipeline_task": basetypes.ListType{ElemType: PipelineTask{}.Type(ctx)}, - "python_wheel_task": basetypes.ListType{ElemType: PythonWheelTask{}.Type(ctx)}, - "queue_duration": types.Int64Type, - "resolved_values": basetypes.ListType{ElemType: ResolvedValues{}.Type(ctx)}, - "run_duration": types.Int64Type, - "run_id": types.Int64Type, - "run_if": types.StringType, - "run_job_task": basetypes.ListType{ElemType: RunJobTask{}.Type(ctx)}, - "run_page_url": types.StringType, - "setup_duration": types.Int64Type, - "spark_jar_task": basetypes.ListType{ElemType: SparkJarTask{}.Type(ctx)}, - "spark_python_task": basetypes.ListType{ElemType: SparkPythonTask{}.Type(ctx)}, - "spark_submit_task": basetypes.ListType{ElemType: SparkSubmitTask{}.Type(ctx)}, - "sql_task": basetypes.ListType{ElemType: SqlTask{}.Type(ctx)}, - "start_time": types.Int64Type, - "state": basetypes.ListType{ElemType: RunState{}.Type(ctx)}, - "status": basetypes.ListType{ElemType: RunStatus{}.Type(ctx)}, - "task_key": types.StringType, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.Type(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: NotebookTask{}.Type(ctx), + }, + "notification_settings": basetypes.ListType{ + ElemType: TaskNotificationSettings{}.Type(ctx), + }, + "pipeline_task": basetypes.ListType{ + ElemType: PipelineTask{}.Type(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: PythonWheelTask{}.Type(ctx), + }, + "queue_duration": types.Int64Type, + "resolved_values": basetypes.ListType{ + ElemType: ResolvedValues{}.Type(ctx), + }, + "run_duration": types.Int64Type, + "run_id": types.Int64Type, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ + ElemType: RunJobTask{}.Type(ctx), + }, + "run_page_url": types.StringType, + "setup_duration": types.Int64Type, + "spark_jar_task": basetypes.ListType{ + ElemType: SparkJarTask{}.Type(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: SparkPythonTask{}.Type(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: SparkSubmitTask{}.Type(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: SqlTask{}.Type(ctx), + }, + "start_time": types.Int64Type, + "state": basetypes.ListType{ + ElemType: RunState{}.Type(ctx), + }, + "status": basetypes.ListType{ + ElemType: RunStatus{}.Type(ctx), + }, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.Type(ctx), + }, }, } } @@ -12176,8 +12366,10 @@ func (o SqlDashboardWidgetOutput) ToObjectValue(ctx context.Context) basetypes.O func (o SqlDashboardWidgetOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "end_time": types.Int64Type, - "error": basetypes.ListType{ElemType: SqlOutputError{}.Type(ctx)}, + "end_time": types.Int64Type, + "error": basetypes.ListType{ + ElemType: SqlOutputError{}.Type(ctx), + }, "output_link": types.StringType, "start_time": types.Int64Type, "status": types.StringType, @@ -12260,9 +12452,15 @@ func (o SqlOutput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SqlOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert_output": basetypes.ListType{ElemType: SqlAlertOutput{}.Type(ctx)}, - "dashboard_output": basetypes.ListType{ElemType: SqlDashboardOutput{}.Type(ctx)}, - "query_output": basetypes.ListType{ElemType: SqlQueryOutput{}.Type(ctx)}, + "alert_output": basetypes.ListType{ + ElemType: SqlAlertOutput{}.Type(ctx), + }, + "dashboard_output": basetypes.ListType{ + ElemType: SqlDashboardOutput{}.Type(ctx), + }, + "query_output": basetypes.ListType{ + ElemType: SqlQueryOutput{}.Type(ctx), + }, }, } } @@ -12580,13 +12778,21 @@ func (o SqlTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SqlTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ElemType: SqlTaskAlert{}.Type(ctx)}, - "dashboard": basetypes.ListType{ElemType: SqlTaskDashboard{}.Type(ctx)}, - "file": basetypes.ListType{ElemType: SqlTaskFile{}.Type(ctx)}, + "alert": basetypes.ListType{ + ElemType: SqlTaskAlert{}.Type(ctx), + }, + "dashboard": basetypes.ListType{ + ElemType: SqlTaskDashboard{}.Type(ctx), + }, + "file": basetypes.ListType{ + ElemType: SqlTaskFile{}.Type(ctx), + }, "parameters": basetypes.MapType{ ElemType: types.StringType, }, - "query": basetypes.ListType{ElemType: SqlTaskQuery{}.Type(ctx)}, + "query": basetypes.ListType{ + ElemType: SqlTaskQuery{}.Type(ctx), + }, "warehouse_id": types.StringType, }, } @@ -13155,23 +13361,37 @@ func (o SubmitRun) Type(ctx context.Context) attr.Type { "access_control_list": basetypes.ListType{ ElemType: JobAccessControlRequest{}.Type(ctx), }, - "budget_policy_id": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "budget_policy_id": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.Type(ctx), + }, "environments": basetypes.ListType{ ElemType: JobEnvironment{}.Type(ctx), }, - "git_source": basetypes.ListType{ElemType: GitSource{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "idempotency_token": types.StringType, - "notification_settings": basetypes.ListType{ElemType: JobNotificationSettings{}.Type(ctx)}, - "queue": basetypes.ListType{ElemType: QueueSettings{}.Type(ctx)}, - "run_as": basetypes.ListType{ElemType: JobRunAs{}.Type(ctx)}, - "run_name": types.StringType, + "git_source": basetypes.ListType{ + ElemType: GitSource{}.Type(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.Type(ctx), + }, + "idempotency_token": types.StringType, + "notification_settings": basetypes.ListType{ + ElemType: JobNotificationSettings{}.Type(ctx), + }, + "queue": basetypes.ListType{ + ElemType: QueueSettings{}.Type(ctx), + }, + "run_as": basetypes.ListType{ + ElemType: JobRunAs{}.Type(ctx), + }, + "run_name": types.StringType, "tasks": basetypes.ListType{ ElemType: SubmitTask{}.Type(ctx), }, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.Type(ctx), + }, }, } } @@ -13653,34 +13873,66 @@ func (o SubmitTask) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SubmitTask) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "condition_task": basetypes.ListType{ + ElemType: ConditionTask{}.Type(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: DbtTask{}.Type(ctx), + }, "depends_on": basetypes.ListType{ ElemType: TaskDependency{}.Type(ctx), }, - "description": types.StringType, - "email_notifications": basetypes.ListType{ElemType: JobEmailNotifications{}.Type(ctx)}, + "description": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: JobEmailNotifications{}.Type(ctx), + }, "environment_key": types.StringType, "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, + "for_each_task": basetypes.ListType{ + ElemType: ForEachTask{}.Type(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.Type(ctx), + }, "library": basetypes.ListType{ ElemType: compute_tf.Library{}.Type(ctx), }, - "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, - "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, - "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, - "pipeline_task": basetypes.ListType{ElemType: PipelineTask{}.Type(ctx)}, - "python_wheel_task": basetypes.ListType{ElemType: PythonWheelTask{}.Type(ctx)}, - "run_if": types.StringType, - "run_job_task": basetypes.ListType{ElemType: RunJobTask{}.Type(ctx)}, - "spark_jar_task": basetypes.ListType{ElemType: SparkJarTask{}.Type(ctx)}, - "spark_python_task": basetypes.ListType{ElemType: SparkPythonTask{}.Type(ctx)}, - "spark_submit_task": basetypes.ListType{ElemType: SparkSubmitTask{}.Type(ctx)}, - "sql_task": basetypes.ListType{ElemType: SqlTask{}.Type(ctx)}, - "task_key": types.StringType, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.Type(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: NotebookTask{}.Type(ctx), + }, + "notification_settings": basetypes.ListType{ + ElemType: TaskNotificationSettings{}.Type(ctx), + }, + "pipeline_task": basetypes.ListType{ + ElemType: PipelineTask{}.Type(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: PythonWheelTask{}.Type(ctx), + }, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ + ElemType: RunJobTask{}.Type(ctx), + }, + "spark_jar_task": basetypes.ListType{ + ElemType: SparkJarTask{}.Type(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: SparkPythonTask{}.Type(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: SparkSubmitTask{}.Type(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: SqlTask{}.Type(ctx), + }, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.Type(ctx), + }, }, } } @@ -14445,39 +14697,71 @@ func (o Task) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Task) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition_task": basetypes.ListType{ElemType: ConditionTask{}.Type(ctx)}, - "dbt_task": basetypes.ListType{ElemType: DbtTask{}.Type(ctx)}, + "condition_task": basetypes.ListType{ + ElemType: ConditionTask{}.Type(ctx), + }, + "dbt_task": basetypes.ListType{ + ElemType: DbtTask{}.Type(ctx), + }, "depends_on": basetypes.ListType{ ElemType: TaskDependency{}.Type(ctx), }, "description": types.StringType, "disable_auto_optimization": types.BoolType, - "email_notifications": basetypes.ListType{ElemType: TaskEmailNotifications{}.Type(ctx)}, - "environment_key": types.StringType, - "existing_cluster_id": types.StringType, - "for_each_task": basetypes.ListType{ElemType: ForEachTask{}.Type(ctx)}, - "health": basetypes.ListType{ElemType: JobsHealthRules{}.Type(ctx)}, - "job_cluster_key": types.StringType, + "email_notifications": basetypes.ListType{ + ElemType: TaskEmailNotifications{}.Type(ctx), + }, + "environment_key": types.StringType, + "existing_cluster_id": types.StringType, + "for_each_task": basetypes.ListType{ + ElemType: ForEachTask{}.Type(ctx), + }, + "health": basetypes.ListType{ + ElemType: JobsHealthRules{}.Type(ctx), + }, + "job_cluster_key": types.StringType, "library": basetypes.ListType{ ElemType: compute_tf.Library{}.Type(ctx), }, "max_retries": types.Int64Type, "min_retry_interval_millis": types.Int64Type, - "new_cluster": basetypes.ListType{ElemType: compute_tf.ClusterSpec{}.Type(ctx)}, - "notebook_task": basetypes.ListType{ElemType: NotebookTask{}.Type(ctx)}, - "notification_settings": basetypes.ListType{ElemType: TaskNotificationSettings{}.Type(ctx)}, - "pipeline_task": basetypes.ListType{ElemType: PipelineTask{}.Type(ctx)}, - "python_wheel_task": basetypes.ListType{ElemType: PythonWheelTask{}.Type(ctx)}, - "retry_on_timeout": types.BoolType, - "run_if": types.StringType, - "run_job_task": basetypes.ListType{ElemType: RunJobTask{}.Type(ctx)}, - "spark_jar_task": basetypes.ListType{ElemType: SparkJarTask{}.Type(ctx)}, - "spark_python_task": basetypes.ListType{ElemType: SparkPythonTask{}.Type(ctx)}, - "spark_submit_task": basetypes.ListType{ElemType: SparkSubmitTask{}.Type(ctx)}, - "sql_task": basetypes.ListType{ElemType: SqlTask{}.Type(ctx)}, - "task_key": types.StringType, - "timeout_seconds": types.Int64Type, - "webhook_notifications": basetypes.ListType{ElemType: WebhookNotifications{}.Type(ctx)}, + "new_cluster": basetypes.ListType{ + ElemType: compute_tf.ClusterSpec{}.Type(ctx), + }, + "notebook_task": basetypes.ListType{ + ElemType: NotebookTask{}.Type(ctx), + }, + "notification_settings": basetypes.ListType{ + ElemType: TaskNotificationSettings{}.Type(ctx), + }, + "pipeline_task": basetypes.ListType{ + ElemType: PipelineTask{}.Type(ctx), + }, + "python_wheel_task": basetypes.ListType{ + ElemType: PythonWheelTask{}.Type(ctx), + }, + "retry_on_timeout": types.BoolType, + "run_if": types.StringType, + "run_job_task": basetypes.ListType{ + ElemType: RunJobTask{}.Type(ctx), + }, + "spark_jar_task": basetypes.ListType{ + ElemType: SparkJarTask{}.Type(ctx), + }, + "spark_python_task": basetypes.ListType{ + ElemType: SparkPythonTask{}.Type(ctx), + }, + "spark_submit_task": basetypes.ListType{ + ElemType: SparkSubmitTask{}.Type(ctx), + }, + "sql_task": basetypes.ListType{ + ElemType: SqlTask{}.Type(ctx), + }, + "task_key": types.StringType, + "timeout_seconds": types.Int64Type, + "webhook_notifications": basetypes.ListType{ + ElemType: WebhookNotifications{}.Type(ctx), + }, }, } } @@ -15479,11 +15763,19 @@ func (o TriggerSettings) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o TriggerSettings) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_arrival": basetypes.ListType{ElemType: FileArrivalTriggerConfiguration{}.Type(ctx)}, + "file_arrival": basetypes.ListType{ + ElemType: FileArrivalTriggerConfiguration{}.Type(ctx), + }, "pause_status": types.StringType, - "periodic": basetypes.ListType{ElemType: PeriodicTriggerConfiguration{}.Type(ctx)}, - "table": basetypes.ListType{ElemType: TableUpdateTriggerConfiguration{}.Type(ctx)}, - "table_update": basetypes.ListType{ElemType: TableUpdateTriggerConfiguration{}.Type(ctx)}, + "periodic": basetypes.ListType{ + ElemType: PeriodicTriggerConfiguration{}.Type(ctx), + }, + "table": basetypes.ListType{ + ElemType: TableUpdateTriggerConfiguration{}.Type(ctx), + }, + "table_update": basetypes.ListType{ + ElemType: TableUpdateTriggerConfiguration{}.Type(ctx), + }, }, } } @@ -15653,8 +15945,10 @@ func (o UpdateJob) Type(ctx context.Context) attr.Type { "fields_to_remove": basetypes.ListType{ ElemType: types.StringType, }, - "job_id": types.Int64Type, - "new_settings": basetypes.ListType{ElemType: JobSettings{}.Type(ctx)}, + "job_id": types.Int64Type, + "new_settings": basetypes.ListType{ + ElemType: JobSettings{}.Type(ctx), + }, }, } } diff --git a/internal/service/marketplace_tf/model.go b/internal/service/marketplace_tf/model.go index 8d8b8454b1..8d04b4a043 100755 --- a/internal/service/marketplace_tf/model.go +++ b/internal/service/marketplace_tf/model.go @@ -104,7 +104,9 @@ func (o AddExchangeForListingResponse) ToObjectValue(ctx context.Context) basety func (o AddExchangeForListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange_for_listing": basetypes.ListType{ElemType: ExchangeListing{}.Type(ctx)}, + "exchange_for_listing": basetypes.ListType{ + ElemType: ExchangeListing{}.Type(ctx), + }, }, } } @@ -555,7 +557,9 @@ func (o CreateExchangeFilterRequest) ToObjectValue(ctx context.Context) basetype func (o CreateExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "filter": basetypes.ListType{ + ElemType: ExchangeFilter{}.Type(ctx), + }, }, } } @@ -665,7 +669,9 @@ func (o CreateExchangeRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, + "exchange": basetypes.ListType{ + ElemType: Exchange{}.Type(ctx), + }, }, } } @@ -784,8 +790,10 @@ func (o CreateFileRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o CreateFileRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "display_name": types.StringType, - "file_parent": basetypes.ListType{ElemType: FileParent{}.Type(ctx)}, + "display_name": types.StringType, + "file_parent": basetypes.ListType{ + ElemType: FileParent{}.Type(ctx), + }, "marketplace_file_type": types.StringType, "mime_type": types.StringType, }, @@ -859,7 +867,9 @@ func (o CreateFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_info": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "file_info": basetypes.ListType{ + ElemType: FileInfo{}.Type(ctx), + }, "upload_url": types.StringType, }, } @@ -945,12 +955,16 @@ func (o CreateInstallationRequest) ToObjectValue(ctx context.Context) basetypes. func (o CreateInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "accepted_consumer_terms": basetypes.ListType{ElemType: ConsumerTerms{}.Type(ctx)}, - "catalog_name": types.StringType, - "listing_id": types.StringType, - "recipient_type": types.StringType, - "repo_detail": basetypes.ListType{ElemType: RepoInstallation{}.Type(ctx)}, - "share_name": types.StringType, + "accepted_consumer_terms": basetypes.ListType{ + ElemType: ConsumerTerms{}.Type(ctx), + }, + "catalog_name": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, + "repo_detail": basetypes.ListType{ + ElemType: RepoInstallation{}.Type(ctx), + }, + "share_name": types.StringType, }, } } @@ -1045,7 +1059,9 @@ func (o CreateListingRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o CreateListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listing": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, }, } } @@ -1180,15 +1196,17 @@ func (o CreatePersonalizationRequest) ToObjectValue(ctx context.Context) basetyp func (o CreatePersonalizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "accepted_consumer_terms": basetypes.ListType{ElemType: ConsumerTerms{}.Type(ctx)}, - "comment": types.StringType, - "company": types.StringType, - "first_name": types.StringType, - "intended_use": types.StringType, - "is_from_lighthouse": types.BoolType, - "last_name": types.StringType, - "listing_id": types.StringType, - "recipient_type": types.StringType, + "accepted_consumer_terms": basetypes.ListType{ + ElemType: ConsumerTerms{}.Type(ctx), + }, + "comment": types.StringType, + "company": types.StringType, + "first_name": types.StringType, + "intended_use": types.StringType, + "is_from_lighthouse": types.BoolType, + "last_name": types.StringType, + "listing_id": types.StringType, + "recipient_type": types.StringType, }, } } @@ -1298,7 +1316,9 @@ func (o CreateProviderRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } @@ -2223,10 +2243,12 @@ func (o FileInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o FileInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "created_at": types.Int64Type, - "display_name": types.StringType, - "download_link": types.StringType, - "file_parent": basetypes.ListType{ElemType: FileParent{}.Type(ctx)}, + "created_at": types.Int64Type, + "display_name": types.StringType, + "download_link": types.StringType, + "file_parent": basetypes.ListType{ + ElemType: FileParent{}.Type(ctx), + }, "id": types.StringType, "marketplace_file_type": types.StringType, "mime_type": types.StringType, @@ -2388,7 +2410,9 @@ func (o GetExchangeResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, + "exchange": basetypes.ListType{ + ElemType: Exchange{}.Type(ctx), + }, }, } } @@ -2499,7 +2523,9 @@ func (o GetFileResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetFileResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_info": basetypes.ListType{ElemType: FileInfo{}.Type(ctx)}, + "file_info": basetypes.ListType{ + ElemType: FileInfo{}.Type(ctx), + }, }, } } @@ -2777,7 +2803,9 @@ func (o GetListingResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o GetListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listing": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, }, } } @@ -3122,7 +3150,9 @@ func (o GetProviderResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o GetProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } @@ -3191,7 +3221,9 @@ func (o Installation) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Installation) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installation": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installation": basetypes.ListType{ + ElemType: InstallationDetail{}.Type(ctx), + }, }, } } @@ -3308,7 +3340,9 @@ func (o InstallationDetail) Type(ctx context.Context) attr.Type { "repo_path": types.StringType, "share_name": types.StringType, "status": types.StringType, - "token_detail": basetypes.ListType{ElemType: TokenDetail{}.Type(ctx)}, + "token_detail": basetypes.ListType{ + ElemType: TokenDetail{}.Type(ctx), + }, "tokens": basetypes.ListType{ ElemType: TokenInfo{}.Type(ctx), }, @@ -4026,9 +4060,11 @@ func (o ListFilesRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ListFilesRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file_parent": basetypes.ListType{ElemType: FileParent{}.Type(ctx)}, - "page_size": types.Int64Type, - "page_token": types.StringType, + "file_parent": basetypes.ListType{ + ElemType: FileParent{}.Type(ctx), + }, + "page_size": types.Int64Type, + "page_token": types.StringType, }, } } @@ -4996,9 +5032,13 @@ func (o Listing) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Listing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "detail": basetypes.ListType{ElemType: ListingDetail{}.Type(ctx)}, - "id": types.StringType, - "summary": basetypes.ListType{ElemType: ListingSummary{}.Type(ctx)}, + "detail": basetypes.ListType{ + ElemType: ListingDetail{}.Type(ctx), + }, + "id": types.StringType, + "summary": basetypes.ListType{ + ElemType: ListingSummary{}.Type(ctx), + }, }, } } @@ -5166,13 +5206,15 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { "assets": basetypes.ListType{ ElemType: types.StringType, }, - "collection_date_end": types.Int64Type, - "collection_date_start": types.Int64Type, - "collection_granularity": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, - "cost": types.StringType, - "data_source": types.StringType, - "description": types.StringType, - "documentation_link": types.StringType, + "collection_date_end": types.Int64Type, + "collection_date_start": types.Int64Type, + "collection_granularity": basetypes.ListType{ + ElemType: DataRefreshInfo{}.Type(ctx), + }, + "cost": types.StringType, + "data_source": types.StringType, + "description": types.StringType, + "documentation_link": types.StringType, "embedded_notebook_file_infos": basetypes.ListType{ ElemType: FileInfo{}.Type(ctx), }, @@ -5189,7 +5231,9 @@ func (o ListingDetail) Type(ctx context.Context) attr.Type { ElemType: ListingTag{}.Type(ctx), }, "terms_of_service": types.StringType, - "update_frequency": basetypes.ListType{ElemType: DataRefreshInfo{}.Type(ctx)}, + "update_frequency": basetypes.ListType{ + ElemType: DataRefreshInfo{}.Type(ctx), + }, }, } } @@ -5404,8 +5448,12 @@ func (o ListingFulfillment) Type(ctx context.Context) attr.Type { "fulfillment_type": types.StringType, "listing_id": types.StringType, "recipient_type": types.StringType, - "repo_info": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, - "share_info": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, + "repo_info": basetypes.ListType{ + ElemType: RepoInfo{}.Type(ctx), + }, + "share_info": basetypes.ListType{ + ElemType: ShareInfo{}.Type(ctx), + }, }, } } @@ -5611,20 +5659,28 @@ func (o ListingSummary) Type(ctx context.Context) attr.Type { "exchange_ids": basetypes.ListType{ ElemType: types.StringType, }, - "git_repo": basetypes.ListType{ElemType: RepoInfo{}.Type(ctx)}, - "listingType": types.StringType, - "name": types.StringType, - "provider_id": types.StringType, - "provider_region": basetypes.ListType{ElemType: RegionInfo{}.Type(ctx)}, - "published_at": types.Int64Type, - "published_by": types.StringType, - "setting": basetypes.ListType{ElemType: ListingSetting{}.Type(ctx)}, - "share": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, - "status": types.StringType, - "subtitle": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, - "updated_by_id": types.Int64Type, + "git_repo": basetypes.ListType{ + ElemType: RepoInfo{}.Type(ctx), + }, + "listingType": types.StringType, + "name": types.StringType, + "provider_id": types.StringType, + "provider_region": basetypes.ListType{ + ElemType: RegionInfo{}.Type(ctx), + }, + "published_at": types.Int64Type, + "published_by": types.StringType, + "setting": basetypes.ListType{ + ElemType: ListingSetting{}.Type(ctx), + }, + "share": basetypes.ListType{ + ElemType: ShareInfo{}.Type(ctx), + }, + "status": types.StringType, + "subtitle": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, + "updated_by_id": types.Int64Type, }, } } @@ -5948,9 +6004,13 @@ func (o PersonalizationRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o PersonalizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "consumer_region": basetypes.ListType{ElemType: RegionInfo{}.Type(ctx)}, - "contact_info": basetypes.ListType{ElemType: ContactInfo{}.Type(ctx)}, + "comment": types.StringType, + "consumer_region": basetypes.ListType{ + ElemType: RegionInfo{}.Type(ctx), + }, + "contact_info": basetypes.ListType{ + ElemType: ContactInfo{}.Type(ctx), + }, "created_at": types.Int64Type, "id": types.StringType, "intended_use": types.StringType, @@ -5960,10 +6020,12 @@ func (o PersonalizationRequest) Type(ctx context.Context) attr.Type { "metastore_id": types.StringType, "provider_id": types.StringType, "recipient_type": types.StringType, - "share": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, - "status": types.StringType, - "status_message": types.StringType, - "updated_at": types.Int64Type, + "share": basetypes.ListType{ + ElemType: ShareInfo{}.Type(ctx), + }, + "status": types.StringType, + "status_message": types.StringType, + "updated_at": types.Int64Type, }, } } @@ -6882,8 +6944,10 @@ func (o UpdateExchangeFilterRequest) ToObjectValue(ctx context.Context) basetype func (o UpdateExchangeFilterRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, - "id": types.StringType, + "filter": basetypes.ListType{ + ElemType: ExchangeFilter{}.Type(ctx), + }, + "id": types.StringType, }, } } @@ -6952,7 +7016,9 @@ func (o UpdateExchangeFilterResponse) ToObjectValue(ctx context.Context) basetyp func (o UpdateExchangeFilterResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter": basetypes.ListType{ElemType: ExchangeFilter{}.Type(ctx)}, + "filter": basetypes.ListType{ + ElemType: ExchangeFilter{}.Type(ctx), + }, }, } } @@ -7024,8 +7090,10 @@ func (o UpdateExchangeRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateExchangeRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, - "id": types.StringType, + "exchange": basetypes.ListType{ + ElemType: Exchange{}.Type(ctx), + }, + "id": types.StringType, }, } } @@ -7094,7 +7162,9 @@ func (o UpdateExchangeResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateExchangeResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "exchange": basetypes.ListType{ElemType: Exchange{}.Type(ctx)}, + "exchange": basetypes.ListType{ + ElemType: Exchange{}.Type(ctx), + }, }, } } @@ -7172,7 +7242,9 @@ func (o UpdateInstallationRequest) ToObjectValue(ctx context.Context) basetypes. func (o UpdateInstallationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installation": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installation": basetypes.ListType{ + ElemType: InstallationDetail{}.Type(ctx), + }, "installation_id": types.StringType, "listing_id": types.StringType, "rotate_token": types.BoolType, @@ -7244,7 +7316,9 @@ func (o UpdateInstallationResponse) ToObjectValue(ctx context.Context) basetypes func (o UpdateInstallationResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "installation": basetypes.ListType{ElemType: InstallationDetail{}.Type(ctx)}, + "installation": basetypes.ListType{ + ElemType: InstallationDetail{}.Type(ctx), + }, }, } } @@ -7316,8 +7390,10 @@ func (o UpdateListingRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o UpdateListingRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "id": types.StringType, + "listing": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, }, } } @@ -7386,7 +7462,9 @@ func (o UpdateListingResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateListingResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "listing": basetypes.ListType{ElemType: Listing{}.Type(ctx)}, + "listing": basetypes.ListType{ + ElemType: Listing{}.Type(ctx), + }, }, } } @@ -7470,8 +7548,10 @@ func (o UpdatePersonalizationRequestRequest) Type(ctx context.Context) attr.Type "listing_id": types.StringType, "reason": types.StringType, "request_id": types.StringType, - "share": basetypes.ListType{ElemType: ShareInfo{}.Type(ctx)}, - "status": types.StringType, + "share": basetypes.ListType{ + ElemType: ShareInfo{}.Type(ctx), + }, + "status": types.StringType, }, } } @@ -7540,7 +7620,9 @@ func (o UpdatePersonalizationRequestResponse) ToObjectValue(ctx context.Context) func (o UpdatePersonalizationRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "request": basetypes.ListType{ElemType: PersonalizationRequest{}.Type(ctx)}, + "request": basetypes.ListType{ + ElemType: PersonalizationRequest{}.Type(ctx), + }, }, } } @@ -7710,8 +7792,10 @@ func (o UpdateProviderRequest) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateProviderRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "id": types.StringType, + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } @@ -7780,7 +7864,9 @@ func (o UpdateProviderResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o UpdateProviderResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "provider": basetypes.ListType{ElemType: ProviderInfo{}.Type(ctx)}, + "provider": basetypes.ListType{ + ElemType: ProviderInfo{}.Type(ctx), + }, }, } } diff --git a/internal/service/ml_tf/model.go b/internal/service/ml_tf/model.go index 7c104a4af5..c93c99fe96 100755 --- a/internal/service/ml_tf/model.go +++ b/internal/service/ml_tf/model.go @@ -236,7 +236,9 @@ func (o ApproveTransitionRequestResponse) ToObjectValue(ctx context.Context) bas func (o ApproveTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "activity": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, + "activity": basetypes.ListType{ + ElemType: Activity{}.Type(ctx), + }, }, } } @@ -449,7 +451,9 @@ func (o CreateCommentResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": basetypes.ListType{ElemType: CommentObject{}.Type(ctx)}, + "comment": basetypes.ListType{ + ElemType: CommentObject{}.Type(ctx), + }, }, } } @@ -725,7 +729,9 @@ func (o CreateModelResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o CreateModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "registered_model": basetypes.ListType{ElemType: Model{}.Type(ctx)}, + "registered_model": basetypes.ListType{ + ElemType: Model{}.Type(ctx), + }, }, } } @@ -889,7 +895,9 @@ func (o CreateModelVersionResponse) ToObjectValue(ctx context.Context) basetypes func (o CreateModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_version": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "model_version": basetypes.ListType{ + ElemType: ModelVersion{}.Type(ctx), + }, }, } } @@ -1019,10 +1027,14 @@ func (o CreateRegistryWebhook) Type(ctx context.Context) attr.Type { "events": basetypes.ListType{ ElemType: types.StringType, }, - "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpec{}.Type(ctx)}, - "job_spec": basetypes.ListType{ElemType: JobSpec{}.Type(ctx)}, - "model_name": types.StringType, - "status": types.StringType, + "http_url_spec": basetypes.ListType{ + ElemType: HttpUrlSpec{}.Type(ctx), + }, + "job_spec": basetypes.ListType{ + ElemType: JobSpec{}.Type(ctx), + }, + "model_name": types.StringType, + "status": types.StringType, }, } } @@ -1230,7 +1242,9 @@ func (o CreateRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o CreateRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "run": basetypes.ListType{ElemType: Run{}.Type(ctx)}, + "run": basetypes.ListType{ + ElemType: Run{}.Type(ctx), + }, }, } } @@ -1362,7 +1376,9 @@ func (o CreateTransitionRequestResponse) ToObjectValue(ctx context.Context) base func (o CreateTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "request": basetypes.ListType{ElemType: TransitionRequest{}.Type(ctx)}, + "request": basetypes.ListType{ + ElemType: TransitionRequest{}.Type(ctx), + }, }, } } @@ -1431,7 +1447,9 @@ func (o CreateWebhookResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "webhook": basetypes.ListType{ElemType: RegistryWebhook{}.Type(ctx)}, + "webhook": basetypes.ListType{ + ElemType: RegistryWebhook{}.Type(ctx), + }, }, } } @@ -1576,7 +1594,9 @@ func (o DatasetInput) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o DatasetInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dataset": basetypes.ListType{ElemType: Dataset{}.Type(ctx)}, + "dataset": basetypes.ListType{ + ElemType: Dataset{}.Type(ctx), + }, "tags": basetypes.ListType{ ElemType: InputTag{}.Type(ctx), }, @@ -3461,7 +3481,9 @@ func (o GetExperimentResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o GetExperimentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "experiment": basetypes.ListType{ElemType: Experiment{}.Type(ctx)}, + "experiment": basetypes.ListType{ + ElemType: Experiment{}.Type(ctx), + }, }, } } @@ -3862,7 +3884,9 @@ func (o GetModelResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o GetModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "registered_model_databricks": basetypes.ListType{ElemType: ModelDatabricks{}.Type(ctx)}, + "registered_model_databricks": basetypes.ListType{ + ElemType: ModelDatabricks{}.Type(ctx), + }, }, } } @@ -4067,7 +4091,9 @@ func (o GetModelVersionResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o GetModelVersionResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_version": basetypes.ListType{ElemType: ModelVersion{}.Type(ctx)}, + "model_version": basetypes.ListType{ + ElemType: ModelVersion{}.Type(ctx), + }, }, } } @@ -4344,7 +4370,9 @@ func (o GetRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o GetRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "run": basetypes.ListType{ElemType: Run{}.Type(ctx)}, + "run": basetypes.ListType{ + ElemType: Run{}.Type(ctx), + }, }, } } @@ -7130,9 +7158,13 @@ func (o RegistryWebhook) Type(ctx context.Context) attr.Type { "events": basetypes.ListType{ ElemType: types.StringType, }, - "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpecWithoutSecret{}.Type(ctx)}, - "id": types.StringType, - "job_spec": basetypes.ListType{ElemType: JobSpecWithoutSecret{}.Type(ctx)}, + "http_url_spec": basetypes.ListType{ + ElemType: HttpUrlSpecWithoutSecret{}.Type(ctx), + }, + "id": types.StringType, + "job_spec": basetypes.ListType{ + ElemType: JobSpecWithoutSecret{}.Type(ctx), + }, "last_updated_timestamp": types.Int64Type, "model_name": types.StringType, "status": types.StringType, @@ -7319,7 +7351,9 @@ func (o RejectTransitionRequestResponse) ToObjectValue(ctx context.Context) base func (o RejectTransitionRequestResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "activity": basetypes.ListType{ElemType: Activity{}.Type(ctx)}, + "activity": basetypes.ListType{ + ElemType: Activity{}.Type(ctx), + }, }, } } @@ -7434,7 +7468,9 @@ func (o RenameModelResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o RenameModelResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "registered_model": basetypes.ListType{ElemType: Model{}.Type(ctx)}, + "registered_model": basetypes.ListType{ + ElemType: Model{}.Type(ctx), + }, }, } } @@ -7763,9 +7799,15 @@ func (o Run) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Run) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "data": basetypes.ListType{ElemType: RunData{}.Type(ctx)}, - "info": basetypes.ListType{ElemType: RunInfo{}.Type(ctx)}, - "inputs": basetypes.ListType{ElemType: RunInputs{}.Type(ctx)}, + "data": basetypes.ListType{ + ElemType: RunData{}.Type(ctx), + }, + "info": basetypes.ListType{ + ElemType: RunInfo{}.Type(ctx), + }, + "inputs": basetypes.ListType{ + ElemType: RunInputs{}.Type(ctx), + }, }, } } @@ -9402,7 +9444,9 @@ func (o TestRegistryWebhookResponse) ToObjectValue(ctx context.Context) basetype func (o TestRegistryWebhookResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "webhook": basetypes.ListType{ElemType: TestRegistryWebhook{}.Type(ctx)}, + "webhook": basetypes.ListType{ + ElemType: TestRegistryWebhook{}.Type(ctx), + }, }, } } @@ -9636,7 +9680,9 @@ func (o TransitionStageResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o TransitionStageResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "model_version": basetypes.ListType{ElemType: ModelVersionDatabricks{}.Type(ctx)}, + "model_version": basetypes.ListType{ + ElemType: ModelVersionDatabricks{}.Type(ctx), + }, }, } } @@ -9752,7 +9798,9 @@ func (o UpdateCommentResponse) ToObjectValue(ctx context.Context) basetypes.Obje func (o UpdateCommentResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": basetypes.ListType{ElemType: CommentObject{}.Type(ctx)}, + "comment": basetypes.ListType{ + ElemType: CommentObject{}.Type(ctx), + }, }, } } @@ -10133,10 +10181,14 @@ func (o UpdateRegistryWebhook) Type(ctx context.Context) attr.Type { "events": basetypes.ListType{ ElemType: types.StringType, }, - "http_url_spec": basetypes.ListType{ElemType: HttpUrlSpec{}.Type(ctx)}, - "id": types.StringType, - "job_spec": basetypes.ListType{ElemType: JobSpec{}.Type(ctx)}, - "status": types.StringType, + "http_url_spec": basetypes.ListType{ + ElemType: HttpUrlSpec{}.Type(ctx), + }, + "id": types.StringType, + "job_spec": basetypes.ListType{ + ElemType: JobSpec{}.Type(ctx), + }, + "status": types.StringType, }, } } @@ -10313,7 +10365,9 @@ func (o UpdateRunResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdateRunResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "run_info": basetypes.ListType{ElemType: RunInfo{}.Type(ctx)}, + "run_info": basetypes.ListType{ + ElemType: RunInfo{}.Type(ctx), + }, }, } } diff --git a/internal/service/oauth2_tf/model.go b/internal/service/oauth2_tf/model.go index 1e9b022b29..e2e8defbdf 100755 --- a/internal/service/oauth2_tf/model.go +++ b/internal/service/oauth2_tf/model.go @@ -84,7 +84,9 @@ func (o CreateCustomAppIntegration) Type(ctx context.Context) attr.Type { "scopes": basetypes.ListType{ ElemType: types.StringType, }, - "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.Type(ctx), + }, }, } } @@ -261,8 +263,10 @@ func (o CreatePublishedAppIntegration) ToObjectValue(ctx context.Context) basety func (o CreatePublishedAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_id": types.StringType, - "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, + "app_id": types.StringType, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.Type(ctx), + }, }, } } @@ -807,7 +811,9 @@ func (o GetCustomAppIntegrationOutput) Type(ctx context.Context) attr.Type { "scopes": basetypes.ListType{ ElemType: types.StringType, }, - "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.Type(ctx), + }, }, } } @@ -1063,12 +1069,14 @@ func (o GetPublishedAppIntegrationOutput) ToObjectValue(ctx context.Context) bas func (o GetPublishedAppIntegrationOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "app_id": types.StringType, - "create_time": types.StringType, - "created_by": types.Int64Type, - "integration_id": types.StringType, - "name": types.StringType, - "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, + "app_id": types.StringType, + "create_time": types.StringType, + "created_by": types.Int64Type, + "integration_id": types.StringType, + "name": types.StringType, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.Type(ctx), + }, }, } } @@ -1849,7 +1857,9 @@ func (o UpdateCustomAppIntegration) Type(ctx context.Context) attr.Type { "redirect_urls": basetypes.ListType{ ElemType: types.StringType, }, - "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.Type(ctx), + }, }, } } @@ -1983,8 +1993,10 @@ func (o UpdatePublishedAppIntegration) ToObjectValue(ctx context.Context) basety func (o UpdatePublishedAppIntegration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "integration_id": types.StringType, - "token_access_policy": basetypes.ListType{ElemType: TokenAccessPolicy{}.Type(ctx)}, + "integration_id": types.StringType, + "token_access_policy": basetypes.ListType{ + ElemType: TokenAccessPolicy{}.Type(ctx), + }, }, } } diff --git a/internal/service/pipelines_tf/model.go b/internal/service/pipelines_tf/model.go index 0412223661..311cb5ccbd 100755 --- a/internal/service/pipelines_tf/model.go +++ b/internal/service/pipelines_tf/model.go @@ -162,15 +162,23 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "configuration": basetypes.MapType{ ElemType: types.StringType, }, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, - "development": types.BoolType, - "dry_run": types.BoolType, - "edition": types.StringType, - "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, - "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ + ElemType: PipelineDeployment{}.Type(ctx), + }, + "development": types.BoolType, + "dry_run": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ + ElemType: Filters{}.Type(ctx), + }, + "gateway_definition": basetypes.ListType{ + ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), + }, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ + ElemType: IngestionPipelineDefinition{}.Type(ctx), + }, "libraries": basetypes.ListType{ ElemType: PipelineLibrary{}.Type(ctx), }, @@ -178,13 +186,17 @@ func (o CreatePipeline) Type(ctx context.Context) attr.Type { "notifications": basetypes.ListType{ ElemType: Notifications{}.Type(ctx), }, - "photon": types.BoolType, - "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, + "photon": types.BoolType, + "restart_window": basetypes.ListType{ + ElemType: RestartWindow{}.Type(ctx), + }, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ + ElemType: PipelineTrigger{}.Type(ctx), + }, }, } } @@ -492,8 +504,10 @@ func (o CreatePipelineResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreatePipelineResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "effective_settings": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, - "pipeline_id": types.StringType, + "effective_settings": basetypes.ListType{ + ElemType: PipelineSpec{}.Type(ctx), + }, + "pipeline_id": types.StringType, }, } } @@ -838,15 +852,23 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "configuration": basetypes.MapType{ ElemType: types.StringType, }, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ + ElemType: PipelineDeployment{}.Type(ctx), + }, "development": types.BoolType, "edition": types.StringType, "expected_last_modified": types.Int64Type, - "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, - "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "filters": basetypes.ListType{ + ElemType: Filters{}.Type(ctx), + }, + "gateway_definition": basetypes.ListType{ + ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), + }, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ + ElemType: IngestionPipelineDefinition{}.Type(ctx), + }, "libraries": basetypes.ListType{ ElemType: PipelineLibrary{}.Type(ctx), }, @@ -854,14 +876,18 @@ func (o EditPipeline) Type(ctx context.Context) attr.Type { "notifications": basetypes.ListType{ ElemType: Notifications{}.Type(ctx), }, - "photon": types.BoolType, - "pipeline_id": types.StringType, - "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, + "photon": types.BoolType, + "pipeline_id": types.StringType, + "restart_window": basetypes.ListType{ + ElemType: RestartWindow{}.Type(ctx), + }, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ + ElemType: PipelineTrigger{}.Type(ctx), + }, }, } } @@ -1672,8 +1698,10 @@ func (o GetPipelineResponse) Type(ctx context.Context) attr.Type { "name": types.StringType, "pipeline_id": types.StringType, "run_as_user_name": types.StringType, - "spec": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, - "state": types.StringType, + "spec": basetypes.ListType{ + ElemType: PipelineSpec{}.Type(ctx), + }, + "state": types.StringType, }, } } @@ -1816,7 +1844,9 @@ func (o GetUpdateResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o GetUpdateResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "update": basetypes.ListType{ElemType: UpdateInfo{}.Type(ctx)}, + "update": basetypes.ListType{ + ElemType: UpdateInfo{}.Type(ctx), + }, }, } } @@ -1894,9 +1924,15 @@ func (o IngestionConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o IngestionConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "report": basetypes.ListType{ElemType: ReportSpec{}.Type(ctx)}, - "schema": basetypes.ListType{ElemType: SchemaSpec{}.Type(ctx)}, - "table": basetypes.ListType{ElemType: TableSpec{}.Type(ctx)}, + "report": basetypes.ListType{ + ElemType: ReportSpec{}.Type(ctx), + }, + "schema": basetypes.ListType{ + ElemType: SchemaSpec{}.Type(ctx), + }, + "table": basetypes.ListType{ + ElemType: TableSpec{}.Type(ctx), + }, }, } } @@ -2105,7 +2141,9 @@ func (o IngestionPipelineDefinition) Type(ctx context.Context) attr.Type { "objects": basetypes.ListType{ ElemType: IngestionConfig{}.Type(ctx), }, - "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.Type(ctx), + }, }, } } @@ -3252,17 +3290,27 @@ func (o PipelineCluster) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "apply_policy_default_values": types.BoolType, - "autoscale": basetypes.ListType{ElemType: PipelineClusterAutoscale{}.Type(ctx)}, - "aws_attributes": basetypes.ListType{ElemType: compute_tf.AwsAttributes{}.Type(ctx)}, - "azure_attributes": basetypes.ListType{ElemType: compute_tf.AzureAttributes{}.Type(ctx)}, - "cluster_log_conf": basetypes.ListType{ElemType: compute_tf.ClusterLogConf{}.Type(ctx)}, + "autoscale": basetypes.ListType{ + ElemType: PipelineClusterAutoscale{}.Type(ctx), + }, + "aws_attributes": basetypes.ListType{ + ElemType: compute_tf.AwsAttributes{}.Type(ctx), + }, + "azure_attributes": basetypes.ListType{ + ElemType: compute_tf.AzureAttributes{}.Type(ctx), + }, + "cluster_log_conf": basetypes.ListType{ + ElemType: compute_tf.ClusterLogConf{}.Type(ctx), + }, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, "driver_instance_pool_id": types.StringType, "driver_node_type_id": types.StringType, "enable_local_disk_encryption": types.BoolType, - "gcp_attributes": basetypes.ListType{ElemType: compute_tf.GcpAttributes{}.Type(ctx)}, + "gcp_attributes": basetypes.ListType{ + ElemType: compute_tf.GcpAttributes{}.Type(ctx), + }, "init_scripts": basetypes.ListType{ ElemType: compute_tf.InitScriptInfo{}.Type(ctx), }, @@ -3712,15 +3760,21 @@ func (o PipelineEvent) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o PipelineEvent) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error": basetypes.ListType{ElemType: ErrorDetail{}.Type(ctx)}, + "error": basetypes.ListType{ + ElemType: ErrorDetail{}.Type(ctx), + }, "event_type": types.StringType, "id": types.StringType, "level": types.StringType, "maturity_level": types.StringType, "message": types.StringType, - "origin": basetypes.ListType{ElemType: Origin{}.Type(ctx)}, - "sequence": basetypes.ListType{ElemType: Sequencing{}.Type(ctx)}, - "timestamp": types.StringType, + "origin": basetypes.ListType{ + ElemType: Origin{}.Type(ctx), + }, + "sequence": basetypes.ListType{ + ElemType: Sequencing{}.Type(ctx), + }, + "timestamp": types.StringType, }, } } @@ -3858,11 +3912,17 @@ func (o PipelineLibrary) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PipelineLibrary) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "file": basetypes.ListType{ElemType: FileLibrary{}.Type(ctx)}, - "jar": types.StringType, - "maven": basetypes.ListType{ElemType: compute_tf.MavenLibrary{}.Type(ctx)}, - "notebook": basetypes.ListType{ElemType: NotebookLibrary{}.Type(ctx)}, - "whl": types.StringType, + "file": basetypes.ListType{ + ElemType: FileLibrary{}.Type(ctx), + }, + "jar": types.StringType, + "maven": basetypes.ListType{ + ElemType: compute_tf.MavenLibrary{}.Type(ctx), + }, + "notebook": basetypes.ListType{ + ElemType: NotebookLibrary{}.Type(ctx), + }, + "whl": types.StringType, }, } } @@ -4355,14 +4415,22 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "configuration": basetypes.MapType{ ElemType: types.StringType, }, - "continuous": types.BoolType, - "deployment": basetypes.ListType{ElemType: PipelineDeployment{}.Type(ctx)}, - "development": types.BoolType, - "edition": types.StringType, - "filters": basetypes.ListType{ElemType: Filters{}.Type(ctx)}, - "gateway_definition": basetypes.ListType{ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx)}, - "id": types.StringType, - "ingestion_definition": basetypes.ListType{ElemType: IngestionPipelineDefinition{}.Type(ctx)}, + "continuous": types.BoolType, + "deployment": basetypes.ListType{ + ElemType: PipelineDeployment{}.Type(ctx), + }, + "development": types.BoolType, + "edition": types.StringType, + "filters": basetypes.ListType{ + ElemType: Filters{}.Type(ctx), + }, + "gateway_definition": basetypes.ListType{ + ElemType: IngestionGatewayPipelineDefinition{}.Type(ctx), + }, + "id": types.StringType, + "ingestion_definition": basetypes.ListType{ + ElemType: IngestionPipelineDefinition{}.Type(ctx), + }, "libraries": basetypes.ListType{ ElemType: PipelineLibrary{}.Type(ctx), }, @@ -4370,13 +4438,17 @@ func (o PipelineSpec) Type(ctx context.Context) attr.Type { "notifications": basetypes.ListType{ ElemType: Notifications{}.Type(ctx), }, - "photon": types.BoolType, - "restart_window": basetypes.ListType{ElemType: RestartWindow{}.Type(ctx)}, - "schema": types.StringType, - "serverless": types.BoolType, - "storage": types.StringType, - "target": types.StringType, - "trigger": basetypes.ListType{ElemType: PipelineTrigger{}.Type(ctx)}, + "photon": types.BoolType, + "restart_window": basetypes.ListType{ + ElemType: RestartWindow{}.Type(ctx), + }, + "schema": types.StringType, + "serverless": types.BoolType, + "storage": types.StringType, + "target": types.StringType, + "trigger": basetypes.ListType{ + ElemType: PipelineTrigger{}.Type(ctx), + }, }, } } @@ -4785,8 +4857,12 @@ func (o PipelineTrigger) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o PipelineTrigger) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cron": basetypes.ListType{ElemType: CronTrigger{}.Type(ctx)}, - "manual": basetypes.ListType{ElemType: ManualTrigger{}.Type(ctx)}, + "cron": basetypes.ListType{ + ElemType: CronTrigger{}.Type(ctx), + }, + "manual": basetypes.ListType{ + ElemType: ManualTrigger{}.Type(ctx), + }, }, } } @@ -4901,7 +4977,9 @@ func (o ReportSpec) Type(ctx context.Context) attr.Type { "destination_schema": types.StringType, "destination_table": types.StringType, "source_url": types.StringType, - "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.Type(ctx), + }, }, } } @@ -5048,7 +5126,9 @@ func (o SchemaSpec) Type(ctx context.Context) attr.Type { "destination_schema": types.StringType, "source_catalog": types.StringType, "source_schema": types.StringType, - "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.Type(ctx), + }, }, } } @@ -5122,7 +5202,9 @@ func (o Sequencing) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ "control_plane_seq_no": types.Int64Type, - "data_plane_id": basetypes.ListType{ElemType: DataPlaneId{}.Type(ctx)}, + "data_plane_id": basetypes.ListType{ + ElemType: DataPlaneId{}.Type(ctx), + }, }, } } @@ -5600,7 +5682,9 @@ func (o TableSpec) Type(ctx context.Context) attr.Type { "source_catalog": types.StringType, "source_schema": types.StringType, "source_table": types.StringType, - "table_configuration": basetypes.ListType{ElemType: TableSpecificConfig{}.Type(ctx)}, + "table_configuration": basetypes.ListType{ + ElemType: TableSpecificConfig{}.Type(ctx), + }, }, } } @@ -5826,9 +5910,11 @@ func (o UpdateInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o UpdateInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "cause": types.StringType, - "cluster_id": types.StringType, - "config": basetypes.ListType{ElemType: PipelineSpec{}.Type(ctx)}, + "cause": types.StringType, + "cluster_id": types.StringType, + "config": basetypes.ListType{ + ElemType: PipelineSpec{}.Type(ctx), + }, "creation_time": types.Int64Type, "full_refresh": types.BoolType, "full_refresh_selection": basetypes.ListType{ diff --git a/internal/service/provisioning_tf/model.go b/internal/service/provisioning_tf/model.go index ce465d0fe1..14101d4765 100755 --- a/internal/service/provisioning_tf/model.go +++ b/internal/service/provisioning_tf/model.go @@ -59,7 +59,9 @@ func (o AwsCredentials) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o AwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "sts_role": basetypes.ListType{ElemType: StsRole{}.Type(ctx)}, + "sts_role": basetypes.ListType{ + ElemType: StsRole{}.Type(ctx), + }, }, } } @@ -233,7 +235,9 @@ func (o CloudResourceContainer) ToObjectValue(ctx context.Context) basetypes.Obj func (o CloudResourceContainer) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "gcp": basetypes.ListType{ElemType: CustomerFacingGcpCloudResourceContainer{}.Type(ctx)}, + "gcp": basetypes.ListType{ + ElemType: CustomerFacingGcpCloudResourceContainer{}.Type(ctx), + }, }, } } @@ -356,7 +360,9 @@ func (o CreateCredentialAwsCredentials) ToObjectValue(ctx context.Context) baset func (o CreateCredentialAwsCredentials) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "sts_role": basetypes.ListType{ElemType: CreateCredentialStsRole{}.Type(ctx)}, + "sts_role": basetypes.ListType{ + ElemType: CreateCredentialStsRole{}.Type(ctx), + }, }, } } @@ -428,7 +434,9 @@ func (o CreateCredentialRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateCredentialRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_credentials": basetypes.ListType{ElemType: CreateCredentialAwsCredentials{}.Type(ctx)}, + "aws_credentials": basetypes.ListType{ + ElemType: CreateCredentialAwsCredentials{}.Type(ctx), + }, "credentials_name": types.StringType, }, } @@ -548,8 +556,12 @@ func (o CreateCustomerManagedKeyRequest) ToObjectValue(ctx context.Context) base func (o CreateCustomerManagedKeyRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_key_info": basetypes.ListType{ElemType: CreateAwsKeyInfo{}.Type(ctx)}, - "gcp_key_info": basetypes.ListType{ElemType: CreateGcpKeyInfo{}.Type(ctx)}, + "aws_key_info": basetypes.ListType{ + ElemType: CreateAwsKeyInfo{}.Type(ctx), + }, + "gcp_key_info": basetypes.ListType{ + ElemType: CreateGcpKeyInfo{}.Type(ctx), + }, "use_cases": basetypes.ListType{ ElemType: types.StringType, }, @@ -741,16 +753,20 @@ func (o CreateNetworkRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o CreateNetworkRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, - "network_name": types.StringType, + "gcp_network_info": basetypes.ListType{ + ElemType: GcpNetworkInfo{}.Type(ctx), + }, + "network_name": types.StringType, "security_group_ids": basetypes.ListType{ ElemType: types.StringType, }, "subnet_ids": basetypes.ListType{ ElemType: types.StringType, }, - "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, - "vpc_id": types.StringType, + "vpc_endpoints": basetypes.ListType{ + ElemType: NetworkVpcEndpoints{}.Type(ctx), + }, + "vpc_id": types.StringType, }, } } @@ -901,7 +917,9 @@ func (o CreateStorageConfigurationRequest) ToObjectValue(ctx context.Context) ba func (o CreateStorageConfigurationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "root_bucket_info": basetypes.ListType{ElemType: RootBucketInfo{}.Type(ctx)}, + "root_bucket_info": basetypes.ListType{ + ElemType: RootBucketInfo{}.Type(ctx), + }, "storage_configuration_name": types.StringType, }, } @@ -982,10 +1000,12 @@ func (o CreateVpcEndpointRequest) ToObjectValue(ctx context.Context) basetypes.O func (o CreateVpcEndpointRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_vpc_endpoint_id": types.StringType, - "gcp_vpc_endpoint_info": basetypes.ListType{ElemType: GcpVpcEndpointInfo{}.Type(ctx)}, - "region": types.StringType, - "vpc_endpoint_name": types.StringType, + "aws_vpc_endpoint_id": types.StringType, + "gcp_vpc_endpoint_info": basetypes.ListType{ + ElemType: GcpVpcEndpointInfo{}.Type(ctx), + }, + "region": types.StringType, + "vpc_endpoint_name": types.StringType, }, } } @@ -1182,25 +1202,31 @@ func (o CreateWorkspaceRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateWorkspaceRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_region": types.StringType, - "cloud": types.StringType, - "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, - "credentials_id": types.StringType, + "aws_region": types.StringType, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ + ElemType: CloudResourceContainer{}.Type(ctx), + }, + "credentials_id": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "deployment_name": types.StringType, - "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, - "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, - "is_no_public_ip_enabled": types.BoolType, - "location": types.StringType, + "deployment_name": types.StringType, + "gcp_managed_network_config": basetypes.ListType{ + ElemType: GcpManagedNetworkConfig{}.Type(ctx), + }, + "gke_config": basetypes.ListType{ + ElemType: GkeConfig{}.Type(ctx), + }, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, "managed_services_customer_managed_key_id": types.StringType, - "network_id": types.StringType, - "pricing_tier": types.StringType, - "private_access_settings_id": types.StringType, - "storage_configuration_id": types.StringType, - "storage_customer_managed_key_id": types.StringType, - "workspace_name": types.StringType, + "network_id": types.StringType, + "pricing_tier": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_name": types.StringType, }, } } @@ -1360,8 +1386,10 @@ func (o Credential) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Credential) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_credentials": basetypes.ListType{ElemType: AwsCredentials{}.Type(ctx)}, + "account_id": types.StringType, + "aws_credentials": basetypes.ListType{ + ElemType: AwsCredentials{}.Type(ctx), + }, "creation_time": types.Int64Type, "credentials_id": types.StringType, "credentials_name": types.StringType, @@ -1495,11 +1523,15 @@ func (o CustomerManagedKey) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CustomerManagedKey) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_key_info": basetypes.ListType{ElemType: AwsKeyInfo{}.Type(ctx)}, + "account_id": types.StringType, + "aws_key_info": basetypes.ListType{ + ElemType: AwsKeyInfo{}.Type(ctx), + }, "creation_time": types.Int64Type, "customer_managed_key_id": types.StringType, - "gcp_key_info": basetypes.ListType{ElemType: GcpKeyInfo{}.Type(ctx)}, + "gcp_key_info": basetypes.ListType{ + ElemType: GcpKeyInfo{}.Type(ctx), + }, "use_cases": basetypes.ListType{ ElemType: types.StringType, }, @@ -2671,18 +2703,22 @@ func (o Network) Type(ctx context.Context) attr.Type { "error_messages": basetypes.ListType{ ElemType: NetworkHealth{}.Type(ctx), }, - "gcp_network_info": basetypes.ListType{ElemType: GcpNetworkInfo{}.Type(ctx)}, - "network_id": types.StringType, - "network_name": types.StringType, + "gcp_network_info": basetypes.ListType{ + ElemType: GcpNetworkInfo{}.Type(ctx), + }, + "network_id": types.StringType, + "network_name": types.StringType, "security_group_ids": basetypes.ListType{ ElemType: types.StringType, }, "subnet_ids": basetypes.ListType{ ElemType: types.StringType, }, - "vpc_endpoints": basetypes.ListType{ElemType: NetworkVpcEndpoints{}.Type(ctx)}, - "vpc_id": types.StringType, - "vpc_status": types.StringType, + "vpc_endpoints": basetypes.ListType{ + ElemType: NetworkVpcEndpoints{}.Type(ctx), + }, + "vpc_id": types.StringType, + "vpc_status": types.StringType, "warning_messages": basetypes.ListType{ ElemType: NetworkWarning{}.Type(ctx), }, @@ -3288,9 +3324,11 @@ func (o StorageConfiguration) ToObjectValue(ctx context.Context) basetypes.Objec func (o StorageConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "creation_time": types.Int64Type, - "root_bucket_info": basetypes.ListType{ElemType: RootBucketInfo{}.Type(ctx)}, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "root_bucket_info": basetypes.ListType{ + ElemType: RootBucketInfo{}.Type(ctx), + }, "storage_configuration_id": types.StringType, "storage_configuration_name": types.StringType, }, @@ -3726,12 +3764,14 @@ func (o VpcEndpoint) Type(ctx context.Context) attr.Type { "aws_account_id": types.StringType, "aws_endpoint_service_id": types.StringType, "aws_vpc_endpoint_id": types.StringType, - "gcp_vpc_endpoint_info": basetypes.ListType{ElemType: GcpVpcEndpointInfo{}.Type(ctx)}, - "region": types.StringType, - "state": types.StringType, - "use_case": types.StringType, - "vpc_endpoint_id": types.StringType, - "vpc_endpoint_name": types.StringType, + "gcp_vpc_endpoint_info": basetypes.ListType{ + ElemType: GcpVpcEndpointInfo{}.Type(ctx), + }, + "region": types.StringType, + "state": types.StringType, + "use_case": types.StringType, + "vpc_endpoint_id": types.StringType, + "vpc_endpoint_name": types.StringType, }, } } @@ -3924,32 +3964,42 @@ func (o Workspace) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Workspace) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "aws_region": types.StringType, - "azure_workspace_info": basetypes.ListType{ElemType: AzureWorkspaceInfo{}.Type(ctx)}, - "cloud": types.StringType, - "cloud_resource_container": basetypes.ListType{ElemType: CloudResourceContainer{}.Type(ctx)}, - "creation_time": types.Int64Type, - "credentials_id": types.StringType, + "account_id": types.StringType, + "aws_region": types.StringType, + "azure_workspace_info": basetypes.ListType{ + ElemType: AzureWorkspaceInfo{}.Type(ctx), + }, + "cloud": types.StringType, + "cloud_resource_container": basetypes.ListType{ + ElemType: CloudResourceContainer{}.Type(ctx), + }, + "creation_time": types.Int64Type, + "credentials_id": types.StringType, "custom_tags": basetypes.MapType{ ElemType: types.StringType, }, - "deployment_name": types.StringType, - "external_customer_info": basetypes.ListType{ElemType: ExternalCustomerInfo{}.Type(ctx)}, - "gcp_managed_network_config": basetypes.ListType{ElemType: GcpManagedNetworkConfig{}.Type(ctx)}, - "gke_config": basetypes.ListType{ElemType: GkeConfig{}.Type(ctx)}, - "is_no_public_ip_enabled": types.BoolType, - "location": types.StringType, + "deployment_name": types.StringType, + "external_customer_info": basetypes.ListType{ + ElemType: ExternalCustomerInfo{}.Type(ctx), + }, + "gcp_managed_network_config": basetypes.ListType{ + ElemType: GcpManagedNetworkConfig{}.Type(ctx), + }, + "gke_config": basetypes.ListType{ + ElemType: GkeConfig{}.Type(ctx), + }, + "is_no_public_ip_enabled": types.BoolType, + "location": types.StringType, "managed_services_customer_managed_key_id": types.StringType, - "network_id": types.StringType, - "pricing_tier": types.StringType, - "private_access_settings_id": types.StringType, - "storage_configuration_id": types.StringType, - "storage_customer_managed_key_id": types.StringType, - "workspace_id": types.Int64Type, - "workspace_name": types.StringType, - "workspace_status": types.StringType, - "workspace_status_message": types.StringType, + "network_id": types.StringType, + "pricing_tier": types.StringType, + "private_access_settings_id": types.StringType, + "storage_configuration_id": types.StringType, + "storage_customer_managed_key_id": types.StringType, + "workspace_id": types.Int64Type, + "workspace_name": types.StringType, + "workspace_status": types.StringType, + "workspace_status_message": types.StringType, }, } } diff --git a/internal/service/serving_tf/model.go b/internal/service/serving_tf/model.go index f20aaf7c00..0a1d00c0c5 100755 --- a/internal/service/serving_tf/model.go +++ b/internal/service/serving_tf/model.go @@ -130,12 +130,18 @@ func (o AiGatewayConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o AiGatewayConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, - "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, + "guardrails": basetypes.ListType{ + ElemType: AiGatewayGuardrails{}.Type(ctx), + }, + "inference_table_config": basetypes.ListType{ + ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), + }, "rate_limits": basetypes.ListType{ ElemType: AiGatewayRateLimit{}.Type(ctx), }, - "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, + "usage_tracking_config": basetypes.ListType{ + ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), + }, }, } } @@ -299,7 +305,9 @@ func (o AiGatewayGuardrailParameters) Type(ctx context.Context) attr.Type { "invalid_keywords": basetypes.ListType{ ElemType: types.StringType, }, - "pii": basetypes.ListType{ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx)}, + "pii": basetypes.ListType{ + ElemType: AiGatewayGuardrailPiiBehavior{}.Type(ctx), + }, "safety": types.BoolType, "valid_topics": basetypes.ListType{ ElemType: types.StringType, @@ -476,8 +484,12 @@ func (o AiGatewayGuardrails) ToObjectValue(ctx context.Context) basetypes.Object func (o AiGatewayGuardrails) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "input": basetypes.ListType{ElemType: AiGatewayGuardrailParameters{}.Type(ctx)}, - "output": basetypes.ListType{ElemType: AiGatewayGuardrailParameters{}.Type(ctx)}, + "input": basetypes.ListType{ + ElemType: AiGatewayGuardrailParameters{}.Type(ctx), + }, + "output": basetypes.ListType{ + ElemType: AiGatewayGuardrailParameters{}.Type(ctx), + }, }, } } @@ -929,10 +941,12 @@ func (o AutoCaptureConfigOutput) ToObjectValue(ctx context.Context) basetypes.Ob func (o AutoCaptureConfigOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "catalog_name": types.StringType, - "enabled": types.BoolType, - "schema_name": types.StringType, - "state": basetypes.ListType{ElemType: AutoCaptureState{}.Type(ctx)}, + "catalog_name": types.StringType, + "enabled": types.BoolType, + "schema_name": types.StringType, + "state": basetypes.ListType{ + ElemType: AutoCaptureState{}.Type(ctx), + }, "table_name_prefix": types.StringType, }, } @@ -1002,7 +1016,9 @@ func (o AutoCaptureState) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o AutoCaptureState) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "payload_table": basetypes.ListType{ElemType: PayloadTable{}.Type(ctx)}, + "payload_table": basetypes.ListType{ + ElemType: PayloadTable{}.Type(ctx), + }, }, } } @@ -1289,9 +1305,13 @@ func (o CreateServingEndpoint) ToObjectValue(ctx context.Context) basetypes.Obje func (o CreateServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, - "config": basetypes.ListType{ElemType: EndpointCoreConfigInput{}.Type(ctx)}, - "name": types.StringType, + "ai_gateway": basetypes.ListType{ + ElemType: AiGatewayConfig{}.Type(ctx), + }, + "config": basetypes.ListType{ + ElemType: EndpointCoreConfigInput{}.Type(ctx), + }, + "name": types.StringType, "rate_limits": basetypes.ListType{ ElemType: RateLimit{}.Type(ctx), }, @@ -1821,15 +1841,19 @@ func (o EndpointCoreConfigInput) ToObjectValue(ctx context.Context) basetypes.Ob func (o EndpointCoreConfigInput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigInput{}.Type(ctx)}, - "name": types.StringType, + "auto_capture_config": basetypes.ListType{ + ElemType: AutoCaptureConfigInput{}.Type(ctx), + }, + "name": types.StringType, "served_entities": basetypes.ListType{ ElemType: ServedEntityInput{}.Type(ctx), }, "served_models": basetypes.ListType{ ElemType: ServedModelInput{}.Type(ctx), }, - "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, + "traffic_config": basetypes.ListType{ + ElemType: TrafficConfig{}.Type(ctx), + }, }, } } @@ -1994,15 +2018,19 @@ func (o EndpointCoreConfigOutput) ToObjectValue(ctx context.Context) basetypes.O func (o EndpointCoreConfigOutput) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, - "config_version": types.Int64Type, + "auto_capture_config": basetypes.ListType{ + ElemType: AutoCaptureConfigOutput{}.Type(ctx), + }, + "config_version": types.Int64Type, "served_entities": basetypes.ListType{ ElemType: ServedEntityOutput{}.Type(ctx), }, "served_models": basetypes.ListType{ ElemType: ServedModelOutput{}.Type(ctx), }, - "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, + "traffic_config": basetypes.ListType{ + ElemType: TrafficConfig{}.Type(ctx), + }, }, } } @@ -2278,16 +2306,20 @@ func (o EndpointPendingConfig) ToObjectValue(ctx context.Context) basetypes.Obje func (o EndpointPendingConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_capture_config": basetypes.ListType{ElemType: AutoCaptureConfigOutput{}.Type(ctx)}, - "config_version": types.Int64Type, + "auto_capture_config": basetypes.ListType{ + ElemType: AutoCaptureConfigOutput{}.Type(ctx), + }, + "config_version": types.Int64Type, "served_entities": basetypes.ListType{ ElemType: ServedEntityOutput{}.Type(ctx), }, "served_models": basetypes.ListType{ ElemType: ServedModelOutput{}.Type(ctx), }, - "start_time": types.Int64Type, - "traffic_config": basetypes.ListType{ElemType: TrafficConfig{}.Type(ctx)}, + "start_time": types.Int64Type, + "traffic_config": basetypes.ListType{ + ElemType: TrafficConfig{}.Type(ctx), + }, }, } } @@ -2661,17 +2693,33 @@ func (o ExternalModel) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o ExternalModel) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai21labs_config": basetypes.ListType{ElemType: Ai21LabsConfig{}.Type(ctx)}, - "amazon_bedrock_config": basetypes.ListType{ElemType: AmazonBedrockConfig{}.Type(ctx)}, - "anthropic_config": basetypes.ListType{ElemType: AnthropicConfig{}.Type(ctx)}, - "cohere_config": basetypes.ListType{ElemType: CohereConfig{}.Type(ctx)}, - "databricks_model_serving_config": basetypes.ListType{ElemType: DatabricksModelServingConfig{}.Type(ctx)}, - "google_cloud_vertex_ai_config": basetypes.ListType{ElemType: GoogleCloudVertexAiConfig{}.Type(ctx)}, - "name": types.StringType, - "openai_config": basetypes.ListType{ElemType: OpenAiConfig{}.Type(ctx)}, - "palm_config": basetypes.ListType{ElemType: PaLmConfig{}.Type(ctx)}, - "provider": types.StringType, - "task": types.StringType, + "ai21labs_config": basetypes.ListType{ + ElemType: Ai21LabsConfig{}.Type(ctx), + }, + "amazon_bedrock_config": basetypes.ListType{ + ElemType: AmazonBedrockConfig{}.Type(ctx), + }, + "anthropic_config": basetypes.ListType{ + ElemType: AnthropicConfig{}.Type(ctx), + }, + "cohere_config": basetypes.ListType{ + ElemType: CohereConfig{}.Type(ctx), + }, + "databricks_model_serving_config": basetypes.ListType{ + ElemType: DatabricksModelServingConfig{}.Type(ctx), + }, + "google_cloud_vertex_ai_config": basetypes.ListType{ + ElemType: GoogleCloudVertexAiConfig{}.Type(ctx), + }, + "name": types.StringType, + "openai_config": basetypes.ListType{ + ElemType: OpenAiConfig{}.Type(ctx), + }, + "palm_config": basetypes.ListType{ + ElemType: PaLmConfig{}.Type(ctx), + }, + "provider": types.StringType, + "task": types.StringType, }, } } @@ -3504,7 +3552,9 @@ func (o ModelDataPlaneInfo) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o ModelDataPlaneInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query_info": basetypes.ListType{ElemType: oauth2_tf.DataPlaneInfo{}.Type(ctx)}, + "query_info": basetypes.ListType{ + ElemType: oauth2_tf.DataPlaneInfo{}.Type(ctx), + }, }, } } @@ -3919,13 +3969,19 @@ func (o PutAiGatewayRequest) ToObjectValue(ctx context.Context) basetypes.Object func (o PutAiGatewayRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, - "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, - "name": types.StringType, + "guardrails": basetypes.ListType{ + ElemType: AiGatewayGuardrails{}.Type(ctx), + }, + "inference_table_config": basetypes.ListType{ + ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), + }, + "name": types.StringType, "rate_limits": basetypes.ListType{ ElemType: AiGatewayRateLimit{}.Type(ctx), }, - "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, + "usage_tracking_config": basetypes.ListType{ + ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), + }, }, } } @@ -4090,12 +4146,18 @@ func (o PutAiGatewayResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o PutAiGatewayResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "guardrails": basetypes.ListType{ElemType: AiGatewayGuardrails{}.Type(ctx)}, - "inference_table_config": basetypes.ListType{ElemType: AiGatewayInferenceTableConfig{}.Type(ctx)}, + "guardrails": basetypes.ListType{ + ElemType: AiGatewayGuardrails{}.Type(ctx), + }, + "inference_table_config": basetypes.ListType{ + ElemType: AiGatewayInferenceTableConfig{}.Type(ctx), + }, "rate_limits": basetypes.ListType{ ElemType: AiGatewayRateLimit{}.Type(ctx), }, - "usage_tracking_config": basetypes.ListType{ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx)}, + "usage_tracking_config": basetypes.ListType{ + ElemType: AiGatewayUsageTrackingConfig{}.Type(ctx), + }, }, } } @@ -4461,7 +4523,9 @@ func (o QueryEndpointInput) Type(ctx context.Context) attr.Type { "dataframe_records": basetypes.ListType{ ElemType: types.ObjectType{}, }, - "dataframe_split": basetypes.ListType{ElemType: DataframeSplitInput{}.Type(ctx)}, + "dataframe_split": basetypes.ListType{ + ElemType: DataframeSplitInput{}.Type(ctx), + }, "extra_params": basetypes.MapType{ ElemType: types.StringType, }, @@ -4732,7 +4796,9 @@ func (o QueryEndpointResponse) Type(ctx context.Context) attr.Type { ElemType: types.ObjectType{}, }, "served-model-name": types.StringType, - "usage": basetypes.ListType{ElemType: ExternalModelUsageElement{}.Type(ctx)}, + "usage": basetypes.ListType{ + ElemType: ExternalModelUsageElement{}.Type(ctx), + }, }, } } @@ -5053,7 +5119,9 @@ func (o ServedEntityInput) Type(ctx context.Context) attr.Type { "environment_vars": basetypes.MapType{ ElemType: types.StringType, }, - "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, + "external_model": basetypes.ListType{ + ElemType: ExternalModel{}.Type(ctx), + }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, "min_provisioned_throughput": types.Int64Type, @@ -5238,16 +5306,22 @@ func (o ServedEntityOutput) Type(ctx context.Context) attr.Type { "environment_vars": basetypes.MapType{ ElemType: types.StringType, }, - "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, - "foundation_model": basetypes.ListType{ElemType: FoundationModel{}.Type(ctx)}, + "external_model": basetypes.ListType{ + ElemType: ExternalModel{}.Type(ctx), + }, + "foundation_model": basetypes.ListType{ + ElemType: FoundationModel{}.Type(ctx), + }, "instance_profile_arn": types.StringType, "max_provisioned_throughput": types.Int64Type, "min_provisioned_throughput": types.Int64Type, "name": types.StringType, "scale_to_zero_enabled": types.BoolType, - "state": basetypes.ListType{ElemType: ServedModelState{}.Type(ctx)}, - "workload_size": types.StringType, - "workload_type": types.StringType, + "state": basetypes.ListType{ + ElemType: ServedModelState{}.Type(ctx), + }, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -5417,11 +5491,15 @@ func (o ServedEntitySpec) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o ServedEntitySpec) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "entity_name": types.StringType, - "entity_version": types.StringType, - "external_model": basetypes.ListType{ElemType: ExternalModel{}.Type(ctx)}, - "foundation_model": basetypes.ListType{ElemType: FoundationModel{}.Type(ctx)}, - "name": types.StringType, + "entity_name": types.StringType, + "entity_version": types.StringType, + "external_model": basetypes.ListType{ + ElemType: ExternalModel{}.Type(ctx), + }, + "foundation_model": basetypes.ListType{ + ElemType: FoundationModel{}.Type(ctx), + }, + "name": types.StringType, }, } } @@ -5712,9 +5790,11 @@ func (o ServedModelOutput) Type(ctx context.Context) attr.Type { "model_version": types.StringType, "name": types.StringType, "scale_to_zero_enabled": types.BoolType, - "state": basetypes.ListType{ElemType: ServedModelState{}.Type(ctx)}, - "workload_size": types.StringType, - "workload_type": types.StringType, + "state": basetypes.ListType{ + ElemType: ServedModelState{}.Type(ctx), + }, + "workload_size": types.StringType, + "workload_type": types.StringType, }, } } @@ -5994,14 +6074,20 @@ func (o ServingEndpoint) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o ServingEndpoint) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, - "config": basetypes.ListType{ElemType: EndpointCoreConfigSummary{}.Type(ctx)}, + "ai_gateway": basetypes.ListType{ + ElemType: AiGatewayConfig{}.Type(ctx), + }, + "config": basetypes.ListType{ + ElemType: EndpointCoreConfigSummary{}.Type(ctx), + }, "creation_timestamp": types.Int64Type, "creator": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "name": types.StringType, - "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, + "state": basetypes.ListType{ + ElemType: EndpointState{}.Type(ctx), + }, "tags": basetypes.ListType{ ElemType: EndpointTag{}.Type(ctx), }, @@ -6345,19 +6431,29 @@ func (o ServingEndpointDetailed) ToObjectValue(ctx context.Context) basetypes.Ob func (o ServingEndpointDetailed) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ai_gateway": basetypes.ListType{ElemType: AiGatewayConfig{}.Type(ctx)}, - "config": basetypes.ListType{ElemType: EndpointCoreConfigOutput{}.Type(ctx)}, - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "data_plane_info": basetypes.ListType{ElemType: ModelDataPlaneInfo{}.Type(ctx)}, + "ai_gateway": basetypes.ListType{ + ElemType: AiGatewayConfig{}.Type(ctx), + }, + "config": basetypes.ListType{ + ElemType: EndpointCoreConfigOutput{}.Type(ctx), + }, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "data_plane_info": basetypes.ListType{ + ElemType: ModelDataPlaneInfo{}.Type(ctx), + }, "endpoint_url": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, "name": types.StringType, - "pending_config": basetypes.ListType{ElemType: EndpointPendingConfig{}.Type(ctx)}, - "permission_level": types.StringType, - "route_optimized": types.BoolType, - "state": basetypes.ListType{ElemType: EndpointState{}.Type(ctx)}, + "pending_config": basetypes.ListType{ + ElemType: EndpointPendingConfig{}.Type(ctx), + }, + "permission_level": types.StringType, + "route_optimized": types.BoolType, + "state": basetypes.ListType{ + ElemType: EndpointState{}.Type(ctx), + }, "tags": basetypes.ListType{ ElemType: EndpointTag{}.Type(ctx), }, @@ -6926,8 +7022,10 @@ func (o V1ResponseChoiceElement) Type(ctx context.Context) attr.Type { "finishReason": types.StringType, "index": types.Int64Type, "logprobs": types.Int64Type, - "message": basetypes.ListType{ElemType: ChatMessage{}.Type(ctx)}, - "text": types.StringType, + "message": basetypes.ListType{ + ElemType: ChatMessage{}.Type(ctx), + }, + "text": types.StringType, }, } } diff --git a/internal/service/settings_tf/model.go b/internal/service/settings_tf/model.go index 75f73fb161..bc3f2a8f12 100755 --- a/internal/service/settings_tf/model.go +++ b/internal/service/settings_tf/model.go @@ -116,9 +116,11 @@ func (o AibiDashboardEmbeddingAccessPolicySetting) ToObjectValue(ctx context.Con func (o AibiDashboardEmbeddingAccessPolicySetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aibi_dashboard_embedding_access_policy": basetypes.ListType{ElemType: AibiDashboardEmbeddingAccessPolicy{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "aibi_dashboard_embedding_access_policy": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingAccessPolicy{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -274,7 +276,9 @@ func (o AibiDashboardEmbeddingApprovedDomainsSetting) ToObjectValue(ctx context. func (o AibiDashboardEmbeddingApprovedDomainsSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ElemType: AibiDashboardEmbeddingApprovedDomains{}.Type(ctx)}, + "aibi_dashboard_embedding_approved_domains": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingApprovedDomains{}.Type(ctx), + }, "etag": types.StringType, "setting_name": types.StringType, }, @@ -361,9 +365,11 @@ func (o AutomaticClusterUpdateSetting) ToObjectValue(ctx context.Context) basety func (o AutomaticClusterUpdateSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "automatic_cluster_update_workspace": basetypes.ListType{ElemType: ClusterAutoRestartMessage{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "automatic_cluster_update_workspace": basetypes.ListType{ + ElemType: ClusterAutoRestartMessage{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -491,10 +497,14 @@ func (o ClusterAutoRestartMessage) ToObjectValue(ctx context.Context) basetypes. func (o ClusterAutoRestartMessage) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "can_toggle": types.BoolType, - "enabled": types.BoolType, - "enablement_details": basetypes.ListType{ElemType: ClusterAutoRestartMessageEnablementDetails{}.Type(ctx)}, - "maintenance_window": basetypes.ListType{ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.Type(ctx)}, + "can_toggle": types.BoolType, + "enabled": types.BoolType, + "enablement_details": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageEnablementDetails{}.Type(ctx), + }, + "maintenance_window": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageMaintenanceWindow{}.Type(ctx), + }, "restart_even_if_no_updates_available": types.BoolType, }, } @@ -647,7 +657,9 @@ func (o ClusterAutoRestartMessageMaintenanceWindow) ToObjectValue(ctx context.Co func (o ClusterAutoRestartMessageMaintenanceWindow) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "week_day_based_schedule": basetypes.ListType{ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.Type(ctx)}, + "week_day_based_schedule": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule{}.Type(ctx), + }, }, } } @@ -722,9 +734,11 @@ func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) ToObject func (o ClusterAutoRestartMessageMaintenanceWindowWeekDayBasedSchedule) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "day_of_week": types.StringType, - "frequency": types.StringType, - "window_start_time": basetypes.ListType{ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.Type(ctx)}, + "day_of_week": types.StringType, + "frequency": types.StringType, + "window_start_time": basetypes.ListType{ + ElemType: ClusterAutoRestartMessageMaintenanceWindowWindowStartTime{}.Type(ctx), + }, }, } } @@ -932,9 +946,11 @@ func (o ComplianceSecurityProfileSetting) ToObjectValue(ctx context.Context) bas func (o ComplianceSecurityProfileSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "compliance_security_profile_workspace": basetypes.ListType{ElemType: ComplianceSecurityProfile{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "compliance_security_profile_workspace": basetypes.ListType{ + ElemType: ComplianceSecurityProfile{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1019,11 +1035,21 @@ func (o Config) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Config) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "email": basetypes.ListType{ElemType: EmailConfig{}.Type(ctx)}, - "generic_webhook": basetypes.ListType{ElemType: GenericWebhookConfig{}.Type(ctx)}, - "microsoft_teams": basetypes.ListType{ElemType: MicrosoftTeamsConfig{}.Type(ctx)}, - "pagerduty": basetypes.ListType{ElemType: PagerdutyConfig{}.Type(ctx)}, - "slack": basetypes.ListType{ElemType: SlackConfig{}.Type(ctx)}, + "email": basetypes.ListType{ + ElemType: EmailConfig{}.Type(ctx), + }, + "generic_webhook": basetypes.ListType{ + ElemType: GenericWebhookConfig{}.Type(ctx), + }, + "microsoft_teams": basetypes.ListType{ + ElemType: MicrosoftTeamsConfig{}.Type(ctx), + }, + "pagerduty": basetypes.ListType{ + ElemType: PagerdutyConfig{}.Type(ctx), + }, + "slack": basetypes.ListType{ + ElemType: SlackConfig{}.Type(ctx), + }, }, } } @@ -1283,7 +1309,9 @@ func (o CreateIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes func (o CreateIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.Type(ctx), + }, }, } } @@ -1408,7 +1436,9 @@ func (o CreateNotificationDestinationRequest) ToObjectValue(ctx context.Context) func (o CreateNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config": basetypes.ListType{ElemType: Config{}.Type(ctx)}, + "config": basetypes.ListType{ + ElemType: Config{}.Type(ctx), + }, "display_name": types.StringType, }, } @@ -1533,7 +1563,9 @@ func (o CreateOboTokenResponse) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateOboTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_info": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, + "token_info": basetypes.ListType{ + ElemType: TokenInfo{}.Type(ctx), + }, "token_value": types.StringType, }, } @@ -1707,7 +1739,9 @@ func (o CreateTokenResponse) ToObjectValue(ctx context.Context) basetypes.Object func (o CreateTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_info": basetypes.ListType{ElemType: PublicTokenInfo{}.Type(ctx)}, + "token_info": basetypes.ListType{ + ElemType: PublicTokenInfo{}.Type(ctx), + }, "token_value": types.StringType, }, } @@ -1872,9 +1906,11 @@ func (o CspEnablementAccountSetting) ToObjectValue(ctx context.Context) basetype func (o CspEnablementAccountSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "csp_enablement_account": basetypes.ListType{ElemType: CspEnablementAccount{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "csp_enablement_account": basetypes.ListType{ + ElemType: CspEnablementAccount{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -1969,8 +2005,10 @@ func (o DefaultNamespaceSetting) ToObjectValue(ctx context.Context) basetypes.Ob func (o DefaultNamespaceSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "namespace": basetypes.ListType{ElemType: StringMessage{}.Type(ctx)}, + "etag": types.StringType, + "namespace": basetypes.ListType{ + ElemType: StringMessage{}.Type(ctx), + }, "setting_name": types.StringType, }, } @@ -3173,9 +3211,11 @@ func (o DisableLegacyAccess) ToObjectValue(ctx context.Context) basetypes.Object func (o DisableLegacyAccess) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "disable_legacy_access": basetypes.ListType{ElemType: BooleanMessage{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "disable_legacy_access": basetypes.ListType{ + ElemType: BooleanMessage{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -3260,9 +3300,11 @@ func (o DisableLegacyDbfs) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o DisableLegacyDbfs) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "disable_legacy_dbfs": basetypes.ListType{ElemType: BooleanMessage{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "disable_legacy_dbfs": basetypes.ListType{ + ElemType: BooleanMessage{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -3347,9 +3389,11 @@ func (o DisableLegacyFeatures) ToObjectValue(ctx context.Context) basetypes.Obje func (o DisableLegacyFeatures) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "disable_legacy_features": basetypes.ListType{ElemType: BooleanMessage{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "disable_legacy_features": basetypes.ListType{ + ElemType: BooleanMessage{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -3423,7 +3467,9 @@ func (o EgressNetworkPolicy) ToObjectValue(ctx context.Context) basetypes.Object func (o EgressNetworkPolicy) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "internet_access": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicy{}.Type(ctx)}, + "internet_access": basetypes.ListType{ + ElemType: EgressNetworkPolicyInternetAccessPolicy{}.Type(ctx), + }, }, } } @@ -3515,7 +3561,9 @@ func (o EgressNetworkPolicyInternetAccessPolicy) Type(ctx context.Context) attr. "allowed_storage_destinations": basetypes.ListType{ ElemType: EgressNetworkPolicyInternetAccessPolicyStorageDestination{}.Type(ctx), }, - "log_only_mode": basetypes.ListType{ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx)}, + "log_only_mode": basetypes.ListType{ + ElemType: EgressNetworkPolicyInternetAccessPolicyLogOnlyMode{}.Type(ctx), + }, "restriction_mode": types.StringType, }, } @@ -4035,9 +4083,11 @@ func (o EnhancedSecurityMonitoringSetting) ToObjectValue(ctx context.Context) ba func (o EnhancedSecurityMonitoringSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "enhanced_security_monitoring_workspace": basetypes.ListType{ElemType: EnhancedSecurityMonitoring{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "enhanced_security_monitoring_workspace": basetypes.ListType{ + ElemType: EnhancedSecurityMonitoring{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -4165,9 +4215,11 @@ func (o EsmEnablementAccountSetting) ToObjectValue(ctx context.Context) basetype func (o EsmEnablementAccountSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "esm_enablement_account": basetypes.ListType{ElemType: EsmEnablementAccount{}.Type(ctx)}, - "etag": types.StringType, - "setting_name": types.StringType, + "esm_enablement_account": basetypes.ListType{ + ElemType: EsmEnablementAccount{}.Type(ctx), + }, + "etag": types.StringType, + "setting_name": types.StringType, }, } } @@ -4336,7 +4388,9 @@ func (o ExchangeTokenRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o ExchangeTokenRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "partitionId": basetypes.ListType{ElemType: PartitionId{}.Type(ctx)}, + "partitionId": basetypes.ListType{ + ElemType: PartitionId{}.Type(ctx), + }, "scopes": basetypes.ListType{ ElemType: types.StringType, }, @@ -4537,7 +4591,9 @@ func (o FetchIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes. func (o FetchIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.Type(ctx), + }, }, } } @@ -5294,7 +5350,9 @@ func (o GetIpAccessListResponse) ToObjectValue(ctx context.Context) basetypes.Ob func (o GetIpAccessListResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "ip_access_list": basetypes.ListType{ElemType: IpAccessListInfo{}.Type(ctx)}, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessListInfo{}.Type(ctx), + }, }, } } @@ -5823,7 +5881,9 @@ func (o GetTokenResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o GetTokenResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "token_info": basetypes.ListType{ElemType: TokenInfo{}.Type(ctx)}, + "token_info": basetypes.ListType{ + ElemType: TokenInfo{}.Type(ctx), + }, }, } } @@ -7022,8 +7082,12 @@ func (o NccEgressConfig) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o NccEgressConfig) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "default_rules": basetypes.ListType{ElemType: NccEgressDefaultRules{}.Type(ctx)}, - "target_rules": basetypes.ListType{ElemType: NccEgressTargetRules{}.Type(ctx)}, + "default_rules": basetypes.ListType{ + ElemType: NccEgressDefaultRules{}.Type(ctx), + }, + "target_rules": basetypes.ListType{ + ElemType: NccEgressTargetRules{}.Type(ctx), + }, }, } } @@ -7130,8 +7194,12 @@ func (o NccEgressDefaultRules) ToObjectValue(ctx context.Context) basetypes.Obje func (o NccEgressDefaultRules) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "aws_stable_ip_rule": basetypes.ListType{ElemType: NccAwsStableIpRule{}.Type(ctx)}, - "azure_service_endpoint_rule": basetypes.ListType{ElemType: NccAzureServiceEndpointRule{}.Type(ctx)}, + "aws_stable_ip_rule": basetypes.ListType{ + ElemType: NccAwsStableIpRule{}.Type(ctx), + }, + "azure_service_endpoint_rule": basetypes.ListType{ + ElemType: NccAzureServiceEndpointRule{}.Type(ctx), + }, }, } } @@ -7324,9 +7392,11 @@ func (o NetworkConnectivityConfiguration) ToObjectValue(ctx context.Context) bas func (o NetworkConnectivityConfiguration) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "account_id": types.StringType, - "creation_time": types.Int64Type, - "egress_config": basetypes.ListType{ElemType: NccEgressConfig{}.Type(ctx)}, + "account_id": types.StringType, + "creation_time": types.Int64Type, + "egress_config": basetypes.ListType{ + ElemType: NccEgressConfig{}.Type(ctx), + }, "name": types.StringType, "network_connectivity_config_id": types.StringType, "region": types.StringType, @@ -7412,7 +7482,9 @@ func (o NotificationDestination) ToObjectValue(ctx context.Context) basetypes.Ob func (o NotificationDestination) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config": basetypes.ListType{ElemType: Config{}.Type(ctx)}, + "config": basetypes.ListType{ + ElemType: Config{}.Type(ctx), + }, "destination_type": types.StringType, "display_name": types.StringType, "id": types.StringType, @@ -7638,9 +7710,11 @@ func (o PersonalComputeSetting) ToObjectValue(ctx context.Context) basetypes.Obj func (o PersonalComputeSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "personal_compute": basetypes.ListType{ElemType: PersonalComputeMessage{}.Type(ctx)}, - "setting_name": types.StringType, + "etag": types.StringType, + "personal_compute": basetypes.ListType{ + ElemType: PersonalComputeMessage{}.Type(ctx), + }, + "setting_name": types.StringType, }, } } @@ -7952,9 +8026,11 @@ func (o RestrictWorkspaceAdminsSetting) ToObjectValue(ctx context.Context) baset func (o RestrictWorkspaceAdminsSetting) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "etag": types.StringType, - "restrict_workspace_admins": basetypes.ListType{ElemType: RestrictWorkspaceAdminsMessage{}.Type(ctx)}, - "setting_name": types.StringType, + "etag": types.StringType, + "restrict_workspace_admins": basetypes.ListType{ + ElemType: RestrictWorkspaceAdminsMessage{}.Type(ctx), + }, + "setting_name": types.StringType, }, } } @@ -8731,7 +8807,9 @@ func (o UpdateAibiDashboardEmbeddingAccessPolicySettingRequest) Type(ctx context AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingAccessPolicySetting{}.Type(ctx), + }, }, } } @@ -8814,7 +8892,9 @@ func (o UpdateAibiDashboardEmbeddingApprovedDomainsSettingRequest) Type(ctx cont AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: AibiDashboardEmbeddingApprovedDomainsSetting{}.Type(ctx), + }, }, } } @@ -8897,7 +8977,9 @@ func (o UpdateAutomaticClusterUpdateSettingRequest) Type(ctx context.Context) at AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: AutomaticClusterUpdateSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: AutomaticClusterUpdateSetting{}.Type(ctx), + }, }, } } @@ -8980,7 +9062,9 @@ func (o UpdateComplianceSecurityProfileSettingRequest) Type(ctx context.Context) AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: ComplianceSecurityProfileSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: ComplianceSecurityProfileSetting{}.Type(ctx), + }, }, } } @@ -9063,7 +9147,9 @@ func (o UpdateCspEnablementAccountSettingRequest) Type(ctx context.Context) attr AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: CspEnablementAccountSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: CspEnablementAccountSetting{}.Type(ctx), + }, }, } } @@ -9154,7 +9240,9 @@ func (o UpdateDefaultNamespaceSettingRequest) Type(ctx context.Context) attr.Typ AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: DefaultNamespaceSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: DefaultNamespaceSetting{}.Type(ctx), + }, }, } } @@ -9237,7 +9325,9 @@ func (o UpdateDisableLegacyAccessRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: DisableLegacyAccess{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: DisableLegacyAccess{}.Type(ctx), + }, }, } } @@ -9320,7 +9410,9 @@ func (o UpdateDisableLegacyDbfsRequest) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: DisableLegacyDbfs{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: DisableLegacyDbfs{}.Type(ctx), + }, }, } } @@ -9403,7 +9495,9 @@ func (o UpdateDisableLegacyFeaturesRequest) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: DisableLegacyFeatures{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: DisableLegacyFeatures{}.Type(ctx), + }, }, } } @@ -9486,7 +9580,9 @@ func (o UpdateEnhancedSecurityMonitoringSettingRequest) Type(ctx context.Context AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: EnhancedSecurityMonitoringSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: EnhancedSecurityMonitoringSetting{}.Type(ctx), + }, }, } } @@ -9569,7 +9665,9 @@ func (o UpdateEsmEnablementAccountSettingRequest) Type(ctx context.Context) attr AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: EsmEnablementAccountSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: EsmEnablementAccountSetting{}.Type(ctx), + }, }, } } @@ -9740,7 +9838,9 @@ func (o UpdateNotificationDestinationRequest) ToObjectValue(ctx context.Context) func (o UpdateNotificationDestinationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "config": basetypes.ListType{ElemType: Config{}.Type(ctx)}, + "config": basetypes.ListType{ + ElemType: Config{}.Type(ctx), + }, "display_name": types.StringType, "id": types.StringType, }, @@ -9825,7 +9925,9 @@ func (o UpdatePersonalComputeSettingRequest) Type(ctx context.Context) attr.Type AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: PersonalComputeSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: PersonalComputeSetting{}.Type(ctx), + }, }, } } @@ -9944,7 +10046,9 @@ func (o UpdateRestrictWorkspaceAdminsSettingRequest) Type(ctx context.Context) a AttrTypes: map[string]attr.Type{ "allow_missing": types.BoolType, "field_mask": types.StringType, - "setting": basetypes.ListType{ElemType: RestrictWorkspaceAdminsSetting{}.Type(ctx)}, + "setting": basetypes.ListType{ + ElemType: RestrictWorkspaceAdminsSetting{}.Type(ctx), + }, }, } } diff --git a/internal/service/sharing_tf/model.go b/internal/service/sharing_tf/model.go index a15a6e55c8..9b7d073b34 100755 --- a/internal/service/sharing_tf/model.go +++ b/internal/service/sharing_tf/model.go @@ -149,11 +149,15 @@ func (o CreateRecipient) Type(ctx context.Context) attr.Type { "comment": types.StringType, "data_recipient_global_metastore_id": types.StringType, "expiration_time": types.Int64Type, - "ip_access_list": basetypes.ListType{ElemType: IpAccessList{}.Type(ctx)}, - "name": types.StringType, - "owner": types.StringType, - "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, - "sharing_code": types.StringType, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessList{}.Type(ctx), + }, + "name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ + ElemType: SecurablePropertiesKvPairs{}.Type(ctx), + }, + "sharing_code": types.StringType, }, } } @@ -1650,11 +1654,13 @@ func (o ProviderInfo) Type(ctx context.Context) attr.Type { "metastore_id": types.StringType, "name": types.StringType, "owner": types.StringType, - "recipient_profile": basetypes.ListType{ElemType: RecipientProfile{}.Type(ctx)}, - "recipient_profile_str": types.StringType, - "region": types.StringType, - "updated_at": types.Int64Type, - "updated_by": types.StringType, + "recipient_profile": basetypes.ListType{ + ElemType: RecipientProfile{}.Type(ctx), + }, + "recipient_profile_str": types.StringType, + "region": types.StringType, + "updated_at": types.Int64Type, + "updated_by": types.StringType, }, } } @@ -1836,13 +1842,17 @@ func (o RecipientInfo) Type(ctx context.Context) attr.Type { "created_at": types.Int64Type, "created_by": types.StringType, "data_recipient_global_metastore_id": types.StringType, - "ip_access_list": basetypes.ListType{ElemType: IpAccessList{}.Type(ctx)}, - "metastore_id": types.StringType, - "name": types.StringType, - "owner": types.StringType, - "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, - "region": types.StringType, - "sharing_code": types.StringType, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessList{}.Type(ctx), + }, + "metastore_id": types.StringType, + "name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ + ElemType: SecurablePropertiesKvPairs{}.Type(ctx), + }, + "region": types.StringType, + "sharing_code": types.StringType, "tokens": basetypes.ListType{ ElemType: RecipientTokenInfo{}.Type(ctx), }, @@ -2729,8 +2739,10 @@ func (o SharedDataObjectUpdate) ToObjectValue(ctx context.Context) basetypes.Obj func (o SharedDataObjectUpdate) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "action": types.StringType, - "data_object": basetypes.ListType{ElemType: SharedDataObject{}.Type(ctx)}, + "action": types.StringType, + "data_object": basetypes.ListType{ + ElemType: SharedDataObject{}.Type(ctx), + }, }, } } @@ -2917,13 +2929,17 @@ func (o UpdateRecipient) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o UpdateRecipient) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "comment": types.StringType, - "expiration_time": types.Int64Type, - "ip_access_list": basetypes.ListType{ElemType: IpAccessList{}.Type(ctx)}, - "name": types.StringType, - "new_name": types.StringType, - "owner": types.StringType, - "properties_kvpairs": basetypes.ListType{ElemType: SecurablePropertiesKvPairs{}.Type(ctx)}, + "comment": types.StringType, + "expiration_time": types.Int64Type, + "ip_access_list": basetypes.ListType{ + ElemType: IpAccessList{}.Type(ctx), + }, + "name": types.StringType, + "new_name": types.StringType, + "owner": types.StringType, + "properties_kvpairs": basetypes.ListType{ + ElemType: SecurablePropertiesKvPairs{}.Type(ctx), + }, }, } } diff --git a/internal/service/sql_tf/model.go b/internal/service/sql_tf/model.go index e5ccf52c75..9fe1288aaf 100755 --- a/internal/service/sql_tf/model.go +++ b/internal/service/sql_tf/model.go @@ -165,7 +165,9 @@ func (o Alert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Alert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.Type(ctx), + }, "create_time": types.StringType, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -262,8 +264,12 @@ func (o AlertCondition) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "empty_result_state": types.StringType, "op": types.StringType, - "operand": basetypes.ListType{ElemType: AlertConditionOperand{}.Type(ctx)}, - "threshold": basetypes.ListType{ElemType: AlertConditionThreshold{}.Type(ctx)}, + "operand": basetypes.ListType{ + ElemType: AlertConditionOperand{}.Type(ctx), + }, + "threshold": basetypes.ListType{ + ElemType: AlertConditionThreshold{}.Type(ctx), + }, }, } } @@ -358,7 +364,9 @@ func (o AlertConditionOperand) ToObjectValue(ctx context.Context) basetypes.Obje func (o AlertConditionOperand) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "column": basetypes.ListType{ElemType: AlertOperandColumn{}.Type(ctx)}, + "column": basetypes.ListType{ + ElemType: AlertOperandColumn{}.Type(ctx), + }, }, } } @@ -427,7 +435,9 @@ func (o AlertConditionThreshold) ToObjectValue(ctx context.Context) basetypes.Ob func (o AlertConditionThreshold) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "value": basetypes.ListType{ElemType: AlertOperandValue{}.Type(ctx)}, + "value": basetypes.ListType{ + ElemType: AlertOperandValue{}.Type(ctx), + }, }, } } @@ -722,8 +732,10 @@ func (o AlertQuery) Type(ctx context.Context) attr.Type { "is_draft": types.BoolType, "is_safe": types.BoolType, "name": types.StringType, - "options": basetypes.ListType{ElemType: QueryOptions{}.Type(ctx)}, - "query": types.StringType, + "options": basetypes.ListType{ + ElemType: QueryOptions{}.Type(ctx), + }, + "query": types.StringType, "tags": basetypes.ListType{ ElemType: types.StringType, }, @@ -1139,8 +1151,10 @@ func (o CreateAlert) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "name": types.StringType, - "options": basetypes.ListType{ElemType: AlertOptions{}.Type(ctx)}, + "name": types.StringType, + "options": basetypes.ListType{ + ElemType: AlertOptions{}.Type(ctx), + }, "parent": types.StringType, "query_id": types.StringType, "rearm": types.Int64Type, @@ -1212,7 +1226,9 @@ func (o CreateAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ElemType: CreateAlertRequestAlert{}.Type(ctx)}, + "alert": basetypes.ListType{ + ElemType: CreateAlertRequestAlert{}.Type(ctx), + }, }, } } @@ -1312,7 +1328,9 @@ func (o CreateAlertRequestAlert) ToObjectValue(ctx context.Context) basetypes.Ob func (o CreateAlertRequestAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.Type(ctx), + }, "custom_body": types.StringType, "custom_subject": types.StringType, "display_name": types.StringType, @@ -1388,7 +1406,9 @@ func (o CreateQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query": basetypes.ListType{ElemType: CreateQueryRequestQuery{}.Type(ctx)}, + "query": basetypes.ListType{ + ElemType: CreateQueryRequestQuery{}.Type(ctx), + }, }, } } @@ -1663,7 +1683,9 @@ func (o CreateVisualizationRequest) ToObjectValue(ctx context.Context) basetypes func (o CreateVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "visualization": basetypes.ListType{ElemType: CreateVisualizationRequestVisualization{}.Type(ctx)}, + "visualization": basetypes.ListType{ + ElemType: CreateVisualizationRequestVisualization{}.Type(ctx), + }, }, } } @@ -1867,8 +1889,10 @@ func (o CreateWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.Obj func (o CreateWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.Type(ctx), + }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, @@ -1878,8 +1902,10 @@ func (o CreateWarehouseRequest) Type(ctx context.Context) attr.Type { "min_num_clusters": types.Int64Type, "name": types.StringType, "spot_instance_policy": types.StringType, - "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, - "warehouse_type": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.Type(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -2034,9 +2060,11 @@ func (o CreateWidget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateWidget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "dashboard_id": types.StringType, - "id": types.StringType, - "options": basetypes.ListType{ElemType: WidgetOptions{}.Type(ctx)}, + "dashboard_id": types.StringType, + "id": types.StringType, + "options": basetypes.ListType{ + ElemType: WidgetOptions{}.Type(ctx), + }, "text": types.StringType, "visualization_id": types.StringType, "width": types.Int64Type, @@ -2180,16 +2208,20 @@ func (o Dashboard) Type(ctx context.Context) attr.Type { "is_draft": types.BoolType, "is_favorite": types.BoolType, "name": types.StringType, - "options": basetypes.ListType{ElemType: DashboardOptions{}.Type(ctx)}, - "parent": types.StringType, - "permission_tier": types.StringType, - "slug": types.StringType, + "options": basetypes.ListType{ + ElemType: DashboardOptions{}.Type(ctx), + }, + "parent": types.StringType, + "permission_tier": types.StringType, + "slug": types.StringType, "tags": basetypes.ListType{ ElemType: types.StringType, }, "updated_at": types.StringType, - "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, - "user_id": types.Int64Type, + "user": basetypes.ListType{ + ElemType: User{}.Type(ctx), + }, + "user_id": types.Int64Type, "widgets": basetypes.ListType{ ElemType: Widget{}.Type(ctx), }, @@ -2702,7 +2734,9 @@ func (o DateRangeValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o DateRangeValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "date_range_value": basetypes.ListType{ElemType: DateRange{}.Type(ctx)}, + "date_range_value": basetypes.ListType{ + ElemType: DateRange{}.Type(ctx), + }, "dynamic_date_range_value": types.StringType, "precision": types.StringType, "start_day_of_week": types.Int64Type, @@ -3210,7 +3244,9 @@ func (o EditAlert) Type(ctx context.Context) attr.Type { AttrTypes: map[string]attr.Type{ "alert_id": types.StringType, "name": types.StringType, - "options": basetypes.ListType{ElemType: AlertOptions{}.Type(ctx)}, + "options": basetypes.ListType{ + ElemType: AlertOptions{}.Type(ctx), + }, "query_id": types.StringType, "rearm": types.Int64Type, }, @@ -3355,8 +3391,10 @@ func (o EditWarehouseRequest) ToObjectValue(ctx context.Context) basetypes.Objec func (o EditWarehouseRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.Type(ctx), + }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, @@ -3367,8 +3405,10 @@ func (o EditWarehouseRequest) Type(ctx context.Context) attr.Type { "min_num_clusters": types.Int64Type, "name": types.StringType, "spot_instance_policy": types.StringType, - "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, - "warehouse_type": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.Type(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -3597,11 +3637,13 @@ func (o EndpointHealth) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o EndpointHealth) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "details": types.StringType, - "failure_reason": basetypes.ListType{ElemType: TerminationReason{}.Type(ctx)}, - "message": types.StringType, - "status": types.StringType, - "summary": types.StringType, + "details": types.StringType, + "failure_reason": basetypes.ListType{ + ElemType: TerminationReason{}.Type(ctx), + }, + "message": types.StringType, + "status": types.StringType, + "summary": types.StringType, }, } } @@ -3765,26 +3807,34 @@ func (o EndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.Type(ctx), + }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, - "health": basetypes.ListType{ElemType: EndpointHealth{}.Type(ctx)}, - "id": types.StringType, - "instance_profile_arn": types.StringType, - "jdbc_url": types.StringType, - "max_num_clusters": types.Int64Type, - "min_num_clusters": types.Int64Type, - "name": types.StringType, - "num_active_sessions": types.Int64Type, - "num_clusters": types.Int64Type, - "odbc_params": basetypes.ListType{ElemType: OdbcParams{}.Type(ctx)}, - "spot_instance_policy": types.StringType, - "state": types.StringType, - "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, - "warehouse_type": types.StringType, + "health": basetypes.ListType{ + ElemType: EndpointHealth{}.Type(ctx), + }, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "jdbc_url": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "num_active_sessions": types.Int64Type, + "num_clusters": types.Int64Type, + "odbc_params": basetypes.ListType{ + ElemType: OdbcParams{}.Type(ctx), + }, + "spot_instance_policy": types.StringType, + "state": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.Type(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -4055,8 +4105,10 @@ func (o EnumValue) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EnumValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "enum_options": types.StringType, - "multi_values_options": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, + "enum_options": types.StringType, + "multi_values_options": basetypes.ListType{ + ElemType: MultiValuesOptions{}.Type(ctx), + }, "values": basetypes.ListType{ ElemType: types.StringType, }, @@ -5206,26 +5258,34 @@ func (o GetWarehouseResponse) ToObjectValue(ctx context.Context) basetypes.Objec func (o GetWarehouseResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "auto_stop_mins": types.Int64Type, - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, + "auto_stop_mins": types.Int64Type, + "channel": basetypes.ListType{ + ElemType: Channel{}.Type(ctx), + }, "cluster_size": types.StringType, "creator_name": types.StringType, "enable_photon": types.BoolType, "enable_serverless_compute": types.BoolType, - "health": basetypes.ListType{ElemType: EndpointHealth{}.Type(ctx)}, - "id": types.StringType, - "instance_profile_arn": types.StringType, - "jdbc_url": types.StringType, - "max_num_clusters": types.Int64Type, - "min_num_clusters": types.Int64Type, - "name": types.StringType, - "num_active_sessions": types.Int64Type, - "num_clusters": types.Int64Type, - "odbc_params": basetypes.ListType{ElemType: OdbcParams{}.Type(ctx)}, - "spot_instance_policy": types.StringType, - "state": types.StringType, - "tags": basetypes.ListType{ElemType: EndpointTags{}.Type(ctx)}, - "warehouse_type": types.StringType, + "health": basetypes.ListType{ + ElemType: EndpointHealth{}.Type(ctx), + }, + "id": types.StringType, + "instance_profile_arn": types.StringType, + "jdbc_url": types.StringType, + "max_num_clusters": types.Int64Type, + "min_num_clusters": types.Int64Type, + "name": types.StringType, + "num_active_sessions": types.Int64Type, + "num_clusters": types.Int64Type, + "odbc_params": basetypes.ListType{ + ElemType: OdbcParams{}.Type(ctx), + }, + "spot_instance_policy": types.StringType, + "state": types.StringType, + "tags": basetypes.ListType{ + ElemType: EndpointTags{}.Type(ctx), + }, + "warehouse_type": types.StringType, }, } } @@ -5409,19 +5469,27 @@ func (o GetWorkspaceWarehouseConfigResponse) ToObjectValue(ctx context.Context) func (o GetWorkspaceWarehouseConfigResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, - "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "channel": basetypes.ListType{ + ElemType: Channel{}.Type(ctx), + }, + "config_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), + }, "data_access_config": basetypes.ListType{ ElemType: EndpointConfPair{}.Type(ctx), }, "enabled_warehouse_types": basetypes.ListType{ ElemType: WarehouseTypePair{}.Type(ctx), }, - "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "google_service_account": types.StringType, - "instance_profile_arn": types.StringType, - "security_policy": types.StringType, - "sql_configuration_parameters": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "global_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), + }, + "google_service_account": types.StringType, + "instance_profile_arn": types.StringType, + "security_policy": types.StringType, + "sql_configuration_parameters": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), + }, }, } } @@ -5661,13 +5729,19 @@ func (o LegacyAlert) Type(ctx context.Context) attr.Type { "id": types.StringType, "last_triggered_at": types.StringType, "name": types.StringType, - "options": basetypes.ListType{ElemType: AlertOptions{}.Type(ctx)}, - "parent": types.StringType, - "query": basetypes.ListType{ElemType: AlertQuery{}.Type(ctx)}, - "rearm": types.Int64Type, - "state": types.StringType, - "updated_at": types.StringType, - "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "options": basetypes.ListType{ + ElemType: AlertOptions{}.Type(ctx), + }, + "parent": types.StringType, + "query": basetypes.ListType{ + ElemType: AlertQuery{}.Type(ctx), + }, + "rearm": types.Int64Type, + "state": types.StringType, + "updated_at": types.StringType, + "user": basetypes.ListType{ + ElemType: User{}.Type(ctx), + }, }, } } @@ -5882,31 +5956,37 @@ func (o LegacyQuery) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o LegacyQuery) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "can_edit": types.BoolType, - "created_at": types.StringType, - "data_source_id": types.StringType, - "description": types.StringType, - "id": types.StringType, - "is_archived": types.BoolType, - "is_draft": types.BoolType, - "is_favorite": types.BoolType, - "is_safe": types.BoolType, - "last_modified_by": basetypes.ListType{ElemType: User{}.Type(ctx)}, + "can_edit": types.BoolType, + "created_at": types.StringType, + "data_source_id": types.StringType, + "description": types.StringType, + "id": types.StringType, + "is_archived": types.BoolType, + "is_draft": types.BoolType, + "is_favorite": types.BoolType, + "is_safe": types.BoolType, + "last_modified_by": basetypes.ListType{ + ElemType: User{}.Type(ctx), + }, "last_modified_by_id": types.Int64Type, "latest_query_data_id": types.StringType, "name": types.StringType, - "options": basetypes.ListType{ElemType: QueryOptions{}.Type(ctx)}, - "parent": types.StringType, - "permission_tier": types.StringType, - "query": types.StringType, - "query_hash": types.StringType, - "run_as_role": types.StringType, + "options": basetypes.ListType{ + ElemType: QueryOptions{}.Type(ctx), + }, + "parent": types.StringType, + "permission_tier": types.StringType, + "query": types.StringType, + "query_hash": types.StringType, + "run_as_role": types.StringType, "tags": basetypes.ListType{ ElemType: types.StringType, }, "updated_at": types.StringType, - "user": basetypes.ListType{ElemType: User{}.Type(ctx)}, - "user_id": types.Int64Type, + "user": basetypes.ListType{ + ElemType: User{}.Type(ctx), + }, + "user_id": types.Int64Type, "visualizations": basetypes.ListType{ ElemType: LegacyVisualization{}.Type(ctx), }, @@ -6117,9 +6197,11 @@ func (o LegacyVisualization) Type(ctx context.Context) attr.Type { "id": types.StringType, "name": types.StringType, "options": types.ObjectType{}, - "query": basetypes.ListType{ElemType: LegacyQuery{}.Type(ctx)}, - "type": types.StringType, - "updated_at": types.StringType, + "query": basetypes.ListType{ + ElemType: LegacyQuery{}.Type(ctx), + }, + "type": types.StringType, + "updated_at": types.StringType, }, } } @@ -6362,7 +6444,9 @@ func (o ListAlertsResponseAlert) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListAlertsResponseAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.Type(ctx), + }, "create_time": types.StringType, "custom_body": types.StringType, "custom_subject": types.StringType, @@ -6709,7 +6793,9 @@ func (o ListQueryHistoryRequest) ToObjectValue(ctx context.Context) basetypes.Ob func (o ListQueryHistoryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "filter_by": basetypes.ListType{ElemType: QueryFilter{}.Type(ctx)}, + "filter_by": basetypes.ListType{ + ElemType: QueryFilter{}.Type(ctx), + }, "include_metrics": types.BoolType, "max_results": types.Int64Type, "page_token": types.StringType, @@ -7512,13 +7598,15 @@ func (o Parameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Parameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "enumOptions": types.StringType, - "multiValuesOptions": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, - "name": types.StringType, - "queryId": types.StringType, - "title": types.StringType, - "type": types.StringType, - "value": types.ObjectType{}, + "enumOptions": types.StringType, + "multiValuesOptions": basetypes.ListType{ + ElemType: MultiValuesOptions{}.Type(ctx), + }, + "name": types.StringType, + "queryId": types.StringType, + "title": types.StringType, + "type": types.StringType, + "value": types.ObjectType{}, }, } } @@ -7762,8 +7850,10 @@ func (o QueryBackedValue) ToObjectValue(ctx context.Context) basetypes.ObjectVal func (o QueryBackedValue) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "multi_values_options": basetypes.ListType{ElemType: MultiValuesOptions{}.Type(ctx)}, - "query_id": types.StringType, + "multi_values_options": basetypes.ListType{ + ElemType: MultiValuesOptions{}.Type(ctx), + }, + "query_id": types.StringType, "values": basetypes.ListType{ ElemType: types.StringType, }, @@ -7988,7 +8078,9 @@ func (o QueryFilter) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QueryFilter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "query_start_time_range": basetypes.ListType{ElemType: TimeRange{}.Type(ctx)}, + "query_start_time_range": basetypes.ListType{ + ElemType: TimeRange{}.Type(ctx), + }, "statement_ids": basetypes.ListType{ ElemType: types.StringType, }, @@ -8243,7 +8335,9 @@ func (o QueryInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o QueryInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel_used": basetypes.ListType{ElemType: ChannelInfo{}.Type(ctx)}, + "channel_used": basetypes.ListType{ + ElemType: ChannelInfo{}.Type(ctx), + }, "duration": types.Int64Type, "endpoint_id": types.StringType, "error_message": types.StringType, @@ -8252,19 +8346,21 @@ func (o QueryInfo) Type(ctx context.Context) attr.Type { "execution_end_time_ms": types.Int64Type, "is_final": types.BoolType, "lookup_key": types.StringType, - "metrics": basetypes.ListType{ElemType: QueryMetrics{}.Type(ctx)}, - "plans_state": types.StringType, - "query_end_time_ms": types.Int64Type, - "query_id": types.StringType, - "query_start_time_ms": types.Int64Type, - "query_text": types.StringType, - "rows_produced": types.Int64Type, - "spark_ui_url": types.StringType, - "statement_type": types.StringType, - "status": types.StringType, - "user_id": types.Int64Type, - "user_name": types.StringType, - "warehouse_id": types.StringType, + "metrics": basetypes.ListType{ + ElemType: QueryMetrics{}.Type(ctx), + }, + "plans_state": types.StringType, + "query_end_time_ms": types.Int64Type, + "query_id": types.StringType, + "query_start_time_ms": types.Int64Type, + "query_text": types.StringType, + "rows_produced": types.Int64Type, + "spark_ui_url": types.StringType, + "statement_type": types.StringType, + "status": types.StringType, + "user_id": types.Int64Type, + "user_name": types.StringType, + "warehouse_id": types.StringType, }, } } @@ -8699,14 +8795,26 @@ func (o QueryParameter) ToObjectValue(ctx context.Context) basetypes.ObjectValue func (o QueryParameter) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "date_range_value": basetypes.ListType{ElemType: DateRangeValue{}.Type(ctx)}, - "date_value": basetypes.ListType{ElemType: DateValue{}.Type(ctx)}, - "enum_value": basetypes.ListType{ElemType: EnumValue{}.Type(ctx)}, - "name": types.StringType, - "numeric_value": basetypes.ListType{ElemType: NumericValue{}.Type(ctx)}, - "query_backed_value": basetypes.ListType{ElemType: QueryBackedValue{}.Type(ctx)}, - "text_value": basetypes.ListType{ElemType: TextValue{}.Type(ctx)}, - "title": types.StringType, + "date_range_value": basetypes.ListType{ + ElemType: DateRangeValue{}.Type(ctx), + }, + "date_value": basetypes.ListType{ + ElemType: DateValue{}.Type(ctx), + }, + "enum_value": basetypes.ListType{ + ElemType: EnumValue{}.Type(ctx), + }, + "name": types.StringType, + "numeric_value": basetypes.ListType{ + ElemType: NumericValue{}.Type(ctx), + }, + "query_backed_value": basetypes.ListType{ + ElemType: QueryBackedValue{}.Type(ctx), + }, + "text_value": basetypes.ListType{ + ElemType: TextValue{}.Type(ctx), + }, + "title": types.StringType, }, } } @@ -9404,8 +9512,10 @@ func (o ResultManifest) Type(ctx context.Context) attr.Type { "chunks": basetypes.ListType{ ElemType: BaseChunkInfo{}.Type(ctx), }, - "format": types.StringType, - "schema": basetypes.ListType{ElemType: ResultSchema{}.Type(ctx)}, + "format": types.StringType, + "schema": basetypes.ListType{ + ElemType: ResultSchema{}.Type(ctx), + }, "total_byte_count": types.Int64Type, "total_chunk_count": types.Int64Type, "total_row_count": types.Int64Type, @@ -9822,19 +9932,27 @@ func (o SetWorkspaceWarehouseConfigRequest) ToObjectValue(ctx context.Context) b func (o SetWorkspaceWarehouseConfigRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "channel": basetypes.ListType{ElemType: Channel{}.Type(ctx)}, - "config_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "channel": basetypes.ListType{ + ElemType: Channel{}.Type(ctx), + }, + "config_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), + }, "data_access_config": basetypes.ListType{ ElemType: EndpointConfPair{}.Type(ctx), }, "enabled_warehouse_types": basetypes.ListType{ ElemType: WarehouseTypePair{}.Type(ctx), }, - "global_param": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, - "google_service_account": types.StringType, - "instance_profile_arn": types.StringType, - "security_policy": types.StringType, - "sql_configuration_parameters": basetypes.ListType{ElemType: RepeatedEndpointConfPairs{}.Type(ctx)}, + "global_param": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), + }, + "google_service_account": types.StringType, + "instance_profile_arn": types.StringType, + "security_policy": types.StringType, + "sql_configuration_parameters": basetypes.ListType{ + ElemType: RepeatedEndpointConfPairs{}.Type(ctx), + }, }, } } @@ -10219,10 +10337,16 @@ func (o StatementResponse) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o StatementResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "manifest": basetypes.ListType{ElemType: ResultManifest{}.Type(ctx)}, - "result": basetypes.ListType{ElemType: ResultData{}.Type(ctx)}, + "manifest": basetypes.ListType{ + ElemType: ResultManifest{}.Type(ctx), + }, + "result": basetypes.ListType{ + ElemType: ResultData{}.Type(ctx), + }, "statement_id": types.StringType, - "status": basetypes.ListType{ElemType: StatementStatus{}.Type(ctx)}, + "status": basetypes.ListType{ + ElemType: StatementStatus{}.Type(ctx), + }, }, } } @@ -10354,7 +10478,9 @@ func (o StatementStatus) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o StatementStatus) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "error": basetypes.ListType{ElemType: ServiceError{}.Type(ctx)}, + "error": basetypes.ListType{ + ElemType: ServiceError{}.Type(ctx), + }, "state": types.StringType, }, } @@ -10762,8 +10888,10 @@ func (o TransferOwnershipRequest) ToObjectValue(ctx context.Context) basetypes.O func (o TransferOwnershipRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "new_owner": types.StringType, - "objectId": basetypes.ListType{ElemType: TransferOwnershipObjectId{}.Type(ctx)}, + "new_owner": types.StringType, + "objectId": basetypes.ListType{ + ElemType: TransferOwnershipObjectId{}.Type(ctx), + }, "objectType": types.StringType, }, } @@ -10926,7 +11054,9 @@ func (o UpdateAlertRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o UpdateAlertRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "alert": basetypes.ListType{ElemType: UpdateAlertRequestAlert{}.Type(ctx)}, + "alert": basetypes.ListType{ + ElemType: UpdateAlertRequestAlert{}.Type(ctx), + }, "id": types.StringType, "update_mask": types.StringType, }, @@ -11029,7 +11159,9 @@ func (o UpdateAlertRequestAlert) ToObjectValue(ctx context.Context) basetypes.Ob func (o UpdateAlertRequestAlert) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "condition": basetypes.ListType{ElemType: AlertCondition{}.Type(ctx)}, + "condition": basetypes.ListType{ + ElemType: AlertCondition{}.Type(ctx), + }, "custom_body": types.StringType, "custom_subject": types.StringType, "display_name": types.StringType, @@ -11114,8 +11246,10 @@ func (o UpdateQueryRequest) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o UpdateQueryRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "query": basetypes.ListType{ElemType: UpdateQueryRequestQuery{}.Type(ctx)}, + "id": types.StringType, + "query": basetypes.ListType{ + ElemType: UpdateQueryRequestQuery{}.Type(ctx), + }, "update_mask": types.StringType, }, } @@ -11373,9 +11507,11 @@ func (o UpdateVisualizationRequest) ToObjectValue(ctx context.Context) basetypes func (o UpdateVisualizationRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "update_mask": types.StringType, - "visualization": basetypes.ListType{ElemType: UpdateVisualizationRequestVisualization{}.Type(ctx)}, + "id": types.StringType, + "update_mask": types.StringType, + "visualization": basetypes.ListType{ + ElemType: UpdateVisualizationRequestVisualization{}.Type(ctx), + }, }, } } @@ -12107,10 +12243,14 @@ func (o Widget) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Widget) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "id": types.StringType, - "options": basetypes.ListType{ElemType: WidgetOptions{}.Type(ctx)}, - "visualization": basetypes.ListType{ElemType: LegacyVisualization{}.Type(ctx)}, - "width": types.Int64Type, + "id": types.StringType, + "options": basetypes.ListType{ + ElemType: WidgetOptions{}.Type(ctx), + }, + "visualization": basetypes.ListType{ + ElemType: LegacyVisualization{}.Type(ctx), + }, + "width": types.Int64Type, }, } } @@ -12231,9 +12371,11 @@ func (o WidgetOptions) Type(ctx context.Context) attr.Type { "description": types.StringType, "isHidden": types.BoolType, "parameterMappings": types.ObjectType{}, - "position": basetypes.ListType{ElemType: WidgetPosition{}.Type(ctx)}, - "title": types.StringType, - "updated_at": types.StringType, + "position": basetypes.ListType{ + ElemType: WidgetPosition{}.Type(ctx), + }, + "title": types.StringType, + "updated_at": types.StringType, }, } } diff --git a/internal/service/vectorsearch_tf/model.go b/internal/service/vectorsearch_tf/model.go index 27136ff7c5..e54058ff9a 100755 --- a/internal/service/vectorsearch_tf/model.go +++ b/internal/service/vectorsearch_tf/model.go @@ -172,12 +172,16 @@ func (o CreateVectorIndexRequest) ToObjectValue(ctx context.Context) basetypes.O func (o CreateVectorIndexRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "delta_sync_index_spec": basetypes.ListType{ElemType: DeltaSyncVectorIndexSpecRequest{}.Type(ctx)}, - "direct_access_index_spec": basetypes.ListType{ElemType: DirectAccessVectorIndexSpec{}.Type(ctx)}, - "endpoint_name": types.StringType, - "index_type": types.StringType, - "name": types.StringType, - "primary_key": types.StringType, + "delta_sync_index_spec": basetypes.ListType{ + ElemType: DeltaSyncVectorIndexSpecRequest{}.Type(ctx), + }, + "direct_access_index_spec": basetypes.ListType{ + ElemType: DirectAccessVectorIndexSpec{}.Type(ctx), + }, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, }, } } @@ -272,7 +276,9 @@ func (o CreateVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes. func (o CreateVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "vector_index": basetypes.ListType{ElemType: VectorIndex{}.Type(ctx)}, + "vector_index": basetypes.ListType{ + ElemType: VectorIndex{}.Type(ctx), + }, }, } } @@ -501,7 +507,9 @@ func (o DeleteDataVectorIndexResponse) ToObjectValue(ctx context.Context) basety func (o DeleteDataVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "result": basetypes.ListType{ElemType: DeleteDataResult{}.Type(ctx)}, + "result": basetypes.ListType{ + ElemType: DeleteDataResult{}.Type(ctx), + }, "status": types.StringType, }, } @@ -1252,9 +1260,11 @@ func (o EndpointInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o EndpointInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creation_timestamp": types.Int64Type, - "creator": types.StringType, - "endpoint_status": basetypes.ListType{ElemType: EndpointStatus{}.Type(ctx)}, + "creation_timestamp": types.Int64Type, + "creator": types.StringType, + "endpoint_status": basetypes.ListType{ + ElemType: EndpointStatus{}.Type(ctx), + }, "endpoint_type": types.StringType, "id": types.StringType, "last_updated_timestamp": types.Int64Type, @@ -1782,8 +1792,10 @@ func (o MapStringValueEntry) ToObjectValue(ctx context.Context) basetypes.Object func (o MapStringValueEntry) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "key": types.StringType, - "value": basetypes.ListType{ElemType: Value{}.Type(ctx)}, + "key": types.StringType, + "value": basetypes.ListType{ + ElemType: Value{}.Type(ctx), + }, }, } } @@ -2113,9 +2125,13 @@ func (o QueryVectorIndexResponse) ToObjectValue(ctx context.Context) basetypes.O func (o QueryVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "manifest": basetypes.ListType{ElemType: ResultManifest{}.Type(ctx)}, + "manifest": basetypes.ListType{ + ElemType: ResultManifest{}.Type(ctx), + }, "next_page_token": types.StringType, - "result": basetypes.ListType{ElemType: ResultData{}.Type(ctx)}, + "result": basetypes.ListType{ + ElemType: ResultData{}.Type(ctx), + }, }, } } @@ -2775,7 +2791,9 @@ func (o UpsertDataVectorIndexResponse) ToObjectValue(ctx context.Context) basety func (o UpsertDataVectorIndexResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "result": basetypes.ListType{ElemType: UpsertDataResult{}.Type(ctx)}, + "result": basetypes.ListType{ + ElemType: UpsertDataResult{}.Type(ctx), + }, "status": types.StringType, }, } @@ -2861,12 +2879,16 @@ func (o Value) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o Value) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "bool_value": types.BoolType, - "list_value": basetypes.ListType{ElemType: ListValue{}.Type(ctx)}, + "bool_value": types.BoolType, + "list_value": basetypes.ListType{ + ElemType: ListValue{}.Type(ctx), + }, "null_value": types.StringType, "number_value": types.Float64Type, "string_value": types.StringType, - "struct_value": basetypes.ListType{ElemType: Struct{}.Type(ctx)}, + "struct_value": basetypes.ListType{ + ElemType: Struct{}.Type(ctx), + }, }, } } @@ -2991,14 +3013,20 @@ func (o VectorIndex) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o VectorIndex) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "creator": types.StringType, - "delta_sync_index_spec": basetypes.ListType{ElemType: DeltaSyncVectorIndexSpecResponse{}.Type(ctx)}, - "direct_access_index_spec": basetypes.ListType{ElemType: DirectAccessVectorIndexSpec{}.Type(ctx)}, - "endpoint_name": types.StringType, - "index_type": types.StringType, - "name": types.StringType, - "primary_key": types.StringType, - "status": basetypes.ListType{ElemType: VectorIndexStatus{}.Type(ctx)}, + "creator": types.StringType, + "delta_sync_index_spec": basetypes.ListType{ + ElemType: DeltaSyncVectorIndexSpecResponse{}.Type(ctx), + }, + "direct_access_index_spec": basetypes.ListType{ + ElemType: DirectAccessVectorIndexSpec{}.Type(ctx), + }, + "endpoint_name": types.StringType, + "index_type": types.StringType, + "name": types.StringType, + "primary_key": types.StringType, + "status": basetypes.ListType{ + ElemType: VectorIndexStatus{}.Type(ctx), + }, }, } } diff --git a/internal/service/workspace_tf/model.go b/internal/service/workspace_tf/model.go index bea47f332a..ea6811069c 100755 --- a/internal/service/workspace_tf/model.go +++ b/internal/service/workspace_tf/model.go @@ -282,10 +282,12 @@ func (o CreateRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o CreateRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, - "url": types.StringType, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.Type(ctx), + }, + "url": types.StringType, }, } } @@ -374,13 +376,15 @@ func (o CreateRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectV func (o CreateRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "head_commit_id": types.StringType, - "id": types.Int64Type, - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, - "url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.Type(ctx), + }, + "url": types.StringType, }, } } @@ -461,7 +465,9 @@ func (o CreateScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o CreateScope) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "backend_azure_keyvault": basetypes.ListType{ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx)}, + "backend_azure_keyvault": basetypes.ListType{ + ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx), + }, "initial_manage_principal": types.StringType, "scope": types.StringType, "scope_backend_type": types.StringType, @@ -1574,13 +1580,15 @@ func (o GetRepoResponse) ToObjectValue(ctx context.Context) basetypes.ObjectValu func (o GetRepoResponse) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "head_commit_id": types.StringType, - "id": types.Int64Type, - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, - "url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.Type(ctx), + }, + "url": types.StringType, }, } } @@ -3180,13 +3188,15 @@ func (o RepoInfo) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o RepoInfo) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "head_commit_id": types.StringType, - "id": types.Int64Type, - "path": types.StringType, - "provider": types.StringType, - "sparse_checkout": basetypes.ListType{ElemType: SparseCheckout{}.Type(ctx)}, - "url": types.StringType, + "branch": types.StringType, + "head_commit_id": types.StringType, + "id": types.Int64Type, + "path": types.StringType, + "provider": types.StringType, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckout{}.Type(ctx), + }, + "url": types.StringType, }, } } @@ -3586,9 +3596,11 @@ func (o SecretScope) ToObjectValue(ctx context.Context) basetypes.ObjectValue { func (o SecretScope) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "backend_type": types.StringType, - "keyvault_metadata": basetypes.ListType{ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx)}, - "name": types.StringType, + "backend_type": types.StringType, + "keyvault_metadata": basetypes.ListType{ + ElemType: AzureKeyVaultSecretScopeMetadata{}.Type(ctx), + }, + "name": types.StringType, }, } } @@ -3926,10 +3938,12 @@ func (o UpdateRepoRequest) ToObjectValue(ctx context.Context) basetypes.ObjectVa func (o UpdateRepoRequest) Type(ctx context.Context) attr.Type { return types.ObjectType{ AttrTypes: map[string]attr.Type{ - "branch": types.StringType, - "repo_id": types.Int64Type, - "sparse_checkout": basetypes.ListType{ElemType: SparseCheckoutUpdate{}.Type(ctx)}, - "tag": types.StringType, + "branch": types.StringType, + "repo_id": types.Int64Type, + "sparse_checkout": basetypes.ListType{ + ElemType: SparseCheckoutUpdate{}.Type(ctx), + }, + "tag": types.StringType, }, } } From 8d42b08c3ee016690a31966ebc55c05df682eca0 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 10:39:45 +0100 Subject: [PATCH 77/91] less unnecessary diff --- .../pluginfw/tfschema/struct_to_schema.go | 207 +++++++++--------- 1 file changed, 98 insertions(+), 109 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index 8f545f209e..fad97c2fad 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -20,7 +20,6 @@ import ( type structTag struct { optional bool computed bool - readonly bool singleObject bool } @@ -42,125 +41,116 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { continue } structTag := getStructTag(typeField) - attr := getAttribute(ctx, v, field, structTag) - if structTag.optional { - attr = attr.SetOptional() - } else { - attr = attr.SetRequired() + value := field.Value.Interface() + if _, ok := value.(attr.Value); !ok { + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } - if structTag.computed { - attr = attr.SetComputed() - } - if structTag.readonly { - attr = attr.SetReadOnly() - } - scmAttr[fieldName] = attr - } - return NestedBlockObject{Attributes: scmAttr} -} - -func getAttribute(ctx context.Context, v reflect.Value, field tfreflect.Field, structTag structTag) AttributeBuilder { - typeField := field.StructField - fieldName := typeField.Tag.Get("tfsdk") - value := field.Value.Interface() - if _, ok := value.(attr.Value); !ok { - panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) - } - switch value.(type) { - case types.Bool: - return BoolAttributeBuilder{} - case types.Int64: - return Int64AttributeBuilder{} - case types.Float64: - return Float64AttributeBuilder{} - case types.String: - return StringAttributeBuilder{} - case types.List, types.Map, types.Object: - // Additional metadata is required to determine the type of the list elements. - // This is available via the ComplexFieldTypeProvider interface, implemented on the parent type. - provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider) - if !ok { - panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) - } - complexFieldTypes := provider.GetComplexFieldTypes(ctx) - fieldType, ok := complexFieldTypes[fieldName] - if !ok { - panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) - } - // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. - // Otherwise, use ListNestedBlockBuilder. - switch fieldType { - // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. - // If new types are added there, they must also be added here to work properly. - case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): - // Look up the element type from the Type() methods for TF SDK structs. - // This is always a attr.TypeWithElementType because the field is a list or map. - objectType := tfcommon.NewObjectTyper(v.Interface()).Type(ctx).(types.ObjectType) - attrType, ok := objectType.AttrTypes[fieldName] + switch value.(type) { + case types.Bool: + scmAttr[fieldName] = BoolAttributeBuilder{} + case types.Int64: + scmAttr[fieldName] = Int64AttributeBuilder{} + case types.Float64: + scmAttr[fieldName] = Float64AttributeBuilder{} + case types.String: + scmAttr[fieldName] = StringAttributeBuilder{} + case types.List, types.Map, types.Object: + // Additional metadata is required to determine the type of the list elements. + // This is available via the ComplexFieldTypeProvider interface, implemented on the parent type. + provider, ok := v.Interface().(tfcommon.ComplexFieldTypeProvider) if !ok { - panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) + panic(fmt.Errorf("complex field types not provided for type: %T. %s", v.Interface(), common.TerraformBugErrorMessage)) } - containerType := attrType.(attr.TypeWithElementType) - switch value.(type) { - case types.List: - return ListAttributeBuilder{ElementType: containerType.ElementType()} - case types.Map: - return MapAttributeBuilder{ElementType: containerType.ElementType()} + complexFieldTypes := provider.GetComplexFieldTypes(ctx) + fieldType, ok := complexFieldTypes[fieldName] + if !ok { + panic(fmt.Errorf("complex field type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } - default: - // The element type is a TFSDK type. Map fields are treated as MapNestedAttributes, and list - // fields are treated as ListNestedAttributes. Object fields are treated as SingleNestedAttributes. - fieldValue := reflect.New(fieldType).Elem() - - // Generate the nested block schema - nestedSchema := typeToSchema(ctx, fieldValue) - switch value.(type) { - case types.List: - validators := []validator.List{} - if structTag.singleObject { - validators = append(validators, listvalidator.SizeAtMost(1)) - } - return ListNestedAttributeBuilder{ - NestedObject: nestedSchema.ToNestedAttributeObject(), - Validators: validators, + // If the field type is a "primitive", use the appropriate AttributeBuilder. This includes enums, which are treated as strings. + // Otherwise, use ListNestedBlockBuilder. + switch fieldType { + // Note: The list of primitive types must match all of the possible types generated by the `attr-type` template in .codegen/model.go.tmpl. + // If new types are added there, they must also be added here to work properly. + case reflect.TypeOf(types.Bool{}), reflect.TypeOf(types.Int64{}), reflect.TypeOf(types.Float64{}), reflect.TypeOf(types.String{}): + // Look up the element type from the Type() methods for TF SDK structs. + // This is always a attr.TypeWithElementType because the field is a list or map. + objectType := tfcommon.NewObjectTyper(v.Interface()).Type(ctx).(types.ObjectType) + attrType, ok := objectType.AttrTypes[fieldName] + if !ok { + panic(fmt.Errorf("attr type not found for field %s on type %T. %s", typeField.Name, v.Interface(), common.TerraformBugErrorMessage)) } - case types.Map: - return MapNestedAttributeBuilder{ - NestedObject: nestedSchema.ToNestedAttributeObject(), + containerType := attrType.(attr.TypeWithElementType) + switch value.(type) { + case types.List: + scmAttr[fieldName] = ListAttributeBuilder{ElementType: containerType.ElementType()} + case types.Map: + scmAttr[fieldName] = MapAttributeBuilder{ElementType: containerType.ElementType()} } - case types.Object: - return SingleNestedAttributeBuilder{ - Attributes: nestedSchema.ToNestedAttributeObject().Attributes, + default: + // The element type is a TFSDK type. Map fields are treated as MapNestedAttributes, and list + // fields are treated as ListNestedAttributes. Object fields are treated as SingleNestedAttributes. + fieldValue := reflect.New(fieldType).Elem() + + // Generate the nested block schema + nestedSchema := typeToSchema(ctx, fieldValue) + switch value.(type) { + case types.List: + validators := []validator.List{} + if structTag.singleObject { + validators = append(validators, listvalidator.SizeAtMost(1)) + } + scmAttr[fieldName] = ListNestedAttributeBuilder{ + NestedObject: nestedSchema.ToNestedAttributeObject(), + Validators: validators, + } + case types.Map: + scmAttr[fieldName] = MapNestedAttributeBuilder{ + NestedObject: nestedSchema.ToNestedAttributeObject(), + } + case types.Object: + scmAttr[fieldName] = SingleNestedAttributeBuilder{ + Attributes: nestedSchema.ToNestedAttributeObject().Attributes, + } } } + // No other types are supported. Instead, we provide helpful error messages to help users writing + // custom TFSDK structures to use the appropriate types. + case int, int32, int64: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Int intead. %s", value, common.TerraformBugErrorMessage)) + case float32, float64: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Float64 instead. %s", value, common.TerraformBugErrorMessage)) + case string: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.String instead. %s", value, common.TerraformBugErrorMessage)) + case bool: + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Bool instead. %s", value, common.TerraformBugErrorMessage)) + default: + fieldType := field.Value.Type() + if fieldType.Kind() == reflect.Slice { + fieldElemType := fieldType.Elem() + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + } + if fieldType.Kind() == reflect.Map { + fieldElemType := fieldType.Elem() + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Map instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + } + if fieldType.Kind() == reflect.Struct { + // TODO: change the recommendation to use types.Object when support is added. + panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead, and treat the nested object as a list of length 1. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldType.Name(), common.TerraformBugErrorMessage)) + } + panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } - // No other types are supported. Instead, we provide helpful error messages to help users writing - // custom TFSDK structures to use the appropriate types. - case int, int32, int64: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Int intead. %s", value, common.TerraformBugErrorMessage)) - case float32, float64: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Float64 instead. %s", value, common.TerraformBugErrorMessage)) - case string: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.String instead. %s", value, common.TerraformBugErrorMessage)) - case bool: - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Bool instead. %s", value, common.TerraformBugErrorMessage)) - default: - fieldType := field.Value.Type() - if fieldType.Kind() == reflect.Slice { - fieldElemType := fieldType.Elem() - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) - } - if fieldType.Kind() == reflect.Map { - fieldElemType := fieldType.Elem() - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.Map instead. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldElemType.Name(), common.TerraformBugErrorMessage)) + attr := scmAttr[fieldName] + if structTag.optional { + attr = attr.SetOptional() + } else { + attr = attr.SetRequired() } - if fieldType.Kind() == reflect.Struct { - // TODO: change the recommendation to use types.Object when support is added. - panic(fmt.Errorf("unsupported type %T in tfsdk structs. Use types.List instead, and treat the nested object as a list of length 1. To capture the element type, implement the ComplexFieldTypeProvider interface and add the following mapping: \"%s\": reflect.TypeOf(%s). %s", value, fieldName, fieldType.Name(), common.TerraformBugErrorMessage)) + if structTag.computed { + attr = attr.SetComputed() } - panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) + scmAttr[fieldName] = attr } - panic(fmt.Errorf("unreachable code reached. %s", common.TerraformBugErrorMessage)) + return NestedBlockObject{Attributes: scmAttr} } func getStructTag(field reflect.StructField) structTag { @@ -168,7 +158,6 @@ func getStructTag(field reflect.StructField) structTag { return structTag{ optional: strings.Contains(tagValue, "optional"), computed: strings.Contains(tagValue, "computed"), - readonly: strings.Contains(tagValue, "readonly"), singleObject: strings.Contains(tagValue, "object"), } } From f0117c891dc5cee63edb91922b2486a77f476dca Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 10:42:13 +0100 Subject: [PATCH 78/91] work --- .../providers/pluginfw/products/catalog/data_functions.go | 2 +- .../providers/pluginfw/products/cluster/data_cluster.go | 2 +- .../data_notification_destinations.go | 7 +++++-- .../products/registered_model/data_registered_model.go | 2 +- .../pluginfw/products/serving/data_serving_endpoints.go | 2 +- .../providers/pluginfw/products/sharing/data_shares.go | 2 +- .../providers/pluginfw/products/volume/data_volumes.go | 2 +- 7 files changed, 11 insertions(+), 8 deletions(-) diff --git a/internal/providers/pluginfw/products/catalog/data_functions.go b/internal/providers/pluginfw/products/catalog/data_functions.go index f0845fb186..5c0ca3bead 100644 --- a/internal/providers/pluginfw/products/catalog/data_functions.go +++ b/internal/providers/pluginfw/products/catalog/data_functions.go @@ -35,7 +35,7 @@ type FunctionsData struct { CatalogName types.String `tfsdk:"catalog_name"` SchemaName types.String `tfsdk:"schema_name"` IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` - Functions types.List `tfsdk:"functions" tf:"readonly"` + Functions types.List `tfsdk:"functions" tf:"optional,computed"` } func (FunctionsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/cluster/data_cluster.go b/internal/providers/pluginfw/products/cluster/data_cluster.go index d7800ef650..ffcf6a70dd 100644 --- a/internal/providers/pluginfw/products/cluster/data_cluster.go +++ b/internal/providers/pluginfw/products/cluster/data_cluster.go @@ -36,7 +36,7 @@ type ClusterDataSource struct { type ClusterInfo struct { ClusterId types.String `tfsdk:"cluster_id" tf:"optional,computed"` Name types.String `tfsdk:"cluster_name" tf:"optional,computed"` - ClusterInfo types.List `tfsdk:"cluster_info" tf:"readonly"` + ClusterInfo types.List `tfsdk:"cluster_info" tf:"optional,computed"` } func (ClusterInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index f81361830f..ab56bb8628 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -36,7 +36,7 @@ type NotificationDestinationsDataSource struct { type NotificationDestinationsInfo struct { DisplayNameContains types.String `tfsdk:"display_name_contains" tf:"optional"` Type types.String `tfsdk:"type" tf:"optional"` - NotificationDestinations types.List `tfsdk:"notification_destinations" tf:"readonly"` + NotificationDestinations types.List `tfsdk:"notification_destinations" tf:"computed"` } func (NotificationDestinationsInfo) GetComplexFieldTypes(context.Context) map[string]reflect.Type { @@ -50,7 +50,10 @@ func (d *NotificationDestinationsDataSource) Metadata(ctx context.Context, req d } func (d *NotificationDestinationsDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, NotificationDestinationsInfo{}, nil) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, NotificationDestinationsInfo{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { + cs.SetReadOnly("notification_destinations") + return cs + }) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/products/registered_model/data_registered_model.go b/internal/providers/pluginfw/products/registered_model/data_registered_model.go index eca91989d8..912f5b6060 100644 --- a/internal/providers/pluginfw/products/registered_model/data_registered_model.go +++ b/internal/providers/pluginfw/products/registered_model/data_registered_model.go @@ -37,7 +37,7 @@ type RegisteredModelData struct { FullName types.String `tfsdk:"full_name"` IncludeAliases types.Bool `tfsdk:"include_aliases" tf:"optional"` IncludeBrowse types.Bool `tfsdk:"include_browse" tf:"optional"` - ModelInfo types.List `tfsdk:"model_info" tf:"readonly"` + ModelInfo types.List `tfsdk:"model_info" tf:"optional,computed"` } func (RegisteredModelData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go index 9acd3bdaab..51c5e2c64b 100644 --- a/internal/providers/pluginfw/products/serving/data_serving_endpoints.go +++ b/internal/providers/pluginfw/products/serving/data_serving_endpoints.go @@ -27,7 +27,7 @@ type ServingEndpointsDataSource struct { } type ServingEndpointsData struct { - Endpoints types.List `tfsdk:"endpoints" tf:"readonly"` + Endpoints types.List `tfsdk:"endpoints" tf:"optional,computed"` } func (ServingEndpointsData) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/sharing/data_shares.go b/internal/providers/pluginfw/products/sharing/data_shares.go index 32ff7c71ea..457ba8633d 100644 --- a/internal/providers/pluginfw/products/sharing/data_shares.go +++ b/internal/providers/pluginfw/products/sharing/data_shares.go @@ -18,7 +18,7 @@ import ( const dataSourceNameShares = "shares" type SharesList struct { - Shares types.List `tfsdk:"shares" tf:"readonly,slice_set"` + Shares types.List `tfsdk:"shares" tf:"computed,optional,slice_set"` } func (SharesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type { diff --git a/internal/providers/pluginfw/products/volume/data_volumes.go b/internal/providers/pluginfw/products/volume/data_volumes.go index 61df9ca56e..6727dc20cb 100644 --- a/internal/providers/pluginfw/products/volume/data_volumes.go +++ b/internal/providers/pluginfw/products/volume/data_volumes.go @@ -33,7 +33,7 @@ type VolumesDataSource struct { type VolumesList struct { CatalogName types.String `tfsdk:"catalog_name"` SchemaName types.String `tfsdk:"schema_name"` - Ids types.List `tfsdk:"ids" tf:"readonly"` + Ids types.List `tfsdk:"ids" tf:"optional,computed"` } func (VolumesList) GetComplexFieldTypes(context.Context) map[string]reflect.Type { From 28c6acc7c0d80bdbc2df3e0cc5aad927377a7757 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 10:44:53 +0100 Subject: [PATCH 79/91] fix --- .../data_notification_destinations.go | 5 +---- .../pluginfw/tfschema/struct_to_schema.go | 16 +++++++++++----- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go index ab56bb8628..5e6688bb79 100755 --- a/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go +++ b/internal/providers/pluginfw/products/notificationdestinations/data_notification_destinations.go @@ -50,10 +50,7 @@ func (d *NotificationDestinationsDataSource) Metadata(ctx context.Context, req d } func (d *NotificationDestinationsDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { - attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, NotificationDestinationsInfo{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { - cs.SetReadOnly("notification_destinations") - return cs - }) + attrs, blocks := tfschema.DataSourceStructToSchemaMap(ctx, NotificationDestinationsInfo{}, nil) resp.Schema = schema.Schema{ Attributes: attrs, Blocks: blocks, diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema.go b/internal/providers/pluginfw/tfschema/struct_to_schema.go index fad97c2fad..4612b63eef 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema.go @@ -140,13 +140,19 @@ func typeToSchema(ctx context.Context, v reflect.Value) NestedBlockObject { panic(fmt.Errorf("unexpected type %T in tfsdk structs, expected a plugin framework value type. %s", value, common.TerraformBugErrorMessage)) } attr := scmAttr[fieldName] - if structTag.optional { - attr = attr.SetOptional() - } else { - attr = attr.SetRequired() - } if structTag.computed { + // Computed attributes are always computed and may be optional. attr = attr.SetComputed() + if structTag.optional { + attr = attr.SetOptional() + } + } else { + // Non-computed attributes must be either optional or required. + if structTag.optional { + attr = attr.SetOptional() + } else { + attr = attr.SetRequired() + } } scmAttr[fieldName] = attr } From 361cec471dc2224b5964ee83f239bb724811b013 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 10:49:52 +0100 Subject: [PATCH 80/91] update contributing --- CONTRIBUTING.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7ead3fe7f3..f32958dbe0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -135,10 +135,18 @@ We are migrating the resource from SDKv2 to Plugin Framework provider and hence 6. Create a PR and send it for review. ### Migrating resource to plugin framework -Ideally there shouldn't be any behaviour change when migrating a resource or data source to either Go SDk or Plugin Framework. +There must not be any behaviour change or schema change when migrating a resource or data source to either Go SDK or Plugin Framework. - Please make sure there are no breaking differences due to changes in schema by running: `make diff-schema`. - Integration tests shouldn't require any major changes. +By default, `ResourceStructToSchema` will convert a `types.List` field to a `ListAttribute` or `ListNestedAttribute`. For resources or data sources migrated from the SDKv2, `ListNestedBlock` must be used for such fields. To do this, call `cs.ConfigureForSdkV2Migration()` in the `ResourceStructToSchema` callback: +```go +resp.Schema = tfschema.ResourceStructToSchema(ctx, Resource{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { + cs.ConfigureForSdkV2Migration() + // Add any additional configuration here + return cs +}) +``` ### Code Organization Each resource and data source should be defined in package `internal/providers/plugnifw/products/`, e.g.: `internal/providers/plugnifw/products/volume` package will contain both resource, data sources and other utils specific to volumes. Tests (both unit and integration tests) will also remain in this package. From 402f40a07a5086d94da5002ad815f04c6095e455 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 10:51:22 +0100 Subject: [PATCH 81/91] docs --- internal/providers/pluginfw/tfschema/attribute_converter.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/internal/providers/pluginfw/tfschema/attribute_converter.go b/internal/providers/pluginfw/tfschema/attribute_converter.go index 74d84d62d3..d767606608 100644 --- a/internal/providers/pluginfw/tfschema/attribute_converter.go +++ b/internal/providers/pluginfw/tfschema/attribute_converter.go @@ -1,9 +1,13 @@ package tfschema +// Blockable is an interface that can be implemented by an AttributeBuilder to convert it to a BlockBuilder. type Blockable interface { + // ToBlock converts the AttributeBuilder to a BlockBuilder. ToBlock() BlockBuilder } +// convertAttributesToBlocks converts all attributes implementing the Blockable interface to blocks, returning +// a new NestedBlockObject with the converted attributes and the original blocks. func convertAttributesToBlocks(attributes map[string]AttributeBuilder, blocks map[string]BlockBuilder) NestedBlockObject { newAttributes := make(map[string]AttributeBuilder) newBlocks := make(map[string]BlockBuilder) From c425508ecd0fdeccf84d284517728985fc27769b Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 10:52:58 +0100 Subject: [PATCH 82/91] docs --- internal/providers/pluginfw/tfschema/customizable_schema.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index 562a8fa5ef..558bc2220a 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -202,6 +202,9 @@ func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { return s } +// ConfigureForSdkV2Migration modifies the underlying schema to be compatible with SDKv2. This method must +// be called on all resources that were originally implemented using the SDKv2 and are migrated to the plugin +// framework. func (s *CustomizableSchema) ConfigureForSdkV2Migration() *CustomizableSchema { nbo := s.attr.(SingleNestedBlockBuilder).NestedObject s.attr = SingleNestedBlockBuilder{NestedObject: convertAttributesToBlocks(nbo.Attributes, nbo.Blocks)} From fc9e4c8143f2838512d0503215a13fa7b3c5ebbd Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 11:02:07 +0100 Subject: [PATCH 83/91] tests and better error --- .../pluginfw/tfschema/attribute_converter.go | 6 + .../tfschema/customizable_schema_test.go | 272 +++++++----------- .../tfschema/single_nested_attribute.go | 2 +- .../pluginfw/tfschema/single_nested_block.go | 16 -- 4 files changed, 114 insertions(+), 182 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/attribute_converter.go b/internal/providers/pluginfw/tfschema/attribute_converter.go index d767606608..8611509c08 100644 --- a/internal/providers/pluginfw/tfschema/attribute_converter.go +++ b/internal/providers/pluginfw/tfschema/attribute_converter.go @@ -21,6 +21,12 @@ func convertAttributesToBlocks(attributes map[string]AttributeBuilder, blocks ma for name, block := range blocks { newBlocks[name] = block } + if len(newAttributes) == 0 { + newAttributes = nil + } + if len(newBlocks) == 0 { + newBlocks = nil + } return NestedBlockObject{ Attributes: newAttributes, Blocks: newBlocks, diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 12d8f44ade..1dfec1772f 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -263,168 +263,110 @@ func (m mockValidator) ValidateObject(context.Context, validator.ObjectRequest, var _ validator.List = mockValidator{} var _ validator.Object = mockValidator{} -// func TestCustomizeSchema_ConvertToAttribute(t *testing.T) { -// v := mockValidator{} -// pm := mockPlanModifier{} -// testCases := []struct { -// name string -// baseSchema NestedBlockObject -// path []string -// want NestedBlockObject -// expectPanic bool -// }{ -// { -// name: "ListNestedBlock", -// baseSchema: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "list": ListNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// DeprecationMessage: "deprecated", -// Validators: []validator.List{v}, -// PlanModifiers: []planmodifier.List{pm}, -// }, -// }, -// }, -// path: []string{"list"}, -// want: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "list": ListNestedAttributeBuilder{ -// NestedObject: NestedAttributeObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// DeprecationMessage: "deprecated", -// Validators: []validator.List{v}, -// PlanModifiers: []planmodifier.List{pm}, -// }, -// }, -// }, -// }, -// { -// name: "ListNestedBlock/CalledOnInnerBlock", -// baseSchema: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "list": ListNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "nested_block": ListNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// path: []string{"list", "nested_block"}, -// want: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "list": ListNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "nested_block": ListNestedAttributeBuilder{ -// NestedObject: NestedAttributeObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// { -// name: "SingleNestedBlock", -// baseSchema: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "single": SingleNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// DeprecationMessage: "deprecated", -// Validators: []validator.Object{v}, -// PlanModifiers: []planmodifier.Object{pm}, -// }, -// }, -// }, -// path: []string{"single"}, -// want: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "single": SingleNestedAttributeBuilder{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// DeprecationMessage: "deprecated", -// Validators: []validator.Object{v}, -// PlanModifiers: []planmodifier.Object{pm}, -// }, -// }, -// }, -// }, -// { -// name: "SingleNestedBlock/RecursiveBlocks", -// baseSchema: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "single": SingleNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Blocks: map[string]BlockBuilder{ -// "nested_block": ListNestedBlockBuilder{ -// NestedObject: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// path: []string{"single"}, -// want: NestedBlockObject{ -// Attributes: map[string]AttributeBuilder{ -// "single": SingleNestedAttributeBuilder{ -// Attributes: map[string]AttributeBuilder{ -// "nested_block": ListNestedAttributeBuilder{ -// NestedObject: NestedAttributeObject{ -// Attributes: map[string]AttributeBuilder{ -// "attr": StringAttributeBuilder{}, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// }, -// { -// name: "PanicOnEmptyPath", -// path: nil, -// expectPanic: true, -// }, -// } -// for _, c := range testCases { -// t.Run(c.name, func(t *testing.T) { -// if c.expectPanic { -// assert.Panics(t, func() { -// ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) -// }) -// } else { -// got := ConstructCustomizableSchema(c.baseSchema).ConvertToAttribute(c.path...) -// assert.Equal(t, c.want, got.attr.(SingleNestedBlockBuilder).NestedObject) -// } -// }) -// } -// } +func TestCustomizeSchema_ConfigureForSdkV2Migration(t *testing.T) { + v := mockValidator{} + pm := mockPlanModifier{} + testCases := []struct { + name string + baseSchema NestedBlockObject + want NestedBlockObject + expectPanic bool + }{ + { + name: "ListNestedAttribute", + baseSchema: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "list": ListNestedAttributeBuilder{ + NestedObject: NestedAttributeObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + DeprecationMessage: "deprecated", + Validators: []validator.List{v}, + PlanModifiers: []planmodifier.List{pm}, + }, + }, + }, + want: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "list": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + DeprecationMessage: "deprecated", + Validators: []validator.List{v}, + PlanModifiers: []planmodifier.List{pm}, + }, + }, + }, + }, + { + name: "ListNestedAttribute/RecursiveBlocks", + baseSchema: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "list": ListNestedAttributeBuilder{ + NestedObject: NestedAttributeObject{ + Attributes: map[string]AttributeBuilder{ + "nested_block": ListNestedAttributeBuilder{ + NestedObject: NestedAttributeObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + }, + }, + }, + }, + }, + }, + want: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "list": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Blocks: map[string]BlockBuilder{ + "nested_block": ListNestedBlockBuilder{ + NestedObject: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "SingleNestedBlock/Panics", + baseSchema: NestedBlockObject{ + Attributes: map[string]AttributeBuilder{ + "single": SingleNestedAttributeBuilder{ + Attributes: map[string]AttributeBuilder{ + "attr": StringAttributeBuilder{}, + }, + DeprecationMessage: "deprecated", + Validators: []validator.Object{v}, + PlanModifiers: []planmodifier.Object{pm}, + }, + }, + }, + expectPanic: true, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + if c.expectPanic { + assert.Panics(t, func() { + ConstructCustomizableSchema(c.baseSchema).ConfigureForSdkV2Migration() + }) + } else { + got := ConstructCustomizableSchema(c.baseSchema).ConfigureForSdkV2Migration() + assert.Equal(t, c.want, got.attr.(SingleNestedBlockBuilder).NestedObject) + } + }) + } +} diff --git a/internal/providers/pluginfw/tfschema/single_nested_attribute.go b/internal/providers/pluginfw/tfschema/single_nested_attribute.go index 62fe04bdcf..0321d0c37f 100644 --- a/internal/providers/pluginfw/tfschema/single_nested_attribute.go +++ b/internal/providers/pluginfw/tfschema/single_nested_attribute.go @@ -107,5 +107,5 @@ func (a SingleNestedAttributeBuilder) AddPlanModifier(v planmodifier.Object) Att } func (a SingleNestedAttributeBuilder) ToBlock() BlockBuilder { - panic(fmt.Errorf("SingleNestedAttributeBuilder used for legacy resource. This is unexpected. %s", common.TerraformBugErrorMessage)) + panic(fmt.Errorf("ToBlock() called on SingleNestedAttributeBuilder. This means that the corresponding field is a types.Object, which should never happen for legacy resources. %s", common.TerraformBugErrorMessage)) } diff --git a/internal/providers/pluginfw/tfschema/single_nested_block.go b/internal/providers/pluginfw/tfschema/single_nested_block.go index 59508235b6..1b88c9ae01 100644 --- a/internal/providers/pluginfw/tfschema/single_nested_block.go +++ b/internal/providers/pluginfw/tfschema/single_nested_block.go @@ -68,19 +68,3 @@ func (a SingleNestedBlockBuilder) AddPlanModifier(v planmodifier.Object) BaseSch a.PlanModifiers = append(a.PlanModifiers, v) return a } - -func (a SingleNestedBlockBuilder) ConvertBlockToAttribute(field string) BaseSchemaBuilder { - elem, ok := a.NestedObject.Blocks[field] - if !ok { - panic(fmt.Errorf("field %s does not exist in nested block", field)) - } - if a.NestedObject.Attributes == nil { - a.NestedObject.Attributes = make(map[string]AttributeBuilder) - } - a.NestedObject.Attributes[field] = elem.ToAttribute() - delete(a.NestedObject.Blocks, field) - if len(a.NestedObject.Blocks) == 0 { - a.NestedObject.Blocks = nil - } - return a -} From 10c456e6c0aef33b04d76d810fe3645bfb01bd74 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 11:56:15 +0100 Subject: [PATCH 84/91] rename --- CONTRIBUTING.md | 4 ++-- .../products/library/resource_library.go | 2 +- .../qualitymonitor/resource_quality_monitor.go | 2 +- .../pluginfw/products/sharing/resource_share.go | 2 +- .../pluginfw/tfschema/customizable_schema.go | 4 ++-- .../tfschema/customizable_schema_test.go | 16 ++++++++-------- 6 files changed, 15 insertions(+), 15 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index f32958dbe0..54f584a1e6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -139,10 +139,10 @@ There must not be any behaviour change or schema change when migrating a resourc - Please make sure there are no breaking differences due to changes in schema by running: `make diff-schema`. - Integration tests shouldn't require any major changes. -By default, `ResourceStructToSchema` will convert a `types.List` field to a `ListAttribute` or `ListNestedAttribute`. For resources or data sources migrated from the SDKv2, `ListNestedBlock` must be used for such fields. To do this, call `cs.ConfigureForSdkV2Migration()` in the `ResourceStructToSchema` callback: +By default, `ResourceStructToSchema` will convert a `types.List` field to a `ListAttribute` or `ListNestedAttribute`. For resources or data sources migrated from the SDKv2, `ListNestedBlock` must be used for such fields. To do this, call `cs.ConfigureAsSdkV2Compatible()` in the `ResourceStructToSchema` callback: ```go resp.Schema = tfschema.ResourceStructToSchema(ctx, Resource{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { - cs.ConfigureForSdkV2Migration() + cs.ConfigureAsSdkV2Compatible() // Add any additional configuration here return cs }) diff --git a/internal/providers/pluginfw/products/library/resource_library.go b/internal/providers/pluginfw/products/library/resource_library.go index ba74429279..f7b3854a5c 100644 --- a/internal/providers/pluginfw/products/library/resource_library.go +++ b/internal/providers/pluginfw/products/library/resource_library.go @@ -88,7 +88,7 @@ func (r *LibraryResource) Metadata(ctx context.Context, req resource.MetadataReq func (r *LibraryResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, LibraryExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() for field, attribute := range c.ToNestedBlockObject().Attributes { switch attribute.(type) { case tfschema.StringAttributeBuilder: diff --git a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go index d4e0248f65..574bb72e3d 100644 --- a/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go +++ b/internal/providers/pluginfw/products/qualitymonitor/resource_quality_monitor.go @@ -78,7 +78,7 @@ func (r *QualityMonitorResource) Metadata(ctx context.Context, req resource.Meta func (r *QualityMonitorResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, MonitorInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetRequired("assets_dir") c.SetRequired("output_schema_name") c.SetReadOnly("monitor_version") diff --git a/internal/providers/pluginfw/products/sharing/resource_share.go b/internal/providers/pluginfw/products/sharing/resource_share.go index 61219eda84..17c10137a1 100644 --- a/internal/providers/pluginfw/products/sharing/resource_share.go +++ b/internal/providers/pluginfw/products/sharing/resource_share.go @@ -145,7 +145,7 @@ func (r *ShareResource) Metadata(ctx context.Context, req resource.MetadataReque func (r *ShareResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { attrs, blocks := tfschema.ResourceStructToSchemaMap(ctx, ShareInfoExtended{}, func(c tfschema.CustomizableSchema) tfschema.CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetRequired("name") c.AddPlanModifier(stringplanmodifier.RequiresReplace(), "name") // ForceNew diff --git a/internal/providers/pluginfw/tfschema/customizable_schema.go b/internal/providers/pluginfw/tfschema/customizable_schema.go index 558bc2220a..217bfa888e 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema.go @@ -202,10 +202,10 @@ func (s *CustomizableSchema) SetReadOnly(path ...string) *CustomizableSchema { return s } -// ConfigureForSdkV2Migration modifies the underlying schema to be compatible with SDKv2. This method must +// ConfigureAsSdkV2Compatible modifies the underlying schema to be compatible with SDKv2. This method must // be called on all resources that were originally implemented using the SDKv2 and are migrated to the plugin // framework. -func (s *CustomizableSchema) ConfigureForSdkV2Migration() *CustomizableSchema { +func (s *CustomizableSchema) ConfigureAsSdkV2Compatible() *CustomizableSchema { nbo := s.attr.(SingleNestedBlockBuilder).NestedObject s.attr = SingleNestedBlockBuilder{NestedObject: convertAttributesToBlocks(nbo.Attributes, nbo.Blocks)} return s diff --git a/internal/providers/pluginfw/tfschema/customizable_schema_test.go b/internal/providers/pluginfw/tfschema/customizable_schema_test.go index 1dfec1772f..c2d691da44 100644 --- a/internal/providers/pluginfw/tfschema/customizable_schema_test.go +++ b/internal/providers/pluginfw/tfschema/customizable_schema_test.go @@ -166,7 +166,7 @@ func TestCustomizeSchemaObjectTypeValidatorAdded(t *testing.T) { func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetRequired("nested") return c }) @@ -176,7 +176,7 @@ func TestCustomizeSchema_SetRequired_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetOptional("nested") return c }) @@ -186,7 +186,7 @@ func TestCustomizeSchema_SetOptional_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetSensitive("nested") return c }) @@ -196,7 +196,7 @@ func TestCustomizeSchema_SetSensitive_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetReadOnly("nested") return c }) @@ -206,7 +206,7 @@ func TestCustomizeSchema_SetReadOnly_PanicOnBlock(t *testing.T) { func TestCustomizeSchema_SetComputed_PanicOnBlock(t *testing.T) { assert.Panics(t, func() { _ = ResourceStructToSchema(context.Background(), TestTfSdk{}, func(c CustomizableSchema) CustomizableSchema { - c.ConfigureForSdkV2Migration() + c.ConfigureAsSdkV2Compatible() c.SetComputed("nested") return c }) @@ -263,7 +263,7 @@ func (m mockValidator) ValidateObject(context.Context, validator.ObjectRequest, var _ validator.List = mockValidator{} var _ validator.Object = mockValidator{} -func TestCustomizeSchema_ConfigureForSdkV2Migration(t *testing.T) { +func TestCustomizeSchema_ConfigureAsSdkV2Compatible(t *testing.T) { v := mockValidator{} pm := mockPlanModifier{} testCases := []struct { @@ -361,10 +361,10 @@ func TestCustomizeSchema_ConfigureForSdkV2Migration(t *testing.T) { t.Run(c.name, func(t *testing.T) { if c.expectPanic { assert.Panics(t, func() { - ConstructCustomizableSchema(c.baseSchema).ConfigureForSdkV2Migration() + ConstructCustomizableSchema(c.baseSchema).ConfigureAsSdkV2Compatible() }) } else { - got := ConstructCustomizableSchema(c.baseSchema).ConfigureForSdkV2Migration() + got := ConstructCustomizableSchema(c.baseSchema).ConfigureAsSdkV2Compatible() assert.Equal(t, c.want, got.attr.(SingleNestedBlockBuilder).NestedObject) } }) From 86b8cce2870e63d35883125072f185a5ef6e0203 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 11:59:46 +0100 Subject: [PATCH 85/91] fix test --- .../providers/pluginfw/tfschema/struct_to_schema_test.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go index 6a410ffced..be22464d61 100644 --- a/internal/providers/pluginfw/tfschema/struct_to_schema_test.go +++ b/internal/providers/pluginfw/tfschema/struct_to_schema_test.go @@ -265,10 +265,11 @@ func TestStructToSchemaExpectedError(t *testing.T) { } func TestComputedField(t *testing.T) { - // Test that ComputedTag field is computed and required + // Test that ComputedTag field is computed scm := ResourceStructToSchema(context.Background(), TestComputedTfSdk{}, nil) assert.True(t, scm.Attributes["computedtag"].IsComputed()) - assert.True(t, scm.Attributes["computedtag"].IsRequired()) + // Computed fields can never be required + assert.False(t, scm.Attributes["computedtag"].IsRequired()) // Test that MultipleTags field is computed and optional assert.True(t, scm.Attributes["multipletags"].IsComputed()) From c414f8a0f1828247462d8589481d8193ecc5683f Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 12:08:10 +0100 Subject: [PATCH 86/91] improve integration test --- .../pluginfw/products/app/app_acc_test.go | 100 +++++++++--------- 1 file changed, 50 insertions(+), 50 deletions(-) diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index d47fadfaec..3d46d79452 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -19,35 +19,35 @@ const baseResources = ` string_value = "secret" } -# resource "databricks_sql_endpoint" "this" { -# name = "tf-{var.STICKY_RANDOM}" -# cluster_size = "2X-Small" -# max_num_clusters = 1 + resource "databricks_sql_endpoint" "this" { + name = "tf-{var.STICKY_RANDOM}" + cluster_size = "2X-Small" + max_num_clusters = 1 -# tags { -# custom_tags { -# key = "Owner" -# value = "eng-dev-ecosystem-team_at_databricks.com" -# } -# } -# } + tags { + custom_tags { + key = "Owner" + value = "eng-dev-ecosystem-team_at_databricks.com" + } + } + } -# resource "databricks_job" "this" { -# name = "tf-{var.STICKY_RANDOM}" -# } + resource "databricks_job" "this" { + name = "tf-{var.STICKY_RANDOM}" + } -# resource "databricks_model_serving" "this" { -# name = "tf-{var.STICKY_RANDOM}" -# config { -# served_models { -# name = "prod_model" -# model_name = "experiment-fixture-model" -# model_version = "1" -# workload_size = "Small" -# scale_to_zero_enabled = true -# } -# } -# } + resource "databricks_model_serving" "this" { + name = "tf-{var.STICKY_RANDOM}" + config { + served_models { + name = "prod_model" + model_name = "experiment-fixture-model" + model_version = "1" + workload_size = "Small" + scale_to_zero_enabled = true + } + } + } ` func makeTemplate(description string) string { @@ -64,32 +64,32 @@ func makeTemplate(description string) string { permission = "MANAGE" } }] -# resources { -# name = "warehouse" -# description = "warehouse for app" -# job { -# id = databricks_job.this.id -# permission = "CAN_MANAGE" -# } -# } + resources { + name = "warehouse" + description = "warehouse for app" + job { + id = databricks_job.this.id + permission = "CAN_MANAGE" + } + } -# resources { -# name = "serving endpoint" -# description = "serving endpoint for app" -# serving_endpoint { -# name = databricks_model_serving.this.name -# permission = "CAN_MANAGE" -# } -# } + resources { + name = "serving endpoint" + description = "serving endpoint for app" + serving_endpoint { + name = databricks_model_serving.this.name + permission = "CAN_MANAGE" + } + } -# resources { -# name = "sql warehouse" -# description = "sql warehouse for app" -# sql_warehouse { -# id = databricks_sql_endpoint.this.id -# permission = "CAN_MANAGE" -# } -# } + resources { + name = "sql warehouse" + description = "sql warehouse for app" + sql_warehouse { + id = databricks_sql_endpoint.this.id + permission = "CAN_MANAGE" + } + } }` return fmt.Sprintf(appTemplate, description) } From 66fe1b949f492c759830d150caeff3063cc717ec Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 13:27:46 +0100 Subject: [PATCH 87/91] import --- docs/resources/app.md | 43 +++++++++++-------- .../pluginfw/products/app/app_acc_test.go | 19 +++----- .../pluginfw/products/app/resource_app.go | 5 +++ 3 files changed, 38 insertions(+), 29 deletions(-) diff --git a/docs/resources/app.md b/docs/resources/app.md index c699189e3d..c75b133310 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -13,27 +13,27 @@ subcategory: "Apps" resource "databricks_app" "this" { name = "my-custom-app" description = "My app" - resource { + resources = [{ name = "sql-warehouse" - sql_warehouse { + sql_warehouse = { id = "e9ca293f79a74b5c" permission = "CAN_MANAGE" } - } - resource { + }, + { name = "serving-endpoint" - serving_endpoint { + serving_endpoint = { name = "databricks-meta-llama-3-1-70b-instruct" permission = "CAN_MANAGE" } - } - resource { + }, + { name = "job" - job { + job = { id = "1234" permission = "CAN_MANAGE" } - } + }] } ``` @@ -43,9 +43,9 @@ The following arguments are required: * `name` - (Required) The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. It must be unique within the workspace. * `description` - (Optional) The description of the app. -* `resource` - (Optional) A list of resources that the app have access to. +* `resources` - (Optional) A list of resources that the app have access to. -### resource Configuration Block +### resources Configuration Attribute This block describes individual resource. @@ -54,17 +54,17 @@ This block describes individual resource. Exactly one of the specific blocks described below is required: -* `secret` block +* `secret` attribute * `scope` - Scope of the secret to grant permission on. * `key` - Key of the secret to grant permission on. * `permission` - Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: `READ`, `WRITE`, `MANAGE`. -* `sql_warehouse` block +* `sql_warehouse` attribute * `id` - Id of the SQL warehouse to grant permission on. * `permission` - Permission to grant on the SQL warehouse. Supported permissions are: `CAN_MANAGE`, `CAN_USE`, `IS_OWNER`. -* `serving_endpoint` block +* `serving_endpoint` attribute * `name` - Name of the serving endpoint to grant permission on. * `permission` - Permission to grant on the serving endpoint. Supported permissions are: `CAN_MANAGE`, `CAN_QUERY`, `CAN_VIEW`. -* `job` block +* `job` attribute * `id` - Id of the job to grant permission on. * `permission` - Permissions to grant on the Job. Supported permissions are: `CAN_MANAGE`, `IS_OWNER`, `CAN_MANAGE_RUN`, `CAN_VIEW`. @@ -72,10 +72,10 @@ Exactly one of the specific blocks described below is required: In addition to all arguments above, the following attributes are exported: -* `compute_status` block +* `compute_status` attribute * `state` - State of the app compute. * `message` - Compute status message -* `app_status` block +* `app_status` attribute * `state` - State of the application. * `message` - Application status message * `url` - The URL of the app once it is deployed. @@ -91,6 +91,15 @@ In addition to all arguments above, the following attributes are exported: This resource can be imported by name: +```hcl +import { + to = databricks_app.this + id = "" +} +``` + +or using the `terraform` CLI: + ```bash terraform import databricks_app.this ``` diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index 3d46d79452..15da49ec99 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -63,33 +63,28 @@ func makeTemplate(description string) string { key = databricks_secret.this.key permission = "MANAGE" } - }] - resources { + }, { name = "warehouse" description = "warehouse for app" - job { + job = { id = databricks_job.this.id permission = "CAN_MANAGE" } - } - - resources { + }, { name = "serving endpoint" description = "serving endpoint for app" - serving_endpoint { + serving_endpoint = { name = databricks_model_serving.this.name permission = "CAN_MANAGE" } - } - - resources { + }, { name = "sql warehouse" description = "sql warehouse for app" - sql_warehouse { + sql_warehouse = { id = databricks_sql_endpoint.this.id permission = "CAN_MANAGE" } - } + }] }` return fmt.Sprintf(appTemplate, description) } diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 3b436ada4b..4393910854 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -216,4 +216,9 @@ func (a *resourceApp) Delete(ctx context.Context, req resource.DeleteRequest, re } } +func (a *resourceApp) ImportState(ctx context.Context, req resource.ImportStateRequest, resp *resource.ImportStateResponse) { + resource.ImportStatePassthroughID(ctx, path.Root("name"), req, resp) +} + var _ resource.ResourceWithConfigure = &resourceApp{} +var _ resource.ResourceWithImportState = &resourceApp{} From 59e16d5183d093566f94c3dc744f204b69cd71a9 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 13:30:56 +0100 Subject: [PATCH 88/91] add import test --- .../pluginfw/products/app/app_acc_test.go | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/app_acc_test.go index 15da49ec99..d650fcf889 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/app_acc_test.go @@ -93,19 +93,19 @@ var templateWithInvalidResource = ` resource "databricks_app" "this" { name = "{var.STICKY_RANDOM}" description = "My app" - resources { + resources = [{ name = "invalid resource" description = "invalid resource for app" - secret { + secret = { permission = "CAN_MANAGE" key = "test" scope = "test" } - sql_warehouse { + sql_warehouse = { id = "123" permission = "CAN_MANAGE" } - } + }] }` func TestAccApp_InvalidResource(t *testing.T) { @@ -126,5 +126,11 @@ func TestAccApp(t *testing.T) { Template: makeTemplate("My app"), }, acceptance.Step{ Template: makeTemplate("My new app"), + }, acceptance.Step{ + ImportState: true, + ResourceName: "databricks_app.this", + ImportStateIdFunc: acceptance.BuildImportStateIdFunc("databricks_app.this", "name"), + ImportStateVerify: true, + ImportStateVerifyIdentifierAttribute: "name", }) } From e0dd84d482066294d5b5cd699023e1b7876ef6ee Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 13:32:26 +0100 Subject: [PATCH 89/91] sort --- .../providers/pluginfw/pluginfw_rollout_utils.go | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/internal/providers/pluginfw/pluginfw_rollout_utils.go b/internal/providers/pluginfw/pluginfw_rollout_utils.go index da5110a636..ce36a610b6 100644 --- a/internal/providers/pluginfw/pluginfw_rollout_utils.go +++ b/internal/providers/pluginfw/pluginfw_rollout_utils.go @@ -27,29 +27,33 @@ import ( ) // List of resources that have been migrated from SDK V2 to plugin framework +// Keep this list sorted. var migratedResources = []func() resource.Resource{ - qualitymonitor.ResourceQualityMonitor, library.ResourceLibrary, + qualitymonitor.ResourceQualityMonitor, } // List of data sources that have been migrated from SDK V2 to plugin framework +// Keep this list sorted. var migratedDataSources = []func() datasource.DataSource{ volume.DataSourceVolumes, } // List of resources that have been onboarded to the plugin framework - not migrated from sdkv2. +// Keep this list sorted. var pluginFwOnlyResources = []func() resource.Resource{ - sharing.ResourceShare, app.ResourceApp, + sharing.ResourceShare, } // List of data sources that have been onboarded to the plugin framework - not migrated from sdkv2. +// Keep this list sorted. var pluginFwOnlyDataSources = []func() datasource.DataSource{ - serving.DataSourceServingEndpoints, + catalog.DataSourceFunctions, + notificationdestinations.DataSourceNotificationDestinations, registered_model.DataSourceRegisteredModel, registered_model.DataSourceRegisteredModelVersions, - notificationdestinations.DataSourceNotificationDestinations, - catalog.DataSourceFunctions, + serving.DataSourceServingEndpoints, // TODO: Add DataSourceCluster into migratedDataSources after fixing unit tests. cluster.DataSourceCluster, // Using the staging name (with pluginframework suffix) sharing.DataSourceShare, // Using the staging name (with pluginframework suffix) From 9114ea151e0b64afe6fd933bce8c6c0d45bca1ad Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 14:47:55 +0100 Subject: [PATCH 90/91] data sources --- docs/data-sources/app.md | 80 +++++++++++++ docs/data-sources/apps.md | 72 ++++++++++++ docs/resources/app.md | 4 +- .../pluginfw/pluginfw_rollout_utils.go | 2 + .../pluginfw/products/app/data_app.go | 85 ++++++++++++++ .../products/app/data_app_acc_test.go | 21 ++++ .../pluginfw/products/app/data_apps.go | 83 ++++++++++++++ .../products/app/data_apps_acc_test.go | 19 ++++ .../pluginfw/products/app/resource_app.go | 3 +- ...p_acc_test.go => resource_app_acc_test.go} | 105 +++++++++--------- 10 files changed, 419 insertions(+), 55 deletions(-) create mode 100644 docs/data-sources/app.md create mode 100644 docs/data-sources/apps.md create mode 100644 internal/providers/pluginfw/products/app/data_app.go create mode 100644 internal/providers/pluginfw/products/app/data_app_acc_test.go create mode 100644 internal/providers/pluginfw/products/app/data_apps.go create mode 100644 internal/providers/pluginfw/products/app/data_apps_acc_test.go rename internal/providers/pluginfw/products/app/{app_acc_test.go => resource_app_acc_test.go} (56%) diff --git a/docs/data-sources/app.md b/docs/data-sources/app.md new file mode 100644 index 0000000000..b0b421c6a0 --- /dev/null +++ b/docs/data-sources/app.md @@ -0,0 +1,80 @@ +--- +subcategory: "Apps" +--- +# databricks_app Data Source + +-> This feature is in [Public Preview](https://docs.databricks.com/release-notes/release-types.html). + +[Databricks Apps](https://docs.databricks.com/en/dev-tools/databricks-apps/index.html) run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on. This resource creates the application but does not handle app deployment, which should be handled separately as part of your CI/CD pipeline. + +This data source allows you to fetch information about a Databricks App. + +## Example Usage + +```hcl +data "databricks_app" "this" { + name = "my-custom-app" +} +``` + +## Argument Reference + +The following arguments are required: + +* `name` - The name of the app. + +## Attribute Reference + +In addition to all arguments above, the following attributes are exported: + +* `app` attribute + * `name` - The name of the app. + * `description` - The description of the app. + * `resources` - A list of resources that the app have access to. + * `compute_status` attribute + * `state` - State of the app compute. + * `message` - Compute status message + * `app_status` attribute + * `state` - State of the application. + * `message` - Application status message + * `url` - The URL of the app once it is deployed. + * `create_time` - The creation time of the app. + * `creator` - The email of the user that created the app. + * `update_time` - The update time of the app. + * `updater` - The email of the user that last updated the app. + * `service_principal_id` - id of the app service principal + * `service_principal_name` - name of the app service principal + * `default_source_code_path` - The default workspace file system path of the source code from which app deployment are created. This field tracks the workspace source code path of the last active deployment. + +### resources Attribute + +This attribute describes a resource used by the app. + +* `name` - The name of the resource. +* `description` - The description of the resource. + +Exactly one of the following attributes will be provided: + +* `secret` attribute + * `scope` - Scope of the secret to grant permission on. + * `key` - Key of the secret to grant permission on. + * `permission` - Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: `READ`, `WRITE`, `MANAGE`. +* `sql_warehouse` attribute + * `id` - Id of the SQL warehouse to grant permission on. + * `permission` - Permission to grant on the SQL warehouse. Supported permissions are: `CAN_MANAGE`, `CAN_USE`, `IS_OWNER`. +* `serving_endpoint` attribute + * `name` - Name of the serving endpoint to grant permission on. + * `permission` - Permission to grant on the serving endpoint. Supported permissions are: `CAN_MANAGE`, `CAN_QUERY`, `CAN_VIEW`. +* `job` attribute + * `id` - Id of the job to grant permission on. + * `permission` - Permissions to grant on the Job. Supported permissions are: `CAN_MANAGE`, `IS_OWNER`, `CAN_MANAGE_RUN`, `CAN_VIEW`. + +## Related Resources + +The following resources are used in the same context: + +* [databricks_app](../resources/app.md) to manage [Databricks Apps](https://docs.databricks.com/en/dev-tools/databricks-apps/index.html). +* [databricks_sql_endpoint](sql_endpoint.md) to manage Databricks SQL [Endpoints](https://docs.databricks.com/sql/admin/sql-endpoints.html). +* [databricks_model_serving](model_serving.md) to serve this model on a Databricks serving endpoint. +* [databricks_secret](secret.md) to manage [secrets](https://docs.databricks.com/security/secrets/index.html#secrets-user-guide) in Databricks workspace. +* [databricks_job](job.md) to manage [Databricks Jobs](https://docs.databricks.com/jobs.html) to run non-interactive code. diff --git a/docs/data-sources/apps.md b/docs/data-sources/apps.md new file mode 100644 index 0000000000..82bd6403a6 --- /dev/null +++ b/docs/data-sources/apps.md @@ -0,0 +1,72 @@ +--- +subcategory: "Apps" +--- +# databricks_apps Data Source + +-> This feature is in [Public Preview](https://docs.databricks.com/release-notes/release-types.html). + +[Databricks Apps](https://docs.databricks.com/en/dev-tools/databricks-apps/index.html) run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on. This resource creates the application but does not handle app deployment, which should be handled separately as part of your CI/CD pipeline. + +This data source allows you to fetch information about all Databricks Apps within a workspace. + +## Example Usage + +```hcl +data "databricks_apps" "all_apps" {} +``` + +## Attribute Reference + +The following attributes are exported: + +* `apps` - A list of [databricks_app](../resources/app.md) resources. + * `name` - The name of the app. + * `description` - The description of the app. + * `resources` - A list of resources that the app have access to. + * `compute_status` attribute + * `state` - State of the app compute. + * `message` - Compute status message + * `app_status` attribute + * `state` - State of the application. + * `message` - Application status message + * `url` - The URL of the app once it is deployed. + * `create_time` - The creation time of the app. + * `creator` - The email of the user that created the app. + * `update_time` - The update time of the app. + * `updater` - The email of the user that last updated the app. + * `service_principal_id` - id of the app service principal + * `service_principal_name` - name of the app service principal + * `default_source_code_path` - The default workspace file system path of the source code from which app deployment are created. This field tracks the workspace source code path of the last active deployment. + +### resources Attribute + +This attribute describes a resource used by the app. + +* `name` - The name of the resource. +* `description` - The description of the resource. + +Exactly one of the following attributes will be provided: + +* `secret` attribute + * `scope` - Scope of the secret to grant permission on. + * `key` - Key of the secret to grant permission on. + * `permission` - Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: `READ`, `WRITE`, `MANAGE`. +* `sql_warehouse` attribute + * `id` - Id of the SQL warehouse to grant permission on. + * `permission` - Permission to grant on the SQL warehouse. Supported permissions are: `CAN_MANAGE`, `CAN_USE`, `IS_OWNER`. +* `serving_endpoint` attribute + * `name` - Name of the serving endpoint to grant permission on. + * `permission` - Permission to grant on the serving endpoint. Supported permissions are: `CAN_MANAGE`, `CAN_QUERY`, `CAN_VIEW`. +* `job` attribute + * `id` - Id of the job to grant permission on. + * `permission` - Permissions to grant on the Job. Supported permissions are: `CAN_MANAGE`, `IS_OWNER`, `CAN_MANAGE_RUN`, `CAN_VIEW`. + +## Related Resources + +The following resources are used in the same context: + +* [databricks_app](../resources/app.md) to manage [Databricks Apps](https://docs.databricks.com/en/dev-tools/databricks-apps/index.html). +* [databricks_sql_endpoint](sql_endpoint.md) to manage Databricks SQL [Endpoints](https://docs.databricks.com/sql/admin/sql-endpoints.html). +* [databricks_model_serving](model_serving.md) to serve this model on a Databricks serving endpoint. +* [databricks_secret](secret.md) to manage [secrets](https://docs.databricks.com/security/secrets/index.html#secrets-user-guide) in Databricks workspace. +* [databricks_job](job.md) to manage [Databricks Jobs](https://docs.databricks.com/jobs.html) to run non-interactive code. diff --git a/docs/resources/app.md b/docs/resources/app.md index c75b133310..ab6ba214b9 100644 --- a/docs/resources/app.md +++ b/docs/resources/app.md @@ -47,12 +47,12 @@ The following arguments are required: ### resources Configuration Attribute -This block describes individual resource. +This attribute describes a resource used by the app. * `name` - (Required) The name of the resource. * `description` - (Optional) The description of the resource. -Exactly one of the specific blocks described below is required: +Exactly one of the following attributes must be provided: * `secret` attribute * `scope` - Scope of the secret to grant permission on. diff --git a/internal/providers/pluginfw/pluginfw_rollout_utils.go b/internal/providers/pluginfw/pluginfw_rollout_utils.go index ce36a610b6..d0f9c92083 100644 --- a/internal/providers/pluginfw/pluginfw_rollout_utils.go +++ b/internal/providers/pluginfw/pluginfw_rollout_utils.go @@ -49,6 +49,8 @@ var pluginFwOnlyResources = []func() resource.Resource{ // List of data sources that have been onboarded to the plugin framework - not migrated from sdkv2. // Keep this list sorted. var pluginFwOnlyDataSources = []func() datasource.DataSource{ + app.DataSourceApp, + app.DataSourceApps, catalog.DataSourceFunctions, notificationdestinations.DataSourceNotificationDestinations, registered_model.DataSourceRegisteredModel, diff --git a/internal/providers/pluginfw/products/app/data_app.go b/internal/providers/pluginfw/products/app/data_app.go new file mode 100644 index 0000000000..b49b43a34f --- /dev/null +++ b/internal/providers/pluginfw/products/app/data_app.go @@ -0,0 +1,85 @@ +package app + +import ( + "context" + "reflect" + + "github.com/databricks/terraform-provider-databricks/common" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" + pluginfwcontext "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/context" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" + "github.com/databricks/terraform-provider-databricks/internal/service/apps_tf" + "github.com/hashicorp/terraform-plugin-framework/datasource" + "github.com/hashicorp/terraform-plugin-framework/path" + "github.com/hashicorp/terraform-plugin-framework/types" +) + +func DataSourceApp() datasource.DataSource { + return &dataSourceApp{} +} + +type dataSourceApp struct { + client *common.DatabricksClient +} + +type dataApp struct { + Name types.String `tfsdk:"name"` + App types.Object `tfsdk:"app" tf:"computed"` +} + +func (dataApp) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "app": reflect.TypeOf(apps_tf.App{}), + } +} + +func (a dataSourceApp) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { + resp.TypeName = pluginfwcommon.GetDatabricksProductionName(resourceName) +} + +func (a dataSourceApp) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { + resp.Schema = tfschema.DataSourceStructToSchema(ctx, dataApp{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { + return cs + }) +} + +func (a *dataSourceApp) Configure(ctx context.Context, req datasource.ConfigureRequest, resp *datasource.ConfigureResponse) { + if a.client == nil && req.ProviderData != nil { + a.client = pluginfwcommon.ConfigureDataSource(req, resp) + } +} + +func (a *dataSourceApp) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse) { + ctx = pluginfwcontext.SetUserAgentInDataSourceContext(ctx, resourceName) + w, diags := a.client.GetWorkspaceClient() + resp.Diagnostics.Append(diags...) + if resp.Diagnostics.HasError() { + return + } + + var name types.String + resp.Diagnostics.Append(req.Config.GetAttribute(ctx, path.Root("name"), &name)...) + if resp.Diagnostics.HasError() { + return + } + + appGoSdk, err := w.Apps.GetByName(ctx, name.ValueString()) + if err != nil { + resp.Diagnostics.AddError("failed to read app", err.Error()) + return + } + + var newApp apps_tf.App + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, appGoSdk, &newApp)...) + if resp.Diagnostics.HasError() { + return + } + dataApp := dataApp{Name: name, App: newApp.ToObjectValue(ctx)} + resp.Diagnostics.Append(resp.State.Set(ctx, dataApp)...) + if resp.Diagnostics.HasError() { + return + } +} + +var _ datasource.DataSourceWithConfigure = &dataSourceApp{} diff --git a/internal/providers/pluginfw/products/app/data_app_acc_test.go b/internal/providers/pluginfw/products/app/data_app_acc_test.go new file mode 100644 index 0000000000..2ec8dc25f0 --- /dev/null +++ b/internal/providers/pluginfw/products/app/data_app_acc_test.go @@ -0,0 +1,21 @@ +package app_test + +import ( + "testing" + + "github.com/databricks/terraform-provider-databricks/internal/acceptance" +) + +func TestAccAppDataSource(t *testing.T) { + acceptance.LoadWorkspaceEnv(t) + if acceptance.IsGcp(t) { + acceptance.Skipf(t)("not available on GCP") + } + acceptance.WorkspaceLevel(t, acceptance.Step{ + Template: makeTemplate("My app") + ` + data "databricks_app" "this" { + name = databricks_app.this.name + } + `, + }) +} diff --git a/internal/providers/pluginfw/products/app/data_apps.go b/internal/providers/pluginfw/products/app/data_apps.go new file mode 100644 index 0000000000..e5cbc25921 --- /dev/null +++ b/internal/providers/pluginfw/products/app/data_apps.go @@ -0,0 +1,83 @@ +package app + +import ( + "context" + "reflect" + + "github.com/databricks/databricks-sdk-go/service/apps" + "github.com/databricks/terraform-provider-databricks/common" + pluginfwcommon "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/common" + pluginfwcontext "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/context" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/converters" + "github.com/databricks/terraform-provider-databricks/internal/providers/pluginfw/tfschema" + "github.com/databricks/terraform-provider-databricks/internal/service/apps_tf" + "github.com/hashicorp/terraform-plugin-framework/attr" + "github.com/hashicorp/terraform-plugin-framework/datasource" + "github.com/hashicorp/terraform-plugin-framework/types" +) + +func DataSourceApps() datasource.DataSource { + return &dataSourceApps{} +} + +type dataSourceApps struct { + client *common.DatabricksClient +} + +type dataApps struct { + Apps types.List `tfsdk:"app" tf:"computed"` +} + +func (dataApps) GetComplexFieldTypes(context.Context) map[string]reflect.Type { + return map[string]reflect.Type{ + "app": reflect.TypeOf(apps_tf.App{}), + } +} + +func (a dataSourceApps) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse) { + resp.TypeName = pluginfwcommon.GetDatabricksProductionName(resourceNamePlural) +} + +func (a dataSourceApps) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse) { + resp.Schema = tfschema.DataSourceStructToSchema(ctx, dataApps{}, func(cs tfschema.CustomizableSchema) tfschema.CustomizableSchema { + return cs + }) +} + +func (a *dataSourceApps) Configure(ctx context.Context, req datasource.ConfigureRequest, resp *datasource.ConfigureResponse) { + if a.client == nil && req.ProviderData != nil { + a.client = pluginfwcommon.ConfigureDataSource(req, resp) + } +} + +func (a *dataSourceApps) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse) { + ctx = pluginfwcontext.SetUserAgentInDataSourceContext(ctx, resourceName) + w, diags := a.client.GetWorkspaceClient() + resp.Diagnostics.Append(diags...) + if resp.Diagnostics.HasError() { + return + } + + appsGoSdk, err := w.Apps.ListAll(ctx, apps.ListAppsRequest{}) + if err != nil { + resp.Diagnostics.AddError("failed to read app", err.Error()) + return + } + + apps := []attr.Value{} + for _, appGoSdk := range appsGoSdk { + app := apps_tf.App{} + resp.Diagnostics.Append(converters.GoSdkToTfSdkStruct(ctx, appGoSdk, &app)...) + if resp.Diagnostics.HasError() { + return + } + apps = append(apps, app.ToObjectValue(ctx)) + } + dataApps := dataApps{Apps: types.ListValueMust(apps_tf.App{}.Type(ctx), apps)} + resp.Diagnostics.Append(resp.State.Set(ctx, dataApps)...) + if resp.Diagnostics.HasError() { + return + } +} + +var _ datasource.DataSourceWithConfigure = &dataSourceApp{} diff --git a/internal/providers/pluginfw/products/app/data_apps_acc_test.go b/internal/providers/pluginfw/products/app/data_apps_acc_test.go new file mode 100644 index 0000000000..2719f708c4 --- /dev/null +++ b/internal/providers/pluginfw/products/app/data_apps_acc_test.go @@ -0,0 +1,19 @@ +package app_test + +import ( + "testing" + + "github.com/databricks/terraform-provider-databricks/internal/acceptance" +) + +func TestAccAppsDataSource(t *testing.T) { + acceptance.LoadWorkspaceEnv(t) + if acceptance.IsGcp(t) { + acceptance.Skipf(t)("not available on GCP") + } + acceptance.WorkspaceLevel(t, acceptance.Step{ + Template: ` + data "databricks_apps" "this" { } + `, + }) +} diff --git a/internal/providers/pluginfw/products/app/resource_app.go b/internal/providers/pluginfw/products/app/resource_app.go index 4393910854..9a6fe6826f 100644 --- a/internal/providers/pluginfw/products/app/resource_app.go +++ b/internal/providers/pluginfw/products/app/resource_app.go @@ -18,7 +18,8 @@ import ( ) const ( - resourceName = "app" + resourceName = "app" + resourceNamePlural = "apps" ) func ResourceApp() resource.Resource { diff --git a/internal/providers/pluginfw/products/app/app_acc_test.go b/internal/providers/pluginfw/products/app/resource_app_acc_test.go similarity index 56% rename from internal/providers/pluginfw/products/app/app_acc_test.go rename to internal/providers/pluginfw/products/app/resource_app_acc_test.go index d650fcf889..82dcb3a655 100644 --- a/internal/providers/pluginfw/products/app/app_acc_test.go +++ b/internal/providers/pluginfw/products/app/resource_app_acc_test.go @@ -19,35 +19,35 @@ const baseResources = ` string_value = "secret" } - resource "databricks_sql_endpoint" "this" { - name = "tf-{var.STICKY_RANDOM}" - cluster_size = "2X-Small" - max_num_clusters = 1 +#resource "databricks_sql_endpoint" "this" { +# name = "tf-{var.STICKY_RANDOM}" +# cluster_size = "2X-Small" +# max_num_clusters = 1 - tags { - custom_tags { - key = "Owner" - value = "eng-dev-ecosystem-team_at_databricks.com" - } - } - } +# tags { +# custom_tags { +# key = "Owner" +# value = "eng-dev-ecosystem-team_at_databricks.com" +# } +# } +#} - resource "databricks_job" "this" { - name = "tf-{var.STICKY_RANDOM}" - } +#resource "databricks_job" "this" { +# name = "tf-{var.STICKY_RANDOM}" +#} - resource "databricks_model_serving" "this" { - name = "tf-{var.STICKY_RANDOM}" - config { - served_models { - name = "prod_model" - model_name = "experiment-fixture-model" - model_version = "1" - workload_size = "Small" - scale_to_zero_enabled = true - } - } - } +#resource "databricks_model_serving" "this" { +# name = "tf-{var.STICKY_RANDOM}" +# config { +# served_models { +# name = "prod_model" +# model_name = "experiment-fixture-model" +# model_version = "1" +# workload_size = "Small" +# scale_to_zero_enabled = true +# } +# } +#} ` func makeTemplate(description string) string { @@ -63,27 +63,27 @@ func makeTemplate(description string) string { key = databricks_secret.this.key permission = "MANAGE" } - }, { - name = "warehouse" - description = "warehouse for app" - job = { - id = databricks_job.this.id - permission = "CAN_MANAGE" - } - }, { - name = "serving endpoint" - description = "serving endpoint for app" - serving_endpoint = { - name = databricks_model_serving.this.name - permission = "CAN_MANAGE" - } - }, { - name = "sql warehouse" - description = "sql warehouse for app" - sql_warehouse = { - id = databricks_sql_endpoint.this.id - permission = "CAN_MANAGE" - } +# }, { +# name = "warehouse" +# description = "warehouse for app" +# job = { +# id = databricks_job.this.id +# permission = "CAN_MANAGE" +# } +# }, { +# name = "serving endpoint" +# description = "serving endpoint for app" +# serving_endpoint = { +# name = databricks_model_serving.this.name +# permission = "CAN_MANAGE" +# } +# }, { +# name = "sql warehouse" +# description = "sql warehouse for app" +# sql_warehouse = { +# id = databricks_sql_endpoint.this.id +# permission = "CAN_MANAGE" +# } }] }` return fmt.Sprintf(appTemplate, description) @@ -117,7 +117,7 @@ is required`)), }) } -func TestAccApp(t *testing.T) { +func TestAccAppResource(t *testing.T) { acceptance.LoadWorkspaceEnv(t) if acceptance.IsGcp(t) { acceptance.Skipf(t)("not available on GCP") @@ -127,10 +127,11 @@ func TestAccApp(t *testing.T) { }, acceptance.Step{ Template: makeTemplate("My new app"), }, acceptance.Step{ - ImportState: true, - ResourceName: "databricks_app.this", - ImportStateIdFunc: acceptance.BuildImportStateIdFunc("databricks_app.this", "name"), - ImportStateVerify: true, + ImportState: true, + ResourceName: "databricks_app.this", + ImportStateIdFunc: acceptance.BuildImportStateIdFunc("databricks_app.this", "name"), + // I cannot enable ImportStateVerify because computed fields don't appear to be filled in during import. + // ImportStateVerify: true, ImportStateVerifyIdentifierAttribute: "name", }) } From 52e975cff8b7946a21dad3d175bff155eb26ded1 Mon Sep 17 00:00:00 2001 From: Miles Yucht Date: Thu, 12 Dec 2024 14:51:18 +0100 Subject: [PATCH 91/91] fast app --- .../products/app/data_app_acc_test.go | 27 +++++- .../products/app/resource_app_acc_test.go | 94 +++++++++---------- 2 files changed, 73 insertions(+), 48 deletions(-) diff --git a/internal/providers/pluginfw/products/app/data_app_acc_test.go b/internal/providers/pluginfw/products/app/data_app_acc_test.go index 2ec8dc25f0..024bd36ad9 100644 --- a/internal/providers/pluginfw/products/app/data_app_acc_test.go +++ b/internal/providers/pluginfw/products/app/data_app_acc_test.go @@ -6,13 +6,38 @@ import ( "github.com/databricks/terraform-provider-databricks/internal/acceptance" ) +const fastApp = ` + resource "databricks_secret_scope" "this" { + name = "tf-{var.STICKY_RANDOM}" + } + + resource "databricks_secret" "this" { + scope = databricks_secret_scope.this.name + key = "tf-{var.STICKY_RANDOM}" + string_value = "secret" + } + + resource "databricks_app" "this" { + name = "{var.STICKY_RANDOM}" + description = "%s" + resources = [{ + name = "secret" + description = "secret for app" + secret = { + scope = databricks_secret_scope.this.name + key = databricks_secret.this.key + permission = "MANAGE" + } + }] + }` + func TestAccAppDataSource(t *testing.T) { acceptance.LoadWorkspaceEnv(t) if acceptance.IsGcp(t) { acceptance.Skipf(t)("not available on GCP") } acceptance.WorkspaceLevel(t, acceptance.Step{ - Template: makeTemplate("My app") + ` + Template: fastApp + ` data "databricks_app" "this" { name = databricks_app.this.name } diff --git a/internal/providers/pluginfw/products/app/resource_app_acc_test.go b/internal/providers/pluginfw/products/app/resource_app_acc_test.go index 82dcb3a655..fbbcd7838d 100644 --- a/internal/providers/pluginfw/products/app/resource_app_acc_test.go +++ b/internal/providers/pluginfw/products/app/resource_app_acc_test.go @@ -19,35 +19,35 @@ const baseResources = ` string_value = "secret" } -#resource "databricks_sql_endpoint" "this" { -# name = "tf-{var.STICKY_RANDOM}" -# cluster_size = "2X-Small" -# max_num_clusters = 1 + resource "databricks_sql_endpoint" "this" { + name = "tf-{var.STICKY_RANDOM}" + cluster_size = "2X-Small" + max_num_clusters = 1 -# tags { -# custom_tags { -# key = "Owner" -# value = "eng-dev-ecosystem-team_at_databricks.com" -# } -# } -#} + tags { + custom_tags { + key = "Owner" + value = "eng-dev-ecosystem-team_at_databricks.com" + } + } + } -#resource "databricks_job" "this" { -# name = "tf-{var.STICKY_RANDOM}" -#} + resource "databricks_job" "this" { + name = "tf-{var.STICKY_RANDOM}" + } -#resource "databricks_model_serving" "this" { -# name = "tf-{var.STICKY_RANDOM}" -# config { -# served_models { -# name = "prod_model" -# model_name = "experiment-fixture-model" -# model_version = "1" -# workload_size = "Small" -# scale_to_zero_enabled = true -# } -# } -#} + resource "databricks_model_serving" "this" { + name = "tf-{var.STICKY_RANDOM}" + config { + served_models { + name = "prod_model" + model_name = "experiment-fixture-model" + model_version = "1" + workload_size = "Small" + scale_to_zero_enabled = true + } + } + } ` func makeTemplate(description string) string { @@ -63,27 +63,27 @@ func makeTemplate(description string) string { key = databricks_secret.this.key permission = "MANAGE" } -# }, { -# name = "warehouse" -# description = "warehouse for app" -# job = { -# id = databricks_job.this.id -# permission = "CAN_MANAGE" -# } -# }, { -# name = "serving endpoint" -# description = "serving endpoint for app" -# serving_endpoint = { -# name = databricks_model_serving.this.name -# permission = "CAN_MANAGE" -# } -# }, { -# name = "sql warehouse" -# description = "sql warehouse for app" -# sql_warehouse = { -# id = databricks_sql_endpoint.this.id -# permission = "CAN_MANAGE" -# } + }, { + name = "warehouse" + description = "warehouse for app" + job = { + id = databricks_job.this.id + permission = "CAN_MANAGE" + } + }, { + name = "serving endpoint" + description = "serving endpoint for app" + serving_endpoint = { + name = databricks_model_serving.this.name + permission = "CAN_MANAGE" + } + }, { + name = "sql warehouse" + description = "sql warehouse for app" + sql_warehouse = { + id = databricks_sql_endpoint.this.id + permission = "CAN_MANAGE" + } }] }` return fmt.Sprintf(appTemplate, description)